Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
}
}
export const EnablePublishSidebarOption = compose(
withSelect( ( select ) => ( {
isChecked: select( 'core/editor' ).isPublishSidebarEnabled(),
} ) ),
withDispatch( ( dispatch ) => {
const { enablePublishSidebar, disablePublishSidebar } = dispatch( 'core/editor' );
return {
onChange: ( isEnabled ) => ( isEnabled ? enablePublishSidebar() : disablePublishSidebar() ),
};
} ),
// In < medium viewports we override this option and always show the publish sidebar.
// See the edit-post's header component for the specific logic.
ifViewportMatches( 'medium' ),
)( Option );
export const EnableTipsOption = compose(
withSelect( ( select ) => ( {
isChecked: select( 'core/nux' ).areTipsEnabled(),
} ) ),
withDispatch( ( dispatch ) => {
const { enableTips, disableTips } = dispatch( 'core/nux' );
return {
onChange: ( isEnabled ) => ( isEnabled ? enableTips() : disableTips() ),
};
} )
)(
// Using DeferredOption here means enableTips() is called when the Options
// modal is dismissed. This stops the NUX guide from appearing above the
// Options modal, which looks totally weird.
info={ __( 'Focus on one block at a time' ) }
messageActivated={ __( 'Spotlight mode activated' ) }
messageDeactivated={ __( 'Spotlight mode deactivated' ) }
/>
);
}
export default ifViewportMatches( 'medium' )( WritingMenu );
feature="fixedToolbar"
label={ __( 'Top Toolbar' ) }
info={ __( 'Access all block and document tools in a single place' ) }
onToggle={ onClose }
/>
);
}
export default ifViewportMatches( 'medium' )( WritingMenu );
*/
import BlockMover from '../block-mover';
import BlockSettingsMenu from '../block-settings-menu';
import VisualEditorInserter from '../inserter';
function BlockMobileToolbar( { rootUID, uid, renderBlockMenu } ) {
return (
<div>
</div>
);
}
export default ifViewportMatches( '< small' )( BlockMobileToolbar );