[ Index ]

PHP Cross Reference of WordPress

title

Body

[close]

/wp-includes/ -> class-wp-customize-panel.php (summary)

WordPress Customize Panel classes

File Size: 395 lines (10 kb)
Included or required: 1 time
Referenced: 0 times
Includes or requires: 1 file
 wp-includes/customize/class-wp-customize-nav-menus-panel.php

Defines 1 class

WP_Customize_Panel:: (12 methods):
  __construct()
  active()
  active_callback()
  json()
  check_capabilities()
  get_content()
  maybe_render()
  render()
  render_content()
  print_template()
  render_template()
  content_template()


Class: WP_Customize_Panel  - X-Ref

Customize Panel class.

A UI container for sections, managed by the WP_Customize_Manager.

__construct( $manager, $id, $args = array()   X-Ref
Constructor.

Any supplied $args override class property defaults.

param: WP_Customize_Manager $manager Customizer bootstrap instance.
param: string               $id      A specific ID for the panel.
param: array                $args    {
since: 4.0.0

active()   X-Ref
Check whether panel is active to current Customizer preview.

return: bool Whether the panel is active to the current preview.
since: 4.1.0

active_callback()   X-Ref
Default callback used when invoking WP_Customize_Panel::active().

Subclasses can override this with their specific logic, or they may
provide an 'active_callback' argument to the constructor.

return: bool Always true.
since: 4.1.0

json()   X-Ref
Gather the parameters passed to client JavaScript via JSON.

return: array The array to be exported to the client as JSON.
since: 4.1.0

check_capabilities()   X-Ref
Checks required user capabilities and whether the theme has the
feature support required by the panel.

return: bool False if theme doesn't support the panel or the user doesn't have the capability.
since: 4.0.0
since: 5.9.0 Method was marked non-final.

get_content()   X-Ref
Get the panel's content template for insertion into the Customizer pane.

return: string Content for the panel.
since: 4.1.0

maybe_render()   X-Ref
Check capabilities and render the panel.

since: 4.0.0

render()   X-Ref
Render the panel container, and then its contents (via `this->render_content()`) in a subclass.

Panel containers are now rendered in JS by default, see WP_Customize_Panel::print_template().

since: 4.0.0

render_content()   X-Ref
Render the panel UI in a subclass.

Panel contents are now rendered in JS by default, see WP_Customize_Panel::print_template().

since: 4.1.0

print_template()   X-Ref
Render the panel's JS templates.

This function is only run for panel types that have been registered with
WP_Customize_Manager::register_panel_type().

since: 4.3.0

render_template()   X-Ref
An Underscore (JS) template for rendering this panel's container.

Class variables for this panel class are available in the `data` JS object;
export custom variables by overriding WP_Customize_Panel::json().

since: 4.3.0

content_template()   X-Ref
An Underscore (JS) template for this panel's content (but not its container).

Class variables for this panel class are available in the `data` JS object;
export custom variables by overriding WP_Customize_Panel::json().

since: 4.3.0



Generated: Sun Dec 22 01:00:02 2024 Cross-referenced by PHPXref 0.7.1