[ Index ]

PHP Cross Reference of WordPress Trunk (Updated Daily)

Search

title

Body

[close]

/wp-includes/js/dist/ -> customize-widgets.js (summary)

(no description)

File Size: 2751 lines (99 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 2 classes

ErrorBoundary:: (43 methods):
  BlockInspectorButton()
  r()
  blockInserterPanel()
  isInserterOpened()
  __experimentalGetInsertionPoint()
  setIsInserterOpened()
  Inserter()
  KeyCombination()
  Shortcut()
  DynamicShortcut()
  KeyboardShortcutHelpModal()
  MoreMenu()
  Header()
  useInserter()
  settingIdToWidgetId()
  blockToWidget()
  widgetToBlock()
  widgetsToBlocks()
  useSidebarBlockEditor()
  FocusControl()
  handleFocus()
  handleReady()
  useBlocksFocusControl()
  SidebarEditorProvider()
  WelcomeGuide()
  KeyboardShortcuts()
  KeyboardShortcutsRegister()
  BlockAppender()
  SidebarBlockEditor()
  SidebarControls()
  useSidebarControls()
  useActiveSidebarControl()
  useClearSelectedBlock()
  handleClearSelectedBlock()
  handleMouseDown()
  handleBlur()
  CustomizeWidgets()
  getInspectorSection()
  getSidebarSection()
  parseWidgetId()
  widgetIdToSettingId()
  debounce()
  debounced()

SidebarAdapter:: (4 methods):
  getInserterOuterSection()
  getSidebarControl()
  moveToSidebar()
  initialize()

Defines 4 functions

  __webpack_require__()
  CopyButton()

Class: ErrorBoundary  - X-Ref

BlockInspectorButton({inspector,closeMenu,...props})   X-Ref
No description

r(e)   X-Ref
No description

blockInserterPanel(state = false, action)   X-Ref
Reducer tracking whether the inserter is open.

param: {boolean|Object} state
param: {Object}         action

isInserterOpened(state)   X-Ref
Returns true if the inserter is opened.

return: {boolean} Whether the inserter is opened.
param: {Object} state Global application state.

__experimentalGetInsertionPoint(state)   X-Ref
Get the insertion point for the inserter.

return: {Object} The root client ID and index to insert at.
param: {Object} state Global application state.

setIsInserterOpened(value)   X-Ref
Returns an action object used to open/close the inserter.

return: {Object} Action object.
param: {boolean|Object} value                Whether the inserter should be
param: {string}         value.rootClientId   The root client ID to insert at.
param: {number}         value.insertionIndex The index to insert at.

Inserter({setIsOpened})   X-Ref
No description

KeyCombination({keyCombination,forceAriaLabel})   X-Ref
No description

Shortcut({description,keyCombination,aliases = [],ariaLabel})   X-Ref
No description

DynamicShortcut({name})   X-Ref
Internal dependencies


KeyboardShortcutHelpModal({isModalActive,toggleModal})   X-Ref
No description

MoreMenu()   X-Ref
No description

Header({sidebar,inserter,isInserterOpened,setIsInserterOpened,isFixedToolbarActive})   X-Ref
No description

useInserter(inserter)   X-Ref
Internal dependencies


settingIdToWidgetId(settingId)   X-Ref
Convert settingId to widgetId.

return: {string} The widget id.
param: {string} settingId The setting id.

blockToWidget(block, existingWidget = null)   X-Ref
Transform a block to a customizable widget.

return: {Object} The transformed widget.
param: {WPBlock} block          The block to be transformed from.
param: {Object}  existingWidget The widget to be extended from.

widgetToBlock({id,idBase,number,instance})   X-Ref
Transform a widget to a block.

return: {WPBlock} The transformed block.
param: {Object} widget          The widget to be transformed from.
param: {string} widget.id       The widget id.
param: {string} widget.idBase   The id base of the widget.
param: {number} widget.number   The number/index of the widget.
param: {Object} widget.instance The instance of the widget.

widgetsToBlocks(widgets)   X-Ref
Internal dependencies


useSidebarBlockEditor(sidebar)   X-Ref
No description

FocusControl({api,sidebarControls,children})   X-Ref
No description

handleFocus(settingId)   X-Ref
No description

handleReady()   X-Ref
No description

useBlocksFocusControl(blocks)   X-Ref
Internal dependencies


SidebarEditorProvider({sidebar,settings,children})   X-Ref
No description

WelcomeGuide({sidebar})   X-Ref
No description

KeyboardShortcuts({undo,redo,save})   X-Ref
No description

KeyboardShortcutsRegister()   X-Ref
No description

BlockAppender(props)   X-Ref
No description

SidebarBlockEditor({blockEditorSettings,sidebar,inserter,inspector})   X-Ref
No description

SidebarControls({sidebarControls,activeSidebarControl,children})   X-Ref
No description

useSidebarControls()   X-Ref
No description

useActiveSidebarControl()   X-Ref
No description

useClearSelectedBlock(sidebarControl, popoverRef)   X-Ref
We can't just use <BlockSelectionClearer> because the customizer has
many root nodes rather than just one in the post editor.
We need to listen to the focus events in all those roots, and also in
the preview iframe.
This hook will clear the selected block when focusing outside the editor,
with a few exceptions:
1. Focusing on popovers.
2. Focusing on the inspector.
3. Focusing on any modals/dialogs.
These cases are normally triggered by user interactions from the editor,
not by explicitly focusing outside the editor, hence no need for clearing.

param: {Object} sidebarControl The sidebar control instance.
param: {Object} popoverRef     The ref object of the popover node container.

handleClearSelectedBlock(element)   X-Ref
No description

handleMouseDown(event)   X-Ref
No description

handleBlur()   X-Ref
No description

CustomizeWidgets({api,sidebarControls,blockEditorSettings})   X-Ref
No description

getInspectorSection()   X-Ref
No description

getSidebarSection()   X-Ref
Internal dependencies


parseWidgetId(widgetId)   X-Ref
No description

widgetIdToSettingId(widgetId)   X-Ref
No description

debounce(leading, callback, timeout)   X-Ref
This is a custom debounce function to call different callbacks depending on
whether it's the _leading_ call or not.

return: {Function} The debounced function.
param: {Function} leading  The callback that gets called first.
param: {Function} callback The callback that gets called after the first time.
param: {number}   timeout  The debounced time in milliseconds.

debounced(...args)   X-Ref
No description

Class: SidebarAdapter  - X-Ref

getInserterOuterSection()   X-Ref
Internal dependencies


getSidebarControl()   X-Ref
No description

moveToSidebar(sidebarControlId)   X-Ref
No description

initialize(editorName, blockEditorSettings)   X-Ref
Initializes the widgets block editor in the customizer.

param: {string} editorName          The editor name.
param: {Object} blockEditorSettings Block editor settings.

Functions
Functions that are not part of a class:

__webpack_require__(moduleId)   X-Ref
No description

CopyButton({text,children})   X-Ref
No description



Generated : Sat Nov 23 08:20:01 2024 Cross-referenced by PHPXref