Repository navigation
feat(css): add color-interpolation property - #1121
Conversation
Record the draft PR links in docs/upstream-prs.md and the README: microsoft/vscode-custom-data#147 and #148, mdn/data#1121 and microsoft/vscode-css-languageservice#547. Drop the Claude attribution and session lines from the PR folders' COMMIT_MSG.txt and PR.md, and update the doc-paths PR body: the Nov 12 web custom data update filled the cited descriptions by hand, but the lookup still returns nothing on main.
Add `color-interpolation` to css/properties.json. The property is defined in SVG 2 and supported in all major browsers (css.properties.color-interpolation in BCD), and MDN already documents it. Only this data was missing it; its sibling `color-interpolation-filters` is already here. Values follow the spec, including the <color-interpolation-method> value that SVG 2 now takes from CSS Color 4: https://w3c.github.io/svgwg/svg2-draft/painting.html#ColorInterpolationProperty Adds the l10n key `limitedSVGElementsContainerGraphicsGradientUseAnimate` for "applies to" and registers it in properties.schema.json.
f6a1801 to
5fd8db5
Compare
There was a problem hiding this comment.
Note
Copilot was unable to complete this review at the selected tier due to model policy or plan restrictions.
🟡 Changes recommended
A new localization entry in l10n/css.json is added with only an en-US value while adjacent “applies to” keys include fr, creating a likely missing French translation that needs to be addressed before approval.
1 open issue
What changed in this PR
Adds the SVG 2 color-interpolation CSS property to the dataset so downstream consumers (e.g., MDN {{CSSInfo}}, VS Code CSS IntelliSense) can recognize and describe it consistently.
Changes:
- Add
color-interpolationtocss/properties.jsonwith syntax/initial/inheritance/computed/animation and applies-to metadata. - Introduce and register a new l10n “applies to” key for the property.
- Update
css/properties.schema.jsonto allow the newappliestokey value.
| File | Description |
|---|---|
| l10n/css.json | Adds a new localization key used to describe the property’s “applies to” scope for color-interpolation. |
| css/properties.schema.json | Registers the new appliesto l10n key in the schema so references validate. |
| css/properties.json | Adds the color-interpolation property definition aligned with the SVG 2 specification (syntax, defaults, inheritance, and applies-to mapping). |
Review effort: Balanced
There was a problem hiding this comment.
Note
Copilot was unable to complete this review at the selected tier due to model policy or plan restrictions.
🟡 Changes recommended
A remaining localization nit flags inconsistent French capitalization in l10n/css.json for a limitedSVGElements* string compared to adjacent entries, indicating a minor but unresolved issue still needs adjustment.
1 open issue
1 resolved since last review
Review effort: Balanced
Corrected capitalization in French translation for SVG elements. Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Replace the hand-written formal-definition table with {{CSSInfo}}, now
that mdn-data has the property (mdn/data#1121). The table was wrong:
it gave the initial value as `auto` (the spec, and Chromium, Gecko and
WebKit, all use `sRGB`) and listed only <linearGradient> and
<radialGradient> under "Applies to".
Replace the hand-written formal-definition table with {{CSSInfo}}, now
that mdn-data has the property (mdn/data#1121). The table was wrong:
it gave the initial value as `auto` (the spec, and Chromium, Gecko and
WebKit, all use `sRGB`) and listed only <linearGradient> and
<radialGradient> under "Applies to".

Description
Adds
color-interpolationtocss/properties.json, following the SVG 2 definition (Painting § color-interpolation, also in@webref/css). Also adds the l10n keylimitedSVGElementsContainerGraphicsGradientUseAnimate(en-USandfr) for "applies to" and registers it inproperties.schema.json.auto | sRGB | linearRGB | <color-interpolation-method>sRGBuseandanimateMotivation
color-interpolationis a standard property that every major browser has shipped for years (css.properties.color-interpolationin BCD), and MDN documents it at Web/CSS/Reference/Properties/color-interpolation. But it's missing fromcss/properties.json, while its siblingcolor-interpolation-filtersis present.{{CSSInfo}}without this entry. Its hand-written formal-definition table gives the initial value asautoand lists only<linearGradient>and<radialGradient>under "Applies to".microsoft/vscode-custom-data, and currently flagscolor-interpolationas Unknown property.Additional details
<color-interpolation-method>from CSS Color 4 to this property (w3c/svgwg#1173, for w3c/svgwg#366). It also definedsRGBandlinearRGBasin srgbandin srgb-linear.<color-interpolation-method>is already incss/syntaxes.json. No browser parses it yet: Chromium, Gecko and WebKit all accept only the three keywords. The syntax here follows the spec, asdocs/updating_css_json.mdasks.sRGB(Chromiumcss_properties.json5, Geckolonghands.toml, WebKitCSSProperties.json), and WPT'ssvg/painting/inheritance.svgtests it.npm testpasses. I also checked that the lint fails ifappliestopoints to an undefined key.vscode-css-languageservice. The property completes, and the Unknown property warning is gone.Related issues and pull requests
{{CSSInfo}}.