mirror of
https://github.com/WordPress/WordPress.git
synced 2025-01-03 06:57:35 +01:00
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 [https://github.com/WordPress/gutenberg/pull/44099 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. Built from https://develop.svn.wordpress.org/trunk@54174 git-svn-id: http://core.svn.wordpress.org/trunk@53733 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
81ada51ba4
commit
c72fae1c58
@ -4210,6 +4210,21 @@ function wp_is_block_theme() {
|
|||||||
return wp_get_theme()->is_block_theme();
|
return wp_get_theme()->is_block_theme();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Given an element name, returns a class name.
|
||||||
|
*
|
||||||
|
* Alias of WP_Theme_JSON::get_element_class_name.
|
||||||
|
*
|
||||||
|
* @since 6.1.0
|
||||||
|
*
|
||||||
|
* @param string $element The name of the element.
|
||||||
|
*
|
||||||
|
* @return string The name of the class.
|
||||||
|
*/
|
||||||
|
function wp_theme_get_element_class_name( $element ) {
|
||||||
|
return WP_Theme_JSON::get_element_class_name( $element );
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Adds default theme supports for block themes when the 'setup_theme' action fires.
|
* Adds default theme supports for block themes when the 'setup_theme' action fires.
|
||||||
*
|
*
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '6.1-alpha-54173';
|
$wp_version = '6.1-alpha-54174';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
Loading…
Reference in New Issue
Block a user