MCPcopy Create free account
hub / github.com/GrapesJS/react / EditorOptionsState

Interface EditorOptionsState

packages/grapesjs-react/src/context/EditorOptions.tsx:6–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4const EditorOptionsContext = createContext<EditorOptionsState | null>(null);
5
6export interface EditorOptionsState {
7 refCanvas?: HTMLElement;
8 customModal?: boolean;
9 customAssets?: boolean;
10 customStyles?: boolean;
11 customBlocks?: boolean;
12 customLayers?: boolean;
13 customSelectors?: boolean;
14 customTraits?: boolean;
15 customRte?: boolean;
16 ready?: boolean;
17 setRefCanvas: (ref: HTMLElement) => void;
18 setCustomModal: (value: boolean) => void;
19 setCustomAssets: (value: boolean) => void;
20 setCustomBlocks: (value: boolean) => void;
21 setCustomRte: (value: boolean) => void;
22 setCustomStyles: (value: boolean) => void;
23 setCustomLayers: (value: boolean) => void;
24 setCustomSelectors: (value: boolean) => void;
25 setCustomTraits: (value: boolean) => void;
26 setReady: (value: boolean) => void;
27}
28
29export const EditorOptionsProvider = ({ children }: { children?: ReactNode }) => {
30 const [state, setState] = useState<EditorOptionsState>(() => ({

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected