Make WordPress Core


Ignore:
Timestamp:
03/20/2023 08:23:47 AM (2 years ago)
Author:
SergeyBiryukov
Message:

KSES: Allow filter property to accept a URL in safecss_filter_attr().

CSS filters can accept url() as a reference to an SVG filter element:

filter: url( file.svg#filter-element-id );

This commit allows for that syntax to be used in inline CSS.

Original PR from Gutenberg repository:

References:

Follow-up to [44136], [52049].

Props scruffian, jeryj, ironprogrammer, azaozz, hellofromTonya, SergeyBiryukov.
Fixes #57780.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/kses.php

    r55309 r55564  
    22802280 * @since 6.2.0 Added support for `aspect-ratio`, `position`, `top`, `right`, `bottom`, `left`,
    22812281 *              and `z-index` CSS properties.
     2282 * @since 6.3.0 Extended support for `filter` to accept a URL.
    22822283 *
    22832284 * @param string $css        A string of CSS rules.
     
    24672468
    24682469        'cursor',
     2470        'filter',
    24692471
    24702472        'list-style',
Note: See TracChangeset for help on using the changeset viewer.