/** * WordPress dependencies */ import { __ } from '@wordpress/i18n'; import { useContext } from '@wordpress/element'; /** * Internal dependencies */ import type { EditorOptions } from '../../../../types'; import { AdminContext } from '../../../index'; import SettingItem from '../../components/setting-item'; export default function MinimapAutohide() { const { editorOptions, setEditorOptions } = useContext( AdminContext ); const onChange = ( value: EditorOptions[ 'minimap' ][ 'autohide' ] ) => { setEditorOptions( { ...editorOptions, minimap: { ...editorOptions.minimap, autohide: value, }, } ); }; return (