WC_Twenty_Seventeen::custom_colors_css()public staticWC 1.0

Custom colors.

Метод класса: WC_Twenty_Seventeen{}

Хуков нет.

Возвращает

Строку.

Использование

$result = WC_Twenty_Seventeen::custom_colors_css( $css, $hue, $saturation );
$css(строка) (обязательный)
Styles.
$hue(строка) (обязательный)
Color.
$saturation(строка) (обязательный)
Saturation.

Код WC_Twenty_Seventeen::custom_colors_css() WC 8.7.0

public static function custom_colors_css( $css, $hue, $saturation ) {
	$css .= '
		.colors-custom .select2-container--default .select2-selection--single {
			border-color: hsl( ' . $hue . ', ' . $saturation . ', 73% );
		}
		.colors-custom .select2-container--default .select2-selection__rendered {
			color: hsl( ' . $hue . ', ' . $saturation . ', 40% );
		}
		.colors-custom .select2-container--default .select2-selection--single .select2-selection__arrow b {
			border-color: hsl( ' . $hue . ', ' . $saturation . ', 40% ) transparent transparent transparent;
		}
		.colors-custom .select2-container--focus .select2-selection {
			border-color: #000;
		}
		.colors-custom .select2-container--focus .select2-selection--single .select2-selection__arrow b {
			border-color: #000 transparent transparent transparent;
		}
		.colors-custom .select2-container--focus .select2-selection .select2-selection__rendered {
			color: #000;
		}
	';
	return $css;
}