Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adjust block inserter style. #3075

Merged
merged 3 commits into from
Aug 22, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions assets/src/stories-editor/components/inserter/edit.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
.amp__block-editor-inserter__menu.block-editor-inserter__menu {
miina marked this conversation as resolved.
Show resolved Hide resolved
display: block;
miina marked this conversation as resolved.
Show resolved Hide resolved
}

.amp__block-editor-inserter__search.block-editor-inserter__search {
width: 90%;
}

.amp__block-editor-inserter__results.block-editor-inserter__results {
height: 360px;
}
1 change: 1 addition & 0 deletions assets/src/stories-editor/components/inserter/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import { withSelect } from '@wordpress/data';
* Internal dependencies
*/
import InserterMenu from './menu'; // eslint-disable-line import/no-named-as-default
import './edit.css';

const defaultRenderToggle = ( { onToggle, disabled, isOpen } ) => (
<IconButton
Expand Down
6 changes: 3 additions & 3 deletions assets/src/stories-editor/components/inserter/menu.js
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ export class InserterMenu extends Component {
/* eslint-disable jsx-a11y/no-autofocus, jsx-a11y/no-static-element-interactions */
return (
<div
className="editor-inserter__menu block-editor-inserter__menu"
className="editor-inserter__menu block-editor-inserter__menu amp__block-editor-inserter__menu"
onKeyPress={ stopKeyPropagation }
onKeyDown={ this.onKeyDown }
>
Expand All @@ -285,13 +285,13 @@ export class InserterMenu extends Component {
id={ `block-editor-inserter__search-${ instanceId }` }
type="search"
placeholder={ __( 'Search for an element', 'amp' ) }
className="editor-inserter__search block-editor-inserter__search"
className="editor-inserter__search block-editor-inserter__search amp__block-editor-inserter__search"
autoFocus
onChange={ this.onChangeSearchInput }
/>

<div
className="editor-inserter__results block-editor-inserter__results"
className="editor-inserter__results amp__block-editor-inserter__results block-editor-inserter__results"
ref={ this.inserterResults }
tabIndex="0"
role="region"
Expand Down