Editor: Fix styles for nested elements (link color)

This fixes an issue by which link color behaves differently in the editor and front end.

Related Gutenberg PR: https://github.com/WordPress/gutenberg/pull/37728.

Props oandregal.
See #55567.



git-svn-id: https://develop.svn.wordpress.org/trunk@53260 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Greg Ziółkowski
2022-04-25 16:35:16 +00:00
parent dea44459da
commit 0cb3193616
2 changed files with 71 additions and 15 deletions

View File

@@ -11,7 +11,7 @@ class Tests_Block_Supports_Elements extends WP_UnitTestCase {
* @return string String where the unique id classes were replaced with "wp-elements-1".
*/
private static function make_unique_id_one( $string ) {
return preg_replace( '/wp-elements-\d+/', 'wp-elements-1', $string );
return preg_replace( '/wp-elements-[a-zA-Z0-9]+/', 'wp-elements-1', $string );
}
/**