| 1 |
<?php |
| 2 |
/** |
| 3 |
* Temporary compatibility shims for features present in Gutenberg, pending |
| 4 |
* upstream commit to the WordPress core source repository. Functions here |
| 5 |
* exist only as long as necessary for corresponding WordPress support, and |
| 6 |
* each should be associated with a Trac ticket. |
| 7 |
* |
| 8 |
* @package gutenberg |
| 9 |
*/ |
| 10 |
|
| 11 |
/** |
| 12 |
* Filters allowed CSS attributes to include `flex-basis`, included in saved |
| 13 |
* markup of the Column block. |
| 14 |
* |
| 15 |
* @since 5.7.0 |
| 16 |
* |
| 17 |
* @param string[] $attr Array of allowed CSS attributes. |
| 18 |
* |
| 19 |
* @return string[] Filtered array of allowed CSS attributes. |
| 20 |
*/ |
| 21 |
function gutenberg_safe_style_css_column_flex_basis( $attr ) { |
| 22 |
$attr[] = 'flex-basis'; |
| 23 |
|
| 24 |
return $attr; |
| 25 |
} |
| 26 |
add_filter( 'safe_style_css', 'gutenberg_safe_style_css_column_flex_basis' ); |
| 27 |
|