From acb1b8badf559af5e886afce00e433ef8819bdaa Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Sun, 4 Feb 2024 15:49:05 +0200 Subject: [PATCH 01/11] Generate stubs for ACF PRO 6.1.8 --- acf-pro-stubs.php | 66 ++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 65 insertions(+), 1 deletion(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index 793a3a2..13f4193 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.1.7'; + public $version = '6.1.8'; /** * The plugin settings array. * @@ -64,6 +64,7 @@ public function initialize() * @since 5.0.0 * * @return void + * @phpstan-return void */ public function init() { @@ -95,12 +96,14 @@ public function register_post_status() * Hooked on `activated_plugin` so other plugin is deactivated when current plugin is activated. * * @param string $plugin The plugin being activated. + * @phpstan-return void */ public function deactivate_other_instances($plugin) { } /** * Displays a notice when either ACF or ACF PRO is automatically deactivated. + * @phpstan-return void */ public function plugin_deactivated_notice() { @@ -323,6 +326,7 @@ public function get_current_admin_url($params = '') * @since 5.0.0 * * @return void + * @phpstan-return void */ public function current_screen() { @@ -507,6 +511,7 @@ public function get_action_notice_text($action, $count = 1) * Checks for the custom "Activate" bulk action. * * @since 6.0 + * @phpstan-return void */ public function check_activate() { @@ -515,6 +520,7 @@ public function check_activate() * Checks for the custom "Deactivate" bulk action. * * @since 6.0 + * @phpstan-return void */ public function check_deactivate() { @@ -526,6 +532,7 @@ public function check_deactivate() * @since 5.9.0 * * @return void + * @phpstan-return void */ public function check_duplicate() { @@ -537,6 +544,7 @@ public function check_duplicate() * @since 5.9.0 * * @return void + * @phpstan-return void */ public function check_sync() { @@ -668,6 +676,7 @@ public function post_updated_messages($messages) * @since 5.0.0 * * @return void + * @phpstan-return void */ public function current_screen() { @@ -754,6 +763,7 @@ public function verify_save_post($post_id, $post) * @since 6.1 * * @return void + * @phpstan-return never */ public function ajax_link_field_groups() { @@ -993,6 +1003,7 @@ function alias($name = '') * @param int $site_id New blog ID. * @param int prev_blog_id Prev blog ID. * @return void + * @phpstan-return void */ function switch_site($site_id, $prev_site_id) { @@ -1232,6 +1243,7 @@ function admin_menu() * @since 6.0.0 Reduce memory usage, cache network upgrade checks. * * @return void + * @phpstan-return void */ function network_admin_menu() { @@ -1370,6 +1382,7 @@ function __construct() * * @date 28/09/13 * @since 5.0.0 + * @phpstan-return void */ public function admin_menu() { @@ -1426,6 +1439,7 @@ public function setup_help_tab() * Shows a notice to import post types and taxonomies from CPTUI if that plugin is active. * * @since 6.1 + * @phpstan-return void */ public function maybe_show_import_from_cptui_notice() { @@ -1581,6 +1595,7 @@ public function admin_footer() * Renders HTML for the ACF PRO features upgrade notice. * * @return void + * @phpstan-return void */ public function include_pro_features() { @@ -1665,6 +1680,7 @@ public function mb_options() * @since 5.0.0 * * @return void + * @phpstan-return never */ public function ajax_render_location_rule() { @@ -1675,6 +1691,7 @@ public function ajax_render_location_rule() * @since 5.0.0 * * @return void + * @phpstan-return never */ public function ajax_render_field_settings() { @@ -1685,6 +1702,7 @@ public function ajax_render_field_settings() * @since 5.0.0 * * @return void No return, HTML output for AJAX consumption. + * @phpstan-return never */ public function ajax_move_field() { @@ -1728,6 +1746,7 @@ public function __construct() * Renders HTML for the ACF PRO features upgrade notice. * * @return void + * @phpstan-return void */ public function include_pro_features() { @@ -1795,6 +1814,7 @@ public function render_admin_table_column_locations($field_group) * * @param array $field_group The main field group array. * @return void + * @phpstan-return void */ public function render_admin_table_column_num_fields($field_group) { @@ -2077,6 +2097,7 @@ public function __construct() * Renders HTML for the ACF PRO features upgrade notice. * * @return void + * @phpstan-return void */ public function include_pro_features() { @@ -2087,6 +2108,7 @@ public function include_pro_features() * @since 6.1 * * @return void + * @phpstan-return void */ public function current_screen() { @@ -2131,6 +2153,7 @@ public function render_admin_table_column($column_name, $post) * * @param array $post_type The main post type array. * @return void + * @phpstan-return void */ public function render_admin_table_column_field_groups($post_type) { @@ -2142,6 +2165,7 @@ public function render_admin_table_column_field_groups($post_type) * * @param array $post_type The main post type array. * @return void + * @phpstan-return void */ public function render_admin_table_column_taxonomies($post_type) { @@ -2153,6 +2177,7 @@ public function render_admin_table_column_taxonomies($post_type) * * @param array $post_type The main post type array. * @return void + * @phpstan-return void */ public function render_admin_table_column_num_posts($post_type) { @@ -2221,6 +2246,7 @@ public function __construct() * Renders HTML for the ACF PRO features upgrade notice. * * @return void + * @phpstan-return void */ public function include_pro_features() { @@ -2231,6 +2257,7 @@ public function include_pro_features() * @since 6.1 * * @return void + * @phpstan-return void */ public function current_screen() { @@ -2275,6 +2302,7 @@ public function render_admin_table_column($column_name, $post) * * @param array $taxonomy The main taxonomy array. * @return void + * @phpstan-return void */ public function render_admin_table_column_field_groups($taxonomy) { @@ -2286,6 +2314,7 @@ public function render_admin_table_column_field_groups($taxonomy) * * @param array $taxonomy The main taxonomy array. * @return void + * @phpstan-return void */ public function render_admin_table_column_post_types($taxonomy) { @@ -2297,6 +2326,7 @@ public function render_admin_table_column_post_types($taxonomy) * * @param array $taxonomy The main taxonomy array. * @return void + * @phpstan-return void */ public function render_admin_table_column_num_terms($taxonomy) { @@ -3041,6 +3071,7 @@ function send($response) * * @param WP_Error error The error object. * @return void + * @phpstan-return never */ function send_error($error) { @@ -3450,6 +3481,7 @@ public function enqueue($args = array()) * * @param void * @return void + * @phpstan-return void */ public function enqueue_uploader() { @@ -3486,6 +3518,7 @@ public function print_scripts() * * @param void * @return void + * @phpstan-return void */ public function print_footer_scripts() { @@ -4464,6 +4497,7 @@ function initialize() * * @param array $field The field settings array * @return void + * @phpstan-return void */ function render_field($field) { @@ -9587,6 +9621,7 @@ function __construct() * * @param void * @return void + * @phpstan-return void */ function initialize() { @@ -9837,6 +9872,7 @@ function __construct() * * @param void * @return void + * @phpstan-return void */ function admin_enqueue_scripts() { @@ -12098,6 +12134,7 @@ public function export_post_as_php($post = array()) * @since 6.1 * * @param array $post The main post type array. + * @phpstan-return void */ public function flush_post_cache($post) { @@ -12242,6 +12279,7 @@ public function export_post_as_php($post = array()) * @since 6.1 * * @param array $post The main post type array. + * @phpstan-return void */ public function flush_post_cache($post) { @@ -12279,6 +12317,7 @@ public function initialize($response, $handler, $request) } /** * Register our custom property as a REST field. + * @phpstan-return void */ public function register_field() { @@ -12344,6 +12383,7 @@ public function initialize() * * @param $post_id * @param array $field + * @phpstan-return void */ public function prepare_links($post_id, array $field) { @@ -12870,6 +12910,7 @@ function ajax_validate_save_post() * @since 5.4.0 * * @return void + * @phpstan-return void */ public function acf_validate_save_post() { @@ -13047,6 +13088,7 @@ function is_translatable() * @param array $field_group The new field group array. * @param object $ofg The old field group WP_Post object. * @return void + * @phpstan-return void */ function upgrade_500_field_group($field_group, $ofg) { @@ -13089,6 +13131,7 @@ function settings_load_json($paths) * * @param void * @return void + * @phpstan-return void */ function icl_make_duplicate($master_post_id, $lang, $postarr, $id) { @@ -13358,6 +13401,7 @@ function __construct() * * @param WP_Error $wp_error The error to display. * @return void + * @phpstan-return void */ function display_wp_error($wp_error) { @@ -13387,6 +13431,7 @@ function get_changelog_changes($changelog = '', $version = '') * * @param void * @return void + * @phpstan-return void */ function admin_menu() { @@ -14668,6 +14713,7 @@ function update_value($value, $post_id, $field) * * @param array $field The main field array. * @return void + * @phpstan-return void */ function delete_field($field) { @@ -14682,6 +14728,7 @@ function delete_field($field) * @param string $key The meta name/key (unused). * @param array $field The main field array. * @return void + * @phpstan-return void */ function delete_value($post_id, $key, $field) { @@ -14808,6 +14855,7 @@ public function get_field_name_from_input_name($input_name) * @since 6.0.0 * * @return void|WP_Error + * @phpstan-return never */ public function ajax_get_rows() { @@ -14847,6 +14895,7 @@ public function render() * @since 6.0.0 * * @return void + * @phpstan-return void */ public function thead() { @@ -14882,6 +14931,7 @@ public function row($i, $row, $return = \false) * * @param int $i The current row number. * @return void + * @phpstan-return void */ public function row_handle($i) { @@ -14892,6 +14942,7 @@ public function row_handle($i) * @since 6.0.0 * * @return void + * @phpstan-return void */ public function row_actions() { @@ -14902,6 +14953,7 @@ public function row_actions() * @since 6.0.0 * * @return void + * @phpstan-return void */ public function table_actions() { @@ -14913,6 +14965,7 @@ public function table_actions() * @since 6.0.0 * * @return void + * @phpstan-return void */ public function pagination() { @@ -15130,6 +15183,7 @@ function __construct() * @type function * @date 10/4/17 * @since 5.5.10 + * @phpstan-return void */ function init() { @@ -15363,6 +15417,7 @@ function acf_render_fields($fields, $post_id = 0, $el = 'div', $instruction = 'l * @param string $instruction The instruction render position (label|field). * @param bool $field_setting If a field setting is being rendered. * @return void + * @phpstan-return void */ function acf_render_field_wrap($field, $element = 'div', $instruction = 'label', $field_setting = \false) { @@ -15377,6 +15432,7 @@ function acf_render_field_wrap($field, $element = 'div', $instruction = 'label', * * @param array $field The field array. * @return void + * @phpstan-return void */ function acf_render_field($field) { @@ -18331,6 +18387,7 @@ function acf_preview_value($value, $post_id, $field) * @param string $function The function that noticed the problem. * * @return void + * @phpstan-return void */ function acf_log_invalid_field_notice($field, $function) { @@ -19466,6 +19523,7 @@ function acf_isset_termmeta($taxonomy = '') * * @param array $ancestors An internal parameter, not required. * @return void + * @phpstan-return void */ function acf_upload_files($ancestors = array()) { @@ -20281,6 +20339,8 @@ function get_field_objects($post_id = \false, $format_value = \true, $load_value * @param string $selector The field name or field key. * @param mixed $post_id The post ID where the value is saved. Defaults to the current post. * @return bool + * @phpstan-impure + * @phpstan-return bool */ function have_rows($selector, $post_id = \false) { @@ -22291,6 +22351,7 @@ function acf_upgrade_550() * * @param void * @return void + * @phpstan-return void */ function acf_upgrade_550_termmeta() { @@ -22648,6 +22709,7 @@ function acf_enqueue_block_type_assets($block_type) * @since 5.7.13 * * @return void + * @phpstan-return never */ function acf_ajax_fetch_block() { @@ -22834,6 +22896,7 @@ function acf_pro_get_activation_failure_transient() * * @date 11/10/2021 * @since 5.11.0 + * @phpstan-return void */ function acf_pro_display_activation_error() { @@ -22941,6 +23004,7 @@ function acf_pro_deactivate_license($silent = \false) * @since 5.7.10 * * @param WP_Error $wp_error The error to display. + * @phpstan-return void */ function display_wp_activation_error($wp_error) { From cffe317493d67cd562dda19b0eef5ebdb22d2cfa Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Sun, 4 Feb 2024 15:49:08 +0200 Subject: [PATCH 02/11] Generate stubs for ACF PRO 6.2.0 --- acf-pro-stubs.php | 1212 +++++++++++++++++++++++++++++++++++++++------ 1 file changed, 1065 insertions(+), 147 deletions(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index 13f4193..13ddd6a 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.1.8'; + public $version = '6.2.0'; /** * The plugin settings array. * @@ -281,6 +281,12 @@ class ACF_Admin_Internal_Post_Type_List * @var string */ public $store = ''; + /** + * If this is a pro feature or not. + * + * @var bool + */ + public $is_pro_feature = \false; /** * Constructs the class. */ @@ -1462,10 +1468,21 @@ function in_admin_header() * @date 7/4/20 * @since 5.9.0 * - * @param string $text The admin footer text. + * @param string $text The current admin footer text. + * @return string + */ + public function admin_footer_text($text) + { + } + /** + * Modifies the admin footer version text. + * + * @since 6.2 + * + * @param string $text The current admin footer version text. * @return string */ - function admin_footer_text($text) + public function admin_footer_version_text($text) { } /** @@ -6691,18 +6708,13 @@ function render_field_presentation_settings($field) class acf_field_post_object extends \acf_field { /** - * __construct - * * This function will setup the field type data * * @type function * @date 5/03/2014 * @since 5.0.0 - * - * @param void - * @return void */ - function initialize() + public function initialize() { } /** @@ -6808,6 +6820,17 @@ function render_field_settings($field) function render_field_validation_settings($field) { } + /** + * Renders the field settings used in the "Advanced" tab. + * + * @since 6.2 + * + * @param array $field The field settings array. + * @return void + */ + public function render_field_advanced_settings($field) + { + } /** * load_value() * @@ -6844,21 +6867,17 @@ function format_value($value, $post_id, $field) { } /** - * update_value() - * - * This filter is appied to the $value before it is updated in the db + * Filters the field value before it is saved into the database. * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @since 3.6 * - * @param $value - the value which will be saved in the database - * @param $post_id - the $post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param mixed $value The value which will be saved in the database. + * @param int $post_id The post_id of which the value will be saved. + * @param array $field The field array holding all the field options. * - * @return $value - the modified value + * @return mixed $value The modified value. */ - function update_value($value, $post_id, $field) + public function update_value($value, $post_id, $field) { } /** @@ -7179,18 +7198,13 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_relationship extends \acf_field { /** - * __construct - * * This function will setup the field type data * * @type function * @date 5/03/2014 * @since 5.0.0 - * - * @param void - * @return void */ - function initialize() + public function initialize() { } /** @@ -7322,6 +7336,17 @@ function render_field_validation_settings($field) function render_field_presentation_settings($field) { } + /** + * Renders the field settings used in the "Advanced" tab. + * + * @since 6.2 + * + * @param array $field The field settings array. + * @return void + */ + public function render_field_advanced_settings($field) + { + } /** * format_value() * @@ -7356,21 +7381,17 @@ function validate_value($valid, $value, $field, $input) { } /** - * update_value() - * - * This filter is applied to the $value before it is updated in the db + * Filters the field value before it is saved into the database. * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @since 3.6 * - * @param $value - the value which will be saved in the database - * @param $post_id - the post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param mixed $value The value which will be saved in the database. + * @param int $post_id The post_id of which the value will be saved. + * @param array $field The field array holding all the field options. * - * @return $value - the modified value + * @return mixed $value The modified value. */ - function update_value($value, $post_id, $field) + public function update_value($value, $post_id, $field) { } /** @@ -7464,18 +7485,14 @@ function ajax_query() { } /** - * get_ajax_query + * This function will return an array of data formatted for use in a select2 AJAX response * - * This function will return an array of data formatted for use in a select2 AJAX response - * - * @type function - * @date 15/10/2014 - * @since 5.0.9 + * @since 5.0.9 * - * @param array $options - * @return array + * @param array $options An array of options. + * @return array A select2 compatible array of options. */ - function get_ajax_query($options = array()) + public function get_ajax_query($options = array()) { } /** @@ -7629,10 +7646,21 @@ function format_value_single($value, $post_id, $field) public function validate_rest_value($valid, $value, $field) { } + /** + * Formats the choices available for the REST API. + * + * @since 6.2 + * + * @param array $choices The choices for the field. + * @return array + */ + public function format_rest_choices($choices) + { + } /** * Return the schema array for the REST API. * - * @param array $field + * @param array $field The main field array. * @return array */ public function get_rest_schema(array $field) @@ -7756,18 +7784,13 @@ class acf_field_taxonomy extends \acf_field // vars var $save_post_terms = array(); /** - * __construct - * * This function will setup the field type data * * @type function * @date 5/03/2014 * @since 5.0.0 - * - * @param void - * @return void */ - function initialize() + public function initialize() { } /** @@ -7848,21 +7871,17 @@ function load_value($value, $post_id, $field) { } /** - * update_value() - * - * This filter is appied to the $value before it is updated in the db + * Filters the field value before it is saved into the database. * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @since 3.6 * - * @param $value - the value which will be saved in the database - * @param $field - the field array holding all the field options - * @param $post_id - the $post_id of which the value will be saved + * @param mixed $value The value which will be saved in the database. + * @param int $post_id The post_id of which the value will be saved. + * @param array $field The field array holding all the field options. * - * @return $value - the modified value + * @return mixed $value The modified value. */ - function update_value($value, $post_id, $field) + public function update_value($value, $post_id, $field) { } /** @@ -7949,6 +7968,17 @@ public function render_field_checkbox($field) function render_field_settings($field) { } + /** + * Renders the field settings used in the "Advanced" tab. + * + * @since 6.2 + * + * @param array $field The field settings array. + * @return void + */ + public function render_field_advanced_settings($field) + { + } /** * ajax_add_term * @@ -8496,9 +8526,6 @@ class ACF_Field_User extends \ACF_Field * * @date 5/03/2014 * @since 5.0.0 - * - * @param void - * @return void */ function initialize() { @@ -8526,6 +8553,17 @@ function render_field_settings($field) function render_field_validation_settings($field) { } + /** + * Renders the field settings used in the "Advanced" tab. + * + * @since 6.2 + * + * @param array $field The field settings array. + * @return void + */ + public function render_field_advanced_settings($field) + { + } /** * Renders the field input HTML. * @@ -8583,15 +8621,15 @@ function format_value($value, $post_id, $field) /** * Filters the field value before it is saved into the database. * - * @date 23/01/13 * @since 3.6.0 * * @param mixed $value The field value. * @param mixed $post_id The post ID where the value is saved. * @param array $field The field array containing all settings. - * @return mixed + * + * @return mixed $value The modified value. */ - function update_value($value, $post_id, $field) + public function update_value($value, $post_id, $field) { } /** @@ -10182,6 +10220,28 @@ public function __construct() public function is_enabled() { } + /** + * Gets the path(s) to load JSON from. + * + * @since 6.2 + * + * @return array + */ + public function get_load_paths() + { + } + /** + * Gets the path(s) to save JSON to. + * + * @since 6.2 + * + * @param string $key The key to get paths for (optional). + * @param array $post The main ACF post array (optional). + * @return array + */ + public function get_save_paths($key = '', $post = array()) + { + } /** * Writes field group data to JSON file. * @@ -10313,10 +10373,11 @@ public function save_file($key, $post) * @date 17/4/20 * @since 5.9.0 * - * @param string $key The ACF post key. - * @return bool True on success. + * @param string $key The ACF post key. + * @param array $post The main ACF post array. + * @return bool */ - public function delete_file($key) + public function delete_file($key, $post = array()) { } /** @@ -13184,6 +13245,25 @@ class acf_pro function __construct() { } + /** + * Registers the `acf-ui-options-page` post type and initializes the UI. + * + * @since 6.2 + * + * @return void + * @phpstan-return void + */ + public function register_ui_options_pages() + { + } + /** + * Action to include JSON options pages. + * + * @since 6.2 + */ + public function include_options_pages() + { + } /** * Includes any files necessary for field types. * @@ -13209,18 +13289,13 @@ function include_location_rules() { } /** - * register_assets + * Registers styles and scripts used by ACF PRO. * - * description - * - * @type function - * @date 4/11/2013 - * @since 5.0.0 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @return void */ - function register_assets() + public function register_assets() { } /** @@ -13253,6 +13328,18 @@ function input_admin_enqueue_scripts() function field_group_admin_enqueue_scripts() { } + /** + * Filters the $where clause allowing for custom WP_Query args. + * + * @since 6.2 + * + * @param string $where The WHERE clause. + * @param WP_Query $wp_query The query object. + * @return string + */ + public function posts_where($where, $wp_query) + { + } } class acf_admin_options_page { @@ -13476,76 +13563,390 @@ function html() { } } -class acf_field_clone extends \acf_field +/** + * ACF Admin UI Options Page Class + * + * All the logic for editing an options page in the UI. + */ +class ACF_Admin_UI_Options_Page extends \ACF_Admin_Internal_Post_Type { /** - * __construct - * - * This function will setup the field type data + * The slug for the internal post type. * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @since 6.1 + * @var string + */ + public $post_type = 'acf-ui-options-page'; + /** + * The admin body class used for the post type. * - * @param void - * @return void + * @since 6.1 + * @var string */ - function initialize() + public $admin_body_class = 'acf-admin-single-options-page'; + /** + * Constructs the class. + */ + public function __construct() { } /** - * is_enabled - * - * This function will return true if acf_local functionality is enabled + * This function will customize the message shown when editing a post type. * - * @type function - * @date 14/07/2016 - * @since 5.4.0 + * @since 5.0.0 * - * @param void - * @return void + * @param array $messages Post type messages. + * @return array */ - function is_enabled() + public function post_updated_messages($messages) { } /** - * load_field() + * Renders the options page created message. * - * This filter is appied to the $field after it is loaded from the database + * @since 6.1 * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @param bool $created True if the options page was just created. + * @return string + */ + public function options_page_created_message($created = \false) + { + } + /** + * Enqueues any scripts necessary for internal post type. * - * @param $field - the field array holding all the field options + * @since 5.0.0 * - * @return $field - the field array holding all the field options + * @return void */ - function load_field($field) + public function admin_enqueue_scripts() { } /** - * acf_get_fields - * - * This function will hook into the 'acf/get_fields' filter and inject/replace seamless clones fields + * Sets up all functionality for the post type edit page to work. * - * @type function - * @date 17/06/2016 - * @since 5.3.8 + * @since 3.1.8 * - * @param array $fields - * @param array $parent - * @return $fields + * @return void */ - function acf_get_fields($fields, $parent) + public function admin_head() { } /** - * get_cloned_fields - * - * This function will return an array of fields for a given clone field + * This action will allow ACF to render metaboxes after the title. * - * @type function + * @return void + */ + public function edit_form_after_title() + { + } + /** + * This function will add extra HTML to the acf form data element + * + * @since 5.3.8 + * + * @param array $args Arguments array to pass through to action. + * @return void + */ + public function form_data($args) + { + } + /** + * This function will append extra l10n strings to the acf JS object + * + * @since 5.3.8 + * + * @param array $l10n The array of translated strings. + * @return array $l10n + */ + public function admin_l10n($l10n) + { + } + /** + * Admin footer third party hook support + * + * @since 5.3.2 + * + * @return void + */ + public function admin_footer() + { + } + /** + * Screen settings html output + * + * @since 3.6.0 + * + * @param string $html Current screen settings HTML. + * @return string $html + */ + public function screen_settings($html) + { + } + /** + * Sets the "Edit Post Type" screen to use a one-column layout. + * + * @param int $columns Number of columns for layout. + * + * @return int + */ + public function screen_layout($columns = 0) + { + } + /** + * Force basic settings to always be visible + * + * @param array $hidden_metaboxes The metaboxes hidden on this page. + * + * @return array + */ + public function force_basic_settings($hidden_metaboxes) + { + } + /** + * Force advanced settings to be visible + * + * @param array $hidden_metaboxes The metaboxes hidden on this page. + * + * @return array + */ + public function force_advanced_settings($hidden_metaboxes) + { + } + /** + * This function will customize the publish metabox + * + * @since 5.2.9 + * + * @return void + */ + public function post_submitbox_misc_actions() + { + } + /** + * Saves post type data. + * + * @since 1.0.0 + * + * @param int $post_id The post ID. + * @param WP_Post $post The post object. + * + * @return int $post_id + */ + public function save_post($post_id, $post) + { + } + /** + * Renders HTML for the basic settings metabox. + * + * @since 5.0.0 + * + * @return void + */ + public function mb_basic_settings() + { + } + /** + * Renders the HTML for the advanced settings metabox. + * + * @since 5.0.0 + * + * @return void + */ + public function mb_advanced_settings() + { + } + /** + * Iterates through the registered options pages and finds eligible parent pages. + * + * @since 6.2 + * + * @param string $menu_slug Optional menu_slug of an existing options page. + * @return array + */ + public static function get_parent_page_choices($menu_slug = '') + { + } + /** + * Creates a simple options page over AJAX. + * + * @since 6.2 + * @return void + * @phpstan-return never + */ + public function ajax_create_options_page() + { + } +} +/** + * The ACF Post Types admin controller class + */ +#[\AllowDynamicProperties] +class ACF_Admin_UI_Options_Pages extends \ACF_Admin_Internal_Post_Type_List +{ + /** + * The slug for the internal post type. + * + * @since 6.1 + * @var string + */ + public $post_type = 'acf-ui-options-page'; + /** + * The admin body class used for the post type. + * + * @since 6.1 + * @var string + */ + public $admin_body_class = 'acf-admin-options-pages'; + /** + * The name of the store used for the post type. + * + * @var string + */ + public $store = 'options-pages'; + /** + * If this is a pro feature or not. + * + * @var bool + */ + public $is_pro_feature = \true; + /** + * Constructor. + * + * @since 6.2 + * + * @return void + */ + public function __construct() + { + } + /** + * Current screen actions for the post types list admin page. + * + * @since 6.1 + * + * @return void + * @phpstan-return void + */ + public function current_screen() + { + } + /** + * Add any menu items required for post types. + * + * @since 6.1 + */ + public function admin_menu() + { + } + /** + * Customizes the admin table columns. + * + * @date 1/4/20 + * @since 5.9.0 + * + * @param array $_columns The columns array. + * @return array + */ + public function admin_table_columns($_columns) + { + } + /** + * Renders a specific admin table column. + * + * @date 17/4/20 + * @since 5.9.0 + * + * @param string $column_name The name of the column to display. + * @param array $post The main ACF post array. + * @return void + */ + public function render_admin_table_column($column_name, $post) + { + } + /** + * Gets the translated action notice text for list table actions (activate, deactivate, sync, etc.). + * + * @since 6.1 + * + * @param string $action The action being performed. + * @param int $count The number of items the action was performed on. + * @return string + */ + public function get_action_notice_text($action, $count = 1) + { + } +} +class acf_field_clone extends \acf_field +{ + /** + * __construct + * + * This function will setup the field type data + * + * @type function + * @date 5/03/2014 + * @since 5.0.0 + * + * @param void + * @return void + */ + function initialize() + { + } + /** + * is_enabled + * + * This function will return true if acf_local functionality is enabled + * + * @type function + * @date 14/07/2016 + * @since 5.4.0 + * + * @param void + * @return void + */ + function is_enabled() + { + } + /** + * load_field() + * + * This filter is appied to the $field after it is loaded from the database + * + * @type filter + * @since 3.6 + * @date 23/01/13 + * + * @param $field - the field array holding all the field options + * + * @return $field - the field array holding all the field options + */ + function load_field($field) + { + } + /** + * acf_get_fields + * + * This function will hook into the 'acf/get_fields' filter and inject/replace seamless clones fields + * + * @type function + * @date 17/06/2016 + * @since 5.3.8 + * + * @param array $fields + * @param array $parent + * @return $fields + */ + function acf_get_fields($fields, $parent) + { + } + /** + * get_cloned_fields + * + * This function will return an array of fields for a given clone field + * + * @type function * @date 28/06/2016 * @since 5.3.8 * @@ -15123,41 +15524,188 @@ function add_sub_page($page) * @date 9/6/17 * @since 5.6.0 * - * @param string $slug - * @param array $data - * @return array + * @param string $slug + * @param array $data + * @return array + */ + function update_page($slug = '', $data = array()) + { + } + /** + * get_page + * + * This function will return an options page settings + * + * @type function + * @date 6/07/2016 + * @since 5.4.0 + * + * @param string $slug + * @return mixed + */ + function get_page($slug) + { + } + /** + * get_pages + * + * This function will return all options page settings + * + * @type function + * @date 6/07/2016 + * @since 5.4.0 + * + * @param string $slug + * @return mixed + */ + function get_pages() + { + } +} +class ACF_UI_Options_Page extends \ACF_Internal_Post_Type +{ + /** + * The ACF internal post type name. + * + * @var string + */ + public $post_type = 'acf-ui-options-page'; + /** + * The prefix for the key used in the main post array. + * + * @var string + */ + public $post_key_prefix = 'ui_options_page_'; + /** + * The cache key for a singular post. + * + * @var string + */ + public $cache_key = 'acf_get_ui_options_page_post:key:'; + /** + * The cache key for a collection of posts. + * + * @var string + */ + public $cache_key_plural = 'acf_get_ui_options_page_posts'; + /** + * The hook name for a singular post. + * + * @var string + */ + public $hook_name = 'ui_options_page'; + /** + * The hook name for a collection of posts. + * + * @var string + */ + public $hook_name_plural = 'ui_options_pages'; + /** + * The name of the store used for the post type. + * + * @var string + */ + public $store = 'ui-options-pages'; + /** + * Constructs the class and any parent classes. + * + * @since 5.0.0 + */ + public function __construct() + { + } + /** + * Registers the acf-ui-options-page custom post type with WordPress. + * + * @since 6.2 + */ + public function register_post_type() + { + } + /** + * Register activated options pages. + * + * @since 6.2 + */ + public function register_ui_options_pages() + { + } + /** + * Gets the default settings array for an ACF options page. + * + * @return array + */ + public function get_settings_array() + { + } + /** + * Validates options page values before allowing save from the global $_POST object. + * Errors are added to the form using acf_add_internal_post_type_validation_error(). + * + * @since 6.2 + * + * @return bool validity status + */ + public function ajax_validate_values() + { + } + /** + * Updates the settings for ACF UI options pages. + * + * @since 6.2 + * + * @param array $post The ACF post to update. + * @return array + */ + public function update_post($post) + { + } + /** + * Sets up the local JSON functionality for options pages. + * + * @since 6.2 + * + * @param ACF_Local_JSON $local_json The ACF_Local_JSON object. + * @return void + */ + public function setup_local_json() + { + } + /** + * Includes all local JSON options pages. + * + * @since 6.1 + * + * @return void + * @phpstan-return void */ - function update_page($slug = '', $data = array()) + public function include_json_options_pages() { } /** - * get_page - * - * This function will return an options page settings + * Returns a string that can be used to create an options page with PHP. * - * @type function - * @date 6/07/2016 - * @since 5.4.0 + * @since 6.2 * - * @param string $slug - * @return mixed + * @param array $post The main options page array. + * @return string */ - function get_page($slug) + public function export_post_as_php($post = array()) { } /** - * get_pages + * Parses ACF options page settings and returns an array of args + * to be handled by `acf_add_options_page()`. * - * This function will return all options page settings + * Omits settings that line up with the defaults to reduce the size + * of the array passed to `acf_add_options_page()`, which might be exported. * - * @type function - * @date 6/07/2016 - * @since 5.4.0 + * @since 6.2 * - * @param string $slug - * @return mixed + * @param array $post The main ACF options page settings array. + * @return array */ - function get_pages() + public function get_options_page_args($post) { } } @@ -15220,6 +15768,81 @@ function modify_plugin_update_message($plugin_data, $response) function acf() { } +/** + * General functions relating to the bidirectional feature of some fields. + * + * @package ACF + */ +/** + * Process updating bidirectional fields. + * + * @since 6.2 + * + * @param array $target_item_ids The post, user or term IDs which should be updated with the origin item ID. + * @param int|string $post_id The ACF encoded origin post, user or term ID. + * @param array $field The field being updated on the origin post, user or term ID. + * @param string|false $target_prefix The ACF prefix for a post, user or term ID required for the update_field call for this field type. + */ +function acf_update_bidirectional_values($target_item_ids, $post_id, $field, $target_prefix = \false) +{ +} +/** + * Allows third party fields to enable support as a target field type for a particular object type + * + * @since 6.2 + * + * @param string $object_type The object type that will be updated on the target field, such as 'term', 'user' or 'post'. + * @return array An array of valid field type names (slugs) for the target of the bidirectional field. + */ +function acf_get_valid_bidirectional_target_types($object_type) +{ +} +/** + * Build the complete choices argument for rendering the select2 field for bidirectional target based on the currently selected choices + * + * @since 6.2 + * + * @param array $choices The currently selected choices (as an array of field keys). + * + * @return array + */ +function acf_build_bidirectional_target_current_choices($choices) +{ +} +/** + * Build valid fields for a bidirectional relationship for select2 display + * + * @since 6.2 + * + * @param array $results The original results array. + * @param array $options The options provided to the select2 AJAX search. + * + * @return array + */ +function acf_build_bidirectional_relationship_field_target_args($results, $options) +{ +} +/** + * Renders the field settings required for bidirectional fields + * + * @since 6.2 + * + * @param array $field The field object passed into field setting functions. + * @phpstan-return void + */ +function acf_render_bidirectional_field_settings($field) +{ +} +/** + * Returns the translated instructional text for the message field for the bidirectional field settings. + * + * @since 6.2 + * + * @return string The html containing the instructional message. + */ +function acf_get_bidirectional_field_settings_instruction_text() +{ +} /** * acf_get_field * @@ -16631,6 +17254,16 @@ function acf_sanitize_files_value_array($array, $sanitize_function) function acf_maybe_unserialize($data) { } +/** + * Check if current install is ACF PRO + * + * @since 6.2 + * + * @return boolean True if the current install is ACF PRO + */ +function acf_is_pro() +{ +} /** * acf_add_filter_variations * @@ -17380,6 +18013,16 @@ function acf_get_combined_post_type_settings_tabs() function acf_get_combined_taxonomy_settings_tabs() { } +/** + * Returns an array of tabs for the options page advanced settings + * + * @since 6.2 + * + * @return array + */ +function acf_get_combined_options_page_settings_tabs() +{ +} /** * Converts an _acf_screen or hook value into a post type. * @@ -17407,11 +18050,12 @@ function acf_validate_internal_post_type_values($post_type) * * @since 6.1 * - * @param string $name The name of the input. - * @param string $message An optional error message to display. + * @param string $name The name of the input. + * @param string $message An optional error message to display. + * @param string $post_type Optional post type the error message is for. * @return void */ -function acf_add_internal_post_type_validation_error($name, $message = '') +function acf_add_internal_post_type_validation_error($name, $message = '', $post_type = '') { } /** @@ -17436,6 +18080,17 @@ function acf_get_post_type_from_request_args($action = '') function acf_get_taxonomy_from_request_args($action = '') { } +/** + * Gets an ACF options page from request args and verifies nonce based on action. + * + * @since 6.2 + * + * @param string $action The action being performed. + * @return array|bool + */ +function acf_get_ui_options_page_from_request_args($action = '') +{ +} /** * Returns an array of "ACF only" meta for the given post_id. * @@ -18530,6 +19185,20 @@ function acf_get_admin_tools_url() function acf_get_admin_tool_url($tool = '') { } +/** + * Helper function for looping over the provided menu items + * and echoing out the necessary markup. + * + * @since 6.2 + * + * @param array $menu_items An array of menu items to print. + * @param string $section The section being printed. + * @return void + * @phpstan-return void + */ +function acf_print_menu_section($menu_items, $section = '') +{ +} /** * acf_is_array * @@ -22456,6 +23125,255 @@ function acf_validate_values($values, $input_prefix = '') function acf_validate_value($value, $field, $input) { } +/** + * Helper/wrapper Functions for ACF UI Options pages. + * + * @package ACF + */ +/** + * Get an ACF UI options page as an array + * + * @since 6.2 + * + * @param int|string $id The post ID being queried. + * @return array|false The UI options page array. + */ +function acf_get_ui_options_page($id) +{ +} +/** + * Retrieves a raw ACF UI options page. + * + * @since 6.2 + * + * @param int|string $id The post ID. + * @return array|false The UI options page array. + */ +function acf_get_raw_ui_options_page($id) +{ +} +/** + * Gets a post object for an ACF UI options page. + * + * @since 6.2 + * + * @param int|string $id The post ID, key, or name. + * @return object|bool The post object, or false on failure. + */ +function acf_get_ui_options_page_post($id) +{ +} +/** + * Returns true if the given identifier is an ACF UI options page key. + * + * @since 6.2 + * + * @param string $id The identifier. + * @return bool + */ +function acf_is_ui_options_page_key($id) +{ +} +/** + * Validates an ACF UI options page. + * + * @since 6.2 + * + * @param array $ui_options_page The ACF UI options page array to validate. + * @return array|bool + */ +function acf_validate_ui_options_page(array $ui_options_page = array()) +{ +} +/** + * Translates the settings for an ACF UI options page. + * + * @since 6.2 + * + * @param array $ui_options_page The ACF UI options page array. + * @return array + */ +function acf_translate_ui_options_page(array $ui_options_page) +{ +} +/** + * Returns and array of ACF UI options pages for the given $filter. + * + * @since 6.2 + * + * @param array $filter An array of args to filter results by. + * @return array + */ +function acf_get_ui_options_pages(array $filter = array()) +{ +} +/** + * Returns an array of raw ACF UI options pages. + * + * @since 6.2 + * + * @return array + */ +function acf_get_raw_ui_options_pages() +{ +} +/** + * Returns a filtered array of ACF UI options pages based on the given $args. + * + * @since 6.2 + * + * @param array $ui_options_pages An array of ACF UI options pages. + * @param array $args An array of args to filter by. + * @return array + */ +function acf_filter_ui_options_pages(array $ui_options_pages, array $args = array()) +{ +} +/** + * Updates an ACF UI options page in the database. + * + * @since 6.2 + * + * @param array $ui_options_page The main ACF UI options page array. + * @return array + */ +function acf_update_ui_options_page(array $ui_options_page) +{ +} +/** + * Deletes all caches for the provided ACF UI options page. + * + * @since 6.2 + * + * @param array $ui_options_page The ACF UI options page array. + * @return void + */ +function acf_flush_ui_options_page_cache(array $ui_options_page) +{ +} +/** + * Deletes an ACF UI options page from the database. + * + * @since 6.2 + * + * @param int|string $id The ACF UI options page ID, key or name. + * @return bool True if the options page was deleted. + */ +function acf_delete_ui_options_page($id = 0) +{ +} +/** + * Trashes an ACF UI options page. + * + * @since 6.2 + * + * @param int|string $id The UI options page ID, key, or name. + * @return bool True if the options page was trashed. + */ +function acf_trash_ui_options_page($id = 0) +{ +} +/** + * Restores an ACF UI options page from the trash. + * + * @since 6.2 + * + * @param int|string $id The UI options page ID, key, or name. + * @return bool True if the options page was untrashed. + */ +function acf_untrash_ui_options_page($id = 0) +{ +} +/** + * Returns true if the given params match an ACF UI options page. + * + * @since 6.2 + * + * @param array $ui_options_page The ACF UI options page array. + * @return bool + */ +function acf_is_ui_options_page($ui_options_page) +{ +} +/** + * Duplicates an ACF UI options page. + * + * @since 6.2 + * + * @param int|string $id The ACF UI options page ID, key or name. + * @param int $new_post_id Optional ID to override. + * @return array|bool The new ACF UI options page, or false on failure. + */ +function acf_duplicate_ui_options_page($id = 0, $new_post_id = 0) +{ +} +/** + * Activates or deactivates an ACF UI options page. + * + * @since 6.2 + * + * @param int|string $id The ACF UI options page ID, key or name. + * @param bool $activate True if the UI options page should be activated. + * @return bool + */ +function acf_update_ui_options_page_active_status($id, $activate = \true) +{ +} +/** + * Checks if the current user can edit the UI options page and returns the edit URL. + * + * @since 6.2 + * + * @param int $post_id The ACF UI options page ID. + * @return string + */ +function acf_get_ui_options_page_edit_link($post_id) +{ +} +/** + * Returns a modified ACF UI options page ready for export. + * + * @since 6.2 + * + * @param array $ui_options_page The ACF UI options page array. + * @return array + */ +function acf_prepare_ui_options_page_for_export(array $ui_options_page = array()) +{ +} +/** + * Exports an ACF UI options page as PHP. + * + * @since 6.2 + * + * @param array $ui_options_page The ACF UI options page array. + * @return string|bool + */ +function acf_export_ui_options_page_as_php(array $ui_options_page) +{ +} +/** + * Prepares an ACF UI options page for the import process. + * + * @since 6.2 + * + * @param array $ui_options_page The ACF UI options page array. + * @return array + */ +function acf_prepare_ui_options_page_for_import(array $ui_options_page = array()) +{ +} +/** + * Imports an ACF UI options page into the database. + * + * @since 6.2 + * + * @param array $ui_options_page The ACF UI options page array. + * @return array The imported options page. + */ +function acf_import_ui_options_page(array $ui_options_page) +{ +} /** * Prefix block names for ACF blocks registered through block.json * From c721683ad7de272a57dffb793d93d7272a97ae58 Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Sun, 4 Feb 2024 15:49:11 +0200 Subject: [PATCH 03/11] Generate stubs for ACF PRO 6.2.1 --- acf-pro-stubs.php | 96 ++++++++++++++++++++++------------------------- 1 file changed, 45 insertions(+), 51 deletions(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index 13ddd6a..0139e5c 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.2.0'; + public $version = '6.2.1'; /** * The plugin settings array. * @@ -12133,6 +12133,18 @@ public function register_post_type() public function register_post_types() { } + /** + * Filters the "Add title" text for ACF post types. + * + * @since 6.2.1 + * + * @param string $default The default text. + * @param WP_Post $post The WP_Post object. + * @return string + */ + public function enter_title_here($default, $post) + { + } /** * Gets the default settings array for an ACF post type. * @@ -12784,18 +12796,27 @@ public function get_plugin_info($id = '', $force_check = \false) { } /** - * get_plugin_update + * Returns specific data from the 'update-check' response. * - * Returns specific data from the 'update-check' response. + * @since 5.7.2 * - * @date 3/8/18 - * @since 5.7.2 + * @param string $basename The plugin basename. + * @param boolean $force_check Bypasses cached result. Defaults to false. + * @return array|false + */ + public function get_plugin_update($basename = '', $force_check = \false) + { + } + /** + * Checks if an update is available, but can't be updated to. * - * @param string $basename The plugin basename. - * @param boolean $force_check Bypasses cached result. Defaults to false - * @return array + * @since 6.2.1 + * + * @param string $basename The plugin basename. + * @param boolean $force_check Bypasses cached result. Defaults to false. + * @return array|false */ - function get_plugin_update($basename = '', $force_check = \false) + public function get_no_update($basename = '', $force_check = \false) { } /** @@ -12841,17 +12862,14 @@ function refresh_plugins_transient() { } /** - * modify_plugins_transient - * * Called when WP updates the 'update_plugins' site transient. Used to inject ACF plugin update info. * - * @date 16/01/2014 * @since 5.0.0 * - * @param object $transient - * @return $transient + * @param object $transient The current transient value. + * @return object $transient The modified transient value. */ - function modify_plugins_transient($transient) + public function modify_plugins_transient($transient) { } /** @@ -12977,41 +12995,6 @@ public function acf_validate_save_post() { } } -class ACF_Walker_Nav_Menu_Edit extends \Walker_Nav_Menu_Edit -{ - /** - * Starts the element output. - * - * Calls the Walker_Nav_Menu_Edit start_el function and then injects the custom field HTML - * - * @since 5.0.0 - * @since 5.7.2 Added preg_replace based on https://github.com/ineagu/wp-menu-item-custom-fields - * - * @param string $output Used to append additional content (passed by reference). - * @param WP_Post $item Menu item data object. - * @param int $depth Depth of menu item. Used for padding. - * @param stdClass $args An object of wp_nav_menu() arguments. - * @param int $id Current item ID. - */ - function start_el(&$output, $item, $depth = 0, $args = array(), $id = 0) - { - } - /** - * Get custom fields HTML - * - * @since 5.0.0 - * @since 5.7.2 Added action based on https://github.com/ineagu/wp-menu-item-custom-fields - * - * @param object $item Menu item data object. - * @param int $depth Depth of menu item. Used for padding. - * @param array $args Menu item args. - * @param int $id Nav menu ID. - * @return string - */ - function get_fields($item, $depth, $args = array(), $id = 0) - { - } -} class ACF_Taxonomy_Field_Walker extends \Walker { /** @@ -13764,7 +13747,7 @@ public function mb_advanced_settings() * @param string $menu_slug Optional menu_slug of an existing options page. * @return array */ - public static function get_parent_page_choices($menu_slug = '') + public static function get_parent_page_choices($current_slug = '') { } /** @@ -18500,6 +18483,17 @@ function acf_prepare_post_type_for_import(array $post_type = array()) function acf_import_post_type(array $post_type) { } +/** + * Exports the "Enter Title Here" text for the provided ACF post types. + * + * @since 6.2.1 + * + * @param array $post_types The post types being exported. + * @return string + */ +function acf_export_enter_title_here(array $post_types) +{ +} /** * Functions for ACF taxonomy objects. * From 29ae4bbadfa3629e92f4596317638e020462c922 Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Sun, 4 Feb 2024 15:49:14 +0200 Subject: [PATCH 04/11] Generate stubs for ACF PRO 6.2.1.1 --- acf-pro-stubs.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index 0139e5c..b59ae2f 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.2.1'; + public $version = '6.2.1.1'; /** * The plugin settings array. * From c2b137920b7dd1dda950e3794cfa3fd3cbb9d04b Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Sun, 4 Feb 2024 15:49:17 +0200 Subject: [PATCH 05/11] Generate stubs for ACF PRO 6.2.2 --- acf-pro-stubs.php | 403 +++++++++++++++++++++++++++++----------------- 1 file changed, 256 insertions(+), 147 deletions(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index b59ae2f..3aeef84 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.2.1.1'; + public $version = '6.2.2'; /** * The plugin settings array. * @@ -1043,6 +1043,53 @@ function render() { } } +class ACF_Admin_Options_Preview +{ + /** + * Constructor. + * + * @since 6.2.2 + */ + public function __construct() + { + } + /** + * Adds the Options Pages menu item to the admin menu. + * + * @since 6.2.2 + * @phpstan-return void + */ + public function admin_menu() + { + } + /** + * Load the body class and scripts. + * + * @since 6.2.2 + */ + public function load() + { + } + /** + * Modifies the admin body class. + * + * @since 6.2.2 + * + * @param string $classes Space-separated list of CSS classes. + * @return string + */ + public function admin_body_class($classes) + { + } + /** + * The render for the options page preview view. + * + * @since 6.2.2 + */ + public function render() + { + } +} #[\AllowDynamicProperties] class acf_admin_tools { @@ -12184,10 +12231,11 @@ public function ajax_validate_values() * * @since 6.1 * - * @param array $post The main ACF post type settings array. + * @param array $post The main ACF post type settings array. + * @param boolean $escape_labels Determines if the label values should be escaped. * @return array */ - public function get_post_type_args($post) + public function get_post_type_args($post, $escape_labels = \true) { } /** @@ -12329,10 +12377,11 @@ public function ajax_validate_values() * * @since 6.1 * - * @param array $post The main ACF taxonomy settings array. + * @param array $post The main ACF taxonomy settings array. + * @param boolean $escape_labels Determines if the label values should be escaped. * @return array */ - public function get_taxonomy_args($post) + public function get_taxonomy_args($post, $escape_labels = \true) { } /** @@ -13311,6 +13360,16 @@ function input_admin_enqueue_scripts() function field_group_admin_enqueue_scripts() { } + /** + * Checks for a license status error and renders it if necessary. + * + * @since 6.2.1 + * + * @return void + */ + public function maybe_show_license_status_error() + { + } /** * Filters the $where clause allowing for custom WP_Query args. * @@ -15695,45 +15754,36 @@ public function get_options_page_args($post) class acf_pro_updates { /** - * __construct + * Initialize filters, action, variables and includes * - * Initialize filters, action, variables and includes - * - * @type function - * @date 23/06/12 - * @since 5.0.0 + * @date 23/06/12 + * @since 5.0.0 */ - function __construct() + public function __construct() { } /** - * init + * Initializes the ACF PRO updates functionality. * - * description - * - * @type function * @date 10/4/17 * @since 5.5.10 * @phpstan-return void */ - function init() + public function init() { } /** - * modify_plugin_update_message - * - * Displays an update message for plugin list screens. + * Displays an update message for plugin list screens. * - * @type function - * @date 14/06/2016 - * @since 5.3.8 + * @date 14/06/2016 + * @since 5.3.8 * - * @param string $message - * @param array $plugin_data - * @param object $r - * @return $message + * @param array $plugin_data An array of plugin metadata. + * @param object $response An object of metadata about the available plugin update. + * @return void + * @phpstan-return void */ - function modify_plugin_update_message($plugin_data, $response) + public function modify_plugin_update_message($plugin_data, $response) { } } @@ -19194,30 +19244,23 @@ function acf_print_menu_section($menu_items, $section = '') { } /** -* acf_is_array -* -* This function will return true for a non empty array -* -* @type function -* @date 6/07/2016 -* @since 5.4.0 -* -* @param array $array -* @return boolean -*/ + * This function will return true for a non empty array + * + * @since 5.4.0 + * + * @param mixed $array The variable to test. + * @return boolean + */ function acf_is_array($array) { } /** - * acf_has_setting - * - * alias of acf()->has_setting() + * Alias of acf()->has_setting() * - * @date 2/2/18 * @since 5.6.5 * - * @param void - * @return void + * @param string $name Name of the setting to check for. + * @return boolean */ function acf_has_setting($name = '') { @@ -19267,17 +19310,14 @@ function acf_validate_setting($name = '') { } /** -* acf_get_setting -* -* alias of acf()->get_setting() -* -* @type function -* @date 28/09/13 -* @since 5.0.0 -* -* @param void -* @return void -*/ + * Alias of acf()->get_setting() + * + * @since 5.0.0 + * + * @param string $name The name of the setting to test. + * @param string $value An optional default value for the setting if it doesn't exist. + * @return void + */ function acf_get_setting($name, $value = \null) { } @@ -19338,27 +19378,20 @@ function acf_set_data($name, $value) /** * Appends data to an existing key. * - * @date 11/06/2020 * @since 5.9.0 * - * @param string $name The data name. - * @return array $data The data array. + * @param string $name The data name. + * @param mixed $data The data to append to name. + * @return void */ function acf_append_data($name, $data) { } /** -* acf_init -* -* alias of acf()->init() -* -* @type function -* @date 28/09/13 -* @since 5.0.0 -* -* @param void -* @return void -*/ + * Alias of acf()->init() - the core ACF init function. + * + * @since 5.0.0 + */ function acf_init() { } @@ -19378,65 +19411,51 @@ function acf_has_done($name) { } /** -* acf_get_external_path -* -* This function will return the path to a file within an external folder -* -* @type function -* @date 22/2/17 -* @since 5.5.8 -* -* @param string $file -* @param string $path -* @return string -*/ + * This function will return the path to a file within an external folder + * + * @since 5.5.8 + * + * @param string $file Directory path. + * @param string $path Optional file path. + * @return string File path. + */ function acf_get_external_path($file, $path = '') { } /** -* acf_get_external_dir -* -* This function will return the url to a file within an external folder -* -* @type function -* @date 22/2/17 -* @since 5.5.8 -* -* @param string $file -* @param string $path -* @return string -*/ + * This function will return the url to a file within an internal ACF folder + * + * @since 5.5.8 + * + * @param string $file Directory path. + * @param string $path Optional file path. + * @return string File path. + */ function acf_get_external_dir($file, $path = '') { } /** - * acf_plugin_dir_url - * * This function will calculate the url to a plugin folder. * Different to the WP plugin_dir_url(), this function can calculate for urls outside of the plugins folder (theme include). * * @date 13/12/17 * @since 5.6.8 * - * @param type $var Description. Default. - * @return type Description. + * @param string $file A file path inside the ACF plugin to get the plugin directory path from. + * @return string The plugin directory path. */ function acf_plugin_dir_url($file) { } /** -* acf_parse_args -* -* This function will merge together 2 arrays and also convert any numeric values to ints -* -* @type function -* @date 18/10/13 -* @since 5.0.0 -* -* @param array $args -* @param array $defaults -* @return array $args -*/ + * This function will merge together 2 arrays and also convert any numeric values to ints + * + * @since 5.0.0 + * + * @param array $args The configured arguments array. + * @param array $defaults The default properties for the passed args to inherit. + * @return array $args Parsed arguments with defaults applied. + */ function acf_parse_args($args, $defaults = array()) { } @@ -19500,49 +19519,39 @@ function acf_merge_atts($atts, $extra = array()) { } /** -* acf_nonce_input -* -* This function will create a basic nonce input -* -* @type function -* @date 24/5/17 -* @since 5.6.0 -* -* @param int $post_id -* @return int $post_id -*/ + * This function will create and echo a basic nonce input + * + * @since 5.6.0 + * + * @param string $nonce The nonce parameter string. + * @return void + */ function acf_nonce_input($nonce = '') { } /** -* acf_extract_var -* -* This function will remove the var from the array, and return the var -* -* @type function -* @date 2/10/13 -* @since 5.0.0 -* -* @param array $array -* @param string $key -* @return mixed -*/ -function acf_extract_var(&$array, $key, $default = \null) + * This function will remove the var from the array, and return the var + * + * @since 5.0.0 + * + * @param array $extract_array an array passed as reference to be extracted. + * @param string $key The key to extract from the array. + * @param mixed $default_value The default value if it doesn't exist in the extract array. + * @return mixed Extracted var or default. + */ +function acf_extract_var(&$extract_array, $key, $default_value = \null) { } /** -* acf_extract_vars -* -* This function will remove the vars from the array, and return the vars -* -* @type function -* @date 8/10/13 -* @since 5.0.0 -* -* @param int $post_id -* @return int $post_id -*/ -function acf_extract_vars(&$array, $keys) + * This function will remove the vars from the array, and return the vars + * + * @since 5.0.0 + * + * @param array $extract_array an array passed as reference to be extracted. + * @param array $keys An array of keys to extract from the original array. + * @return array An array of extracted values. + */ +function acf_extract_vars(&$extract_array, $keys) { } /** @@ -20932,7 +20941,7 @@ function get_field_object($selector, $post_id = \false, $format_value = \true, $ * @date 4/08/2015 * @since 5.2.3 * -* @param mixed $selector identifyer of field. Can be an ID, key, name or post object +* @param mixed $selector identifier of field. Can be an ID, key, name or post object * @param mixed $post_id the post_id of which the value is saved against * @param boolean $strict if true, return a field only when a field key is found. * @return array $field @@ -23368,6 +23377,30 @@ function acf_prepare_ui_options_page_for_import(array $ui_options_page = array() function acf_import_ui_options_page(array $ui_options_page) { } +/** + * Renders the license status table. + * + * @since 6.? + * + * @param array $status The current license status array. + * @return void + * @phpstan-return void + */ +function acf_pro_render_license_status_table($status) +{ +} +/** + * Renders the "Manage License"/"Renew Subscription" button. + * + * @since 6.? + * + * @param array $status The current license status. + * @return void + * @phpstan-return void + */ +function acf_pro_render_manage_license_button($status) +{ +} /** * Prefix block names for ACF blocks registered through block.json * @@ -23920,4 +23953,80 @@ function acf_pro_deactivate_license($silent = \false) */ function display_wp_activation_error($wp_error) { +} +/** + * Returns the status of the current ACF PRO license. + * + * @since 6.2.2 + * + * @param bool $force_check If we should force a call to the API. + * @return array + */ +function acf_pro_get_license_status($force_check = \false) +{ +} +/** + * Makes sure the ACF PRO license status is in a format we expect. + * + * @since 6.2.2 + * + * @param array $status The license status. + * @return array + */ +function acf_pro_parse_license_status($status = array()) +{ +} +/** + * Updates the ACF PRO license status. + * + * @since 6.2.2 + * + * @param array $status The current license status. + * @return bool True if the value was set, false otherwise. + */ +function acf_pro_update_license_status($status) +{ +} +/** + * Removes the ACF PRO license status. + * + * @since 6.2 + * + * @return bool True if the transient was deleted, false otherwise. + */ +function acf_pro_remove_license_status() +{ +} +/** + * Checks if the current license is active. + * + * @since 6.2.2 + * + * @param array $status Optional license status array. + * @return bool True if active, false if not. + */ +function acf_pro_is_license_active($status = array()) +{ +} +/** + * Checks if the current license is expired. + * + * @since 6.2.2 + * + * @param array $status Optional license status array. + * @return bool True if expired, false if not. + */ +function acf_pro_is_license_expired($status = array()) +{ +} +/** + * Checks if the current license was refunded. + * + * @since 6.2.2 + * + * @param array $status Optional license status array. + * @return bool True if refunded, false if not. + */ +function acf_pro_was_license_refunded($status = array()) +{ } \ No newline at end of file From 3965fc682473f11aae1ff6a8344a94cafdac045f Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Sun, 4 Feb 2024 15:49:21 +0200 Subject: [PATCH 06/11] Generate stubs for ACF PRO 6.2.3 --- acf-pro-stubs.php | 120 ++++++++++++++++++++++++++++++++-------------- 1 file changed, 85 insertions(+), 35 deletions(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index 3aeef84..b42db22 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.2.2'; + public $version = '6.2.3'; /** * The plugin settings array. * @@ -1236,17 +1236,16 @@ function html() { } /** - * meta_box_html + * Output the metabox HTML for specific tools * - * description + * @since 5.6.3 * - * @date 10/10/17 - * @since 5.6.3 + * @param mixed $post The post this metabox is being displayed on, should be an empty string always for us on a tools page. + * @param array $metabox An array of the metabox attributes. * - * @param void - * @return void + * @return void */ - function metabox_html($post, $metabox) + public function metabox_html($post, $metabox) { } } @@ -13366,6 +13365,7 @@ function field_group_admin_enqueue_scripts() * @since 6.2.1 * * @return void + * @phpstan-return void */ public function maybe_show_license_status_error() { @@ -20247,6 +20247,16 @@ function acf_update_nested_array(&$array, $ancestors, $value) function acf_is_screen($id = '') { } +/** + * Check if we're in an ACF admin screen + * + * @since 6.2.2 + * + * @return boolean Returns true if the current screen is an ACF admin screen. + */ +function acf_is_acf_admin_screen() +{ +} /** * acf_maybe_get * @@ -20521,17 +20531,14 @@ function acf_is_ajax($action = '') { } /** -* acf_format_date -* -* This function will accept a date value and return it in a formatted string -* -* @type function -* @date 16/06/2016 -* @since 5.3.8 -* -* @param string $value -* @return string $format -*/ + * Returns a date value in a formatted string. + * + * @since 5.3.8 + * + * @param string $value The date value to format. + * @param string $format The format to use. + * @return string + */ function acf_format_date($value, $format) { } @@ -23811,6 +23818,17 @@ function register_options_page($page = '') function acf_pro_check_defined_license() { } +/** + * Get translated upstream message + * + * @since 6.2.3 + * @param string $text server side message string. + * + * @return string a translated (or original, if unavailable), message string. + */ +function acf_pro_get_translated_connect_message($text) +{ +} /** * Set the automatic activation failure transient * @@ -23843,7 +23861,7 @@ function acf_pro_get_activation_failure_transient() * @since 5.11.0 * @phpstan-return void */ -function acf_pro_display_activation_error() +function acf_pro_display_activation_error($screen) { } /** @@ -23859,11 +23877,11 @@ function acf_pro_get_license() { } /** - * An ACF specific getter to replace `home_url` in our licence checks to ensure we can avoid third party filters. + * An ACF specific getter to replace `home_url` in our license checks to ensure we can avoid third party filters. * * @since 6.0.1 * - * @return string $home_url The output from home_url, sans known third party filters which cause licence activation issues. + * @return string $home_url The output from home_url, sans known third party filters which cause license activation issues. */ function acf_get_home_url() { @@ -23873,23 +23891,21 @@ function acf_get_home_url() * * @since 6.0.1 * - * @param string $home_url the WPML converted home URL. + * @param string $home_url the multilingual plugin converted home URL. * @param string $url the original home URL. * * @return string $url */ -function acf_licence_wpml_intercept($home_url, $url) +function acf_license_ml_intercept($home_url, $url) { } /** - * This function will return the license key + * Returns the license key. * - * @type function - * @date 20/09/2016 - * @since 5.4.0 + * @since 5.4.0 * - * @param boolean $skip_url_check Skip the check of the current site url. - * @return string $license_key + * @param boolean $skip_url_check Skip the check of the current site url. + * @return string|bool License key on success, or false on failure. */ function acf_pro_get_license_key($skip_url_check = \false) { @@ -23919,14 +23935,14 @@ function acf_pro_get_registered_block_count() * Activates the submitted license key * Formally ACF_Admin_Updates::activate_pro_licence since 5.0.0 * - * @date 30/09/2021 * @since 5.11.0 * - * @param string $license_key License key to activate - * @param boolean $silent Return errors rather than displaying them - * @return mixed $response A wp-error instance, or an array with a boolean success key, and string message key + * @param string $license_key License key to activate. + * @param boolean $silent Return errors rather than displaying them. + * @param boolean $automatic True if this activation is happening automatically. + * @return mixed $response A wp-error instance, or an array with a boolean success key, and string message key. */ -function acf_pro_activate_license($license_key, $silent = \false) +function acf_pro_activate_license($license_key, $silent = \false, $automatic = \false) { } /** @@ -24029,4 +24045,38 @@ function acf_pro_is_license_expired($status = array()) */ function acf_pro_was_license_refunded($status = array()) { +} +/** + * Checks if the `home_url` has changed since license activation. + * + * @since 6.2.2 + * + * @param array $license Optional ACF license array. + * @param string $url An optional URL to provide. + * @return bool True if the URL has changed, false otherwise. + */ +function acf_pro_has_license_url_changed($license = array(), $url = '') +{ +} +/** + * Attempts to reactivate the license if the URL has changed. + * + * @since 6.2.3 + * + * @return void + * @phpstan-return void + */ +function acf_pro_maybe_reactivate_license() +{ +} +/** + * Gets the URL to the "My Account" section for an ACF license. + * + * @since 6.2.3 + * + * @param array $status Optional license status array. + * @return string + */ +function acf_pro_get_manage_license_url($status = array()) +{ } \ No newline at end of file From 69cf01c7f8e47a19bf0dd842b72f5a8a8d0c91b6 Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Sun, 4 Feb 2024 15:49:24 +0200 Subject: [PATCH 07/11] Generate stubs for ACF PRO 6.2.4 --- acf-pro-stubs.php | 2362 ++++++++++++++++++++------------------------- 1 file changed, 1069 insertions(+), 1293 deletions(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index b42db22..c73fd58 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.2.3'; + public $version = '6.2.4'; /** * The plugin settings array. * @@ -1303,7 +1303,7 @@ function network_admin_menu() /** * Checks if an ACF database upgrade is required on any site in the * multisite network. - * + * * Stores the result in `$this->network_upgrade_needed_transient`, * which is version-linked to ACF_UPGRADE_VERSION: the highest ACF * version that requires an upgrade function to run. Bumping @@ -12672,268 +12672,71 @@ function acf_validate_post_id($post_id, $_post_id) { } } +/** + * ACF 3rd Party Compatibility Class + */ class acf_third_party { /** - * __construct - * - * This function will setup the class functionality - * - * @type function - * @date 5/03/2014 - * @since 5.0.0 - * - * @param void - * @return void - */ - function __construct() - { - } - /** - * acf_get_post_types - * - * EE post types do not use the native post.php edit page, but instead render their own. - * Show the EE post types in lists where 'show_ui' is used. - * - * @date 24/2/18 - * @since 5.6.9 - * - * @param array $post_types - * @param array $args - * @return array - */ - function ee_get_post_types($post_types, $args) - { - } - /** - * tabify_posttypes - * - * This function removes ACF post types from the tabify edit screen (post type selection sidebar) - * - * @type function - * @date 9/10/12 - * @since 3.5.1 - * - * @param int $post_id - * @return int $post_id - */ - function tabify_posttypes($posttypes) - { - } - /** - * tabify_add_meta_boxes - * - * This function creates dummy metaboxes on the tabify edit screen page - * - * @type function - * @date 9/10/12 - * @since 3.5.1 - * - * @param string $post_type - * @return void - */ - function tabify_add_meta_boxes($post_type) - { - } - /** - * pts_allowed_pages - * - * This filter will prevent PTS from running on the field group page! - * - * @type function - * @date 25/09/2014 - * @since 5.0.0 - * - * @param array $pages - * @return $pages - */ - function pts_allowed_pages($pages) - { - } - /** - * doing_dark_mode - * - * Runs during 'admin_enqueue_scripts' if dark mode is enabled - * - * @date 13/8/18 - * @since 5.7.3 - * - * @param void - * @return void - */ - function doing_dark_mode() - { - } -} -class ACF_Updates -{ - /** @var string The ACF_Updates version */ - var $version = '2.4'; - /** @var array The array of registered plugins */ - var $plugins = array(); - /** @var int Counts the number of plugin update checks */ - var $checked = 0; - /** - * __construct - * - * Sets up the class functionality. - * - * @date 5/03/2014 - * @since 5.0.0 - * - * @param void - * @return void - */ - function __construct() - { - } - /** - * add_plugin - * - * Registeres a plugin for updates. - * - * @date 8/4/17 - * @since 5.5.10 - * - * @param array $plugin The plugin array. - * @return void - */ - function add_plugin($plugin) - { - } - /** - * get_plugin_by - * - * Returns a registered plugin for the give key and value. - * - * @date 3/8/18 - * @since 5.7.2 - * - * @param string $key The array key to compare - * @param string $value The value to compare against - * @return array|false - */ - function get_plugin_by($key = '', $value = \null) - { - } - /** - * request - * - * Makes a request to the ACF connect server. - * - * @date 8/4/17 - * @since 5.5.10 - * - * @param string $endpoint The API endpoint. - * @param array $body The body to post. - * @return array|string|WP_Error - */ - function request($endpoint = '', $body = \null) - { - } - /** - * Returns update information for the given plugin id. - * - * @since 5.5.10 - * - * @param string $id The plugin id such as 'pro'. - * @param boolean $force_check Bypasses cached result. Defaults to false. - * @return array|WP_Error - */ - public function get_plugin_info($id = '', $force_check = \false) - { - } - /** - * Returns specific data from the 'update-check' response. - * - * @since 5.7.2 - * - * @param string $basename The plugin basename. - * @param boolean $force_check Bypasses cached result. Defaults to false. - * @return array|false - */ - public function get_plugin_update($basename = '', $force_check = \false) - { - } - /** - * Checks if an update is available, but can't be updated to. - * - * @since 6.2.1 + * This function will setup the class functionality * - * @param string $basename The plugin basename. - * @param boolean $force_check Bypasses cached result. Defaults to false. - * @return array|false + * @since 5.0.0 */ - public function get_no_update($basename = '', $force_check = \false) + public function __construct() { } /** - * get_plugin_updates + * Event Espresso post types do not use the native post.php edit page, but instead render their own. + * Show the EE post types in lists where 'show_ui' is used. * - * Checks for plugin updates. - * - * @date 8/7/18 - * @since 5.6.9 - * @since 5.7.2 Added 'checked' comparison + * @date 24/2/18 + * @since 5.6.9 * - * @param boolean $force_check Bypasses cached result. Defaults to false. - * @return array|WP_Error. + * @param array $post_types Post types array. + * @param array $args Other arguments array. + * @return array */ - function get_plugin_updates($force_check = \false) + public function ee_get_post_types($post_types, $args) { } /** - * This function safely gets the expiration value from a response. + * This function removes ACF post types from the tabify edit screen (post type selection sidebar) * - * @since 5.6.9 + * @since 3.5.1 * - * @param mixed $response The response from the server. Default false. - * @param int $min The minimum expiration limit. Default 0. - * @param int $max The maximum expiration limit. Default 0. - * @return int + * @param array $posttypes An array of post types supported by tabify. + * @return array */ - public function get_expiration($response = \false, $min = 0, $max = 0) + public function tabify_posttypes($posttypes) { } /** - * refresh_plugins_transient + * This function creates dummy metaboxes on the tabify edit screen page * - * Deletes transients and allows a fresh lookup. - * - * @date 11/4/17 - * @since 5.5.10 + * @since 3.5.1 * - * @param void - * @return void + * @param string $post_type The name of the displayed post type. */ - function refresh_plugins_transient() + public function tabify_add_meta_boxes($post_type) { } /** - * Called when WP updates the 'update_plugins' site transient. Used to inject ACF plugin update info. + * This filter will prevent PTS from running on the field group page * - * @since 5.0.0 + * @since 5.0.0 * - * @param object $transient The current transient value. - * @return object $transient The modified transient value. + * @param array $pages An array of pages PTS should run on. + * @return array */ - public function modify_plugins_transient($transient) + public function pts_allowed_pages($pages) { } /** - * modify_plugin_details - * - * Returns the plugin data visible in the 'View details' popup - * - * @date 17/01/2014 - * @since 5.0.0 + * Runs during 'admin_enqueue_scripts' if dark mode is enabled * - * @param object $result - * @param string $action - * @param object $args - * @return $result + * @since 5.7.3 */ - function modify_plugin_details($result, $action = \null, $args = \null) + public function doing_dark_mode() { } } @@ -13544,7 +13347,7 @@ function display_wp_error($wp_error) * @since 5.7.10 * * @param string $changelog The changelog text. - * @param string $version The version to find. + * @param string $version The version to find. * @return string */ function get_changelog_changes($changelog = '', $version = '') @@ -13635,7 +13438,7 @@ public function __construct() /** * This function will customize the message shown when editing a post type. * - * @since 5.0.0 + * @since 6.2 * * @param array $messages Post type messages. * @return array @@ -13648,18 +13451,24 @@ public function post_updated_messages($messages) * * @since 6.1 * - * @param bool $created True if the options page was just created. + * @param boolean $created True if the options page was just created. * @return string */ public function options_page_created_message($created = \false) { } /** - * Enqueues any scripts necessary for internal post type. + * Allow other pages to get available option page parents. * - * @since 5.0.0 + * @since 6.2 + */ + public function add_js_parent_choices() + { + } + /** + * Enqueues any scripts necessary for internal post type. * - * @return void + * @since 6.2 */ public function admin_enqueue_scripts() { @@ -13728,9 +13537,9 @@ public function screen_settings($html) /** * Sets the "Edit Post Type" screen to use a one-column layout. * - * @param int $columns Number of columns for layout. + * @param integer $columns Number of columns for layout. * - * @return int + * @return integer */ public function screen_layout($columns = 0) { @@ -13770,10 +13579,10 @@ public function post_submitbox_misc_actions() * * @since 1.0.0 * - * @param int $post_id The post ID. + * @param integer $post_id The post ID. * @param WP_Post $post The post object. * - * @return int $post_id + * @return integer $post_id */ public function save_post($post_id, $post) { @@ -13781,7 +13590,7 @@ public function save_post($post_id, $post) /** * Renders HTML for the basic settings metabox. * - * @since 5.0.0 + * @since 6.2 * * @return void */ @@ -13791,7 +13600,7 @@ public function mb_basic_settings() /** * Renders the HTML for the advanced settings metabox. * - * @since 5.0.0 + * @since 6.2 * * @return void */ @@ -13803,10 +13612,10 @@ public function mb_advanced_settings() * * @since 6.2 * - * @param string $menu_slug Optional menu_slug of an existing options page. + * @param integer $post_id The post ID of a current ACF UI options page used to prevent selection of itself as a child. * @return array */ - public static function get_parent_page_choices($current_slug = '') + public function get_parent_page_choices(int $post_id = 0) { } /** @@ -13919,93 +13728,253 @@ public function get_action_notice_text($action, $count = 1) { } } -class acf_field_clone extends \acf_field +/** + * class for handling API services. + */ +class ACF_Updates { /** - * __construct + * The ACF_Updates version * - * This function will setup the field type data + * @var string + */ + public $version = '2.4'; + /** + * The array of registered plugins * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @var array + */ + public $plugins = array(); + /** + * Counts the number of plugin update checks * - * @param void - * @return void + * @var integer */ - function initialize() + public $checked = 0; + /** + * Sets up the class functionality. + * + * @since 5.0.0 + */ + public function __construct() { } /** - * is_enabled - * - * This function will return true if acf_local functionality is enabled + * Registeres a plugin for updates. * - * @type function - * @date 14/07/2016 - * @since 5.4.0 + * @since 5.5.10 * - * @param void - * @return void + * @param array $plugin The plugin array. + * @return void */ - function is_enabled() + public function add_plugin($plugin) { } /** - * load_field() - * - * This filter is appied to the $field after it is loaded from the database - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * Returns a registered plugin for the give key and value. * - * @param $field - the field array holding all the field options + * @since 5.7.2 * - * @return $field - the field array holding all the field options + * @param string $key The array key to compare. + * @param string $value The value to compare against. + * @return array|false */ - function load_field($field) + public function get_plugin_by($key = '', $value = \null) { } /** - * acf_get_fields - * - * This function will hook into the 'acf/get_fields' filter and inject/replace seamless clones fields + * Makes a request to the ACF connect server. * - * @type function - * @date 17/06/2016 - * @since 5.3.8 + * @since 5.5.10 * - * @param array $fields - * @param array $parent - * @return $fields + * @param string $endpoint The API endpoint. + * @param array $body The body to post. + * @return array|string|WP_Error */ - function acf_get_fields($fields, $parent) + public function request($endpoint = '', $body = \null) { } /** - * get_cloned_fields - * - * This function will return an array of fields for a given clone field + * Returns update information for the given plugin id. * - * @type function - * @date 28/06/2016 - * @since 5.3.8 + * @since 5.5.10 * - * @param array $field - * @param array $parent - * @return array + * @param string $id The plugin id such as 'pro'. + * @param boolean $force_check Bypasses cached result. Defaults to false. + * @return array|WP_Error */ - function get_cloned_fields($field) + public function get_plugin_info($id = '', $force_check = \false) { } /** - * acf_clone_field + * Returns specific data from the 'update-check' response. * - * This function is run when cloning a clone field - * Important to run the acf_clone_field function on sub fields to pass on settings such as 'parent_layout' + * @since 5.7.2 * - * @type function + * @param string $basename The plugin basename. + * @param boolean $force_check Bypasses cached result. Defaults to false. + * @return array|false + */ + public function get_plugin_update($basename = '', $force_check = \false) + { + } + /** + * Checks if an update is available, but can't be updated to. + * + * @since 6.2.1 + * + * @param string $basename The plugin basename. + * @param boolean $force_check Bypasses cached result. Defaults to false. + * @return array|false + */ + public function get_no_update($basename = '', $force_check = \false) + { + } + /** + * Checks for plugin updates. + * + * @since 5.6.9 + * @since 5.7.2 Added 'checked' comparison + * + * @param boolean $force_check Bypasses cached result. Defaults to false. + * @return array|WP_Error. + */ + public function get_plugin_updates($force_check = \false) + { + } + /** + * This function safely gets the expiration value from a response. + * + * @since 5.6.9 + * + * @param mixed $response The response from the server. Default false. + * @param integer $min The minimum expiration limit. Default 0. + * @param integer $max The maximum expiration limit. Default 0. + * @return integer + */ + public function get_expiration($response = \false, $min = 0, $max = 0) + { + } + /** + * Deletes transients and allows a fresh lookup. + * + * @since 5.5.10 + */ + public function refresh_plugins_transient() + { + } + /** + * Called when WP updates the 'update_plugins' site transient. Used to inject ACF plugin update info. + * + * @since 5.0.0 + * + * @param object $transient The current transient value. + * @return object $transient The modified transient value. + */ + public function modify_plugins_transient($transient) + { + } + /** + * Returns the plugin data visible in the 'View details' popup + * + * @since 5.0.0 + * + * @param object $result The current result of plugin data. + * @param string $action The action being performed. + * @param object $args Data about the plugin being retried. + * @return $result + */ + public function modify_plugin_details($result, $action = \null, $args = \null) + { + } +} +class acf_field_clone extends \acf_field +{ + /** + * __construct + * + * This function will setup the field type data + * + * @type function + * @date 5/03/2014 + * @since 5.0.0 + * + * @param void + * @return void + */ + function initialize() + { + } + /** + * is_enabled + * + * This function will return true if acf_local functionality is enabled + * + * @type function + * @date 14/07/2016 + * @since 5.4.0 + * + * @param void + * @return void + */ + function is_enabled() + { + } + /** + * load_field() + * + * This filter is appied to the $field after it is loaded from the database + * + * @type filter + * @since 3.6 + * @date 23/01/13 + * + * @param $field - the field array holding all the field options + * + * @return $field - the field array holding all the field options + */ + function load_field($field) + { + } + /** + * acf_get_fields + * + * This function will hook into the 'acf/get_fields' filter and inject/replace seamless clones fields + * + * @type function + * @date 17/06/2016 + * @since 5.3.8 + * + * @param array $fields + * @param array $parent + * @return $fields + */ + function acf_get_fields($fields, $parent) + { + } + /** + * get_cloned_fields + * + * This function will return an array of fields for a given clone field + * + * @type function + * @date 28/06/2016 + * @since 5.3.8 + * + * @param array $field + * @param array $parent + * @return array + */ + function get_cloned_fields($field) + { + } + /** + * acf_clone_field + * + * This function is run when cloning a clone field + * Important to run the acf_clone_field function on sub fields to pass on settings such as 'parent_layout' + * + * @type function * @date 28/06/2016 * @since 5.3.8 * @@ -15651,7 +15620,7 @@ class ACF_UI_Options_Page extends \ACF_Internal_Post_Type /** * Constructs the class and any parent classes. * - * @since 5.0.0 + * @since 6.2 */ public function __construct() { @@ -15765,8 +15734,7 @@ public function __construct() /** * Initializes the ACF PRO updates functionality. * - * @date 10/4/17 - * @since 5.5.10 + * @since 5.5.10 * @phpstan-return void */ public function init() @@ -15811,10 +15779,10 @@ function acf() * * @since 6.2 * - * @param array $target_item_ids The post, user or term IDs which should be updated with the origin item ID. - * @param int|string $post_id The ACF encoded origin post, user or term ID. - * @param array $field The field being updated on the origin post, user or term ID. - * @param string|false $target_prefix The ACF prefix for a post, user or term ID required for the update_field call for this field type. + * @param array $target_item_ids The post, user or term IDs which should be updated with the origin item ID. + * @param integer|string $post_id The ACF encoded origin post, user or term ID. + * @param array $field The field being updated on the origin post, user or term ID. + * @param string|false $target_prefix The ACF prefix for a post, user or term ID required for the update_field call for this field type. */ function acf_update_bidirectional_values($target_item_ids, $post_id, $field, $target_prefix = \false) { @@ -15825,6 +15793,7 @@ function acf_update_bidirectional_values($target_item_ids, $post_id, $field, $ta * @since 6.2 * * @param string $object_type The object type that will be updated on the target field, such as 'term', 'user' or 'post'. + * * @return array An array of valid field type names (slugs) for the target of the bidirectional field. */ function acf_get_valid_bidirectional_target_types($object_type) @@ -19244,67 +19213,63 @@ function acf_print_menu_section($menu_items, $section = '') { } /** - * This function will return true for a non empty array + * This function will return true for a non empty array * - * @since 5.4.0 + * @since 5.4.0 * - * @param mixed $array The variable to test. - * @return boolean + * @param mixed $array The variable to test. + * @return boolean */ function acf_is_array($array) { } /** - * Alias of acf()->has_setting() + * Alias of acf()->has_setting() * - * @since 5.6.5 + * @since 5.6.5 * - * @param string $name Name of the setting to check for. - * @return boolean + * @param string $name Name of the setting to check for. + * @return boolean */ function acf_has_setting($name = '') { } /** - * acf_raw_setting + * acf_raw_setting * - * alias of acf()->get_setting() + * alias of acf()->get_setting() * - * @date 2/2/18 - * @since 5.6.5 + * @since 5.6.5 * - * @param void - * @return void + * @param void + * @return void */ function acf_raw_setting($name = '') { } /** -* acf_update_setting -* -* alias of acf()->update_setting() -* -* @type function -* @date 28/09/13 -* @since 5.0.0 -* -* @param string $name -* @param mixed $value -* @return void -*/ + * acf_update_setting + * + * alias of acf()->update_setting() + * + * @since 5.0.0 + * + * @param string $name + * @param mixed $value + * @return void + */ function acf_update_setting($name, $value) { } /** - * acf_validate_setting + * acf_validate_setting * - * Returns the changed setting name if available. + * Returns the changed setting name if available. * - * @date 2/2/18 - * @since 5.6.5 + * @since 5.6.5 * - * @param void - * @return void + * @param void + * @return void */ function acf_validate_setting($name = '') { @@ -19314,7 +19279,7 @@ function acf_validate_setting($name = '') * * @since 5.0.0 * - * @param string $name The name of the setting to test. + * @param string $name The name of the setting to test. * @param string $value An optional default value for the setting if it doesn't exist. * @return void */ @@ -19331,46 +19296,42 @@ function acf_get_internal_post_types() { } /** -* acf_append_setting -* -* This function will add a value into the settings array found in the acf object -* -* @type function -* @date 28/09/13 -* @since 5.0.0 -* -* @param string $name -* @param mixed $value -* @return void -*/ + * acf_append_setting + * + * This function will add a value into the settings array found in the acf object + * + * @since 5.0.0 + * + * @param string $name + * @param mixed $value + * @return void + */ function acf_append_setting($name, $value) { } /** - * acf_get_data + * acf_get_data * - * Returns data. + * Returns data. * - * @date 28/09/13 - * @since 5.0.0 + * @since 5.0.0 * - * @param string $name - * @return mixed + * @param string $name + * @return mixed */ function acf_get_data($name) { } /** - * acf_set_data + * acf_set_data * - * Sets data. + * Sets data. * - * @date 28/09/13 - * @since 5.0.0 + * @since 5.0.0 * - * @param string $name - * @param mixed $value - * @return void + * @param string $name + * @param mixed $value + * @return void */ function acf_set_data($name, $value) { @@ -19382,42 +19343,39 @@ function acf_set_data($name, $value) * * @param string $name The data name. * @param mixed $data The data to append to name. - * @return void */ function acf_append_data($name, $data) { } /** - * Alias of acf()->init() - the core ACF init function. + * Alias of acf()->init() - the core ACF init function. * - * @since 5.0.0 + * @since 5.0.0 */ function acf_init() { } /** -* acf_has_done -* -* This function will return true if this action has already been done -* -* @type function -* @date 16/12/2015 -* @since 5.3.2 -* -* @param string $name -* @return boolean -*/ + * acf_has_done + * + * This function will return true if this action has already been done + * + * @since 5.3.2 + * + * @param string $name + * @return boolean + */ function acf_has_done($name) { } /** * This function will return the path to a file within an external folder * - * @since 5.5.8 + * @since 5.5.8 * - * @param string $file Directory path. - * @param string $path Optional file path. - * @return string File path. + * @param string $file Directory path. + * @param string $path Optional file path. + * @return string File path. */ function acf_get_external_path($file, $path = '') { @@ -19425,106 +19383,95 @@ function acf_get_external_path($file, $path = '') /** * This function will return the url to a file within an internal ACF folder * - * @since 5.5.8 + * @since 5.5.8 * - * @param string $file Directory path. - * @param string $path Optional file path. - * @return string File path. + * @param string $file Directory path. + * @param string $path Optional file path. + * @return string File path. */ function acf_get_external_dir($file, $path = '') { } /** - * This function will calculate the url to a plugin folder. - * Different to the WP plugin_dir_url(), this function can calculate for urls outside of the plugins folder (theme include). + * This function will calculate the url to a plugin folder. + * Different to the WP plugin_dir_url(), this function can calculate for urls outside of the plugins folder (theme include). * - * @date 13/12/17 - * @since 5.6.8 + * @since 5.6.8 * - * @param string $file A file path inside the ACF plugin to get the plugin directory path from. - * @return string The plugin directory path. + * @param string $file A file path inside the ACF plugin to get the plugin directory path from. + * @return string The plugin directory path. */ function acf_plugin_dir_url($file) { } /** - * This function will merge together 2 arrays and also convert any numeric values to ints + * This function will merge together 2 arrays and also convert any numeric values to ints * - * @since 5.0.0 + * @since 5.0.0 * - * @param array $args The configured arguments array. - * @param array $defaults The default properties for the passed args to inherit. - * @return array $args Parsed arguments with defaults applied. + * @param array $args The configured arguments array. + * @param array $defaults The default properties for the passed args to inherit. + * @return array $args Parsed arguments with defaults applied. */ function acf_parse_args($args, $defaults = array()) { } /** -* acf_parse_types -* -* This function will convert any numeric values to int and trim strings -* -* @type function -* @date 18/10/13 -* @since 5.0.0 -* -* @param mixed $var -* @return mixed $var -*/ + * acf_parse_types + * + * This function will convert any numeric values to int and trim strings + * + * @since 5.0.0 + * + * @param mixed $var + * @return mixed $var + */ function acf_parse_types($array) { } /** -* acf_parse_type -* -* description -* -* @type function -* @date 11/11/2014 -* @since 5.0.9 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_parse_type + * + * description + * + * @since 5.0.9 + * + * @param int $post_id + * @return int $post_id + */ function acf_parse_type($v) { } /** - * This function will load in a file from the 'admin/views' folder and allow variables to be passed through + * This function will load in a file from the 'admin/views' folder and allow variables to be passed through * - * @date 28/09/13 - * @since 5.0.0 - * - * @param string $view_path - * @param array $view_args + * @since 5.0.0 * - * @return void + * @param string $view_path + * @param array $view_args */ function acf_get_view($view_path = '', $view_args = array()) { } /** -* acf_merge_atts -* -* description -* -* @type function -* @date 2/11/2014 -* @since 5.0.9 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_merge_atts + * + * description + * + * @since 5.0.9 + * + * @param int $post_id + * @return int $post_id + */ function acf_merge_atts($atts, $extra = array()) { } /** * This function will create and echo a basic nonce input * - * @since 5.6.0 + * @since 5.6.0 * - * @param string $nonce The nonce parameter string. - * @return void + * @param string $nonce The nonce parameter string. */ function acf_nonce_input($nonce = '') { @@ -19535,7 +19482,7 @@ function acf_nonce_input($nonce = '') * @since 5.0.0 * * @param array $extract_array an array passed as reference to be extracted. - * @param string $key The key to extract from the array. + * @param string $key The key to extract from the array. * @param mixed $default_value The default value if it doesn't exist in the extract array. * @return mixed Extracted var or default. */ @@ -19548,35 +19495,32 @@ function acf_extract_var(&$extract_array, $key, $default_value = \null) * @since 5.0.0 * * @param array $extract_array an array passed as reference to be extracted. - * @param array $keys An array of keys to extract from the original array. + * @param array $keys An array of keys to extract from the original array. * @return array An array of extracted values. */ function acf_extract_vars(&$extract_array, $keys) { } /** -* acf_get_sub_array -* -* This function will return a sub array of data -* -* @type function -* @date 15/03/2016 -* @since 5.3.2 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_get_sub_array + * + * This function will return a sub array of data + * + * @since 5.3.2 + * + * @param int $post_id + * @return int $post_id + */ function acf_get_sub_array($array, $keys) { } /** - * Returns an array of post type names. + * Returns an array of post type names. * - * @date 7/10/13 - * @since 5.0.0 + * @since 5.0.0 * - * @param array $args Optional. An array of key => value arguments to match against the post type objects. Default empty array. - * @return array A list of post type names. + * @param array $args Optional. An array of key => value arguments to match against the post type objects. Default empty array. + * @return array A list of post type names. */ function acf_get_post_types($args = array()) { @@ -19585,106 +19529,94 @@ function acf_get_pretty_post_types($post_types = array()) { } /** - * Function acf_get_post_stati() + * Function acf_get_post_stati() * - * Returns an array of post status names. + * Returns an array of post status names. * - * @date 01/24/23 - * @since 6.1.0 + * @since 6.1.0 * - * @param array $args Optional. An array of key => value arguments to match against the post status objects. Default empty array. - * @return array A list of post status names. + * @param array $args Optional. An array of key => value arguments to match against the post status objects. Default empty array. + * @return array A list of post status names. */ function acf_get_post_stati($args = array()) { } /** - * Function acf_get_pretty_post_statuses() + * Function acf_get_pretty_post_statuses() * - * Returns a clean array of post status names. + * Returns a clean array of post status names. * - * @date 02/16/23 - * @since 6.1.0 + * @since 6.1.0 * - * @param array $post_statuses Optional. An array of post status objects. Default empty array. - * @return array An array of post status names. + * @param array $post_statuses Optional. An array of post status objects. Default empty array. + * @return array An array of post status names. */ function acf_get_pretty_post_statuses($post_statuses = array()) { } /** -* acf_get_post_type_label -* -* This function will return a pretty label for a specific post_type -* -* @type function -* @date 5/07/2016 -* @since 5.4.0 -* -* @param string $post_type -* @return string -*/ + * acf_get_post_type_label + * + * This function will return a pretty label for a specific post_type + * + * @since 5.4.0 + * + * @param string $post_type + * @return string + */ function acf_get_post_type_label($post_type) { } /** - * Function acf_get_post_status_label() + * Function acf_get_post_status_label() * - * This function will return a pretty label for a specific post_status + * This function will return a pretty label for a specific post_status * - * @type function - * @date 01/24/2023 - * @since 6.1.0 + * @since 6.1.0 * - * @param string $post_status The post status. - * @return string The post status label. + * @param string $post_status The post status. + * @return string The post status label. */ function acf_get_post_status_label($post_status) { } /** -* acf_verify_nonce -* -* This function will look at the $_POST['_acf_nonce'] value and return true or false -* -* @type function -* @date 15/10/13 -* @since 5.0.0 -* -* @param string $nonce -* @return boolean -*/ + * acf_verify_nonce + * + * This function will look at the $_POST['_acf_nonce'] value and return true or false + * + * @since 5.0.0 + * + * @param string $nonce + * @return boolean + */ function acf_verify_nonce($value) { } /** -* acf_verify_ajax -* -* This function will return true if the current AJAX request is valid -* It's action will also allow WPML to set the lang and avoid AJAX get_posts issues -* -* @type function -* @date 7/08/2015 -* @since 5.2.3 -* -* @param void -* @return boolean -*/ + * acf_verify_ajax + * + * This function will return true if the current AJAX request is valid + * It's action will also allow WPML to set the lang and avoid AJAX get_posts issues + * + * @since 5.2.3 + * + * @param void + * @return boolean + */ function acf_verify_ajax() { } /** -* acf_get_image_sizes -* -* This function will return an array of available image sizes -* -* @type function -* @date 23/10/13 -* @since 5.0.0 -* -* @param void -* @return array -*/ + * acf_get_image_sizes + * + * This function will return an array of available image sizes + * + * @since 5.0.0 + * + * @param void + * @return array + */ function acf_get_image_sizes() { } @@ -19696,89 +19628,78 @@ function acf_get_image_size($s = '') * * Similar to the version_compare() function but with extra functionality. * - * @date 21/11/16 * @since 5.5.0 * - * @param string $left The left version number. + * @param string $left The left version number. * @param string $compare The compare operator. - * @param string $right The right version number. - * @return bool + * @param string $right The right version number. + * @return boolean */ function acf_version_compare($left = '', $compare = '>', $right = '') { } /** -* acf_get_full_version -* -* This function will remove any '-beta1' or '-RC1' strings from a version -* -* @type function -* @date 24/11/16 -* @since 5.5.0 -* -* @param string $version -* @return string -*/ + * acf_get_full_version + * + * This function will remove any '-beta1' or '-RC1' strings from a version + * + * @since 5.5.0 + * + * @param string $version + * @return string + */ function acf_get_full_version($version = '1') { } /** -* acf_get_terms -* -* This function is a wrapper for the get_terms() function -* -* @type function -* @date 28/09/2016 -* @since 5.4.0 -* -* @param array $args -* @return array -*/ + * acf_get_terms + * + * This function is a wrapper for the get_terms() function + * + * @since 5.4.0 + * + * @param array $args + * @return array + */ function acf_get_terms($args) { } /** -* acf_get_taxonomy_terms -* -* This function will return an array of available taxonomy terms -* -* @type function -* @date 7/10/13 -* @since 5.0.0 -* -* @param array $taxonomies -* @return array -*/ + * acf_get_taxonomy_terms + * + * This function will return an array of available taxonomy terms + * + * @since 5.0.0 + * + * @param array $taxonomies + * @return array + */ function acf_get_taxonomy_terms($taxonomies = array()) { } /** -* acf_decode_taxonomy_terms -* -* This function decodes the $taxonomy:$term strings into a nested array -* -* @type function -* @date 27/02/2014 -* @since 5.0.0 -* -* @param array $terms -* @return array -*/ + * acf_decode_taxonomy_terms + * + * This function decodes the $taxonomy:$term strings into a nested array + * + * @since 5.0.0 + * + * @param array $terms + * @return array + */ function acf_decode_taxonomy_terms($strings = \false) { } /** -* acf_decode_taxonomy_term -* -* This function will return the taxonomy and term slug for a given value -* -* @type function -* @date 31/03/2014 -* @since 5.0.0 -* -* @param string $string -* @return array -*/ + * acf_decode_taxonomy_term + * + * This function will return the taxonomy and term slug for a given value + * + * @since 5.0.0 + * + * @param string $string + * @return array + */ function acf_decode_taxonomy_term($value) { } @@ -19787,7 +19708,6 @@ function acf_decode_taxonomy_term($value) * * Casts the value into an array. * - * @date 9/1/19 * @since 5.7.10 * * @param mixed $val The value to cast. @@ -19799,7 +19719,6 @@ function acf_array($val = array()) /** * Returns a non-array value. * - * @date 11/05/2020 * @since 5.8.10 * * @param mixed $val The value to review. @@ -19809,32 +19728,28 @@ function acf_unarray($val) { } /** -* acf_get_array -* -* This function will force a variable to become an array -* -* @type function -* @date 4/02/2014 -* @since 5.0.0 -* -* @param mixed $var -* @return array -*/ + * acf_get_array + * + * This function will force a variable to become an array + * + * @since 5.0.0 + * + * @param mixed $var + * @return array + */ function acf_get_array($var = \false, $delimiter = '') { } /** -* acf_get_numeric -* -* This function will return numeric values -* -* @type function -* @date 15/07/2016 -* @since 5.4.0 -* -* @param mixed $value -* @return mixed -*/ + * acf_get_numeric + * + * This function will return numeric values + * + * @since 5.4.0 + * + * @param mixed $value + * @return mixed + */ function acf_get_numeric($value = '') { } @@ -19843,7 +19758,6 @@ function acf_get_numeric($value = '') * * Similar to the get_posts() function but with extra functionality. * - * @date 3/03/15 * @since 5.1.5 * * @param array $args The query args. @@ -19853,34 +19767,30 @@ function acf_get_posts($args = array()) { } /** -* _acf_query_remove_post_type -* -* This function will remove the 'wp_posts.post_type' WHERE clause completely -* When using 'post__in', this clause is unneccessary and slow. -* -* @type function -* @date 4/03/2015 -* @since 5.1.5 -* -* @param string $sql -* @return $sql -*/ + * _acf_query_remove_post_type + * + * This function will remove the 'wp_posts.post_type' WHERE clause completely + * When using 'post__in', this clause is unneccessary and slow. + * + * @since 5.1.5 + * + * @param string $sql + * @return $sql + */ function _acf_query_remove_post_type($sql) { } /** -* acf_get_grouped_posts -* -* This function will return all posts grouped by post_type -* This is handy for select settings -* -* @type function -* @date 27/02/2014 -* @since 5.0.0 -* -* @param array $args -* @return array -*/ + * acf_get_grouped_posts + * + * This function will return all posts grouped by post_type + * This is handy for select settings + * + * @since 5.0.0 + * + * @param array $args + * @return array + */ function acf_get_grouped_posts($args) { } @@ -19894,33 +19804,29 @@ function acf_order_by_search($array, $search) { } /** -* acf_get_pretty_user_roles -* -* description -* -* @type function -* @date 23/02/2016 -* @since 5.3.2 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_get_pretty_user_roles + * + * description + * + * @since 5.3.2 + * + * @param int $post_id + * @return int $post_id + */ function acf_get_pretty_user_roles($allowed = \false) { } /** -* acf_get_grouped_users -* -* This function will return all users grouped by role -* This is handy for select settings -* -* @type function -* @date 27/02/2014 -* @since 5.0.0 -* -* @param array $args -* @return array -*/ + * acf_get_grouped_users + * + * This function will return all users grouped by role + * This is handy for select settings + * + * @since 5.0.0 + * + * @param array $args + * @return array + */ function acf_get_grouped_users($args = array()) { } @@ -19929,7 +19835,6 @@ function acf_get_grouped_users($args = array()) * * Returns json_encode() ready for file / database use. * - * @date 29/4/19 * @since 5.0.0 * * @param array $json The array of data to encode. @@ -19939,33 +19844,29 @@ function acf_json_encode($json) { } /** -* acf_str_exists -* -* This function will return true if a sub string is found -* -* @type function -* @date 1/05/2014 -* @since 5.0.0 -* -* @param string $needle -* @param string $haystack -* @return boolean -*/ + * acf_str_exists + * + * This function will return true if a sub string is found + * + * @since 5.0.0 + * + * @param string $needle + * @param string $haystack + * @return boolean + */ function acf_str_exists($needle, $haystack) { } /** -* acf_debug -* -* description -* -* @type function -* @date 2/05/2014 -* @since 5.0.0 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_debug + * + * description + * + * @since 5.0.0 + * + * @param int $post_id + * @return int $post_id + */ function acf_debug() { } @@ -19976,17 +19877,15 @@ function acf_debug_end() { } /** -* acf_encode_choices -* -* description -* -* @type function -* @date 4/06/2014 -* @since 5.0.0 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_encode_choices + * + * description + * + * @since 5.0.0 + * + * @param int $post_id + * @return int $post_id + */ function acf_encode_choices($array = array(), $show_keys = \true) { } @@ -19994,256 +19893,213 @@ function acf_decode_choices($string = '', $array_keys = \false) { } /** -* acf_str_replace -* -* This function will replace an array of strings much like str_replace -* The difference is the extra logic to avoid replacing a string that has alread been replaced -* This is very useful for replacing date characters as they overlap with eachother -* -* @type function -* @date 21/06/2016 -* @since 5.3.8 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_str_replace + * + * This function will replace an array of strings much like str_replace + * The difference is the extra logic to avoid replacing a string that has alread been replaced + * This is very useful for replacing date characters as they overlap with eachother + * + * @since 5.3.8 + * + * @param int $post_id + * @return int $post_id + */ function acf_str_replace($string = '', $search_replace = array()) { } /** -* acf_split_date_time -* -* This function will split a format string into seperate date and time -* -* @type function -* @date 26/05/2016 -* @since 5.3.8 -* -* @param string $date_time -* @return array $formats -*/ + * acf_split_date_time + * + * This function will split a format string into seperate date and time + * + * @since 5.3.8 + * + * @param string $date_time + * @return array $formats + */ function acf_split_date_time($date_time = '') { } /** -* acf_convert_date_to_php -* -* This fucntion converts a date format string from JS to PHP -* -* @type function -* @date 20/06/2014 -* @since 5.0.0 -* -* @param string $date -* @return string -*/ + * acf_convert_date_to_php + * + * This fucntion converts a date format string from JS to PHP + * + * @since 5.0.0 + * + * @param string $date + * @return string + */ function acf_convert_date_to_php($date = '') { } /** -* acf_convert_date_to_js -* -* This fucntion converts a date format string from PHP to JS -* -* @type function -* @date 20/06/2014 -* @since 5.0.0 -* -* @param string $date -* @return string -*/ + * acf_convert_date_to_js + * + * This fucntion converts a date format string from PHP to JS + * + * @since 5.0.0 + * + * @param string $date + * @return string + */ function acf_convert_date_to_js($date = '') { } /** -* acf_convert_time_to_php -* -* This fucntion converts a time format string from JS to PHP -* -* @type function -* @date 20/06/2014 -* @since 5.0.0 -* -* @param string $time -* @return string -*/ + * acf_convert_time_to_php + * + * This fucntion converts a time format string from JS to PHP + * + * @since 5.0.0 + * + * @param string $time + * @return string + */ function acf_convert_time_to_php($time = '') { } /** -* acf_convert_time_to_js -* -* This fucntion converts a date format string from PHP to JS -* -* @type function -* @date 20/06/2014 -* @since 5.0.0 -* -* @param string $time -* @return string -*/ + * acf_convert_time_to_js + * + * This fucntion converts a date format string from PHP to JS + * + * @since 5.0.0 + * + * @param string $time + * @return string + */ function acf_convert_time_to_js($time = '') { } /** -* acf_update_user_setting -* -* description -* -* @type function -* @date 15/07/2014 -* @since 5.0.0 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_update_user_setting + * + * description + * + * @since 5.0.0 + * + * @param int $post_id + * @return int $post_id + */ function acf_update_user_setting($name, $value) { } /** -* acf_get_user_setting -* -* description -* -* @type function -* @date 15/07/2014 -* @since 5.0.0 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_get_user_setting + * + * description + * + * @since 5.0.0 + * + * @param int $post_id + * @return int $post_id + */ function acf_get_user_setting($name = '', $default = \false) { } /** -* acf_in_array -* -* description -* -* @type function -* @date 22/07/2014 -* @since 5.0.0 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_in_array + * + * description + * + * @since 5.0.0 + * + * @param int $post_id + * @return int $post_id + */ function acf_in_array($value = '', $array = \false) { } /** -* acf_get_valid_post_id -* -* This function will return a valid post_id based on the current screen / parameter -* -* @type function -* @date 8/12/2013 -* @since 5.0.0 -* -* @param mixed $post_id -* @return mixed $post_id -*/ + * acf_get_valid_post_id + * + * This function will return a valid post_id based on the current screen / parameter + * + * @since 5.0.0 + * + * @param mixed $post_id + * @return mixed $post_id + */ function acf_get_valid_post_id($post_id = 0) { } /** -* acf_get_post_id_info -* -* This function will return the type and id for a given $post_id string -* -* @type function -* @date 2/07/2016 -* @since 5.4.0 -* -* @param mixed $post_id -* @return array $info -*/ + * acf_get_post_id_info + * + * This function will return the type and id for a given $post_id string + * + * @since 5.4.0 + * + * @param mixed $post_id + * @return array $info + */ function acf_get_post_id_info($post_id = 0) { } /** -acf_log( acf_get_post_id_info(4) ); -acf_log( acf_get_post_id_info('post_4') ); -acf_log( acf_get_post_id_info('user_123') ); -acf_log( acf_get_post_id_info('term_567') ); -acf_log( acf_get_post_id_info('category_204') ); -acf_log( acf_get_post_id_info('comment_6') ); -acf_log( acf_get_post_id_info('options_lol!') ); -acf_log( acf_get_post_id_info('option') ); -acf_log( acf_get_post_id_info('options') ); -*/ -/** -* acf_isset_termmeta -* -* This function will return true if the termmeta table exists -* https://developer.wordpress.org/reference/functions/get_term_meta/ -* -* @type function -* @date 3/09/2016 -* @since 5.4.0 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_isset_termmeta + * + * This function will return true if the termmeta table exists + * https://developer.wordpress.org/reference/functions/get_term_meta/ + * + * @since 5.4.0 + * + * @param int $post_id + * @return int $post_id + */ function acf_isset_termmeta($taxonomy = '') { } /** * This function will walk through the $_FILES data and upload each found. * - * @date 25/10/2014 * @since 5.0.9 * * @param array $ancestors An internal parameter, not required. - * @return void * @phpstan-return void */ function acf_upload_files($ancestors = array()) { } /** -* acf_upload_file -* -* This function will uploade a $_FILE -* -* @type function -* @date 27/10/2014 -* @since 5.0.9 -* -* @param array $uploaded_file array found from $_FILE data -* @return int $id new attachment ID -*/ + * acf_upload_file + * + * This function will uploade a $_FILE + * + * @since 5.0.9 + * + * @param array $uploaded_file array found from $_FILE data + * @return int $id new attachment ID + */ function acf_upload_file($uploaded_file) { } /** -* acf_update_nested_array -* -* This function will update a nested array value. Useful for modifying the $_POST array -* -* @type function -* @date 27/10/2014 -* @since 5.0.9 -* -* @param array $array target array to be updated -* @param array $ancestors array of keys to navigate through to find the child -* @param mixed $value The new value -* @return boolean -*/ + * acf_update_nested_array + * + * This function will update a nested array value. Useful for modifying the $_POST array + * + * @since 5.0.9 + * + * @param array $array target array to be updated + * @param array $ancestors array of keys to navigate through to find the child + * @param mixed $value The new value + * @return boolean + */ function acf_update_nested_array(&$array, $ancestors, $value) { } /** -* acf_is_screen -* -* This function will return true if all args are matched for the current screen -* -* @type function -* @date 9/12/2014 -* @since 5.1.5 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_is_screen + * + * This function will return true if all args are matched for the current screen + * + * @since 5.1.5 + * + * @param int $post_id + * @return int $post_id + */ function acf_is_screen($id = '') { } @@ -20258,19 +20114,17 @@ function acf_is_acf_admin_screen() { } /** -* acf_maybe_get -* -* This function will return a var if it exists in an array -* -* @type function -* @date 9/12/2014 -* @since 5.1.5 -* -* @param array $array the array to look within -* @param key $key the array key to look for. Nested values may be found using '/' -* @param mixed $default the value returned if not found -* @return int $post_id -*/ + * acf_maybe_get + * + * This function will return a var if it exists in an array + * + * @since 5.1.5 + * + * @param array $array the array to look within + * @param key $key the array key to look for. Nested values may be found using '/' + * @param mixed $default the value returned if not found + * @return int $post_id + */ function acf_maybe_get($array = array(), $key = 0, $default = \null) { } @@ -20283,104 +20137,92 @@ function acf_maybe_get_GET($key = '', $default = \null) /** * Returns an array of attachment data. * - * @date 05/01/2015 * @since 5.1.5 * - * @param int|WP_Post The attachment ID or object. + * @param integer|WP_Post The attachment ID or object * @return array|false */ function acf_get_attachment($attachment) { } /** - * This function will truncate and return a string + * This function will truncate and return a string * - * @date 8/08/2014 - * @since 5.0.0 + * @since 5.0.0 * - * @param string $text The text to truncate. - * @param int $length The number of characters to allow in the string. + * @param string $text The text to truncate. + * @param integer $length The number of characters to allow in the string. * - * @return string + * @return string */ function acf_get_truncated($text, $length = 64) { } /** -* acf_current_user_can_admin -* -* This function will return true if the current user can administrate the ACF field groups -* -* @type function -* @date 9/02/2015 -* @since 5.1.5 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_current_user_can_admin + * + * This function will return true if the current user can administrate the ACF field groups + * + * @since 5.1.5 + * + * @param int $post_id + * @return int $post_id + */ function acf_current_user_can_admin() { } /** -* acf_get_filesize -* -* This function will return a numeric value of bytes for a given filesize string -* -* @type function -* @date 18/02/2015 -* @since 5.1.5 -* -* @param mixed $size -* @return int -*/ + * acf_get_filesize + * + * This function will return a numeric value of bytes for a given filesize string + * + * @since 5.1.5 + * + * @param mixed $size + * @return int + */ function acf_get_filesize($size = 1) { } /** -* acf_format_filesize -* -* This function will return a formatted string containing the filesize and unit -* -* @type function -* @date 18/02/2015 -* @since 5.1.5 -* -* @param mixed $size -* @return int -*/ + * acf_format_filesize + * + * This function will return a formatted string containing the filesize and unit + * + * @since 5.1.5 + * + * @param mixed $size + * @return int + */ function acf_format_filesize($size = 1) { } /** -* acf_get_valid_terms -* -* This function will replace old terms with new split term ids -* -* @type function -* @date 27/02/2015 -* @since 5.1.5 -* -* @param int|array $terms -* @param string $taxonomy -* @return $terms -*/ + * acf_get_valid_terms + * + * This function will replace old terms with new split term ids + * + * @since 5.1.5 + * + * @param int|array $terms + * @param string $taxonomy + * @return $terms + */ function acf_get_valid_terms($terms = \false, $taxonomy = 'category') { } /** -* acf_validate_attachment -* -* This function will validate an attachment based on a field's restrictions and return an array of errors -* -* @type function -* @date 3/07/2015 -* @since 5.2.3 -* -* @param array $attachment attachment data. Changes based on context -* @param array $field field settings containing restrictions -* @param string $context $file is different when uploading / preparing -* @return array $errors -*/ + * acf_validate_attachment + * + * This function will validate an attachment based on a field's restrictions and return an array of errors + * + * @since 5.2.3 + * + * @param array $attachment attachment data. Changes based on context + * @param array $field field settings containing restrictions + * @param context (string) $file is different when uploading / preparing + * @return array $errors + */ function acf_validate_attachment($attachment, $field, $context = 'prepare') { } @@ -20388,116 +20230,69 @@ function _acf_settings_uploader($uploader) { } /** -* acf_translate_keys -* -* description -* -* @type function -* @date 7/12/2015 -* @since 5.3.2 -* -* @param int $post_id -* @return int $post_id -*/ -/** -function acf_translate_keys( $array, $keys ) { - - // bail early if no keys - if( empty($keys) ) return $array; - - - // translate - foreach( $keys as $k ) { - - // bail early if not exists - if( !isset($array[ $k ]) ) continue; - - - // translate - $array[ $k ] = acf_translate( $array[ $k ] ); - - } - - - // return - return $array; - -} -*/ -/** -* acf_translate -* -* This function will translate a string using the new 'l10n_textdomain' setting -* Also works for arrays which is great for fields - select -> choices -* -* @type function -* @date 4/12/2015 -* @since 5.3.2 -* -* @param mixed $string string or array containins strings to be translated -* @return $string -*/ + * acf_translate + * + * This function will translate a string using the new 'l10n_textdomain' setting + * Also works for arrays which is great for fields - select -> choices + * + * @since 5.3.2 + * + * @param mixed $string string or array containins strings to be translated + * @return $string + */ function acf_translate($string) { } /** -* acf_maybe_add_action -* -* This function will determine if the action has already run before adding / calling the function -* -* @type function -* @date 13/01/2016 -* @since 5.3.2 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_maybe_add_action + * + * This function will determine if the action has already run before adding / calling the function + * + * @since 5.3.2 + * + * @param int $post_id + * @return int $post_id + */ function acf_maybe_add_action($tag, $function_to_add, $priority = 10, $accepted_args = 1) { } /** -* acf_is_row_collapsed -* -* This function will return true if the field's row is collapsed -* -* @type function -* @date 2/03/2016 -* @since 5.3.2 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_is_row_collapsed + * + * This function will return true if the field's row is collapsed + * + * @since 5.3.2 + * + * @param int $post_id + * @return int $post_id + */ function acf_is_row_collapsed($field_key = '', $row_index = 0) { } /** -* acf_get_attachment_image -* -* description -* -* @type function -* @date 24/10/16 -* @since 5.5.0 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_get_attachment_image + * + * description + * + * @since 5.5.0 + * + * @param int $post_id + * @return int $post_id + */ function acf_get_attachment_image($attachment_id = 0, $size = 'thumbnail') { } /** -* acf_get_post_thumbnail -* -* This function will return a thumbail image url for a given post -* -* @type function -* @date 3/05/2016 -* @since 5.3.8 -* -* @param obj $post -* @param mixed $size -* @return string -*/ + * acf_get_post_thumbnail + * + * This function will return a thumbail image url for a given post + * + * @since 5.3.8 + * + * @param obj $post + * @param mixed $size + * @return string + */ function acf_get_post_thumbnail($post = \null, $size = 'thumbnail') { } @@ -20506,7 +20301,6 @@ function acf_get_post_thumbnail($post = \null, $size = 'thumbnail') * * Returns the name of the current browser. * - * @date 17/01/2014 * @since 5.0.0 * * @param void @@ -20516,17 +20310,15 @@ function acf_get_browser() { } /** -* acf_is_ajax -* -* This function will reutrn true if performing a wp ajax call -* -* @type function -* @date 7/06/2016 -* @since 5.3.8 -* -* @param void -* @return boolean -*/ + * acf_is_ajax + * + * This function will reutrn true if performing a wp ajax call + * + * @since 5.3.8 + * + * @param void + * @return boolean + */ function acf_is_ajax($action = '') { } @@ -20547,7 +20339,6 @@ function acf_format_date($value, $format) * * Deletes the debug.log file. * - * @date 21/1/19 * @since 5.7.10 * * @param type $var Description. Default. @@ -20557,314 +20348,279 @@ function acf_clear_log() { } /** -* acf_log -* -* description -* -* @type function -* @date 24/06/2016 -* @since 5.3.8 -* -* @param int $post_id -* @return int $post_id -*/ + * acf_log + * + * description + * + * @since 5.3.8 + * + * @param int $post_id + * @return int $post_id + */ function acf_log() { } /** - * acf_dev_log + * acf_dev_log * - * Used to log variables only if ACF_DEV is defined + * Used to log variables only if ACF_DEV is defined * - * @date 25/8/18 - * @since 5.7.4 + * @since 5.7.4 * - * @param mixed - * @return void + * @param mixed + * @return void */ function acf_dev_log() { } /** -* acf_doing -* -* This function will tell ACF what task it is doing -* -* @type function -* @date 28/06/2016 -* @since 5.3.8 -* -* @param string $event -* @param context (string) -* @return void -*/ + * acf_doing + * + * This function will tell ACF what task it is doing + * + * @since 5.3.8 + * + * @param string $event + * @param context (string) + * @return void + */ function acf_doing($event = '', $context = '') { } /** -* acf_is_doing -* -* This function can be used to state what ACF is doing, or to check -* -* @type function -* @date 28/06/2016 -* @since 5.3.8 -* -* @param string $event -* @param context (string) -* @return boolean -*/ + * acf_is_doing + * + * This function can be used to state what ACF is doing, or to check + * + * @since 5.3.8 + * + * @param string $event + * @param context (string) + * @return boolean + */ function acf_is_doing($event = '', $context = '') { } /** -* acf_is_plugin_active -* -* This function will return true if the ACF plugin is active -* - May be included within a theme or other plugin -* -* @type function -* @date 13/07/2016 -* @since 5.4.0 -* -* @param int $basename -* @return int $post_id -*/ + * acf_is_plugin_active + * + * This function will return true if the ACF plugin is active + * - May be included within a theme or other plugin + * + * @since 5.4.0 + * + * @param int $basename + * @return int $post_id + */ function acf_is_plugin_active() { } /** -* acf_send_ajax_results -* -* This function will print JSON data for a Select2 AJAX query -* -* @type function -* @date 19/07/2016 -* @since 5.4.0 -* -* @param array $response -* @return void -*/ + * acf_send_ajax_results + * + * This function will print JSON data for a Select2 AJAX query + * + * @since 5.4.0 + * + * @param array $response + * @return void + * @phpstan-return never + */ function acf_send_ajax_results($response) { } /** -* acf_is_sequential_array -* -* This function will return true if the array contains only numeric keys -* -* @source http://stackoverflow.com/questions/173400/how-to-check-if-php-array-is-associative-or-sequential -* @type function -* @date 9/09/2016 -* @since 5.4.0 -* -* @param array $array -* @return boolean -*/ + * acf_is_sequential_array + * + * This function will return true if the array contains only numeric keys + * + * @source http://stackoverflow.com/questions/173400/how-to-check-if-php-array-is-associative-or-sequential + * + * @since 5.4.0 + * + * @param array $array + * @return boolean + */ function acf_is_sequential_array($array) { } /** -* acf_is_associative_array -* -* This function will return true if the array contains one or more string keys -* -* @source http://stackoverflow.com/questions/173400/how-to-check-if-php-array-is-associative-or-sequential -* @type function -* @date 9/09/2016 -* @since 5.4.0 -* -* @param array $array -* @return boolean -*/ + * acf_is_associative_array + * + * This function will return true if the array contains one or more string keys + * + * @source http://stackoverflow.com/questions/173400/how-to-check-if-php-array-is-associative-or-sequential + * + * @since 5.4.0 + * + * @param array $array + * @return boolean + */ function acf_is_associative_array($array) { } /** -* acf_add_array_key_prefix -* -* This function will add a prefix to all array keys -* Useful to preserve numeric keys when performing array_multisort -* -* @type function -* @date 15/09/2016 -* @since 5.4.0 -* -* @param array $array -* @param string $prefix -* @return array -*/ + * acf_add_array_key_prefix + * + * This function will add a prefix to all array keys + * Useful to preserve numeric keys when performing array_multisort + * + * @since 5.4.0 + * + * @param array $array + * @param string $prefix + * @return array + */ function acf_add_array_key_prefix($array, $prefix) { } /** -* acf_remove_array_key_prefix -* -* This function will remove a prefix to all array keys -* Useful to preserve numeric keys when performing array_multisort -* -* @type function -* @date 15/09/2016 -* @since 5.4.0 -* -* @param array $array -* @param string $prefix -* @return array -*/ + * acf_remove_array_key_prefix + * + * This function will remove a prefix to all array keys + * Useful to preserve numeric keys when performing array_multisort + * + * @since 5.4.0 + * + * @param array $array + * @param string $prefix + * @return array + */ function acf_remove_array_key_prefix($array, $prefix) { } /** -* acf_strip_protocol -* -* This function will remove the proticol from a url -* Used to allow licenses to remain active if a site is switched to https -* -* @type function -* @date 10/01/2017 -* @since 5.5.4 -* @author Aaron -* -* @param string $url -* @return string -*/ + * This function will remove the proticol from a url + * Used to allow licenses to remain active if a site is switched to https + * + * @since 5.5.4 + * + * @param string $url The URL to strip the protocol from. + * @return string + */ function acf_strip_protocol($url) { } /** -* acf_connect_attachment_to_post -* -* This function will connect an attacment (image etc) to the post -* Used to connect attachements uploaded directly to media that have not been attaced to a post -* -* @type function -* @date 11/01/2017 -* @since 5.8.0 Added filter to prevent connection. -* @since 5.5.4 -* -* @param int $attachment_id The attachment ID. -* @param int $post_id The post ID. -* @return bool True if attachment was connected. -*/ + * This function will connect an attacment (image etc) to the post + * Used to connect attachements uploaded directly to media that have not been attaced to a post + * + * @since 5.8.0 Added filter to prevent connection. + * @since 5.5.4 + * + * @param integer $attachment_id The attachment ID. + * @param integer $post_id The post ID. + * @return boolean True if attachment was connected. + */ function acf_connect_attachment_to_post($attachment_id = 0, $post_id = 0) { } /** -* acf_encrypt -* -* This function will encrypt a string using PHP -* https://bhoover.com/using-php-openssl_encrypt-openssl_decrypt-encrypt-decrypt-data/ -* -* @type function -* @date 27/2/17 -* @since 5.5.8 -* -* @param string $data -* @return string -*/ + * acf_encrypt + * + * This function will encrypt a string using PHP + * https://bhoover.com/using-php-openssl_encrypt-openssl_decrypt-encrypt-decrypt-data/ + * + * @since 5.5.8 + * + * @param string $data + * @return string + */ function acf_encrypt($data = '') { } /** -* acf_decrypt -* -* This function will decrypt an encrypted string using PHP -* https://bhoover.com/using-php-openssl_encrypt-openssl_decrypt-encrypt-decrypt-data/ -* -* @type function -* @date 27/2/17 -* @since 5.5.8 -* -* @param string $data -* @return string -*/ + * acf_decrypt + * + * This function will decrypt an encrypted string using PHP + * https://bhoover.com/using-php-openssl_encrypt-openssl_decrypt-encrypt-decrypt-data/ + * + * @since 5.5.8 + * + * @param string $data + * @return string + */ function acf_decrypt($data = '') { } /** - * acf_parse_markdown + * acf_parse_markdown * - * A very basic regex-based Markdown parser function based off [slimdown](https://gist.github.com/jbroadway/2836900). + * A very basic regex-based Markdown parser function based off [slimdown](https://gist.github.com/jbroadway/2836900). * - * @date 6/8/18 - * @since 5.7.2 + * @since 5.7.2 * - * @param string $text The string to parse. - * @return string + * @param string $text The string to parse. + * @return string */ function acf_parse_markdown($text = '') { } /** - * acf_get_sites + * acf_get_sites * - * Returns an array of sites for a network. + * Returns an array of sites for a network. * - * @date 29/08/2016 - * @since 5.4.0 + * @since 5.4.0 * - * @param void - * @return array + * @param void + * @return array */ function acf_get_sites() { } /** - * acf_convert_rules_to_groups + * acf_convert_rules_to_groups * - * Converts an array of rules from ACF4 to an array of groups for ACF5 + * Converts an array of rules from ACF4 to an array of groups for ACF5 * - * @date 25/8/18 - * @since 5.7.4 + * @since 5.7.4 * - * @param array $rules An array of rules. - * @param string $anyorall The anyorall setting used in ACF4. Defaults to 'any'. - * @return array + * @param array $rules An array of rules. + * @param string $anyorall The anyorall setting used in ACF4. Defaults to 'any'. + * @return array */ function acf_convert_rules_to_groups($rules, $anyorall = 'any') { } /** - * acf_register_ajax + * acf_register_ajax * - * Regsiters an ajax callback. + * Regsiters an ajax callback. * - * @date 5/10/18 - * @since 5.7.7 + * @since 5.7.7 * - * @param string $name The ajax action name. - * @param array $callback The callback function or array. - * @param bool $public Whether to allow access to non logged in users. - * @return void + * @param string $name The ajax action name. + * @param array $callback The callback function or array. + * @param boolean $public Whether to allow access to non logged in users. + * @return void */ function acf_register_ajax($name = '', $callback = \false, $public = \false) { } /** - * acf_str_camel_case + * acf_str_camel_case * - * Converts a string into camelCase. - * Thanks to https://stackoverflow.com/questions/31274782/convert-array-keys-from-underscore-case-to-camelcase-recursively + * Converts a string into camelCase. + * Thanks to https://stackoverflow.com/questions/31274782/convert-array-keys-from-underscore-case-to-camelcase-recursively * - * @date 24/10/18 - * @since 5.8.0 + * @since 5.8.0 * - * @param string $string The string ot convert. - * @return string + * @param string $string The string ot convert. + * @return string */ function acf_str_camel_case($string = '') { } /** - * acf_array_camel_case + * acf_array_camel_case * - * Converts all aray keys to camelCase. + * Converts all aray keys to camelCase. * - * @date 24/10/18 - * @since 5.8.0 + * @since 5.8.0 * - * @param array $array The array to convert. - * @return array + * @param array $array The array to convert. + * @return array */ function acf_array_camel_case($array = array()) { @@ -20872,10 +20628,9 @@ function acf_array_camel_case($array = array()) /** * Returns true if the current screen is using the block editor. * - * @date 13/12/18 * @since 5.8.0 * - * @return bool + * @return boolean */ function acf_is_block_editor() { @@ -20890,6 +20645,26 @@ function acf_is_block_editor() function acf_get_wp_reserved_terms() { } +/** + * Detect if we're on a multisite subsite. + * + * @since 6.2.4 + * + * @return boolean true if we're in a multisite install and not on the main site + */ +function acf_is_multisite_sub_site() +{ +} +/** + * Detect if we're on a multisite main site. + * + * @since 6.2.4 + * + * @return boolean true if we're in a multisite install and on the main site + */ +function acf_is_multisite_main_site() +{ +} /** * get_field() * @@ -22852,38 +22627,6 @@ function acf_save_post_revision($post_id = 0) function acf_get_post_latest_revision($post_id) { } -/** - * acf_updates - * - * The main function responsible for returning the one true acf_updates instance to functions everywhere. - * Use this function like you would a global variable, except without needing to declare the global. - * - * Example: - * - * @date 9/4/17 - * @since 5.5.12 - * - * @param void - * @return object - */ -function acf_updates() -{ -} -/** - * acf_register_plugin_update - * - * Alias of acf_updates()->add_plugin(). - * - * @type function - * @date 12/4/17 - * @since 5.5.10 - * - * @param array $plugin - * @return void - */ -function acf_register_plugin_update($plugin) -{ -} /** * acf_has_upgrade * @@ -23765,6 +23508,29 @@ function acf_set_after_rest_media_enqueue_reset_flag($response) function acf_reset_media_enqueue_after_rest($response) { } +/** + * The main function responsible for returning the acf_updates singleton. + * Use this function like you would a global variable, except without needing to declare the global. + * + * Example: + * + * @since 5.5.12 + * + * @return ACF_Updates The singleton instance of ACF_Updates. + */ +function acf_updates() +{ +} +/** + * Alias of acf_updates()->add_plugin(). + * + * @since 5.5.10 + * + * @param array $plugin Plugin data array. + */ +function acf_register_plugin_update($plugin) +{ +} /** * acf_options_page * @@ -23899,6 +23665,16 @@ function acf_get_home_url() function acf_license_ml_intercept($home_url, $url) { } +/** + * Is the updates page visible. + * + * @since 6.2.4 + * + * @return boolean true if the updates page should be hidden as we're not the primary multisite site. + */ +function acf_is_updates_page_visible() +{ +} /** * Returns the license key. * From c99bfb93ac61a38b4ebcc1b2bee4d98946d0df98 Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Sun, 4 Feb 2024 15:49:27 +0200 Subject: [PATCH 08/11] Generate stubs for ACF PRO 6.2.5 --- acf-pro-stubs.php | 408 +++++++++++++++++++++++++++++----------------- 1 file changed, 260 insertions(+), 148 deletions(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index c73fd58..0d75334 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.2.4'; + public $version = '6.2.5'; /** * The plugin settings array. * @@ -1420,13 +1420,11 @@ class ACF_Admin /** * Constructor. * - * @date 23/06/12 - * @since 5.0.0 + * @since 5.0.0 * - * @param void - * @return void + * @return void */ - function __construct() + public function __construct() { } /** @@ -1442,13 +1440,11 @@ public function admin_menu() /** * Enqueues global admin styling. * - * @date 28/09/13 * @since 5.0.0 * - * @param void - * @return void + * @return void */ - function admin_enqueue_scripts() + public function admin_enqueue_scripts() { } /** @@ -1496,6 +1492,27 @@ public function setup_help_tab() public function maybe_show_import_from_cptui_notice() { } + /** + * Notifies the user that fields rendered via shortcode or the_field() have + * had HTML removed/altered due to unsafe HTML being escaped. + * + * @since 6.2.5 + * + * @return void + * @phpstan-return void + */ + public function maybe_show_escaped_html_notice() + { + } + /** + * Dismisses the escaped unsafe HTML notice by clearing the stored log. + * + * @since 6.2.5 + * @phpstan-return void + */ + public function dismiss_escaped_html_notice() + { + } /** * Renders the admin navigation element. * @@ -4278,6 +4295,7 @@ class acf_field public $l10n = array(); public $public = \true; public $show_in_rest = \true; + public $supports = array('escaping_html' => \false); /** * __construct * @@ -5603,21 +5621,19 @@ function load_value($value, $post_id, $field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. + * @param boolean $escape_html Should the field return a HTML safe formatted value. * - * @return mixed $value the modified value + * @return mixed the modified value */ - function format_value($value, $post_id, $field) + public function format_value($value, $post_id, $field, $escape_html = \false) { } /** @@ -6432,19 +6448,16 @@ function render_field_settings($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template. * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. * - * @return mixed $value the modified value + * @return mixed the modified value */ function format_value($value, $post_id, $field) { @@ -8921,15 +8934,15 @@ function render_field_presentation_settings($field) * * @type filter * @since 3.6 - * @date 23/01/13 * - * @param mixed $value The value which was loaded from the database - * @param mixed $post_id The $post_id from which the value was loaded - * @param array $field The field array holding all the field options + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. + * @param boolean $escape_html Should the field return a HTML safe formatted value. * * @return mixed $value The modified value */ - function format_value($value, $post_id, $field) + public function format_value($value, $post_id, $field, $escape_html) { } } @@ -14036,21 +14049,19 @@ function load_value($value, $post_id, $field) { } /** - * format_value() + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. + * @param boolean $escape_html Should the field return a HTML safe formatted value. * - * @return mixed $value the modified value + * @return mixed $value The modified value. */ - function format_value($value, $post_id, $field) + public function format_value($value, $post_id, $field, $escape_html = \false) { } /** @@ -14405,21 +14416,19 @@ function load_value($value, $post_id, $field) { } /** - * format_value() + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. + * @param boolean $escape_html Should the field return a HTML safe formatted value. * - * @return mixed $value the modified value + * @return mixed $value The modified value. */ - function format_value($value, $post_id, $field) + public function format_value($value, $post_id, $field, $escape_html = \false) { } /** @@ -15042,19 +15051,19 @@ public function load_value($value, $post_id, $field) { } /** - * This filter is applied to the $value after it is loaded from the db, - * and before it is returned to the template. + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * + * @type filter * @since 3.6 - * @date 23/01/13 * - * @param mixed $value The value which was loaded from the database. - * @param mixed $post_id The $post_id from which the value was loaded. - * @param array $field The field array holding all the field options. + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. + * @param boolean $escape_html Should the field return a HTML safe formatted value. * * @return array $value The modified value. */ - function format_value($value, $post_id, $field) + public function format_value($value, $post_id, $field, $escape_html = \false) { } /** @@ -18936,7 +18945,7 @@ function acf_include($filename = '') * @since 5.6.5 * * @param string $field_name The name of the field. eg 'sub_heading'. - * @param mixed $post_id The post_id of which the value is saved against. + * @param mixed $post_id The post_id of which the value is saved against. * @return string The field key. */ function acf_get_reference($field_name, $post_id) @@ -18948,8 +18957,8 @@ function acf_get_reference($field_name, $post_id) * @date 28/09/13 * @since 5.0.0 * - * @param int|string $post_id The post id. - * @param array $field The field array. + * @param integer|string $post_id The post id. + * @param array $field The field array. * @return mixed */ function acf_get_value($post_id, $field) @@ -18960,15 +18969,15 @@ function acf_get_value($post_id, $field) * * Returns a formatted version of the provided value. * - * @date 28/09/13 * @since 5.0.0 * - * @param mixed $value The field value. - * @param int|string $post_id The post id. - * @param array $field The field array. - * @return mixed. + * @param mixed $value The field value. + * @param integer|string $post_id The post id. + * @param array $field The field array. + * @param boolean $escape_html Ask the field for a HTML safe version of it's output. + * @return mixed */ -function acf_format_value($value, $post_id, $field) +function acf_format_value($value, $post_id, $field, $escape_html = \false) { } /** @@ -18979,10 +18988,10 @@ function acf_format_value($value, $post_id, $field) * @date 28/09/13 * @since 5.0.0 * - * @param mixed $value The new value. + * @param mixed $value The new value. * @param int|string $post_id The post id. - * @param array $field The field array. - * @return bool. + * @param array $field The field array. + * @return boolean */ function acf_update_value($value, $post_id, $field) { @@ -19010,7 +19019,7 @@ function acf_update_values($values, $post_id) * @date 22/1/19 * @since 5.7.10 * - * @param int|string $post_id The post id. + * @param int|string $post_id The post id. * @param string $field_name The field name. * @return void */ @@ -19026,8 +19035,8 @@ function acf_flush_value_cache($post_id = 0, $field_name = '') * @since 5.0.0 * * @param int|string $post_id The post id. - * @param array $field The field array. - * @return bool. + * @param array $field The field array. + * @return boolean */ function acf_delete_value($post_id, $field) { @@ -19040,10 +19049,10 @@ function acf_delete_value($post_id, $field) * @date 28/09/13 * @since 5.0.0 * - * @param mixed $value The new value. + * @param mixed $value The new value. * @param int|string $post_id The post id. - * @param array $field The field array. - * @return bool. + * @param array $field The field array. + * @return boolean */ function acf_preview_value($value, $post_id, $field) { @@ -20666,51 +20675,146 @@ function acf_is_multisite_main_site() { } /** -* get_field() -* -* This function will return a custom field value for a specific field name/key + post_id. -* There is a 3rd parameter to turn on/off formating. This means that an image field will not use -* its 'return option' to format the value but return only what was saved in the database -* -* @type function -* @since 3.6 -* @date 29/01/13 -* -* @param string $selector the field name or key -* @param mixed $post_id the post_id of which the value is saved against -* @param boolean $format_value whether or not to format the value as described above -* @return mixed -*/ -function get_field($selector, $post_id = \false, $format_value = \true) + * get_field() + * + * This function will return a custom field value for a specific field name/key + post_id. + * There is a 3rd parameter to turn on/off formating. This means that an image field will not use + * its 'return option' to format the value but return only what was saved in the database + * + * @since 3.6 + * + * @param string $selector The field name or key. + * @param mixed $post_id The post_id of which the value is saved against. + * @param boolean $format_value Whether or not to format the value as described above. + * @param boolean $escape_html If we're formatting the value, should we also ask the field to escape it for unsafe html. + * This parameter will not guarantee the result is escaped, only if the field type supports it. + * @return mixed + */ +function get_field($selector, $post_id = \false, $format_value = \true, $escape_html = \false) { } /** * This function is the same as echo get_field(). * - * @since 1.0.3 - * @date 29/01/13 + * @since 1.0.3 + * @date 29/01/13 * - * @param string $selector The field name or key. - * @param mixed $post_id The post_id of which the value is saved against. - * @return void + * @param string $selector The field name or key. + * @param mixed $post_id The post_id of which the value is saved against. + * @param boolean $format_value Enable formatting of value. + * @return void + * @phpstan-return void */ function the_field($selector, $post_id = \false, $format_value = \true) { } +/** + * Logs instances of ACF successfully escaping unsafe HTML. + * + * @since 6.2.5 + * + * @param string $function The function that resulted in HTML being escaped. + * @param string $selector The selector (field key, name, etc.) passed to that function. + * @param array $field The field being queried when HTML was escaped. + * @param mixed $post_id The post ID the function was called on. + * @return void + * @phpstan-return void + */ +function _acf_log_escaped_html($function, $selector, $field, $post_id) +{ +} +/** + * Logs instances of where ACF will soon escape HTML using the_field. + * + * @since 6.2.5 + * + * @param string $function The function that resulted in HTML being escaped. + * @param string $selector The selector (field key, name, etc.) passed to that function. + * @param array $field The field being queried when HTML was escaped. + * @param mixed $post_id The post ID the function was called on. + * @return void + * @phpstan-return void + */ +function _acf_log_will_escape_html($function, $selector, $field, $post_id) +{ +} +/** + * Returns an array of instances where HTML was altered due to escaping in the_field or a shortcode. + * + * @since 6.2.5 + * + * @return array + */ +function _acf_get_escaped_html_log() +{ +} +/** + * Updates the array of instances where HTML was altered due to escaping in the_field or a shortcode. + * + * @since 6.2.5 + * + * @param array $escaped The array of instances. + * @return boolean True on success, or false on failure. + */ +function _acf_update_escaped_html_log($escaped = array()) +{ +} +/** + * Deletes the array of instances where HTML was altered due to escaping in the_field or a shortcode. + * + * @since 6.2.5 + * + * @return boolean True on success, or false on failure. + */ +function _acf_delete_escaped_html_log() +{ +} +/** + * Returns an array of instances where HTML will be escaped in the_field(). + * + * @since 6.2.5 + * + * @return array + */ +function _acf_get_will_escape_html_log() +{ +} +/** + * Updates the array of instances where HTML will be escaped in the_field(). + * + * @since 6.2.5 + * + * @param array $escaped The array of instances. + * @return boolean True on success, or false on failure. + */ +function _acf_update_will_escape_html_log($escaped = array()) +{ +} +/** + * Deletes the array of instances where HTML will be escaped in the_field(). + * + * @since 6.2.5 + * + * @return boolean True on success, or false on failure. + */ +function _acf_delete_will_escape_html_log() +{ +} /** * This function will return an array containing all the field data for a given field_name. * * @since 3.6 - * @date 3/02/13 * - * @param string $selector The field name or key. - * @param mixed $post_id The post_id of which the value is saved against. - * @param bool $format_value Whether to format the field value. - * @param bool $load_value Whether to load the field value. + * @param string $selector The field name or key. + * @param mixed $post_id The post_id of which the value is saved against. + * @param boolean $format_value Whether to format the field value. + * @param boolean $load_value Whether to load the field value. + * @param boolean $escape_html Should the field return a HTML safe formatted value if $format_value is true. + * This parameter will not guarantee the result is escaped, only if the field type supports it. * * @return array|false $field */ -function get_field_object($selector, $post_id = \false, $format_value = \true, $load_value = \true) +function get_field_object($selector, $post_id = \false, $format_value = \true, $load_value = \true, $escape_html = \false) { } /** @@ -20764,21 +20868,19 @@ function get_fields($post_id = \false, $format_value = \true) { } /** -* get_field_objects() -* -* This function will return an array containing all the custom field objects for a specific post_id. -* The function is not very elegant and wastes a lot of PHP memory / SQL queries if you are not using all the fields / values. -* -* @type function -* @since 3.6 -* @date 29/01/13 -* -* @param mixed $post_id the post_id of which the value is saved against -* @param boolean $format_value whether or not to format the field value -* @param boolean $load_value whether or not to load the field value -* @return array associative array where field name => field -*/ -function get_field_objects($post_id = \false, $format_value = \true, $load_value = \true) + * This function will return an array containing all the custom field objects for a specific post_id. + * The function is not very elegant and wastes a lot of PHP memory / SQL queries if you are not using all the fields / values. + * + * @since 3.6 + * + * @param mixed $post_id The post_id of which the value is saved against. + * @param boolean $format_value Whether or not to format the field value. + * @param boolean $load_value Whether or not to load the field value. + * @param boolean $escape_html Should the field return a HTML safe formatted value if $format_value is true. + * This parameter will not guarantee the result is escaped, only if the field type supports it. + * @return array associative array where field name => field + */ +function get_field_objects($post_id = \false, $format_value = \true, $load_value = \true, $escape_html = \false) { } /** @@ -20906,33 +21008,30 @@ function get_sub_field($selector = '', $format_value = \true) { } /** -* the_sub_field() -* -* This function is the same as echo get_sub_field -* -* @type function -* @since 1.0.3 -* @date 29/01/13 -* -* @param string $field_name the field name -* @return void -*/ + * This function is the same as echo get_sub_field + * + * @since 1.0.3 + * + * @param string $field_name The field name. + * @param boolean $format_value Format the value before output. + * @phpstan-return void + */ function the_sub_field($field_name, $format_value = \true) { } /** -* get_sub_field_object() -* -* This function is used inside a 'has_sub_field' while loop to return a sub field object -* -* @type function -* @since 3.5.8.1 -* @date 29/01/13 -* -* @param string $child_name the field name -* @return array -*/ -function get_sub_field_object($selector, $format_value = \true, $load_value = \true) + * This function is used inside a 'has_sub_field' while loop to return a sub field object + * + * @since 3.5.8.1 + * + * @param string $selector The field name or key. + * @param boolean $format_value Whether to format the field value. + * @param boolean $load_value Whether to load the field value. + * @param boolean $escape_html Should the field return a HTML safe formatted value. + * This parameter will not guarantee the result is escaped, only if the field type supports it. + * @return mixed + */ +function get_sub_field_object($selector, $format_value = \true, $load_value = \true, $escape_html = \false) { } /** @@ -21668,6 +21767,19 @@ function acf_get_field_type_prop($name = '', $prop = '') function acf_get_field_type_label($name = '') { } +/** + * Returns the value of a field type "supports" property. + * + * @since 6.2.5 + * + * @param string $name The name of the field type. + * @param string $prop The name of the supports property. + * + * @return mixed The value of the supports property which may be false, or false on failure. + */ +function acf_field_type_supports($name = '', $prop = '') +{ +} /** * acf_field_type_exists (deprecated) * From a28b23c89a2628b325d3910632378e05c7407bfc Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Mon, 11 Mar 2024 11:18:38 +0200 Subject: [PATCH 09/11] Generate stubs for ACF PRO 6.2.6 --- acf-pro-stubs.php | 1013 +++++++++++++++++++++++---------------------- 1 file changed, 525 insertions(+), 488 deletions(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index 0d75334..475a2ad 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.2.5'; + public $version = '6.2.6'; /** * The plugin settings array. * @@ -127,7 +127,7 @@ public function posts_where($where, $wp_query) * @date 3/5/17 * @since 5.5.13 * - * @param string $name The constant name. + * @param string $name The constant name. * @param mixed $value The constant value. * @return void */ @@ -164,7 +164,7 @@ public function get_setting($name) * @date 28/09/13 * @since 5.0.0 * - * @param string $name The setting name. + * @param string $name The setting name. * @param mixed $value The setting value. * @return true */ @@ -189,7 +189,7 @@ public function get_data($name) * @date 28/09/13 * @since 5.0.0 * - * @param string $name The data name. + * @param string $name The data name. * @param mixed $value The data value. * @return void */ @@ -227,7 +227,7 @@ public function new_instance($class) * @since 5.9.0 * * @param string $key Key name. - * @return bool + * @return boolean */ public function __isset($key) { @@ -244,6 +244,14 @@ public function __isset($key) public function __get($key) { } + /** + * Plugin Activation Hook + * + * @since 6.2.6 + */ + public function acf_plugin_activated() + { + } } class ACF_Admin_Internal_Post_Type_List { @@ -4295,147 +4303,124 @@ class acf_field public $l10n = array(); public $public = \true; public $show_in_rest = \true; - public $supports = array('escaping_html' => \false); + public $supports = array( + 'escaping_html' => \false, + // Set true when a field handles its own HTML escaping in format_value + 'required' => \true, + ); /** - * __construct - * - * This function will initialize the field type + * Initializes the `acf_field` class. To initialize a field type that is + * extending this class, use the `initialize()` method in the child class instead. * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @since 5.0.0 * - * @param void - * @return void + * @return void */ - function __construct() + public function __construct() { } /** - * initialize + * Initializes the field type. Overridden in child classes. * - * This function will initialize the field type - * - * @type function - * @date 27/6/17 - * @since 5.6.0 + * @since 5.6.0 * - * @param void - * @return void + * @return void */ - function initialize() + public function initialize() { } /** - * add_filter - * - * This function checks if the function is_callable before adding the filter + * Checks a function `is_callable()` before adding the filter, since + * classes that extend `acf_field` might not implement all filters. * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @since 5.0.0 * - * @param string $tag - * @param string $function_to_add - * @param int $priority - * @param int $accepted_args - * @return void + * @param string $tag The name of the filter to add the callback to. + * @param string $function_to_add The callback to be run when the filter is applied. + * @param integer $priority The priority to add the filter on. + * @param integer $accepted_args The number of args to pass to the function. + * @return void + * @phpstan-return void */ - function add_filter($tag = '', $function_to_add = '', $priority = 10, $accepted_args = 1) + public function add_filter($tag = '', $function_to_add = '', $priority = 10, $accepted_args = 1) { } /** - * add_field_filter - * - * This function will add a field type specific filter + * Adds a filter specific to the current field type. * - * @type function - * @date 29/09/2016 - * @since 5.4.0 + * @since 5.4.0 * - * @param string $tag - * @param string $function_to_add - * @param int $priority - * @param int $accepted_args - * @return void + * @param string $tag The name of the filter to add the callback to. + * @param string $function_to_add The callback to be run when the filter is applied. + * @param integer $priority The priority to add the filter on. + * @param integer $accepted_args The number of args to pass to the function. + * @return void */ - function add_field_filter($tag = '', $function_to_add = '', $priority = 10, $accepted_args = 1) + public function add_field_filter($tag = '', $function_to_add = '', $priority = 10, $accepted_args = 1) { } /** - * add_action - * - * This function checks if the function is_callable before adding the action + * Checks a function `is_callable()` before adding the action, since + * classes that extend `acf_field` might not implement all actions. * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @since 5.0.0 * - * @param string $tag - * @param string $function_to_add - * @param int $priority - * @param int $accepted_args - * @return void + * @param string $tag The name of the action to add the callback to. + * @param string $function_to_add The callback to be run when the action is ran. + * @param integer $priority The priority to add the action on. + * @param integer $accepted_args The number of args to pass to the function. + * @return void + * @phpstan-return void */ - function add_action($tag = '', $function_to_add = '', $priority = 10, $accepted_args = 1) + public function add_action($tag = '', $function_to_add = '', $priority = 10, $accepted_args = 1) { } /** - * add_field_action - * - * This function will add a field type specific filter + * Adds an action specific to the current field type. * - * @type function - * @date 29/09/2016 - * @since 5.4.0 + * @since 5.4.0 * - * @param string $tag - * @param string $function_to_add - * @param int $priority - * @param int $accepted_args - * @return void + * @param string $tag The name of the action to add the callback to. + * @param string $function_to_add The callback to be run when the action is ran. + * @param integer $priority The priority to add the action on. + * @param integer $accepted_args The number of args to pass to the function. + * @return void */ - function add_field_action($tag = '', $function_to_add = '', $priority = 10, $accepted_args = 1) + public function add_field_action($tag = '', $function_to_add = '', $priority = 10, $accepted_args = 1) { } /** - * validate_field + * Appends default settings to a field. + * Runs on `acf/validate_field/type={$this->name}`. * - * This function will append default settings to a field - * - * @type filter ("acf/validate_field/type={$this->name}") - * @since 3.6 - * @date 23/01/13 + * @since 3.6 * - * @param array $field - * @return array $field + * @param array $field The field array. + * @return array $field */ - function validate_field($field) + public function validate_field($field) { } /** - * admin_l10n - * - * This function will append l10n text translations to an array which is later passed to JS + * Append l10n text translations to an array which is later passed to JS. + * Runs on `acf/input/admin_l10n`. * - * @type filter ("acf/input/admin_l10n") - * @since 3.6 - * @date 23/01/13 + * @since 3.6 * - * @param array $l10n - * @return array $l10n + * @param array $l10n + * @return array $l10n */ - function input_admin_l10n($l10n) + public function input_admin_l10n($l10n) { } /** * Add additional validation for fields being updated via the REST API. * - * @param bool $valid - * @param mixed $value - * @param array $field + * @param boolean $valid + * @param mixed $value + * @param array $field * - * @return bool|WP_Error + * @return boolean|WP */ public function validate_rest_value($valid, $value, $field) { @@ -4469,9 +4454,9 @@ public function get_rest_schema(array $field) * ], * ] * - * @param mixed $value The raw (unformatted) field value. - * @param string|int $post_id - * @param array $field + * @param mixed $value The raw (unformatted) field value. + * @param string|integer $post_id + * @param array $field * @return array */ public function get_rest_links($value, $post_id, array $field) @@ -4480,14 +4465,26 @@ public function get_rest_links($value, $post_id, array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) { } + /** + * Renders the "Required" setting on the field type "Validation" settings tab. + * + * @since 6.2.5 + * + * @param array $field The field type being rendered. + * @return void + * @phpstan-return void + */ + public function render_required_setting($field) + { + } } class acf_field__accordion extends \acf_field { @@ -8496,50 +8493,38 @@ public function format_value_for_rest($value, $post_id, array $field) { } } +/** + * The URL field class. + */ class acf_field_url extends \acf_field { /** - * initialize - * - * This function will setup the field type data - * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * This function will setup the field type data * - * @param void - * @return void + * @since 5.0.0 */ - function initialize() + public function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @since 3.6 * - * @type action - * @since 3.6 - * @date 23/01/13 + * @param array $field An array holding all the field's data. */ - function render_field($field) + public function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @since 3.6 * - * @param $field - an array holding all the field's data + * @param array $field An array holding all the field's data. */ - function render_field_settings($field) + public function render_field_settings($field) { } /** @@ -8550,28 +8535,44 @@ function render_field_settings($field) * @param array $field The field settings array. * @return void */ - function render_field_presentation_settings($field) + public function render_field_presentation_settings($field) { } /** - * validate_value + * Validate the fields value is correctly formatted as a URL * - * description + * @since 5.0.0 * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @param mixed $valid The current validity of the field value. Boolean true if valid, a validation error message string if not. + * @param string $value The value of the field. + * @param array $field Field object array. + * @param string $input The form input name for this field. * - * @param int $post_id - * @return int $post_id + * @return mixed Boolean true if valid, a validation error message string if not. */ - function validate_value($valid, $value, $field, $input) + public function validate_value($valid, $value, $field, $input) + { + } + /** + * This filter is applied to the $value after it is loaded from the db, and before it is returned to the template + * + * @since 6.2.6 + * + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. + * @param boolean $escape_html Should the field return a HTML safe formatted value. + * + * @return mixed $value The modified value + */ + public function format_value($value, $post_id, $field, $escape_html) { } /** * Return the schema array for the REST API. * - * @param array $field + * @param array $field The field object. + * * @return array */ public function get_rest_schema(array $field) @@ -9799,19 +9800,15 @@ function allow_save_post($post) { } /** - * save_post - * - * Triggers during the 'save_post' action to save the $_POST data. + * Triggers during the 'save_post' action to save the $_POST data. * - * @type function - * @date 23/06/12 - * @since 1.0.0 + * @since 1.0.0 * - * @param int $post_id The post ID - * @param WP_POST $post the post object. - * @return int + * @param integer $post_id The post ID. + * @param WP_Post $post The post object. + * @return integer */ - function save_post($post_id, $post) + public function save_post($post_id, $post) { } } @@ -12574,17 +12571,61 @@ class acf_revisions // vars var $cache = array(); /** - * __construct + * Constructs the acf_revisions class. * - * A good place to add actions / filters + * @return void + */ + public function __construct() + { + } + /** + * Registers any ACF meta that should be sent the REST/Gutenberg request. + * For now, this is just our "_acf_changed" key that we use to detect if ACF fields have changed. * - * @type function - * @date 11/08/13 + * @since 6.2.6 * - * @param void - * @return void + * @return void */ - function __construct() + public function register_meta() + { + } + /** + * Lets WordPress know which meta keys to include in revisions. + * For now, this is just our "_acf_changed" key, as we still handle revisions ourselves. + * + * @since 6.2.6 + * + * @param array $keys The meta keys that should be revisioned. + * @return array + */ + public function wp_post_revision_meta_keys($keys) + { + } + /** + * Helps WordPress determine if fields have changed, and if in a legacy + * metabox AJAX request, copies the metadata to the new revision. + * + * @since 6.2.6 + * + * @param boolean $post_has_changed True if the post has changed, false if not. + * @param WP_Post $last_revision The WP_Post object for the latest revision. + * @param WP_Post $post The WP_Post object for the parent post. + * @return boolean + */ + public function check_acf_fields_have_changed($post_has_changed, $last_revision, $post) + { + } + /** + * Copies ACF field data to the latest revision. + * + * @since 6.2.6 + * + * @param integer $revision_id The ID of the revision that was just created. + * @param integer $post_id The ID of the post being updated. + * @return void + * @phpstan-return void + */ + public function maybe_save_revision($revision_id, $post_id) { } /** @@ -15734,7 +15775,6 @@ class acf_pro_updates /** * Initialize filters, action, variables and includes * - * @date 23/06/12 * @since 5.0.0 */ public function __construct() @@ -15752,7 +15792,6 @@ public function init() /** * Displays an update message for plugin list screens. * - * @date 14/06/2016 * @since 5.3.8 * * @param array $plugin_data An array of plugin metadata. @@ -18965,16 +19004,15 @@ function acf_get_value($post_id, $field) { } /** - * acf_format_value - * * Returns a formatted version of the provided value. * * @since 5.0.0 * - * @param mixed $value The field value. - * @param integer|string $post_id The post id. - * @param array $field The field array. + * @param mixed $value The field value. + * @param integer|string $post_id The post id. + * @param array $field The field array. * @param boolean $escape_html Ask the field for a HTML safe version of it's output. + * * @return mixed */ function acf_format_value($value, $post_id, $field, $escape_html = \false) @@ -20675,34 +20713,32 @@ function acf_is_multisite_main_site() { } /** - * get_field() - * - * This function will return a custom field value for a specific field name/key + post_id. - * There is a 3rd parameter to turn on/off formating. This means that an image field will not use - * its 'return option' to format the value but return only what was saved in the database + * This function will return a custom field value for a specific field name/key + post_id. + * There is a 3rd parameter to turn on/off formating. This means that an image field will not use + * its 'return option' to format the value but return only what was saved in the database * * @since 3.6 * * @param string $selector The field name or key. * @param mixed $post_id The post_id of which the value is saved against. * @param boolean $format_value Whether or not to format the value as described above. - * @param boolean $escape_html If we're formatting the value, should we also ask the field to escape it for unsafe html. - * This parameter will not guarantee the result is escaped, only if the field type supports it. - * @return mixed + * @param boolean $escape_html If we're formatting the value, make sure it's also HTML safe. + * + * @return mixed */ function get_field($selector, $post_id = \false, $format_value = \true, $escape_html = \false) { } /** - * This function is the same as echo get_field(). + * This function is the same as echo get_field(), but will soon escape the value by default. * * @since 1.0.3 - * @date 29/01/13 * * @param string $selector The field name or key. * @param mixed $post_id The post_id of which the value is saved against. * @param boolean $format_value Enable formatting of value. - * @return void + * + * @return void * @phpstan-return void */ function the_field($selector, $post_id = \false, $format_value = \true) @@ -20810,7 +20846,6 @@ function _acf_delete_will_escape_html_log() * @param boolean $format_value Whether to format the field value. * @param boolean $load_value Whether to load the field value. * @param boolean $escape_html Should the field return a HTML safe formatted value if $format_value is true. - * This parameter will not guarantee the result is escaped, only if the field type supports it. * * @return array|false $field */ @@ -20818,53 +20853,44 @@ function get_field_object($selector, $post_id = \false, $format_value = \true, $ { } /** -* acf_get_object_field -* -* This function will return a field for the given selector. -* It will also review the field_reference to ensure the correct field is returned which makes it useful for the template API -* -* @type function -* @date 4/08/2015 -* @since 5.2.3 -* -* @param mixed $selector identifier of field. Can be an ID, key, name or post object -* @param mixed $post_id the post_id of which the value is saved against -* @param boolean $strict if true, return a field only when a field key is found. -* @return array $field -*/ + * This function will return a field for the given selector. + * It will also review the field_reference to ensure the correct field is returned which makes it useful for the template API + * + * @since 5.2.3 + * + * @param mixed $selector identifier of field. Can be an ID, key, name or post object + * @param mixed $post_id the post_id of which the value is saved against + * @param boolean $strict if true, return a field only when a field key is found. + * + * @return array $field + */ function acf_maybe_get_field($selector, $post_id = \false, $strict = \true) { } /** -* acf_maybe_get_sub_field -* -* This function will attempt to find a sub field -* -* @type function -* @date 3/10/2016 -* @since 5.4.0 -* -* @param int $post_id -* @return int $post_id -*/ + * This function will attempt to find a sub field + * + * @since 5.4.0 + * + * @param int $post_id + * @return int $post_id + */ function acf_maybe_get_sub_field($selectors, $post_id = \false, $strict = \true) { } /** -* get_fields() -* -* This function will return an array containing all the custom field values for a specific post_id. -* The function is not very elegant and wastes a lot of PHP memory / SQL queries if you are not using all the values. -* -* @type function -* @since 3.6 -* @date 29/01/13 -* -* @param mixed $post_id the post_id of which the value is saved against -* @param boolean $format_value whether or not to format the field value -* @return array associative array where field name => field value -*/ -function get_fields($post_id = \false, $format_value = \true) + * This function will return an array containing all the custom field values for a specific post_id. + * The function is not very elegant and wastes a lot of PHP memory / SQL queries if you are not using all the values. + * + * @since 3.6 + * + * @param mixed $post_id The post_id of which the value is saved against. + * @param boolean $format_value Whether or not to format the field value. + * @param boolean $escape_html Should the field return a HTML safe formatted value if $format_value is true. + * + * @return array associative array where field name => field value + */ +function get_fields($post_id = \false, $format_value = \true, $escape_html = \false) { } /** @@ -20877,24 +20903,21 @@ function get_fields($post_id = \false, $format_value = \true) * @param boolean $format_value Whether or not to format the field value. * @param boolean $load_value Whether or not to load the field value. * @param boolean $escape_html Should the field return a HTML safe formatted value if $format_value is true. - * This parameter will not guarantee the result is escaped, only if the field type supports it. + * * @return array associative array where field name => field */ function get_field_objects($post_id = \false, $format_value = \true, $load_value = \true, $escape_html = \false) { } /** - * have_rows - * * Checks if a field (such as Repeater or Flexible Content) has any rows of data to loop over. * This function is intended to be used in conjunction with the_row() to step through available values. * - * @date 2/09/13 * @since 4.3.0 * * @param string $selector The field name or field key. - * @param mixed $post_id The post ID where the value is saved. Defaults to the current post. - * @return bool + * @param mixed $post_id The post ID where the value is saved. Defaults to the current post. + * @return boolean * @phpstan-impure * @phpstan-return bool */ @@ -20902,17 +20925,13 @@ function have_rows($selector, $post_id = \false) { } /** -* the_row -* -* This function will progress the global repeater or flexible content value 1 row -* -* @type function -* @date 2/09/13 -* @since 4.3.0 -* -* @param void -* @return array the current row data -*/ + * This function will progress the global repeater or flexible content value 1 row + * + * @since 4.3.0 + * + * @param void + * @return array the current row data + */ function the_row($format = \false) { } @@ -20926,85 +20945,71 @@ function the_row_index() { } /** -* get_row_sub_field -* -* This function is used inside a 'has_sub_field' while loop to return a sub field object -* -* @type function -* @date 16/05/2016 -* @since 5.3.8 -* -* @param string $selector -* @return array -*/ + * This function is used inside a 'has_sub_field' while loop to return a sub field object + * + * @since 5.3.8 + * + * @param string $selector + * @return array + */ function get_row_sub_field($selector) { } /** -* get_row_sub_value -* -* This function is used inside a 'has_sub_field' while loop to return a sub field value -* -* @type function -* @date 16/05/2016 -* @since 5.3.8 -* -* @param string $selector -* @return mixed -*/ + * This function is used inside a 'has_sub_field' while loop to return a sub field value + * + * @since 5.3.8 + * + * @param string $selector + * @return mixed + */ function get_row_sub_value($selector) { } /** -* reset_rows -* -* This function will find the current loop and unset it from the global array. -* To bo used when loop finishes or a break is used -* -* @type function -* @date 26/10/13 -* @since 5.0.0 -* -* @param boolean $hard_reset completely wipe the global variable, or just unset the active row -* @return boolean -*/ + * This function will find the current loop and unset it from the global array. + * To be used when loop finishes or a break is used + * + * @since 5.0.0 + * + * @param boolean $hard_reset completely wipe the global variable, or just unset the active row + * @return boolean + */ function reset_rows() { } /** -* has_sub_field() -* -* This function is used inside a while loop to return either true or false (loop again or stop). -* When using a repeater or flexible content field, it will loop through the rows until -* there are none left or a break is detected -* -* @type function -* @since 1.0.3 -* @date 29/01/13 -* -* @param string $field_name the field name -* @param mixed $post_id the post_id of which the value is saved against -* @return boolean -*/ + * This function is used inside a while loop to return either true or false (loop again or stop). + * When using a repeater or flexible content field, it will loop through the rows until + * there are none left or a break is detected + * + * @since 1.0.3 + * + * @param string $field_name the field name + * @param mixed $post_id the post_id of which the value is saved against + * @return boolean + */ function has_sub_field($field_name, $post_id = \false) { } +/** + * Alias of has_sub_field + */ function has_sub_fields($field_name, $post_id = \false) { } /** -* get_sub_field() -* -* This function is used inside a 'has_sub_field' while loop to return a sub field value -* -* @type function -* @since 1.0.3 -* @date 29/01/13 -* -* @param string $field_name the field name -* @return mixed -*/ -function get_sub_field($selector = '', $format_value = \true) + * This function is used inside a 'has_sub_field' while loop to return a sub field value + * + * @since 1.0.3 + * + * @param string $selector The field name or key. + * @param boolean $format_value Whether or not to format the value as described above. + * @param boolean $escape_html If we're formatting the value, make sure it's also HTML safe. + * + * @return mixed + */ +function get_sub_field($selector = '', $format_value = \true, $escape_html = \false) { } /** @@ -21028,24 +21033,19 @@ function the_sub_field($field_name, $format_value = \true) * @param boolean $format_value Whether to format the field value. * @param boolean $load_value Whether to load the field value. * @param boolean $escape_html Should the field return a HTML safe formatted value. - * This parameter will not guarantee the result is escaped, only if the field type supports it. + * * @return mixed */ function get_sub_field_object($selector, $format_value = \true, $load_value = \true, $escape_html = \false) { } /** -* get_row_layout() -* -* This function will return a string representation of the current row layout within a 'have_rows' loop -* -* @type function -* @since 3.0.6 -* @date 29/01/13 -* -* @param void -* @return string -*/ + * This function will return a string representation of the current row layout within a 'have_rows' loop + * + * @since 3.0.6 + * + * @return mixed + */ function get_row_layout() { } @@ -21054,7 +21054,6 @@ function get_row_layout() * eg. [acf field="heading" post_id="123" format_value="1"] * * @since 1.1.1 - * @date 29/01/13 * * @param array $atts The shortcode attributes. * @@ -21064,187 +21063,148 @@ function acf_shortcode($atts) { } /** -* update_field() -* -* This function will update a value in the database -* -* @type function -* @since 3.1.9 -* @date 29/01/13 -* -* @param string $selector the field name or key -* @param mixed $value the value to save in the database -* @param mixed $post_id the post_id of which the value is saved against -* @return boolean -*/ + * This function will update a value in the database + * + * @since 3.1.9 + * + * @param string $selector The field name or key. + * @param mixed $value The value to save in the database. + * @param mixed $post_id The post_id of which the value is saved against. + * + * @return boolean + */ function update_field($selector, $value, $post_id = \false) { } /** -* update_sub_field -* -* This function will update a value of a sub field in the database -* -* @type function -* @date 2/04/2014 -* @since 5.0.0 -* -* @param mixed $selector the sub field name or key, or an array of ancestors -* @param mixed $value the value to save in the database -* @param mixed $post_id the post_id of which the value is saved against -* @return boolean -*/ + * This function will update a value of a sub field in the database + * + * @since 5.0.0 + * + * @param mixed $selector the sub field name or key, or an array of ancestors + * @param mixed $value the value to save in the database + * @param mixed $post_id the post_id of which the value is saved against + * + * @return boolean + */ function update_sub_field($selector, $value, $post_id = \false) { } /** -* delete_field() -* -* This function will remove a value from the database -* -* @type function -* @since 3.1.9 -* @date 29/01/13 -* -* @param string $selector the field name or key -* @param mixed $post_id the post_id of which the value is saved against -* @return boolean -*/ + * This function will remove a value from the database + * + * @since 3.1.9 + * + * @param string $selector the field name or key + * @param mixed $post_id the post_id of which the value is saved against + * + * @return boolean + */ function delete_field($selector, $post_id = \false) { } /** -* delete_sub_field -* -* This function will delete a value of a sub field in the database -* -* @type function -* @date 2/04/2014 -* @since 5.0.0 -* -* @param mixed $selector the sub field name or key, or an array of ancestors -* @param mixed $value the value to save in the database -* @param mixed $post_id the post_id of which the value is saved against -* @return boolean -*/ + * This function will delete a value of a sub field in the database + * + * @since 5.0.0 + * + * @param mixed $selector the sub field name or key, or an array of ancestors + * @param mixed $value the value to save in the database + * @param mixed $post_id the post_id of which the value is saved against + * @return boolean + */ function delete_sub_field($selector, $post_id = \false) { } /** -* add_row -* -* This function will add a row of data to a field -* -* @type function -* @date 16/10/2015 -* @since 5.2.3 -* -* @param string $selector -* @param array $row -* @param mixed $post_id -* @return boolean -*/ + * This function will add a row of data to a field + * + * @since 5.2.3 + * + * @param string $selector + * @param array $row + * @param mixed $post_id + * @return boolean + */ function add_row($selector, $row = \false, $post_id = \false) { } /** -* add_sub_row -* -* This function will add a row of data to a field -* -* @type function -* @date 16/10/2015 -* @since 5.2.3 -* -* @param string $selector -* @param array $row -* @param mixed $post_id -* @return boolean -*/ + * This function will add a row of data to a field + * + * @since 5.2.3 + * + * @param string $selector + * @param array $row + * @param mixed $post_id + * @return boolean + */ function add_sub_row($selector, $row = \false, $post_id = \false) { } /** -* update_row -* -* This function will update a row of data to a field -* -* @type function -* @date 19/10/2015 -* @since 5.2.3 -* -* @param string $selector -* @param int $i -* @param array $row -* @param mixed $post_id -* @return boolean -*/ + * This function will update a row of data to a field + * + * @since 5.2.3 + * + * @param string $selector + * @param int $i + * @param array $row + * @param mixed $post_id + * @return boolean + */ function update_row($selector, $i = 1, $row = \false, $post_id = \false) { } /** -* update_sub_row -* -* This function will add a row of data to a field -* -* @type function -* @date 16/10/2015 -* @since 5.2.3 -* -* @param string $selector -* @param array $row -* @param mixed $post_id -* @return boolean -*/ + * This function will add a row of data to a field + * + * @since 5.2.3 + * + * @param string $selector + * @param array $row + * @param mixed $post_id + * @return boolean + */ function update_sub_row($selector, $i = 1, $row = \false, $post_id = \false) { } /** -* delete_row -* -* This function will delete a row of data from a field -* -* @type function -* @date 19/10/2015 -* @since 5.2.3 -* -* @param string $selector -* @param int $i -* @param mixed $post_id -* @return boolean -*/ + * This function will delete a row of data from a field + * + * @since 5.2.3 + * + * @param string $selector + * @param int $i + * @param mixed $post_id + * @return boolean + */ function delete_row($selector, $i = 1, $post_id = \false) { } /** -* delete_sub_row -* -* This function will add a row of data to a field -* -* @type function -* @date 16/10/2015 -* @since 5.2.3 -* -* @param string $selector -* @param array $row -* @param mixed $post_id -* @return boolean -*/ + * This function will add a row of data to a field + * + * @since 5.2.3 + * + * @param string $selector + * @param array $row + * @param mixed $post_id + * @return boolean + */ function delete_sub_row($selector, $i = 1, $post_id = \false) { } /** -* Depreceated Functions -* -* These functions are outdated -* -* @type function -* @date 4/03/2014 -* @since 1.0.0 -* -* @param void -* @return void -*/ + * Depreceated Functions + * + * These functions are outdated + * + * @since 1.0.0 + * + * @param void + * @return void + */ function create_field($field) { } @@ -21772,12 +21732,13 @@ function acf_get_field_type_label($name = '') * * @since 6.2.5 * - * @param string $name The name of the field type. - * @param string $prop The name of the supports property. + * @param string $name The name of the field type. + * @param string $prop The name of the supports property. + * @param mixed $default The default value if the property is not set. * - * @return mixed The value of the supports property which may be false, or false on failure. + * @return mixed The value of the supports property which may be false, or $default on failure. */ -function acf_field_type_supports($name = '', $prop = '') +function acf_field_type_supports($name = '', $prop = '', $default = \false) { } /** @@ -23242,7 +23203,7 @@ function acf_import_ui_options_page(array $ui_options_page) /** * Renders the license status table. * - * @since 6.? + * @since 6.2.3 * * @param array $status The current license status array. * @return void @@ -23254,7 +23215,7 @@ function acf_pro_render_license_status_table($status) /** * Renders the "Manage License"/"Renew Subscription" button. * - * @since 6.? + * @since 6.2.3 * * @param array $status The current license status. * @return void @@ -23690,7 +23651,6 @@ function register_options_page($page = '') * Check if a license is defined in wp-config.php and requires activation. * Also checks if the license key has been changed and reactivates. * - * @date 29/09/2021 * @since 5.11.0 */ function acf_pro_check_defined_license() @@ -23708,26 +23668,24 @@ function acf_pro_get_translated_connect_message($text) { } /** - * Set the automatic activation failure transient + * Set the automatic activation failure transient * - * @date 11/10/2021 - * @since 5.11.0 + * @since 5.11.0 * - * @param string $error_text string containing the error text message. - * @param string $license_key the license key that was used during the failed activation. + * @param string $error_text string containing the error text message. + * @param string $license_key the license key that was used during the failed activation. * - * @return void + * @return void */ function acf_pro_set_activation_failure_transient($error_text, $license_key) { } /** - * Get the automatic activation failure transient + * Get the automatic activation failure transient * - * @date 11/10/2021 - * @since 5.11.0 + * @since 5.11.0 * - * @return array|false Activation failure transient array, or false if it's not set. + * @return array|false Activation failure transient array, or false if it's not set. */ function acf_pro_get_activation_failure_transient() { @@ -23735,7 +23693,6 @@ function acf_pro_get_activation_failure_transient() /** * Display the stored activation error * - * @date 11/10/2021 * @since 5.11.0 * @phpstan-return void */ @@ -23743,13 +23700,11 @@ function acf_pro_display_activation_error($screen) { } /** - * This function will return the license + * This function will return the license * - * @type function - * @date 20/09/2016 - * @since 5.4.0 + * @since 5.4.0 * - * @return $license Activated license array + * @return array|boolean $license The ACF PRO license array on success, or false on failure. */ function acf_pro_get_license() { @@ -23770,7 +23725,7 @@ function acf_get_home_url() * @since 6.0.1 * * @param string $home_url the multilingual plugin converted home URL. - * @param string $url the original home URL. + * @param string $url the original home URL. * * @return string $url */ @@ -23793,20 +23748,18 @@ function acf_is_updates_page_visible() * @since 5.4.0 * * @param boolean $skip_url_check Skip the check of the current site url. - * @return string|bool License key on success, or false on failure. + * @return string|boolean License key on success, or false on failure. */ function acf_pro_get_license_key($skip_url_check = \false) { } /** - * This function will update the DB license + * This function will update the DB license * - * @type function - * @date 20/09/2016 - * @since 5.4.0 + * @since 5.4.0 * - * @param string $key The license key - * @return bool The result of the update_option call + * @param string $key The license key. + * @return boolean The result of the update_option call */ function acf_pro_update_license($key = '') { @@ -23814,7 +23767,7 @@ function acf_pro_update_license($key = '') /** * Get count of registered ACF Blocks * - * @return int + * @return integer */ function acf_pro_get_registered_block_count() { @@ -23825,9 +23778,9 @@ function acf_pro_get_registered_block_count() * * @since 5.11.0 * - * @param string $license_key License key to activate. - * @param boolean $silent Return errors rather than displaying them. - * @param boolean $automatic True if this activation is happening automatically. + * @param string $license_key License key to activate. + * @param boolean $silent Return errors rather than displaying them. + * @param boolean $automatic True if this activation is happening automatically. * @return mixed $response A wp-error instance, or an array with a boolean success key, and string message key. */ function acf_pro_activate_license($license_key, $silent = \false, $automatic = \false) @@ -23837,10 +23790,9 @@ function acf_pro_activate_license($license_key, $silent = \false, $automatic = \ * Deactivates the registered license key. * Formally ACF_Admin_Updates::deactivate_pro_licence since 5.0.0 * - * @date 30/09/2021 * @since 5.11.0 * - * @param bool $silent Return errors rather than displaying them + * @param boolean $silent Return errors rather than displaying them * @return mixed $response A wp-error instance, or an array with a boolean success key, and string message key */ function acf_pro_deactivate_license($silent = \false) @@ -23849,7 +23801,6 @@ function acf_pro_deactivate_license($silent = \false) /** * Adds an admin notice using the provided WP_Error. * - * @date 14/1/19 * @since 5.7.10 * * @param WP_Error $wp_error The error to display. @@ -23863,7 +23814,7 @@ function display_wp_activation_error($wp_error) * * @since 6.2.2 * - * @param bool $force_check If we should force a call to the API. + * @param boolean $force_check If we should force a call to the API. * @return array */ function acf_pro_get_license_status($force_check = \false) @@ -23886,7 +23837,7 @@ function acf_pro_parse_license_status($status = array()) * @since 6.2.2 * * @param array $status The current license status. - * @return bool True if the value was set, false otherwise. + * @return boolean True if the value was set, false otherwise. */ function acf_pro_update_license_status($status) { @@ -23896,7 +23847,7 @@ function acf_pro_update_license_status($status) * * @since 6.2 * - * @return bool True if the transient was deleted, false otherwise. + * @return boolean True if the transient was deleted, false otherwise. */ function acf_pro_remove_license_status() { @@ -23907,7 +23858,7 @@ function acf_pro_remove_license_status() * @since 6.2.2 * * @param array $status Optional license status array. - * @return bool True if active, false if not. + * @return boolean True if active, false if not. */ function acf_pro_is_license_active($status = array()) { @@ -23918,7 +23869,7 @@ function acf_pro_is_license_active($status = array()) * @since 6.2.2 * * @param array $status Optional license status array. - * @return bool True if expired, false if not. + * @return boolean True if expired, false if not. */ function acf_pro_is_license_expired($status = array()) { @@ -23929,7 +23880,7 @@ function acf_pro_is_license_expired($status = array()) * @since 6.2.2 * * @param array $status Optional license status array. - * @return bool True if refunded, false if not. + * @return boolean True if refunded, false if not. */ function acf_pro_was_license_refunded($status = array()) { @@ -23941,7 +23892,7 @@ function acf_pro_was_license_refunded($status = array()) * * @param array $license Optional ACF license array. * @param string $url An optional URL to provide. - * @return bool True if the URL has changed, false otherwise. + * @return boolean True if the URL has changed, false otherwise. */ function acf_pro_has_license_url_changed($license = array(), $url = '') { @@ -23967,4 +23918,90 @@ function acf_pro_maybe_reactivate_license() */ function acf_pro_get_manage_license_url($status = array()) { +} +/** + * Returns a multisite compatible licensing data value + * For multisite installs, this is from the main site options if available or the normal option otherwise. + * + * @since 6.2.6 + * + * @param string $option_name The option name to load. + * @param mixed $default_value The default value to return if not set. + * @return mixed the resulting option value from cache or database. + */ +function acf_pro_get_license_option($option_name, $default_value = \false) +{ +} +/** + * Updates a multisite compatible licensing data value + * For multisite installs, this is from the main site options if available or the normal option otherwise. + * + * @since 6.2.6 + * + * @param string $option_name The option name to update. + * @param mixed $value The new value to set. + * @return boolean True if the value was updated, false otherwise. + */ +function acf_pro_update_license_option($option_name, $value = \false) +{ +} +/** + * Deletes a multisite compatible licensing data value + * For multisite installs, this is from the main site options if available or the normal option otherwise. + * + * @since 6.2.6 + * + * @param string $option_name The option name to load. + * @return boolean The result of the deletion request. + */ +function acf_pro_delete_license_option($option_name) +{ +} +/** + * Returns a license related transient + * For multisite installs, this is from the network, otherwise from the normal transient function. + * + * @since 6.2.6 + * + * @param string $transient_name The name of the transient to return. + * @return mixed the resulting transient value from cache or database. + */ +function acf_pro_get_license_transient($transient_name) +{ +} +/** + * Updates a license related transient + * For multisite installs, this is from the network, otherwise from the normal transient function. + * + * @since 6.2.6 + * + * @param string $name The name of the transient to update. + * @param mixed $value The new value of the transient. + * @return mixed The result of the set function. + */ +function acf_pro_set_license_transient($name, $value) +{ +} +/** + * Deletes a license related transient + * For multisite installs, this is from the network, otherwise from the normal transient function. + * + * @since 6.2.6 + * + * @param string $transient_name The name of the transient to return. + * @return boolean True if the transient was deleted, false otherwise. + */ +function acf_pro_delete_license_transient($transient_name) +{ +} +/** + * Checks if the current license allows the legacy multisite behavior if we're on a multisite install. + * + * @since 6.2.6 + * + * @param array $status Optional license status array. + * @return boolean True if legacy multisite, false if not. + */ +function acf_pro_is_legacy_multisite(array $status = array()) +{ } \ No newline at end of file From 55bb27bbe68ee29040427519a099f58931c032db Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Mon, 11 Mar 2024 11:18:41 +0200 Subject: [PATCH 10/11] Generate stubs for ACF PRO 6.2.6.1 --- acf-pro-stubs.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index 475a2ad..1a8d247 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.2.6'; + public $version = '6.2.6.1'; /** * The plugin settings array. * From 8145c126bde2e34d44e8ffe4ddbb090eb3f3eca1 Mon Sep 17 00:00:00 2001 From: Juho Jama Date: Mon, 11 Mar 2024 11:18:44 +0200 Subject: [PATCH 11/11] Generate stubs for ACF PRO 6.2.7 --- acf-pro-stubs.php | 8907 ++++++++++++++++++++------------------------- 1 file changed, 3935 insertions(+), 4972 deletions(-) diff --git a/acf-pro-stubs.php b/acf-pro-stubs.php index 1a8d247..3c5ad40 100644 --- a/acf-pro-stubs.php +++ b/acf-pro-stubs.php @@ -16,7 +16,7 @@ class ACF * * @var string */ - public $version = '6.2.6.1'; + public $version = '6.2.7'; /** * The plugin settings array. * @@ -40,8 +40,6 @@ class ACF * * @date 23/06/12 * @since 5.0.0 - * - * @return void */ public function __construct() { @@ -51,8 +49,6 @@ public function __construct() * * @date 28/09/13 * @since 5.0.0 - * - * @return void */ public function initialize() { @@ -62,8 +58,6 @@ public function initialize() * * @date 28/09/13 * @since 5.0.0 - * - * @return void * @phpstan-return void */ public function init() @@ -74,8 +68,6 @@ public function init() * * @date 22/10/2015 * @since 5.3.2 - * - * @return void */ public function register_post_types() { @@ -85,8 +77,6 @@ public function register_post_types() * * @date 22/10/2015 * @since 5.3.2 - * - * @return void */ public function register_post_status() { @@ -292,7 +282,7 @@ class ACF_Admin_Internal_Post_Type_List /** * If this is a pro feature or not. * - * @var bool + * @var boolean */ public $is_pro_feature = \false; /** @@ -336,10 +326,7 @@ public function get_current_admin_url($params = '') /** * Constructor for all ACF internal post type admin list pages. * - * @date 21/07/2014 * @since 5.0.0 - * - * @return void * @phpstan-return void */ public function current_screen() @@ -348,10 +335,7 @@ public function current_screen() /** * Sets up the field groups ready for sync. * - * @date 17/4/20 * @since 5.9.0 - * - * @return void */ public function setup_sync() { @@ -359,10 +343,7 @@ public function setup_sync() /** * Enqueues admin scripts. * - * @date 18/4/20 * @since 5.9.0 - * - * @return void */ public function admin_enqueue_scripts() { @@ -382,9 +363,9 @@ public function admin_body_class($classes) /** * Returns the disabled post state HTML. * - * @since 5.9.0 + * @since 5.9.0 * - * @return string + * @return string */ public function get_disabled_post_state() { @@ -392,9 +373,9 @@ public function get_disabled_post_state() /** * Returns the registration error state. * - * @since 6.1 + * @since 6.1 * - * @return string + * @return string */ public function get_registration_error_state() { @@ -415,7 +396,7 @@ public function display_post_states($post_states, $post) /** * Get the HTML for when there are no post objects found. * - * @since 6.0.0 + * @since 6.0.0 * * @return string */ @@ -440,8 +421,8 @@ public function admin_table_columns($_columns) * @date 1/4/20 * @since 5.9.0 * - * @param string $column_name The name of the column to display. - * @param int $post_id The current post ID. + * @param string $column_name The name of the column to display. + * @param integer $post_id The current post ID. * @return void */ public function admin_table_columns_html($column_name, $post_id) @@ -491,7 +472,7 @@ public function render_admin_table_column_local_status($post) * @since 5.9.0 * * @param array $actions The array of actions HTML. - * @param WP_Post $post The post. + * @param WP_Post $post The post. * @return array */ public function page_row_actions($actions, $post) @@ -514,8 +495,8 @@ public function admin_table_bulk_actions($actions) * * @since 6.1 * - * @param string $action The action being performed. - * @param int $count The number of items the action was performed on. + * @param string $action The action being performed. + * @param integer $count The number of items the action was performed on. * @return string */ public function get_action_notice_text($action, $count = 1) @@ -542,10 +523,7 @@ public function check_deactivate() /** * Checks for the custom "duplicate" action. * - * @date 15/4/20 * @since 5.9.0 - * - * @return void * @phpstan-return void */ public function check_duplicate() @@ -554,10 +532,7 @@ public function check_duplicate() /** * Checks for the custom "acfsync" action. * - * @date 15/4/20 * @since 5.9.0 - * - * @return void * @phpstan-return void */ public function check_sync() @@ -578,10 +553,7 @@ public function admin_table_views($views) /** * Prints scripts into the admin footer. * - * @date 20/4/20 * @since 5.9.0 - * - * @return void */ public function admin_footer() { @@ -589,10 +561,7 @@ public function admin_footer() /** * Customizes the admin table HTML when viewing "sync" post_status. * - * @date 17/4/20 * @since 5.9.0 - * - * @return void */ public function admin_footer__sync() { @@ -600,11 +569,9 @@ public function admin_footer__sync() /** * Fires when trashing an internal post type. * - * @date 8/01/2014 - * @since 5.0.0 + * @since 5.0.0 * - * @param int $post_id The post ID. - * @return void + * @param integer $post_id The post ID. */ public function trashed_post($post_id) { @@ -615,7 +582,7 @@ public function trashed_post($post_id) * @date 8/01/2014 * @since 5.0.0 * - * @param int $post_id The post ID. + * @param integer $post_id The post ID. * @return void */ public function untrashed_post($post_id) @@ -627,7 +594,7 @@ public function untrashed_post($post_id) * @date 8/01/2014 * @since 5.0.0 * - * @param int $post_id The post ID. + * @param integer $post_id The post ID. * @return void */ public function deleted_post($post_id) @@ -666,9 +633,9 @@ public function __construct() * * @since 5.8.0 * - * @param bool $use_block_editor Whether the post type can be edited or not. Default true. - * @param string $post_type The post type being checked. - * @return bool + * @param boolean $use_block_editor Whether the post type can be edited or not. Default true. + * @param string $post_type The post type being checked. + * @return boolean */ public function use_block_editor_for_post_type($use_block_editor, $post_type) { @@ -688,8 +655,6 @@ public function post_updated_messages($messages) * This function is fired when loading the admin page before HTML has been rendered. * * @since 5.0.0 - * - * @return void * @phpstan-return void */ public function current_screen() @@ -710,8 +675,6 @@ public function admin_body_class($classes) * Enqueues any scripts necessary for internal post type. * * @since 5.0.0 - * - * @return void */ public function admin_enqueue_scripts() { @@ -720,8 +683,6 @@ public function admin_enqueue_scripts() * Set up functionality for the field group edit page. * * @since 3.1.8 - * - * @return void */ public function admin_head() { @@ -729,10 +690,10 @@ public function admin_head() /** * Adds extra HTML to the acf form data element. * - * @since 5.3.8 + * @since 5.3.8 * - * @param array $args Arguments array to pass through to action. - * @return void + * @param array $args Arguments array to pass through to action. + * @return void */ public function form_data($args) { @@ -741,8 +702,6 @@ public function form_data($args) * Admin footer third party hook support * * @since 5.3.2 - * - * @return void */ public function admin_footer() { @@ -763,10 +722,9 @@ public function admin_l10n($l10n) * * @since 6.1 * - * @param int $post_id The ID of the post being saved. + * @param integer $post_id The ID of the post being saved. * @param WP_Post $post The post object. - * - * @return bool + * @return boolean */ public function verify_save_post($post_id, $post) { @@ -775,8 +733,6 @@ public function verify_save_post($post_id, $post) * Powers the modal for linking field groups to newly-created CPTs/taxonomies. * * @since 6.1 - * - * @return void * @phpstan-return never */ public function ajax_link_field_groups() @@ -792,7 +748,7 @@ class ACF_Data var $data = array(); /** @var array Storage for data aliases. */ var $aliases = array(); - /** @var bool Enables unique data per site. */ + /** @var boolean Enables unique data per site. */ var $multisite = \false; /** * __construct @@ -830,7 +786,7 @@ function initialize() * @date 9/1/19 * @since 5.7.10 * - * @param string|array $name The data name or an array of data. + * @param string|array $name The data name or an array of data. * @param mixed $value The data value. * @return ACF_Data */ @@ -915,7 +871,7 @@ function get_data() * @date 9/1/19 * @since 5.7.10 * - * @param string|array $name The data name or an array of data. + * @param string|array $name The data name or an array of data. * @param mixed $value The data value. * @return ACF_Data */ @@ -973,7 +929,7 @@ function reset() * @since 5.7.10 * * @param void - * @return int + * @return integer */ function count() { @@ -987,7 +943,7 @@ function count() * @since 5.7.10 * * @param void - * @return int + * @return integer */ function query($args, $operator = 'AND') { @@ -1014,7 +970,7 @@ function alias($name = '') * @date 13/2/19 * @since 5.7.11 * - * @param int $site_id New blog ID. + * @param integer $site_id New blog ID. * @param int prev_blog_id Prev blog ID. * @return void * @phpstan-return void @@ -1037,15 +993,15 @@ class ACF_Admin_Notice extends \ACF_Data 'persisted' => \false, ); /** - * render + * render * - * Renders the notice HTML. + * Renders the notice HTML. * - * @date 27/12/18 - * @since 5.8.0 + * @date 27/12/18 + * @since 5.8.0 * - * @param void - * @return void + * @param void + * @return void */ function render() { @@ -1106,86 +1062,85 @@ class acf_admin_tools /** @var string The active tool */ var $active = ''; /** - * __construct + * __construct * - * This function will setup the class functionality + * This function will setup the class functionality * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * register_tool + * register_tool * - * This function will store a tool tool class + * This function will store a tool tool class * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param string $class - * @return void + * @param string $class + * @return void */ function register_tool($class) { } /** - * get_tool + * get_tool * - * This function will return a tool tool class + * This function will return a tool tool class * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param string $name - * @return void + * @param string $name + * @return void */ function get_tool($name) { } /** - * get_tools + * get_tools * - * This function will return an array of all tools + * This function will return an array of all tools * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return array + * @param void + * @return array */ function get_tools() { } /** - * admin_menu - * - * This function will add the ACF menu item to the WP admin + * This function will add the ACF menu item to the WP admin * - * @type action (admin_menu) - * @date 28/09/13 - * @since 5.0.0 + * @type action (admin_menu) + * @date 28/09/13 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void + * @phpstan-return void */ function admin_menu() { } /** - * load + * load * - * description + * description * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function load() { @@ -1202,43 +1157,43 @@ public function admin_body_class($classes) { } /** - * include_tools + * include_tools * - * description + * description * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function include_tools() { } /** - * check_submit + * check_submit * - * description + * description * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function check_submit() { } /** - * html + * html * - * description + * description * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function html() { @@ -1250,8 +1205,6 @@ function html() * * @param mixed $post The post this metabox is being displayed on, should be an empty string always for us on a tools page. * @param array $metabox An array of the metabox attributes. - * - * @return void */ public function metabox_html($post, $metabox) { @@ -1266,29 +1219,29 @@ class ACF_Admin_Upgrade */ public $network_upgrade_needed_transient; /** - * __construct + * __construct * - * Sets up the class functionality. + * Sets up the class functionality. * - * @date 31/7/18 - * @since 5.7.2 + * @date 31/7/18 + * @since 5.7.2 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * admin_menu + * admin_menu * - * Setus up logic if DB Upgrade is needed on a single site. + * Setus up logic if DB Upgrade is needed on a single site. * - * @date 24/8/18 - * @since 5.7.4 + * @date 24/8/18 + * @since 5.7.4 * - * @param void - * @return void + * @param void + * @return void */ function admin_menu() { @@ -1298,11 +1251,8 @@ function admin_menu() * the “Upgrade Database” submenu under the “Dashboard” network admin * menu item if an ACF upgrade needs to run on any network site. * - * @date 24/8/18 * @since 5.7.4 * @since 6.0.0 Reduce memory usage, cache network upgrade checks. - * - * @return void * @phpstan-return void */ function network_admin_menu() @@ -1320,37 +1270,37 @@ function network_admin_menu() * * @since 6.0.0 * @return string 'yes' if any site in the network requires an upgrade, - * otherwise 'no'. String instead of boolean so that - * `false` returned from a get_site_transient check can - * denote that an upgrade check is needed. + * otherwise 'no'. String instead of boolean so that + * `false` returned from a get_site_transient check can + * denote that an upgrade check is needed. */ public function check_for_network_upgrades() { } /** - * admin_load + * admin_load * - * Runs during the loading of the admin page. + * Runs during the loading of the admin page. * - * @date 24/8/18 - * @since 5.7.4 + * @date 24/8/18 + * @since 5.7.4 * - * @param type $var Description. Default. - * @return type Description. + * @param type $var Description. Default. + * @return type Description. */ function admin_load() { } /** - * network_admin_load + * network_admin_load * - * Runs during the loading of the network admin page. + * Runs during the loading of the network admin page. * - * @date 24/8/18 - * @since 5.7.4 + * @date 24/8/18 + * @since 5.7.4 * - * @param type $var Description. Default. - * @return type Description. + * @param type $var Description. Default. + * @return type Description. */ function network_admin_load() { @@ -1367,57 +1317,57 @@ public function admin_body_class($classes) { } /** - * admin_notices + * admin_notices * - * Displays the DB Upgrade prompt. + * Displays the DB Upgrade prompt. * - * @date 23/8/18 - * @since 5.7.3 + * @date 23/8/18 + * @since 5.7.3 * - * @param void - * @return void + * @param void + * @return void */ function admin_notices() { } /** - * network_admin_notices + * network_admin_notices * - * Displays the DB Upgrade prompt on a multi site. + * Displays the DB Upgrade prompt on a multi site. * - * @date 23/8/18 - * @since 5.7.3 + * @date 23/8/18 + * @since 5.7.3 * - * @param void - * @return void + * @param void + * @return void */ function network_admin_notices() { } /** - * admin_html + * admin_html * - * Displays the HTML for the admin page. + * Displays the HTML for the admin page. * - * @date 24/8/18 - * @since 5.7.4 + * @date 24/8/18 + * @since 5.7.4 * - * @param void - * @return void + * @param void + * @return void */ function admin_html() { } /** - * network_admin_html + * network_admin_html * - * Displays the HTML for the network upgrade admin page. + * Displays the HTML for the network upgrade admin page. * - * @date 24/8/18 - * @since 5.7.4 + * @date 24/8/18 + * @since 5.7.4 * - * @param void - * @return void + * @param void + * @return void */ function network_admin_html() { @@ -1429,8 +1379,6 @@ class ACF_Admin * Constructor. * * @since 5.0.0 - * - * @return void */ public function __construct() { @@ -1449,8 +1397,6 @@ public function admin_menu() * Enqueues global admin styling. * * @since 5.0.0 - * - * @return void */ public function admin_enqueue_scripts() { @@ -1505,8 +1451,6 @@ public function maybe_show_import_from_cptui_notice() * had HTML removed/altered due to unsafe HTML being escaped. * * @since 6.2.5 - * - * @return void * @phpstan-return void */ public function maybe_show_escaped_html_notice() @@ -1578,9 +1522,9 @@ public function ensure_submenu_selection($submenu_file) } } /** - * ACF Admin Field Group Class + * ACF Admin Field Group Class * - * All the logic for editing a field group + * All the logic for editing a field group */ class acf_admin_field_group extends \ACF_Admin_Internal_Post_Type { @@ -1601,20 +1545,18 @@ class acf_admin_field_group extends \ACF_Admin_Internal_Post_Type /** * Constructs the class. * - * @since 5.0.0 - * - * @return void + * @since 5.0.0 */ public function __construct() { } /** - * This function will customize the message shown when editing a field group + * This function will customize the message shown when editing a field group * - * @since 5.0.0 + * @since 5.0.0 * - * @param array $messages Post type messages. - * @return array + * @param array $messages Post type messages. + * @return array */ public function post_updated_messages($messages) { @@ -1623,8 +1565,6 @@ public function post_updated_messages($messages) * Enqueues any scripts necessary for internal post type. * * @since 5.0.0 - * - * @return void */ public function admin_enqueue_scripts() { @@ -1633,16 +1573,12 @@ public function admin_enqueue_scripts() * Set up functionality for the field group edit page. * * @since 3.1.8 - * - * @return void */ public function admin_head() { } /** * This action will allow ACF to render metaboxes after the title. - * - * @return void */ public function edit_form_after_title() { @@ -1672,17 +1608,13 @@ public function admin_l10n($l10n) /** * Admin footer third party hook support * - * @since 5.3.2 - * - * @return void + * @since 5.3.2 */ public function admin_footer() { } /** * Renders HTML for the ACF PRO features upgrade notice. - * - * @return void * @phpstan-return void */ public function include_pro_features() @@ -1702,9 +1634,8 @@ public function screen_settings($html) /** * Sets the "Edit Field Group" screen to use a one-column layout. * - * @param int $columns Number of columns for layout. - * - * @return int + * @param integer $columns Number of columns for layout. + * @return integer */ public function screen_layout($columns = 0) { @@ -1713,8 +1644,6 @@ public function screen_layout($columns = 0) * This function will customize the publish metabox * * @since 5.2.9 - * - * @return void */ public function post_submitbox_misc_actions() { @@ -1724,10 +1653,9 @@ public function post_submitbox_misc_actions() * * @since 1.0.0 * - * @param int $post_id The post ID. + * @param integer $post_id The post ID. * @param WP_Post $post The post object. - * - * @return int $post_id + * @return integer $post_id */ public function save_post($post_id, $post) { @@ -1735,9 +1663,7 @@ public function save_post($post_id, $post) /** * This function will render the HTML for the metabox 'acf-field-group-fields' * - * @since 5.0.0 - * - * @return void + * @since 5.0.0 */ public function mb_fields() { @@ -1746,8 +1672,6 @@ public function mb_fields() * This function will render the HTML for the metabox 'acf-field-group-pro-features' * * @since 6.0.0 - * - * @return void */ public function mb_pro_features() { @@ -1756,8 +1680,6 @@ public function mb_pro_features() * This function will render the HTML for the metabox 'acf-field-group-options' * * @since 5.0.0 - * - * @return void */ public function mb_options() { @@ -1765,9 +1687,7 @@ public function mb_options() /** * This function can be accessed via an AJAX action and will return the result from the render_location_value function * - * @since 5.0.0 - * - * @return void + * @since 5.0.0 * @phpstan-return never */ public function ajax_render_location_rule() @@ -1776,9 +1696,7 @@ public function ajax_render_location_rule() /** * This function will return HTML containing the field's settings based on it's new type * - * @since 5.0.0 - * - * @return void + * @since 5.0.0 * @phpstan-return never */ public function ajax_render_field_settings() @@ -1787,9 +1705,7 @@ public function ajax_render_field_settings() /** * Move field AJAX function * - * @since 5.0.0 - * - * @return void No return, HTML output for AJAX consumption. + * @since 5.0.0 * @phpstan-return never */ public function ajax_move_field() @@ -1822,18 +1738,13 @@ class ACF_Admin_Field_Groups extends \ACF_Admin_Internal_Post_Type_List /** * Constructor. * - * @date 5/03/2014 * @since 5.0.0 - * - * @return void */ public function __construct() { } /** * Renders HTML for the ACF PRO features upgrade notice. - * - * @return void * @phpstan-return void */ public function include_pro_features() @@ -1850,10 +1761,7 @@ public function admin_menu() /** * Redirects users from ACF 4.0 admin page. * - * @date 17/9/18 - * @since 5.7.6 - * - * @return void + * @since 5.7.6 */ public function handle_redirection() { @@ -1913,7 +1821,7 @@ public function render_admin_table_column_num_fields($field_group) * @date 8/01/2014 * @since 5.0.0 * - * @param int $post_id The post ID. + * @param integer $post_id The post ID. * @return void */ public function trashed_post($post_id) @@ -1925,7 +1833,7 @@ public function trashed_post($post_id) * @date 8/01/2014 * @since 5.0.0 * - * @param int $post_id The post ID. + * @param integer $post_id The post ID. * @return void */ public function untrashed_post($post_id) @@ -1937,7 +1845,7 @@ public function untrashed_post($post_id) * @date 8/01/2014 * @since 5.0.0 * - * @param int $post_id The post ID. + * @param integer $post_id The post ID. * @return void */ public function deleted_post($post_id) @@ -1948,8 +1856,8 @@ public function deleted_post($post_id) * * @since 6.1 * - * @param string $action The action being performed. - * @param int $count The number of items the action was performed on. + * @param string $action The action being performed. + * @param integer $count The number of items the action was performed on. * @return string */ public function get_action_notice_text($action, $count = 1) @@ -1957,9 +1865,9 @@ public function get_action_notice_text($action, $count = 1) } } /** - * ACF Admin Post Type Class + * ACF Admin Post Type Class * - * All the logic for editing a post type. + * All the logic for editing a post type. */ class ACF_Admin_Post_type extends \ACF_Admin_Internal_Post_Type { @@ -1993,7 +1901,7 @@ public function post_updated_messages($messages) * * @since 6.1 * - * @param bool $created True if the post was just created. + * @param boolean $created True if the post was just created. * @return string */ public function post_type_created_message($created = \false) @@ -2003,8 +1911,6 @@ public function post_type_created_message($created = \false) * Enqueues any scripts necessary for internal post type. * * @since 5.0.0 - * - * @return void */ public function admin_enqueue_scripts() { @@ -2012,17 +1918,13 @@ public function admin_enqueue_scripts() /** * Sets up all functionality for the post type edit page to work. * - * @since 3.1.8 - * - * @return void + * @since 3.1.8 */ public function admin_head() { } /** * This action will allow ACF to render metaboxes after the title. - * - * @return void */ public function edit_form_after_title() { @@ -2030,10 +1932,10 @@ public function edit_form_after_title() /** * This function will add extra HTML to the acf form data element * - * @since 5.3.8 + * @since 5.3.8 * - * @param array $args Arguments array to pass through to action. - * @return void + * @param array $args Arguments array to pass through to action. + * @return void */ public function form_data($args) { @@ -2052,9 +1954,7 @@ public function admin_l10n($l10n) /** * Admin footer third party hook support * - * @since 5.3.2 - * - * @return void + * @since 5.3.2 */ public function admin_footer() { @@ -2073,9 +1973,8 @@ public function screen_settings($html) /** * Sets the "Edit Post Type" screen to use a one-column layout. * - * @param int $columns Number of columns for layout. - * - * @return int + * @param integer $columns Number of columns for layout. + * @return integer */ public function screen_layout($columns = 0) { @@ -2083,8 +1982,7 @@ public function screen_layout($columns = 0) /** * Force basic settings to always be visible * - * @param array $hidden_metaboxes The metaboxes hidden on this page. - * + * @param array $hidden_metaboxes The metaboxes hidden on this page. * @return array */ public function force_basic_settings($hidden_metaboxes) @@ -2094,7 +1992,6 @@ public function force_basic_settings($hidden_metaboxes) * Force advanced settings to be visible * * @param array $hidden_metaboxes The metaboxes hidden on this page. - * * @return array */ public function force_advanced_settings($hidden_metaboxes) @@ -2103,9 +2000,7 @@ public function force_advanced_settings($hidden_metaboxes) /** * This function will customize the publish metabox * - * @since 5.2.9 - * - * @return void + * @since 5.2.9 */ public function post_submitbox_misc_actions() { @@ -2115,10 +2010,9 @@ public function post_submitbox_misc_actions() * * @since 1.0.0 * - * @param int $post_id The post ID. - * @param WP_Post $post The post object. - * - * @return int $post_id + * @param integer $post_id The post ID. + * @param WP_Post $post The post object. + * @return integer $post_id */ public function save_post($post_id, $post) { @@ -2127,8 +2021,6 @@ public function save_post($post_id, $post) * Renders HTML for the basic settings metabox. * * @since 5.0.0 - * - * @return void */ public function mb_basic_settings() { @@ -2136,9 +2028,7 @@ public function mb_basic_settings() /** * Renders the HTML for the advanced settings metabox. * - * @since 5.0.0 - * - * @return void + * @since 5.0.0 */ public function mb_advanced_settings() { @@ -2173,18 +2063,13 @@ class ACF_Admin_Post_Types extends \ACF_Admin_Internal_Post_Type_List /** * Constructor. * - * @date 5/03/2014 - * @since 6.2 - * - * @return void + * @since 6.2 */ public function __construct() { } /** * Renders HTML for the ACF PRO features upgrade notice. - * - * @return void * @phpstan-return void */ public function include_pro_features() @@ -2193,9 +2078,7 @@ public function include_pro_features() /** * Current screen actions for the post types list admin page. * - * @since 6.1 - * - * @return void + * @since 6.1 * @phpstan-return void */ public function current_screen() @@ -2275,8 +2158,8 @@ public function render_admin_table_column_num_posts($post_type) * * @since 6.1 * - * @param string $action The action being performed. - * @param int $count The number of items the action was performed on. + * @param string $action The action being performed. + * @param integer $count The number of items the action was performed on. * @return string */ public function get_action_notice_text($action, $count = 1) @@ -2321,19 +2204,13 @@ class ACF_Admin_Taxonomies extends \ACF_Admin_Internal_Post_Type_List public $store = 'taxonomies'; /** * Constructor. - * - * @date 5/03/2014 - * @since 6.2 - * - * @return void + * @since 6.2 */ public function __construct() { } /** * Renders HTML for the ACF PRO features upgrade notice. - * - * @return void * @phpstan-return void */ public function include_pro_features() @@ -2342,9 +2219,7 @@ public function include_pro_features() /** * Current screen actions for the taxonomies list admin page. * - * @since 6.1 - * - * @return void + * @since 6.1 * @phpstan-return void */ public function current_screen() @@ -2424,8 +2299,8 @@ public function render_admin_table_column_num_terms($taxonomy) * * @since 6.1 * - * @param string $action The action being performed. - * @param int $count The number of items the action was performed on. + * @param string $action The action being performed. + * @param integer $count The number of items the action was performed on. * @return string */ public function get_action_notice_text($action, $count = 1) @@ -2434,18 +2309,18 @@ public function get_action_notice_text($action, $count = 1) /** * Returns the registration error state. * - * @since 6.1 + * @since 6.1 * - * @return string + * @return string */ public function get_registration_error_state() { } } /** - * ACF Admin Field Group Class + * ACF Admin Field Group Class * - * All the logic for editing a taxonomy. + * All the logic for editing a taxonomy. */ class ACF_Admin_Taxonomy extends \ACF_Admin_Internal_Post_Type { @@ -2464,12 +2339,12 @@ class ACF_Admin_Taxonomy extends \ACF_Admin_Internal_Post_Type */ public $admin_body_class = 'acf-admin-single-taxonomy'; /** - * This function will customize the message shown when editing a field group + * This function will customize the message shown when editing a field group * - * @since 5.0.0 + * @since 5.0.0 * - * @param array $messages Post type messages. - * @return array + * @param array $messages Post type messages. + * @return array */ public function post_updated_messages($messages) { @@ -2479,7 +2354,7 @@ public function post_updated_messages($messages) * * @since 6.1 * - * @param bool $created True if the post was just created. + * @param boolean $created True if the post was just created. * @return string */ public function taxonomy_saved_message($created = \false) @@ -2489,26 +2364,20 @@ public function taxonomy_saved_message($created = \false) * Enqueues any scripts necessary for internal post type. * * @since 5.0.0 - * - * @return void */ public function admin_enqueue_scripts() { } /** - * Sets up all functionality for the taxonomy edit page to work. - * - * @since 3.1.8 + * Sets up all functionality for the taxonomy edit page to work. * - * @return void + * @since 3.1.8 */ public function admin_head() { } /** * This action will allow ACF to render metaboxes after the title. - * - * @return void */ public function edit_form_after_title() { @@ -2516,10 +2385,10 @@ public function edit_form_after_title() /** * This function will add extra HTML to the acf form data element * - * @since 5.3.8 + * @since 5.3.8 * - * @param array $args Arguments array to pass through to action. - * @return void + * @param array $args Arguments array to pass through to action. + * @return void */ public function form_data($args) { @@ -2538,9 +2407,7 @@ public function admin_l10n($l10n) /** * Admin footer third party hook support * - * @since 5.3.2 - * - * @return void + * @since 5.3.2 */ public function admin_footer() { @@ -2559,9 +2426,8 @@ public function screen_settings($html) /** * Sets the "Edit Field Group" screen to use a one-column layout. * - * @param int $columns Number of columns for layout. - * - * @return int + * @param integer $columns Number of columns for layout. + * @return integer */ public function screen_layout($columns = 0) { @@ -2569,8 +2435,7 @@ public function screen_layout($columns = 0) /** * Force basic settings to always be visible * - * @param array $hidden_metaboxes The metaboxes hidden on this page. - * + * @param array $hidden_metaboxes The metaboxes hidden on this page. * @return array */ public function force_basic_settings($hidden_metaboxes) @@ -2579,19 +2444,16 @@ public function force_basic_settings($hidden_metaboxes) /** * Force advanced settings to be visible * - * @param array $hidden_metaboxes The metaboxes hidden on this page. - * + * @param array $hidden_metaboxes The metaboxes hidden on this page. * @return array */ public function force_advanced_settings($hidden_metaboxes) { } /** - * This function will customize the publish metabox - * - * @since 5.2.9 + * This function will customize the publish metabox * - * @return void + * @since 5.2.9 */ public function post_submitbox_misc_actions() { @@ -2601,10 +2463,9 @@ public function post_submitbox_misc_actions() * * @since 1.0.0 * - * @param int $post_id The post ID. - * @param WP_Post $post The post object. - * - * @return int $post_id + * @param integer $post_id The post ID. + * @param WP_Post $post The post object. + * @return integer $post_id */ public function save_post($post_id, $post) { @@ -2613,8 +2474,6 @@ public function save_post($post_id, $post) * Renders HTML for the 'acf-taxonomy-fields' metabox. * * @since 5.0.0 - * - * @return void */ public function mb_basic_settings() { @@ -2622,9 +2481,7 @@ public function mb_basic_settings() /** * Renders the HTML for the 'acf-taxonomy-options' metabox. * - * @since 5.0.0 - * - * @return void + * @since 5.0.0 */ public function mb_advanced_settings() { @@ -2641,128 +2498,126 @@ class ACF_Admin_Tool /** @var boolean Redirect form to single */ // var $redirect = false; /** - * get_name + * get_name * - * This function will return the Tool's name + * This function will return the Tool's name * - * @date 19/10/17 - * @since 5.6.3 + * @date 19/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function get_name() { } /** - * get_title + * get_title * - * This function will return the Tool's title + * This function will return the Tool's title * - * @date 19/10/17 - * @since 5.6.3 + * @date 19/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function get_title() { } /** - * get_url + * get_url * - * This function will return the Tool's title + * This function will return the Tool's title * - * @date 19/10/17 - * @since 5.6.3 + * @date 19/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function get_url() { } /** - * is_active + * is_active * - * This function will return true if the tool is active + * This function will return true if the tool is active * - * @date 19/10/17 - * @since 5.6.3 + * @date 19/10/17 + * @since 5.6.3 * - * @param void - * @return bool + * @param void + * @return boolean */ function is_active() { } /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 27/6/17 - * @since 5.6.0 + * @type function + * @date 27/6/17 + * @since 5.6.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * initialize + * initialize * - * This function will initialize the admin tool + * This function will initialize the admin tool * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * load + * load * - * This function is called during the admin page load + * This function is called during the admin page load * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function load() { } /** - * html + * html * - * This function will output the metabox HTML + * This function will output the metabox HTML * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function html() { } /** - * submit + * submit * - * This function will run when the tool's form has been submit + * This function will run when the tool's form has been submit * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function submit() { @@ -2775,85 +2630,85 @@ class ACF_Admin_Tool_Export extends \ACF_Admin_Tool /** @var array Export data */ var $json = ''; /** - * initialize + * initialize * - * This function will initialize the admin tool + * This function will initialize the admin tool * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * submit + * submit * - * This function will run when the tool's form has been submit + * This function will run when the tool's form has been submit * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function submit() { } /** - * submit_download + * submit_download * - * description + * description * - * @date 17/10/17 - * @since 5.6.3 + * @date 17/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function submit_download() { } /** - * submit_generate + * submit_generate * - * description + * description * - * @date 17/10/17 - * @since 5.6.3 + * @date 17/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function submit_generate() { } /** - * load + * load * - * description + * description * - * @date 21/10/17 - * @since 5.6.3 + * @date 21/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function load() { } /** - * html + * html * - * This function will output the metabox HTML + * This function will output the metabox HTML * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function html() { @@ -2861,10 +2716,7 @@ function html() /** * Renders the checkboxes to select items to export. * - * @date 24/10/17 * @since 5.6.3 - * - * @return void */ public function html_field_selection() { @@ -2872,38 +2724,21 @@ public function html_field_selection() /** * Renders the side panel for selecting ACF items to export via PHP. * - * @date 21/10/17 * @since 5.6.3 - * - * @return void */ public function html_panel_selection() { } /** - * html_panel_settings - * - * description - * - * @date 21/10/17 - * @since 5.6.3 - * - * @param void - * @return void - */ - function html_panel_settings() - { - } - /** - * html_archive + * html_archive * - * description + * description * - * @date 20/10/17 - * @since 5.6.3 + * @date 20/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function html_archive() { @@ -2911,10 +2746,7 @@ function html_archive() /** * Renders the PHP export screen. * - * @date 20/10/17 * @since 5.6.3 - * - * @return void */ public function html_single() { @@ -2922,10 +2754,7 @@ public function html_single() /** * Generates the HTML for the PHP export functionality. * - * @date 17/10/17 * @since 5.6.3 - * - * @return void */ public function html_generate() { @@ -2933,10 +2762,9 @@ public function html_generate() /** * Return an array of keys that have been selected in the export tool. * - * @date 20/10/17 * @since 5.6.3 * - * @return array|bool + * @return array|boolean */ public function get_selected_keys() { @@ -2944,10 +2772,9 @@ public function get_selected_keys() /** * Returns the JSON data for given $_POST args. * - * @date 17/10/17 * @since 5.6.3 * - * @return array|bool + * @return array|boolean */ public function get_selected() { @@ -2956,29 +2783,29 @@ public function get_selected() class ACF_Admin_Tool_Import extends \ACF_Admin_Tool { /** - * initialize + * initialize * - * This function will initialize the admin tool + * This function will initialize the admin tool * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * html + * html * - * This function will output the metabox HTML + * This function will output the metabox HTML * - * @date 10/10/17 - * @since 5.6.3 + * @date 10/10/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function html() { @@ -2986,7 +2813,6 @@ function html() /** * Imports the selected ACF posts and returns an admin notice on completion. * - * @date 10/10/17 * @since 5.6.3 * * @return ACF_Admin_Notice @@ -3012,7 +2838,7 @@ class ACF_Ajax var $action = ''; /** @var array The $_REQUEST data. */ var $request; - /** @var bool Prevents access for non-logged in users. */ + /** @var boolean Prevents access for non-logged in users. */ var $public = \false; /** * __construct @@ -3062,7 +2888,7 @@ function get($key = '') * @date 31/7/18 * @since 5.7.2 * - * @param string $key The data key. + * @param string $key The data key. * @param mixed $value The data value. * @return ACF_Ajax */ @@ -3169,7 +2995,7 @@ class ACF_Ajax_Check_Screen extends \ACF_Ajax { /** @var string The AJAX action name. */ var $action = 'acf/ajax/check_screen'; - /** @var bool Prevents access for non-logged in users. */ + /** @var boolean Prevents access for non-logged in users. */ var $public = \false; /** * get_response @@ -3197,7 +3023,7 @@ class ACF_Ajax_Local_JSON_Diff extends \ACF_Ajax /** * Prevents access for non-logged in users. * - * @var bool + * @var boolean */ public $public = \false; /** @@ -3215,17 +3041,17 @@ public function get_response($request) } class ACF_Ajax_Query extends \ACF_Ajax { - /** @var bool Prevents access for non-logged in users. */ + /** @var boolean Prevents access for non-logged in users. */ var $public = \true; - /** @var int The page of results to return. */ + /** @var integer The page of results to return. */ var $page = 1; - /** @var int The number of results per page. */ + /** @var integer The number of results per page. */ var $per_page = 20; - /** @var bool Signifies whether or not this AJAX query has more pages to load. */ + /** @var boolean Signifies whether or not this AJAX query has more pages to load. */ var $more = \false; /** @var string The searched term. */ var $search = ''; - /** @var bool Signifies whether the current query is a search. */ + /** @var boolean Signifies whether the current query is a search. */ var $is_search = \false; /** @var (int|string) The post_id being edited. */ var $post_id = 0; @@ -3380,8 +3206,8 @@ function get_result($user) * @date 9/3/20 * @since 5.8.8 * - * @param array $columns An array of column names to be searched. - * @param string $search The search term. + * @param array $columns An array of column names to be searched. + * @param string $search The search term. * @param WP_User_Query $WP_User_Query The WP_User_Query instance. * @return array */ @@ -3412,7 +3238,7 @@ class ACF_Ajax_User_Setting extends \ACF_Ajax { /** @var string The AJAX action name. */ var $action = 'acf/ajax/user_setting'; - /** @var bool Prevents access for non-logged in users. */ + /** @var boolean Prevents access for non-logged in users. */ var $public = \true; /** * get_response @@ -3463,7 +3289,7 @@ public function __construct() * @date 10/4/20 * @since 5.9.0 * - * @param string $name The method name. + * @param string $name The method name. * @param array $arguments The array of arguments. * @return mixed */ @@ -3538,10 +3364,10 @@ public function enqueue_style($name) * @date 28/4/20 * @since 5.9.0 * - * @param string $action The action name. - * @param string $method The method name. - * @param int $priority See add_action(). - * @param int $accepted_args See add_action(). + * @param string $action The action name. + * @param string $method The method name. + * @param integer $priority See add_action(). + * @param integer $accepted_args See add_action(). * @return void */ public function add_action($action, $method, $priority = 10, $accepted_args = 1) @@ -3554,7 +3380,7 @@ public function add_action($action, $method, $priority = 10, $accepted_args = 1) * @since 5.9.0 * * @param array $args { - * @type bool $uploader Whether or not to enqueue uploader scripts. + * @type bool $uploader Whether or not to enqueue uploader scripts. * } * @return void */ @@ -3679,8 +3505,8 @@ public function __construct() * * @since 6.1 * - * @param int|WP_Post $id The post ID being queried. - * @return array|bool The main ACF array for the post, or false on failure. + * @param integer|WP_Post $id The post ID being queried. + * @return array|boolean The main ACF array for the post, or false on failure. */ public function get_post($id = 0) { @@ -3690,7 +3516,7 @@ public function get_post($id = 0) * * @since 6.1 * - * @param int|string $id The field ID, key or name. + * @param integer|string $id The field ID, key or name. * @return array|false The field group array, or false on failure. */ public function get_raw_post($id = 0) @@ -3701,7 +3527,7 @@ public function get_raw_post($id = 0) * * @since 6.1 * - * @param int|string $id The post ID, key, or name. + * @param integer|string $id The post ID, key, or name. * @return WP_Post|bool The post object, or false on failure. */ public function get_post_object($id = 0) @@ -3713,7 +3539,7 @@ public function get_post_object($id = 0) * @since 6.1 * * @param string $id The identifier. - * @return bool + * @return boolean */ public function is_post_key($id = '') { @@ -3734,8 +3560,6 @@ public function validate_post($post = array()) * Errors are added to the form using acf_add_internal_post_type_validation_error(). * * @since 6.1 - * - * @return bool */ public function ajax_validate_values() { @@ -3819,12 +3643,12 @@ public function update_post($post) * * @since 6.1 * - * @param string $slug The post slug. - * @param int $post_ID Post ID. - * @param string $post_status The post status. - * @param string $post_type Post type. - * @param int $post_parent Post parent ID. - * @param string $original_slug The original post slug. + * @param string $slug The post slug. + * @param integer $post_ID Post ID. + * @param string $post_status The post status. + * @param string $post_type Post type. + * @param integer $post_parent Post parent ID. + * @param string $original_slug The original post slug. * @return string */ public function apply_unique_post_slug($slug, $post_ID, $post_status, $post_type, $post_parent, $original_slug) @@ -3846,8 +3670,8 @@ public function flush_post_cache($post) * * @since 6.1 * - * @param int|string $id The ID of the ACF post to delete. - * @return bool + * @param integer|string $id The ID of the ACF post to delete. + * @return boolean */ public function delete_post($id = 0) { @@ -3857,8 +3681,8 @@ public function delete_post($id = 0) * * @since 6.1 * - * @param int|string $id The ID of the ACF post to trash. - * @return bool + * @param integer|string $id The ID of the ACF post to trash. + * @return boolean */ public function trash_post($id = 0) { @@ -3868,8 +3692,8 @@ public function trash_post($id = 0) * * @since 6.1 * - * @param int|string $id The ID of the ACF post to untrash. - * @return bool + * @param integer|string $id The ID of the ACF post to untrash. + * @return boolean */ public function untrash_post($id = 0) { @@ -3880,9 +3704,9 @@ public function untrash_post($id = 0) * * @since 6.1 * - * @param string $new_status The new status of the post being restored. - * @param int $post_id The ID of the post being restored. - * @param string $previous_status The status of the post at the point where it was trashed. + * @param string $new_status The new status of the post being restored. + * @param integer $post_id The ID of the post being restored. + * @param string $previous_status The status of the post at the point where it was trashed. * @return string */ public function untrash_post_status($new_status, $post_id, $previous_status) @@ -3894,7 +3718,7 @@ public function untrash_post_status($new_status, $post_id, $previous_status) * @since 6.1 * * @param array $post The post array to check. - * @return bool + * @return boolean */ public function is_post($post = \false) { @@ -3904,8 +3728,8 @@ public function is_post($post = \false) * * @since 6.1 * - * @param int|string $id The ID of the post to duplicate. - * @param int $new_post_id Optional post ID to override. + * @param integer|string $id The ID of the post to duplicate. + * @param integer $new_post_id Optional post ID to override. * @return array The new ACF post array. */ public function duplicate_post($id = 0, $new_post_id = 0) @@ -3916,9 +3740,9 @@ public function duplicate_post($id = 0, $new_post_id = 0) * * @since 6.1 * - * @param int|string $id The ID of the ACF post to activate/deactivate. - * @param bool $activate True if the post should be activated. - * @return bool + * @param integer|string $id The ID of the ACF post to activate/deactivate. + * @param boolean $activate True if the post should be activated. + * @return boolean */ public function update_post_active_status($id, $activate = \true) { @@ -3928,7 +3752,7 @@ public function update_post_active_status($id, $activate = \true) * * @since 6.1 * - * @param int $post_id The ACF post ID. + * @param integer $post_id The ACF post ID. * @return string */ public function get_post_edit_link($post_id) @@ -3993,15 +3817,15 @@ public function import_post($post) class ACF_Compatibility { /** - * __construct + * __construct * - * Sets up the class functionality. + * Sets up the class functionality. * - * @date 30/04/2014 - * @since 5.0.0 + * @date 30/04/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { @@ -4029,162 +3853,160 @@ function init() * @since 5.7.10 * * @param array $wrapper The wrapper attributes array. - * @param array $field The field array. + * @param array $field The field array. */ function field_wrapper_attributes($wrapper, $field) { } /** - * validate_field + * validate_field * - * Adds compatibility with deprecated settings + * Adds compatibility with deprecated settings * - * @date 23/04/2014 - * @since 5.0.0 + * @date 23/04/2014 + * @since 5.0.0 * - * @param array $field The field array. - * @return array $field + * @param array $field The field array. + * @return array $field */ function validate_field($field) { } /** - * validate_textarea_field + * validate_textarea_field * - * Adds compatibility with deprecated settings + * Adds compatibility with deprecated settings * - * @date 23/04/2014 - * @since 5.0.0 + * @date 23/04/2014 + * @since 5.0.0 * - * @param array $field The field array. - * @return array $field + * @param array $field The field array. + * @return array $field */ function validate_textarea_field($field) { } /** - * validate_relationship_field + * validate_relationship_field * - * Adds compatibility with deprecated settings + * Adds compatibility with deprecated settings * - * @date 23/04/2014 - * @since 5.0.0 + * @date 23/04/2014 + * @since 5.0.0 * - * @param array $field The field array. - * @return array $field + * @param array $field The field array. + * @return array $field */ function validate_relationship_field($field) { } /** - * validate_image_field + * validate_image_field * - * Adds compatibility with deprecated settings + * Adds compatibility with deprecated settings * - * @date 23/04/2014 - * @since 5.0.0 + * @date 23/04/2014 + * @since 5.0.0 * - * @param array $field The field array. - * @return array $field + * @param array $field The field array. + * @return array $field */ function validate_image_field($field) { } /** - * validate_wysiwyg_field + * validate_wysiwyg_field * - * Adds compatibility with deprecated settings + * Adds compatibility with deprecated settings * - * @date 23/04/2014 - * @since 5.0.0 + * @date 23/04/2014 + * @since 5.0.0 * - * @param array $field The field array. - * @return array $field + * @param array $field The field array. + * @return array $field */ function validate_wysiwyg_field($field) { } /** - * validate_date_picker_field + * validate_date_picker_field * - * Adds compatibility with deprecated settings + * Adds compatibility with deprecated settings * - * @date 23/04/2014 - * @since 5.0.0 + * @date 23/04/2014 + * @since 5.0.0 * - * @param array $field The field array. - * @return array $field + * @param array $field The field array. + * @return array $field */ function validate_date_picker_field($field) { } /** - * validate_taxonomy_field + * validate_taxonomy_field * - * Adds compatibility with deprecated settings + * Adds compatibility with deprecated settings * - * @date 23/04/2014 - * @since 5.2.7 + * @date 23/04/2014 + * @since 5.2.7 * - * @param array $field The field array. - * @return array $field + * @param array $field The field array. + * @return array $field */ function validate_taxonomy_field($field) { } /** - * validate_date_time_picker_field + * validate_date_time_picker_field * - * Adds compatibility with deprecated settings + * Adds compatibility with deprecated settings * - * @date 23/04/2014 - * @since 5.2.7 + * @date 23/04/2014 + * @since 5.2.7 * - * @param array $field The field array. - * @return array $field + * @param array $field The field array. + * @return array $field */ function validate_date_time_picker_field($field) { } /** - * validate_user_field + * validate_user_field * - * Adds compatibility with deprecated settings + * Adds compatibility with deprecated settings * - * @date 23/04/2014 - * @since 5.2.7 + * @date 23/04/2014 + * @since 5.2.7 * - * @param array $field The field array. - * @return array $field + * @param array $field The field array. + * @return array $field */ function validate_user_field($field) { } /** - * validate_field_group - * - * This function will provide compatibility with ACF4 field groups + * This function will provide compatibility with ACF4 field groups * - * @type function - * @date 23/04/2014 - * @since 5.0.0 + * @type function + * @date 23/04/2014 + * @since 5.0.0 * - * @param array $field_group - * @return $field_group + * @param array $field_group + * @return $field_group */ function validate_field_group($field_group) { } /** - * validate_post_taxonomy_location_rule + * validate_post_taxonomy_location_rule * - * description + * description * - * @date 27/8/18 - * @since 5.7.4 + * @date 27/8/18 + * @since 5.7.4 * - * @param type $var Description. Default. - * @return type Description. + * @param type $var Description. Default. + * @return type Description. */ function validate_post_taxonomy_location_rule($rule) { @@ -4196,92 +4018,80 @@ class acf_fields /** @var array Contains an array of field type instances */ var $types = array(); /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.4.0 + * @type function + * @date 5/03/2014 + * @since 5.4.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * register_field_type - * - * This function will register a field type instance + * This function will register a field type instance * - * @type function - * @date 6/07/2016 - * @since 5.4.0 + * @type function + * @date 6/07/2016 + * @since 5.4.0 * - * @param string $class - * @return void + * @param string $class + * @return void */ function register_field_type($class) { } /** - * get_field_type + * This function will return a field type instance * - * This function will return a field type instance - * - * @type function - * @date 6/07/2016 - * @since 5.4.0 + * @type function + * @date 6/07/2016 + * @since 5.4.0 * - * @param string $name - * @return mixed + * @param string $name + * @return mixed */ function get_field_type($name) { } /** - * is_field_type + * This function will return true if a field type exists * - * This function will return true if a field type exists - * - * @type function - * @date 6/07/2016 - * @since 5.4.0 + * @type function + * @date 6/07/2016 + * @since 5.4.0 * - * @param string $name - * @return mixed + * @param string $name + * @return mixed */ function is_field_type($name) { } /** - * register_field_type_info + * This function will store a basic array of info about the field type + * to later be overriden by the above register_field_type function * - * This function will store a basic array of info about the field type - * to later be overriden by the above register_field_type function - * - * @type function - * @date 29/5/17 - * @since 5.6.0 + * @type function + * @date 29/5/17 + * @since 5.6.0 * - * @param array $info - * @return void + * @param array $info + * @return void */ function register_field_type_info($info) { } /** - * get_field_types - * - * This function will return an array of all field types + * This function will return an array of all field types * - * @type function - * @date 6/07/2016 - * @since 5.4.0 + * @type function + * @date 6/07/2016 + * @since 5.4.0 * - * @param string $name - * @return mixed + * @param string $name + * @return mixed */ function get_field_types() { @@ -4313,8 +4123,6 @@ class acf_field * extending this class, use the `initialize()` method in the child class instead. * * @since 5.0.0 - * - * @return void */ public function __construct() { @@ -4323,8 +4131,6 @@ public function __construct() * Initializes the field type. Overridden in child classes. * * @since 5.6.0 - * - * @return void */ public function initialize() { @@ -4416,11 +4222,10 @@ public function input_admin_l10n($l10n) /** * Add additional validation for fields being updated via the REST API. * - * @param boolean $valid - * @param mixed $value - * @param array $field - * - * @return boolean|WP + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP_Error */ public function validate_rest_value($valid, $value, $field) { @@ -4441,18 +4246,18 @@ public function get_rest_schema(array $field) * under the `_embedded` response property. * * e.g; - * [ - * [ - * 'rel' => 'acf:post', - * 'href' => 'https://example.com/wp-json/wp/v2/posts/497', - * 'embeddable' => true, - * ], - * [ - * 'rel' => 'acf:user', - * 'href' => 'https://example.com/wp-json/wp/v2/users/2', - * 'embeddable' => true, - * ], - * ] + * [ + * [ + * 'rel' => 'acf:post', + * 'href' => 'https://example.com/wp-json/wp/v2/posts/497', + * 'embeddable' => true, + * ], + * [ + * 'rel' => 'acf:user', + * 'href' => 'https://example.com/wp-json/wp/v2/users/2', + * 'embeddable' => true, + * ], + * ] * * @param mixed $value The raw (unformatted) field value. * @param string|integer $post_id @@ -4490,9 +4295,9 @@ class acf_field__accordion extends \acf_field { public $show_in_rest = \false; /** - * initialize + * initialize * - * This function will setup the field type data + * This function will setup the field type data * * @date 30/10/17 * @since 5.6.3 @@ -4504,9 +4309,9 @@ function initialize() { } /** - * render_field + * render_field * - * Create the HTML interface for your field + * Create the HTML interface for your field * * @date 30/10/17 * @since 5.6.3 @@ -4518,32 +4323,28 @@ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field_settings($field) { } /** - * load_field() - * - * This filter is appied to the $field after it is loaded from the database + * This filter is appied to the $field after it is loaded from the database * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options + * @param $field - the field array holding all the field options * - * @return $field - the field array holding all the field options + * @return $field - the field array holding all the field options */ function load_field($field) { @@ -4552,44 +4353,40 @@ function load_field($field) class acf_field_button_group extends \acf_field { /** - * initialize() + * initialize() * - * This function will setup the field type data + * This function will setup the field type data * - * @date 18/9/17 - * @since 5.6.3 + * @date 18/9/17 + * @since 5.6.3 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Creates the field's input HTML + * Creates the field's input HTML * - * @date 18/9/17 - * @since 5.6.3 + * @since 5.6.3 * - * @param array $field The field settings array - * @return void + * @param array $field The field settings array * @phpstan-return void */ - function render_field($field) + public function render_field($field) { } /** - * render_field_settings() + * render_field_settings() * - * Creates the field's settings HTML + * Creates the field's settings HTML * - * @date 18/9/17 - * @since 5.6.3 + * @date 18/9/17 + * @since 5.6.3 * - * @param array $field The field settings array - * @return void + * @param array $field The field settings array + * @return void */ function render_field_settings($field) { @@ -4617,61 +4414,53 @@ function render_field_presentation_settings($field) { } /** - * update_field() - * - * This filter is appied to the $field before it is saved to the database + * This filter is appied to the $field before it is saved to the database * - * @date 18/9/17 - * @since 5.6.3 + * @date 18/9/17 + * @since 5.6.3 * - * @param array $field The field array holding all the field options - * @return $field + * @param array $field The field array holding all the field options + * @return $field */ function update_field($field) { } /** - * load_value() - * - * This filter is appied to the $value after it is loaded from the db + * This filter is appied to the $value after it is loaded from the db * - * @date 18/9/17 - * @since 5.6.3 + * @date 18/9/17 + * @since 5.6.3 * - * @param mixed $value The value found in the database - * @param mixed $post_id The post ID from which the value was loaded from - * @param array $field The field array holding all the field options - * @return $value + * @param mixed $value The value found in the database + * @param mixed $post_id The post ID from which the value was loaded from + * @param array $field The field array holding all the field options + * @return $value */ function load_value($value, $post_id, $field) { } /** - * translate_field - * - * This function will translate field settings + * This function will translate field settings * - * @date 18/9/17 - * @since 5.6.3 + * @date 18/9/17 + * @since 5.6.3 * - * @param array $field The field array holding all the field options - * @return $field + * @param array $field The field array holding all the field options + * @return $field */ function translate_field($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @date 18/9/17 - * @since 5.6.3 + * @date 18/9/17 + * @since 5.6.3 * - * @param mixed $value The value found in the database - * @param mixed $post_id The post ID from which the value was loaded from - * @param array $field The field array holding all the field options - * @return $value + * @param mixed $value The value found in the database + * @param mixed $post_id The post ID from which the value was loaded from + * @param array $field The field array holding all the field options + * @return $value */ function format_value($value, $post_id, $field) { @@ -4689,48 +4478,42 @@ function get_rest_schema(array $field) class acf_field_checkbox extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param array $field the $field being rendered + * @param array $field the $field being rendered * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param array $field the $field being edited - * @return void + * @param array $field the $field being edited + * @return void */ function render_field($field) { } /** - * render_field_choices - * - * description + * description * - * @type function - * @date 15/7/17 - * @since 5.6.0 + * @type function + * @date 15/7/17 + * @since 5.6.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function render_field_choices($field) { @@ -4738,45 +4521,39 @@ function render_field_choices($field) /** * Validates values for the checkbox field * - * @date 09/12/2022 * @since 6.0.0 * - * @param bool $valid If the field is valid. - * @param mixed $value The value to validate. - * @param array $field The main field array. - * @param string $input The input element's name attribute. - * - * @return bool + * @param boolean $valid If the field is valid. + * @param mixed $value The value to validate. + * @param array $field The main field array. + * @param string $input The input element's name attribute. + * @return boolean */ - function validate_value($valid, $value, $field, $input) + public function validate_value($valid, $value, $field, $input) { } /** - * render_field_toggle - * - * description + * description * - * @type function - * @date 15/7/17 - * @since 5.6.0 + * @type function + * @date 15/7/17 + * @since 5.6.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function render_field_toggle($field) { } /** - * render_field_custom - * - * description + * description * - * @type function - * @date 15/7/17 - * @since 5.6.0 + * @type function + * @date 15/7/17 + * @since 5.6.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function render_field_custom($field) { @@ -4785,16 +4562,14 @@ function walk($choices = array(), $args = array(), $depth = 0) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -4822,69 +4597,61 @@ function render_field_presentation_settings($field) { } /** - * update_field() + * This filter is appied to the $field before it is saved to the database * - * This filter is appied to the $field before it is saved to the database + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @param $field - the field array holding all the field options + * @param $post_id - the field group ID (post_type = acf) * - * @param $field - the field array holding all the field options - * @param $post_id - the field group ID (post_type = acf) - * - * @return $field - the modified field + * @return $field - the modified field */ function update_field($field) { } /** - * update_value() - * - * This filter is appied to the $value before it is updated in the db + * This filter is appied to the $value before it is updated in the db * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $post_id - the $post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param $value - the value which will be saved in the database + * @param $post_id - the post_id of which the value will be saved + * @param $field - the field array holding all the field options * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { } /** - * translate_field - * - * This function will translate field settings + * This function will translate field settings * - * @type function - * @date 8/03/2016 - * @since 5.3.2 + * @type function + * @date 8/03/2016 + * @since 5.3.2 * - * @param array $field - * @return $field + * @param array $field + * @return $field */ function translate_field($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { @@ -4902,60 +4669,52 @@ public function get_rest_schema(array $field) class acf_field_color_picker extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * input_admin_enqueue_scripts - * - * description + * description * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function input_admin_enqueue_scripts() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -4964,13 +4723,11 @@ function render_field_settings($field) * Format the value for use in templates. At this stage, the value has been loaded from the * database and is being returned by an API function such as get_field(), the_field(), etc. * - * @since 5.10 - * @date 15/12/20 - * - * @param mixed $value - * @param int $post_id - * @param array $field + * @since 5.10 * + * @param mixed $value The field value + * @param integer $post_id The post ID + * @param array $field The field array * @return string|array */ public function format_value($value, $post_id, $field) @@ -4980,101 +4737,91 @@ public function format_value($value, $post_id, $field) class acf_field_date_picker extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * input_admin_enqueue_scripts - * - * description + * description * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return void */ function input_admin_enqueue_scripts() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { } /** - * This filter is applied to the $field after it is loaded from the database - * and ensures the return and display values are set. + * This filter is applied to the $field after it is loaded from the database + * and ensures the return and display values are set. * - * @type filter - * @since 5.11.0 - * @date 28/09/21 - * - * @param array $field The field array holding all the field options. + * @type filter + * @since 5.11.0 + * @date 28/09/21 * - * @return array + * @param array $field The field array holding all the field options. + * @return array */ - function load_field($field) + public function load_field($field) { } /** * Return the schema array for the REST API. * - * @param array $field + * @param array $field The field array * @return array */ public function get_rest_schema(array $field) @@ -5083,9 +4830,9 @@ public function get_rest_schema(array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -5095,95 +4842,82 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_date_and_time_picker extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * input_admin_enqueue_scripts - * - * description + * description * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return void */ function input_admin_enqueue_scripts() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @type filter + * @since 3.6 * - * @return mixed $value the modified value + * @param mixed $value The value which was loaded from the database + * @param mixed $post_id The post_id from which the value was loaded + * @param array $field The field array holding all the field options + * @return mixed $value The modified value */ - function format_value($value, $post_id, $field) + public function format_value($value, $post_id, $field) { } /** - * This filter is applied to the $field after it is loaded from the database - * and ensures the return and display values are set. - * - * @type filter - * @since 5.11.0 - * @date 28/09/21 + * This filter is applied to the $field after it is loaded from the database + * and ensures the return and display values are set. * - * @param array $field The field array holding all the field options. + * @type filter + * @since 5.11.0 * - * @return array + * @param array $field The field array holding all the field options. + * @return array */ - function load_field($field) + public function load_field($field) { } /** @@ -5199,45 +4933,39 @@ public function get_rest_schema(array $field) class acf_field_email extends \acf_field { /** - * initialize - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -5258,12 +4986,11 @@ function render_field_presentation_settings($field) * FALSE or a string is returned, the input value is invalid and the user is shown a * notice. If a string is returned, the string is show as the message text. * - * @param bool $valid Whether the value is valid. - * @param mixed $value The field value. - * @param array $field The field array. - * @param string $input The request variable name for the inbound field. - * - * @return bool|string + * @param boolean $valid Whether the value is valid. + * @param mixed $value The field value. + * @param array $field The field array. + * @param string $input The request variable name for the inbound field. + * @return boolean|string */ public function validate_value($valid, $value, $field, $input) { @@ -5281,60 +5008,52 @@ public function get_rest_schema(array $field) class acf_field_file extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * input_admin_enqueue_scripts - * - * description + * description * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function input_admin_enqueue_scripts() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -5351,67 +5070,61 @@ function render_field_validation_settings($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { } /** - * get_media_item_args - * - * description + * description * - * @type function - * @date 27/01/13 - * @since 3.6.0 + * @type function + * @date 27/01/13 + * @since 3.6.0 * - * @param array $vars - * @return $vars + * @param array $vars + * @return $vars */ function get_media_item_args($vars) { } /** - * update_value() + * This filter is appied to the $value before it is updated in the db * - * This filter is appied to the $value before it is updated in the db - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $post_id - the $post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param $value - the value which will be saved in the database + * @param $post_id - the post_id of which the value will be saved + * @param $field - the field array holding all the field options * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { } /** - * validate_value + * validate_value * - * This function will validate a basic file input + * This function will validate a basic file input * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @type function + * @date 11/02/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function validate_value($valid, $value, $field, $input) { @@ -5419,11 +5132,10 @@ function validate_value($valid, $value, $field, $input) /** * Validates file fields updated via the REST API. * - * @param bool $valid - * @param int $value - * @param array $field - * - * @return bool|WP_Error + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP_Error */ public function validate_rest_value($valid, $value, $field) { @@ -5440,9 +5152,9 @@ public function get_rest_schema(array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -5453,60 +5165,53 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_google_map extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * input_admin_enqueue_scripts - * - * description + * description * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return void */ function input_admin_enqueue_scripts() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -5519,28 +5224,26 @@ function render_field_settings($field) * @date 16/10/19 * @since 5.8.1 * - * @param mixed $value The value loaded from the database. + * @param mixed $value The value loaded from the database. * @param mixed $post_id The post ID where the value is saved. - * @param array $field The field settings array. + * @param array $field The field settings array. * @return array|false */ function load_value($value, $post_id, $field) { } /** - * update_value() - * - * This filter is appied to the $value before it is updated in the db + * This filter is appied to the $value before it is updated in the db * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $post_id - the $post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param $value - the value which will be saved in the database + * @param $post_id - the post_id of which the value will be saved + * @param $field - the field array holding all the field options * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { @@ -5557,9 +5260,9 @@ public function get_rest_schema(array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -5570,49 +5273,43 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field__group extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * load_field() + * This filter is appied to the $field after it is loaded from the database * - * This filter is appied to the $field after it is loaded from the database - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options + * @param $field - the field array holding all the field options * - * @return $field - the field array holding all the field options + * @return $field - the field array holding all the field options */ function load_field($field) { } /** - * load_value() - * - * This filter is applied to the $value after it is loaded from the db + * This filter is applied to the $value after it is loaded from the db * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value found in the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options - * @return $value + * @param mixed $value the value found in the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options + * @return $value */ function load_value($value, $post_id, $field) { @@ -5623,135 +5320,119 @@ function load_value($value, $post_id, $field) * @type filter * @since 3.6 * - * @param mixed $value The value which was loaded from the database. - * @param mixed $post_id The $post_id from which the value was loaded. - * @param array $field The field array holding all the field options. - * @param boolean $escape_html Should the field return a HTML safe formatted value. - * + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. + * @param boolean $escape_html Should the field return a HTML safe formatted value. * @return mixed the modified value */ public function format_value($value, $post_id, $field, $escape_html = \false) { } /** - * update_value() + * This filter is appied to the $value before it is updated in the db * - * This filter is appied to the $value before it is updated in the db - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $field - the field array holding all the field options - * @param $post_id - the $post_id of which the value will be saved + * @param $value - the value which will be saved in the database + * @param $field - the field array holding all the field options + * @param $post_id - the post_id of which the value will be saved * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { } /** - * prepare_field_for_db - * - * This function will modify sub fields ready for update / load + * This function will modify sub fields ready for update / load * - * @type function - * @date 4/11/16 - * @since 5.5.0 + * @type function + * @date 4/11/16 + * @since 5.5.0 * - * @param array $field - * @return $field + * @param array $field + * @return $field */ function prepare_field_for_db($field) { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 + * @phpstan-return void */ function render_field($field) { } /** - * render_field_block - * - * description + * description * - * @type function - * @date 12/07/2016 - * @since 5.4.0 + * @type function + * @date 12/07/2016 + * @since 5.4.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function render_field_block($field) { } /** - * render_field_table - * - * description + * description * - * @type function - * @date 12/07/2016 - * @since 5.4.0 + * @type function + * @date 12/07/2016 + * @since 5.4.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function render_field_table($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { } /** - * validate_value - * - * description + * description * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @type function + * @date 11/02/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function validate_value($valid, $value, $field, $input) { } /** - * duplicate_field() + * This filter is appied to the $field before it is duplicated and saved to the database * - * This filter is appied to the $field before it is duplicated and saved to the database - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options + * @param $field - the field array holding all the field options * - * @return $field - the modified field + * @return $field - the modified field */ function duplicate_field($field) { @@ -5785,31 +5466,29 @@ function prepare_field_for_import($field) { } /** - * delete_value - * - * Called when deleting this field's value. + * Called when deleting this field's value. * - * @date 1/07/2015 - * @since 5.2.3 + * @date 1/07/2015 + * @since 5.2.3 * - * @param mixed $post_id The post ID being saved - * @param string $meta_key The field name as seen by the DB - * @param array $field The field settings - * @return void + * @param mixed $post_id The post ID being saved + * @param string $meta_key The field name as seen by the DB + * @param array $field The field settings + * @return void */ function delete_value($post_id, $meta_key, $field) { } /** - * delete_field + * delete_field * - * Called when deleting a field of this type. + * Called when deleting a field of this type. * - * @date 8/11/18 - * @since 5.8.0 + * @date 8/11/18 + * @since 5.8.0 * - * @param arra $field The field settings. - * @return void + * @param arra $field The field settings. + * @return void */ function delete_field($field) { @@ -5826,9 +5505,9 @@ public function get_rest_schema(array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param int|string $post_id - * @param array $field + * @param mixed $value + * @param integer|string $post_id + * @param array $field * @return array|mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -5838,31 +5517,27 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_image extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * input_admin_enqueue_scripts - * - * description + * description * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function input_admin_enqueue_scripts() { @@ -5880,16 +5555,14 @@ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -5917,79 +5590,72 @@ function render_field_presentation_settings($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { } /** - * get_media_item_args - * - * description + * description * - * @type function - * @date 27/01/13 - * @since 3.6.0 + * @type function + * @date 27/01/13 + * @since 3.6.0 * - * @param array $vars - * @return $vars + * @param array $vars + * @return $vars */ function get_media_item_args($vars) { } /** - * update_value() - * - * This filter is appied to the $value before it is updated in the db + * This filter is appied to the $value before it is updated in the db * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $post_id - the $post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param $value - the value which will be saved in the database + * @param $post_id - the post_id of which the value will be saved + * @param $field - the field array holding all the field options * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { } /** - * validate_value + * This function will validate a basic file input * - * This function will validate a basic file input - * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @type function + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param boolean $valid The current validity status. + * @param mixed $value The field value. + * @param array $field The field array. + * @param string $input The name of the input in the POST object. + * @return boolean The validity status. */ - function validate_value($valid, $value, $field, $input) + public function validate_value($valid, $value, $field, $input) { } /** * Additional validation for the image field when submitted via REST. * - * @param bool $valid - * @param int $value - * @param array $field - * - * @return bool|WP_Error + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP_Error */ public function validate_rest_value($valid, $value, $field) { @@ -5997,7 +5663,7 @@ public function validate_rest_value($valid, $value, $field) /** * Return the schema array for the REST API. * - * @param array $field + * @param array $field The field array * @return array */ public function get_rest_schema(array $field) @@ -6006,9 +5672,9 @@ public function get_rest_schema(array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value The field value + * @param string|integer $post_id The post ID + * @param array $field The field array * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -6018,111 +5684,96 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_link extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * get_link - * - * description + * description * - * @type function - * @date 16/5/17 - * @since 5.5.13 + * @type function + * @date 16/5/17 + * @since 5.5.13 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function get_link($value = '') { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 */ - function render_field($field) + public function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { } /** - * validate_value - * - * description + * description * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @type function + * @date 11/02/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function validate_value($valid, $value, $field, $input) { } /** - * update_value() - * - * This filter is appied to the $value before it is updated in the db + * This filter is appied to the $value before it is updated in the db * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $post_id - the $post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param $value - the value which will be saved in the database + * @param $post_id - the post_id of which the value will be saved + * @param $field - the field array holding all the field options * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { @@ -6141,76 +5792,66 @@ class acf_field_message extends \acf_field { public $show_in_rest = \false; /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field_settings($field) { } /** - * translate_field - * - * This function will translate field settings + * This function will translate field settings * - * @type function - * @date 8/03/2016 - * @since 5.3.2 + * @type function + * @date 8/03/2016 + * @since 5.3.2 * - * @param array $field - * @return $field + * @param array $field + * @return $field */ function translate_field($field) { } /** - * load_field() - * - * This filter is appied to the $field after it is loaded from the database + * This filter is appied to the $field after it is loaded from the database * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options + * @param $field - the field array holding all the field options * - * @return $field - the field array holding all the field options + * @return $field - the field array holding all the field options */ function load_field($field) { @@ -6219,45 +5860,39 @@ function load_field($field) class acf_field_number extends \acf_field { /** - * initialize - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -6285,34 +5920,30 @@ function render_field_presentation_settings($field) { } /** - * validate_value - * - * description + * description * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @type function + * @date 11/02/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function validate_value($valid, $value, $field, $input) { } /** - * update_value() - * - * This filter is appied to the $value before it is updated in the db + * This filter is appied to the $value before it is updated in the db * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $field - the field array holding all the field options - * @param $post_id - the $post_id of which the value will be saved + * @param $value - the value which will be saved in the database + * @param $field - the field array holding all the field options + * @param $post_id - the post_id of which the value will be saved * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { @@ -6329,9 +5960,9 @@ public function get_rest_schema(array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -6342,31 +5973,27 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_oembed extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * prepare_field + * This function will prepare the field for input * - * This function will prepare the field for input - * - * @type function - * @date 14/2/17 - * @since 5.5.8 + * @type function + * @date 14/2/17 + * @since 5.5.8 * - * @param array $field - * @return int + * @param array $field + * @return int */ function prepare_field($field) { @@ -6377,69 +6004,64 @@ function prepare_field($field) * @date 24/01/2014 * @since 5.0.0 * - * @param string $url The URL that should be embedded. - * @param int|string $width Optional maxwidth value passed to the provider URL. - * @param int|string $height Optional maxheight value passed to the provider URL. + * @param string $url The URL that should be embedded. + * @param integer|string $width Optional maxwidth value passed to the provider URL. + * @param integer|string $height Optional maxheight value passed to the provider URL. * @return string|false The embedded HTML on success, false on failure. */ function wp_oembed_get($url = '', $width = 0, $height = 0) { } /** - * ajax_query - * - * description + * description * - * @type function - * @date 24/10/13 - * @since 5.0.0 + * @type function + * @date 24/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return never */ function ajax_query() { } /** - * get_ajax_query - * - * This function will return an array of data formatted for use in a select2 AJAX response + * This function will return an array of data formatted for use in a select2 AJAX response * - * @type function - * @date 15/10/2014 - * @since 5.0.9 + * @type function + * @date 15/10/2014 + * @since 5.0.9 * - * @param array $options - * @return array + * @param array $options + * @return array */ function get_ajax_query($args = array()) { } /** - * render_field() + * render_field() * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field_settings($field) { @@ -6450,13 +6072,12 @@ function render_field_settings($field) * @type filter * @since 3.6 * - * @param mixed $value The value which was loaded from the database. - * @param mixed $post_id The $post_id from which the value was loaded. - * @param array $field The field array holding all the field options. - * + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. * @return mixed the modified value */ - function format_value($value, $post_id, $field) + public function format_value($value, $post_id, $field) { } /** @@ -6472,33 +6093,30 @@ public function get_rest_schema(array $field) class acf_field_output extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param array $field the $field being rendered + * @param array $field the $field being rendered * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param array $field the $field being edited - * @return void + * @param array $field the $field being edited + * @return void + * @phpstan-return void */ function render_field($field) { @@ -6507,108 +6125,94 @@ function render_field($field) class acf_field_page_link extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * ajax_query - * - * description + * description * - * @type function - * @date 24/10/13 - * @since 5.0.0 + * @type function + * @date 24/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function ajax_query() { } /** - * get_post_result + * This function will return an array containing id, text and maybe description data * - * This function will return an array containing id, text and maybe description data - * - * @type function - * @date 7/07/2016 - * @since 5.4.0 + * @type function + * @date 7/07/2016 + * @since 5.4.0 * - * @param mixed $id - * @param string $text - * @return array + * @param mixed $id + * @param string $text + * @return array */ function get_post_result($id, $text) { } /** - * get_post_title - * - * This function returns the HTML for a result + * This function returns the HTML for a result * - * @type function - * @date 1/11/2013 - * @since 5.0.0 + * @type function + * @date 1/11/2013 + * @since 5.0.0 * - * @param object $post - * @param array $field - * @param int $post_id the post_id to which this value is saved to - * @return string + * @param object $post + * @param array $field + * @param int $post_id the post_id to which this value is saved to + * @return string */ function get_post_title($post, $field, $post_id = 0, $is_search = 0) { } /** - * get_posts + * This function will return an array of posts for a given field value * - * This function will return an array of posts for a given field value - * - * @type function - * @date 13/06/2014 - * @since 5.0.0 + * @type function + * @date 13/06/2014 + * @since 5.0.0 * - * @param array $value - * @return $value + * @param array $value + * @return $value */ function get_posts($value, $field) { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -6625,37 +6229,33 @@ function render_field_validation_settings($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { } /** - * update_value() + * This filter is appied to the $value before it is updated in the db * - * This filter is appied to the $value before it is updated in the db - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $post_id - the $post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param $value - the value which will be saved in the database + * @param $post_id - the post_id of which the value will be saved + * @param $field - the field array holding all the field options * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { @@ -6663,11 +6263,10 @@ function update_value($value, $post_id, $field) /** * Validates page link fields updated via the REST API. * - * @param bool $valid - * @param int $value - * @param array $field - * - * @return bool|WP_Error + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP_Error */ public function validate_rest_value($valid, $value, $field) { @@ -6683,9 +6282,9 @@ public function get_rest_schema(array $field) } /** * @see \acf_field::get_rest_links() - * @param mixed $value The raw (unformatted) field value. - * @param int|string $post_id - * @param array $field + * @param mixed $value The raw (unformatted) field value. + * @param integer|string $post_id + * @param array $field * @return array */ public function get_rest_links($value, $post_id, array $field) @@ -6694,9 +6293,9 @@ public function get_rest_links($value, $post_id, array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -6706,45 +6305,39 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_password extends \acf_field { /** - * initialize - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -6764,103 +6357,91 @@ function render_field_presentation_settings($field) class acf_field_post_object extends \acf_field { /** - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 */ public function initialize() { } /** - * ajax_query - * - * description + * description * - * @type function - * @date 24/10/13 - * @since 5.0.0 + * @type function + * @date 24/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function ajax_query() { } /** - * get_ajax_query - * - * This function will return an array of data formatted for use in a select2 AJAX response + * This function will return an array of data formatted for use in a select2 AJAX response * - * @type function - * @date 15/10/2014 - * @since 5.0.9 + * @type function + * @date 15/10/2014 + * @since 5.0.9 * - * @param array $options - * @return array + * @param array $options + * @return array */ function get_ajax_query($options = array()) { } /** - * get_post_result + * This function will return an array containing id, text and maybe description data * - * This function will return an array containing id, text and maybe description data - * - * @type function - * @date 7/07/2016 - * @since 5.4.0 + * @type function + * @date 7/07/2016 + * @since 5.4.0 * - * @param mixed $id - * @param string $text - * @return array + * @param mixed $id + * @param string $text + * @return array */ function get_post_result($id, $text) { } /** - * get_post_title - * - * This function returns the HTML for a result + * This function returns the HTML for a result * - * @type function - * @date 1/11/2013 - * @since 5.0.0 + * @type function + * @date 1/11/2013 + * @since 5.0.0 * - * @param object $post - * @param array $field - * @param int $post_id the post_id to which this value is saved to - * @return string + * @param object $post + * @param array $field + * @param int $post_id the post_id to which this value is saved to + * @return string */ function get_post_title($post, $field, $post_id = 0, $is_search = 0) { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -6888,36 +6469,32 @@ public function render_field_advanced_settings($field) { } /** - * load_value() - * - * This filter is applied to the $value after it is loaded from the db + * This filter is applied to the $value after it is loaded from the db * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value found in the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options - * @return $value + * @param mixed $value the value found in the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options + * @return $value */ function load_value($value, $post_id, $field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { @@ -6927,26 +6504,23 @@ function format_value($value, $post_id, $field) * * @since 3.6 * - * @param mixed $value The value which will be saved in the database. - * @param int $post_id The post_id of which the value will be saved. - * @param array $field The field array holding all the field options. - * - * @return mixed $value The modified value. + * @param mixed $value The value which will be saved in the database. + * @param integer $post_id The post_id of which the value will be saved. + * @param array $field The field array holding all the field options. + * @return mixed $value The modified value. */ public function update_value($value, $post_id, $field) { } /** - * get_posts - * - * This function will return an array of posts for a given field value + * This function will return an array of posts for a given field value * - * @type function - * @date 13/06/2014 - * @since 5.0.0 + * @type function + * @date 13/06/2014 + * @since 5.0.0 * - * @param array $value - * @return $value + * @param array $value + * @return $value */ function get_posts($value, $field) { @@ -6954,11 +6528,10 @@ function get_posts($value, $field) /** * Validates post object fields updated via the REST API. * - * @param bool $valid - * @param int $value - * @param array $field - * - * @return bool|WP_Error + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP_Error */ public function validate_rest_value($valid, $value, $field) { @@ -6974,9 +6547,9 @@ public function get_rest_schema(array $field) } /** * @see \acf_field::get_rest_links() - * @param mixed $value The raw (unformatted) field value. - * @param int|string $post_id - * @param array $field + * @param mixed $value The raw (unformatted) field value. + * @param integer|string $post_id + * @param array $field * @return array */ public function get_rest_links($value, $post_id, array $field) @@ -6985,9 +6558,9 @@ public function get_rest_links($value, $post_id, array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -6997,48 +6570,43 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_radio extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param array $field the $field being rendered + * @param array $field the $field being rendered * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param array $field the $field being edited - * @return void + * @param array $field the $field being edited + * @return void + * @phpstan-return void */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -7066,88 +6634,78 @@ function render_field_presentation_settings($field) { } /** - * update_field() - * - * This filter is appied to the $field before it is saved to the database + * This filter is appied to the $field before it is saved to the database * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options - * @param $post_id - the field group ID (post_type = acf) + * @param $field - the field array holding all the field options + * @param $post_id - the field group ID (post_type = acf) * - * @return $field - the modified field + * @return $field - the modified field */ function update_field($field) { } /** - * update_value() - * - * This filter is appied to the $value before it is updated in the db + * This filter is appied to the $value before it is updated in the db * - * @type filter - * @since 3.6 - * @date 23/01/13 - * @todo Fix bug where $field was found via json and has no ID + * @type filter + * @since 3.6 + * @date 23/01/13 + * @todo Fix bug where $field was found via json and has no ID * - * @param $value - the value which will be saved in the database - * @param $post_id - the $post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param $value - the value which will be saved in the database + * @param $post_id - the post_id of which the value will be saved + * @param $field - the field array holding all the field options * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { } /** - * load_value() - * - * This filter is appied to the $value after it is loaded from the db + * This filter is appied to the $value after it is loaded from the db * - * @type filter - * @since 5.2.9 - * @date 23/01/13 + * @type filter + * @since 5.2.9 + * @date 23/01/13 * - * @param $value - the value found in the database - * @param $post_id - the $post_id from which the value was loaded from - * @param $field - the field array holding all the field options + * @param $value - the value found in the database + * @param $post_id - the post_id from which the value was loaded from + * @param $field - the field array holding all the field options * - * @return $value - the value to be saved in te database + * @return $value - the value to be saved in te database */ function load_value($value, $post_id, $field) { } /** - * translate_field - * - * This function will translate field settings + * This function will translate field settings * - * @type function - * @date 8/03/2016 - * @since 5.3.2 + * @type function + * @date 8/03/2016 + * @since 5.3.2 * - * @param array $field - * @return $field + * @param array $field + * @return $field */ function translate_field($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { @@ -7165,45 +6723,39 @@ function get_rest_schema(array $field) class acf_field_range extends \acf_field_number { /** - * initialize - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -7242,9 +6794,9 @@ public function get_rest_schema(array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -7254,118 +6806,104 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_relationship extends \acf_field { /** - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 */ public function initialize() { } /** - * input_admin_enqueue_scripts - * - * description + * description * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function input_admin_enqueue_scripts() { } /** - * ajax_query - * - * description + * description * - * @type function - * @date 24/10/13 - * @since 5.0.0 + * @type function + * @date 24/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function ajax_query() { } /** - * get_ajax_query - * - * This function will return an array of data formatted for use in a select2 AJAX response + * This function will return an array of data formatted for use in a select2 AJAX response * - * @type function - * @date 15/10/2014 - * @since 5.0.9 + * @type function + * @date 15/10/2014 + * @since 5.0.9 * - * @param array $options - * @return array + * @param array $options + * @return array */ function get_ajax_query($options = array()) { } /** - * get_post_result - * - * This function will return an array containing id, text and maybe description data + * This function will return an array containing id, text and maybe description data * - * @type function - * @date 7/07/2016 - * @since 5.4.0 + * @type function + * @date 7/07/2016 + * @since 5.4.0 * - * @param mixed $id - * @param string $text - * @return array + * @param mixed $id + * @param string $text + * @return array */ function get_post_result($id, $text) { } /** - * get_post_title + * This function returns the HTML for a result * - * This function returns the HTML for a result - * - * @type function - * @date 1/11/2013 - * @since 5.0.0 + * @type function + * @date 1/11/2013 + * @since 5.0.0 * - * @param object $post - * @param array $field - * @param int $post_id the post_id to which this value is saved to - * @return string + * @param object $post + * @param array $field + * @param int $post_id the post_id to which this value is saved to + * @return string */ function get_post_title($post, $field, $post_id = 0, $is_search = 0) { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -7404,34 +6942,30 @@ public function render_field_advanced_settings($field) { } /** - * format_value() + * This filter is applied to the $value after it is loaded from the db and before it is returned to the template * - * This filter is applied to the $value after it is loaded from the db and before it is returned to the template - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { } /** - * validate_value - * - * description + * description * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @type function + * @date 11/02/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function validate_value($valid, $value, $field, $input) { @@ -7441,9 +6975,9 @@ function validate_value($valid, $value, $field, $input) * * @since 3.6 * - * @param mixed $value The value which will be saved in the database. - * @param int $post_id The post_id of which the value will be saved. - * @param array $field The field array holding all the field options. + * @param mixed $value The value which will be saved in the database. + * @param integer $post_id The post_id of which the value will be saved. + * @param array $field The field array holding all the field options. * * @return mixed $value The modified value. */ @@ -7453,11 +6987,10 @@ public function update_value($value, $post_id, $field) /** * Validates relationship fields updated via the REST API. * - * @param bool $valid - * @param int $value - * @param array $field - * - * @return bool|WP_Error + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP_Error */ public function validate_rest_value($valid, $value, $field) { @@ -7473,9 +7006,9 @@ public function get_rest_schema(array $field) } /** * @see \acf_field::get_rest_links() - * @param mixed $value The raw (unformatted) field value. - * @param int|string $post_id - * @param array $field + * @param mixed $value The raw (unformatted) field value. + * @param integer|string $post_id + * @param array $field * @return array */ public function get_rest_links($value, $post_id, array $field) @@ -7484,9 +7017,9 @@ public function get_rest_links($value, $post_id, array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -7496,46 +7029,41 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_select extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * input_admin_enqueue_scripts - * - * description + * description * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return void */ function input_admin_enqueue_scripts() { } /** - * ajax_query - * - * description + * description * - * @type function - * @date 24/10/13 - * @since 5.0.0 + * @type function + * @date 24/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function ajax_query() { @@ -7552,30 +7080,26 @@ public function get_ajax_query($options = array()) { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -7603,86 +7127,77 @@ function render_field_presentation_settings($field) { } /** - * load_value() - * - * This filter is applied to the $value after it is loaded from the db + * This filter is applied to the $value after it is loaded from the db * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value found in the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options - * @return $value + * @param mixed $value the value found in the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options + * @return $value */ function load_value($value, $post_id, $field) { } /** - * update_field() * - * This filter is appied to the $field before it is saved to the database + * This filter is appied to the $field before it is saved to the database * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options - * @param $post_id - the field group ID (post_type = acf) + * @param $field - the field array holding all the field options + * @param $post_id - the field group ID (post_type = acf) * - * @return $field - the modified field + * @return $field - the modified field */ function update_field($field) { } /** - * update_value() + * This filter is appied to the $value before it is updated in the db * - * This filter is appied to the $value before it is updated in the db - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $post_id - the $post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param $value - the value which will be saved in the database + * @param $post_id - the post_id of which the value will be saved + * @param $field - the field array holding all the field options * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { } /** - * translate_field + * This function will translate field settings * - * This function will translate field settings - * - * @type function - * @date 8/03/2016 - * @since 5.3.2 + * @type function + * @date 8/03/2016 + * @since 5.3.2 * - * @param array $field - * @return $field + * @param array $field + * @return $field */ function translate_field($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { @@ -7693,11 +7208,10 @@ function format_value_single($value, $post_id, $field) /** * Validates select fields updated via the REST API. * - * @param bool $valid - * @param int $value - * @param array $field - * - * @return bool|WP_Error + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP_Error */ public function validate_rest_value($valid, $value, $field) { @@ -7726,46 +7240,40 @@ public function get_rest_schema(array $field) class acf_field_separator extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * load_field() - * - * This filter is appied to the $field after it is loaded from the database + * This filter is appied to the $field after it is loaded from the database * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options + * @param $field - the field array holding all the field options * - * @return $field - the field array holding all the field options + * @return $field - the field array holding all the field options */ function load_field($field) { @@ -7775,61 +7283,53 @@ class acf_field_tab extends \acf_field { public $show_in_rest = \false; /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field_settings($field) { } /** - * load_field() + * This filter is appied to the $field after it is loaded from the database * - * This filter is appied to the $field after it is loaded from the database - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options + * @param $field - the field array holding all the field options * - * @return $field - the field array holding all the field options + * @return $field - the field array holding all the field options */ function load_field($field) { @@ -7840,41 +7340,37 @@ class acf_field_taxonomy extends \acf_field // vars var $save_post_terms = array(); /** - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 */ public function initialize() { } /** - * ajax_query - * - * description + * description * - * @type function - * @date 24/10/13 - * @since 5.0.0 + * @type function + * @date 24/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function ajax_query() { } /** - * get_ajax_query - * - * This function will return an array of data formatted for use in a select2 AJAX response + * This function will return an array of data formatted for use in a select2 AJAX response * - * @type function - * @date 15/10/2014 - * @since 5.0.9 + * @type function + * @date 15/10/2014 + * @since 5.0.9 * - * @param array $options - * @return array + * @param array $options + * @return array */ function get_ajax_query($options = array()) { @@ -7885,8 +7381,8 @@ function get_ajax_query($options = array()) * @date 1/11/2013 * @since 5.0.0 * - * @param WP_Term $term The term object. - * @param array $field The field settings. + * @param WP_Term $term The term object. + * @param array $field The field settings. * @param mixed $post_id The post_id being edited. * @return string */ @@ -7894,34 +7390,30 @@ function get_term_title($term, $field, $post_id = 0) { } /** - * get_terms + * This function will return an array of terms for a given field value * - * This function will return an array of terms for a given field value - * - * @type function - * @date 13/06/2014 - * @since 5.0.0 + * @type function + * @date 13/06/2014 + * @since 5.0.0 * - * @param array $value - * @return $value + * @param array $value + * @return $value */ function get_terms($value, $taxonomy = 'category') { } /** - * load_value() + * This filter is appied to the $value after it is loaded from the db * - * This filter is appied to the $value after it is loaded from the db - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value found in the database - * @param $post_id - the $post_id from which the value was loaded from - * @param $field - the field array holding all the field options + * @param $value - the value found in the database + * @param $post_id - the post_id from which the value was loaded from + * @param $field - the field array holding all the field options * - * @return $value - the value to be saved in te database + * @return $value - the value to be saved in te database */ function load_value($value, $post_id, $field) { @@ -7931,10 +7423,9 @@ function load_value($value, $post_id, $field) * * @since 3.6 * - * @param mixed $value The value which will be saved in the database. - * @param int $post_id The post_id of which the value will be saved. - * @param array $field The field array holding all the field options. - * + * @param mixed $value The value which will be saved in the database. + * @param integer $post_id The post_id of which the value will be saved. + * @param array $field The field array holding all the field options. * @return mixed $value The modified value. */ public function update_value($value, $post_id, $field) @@ -7943,83 +7434,74 @@ public function update_value($value, $post_id, $field) /** * This function will save any terms in the save_post_terms array * - * @date 26/11/2014 * @since 5.0.9 * - * @param int $post_id - * + * @param mixed $post_id The ACF post ID to save to. * @return void */ - function save_post($post_id) + public function save_post($post_id) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data + * @phpstan-return void */ function render_field($field) { } /** - * render_field_select() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_select($field) { } /** - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @since 3.6 + * @since 3.6 * - * @param array $field an array holding all the field's data. + * @param array $field an array holding all the field's data. */ public function render_field_checkbox($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -8036,16 +7518,15 @@ public function render_field_advanced_settings($field) { } /** - * ajax_add_term - * - * description + * description * - * @type function - * @date 17/04/2015 - * @since 5.2.3 + * @type function + * @date 17/04/2015 + * @since 5.2.3 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return never */ function ajax_add_term() { @@ -8061,9 +7542,9 @@ public function get_rest_schema(array $field) } /** * @see \acf_field::get_rest_links() - * @param mixed $value The raw (unformatted) field value. - * @param int|string $post_id - * @param array $field + * @param mixed $value The raw (unformatted) field value. + * @param integer|string $post_id + * @param array $field * @return array */ public function get_rest_links($value, $post_id, array $field) @@ -8073,45 +7554,39 @@ public function get_rest_links($value, $post_id, array $field) class acf_field_text extends \acf_field { /** - * initialize - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field_settings($field) { @@ -8168,45 +7643,39 @@ function get_rest_schema(array $field) class acf_field_textarea extends \acf_field { /** - * initialize - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field_settings($field) { @@ -8234,19 +7703,17 @@ function render_field_presentation_settings($field) { } /** - * format_value() - * - * This filter is applied to the $value after it is loaded from the db and before it is returned to the template + * This filter is applied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { @@ -8281,86 +7748,75 @@ function get_rest_schema(array $field) class acf_field_time_picker extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @return mixed $value the modified value + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options + * @return mixed $value the modified value */ - function format_value($value, $post_id, $field) + public function format_value($value, $post_id, $field) { } /** - * This filter is applied to the $field after it is loaded from the database - * and ensures the return and display values are set. + * This filter is applied to the $field after it is loaded from the database + * and ensures the return and display values are set. * - * @type filter - * @since 5.11.0 - * @date 28/09/21 - * - * @param array $field The field array holding all the field options. + * @type filter + * @since 5.11.0 * - * @return array + * @param array $field The field array holding all the field options. + * @return array */ - function load_field($field) + public function load_field($field) { } /** * Return the schema array for the REST API. * - * @param array $field + * @param array $field The field array. * @return array */ public function get_rest_schema(array $field) @@ -8370,45 +7826,39 @@ public function get_rest_schema(array $field) class acf_field_true_false extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -8425,49 +7875,43 @@ function render_field_presentation_settings($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { } /** - * validate_value - * - * description + * description * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @type function + * @date 11/02/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function validate_value($valid, $value, $field, $input) { } /** - * translate_field - * - * This function will translate field settings + * This function will translate field settings * - * @type function - * @date 8/03/2016 - * @since 5.3.2 + * @type function + * @date 8/03/2016 + * @since 5.3.2 * - * @param array $field - * @return $field + * @param array $field + * @return $field */ function translate_field($field) { @@ -8484,9 +7928,9 @@ public function get_rest_schema(array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -8543,11 +7987,10 @@ public function render_field_presentation_settings($field) * * @since 5.0.0 * - * @param mixed $valid The current validity of the field value. Boolean true if valid, a validation error message string if not. - * @param string $value The value of the field. - * @param array $field Field object array. - * @param string $input The form input name for this field. - * + * @param mixed $valid The current validity of the field value. Boolean true if valid, a validation error message string if not. + * @param string $value The value of the field. + * @param array $field Field object array. + * @param string $input The form input name for this field. * @return mixed Boolean true if valid, a validation error message string if not. */ public function validate_value($valid, $value, $field, $input) @@ -8558,11 +8001,10 @@ public function validate_value($valid, $value, $field, $input) * * @since 6.2.6 * - * @param mixed $value The value which was loaded from the database. - * @param mixed $post_id The $post_id from which the value was loaded. - * @param array $field The field array holding all the field options. - * @param boolean $escape_html Should the field return a HTML safe formatted value. - * + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. + * @param boolean $escape_html Should the field return a HTML safe formatted value. * @return mixed $value The modified value */ public function format_value($value, $post_id, $field, $escape_html) @@ -8571,8 +8013,7 @@ public function format_value($value, $post_id, $field, $escape_html) /** * Return the schema array for the REST API. * - * @param array $field The field object. - * + * @param array $field The field object. * @return array */ public function get_rest_schema(array $field) @@ -8642,8 +8083,8 @@ function render_field($field) * @date 1/11/2013 * @since 5.0.0 * - * @param WP_User $user The WP_User object. - * @param array $field The ACF field related to this query. + * @param WP_User $user The WP_User object. + * @param array $field The ACF field related to this query. * @param int|string $post_id The post_id being edited. * @return string */ @@ -8656,9 +8097,9 @@ function get_result($user, $field, $post_id = 0) * @date 23/01/13 * @since 3.6.0 * - * @param mixed $value The field value. + * @param mixed $value The field value. * @param mixed $post_id The post ID where the value is saved. - * @param array $field The field array containing all settings. + * @param array $field The field array containing all settings. * @return mixed */ function load_value($value, $post_id, $field) @@ -8670,9 +8111,9 @@ function load_value($value, $post_id, $field) * @date 23/01/13 * @since 3.6.0 * - * @param mixed $value The field value. + * @param mixed $value The field value. * @param mixed $post_id The post ID where the value is saved. - * @param array $field The field array containing all settings. + * @param array $field The field array containing all settings. * @return mixed */ function format_value($value, $post_id, $field) @@ -8683,11 +8124,10 @@ function format_value($value, $post_id, $field) * * @since 3.6.0 * - * @param mixed $value The field value. - * @param mixed $post_id The post ID where the value is saved. - * @param array $field The field array containing all settings. - * - * @return mixed $value The modified value. + * @param mixed $value The field value. + * @param mixed $post_id The post ID where the value is saved. + * @param array $field The field array containing all settings. + * @return mixed $value The modified value. */ public function update_value($value, $post_id, $field) { @@ -8711,7 +8151,7 @@ function ajax_query() * @since 5.8.8 * * @param array $request The query request. - * @param ACF_Ajax_Query $query The query object. + * @param ACF_Ajax_Query $query The query object. * @return void */ function ajax_query_init($request, $query) @@ -8723,9 +8163,9 @@ function ajax_query_init($request, $query) * @date 9/3/20 * @since 5.8.8 * - * @param array $args The query args. + * @param array $args The query args. * @param array $request The query request. - * @param ACF_Ajax_Query $query The query object. + * @param ACF_Ajax_Query $query The query object. * @return array */ function ajax_query_args($args, $request, $query) @@ -8737,8 +8177,8 @@ function ajax_query_args($args, $request, $query) * @date 9/3/20 * @since 5.8.8 * - * @param array $columns An array of column names to be searched. - * @param string $search The search term. + * @param array $columns An array of column names to be searched. + * @param string $search The search term. * @param WP_User_Query $WP_User_Query The WP_User_Query instance. * @return array */ @@ -8751,8 +8191,8 @@ function ajax_query_search_columns($columns, $search, $WP_User_Query, $query) * @date 9/3/20 * @since 5.8.8 * - * @param array $item The choice id and text. - * @param WP_User $user The user object. + * @param array $item The choice id and text. + * @param WP_User $user The user object. * @param ACF_Ajax_Query $query The query object. * @return array */ @@ -8779,8 +8219,8 @@ function get_ajax_query($options = array()) * @since 5.0.9 * @deprecated 5.8.9 * - * @param array $columns An array of column names to be searched. - * @param string $search The search term. + * @param array $columns An array of column names to be searched. + * @param string $search The search term. * @param WP_User_Query $WP_User_Query The WP_User_Query instance. * @return array */ @@ -8790,11 +8230,10 @@ function user_search_columns($columns, $search, $WP_User_Query) /** * Validates user fields updated via the REST API. * - * @param bool $valid - * @param int $value - * @param array $field - * - * @return bool|WP_Error + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP_Error */ public function validate_rest_value($valid, $value, $field) { @@ -8810,9 +8249,9 @@ public function get_rest_schema(array $field) } /** * @see \acf_field::get_rest_links() - * @param mixed $value The raw (unformatted) field value. - * @param int|string $post_id - * @param array $field + * @param mixed $value The raw (unformatted) field value. + * @param integer|string $post_id + * @param array $field * @return array */ public function get_rest_links($value, $post_id, array $field) @@ -8821,9 +8260,9 @@ public function get_rest_links($value, $post_id, array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -8833,61 +8272,53 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_wysiwyg extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * add_filters + * This function will add filters to 'acf_the_content' * - * This function will add filters to 'acf_the_content' - * - * @type function - * @date 20/09/2016 - * @since 5.4.0 + * @type function + * @date 20/09/2016 + * @since 5.4.0 * - * @param void - * @return void + * @param void + * @return void */ function add_filters() { } /** - * get_toolbars + * This function will return an array of toolbars for the WYSIWYG field * - * This function will return an array of toolbars for the WYSIWYG field - * - * @type function - * @date 18/04/2014 - * @since 5.0.0 + * @type function + * @date 18/04/2014 + * @since 5.0.0 * - * @param void - * @return array + * @param void + * @return array */ function get_toolbars() { } /** - * acf_enqueue_uploader + * Registers toolbars data for the WYSIWYG field. * - * Registers toolbars data for the WYSIWYG field. - * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param void - * @return void + * @param void + * @return void */ function acf_enqueue_uploader() { @@ -8905,16 +8336,14 @@ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -8936,12 +8365,11 @@ function render_field_presentation_settings($field) * @type filter * @since 3.6 * - * @param mixed $value The value which was loaded from the database. - * @param mixed $post_id The $post_id from which the value was loaded. - * @param array $field The field array holding all the field options. - * @param boolean $escape_html Should the field return a HTML safe formatted value. - * - * @return mixed $value The modified value + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. + * @param boolean $escape_html Should the field return a HTML safe formatted value. + * @return mixed $value The modified value */ public function format_value($value, $post_id, $field, $escape_html) { @@ -8950,77 +8378,68 @@ public function format_value($value, $post_id, $field, $escape_html) class acf_form_attachment { /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * admin_enqueue_scripts - * - * This action is run after post query but before any admin script / head actions. - * It is a good place to register all actions. + * This action is run after post query but before any admin script / head actions. + * It is a good place to register all actions. * - * @type action (admin_enqueue_scripts) - * @date 26/01/13 - * @since 3.6.0 + * @type action (admin_enqueue_scripts) + * @date 26/01/13 + * @since 3.6.0 * - * @param void - * @return void + * @param void + * @return void + * @phpstan-return void */ function admin_enqueue_scripts() { } /** - * admin_footer + * This function will add acf_form_data to the WP 4.0 attachment grid * - * This function will add acf_form_data to the WP 4.0 attachment grid - * - * @type action (admin_footer) - * @date 11/09/2014 - * @since 5.0.0 + * @type action (admin_footer) + * @date 11/09/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function admin_footer() { } /** - * edit_attachment - * - * description + * description * - * @type function - * @date 8/10/13 - * @since 5.0.0 + * @type function + * @date 8/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function edit_attachment($form_fields, $post) { } /** - * save_attachment - * - * description + * description * - * @type function - * @date 8/10/13 - * @since 5.0.0 + * @type function + * @date 8/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function save_attachment($post, $attachment) { @@ -9029,107 +8448,94 @@ function save_attachment($post, $attachment) class acf_form_comment { /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * validate_page + * This function will check if the current page is for a post/page edit form * - * This function will check if the current page is for a post/page edit form - * - * @type function - * @date 23/06/12 - * @since 3.1.8 + * @type function + * @date 23/06/12 + * @since 3.1.8 * - * @param void - * @return boolean + * @param void + * @return boolean */ function validate_page() { } /** - * admin_enqueue_scripts - * - * This action is run after post query but before any admin script / head actions. - * It is a good place to register all actions. + * This action is run after post query but before any admin script / head actions. + * It is a good place to register all actions. * - * @type action (admin_enqueue_scripts) - * @date 26/01/13 - * @since 3.6.0 + * @type action (admin_enqueue_scripts) + * @date 26/01/13 + * @since 3.6.0 * - * @param void - * @return void + * @param void + * @return void + * @phpstan-return void */ function admin_enqueue_scripts() { } /** - * edit_comment + * This function is run on the admin comment.php page and will render the ACF fields within custom metaboxes to look native * - * This function is run on the admin comment.php page and will render the ACF fields within custom metaboxes to look native - * - * @type function - * @date 19/10/13 - * @since 5.0.0 + * @type function + * @date 19/10/13 + * @since 5.0.0 * - * @param object $comment - * @return void + * @param object $comment + * @return void */ function edit_comment($comment) { } /** - * comment_form_field_comment - * - * description + * description * - * @type function - * @date 18/04/2016 - * @since 5.3.8 + * @type function + * @date 18/04/2016 + * @since 5.3.8 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function comment_form_field_comment($html) { } /** - * save_comment + * This function will save the comment data * - * This function will save the comment data - * - * @type function - * @date 19/10/13 - * @since 5.0.0 + * @type function + * @date 19/10/13 + * @since 5.0.0 * - * @param comment_id (int) - * @return void + * @param comment_id (int) + * @return void */ function save_comment($comment_id) { } /** - * admin_footer - * - * description + * description * - * @type function - * @date 27/03/2015 - * @since 5.1.5 + * @type function + * @date 27/03/2015 + * @since 5.1.5 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function admin_footer() { @@ -9139,156 +8545,142 @@ function admin_footer() class acf_form_customizer { /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * admin_enqueue_scripts + * This action is run after post query but before any admin script / head actions. + * It is a good place to register all actions. * - * This action is run after post query but before any admin script / head actions. - * It is a good place to register all actions. - * - * @type action (admin_enqueue_scripts) - * @date 26/01/13 - * @since 3.6.0 + * @type action (admin_enqueue_scripts) + * @date 26/01/13 + * @since 3.6.0 * - * @param void - * @return void + * @param void + * @return void */ function customize_controls_init() { } /** - * save_widget + * This function will hook into the widget update filter and save ACF data * - * This function will hook into the widget update filter and save ACF data - * - * @type function - * @date 27/05/2015 - * @since 5.2.3 + * @type function + * @date 27/05/2015 + * @since 5.2.3 * - * @param array $instance widget settings - * @param array $new_instance widget settings - * @param array $old_instance widget settings - * @param object $widget widget info - * @return $instance + * @param array $instance widget settings + * @param array $new_instance widget settings + * @param array $old_instance widget settings + * @param object $widget widget info + * @return $instance */ function save_widget($instance, $new_instance, $old_instance, $widget) { } /** - * settings + * This function will return an array of cutomizer settings that include ACF data + * similar to `$customizer->settings();` * - * This function will return an array of cutomizer settings that include ACF data - * similar to `$customizer->settings();` - * - * @type function - * @date 22/03/2016 - * @since 5.3.2 + * @type function + * @date 22/03/2016 + * @since 5.3.2 * - * @param object $customizer - * @return mixed $value + * @param object $customizer + * @return mixed $value */ function settings($customizer) { } /** - * customize_preview_init + * This function is called when customizer preview is initialized * - * This function is called when customizer preview is initialized - * - * @type function - * @date 22/03/2016 - * @since 5.3.2 + * @type function + * @date 22/03/2016 + * @since 5.3.2 * - * @param object $customizer - * @return void + * @param object $customizer + * @return void + * @phpstan-return void */ function customize_preview_init($customizer) { } /** - * pre_load_value + * pre_load_value * - * Used to inject preview value + * Used to inject preview value * - * @date 2/2/18 - * @since 5.6.5 + * @date 2/2/18 + * @since 5.6.5 * - * @param type $var Description. Default. - * @return type Description. + * @param type $var Description. Default. + * @return type Description. */ function pre_load_value($value, $post_id, $field) { } /** - * pre_load_reference + * pre_load_reference * - * Used to inject preview value + * Used to inject preview value * - * @date 2/2/18 - * @since 5.6.5 + * @date 2/2/18 + * @since 5.6.5 * - * @param type $var Description. Default. - * @return type Description. + * @param type $var Description. Default. + * @return type Description. */ function pre_load_reference($field_key, $field_name, $post_id) { } /** - * customize_save + * This function is called when customizer saves a widget. + * Normally, the widget_update_callback filter would be used, but the customizer disables this and runs a custom action + * class-customizer-settings.php will save the widget data via the function set_root_value which uses update_option * - * This function is called when customizer saves a widget. - * Normally, the widget_update_callback filter would be used, but the customizer disables this and runs a custom action - * class-customizer-settings.php will save the widget data via the function set_root_value which uses update_option - * - * @type function - * @date 22/03/2016 - * @since 5.3.2 + * @type function + * @date 22/03/2016 + * @since 5.3.2 * - * @param object $customizer - * @return void + * @param object $customizer + * @return void + * @phpstan-return void */ function customize_save($customizer) { } /** - * pre_update_option + * This function will remove the [acf] data from widget insance * - * this function will remove the [acf] data from widget insance - * - * @type function - * @date 22/03/2016 - * @since 5.3.2 + * @type function + * @date 22/03/2016 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function pre_update_option($value, $option, $old_value) { } /** - * admin_footer + * This function will add some custom HTML to the footer of the edit page * - * This function will add some custom HTML to the footer of the edit page - * - * @type function - * @date 11/06/2014 - * @since 5.0.0 + * @type function + * @date 11/06/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function admin_footer() { @@ -9300,151 +8692,131 @@ class acf_form_front /** @var array An array of default fields */ public $fields = array(); /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * validate_form - * - * description + * description * - * @type function - * @date 28/2/17 - * @since 5.5.8 + * @type function + * @date 28/2/17 + * @since 5.5.8 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function validate_form($args) { } /** - * add_form - * - * description + * description * - * @type function - * @date 28/2/17 - * @since 5.5.8 + * @type function + * @date 28/2/17 + * @since 5.5.8 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function add_form($args = array()) { } /** - * get_form - * - * description + * description * - * @type function - * @date 28/2/17 - * @since 5.5.8 + * @type function + * @date 28/2/17 + * @since 5.5.8 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function get_form($id = '') { } /** - * validate_save_post + * This function will validate fields from the above array * - * This function will validate fields from the above array - * - * @type function - * @date 7/09/2016 - * @since 5.4.0 + * @type function + * @date 7/09/2016 + * @since 5.4.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function validate_save_post() { } /** - * pre_save_post - * - * description + * description * - * @type function - * @date 7/09/2016 - * @since 5.4.0 + * @type function + * @date 7/09/2016 + * @since 5.4.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function pre_save_post($post_id, $form) { } /** - * enqueue - * - * This function will enqueue a form + * This function will enqueue a form * - * @type function - * @date 7/09/2016 - * @since 5.4.0 + * @type function + * @date 7/09/2016 + * @since 5.4.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function enqueue_form() { } /** - * check_submit_form - * - * This function will maybe submit form data + * This function will maybe submit form data * - * @type function - * @date 3/3/17 - * @since 5.5.10 + * @type function + * @date 3/3/17 + * @since 5.5.10 * - * @param void - * @return void + * @param void + * @return void */ function check_submit_form() { } /** - * submit_form - * - * This function will submit form data + * This function will submit form data * - * @type function - * @date 3/3/17 - * @since 5.5.10 + * @type function + * @date 3/3/17 + * @since 5.5.10 * - * @param void - * @return void + * @param void + * @return void */ function submit_form($form) { } /** - * render - * - * description + * description * - * @type function - * @date 7/09/2016 - * @since 5.4.0 + * @type function + * @date 7/09/2016 + * @since 5.4.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function render_form($args = array()) { @@ -9453,57 +8825,57 @@ function render_form($args = array()) class ACF_Form_Gutenberg { /** - * __construct + * __construct * - * Setup for class functionality. + * Setup for class functionality. * - * @date 13/12/18 - * @since 5.8.0 + * @date 13/12/18 + * @since 5.8.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * enqueue_block_editor_assets + * enqueue_block_editor_assets * - * Allows a safe way to customize Guten-only functionality. + * Allows a safe way to customize Guten-only functionality. * - * @date 14/12/18 - * @since 5.8.0 + * @date 14/12/18 + * @since 5.8.0 * - * @param void - * @return void + * @param void + * @return void */ function enqueue_block_editor_assets() { } /** - * add_meta_boxes + * add_meta_boxes * - * Modify screen for Gutenberg. + * Modify screen for Gutenberg. * - * @date 13/12/18 - * @since 5.8.0 + * @date 13/12/18 + * @since 5.8.0 * - * @param void - * @return void + * @param void + * @return void */ function add_meta_boxes() { } /** - * block_editor_meta_box_hidden_fields + * block_editor_meta_box_hidden_fields * - * Modify screen for Gutenberg. + * Modify screen for Gutenberg. * - * @date 13/12/18 - * @since 5.8.0 + * @date 13/12/18 + * @since 5.8.0 * - * @param void - * @return void + * @param void + * @return void */ function block_editor_meta_box_hidden_fields() { @@ -9538,16 +8910,16 @@ function modify_user_option_meta_box_order($locations) { } /** - * acf_validate_save_post + * acf_validate_save_post * - * Ignore errors during the Gutenberg "save metaboxes" AJAX request. - * Allows data to save and prevent UX issues. + * Ignore errors during the Gutenberg "save metaboxes" AJAX request. + * Allows data to save and prevent UX issues. * - * @date 16/12/18 - * @since 5.8.0 + * @date 16/12/18 + * @since 5.8.0 * - * @param void - * @return void + * @param void + * @return void */ function acf_validate_save_post() { @@ -9556,92 +8928,86 @@ function acf_validate_save_post() class acf_form_nav_menu { /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * admin_enqueue_scripts + * This action is run after post query but before any admin script / head actions. + * It is a good place to register all actions. * - * This action is run after post query but before any admin script / head actions. - * It is a good place to register all actions. - * - * @type action (admin_enqueue_scripts) - * @date 26/01/13 - * @since 3.6.0 + * @type action (admin_enqueue_scripts) + * @date 26/01/13 + * @since 3.6.0 * - * @param void - * @return void + * @param void + * @return void + * @phpstan-return void */ function admin_enqueue_scripts() { } /** - * wp_nav_menu_item_custom_fields + * wp_nav_menu_item_custom_fields * - * description + * description * - * @date 30/7/18 - * @since 5.6.9 + * @date 30/7/18 + * @since 5.6.9 * - * @param type $var Description. Default. - * @return type Description. + * @param type $var Description. Default. + * @return type Description. */ function wp_nav_menu_item_custom_fields($item_id, $item, $depth, $args, $id = '') { } /** - * update_nav_menu - * - * description + * description * - * @type function - * @date 26/5/17 - * @since 5.6.0 + * @type function + * @date 26/5/17 + * @since 5.6.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function update_nav_menu($menu_id) { } /** - * update_nav_menu_items - * - * description + * description * - * @type function - * @date 26/5/17 - * @since 5.6.0 + * @type function + * @date 26/5/17 + * @since 5.6.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return void */ function update_nav_menu_items($menu_id) { } /** - * wp_get_nav_menu_items + * wp_get_nav_menu_items * - * WordPress does not provide an easy way to find the current menu being edited. - * This function listens to when a menu's items are loaded and stores the menu. - * Needed on nav-menus.php page for new menu with no items + * WordPress does not provide an easy way to find the current menu being edited. + * This function listens to when a menu's items are loaded and stores the menu. + * Needed on nav-menus.php page for new menu with no items * - * @date 23/2/18 - * @since 5.6.9 + * @date 23/2/18 + * @since 5.6.9 * - * @param type $var Description. Default. - * @return type Description. + * @param type $var Description. Default. + * @return type Description. */ function wp_get_nav_menu_items($items, $menu, $args) { @@ -9653,39 +9019,36 @@ function wp_get_nav_menu_items($items, $menu, $args) * @date 26/5/17 * @since 5.6.0 * - * @param string $class The walker class to use. Default 'Walker_Nav_Menu_Edit'. - * @param int $menu_id ID of the menu being rendered. + * @param string $class The walker class to use. Default 'Walker_Nav_Menu_Edit'. + * @param integer $menu_id ID of the menu being rendered. * @return string */ function wp_edit_nav_menu_walker($class, $menu_id = 0) { } /** - * acf_validate_save_post - * - * This function will loop over $_POST data and validate + * This function will loop over $_POST data and validate * - * @type action 'acf/validate_save_post' 5 - * @date 7/09/2016 - * @since 5.4.0 + * @type action 'acf/validate_save_post' 5 + * @date 7/09/2016 + * @since 5.4.0 * - * @param void - * @return void + * @param void + * @return void + * @phpstan-return void */ function acf_validate_save_post() { } /** - * admin_footer + * This function will add some custom HTML to the footer of the edit page * - * This function will add some custom HTML to the footer of the edit page - * - * @type function - * @date 11/06/2014 - * @since 5.0.0 + * @type function + * @date 11/06/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function admin_footer() { @@ -9696,105 +9059,98 @@ class ACF_Form_Post /** @var string The first field groups style CSS. */ var $style = ''; /** - * __construct + * __construct * - * Sets up the class functionality. + * Sets up the class functionality. * - * @date 5/03/2014 - * @since 5.0.0 + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * initialize + * initialize * - * Sets up Form functionality. + * Sets up Form functionality. * - * @date 19/9/18 - * @since 5.7.6 + * @date 19/9/18 + * @since 5.7.6 * - * @param void - * @return void + * @param void + * @return void * @phpstan-return void */ function initialize() { } /** - * add_meta_boxes + * add_meta_boxes * - * Adds ACF metaboxes for the given $post_type and $post. + * Adds ACF metaboxes for the given $post_type and $post. * - * @date 19/9/18 - * @since 5.7.6 + * @date 19/9/18 + * @since 5.7.6 * - * @param string $post_type The post type. - * @param WP_Post $post The post being edited. - * @return void + * @param string $post_type The post type. + * @param WP_Post $post The post being edited. + * @return void */ function add_meta_boxes($post_type, $post) { } /** - * edit_form_after_title - * - * Called after the title adn before the content editor. - * - * @date 19/9/18 - * @since 5.7.6 + * Called after the title and before the content editor to render the after title metaboxes. + * Also renders the CSS required to hide the "hide-on-screen" elements on the page based on the field group settings. * - * @param void - * @return void + * @since 5.7.6 */ - function edit_form_after_title() + public function edit_form_after_title() { } /** - * render_meta_box + * render_meta_box * - * Renders the ACF metabox HTML. + * Renders the ACF metabox HTML. * - * @date 19/9/18 - * @since 5.7.6 + * @date 19/9/18 + * @since 5.7.6 * - * @param WP_Post $post The post being edited. - * @param array metabox The add_meta_box() args. - * @return void + * @param WP_Post $post The post being edited. + * @param array metabox The add_meta_box() args. + * @return void */ function render_meta_box($post, $metabox) { } /** - * wp_insert_post_empty_content + * wp_insert_post_empty_content * - * Allows WP to insert a new post without title or post_content if ACF data exists. + * Allows WP to insert a new post without title or post_content if ACF data exists. * - * @date 16/07/2014 - * @since 5.0.1 + * @date 16/07/2014 + * @since 5.0.1 * - * @param bool $maybe_empty Whether the post should be considered "empty". - * @param array $postarr Array of post data. - * @return bool + * @param boolean $maybe_empty Whether the post should be considered "empty". + * @param array $postarr Array of post data. + * @return boolean */ function wp_insert_post_empty_content($maybe_empty, $postarr) { } /** - * allow_save_post + * Checks if the $post is allowed to be saved. + * Used to avoid triggering "acf/save_post" on dynamically created posts during save. * - * Checks if the $post is allowed to be saved. - * Used to avoid triggering "acf/save_post" on dynamically created posts during save. - * - * @type function - * @date 26/06/2016 - * @since 5.3.8 + * @type function + * @date 26/06/2016 + * @since 5.3.8 * - * @param WP_Post $post The post to check. - * @return bool + * @param WP_Post $post The post to check. + * @return boolean */ function allow_save_post($post) { @@ -9816,122 +9172,107 @@ class acf_form_taxonomy { var $view = 'add'; /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * validate_page - * - * This function will check if the current page is for a post/page edit form + * This function will check if the current page is for a post/page edit form * - * @type function - * @date 23/06/12 - * @since 3.1.8 + * @type function + * @date 23/06/12 + * @since 3.1.8 * - * @param void - * @return boolean + * @param void + * @return boolean */ function validate_page() { } /** - * admin_enqueue_scripts + * This action is run after post query but before any admin script / head actions. + * It is a good place to register all actions. * - * This action is run after post query but before any admin script / head actions. - * It is a good place to register all actions. - * - * @type action (admin_enqueue_scripts) - * @date 26/01/13 - * @since 3.6.0 + * @type action (admin_enqueue_scripts) + * @date 26/01/13 + * @since 3.6.0 * - * @param void - * @return void + * @param void + * @return void + * @phpstan-return void */ function admin_enqueue_scripts() { } /** - * add_term - * - * description + * description * - * @type function - * @date 8/10/13 - * @since 5.0.0 + * @type function + * @date 8/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function add_term($taxonomy) { } /** - * edit_term - * - * description + * description * - * @type function - * @date 8/10/13 - * @since 5.0.0 + * @type function + * @date 8/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function edit_term($term, $taxonomy) { } /** - * admin_footer - * - * description + * description * - * @type function - * @date 27/03/2015 - * @since 5.1.5 + * @type function + * @date 27/03/2015 + * @since 5.1.5 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function admin_footer() { } /** - * save_term - * - * description + * description * - * @type function - * @date 8/10/13 - * @since 5.0.0 + * @type function + * @date 8/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function save_term($term_id, $tt_id, $taxonomy) { } /** - * delete_term - * - * description + * description * - * @type function - * @date 15/10/13 - * @since 5.0.0 + * @type function + * @date 15/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function delete_term($term, $tt_id, $taxonomy, $deleted_term) { @@ -9942,137 +9283,124 @@ class ACF_Form_User /** @var string The current view (new, edit, register) */ var $view = ''; /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * admin_enqueue_scripts + * admin_enqueue_scripts * - * Checks current screen and enqueues scripts + * Checks current screen and enqueues scripts * - * @date 17/4/18 - * @since 5.6.9 + * @date 17/4/18 + * @since 5.6.9 * - * @param void - * @return void + * @param void + * @return void * @phpstan-return void */ function admin_enqueue_scripts() { } /** - * login_form_register + * login_form_register * - * Customizes and enqueues scripts + * Customizes and enqueues scripts * - * @date 17/4/18 - * @since 5.6.9 + * @date 17/4/18 + * @since 5.6.9 * - * @param void - * @return void + * @param void + * @return void */ function login_form_register() { } /** - * register_user + * Called during the user register form * - * Called during the user register form - * - * @type function - * @date 8/10/13 - * @since 5.0.0 + * @type function + * @date 8/10/13 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function render_register() { } /** - * render_edit + * Called during the user edit form * - * Called during the user edit form - * - * @type function - * @date 8/10/13 - * @since 5.0.0 + * @type function + * @date 8/10/13 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function render_edit($user) { } /** - * user_new_form - * - * description + * description * - * @type function - * @date 8/10/13 - * @since 5.0.0 + * @type function + * @date 8/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return void */ function render_new() { } /** - * render + * This function will render ACF fields for a given $post_id parameter * - * This function will render ACF fields for a given $post_id parameter - * - * @type function - * @date 7/10/13 - * @since 5.0.0 + * @type function + * @since 5.0.0 * - * @param int $user_id this can be set to 0 for a new user - * @param string $user_form used for location rule matching. edit | add | register - * @param string $el - * @return void + * @param int $user_id this can be set to 0 for a new user + * @param string $user_form used for location rule matching. edit | add | register + * @param string $el + * @return void + * @phpstan-return void */ function render($args = array()) { } /** - * admin_footer - * - * description + * description * - * @type function - * @date 27/03/2015 - * @since 5.1.5 + * @type function + * @date 27/03/2015 + * @since 5.1.5 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function admin_footer() { } /** - * save_user - * - * description + * description * - * @type function - * @date 8/10/13 - * @since 5.0.0 + * @type function + * @date 8/10/13 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function save_user($user_id) { @@ -10085,9 +9413,9 @@ function save_user($user_id) * @date 12/7/19 * @since 5.8.1 * - * @param WP_Error $errors A WP_Error object containing any errors encountered during registration. + * @param WP_Error $errors A WP_Error object containing any errors encountered during registration. * @param string $sanitized_user_login User's username after it has been sanitized. - * @param string $user_email User's email. + * @param string $user_email User's email. * @return WP_Error */ function filter_registration_errors($errors, $sanitized_user_login, $user_email) @@ -10101,9 +9429,9 @@ function filter_registration_errors($errors, $sanitized_user_login, $user_email) * @date 12/7/19 * @since 5.8.2 * - * @param null $null A null placeholder. + * @param null $null A null placeholder. * @param int|string $post_id The post id. - * @param array $field The field array. + * @param array $field The field array. * @return mixed */ function filter_pre_load_value($null, $post_id, $field) @@ -10114,97 +9442,83 @@ function filter_pre_load_value($null, $post_id, $field) class acf_form_widget { /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * admin_enqueue_scripts + * This action is run after post query but before any admin script / head actions. + * It is a good place to register all actions. * - * This action is run after post query but before any admin script / head actions. - * It is a good place to register all actions. - * - * @type action (admin_enqueue_scripts) - * @date 26/01/13 - * @since 3.6.0 + * @type action (admin_enqueue_scripts) + * @date 26/01/13 + * @since 3.6.0 * - * @param void - * @return void + * @param void + * @return void + * @phpstan-return void */ function admin_enqueue_scripts() { } /** - * acf_validate_save_post - * - * This function will loop over $_POST data and validate + * This function will loop over $_POST data and validate * - * @type action 'acf/validate_save_post' 5 - * @date 7/09/2016 - * @since 5.4.0 - * - * @param void - * @return void + * @type action 'acf/validate_save_post' 5 + * @since 5.4.0 + * @phpstan-return void */ - function acf_validate_save_post() + public function acf_validate_save_post() { } /** - * edit_widget - * - * This function will render the fields for a widget form + * This function will render the fields for a widget form * - * @type function - * @date 11/06/2014 - * @since 5.0.0 + * @type function + * @date 11/06/2014 + * @since 5.0.0 * - * @param object $widget - * @param null $return - * @param object $instance - * @return int $post_id + * @param object $widget + * @param null $return + * @param object $instance + * @return int $post_id */ function edit_widget($widget, $return, $instance) { } /** - * save_widget - * - * This function will hook into the widget update filter and save ACF data + * This function will hook into the widget update filter and save ACF data * - * @type function - * @date 27/05/2015 - * @since 5.2.3 + * @type function + * @date 27/05/2015 + * @since 5.2.3 * - * @param array $instance widget settings - * @param array $new_instance widget settings - * @param array $old_instance widget settings - * @param object $widget widget info - * @return $instance + * @param array $instance widget settings + * @param array $new_instance widget settings + * @param array $old_instance widget settings + * @param object $widget widget info + * @return $instance */ function save_widget($instance, $new_instance, $old_instance, $widget) { } /** - * admin_footer - * - * This function will add some custom HTML to the footer of the edit page + * This function will add some custom HTML to the footer of the edit page * - * @type function - * @date 11/06/2014 - * @since 5.0.0 + * @type function + * @date 11/06/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function admin_footer() { @@ -10219,7 +9533,7 @@ class ACF_Legacy_Locations * @since 5.9.0 * * @param string $key Key name. - * @return bool + * @return boolean */ public function __isset($key) { @@ -10242,7 +9556,7 @@ public function __get($key) * @date 10/4/20 * @since 5.9.0 * - * @param string $name The method name. + * @param string $name The method name. * @param array $arguments The array of arguments. * @return mixed */ @@ -10271,7 +9585,7 @@ public function __construct() * @since 5.9.0 * * @param void - * @return bool. + * @return boolean */ public function is_enabled() { @@ -10316,7 +9630,7 @@ public function update_field_group($field_group) * @since 6.1 * * @param array $post The main ACF post array. - * @return bool + * @return boolean */ public function update_internal_post_type($post) { @@ -10328,7 +9642,7 @@ public function update_internal_post_type($post) * @since 5.9.0 * * @param array $field_group The field group. - * @return bool + * @return boolean */ public function delete_field_group($field_group) { @@ -10339,7 +9653,7 @@ public function delete_field_group($field_group) * @since 6.1 * * @param array $post The main ACF post array. - * @return bool + * @return boolean */ public function delete_internal_post_type($post) { @@ -10360,8 +9674,6 @@ public function include_fields() * Includes all local JSON post types. * * @since 6.1 - * - * @return void */ public function include_post_types() { @@ -10370,8 +9682,6 @@ public function include_post_types() * Includes all local JSON taxonomies. * * @since 6.1 - * - * @return void */ public function include_taxonomies() { @@ -10382,7 +9692,7 @@ public function include_taxonomies() * @date 14/4/20 * @since 5.9.0 * - * @return array + * @return array */ function scan_field_groups() { @@ -10418,7 +9728,7 @@ public function get_files($post_type = 'acf-field-group') * * @param string $key The ACF post key. * @param array $post The main ACF post array. - * @return bool + * @return boolean */ public function save_file($key, $post) { @@ -10431,7 +9741,7 @@ public function save_file($key, $post) * * @param string $key The ACF post key. * @param array $post The main ACF post array. - * @return bool + * @return boolean */ public function delete_file($key, $post = array()) { @@ -10439,12 +9749,9 @@ public function delete_file($key, $post = array()) /** * Includes all local JSON files. * - * @date 10/03/2014 - * @since 5.0.0 + * @date 10/03/2014 + * @since 5.0.0 * @deprecated 5.9.0 - * - * @param void - * @return void */ public function include_json_folders() { @@ -10492,9 +9799,9 @@ function __construct() * @date 8/10/18 * @since 5.8.0 * - * @param array $meta An array of metdata to store. - * @param mixed $post_id The post_id for this data. - * @param bool $is_main Makes this postmeta visible to get_field() without a $post_id value. + * @param array $meta An array of metdata to store. + * @param mixed $post_id The post_id for this data. + * @param boolean $is_main Makes this postmeta visible to get_field() without a $post_id value. * @return array */ function add($meta = array(), $post_id = 0, $is_main = \false) @@ -10509,7 +9816,7 @@ function add($meta = array(), $post_id = 0, $is_main = \false) * @since 5.7.14 * * @param array $meta An array of metdata to check. - * @return bool + * @return boolean */ function is_request($meta = array()) { @@ -10523,7 +9830,7 @@ function is_request($meta = array()) * @date 26/2/19 * @since 5.7.13 * - * @param array $values An array of raw values. + * @param array $values An array of raw values. * @param mixed $post_id The post_id for this data. * @return array */ @@ -10538,11 +9845,11 @@ function capture($values = array(), $post_id = 0) * @date 26/2/19 * @since 5.7.13 * - * @param null $null . + * @param null $null . * @param int|string $post_id The post id. - * @param string $name The meta name. - * @param mixed $value The meta value. - * @param bool $hidden If the meta is hidden (starts with an underscore). + * @param string $name The meta name. + * @param mixed $value The meta value. + * @param boolean $hidden If the meta is hidden (starts with an underscore). * @return false. */ function capture_update_metadata($null, $post_id, $name, $value, $hidden) @@ -10570,7 +9877,7 @@ function remove($post_id = 0) * @date 8/10/18 * @since 5.8.0 * - * @param null $null An empty parameter. Return a non null value to short-circuit the function. + * @param null $null An empty parameter. Return a non null value to short-circuit the function. * @param mixed $post_id The post_id for this data. * @return mixed */ @@ -10585,10 +9892,10 @@ function pre_load_meta($null, $post_id) * @date 8/10/18 * @since 5.8.0 * - * @param null $null An empty parameter. Return a non null value to short-circuit the function. + * @param null $null An empty parameter. Return a non null value to short-circuit the function. * @param int|string $post_id The post id. - * @param string $name The meta name. - * @param bool $hidden If the meta is hidden (starts with an underscore). + * @param string $name The meta name. + * @param boolean $hidden If the meta is hidden (starts with an underscore). * @return mixed */ function pre_load_metadata($null, $post_id, $name, $hidden) @@ -10602,7 +9909,7 @@ function pre_load_metadata($null, $post_id, $name, $hidden) * @date 8/10/18 * @since 5.8.0 * - * @param null $null An empty parameter. Return a non null value to short-circuit the function. + * @param null $null An empty parameter. Return a non null value to short-circuit the function. * @param mixed $post_id The post_id for this data. * @return mixed */ @@ -10630,7 +9937,7 @@ public function __construct() * @date 10/4/20 * @since 5.9.0 * - * @param string $name The method name. + * @param string $name The method name. * @param array $arguments The array of arguments. * @return mixed */ @@ -10667,7 +9974,7 @@ abstract class ACF_Location extends \ACF_Legacy_Location * Whether or not the location rule is publicly accessible. * * @since 5.0.0 - * @var bool + * @var boolean */ public $public = \true; /** @@ -10766,10 +10073,10 @@ public function get_object_subtype($rule) * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -10780,9 +10087,9 @@ public function match($rule, $screen, $field_group) * @date 17/9/19 * @since 5.8.1 * - * @param array $rule The location rule data. + * @param array $rule The location rule data. * @param mixed $value The value to compare against. - * @return bool + * @return boolean */ public function compare_to_rule($value, $rule) { @@ -10808,10 +10115,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -10849,10 +10156,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -10890,10 +10197,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -10931,10 +10238,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -10972,10 +10279,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11013,10 +10320,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11054,10 +10361,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11095,10 +10402,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11136,10 +10443,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11177,10 +10484,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11218,10 +10525,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11271,10 +10578,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11312,10 +10619,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11353,10 +10660,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11406,10 +10713,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11459,10 +10766,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11512,10 +10819,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11553,10 +10860,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11606,10 +10913,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11649,10 +10956,10 @@ function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11690,10 +10997,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -11715,124 +11022,108 @@ public function get_values($rule) class acf_loop { /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * is_empty - * - * This function will return true if no loops exist + * This function will return true if no loops exist * - * @type function - * @date 3/03/2016 - * @since 5.3.2 + * @type function + * @date 3/03/2016 + * @since 5.3.2 * - * @param void - * @return boolean + * @param void + * @return boolean */ function is_empty() { } /** - * is_loop - * - * This function will return true if a loop exists for the given array index + * This function will return true if a loop exists for the given array index * - * @type function - * @date 3/03/2016 - * @since 5.3.2 + * @type function + * @date 3/03/2016 + * @since 5.3.2 * - * @param int $i - * @return boolean + * @param int $i + * @return boolean */ function is_loop($i = 0) { } /** - * get_i + * This function will return a valid array index for the given $i * - * This function will return a valid array index for the given $i - * - * @type function - * @date 3/03/2016 - * @since 5.3.2 + * @type function + * @date 3/03/2016 + * @since 5.3.2 * - * @param mixed $i - * @return int + * @param mixed $i + * @return int */ function get_i($i = 0) { } /** - * add_loop - * - * This function will add a new loop + * This function will add a new loop * - * @type function - * @date 3/03/2016 - * @since 5.3.2 + * @type function + * @date 3/03/2016 + * @since 5.3.2 * - * @param array $loop - * @return void + * @param array $loop + * @return void */ function add_loop($loop = array()) { } /** - * update_loop + * This function will update a loop's setting * - * This function will update a loop's setting - * - * @type function - * @date 3/03/2016 - * @since 5.3.2 + * @type function + * @date 3/03/2016 + * @since 5.3.2 * - * @param mixed $i - * @param string $key the loop setting name - * @param mixed $value the loop setting value - * @return boolean true on success + * @param mixed $i + * @param string $key the loop setting name + * @param mixed $value the loop setting value + * @return boolean true on success */ function update_loop($i = 'active', $key = \null, $value = \null) { } /** - * get_loop + * This function will return a loop, or loop's setting for a given index & key * - * This function will return a loop, or loop's setting for a given index & key - * - * @type function - * @date 3/03/2016 - * @since 5.3.2 + * @type function + * @date 3/03/2016 + * @since 5.3.2 * - * @param mixed $i - * @param string $key the loop setting name - * @return mixed false on failure + * @param mixed $i + * @param string $key the loop setting name + * @return mixed false on failure */ function get_loop($i = 'active', $key = \null) { } /** - * remove_loop + * This function will remove a loop * - * This function will remove a loop - * - * @type function - * @date 3/03/2016 - * @since 5.3.2 + * @type function + * @date 3/03/2016 + * @since 5.3.2 * - * @param mixed $i - * @return boolean true on success + * @param mixed $i + * @return boolean true on success */ function remove_loop($i = 'active') { @@ -11870,7 +11161,7 @@ public function enqueue_scripts() * @date 24/10/2014 * @since 5.0.9 * - * @param string|int $post_id The post ID being saved. + * @param string|integer $post_id The post ID being saved. * @return void */ public function save_files($post_id = 0) @@ -11906,9 +11197,9 @@ function wp_ajax_query_attachments() * @date 31/8/21 * @since 5.10.2 * - * @param array $response Array of prepared attachment data. + * @param array $response Array of prepared attachment data. * @param WP_Post $attachment Attachment object. - * @param array|false $meta Array of attachment meta data, or false if there is none. + * @param array|false $meta Array of attachment meta data, or false if there is none. * @return array */ function clear_acf_errors_for_core_requests($response, $attachment, $meta) @@ -11920,9 +11211,9 @@ function clear_acf_errors_for_core_requests($response, $attachment, $meta) * @date 21/5/21 * @since 5.9.7 * - * @param array $response Array of prepared attachment data. + * @param array $response Array of prepared attachment data. * @param WP_Post $attachment Attachment object. - * @param array|false $meta Array of attachment meta data, or false if there is none. + * @param array|false $meta Array of attachment meta data, or false if there is none. * @return array */ function wp_prepare_attachment_for_js($response, $attachment, $meta) @@ -12004,8 +11295,8 @@ public function get_settings_array() * * @since 6.1 * - * @param int|WP_Post $id The post ID being queried. - * @return array|bool The main ACF array for the post, or false on failure. + * @param integer|WP_Post $id The post ID being queried. + * @return array|boolean The main ACF array for the post, or false on failure. */ public function get_post($id = 0) { @@ -12038,8 +11329,8 @@ public function pre_update_field_group($field_group) * * @since 6.1 * - * @param int|string $id The ID of the field group to delete. - * @return bool + * @param integer|string $id The ID of the field group to delete. + * @return boolean */ public function delete_post($id = 0) { @@ -12049,8 +11340,8 @@ public function delete_post($id = 0) * * @since 6.1 * - * @param int|string $id The ID of the field group to trash. - * @return bool + * @param integer|string $id The ID of the field group to trash. + * @return boolean */ public function trash_post($id = 0) { @@ -12060,8 +11351,8 @@ public function trash_post($id = 0) * * @since 6.1 * - * @param int|string $id The ID of the ACF post to untrash. - * @return bool + * @param integer|string $id The ID of the ACF post to untrash. + * @return boolean */ public function untrash_post($id = 0) { @@ -12071,8 +11362,8 @@ public function untrash_post($id = 0) * * @since 6.1 * - * @param int|string $id The ID of the post to duplicate. - * @param int $new_post_id Optional post ID to override. + * @param integer|string $id The ID of the post to duplicate. + * @param integer $new_post_id Optional post ID to override. * @return array The new ACF post array. */ public function duplicate_post($id = 0, $new_post_id = 0) @@ -12226,7 +11517,7 @@ public function validate_post($post = array()) * * @since 6.1 * - * @return bool validity status + * @return boolean validity status */ public function ajax_validate_values() { @@ -12240,7 +11531,7 @@ public function ajax_validate_values() * * @since 6.1 * - * @param array $post The main ACF post type settings array. + * @param array $post The main ACF post type settings array. * @param boolean $escape_labels Determines if the label values should be escaped. * @return array */ @@ -12372,7 +11663,7 @@ public function get_settings_array() * * @since 6.1 * - * @return bool validity status + * @return boolean validity status */ public function ajax_validate_values() { @@ -12386,7 +11677,7 @@ public function ajax_validate_values() * * @since 6.1 * - * @param array $post The main ACF taxonomy settings array. + * @param array $post The main ACF taxonomy settings array. * @param boolean $escape_labels Determines if the label values should be escaped. * @return array */ @@ -12465,7 +11756,7 @@ public function register_field() * @param \WP_REST_Request $request * @param string $param * - * @return bool|WP_Error + * @return boolean|WP_Error */ public function validate_rest_arg($value, $request, $param) { @@ -12474,11 +11765,11 @@ public function validate_rest_arg($value, $request, $param) * Load field values into the requested object. This method is not a part of any public API and is only public as * it is required by WordPress. * - * @param array $object An array representation of the post, term, or user object. + * @param array $object An array representation of the post, term, or user object. * @param string $field_name * @param WP_REST_Request $request * @param string $object_sub_type Note that this isn't the same as $this->object_type. This variable is - * more specific and can be a post type or taxonomy. + * more specific and can be a post type or taxonomy. * @return array */ public function load_fields($object, $field_name, $request, $object_sub_type) @@ -12490,10 +11781,10 @@ public function load_fields($object, $field_name, $request, $object_sub_type) * * @param array $data * @param WP_Post|WP_Term|WP_User $object - * @param string $property 'acf' + * @param string $property 'acf' * @param WP_REST_Request $request * @param string $object_sub_type This will be the post type, the taxonomy, or 'user'. - * @return bool|WP_Error + * @return boolean|WP_Error */ public function update_fields($data, $object, $property, $request, $object_sub_type) { @@ -12533,10 +11824,6 @@ public function load_item_links($response, $item, $request) } /** * Class ACF_Rest_Request - * - * @property-read string $object_sub_type - * @property-read string $object_type - * @property-read string $http_method */ class ACF_Rest_Request { @@ -12572,8 +11859,6 @@ class acf_revisions var $cache = array(); /** * Constructs the acf_revisions class. - * - * @return void */ public function __construct() { @@ -12583,8 +11868,6 @@ public function __construct() * For now, this is just our "_acf_changed" key that we use to detect if ACF fields have changed. * * @since 6.2.6 - * - * @return void */ public function register_meta() { @@ -12629,98 +11912,86 @@ public function maybe_save_revision($revision_id, $post_id) { } /** - * wp_preview_post_fields + * This function is used to trick WP into thinking that one of the $post's fields has changed and + * will allow an autosave to be updated. + * Fixes an odd bug causing the preview page to render the non autosave post data on every odd attempt * - * This function is used to trick WP into thinking that one of the $post's fields has changed and - * will allow an autosave to be updated. - * Fixes an odd bug causing the preview page to render the non autosave post data on every odd attempt + * @type function + * @date 21/10/2014 + * @since 5.1.0 * - * @type function - * @date 21/10/2014 - * @since 5.1.0 - * - * @param array $fields - * @return $fields + * @param array $fields + * @return $fields */ function wp_preview_post_fields($fields) { } /** - * wp_save_post_revision_check_for_changes - * - * This filter will return false and force WP to save a revision. This is required due to - * WP checking only post_title, post_excerpt and post_content values, not custom fields. + * This filter will return false and force WP to save a revision. This is required due to + * WP checking only post_title, post_excerpt and post_content values, not custom fields. * - * @type filter - * @date 19/09/13 + * @type filter + * @date 19/09/13 * - * @param boolean $return defaults to true - * @param object $last_revision the last revision that WP will compare against - * @param object $post the $post that WP will compare against - * @return boolean $return + * @param boolean $return defaults to true + * @param object $last_revision the last revision that WP will compare against + * @param object $post the $post object that WP will compare against + * @return boolean $return */ function wp_save_post_revision_check_for_changes($return, $last_revision, $post) { } /** - * wp_post_revision_fields - * - * This filter will add the ACF fields to the returned array - * Versions 3.5 and 3.6 of WP feature different uses of the revisions filters, so there are - * some hacks to allow both versions to work correctly + * This filter will add the ACF fields to the returned array + * Versions 3.5 and 3.6 of WP feature different uses of the revisions filters, so there are + * some hacks to allow both versions to work correctly * - * @type filter - * @date 11/08/13 + * @type filter + * @date 11/08/13 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function wp_post_revision_fields($fields, $post = \null) { } /** - * wp_post_revision_field - * - * This filter will load the value for the given field and return it for rendering + * This filter will load the value for the given field and return it for rendering * - * @type filter - * @date 11/08/13 + * @type filter + * @date 11/08/13 * - * @param mixed $value should be false as it has not yet been loaded - * @param string $field_name The name of the field - * @param mixed $post Holds the $post object to load from - in WP 3.5, this is not passed! - * @param string $direction to / from - not used - * @return string $value + * @param mixed $value should be false as it has not yet been loaded + * @param string $field_name The name of the field + * @param post (mixed) Holds the $post object to load from - in WP 3.5, this is not passed! + * @param string $direction to / from - not used + * @return string $value */ function wp_post_revision_field($value, $field_name, $post = \null, $direction = \false) { } /** - * wp_restore_post_revision - * - * This action will copy and paste the metadata from a revision to the post + * This action will copy and paste the metadata from a revision to the post * - * @type action - * @date 11/08/13 + * @type action + * @date 11/08/13 * - * @param int $parent_id the destination post - * @return int $revision_id the source post + * @param int $parent_id the destination post + * @return int $revision_id the source post */ function wp_restore_post_revision($post_id, $revision_id) { } /** - * acf_validate_post_id - * - * This function will modify the $post_id and allow loading values from a revision + * This function will modify the $post_id and allow loading values from a revision * - * @type function - * @date 6/3/17 - * @since 5.5.10 + * @type function + * @date 6/3/17 + * @since 5.5.10 * - * @param int $post_id - * @param int $_post_id - * @return int $post_id + * @param int $post_id + * @param int $_post_id + * @return int $post_id */ function acf_validate_post_id($post_id, $_post_id) { @@ -12798,92 +12069,81 @@ public function doing_dark_mode() class acf_validation { /** - * __construct - * - * This function will setup the class functionality + * This function will setup the class functionality * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * add_error - * - * This function will add an error message for a field + * This function will add an error message for a field * - * @type function - * @date 25/11/2013 - * @since 5.0.0 + * @type function + * @date 25/11/2013 + * @since 5.0.0 * - * @param string $input name attribute of DOM elmenet - * @param string $message error message - * @return int $post_id + * @param string $input name attribute of DOM elmenet + * @param string $message error message + * @return int $post_id */ function add_error($input, $message) { } /** - * get_error - * - * This function will return an error for a given input + * This function will return an error for a given input * - * @type function - * @date 5/03/2016 - * @since 5.3.2 + * @type function + * @date 5/03/2016 + * @since 5.3.2 * - * @param string $input name attribute of DOM elmenet - * @return mixed + * @param string $input name attribute of DOM elmenet + * @return mixed */ function get_error($input) { } /** - * get_errors + * This function will return validation errors * - * This function will return validation errors - * - * @type function - * @date 25/11/2013 - * @since 5.0.0 + * @type function + * @date 25/11/2013 + * @since 5.0.0 * - * @param void - * @return array|boolean + * @param void + * @return array|boolean */ function get_errors() { } /** - * reset_errors - * - * This function will remove all errors + * This function will remove all errors * - * @type function - * @date 4/03/2016 - * @since 5.3.2 + * @type function + * @date 4/03/2016 + * @since 5.3.2 * - * @param void - * @return void + * @param void + * @return void */ function reset_errors() { } /** - * ajax_validate_save_post - * - * This function will validate the $_POST data via AJAX + * This function will validate the $_POST data via AJAX * - * @type function - * @date 27/10/2014 - * @since 5.0.9 + * @type function + * @date 27/10/2014 + * @since 5.0.9 * - * @param void - * @return void + * @param void + * @return void + * @phpstan-return never */ function ajax_validate_save_post() { @@ -12892,8 +12152,6 @@ function ajax_validate_save_post() * Loops over $_POST data and validates ACF values. * * @since 5.4.0 - * - * @return void * @phpstan-return void */ public function acf_validate_save_post() @@ -12942,9 +12200,9 @@ function __construct($field) * * @since 1.0.0 * - * @param string $output Used to append additional content (passed by reference). - * @param int $depth Depth of category. Used for tab indentation. - * @param array $args An array of arguments. @see wp_terms_checklist() + * @param string $output Used to append additional content (passed by reference). + * @param integer $depth Depth of category. Used for tab indentation. + * @param array $args An array of arguments. @see wp_terms_checklist() */ public function start_lvl(&$output, $depth = 0, $args = array()) { @@ -12956,9 +12214,9 @@ public function start_lvl(&$output, $depth = 0, $args = array()) * * @since 1.0.0 * - * @param string $output Used to append additional content (passed by reference). - * @param int $depth Depth of category. Used for tab indentation. - * @param array $args An array of arguments. @see wp_terms_checklist() + * @param string $output Used to append additional content (passed by reference). + * @param integer $depth Depth of category. Used for tab indentation. + * @param array $args An array of arguments. @see wp_terms_checklist() */ public function end_lvl(&$output, $depth = 0, $args = array()) { @@ -12970,11 +12228,11 @@ public function end_lvl(&$output, $depth = 0, $args = array()) * * @since 1.0.0 * - * @param string $output Used to append additional content (passed by reference). - * @param WP_Term $term The current term object. - * @param int $depth Depth of the term in reference to parents. Default 0. - * @param array $args An array of arguments. @see wp_terms_checklist() - * @param int $id ID of the current term. + * @param string $output Used to append additional content (passed by reference). + * @param WP_Term $term The current term object. + * @param integer $depth Depth of the term in reference to parents. Default 0. + * @param array $args An array of arguments. @see wp_terms_checklist() + * @param integer $id ID of the current term. */ public function start_el(&$output, $term, $depth = 0, $args = array(), $id = 0) { @@ -12988,7 +12246,7 @@ public function start_el(&$output, $term, $depth = 0, $args = array(), $id = 0) * * @param string $output Used to append additional content (passed by reference). * @param WP_Term $category The current term object. - * @param int $depth Depth of the term in reference to parents. Default 0. + * @param integer $depth Depth of the term in reference to parents. Default 0. * @param array $args An array of arguments. @see wp_terms_checklist() */ public function end_el(&$output, $category, $depth = 0, $args = array()) @@ -12998,147 +12256,141 @@ public function end_el(&$output, $category, $depth = 0, $args = array()) class ACF_WPML_Compatibility { /** - * __construct + * __construct * - * Sets up the class functionality. + * Sets up the class functionality. * - * @date 23/06/12 - * @since 3.1.8 + * @date 23/06/12 + * @since 3.1.8 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { } /** - * is_translatable + * is_translatable * - * Returns true if the acf-field-group post type is translatable. - * Also adds compatibility with ACF4 settings + * Returns true if the acf-field-group post type is translatable. + * Also adds compatibility with ACF4 settings * - * @date 10/04/2015 - * @since 5.2.3 + * @date 10/04/2015 + * @since 5.2.3 * - * @param void - * @return bool + * @param void + * @return boolean */ function is_translatable() { } /** - * upgrade_500_field_group + * upgrade_500_field_group * - * Update the icl_translations table data when creating the field groups. + * Update the icl_translations table data when creating the field groups. * - * @date 10/04/2015 - * @since 5.2.3 + * @date 10/04/2015 + * @since 5.2.3 * - * @param array $field_group The new field group array. - * @param object $ofg The old field group WP_Post object. - * @return void + * @param array $field_group The new field group array. + * @param object $ofg The old field group WP_Post object. + * @return void * @phpstan-return void */ function upgrade_500_field_group($field_group, $ofg) { } /** - * settings_save_json + * settings_save_json * - * Modifies the json path. + * Modifies the json path. * - * @date 19/05/2014 - * @since 5.0.0 + * @date 19/05/2014 + * @since 5.0.0 * - * @param string $path The json save path. - * @return string + * @param string $path The json save path. + * @return string */ function settings_save_json($path) { } /** - * settings_load_json + * settings_load_json * - * Modifies the json path. + * Modifies the json path. * - * @date 19/05/2014 - * @since 5.0.0 + * @date 19/05/2014 + * @since 5.0.0 * - * @param string $path The json save path. - * @return string + * @param string $path The json save path. + * @return string */ function settings_load_json($paths) { } /** - * icl_make_duplicate + * icl_make_duplicate * - * description + * description * - * @date 26/02/2014 - * @since 5.0.0 + * @date 26/02/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void * @phpstan-return void */ function icl_make_duplicate($master_post_id, $lang, $postarr, $id) { } /** - * verify_ajax + * verify_ajax * - * Sets the correct language during AJAX requests. + * Sets the correct language during AJAX requests. * - * @type function - * @date 7/08/2015 - * @since 5.2.3 + * @type function + * @date 7/08/2015 + * @since 5.2.3 * - * @param void - * @return void + * @param void + * @return void */ function verify_ajax() { } /** - * get_translatable_documents + * get_translatable_documents * - * Removes 'acf-field' from the available post types for translation. + * Removes 'acf-field' from the available post types for translation. * - * @type function - * @date 17/8/17 - * @since 5.6.0 + * @type function + * @date 17/8/17 + * @since 5.6.0 * - * @param array $icl_post_types The array of post types. - * @return array + * @param array $icl_post_types The array of post types. + * @return array */ function get_translatable_documents($icl_post_types) { } } +/** + * The main ACF PRO class. + */ class acf_pro { /** - * __construct - * - * - * - * @type function - * @date 23/06/12 - * @since 5.0.0 + * Main ACF PRO constructor * - * @param void - * @return void + * @since 5.0.0 */ - function __construct() + public function __construct() { } /** * Registers the `acf-ui-options-page` post type and initializes the UI. * * @since 6.2 - * - * @return void * @phpstan-return void */ public function register_ui_options_pages() @@ -13162,16 +12414,14 @@ function include_field_types() { } /** - * include_location_rules - * - * description + * description * - * @type function - * @date 10/6/17 - * @since 5.6.0 + * @type function + * @date 10/6/17 + * @since 5.6.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function include_location_rules() { @@ -13180,38 +12430,34 @@ function include_location_rules() * Registers styles and scripts used by ACF PRO. * * @since 5.0.0 - * - * @return void */ public function register_assets() { } /** - * input_admin_enqueue_scripts + * input_admin_enqueue_scripts * - * description + * description * - * @type function - * @date 4/11/2013 - * @since 5.0.0 + * @type function + * @date 4/11/2013 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function input_admin_enqueue_scripts() { } /** - * field_group_admin_enqueue_scripts - * - * description + * description * - * @type function - * @date 4/11/2013 - * @since 5.0.0 + * @type function + * @date 4/11/2013 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function field_group_admin_enqueue_scripts() { @@ -13220,8 +12466,6 @@ function field_group_admin_enqueue_scripts() * Checks for a license status error and renders it if necessary. * * @since 6.2.1 - * - * @return void * @phpstan-return void */ public function maybe_show_license_status_error() @@ -13245,91 +12489,61 @@ class acf_admin_options_page /** @var array Contains the current options page */ var $page; /** - * __construct - * - * Initialize filters, action, variables and includes - * - * @type function - * @date 23/06/12 - * @since 5.0.0 + * Initialize filters, action, variables and includes * - * @param void - * @return void + * @since 5.0.0 */ - function __construct() + public function __construct() { } /** - * admin_menu - * - * description - * - * @type function - * @date 24/02/2014 - * @since 5.0.0 + * description * - * @param - * @return + * @since 5.0.0 + * @phpstan-return void */ - function admin_menu() + public function admin_menu() { } /** - * load - * - * description + * description * - * @type function - * @date 2/02/13 - * @since 3.6 + * @type function + * @date 2/02/13 + * @since 3.6 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function admin_load() { } /** - * admin_enqueue_scripts - * - * This function will enqueue the 'post.js' script which adds support for 'Screen Options' column toggle + * This function will enqueue the 'post.js' script which adds support for 'Screen Options' column toggle * - * @type function - * @date 23/03/2016 - * @since 5.3.2 - * - * @param - * @return + * @since 5.3.2 */ - function admin_enqueue_scripts() + public function admin_enqueue_scripts() { } /** - * admin_head - * - * This action will find and add field groups to the current edit page - * - * @type action (admin_head) - * @date 23/06/12 - * @since 3.1.8 + * This action will find and add field groups to the current edit page * - * @param void - * @return void + * @type action (admin_head) + * @since 3.1.8 */ - function admin_head() + public function admin_head() { } /** - * postbox_submitdiv + * This function will render the submitdiv metabox * - * This function will render the submitdiv metabox - * - * @type function - * @date 23/03/2016 - * @since 5.3.2 + * @type function + * @date 23/03/2016 + * @since 5.3.2 * - * @param void - * @return void + * @param void + * @return void */ function postbox_submitdiv($post, $args) { @@ -13337,23 +12551,18 @@ function postbox_submitdiv($post, $args) /** * Renders a postbox on an ACF options page. * - * @date 24/02/2014 * @since 5.0.0 * - * @param object $post - * @param array $args - * - * @return void + * @param object $post The post object + * @param array $args The metabox arguments */ - function postbox_acf($post, $args) + public function postbox_acf($post, $args) { } /** - * html + * description * - * @description: - * @since: 2.0.4 - * @created: 5/12/12 + * @since 2.0.4 */ function html() { @@ -13530,17 +12739,13 @@ public function admin_enqueue_scripts() /** * Sets up all functionality for the post type edit page to work. * - * @since 3.1.8 - * - * @return void + * @since 3.1.8 */ public function admin_head() { } /** * This action will allow ACF to render metaboxes after the title. - * - * @return void */ public function edit_form_after_title() { @@ -13548,10 +12753,10 @@ public function edit_form_after_title() /** * This function will add extra HTML to the acf form data element * - * @since 5.3.8 + * @since 5.3.8 * - * @param array $args Arguments array to pass through to action. - * @return void + * @param array $args Arguments array to pass through to action. + * @return void */ public function form_data($args) { @@ -13570,9 +12775,7 @@ public function admin_l10n($l10n) /** * Admin footer third party hook support * - * @since 5.3.2 - * - * @return void + * @since 5.3.2 */ public function admin_footer() { @@ -13591,8 +12794,7 @@ public function screen_settings($html) /** * Sets the "Edit Post Type" screen to use a one-column layout. * - * @param integer $columns Number of columns for layout. - * + * @param integer $columns Number of columns for layout. * @return integer */ public function screen_layout($columns = 0) @@ -13601,8 +12803,7 @@ public function screen_layout($columns = 0) /** * Force basic settings to always be visible * - * @param array $hidden_metaboxes The metaboxes hidden on this page. - * + * @param array $hidden_metaboxes The metaboxes hidden on this page. * @return array */ public function force_basic_settings($hidden_metaboxes) @@ -13611,8 +12812,7 @@ public function force_basic_settings($hidden_metaboxes) /** * Force advanced settings to be visible * - * @param array $hidden_metaboxes The metaboxes hidden on this page. - * + * @param array $hidden_metaboxes The metaboxes hidden on this page. * @return array */ public function force_advanced_settings($hidden_metaboxes) @@ -13621,9 +12821,7 @@ public function force_advanced_settings($hidden_metaboxes) /** * This function will customize the publish metabox * - * @since 5.2.9 - * - * @return void + * @since 5.2.9 */ public function post_submitbox_misc_actions() { @@ -13633,9 +12831,8 @@ public function post_submitbox_misc_actions() * * @since 1.0.0 * - * @param integer $post_id The post ID. - * @param WP_Post $post The post object. - * + * @param integer $post_id The post ID. + * @param WP_Post $post The post object. * @return integer $post_id */ public function save_post($post_id, $post) @@ -13645,8 +12842,6 @@ public function save_post($post_id, $post) * Renders HTML for the basic settings metabox. * * @since 6.2 - * - * @return void */ public function mb_basic_settings() { @@ -13655,8 +12850,6 @@ public function mb_basic_settings() * Renders the HTML for the advanced settings metabox. * * @since 6.2 - * - * @return void */ public function mb_advanced_settings() { @@ -13712,15 +12905,13 @@ class ACF_Admin_UI_Options_Pages extends \ACF_Admin_Internal_Post_Type_List /** * If this is a pro feature or not. * - * @var bool + * @var boolean */ public $is_pro_feature = \true; /** * Constructor. * * @since 6.2 - * - * @return void */ public function __construct() { @@ -13729,8 +12920,6 @@ public function __construct() * Current screen actions for the post types list admin page. * * @since 6.1 - * - * @return void * @phpstan-return void */ public function current_screen() @@ -13774,8 +12963,8 @@ public function render_admin_table_column($column_name, $post) * * @since 6.1 * - * @param string $action The action being performed. - * @param int $count The number of items the action was performed on. + * @param string $action The action being performed. + * @param integer $count The number of items the action was performed on. * @return string */ public function get_action_notice_text($action, $count = 1) @@ -13945,146 +13134,128 @@ public function modify_plugin_details($result, $action = \null, $args = \null) class acf_field_clone extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * is_enabled + * This function will return true if acf_local functionality is enabled * - * This function will return true if acf_local functionality is enabled - * - * @type function - * @date 14/07/2016 - * @since 5.4.0 + * @type function + * @date 14/07/2016 + * @since 5.4.0 * - * @param void - * @return void + * @param void + * @return void */ function is_enabled() { } /** - * load_field() + * This filter is appied to the $field after it is loaded from the database * - * This filter is appied to the $field after it is loaded from the database - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options + * @param $field - the field array holding all the field options * - * @return $field - the field array holding all the field options + * @return $field - the field array holding all the field options */ function load_field($field) { } /** - * acf_get_fields + * This function will hook into the 'acf/get_fields' filter and inject/replace seamless clones fields * - * This function will hook into the 'acf/get_fields' filter and inject/replace seamless clones fields - * - * @type function - * @date 17/06/2016 - * @since 5.3.8 + * @type function + * @date 17/06/2016 + * @since 5.3.8 * - * @param array $fields - * @param array $parent - * @return $fields + * @param array $fields + * @param array $parent + * @return $fields */ function acf_get_fields($fields, $parent) { } /** - * get_cloned_fields + * This function will return an array of fields for a given clone field * - * This function will return an array of fields for a given clone field - * - * @type function - * @date 28/06/2016 - * @since 5.3.8 + * @type function + * @date 28/06/2016 + * @since 5.3.8 * - * @param array $field - * @param array $parent - * @return array + * @param array $field + * @param array $parent + * @return array */ function get_cloned_fields($field) { } /** - * acf_clone_field + * This function is run when cloning a clone field + * Important to run the acf_clone_field function on sub fields to pass on settings such as 'parent_layout' * - * This function is run when cloning a clone field - * Important to run the acf_clone_field function on sub fields to pass on settings such as 'parent_layout' - * - * @type function - * @date 28/06/2016 - * @since 5.3.8 + * @type function + * @date 28/06/2016 + * @since 5.3.8 * - * @param array $field - * @param array $clone_field - * @return $field + * @param array $field + * @param array $clone_field + * @return $field */ function acf_clone_field($field, $clone_field) { } /** - * acf_clone_clone_field - * - * This function is run when cloning a clone field - * Important to run the acf_clone_field function on sub fields to pass on settings such as 'parent_layout' - * Do not delete! Removing this logic causes major issues with cloned clone fields within a flexible content layout. + * This function is run when cloning a clone field + * Important to run the acf_clone_field function on sub fields to pass on settings such as 'parent_layout' + * Do not delete! Removing this logic causes major issues with cloned clone fields within a flexible content layout. * - * @type function - * @date 28/06/2016 - * @since 5.3.8 + * @type function + * @date 28/06/2016 + * @since 5.3.8 * - * @param array $field - * @param array $clone_field - * @return $field + * @param array $field + * @param array $clone_field + * @return $field */ function acf_clone_clone_field($field, $clone_field) { } /** - * prepare_field_for_db - * - * description + * description * - * @type function - * @date 4/11/16 - * @since 5.5.0 + * @type function + * @date 4/11/16 + * @since 5.5.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function prepare_field_for_db($field) { } /** - * load_value() + * This filter is applied to the $value after it is loaded from the db * - * This filter is applied to the $value after it is loaded from the db - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value found in the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options - * @return $value + * @param mixed $value the value found in the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options + * @return $value */ function load_value($value, $post_id, $field) { @@ -14099,7 +13270,6 @@ function load_value($value, $post_id, $field) * @param mixed $post_id The $post_id from which the value was loaded. * @param array $field The field array holding all the field options. * @param boolean $escape_html Should the field return a HTML safe formatted value. - * * @return mixed $value The modified value. */ public function format_value($value, $post_id, $field, $escape_html = \false) @@ -14108,192 +13278,169 @@ public function format_value($value, $post_id, $field, $escape_html = \false) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) { } /** - * update_value() + * This filter is appied to the $value before it is updated in the db * - * This filter is appied to the $value before it is updated in the db - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $field - the field array holding all the field options - * @param $post_id - the $post_id of which the value will be saved + * @param $value - the value which will be saved in the database + * @param $field - the field array holding all the field options + * @param $post_id - the post_id of which the value will be saved * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 + * @phpstan-return void */ function render_field($field) { } /** - * render_field_block - * - * description + * description * - * @type function - * @date 12/07/2016 - * @since 5.4.0 + * @type function + * @date 12/07/2016 + * @since 5.4.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function render_field_block($field) { } /** - * render_field_table - * - * description + * description * - * @type function - * @date 12/07/2016 - * @since 5.4.0 + * @type function + * @date 12/07/2016 + * @since 5.4.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function render_field_table($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field_settings($field) { } /** - * get_clone_setting_choices + * This function will return an array of choices data for Select2 * - * This function will return an array of choices data for Select2 - * - * @type function - * @date 17/06/2016 - * @since 5.3.8 + * @type function + * @date 17/06/2016 + * @since 5.3.8 * - * @param mixed $value - * @return array + * @param mixed $value + * @return array */ function get_clone_setting_choices($value) { } /** - * get_clone_setting_choice - * - * This function will return the label for a given clone choice + * This function will return the label for a given clone choice * - * @type function - * @date 17/06/2016 - * @since 5.3.8 + * @type function + * @date 17/06/2016 + * @since 5.3.8 * - * @param mixed $selector - * @return string + * @param mixed $selector + * @return string */ function get_clone_setting_choice($selector = '') { } /** - * get_clone_setting_field_choice + * This function will return the text for a field choice * - * This function will return the text for a field choice - * - * @type function - * @date 20/07/2016 - * @since 5.4.0 + * @type function + * @date 20/07/2016 + * @since 5.4.0 * - * @param array $field - * @return string + * @param array $field + * @return string */ function get_clone_setting_field_choice($field) { } /** - * get_clone_setting_group_choice + * This function will return the text for a group choice * - * This function will return the text for a group choice - * - * @type function - * @date 20/07/2016 - * @since 5.4.0 + * @type function + * @date 20/07/2016 + * @since 5.4.0 * - * @param array $field_group - * @return string + * @param array $field_group + * @return string */ function get_clone_setting_group_choice($field_group) { } /** - * ajax_query - * - * description + * description * - * @type function - * @date 17/06/2016 - * @since 5.3.8 + * @type function + * @date 17/06/2016 + * @since 5.3.8 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function ajax_query() { } /** - * acf_prepare_field + * This function will restore a field's key ready for input * - * This function will restore a field's key ready for input - * - * @type function - * @date 6/09/2016 - * @since 5.4.0 + * @type function + * @date 6/09/2016 + * @since 5.4.0 * - * @param array $field - * @return $field + * @param array $field + * @return $field */ function acf_prepare_field($field) { } /** - * validate_value - * - * description + * description * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @type function + * @date 11/02/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function validate_value($valid, $value, $field, $input) { @@ -14311,108 +13458,94 @@ public function get_rest_schema(array $field) class acf_field_flexible_content extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ - function initialize() + public function initialize() { } /** - * input_admin_enqueue_scripts + * Admin scripts enqueue for field. * - * description - * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ - function input_admin_enqueue_scripts() + public function input_admin_enqueue_scripts() { } /** - * get_valid_layout - * - * This function will fill in the missing keys to create a valid layout + * This function will fill in the missing keys to create a valid layout * - * @type function - * @date 3/10/13 - * @since 1.1.0 + * @type function + * @date 3/10/13 + * @since 1.1.0 * - * @param array $layout - * @return array $layout + * @param array $layout + * @return array $layout */ function get_valid_layout($layout = array()) { } /** - * load_field() + * This filter is appied to the $field after it is loaded from the database * - * This filter is appied to the $field after it is loaded from the database - * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options + * @param $field - the field array holding all the field options * - * @return $field - the field array holding all the field options + * @return $field - the field array holding all the field options */ function load_field($field) { } /** - * get_sub_field + * This function will return a specific sub field * - * This function will return a specific sub field - * - * @type function - * @date 29/09/2016 - * @since 5.4.0 + * @type function + * @date 29/09/2016 + * @since 5.4.0 * - * @param $sub_field - * @param string $selector - * @param array $field - * @return int $post_id + * @param $sub_field + * @param string $selector + * @param array $field + * @return int $post_id */ function get_sub_field($sub_field, $id, $field) { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_layout - * - * description + * description * - * @type function - * @date 19/11/2013 - * @since 5.0.0 + * @type function + * @date 19/11/2013 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function render_layout($field, $layout, $i, $value) { @@ -14440,20 +13573,17 @@ function render_field_presentation_settings($field) { } /** - * load_value() - * - * This filter is applied to the $value after it is loaded from the db + * This filter is applied to the $value after it is loaded from the db * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 * - * @param mixed $value the value found in the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options - * @return $value + * @param mixed $value The value found in the database + * @param mixed $post_id The post_id from which the value was loaded + * @param array $field The field array holding all the field options + * @return $value */ - function load_value($value, $post_id, $field) + public function load_value($value, $post_id, $field) { } /** @@ -14462,42 +13592,38 @@ function load_value($value, $post_id, $field) * @type filter * @since 3.6 * - * @param mixed $value The value which was loaded from the database. - * @param mixed $post_id The $post_id from which the value was loaded. - * @param array $field The field array holding all the field options. - * @param boolean $escape_html Should the field return a HTML safe formatted value. - * - * @return mixed $value The modified value. + * @param mixed $value The value which was loaded from the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. + * @param boolean $escape_html Should the field return a HTML safe formatted value. + * @return mixed $value The modified value. */ public function format_value($value, $post_id, $field, $escape_html = \false) { } /** - * validate_value - * - * description + * description * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @type function + * @date 11/02/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ - function validate_value($valid, $value, $field, $input) + public function validate_value($valid, $value, $field, $input) { } /** * This function will return a specific layout by name from a field * - * @date 15/2/17 * @since 5.5.8 * - * @param string $name - * @param array $field - * @return array|false + * @param string $name The layout name. + * @param array $field The field to load the layout from. + * @return array|false */ - function get_layout($name, $field) + public function get_layout($name, $field) { } /** @@ -14506,12 +13632,12 @@ function get_layout($name, $field) * @date 15/2/17 * @since 5.5.8 * - * @param int $i - * @param array $field - * @param mixed $post_id - * @return bool + * @param integer $i + * @param array $field + * @param mixed $post_id + * @return boolean */ - function delete_row($i, $field, $post_id) + public function delete_row($i, $field, $post_id) { } /** @@ -14520,201 +13646,177 @@ function delete_row($i, $field, $post_id) * @date 15/2/17 * @since 5.5.8 * - * @param array $row - * @param int $i - * @param array $field - * @param mixed $post_id - * @return bool + * @param array $row + * @param integer $i + * @param array $field + * @param mixed $post_id + * @return boolean */ - function update_row($row, $i, $field, $post_id) + public function update_row($row, $i, $field, $post_id) { } /** - * update_value() - * - * This filter is appied to the $value before it is updated in the db + * This filter is appied to the $value before it is updated in the db * - * @type filter - * @since 3.6 - * @date 23/01/13 - * - * @param $value - the value which will be saved in the database - * @param $field - the field array holding all the field options - * @param $post_id - the $post_id of which the value will be saved + * @type filter + * @since 3.6 * - * @return $value - the modified value + * @param mixed $value The value which will be saved in the database + * @param mixed $post_id The post_id of which the value will be saved + * @param array $field The field array holding all the field options + * @return mixed $value The modified value */ - function update_value($value, $post_id, $field) + public function update_value($value, $post_id, $field) { } /** - * delete_value - * - * description + * Deletes a layout from a flexible content field. * - * @type function - * @date 1/07/2015 - * @since 5.2.3 + * @type function + * @date 1/07/2015 + * @since 5.2.3 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return void */ - function delete_value($post_id, $key, $field) + public function delete_value($post_id, $key, $field) { } /** - * update_field() + * This filter is appied to the $field before it is saved to the database * - * This filter is appied to the $field before it is saved to the database - * - * @type filter - * @since 3.6 - * @date 23/01/13 - * - * @param $field - the field array holding all the field options - * @param $post_id - the field group ID (post_type = acf) + * @type filter + * @since 3.6 * - * @return $field - the modified field + * @param array $field The field array holding all the field options + * @return array $field The modified field */ - function update_field($field) + public function update_field($field) { } /** - * delete_field - * - * description + * description * - * @type function - * @date 4/04/2014 - * @since 5.0.0 + * @type function + * @date 4/04/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function delete_field($field) { } /** - * duplicate_field() - * - * This filter is appied to the $field before it is duplicated and saved to the database + * This filter is appied to the $field before it is duplicated and saved to the database * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $field - the field array holding all the field options + * @param $field - the field array holding all the field options * - * @return $field - the modified field + * @return $field - the modified field */ function duplicate_field($field) { } /** - * ajax_layout_title - * - * description + * Output the layout title for an AJAX response. * - * @type function - * @date 2/03/2016 - * @since 5.3.2 - * - * @param int $post_id - * @return int $post_id + * @since 5.3.2 + * @phpstan-return never */ - function ajax_layout_title() + public function ajax_layout_title() { } - function get_layout_title($field, $layout, $i, $value) + /** + * Get a layout title for a field. + * + * @param array $field The field array + * @param array $layout The layout array + * @param integer $i The order number of the layout + * @param array $value The value of the layout + * @return string The layout title, optionally filtered. + */ + public function get_layout_title($field, $layout, $i, $value) { } /** - * clone_any_field + * This function will update clone field settings based on the origional field * - * This function will update clone field settings based on the origional field - * - * @type function - * @date 28/06/2016 - * @since 5.3.8 + * @type function + * @date 28/06/2016 + * @since 5.3.8 * - * @param array $clone - * @param array $field - * @return $clone + * @param array $clone + * @param array $field + * @return $clone */ - function clone_any_field($field, $clone_field) + public function clone_any_field($field, $clone_field) { } /** - * prepare_field_for_export - * - * description + * Handles preparing the layouts for export. * - * @type function - * @date 11/03/2014 - * @since 5.0.0 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param array $field The whole fiel array + * @return array The export ready field array. */ - function prepare_field_for_export($field) + public function prepare_field_for_export($field) { } function prepare_any_field_for_export($field) { } /** - * prepare_field_for_import - * - * description + * description * - * @type function - * @date 11/03/2014 - * @since 5.0.0 + * @type function + * @date 11/03/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ - function prepare_field_for_import($field) + public function prepare_field_for_import($field) { } /** - * validate_any_field - * - * This function will add compatibility for the 'column_width' setting + * This function will add compatibility for the 'column_width' setting * - * @type function - * @date 30/1/17 - * @since 5.5.6 + * @type function + * @date 30/1/17 + * @since 5.5.6 * - * @param array $field - * @return $field + * @param array $field + * @return $field */ function validate_any_field($field) { } /** - * translate_field + * This function will translate field settings * - * This function will translate field settings - * - * @type function - * @date 8/03/2016 - * @since 5.3.2 + * @type function + * @date 8/03/2016 + * @since 5.3.2 * - * @param array $field - * @return $field + * @param array $field + * @return $field */ function translate_field($field) { } /** - * Additional validation for the flexible content field when submitted via REST. - * - * @param bool $valid - * @param int $value - * @param array $field + * Additional validation for the flexible content field when submitted via REST. * - * @return bool|WP_Error + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP */ public function validate_rest_value($valid, $value, $field) { @@ -14731,9 +13833,9 @@ public function get_rest_schema(array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param int|string $post_id - * @param array $field + * @param mixed $value + * @param integer|string $post_id + * @param array $field * @return array|mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -14743,76 +13845,69 @@ public function format_value_for_rest($value, $post_id, array $field) class acf_field_gallery extends \acf_field { /** - * __construct - * - * This function will setup the field type data + * This function will setup the field type data * - * @type function - * @date 5/03/2014 - * @since 5.0.0 + * @type function + * @date 5/03/2014 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function initialize() { } /** - * input_admin_enqueue_scripts - * - * description + * description * - * @type function - * @date 16/12/2015 - * @since 5.3.2 + * @type function + * @date 16/12/2015 + * @since 5.3.2 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function input_admin_enqueue_scripts() { } /** - * ajax_get_attachment - * - * description + * description * - * @type function - * @date 13/12/2013 - * @since 5.0.0 + * @type function + * @date 13/12/2013 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return never */ function ajax_get_attachment() { } /** - * ajax_update_attachment - * - * description + * description * - * @type function - * @date 13/12/2013 - * @since 5.0.0 + * @type function + * @date 13/12/2013 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return never */ function ajax_update_attachment() { } /** - * ajax_get_sort_order - * - * description + * description * - * @type function - * @date 13/12/2013 - * @since 5.0.0 + * @type function + * @date 13/12/2013 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id + * @phpstan-return never */ function ajax_get_sort_order() { @@ -14823,38 +13918,34 @@ function ajax_get_sort_order() * @date 13/12/2013 * @since 5.0.0 * - * @param int $id The attachment ID. - * @param array $field The field array. + * @param integer $id The attachment ID. + * @param array $field The field array. * @return void */ function render_attachment($id, $field) { } /** - * render_field() - * - * Create the HTML interface for your field + * Create the HTML interface for your field * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 */ function render_field($field) { } /** - * render_field_settings() - * - * Create extra options for your field. This is rendered when editing a field. - * The value of $field['name'] can be used (like bellow) to save extra data to the $field + * Create extra options for your field. This is rendered when editing a field. + * The value of $field['name'] can be used (like bellow) to save extra data to the $field * - * @type action - * @since 3.6 - * @date 23/01/13 + * @type action + * @since 3.6 + * @date 23/01/13 * - * @param $field - an array holding all the field's data + * @param $field - an array holding all the field's data */ function render_field_settings($field) { @@ -14882,52 +13973,46 @@ function render_field_presentation_settings($field) { } /** - * format_value() - * - * This filter is appied to the $value after it is loaded from the db and before it is returned to the template + * This filter is appied to the $value after it is loaded from the db and before it is returned to the template * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param mixed $value the value which was loaded from the database - * @param mixed $post_id the $post_id from which the value was loaded - * @param array $field the field array holding all the field options + * @param mixed $value the value which was loaded from the database + * @param mixed $post_id the post_id from which the value was loaded + * @param array $field the field array holding all the field options * - * @return mixed $value the modified value + * @return mixed $value the modified value */ function format_value($value, $post_id, $field) { } /** - * validate_value - * - * description + * description * - * @type function - * @date 11/02/2014 - * @since 5.0.0 + * @type function + * @date 11/02/2014 + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function validate_value($valid, $value, $field, $input) { } /** - * update_value() - * - * This filter is appied to the $value before it is updated in the db + * This filter is appied to the $value before it is updated in the db * - * @type filter - * @since 3.6 - * @date 23/01/13 + * @type filter + * @since 3.6 + * @date 23/01/13 * - * @param $value - the value which will be saved in the database - * @param $post_id - the $post_id of which the value will be saved - * @param $field - the field array holding all the field options + * @param $value - the value which will be saved in the database + * @param $post_id - the post_id of which the value will be saved + * @param $field - the field array holding all the field options * - * @return $value - the modified value + * @return $value - the modified value */ function update_value($value, $post_id, $field) { @@ -14935,11 +14020,10 @@ function update_value($value, $post_id, $field) /** * Validates file fields updated via the REST API. * - * @param bool $valid - * @param int $value - * @param array $field - * - * @return bool|WP_Error + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP */ public function validate_rest_value($valid, $value, $field) { @@ -14955,9 +14039,9 @@ public function get_rest_schema(array $field) } /** * @see \acf_field::get_rest_links() - * @param mixed $value The raw (unformatted) field value. - * @param int|string $post_id - * @param array $field + * @param mixed $value The raw (unformatted) field value. + * @param integer|string $post_id + * @param array $field * @return array */ public function get_rest_links($value, $post_id, array $field) @@ -14966,9 +14050,9 @@ public function get_rest_links($value, $post_id, array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param string|int $post_id - * @param array $field + * @param mixed $value + * @param string|integer $post_id + * @param array $field * @return mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -14980,7 +14064,7 @@ class acf_field_repeater extends \acf_field /** * If we're currently rendering fields. * - * @var bool + * @var boolean */ public $is_rendering = \false; /** @@ -15081,11 +14165,10 @@ function render_field_presentation_settings($field) * Filters the field $value after it is loaded from the database. * * @since 3.6 - * @date 23/01/13 * - * @param mixed $value The value found in the database. - * @param mixed $post_id The $post_id from which the value was loaded. - * @param array $field The field array holding all the field options. + * @param mixed $value The value found in the database. + * @param mixed $post_id The $post_id from which the value was loaded. + * @param array $field The field array holding all the field options. * @return array $value */ public function load_value($value, $post_id, $field) @@ -15101,8 +14184,7 @@ public function load_value($value, $post_id, $field) * @param mixed $post_id The $post_id from which the value was loaded. * @param array $field The field array holding all the field options. * @param boolean $escape_html Should the field return a HTML safe formatted value. - * - * @return array $value The modified value. + * @return array $value The modified value. */ public function format_value($value, $post_id, $field, $escape_html = \false) { @@ -15113,12 +14195,11 @@ public function format_value($value, $post_id, $field, $escape_html = \false) * @date 11/02/2014 * @since 5.0.0 * - * @param bool $valid If the field is valid. - * @param mixed $value The value to validate. - * @param array $field The main field array. - * @param string $input The input element's name attribute. - * - * @return bool + * @param boolean $valid If the field is valid. + * @param mixed $value The value to validate. + * @param array $field The main field array. + * @param string $input The input element's name attribute. + * @return boolean */ function validate_value($valid, $value, $field, $input) { @@ -15129,10 +14210,10 @@ function validate_value($valid, $value, $field, $input) * @date 15/2/17 * @since 5.5.8 * - * @param array $row - * @param int $i - * @param array $field - * @param mixed $post_id + * @param array $row + * @param integer $i + * @param array $field + * @param mixed $post_id * @return boolean */ function update_row($row, $i, $field, $post_id) @@ -15144,9 +14225,9 @@ function update_row($row, $i, $field, $post_id) * @date 15/2/17 * @since 5.5.8 * - * @param int $i - * @param array $field - * @param mixed $post_id + * @param integer $i + * @param array $field + * @param mixed $post_id * @return boolean */ function delete_row($i, $field, $post_id) @@ -15158,13 +14239,12 @@ function delete_row($i, $field, $post_id) * @since 3.6 * @date 23/01/13 * - * @param mixed $value The value which will be saved in the database. - * @param array $field The field array holding all the field options. - * @param mixed $post_id The $post_id of which the value will be saved. - * + * @param mixed $value The value which will be saved in the database. + * @param mixed $post_id The $post_id of which the value will be saved. + * @param array $field The field array holding all the field options. * @return mixed $value */ - function update_value($value, $post_id, $field) + public function update_value($value, $post_id, $field) { } /** @@ -15186,9 +14266,9 @@ function delete_field($field) * @date 1/07/2015 * @since 5.2.3 * - * @param int $post_id The post ID to delete the value from. - * @param string $key The meta name/key (unused). - * @param array $field The main field array. + * @param integer $post_id The post ID to delete the value from. + * @param string $key The meta name/key (unused). + * @param array $field The main field array. * @return void * @phpstan-return void */ @@ -15199,13 +14279,11 @@ function delete_value($post_id, $key, $field) * This filter is applied to the $field before it is saved to the database. * * @since 3.6 - * @date 23/01/13 - * - * @param array $field The field array holding all the field options. * + * @param array $field The field array holding all the field options. * @return array */ - function update_field($field) + public function update_field($field) { } /** @@ -15271,11 +14349,10 @@ function prepare_field_for_import($field) /** * Additional validation for the repeater field when submitted via REST. * - * @param bool $valid - * @param int $value - * @param array $field - * - * @return bool|WP_Error + * @param boolean $valid The current validity booleean + * @param integer $value The value of the field + * @param array $field The field array + * @return boolean|WP */ public function validate_rest_value($valid, $value, $field) { @@ -15292,9 +14369,9 @@ public function get_rest_schema(array $field) /** * Apply basic formatting to prepare the value for default REST output. * - * @param mixed $value - * @param int|string $post_id - * @param array $field + * @param mixed $value + * @param integer|string $post_id + * @param array $field * @return array|mixed */ public function format_value_for_rest($value, $post_id, array $field) @@ -15304,9 +14381,8 @@ public function format_value_for_rest($value, $post_id, array $field) * Takes the provided input name and turns it into a field name that * works with repeater fields that are subfields of other fields. * - * @param string $input_name The name attribute used in the repeater. - * - * @return string|bool + * @param string $input_name The name attribute used in the repeater. + * @return string|boolean */ public function get_field_name_from_input_name($input_name) { @@ -15328,8 +14404,6 @@ public function ajax_get_rows() * * Helper class for rendering repeater tables. * - * @package ACF - * @since 6.0.0 */ class ACF_Repeater_Table { @@ -15367,7 +14441,7 @@ public function thead() * * @since 6.0.0 * - * @param bool $return If we should return the rows or render them. + * @param boolean $return If we should return the rows or render them. * @return array|void */ public function rows($return = \false) @@ -15378,9 +14452,9 @@ public function rows($return = \false) * * @since 6.0.0 * - * @param int $i The row number. - * @param array $row An array containing the row values. - * @param bool $return If we should return the row or render it. + * @param integer $i The row number. + * @param array $row An array containing the row values. + * @param boolean $return If we should return the row or render it. * @return string|void */ public function row($i, $row, $return = \false) @@ -15391,7 +14465,7 @@ public function row($i, $row, $return = \false) * * @since 6.0.0 * - * @param int $i The current row number. + * @param integer $i The current row number. * @return void * @phpstan-return void */ @@ -15453,10 +14527,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -15494,10 +14568,10 @@ public function initialize() * @date 9/4/20 * @since 5.9.0 * - * @param array $rule The location rule. - * @param array $screen The screen args. + * @param array $rule The location rule. + * @param array $screen The screen args. * @param array $field_group The field group settings. - * @return bool + * @return boolean */ public function match($rule, $screen, $field_group) { @@ -15520,16 +14594,14 @@ class acf_options_page /** @var array Contains an array of options page settings */ var $pages = array(); /** - * __construct - * - * Initialize filters, action, variables and includes + * Initialize filters, action, variables and includes * - * @type function - * @date 23/06/12 - * @since 5.0.0 + * @type function + * @date 23/06/12 + * @since 5.0.0 * - * @param void - * @return void + * @param void + * @return void */ function __construct() { @@ -15547,77 +14619,67 @@ function validate_page($page) { } /** - * add_page - * - * This function will store an options page settings + * This function will store an options page settings * - * @type function - * @date 9/6/17 - * @since 5.6.0 + * @type function + * @date 9/6/17 + * @since 5.6.0 * - * @param array $page - * @return void + * @param array $page + * @return void */ function add_page($page) { } /** - * add_sub_page - * - * description + * description * - * @type function - * @date 9/6/17 - * @since 5.6.0 + * @type function + * @date 9/6/17 + * @since 5.6.0 * - * @param int $post_id - * @return int $post_id + * @param int $post_id + * @return int $post_id */ function add_sub_page($page) { } /** - * update_page - * - * This function will update an options page settings + * This function will update an options page settings * - * @type function - * @date 9/6/17 - * @since 5.6.0 + * @type function + * @date 9/6/17 + * @since 5.6.0 * - * @param string $slug - * @param array $data - * @return array + * @param string $slug + * @param array $data + * @return array */ function update_page($slug = '', $data = array()) { } /** - * get_page + * This function will return an options page settings * - * This function will return an options page settings - * - * @type function - * @date 6/07/2016 - * @since 5.4.0 + * @type function + * @date 6/07/2016 + * @since 5.4.0 * - * @param string $slug - * @return mixed + * @param string $slug + * @return mixed */ function get_page($slug) { } /** - * get_pages - * - * This function will return all options page settings + * This function will return all options page settings * - * @type function - * @date 6/07/2016 - * @since 5.4.0 + * @type function + * @date 6/07/2016 + * @since 5.4.0 * - * @param string $slug - * @return mixed + * @param string $slug + * @return mixed */ function get_pages() { @@ -15705,7 +14767,7 @@ public function get_settings_array() * * @since 6.2 * - * @return bool validity status + * @return boolean validity status */ public function ajax_validate_values() { @@ -15736,8 +14798,6 @@ public function setup_local_json() * Includes all local JSON options pages. * * @since 6.1 - * - * @return void * @phpstan-return void */ public function include_json_options_pages() @@ -15944,7 +15004,7 @@ function acf_get_field_post($id = 0) * @since 5.0.0 * * @param string $id The identifier. - * @return bool + * @return boolean */ function acf_is_field_key($id = '') { @@ -16013,7 +15073,7 @@ function acf_get_fields($parent) * @date 18/1/19 * @since 5.7.10 * - * @param int $id The field group or field id. + * @param integer $id The field group or field id. * @return array */ function acf_get_raw_fields($id = 0) @@ -16028,7 +15088,7 @@ function acf_get_raw_fields($id = 0) * @since 5.0.0 * * @param array $parent The field group or field array. - * @return int + * @return integer */ function acf_get_field_count($parent) { @@ -16041,7 +15101,7 @@ function acf_get_field_count($parent) * @date 8/03/2016 * @since 5.3.2 * - * @param array $field The field being cloned. + * @param array $field The field being cloned. * @param array $clone_field The clone field. * @return array */ @@ -16071,9 +15131,9 @@ function acf_prepare_field($field) * @since 5.0.0 * @since 5.6.9 Changed parameter order. * - * @param array $fields An array of fields. - * @param int|string $post_id The post ID to load values from. - * @param string $element The wrapping element type. + * @param array $fields An array of fields. + * @param int|string $post_id The post ID to load values from. + * @param string $element The wrapping element type. * @param string $instruction The instruction render position (label|field). * @return void */ @@ -16085,10 +15145,10 @@ function acf_render_fields($fields, $post_id = 0, $el = 'div', $instruction = 'l * * @since 5.0.0 * - * @param array $field The field array. - * @param string $element The wrapping element type. - * @param string $instruction The instruction render position (label|field). - * @param bool $field_setting If a field setting is being rendered. + * @param array $field The field array. + * @param string $element The wrapping element type. + * @param string $instruction The instruction render position (label|field). + * @param boolean $field_setting If a field setting is being rendered. * @return void * @phpstan-return void */ @@ -16132,7 +15192,7 @@ function acf_render_field_label($field) * @date 4/11/2013 * @since 5.0.0 * - * @param array $field The field array. + * @param array $field The field array. * @param string $context The output context (admin). * @return string The field label in HTML format. */ @@ -16159,9 +15219,9 @@ function acf_render_field_instructions($field, $tooltip = \false) * @date 21/1/19 * @since 5.7.10 * - * @param array $field The field array. - * @param array $setting The settings field array. - * @param bool $global Whether this setting is a global or field type specific one. + * @param array $field The field array. + * @param array $setting The settings field array. + * @param boolean $global Whether this setting is a global or field type specific one. * @return void */ function acf_render_field_setting($field, $setting, $global = \false) @@ -16175,7 +15235,7 @@ function acf_render_field_setting($field, $setting, $global = \false) * @date 21/1/19 * @since 5.7.10 * - * @param array $field The field array. + * @param array $field The field array. * @param array $specific An array of specific field attributes to update. * @return array */ @@ -16190,12 +15250,12 @@ function acf_update_field($field, $specific = array()) * @date 21/1/19 * @since 5.7.10 * - * @param string $slug The post slug. - * @param int $post_ID Post ID. - * @param string $post_status The post status. - * @param string $post_type Post type. - * @param int $post_parent Post parent ID - * @param string $original_slug The original post slug. + * @param string $slug The post slug. + * @param integer $post_ID Post ID. + * @param string $post_status The post status. + * @param string $post_type Post type. + * @param integer $post_parent Post parent ID + * @param string $original_slug The original post slug. */ function _acf_apply_unique_field_slug($slug, $post_ID, $post_status, $post_type, $post_parent, $original_slug) { @@ -16223,7 +15283,7 @@ function acf_flush_field_cache($field) * @since 5.7.10 * * @param int|string $id The field ID, key or name. - * @return bool True if field was deleted. + * @return boolean True if field was deleted. */ function acf_delete_field($id = 0) { @@ -16237,7 +15297,7 @@ function acf_delete_field($id = 0) * @since 5.0.0 * * @param int|string $id The field ID, key or name. - * @return bool True if field was trashed. + * @return boolean True if field was trashed. */ function acf_trash_field($id = 0) { @@ -16251,7 +15311,7 @@ function acf_trash_field($id = 0) * @since 5.0.0 * * @param int|string $id The field ID, key or name. - * @return bool True if field was trashed. + * @return boolean True if field was trashed. */ function acf_untrash_field($id = 0) { @@ -16263,9 +15323,9 @@ function acf_untrash_field($id = 0) * * @since 5.9.5 * - * @param string $new_status The new status of the post being restored. - * @param int $post_id The ID of the post being restored. - * @param string $previous_status The status of the post at the point where it was trashed. + * @param string $new_status The new status of the post being restored. + * @param integer $post_id The ID of the post being restored. + * @param string $previous_status The status of the post at the point where it was trashed. * @return string. */ function _acf_untrash_field_post_status($new_status, $post_id, $previous_status) @@ -16294,7 +15354,7 @@ function acf_prefix_fields(&$fields, $prefix = 'acf') * @date 21/1/19 * @since 5.7.10 * - * @param int|string $id The field ID, key or name. + * @param int|string $id The field ID, key or name. * @param array $field The parent field array. * @return array|false */ @@ -16309,7 +15369,7 @@ function acf_get_sub_field($id, $field) * @date 12/2/19 * @since 5.7.11 * - * @param int|string $id The field ID, key or name. + * @param int|string $id The field ID, key or name. * @param array $haystack The array of fields. * @return int|false */ @@ -16325,8 +15385,8 @@ function acf_search_fields($id, $fields) * @since 5.7.10 * * @param array $field The field array. - * @param mixed $id An optional identifier to search for. - * @return bool + * @param mixed $id An optional identifier to search for. + * @return boolean */ function acf_is_field($field = \false, $id = '') { @@ -16353,8 +15413,8 @@ function acf_get_field_ancestors($field) * @date 16/06/2014 * @since 5.0.0 * - * @param array $fields An array of fields. - * @param int $parent_id The new parent ID. + * @param array $fields An array of fields. + * @param integer $parent_id The new parent ID. * @return array */ function acf_duplicate_fields($fields = array(), $parent_id = 0) @@ -16368,9 +15428,9 @@ function acf_duplicate_fields($fields = array(), $parent_id = 0) * @date 16/06/2014 * @since 5.0.0 * - * @param int|string $id The field ID, key or name. - * @param int $parent_id The new parent ID. - * @return bool True if field was duplicated. + * @param int|string $id The field ID, key or name. + * @param integer $parent_id The new parent ID. + * @return boolean True if field was duplicated. */ function acf_duplicate_field($id = 0, $parent_id = 0) { @@ -16483,7 +15543,7 @@ function acf_get_field_group_post($id = 0) * @since 5.0.0 * * @param string $id The identifier. - * @return bool + * @return boolean */ function acf_is_field_group_key($id = '') { @@ -16565,7 +15625,7 @@ function acf_get_raw_field_groups() * @since 5.0.0 * * @param array $field_groups An array of field groups. - * @param array $args An array of location args. + * @param array $args An array of location args. * @return array */ function acf_filter_field_groups($field_groups, $args = array()) @@ -16580,8 +15640,8 @@ function acf_filter_field_groups($field_groups, $args = array()) * @since 5.0.0 * * @param array $field_groups An array of field groups. - * @param array $args An array of location args. - * @return bool + * @param array $args An array of location args. + * @return boolean */ function acf_get_field_group_visibility($field_group, $args = array()) { @@ -16608,12 +15668,12 @@ function acf_update_field_group($field_group) * @date 21/1/19 * @since 5.7.10 * - * @param string $slug The post slug. - * @param int $post_ID Post ID. - * @param string $post_status The post status. - * @param string $post_type Post type. - * @param int $post_parent Post parent ID - * @param string $original_slug The original post slug. + * @param string $slug The post slug. + * @param integer $post_ID Post ID. + * @param string $post_status The post status. + * @param string $post_type Post type. + * @param integer $post_parent Post parent ID + * @param string $original_slug The original post slug. */ function _acf_apply_unique_field_group_slug($slug, $post_ID, $post_status, $post_type, $post_parent, $original_slug) { @@ -16641,7 +15701,7 @@ function acf_flush_field_group_cache($field_group) * @since 5.7.10 * * @param int|string $id The field group ID, key or name. - * @return bool True if field group was deleted. + * @return boolean True if field group was deleted. */ function acf_delete_field_group($id = 0) { @@ -16655,7 +15715,7 @@ function acf_delete_field_group($id = 0) * @since 5.0.0 * * @param int|string $id The field group ID, key or name. - * @return bool True if field group was trashed. + * @return boolean True if field group was trashed. */ function acf_trash_field_group($id = 0) { @@ -16669,7 +15729,7 @@ function acf_trash_field_group($id = 0) * @since 5.0.0 * * @param int|string $id The field_group ID, key or name. - * @return bool True if field_group was trashed. + * @return boolean True if field_group was trashed. */ function acf_untrash_field_group($id = 0) { @@ -16681,9 +15741,9 @@ function acf_untrash_field_group($id = 0) * * @since 5.9.5 * - * @param string $new_status The new status of the post being restored. - * @param int $post_id The ID of the post being restored. - * @param string $previous_status The status of the post at the point where it was trashed. + * @param string $new_status The new status of the post being restored. + * @param integer $post_id The ID of the post being restored. + * @param string $previous_status The status of the post at the point where it was trashed. * @return string. */ function _acf_untrash_field_group_post_status($new_status, $post_id, $previous_status) @@ -16698,8 +15758,8 @@ function _acf_untrash_field_group_post_status($new_status, $post_id, $previous_s * @since 5.7.10 * * @param array $field_group The field group array. - * @param mixed $id An optional identifier to search for. - * @return bool + * @param mixed $id An optional identifier to search for. + * @return boolean */ function acf_is_field_group($field_group = \false) { @@ -16712,8 +15772,8 @@ function acf_is_field_group($field_group = \false) * @date 16/06/2014 * @since 5.0.0 * - * @param int|string $id The field_group ID, key or name. - * @param int $new_post_id Optional post ID to override. + * @param int|string $id The field_group ID, key or name. + * @param integer $new_post_id Optional post ID to override. * @return array The new field group. */ function acf_duplicate_field_group($id = 0, $new_post_id = 0) @@ -16722,9 +15782,9 @@ function acf_duplicate_field_group($id = 0, $new_post_id = 0) /** * Activates or deactivates a field group. * - * @param int|string $id The field_group ID, key or name. - * @param bool $activate True if the post should be activated. - * @return bool + * @param integer|string $id The field_group ID, key or name. + * @param boolean $activate True if the post should be activated. + * @return boolean */ function acf_update_field_group_active_status($id, $activate = \true) { @@ -16751,7 +15811,7 @@ function acf_get_field_group_style($field_group) * @date 23/9/18 * @since 5.7.7 * - * @param int $post_id The field group ID. + * @param integer $post_id The field group ID. * @return string */ function acf_get_field_group_edit_link($post_id) @@ -16800,14 +15860,14 @@ function acf_import_field_group($field_group) { } /** - * Returns an array of tabs for the field group settings. - * We combine a list of default tabs with filtered tabs. - * I.E. Default tabs should be static and should not be changed by the - * filtered tabs. + * Returns an array of tabs for the field group settings. + * We combine a list of default tabs with filtered tabs. + * I.E. Default tabs should be static and should not be changed by the + * filtered tabs. * - * @since 6.1 + * @since 6.1 * - * @return array Key/value array of the default settings tabs for field group settings. + * @return array Key/value array of the default settings tabs for field group settings. */ function acf_get_combined_field_group_settings_tabs() { @@ -16863,9 +15923,9 @@ function acf_form_data($data = array()) * @date 15/10/13 * @since 5.0.0 * - * @param int|string $post_id The post id. - * @param array $values An array of values to override $_POST. - * @return bool True if save was successful. + * @param integer|string $post_id The post id. + * @param array $values An array of values to override $_POST. + * @return boolean True if save was successful. */ function acf_save_post($post_id = 0, $values = \null) { @@ -16879,43 +15939,37 @@ function acf_save_post($post_id = 0, $values = \null) * @date 11/1/19 * @since 5.7.10 * - * @param int|string $post_id The post id. + * @param integer|string $post_id The post id. * @return void */ function _acf_do_save_post($post_id = 0) { } /** - * acf_is_empty - * * Returns true if the value provided is considered "empty". Allows numbers such as 0. * * @date 6/7/16 * @since 5.4.0 * * @param mixed $var The value to check. - * @return bool + * @return boolean */ function acf_is_empty($var) { } /** - * acf_not_empty - * * Returns true if the value provided is considered "not empty". Allows numbers such as 0. * * @date 15/7/19 * @since 5.8.1 * * @param mixed $var The value to check. - * @return bool + * @return boolean */ function acf_not_empty($var) { } /** - * acf_uniqid - * * Returns a unique numeric based id. * * @date 9/1/19 @@ -16928,8 +15982,6 @@ function acf_uniqid($prefix = 'acf') { } /** - * acf_merge_attributes - * * Merges together two arrays but with extra functionality to append class names. * * @date 22/1/19 @@ -16976,7 +16028,7 @@ function acf_request_args($args = array()) * @date 23/10/20 * @since 5.9.2 * - * @param string $key The property name. + * @param string $key The property name. * @param mixed $default The default value to fallback to. * @return mixed */ @@ -17090,7 +16142,7 @@ function acf_enable_filters($filters = array()) * @since 5.7.14 * * @param mixed $value A value to parse. - * @return int + * @return integer */ function acf_idval($value) { @@ -17153,7 +16205,7 @@ function acf_idify($str = '') * @date 24/12/17 * @since 5.6.5 * - * @param string $str The string to convert. + * @param string $str The string to convert. * @param string $glue The glue between each slug piece. * @return string */ @@ -17181,7 +16233,7 @@ function acf_punctify($str = '') * @since 5.8.1 * * @param string $name The name of the event. - * @return bool + * @return boolean */ function acf_did($name) { @@ -17199,7 +16251,7 @@ function acf_did($name) * @since 5.9.0 * * @param string $str The string to review. - * @return int + * @return integer */ function acf_strlen($str) { @@ -17210,7 +16262,7 @@ function acf_strlen($str) * @date 6/4/20 * @since 5.9.0 * - * @param mixed $value The value. + * @param mixed $value The value. * @param mixed $default_value The default value. * @return mixed */ @@ -17224,7 +16276,7 @@ function acf_with_default($value, $default_value) * @since 5.9.0 * * @param string $action The action name. - * @return int|bool + * @return integer|boolean */ function acf_doing_action($action) { @@ -17246,12 +16298,12 @@ function acf_get_current_url() * * @since 6.0.0 * - * @param string $url The URL to be tagged. - * @param string $campaign The campaign tag. - * @param string $content The UTM content tag. - * @param bool $anchor An optional anchor ID. - * @param string $source An optional UTM source tag. - * @param string $medium An optional UTM medium tag. + * @param string $url The URL to be tagged. + * @param string $campaign The campaign tag. + * @param string $content The UTM content tag. + * @param boolean $anchor An optional anchor ID. + * @param string $source An optional UTM source tag. + * @param string $medium An optional UTM medium tag. * @return string */ function acf_add_url_utm_tags($url, $campaign, $content, $anchor = \false, $source = '', $medium = '') @@ -17262,7 +16314,7 @@ function acf_add_url_utm_tags($url, $campaign, $content, $anchor = \false, $sour * * @param mixed $args The data to sanitize. * - * @return array|bool|float|int|mixed|string + * @return array|boolean|float|integer|mixed|string */ function acf_sanitize_request_args($args = array()) { @@ -17286,7 +16338,7 @@ function acf_sanitize_files_array(array $args = array()) * * @since 6.0.5 * - * @param array $array The file upload array. + * @param array $array The file upload array. * @param string $sanitize_function Callback used to sanitize array value. * @return array */ @@ -17322,9 +16374,9 @@ function acf_is_pro() * @date 26/1/19 * @since 5.7.11 * - * @param string $filter The filter name. - * @param array $variations An array variation keys. - * @param int $index The param index to find variation values. + * @param string $filter The filter name. + * @param array $variations An array variation keys. + * @param integer $index The param index to find variation values. * @return void */ function acf_add_filter_variations($filter = '', $variations = array(), $index = 0) @@ -17338,9 +16390,9 @@ function acf_add_filter_variations($filter = '', $variations = array(), $index = * @date 26/1/19 * @since 5.7.11 * - * @param string $action The action name. - * @param array $variations An array variation keys. - * @param int $index The param index to find variation values. + * @param string $action The action name. + * @param array $variations An array variation keys. + * @param integer $index The param index to find variation values. * @return void */ function acf_add_action_variations($action = '', $variations = array(), $index = 0) @@ -17368,8 +16420,8 @@ function _acf_apply_hook_variations() * @date 25/1/19 * @since 5.7.11 * - * @param string $deprecated The deprecated hook. - * @param string $version The version this hook was deprecated. + * @param string $deprecated The deprecated hook. + * @param string $version The version this hook was deprecated. * @param string $replacement The replacement hook. * @return void */ @@ -17384,8 +16436,8 @@ function acf_add_deprecated_filter($deprecated, $version, $replacement) * @date 25/1/19 * @since 5.7.11 * - * @param string $deprecated The deprecated hook. - * @param string $version The version this hook was deprecated. + * @param string $deprecated The deprecated hook. + * @param string $version The version this hook was deprecated. * @param string $replacement The replacement hook. * @return void */ @@ -17452,7 +16504,7 @@ function acf_esc_html($string = '') * @date 16/4/21 * @since 5.9.6 * - * @param array $tags An array of allowed tags. + * @param array $tags An array of allowed tags. * @param string $context The context name. * @return array. */ @@ -17678,8 +16730,8 @@ function acf_get_select_input($attrs = array()) * @since 5.6.0 * * @param array $choices The choices to walk through. - * @param array $values The selected choices. - * @param array $depth The current walk depth. + * @param array $values The selected choices. + * @param array $depth The current walk depth. * @return string */ function acf_walk_select_input($choices = array(), $values = array(), $depth = 0) @@ -17716,11 +16768,10 @@ function acf_esc_atts($attrs) /** * acf_esc_attr * - * See acf_esc_attrs(). - * * @date 13/6/19 * @since 5.8.1 * @deprecated 5.6.0 + * @see acf_esc_attrs(). * * @param array $attrs The array of attrs. * @return string @@ -17738,7 +16789,6 @@ function acf_esc_attr($attrs) * @deprecated 5.6.0 * * @param array $attrs The array of attrs. - * @return string */ function acf_esc_attr_e($attrs) { @@ -17753,7 +16803,6 @@ function acf_esc_attr_e($attrs) * @deprecated 5.6.0 * * @param array $attrs The array of attrs. - * @return string */ function acf_esc_atts_e($attrs) { @@ -17775,8 +16824,8 @@ function acf_get_internal_post_type_instance($post_type = 'acf-field-group') /** * Get an ACF CPT object as an array * - * @param int $id The post ID being queried. - * @param string $post_type The post type being queried. + * @param integer $id The post ID being queried. + * @param string $post_type The post type being queried. * @return array|false The post type object. */ function acf_get_internal_post_type($id, $post_type) @@ -17787,8 +16836,8 @@ function acf_get_internal_post_type($id, $post_type) * * @since 6.1 * - * @param int|string $id The post ID. - * @param string $post_type The post type name. + * @param integer|string $id The post ID. + * @param string $post_type The post type name. * @return array|false The internal post type array. */ function acf_get_raw_internal_post_type($id, $post_type) @@ -17799,9 +16848,9 @@ function acf_get_raw_internal_post_type($id, $post_type) * * @since 6.1 * - * @param int|string $id The post ID, key, or name. - * @param string $post_type The post type name. - * @return object|bool The post object, or false on failure. + * @param integer|string $id The post ID, key, or name. + * @param string $post_type The post type name. + * @return object|boolean The post object, or false on failure. */ function acf_get_internal_post_type_post($id, $post_type) { @@ -17813,7 +16862,7 @@ function acf_get_internal_post_type_post($id, $post_type) * * @param string $id The identifier. * @param string $post_type The ACF post type the key is for. - * @return bool + * @return boolean */ function acf_is_internal_post_type_key($id = '', $post_type = 'acf-field-group') { @@ -17825,7 +16874,7 @@ function acf_is_internal_post_type_key($id = '', $post_type = 'acf-field-group') * * @param array $internal_post_type The internal post type array. * @param string $post_type_name The post type name. - * @return array|bool + * @return array|boolean */ function acf_validate_internal_post_type($internal_post_type, $post_type_name) { @@ -17907,9 +16956,9 @@ function acf_flush_internal_post_type_cache($post, $post_type) * * @since 6.1 * - * @param int|string $id The internal post type ID, key or name. - * @param string $post_type_name The post type to be deleted. - * @return bool True if field group was deleted. + * @param integer|string $id The internal post type ID, key or name. + * @param string $post_type_name The post type to be deleted. + * @return boolean True if field group was deleted. */ function acf_delete_internal_post_type($id = 0, $post_type_name = '') { @@ -17919,9 +16968,9 @@ function acf_delete_internal_post_type($id = 0, $post_type_name = '') * * @since 6.1 * - * @param int|string $id The internal post type ID, key, or name. - * @param string $post_type_name The post type being trashed. - * @return bool True if post was trashed. + * @param integer|string $id The internal post type ID, key, or name. + * @param string $post_type_name The post type being trashed. + * @return boolean True if post was trashed. */ function acf_trash_internal_post_type($id = 0, $post_type_name = '') { @@ -17931,9 +16980,9 @@ function acf_trash_internal_post_type($id = 0, $post_type_name = '') * * @since 6.1 * - * @param int|string $id The internal post type ID, key, or name. - * @param string $post_type_name The post type being untrashed. - * @return bool True if post was untrashed. + * @param integer|string $id The internal post type ID, key, or name. + * @param string $post_type_name The post type being untrashed. + * @return boolean True if post was untrashed. */ function acf_untrash_internal_post_type($id = 0, $post_type_name = '') { @@ -17945,7 +16994,7 @@ function acf_untrash_internal_post_type($id = 0, $post_type_name = '') * * @param array $post The ACF post array. * @param string $post_type The ACF post type. - * @return bool + * @return boolean */ function acf_is_internal_post_type($post, $post_type) { @@ -17955,10 +17004,10 @@ function acf_is_internal_post_type($post, $post_type) * * @since 6.1 * - * @param int|string $id The field_group ID, key or name. - * @param int $new_post_id Optional ID to override. - * @param string $post_type The post type of the post being duplicated. - * @return array|bool The new ACF post, or false on failure. + * @param integer|string $id The field_group ID, key or name. + * @param integer $new_post_id Optional ID to override. + * @param string $post_type The post type of the post being duplicated. + * @return array|boolean The new ACF post, or false on failure. */ function acf_duplicate_internal_post_type($id = 0, $new_post_id = 0, $post_type = 'acf-field-group') { @@ -17966,10 +17015,10 @@ function acf_duplicate_internal_post_type($id = 0, $new_post_id = 0, $post_type /** * Activates or deactivates an ACF post. * - * @param int|string $id The field_group ID, key or name. - * @param bool $activate True if the post should be activated. - * @param string $post_type The post type being activated/deactivated. - * @return bool + * @param integer|string $id The field_group ID, key or name. + * @param boolean $activate True if the post should be activated. + * @param string $post_type The post type being activated/deactivated. + * @return boolean */ function acf_update_internal_post_type_active_status($id, $activate = \true, $post_type = 'acf-field-group') { @@ -17979,8 +17028,8 @@ function acf_update_internal_post_type_active_status($id, $activate = \true, $po * * @since 6.1 * - * @param int $post_id The ACF post ID. - * @param string $post_type The ACF post type to get the edit link for. + * @param integer $post_id The ACF post ID. + * @param string $post_type The ACF post type to get the edit link for. * @return string */ function acf_get_internal_post_type_edit_link($post_id, $post_type) @@ -18005,7 +17054,7 @@ function acf_prepare_internal_post_type_for_export($post = array(), $post_type = * * @param array $post The ACF post array. * @param string $post_type The post type of the ACF post being exported. - * @return string|bool + * @return string|boolean */ function acf_export_internal_post_type_as_php($post, $post_type = 'acf-field-group') { @@ -18038,7 +17087,7 @@ function acf_import_internal_post_type($post, $post_type) * Tries to determine the ACF post type for the provided key. * * @param string $key The key to check. - * @return string|bool + * @return string|boolean */ function acf_determine_internal_post_type($key) { @@ -18114,7 +17163,7 @@ function acf_add_internal_post_type_validation_error($name, $message = '', $post * @since 6.1.5 * * @param string $action The action being performed. - * @return array|bool + * @return array|boolean */ function acf_get_post_type_from_request_args($action = '') { @@ -18125,7 +17174,7 @@ function acf_get_post_type_from_request_args($action = '') * @since 6.1.5 * * @param string $action The action being performed. - * @return array|bool + * @return array|boolean */ function acf_get_taxonomy_from_request_args($action = '') { @@ -18136,7 +17185,7 @@ function acf_get_taxonomy_from_request_args($action = '') * @since 6.2 * * @param string $action The action being performed. - * @return array|bool + * @return array|boolean */ function acf_get_ui_options_page_from_request_args($action = '') { @@ -18174,9 +17223,9 @@ function acf_get_option_meta($prefix = '') * @date 16/10/2015 * @since 5.2.3 * - * @param int|string $post_id The post id. - * @param string $name The meta name. - * @param bool $hidden If the meta is hidden (starts with an underscore). + * @param integer|string $post_id The post id. + * @param string $name The meta name. + * @param boolean $hidden If the meta is hidden (starts with an underscore). * * @return mixed */ @@ -18189,12 +17238,12 @@ function acf_get_metadata($post_id = 0, $name = '', $hidden = \false) * @date 16/10/2015 * @since 5.2.3 * - * @param int|string $post_id The post id. - * @param string $name The meta name. - * @param mixed $value The meta value. - * @param bool $hidden If the meta is hidden (starts with an underscore). + * @param integer|string $post_id The post id. + * @param string $name The meta name. + * @param mixed $value The meta value. + * @param boolean $hidden If the meta is hidden (starts with an underscore). * - * @return int|bool Meta ID if the key didn't exist, true on successful update, false on failure. + * @return integer|boolean Meta ID if the key didn't exist, true on successful update, false on failure. */ function acf_update_metadata($post_id = 0, $name = '', $value = '', $hidden = \false) { @@ -18205,11 +17254,11 @@ function acf_update_metadata($post_id = 0, $name = '', $value = '', $hidden = \f * @date 16/10/2015 * @since 5.2.3 * - * @param int|string $post_id The post id. - * @param string $name The meta name. - * @param bool $hidden If the meta is hidden (starts with an underscore). + * @param integer|string $post_id The post id. + * @param string $name The meta name. + * @param boolean $hidden If the meta is hidden (starts with an underscore). * - * @return bool + * @return boolean */ function acf_delete_metadata($post_id = 0, $name = '', $hidden = \false) { @@ -18223,7 +17272,7 @@ function acf_delete_metadata($post_id = 0, $name = '', $hidden = \false) * @since 5.3.8 * * @param int|string $from_post_id The post id to copy from. - * @param int|string $to_post_id The post id to paste to. + * @param int|string $to_post_id The post id to paste to. * @return void */ function acf_copy_metadata($from_post_id = 0, $to_post_id = 0) @@ -18238,8 +17287,8 @@ function acf_copy_metadata($from_post_id = 0, $to_post_id = 0) * @since 5.3.8 * @deprecated 5.7.11 * - * @param int $from_post_id The post id to copy from. - * @param int $to_post_id The post id to paste to. + * @param integer $from_post_id The post id to copy from. + * @param integer $to_post_id The post id to paste to. * @return void */ function acf_copy_postmeta($from_post_id = 0, $to_post_id = 0) @@ -18254,7 +17303,7 @@ function acf_copy_postmeta($from_post_id = 0, $to_post_id = 0) * @date 21/1/19 * @since 5.7.10 * - * @param string $key The meta name (field name). + * @param string $key The meta name (field name). * @param int|string $post_id The post_id where this field's value is saved. * @return array|false The field array. */ @@ -18271,7 +17320,7 @@ function acf_get_meta_field($key = 0, $post_id = 0) * * @param int|string $post_id The post id. * @param string type The reference type (fields|groups). - * @param string $name An optional specific name + * @param string $name An optional specific name * @return mixed */ function acf_get_metaref($post_id = 0, $type = 'fields', $name = '') @@ -18285,7 +17334,7 @@ function acf_get_metaref($post_id = 0, $type = 'fields', $name = '') * @date 16/10/2015 * @since 5.2.3 * - * @param int|string $post_id The post id. + * @param int|string $post_id The post id. * @param string type The reference type (fields|groups). * @param array $references An array of references. * @return int|bool Meta ID if the key didn't exist, true on successful update, false on failure. @@ -18313,7 +17362,7 @@ function acf_get_post_templates() /** * Get an ACF CPT as an array * - * @param int|string $id The post ID being queried. + * @param integer|string $id The post ID being queried. * @return array|false The post type object. */ function acf_get_post_type($id) @@ -18324,7 +17373,7 @@ function acf_get_post_type($id) * * @since 6.1 * - * @param int|string $id The post ID. + * @param integer|string $id The post ID. * @return array|false The internal post type array. */ function acf_get_raw_post_type($id) @@ -18335,8 +17384,8 @@ function acf_get_raw_post_type($id) * * @since 6.1 * - * @param int|string $id The post ID, key, or name. - * @return object|bool The post object, or false on failure. + * @param integer|string $id The post ID, key, or name. + * @return object|boolean The post object, or false on failure. */ function acf_get_post_type_post($id) { @@ -18347,7 +17396,7 @@ function acf_get_post_type_post($id) * @since 6.1 * * @param string $id The identifier. - * @return bool + * @return boolean */ function acf_is_post_type_key($id) { @@ -18358,7 +17407,7 @@ function acf_is_post_type_key($id) * @since 6.1 * * @param array $post_type The ACF post type array. - * @return array|bool + * @return array|boolean */ function acf_validate_post_type(array $post_type = array()) { @@ -18434,8 +17483,8 @@ function acf_flush_post_type_cache(array $post_type) * * @since 6.1 * - * @param int|string $id The ACF post type ID, key or name. - * @return bool True if post type was deleted. + * @param integer|string $id The ACF post type ID, key or name. + * @return boolean True if post type was deleted. */ function acf_delete_post_type($id = 0) { @@ -18445,8 +17494,8 @@ function acf_delete_post_type($id = 0) * * @since 6.1 * - * @param int|string $id The post type ID, key, or name. - * @return bool True if post was trashed. + * @param integer|string $id The post type ID, key, or name. + * @return boolean True if post was trashed. */ function acf_trash_post_type($id = 0) { @@ -18456,8 +17505,8 @@ function acf_trash_post_type($id = 0) * * @since 6.1 * - * @param int|string $id The post type ID, key, or name. - * @return bool True if post was untrashed. + * @param integer|string $id The post type ID, key, or name. + * @return boolean True if post was untrashed. */ function acf_untrash_post_type($id = 0) { @@ -18468,7 +17517,7 @@ function acf_untrash_post_type($id = 0) * @since 6.1 * * @param array $post_type The ACF post type array. - * @return bool + * @return boolean */ function acf_is_post_type($post_type) { @@ -18478,9 +17527,9 @@ function acf_is_post_type($post_type) * * @since 6.1 * - * @param int|string $id The ACF post type ID, key or name. - * @param int $new_post_id Optional ID to override. - * @return array|bool The new ACF post type, or false on failure. + * @param integer|string $id The ACF post type ID, key or name. + * @param integer $new_post_id Optional ID to override. + * @return array|boolean The new ACF post type, or false on failure. */ function acf_duplicate_post_type($id = 0, $new_post_id = 0) { @@ -18488,9 +17537,9 @@ function acf_duplicate_post_type($id = 0, $new_post_id = 0) /** * Activates or deactivates an ACF post type. * - * @param int|string $id The ACF post type ID, key or name. - * @param bool $activate True if the post type should be activated. - * @return bool + * @param integer|string $id The ACF post type ID, key or name. + * @param boolean $activate True if the post type should be activated. + * @return boolean */ function acf_update_post_type_active_status($id, $activate = \true) { @@ -18500,7 +17549,7 @@ function acf_update_post_type_active_status($id, $activate = \true) * * @since 6.1 * - * @param int $post_id The ACF post type ID. + * @param integer $post_id The ACF post type ID. * @return string */ function acf_get_post_type_edit_link($post_id) @@ -18523,7 +17572,7 @@ function acf_prepare_post_type_for_export(array $post_type = array()) * @since 6.1 * * @param array $post_type The ACF post type array. - * @return string|bool + * @return string|boolean */ function acf_export_post_type_as_php(array $post_type) { @@ -18569,7 +17618,7 @@ function acf_export_enter_title_here(array $post_types) /** * Get an ACF taxonomy as an array * - * @param int|string $id The post ID being queried. + * @param integer|string $id The post ID being queried. * @return array|false The taxonomy object. */ function acf_get_taxonomy($id) @@ -18580,7 +17629,7 @@ function acf_get_taxonomy($id) * * @since 6.1 * - * @param int|string $id The post ID. + * @param integer|string $id The post ID. * @return array|false The taxonomy array. */ function acf_get_raw_taxonomy($id) @@ -18591,8 +17640,8 @@ function acf_get_raw_taxonomy($id) * * @since 6.1 * - * @param int|string $id The post ID, key, or name. - * @return object|bool The post object, or false on failure. + * @param integer|string $id The post ID, key, or name. + * @return object|boolean The post object, or false on failure. */ function acf_get_taxonomy_post($id) { @@ -18603,7 +17652,7 @@ function acf_get_taxonomy_post($id) * @since 6.1 * * @param string $id The identifier. - * @return bool + * @return boolean */ function acf_is_taxonomy_key($id) { @@ -18614,7 +17663,7 @@ function acf_is_taxonomy_key($id) * @since 6.1 * * @param array $taxonomy The ACF taxonomy array. - * @return array|bool + * @return array|boolean */ function acf_validate_taxonomy(array $taxonomy = array()) { @@ -18690,8 +17739,8 @@ function acf_flush_taxonomy_cache(array $taxonomy) * * @since 6.1 * - * @param int|string $id The ACF taxonomy ID, key or name. - * @return bool True if taxonomy was deleted. + * @param integer|string $id The ACF taxonomy ID, key or name. + * @return boolean True if taxonomy was deleted. */ function acf_delete_taxonomy($id = 0) { @@ -18701,8 +17750,8 @@ function acf_delete_taxonomy($id = 0) * * @since 6.1 * - * @param int|string $id The taxonomy ID, key, or name. - * @return bool True if taxonomy was trashed. + * @param integer|string $id The taxonomy ID, key, or name. + * @return boolean True if taxonomy was trashed. */ function acf_trash_taxonomy($id = 0) { @@ -18712,8 +17761,8 @@ function acf_trash_taxonomy($id = 0) * * @since 6.1 * - * @param int|string $id The taxonomy ID, key, or name. - * @return bool True if taxonomy was untrashed. + * @param integer|string $id The taxonomy ID, key, or name. + * @return boolean True if taxonomy was untrashed. */ function acf_untrash_taxonomy($id = 0) { @@ -18724,7 +17773,7 @@ function acf_untrash_taxonomy($id = 0) * @since 6.1 * * @param array $taxonomy The ACF taxonomy array. - * @return bool + * @return boolean */ function acf_is_taxonomy($taxonomy) { @@ -18734,9 +17783,9 @@ function acf_is_taxonomy($taxonomy) * * @since 6.1 * - * @param int|string $id The ACF taxonomy ID, key or name. - * @param int $new_post_id Optional ID to override. - * @return array|bool The new ACF taxonomy, or false on failure. + * @param integer|string $id The ACF taxonomy ID, key or name. + * @param integer $new_post_id Optional ID to override. + * @return array|boolean The new ACF taxonomy, or false on failure. */ function acf_duplicate_taxonomy($id = 0, $new_post_id = 0) { @@ -18744,9 +17793,9 @@ function acf_duplicate_taxonomy($id = 0, $new_post_id = 0) /** * Activates or deactivates an ACF taxonomy. * - * @param int|string $id The ACF taxonomy ID, key or name. - * @param bool $activate True if the taxonomy should be activated. - * @return bool + * @param integer|string $id The ACF taxonomy ID, key or name. + * @param boolean $activate True if the taxonomy should be activated. + * @return boolean */ function acf_update_taxonomy_active_status($id, $activate = \true) { @@ -18756,7 +17805,7 @@ function acf_update_taxonomy_active_status($id, $activate = \true) * * @since 6.1 * - * @param int $post_id The ACF taxonomy ID. + * @param integer $post_id The ACF taxonomy ID. * @return string */ function acf_get_taxonomy_edit_link($post_id) @@ -18779,7 +17828,7 @@ function acf_prepare_taxonomy_for_export(array $taxonomy = array()) * @since 6.1 * * @param array $taxonomy The ACF taxonomy array. - * @return string|bool + * @return string|boolean */ function acf_export_taxonomy_as_php(array $taxonomy) { @@ -18857,7 +17906,7 @@ function acf_get_user_role_labels($roles = array()) * @since 5.7.10 * * @param void - * @return bool + * @return boolean */ function acf_allow_unfiltered_html() { @@ -18925,7 +17974,7 @@ function acf_get_store($name = '') * @date 13/2/19 * @since 5.7.11 * - * @param int $site_id New blog ID. + * @param integer $site_id New blog ID. * @param int prev_blog_id Prev blog ID. * @return void */ @@ -18962,8 +18011,6 @@ function acf_get_url($filename = '') { } /** - * acf_include - * * Includes a file within the ACF plugin. * * @date 10/3/14 @@ -19113,7 +18160,7 @@ function acf_log_invalid_field_notice($field, $function) * @date 1/4/20 * @since 5.9.0 * - * @param string $object_type The object type (post, term, user, etc). + * @param string $object_type The object type (post, term, user, etc). * @param string $object_subtype Optional object subtype (post type, taxonomy). * @return object */ @@ -19148,22 +18195,22 @@ function acf_get_object_type_rest_base($type_object) * load_fields() callbacks. * * @param WP_Post|WP_User|WP_Term|WP_Comment|array $object - * @return int|mixed|null + * @return integer|mixed|null */ function acf_get_object_id($object) { } // class_exists check /** - * acf_new_admin_notice + * acf_new_admin_notice * - * Instantiates and returns a new model. + * Instantiates and returns a new model. * - * @date 23/12/18 - * @since 5.8.0 + * @date 23/12/18 + * @since 5.8.0 * - * @param array $data Optional data to set. - * @return ACF_Admin_Notice + * @param array $data Optional data to set. + * @return ACF_Admin_Notice */ function acf_new_admin_notice($data = \false) { @@ -19190,10 +18237,10 @@ function acf_render_admin_notices() * @date 17/10/13 * @since 5.0.0 * - * @param string $text The admin notice text. - * @param string $class The type of notice (warning, error, success, info). + * @param string $text The admin notice text. + * @param string $class The type of notice (warning, error, success, info). * @param boolean $dismissable Is this notification dismissible (default true) (since 5.11.0) - * @param boolean $persisted Store once a notice has been dismissed per user and prevent showing it again. (since 6.1.0) + * @param boolean $persisted Store once a notice has been dismissed per user and prevent showing it again. (since 6.1.0) * @return ACF_Admin_Notice */ function acf_add_admin_notice($text = '', $type = 'info', $dismissible = \true, $persisted = \false) @@ -19201,47 +18248,41 @@ function acf_add_admin_notice($text = '', $type = 'info', $dismissible = \true, } // class_exists check /** -* acf_register_admin_tool -* -* alias of acf()->admin_tools->register_tool() -* -* @type function -* @date 31/5/17 -* @since 5.6.0 -* -* @param void -* @return void -*/ + * alias of acf()->admin_tools->register_tool() + * + * @type function + * @date 31/5/17 + * @since 5.6.0 + * + * @param void + * @return void + */ function acf_register_admin_tool($class) { } /** -* acf_get_admin_tools_url -* -* This function will return the admin URL to the tools page -* -* @type function -* @date 31/5/17 -* @since 5.6.0 -* -* @param void -* @return void -*/ + * This function will return the admin URL to the tools page + * + * @type function + * @date 31/5/17 + * @since 5.6.0 + * + * @param void + * @return void + */ function acf_get_admin_tools_url() { } /** -* acf_get_admin_tool_url -* -* This function will return the admin URL to the tools page -* -* @type function -* @date 31/5/17 -* @since 5.6.0 -* -* @param void -* @return void -*/ + * This function will return the admin URL to the tools page + * + * @type function + * @date 31/5/17 + * @since 5.6.0 + * + * @param void + * @return void + */ function acf_get_admin_tool_url($tool = '') { } @@ -19905,21 +18946,35 @@ function acf_str_exists($needle, $haystack) { } /** - * acf_debug - * - * description + * A legacy function designed for developer debugging. * - * @since 5.0.0 + * @deprecated 6.2.6 Removed for security, but keeping the definition in case third party devs have it in their code. + * @since 5.0.0 * - * @param int $post_id - * @return int $post_id + * @return false */ function acf_debug() { } +/** + * A legacy function designed for developer debugging. + * + * @deprecated 6.2.6 Removed for security, but keeping the definition in case third party devs have it in their code. + * @since 5.0.0 + * + * @return false + */ function acf_debug_start() { } +/** + * A legacy function designed for developer debugging. + * + * @deprecated 6.2.6 Removed for security, but keeping the definition in case third party devs have it in their code. + * @since 5.0.0 + * + * @return false + */ function acf_debug_end() { } @@ -20382,14 +19437,10 @@ function acf_format_date($value, $format) { } /** - * acf_clear_log + * Previously, deletes the debug.log file. * - * Deletes the debug.log file. - * - * @since 5.7.10 - * - * @param type $var Description. Default. - * @return type Description. + * @since 5.7.10 + * @deprecated 6.2.7 */ function acf_clear_log() { @@ -20730,110 +19781,65 @@ function get_field($selector, $post_id = \false, $format_value = \true, $escape_ { } /** - * This function is the same as echo get_field(), but will soon escape the value by default. + * This function is the same as echo get_field(), but will escape the value for safe HTML output regardless of parameters. * * @since 1.0.3 * * @param string $selector The field name or key. * @param mixed $post_id The post_id of which the value is saved against. - * @param boolean $format_value Enable formatting of value. - * - * @return void - * @phpstan-return void - */ -function the_field($selector, $post_id = \false, $format_value = \true) -{ -} -/** - * Logs instances of ACF successfully escaping unsafe HTML. - * - * @since 6.2.5 - * - * @param string $function The function that resulted in HTML being escaped. - * @param string $selector The selector (field key, name, etc.) passed to that function. - * @param array $field The field being queried when HTML was escaped. - * @param mixed $post_id The post ID the function was called on. - * @return void - * @phpstan-return void - */ -function _acf_log_escaped_html($function, $selector, $field, $post_id) -{ -} -/** - * Logs instances of where ACF will soon escape HTML using the_field. - * - * @since 6.2.5 - * - * @param string $function The function that resulted in HTML being escaped. - * @param string $selector The selector (field key, name, etc.) passed to that function. - * @param array $field The field being queried when HTML was escaped. - * @param mixed $post_id The post ID the function was called on. - * @return void - * @phpstan-return void - */ -function _acf_log_will_escape_html($function, $selector, $field, $post_id) -{ -} -/** - * Returns an array of instances where HTML was altered due to escaping in the_field or a shortcode. - * - * @since 6.2.5 - * - * @return array - */ -function _acf_get_escaped_html_log() -{ -} -/** - * Updates the array of instances where HTML was altered due to escaping in the_field or a shortcode. + * @param boolean $format_value Enable formatting of value. Default true. * - * @since 6.2.5 - * - * @param array $escaped The array of instances. - * @return boolean True on success, or false on failure. + * @return void + * @phpstan-return void */ -function _acf_update_escaped_html_log($escaped = array()) +function the_field($selector, $post_id = \false, $format_value = \true) { } /** - * Deletes the array of instances where HTML was altered due to escaping in the_field or a shortcode. + * Logs instances of ACF successfully escaping unsafe HTML. * * @since 6.2.5 * - * @return boolean True on success, or false on failure. + * @param string $function The function that resulted in HTML being escaped. + * @param string $selector The selector (field key, name, etc.) passed to that function. + * @param array $field The field being queried when HTML was escaped. + * @param mixed $post_id The post ID the function was called on. + * @return void + * @phpstan-return void */ -function _acf_delete_escaped_html_log() +function _acf_log_escaped_html($function, $selector, $field, $post_id) { } /** - * Returns an array of instances where HTML will be escaped in the_field(). + * Returns an array of instances where HTML was altered due to escaping in the_field or a shortcode. * * @since 6.2.5 * * @return array */ -function _acf_get_will_escape_html_log() +function _acf_get_escaped_html_log() { } /** - * Updates the array of instances where HTML will be escaped in the_field(). + * Updates the array of instances where HTML was altered due to escaping in the_field or a shortcode. * * @since 6.2.5 * * @param array $escaped The array of instances. * @return boolean True on success, or false on failure. */ -function _acf_update_will_escape_html_log($escaped = array()) +function _acf_update_escaped_html_log($escaped = array()) { } /** - * Deletes the array of instances where HTML will be escaped in the_field(). + * Deletes the array of instances where HTML was altered due to escaping in the_field or a shortcode. + * Since 6.2.7, also clears the legacy `acf_will_escape_html_log` option to clean up. * * @since 6.2.5 * * @return boolean True on success, or false on failure. */ -function _acf_delete_will_escape_html_log() +function _acf_delete_escaped_html_log() { } /** @@ -21013,12 +20019,14 @@ function get_sub_field($selector = '', $format_value = \true, $escape_html = \fa { } /** - * This function is the same as echo get_sub_field + * This function is the same as echo get_sub_field(), but will escape the value for safe HTML output. * * @since 1.0.3 * * @param string $field_name The field name. - * @param boolean $format_value Format the value before output. + * @param boolean $format_value Enable formatting of value. When false, the field value will be escaped at this level with `acf_esc_html`. Default true. + * + * @return void * @phpstan-return void */ function the_sub_field($field_name, $format_value = \true) @@ -21057,7 +20065,7 @@ function get_row_layout() * * @param array $atts The shortcode attributes. * - * @return string + * @return string|void */ function acf_shortcode($atts) { @@ -21224,201 +20232,197 @@ function acf_filter_post_id($post_id) { } /** -* acf_get_taxonomies -* -* Returns an array of taxonomy names. -* -* @date 7/10/13 -* @since 5.0.0 -* -* @param array $args An array of args used in the get_taxonomies() function. -* @return array An array of taxonomy names. -*/ + * Returns an array of taxonomy names. + * + * @date 7/10/13 + * @since 5.0.0 + * + * @param array $args An array of args used in the get_taxonomies() function. + * @return array An array of taxonomy names. + */ function acf_get_taxonomies($args = array()) { } /** - * acf_get_taxonomies_for_post_type + * acf_get_taxonomies_for_post_type * - * Returns an array of taxonomies for a given post type(s) + * Returns an array of taxonomies for a given post type(s) * - * @date 7/9/18 - * @since 5.7.5 + * @date 7/9/18 + * @since 5.7.5 * - * @param string|array $post_types The post types to compare against. - * @return array + * @param string|array $post_types The post types to compare against. + * @return array */ function acf_get_taxonomies_for_post_type($post_types = 'post') { } /** -* acf_get_taxonomy_labels -* -* Returns an array of taxonomies in the format "name => label" for use in a select field. -* -* @date 3/8/18 -* @since 5.7.2 -* -* @param array $taxonomies Optional. An array of specific taxonomies to return. -* @return array -*/ + * Returns an array of taxonomies in the format "name => label" for use in a select field. + * + * @date 3/8/18 + * @since 5.7.2 + * + * @param array $taxonomies Optional. An array of specific taxonomies to return. + * @return array + */ function acf_get_taxonomy_labels($taxonomies = array()) { } /** - * acf_get_term_title + * acf_get_term_title * - * Returns the title for this term object. + * Returns the title for this term object. * - * @date 10/9/18 - * @since 5.0.0 + * @date 10/9/18 + * @since 5.0.0 * - * @param object $term The WP_Term object. - * @return string + * @param object $term The WP_Term object. + * @return string */ function acf_get_term_title($term) { } /** - * acf_get_grouped_terms + * acf_get_grouped_terms * - * Returns an array of terms for the given query $args and groups by taxonomy name. + * Returns an array of terms for the given query $args and groups by taxonomy name. * - * @date 2/8/18 - * @since 5.7.2 + * @date 2/8/18 + * @since 5.7.2 * - * @param array $args An array of args used in the get_terms() function. - * @return array + * @param array $args An array of args used in the get_terms() function. + * @return array */ function acf_get_grouped_terms($args) { } /** - * _acf_terms_clauses + * _acf_terms_clauses * - * Used in the 'terms_clauses' filter to order terms by taxonomy name. + * Used in the 'terms_clauses' filter to order terms by taxonomy name. * - * @date 2/8/18 - * @since 5.7.2 + * @date 2/8/18 + * @since 5.7.2 * - * @param array $pieces Terms query SQL clauses. - * @param array $taxonomies An array of taxonomies. - * @param array $args An array of terms query arguments. - * @return array $pieces + * @param array $pieces Terms query SQL clauses. + * @param array $taxonomies An array of taxonomies. + * @param array $args An array of terms query arguments. + * @return array $pieces */ function _acf_terms_clauses($pieces, $taxonomies, $args) { } /** - * acf_get_pretty_taxonomies + * acf_get_pretty_taxonomies * - * Deprecated in favor of acf_get_taxonomy_labels() function. + * Deprecated in favor of acf_get_taxonomy_labels() function. * - * @date 7/10/13 - * @since 5.0.0 - * @deprecated 5.7.2 + * @date 7/10/13 + * @since 5.0.0 + * @deprecated 5.7.2 */ function acf_get_pretty_taxonomies($taxonomies = array()) { } /** - * acf_get_term + * acf_get_term * - * Similar to get_term() but with some extra functionality. + * Similar to get_term() but with some extra functionality. * - * @date 19/8/18 - * @since 5.7.3 + * @date 19/8/18 + * @since 5.7.3 * - * @param mixed $term_id The term ID or a string of "taxonomy:slug". - * @param string $taxonomy The taxonomyname. - * @return WP_Term + * @param mixed $term_id The term ID or a string of "taxonomy:slug". + * @param string $taxonomy The taxonomyname. + * @return WP_Term */ function acf_get_term($term_id, $taxonomy = '') { } /** - * acf_encode_term + * acf_encode_term * - * Returns a "taxonomy:slug" string for a given WP_Term. + * Returns a "taxonomy:slug" string for a given WP_Term. * - * @date 27/8/18 - * @since 5.7.4 + * @date 27/8/18 + * @since 5.7.4 * - * @param WP_Term $term The term object. - * @return string + * @param WP_Term $term The term object. + * @return string */ function acf_encode_term($term) { } /** - * acf_decode_term + * acf_decode_term * - * Decodes a "taxonomy:slug" string into an array of taxonomy and slug. + * Decodes a "taxonomy:slug" string into an array of taxonomy and slug. * - * @date 27/8/18 - * @since 5.7.4 + * @date 27/8/18 + * @since 5.7.4 * - * @param WP_Term $term The term object. - * @return string + * @param WP_Term $term The term object. + * @return string */ function acf_decode_term($string) { } /** - * acf_get_encoded_terms + * acf_get_encoded_terms * - * Returns an array of WP_Term objects from an array of encoded strings + * Returns an array of WP_Term objects from an array of encoded strings * - * @date 9/9/18 - * @since 5.7.5 + * @date 9/9/18 + * @since 5.7.5 * - * @param array $values The array of encoded strings. - * @return array + * @param array $values The array of encoded strings. + * @return array */ function acf_get_encoded_terms($values) { } /** - * acf_get_choices_from_terms + * acf_get_choices_from_terms * - * Returns an array of choices from the terms provided. + * Returns an array of choices from the terms provided. * - * @date 8/9/18 - * @since 5.7.5 + * @date 8/9/18 + * @since 5.7.5 * - * @param array $values and array of WP_Terms objects or encoded strings. - * @param string $format The value format (term_id, slug). - * @return array + * @param array $values and array of WP_Terms objects or encoded strings. + * @param string $format The value format (term_id, slug). + * @return array */ function acf_get_choices_from_terms($terms, $format = 'term_id') { } /** - * acf_get_choices_from_grouped_terms + * acf_get_choices_from_grouped_terms * - * Returns an array of choices from the grouped terms provided. + * Returns an array of choices from the grouped terms provided. * - * @date 8/9/18 - * @since 5.7.5 + * @date 8/9/18 + * @since 5.7.5 * - * @param array $value A grouped array of WP_Terms objects. - * @param string $format The value format (term_id, slug). - * @return array + * @param array $value A grouped array of WP_Terms objects. + * @param string $format The value format (term_id, slug). + * @return array */ function acf_get_choices_from_grouped_terms($value, $format = 'term_id') { } /** - * acf_get_choice_from_term + * acf_get_choice_from_term * - * Returns an array containing the id and text for this item. + * Returns an array containing the id and text for this item. * - * @date 10/9/18 - * @since 5.7.6 + * @date 10/9/18 + * @since 5.7.6 * - * @param object $item The item object such as WP_Post or WP_Term. - * @param string $format The value format (term_id, slug) - * @return array + * @param object $item The item object such as WP_Post or WP_Term. + * @param string $format The value format (term_id, slug) + * @return array */ function acf_get_choice_from_term($term, $format = 'term_id') { @@ -21501,15 +20505,13 @@ function acf_enqueue_uploader() } // class_exists check /** - * acf_get_compatibility - * * Returns true if compatibility is enabled for the given component. * * @date 20/1/15 * @since 5.1.5 * * @param string $name The name of the component to check. - * @return bool + * @return boolean */ function acf_get_compatibility($name) { @@ -21545,15 +20547,13 @@ function acf_render_field_wrap_description($field) { } /** - * acf_get_fields_by_id - * * Returns and array of fields for the given $parent_id. * * @date 27/02/2014 * @since 5.0.0. * @deprecated 5.7.11 * - * @param int $parent_id The parent ID. + * @param integer $parent_id The parent ID. * @return array */ function acf_get_fields_by_id($parent_id = 0) @@ -21568,10 +20568,10 @@ function acf_get_fields_by_id($parent_id = 0) * @since 5.0.0 * @deprecated 5.7.11 * - * @param string $option The option name. - * @param string $value The option value. + * @param string $option The option name. + * @param string $value The option value. * @param string $autoload An optional autoload value. - * @return bool + * @return boolean */ function acf_update_option($option = '', $value = '', $autoload = \null) { @@ -21609,121 +20609,107 @@ function acf_get_dir($filename = '') } // class_exists check /** -* acf_register_field_type -* -* alias of acf()->fields->register_field_type() -* -* @type function -* @date 31/5/17 -* @since 5.6.0 -* -* @param void -* @return void -*/ + * alias of acf()->fields->register_field_type() + * + * @type function + * @date 31/5/17 + * @since 5.6.0 + * + * @param void + * @return void + */ function acf_register_field_type($class) { } /** -* acf_register_field_type_info -* -* alias of acf()->fields->register_field_type_info() -* -* @type function -* @date 31/5/17 -* @since 5.6.0 -* -* @param void -* @return void -*/ + * alias of acf()->fields->register_field_type_info() + * + * @type function + * @date 31/5/17 + * @since 5.6.0 + * + * @param void + * @return void + */ function acf_register_field_type_info($info) { } /** -* acf_get_field_type -* -* alias of acf()->fields->get_field_type() -* -* @type function -* @date 31/5/17 -* @since 5.6.0 -* -* @param void -* @return void -*/ + * alias of acf()->fields->get_field_type() + * + * @type function + * @date 31/5/17 + * @since 5.6.0 + * + * @param void + * @return void + */ function acf_get_field_type($name) { } /** -* acf_get_field_types -* -* alias of acf()->fields->get_field_types() -* -* @type function -* @date 31/5/17 -* @since 5.6.0 -* -* @param void -* @return void -*/ + * alias of acf()->fields->get_field_types() + * + * @type function + * @date 31/5/17 + * @since 5.6.0 + * + * @param void + * @return void + */ function acf_get_field_types($args = array()) { } /** - * acf_get_field_types_info + * acf_get_field_types_info * - * Returns an array containing information about each field type + * Returns an array containing information about each field type * - * @date 18/6/18 - * @since 5.6.9 + * @date 18/6/18 + * @since 5.6.9 * - * @param type $var Description. Default. - * @return type Description. + * @param type $var Description. Default. + * @return type Description. */ function acf_get_field_types_info($args = array()) { } /** -* acf_is_field_type -* -* alias of acf()->fields->is_field_type() -* -* @type function -* @date 31/5/17 -* @since 5.6.0 -* -* @param void -* @return void -*/ + * alias of acf()->fields->is_field_type() + * + * @type function + * @date 31/5/17 + * @since 5.6.0 + * + * @param void + * @return void + */ function acf_is_field_type($name = '') { } /** -* acf_get_field_type_prop -* -* This function will return a field type's property -* -* @type function -* @date 1/10/13 -* @since 5.0.0 -* -* @param void -* @return array -*/ + * This function will return a field type's property + * + * @type function + * @date 1/10/13 + * @since 5.0.0 + * + * @param void + * @return array + */ function acf_get_field_type_prop($name = '', $prop = '') { } /** -* acf_get_field_type_label -* -* This function will return the label of a field type -* -* @type function -* @date 1/10/13 -* @since 5.0.0 -* -* @param void -* @return array -*/ + * This function will return the label of a field type + * + * @type function + * @date 1/10/13 + * @since 5.0.0 + * + * @param void + * @return array + */ function acf_get_field_type_label($name = '') { } @@ -21742,17 +20728,17 @@ function acf_field_type_supports($name = '', $prop = '', $default = \false) { } /** -* acf_field_type_exists (deprecated) -* -* deprecated in favour of acf_is_field_type() -* -* @type function -* @date 1/10/13 -* @since 5.0.0 -* -* @param string $type -* @return boolean -*/ + * + * @deprecated + * @see acf_is_field_type() + * + * @type function + * @date 1/10/13 + * @since 5.0.0 + * + * @param string $type + * @return boolean + */ function acf_field_type_exists($type = '') { } @@ -21767,24 +20753,24 @@ function acf_get_field_categories_i18n() { } /** - * Returns an multi-dimentional array of field types "name => label" grouped by category + * Returns an multi-dimentional array of field types "name => label" grouped by category * - * @since 5.0.0 + * @since 5.0.0 * - * @return array + * @return array */ function acf_get_grouped_field_types() { } /** - * Returns an array of tabs for a field type. - * We combine a list of default tabs with filtered tabs. - * I.E. Default tabs should be static and should not be changed by the - * filtered tabs. + * Returns an array of tabs for a field type. + * We combine a list of default tabs with filtered tabs. + * I.E. Default tabs should be static and should not be changed by the + * filtered tabs. * - * @since 6.1 + * @since 6.1 * - * @return array Key/value array of the default settings tabs for field type settings. + * @return array Key/value array of the default settings tabs for field type settings. */ function acf_get_combined_field_type_settings_tabs() { @@ -21801,17 +20787,17 @@ function acf_get_pro_field_types() } // class_exists check /** -* Functions -* -* alias of acf()->form->functions -* -* @type function -* @date 11/06/2014 -* @since 5.0.0 -* -* @param void -* @return void -*/ + * Functions + * + * alias of acf()->form->functions + * + * @type function + * @date 11/06/2014 + * @since 5.0.0 + * + * @param void + * @return void + */ function acf_form_head() { } @@ -21828,8 +20814,6 @@ function acf_register_form($args) { } /** - * acf_get_locale - * * Returns the current locale. * * @date 16/12/16 @@ -21906,7 +20890,7 @@ function acf_disable_local() * @since 5.7.10 * * @param void - * @return bool + * @return boolean */ function acf_is_local_enabled() { @@ -22000,7 +20984,7 @@ function acf_count_local_field_groups() * @since 5.7.10 * * @param array $field_group The field group array. - * @return bool + * @return boolean */ function acf_add_local_field_group($field_group) { @@ -22012,7 +20996,7 @@ function acf_add_local_field_group($field_group) * * @param array $post The main ACF post array. * @param string $post_type The post type being added. - * @return bool + * @return boolean */ function acf_add_local_internal_post_type($post, $post_type) { @@ -22040,7 +21024,7 @@ function register_field_group($field_group) * @since 5.7.10 * * @param string $key The field group key. - * @return bool + * @return boolean */ function acf_remove_local_field_group($key = '') { @@ -22052,7 +21036,7 @@ function acf_remove_local_field_group($key = '') * * @param string $key The ACF key. * @param string $post_type The ACF post type. - * @return bool + * @return boolean */ function acf_remove_local_internal_post_type($key = '', $post_type = 'acf-field-group') { @@ -22066,7 +21050,7 @@ function acf_remove_local_internal_post_type($key = '', $post_type = 'acf-field- * @since 5.7.10 * * @param string $key The field group key. - * @return bool + * @return boolean */ function acf_is_local_field_group($key = '') { @@ -22078,7 +21062,7 @@ function acf_is_local_field_group($key = '') * * @param string $key The ACF key. * @param string $post_type The ACF post type. - * @return bool + * @return boolean */ function acf_is_local_internal_post_type($key = '', $post_type = 'acf-field-group') { @@ -22092,7 +21076,7 @@ function acf_is_local_internal_post_type($key = '', $post_type = 'acf-field-grou * @since 5.7.10 * * @param string $key The field group key. - * @return bool + * @return boolean */ function acf_is_local_field_group_key($key = '') { @@ -22104,7 +21088,7 @@ function acf_is_local_field_group_key($key = '') * * @param string $key The ACF post key. * @param string $post_type The post type to check. - * @return bool + * @return boolean */ function acf_is_local_internal_post_type_key($key = '', $post_type = '') { @@ -22172,7 +21156,7 @@ function acf_get_local_fields($parent = '') * @since 5.7.10 * * @param string $parent The parent key. - * @return bool + * @return boolean */ function acf_have_local_fields($parent = '') { @@ -22186,7 +21170,7 @@ function acf_have_local_fields($parent = '') * @since 5.7.10 * * @param string $parent The parent key. - * @return int + * @return integer */ function acf_count_local_fields($parent = '') { @@ -22199,8 +21183,8 @@ function acf_count_local_fields($parent = '') * @date 22/1/19 * @since 5.7.10 * - * @param array $field The field array. - * @param bool $prepared Whether or not the field has already been prepared for import. + * @param array $field The field array. + * @param boolean $prepared Whether or not the field has already been prepared for import. * @return void */ function acf_add_local_field($field, $prepared = \false) @@ -22215,7 +21199,7 @@ function acf_add_local_field($field, $prepared = \false) * @since 5.7.10 * * @param string $key The field key. - * @return bool + * @return boolean */ function _acf_generate_local_key($field) { @@ -22229,7 +21213,7 @@ function _acf_generate_local_key($field) * @since 5.7.10 * * @param string $key The field key. - * @return bool + * @return boolean */ function acf_remove_local_field($key = '') { @@ -22243,7 +21227,7 @@ function acf_remove_local_field($key = '') * @since 5.7.10 * * @param string $key The field group key. - * @return bool + * @return boolean */ function acf_is_local_field($key = '') { @@ -22257,7 +21241,7 @@ function acf_is_local_field($key = '') * @since 5.7.10 * * @param string $key The field group key. - * @return bool + * @return boolean */ function acf_is_local_field_key($key = '') { @@ -22310,9 +21294,9 @@ function _acf_apply_get_local_internal_posts($posts = array(), $post_type = 'acf * @date 23/1/19 * @since 5.7.10 * - * @param bool $bool The result. - * @param string $id The identifier. - * @return bool + * @param boolean $bool The result. + * @param string $id The identifier. + * @return boolean */ function _acf_apply_is_local_field_key($bool, $id) { @@ -22325,9 +21309,9 @@ function _acf_apply_is_local_field_key($bool, $id) * @date 23/1/19 * @since 5.7.10 * - * @param bool $bool The result. - * @param string $id The identifier. - * @return bool + * @param boolean $bool The result. + * @param string $id The identifier. + * @return boolean */ function _acf_apply_is_local_field_group_key($bool, $id) { @@ -22337,10 +21321,10 @@ function _acf_apply_is_local_field_group_key($bool, $id) * * @since 6.1 * - * @param bool $bool The result. - * @param string $id The identifier. - * @param string $post_type The post type. - * @return bool + * @param boolean $bool The result. + * @param string $id The identifier. + * @param string $post_type The post type. + * @return boolean */ function _acf_apply_is_local_internal_post_type_key($bool, $id, $post_type = 'acf-field-group') { @@ -22379,7 +21363,7 @@ function acf_get_local_json_files($post_type = 'acf-field-group') * @since 5.1.5 * * @param array $field_group The field group. - * @return bool + * @return boolean */ function acf_write_json_field_group($field_group) { @@ -22391,7 +21375,7 @@ function acf_write_json_field_group($field_group) * @since 5.1.5 * * @param string $key The field group key. - * @return bool True on success. + * @return boolean True on success. */ function acf_delete_json_field_group($key) { @@ -22515,10 +21499,10 @@ function acf_get_location_rule_values($rule) * @date 30/5/17 * @since 5.6.0 * - * @param array $rule The location rule. + * @param array $rule The location rule. * @param array $screen The screen args. - * @param array $field The field group array. - * @return bool + * @param array $field The field group array. + * @return boolean */ function acf_match_location_rule($rule, $screen, $field_group) { @@ -22529,7 +21513,7 @@ function acf_match_location_rule($rule, $screen, $field_group) * @date 8/4/20 * @since 5.9.0 * - * @param array $screen The screen args. + * @param array $screen The screen args. * @param array $deprecated The field group array. * @return array */ @@ -22574,62 +21558,54 @@ function acf_get_valid_location_rule($rule) } // class_exists check /** -* acf_add_loop -* -* alias of acf()->loop->add_loop() -* -* @type function -* @date 6/10/13 -* @since 5.0.0 -* -* @param void -* @return void -*/ + * alias of acf()->loop->add_loop() + * + * @type function + * @date 6/10/13 + * @since 5.0.0 + * + * @param void + * @return void + */ function acf_add_loop($loop = array()) { } /** -* acf_update_loop -* -* alias of acf()->loop->update_loop() -* -* @type function -* @date 6/10/13 -* @since 5.0.0 -* -* @param void -* @return void -*/ + * alias of acf()->loop->update_loop() + * + * @type function + * @date 6/10/13 + * @since 5.0.0 + * + * @param void + * @return void + */ function acf_update_loop($i = 'active', $key = \null, $value = \null) { } /** -* acf_get_loop -* -* alias of acf()->loop->get_loop() -* -* @type function -* @date 6/10/13 -* @since 5.0.0 -* -* @param void -* @return void -*/ + * alias of acf()->loop->get_loop() + * + * @type function + * @date 6/10/13 + * @since 5.0.0 + * + * @param void + * @return void + */ function acf_get_loop($i = 'active', $key = \null) { } /** -* acf_remove_loop -* -* alias of acf()->loop->remove_loop() -* -* @type function -* @date 6/10/13 -* @since 5.0.0 -* -* @param void -* @return void -*/ + * alias of acf()->loop->remove_loop() + * + * @type function + * @date 6/10/13 + * @since 5.0.0 + * + * @param void + * @return void + */ function acf_remove_loop($i = 'active') { } @@ -22650,8 +21626,8 @@ function acf_get_field_rest_schema(array $field) * @see \acf_field::get_rest_links() * @see https://developer.wordpress.org/rest-api/using-the-rest-api/linking-and-embedding/ * - * @param string|int $post_id - * @param array $field + * @param string|integer $post_id + * @param array $field * @return array */ function acf_get_field_rest_links($post_id, array $field) @@ -22671,228 +21647,220 @@ function acf_format_value_for_rest($value, $post_id, $field, $format = 'light') } // class_exists check /** -* acf_save_post_revision -* -* This function will copy meta from a post to it's latest revision -* -* @type function -* @date 26/09/2016 -* @since 5.4.0 -* -* @param int $post_id -* @return void -*/ + * This function will copy meta from a post to it's latest revision + * + * @type function + * @date 26/09/2016 + * @since 5.4.0 + * + * @param int $post_id + * @return void + */ function acf_save_post_revision($post_id = 0) { } /** -* acf_get_post_latest_revision -* -* This function will return the latest revision for a given post -* -* @type function -* @date 25/06/2016 -* @since 5.3.8 -* -* @param int $post_id -* @return int $post_id -*/ + * This function will return the latest revision for a given post + * + * @type function + * @date 25/06/2016 + * @since 5.3.8 + * + * @param int $post_id + * @return int $post_id + */ function acf_get_post_latest_revision($post_id) { } /** - * acf_has_upgrade + * acf_has_upgrade * - * Returns true if this site has an upgrade avaialble. + * Returns true if this site has an upgrade avaialble. * - * @date 24/8/18 - * @since 5.7.4 + * @date 24/8/18 + * @since 5.7.4 * - * @param void - * @return bool + * @param void + * @return boolean */ function acf_has_upgrade() { } /** - * Runs upgrade routines if this site has an upgrade available. + * Runs upgrade routines if this site has an upgrade available. * - * @date 24/8/18 - * @since 5.7.4 + * @date 24/8/18 + * @since 5.7.4 */ function acf_upgrade_all() { } /** - * acf_get_db_version + * acf_get_db_version * - * Returns the ACF DB version. + * Returns the ACF DB version. * - * @date 10/09/2016 - * @since 5.4.0 + * @date 10/09/2016 + * @since 5.4.0 * - * @param void - * @return string + * @param void + * @return string */ function acf_get_db_version() { } /** -* acf_update_db_version -* -* Updates the ACF DB version. -* -* @date 10/09/2016 -* @since 5.4.0 -* -* @param string $version The new version. -* @return void -*/ + * Updates the ACF DB version. + * + * @date 10/09/2016 + * @since 5.4.0 + * + * @param string $version The new version. + * @return void + */ function acf_update_db_version($version = '') { } /** - * acf_upgrade_500 + * acf_upgrade_500 * - * Version 5 introduces new post types for field groups and fields. + * Version 5 introduces new post types for field groups and fields. * - * @date 23/8/18 - * @since 5.7.4 + * @date 23/8/18 + * @since 5.7.4 * - * @param void - * @return void + * @param void + * @return void */ function acf_upgrade_500() { } /** - * acf_upgrade_500_field_groups + * acf_upgrade_500_field_groups * - * Upgrades all ACF4 field groups to ACF5 + * Upgrades all ACF4 field groups to ACF5 * - * @date 23/8/18 - * @since 5.7.4 + * @date 23/8/18 + * @since 5.7.4 * - * @param void - * @return void + * @param void + * @return void */ function acf_upgrade_500_field_groups() { } /** - * acf_upgrade_500_field_group + * acf_upgrade_500_field_group * - * Upgrades a ACF4 field group to ACF5 + * Upgrades a ACF4 field group to ACF5 * - * @date 23/8/18 - * @since 5.7.4 + * @date 23/8/18 + * @since 5.7.4 * - * @param object $ofg The old field group post object. - * @return array $nfg The new field group array. + * @param object $ofg The old field group post object. + * @return array $nfg The new field group array. */ function acf_upgrade_500_field_group($ofg) { } /** - * acf_upgrade_500_fields + * acf_upgrade_500_fields * - * Upgrades all ACF4 fields to ACF5 from a specific field group + * Upgrades all ACF4 fields to ACF5 from a specific field group * - * @date 23/8/18 - * @since 5.7.4 + * @date 23/8/18 + * @since 5.7.4 * - * @param object $ofg The old field group post object. - * @param array $nfg The new field group array. - * @return void + * @param object $ofg The old field group post object. + * @param array $nfg The new field group array. + * @return void */ function acf_upgrade_500_fields($ofg, $nfg) { } /** - * acf_upgrade_500_field + * acf_upgrade_500_field * - * Upgrades a ACF4 field to ACF5 + * Upgrades a ACF4 field to ACF5 * - * @date 23/8/18 - * @since 5.7.4 + * @date 23/8/18 + * @since 5.7.4 * - * @param array $field The old field. - * @return array $field The new field. + * @param array $field The old field. + * @return array $field The new field. */ function acf_upgrade_500_field($field) { } /** - * acf_upgrade_550 + * acf_upgrade_550 * - * Version 5.5 adds support for the wp_termmeta table added in WP 4.4. + * Version 5.5 adds support for the wp_termmeta table added in WP 4.4. * - * @date 23/8/18 - * @since 5.7.4 + * @date 23/8/18 + * @since 5.7.4 * - * @param void - * @return void + * @param void + * @return void */ function acf_upgrade_550() { } /** - * acf_upgrade_550_termmeta + * acf_upgrade_550_termmeta * - * Upgrades all ACF4 termmeta saved in wp_options to the wp_termmeta table. + * Upgrades all ACF4 termmeta saved in wp_options to the wp_termmeta table. * - * @date 23/8/18 - * @since 5.7.4 + * @date 23/8/18 + * @since 5.7.4 * - * @param void - * @return void + * @param void + * @return void * @phpstan-return void */ function acf_upgrade_550_termmeta() { } /** -* acf_wp_upgrade_550_termmeta -* -* When the database is updated to support term meta, migrate ACF term meta data across. -* -* @date 23/8/18 -* @since 5.7.4 -* -* @param string $wp_db_version The new $wp_db_version. -* @param string $wp_current_db_version The old (current) $wp_db_version. -* @return void -*/ + * When the database is updated to support term meta, migrate ACF term meta data across. + * + * @date 23/8/18 + * @since 5.7.4 + * + * @param string $wp_db_version The new $wp_db_version. + * @param string $wp_current_db_version The old (current) $wp_db_version. + * @return void + */ function acf_wp_upgrade_550_termmeta($wp_db_version, $wp_current_db_version) { } /** - * acf_upgrade_550_taxonomy + * acf_upgrade_550_taxonomy * - * Upgrades all ACF4 termmeta for a specific taxonomy. + * Upgrades all ACF4 termmeta for a specific taxonomy. * - * @date 24/8/18 - * @since 5.7.4 + * @date 24/8/18 + * @since 5.7.4 * - * @param string $taxonomy The taxonomy name. - * @return void + * @param string $taxonomy The taxonomy name. + * @return void */ function acf_upgrade_550_taxonomy($taxonomy) { } // class_exists check /** -* Public functions -* -* alias of acf()->validation->function() -* -* @type function -* @date 6/10/13 -* @since 5.0.0 -* -* @param void -* @return void -*/ + * Public functions + * + * alias of acf()->validation->function() + * + * @type function + * @date 6/10/13 + * @since 5.0.0 + * + * @param void + * @return void + */ function acf_add_validation_error($input, $message = '') { } @@ -22906,48 +21874,43 @@ function acf_reset_validation_errors() { } /** -* acf_validate_save_post -* -* This function will validate $_POST data and add errors -* -* @type function -* @date 25/11/2013 -* @since 5.0.0 -* -* @param boolean $show_errors if true, errors will be shown via a wp_die screen -* @return boolean -*/ + * This function will validate $_POST data and add errors + * + * @type function + * @date 25/11/2013 + * @since 5.0.0 + * + * @param boolean $show_errors if true, errors will be shown via a wp_die screen + * @return boolean + */ function acf_validate_save_post($show_errors = \false) { } /** -* acf_validate_values -* -* This function will validate an array of field values -* -* @type function -* @date 6/10/13 -* @since 5.0.0 -* -* @param values (array) -* @param string $input_prefix -* @return void -*/ + * This function will validate an array of field values + * + * @type function + * @date 6/10/13 + * @since 5.0.0 + * + * @param values (array) + * @param string $input_prefix + * @return void + * @phpstan-return void + */ function acf_validate_values($values, $input_prefix = '') { } /** -* acf_validate_value -* -* This function will validate a field's value -* -* @type function -* @date 6/10/13 -* @since 5.0.0 -* -* @param void -* @return void -*/ + * This function will validate a field's value + * + * @type function + * @date 6/10/13 + * @since 5.0.0 + * + * @param void + * @return void + */ function acf_validate_value($value, $field, $input) { } @@ -22961,7 +21924,7 @@ function acf_validate_value($value, $field, $input) * * @since 6.2 * - * @param int|string $id The post ID being queried. + * @param integer|string $id The post ID being queried. * @return array|false The UI options page array. */ function acf_get_ui_options_page($id) @@ -22972,7 +21935,7 @@ function acf_get_ui_options_page($id) * * @since 6.2 * - * @param int|string $id The post ID. + * @param integer|string $id The post ID. * @return array|false The UI options page array. */ function acf_get_raw_ui_options_page($id) @@ -22983,8 +21946,8 @@ function acf_get_raw_ui_options_page($id) * * @since 6.2 * - * @param int|string $id The post ID, key, or name. - * @return object|bool The post object, or false on failure. + * @param integer|string $id The post ID, key, or name. + * @return object|boolean The post object, or false on failure. */ function acf_get_ui_options_page_post($id) { @@ -22995,7 +21958,7 @@ function acf_get_ui_options_page_post($id) * @since 6.2 * * @param string $id The identifier. - * @return bool + * @return boolean */ function acf_is_ui_options_page_key($id) { @@ -23006,7 +21969,7 @@ function acf_is_ui_options_page_key($id) * @since 6.2 * * @param array $ui_options_page The ACF UI options page array to validate. - * @return array|bool + * @return array|boolean */ function acf_validate_ui_options_page(array $ui_options_page = array()) { @@ -23082,8 +22045,8 @@ function acf_flush_ui_options_page_cache(array $ui_options_page) * * @since 6.2 * - * @param int|string $id The ACF UI options page ID, key or name. - * @return bool True if the options page was deleted. + * @param integer|string $id The ACF UI options page ID, key or name. + * @return boolean True if the options page was deleted. */ function acf_delete_ui_options_page($id = 0) { @@ -23093,8 +22056,8 @@ function acf_delete_ui_options_page($id = 0) * * @since 6.2 * - * @param int|string $id The UI options page ID, key, or name. - * @return bool True if the options page was trashed. + * @param integer|string $id The UI options page ID, key, or name. + * @return boolean True if the options page was trashed. */ function acf_trash_ui_options_page($id = 0) { @@ -23104,8 +22067,8 @@ function acf_trash_ui_options_page($id = 0) * * @since 6.2 * - * @param int|string $id The UI options page ID, key, or name. - * @return bool True if the options page was untrashed. + * @param integer|string $id The UI options page ID, key, or name. + * @return boolean True if the options page was untrashed. */ function acf_untrash_ui_options_page($id = 0) { @@ -23116,7 +22079,7 @@ function acf_untrash_ui_options_page($id = 0) * @since 6.2 * * @param array $ui_options_page The ACF UI options page array. - * @return bool + * @return boolean */ function acf_is_ui_options_page($ui_options_page) { @@ -23126,9 +22089,9 @@ function acf_is_ui_options_page($ui_options_page) * * @since 6.2 * - * @param int|string $id The ACF UI options page ID, key or name. - * @param int $new_post_id Optional ID to override. - * @return array|bool The new ACF UI options page, or false on failure. + * @param integer|string $id The ACF UI options page ID, key or name. + * @param integer $new_post_id Optional ID to override. + * @return array|boolean The new ACF UI options page, or false on failure. */ function acf_duplicate_ui_options_page($id = 0, $new_post_id = 0) { @@ -23138,9 +22101,9 @@ function acf_duplicate_ui_options_page($id = 0, $new_post_id = 0) * * @since 6.2 * - * @param int|string $id The ACF UI options page ID, key or name. - * @param bool $activate True if the UI options page should be activated. - * @return bool + * @param integer|string $id The ACF UI options page ID, key or name. + * @param boolean $activate True if the UI options page should be activated. + * @return boolean */ function acf_update_ui_options_page_active_status($id, $activate = \true) { @@ -23150,7 +22113,7 @@ function acf_update_ui_options_page_active_status($id, $activate = \true) * * @since 6.2 * - * @param int $post_id The ACF UI options page ID. + * @param integer $post_id The ACF UI options page ID. * @return string */ function acf_get_ui_options_page_edit_link($post_id) @@ -23173,7 +22136,7 @@ function acf_prepare_ui_options_page_for_export(array $ui_options_page = array() * @since 6.2 * * @param array $ui_options_page The ACF UI options page array. - * @return string|bool + * @return string|boolean */ function acf_export_ui_options_page_as_php(array $ui_options_page) { @@ -23254,7 +22217,7 @@ function acf_handle_json_block_registration($settings, $metadata) * @since 6.0.0 * * @param array $metadata The raw block metadata array. - * @return bool + * @return boolean */ function acf_is_acf_block_json($metadata) { @@ -23289,7 +22252,7 @@ function acf_register_block($block) * @since 5.7.12 * * @param string $name The block type name. - * @return bool + * @return boolean */ function acf_has_block_type($name) { @@ -23388,8 +22351,8 @@ function acf_get_block_back_compat_attribute_key_array() * @since 5.9.2 * * @param array $attributes The block attributes. - * @param string $content The block content. - * @param WP_Block $wp_block The block instance (since WP 5.5). + * @param string $content The block content. + * @param WP_Block $wp_block The block instance (since WP 5.5). * @return string The block HTML. */ function acf_render_block_callback($attributes, $content = '', $wp_block = \null) @@ -23402,11 +22365,11 @@ function acf_render_block_callback($attributes, $content = '', $wp_block = \null * @since 5.7.13 * * @param array $attributes The block attributes. - * @param string $content The block content. - * @param bool $is_preview Whether or not the block is being rendered for editing preview. - * @param int $post_id The current post being edited or viewed. - * @param WP_Block $wp_block The block instance (since WP 5.5). - * @param array $context The block context array. + * @param string $content The block content. + * @param boolean $is_preview Whether or not the block is being rendered for editing preview. + * @param integer $post_id The current post being edited or viewed. + * @param WP_Block $wp_block The block instance (since WP 5.5). + * @param array $context The block context array. * @return string The block HTML. */ function acf_rendered_block($attributes, $content = '', $is_preview = \false, $post_id = 0, $wp_block = \null, $context = \false) @@ -23418,11 +22381,11 @@ function acf_rendered_block($attributes, $content = '', $is_preview = \false, $p * @since 5.7.12 * * @param array $attributes The block attributes. - * @param string $content The block content. - * @param bool $is_preview Whether or not the block is being rendered for editing preview. - * @param int $post_id The current post being edited or viewed. - * @param WP_Block $wp_block The block instance (since WP 5.5). - * @param array $context The block context array. + * @param string $content The block content. + * @param boolean $is_preview Whether or not the block is being rendered for editing preview. + * @param integer $post_id The current post being edited or viewed. + * @param WP_Block $wp_block The block instance (since WP 5.5). + * @param array $context The block context array. * @return void|string */ function acf_render_block($attributes, $content = '', $is_preview = \false, $post_id = 0, $wp_block = \null, $context = \false) @@ -23521,7 +22484,7 @@ function acf_parse_save_blocks_callback($matches) * @since 6.0.0 * * @param array $attributes A block attributes array. - * @param array $context The block context array, defaults to an empty array. + * @param array $context The block context array, defaults to an empty array. * @return string A block ID. */ function acf_get_block_id($attributes, $context = array()) @@ -23605,16 +22568,16 @@ function acf_register_plugin_update($plugin) { } /** - * acf_options_page + * acf_options_page * - * This function will return the options page instance + * This function will return the options page instance * - * @type function - * @date 9/6/17 - * @since 5.6.0 + * @type function + * @date 9/6/17 + * @since 5.6.0 * - * @param void - * @return object + * @param void + * @return object */ function acf_options_page() {