wpseek.com
WordPress开发者和主题制作者的搜索引擎



wp_state_paints_own_background › WordPress Function

Since7.2.0
已弃用n/a
› wp_state_paints_own_background ( $state_style )
访问:
  • private
参数:
  • (array<string,mixed>) $state_style State style object.
    Required: Yes
返回:
  • (bool) Whether the state sets a gradient or background image.
定义在:
文档:

Checks whether a state paints its own background.



源码

function wp_state_paints_own_background( array $state_style ): bool {
	return ! empty( $state_style['background']['gradient'] ) ||
		! empty( $state_style['background']['backgroundImage'] ) ||
		! empty( $state_style['color']['gradient'] );
}