Make WordPress Core


Ignore:
Timestamp:
09/15/2022 10:53:18 AM (2 years ago)
Author:
audrasjb
Message:

Editor: Backport wp_theme_element_class_name() alias.

This changeset backports the wp_theme_element_class_name() alias for the "internal" WP_Theme_JSON::get_element_class_name() function.

This is a backport of gutenberg/PR44099.

Note: this changeset doesn't replace calls to WP_Theme_JSON::get_element_class_name in the tests, since those are specifically for the WP_Theme_JSON class.

Props bernhard-reiter, cbravobernal, costdev.
See #56467.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/theme.php

    r54162 r54174  
    42124212
    42134213/**
     4214 * Given an element name, returns a class name.
     4215 *
     4216 * Alias of WP_Theme_JSON::get_element_class_name.
     4217 *
     4218 * @since 6.1.0
     4219 *
     4220 * @param string $element The name of the element.
     4221 *
     4222 * @return string The name of the class.
     4223 */
     4224function wp_theme_get_element_class_name( $element ) {
     4225    return WP_Theme_JSON::get_element_class_name( $element );
     4226}
     4227
     4228/**
    42144229 * Adds default theme supports for block themes when the 'setup_theme' action fires.
    42154230 *
Note: See TracChangeset for help on using the changeset viewer.