Skip to content

Commit

Permalink
Docs: Various Docblock fixes in `wp-includes/class-wp-customize-contr…
Browse files Browse the repository at this point in the history
…ol.php`, as per WP Docs standards;

See #62281.




git-svn-id: https://develop.svn.wordpress.org/trunk@59785 602fd350-edb4-49c9-b593-d223f7449a82
  • Loading branch information
audrasjb committed Feb 8, 2025
1 parent 3f4d358 commit 37f4f61
Showing 1 changed file with 16 additions and 15 deletions.
31 changes: 16 additions & 15 deletions src/wp-includes/class-wp-customize-control.php
Original file line number Diff line number Diff line change
Expand Up @@ -247,14 +247,14 @@ public function __construct( $manager, $id, $args = array() ) {
}

/**
* Enqueue control related scripts/styles.
* Enqueues control related scripts/styles.
*
* @since 3.4.0
*/
public function enqueue() {}

/**
* Check whether control is active to current Customizer preview.
* Checks whether control is active to current Customizer preview.
*
* @since 4.0.0
*
Expand Down Expand Up @@ -292,7 +292,7 @@ public function active_callback() {
}

/**
* Fetch a setting's value.
* Fetches a setting's value.
* Grabs the main setting by default.
*
* @since 3.4.0
Expand All @@ -307,7 +307,7 @@ final public function value( $setting_key = 'default' ) {
}

/**
* Refresh the parameters passed to the JavaScript via JSON.
* Refreshes the parameters passed to the JavaScript via JSON.
*
* @since 3.4.0
*/
Expand All @@ -332,7 +332,7 @@ public function to_json() {
}

/**
* Get the data to export to the client via JSON.
* Gets the data to export to the client via JSON.
*
* @since 4.1.0
*
Expand Down Expand Up @@ -375,7 +375,7 @@ final public function check_capabilities() {
}

/**
* Get the control's content for insertion into the Customizer pane.
* Gets the control's content for insertion into the Customizer pane.
*
* @since 4.1.0
*
Expand All @@ -388,7 +388,7 @@ final public function get_content() {
}

/**
* Check capabilities and render the control.
* Checks capabilities and render the control.
*
* @since 3.4.0
* @uses WP_Customize_Control::render()
Expand Down Expand Up @@ -437,14 +437,15 @@ protected function render() {
}

/**
* Get the data link attribute for a setting.
* Gets the data link attribute for a setting.
*
* @since 3.4.0
* @since 4.9.0 Return a `data-customize-setting-key-link` attribute if a setting is not registered for the supplied setting key.
*
* @param string $setting_key
* @return string Data link parameter, a `data-customize-setting-link` attribute if the `$setting_key` refers to a pre-registered setting,
* and a `data-customize-setting-key-link` attribute if the setting is not yet registered.
* @return string Data link parameter, a `data-customize-setting-link` attribute if the `$setting_key` refers
* to a pre-registered setting, and a `data-customize-setting-key-link` attribute if the setting
* is not yet registered.
*/
public function get_link( $setting_key = 'default' ) {
if ( isset( $this->settings[ $setting_key ] ) && $this->settings[ $setting_key ] instanceof WP_Customize_Setting ) {
Expand All @@ -455,19 +456,19 @@ public function get_link( $setting_key = 'default' ) {
}

/**
* Render the data link attribute for the control's input element.
* Renders the data link attribute for the control's input element.
*
* @since 3.4.0
* @uses WP_Customize_Control::get_link()
*
* @param string $setting_key
* @param string $setting_key Default 'default'.
*/
public function link( $setting_key = 'default' ) {
echo $this->get_link( $setting_key );
}

/**
* Render the custom attributes for the control's input element.
* Renders the custom attributes for the control's input element.
*
* @since 4.0.0
*/
Expand All @@ -478,7 +479,7 @@ public function input_attrs() {
}

/**
* Render the control's content.
* Renders the control's content.
*
* Allows the content to be overridden without having to rewrite the wrapper in `$this::render()`.
*
Expand Down Expand Up @@ -674,7 +675,7 @@ protected function render_content() {
}

/**
* Render the control's JS template.
* Renders the control's JS template.
*
* This function is only run for control types that have been registered with
* WP_Customize_Manager::register_control_type().
Expand Down

0 comments on commit 37f4f61

Please sign in to comment.