mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 09:37:42 +01:00
Docs: Add a reference to WP_Customize_Section::__construct()
for information on accepted arguments in WP_Customize_Manager::add_section()
.
Synchronize the documentation between two places, use `WP_Customize_Section::__construct()` as the canonical source. Props amolv, marekdedic. Fixes #48346. Built from https://develop.svn.wordpress.org/trunk@47386 git-svn-id: http://core.svn.wordpress.org/trunk@47173 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
569319f553
commit
9043b9833f
@ -3899,25 +3899,12 @@ final class WP_Customize_Manager {
|
|||||||
* @since 3.4.0
|
* @since 3.4.0
|
||||||
* @since 4.5.0 Return added WP_Customize_Section instance.
|
* @since 4.5.0 Return added WP_Customize_Section instance.
|
||||||
*
|
*
|
||||||
* @param WP_Customize_Section|string $id Customize Section object, or Section ID.
|
* @see WP_Customize_Section::__construct()
|
||||||
* @param array $args {
|
|
||||||
* Optional. Array of properties for the new Section object. Default empty array.
|
|
||||||
*
|
*
|
||||||
* @type int $priority Priority of the section, defining the display order
|
* @param WP_Customize_Section|string $id Customize Section object, or Section ID.
|
||||||
* of panels and sections. Default 160.
|
* @param array $args Optional. Array of properties for the new Section object.
|
||||||
* @type string $panel The panel this section belongs to (if any).
|
* See WP_Customize_Section::__construct() for information
|
||||||
* Default empty.
|
* on accepted arguments. Default empty array.
|
||||||
* @type string $capability Capability required for the section.
|
|
||||||
* Default 'edit_theme_options'
|
|
||||||
* @type string|string[] $theme_supports Theme features required to support the section.
|
|
||||||
* @type string $title Title of the section to show in UI.
|
|
||||||
* @type string $description Description to show in the UI.
|
|
||||||
* @type string $type Type of the section.
|
|
||||||
* @type callable $active_callback Active callback.
|
|
||||||
* @type bool $description_hidden Hide the description behind a help icon,
|
|
||||||
* instead of inline above the first control.
|
|
||||||
* Default false.
|
|
||||||
* }
|
|
||||||
* @return WP_Customize_Section The instance of the section that was added.
|
* @return WP_Customize_Section The instance of the section that was added.
|
||||||
*/
|
*/
|
||||||
public function add_section( $id, $args = array() ) {
|
public function add_section( $id, $args = array() ) {
|
||||||
|
@ -150,7 +150,24 @@ class WP_Customize_Section {
|
|||||||
*
|
*
|
||||||
* @param WP_Customize_Manager $manager Customizer bootstrap instance.
|
* @param WP_Customize_Manager $manager Customizer bootstrap instance.
|
||||||
* @param string $id A specific ID of the section.
|
* @param string $id A specific ID of the section.
|
||||||
* @param array $args Section arguments.
|
* @param array $args {
|
||||||
|
* Optional. Array of properties for the new Section object. Default empty array.
|
||||||
|
*
|
||||||
|
* @type int $priority Priority of the section, defining the display order
|
||||||
|
* of panels and sections. Default 160.
|
||||||
|
* @type string $panel The panel this section belongs to (if any).
|
||||||
|
* Default empty.
|
||||||
|
* @type string $capability Capability required for the section.
|
||||||
|
* Default 'edit_theme_options'
|
||||||
|
* @type string|string[] $theme_supports Theme features required to support the section.
|
||||||
|
* @type string $title Title of the section to show in UI.
|
||||||
|
* @type string $description Description to show in the UI.
|
||||||
|
* @type string $type Type of the section.
|
||||||
|
* @type callable $active_callback Active callback.
|
||||||
|
* @type bool $description_hidden Hide the description behind a help icon,
|
||||||
|
* instead of inline above the first control.
|
||||||
|
* Default false.
|
||||||
|
* }
|
||||||
*/
|
*/
|
||||||
public function __construct( $manager, $id, $args = array() ) {
|
public function __construct( $manager, $id, $args = array() ) {
|
||||||
$keys = array_keys( get_object_vars( $this ) );
|
$keys = array_keys( get_object_vars( $this ) );
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '5.4-beta3-47385';
|
$wp_version = '5.4-beta3-47386';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
Loading…
Reference in New Issue
Block a user