wp_get_duotone_filter_property()WP 5.9.0

Returns the CSS filter property url to reference the rendered SVG.

No Hooks.

Return

String. Duotone CSS filter property url value.

Usage

wp_get_duotone_filter_property( $preset );
$preset(array) (required)
Duotone preset value as seen in theme.json.

Changelog

Since 5.9.0 Introduced.

Code of wp_get_duotone_filter_property() WP 6.0.1

function wp_get_duotone_filter_property( $preset ) {
	$filter_id = wp_get_duotone_filter_id( $preset );
	return "url('#" . $filter_id . "')";
}