UNPKG

@wordpress/components

Version:
34 lines (31 loc) 876 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.useToolsPanelContext = exports.ToolsPanelContext = void 0; var _element = require("@wordpress/element"); /** * WordPress dependencies */ /** * Internal dependencies */ const noop = () => undefined; const ToolsPanelContext = exports.ToolsPanelContext = (0, _element.createContext)({ menuItems: { default: {}, optional: {} }, hasMenuItems: false, isResetting: false, shouldRenderPlaceholderItems: false, registerPanelItem: noop, deregisterPanelItem: noop, flagItemCustomization: noop, registerResetAllFilter: noop, deregisterResetAllFilter: noop, areAllOptionalControlsHidden: true }); const useToolsPanelContext = () => (0, _element.useContext)(ToolsPanelContext); exports.useToolsPanelContext = useToolsPanelContext; //# sourceMappingURL=context.js.map