diff --git a/.update b/.update new file mode 100644 index 0000000..d8e77cf --- /dev/null +++ b/.update @@ -0,0 +1 @@ +Wed Mar 20 2024 19:58:05 GMT-0700 (Pacific Daylight Time) \ No newline at end of file diff --git a/idl/core/accessibility/aria_notification_options.idl b/idl/core/accessibility/aria_notification_options.idl new file mode 100644 index 0000000..e3a9164 --- /dev/null +++ b/idl/core/accessibility/aria_notification_options.idl @@ -0,0 +1,8 @@ +enum AriaNotifyInterrupt { "none", "all", "pending" }; +enum AriaNotifyPriority { "none", "important" }; + +dictionary AriaNotificationOptions { + AriaNotifyInterrupt interrupt = "none"; + AriaNotifyPriority priority = "none"; + DOMString notificationId = ""; +}; \ No newline at end of file diff --git a/idl/core/animation/animatable.idl b/idl/core/animation/animatable.idl new file mode 100644 index 0000000..3e816b7 --- /dev/null +++ b/idl/core/animation/animatable.idl @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2013 Google Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * * Neither the name of Google Inc. nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://w3.org/TR/web-animations-1/#the-animatable-interface-mixin +interface mixin Animatable { + [CallWith=ScriptState, Measure, RaisesException] Animation animate(object? keyframes, optional (unrestricted double or KeyframeAnimationOptions) options); + sequence getAnimations(optional GetAnimationsOptions options = {}); +}; + +// https://drafts.csswg.org/web-animations-1/#extensions-to-the-element-interface +Element includes Animatable; + +// https://drafts.csswg.org/web-animations-1/#extensions-to-the-pseudoelement-interface +// TODO(smcgruer): Uncomment once CSSPseudoElement is implemented in Chromium. +// CSSPseudoElement includes Animatable; diff --git a/idl/core/animation/animation.idl b/idl/core/animation/animation.idl new file mode 100644 index 0000000..bd549df --- /dev/null +++ b/idl/core/animation/animation.idl @@ -0,0 +1,66 @@ +/* + * Copyright (C) 2013 Google Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * * Neither the name of Google Inc. nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://w3.org/TR/web-animations-1/#the-animation-interface + +enum AnimationPlayState { "idle", "pending", "running", "paused", "finished" }; + +enum ReplaceState { "active", "removed", "persisted" }; + +[ + Exposed=Window, + ActiveScriptWrappable +] interface Animation : EventTarget { + [CallWith=ExecutionContext, RaisesException] constructor(optional AnimationEffect? effect = null, optional AnimationTimeline? timeline); + [Measure] attribute AnimationEffect? effect; + attribute AnimationTimeline? timeline; + [Measure, RaisesException=Setter] attribute CSSNumberish? startTime; + [Measure, RaisesException=Setter] attribute CSSNumberish? currentTime; + [Measure, RaisesException=Setter] attribute double playbackRate; + [RuntimeEnabled=ScrollTimeline, Measure, RaisesException=Setter] attribute (TimelineRangeOffset or DOMString) rangeStart; + [RuntimeEnabled=ScrollTimeline, Measure, RaisesException=Setter] attribute (TimelineRangeOffset or DOMString) rangeEnd; + [Measure] readonly attribute AnimationPlayState playState; + [Measure] readonly attribute ReplaceState replaceState; + [Measure] readonly attribute boolean pending; + [Measure, RaisesException, CEReactions] void commitStyles(); + [Measure, RaisesException] void finish(); + [Measure, RaisesException] void play(); + [Measure, RaisesException] void pause(); + [Measure, RaisesException] void reverse(); + [Measure, RaisesException] void updatePlaybackRate(double playback_rate); + [Measure] void persist(); + [Measure] attribute DOMString id; + [Measure] void cancel(); + [Measure] attribute EventHandler onfinish; + [Measure] attribute EventHandler oncancel; + [Measure] attribute EventHandler onremove; + [CallWith=ScriptState] readonly attribute Promise finished; + [CallWith=ScriptState] readonly attribute Promise ready; +}; diff --git a/idl/core/animation/animation_effect.idl b/idl/core/animation/animation_effect.idl new file mode 100644 index 0000000..5a17366 --- /dev/null +++ b/idl/core/animation/animation_effect.idl @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2013 Google Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * * Neither the name of Google Inc. nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://w3.org/TR/web-animations-1/#the-animationeffect-interface + +[Exposed=Window] +interface AnimationEffect { + EffectTiming getTiming(); + ComputedEffectTiming getComputedTiming(); + [RaisesException] void updateTiming(optional OptionalEffectTiming timing = {}); +}; diff --git a/idl/core/animation/animation_timeline.idl b/idl/core/animation/animation_timeline.idl new file mode 100644 index 0000000..c4ca4f4 --- /dev/null +++ b/idl/core/animation/animation_timeline.idl @@ -0,0 +1,14 @@ +// Copyright 2014 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://w3.org/TR/web-animations-1/#the-animationtimeline-interface + +enum TimelinePhase { "inactive", "before", "active", "after" }; +[ + Exposed=Window +] interface AnimationTimeline { + readonly attribute CSSNumberish? currentTime; + [RuntimeEnabled=ScrollTimeline] readonly attribute CSSNumberish? duration; + [RuntimeEnabled=ScrollTimelineCurrentTime] CSSNumericValue? getCurrentTime(optional DOMString rangeName = "cover"); +}; diff --git a/idl/core/animation/base_keyframe.idl b/idl/core/animation/base_keyframe.idl new file mode 100644 index 0000000..e8d6c2b --- /dev/null +++ b/idl/core/animation/base_keyframe.idl @@ -0,0 +1,14 @@ +// Copyright 2018 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://w3.org/TR/web-animations-1/#dictdef-basekeyframe + +enum CompositeOperationOrAuto {"replace", "add", "accumulate", "auto"}; + +typedef (double or TimelineRangeOffset or DOMString) KeyframeOffset; +dictionary BaseKeyframe { + KeyframeOffset? offset = null; + DOMString easing = "linear"; + CompositeOperationOrAuto composite = "auto"; +}; diff --git a/idl/core/animation/base_property_indexed_keyframe.idl b/idl/core/animation/base_property_indexed_keyframe.idl new file mode 100644 index 0000000..dd0ff76 --- /dev/null +++ b/idl/core/animation/base_property_indexed_keyframe.idl @@ -0,0 +1,11 @@ +// Copyright 2017 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://w3.org/TR/web-animations-1/#dictdef-basepropertyindexedkeyframe + +dictionary BasePropertyIndexedKeyframe { + (KeyframeOffset? or sequence) offset = []; + (DOMString or sequence) easing = []; + (CompositeOperationOrAuto or sequence) composite = []; +}; diff --git a/idl/core/animation/computed_effect_timing.idl b/idl/core/animation/computed_effect_timing.idl new file mode 100644 index 0000000..4dd6557 --- /dev/null +++ b/idl/core/animation/computed_effect_timing.idl @@ -0,0 +1,13 @@ +// Copyright 2014 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://w3.org/TR/web-animations-1/#the-computedeffecttiming-dictionary + +dictionary ComputedEffectTiming : EffectTiming { + CSSNumberish endTime; + CSSNumberish activeDuration; + CSSNumberish? localTime; + double? progress; + unrestricted double? currentIteration; +}; diff --git a/idl/core/animation/css/css_animation.idl b/idl/core/animation/css/css_animation.idl new file mode 100644 index 0000000..cfbfa6d --- /dev/null +++ b/idl/core/animation/css/css_animation.idl @@ -0,0 +1,10 @@ +// Copyright 2019 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/css-animations-2/#the-CSSAnimation-interface + +[Exposed=Window] +interface CSSAnimation : Animation { + readonly attribute CSSOMString animationName; +}; diff --git a/idl/core/animation/css/css_transition.idl b/idl/core/animation/css/css_transition.idl new file mode 100644 index 0000000..a5dc5ea --- /dev/null +++ b/idl/core/animation/css/css_transition.idl @@ -0,0 +1,10 @@ +// Copyright 2019 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/css-transitions-2/#the-CSSTransition-interface + +[Exposed=Window] +interface CSSTransition : Animation { + readonly attribute CSSOMString transitionProperty; +}; diff --git a/idl/core/animation/document_animation.idl b/idl/core/animation/document_animation.idl new file mode 100644 index 0000000..b0c5290 --- /dev/null +++ b/idl/core/animation/document_animation.idl @@ -0,0 +1,11 @@ +// Copyright 2014 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://w3.org/TR/web-animations-1/#extensions-to-the-document-interface + +[ + ImplementedAs=DocumentAnimation +] partial interface Document { + readonly attribute DocumentTimeline timeline; +}; diff --git a/idl/core/animation/document_timeline.idl b/idl/core/animation/document_timeline.idl new file mode 100644 index 0000000..0668662 --- /dev/null +++ b/idl/core/animation/document_timeline.idl @@ -0,0 +1,11 @@ +// Copyright 2016 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://w3.org/TR/web-animations-1/#the-documenttimeline-interface + +[ + Exposed=Window +] interface DocumentTimeline : AnimationTimeline { + [CallWith=ExecutionContext] constructor(optional DocumentTimelineOptions options = {}); +}; diff --git a/idl/core/animation/document_timeline_options.idl b/idl/core/animation/document_timeline_options.idl new file mode 100644 index 0000000..84ad2d9 --- /dev/null +++ b/idl/core/animation/document_timeline_options.idl @@ -0,0 +1,9 @@ +// Copyright 2017 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://w3.org/TR/web-animations-1/#dictdef-documenttimelineoptions + +dictionary DocumentTimelineOptions { + DOMHighResTimeStamp originTime = 0; +}; diff --git a/idl/core/animation/effect_timing.idl b/idl/core/animation/effect_timing.idl new file mode 100644 index 0000000..8742513 --- /dev/null +++ b/idl/core/animation/effect_timing.idl @@ -0,0 +1,19 @@ +// Copyright 2016 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://w3.org/TR/web-animations-1/#the-effecttiming-dictionaries + +enum FillMode { "none", "forwards", "backwards", "both", "auto" }; +enum PlaybackDirection { "normal", "reverse", "alternate", "alternate-reverse" }; + +dictionary EffectTiming { + (double or CSSNumericValue) delay = 0; + (double or CSSNumericValue) endDelay = 0; + FillMode fill = "auto"; + double iterationStart = 0.0; + unrestricted double iterations = 1.0; + (unrestricted double or CSSNumericValue or DOMString) duration = "auto"; + PlaybackDirection direction = "normal"; + DOMString easing = "linear"; +}; diff --git a/idl/core/animation/get_animations_options.idl b/idl/core/animation/get_animations_options.idl new file mode 100644 index 0000000..bf27144 --- /dev/null +++ b/idl/core/animation/get_animations_options.idl @@ -0,0 +1,9 @@ +// Copyright 2019 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/web-animations-1/#the-animatable-interface-mixin + +dictionary GetAnimationsOptions { + boolean subtree = false; +}; diff --git a/idl/core/animation/keyframe_animation_options.idl b/idl/core/animation/keyframe_animation_options.idl new file mode 100644 index 0000000..a58acd1 --- /dev/null +++ b/idl/core/animation/keyframe_animation_options.idl @@ -0,0 +1,29 @@ +// Copyright 2017 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://w3.org/TR/web-animations-1/#dictdef-keyframeanimationoptions + +// TODO(kevers): Add scroll-animations-1 link once range(Start|End) are fully +// speced. + +enum TimelineRange { + "none", + "cover", + "contain", + "entry", + "entry-crossing", + "exit", + "exit-crossing" }; + +dictionary TimelineRangeOffset { + TimelineRange rangeName; + CSSNumericValue offset; +}; + +dictionary KeyframeAnimationOptions : KeyframeEffectOptions { + DOMString id = ""; + AnimationTimeline? timeline; + (DOMString or TimelineRangeOffset) rangeStart = "normal"; + (DOMString or TimelineRangeOffset) rangeEnd = "normal"; +}; diff --git a/idl/core/animation/keyframe_effect.idl b/idl/core/animation/keyframe_effect.idl new file mode 100644 index 0000000..5077101 --- /dev/null +++ b/idl/core/animation/keyframe_effect.idl @@ -0,0 +1,45 @@ +/* + * Copyright (C) 2013 Google Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * * Neither the name of Google Inc. nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://w3.org/TR/web-animations-1/#the-keyframeeffect-interface + +enum CompositeOperation { "replace", "add", "accumulate" }; + +[ + Exposed=Window +] interface KeyframeEffect : AnimationEffect { + [CallWith=ScriptState, RaisesException, Measure] constructor(Element? target, object? keyframes, optional (unrestricted double or KeyframeEffectOptions) options); + [CallWith=ScriptState, RaisesException, Measure] constructor(KeyframeEffect source); + attribute Element? target; + [RaisesException=Setter] attribute CSSOMString? pseudoElement; + attribute CompositeOperation composite; + [CallWith=ScriptState] sequence getKeyframes(); + [CallWith=ScriptState, RaisesException] void setKeyframes(object? keyframes); +}; diff --git a/idl/core/animation/keyframe_effect_options.idl b/idl/core/animation/keyframe_effect_options.idl new file mode 100644 index 0000000..1f4ec7d --- /dev/null +++ b/idl/core/animation/keyframe_effect_options.idl @@ -0,0 +1,11 @@ +// Copyright 2016 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://w3.org/TR/web-animations-1/#the-keyframeeffectoptions-dictionary + +dictionary KeyframeEffectOptions : EffectTiming { + // TODO(alancutter): Implement iterationComposite + CompositeOperation composite = "replace"; + CSSOMString? pseudoElement = null; +}; diff --git a/idl/core/animation/optional_effect_timing.idl b/idl/core/animation/optional_effect_timing.idl new file mode 100644 index 0000000..0164bad --- /dev/null +++ b/idl/core/animation/optional_effect_timing.idl @@ -0,0 +1,19 @@ +// Copyright 2018 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/web-animations-1/#the-effecttiming-dictionaries + +dictionary OptionalEffectTiming { + (double or CSSNumericValue) delay; + (double or CSSNumericValue) endDelay; + FillMode fill; + double iterationStart; + unrestricted double iterations; + // CSSNumericValue is only included here so that it continues to match + // EffectTiming which allows code that expects them to match to continue + // working. Duration cannot be set using CSSNumericValue. + (unrestricted double or CSSNumericValue or DOMString) duration; + PlaybackDirection direction; + DOMString easing; +}; diff --git a/idl/core/animation/scroll_timeline.idl b/idl/core/animation/scroll_timeline.idl new file mode 100644 index 0000000..58f7cb2 --- /dev/null +++ b/idl/core/animation/scroll_timeline.idl @@ -0,0 +1,15 @@ +// Copyright 2017 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +enum ScrollAxis { "block", "inline", "x", "y" }; + +// https://wicg.github.io/scroll-animations/#scrolltimeline-interface +[ + RuntimeEnabled=ScrollTimeline, + Exposed=Window +] interface ScrollTimeline : AnimationTimeline { + [CallWith=Document, RaisesException, MeasureAs=ScrollTimelineConstructor] constructor(optional ScrollTimelineOptions options = {}); + readonly attribute Element? source; + readonly attribute ScrollAxis axis; +}; diff --git a/idl/core/animation/scroll_timeline_options.idl b/idl/core/animation/scroll_timeline_options.idl new file mode 100644 index 0000000..b49daa9 --- /dev/null +++ b/idl/core/animation/scroll_timeline_options.idl @@ -0,0 +1,10 @@ +// Copyright 2017 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://wicg.github.io/scroll-animations/#dictdef-scrolltimelineoptions + +dictionary ScrollTimelineOptions { + Element? source; + ScrollAxis axis = "block"; +}; diff --git a/idl/core/animation/view_timeline.idl b/idl/core/animation/view_timeline.idl new file mode 100644 index 0000000..9301a84 --- /dev/null +++ b/idl/core/animation/view_timeline.idl @@ -0,0 +1,16 @@ +// Copyright 2022 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// TODO(crbug.com/1329159): Update link once rewrite replaces the draft +// version. +// https://drafts.csswg.org/scroll-animations-1/rewrite#viewtimeline-interface +[ + RuntimeEnabled=ScrollTimeline, + Exposed=Window +] interface ViewTimeline : ScrollTimeline { + [CallWith=Document, RaisesException, MeasureAs=ViewTimelineConstructor] constructor(optional ViewTimelineOptions options = {}); + readonly attribute Element? subject; + readonly attribute CSSNumericValue? startOffset; + readonly attribute CSSNumericValue? endOffset; +}; diff --git a/idl/core/animation/view_timeline_options.idl b/idl/core/animation/view_timeline_options.idl new file mode 100644 index 0000000..f81b112 --- /dev/null +++ b/idl/core/animation/view_timeline_options.idl @@ -0,0 +1,13 @@ +// Copyright 2022 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/scroll-animations-1/rewrite#viewtimeline-interface + +dictionary ViewTimelineOptions { + Element subject; + ScrollAxis axis = "block"; + // String in CSS format or sequence of TypedOM values. + // DOMString within sequence is for keyword "auto". + (DOMString or sequence<(DOMString or CSSNumericValue)>) inset = []; +}; diff --git a/idl/core/aom/accessible_node.idl b/idl/core/aom/accessible_node.idl new file mode 100644 index 0000000..02775b6 --- /dev/null +++ b/idl/core/aom/accessible_node.idl @@ -0,0 +1,72 @@ +// Copyright 2017 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// Accessibility Object Model node +// Explainer: https://github.com/WICG/aom/blob/gh-pages/explainer.md +// Spec: https://wicg.github.io/aom/spec/ +[ + Exposed=Window, + RuntimeEnabled=AccessibilityObjectModel +] interface AccessibleNode : EventTarget { + [CallWith=Document] constructor(); + attribute AccessibleNode? activeDescendant; + attribute boolean? atomic; + attribute DOMString? autocomplete; + attribute boolean? busy; + attribute DOMString? checked; + attribute long? colCount; + attribute unsigned long? colIndex; + attribute unsigned long? colSpan; + attribute AccessibleNodeList? controls; + attribute DOMString? current; + attribute AccessibleNodeList? describedBy; + attribute AccessibleNodeList? details; + attribute boolean? disabled; + attribute AccessibleNodeList? errorMessage; + attribute boolean? expanded; + attribute AccessibleNodeList? flowTo; + attribute DOMString? hasPopup; + attribute boolean? hidden; + attribute DOMString? invalid; + attribute DOMString? keyShortcuts; + attribute DOMString? label; + attribute AccessibleNodeList? labeledBy; + attribute unsigned long? level; + attribute DOMString? live; + attribute boolean? modal; + attribute boolean? multiline; + attribute boolean? multiselectable; + attribute DOMString? orientation; + attribute AccessibleNodeList? owns; + attribute DOMString? placeholder; + attribute unsigned long? posInSet; + attribute DOMString? pressed; + attribute boolean? readOnly; + attribute DOMString? relevant; + attribute boolean? required; + attribute DOMString? role; + attribute DOMString? roleDescription; + attribute long? rowCount; + attribute unsigned long? rowIndex; + attribute unsigned long? rowSpan; + attribute boolean? selected; + attribute long? setSize; + attribute DOMString? sort; + attribute double? valueMax; + attribute double? valueMin; + attribute double? valueNow; + attribute DOMString? valueText; + + attribute EventHandler onaccessibleclick; + attribute EventHandler onaccessiblecontextmenu; + attribute EventHandler onaccessibledecrement; + attribute EventHandler onaccessiblefocus; + attribute EventHandler onaccessibleincrement; + attribute EventHandler onaccessiblescrollintoview; + + readonly attribute AccessibleNodeList childNodes; + + [RaisesException] void appendChild(AccessibleNode child); + [RaisesException] void removeChild(AccessibleNode child); +}; diff --git a/idl/core/aom/accessible_node_list.idl b/idl/core/aom/accessible_node_list.idl new file mode 100644 index 0000000..c742c8f --- /dev/null +++ b/idl/core/aom/accessible_node_list.idl @@ -0,0 +1,18 @@ +// Copyright 2017 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// Accessibility Object Model node list +// Explainer: https://github.com/WICG/aom/blob/gh-pages/explainer.md +// Spec: https://wicg.github.io/aom/spec/ +[ + Exposed=Window, + RuntimeEnabled=AccessibilityObjectModel +] interface AccessibleNodeList { + constructor(optional sequence nodes = []); + attribute unsigned long length; + getter AccessibleNode? item(unsigned long index); + [RaisesException] setter void (unsigned long index, AccessibleNode node); + void add(AccessibleNode node, optional AccessibleNode? before = null); + void remove(long index); +}; diff --git a/idl/core/aom/computed_accessible_node.idl b/idl/core/aom/computed_accessible_node.idl new file mode 100644 index 0000000..5a810b3 --- /dev/null +++ b/idl/core/aom/computed_accessible_node.idl @@ -0,0 +1,54 @@ +// Copyright 2017 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// Computed Accessibility node +// Explainer: https://github.com/WICG/aom/blob/gh-pages/explainer.md +// Spec: https://wicg.github.io/aom/spec/ +[ + Exposed=Window, + RuntimeEnabled=AccessibilityObjectModel +] interface ComputedAccessibleNode { + + readonly attribute boolean? atomic; + readonly attribute boolean? busy; + readonly attribute boolean? disabled; + readonly attribute boolean? expanded; + readonly attribute boolean? modal; + readonly attribute boolean? multiline; + readonly attribute boolean? multiselectable; + readonly attribute boolean? readOnly; + readonly attribute boolean? required; + readonly attribute boolean? selected; + + readonly attribute long? colCount; + readonly attribute unsigned long? colIndex; + readonly attribute unsigned long? colSpan; + readonly attribute unsigned long? level; + readonly attribute unsigned long? posInSet; + readonly attribute long? rowCount; + readonly attribute unsigned long? rowIndex; + readonly attribute unsigned long? rowSpan; + readonly attribute long? setSize; + + readonly attribute double? valueMax; + readonly attribute double? valueMin; + readonly attribute double? valueNow; + + readonly attribute DOMString? autocomplete; + readonly attribute DOMString? checked; + readonly attribute DOMString? keyShortcuts; + readonly attribute DOMString? name; + readonly attribute DOMString? placeholder; + readonly attribute DOMString? role; + readonly attribute DOMString? roleDescription; + readonly attribute DOMString? valueText; + + readonly attribute ComputedAccessibleNode? parent; + readonly attribute ComputedAccessibleNode? firstChild; + readonly attribute ComputedAccessibleNode? lastChild; + readonly attribute ComputedAccessibleNode? previousSibling; + readonly attribute ComputedAccessibleNode? nextSibling; + + [CallWith=ScriptState] Promise ensureUpToDate(); +}; diff --git a/idl/core/clipboard/data_transfer.idl b/idl/core/clipboard/data_transfer.idl new file mode 100644 index 0000000..7209dd8 --- /dev/null +++ b/idl/core/clipboard/data_transfer.idl @@ -0,0 +1,48 @@ +/* + * Copyright (C) 2008 Apple Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of Apple Computer, Inc. ("Apple") nor the names of + * its contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://html.spec.whatwg.org/C/#the-datatransfer-interface + +[ + Exposed=Window +] interface DataTransfer { + constructor(); + attribute DOMString dropEffect; + attribute DOMString effectAllowed; + + [SameObject] readonly attribute DataTransferItemList items; + + void setDragImage(Element image, long x, long y); + + /* old interface */ + [CachedAttribute=hasDataStoreItemListChanged] readonly attribute FrozenArray types; + DOMString getData(DOMString format); + void setData(DOMString format, DOMString data); + void clearData(optional DOMString format); + [SameObject] readonly attribute FileList files; +}; diff --git a/idl/core/clipboard/data_transfer_item.idl b/idl/core/clipboard/data_transfer_item.idl new file mode 100644 index 0000000..3e163a8 --- /dev/null +++ b/idl/core/clipboard/data_transfer_item.idl @@ -0,0 +1,40 @@ +/* + * Copyright (C) 2011 Google Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * * Neither the name of Google Inc. nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://html.spec.whatwg.org/C/#the-datatransferitem-interface + +[ + Exposed=Window +] interface DataTransferItem { + readonly attribute DOMString kind; + readonly attribute DOMString type; + [CallWith=ScriptState] void getAsString(FunctionStringCallback? callback); + File? getAsFile(); +}; \ No newline at end of file diff --git a/idl/core/clipboard/data_transfer_item_list.idl b/idl/core/clipboard/data_transfer_item_list.idl new file mode 100644 index 0000000..2403585 --- /dev/null +++ b/idl/core/clipboard/data_transfer_item_list.idl @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2011 Google Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * * Neither the name of Google Inc. nor the names of its + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://html.spec.whatwg.org/C/#the-datatransferitemlist-interface + +[ + Exposed=Window +] interface DataTransferItemList { + readonly attribute unsigned long length; + [ImplementedAs=item] getter DataTransferItem (unsigned long index); + [RaisesException] DataTransferItem? add(DOMString data, DOMString type); + DataTransferItem? add(File file); + [RaisesException, ImplementedAs=deleteItem] void remove(unsigned long index); + void clear(); +}; diff --git a/idl/core/css/computed_style_field_aliases.json5 b/idl/core/css/computed_style_field_aliases.json5 new file mode 100644 index 0000000..f59f92f --- /dev/null +++ b/idl/core/css/computed_style_field_aliases.json5 @@ -0,0 +1,20 @@ +{ +// This file specifies all alias used in css_properties.json5, these alias +// replace frequently used combination of property. + "parameters": { + }, + "data": [ + { + "name": "", + "field_template": "external", + "type_name": "Length", + "include_paths": ["third_party/blink/renderer/platform/geometry/length.h"] + }, + { + "name": "", + "field_template": "external", + "type_name": "StyleColor", + "include_paths": ["third_party/blink/renderer/core/css/style_color.h"], + } + ] +} diff --git a/idl/core/css/css.idl b/idl/core/css/css.idl new file mode 100644 index 0000000..02f8f48 --- /dev/null +++ b/idl/core/css/css.idl @@ -0,0 +1,39 @@ +/* + * Copyright (C) 2012 Motorola Mobility Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the distribution. + * 3. Neither the name of Motorola Mobility Inc. nor the names of its + * contributors may be used to endorse or promote products derived from this + * software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://drafts.csswg.org/css-conditional/#the-css-interface + +[ + Exposed=Window, + ImplementedAs=DOMWindowCSS +] namespace CSS { + [CallWith=ExecutionContext] boolean supports(DOMString property, DOMString value); + [CallWith=ExecutionContext] boolean supports(DOMString conditionText); + DOMString escape(DOMString ident); +}; diff --git a/idl/core/css/css_condition_rule.idl b/idl/core/css/css_condition_rule.idl new file mode 100644 index 0000000..c306ae7 --- /dev/null +++ b/idl/core/css/css_condition_rule.idl @@ -0,0 +1,12 @@ +// Copyright 2016 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/css-conditional/#the-cssconditionrule-interface + +[ + Exposed=Window +] interface CSSConditionRule : CSSGroupingRule { + // TODO(xing.xu): readonly should be removed. + readonly attribute DOMString conditionText; +}; diff --git a/idl/core/css/css_container_rule.idl b/idl/core/css/css_container_rule.idl new file mode 100644 index 0000000..5f7eff6 --- /dev/null +++ b/idl/core/css/css_container_rule.idl @@ -0,0 +1,11 @@ +// Copyright 2020 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +[ + Exposed=Window +] interface CSSContainerRule : CSSConditionRule { + // TODO(crbug.com/1145970): Spec and implement. + readonly attribute DOMString containerName; + readonly attribute DOMString containerQuery; +}; diff --git a/idl/core/css/css_counter_style_rule.idl b/idl/core/css/css_counter_style_rule.idl new file mode 100644 index 0000000..35d9b98 --- /dev/null +++ b/idl/core/css/css_counter_style_rule.idl @@ -0,0 +1,19 @@ +// Copyright 2020 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/css-counter-styles-3/#the-csscounterstylerule-interface +[Exposed=Window] +interface CSSCounterStyleRule : CSSRule { + [SetterCallWith=ExecutionContext] attribute CSSOMString name; + [SetterCallWith=ExecutionContext] attribute CSSOMString system; + [SetterCallWith=ExecutionContext] attribute CSSOMString symbols; + [SetterCallWith=ExecutionContext] attribute CSSOMString additiveSymbols; + [SetterCallWith=ExecutionContext] attribute CSSOMString negative; + [SetterCallWith=ExecutionContext] attribute CSSOMString prefix; + [SetterCallWith=ExecutionContext] attribute CSSOMString suffix; + [SetterCallWith=ExecutionContext] attribute CSSOMString range; + [SetterCallWith=ExecutionContext] attribute CSSOMString pad; + [SetterCallWith=ExecutionContext] attribute CSSOMString speakAs; + [SetterCallWith=ExecutionContext] attribute CSSOMString fallback; +}; diff --git a/idl/core/css/css_font_face_rule.idl b/idl/core/css/css_font_face_rule.idl new file mode 100644 index 0000000..074647a --- /dev/null +++ b/idl/core/css/css_font_face_rule.idl @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2006, 2007 Apple Inc. All rights reserved. + * Copyright (C) 2006 Samuel Weinig + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public License + * along with this library; see the file COPYING.LIB. If not, write to + * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + * Boston, MA 02110-1301, USA. + */ + +// https://drafts.csswg.org/css-fonts/#om-fontface + +[ + Exposed=Window +] interface CSSFontFaceRule : CSSRule { + [Measure] readonly attribute CSSStyleDeclaration style; +}; diff --git a/idl/core/css/css_font_feature_values_rule.idl b/idl/core/css/css_font_feature_values_rule.idl new file mode 100644 index 0000000..0ee2386 --- /dev/null +++ b/idl/core/css/css_font_feature_values_rule.idl @@ -0,0 +1,22 @@ +// Copyright 2022 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/css-fonts-4/#om-fontfeaturevalues + +interface CSSFontFeatureValuesRule : CSSRule { + attribute CSSOMString fontFamily; + + readonly attribute CSSFontFeatureValuesMap annotation; + readonly attribute CSSFontFeatureValuesMap ornaments; + readonly attribute CSSFontFeatureValuesMap stylistic; + readonly attribute CSSFontFeatureValuesMap swash; + readonly attribute CSSFontFeatureValuesMap characterVariant; + readonly attribute CSSFontFeatureValuesMap styleset; +}; + +interface CSSFontFeatureValuesMap { + maplike>; + undefined set(CSSOMString featureValueName, + (unsigned long or sequence) values); +}; diff --git a/idl/core/css/css_font_palette_values_rule.idl b/idl/core/css/css_font_palette_values_rule.idl new file mode 100644 index 0000000..64a8fcf --- /dev/null +++ b/idl/core/css/css_font_palette_values_rule.idl @@ -0,0 +1,13 @@ +// Copyright 2022 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/css-fonts-4/#om-fontpalettevalues + +[Exposed=Window] +interface CSSFontPaletteValuesRule : CSSRule { + readonly attribute CSSOMString name; + readonly attribute CSSOMString fontFamily; + readonly attribute CSSOMString basePalette; + readonly attribute CSSOMString overrideColors; +}; diff --git a/idl/core/css/css_group_config.json5 b/idl/core/css/css_group_config.json5 new file mode 100644 index 0000000..19100eb --- /dev/null +++ b/idl/core/css/css_group_config.json5 @@ -0,0 +1,25 @@ +// DO NOT EDIT: This file is generated by manually running: +// third_party/blink/renderer/build/scripts/update_css_ranking.py +// +// The grouping parameter is a cumulative distribution over the whole set of ranked +// CSS properties. +{ + "data": [ + { + "name": "rare_non_inherited_properties_rule", + "cumulative_distribution": [ + 0.1366120218579235, + 0.2185792349726776, + 1.0 + ] + }, + { + "name": "rare_inherited_properties_rule", + "cumulative_distribution": [ + 0.6379781420765027, + 1.0 + ] + } + ], + "parameters": {} +} diff --git a/idl/core/css/css_grouping_rule.idl b/idl/core/css/css_grouping_rule.idl new file mode 100644 index 0000000..2a3db77 --- /dev/null +++ b/idl/core/css/css_grouping_rule.idl @@ -0,0 +1,13 @@ +// Copyright 2015 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/cssom/#the-cssgroupingrule-interface + +[ + Exposed=Window +] interface CSSGroupingRule : CSSRule { + [SameObject] readonly attribute CSSRuleList cssRules; + [RaisesException, CallWith=ExecutionContext] unsigned long insertRule(CSSOMString rule, optional unsigned long index = 0); + [RaisesException] void deleteRule(unsigned long index); +}; diff --git a/idl/core/css/css_import_rule.idl b/idl/core/css/css_import_rule.idl new file mode 100644 index 0000000..6f4d85f --- /dev/null +++ b/idl/core/css/css_import_rule.idl @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2006, 2007 Apple Inc. All rights reserved. + * Copyright (C) 2006 Samuel Weinig + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public License + * along with this library; see the file COPYING.LIB. If not, write to + * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + * Boston, MA 02110-1301, USA. + */ + +// https://drafts.csswg.org/cssom/#the-cssimportrule-interface + +[ + Exposed=Window +] interface CSSImportRule : CSSRule { + // TODO(bhagirathi.s@samsung.com): href should be USVString. + readonly attribute DOMString href; + [SameObject, PutForwards=mediaText] readonly attribute MediaList media; + [SameObject] readonly attribute CSSStyleSheet styleSheet; + + readonly attribute CSSOMString? layerName; + readonly attribute CSSOMString? supportsText; +}; diff --git a/idl/core/css/css_keyframe_rule.idl b/idl/core/css/css_keyframe_rule.idl new file mode 100644 index 0000000..16d3d08 --- /dev/null +++ b/idl/core/css/css_keyframe_rule.idl @@ -0,0 +1,36 @@ +/* + * Copyright (C) 2008 Apple Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of Apple Computer, Inc. ("Apple") nor the names of + * its contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://drafts.csswg.org/css-animations/#interface-csskeyframerule + +[ + Exposed=Window +] interface CSSKeyframeRule : CSSRule { + [RaisesException=Setter, SetterCallWith=ExecutionContext] attribute DOMString keyText; + [SameObject, PutForwards=cssText] readonly attribute CSSStyleDeclaration style; +}; diff --git a/idl/core/css/css_keyframes_rule.idl b/idl/core/css/css_keyframes_rule.idl new file mode 100644 index 0000000..0f1ef7e --- /dev/null +++ b/idl/core/css/css_keyframes_rule.idl @@ -0,0 +1,42 @@ +/* + * Copyright (C) 2008 Apple Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of Apple Computer, Inc. ("Apple") nor the names of + * its contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://drafts.csswg.org/css-animations/#interface-csskeyframesrule + +[ + Exposed=Window +] interface CSSKeyframesRule : CSSRule { + attribute DOMString name; + readonly attribute CSSRuleList cssRules; + [RuntimeEnabled=CSSKeyframesRuleLength] readonly attribute unsigned long length; + + getter CSSKeyframeRule (unsigned long index); + [CallWith=ExecutionContext] void appendRule(DOMString rule); + [CallWith=ExecutionContext] void deleteRule(DOMString select); + [CallWith=ExecutionContext] CSSKeyframeRule? findRule(DOMString select); +}; diff --git a/idl/core/css/css_layer_block_rule.idl b/idl/core/css/css_layer_block_rule.idl new file mode 100644 index 0000000..e7ed02d --- /dev/null +++ b/idl/core/css/css_layer_block_rule.idl @@ -0,0 +1,10 @@ +// Copyright 2021 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/css-cascade-5/#the-csslayerblockrule-interface +[ + Exposed=Window +] interface CSSLayerBlockRule : CSSGroupingRule { + readonly attribute CSSOMString name; +}; diff --git a/idl/core/css/css_layer_statement_rule.idl b/idl/core/css/css_layer_statement_rule.idl new file mode 100644 index 0000000..4b3b095 --- /dev/null +++ b/idl/core/css/css_layer_statement_rule.idl @@ -0,0 +1,10 @@ +// Copyright 2021 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/css-cascade-5/#the-csslayerstatementrule-interface +[ + Exposed=Window +] interface CSSLayerStatementRule : CSSRule { + readonly attribute FrozenArray nameList; +}; diff --git a/idl/core/css/css_media_rule.idl b/idl/core/css/css_media_rule.idl new file mode 100644 index 0000000..d4e4809 --- /dev/null +++ b/idl/core/css/css_media_rule.idl @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2006, 2007 Apple Inc. All rights reserved. + * Copyright (C) 2006 Samuel Weinig + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public License + * along with this library; see the file COPYING.LIB. If not, write to + * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + * Boston, MA 02110-1301, USA. + */ + +// https://drafts.csswg.org/cssom/#the-cssmediarule-interface + +[ + Exposed=Window +] interface CSSMediaRule : CSSConditionRule { + [SameObject, PutForwards=mediaText] readonly attribute MediaList media; +}; diff --git a/idl/core/css/css_namespace_rule.idl b/idl/core/css/css_namespace_rule.idl new file mode 100644 index 0000000..d73a481 --- /dev/null +++ b/idl/core/css/css_namespace_rule.idl @@ -0,0 +1,13 @@ +// Copyright 2015 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/cssom/#the-cssnamespacerule-interface + +[ + Exposed=Window +] interface CSSNamespaceRule : CSSRule { + + readonly attribute DOMString namespaceURI; + readonly attribute DOMString prefix; +}; diff --git a/idl/core/css/css_page_rule.idl b/idl/core/css/css_page_rule.idl new file mode 100644 index 0000000..ae81873 --- /dev/null +++ b/idl/core/css/css_page_rule.idl @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2006, 2007 Apple Inc. All rights reserved. + * Copyright (C) 2006 Samuel Weinig + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public License + * along with this library; see the file COPYING.LIB. If not, write to + * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + * Boston, MA 02110-1301, USA. + */ + +// https://drafts.csswg.org/cssom/#the-csspagerule-interface + +// TODO(foolip): CSSPageRule should inherit from CSSGroupingRule. +// crbug.com/496381. To internally implement this as grouping rule, +// margin at-rules should be implemented crbug.com/320370, since the +// spec https://drafts.csswg.org/css-page/#at-page-rule allows only +// margin at-rules inside @page. +[ + Exposed=Window +] interface CSSPageRule : CSSRule { + [SetterCallWith=ExecutionContext] attribute DOMString selectorText; + [SameObject, PutForwards=cssText] readonly attribute CSSStyleDeclaration style; +}; diff --git a/idl/core/css/css_position_try_rule.idl b/idl/core/css/css_position_try_rule.idl new file mode 100644 index 0000000..4b4bee2 --- /dev/null +++ b/idl/core/css/css_position_try_rule.idl @@ -0,0 +1,11 @@ +// Copyright 2024 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +// https://drafts.csswg.org/css-anchor-position-1/#idl-index + +[Exposed=Window, RuntimeEnabled=CSSAnchorPositioning] +interface CSSPositionTryRule : CSSRule { + readonly attribute CSSOMString name; + [SameObject, PutForwards=cssText] readonly attribute CSSStyleDeclaration style; +}; diff --git a/idl/core/css/css_primitive_value_units.json5 b/idl/core/css/css_primitive_value_units.json5 new file mode 100644 index 0000000..bd6a81b --- /dev/null +++ b/idl/core/css/css_primitive_value_units.json5 @@ -0,0 +1,262 @@ +{ + // This file specifies the unit strings used in CSSPrimitiveValues. + + parameters: { + unit_type: {}, + }, + + data: [ + { + name: "em", + unit_type: "kEms", + }, + { + name: "ex", + unit_type: "kExs", + }, + { + name: "px", + unit_type: "kPixels", + }, + { + name: "cm", + unit_type: "kCentimeters", + }, + { + name: "mm", + unit_type: "kMillimeters", + }, + { + name: "q", + unit_type: "kQuarterMillimeters", + }, + { + name: "in", + unit_type: "kInches", + }, + { + name: "pt", + unit_type: "kPoints", + }, + { + name: "pc", + unit_type: "kPicas", + }, + { + name: "deg", + unit_type: "kDegrees", + }, + { + name: "rad", + unit_type: "kRadians", + }, + { + name: "grad", + unit_type: "kGradians", + }, + { + name: "ms", + unit_type: "kMilliseconds", + }, + { + name: "s", + unit_type: "kSeconds", + }, + { + name: "hz", + unit_type: "kHertz", + }, + { + name: "khz", + unit_type: "kKilohertz", + }, + { + name: "dpi", + unit_type: "kDotsPerInch", + }, + { + name: "dpcm", + unit_type: "kDotsPerCentimeter", + }, + { + name: "dppx", + unit_type: "kDotsPerPixel", + }, + { + name: "x", + unit_type: "kX", + }, + { + name: "vw", + unit_type: "kViewportWidth", + }, + { + name: "vh", + unit_type: "kViewportHeight", + }, + { + name: "vi", + unit_type: "kViewportInlineSize", + }, + { + name: "vb", + unit_type: "kViewportBlockSize", + }, + { + name: "vmin", + unit_type: "kViewportMin", + }, + { + name: "vmax", + unit_type: "kViewportMax", + }, + { + name: "svw", + unit_type: "kSmallViewportWidth", + }, + { + name: "svh", + unit_type: "kSmallViewportHeight", + }, + { + name: "svi", + unit_type: "kSmallViewportInlineSize", + }, + { + name: "svb", + unit_type: "kSmallViewportBlockSize", + }, + { + name: "svmin", + unit_type: "kSmallViewportMin", + }, + { + name: "svmax", + unit_type: "kSmallViewportMax", + }, + { + name: "lvw", + unit_type: "kLargeViewportWidth", + }, + { + name: "lvh", + unit_type: "kLargeViewportHeight", + }, + { + name: "lvi", + unit_type: "kLargeViewportInlineSize", + }, + { + name: "lvb", + unit_type: "kLargeViewportBlockSize", + }, + { + name: "lvmin", + unit_type: "kLargeViewportMin", + }, + { + name: "lvmax", + unit_type: "kLargeViewportMax", + }, + { + name: "dvw", + unit_type: "kDynamicViewportWidth", + }, + { + name: "dvh", + unit_type: "kDynamicViewportHeight", + }, + { + name: "dvi", + unit_type: "kDynamicViewportInlineSize", + }, + { + name: "dvb", + unit_type: "kDynamicViewportBlockSize", + }, + { + name: "dvmin", + unit_type: "kDynamicViewportMin", + }, + { + name: "dvmax", + unit_type: "kDynamicViewportMax", + }, + { + name: "cqw", + unit_type: "kContainerWidth", + }, + { + name: "cqh", + unit_type: "kContainerHeight", + }, + { + name: "cqi", + unit_type: "kContainerInlineSize", + }, + { + name: "cqb", + unit_type: "kContainerBlockSize", + }, + { + name: "cqmin", + unit_type: "kContainerMin", + }, + { + name: "cqmax", + unit_type: "kContainerMax", + }, + { + name: "rem", + unit_type: "kRems", + }, + { + name: "rex", + unit_type: "kRexs", + }, + { + name: "rch", + unit_type: "kRchs", + }, + { + name: "ric", + unit_type: "kRics", + }, + { + name: "fr", + unit_type: "kFlex", + }, + { + name: "turn", + unit_type: "kTurns", + }, + { + name: "ch", + unit_type: "kChs", + }, + { + name: "ic", + unit_type: "kIcs", + }, + { + name: "lh", + unit_type: "kLhs", + }, + { + name: "rlh", + unit_type: "kRlhs", + }, + { + name: "cap", + unit_type: "kCaps", + }, + { + name: "rcap", + unit_type: "kRcaps", + }, + { + name: "__qem", + unit_type: "kQuirkyEms", + }, + ], +} diff --git a/idl/core/css/css_properties.json5 b/idl/core/css/css_properties.json5 new file mode 100644 index 0000000..02a54b3 --- /dev/null +++ b/idl/core/css/css_properties.json5 @@ -0,0 +1,8863 @@ +// Copyright 2017 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +{ +// This file specifies all the CSS properties we support and the necessary +// information for our code generation. The various supported arguments +// are described below with example usage + + parameters: { + // - alias_for: "other-property" + // Properties specifying alias_for should be virtually identical to the + // properties they alias. Minor parsing differences are allowed as long as + // the CSSValues created are of the same format of the aliased property. + alias_for: { + }, + + // - alternative_of: "other-property" + // + // Makes the the property an "alternative" of another property. + // An alternative property has a separate CSSProperty class which (based on + // runtime flags) is used internally in place of the main CSSProperty class. + // This makes it possible to e.g. switch a property definition from a + // longhand to a shorthand at runtime. + // + // When parsing text (e.g. "animation") into a CSSPropertyID, the + // alternative will be chosen if it is enabled. Otherwise, the main + // property will be chosen. + // + // A main property may only have a single alternative property. It is + // however possible to have an alternative of an alternative, in which case + // the chain is followed. In other words, we choose the "innermost" + // alternative that's enabled. + // + // Note that an alternative property ignores any runtime_flag on the main + // property. + alternative_of: { + valid_type: "str", + }, + + // - longhands: ["property", "other-property"] + // The property is a shorthand for several other properties. + longhands: { + }, + + // - property_methods: ["method1", "method2"] + // List of methods that are implemented in the CSSProperty for this + // property. + property_methods: { + default: [], + valid_type: "list", + valid_values: [ + "ParseSingleValue", + "ParseShorthand", + "CSSValueFromComputedStyleInternal", + "ColorIncludingFallback", + "InitialValue" + ], + }, + + // Suppresses code generation for the specified style builder functions. + // This allows us to provide hand-written style builder functions in cases + // where it's needed. + style_builder_custom_functions: { + default: [], + valid_type: "list", + valid_values: [ + "initial", + "inherit", + "value", + ], + }, + + // Affects how the style building functions are generated. + // + // Several property groups (e.g. color properties) deviate from the default + // style builder application, yet there are enough of these properties that + // we want to generate code for them rather than having manually written + // style builder functions. + style_builder_template: { + valid_values: [ + "animation", + "auto", + "background_layer", + "border_image", + "color", + "counter", + "empty", + "grid", + // The legacy template means that regular code generation should not be + // be performed, and that the property is hard-coded in + // style_builder_functions.cc.tmpl. + "legacy", + "mask_box", + "mask_layer", + "transition", + "visited_color", + ], + }, + + // Additional arguments to 'style_builder_template' may be provided here. + style_builder_template_args: { + default: {}, + valid_type: "dict" + }, + + // - is_descriptor + // Whether it is a CSS descriptor. Descriptors define the characteristics of + // an at-rule. E.g. @font-face is an at-rule, and src is a valid descriptor + // for @font-face. Descriptors and CSS properties with the same name are + // handled together in this file. + // TODO(crbug.com/752745): Don't use CSSPropertyID for descriptors. + // - is_property + // Whether it is a CSS property. If this is false then is_descriptor must be + // true. + is_descriptor: { + default: false, + valid_type: "bool", + }, + is_property: { + default: true, + valid_type: "bool", + }, + + // - independent + // This property affects only one field on ComputedStyle, and can be set + // directly during inheritance instead of forcing a recalc. + // StyleResolver and StyleAdjuster are not invoked when these properties + // are changed on a parent. Recalcs only happen if at least one + // non-independent inherited property is changed in the parent. + independent: { + default: false, + valid_type: "bool", + }, + + // - semi_independent_variable + // This property affects to the {Inherited, NonInherited}Variable data fields so that we + // can assume that the custom properties might not depend on any other property. We can + // handle these properties so that they are excluded from the shared Inherited/NohInherited + // logic, like the Equal and inheritance functions. + semi_independent_variable: { + default: false, + valid_type: "bool", + }, + + // - affected_by_all + // The affected_by_all flag indicates whether a change to the CSS property + // "all" affects this property. + // c.f. https://drafts.csswg.org/css-cascade/#all-shorthand + // Descriptors (is_property: false) are never affected by changes to the + // all property. + affected_by_all: { + default: true, + valid_type: "bool", + }, + + // - interpolable + // The interpolable flag indicates whether a property can be animated + // smoothly. If this flag is set, the property should also be added to the + // switch statements in CSSPropertyEquality and CSSInterpolationTypesMap. + interpolable: { + default: false, + valid_type: "bool", + }, + + // - inherited + // The property will inherit by default if no value is specified, typically + // mentioned in specifications as "Inherited: yes" + inherited: { + default: false, + valid_type: "bool", + }, + + // - compositable + // The property can be animated by the compositor + compositable: { + default: false, + valid_type: "bool", + }, + + // - computable + // + // Whether or not a property appears on CSSStyleDeclaration. + // + // By default a property is computable if it's all of the following: + // + // - Not an alias + // - A property (as opposed to a descriptor) + // - A longhand + // + // Otherwise the property is (by default) _not_ computable. + // + // If an explicit true/false value is provided, this overrides the default, + // and the property unconditionally becomes computable/not-computable + // according to the value specified. + // + // Internal properties (-internal-*) are never computable, and using this + // flag on internal properties is an error. + computable: { + valid_type: "bool", + }, + + // - runtime_flag + // The name of the flag on RuntimeEnabledFeatures + // (e.g. "CSSOverscrollBehavior") that conditionally enables the + // property. + // This doesn't currently work with alias_for. + runtime_flag: { + valid_type: "str", + }, + + // - field_group + // Name of the group that this field belongs to. Fields in the same group + // are stored together as a nested class inside ComputedStyle and + // dynamically allocated on use. + // Leave this out if the field is stored directly on ComputedStyle. + // If you want to auto group this property use: field_group: "*[->subgroup]" + // If you use the auto grouping function check if your property is in + // css_properties_ranking.json5 + // - If yes, only provide: field_group: "*" + // - If no, you can specify a subgroup following the asterisk: + // field_group: "*[->subgroup]" + field_group: { + valid_type: "str", + }, + + // - field_size + // Number of bits needed to store this field. + field_size: { + valid_type: "int", + }, + + // - field_template + // Affects how the interface to this field is generated. + // TODO(sashab, meade): Remove this once TypedOM types are specified for + // every property, since this value can be inferred from that. + field_template: { + valid_values: [ + // Field is stored as an enum and has a initial/getter/setter/resetter. + // If include_paths is empty, we would also generate the corresponding + // enum definition in ComputedStyleConstants.h. + "keyword", + // Field can take on any subset of values from a list of keywords. + "multi_keyword", + // Semantically equivalent to keyword, but the type is represented as a + // bit flag field as with multi_keyword as a performance optimization + // for matching multiple values. + "bitset_keyword", + // Field stores a primitive value like int/bool. The type is specified + // by type_name. The interface has a initial/getter/setter/resetter. + "primitive", + // Field is stored as a bool, whose default value is false + // and can only be set to true. Has a initial/getter/setter. + "monotonic_flag", + // A derived flag is derived from other information on ComputedStyle. + // It has no setters, and is instead calculated on first access by + // the function specified by 'derived_from'. + // + // Derived flags must be marked as 'mutable', and can not have a + // 'field_group' (i.e. must exist on the top level of ComputedStyle). + // + // See computed_style_extra_fields.json5 for examples of derived flags. + "derived_flag", + // Field has type specified at type_name and has a getter/setter. + // Also has a setter taking an rvalue reference. Cannot be packed. + "external", + // Field is stored as a wrapper_pointer_name to a class. + "pointer", + // Preset "length" for external and Length class + // This preset represents alias templates that will be replace by + // entries in CSSFieldAlias.json5. + "<[a-z]+>" + ], + }, + + // - anchor_mode + // Determines whether or not anchor() / anchor-size() queries are allowed + // in the relevant property. + // + // If omitted, no anchor queries are allowed. + // + // See also AnchorScope::Mode. + anchor_mode: { + valid_values: [ + // anchor() + "left", + "right", + "top", + "bottom", + + // anchor-size() + "size", + ] + }, + + // Valid for field_template:derived_flag only. This specifies the function + // on ComputedStyle used to calculate the flag. + derived_from: { + valid_type: "str", + }, + + // - include_paths: ["path/to/file1.h", "path/to/file2.h"] + // List of files containing the definitions of types in 'type_name'. Each of + // these files will appear as a #include in ComputedStyleBase.h. For + // example, if the type_name is 'Vector', include_paths should be + // ["third_party/blink/renderer/platform/wtf/vector.h", + // "third_party/blink/renderer/platform/wtf/text/wtf_string.h"] + include_paths: { + default: [], + }, + + // Name of the pointer type that wraps this field (e.g. scoped_refptr). + wrapper_pointer_name: { + valid_type: "str", + valid_values: ["scoped_refptr", "Member", "std::unique_ptr"], + }, + + // - keywords: ["keyword1", "keyword2"] + // This specifies all valid keyword values for the property. + // TODO(sashab): Once all properties are represented here, delete + // CSSValueKeywords.in and use this list instead. + keywords: { + default: [], + }, + + // - default_value: "keyword-value" + // This specifies the default value for this field. + // - for keyword fields, this is the initial keyword + // - for other fields, this is a string containg the C++ expression + // that is used to initialise the field. + default_value: { + }, + + // Flags which go into CSSOMTypes: + // - typedom_types: ["Keyword", "Type", "OtherType"] + // The property can take types specified in typedom_types for CSS Typed OM. + // - separator + // The property supports a list of values, and when there is more than one, + // it is separated with this character. + typedom_types: { + default: [], + valid_type: "list", + valid_values: [ + "Angle", + "Flex", + "Frequency", + "Keyword", + "Length", + "Number", + "Percentage", + "Position", + "Resolution", + "Time", + "Transform", + "Unparsed", + "Image" + ], + }, + separator: { + valid_values: [",", " ", "/"], + }, + + // The remaining arguments are used for the StyleBuilder and allow us to + // succinctly describe how to apply properties. When default handlers are + // not sufficient, we should prefer to use converter, and failing that + // define custom property handlers in CSSProperty subclasses. We should only + // use style_builder_functions.tmpl to define handlers when there are + // multiple properties requiring the same handling, but converter doesn't + // suffice. + + // - font + // The default property handlers call into the FontBuilder instead of + // setting values directly onto the ComputedStyle + font: { + default: false, + valid_type: "bool", + }, + + // - name_for_methods: "BlendMode" + // Tweaks how we choose defaults for getter, setter, initial and type_name. + // For example, setting this to BlendMode will make us use a setter of + // setBlendMode + // - initial + // The static function to invoke on ComputedStyleInitialValues + // or FontBuilder to retrieve the initial value. + // Defaults to e.g. InitialBorderBottomLeft. + // - getter + // The ComputedStyle getter, defaults to e.g. BorderBottomLeft + // - setter + // The ComputedStyle setter, defaults to e.g. GetBorderBottomLeft + // - type_name + // The computed type for the property. Only required for the default value + // application, defaults to e.g. EDisplay + name_for_methods: { + }, + initial: { + }, + getter: { + }, + setter: { + }, + type_name: { + }, + + // - computed_style_protected_functions + // + // Any function specified in the list will be generated with protected + // visibility. This is useful if the default-generated getter function is + // typically not what clients want to use. + // + // For example, the Clear getter is protected to force clients to take + // TextDirection into account. + computed_style_protected_functions: { + default: [], + valid_type: "list", + valid_values: ["getter", "setter", "resetter"], + }, + + // - computed_style_custom_functions + // + // Any function specified in the list will be generated with protected + // visibility and an "Internal" suffix. A custom accessor (with the suffix- + // less name) must be manually provided on ComputedStyle. This is useful for + // e.g. properties that have special behavior that affects the computed + // value of the property. + // + // For example, the computed value of border-left-width magically becomes + // zero if border-left-style is none or hidden. The generated code can not + // express this, hence a custom one is specified. + // + // Any custom function automatically gets protected visiblity, and therefore + // it is not valid to specify a function as both custom and explicitly + // protected (using computed_style_protected_functions). + computed_style_custom_functions: { + default: [], + valid_type: "list", + valid_values: ["initial", "getter", "setter", "resetter"], + }, + + // - converter: "ConvertRadius" + // The StyleBuilder will call the specified function on + // StyleBuilderConverter to convert a CSSValue to an appropriate platform + // value + converter: { + }, + + // - logical_property_group: used for properties that depend on writing-mode + // and/or text-direction (e.g. css-logical), and for their physical counterparts. + // Represents the "logical property group" described by css-logical + // (https://drafts.csswg.org/css-logical/#logical-property-group). + logical_property_group: { + // A name identifying the logical property group. All logical and physical + // properties in the same group should have the same name. + // + // In terms of code generation, each value corresponds to 2 functions in + // CSSDirectionAwareResolver. E.g. a value of "foo-bar" would correspond to: + // - CSSDirectionAwareResolver::LogicalFooBarMapping(), containing the + // properties of the group with a flow-relative mapping logic. + // - CSSDirectionAwareResolver::PhysicalFooBarMapping(), containing the + // properties of the group with a physical mapping logic. + name: { + valid_type: "str", + valid_values: ["border", "border-color", "border-radius", + "border-style", "border-width", "contain-intrinsic-size", + "inset", "margin", "max-size", "min-size", "overflow", + "padding", "scroll-margin", "scroll-padding", + "scroll-start", "scroll-start-target", "size", + "visited-border-color"], + }, + // The name of the mapping function used to convert between equivalent + // logical and physical properties within the same group. Corresponds to + // a function in CSSDirectionAwareResolver. E.g. a value of "baz" + // corresponds to CSSDirectionAwareResolver::ResolveBaz(...). + // + // Also identifies the mapping logic of the group + // (https://drafts.csswg.org/css-logical-1/#mapping-logic) + resolver: { + valid_type: "str", + valid_values: [ + // Mapping logic: flow-relative (logical) + "block", "inline", + "block-start", "block-end", "inline-start", "inline-end", + "start-start", "start-end", "end-start", "end-end", + // Mapping logic: physical + "vertical", "horizontal", + "top", "bottom", "left", "right", + "top-left", "top-right", "bottom-right", "bottom-left", + ], + }, + }, + + // - surrogate_for: "other-property" + // + // A surrogate is a property which acts like another property. Unlike an + // alias (which is resolved as parse-time), a surrogate exists alongside + // the original in the parsed rule, and in the cascade. + // + // However, surrogates modify the same fields on ComputedStyle. Examples of + // surrogates are: + // + // * -webkit-writing-mode (surrogate of writing-mode) + // * inline-size (surrogate for width, or height) + // * All css-logical properties in general + // + // Note that for properties that use logical_property_group, + // 'surrogate_for' should not be set, as the mapping is determined at + // run-time (depending og e.g. 'direction'). + surrogate_for: { + valid_type: "str", + }, + + // - priority: 1 + // The priority level for computing the property. Properties with the same + // priority level are grouped and computed in alphabetical order. + // Anything above zero are designated "high priority" and done before + // certain operations, like updating fonts. (Most high-priority properties + // are 1; 2 and higher are used only in special circumstances.) This mechanism + // is primarily useful for properties that influence other properties, + // like line-height influencing lh units. Negative values are not used. + priority: { + default: 0, + valid_type: "int", + }, + + // - layout_dependent + // The resolved value used for getComputedStyle() depends on layout for this + // property, which means we may need to update layout to return the correct + // value from getComputedStyle(). Setting this to true will override + // IsLayoutDependentProperty() to return true and require a custom + // IsLayoutDependent() which typically checks for LayoutObject existence and + // type. + layout_dependent: { + default: false, + valid_type: "bool", + }, + + // - visited_property_for: "other-property" + // CSS properties that are allowed in :visited selectors each have an + // internal "companion" property with the visited value. For privacy reasons + // CSSOM APIs must return computed values as if links aren't visited, but + // for rendering purposes we need the value with the :visited rules applied. + // + // This means that the regular property (e.g. background-color) represents + // the value as seen by CSSOM, and the -internal-visited counterpart (e.g. + // -internal-visited-background-color) represents the same property as seen + // by painting. + visited_property_for: { + valid_type: "str", + }, + + // - valid_for_first_letter: true + // + // https://drafts.csswg.org/css-pseudo-4/#first-letter-styling + valid_for_first_letter: { + default: false, + valid_type: "bool", + }, + + // - valid_for_first_line: true + // + // https://drafts.csswg.org/css-pseudo-4/#first-line-styling + valid_for_first_line: { + default: false, + valid_type: "bool", + }, + + // - valid_for_cue: true + // + // https://w3c.github.io/webvtt/#the-cue-pseudo-element + valid_for_cue: { + default: false, + valid_type: "bool", + }, + + // - valid_for_marker: true + // + // https://drafts.csswg.org/css-pseudo-4/#marker-pseudo + valid_for_marker: { + default: false, + valid_type: "bool", + }, + + // - valid_for_highlight_legacy: true + // + // Theoretically matches + // https://drafts.csswg.org/css-pseudo-4/#highlight-styling, + // but includes additional properties for compatibility reasons. + // Applied to highlight pseudos that use originating inheritance + // instead of highlight inheritance. + valid_for_highlight_legacy: { + default: false, + valid_type: "bool", + }, + + // - valid_for_highlight: true + // + // https://drafts.csswg.org/css-pseudo-4/#highlight-styling + valid_for_highlight: { + default: false, + valid_type: "bool", + }, + + // Valid @page properties and descriptors when PageMarginBoxes aren't + // enabled. This is limited to the set of descriptors and properties + // that have an effect when this feature is disabled (essentially page + // size, margins and orientation). + valid_for_limited_page_context: { + default: false, + valid_type: "bool", + }, + + // Applicable @page properties and descriptors. + valid_for_page_context: { + default: false, + valid_type: "bool", + }, + + // - is_border + // The property, when used by the author, will disable any native + // appearance on UI elements. + is_border: { + default: false, + valid_type: "bool", + }, + + // - is_background + // The property, when used by the author, will disable any native + // appearance on UI elements. + is_background: { + default: false, + valid_type: "bool", + }, + + // - is_border_radius + // The property, when used by the author, will disable any native + // appearance on UI elements. + is_border_radius: { + default: false, + valid_type: "bool", + }, + + // - is_highlight_colors + // The property participates in paired cascade, such that when encountered + // in highlight styles, we make all other highlight color properties default + // to initial, rather than the UA default. + // https://drafts.csswg.org/css-pseudo-4/#highlight-cascade + is_highlight_colors: { + default: false, + valid_type: "bool", + }, + // - is_visited_highlight_colors + // Like the previous one but for visited internal properties. + is_visited_highlight_colors: { + default: false, + valid_type: "bool", + }, + + // - is_animation_property + // The property is a longhand of the 'animation' or 'transition' shorthands. + is_animation_property: { + default: false, + valid_type: "bool", + }, + + // Whether changing this property is so independent that we can apply + // a change to them incrementally on top of the old style. This happens + // only when inline style is changed. Conceptually, this could be a blocklist, + // but being conservative, we have chosen to make it an allowlist. + // The properties with known issue are explicitly marked as false, + // so changing the default from false to true _should_ have no ill effects, + // but bugs are of course possible. (There is a DCHECK verifying that we + // computed the correct style when this optimization is in effect.) + // + // Since animations can affect pretty much anything else, and we don't + // support their interactions anyway (see CanApplyInlineStyleIncrementally()), + // animation properties are also never marked as supporting incremental style. + // This is verified in validate_property(). + supports_incremental_style: { + default: false, + valid_type: "bool", + }, + + // If false, this property is known to cause problems if setting + // it on an element's inline style will cause problems with computing + // that element's style incrementally. + // + // NOTE: Setting false here is probably indicative of a bug. Long-term, + // we should fix all of these and remove the flag. + idempotent: { + default: true, + valid_type: "bool", + }, + + // If true, this property will accept a CSSNumericLiteralValue + // (created by a fast-path parser), with no restrictions on range. + // (NaN and infinities will be sent through the normal ParseSingleValue + // path.) A typical case is the properties that can accept an alpha value; + // percent values will take the slow paths, but simple numbers will be sent + // directly through. + accepts_numeric_literal: { + default: false, + valid_type: "bool", + }, + + // If true, then the ComputedStyle field for this property overlaps with + // another property. + // + // Overlapping properties are *partially* overlapping, or do otherwise not + // have compatible or interchangeable values with each other. + overlapping: { + default: false, + valid_type: "bool", + }, + + // Like 'overlapping', but set on -webkit-prefixed properties that should + // ultimately be removed. + // + // Note that properties that are legacy_overlapping are also overlapping + // (i.e. legacy_overlapping:true implies overlapping:true). + legacy_overlapping: { + default: false, + valid_type: "bool", + }, + + // - valid_for_formatted_text: true + // + // Whether the property can be used to style the top-level container + // (similar to display:block, but supporting fewer properties), in the + // experimental API to bring multiline text rendering to HTML canvas. + // https://github.com/WICG/canvas-formatted-text/ + valid_for_formatted_text: { + default: false, + valid_type: "bool", + }, + + // - valid_for_formatted_text_run: true + // + // Whether the property can be used to style individual text runs, in the + // experimental API to bring multiline text rendering to HTML canvas. + valid_for_formatted_text_run: { + default: false, + valid_type: "bool", + }, + + // - valid_for_keyframe: true + // + // Whether the property can be used in @keyframes. + // https://www.w3.org/TR/css-animations-1/#typedef-keyframe-block + valid_for_keyframe: { + default: true, + valid_type: "bool", + }, + + // Whether the property can be applied to elements. + // See https://github.com/WICG/PEPC/blob/main/explainer.md#locking-the-pepc-style + valid_for_permission_element: { + default: false, + valid_type: "bool", + }, + + // - valid_for_position_try: true + // + // Whether the property can be used in a @position-try rule + // https://drafts.csswg.org/css-anchor-1/#fallback-rule + valid_for_position_try: { + default: false, + valid_type: "bool", + }, + + // - affected_by_zoom: true + // + // Whether or not the computed value of this property is affected by + // the effective zoom factor. Generally, all computed values that contain + // a blink::Length are affected by zoom. + // + // Setting this flag to 'true' will change the inheritance behavior + // (Longhand::ApplyInherit) to effectively "rezoom" the inherited value. + // + // https://github.com/w3c/csswg-drafts/issues/9397 + affected_by_zoom: { + default: false, + valid_type: "bool", + }, + }, + + // Members in the data objects should appear in the same order as in the + // parameters object above + data: [ + // Properties with StyleBuilder handling + + // Animation Priority properties + { + name: "animation-composition", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + keywords: ["replace", "add", "accumulate"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "Composition", + }, + typedom_types: ["Keyword"], + separator: ",", + include_paths: ["third_party/blink/renderer/core/animation/effect_model.h"], + default_value: "EffectModel::kCompositeReplace", + type_name: "EffectModel::CompositeOperation", + valid_for_marker: true, + }, + { + name: "animation-delay", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "DelayStart", + }, + typedom_types: ["Time"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + }, + { + name: "-alternative-animation-delay", + alternative_of: "animation-delay", + longhands: [ + "animation-delay-start", "animation-delay-end" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + runtime_flag: "CSSAnimationDelayStartEnd", + }, + { + name: "animation-delay-start", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "DelayStart", + }, + typedom_types: ["Time"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + runtime_flag: "CSSAnimationDelayStartEnd", + }, + { + name: "animation-delay-end", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "DelayEnd", + }, + typedom_types: ["Time"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + runtime_flag: "CSSAnimationDelayStartEnd", + }, + { + name: "animation-direction", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + keywords: ["normal", "reverse", "alternate", "alternate-reverse"], + typedom_types: ["Keyword"], + separator: ",", + style_builder_template: "animation", + style_builder_template_args: { + attribute: "Direction", + }, + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + }, + { + name: "animation-duration", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + separator: ",", + style_builder_template: "animation", + style_builder_template_args: { + attribute: "Duration", + }, + typedom_types: ["Time"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + }, + { + name: "animation-fill-mode", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "FillMode", + }, + keywords: ["none", "forwards", "backwards", "both"], + typedom_types: ["Keyword"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + }, + { + name: "animation-iteration-count", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + keywords: ["infinite"], + separator: ",", + style_builder_template: "animation", + style_builder_template_args: { + attribute: "IterationCount", + }, + keywords: ["infinite"], + typedom_types: ["Keyword", "Number"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + }, + { + // TODO(futhark): Set the TreeScope on CSSAnimationData. + name: "animation-name", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "Name", + }, + keywords: ["none"], + typedom_types: ["Keyword"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + }, + { + name: "animation-play-state", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "PlayState", + }, + keywords: ["running", "paused"], + typedom_types: ["Keyword"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + }, + { + name: "animation-range-start", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "RangeStart", + }, + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + runtime_flag: "ScrollTimeline", + }, + { + name: "animation-range-end", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "RangeEnd", + }, + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + valid_for_keyframe: false, + runtime_flag: "ScrollTimeline", + }, + { + name: "animation-timeline", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "Timeline", + }, + keywords: ["none", "auto"], + typedom_types: ["Keyword"], + separator: ",", + valid_for_marker: true, + runtime_flag: "ScrollTimeline", + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + }, + { + name: "animation-timing-function", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "animation", + style_builder_template_args: { + attribute: "TimingFunction", + }, + keywords: [ + "linear", + "ease", + "ease-in", + "ease-out", + "ease-in-out", + "jump-both", + "jump-end", + "jump-none", + "jump-start", + "step-start", + "step-end" + ], + typedom_types: ["Keyword"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + }, + { + name: "transition-delay", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "transition", + style_builder_template_args: { + attribute: "DelayStart", + }, + typedom_types: ["Time"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + }, + { + name: "transition-duration", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + typedom_types: ["Keyword", "Time"], + separator: ",", + style_builder_template: "transition", + style_builder_template_args: { + attribute: "Duration", + }, + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + }, + { + name: "transition-property", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "transition", + style_builder_template_args: { + attribute: "Property", + }, + keywords: ["none"], + typedom_types: ["Keyword"], + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + }, + { + name: "transition-behavior", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + typedom_types: ["Keyword"], + separator: ",", + style_builder_template: "transition", + style_builder_template_args: { + attribute: "Behavior", + }, + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + runtime_flag: "CSSTransitionDiscrete", + }, + { + name: "transition-timing-function", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "transition", + style_builder_template_args: { + attribute: "TimingFunction", + }, + keywords: [ + "linear", + "ease", + "ease-in", + "ease-out", + "ease-in-out", + "jump-both", + "jump-end", + "jump-none", + "jump-start", + "step-start", + "step-end"], + typedom_types: ["Keyword"], + separator: ",", + valid_for_marker: true, + is_animation_property: true, + // Animation properites are never incremental. + supports_incremental_style: false, + }, + + // High Priority and all other font properties. + // Other properties can depend upon high priority properties + // (e.g. font-size / ems) + { + name: "color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + inherited: true, + // color isn't strictly independent of all other properties; + // it determines currentColor, which in turn can affect the used value of + // other properties (such as border colors, stops in gradients, etc.). + // However, changes to color generally also trigger paint invalidation, + // and paint invalidation resolves the color anew. (For the special case + // of gradient stops, we have logic within ComputedStyle::AdjustDiffForBackgroundVisuallyEqual + // that forces paint invalidation, recomputing the gradient and repainting + // the element.) + independent: true, + field_group: "inherited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor(Color::kBlack)", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + style_builder_custom_functions: ["initial", "inherit", "value"], + priority: 1, + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + is_highlight_colors: true, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "direction", + property_methods: ["CSSValueFromComputedStyleInternal"], + affected_by_all: false, + inherited: true, + field_template: "keyword", + include_paths: ["third_party/blink/renderer/platform/text/text_direction.h"], + keywords: ["ltr", "rtl"], + typedom_types: ["Keyword"], + default_value: "ltr", + type_name: "TextDirection", + style_builder_custom_functions: ["value"], + priority: 1, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_page_context: true, + }, + { + name: "font-family", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + is_descriptor: true, + inherited: true, + font: true, + name_for_methods: "FamilyDescription", + type_name: "FontDescription::FamilyDescription", + style_builder_custom_functions: ["initial", "inherit"], + converter: "ConvertFontFamily", + priority: 1, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_page_context: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "font-kerning", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + name_for_methods: "Kerning", + converter: "ConvertFontKerning", + type_name: "FontDescription::Kerning", + priority: 1, + keywords: ["auto", "normal", "none"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "font-optical-sizing", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + name_for_methods: "FontOpticalSizing", + converter: "ConvertFontOpticalSizing", + type_name: "OpticalSizing", + priority: 1, + keywords: ["auto", "none"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + // See comment on font. + supports_incremental_style: false, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "font-palette", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal" ], + interpolable: true, + inherited: true, + font: true, + converter: "ConvertFontPalette", + type_name: "FontPalette", + priority: 1, + keywords: ["normal", "light", "dark"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_page_context: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "font-size", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + font: true, + name_for_methods: "Size", + getter: "GetSize", + converter: "ConvertFontSize", + priority: 1, + keywords: ["xx-small", "x-small", "small", "medium", "large", "x-large", "xx-large", "xxx-large", "larger", "smaller", "-webkit-xxx-large"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "font-size-adjust", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + runtime_flag: "CSSFontSizeAdjust", + font: true, + name_for_methods: "SizeAdjust", + converter: "ConvertFontSizeAdjust", + priority: 1, + keywords: ["none", "ex-height", "cap-height", "ch-width", "ic-width", "from-font"], + typedom_types: ["Keyword", "Number"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_page_context: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "font-stretch", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + is_descriptor: true, + interpolable: true, + inherited: true, + font: true, + name_for_methods: "Stretch", + converter: "ConvertFontStretch", + priority: 1, + keywords: [ + "normal", "ultra-condensed", "extra-condensed", "condensed", + "semi-condensed", "semi-expanded", "expanded", "extra-expanded", "ultra-expanded" + ], + typedom_types: ["Keyword", "Percentage"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "font-style", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + is_descriptor: true, + interpolable: true, + inherited: true, + font: true, + name_for_methods: "Style", + converter: "ConvertFontStyle", + priority: 1, + keywords: ["normal", "italic", "oblique"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "font-variant-ligatures", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + name_for_methods: "VariantLigatures", + type_name: "VariantLigatures", + converter: "ConvertFontVariantLigatures", + priority: 1, + keywords: [ + "normal", "none", "common-ligatures", "no-common-ligatures", + "discretionary-ligatures", "no-discretionary-ligatures", + "historical-ligatures", "no-historical-ligatures", "contextual", + "no-contextual" + ], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "font-variant-caps", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + name_for_methods: "VariantCaps", + converter: "ConvertFontVariantCaps", + priority: 1, + keywords: [ + "normal", "small-caps", "all-small-caps", "petite-caps", + "all-petite-caps", "unicase", "titling-caps" + ], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "font-variant-east-asian", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + name_for_methods: "VariantEastAsian", + converter: "ConvertFontVariantEastAsian", + priority: 1, + keywords: [ + "normal", "jis78", "jis83", "jis90", "jis04", "simplified", + "traditional", "full-width", "proportional-width", "ruby" + ], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "font-variant-numeric", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + name_for_methods: "VariantNumeric", + converter: "ConvertFontVariantNumeric", + priority: 1, + keywords: [ + "normal", "lining-nums", "oldstyle-nums", "proportional-nums", + "tabular-nums", "diagonal-fractions", "stacked-fractions", "ordinal", + "slashed-zero" + ], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "font-variant-alternates", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + type_name: "FontVariantAlternates", + name_for_methods: "FontVariantAlternates", + converter: "ConvertFontVariantAlternates", + priority: 1, + keywords: [ + "normal", + ], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "font-weight", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + is_descriptor: true, + interpolable: true, + inherited: true, + font: true, + name_for_methods: "Weight", + converter: "ConvertFontWeight", + priority: 1, + keywords: ["normal", "bold", "bolder", "lighter"], + typedom_types: ["Keyword", "Number"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "font-synthesis-weight", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + name_for_methods: "FontSynthesisWeight", + type_name: "FontDescription::FontSynthesisWeight", + priority: 1, + keywords: ["auto", "none"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + // See comment on font. + supports_incremental_style: false, + valid_for_permission_element: true, + }, + { + name: "font-synthesis-style", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + name_for_methods: "FontSynthesisStyle", + type_name: "FontDescription::FontSynthesisStyle", + priority: 1, + keywords: ["auto", "none"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + // See comment on font. + supports_incremental_style: false, + valid_for_permission_element: true, + }, + { + name: "font-synthesis-small-caps", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + name_for_methods: "FontSynthesisSmallCaps", + type_name: "FontDescription::FontSynthesisSmallCaps", + priority: 1, + keywords: ["auto", "none"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + // See comment on font. + supports_incremental_style: false, + valid_for_permission_element: true, + }, + { + name: "font-feature-settings", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + is_descriptor: true, + inherited: true, + font: true, + name_for_methods: "FeatureSettings", + converter: "ConvertFontFeatureSettings", + priority: 1, + keywords: ["normal"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + computable: false, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + valid_for_permission_element: true, + }, + { + name: "font-variation-settings", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + font: true, + name_for_methods: "VariationSettings", + converter: "ConvertFontVariationSettings", + priority: 1, + keywords: ["normal"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + computable: false, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "font-variant-position", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + name_for_methods: "VariantPosition", + type_name: "FontDescription::FontVariantPosition", + converter: "ConvertFontVariantPosition", + priority: 1, + keywords: ["normal", "sub", "super"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "-webkit-font-smoothing", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + type_name: "FontSmoothingMode", + priority: 1, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_permission_element: true, + }, + { + name: "forced-color-adjust", + field_group: "*", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + runtime_flag: "ForcedColors", + field_template: "keyword", + // Affects the computed value of color when it is inherited and + // forced-color- adjust is set to preserve-parent-color. + priority: 2, + keywords: ["auto", "none", "preserve-parent-color"], + typedom_types: ["Keyword"], + default_value: "auto", + valid_for_highlight_legacy: true, + computable: false, + valid_for_permission_element: true, + }, + { + name: "field-sizing", + field_group: "visual", + field_template: "keyword", + property_methods: ["CSSValueFromComputedStyleInternal"], + keywords: ["fixed", "content"], + default_value: "fixed", + typedom_types: ["Keyword"], + runtime_flag: "CssFieldSizing", + }, + { + name: "-webkit-locale", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + style_builder_custom_functions: ["value"], + priority: 1, + }, + { + name: "math-depth", + default_value: 0, + field_group: "*", + field_template: "primitive", + inherited: true, + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_custom_functions: ["value"], + type_name: "short", + typedom_types: ["Number"], + // Affects the computed value of 'font-size', hence needs to happen before + // high-priority properties. + priority: 2, + }, + { + name: "text-orientation", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["sideways", "mixed", "upright"], + typedom_types: ["Keyword"], + default_value: "mixed", + getter: "GetTextOrientation", + style_builder_custom_functions: ["initial", "inherit", "value"], + priority: 1, + computable: false, + valid_for_formatted_text: true, + }, + { + name: "-webkit-text-orientation", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + type_name: "TextOrientation", + priority: 1, + surrogate_for: "text-orientation", + }, + { + name: "writing-mode", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_template: "keyword", + include_paths: ["third_party/blink/renderer/platform/text/writing_mode.h"], + keywords: ["horizontal-tb", "vertical-rl", "vertical-lr"], + typedom_types: ["Keyword"], + default_value: "horizontal-tb", + type_name: "WritingMode", + style_builder_custom_functions: ["initial", "inherit", "value"], + priority: 1, + valid_for_formatted_text: true, + // Incremental code does not call DidChangeWritingMode(), which influences + // the font. + supports_incremental_style: false, + }, + { + name: "-webkit-writing-mode", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + type_name: "WritingMode", + priority: 1, + surrogate_for: "writing-mode", + }, + { + name: "text-rendering", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + type_name: "TextRenderingMode", + keywords: ["auto", "optimizespeed", "optimizelegibility", "geometricprecision"], + typedom_types: ["Keyword"], + priority: 1, + valid_for_permission_element: true, + }, + { + name: "zoom", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "visual", + field_template: "primitive", + default_value: "1.0", + type_name: "float", + style_builder_custom_functions: ["initial", "inherit", "value"], + priority: 1, + // Setting zoom affects the _EffectiveZoom_, which in turns affects every px value + // stored on ComputedStyle; see CSSToLengthConversionData::ZoomedComputedPixels. + supports_incremental_style: false, + valid_for_permission_element: true, + }, + { + name: "accent-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_auto_color.h"], + type_name: "StyleAutoColor", + computed_style_protected_functions: ["getter"], + keywords: ["auto", "currentcolor"], + typedom_types: ["Keyword"], + converter: "ConvertStyleAutoColor", + default_value: "StyleAutoColor::AutoColor()", + computable: true, + }, + { + name: "align-content", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_content_alignment_data.h"], + default_value: "StyleContentAlignmentData(ContentPosition::kNormal, ContentDistributionType::kDefault, OverflowAlignment::kDefault)", + type_name: "StyleContentAlignmentData", + converter: "ConvertContentAlignmentData", + }, + { + name: "align-items", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_self_alignment_data.h"], + default_value: "StyleSelfAlignmentData(ItemPosition::kNormal, OverflowAlignment::kDefault)", + type_name: "StyleSelfAlignmentData", + converter: "ConvertSelfOrDefaultAlignmentData", + }, + { + name: "alignment-baseline", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "svg", + field_template: "keyword", + keywords: ["auto", "baseline", "alphabetic", "ideographic", "middle", + "central", "mathematical", "before-edge", "text-before-edge", + "after-edge", "text-after-edge", "hanging"], + typedom_types: ["Keyword"], + default_value: "auto", + }, + { + name: "align-self", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_self_alignment_data.h"], + default_value: "StyleSelfAlignmentData(ItemPosition::kAuto, OverflowAlignment::kDefault)", + type_name: "StyleSelfAlignmentData", + converter: "ConvertSelfOrDefaultAlignmentData", + valid_for_position_try: true, + valid_for_permission_element: true, + }, + { + name: "anchor-name", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal" ], + include_paths: ["third_party/blink/renderer/core/style/scoped_css_name.h"], + type_name: "ScopedCSSNameList", + wrapper_pointer_name: "Member", + default_value: "nullptr", + field_group: "*", + field_template: "external", + converter: "ConvertAnchorName", + keywords: ["none"], + typedom_types: ["Keyword"], + runtime_flag: "CSSAnchorPositioning", + valid_for_permission_element: true, + }, + { + name: "aspect-ratio", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "surround", + field_template: "external", + keywords: ["auto"], + default_value: "StyleAspectRatio(EAspectRatioType::kAuto, gfx::SizeF())", + type_name: "StyleAspectRatio", + converter: "ConvertAspectRatio", + include_paths: ["third_party/blink/renderer/core/style/style_aspect_ratio.h"], + computable: false, + valid_for_permission_element: true, + }, + { + name: "backdrop-filter", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + compositable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/filter_operations.h"], + default_value: "FilterOperations()", + type_name: "FilterOperations", + computed_style_custom_functions: ["initial"], + style_builder_custom_functions: ["value"], + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "backface-visibility", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["visible", "hidden"], + typedom_types: ["Keyword"], + default_value: "visible", + }, + { + name: "background-attachment", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + keywords: ["scroll", "fixed", "local"], + typedom_types: ["Keyword"], + separator: " ", + style_builder_template: "background_layer", + style_builder_template_args: { + fill_type: "Attachment", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + is_background: true, + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "background-blend-mode", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + keywords: [ + "normal", "multiply", "screen", "overlay", "darken", "lighten", + "color-dodge", "color-burn", "hard-light", "soft-light", "difference", + "exclusion", "hue", "saturation", "color", "luminosity" + ], + typedom_types: ["Keyword"], + separator: " ", + style_builder_template: "background_layer", + style_builder_template_args: { + fill_type: "BlendMode", + fill_type_getter: "GetBlendMode", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + is_background: false, + valid_for_page_context: true, + }, + { + name: "background-clip", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + keywords: ["border-box", "padding-box", "content-box", "text"], + typedom_types: ["Keyword"], + separator: " ", + style_builder_template: "background_layer", + style_builder_template_args: { + fill_type: "Clip", + }, + style_builder_custom_functions: ["value"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + is_background: true, + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "background-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + compositable: true, + field_group: "background", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor(Color::kTransparent)", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + converter: "ConvertStyleColor", + style_builder_template: "color", + style_builder_template_args: { + initial_color: "ComputedStyleInitialValues::InitialBackgroundColor", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + is_background: true, + is_highlight_colors: true, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "background-image", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + keywords: ["auto", "none"], + typedom_types: ["Keyword", "Image"], + separator: " ", + style_builder_template: "background_layer", + style_builder_template_args: { + fill_type: "Image", + fill_type_getter: "GetImage", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + is_background: true, + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "background-origin", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + keywords: ["border-box", "padding-box", "content-box"], + typedom_types: ["Keyword"], + separator: " ", + style_builder_template: "background_layer", + style_builder_template_args: { + fill_type: "Origin", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + is_background: true, + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "background-position-x", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + style_builder_template: "background_layer", + style_builder_template_args: { + fill_type: "PositionX", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + is_background: true, + computable: false, + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "background-position-y", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + style_builder_template: "background_layer", + style_builder_template_args: { + fill_type: "PositionY", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + is_background: true, + computable: false, + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "background-repeat", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_template: "background_layer", + style_builder_template_args: { + fill_type: "Repeat", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "background-size", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + keywords: ["auto", "cover", "contain"], + typedom_types: ["Keyword", "Length", "Percentage"], + separator: " ", + style_builder_template: "background_layer", + style_builder_template_args: { + fill_type: "Size", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + is_background: true, + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "baseline-shift", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->misc", + field_template: "external", + type_name: "Length", + default_value: "Length::Fixed()", + style_builder_custom_functions: ["inherit", "value"], + keywords: ["baseline", "sub", "super"], + typedom_types: ["Keyword", "Percentage", "Length"], + }, + { + name: "baseline-source", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "box", + field_template: "keyword", + default_value: "auto", + keywords: ["auto", "first", "last"], + typedom_types: ["Keyword"], + }, + { + name: "border-bottom-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + field_group: "surround", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-color", + resolver: "bottom", + }, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-bottom-left-radius", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "surround", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length_size.h"], + default_value: "LengthSize(Length::Fixed(0), Length::Fixed(0))", + type_name: "LengthSize", + converter: "ConvertRadius", + typedom_types: ["Length", "Percentage"], + valid_for_first_letter: true, + is_border: true, + is_border_radius: true, + logical_property_group: { + name: "border-radius", + resolver: "bottom-left", + }, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-bottom-right-radius", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "surround", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length_size.h"], + default_value: "LengthSize(Length::Fixed(0), Length::Fixed(0))", + type_name: "LengthSize", + converter: "ConvertRadius", + typedom_types: ["Length", "Percentage"], + valid_for_first_letter: true, + is_border: true, + is_border_radius: true, + logical_property_group: { + name: "border-radius", + resolver: "bottom-right", + }, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-bottom-style", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "box", + field_template: "keyword", + keywords: [ + "none", "hidden", "inset", "groove", "outset", "ridge", "dotted", + "dashed", "solid", "double" + ], + typedom_types: ["Keyword"], + default_value: "none", + type_name: "EBorderStyle", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-style", + resolver: "bottom", + }, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-bottom-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "box", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/layout_unit.h"], + keywords: ["thin", "medium", "thick"], + default_value: "LayoutUnit(3)", + typedom_types: ["Keyword", "Length"], + type_name: "LayoutUnit", + computed_style_custom_functions: ["getter"], + converter: "ConvertBorderWidth", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-width", + resolver: "bottom", + }, + // Overlaps with -webkit-border-image. + overlapping: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-collapse", + property_methods: ["CSSValueFromComputedStyleInternal"], + independent: true, + inherited: true, + field_template: "keyword", + keywords: ["separate", "collapse"], + typedom_types: ["Keyword"], + default_value: "separate", + }, + { + name: "border-image-outset", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + interpolable: true, + typedom_types: ["Length", "Number"], + style_builder_template: "border_image", + style_builder_template_args: { + modifier_type: "Outset", + }, + valid_for_first_letter: true, + is_border: true, + // Overlaps with -webkit-border-image. + overlapping: true, + }, + { + name: "border-image-repeat", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + keywords: ["stretch", "repeat", "round", "space"], + typedom_types: ["Keyword"], + style_builder_template: "border_image", + style_builder_template_args: { + modifier_type: "Repeat", + }, + valid_for_first_letter: true, + is_border: true, + // Overlaps with -webkit-border-image. + overlapping: true, + }, + { + name: "border-image-slice", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + interpolable: true, + typedom_types: ["Number", "Percentage"], + style_builder_template: "border_image", + style_builder_template_args: { + modifier_type: "Slice", + }, + valid_for_first_letter: true, + is_border: true, + // Overlaps with -webkit-border-image. + overlapping: true, + }, + { + name: "border-image-source", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + interpolable: true, + keywords: ["none"], + typedom_types: ["Keyword", "Image"], + style_builder_custom_functions: ["value"], + valid_for_first_letter: true, + is_border: true, + // Overlaps with -webkit-border-image. + overlapping: true, + }, + { + name: "border-image-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + interpolable: true, + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage", "Number"], + style_builder_template: "border_image", + style_builder_template_args: { + modifier_type: "Width", + }, + valid_for_first_letter: true, + is_border: true, + // Overlaps with -webkit-border-image. + overlapping: true, + }, + { + name: "border-left-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + field_group: "surround", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-color", + resolver: "left", + }, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-left-style", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "box", + field_template: "keyword", + keywords: [ + "none", "hidden", "inset", "groove", "outset", "ridge", "dotted", + "dashed", "solid", "double" + ], + typedom_types: ["Keyword"], + default_value: "none", + type_name: "EBorderStyle", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-style", + resolver: "left", + }, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-left-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "box", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/layout_unit.h"], + keywords: ["thin", "medium", "thick"], + default_value: "LayoutUnit(3)", + typedom_types: ["Keyword", "Length"], + type_name: "LayoutUnit", + computed_style_custom_functions: ["getter"], + converter: "ConvertBorderWidth", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-width", + resolver: "left", + }, + // Overlaps with -webkit-border-image. + overlapping: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-right-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + field_group: "surround", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-color", + resolver: "right", + }, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-right-style", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "box", + field_template: "keyword", + keywords: [ + "none", "hidden", "inset", "groove", "outset", "ridge", "dotted", + "dashed", "solid", "double" + ], + typedom_types: ["Keyword"], + default_value: "none", + type_name: "EBorderStyle", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-style", + resolver: "right", + }, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-right-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "box", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/layout_unit.h"], + keywords: ["thin", "medium", "thick"], + default_value: "LayoutUnit(3)", + typedom_types: ["Keyword", "Length"], + type_name: "LayoutUnit", + computed_style_custom_functions: ["getter"], + converter: "ConvertBorderWidth", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-width", + resolver: "right", + }, + // Overlaps with -webkit-border-image. + overlapping: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-top-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + field_group: "surround", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-color", + resolver: "top", + }, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-top-left-radius", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "surround", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length_size.h"], + default_value: "LengthSize(Length::Fixed(0), Length::Fixed(0))", + type_name: "LengthSize", + converter: "ConvertRadius", + typedom_types: ["Length", "Percentage"], + valid_for_first_letter: true, + is_border: true, + is_border_radius: true, + logical_property_group: { + name: "border-radius", + resolver: "top-left", + }, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-top-right-radius", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "surround", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length_size.h"], + default_value: "LengthSize(Length::Fixed(0), Length::Fixed(0))", + type_name: "LengthSize", + converter: "ConvertRadius", + typedom_types: ["Length", "Percentage"], + valid_for_first_letter: true, + is_border: true, + is_border_radius: true, + logical_property_group: { + name: "border-radius", + resolver: "top-right", + }, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-top-style", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "box", + field_template: "keyword", + keywords: [ + "none", "hidden", "inset", "groove", "outset", "ridge", "dotted", + "dashed", "solid", "double" + ], + typedom_types: ["Keyword"], + default_value: "none", + type_name: "EBorderStyle", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-style", + resolver: "top", + }, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-top-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "box", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/layout_unit.h"], + keywords: ["thin", "medium", "thick"], + default_value: "LayoutUnit(3)", + typedom_types: ["Keyword", "Length"], + type_name: "LayoutUnit", + computed_style_custom_functions: ["getter"], + converter: "ConvertBorderWidth", + valid_for_first_letter: true, + is_border: true, + logical_property_group: { + name: "border-width", + resolver: "top", + }, + // Overlaps with -webkit-border-image. + overlapping: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "bottom", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "surround", + field_template: "", + keywords: ["auto"], + default_value: "Length()", + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthOrAuto", + anchor_mode: "bottom", + logical_property_group: { + name: "inset", + resolver: "bottom", + }, + supports_incremental_style: true, + valid_for_position_try: true, + valid_for_permission_element: true, + }, + { + name: "box-shadow", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "pointer", + include_paths: ["third_party/blink/renderer/core/style/shadow_list.h"], + wrapper_pointer_name: "scoped_refptr", + default_value: "nullptr", + type_name: "ShadowList", + converter: "ConvertShadowList", + keywords: ["none"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + }, + { + name: "box-sizing", + property_methods: ["CSSValueFromComputedStyleInternal"], + // NOTE: Naturally fits into field_group: "box", but is so commonly set + // that is is better to have it at the root. + field_template: "keyword", + keywords: ["content-box", "border-box"], + typedom_types: ["Keyword"], + default_value: "content-box", + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "break-after", + property_methods: ["CSSValueFromComputedStyleInternal"], + // Storage for this property also covers these legacy properties: + // page-break-after, -webkit-column-break-after + field_template: "keyword", + keywords: [ + "auto", "avoid", "avoid-column", "avoid-page", "column", "left", "page", + "recto", "right", "verso" + ], + typedom_types: ["Keyword"], + default_value: "auto", + type_name: "EBreakBetween", + }, + { + name: "break-before", + property_methods: ["CSSValueFromComputedStyleInternal"], + // Storage for this property also covers these legacy properties: + // page-break-before, -webkit-column-break-before + field_template: "keyword", + keywords: [ + "auto", "avoid", "avoid-column", "avoid-page", "column", "left", "page", + "recto", "right", "verso" + ], + typedom_types: ["Keyword"], + default_value: "auto", + type_name: "EBreakBetween", + }, + { + name: "break-inside", + property_methods: ["CSSValueFromComputedStyleInternal"], + // Storage for this property also covers these legacy properties: + // page-break-inside, -webkit-column-break-inside + field_template: "keyword", + keywords: ["auto", "avoid", "avoid-column", "avoid-page"], + typedom_types: ["Keyword"], + default_value: "auto", + }, + { + name: "buffered-rendering", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "svg", + field_template: "keyword", + keywords: ["auto", "dynamic", "static"], + default_value: "auto", + }, + { + name: "caption-side", + property_methods: ["CSSValueFromComputedStyleInternal"], + independent: true, + inherited: true, + field_template: "keyword", + keywords: ["top", "bottom"], + typedom_types: ["Keyword"], + default_value: "top", + }, + { + name: "caret-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_auto_color.h"], + default_value: "StyleAutoColor::AutoColor()", + type_name: "StyleAutoColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleAutoColor", + keywords: ["auto", "currentcolor"], + typedom_types: ["Keyword"], + valid_for_highlight_legacy: true, + }, + { + name: "clear", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + computed_style_protected_functions: ["getter"], + keywords: ["none", "left", "right", "both", "inline-start", "inline-end"], + typedom_types: ["Keyword"], + default_value: "none", + valid_for_permission_element: true, + }, + { + name: "clip", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "visual", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length_box.h"], + default_value: "LengthBox()", + type_name: "LengthBox", + computed_style_custom_functions: ["setter"], + style_builder_template: "auto", + converter: "ConvertClip", + keywords: ["auto"], + typedom_types: ["Keyword"], + }, + { + name: "clip-path", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + compositable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/clip_path_operation.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + type_name: "ClipPathOperation", + computed_style_custom_functions: ["getter", "setter"], + converter: "ConvertClipPath", + keywords: ["border-box", "padding-box", "content-box", "margin-box", "fill-box", "stroke-box", "view-box", "none"], + typedom_types: ["Keyword"], + }, + { + name: "clip-rule", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg", + // TODO(fs): Convert this to a keyword (requires enum massage). + field_template: "primitive", + field_size: 1, + include_paths: ["third_party/blink/renderer/platform/graphics/graphics_types.h"], + type_name: "WindRule", + keywords: ["nonzero", "evenodd"], + default_value: "RULE_NONZERO", + typedom_types: ["Keyword"], + }, + { + name: "color-interpolation", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg", + field_template: "keyword", + type_name: "EColorInterpolation", + keywords: ["auto", "srgb", "linearrgb"], + default_value: "srgb", + typedom_types: ["Keyword"], + }, + { + name: "color-interpolation-filters", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg", + field_template: "keyword", + type_name: "EColorInterpolation", + keywords: ["auto", "srgb", "linearrgb"], + default_value: "linearrgb", + typedom_types: ["Keyword"], + }, + { + name: "color-rendering", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg", + field_template: "keyword", + keywords: ["auto", "optimizespeed", "optimizequality"], + default_value: "auto", + typedom_types: ["Keyword"], + }, + { + name: "color-scheme", + field_group: "*", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_custom_functions: ["initial", "inherit", "value"], + inherited: true, + include_paths: ["third_party/blink/public/mojom/frame/color_scheme.mojom-blink.h"], + type_name: "Vector", + default_value: "Vector()", + field_template: "external", + valid_for_highlight_legacy: true, + computable: false, + // Affects the computed value of 'color', hence needs to happen before + // high-priority properties. + priority: 2, + valid_for_permission_element: true, + }, + { + name: "column-fill", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["balance", "auto"], + default_value: "balance", + getter: "GetColumnFill", + typedom_types: ["Keyword"], + computable: false, + }, + { + name: "contain", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_size: 5, + field_template: "primitive", + default_value: "kContainsNone", + name_for_methods: "Contain", + type_name: "unsigned", + converter: "ConvertFlags", + keywords: ["none", "strict", "content", "size", "layout", "style", "paint", "inline-size", "block-size"], + typedom_types: ["Keyword"], + computable: false, + valid_for_permission_element: true, + }, + { + name: "contain-intrinsic-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "surround", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_intrinsic_length.h"], + keywords: ["none"], + default_value: "StyleIntrinsicLength()", + type_name: "StyleIntrinsicLength", + converter: "ConvertIntrinsicDimension", + valid_for_permission_element: true, + }, + { + name: "contain-intrinsic-height", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "surround", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_intrinsic_length.h"], + keywords: ["none"], + default_value: "StyleIntrinsicLength()", + type_name: "StyleIntrinsicLength", + converter: "ConvertIntrinsicDimension", + valid_for_permission_element: true, + }, + { + name: "container-name", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + type_name: "ScopedCSSNameList", + wrapper_pointer_name: "Member", + default_value: "nullptr", + field_group: "*", + field_template: "external", + converter: "ConvertContainerName", + keywords: ["none"], + typedom_types: ["Keyword"], + valid_for_permission_element: true, + }, + { + name: "container-type", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + keywords: ["normal", "inline-size", "size", "scroll-state"], + field_group: "*", + field_size: 3, + field_template: "primitive", + default_value: "kContainerTypeNormal", + type_name: "unsigned", + converter: "ConvertFlags", + typedom_types: ["Keyword"], + valid_for_permission_element: true, + }, + { + name: "content", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/content_data.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + separator: ",", + type_name: "ContentData", + computed_style_custom_functions: ["getter"], + style_builder_custom_functions: ["initial", "inherit", "value"], + valid_for_marker: true, + supports_incremental_style: true, + }, + { + name: "counter-increment", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_template: "counter", + style_builder_template_args: { + action: "Increment", + }, + keywords: ["none"], + typedom_types: ["Keyword"], + computable: false, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "counter-reset", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_template: "counter", + style_builder_template_args: { + action: "Reset", + }, + keywords: ["none"], + typedom_types: ["Keyword"], + computable: false, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "counter-set", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_template: "counter", + style_builder_template_args: { + action: "Set", + }, + keywords: ["none"], + typedom_types: ["Keyword"], + computable: false, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "cursor", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_template: "keyword", + keywords: [ + "auto", "default", "none", "context-menu", "help", "pointer", + "progress", "wait", "cell", "crosshair", "text", "vertical-text", + "alias", "copy", "move", "no-drop", "not-allowed", "e-resize", + "n-resize", "ne-resize", "nw-resize", "s-resize", "se-resize", + "sw-resize", "w-resize", "ew-resize", "ns-resize", "nesw-resize", + "nwse-resize", "col-resize", "row-resize", "all-scroll", "zoom-in", + "zoom-out", "grab", "grabbing" + ], + default_value: "auto", + style_builder_custom_functions: ["initial", "inherit", "value"], + typedom_types: ["Keyword"], + valid_for_highlight_legacy: true, + }, + { + name: "cx", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->geometry", + field_template: "", + default_value: "Length::Fixed()", + typedom_types: ["Length", "Percentage"], + converter: "ConvertLength", + supports_incremental_style: true, + }, + { + name: "cy", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->geometry", + field_template: "", + default_value: "Length::Fixed()", + typedom_types: ["Length", "Percentage"], + converter: "ConvertLength", + supports_incremental_style: true, + }, + { + name: "d", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->geometry", + field_template: "pointer", + include_paths: ["third_party/blink/renderer/core/style/style_path.h"], + wrapper_pointer_name: "scoped_refptr", + type_name: "StylePath", + default_value: "nullptr", + converter: "ConvertPathOrNone", + keywords: ["none"], + typedom_types: ["Keyword"], + supports_incremental_style: true, + }, + { + name: "display", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + keywords: [ + "inline", "block", "list-item", "inline-block", "table", "inline-table", + "table-row-group", "table-header-group", "table-footer-group", + "table-row", "table-column-group", "table-column", "table-cell", + "table-caption", "-webkit-box", "-webkit-inline-box", "flex", + "inline-flex", "grid", "inline-grid", "contents", "flow-root", "none", + "flow", "math", "ruby", "ruby-text" + ], + typedom_types: ["Keyword"], + style_builder_custom_functions: ["initial", "inherit", "value"], + // In general many things are tweaked after-the-fact based on display/float/position + // (e.g. OriginalDisplay is based on display, and setting float can cause blockification), + // so we turn off incremental style for all them all. + supports_incremental_style: false, + valid_for_permission_element: true, + }, + { + name: "dominant-baseline", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg", + field_template: "keyword", + keywords: ["auto", "alphabetic", "ideographic", "middle", "central", "mathematical", "hanging", + "use-script", "no-change", "reset-size", "text-after-edge", "text-before-edge"], + default_value: "auto", + typedom_types: ["Keyword"], + }, + { + name: "empty-cells", + property_methods: ["CSSValueFromComputedStyleInternal"], + independent: true, + inherited: true, + field_template: "keyword", + keywords: ["show", "hide"], + typedom_types: ["Keyword"], + default_value: "show", + }, + { + name: "fill", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + inherited: true, + field_group: "svg->fill", + field_template: "external", + type_name: "SVGPaint", + include_paths: ["third_party/blink/renderer/core/style/svg_paint.h"], + default_value: "SVGPaint(Color::kBlack)", + name_for_methods: "FillPaint", + converter: "ConvertSVGPaint", + style_builder_template: "color", + style_builder_template_args: { + initial_color: "ComputedStyleInitialValues::InitialFillPaint", + }, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "fill-opacity", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "svg->fill", + field_template: "primitive", + type_name: "float", + default_value: "1", + converter: "ConvertAlpha", + typedom_types: ["Number"], + accepts_numeric_literal: true, + }, + { + name: "fill-rule", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg", + // TODO(fs): Convert this to a keyword (requires enum massage). + field_template: "primitive", + field_size: 1, + include_paths: ["third_party/blink/renderer/platform/graphics/graphics_types.h"], + type_name: "WindRule", + keywords: ["nonzero", "evenodd"], + default_value: "RULE_NONZERO", + typedom_types: ["Keyword"], + }, + { + name: "filter", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + compositable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/filter_operations.h"], + default_value: "FilterOperations()", + type_name: "FilterOperations", + computed_style_custom_functions: ["initial"], + style_builder_custom_functions: ["value"], + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "flex-basis", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "", + default_value: "Length::Auto()", + converter: "ConvertLengthSizing", + typedom_types: ["Keyword", "Length", "Percentage"], + keywords: ["auto", "fit-content", "min-content", "max-content", "content"], + valid_for_permission_element: true, + }, + { + name: "flex-direction", + property_methods: ["CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*", + field_template: "keyword", + typedom_types: ["Keyword"], + keywords: ["row", "row-reverse", "column", "column-reverse"], + default_value: "row", + valid_for_permission_element: true, + }, + { + name: "flex-grow", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "primitive", + default_value: "0.0f", + type_name: "float", + typedom_types: ["Number"], + valid_for_permission_element: true, + }, + { + name: "flex-shrink", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "primitive", + default_value: "1.0f", + type_name: "float", + typedom_types: ["Number"], + valid_for_permission_element: true, + }, + { + name: "flex-wrap", + property_methods: ["CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*", + field_template: "keyword", + typedom_types: ["Keyword"], + keywords: ["nowrap", "wrap", "wrap-reverse"], + default_value: "nowrap", + valid_for_permission_element: true, + }, + { + name: "float", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + computed_style_protected_functions: ["getter"], + keywords: ["none", "left", "right", "inline-start", "inline-end"], + typedom_types: ["Keyword"], + default_value: "none", + name_for_methods: "Floating", + type_name: "EFloat", + valid_for_first_letter: true, + // See comment on display. + supports_incremental_style: false, + valid_for_permission_element: true, + }, + { + name: "flood-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + field_group: "svg->misc", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor(Color::kBlack)", + type_name: "StyleColor", + style_builder_template: "color", + style_builder_template_args: { + initial_color: "ComputedStyleInitialValues::InitialFloodColor", + }, + converter: "ConvertStyleColor", + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + supports_incremental_style: true, + }, + { + name: "flood-opacity", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->misc", + field_template: "primitive", + type_name: "float", + default_value: "1", + converter: "ConvertAlpha", + typedom_types: ["Number"], + supports_incremental_style: true, + accepts_numeric_literal: true, + }, + { + name: "grid-auto-columns", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/grid_track_list.h"], + default_value: "NGGridTrackList(GridTrackSize(Length::Auto()))", + type_name: "NGGridTrackList", + converter: "ConvertGridTrackSizeList", + keywords: ["auto", "min-content", "max-content"], + typedom_types: ["Keyword", "Length", "Percentage", "Flex"], + separator: " ", + }, + { + name: "grid-auto-flow", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*", + field_size: 4, // FIXME: Make this use "kGridAutoFlowBits". + field_template: "primitive", + default_value: "kAutoFlowRow", + type_name: "GridAutoFlow", + computed_style_custom_functions: ["getter"], + converter: "ConvertGridAutoFlow", + keywords: ["row", "column"], + typedom_types: ["Keyword"], + }, + { + name: "grid-auto-rows", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/grid_track_list.h"], + default_value: "NGGridTrackList(GridTrackSize(Length::Auto()))", + type_name: "NGGridTrackList", + converter: "ConvertGridTrackSizeList", + keywords: ["auto", "min-content", "max-content"], + typedom_types: ["Keyword", "Length", "Percentage", "Flex"], + separator: " ", + }, + { + name: "grid-column-end", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/grid_position.h"], + default_value: "GridPosition()", + type_name: "GridPosition", + keywords: ["auto"], + typedom_types: ["Keyword"], + converter: "ConvertGridPosition", + }, + { + name: "grid-column-start", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/grid_position.h"], + default_value: "GridPosition()", + type_name: "GridPosition", + keywords: ["auto"], + typedom_types: ["Keyword"], + converter: "ConvertGridPosition", + }, + { + name: "grid-row-end", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/grid_position.h"], + default_value: "GridPosition()", + type_name: "GridPosition", + keywords: ["auto"], + typedom_types: ["Keyword"], + converter: "ConvertGridPosition", + }, + { + name: "grid-row-start", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/grid_position.h"], + default_value: "GridPosition()", + type_name: "GridPosition", + keywords: ["auto"], + typedom_types: ["Keyword"], + converter: "ConvertGridPosition", + }, + { + name: "grid-template-areas", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/computed_grid_template_areas.h"], + type_name: "ComputedGridTemplateAreas", + wrapper_pointer_name: "Member", + default_value: "nullptr", + keywords: ["none"], + typedom_types: ["Keyword"], + converter: "ConvertGridTemplateAreas", + }, + { + name: "grid-template-columns", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + layout_dependent: true, + field_group: "*->grid", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/computed_grid_track_list.h"], + interpolable: true, + default_value: "ComputedGridTrackList()", + type_name: "ComputedGridTrackList", + style_builder_template: "grid", + style_builder_template_args: { + type: "Column", + }, + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "grid-template-rows", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + layout_dependent: true, + field_group: "*->grid", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/computed_grid_track_list.h"], + interpolable: true, + default_value: "ComputedGridTrackList()", + type_name: "ComputedGridTrackList", + style_builder_template: "grid", + style_builder_template_args: { + type: "Row", + }, + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "height", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "box", + field_template: "", + keywords: ["auto", "fit-content", "min-content", "max-content"], + default_value: "Length()", + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthSizing", + anchor_mode: "size", + logical_property_group: { + name: "size", + resolver: "vertical", + }, + supports_incremental_style: true, + valid_for_formatted_text: true, + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "hyphenate-limit-chars", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "external", + keywords: ["auto"], + type_name: "StyleHyphenateLimitChars", + default_value: "StyleHyphenateLimitChars()", + include_paths: ["third_party/blink/renderer/core/style/style_hyphenate_limit_chars.h"], + converter: "ConvertHyphenateLimitChars", + }, + { + name: "popover-show-delay", + runtime_flag: "HTMLPopoverActionHover", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "primitive", + type_name: "float", + interpolable: true, + typedom_types: ["Time"], + converter: "ConvertTimeValue", + default_value: "0.5", + supports_incremental_style: true, + }, + { + name: "popover-hide-delay", + runtime_flag: "HTMLPopoverActionHover", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "primitive", + type_name: "float", + interpolable: true, + typedom_types: ["Time"], + converter: "ConvertTimeValue", + default_value: "HUGE_VALF", + supports_incremental_style: true, + }, + { + name: "hyphens", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["none", "manual", "auto"], + default_value: "manual", + type_name: "Hyphens", + typedom_types: ["Keyword"], + valid_for_marker: true, + }, + { + name: "image-rendering", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: [ + "auto", "optimizespeed", "optimizequality", + "-webkit-optimize-contrast", "pixelated" + ], + typedom_types: ["Keyword"], + default_value: "auto", + }, + { + name: "image-orientation", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "primitive", + field_size: 1, + type_name: "RespectImageOrientationEnum", + default_value: "kRespectImageOrientation", + converter: "ConvertImageOrientation", + include_paths: [ + "third_party/blink/renderer/platform/graphics/image_orientation.h" + ], + }, + { + name: "dynamic-range-limit", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + runtime_flag: "CSSDynamicRangeLimit", + converter: "ConvertDynamicRangeLimit", + type_name: "DynamicRangeLimit", + field_group: "*", + field_template: "external", + keywords: ["standard", "high", "constrained-high"], + typedom_types: ["Keyword"], + include_paths: ["third_party/blink/renderer/platform/graphics/graphics_types.h"], + default_value: "DynamicRangeLimit(cc::PaintFlags::DynamicRangeLimit::kHigh)", + }, + { + name: "initial-letter", + converter: "ConvertInitialLetter", + default_value: "StyleInitialLetter()", + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_initial_letter.h"], + inherited: false, + keywords: ["drop", "normal", "raise"], + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + type_name: "StyleInitialLetter", + valid_for_first_letter: true, + }, + { + name: "isolation", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["auto", "isolate"], + typedom_types: ["Keyword"], + default_value: "auto", + valid_for_permission_element: true, + }, + { + name: "justify-content", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_content_alignment_data.h"], + default_value: "StyleContentAlignmentData(ContentPosition::kNormal, ContentDistributionType::kDefault, OverflowAlignment::kDefault)", + type_name: "StyleContentAlignmentData", + converter: "ConvertContentAlignmentData", + }, + { + name: "justify-items", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_self_alignment_data.h"], + default_value: "StyleSelfAlignmentData(ItemPosition::kLegacy, OverflowAlignment::kDefault)", + type_name: "StyleSelfAlignmentData", + converter: "ConvertSelfOrDefaultAlignmentData", + }, + { + name: "justify-self", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_self_alignment_data.h"], + default_value: "StyleSelfAlignmentData(ItemPosition::kAuto, OverflowAlignment::kDefault)", + type_name: "StyleSelfAlignmentData", + converter: "ConvertSelfOrDefaultAlignmentData", + valid_for_position_try: true, + valid_for_permission_element: true, + }, + { + name: "left", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "surround", + field_template: "", + keywords: ["auto"], + default_value: "Length()", + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthOrAuto", + anchor_mode: "left", + logical_property_group: { + name: "inset", + resolver: "left", + }, + supports_incremental_style: true, + valid_for_position_try: true, + valid_for_permission_element: true, + }, + { + name: "letter-spacing", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + converter: "ConvertSpacing", + keywords: ["normal"], + typedom_types: ["Keyword", "Length"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "lighting-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + field_group: "svg->misc", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor(Color::kWhite)", + type_name: "StyleColor", + style_builder_template: "color", + style_builder_template_args: { + initial_color: "ComputedStyleInitialValues::InitialLightingColor", + }, + converter: "ConvertStyleColor", + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + }, + { + name: "line-height", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "inherited", + field_template: "", + default_value: "Length::Auto()", + getter: "SpecifiedLineHeight", + computed_style_custom_functions: ["getter"], + converter: "ConvertLineHeight", + keywords: ["normal"], + typedom_types: ["Keyword", "Length", "Number", "Percentage"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + valid_for_page_context: true, + affected_by_zoom: true, + }, + { + name: "list-style-image", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_image.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + typedom_types: ["Keyword", "Image"], + type_name: "StyleImage", + style_builder_custom_functions: ["value"], + keywords: ["none"], + }, + { + name: "list-style-position", + property_methods: ["CSSValueFromComputedStyleInternal"], + independent: true, + inherited: true, + field_template: "keyword", + keywords: ["outside", "inside"], + typedom_types: ["Keyword"], + default_value: "outside", + }, + { + name: "list-style-type", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/keywords.h", + "third_party/blink/renderer/core/style/list_style_type_data.h"], + wrapper_pointer_name: "Member", + default_value: "ListStyleTypeData::CreateCounterStyle(keywords::kDisc, nullptr)", + type_name: "ListStyleTypeData", + keywords: [ + "disc", "circle", "square", "disclosure-open", "disclosure-closed", + "decimal", "none" + ], + style_builder_custom_functions: ["value"], + }, + { + name: "margin-bottom", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "box", + field_template: "", + default_value: "Length::Fixed()", + converter: "ConvertQuirkyLength", + computed_style_custom_functions: ["setter"], + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_position_try: true, + logical_property_group: { + name: "margin", + resolver: "bottom", + }, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "margin-left", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "box", + field_template: "", + default_value: "Length::Fixed()", + converter: "ConvertQuirkyLength", + computed_style_custom_functions: ["setter"], + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_position_try: true, + logical_property_group: { + name: "margin", + resolver: "left", + }, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "margin-right", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "box", + field_template: "", + default_value: "Length::Fixed()", + converter: "ConvertQuirkyLength", + computed_style_custom_functions: ["setter"], + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_position_try: true, + logical_property_group: { + name: "margin", + resolver: "right", + }, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "margin-top", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "box", + field_template: "", + default_value: "Length::Fixed()", + converter: "ConvertQuirkyLength", + computed_style_custom_functions: ["setter"], + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_position_try: true, + logical_property_group: { + name: "margin", + resolver: "top", + }, + supports_incremental_style: true, + valid_for_permission_element: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "marker-end", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg->inherited_resources", + field_template: "pointer", + type_name: "StyleSVGResource", + include_paths: ["third_party/blink/renderer/core/style/style_svg_resource.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + name_for_methods: "MarkerEndResource", + converter: "ConvertElementReference", + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "marker-mid", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg->inherited_resources", + field_template: "pointer", + type_name: "StyleSVGResource", + include_paths: ["third_party/blink/renderer/core/style/style_svg_resource.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + name_for_methods: "MarkerMidResource", + converter: "ConvertElementReference", + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "marker-start", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg->inherited_resources", + field_template: "pointer", + type_name: "StyleSVGResource", + include_paths: ["third_party/blink/renderer/core/style/style_svg_resource.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + name_for_methods: "MarkerStartResource", + converter: "ConvertElementReference", + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "mask", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "svg", + field_template: "pointer", + type_name: "StyleSVGResource", + include_paths: ["third_party/blink/renderer/core/style/style_svg_resource.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + name_for_methods: "MaskerResource", + converter: "ConvertElementReference", + computable: false, + }, + { + name: "mask-type", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "svg", + field_template: "keyword", + keywords: ["luminance", "alpha"], + typedom_types: ["Keyword"], + default_value: "luminance", + }, + { + name: "math-shift", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + inherited: true, + keywords: ["normal", "compact"], + typedom_types: ["Keyword"], + default_value: "normal", + }, + { + name: "math-style", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + inherited: true, + keywords: ["normal", "compact"], + typedom_types: ["Keyword"], + default_value: "normal", + }, + { + name: "max-height", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "box", + field_template: "", + default_value: "Length::None()", + converter: "ConvertLengthMaxSizing", + anchor_mode: "size", + keywords: ["none"], + typedom_types: ["Keyword", "Length", "Percentage"], + logical_property_group: { + name: "max-size", + resolver: "vertical", + }, + supports_incremental_style: true, + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "max-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "box", + field_template: "", + default_value: "Length::None()", + converter: "ConvertLengthMaxSizing", + anchor_mode: "size", + keywords: ["none"], + typedom_types: ["Keyword", "Length", "Percentage"], + logical_property_group: { + name: "max-size", + resolver: "horizontal", + }, + supports_incremental_style: true, + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "min-height", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "box", + field_template: "", + default_value: "Length()", + converter: "ConvertLengthSizing", + anchor_mode: "size", + typedom_types: ["Length", "Percentage"], + logical_property_group: { + name: "min-size", + resolver: "vertical", + }, + supports_incremental_style: true, + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "min-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "box", + field_template: "", + default_value: "Length()", + converter: "ConvertLengthSizing", + anchor_mode: "size", + typedom_types: ["Length", "Percentage"], + logical_property_group: { + name: "min-size", + resolver: "horizontal", + }, + supports_incremental_style: true, + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "mix-blend-mode", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + include_paths: ["third_party/blink/renderer/platform/graphics/graphics_types.h"], + keywords: [ + "normal", "multiply", "screen", "overlay", "darken", "lighten", + "color-dodge", "color-burn", "hard-light", "soft-light", "difference", + "exclusion", "hue", "saturation", "color", "luminosity", "plus-lighter" + ], + typedom_types: ["Keyword"], + default_value: "normal", + name_for_methods: "BlendMode", + type_name: "BlendMode", + }, + { + name: "object-fit", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["fill", "contain", "cover", "none", "scale-down"], + typedom_types: ["Keyword"], + default_value: "fill", + getter: "GetObjectFit", + }, + { + name: "object-position", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length_point.h"], + default_value: "LengthPoint(Length::Percent(50.0), Length::Percent(50.0))", + type_name: "LengthPoint", + converter: "ConvertPosition", + typedom_types: ["Keyword", "Position"], + }, + { + name: "object-view-box", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "pointer", + include_paths: ["third_party/blink/renderer/core/style/basic_shapes.h"], + wrapper_pointer_name: "scoped_refptr", + default_value: "nullptr", + type_name: "BasicShape", + converter: "ConvertObjectViewBox", + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "offset-anchor", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + runtime_flag: "CSSOffsetPositionAnchor", + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length_point.h"], + default_value: "LengthPoint(Length::Auto(), Length::Auto())", + type_name: "LengthPoint", + converter: "ConvertPositionOrAuto", + keywords: ["auto"], + typedom_types: ["Keyword", "Position"], + }, + { + name: "offset-distance", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "", + default_value: "Length::Fixed(0)", + converter: "ConvertLength", + typedom_types: ["Length", "Percentage"], + }, + { + name: "offset-path", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "pointer", + include_paths: ["third_party/blink/renderer/core/style/offset_path_operation.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + type_name: "OffsetPathOperation", + converter: "ConvertOffsetPath", + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "offset-position", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + runtime_flag: "CSSOffsetPositionAnchor", + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length_point.h"], + default_value: "LengthPoint(Length::None(), Length::None())", + type_name: "LengthPoint", + converter: "ConvertOffsetPosition", + keywords: ["auto", "normal"], + typedom_types: ["Keyword", "Position"], + }, + { + name: "offset-rotate", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/style_offset_rotation.h"], + default_value: "StyleOffsetRotation(0, OffsetRotationType::kAuto)", + type_name: "StyleOffsetRotation", + converter: "ConvertOffsetRotate", + keywords: ["auto", "reverse"], + typedom_types: ["Keyword", "Angle"], + }, + { + name: "opacity", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + compositable: true, + field_group: "*", + field_template: "primitive", + default_value: "1.0", + type_name: "float", + computed_style_custom_functions: ["setter"], + typedom_types: ["Number"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + supports_incremental_style: true, + accepts_numeric_literal: true, + }, + { + name: "order", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "primitive", + default_value: "0", + type_name: "int", + typedom_types: ["Number"], + valid_for_permission_element: true, + }, + { + // This property is used for testing with origin trial intergration only. + // It should never be web-exposed. + name: "origin-trial-test-property", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + default_value: "normal", + keywords: ["normal", "none"], + typedom_types: ["Keyword"], + runtime_flag: "OriginTrialsSampleAPI", + computable: false, + }, + { + name: "orphans", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "primitive", + computed_style_custom_functions: ["setter"], + default_value: "2", + type_name: "short", + typedom_types: ["Number"], + valid_for_permission_element: true, + }, + { + name: "outline-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_cue: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "outline-offset", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/layout_unit.h"], + default_value: "LayoutUnit()", + type_name: "LayoutUnit", + converter: "ConvertLayoutUnit", + typedom_types: ["Length"], + valid_for_cue: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "outline-style", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: [ + "none", "hidden", "inset", "groove", "outset", "ridge", "dotted", + "dashed", "solid", "double" + ], + typedom_types: ["Keyword"], + default_value: "none", + type_name: "EBorderStyle", + style_builder_custom_functions: ["initial", "inherit", "value"], + valid_for_cue: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "outline-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/layout_unit.h"], + default_value: "LayoutUnit(3)", + type_name: "LayoutUnit", + computed_style_custom_functions: ["getter"], + converter: "ConvertBorderWidth", + keywords: ["thin", "medium", "thick"], + typedom_types: ["Keyword", "Length"], + valid_for_cue: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "overflow-anchor", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: false, + field_template: "keyword", + keywords: [ + "visible", "none", "auto" + ], + typedom_types: ["Keyword"], + default_value: "auto", + valid_for_permission_element: true, + }, + { + name: "overflow-wrap", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["normal", "break-word", "anywhere"], + default_value: "normal", + typedom_types: ["Keyword"], + valid_for_marker: true, + }, + { + name: "overflow-inline", + logical_property_group: { + name: "overflow", + resolver: "inline", + }, + runtime_flag: "CSSLogicalOverflow", + // See comment on overflow-x. + supports_incremental_style: false, + }, + { + name: "-internal-overflow-inline", + logical_property_group: { + name: "overflow", + resolver: "inline", + }, + }, + { + name: "overflow-block", + logical_property_group: { + name: "overflow", + resolver: "block", + }, + runtime_flag: "CSSLogicalOverflow", + // See comment on overflow-x. + supports_incremental_style: false, + }, + { + name: "-internal-overflow-block", + logical_property_group: { + name: "overflow", + resolver: "block", + }, + }, + { + name: "overflow-clip-margin", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_template: "external", + field_group: "*", + include_paths: ["third_party/blink/renderer/core/style/style_overflow_clip_margin.h"], + keywords: ["border-box", "content-box", "padding-box"], + separator: " ", + default_value: "std::nullopt", + type_name: "std::optional", + converter: "ConvertOverflowClipMargin", + }, + { + name: "overflow-x", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + keywords: [ + "visible", "hidden", "scroll", "auto", "overlay", "clip" + ], + typedom_types: ["Keyword"], + default_value: "visible", + // This is to allow us to gather metrics when overflow is explicitly set. + style_builder_custom_functions: ["initial", "inherit", "value"], + type_name: "EOverflow", + logical_property_group: { + name: "overflow", + resolver: "horizontal", + }, + // Overflow has special semantics; overflowY can influence overflowX. + // But StyleAdjuster::AdjustOverflow() only does this properly if overflowX + // is set to the initial value (it cannot distinguish between an explicitly + // set overflowX, and one that was already adjusted in a previous pass). + // Modifying overflow frequently should not be common, so we take it out. + supports_incremental_style: false, + idempotent: false, + }, + { + name: "overflow-y", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + keywords: [ + "visible", "hidden", "scroll", "auto", "overlay", "clip" + ], + typedom_types: ["Keyword"], + default_value: "visible", + // This is to allow us to gather metrics when overflow is explicitly set. + style_builder_custom_functions: ["initial", "inherit", "value"], + type_name: "EOverflow", + logical_property_group: { + name: "overflow", + resolver: "vertical", + }, + // See comment on overflow-x. + supports_incremental_style: false, + idempotent: false, + }, + { + name: "overscroll-behavior-inline", + logical_property_group: { + name: "overscroll-behavior", + resolver: "inline", + }, + valid_for_permission_element: true, + }, + { + name: "overscroll-behavior-block", + logical_property_group: { + name: "overscroll-behavior", + resolver: "block", + }, + valid_for_permission_element: true, + }, + { + name: "overscroll-behavior-x", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + field_group: "*", + keywords: ["auto", "contain", "none"], + default_value: "auto", + type_name: "EOverscrollBehavior", + typedom_types: ["Keyword"], + logical_property_group: { + name: "overscroll-behavior", + resolver: "horizontal", + }, + computable: false, + valid_for_permission_element: true, + }, + { + name: "overscroll-behavior-y", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + field_group: "*", + keywords: ["auto", "contain", "none"], + default_value: "auto", + type_name: "EOverscrollBehavior", + typedom_types: ["Keyword"], + logical_property_group: { + name: "overscroll-behavior", + resolver: "vertical", + }, + computable: false, + valid_for_permission_element: true, + }, + { + name: "padding-bottom", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "box", + field_template: "", + default_value: "Length::Fixed()", + converter: "ConvertLength", + computed_style_custom_functions: ["setter"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_page_context: true, + logical_property_group: { + name: "padding", + resolver: "bottom", + }, + supports_incremental_style: true, + }, + { + name: "padding-left", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "box", + field_template: "", + default_value: "Length::Fixed()", + converter: "ConvertLength", + computed_style_custom_functions: ["setter"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_page_context: true, + logical_property_group: { + name: "padding", + resolver: "left", + }, + supports_incremental_style: true, + }, + { + name: "padding-right", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "box", + field_template: "", + default_value: "Length::Fixed()", + converter: "ConvertLength", + computed_style_custom_functions: ["setter"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_page_context: true, + logical_property_group: { + name: "padding", + resolver: "right", + }, + supports_incremental_style: true, + }, + { + name: "padding-top", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "box", + field_template: "", + default_value: "Length::Fixed()", + converter: "ConvertLength", + computed_style_custom_functions: ["setter"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_page_context: true, + logical_property_group: { + name: "padding", + resolver: "top", + }, + supports_incremental_style: true, + }, + { + name: "page", + field_group: "*", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + converter: "ConvertPage", + type_name: "AtomicString", + default_value: "AtomicString()", + field_template: "external", + keywords: ["auto"], + typedom_types: ["Keyword"], + computable: false, + valid_for_permission_element: true, + }, + { + name: "page-orientation", + is_descriptor: true, + field_template: "primitive", + field_group: "*", + type_name: "PageOrientation", + field_size: 2, + default_value: "PageOrientation::kUpright", + include_paths: ["third_party/blink/public/common/css/page_orientation.h"], + computable: false, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "paint-order", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg", + field_template: "primitive", + field_size: 3, + type_name: "EPaintOrder", + default_value: "kPaintOrderNormal", + converter: "ConvertPaintOrder", + keywords: ["normal", "fill", "stroke", "markers"], + typedom_types: ["Keyword"], + }, + { + name: "perspective", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "primitive", + default_value: "-1.0", + type_name: "float", + converter: "ConvertPerspective", + keywords: ["none"], + typedom_types: ["Keyword", "Length"], + }, + { + name: "perspective-origin", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length_point.h"], + default_value: "LengthPoint(Length::Percent(50.0), Length::Percent(50.0))", + type_name: "LengthPoint", + converter: "ConvertPosition", + typedom_types: ["Position"], + // Overlaps with -webkit-perspective-origin-[x,y]. + overlapping: true, + }, + { + name: "pointer-events", + property_methods: ["CSSValueFromComputedStyleInternal"], + computed_style_protected_functions: ["getter"], + independent: true, + inherited: true, + field_template: "keyword", + keywords: [ + "none", "auto", "stroke", "fill", "painted", "visible", "visiblestroke", + "visiblefill", "visiblepainted", "bounding-box", "all" + ], + typedom_types: ["Keyword"], + default_value: "auto", + }, + { + name: "position", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + keywords: [ + "static", "relative", "absolute", "fixed", "sticky" + ], + typedom_types: ["Keyword"], + default_value: "static", + getter: "GetPosition", + computed_style_custom_functions: ["getter"], + // See comment on display. + supports_incremental_style: false, + // @position-try-styling rely on this being high-priority, so that + // declarations from @position-try blocks can be applied conditionally + // based on whether or not we're out-of-flow positioned. + priority: 1, + valid_for_permission_element: true, + }, + { + name: "position-anchor", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal" ], + include_paths: ["third_party/blink/renderer/core/style/scoped_css_name.h"], + type_name: "ScopedCSSName", + wrapper_pointer_name: "Member", + default_value: "nullptr", + field_group: "*", + field_template: "external", + converter: "ConvertPositionAnchor", + keywords: ["implicit"], + typedom_types: ["Keyword"], + runtime_flag: "CSSAnchorPositioning", + valid_for_permission_element: true, + valid_for_position_try: true, + }, + { + name: "position-fallback-bounds", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal" ], + include_paths: ["third_party/blink/renderer/core/style/scoped_css_name.h"], + type_name: "ScopedCSSName", + wrapper_pointer_name: "Member", + default_value: "nullptr", + field_group: "*", + field_template: "external", + converter: "ConvertNormalOrCustomIdent", + keywords: ["normal"], + typedom_types: ["Keyword"], + runtime_flag: "CSSPositionFallbackBounds", + }, + { + name: "position-try-options", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_custom_functions: ["value"], + field_group: "*", + field_template: "external", + keywords: ["none", "flip-block", "flip-inline", "flip-start"], + typedom_types: ["Keyword"], + include_paths: ["third_party/blink/renderer/core/style/position_try_options.h"], + wrapper_pointer_name: "Member", + type_name: "PositionTryOptions", + default_value: "nullptr", + runtime_flag: "CSSAnchorPositioning", + }, + { + name: "position-try-order", + property_methods: ["CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*", + field_template: "keyword", + keywords: ["normal", "most-width", "most-height", "most-block-size", "most-inline-size"], + typedom_types: ["Keyword"], + default_value: "normal", + runtime_flag: "CSSPositionTryOrder", + }, + { + name: "quotes", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "pointer", + include_paths: ["third_party/blink/renderer/platform/text/quotes_data.h"], + wrapper_pointer_name: "scoped_refptr", + default_value: "nullptr", + type_name: "QuotesData", + converter: "ConvertQuotes", + keywords: ["auto", "none"], + typedom_types: ["Keyword"], + computable: false, + valid_for_page_context: true, + }, + { + name: "content-visibility", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_template: "keyword", + keywords: ["visible", "auto", "hidden"], + default_value: "visible", + typedom_types: ["Keyword"], + computable: false, + valid_for_permission_element: true, + }, + { + name: "reading-order-items", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["normal", "flex-visual", "flex-flow", "grid-rows", "grid-columns", "grid-order"], + typedom_types: ["Keyword"], + default_value: "normal", + runtime_flag: "CSSReadingOrderItems", + }, + { + name: "resize", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + computed_style_protected_functions: ["getter"], + style_builder_custom_functions: ["value"], + keywords: ["none", "both", "horizontal", "vertical", "block", "inline"], + typedom_types: ["Keyword"], + default_value: "none", + }, + { + name: "right", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "surround", + field_template: "", + keywords: ["auto"], + default_value: "Length()", + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthOrAuto", + anchor_mode: "right", + logical_property_group: { + name: "inset", + resolver: "right", + }, + supports_incremental_style: true, + valid_for_position_try: true, + valid_for_permission_element: true, + }, + { + name: "r", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->geometry", + field_template: "", + default_value: "Length::Fixed()", + typedom_types: ["Length", "Percentage"], + converter: "ConvertLength", + supports_incremental_style: true, + }, + { + name: "rx", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->geometry", + field_template: "", + default_value: "Length::Auto()", + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthOrAuto", + supports_incremental_style: true, + }, + { + name: "ry", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->geometry", + field_template: "", + default_value: "Length::Auto()", + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthOrAuto", + supports_incremental_style: true, + }, + { + interpolable: true, + name: "scrollbar-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + name_for_methods: "ScrollbarColor", + type_name: "std::optional", + converter: "ConvertScrollbarColor", + keywords: ["auto"], + field_group: "*", + field_template: "external", + default_value: "std::optional()", + include_paths: ["third_party/blink/renderer/core/style/style_scrollbar_color.h"], + runtime_flag: "ScrollbarColor", + }, + { + name: "scrollbar-gutter", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: false, + field_size: 4, + field_template: "primitive", + default_value: "kScrollbarGutterAuto", + name_for_methods: "ScrollbarGutter", + type_name: "unsigned", + converter: "ConvertScrollbarGutter", + keywords: [ + "auto", "stable", "both-edges" + ], + typedom_types: ["Keyword"], + }, + { + name: "scrollbar-width", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: false, + field_group: "*", + field_template: "keyword", + keywords: ["auto", "thin", "none"], + default_value: "auto", + typedom_types: ["Keyword"], + runtime_flag: "ScrollbarWidth", + }, + { + name: "scroll-behavior", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_size: 2, // FIXME: Convert this to a keyword field + field_template: "primitive", + include_paths: ["third_party/blink/public/mojom/scroll/scroll_enums.mojom-blink.h"], + default_value: "mojom::blink::ScrollBehavior::kAuto", + type_name: "mojom::blink::ScrollBehavior", + keywords: ["auto", "smooth"], + typedom_types: ["Keyword"], + }, + { + name: "scroll-margin-block-end", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "scroll-margin", + resolver: "block-end", + }, + typedom_types: ["Keyword", "Length"], + valid_for_permission_element: true, + }, + { + name: "scroll-margin-block-start", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "scroll-margin", + resolver: "block-start", + }, + typedom_types: ["Keyword", "Length"], + valid_for_permission_element: true, + }, + { + name: "scroll-margin-bottom", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "primitive", + default_value: "0.0f", + type_name: "float", + converter: "ConvertComputedLength", + typedom_types: ["Keyword", "Length"], + logical_property_group: { + name: "scroll-margin", + resolver: "bottom", + }, + computable: false, + valid_for_permission_element: true, + }, + { + name: "scroll-margin-inline-end", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "scroll-margin", + resolver: "inline-end", + }, + typedom_types: ["Keyword", "Length"], + valid_for_permission_element: true, + }, + { + name: "scroll-margin-inline-start", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "scroll-margin", + resolver: "inline-start", + }, + typedom_types: ["Keyword", "Length"], + valid_for_permission_element: true, + }, + { + name: "scroll-margin-left", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "primitive", + default_value: "0.0f", + type_name: "float", + converter: "ConvertComputedLength", + typedom_types: ["Keyword", "Length"], + logical_property_group: { + name: "scroll-margin", + resolver: "left", + }, + computable: false, + valid_for_permission_element: true, + }, + { + name: "scroll-margin-right", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "primitive", + default_value: "0.0f", + type_name: "float", + converter: "ConvertComputedLength", + typedom_types: ["Keyword", "Length"], + logical_property_group: { + name: "scroll-margin", + resolver: "right", + }, + computable: false, + valid_for_permission_element: true, + }, + { + name: "scroll-margin-top", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "primitive", + default_value: "0.0f", + type_name: "float", + converter: "ConvertComputedLength", + typedom_types: ["Keyword", "Length"], + logical_property_group: { + name: "scroll-margin", + resolver: "top", + }, + computable: false, + valid_for_permission_element: true, + }, + { + name: "scroll-padding-block-end", + property_methods: ["ParseSingleValue"], + include_paths: ["third_party/blink/renderer/platform/geometry/length.h"], + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + type_name: "Length", + converter: "ConvertLengthOrAuto", + logical_property_group: { + name: "scroll-padding", + resolver: "block-end", + }, + valid_for_permission_element: true, + }, + { + name: "scroll-padding-block-start", + property_methods: ["ParseSingleValue"], + include_paths: ["third_party/blink/renderer/platform/geometry/length.h"], + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + type_name: "Length", + converter: "ConvertLengthOrAuto", + logical_property_group: { + name: "scroll-padding", + resolver: "block-start", + }, + valid_for_permission_element: true, + }, + { + name: "scroll-padding-bottom", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "", + default_value: "Length()", + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthOrAuto", + logical_property_group: { + name: "scroll-padding", + resolver: "bottom", + }, + computable: false, + valid_for_permission_element: true, + }, + { + name: "scroll-padding-inline-end", + property_methods: ["ParseSingleValue"], + include_paths: ["third_party/blink/renderer/platform/geometry/length.h"], + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + type_name: "Length", + converter: "ConvertLengthOrAuto", + logical_property_group: { + name: "scroll-padding", + resolver: "inline-end", + }, + valid_for_permission_element: true, + }, + { + name: "scroll-padding-inline-start", + property_methods: ["ParseSingleValue"], + include_paths: ["third_party/blink/renderer/platform/geometry/length.h"], + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + type_name: "Length", + converter: "ConvertLengthOrAuto", + logical_property_group: { + name: "scroll-padding", + resolver: "inline-start", + }, + valid_for_permission_element: true, + }, + { + name: "scroll-padding-left", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "", + default_value: "Length()", + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthOrAuto", + logical_property_group: { + name: "scroll-padding", + resolver: "left", + }, + computable: false, + valid_for_permission_element: true, + }, + { + name: "scroll-padding-right", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "", + default_value: "Length()", + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthOrAuto", + logical_property_group: { + name: "scroll-padding", + resolver: "right", + }, + computable: false, + valid_for_permission_element: true, + }, + { + name: "scroll-padding-top", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "", + default_value: "Length()", + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthOrAuto", + logical_property_group: { + name: "scroll-padding", + resolver: "top", + }, + computable: false, + valid_for_permission_element: true, + }, + { + name: "scroll-snap-align", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["cc/input/scroll_snap_data.h"], + default_value: "cc::ScrollSnapAlign()", + getter: "GetScrollSnapAlign", + type_name: "cc::ScrollSnapAlign", + converter: "ConvertSnapAlign", + keywords: ["none", "start", "end", "center"], + typedom_types: ["Keyword"], + computable: false, + }, + { + name: "scroll-snap-stop", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + keywords: ["normal", "always"], + default_value: "normal", + typedom_types: ["Keyword"], + computable: false, + }, + { + name: "scroll-snap-type", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["cc/input/scroll_snap_data.h"], + default_value: "cc::ScrollSnapType()", + getter: "GetScrollSnapType", + type_name: "cc::ScrollSnapType", + converter: "ConvertSnapType", + keywords: ["none", "x", "y", "block", "inline", "both", "mandatory", "proximity"], + typedom_types: ["Keyword"], + computable: false, + }, + { + name: "scroll-start-block", + property_methods: ["ParseSingleValue"], + field_group: "*->start", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/scroll_start_data.h"], + default_value: "blink::ScrollStartData()", + type_name: "ScrollStartData", + logical_property_group : { + name: "scroll-start", + resolver: "block" + }, + keywords: ["auto", "start", "end", "center", "top", "bottom", "left", "right"], + typedom_types: ["Keyword", "Length", "Percentage"], + runtime_flag: "CSSScrollStart", + }, + { + name: "scroll-start-inline", + property_methods: ["ParseSingleValue"], + field_group: "*->start", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/scroll_start_data.h"], + default_value: "blink::ScrollStartData()", + type_name: "ScrollStartData", + logical_property_group : { + name: "scroll-start", + resolver: "inline" + }, + keywords: ["auto", "start", "end", "center", "top", "bottom", "left", "right"], + typedom_types: ["Keyword", "Length", "Percentage"], + runtime_flag: "CSSScrollStart", + }, + { + name: "scroll-start-x", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*->start", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/scroll_start_data.h"], + default_value: "blink::ScrollStartData()", + type_name: "ScrollStartData", + converter: "ConvertScrollStart", + logical_property_group : { + name: "scroll-start", + resolver: "horizontal" + }, + runtime_flag: "CSSScrollStart", + }, + { + name: "scroll-start-y", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*->start", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/scroll_start_data.h"], + default_value: "blink::ScrollStartData()", + type_name: "ScrollStartData", + converter: "ConvertScrollStart", + logical_property_group : { + name: "scroll-start", + resolver: "vertical" + }, + runtime_flag: "CSSScrollStart", + }, + { + name: "scroll-start-target-block", + property_methods: ["ParseSingleValue"], + field_group: "*->target", + field_template: "keyword", + default_value: "none", + type_name: "EScrollStartTarget", + logical_property_group: { + name: "scroll-start-target", + resolver: "block", + }, + keywords: ["none", "auto"], + typedom_types: ["Keyword"], + runtime_flag: "CSSScrollStart", + }, + { + name: "scroll-start-target-inline", + property_methods: ["ParseSingleValue"], + field_group: "*->target", + field_template: "keyword", + default_value: "none", + type_name: "EScrollStartTarget", + logical_property_group: { + name: "scroll-start-target", + resolver: "inline", + }, + keywords: ["none", "auto"], + typedom_types: ["Keyword"], + runtime_flag: "CSSScrollStart", + }, + { + name: "scroll-start-target-x", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*->target", + field_template: "keyword", + type_name: "EScrollStartTarget", + default_value: "none", + logical_property_group: { + name: "scroll-start-target", + resolver: "horizontal" + }, + keywords: ["none", "auto"], + runtime_flag: "CSSScrollStart", + }, + { + name: "scroll-start-target-y", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*->target", + field_template: "keyword", + type_name: "EScrollStartTarget", + default_value: "none", + logical_property_group: { + name: "scroll-start-target", + resolver: "vertical" + }, + keywords: ["none", "auto"], + runtime_flag: "CSSScrollStart", + }, + { + name: "scroll-timeline-axis", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*->timeline", + field_template: "external", + default_value: "Vector()", + type_name: "Vector", + converter: "ConvertViewTimelineAxis", + separator: ",", + runtime_flag: "ScrollTimeline", + }, + { + name: "scroll-timeline-name", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*->timeline", + field_template: "external", + default_value: "nullptr", + type_name: "ScopedCSSNameList", + wrapper_pointer_name: "Member", + converter: "ConvertViewTimelineName", + separator: ",", + runtime_flag: "ScrollTimeline", + }, + { + name: "shape-image-threshold", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "primitive", + default_value: "0.0", + type_name: "float", + computed_style_custom_functions: ["setter"], + typedom_types: ["Number"], + accepts_numeric_literal: true, + }, + { + name: "shape-margin", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "", + default_value: "Length::Fixed(0)", + converter: "ConvertLength", + keywords: ["none"], + typedom_types: ["Length", "Percentage"], + }, + { + name: "shape-outside", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/shape_value.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + typedom_types: ["Keyword", "Image"], + type_name: "ShapeValue", + computed_style_custom_functions: ["getter"], + converter: "ConvertShapeValue", + keywords: ["none"], + }, + { + name: "shape-rendering", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg", + field_template: "keyword", + keywords: ["auto", "optimizespeed", "crispedges", "geometricprecision"], + default_value: "auto", + typedom_types: ["Keyword"], + }, + { + name: "size", + property_methods: ["ParseSingleValue"], + style_builder_custom_functions: ["initial", "inherit", "value"], + computable: false, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "speak", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: [ + "none", "normal", "spell-out", "digits", "literal-punctuation", + "no-punctuation" + ], + default_value: "normal", + }, + { + name: "stop-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + field_group: "svg->stop", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor(Color::kBlack)", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + style_builder_template: "color", + style_builder_template_args: { + initial_color: "ComputedStyleInitialValues::InitialStopColor", + }, + converter: "ConvertStyleColor", + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + }, + { + name: "stop-opacity", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->stop", + field_template: "primitive", + type_name: "float", + default_value: "1", + converter: "ConvertAlpha", + typedom_types: ["Number"], + accepts_numeric_literal: true, + }, + { + name: "stroke", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + inherited: true, + field_group: "svg->stroke", + field_template: "external", + type_name: "SVGPaint", + include_paths: ["third_party/blink/renderer/core/style/svg_paint.h"], + default_value: "SVGPaint()", + name_for_methods: "StrokePaint", + converter: "ConvertSVGPaint", + style_builder_template: "color", + style_builder_template_args: { + initial_color: "ComputedStyleInitialValues::InitialStrokePaint", + }, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "stroke-dasharray", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "svg->stroke", + field_template: "pointer", + type_name: "SVGDashArray", + include_paths: ["third_party/blink/renderer/core/style/svg_dash_array.h"], + wrapper_pointer_name: "scoped_refptr", + default_value: "EmptyDashArray()", + name_for_methods: "StrokeDashArray", + converter: "ConvertStrokeDasharray", + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "stroke-dashoffset", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "svg->stroke", + field_template: "external", + type_name: "Length", + default_value: "Length::Fixed()", + name_for_methods: "StrokeDashOffset", + converter: "ConvertLength", + typedom_types: ["Length", "Percentage"], + }, + { + name: "stroke-linecap", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg->stroke", + field_template: "primitive", + field_size: 2, + type_name: "LineCap", + default_value: "kButtCap", + name_for_methods: "CapStyle", + keywords: ["butt", "round", "square"], + typedom_types: ["Keyword"], + }, + { + name: "stroke-linejoin", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg->stroke", + field_template: "primitive", + field_size: 2, + type_name: "LineJoin", + default_value: "kMiterJoin", + name_for_methods: "JoinStyle", + keywords: ["miter", "bevel", "round"], + typedom_types: ["Keyword"], + }, + { + name: "stroke-miterlimit", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "svg->stroke", + field_template: "primitive", + type_name: "float", + default_value: "4", + name_for_methods: "StrokeMiterLimit", + typedom_types: ["Number"], + }, + { + name: "stroke-opacity", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "svg->stroke", + field_template: "primitive", + type_name: "float", + default_value: "1", + converter: "ConvertAlpha", + typedom_types: ["Number"], + accepts_numeric_literal: true, + }, + { + name: "stroke-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "svg->stroke", + field_template: "external", + type_name: "UnzoomedLength", + include_paths: ["third_party/blink/renderer/core/style/unzoomed_length.h"], + default_value: "UnzoomedLength(Length::Fixed(1))", + converter: "ConvertUnzoomedLength", + typedom_types: ["Length", "Percentage"], + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "table-layout", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + keywords: [ + "auto", "fixed" + ], + typedom_types: ["Keyword"], + default_value: "auto", + }, + { + name: "tab-size", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/text/tab_size.h"], + default_value: "TabSize(8)", + getter: "GetTabSize", + type_name: "TabSize", + converter: "ConvertLengthOrTabSpaces", + computed_style_custom_functions: ["setter"], + typedom_types: ["Number", "Length"], + valid_for_marker: true, + }, + { + name: "text-align", + property_methods: ["CSSValueFromComputedStyleInternal"], + independent: false, + inherited: true, + field_template: "keyword", + keywords: [ + "left", "right", "center", "justify", "-webkit-left", "-webkit-right", + "-webkit-center", "start", "end" + ], + typedom_types: ["Keyword"], + default_value: "start", + getter: "GetTextAlign", + style_builder_custom_functions: ["value"], + valid_for_formatted_text: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "text-align-last", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["auto", "start", "end", "left", "right", "center", "justify"], + default_value: "auto", + typedom_types: ["Keyword"], + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "text-anchor", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "svg", + field_template: "keyword", + keywords: ["start", "middle", "end"], + default_value: "start", + typedom_types: ["Keyword"], + }, + { + name: "text-autospace", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["normal", "no-autospace"], + default_value: "normal", + typedom_types: ["Keyword"], + runtime_flag: "CSSTextAutoSpace", + }, + { + name: "text-box-trim", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "box", + field_template: "keyword", + default_value: "none", + keywords: ["none", "start", "end", "both"], + typedom_types: ["Keyword"], + runtime_flag: "CSSTextBoxTrim", + }, + { + name: "text-box-edge", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "box", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/text_box_edge.h"], + default_value: "TextBoxEdge(TextBoxEdge::TextBoxEdgeType::kLeading)", + type_name: "TextBoxEdge", + converter: "ConvertTextBoxEdge", + runtime_flag: "CSSTextBoxTrim", + }, + { + name: "text-combine-upright", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["none", "all"], + typedom_types: ["Keyword"], + default_value: "none", + name_for_methods: "TextCombine", + valid_for_marker: true, + computable: false, + valid_for_formatted_text: true, + }, + { + name: "text-decoration-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + supports_incremental_style: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_page_context: true, + }, + { + name: "text-decoration-line", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "visual", + field_template: "multi_keyword", + keywords: ["none", "underline", "overline", "line-through", "blink", "spelling-error", "grammar-error"], + typedom_types: ["Keyword"], + default_value: "none", + type_name: "TextDecorationLine", + converter: "ConvertFlags", + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_page_context: true, + }, + { + name: "text-decoration-skip-ink", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["none", "auto"], + typedom_types: ["Keyword"], + default_value: "auto", + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_page_context: true, + }, + { + name: "text-decoration-style", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["solid", "double", "dotted", "dashed", "wavy"], + typedom_types: ["Keyword"], + default_value: "solid", + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_page_context: true, + }, + { + name: "text-decoration-thickness", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + include_paths: ["third_party/blink/renderer/core/style/text_decoration_thickness.h"], + inherited: false, + field_group: "*", + field_template: "external", + type_name: "TextDecorationThickness", + default_value: "TextDecorationThickness(Length::Auto())", + converter: "ConvertTextDecorationThickness", + keywords: ["auto", "from-font"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + computable: false, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_page_context: true, + }, + { + name: "text-indent", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "", + default_value: "Length::Fixed()", + style_builder_custom_functions: ["value"], + typedom_types: ["Length", "Percentage"], + valid_for_page_context: true, + }, + { + name: "text-overflow", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["clip", "ellipsis"], + typedom_types: ["Keyword"], + default_value: "clip", + valid_for_formatted_text: true, + valid_for_page_context: true, + }, + { + name: "text-shadow", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "pointer", + include_paths: ["third_party/blink/renderer/core/style/shadow_list.h"], + wrapper_pointer_name: "scoped_refptr", + default_value: "nullptr", + type_name: "ShadowList", + converter: "ConvertShadowList", + keywords: ["none"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_page_context: true, + }, + { + name: "text-size-adjust", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/text_size_adjust.h"], + default_value: "TextSizeAdjust::AdjustAuto()", + getter: "GetTextSizeAdjust", + type_name: "TextSizeAdjust", + converter: "ConvertTextSizeAdjust", + keywords: ["none", "auto"], + typedom_types: ["Keyword", "Percentage"], + }, + { + name: "text-spacing", + longhands: ["text-autospace", "text-spacing-trim"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + runtime_flag: "CSSTextSpacing", + }, + { + name: "text-spacing-trim", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + font: true, + priority: 1, + type_name: "TextSpacingTrim", + include_paths: ["third_party/blink/renderer/platform/fonts/shaping/text_spacing_trim.h"], + keywords: ["normal", "space-all", "space-first", "trim-start"], + default_value: "TextSpacingTrim::kInitial", + typedom_types: ["Keyword"], + runtime_flag: "CSSTextSpacingTrim", + valid_for_permission_element: true, + }, + { + name: "text-transform", + property_methods: ["CSSValueFromComputedStyleInternal"], + independent: true, + inherited: true, + field_template: "keyword", + keywords: ["capitalize", "uppercase", "lowercase", "none", "math-auto"], + typedom_types: ["Keyword"], + default_value: "none", + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_page_context: true, + }, + { + name: "text-underline-offset", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "", + default_value: "Length()", + name_for_methods: "TextUnderlineOffset", + converter: "ConvertTextUnderlineOffset", + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_first_letter: true, + valid_for_first_line: true, + computable: false, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_highlight: true, + valid_for_page_context: true, + }, + { + name: "text-underline-position", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_size: 4, + field_template: "primitive", + default_value: "TextUnderlinePosition::kAuto", + getter: "GetTextUnderlinePosition", + type_name: "TextUnderlinePosition", + converter: "ConvertTextUnderlinePosition", + keywords: ["auto", "from-font", "under", "left", "right"], + typedom_types: ["Keyword"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_formatted_text: true, + valid_for_formatted_text_run: true, + valid_for_page_context: true, + }, + { + name: "timeline-scope", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*->timeline", + field_template: "external", + default_value: "nullptr", + type_name: "ScopedCSSNameList", + wrapper_pointer_name: "Member", + converter: "ConvertTimelineScope", + separator: ",", + runtime_flag: "TimelineScope", + }, + { + name: "top", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "surround", + field_template: "", + keywords: ["auto"], + default_value: "Length()", + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthOrAuto", + anchor_mode: "top", + logical_property_group: { + name: "inset", + resolver: "top", + }, + supports_incremental_style: true, + valid_for_position_try: true, + valid_for_permission_element: true, + }, + { + name: "overlay", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["none", "auto"], + default_value: "none", + typedom_types: ["Keyword"], + }, + { + name: "touch-action", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_size: 8, // FIXME: Make this use "kTouchActionBits". + field_template: "primitive", + include_paths: ["third_party/blink/renderer/platform/graphics/touch_action.h"], + default_value: "TouchAction::kAuto", + type_name: "TouchAction", + converter: "ConvertFlags", + keywords: ["auto", "none", "pan-x", "pan-left", "pan-right", "pan-y", "pan-up", "pan-down", "pinch-zoom", "manipulation"], + typedom_types: ["Keyword"], + }, + { + name: "transform", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + compositable: true, + layout_dependent: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/transforms/transform_operations.h"], + keywords: ["none"], + default_value: "EmptyTransformOperations()", + typedom_types: ["Keyword", "Transform"], + type_name: "TransformOperations", + converter: "ConvertTransformOperations", + supports_incremental_style: true, + }, + { + name: "transform-box", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + keywords: ["content-box", "border-box", "fill-box", "stroke-box", "view-box"], + default_value: "view-box", + typedom_types: ["Keyword"], + computable: false, + supports_incremental_style: true, + }, + { + name: "transform-origin", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "svg", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/transform_origin.h"], + default_value: "TransformOrigin(Length::Percent(50.0), Length::Percent(50.0), 0)", + getter: "GetTransformOrigin", + type_name: "TransformOrigin", + converter: "ConvertTransformOrigin", + supports_incremental_style: true, + // Overlaps with -webkit-transform-origin-[x,y,z]. + overlapping: true, + }, + { + name: "transform-style", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["flat", "preserve-3d"], + default_value: "flat", + typedom_types: ["Keyword"], + name_for_methods: "TransformStyle3D", + supports_incremental_style: true, + }, + { + name: "translate", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + compositable: true, + layout_dependent: true, + field_group: "*", + field_template: "pointer", + include_paths: ["third_party/blink/renderer/platform/transforms/translate_transform_operation.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + type_name: "TranslateTransformOperation", + converter: "ConvertTranslate", + supports_incremental_style: true, + }, + { + name: "rotate", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + compositable: true, + field_group: "*", + field_template: "pointer", + include_paths: ["third_party/blink/renderer/platform/transforms/rotate_transform_operation.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + type_name: "RotateTransformOperation", + converter: "ConvertRotate", + supports_incremental_style: true, + }, + { + name: "scale", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + compositable: true, + field_group: "*", + field_template: "pointer", + include_paths: ["third_party/blink/renderer/platform/transforms/scale_transform_operation.h"], + wrapper_pointer_name: "Member", + default_value: "nullptr", + type_name: "ScaleTransformOperation", + converter: "ConvertScale", + supports_incremental_style: true, + }, + { + name: "unicode-bidi", + property_methods: ["CSSValueFromComputedStyleInternal"], + affected_by_all: false, + field_template: "keyword", + include_paths: ["third_party/blink/renderer/platform/text/unicode_bidi.h"], + keywords: [ + "normal", "embed", "bidi-override", "isolate", "plaintext", + "isolate-override" + ], + typedom_types: ["Keyword"], + default_value: "normal", + type_name: "UnicodeBidi", + valid_for_marker: true, + }, + { + name: "vector-effect", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "svg", + field_template: "keyword", + keywords: ["none", "non-scaling-stroke"], + typedom_types: ["Keyword"], + default_value: "none", + }, + { + name: "vertical-align", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + style_builder_custom_functions: ["inherit", "value"], + typedom_types: ["Keyword", "Length", "Percentage"], + keywords: ["baseline", "sub", "super", "text-top", "text-bottom", "middle"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_permission_element: true, + }, + { + name: "view-timeline-axis", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*->timeline", + field_template: "external", + default_value: "Vector()", + type_name: "Vector", + converter: "ConvertViewTimelineAxis", + separator: ",", + runtime_flag: "ScrollTimeline", + }, + { + name: "view-timeline-inset", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*->timeline", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/animation/timeline_inset.h"], + default_value: "Vector()", + type_name: "Vector", + converter: "ConvertViewTimelineInset", + separator: ",", + runtime_flag: "ScrollTimeline", + }, + { + name: "view-timeline-name", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + field_group: "*->timeline", + field_template: "external", + default_value: "nullptr", + type_name: "ScopedCSSNameList", + wrapper_pointer_name: "Member", + converter: "ConvertViewTimelineName", + separator: ",", + runtime_flag: "ScrollTimeline", + }, + { + name: "view-transition-class", + field_group: "*", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + converter: "ConvertViewTransitionClass", + type_name: "Vector", + default_value: "Vector()", + field_template: "external", + keywords: ["none"], + typedom_types: ["Keyword"], + runtime_flag: "CSSViewTransitionClass", + }, + { + name: "view-transition-name", + field_group: "*", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + converter: "ConvertViewTransitionName", + type_name: "AtomicString", + default_value: "AtomicString()", + field_template: "external", + keywords: ["none"], + typedom_types: ["Keyword"], + }, + { + name: "visibility", + property_methods: ["CSSValueFromComputedStyleInternal"], + independent: true, + interpolable: true, + inherited: true, + field_template: "keyword", + keywords: ["visible", "hidden", "collapse"], + typedom_types: ["Keyword"], + default_value: "visible", + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "x", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->geometry", + field_template: "", + default_value: "Length::Fixed()", + typedom_types: ["Length", "Percentage"], + converter: "ConvertLength", + supports_incremental_style: true, + valid_for_permission_element: true, + }, + { + name: "y", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "svg->geometry", + field_template: "", + default_value: "Length::Fixed()", + typedom_types: ["Length", "Percentage"], + converter: "ConvertLength", + supports_incremental_style: true, + valid_for_permission_element: true, + }, + { + name: "appearance", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_size: 5, + field_template: "primitive", + include_paths: ["third_party/blink/renderer/platform/theme_types.h"], + computed_style_protected_functions: ["getter"], + default_value: "kNoControlPart", + type_name: "ControlPart", + }, + { + name: "-webkit-appearance", + alias_for: "appearance", + }, + { + name: "app-region", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["none", "drag", "no-drag"], + default_value: "none", + name_for_methods: "DraggableRegionMode", + style_builder_custom_functions: ["initial", "inherit", "value"], + }, + { + name: "-webkit-app-region", + alias_for: "app-region", + }, + { + name: "-webkit-border-horizontal-spacing", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "inherited", + field_template: "primitive", + default_value: "0", + name_for_methods: "HorizontalBorderSpacing", + type_name: "short", + converter: "ConvertComputedLength", + valid_for_first_letter: true, + }, + { + name: "-webkit-border-image", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_custom_functions: ["value"], + valid_for_first_letter: true, + affected_by_all: false, + // Overlaps with border-image. + legacy_overlapping: true, + }, + { + name: "-webkit-border-vertical-spacing", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "inherited", + field_template: "primitive", + default_value: "0", + name_for_methods: "VerticalBorderSpacing", + type_name: "short", + converter: "ConvertComputedLength", + valid_for_first_letter: true, + }, + // For valid values of box-align see + // http://www.w3.org/TR/2009/WD-css3-flexbox-20090723/#alignment + { + name: "-webkit-box-align", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["stretch", "start", "center", "end", "baseline"], + default_value: "stretch", + type_name: "EBoxAlignment", + valid_for_permission_element: true, + }, + { + name: "-webkit-box-decoration-break", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "box", + field_template: "keyword", + keywords: ["slice", "clone"], + default_value: "slice", + }, + { + name: "-webkit-box-direction", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_template: "keyword", + keywords: ["normal", "reverse"], + default_value: "normal", + computed_style_protected_functions: ["getter"], + }, + { + name: "-webkit-box-flex", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "primitive", + default_value: "0.0f", + type_name: "float", + accepts_numeric_literal: true, + }, + { + name: "-webkit-box-ordinal-group", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "primitive", + default_value: "1", + type_name: "unsigned", + computed_style_custom_functions: ["setter"], + valid_for_permission_element: true, + }, + { + name: "-webkit-box-orient", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["horizontal", "vertical"], + default_value: "horizontal", + }, + { + name: "-webkit-box-pack", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["start", "center", "end", "justify"], + default_value: "start", + }, + { + name: "-webkit-box-reflect", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "pointer", + include_paths: ["third_party/blink/renderer/core/style/style_reflection.h"], + wrapper_pointer_name: "scoped_refptr", + default_value: "nullptr", + type_name: "StyleReflection", + converter: "ConvertBoxReflect", + }, + { + name: "column-count", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "primitive", + default_value: "1", + type_name: "unsigned short", + computed_style_custom_functions: ["setter"], + style_builder_template: "auto", + keywords: ["auto"], + typedom_types: ["Keyword", "Number"], + }, + { + name: "column-gap", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length.h"], + default_value: "std::nullopt", + type_name: "std::optional", + converter: "ConvertGapLength", + keywords: ["normal"], + typedom_types: ["Keyword", "Length", "Percentage"], + }, + { + name: "row-gap", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/length.h"], + default_value: "std::nullopt", + type_name: "std::optional", + converter: "ConvertGapLength", + keywords: ["normal"], + typedom_types: ["Keyword", "Length", "Percentage"], + }, + { + name: "column-rule-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + converter: "ConvertStyleColor", + style_builder_template: "color", + }, + { + name: "column-rule-style", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: [ + "none", "hidden", "inset", "groove", "outset", "ridge", "dotted", + "dashed", "solid", "double" + ], + default_value: "none", + type_name: "EBorderStyle", + typedom_types: ["Keyword"], + }, + { + name: "column-rule-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/geometry/layout_unit.h"], + default_value: "LayoutUnit(3)", + type_name: "LayoutUnit", + computed_style_custom_functions: ["initial", "getter", "setter"], + converter: "ConvertColumnRuleWidth", + keywords: ["thin", "medium", "thick"], + typedom_types: ["Keyword", "Length"], + }, + { + name: "column-span", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["none", "all"], + default_value: "none", + getter: "GetColumnSpan", + typedom_types: ["Keyword"], + }, + { + name: "column-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "*", + field_template: "primitive", + default_value: "0.0f", + type_name: "float", + computed_style_custom_functions: ["setter"], + style_builder_template: "auto", + converter: "ConvertComputedLength", + keywords: ["auto"], + typedom_types: ["Keyword", "Length"], + }, + { + name: "hyphenate-character", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/platform/wtf/text/atomic_string.h"], + default_value: "AtomicString()", + name_for_methods: "HyphenationString", + type_name: "AtomicString", + converter: "ConvertString", + }, + { + name: "-webkit-line-break", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["auto", "loose", "normal", "strict", "after-white-space", "anywhere"], + default_value: "auto", + type_name: "LineBreak", + valid_for_formatted_text: true, + }, + { + name: "line-break", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + type_name: "LineBreak", + keywords: ["auto", "loose", "normal", "strict", "anywhere"], + typedom_types: ["Keyword"], + valid_for_marker: true, + valid_for_formatted_text: true, + surrogate_for: "-webkit-line-break", + }, + // An Apple extension. + { + name: "-webkit-line-clamp", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + default_value: "0", + type_name: "int", + }, + { + name: "-webkit-mask-box-image-outset", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + style_builder_template: "mask_box", + style_builder_template_args: { + modifier_type: "Outset", + }, + }, + { + name: "-webkit-mask-box-image-repeat", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_template: "mask_box", + style_builder_template_args: { + modifier_type: "Repeat", + }, + }, + { + name: "-webkit-mask-box-image-slice", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + style_builder_template: "mask_box", + style_builder_template_args: { + modifier_type: "Slice", + }, + }, + { + name: "-webkit-mask-box-image-source", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + style_builder_custom_functions: ["value"], + }, + { + name: "-webkit-mask-box-image-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + style_builder_template: "mask_box", + style_builder_template_args: { + modifier_type: "Width", + }, + }, + { + name: "mask-mode", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "MaskMode", + }, + runtime_flag: "CSSMaskingInterop", + }, + { + name: "mask-clip", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "Clip", + }, + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-alternative-mask-clip", + alternative_of: "-webkit-mask-clip", + alias_for: "mask-clip", + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-mask-clip", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "Clip", + }, + }, + { + name: "mask-composite", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "CompositingOperator", + }, + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-alternative-mask-composite", + alternative_of: "-webkit-mask-composite", + alias_for: "mask-composite", + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-mask-composite", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "CompositingOperator", + }, + }, + { + name: "mask-image", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "Image", + fill_type_getter: "GetImage" + }, + runtime_flag: "CSSMaskingInterop", + // {-webkit-}mask-image needs to be applied before {-webkit-}mask-composite, + // otherwise {-webkit-}mask-composite has no effect. + priority: 2, + }, + { + name: "-webkit-alternative-mask-image", + alternative_of: "-webkit-mask-image", + alias_for: "mask-image", + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-mask-image", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "Image", + fill_type_getter: "GetImage" + }, + // {-webkit-}mask-image needs to be applied before {-webkit-}mask-composite, + // otherwise {-webkit-}mask-composite has no effect. + priority: 2, + }, + { + name: "mask-origin", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "Origin", + }, + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-alternative-mask-origin", + alternative_of: "-webkit-mask-origin", + alias_for: "mask-origin", + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-mask-origin", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "Origin", + }, + }, + { + name: "-webkit-mask-position-x", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + interpolable: true, + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "PositionX", + }, + computable: false, + }, + { + name: "-webkit-mask-position-y", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + interpolable: true, + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "PositionY", + }, + computable: false, + }, + { + name: "mask-repeat", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "Repeat", + }, + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-alternative-mask-repeat", + alternative_of: "-webkit-mask-repeat", + alias_for: "mask-repeat", + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-mask-repeat", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "Repeat", + }, + }, + { + name: "mask-size", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"], + interpolable: true, + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "Size", + }, + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-alternative-mask-size", + alternative_of: "-webkit-mask-size", + alias_for: "mask-size", + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-mask-size", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + style_builder_template: "mask_layer", + style_builder_template_args: { + fill_type: "Size", + }, + }, + { + name: "-webkit-perspective-origin-x", + property_methods: ["ParseSingleValue"], + style_builder_custom_functions: ["inherit"], + interpolable: true, + converter: "ConvertLength", + computable: false, + affected_by_all: false, + // Overlaps with perspective-origin. + legacy_overlapping: true, + }, + { + name: "-webkit-perspective-origin-y", + property_methods: ["ParseSingleValue"], + style_builder_custom_functions: ["inherit"], + interpolable: true, + converter: "ConvertLength", + computable: false, + affected_by_all: false, + // Overlaps with perspective-origin. + legacy_overlapping: true, + }, + { + name: "-webkit-print-color-adjust", + property_methods: ["CSSValueFromComputedStyleInternal"], + independent: false, // Actually true, but setting it to false saves a precious bit in ComputedStyleBase. + inherited: true, + field_template: "keyword", + keywords: ["economy", "exact"], + default_value: "economy", + valid_for_permission_element: true, + }, + { + name: "-webkit-rtl-ordering", + property_methods: ["CSSValueFromComputedStyleInternal"], + independent: true, + inherited: true, + field_template: "keyword", + keywords: ["logical", "visual"], + default_value: "logical", + name_for_methods: "RtlOrdering", + setter: "SetRtlOrdering", + type_name: "EOrder", + }, + { + name: "-webkit-ruby-position", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["before", "after"], + default_value: "before", + type_name: "RubyPosition", + converter: "ConvertRubyPosition", + computable: false, + valid_for_permission_element: true, + }, + { + name: "ruby-position", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + type_name: "RubyPosition", + converter: "ConvertRubyPosition", + surrogate_for: "-webkit-ruby-position", + valid_for_permission_element: true, + }, + { + name: "-webkit-tap-highlight-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h", + "third_party/blink/renderer/core/layout/layout_theme.h"], + type_name: "StyleColor", + default_value: "StyleColor(LayoutTheme::TapHighlightColor())", + converter: "ConvertStyleColor", + }, + { + name: "-webkit-text-combine", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + surrogate_for: "text-combine-upright", + }, + { + name: "text-emphasis-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + keywords: ["currentcolor"], + typedom_types: ["Keyword"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_marker: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "text-emphasis-position", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_size: 2, + field_template: "primitive", + default_value: "TextEmphasisPosition::kOverRight", + type_name: "TextEmphasisPosition", + converter: "ConvertTextTextEmphasisPosition", + valid_for_marker: true, + }, + { + name: "text-emphasis-style", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + style_builder_custom_functions: ["initial", "inherit", "value"], + valid_for_marker: true, + }, + { + name: "-webkit-text-fill-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "-webkit-text-security", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["none", "disc", "circle", "square"], + default_value: "none", + }, + { + name: "-webkit-text-stroke-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "-webkit-text-stroke-width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "primitive", + default_value: "0", + type_name: "float", + converter: "ConvertTextStrokeWidth", + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "-webkit-transform-origin-x", + property_methods: ["ParseSingleValue"], + style_builder_custom_functions: ["inherit"], + interpolable: true, + converter: "ConvertLength", + computable: false, + affected_by_all: false, + // Overlaps with transform-origin. + legacy_overlapping: true, + }, + { + name: "-webkit-transform-origin-y", + property_methods: ["ParseSingleValue"], + style_builder_custom_functions: ["inherit"], + interpolable: true, + converter: "ConvertLength", + computable: false, + affected_by_all: false, + // Overlaps with transform-origin. + legacy_overlapping: true, + }, + { + name: "-webkit-transform-origin-z", + property_methods: ["ParseSingleValue"], + style_builder_custom_functions: ["inherit"], + interpolable: true, + converter: "ConvertComputedLength", + computable: false, + affected_by_all: false, + // Overlaps with transform-origin. + legacy_overlapping: true, + }, + { + name: "-webkit-user-drag", + property_methods: ["CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "keyword", + keywords: ["auto", "none", "element"], + default_value: "auto", + valid_for_permission_element: true, + }, + { + name: "-webkit-user-modify", + property_methods: ["CSSValueFromComputedStyleInternal"], + computed_style_protected_functions: ["getter"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["read-only", "read-write", "read-write-plaintext-only"], + default_value: "read-only", + affected_by_all: false, + }, + { + name: "user-select", + property_methods: ["CSSValueFromComputedStyleInternal"], + computed_style_protected_functions: ["getter"], + inherited: true, + field_group: "*", + field_template: "keyword", + keywords: ["auto", "none", "text", "all", "contain"], + typedom_types: ["Keyword"], + default_value: "auto", + valid_for_permission_element: true, + }, + { + name: "white-space", + longhands: [ + "white-space-collapse", "text-wrap" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "white-space-collapse", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_template: "primitive", + field_size: 2, // Ensure this is in sync with `kWhiteSpaceCollapseBits`. + type_name: "WhiteSpaceCollapse", + keywords: ["collapse", "preserve", "preserve-breaks", "break-spaces"], + default_value: "WhiteSpaceCollapse::kCollapse", + include_paths: ["third_party/blink/renderer/core/css/white_space.h"], + typedom_types: ["Keyword"], + valid_for_cue: true, + valid_for_marker: true, + valid_for_page_context: true, + }, + { + name: "text-wrap", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_template: "primitive", + field_size: 2, // Ensure this is in sync with `kTextWrapBits`. + keywords: ["wrap", "nowrap", "balance", "pretty"], + type_name: "TextWrap", + default_value: "TextWrap::kWrap", + include_paths: ["third_party/blink/renderer/core/css/white_space.h"], + typedom_types: ["Keyword"], + valid_for_cue: true, + valid_for_marker: true, + valid_for_page_context: true, + }, + { + name: "widows", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + field_group: "*", + field_template: "primitive", + computed_style_custom_functions: ["setter"], + default_value: "2", + type_name: "short", + typedom_types: ["Number"], + }, + { + name: "width", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + layout_dependent: true, + field_group: "box", + field_template: "", + keywords: ["auto", "fit-content", "min-content", "max-content"], + default_value: "Length()", + typedom_types: ["Keyword", "Length", "Percentage"], + converter: "ConvertLengthSizing", + anchor_mode: "size", + logical_property_group: { + name: "size", + resolver: "horizontal", + }, + supports_incremental_style: true, + valid_for_formatted_text: true, + valid_for_position_try: true, + affected_by_zoom: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "will-change", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + style_builder_custom_functions: ["initial", "inherit", "value"], + keywords: ["auto"], + typedom_types: ["Keyword"], + valid_for_permission_element: true, + }, + { + name: "word-break", + property_methods: ["CSSValueFromComputedStyleInternal"], + inherited: true, + field_group: "*", + field_template: "keyword", + // Word Break Values. Matches WinIE and CSS3 + keywords: ["normal", "break-all", "keep-all", "break-word", "auto-phrase"], + default_value: "normal", + typedom_types: ["Keyword"], + valid_for_marker: true, + }, + { + name: "word-spacing", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + inherited: true, + converter: "ConvertSpacing", + keywords: ["normal"], + typedom_types: ["normal"], + typedom_types: ["Keyword", "Length"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_marker: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "z-index", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + interpolable: true, + field_group: "box", + field_template: "primitive", + default_value: "0", + type_name: "int", + computed_style_custom_functions: ["setter"], + style_builder_template: "auto", + converter: "ConvertInteger", + keywords: ["auto"], + typedom_types: ["Keyword", "Number"], + valid_for_permission_element: true, + }, + + // CSS logical props + { + name: "inline-size", + property_methods: ["ParseSingleValue"], + layout_dependent: true, + logical_property_group: { + name: "size", + resolver: "inline", + }, + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "block-size", + property_methods: ["ParseSingleValue"], + layout_dependent: true, + logical_property_group: { + name: "size", + resolver: "block", + }, + keywords: ["auto"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "min-inline-size", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "min-size", + resolver: "inline", + }, + typedom_types: ["Length", "Percentage"], + valid_for_position_try: true, + valid_for_page_context: true, + }, + { + name: "min-block-size", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "min-size", + resolver: "block", + }, + typedom_types: ["Length", "Percentage"], + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "max-inline-size", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "max-size", + resolver: "inline", + }, + keywords: ["none"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "max-block-size", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "max-size", + resolver: "block", + }, + keywords: ["none"], + typedom_types: ["Keyword", "Length", "Percentage"], + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "margin-inline-start", + layout_dependent: true, + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "margin", + resolver: "inline-start", + }, + typedom_types: ["Length", "Percentage"], + keywords: ["auto"], + valid_for_first_letter: true, + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "margin-inline-end", + layout_dependent: true, + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "margin", + resolver: "inline-end", + }, + typedom_types: ["Length", "Percentage"], + keywords: ["auto"], + valid_for_first_letter: true, + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "margin-block-start", + layout_dependent: true, + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "margin", + resolver: "block-start", + }, + typedom_types: ["Length", "Percentage"], + keywords: ["auto"], + valid_for_first_letter: true, + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "margin-block-end", + layout_dependent: true, + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "margin", + resolver: "block-end", + }, + typedom_types: ["Length", "Percentage"], + keywords: ["auto"], + valid_for_first_letter: true, + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "padding-inline-start", + layout_dependent: true, + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "padding", + resolver: "inline-start", + }, + typedom_types: ["Length", "Percentage"], + valid_for_page_context: true, + }, + { + name: "padding-inline-end", + layout_dependent: true, + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "padding", + resolver: "inline-end", + }, + typedom_types: ["Length", "Percentage"], + valid_for_page_context: true, + }, + { + name: "padding-block-start", + layout_dependent: true, + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "padding", + resolver: "block-start", + }, + typedom_types: ["Length", "Percentage"], + valid_for_page_context: true, + }, + { + name: "padding-block-end", + layout_dependent: true, + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "padding", + resolver: "block-end", + }, + typedom_types: ["Length", "Percentage"], + valid_for_page_context: true, + }, + { + name: "border-inline-start-width", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-width", + resolver: "inline-start", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-inline-start-style", + logical_property_group: { + name: "border-style", + resolver: "inline-start", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-inline-start-color", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-color", + resolver: "inline-start", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-inline-end-width", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-width", + resolver: "inline-end", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-inline-end-style", + logical_property_group: { + name: "border-style", + resolver: "inline-end", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-inline-end-color", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-color", + resolver: "inline-end", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-block-start-width", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-width", + resolver: "block-start", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-block-start-style", + logical_property_group: { + name: "border-style", + resolver: "block-start", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-block-start-color", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-color", + resolver: "block-start", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-block-end-width", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-width", + resolver: "block-end", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-block-end-style", + logical_property_group: { + name: "border-style", + resolver: "block-end", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-block-end-color", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-color", + resolver: "block-end", + }, + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "inset-inline-start", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "inset", + resolver: "inline-start", + }, + typedom_types: ["Length", "Percentage"], + valid_for_position_try: true, + layout_dependent: true, + valid_for_permission_element: true, + }, + { + name: "inset-inline-end", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "inset", + resolver: "inline-end", + }, + typedom_types: ["Length", "Percentage"], + valid_for_position_try: true, + layout_dependent: true, + valid_for_permission_element: true, + }, + { + name: "inset-block-start", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "inset", + resolver: "block-start", + }, + typedom_types: ["Length", "Percentage"], + valid_for_position_try: true, + layout_dependent: true, + valid_for_permission_element: true, + }, + { + name: "inset-block-end", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "inset", + resolver: "block-end", + }, + typedom_types: ["Length", "Percentage"], + valid_for_position_try: true, + layout_dependent: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-start-start-radius", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-radius", + resolver: "start-start", + }, + typedom_types: ["Length", "Percentage"], + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-start-end-radius", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-radius", + resolver: "start-end", + }, + typedom_types: ["Length", "Percentage"], + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-end-start-radius", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-radius", + resolver: "end-start", + }, + typedom_types: ["Length", "Percentage"], + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-end-end-radius", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "border-radius", + resolver: "end-end", + }, + typedom_types: ["Length", "Percentage"], + valid_for_first_letter: true, + valid_for_permission_element: true, + valid_for_page_context: true, + }, + + // Non-standard direction aware properties + + { + name: "-webkit-border-end-color", + alias_for: "border-inline-end-color", + }, + { + name: "-webkit-border-end-style", + alias_for: "border-inline-end-style", + }, + { + name: "-webkit-border-end-width", + alias_for: "border-inline-end-width", + }, + { + name: "-webkit-border-start-color", + alias_for: "border-inline-start-color", + }, + { + name: "-webkit-border-start-style", + alias_for: "border-inline-start-style", + }, + { + name: "-webkit-border-start-width", + alias_for: "border-inline-start-width", + }, + { + name: "-webkit-border-before-color", + alias_for: "border-block-start-color", + }, + { + name: "-webkit-border-before-style", + alias_for: "border-block-start-style", + }, + { + name: "-webkit-border-before-width", + alias_for: "border-block-start-width", + }, + { + name: "-webkit-border-after-color", + alias_for: "border-block-end-color", + }, + { + name: "-webkit-border-after-style", + alias_for: "border-block-end-style", + }, + { + name: "-webkit-border-after-width", + alias_for: "border-block-end-width", + }, + { + name: "-webkit-margin-end", + alias_for: "margin-inline-end", + }, + { + name: "-webkit-margin-start", + alias_for: "margin-inline-start", + }, + { + name: "-webkit-margin-before", + alias_for: "margin-block-start", + }, + { + name: "-webkit-margin-after", + alias_for: "margin-block-end", + }, + { + name: "-webkit-padding-end", + alias_for: "padding-inline-end", + }, + { + name: "-webkit-padding-start", + alias_for: "padding-inline-start", + }, + { + name: "-webkit-padding-before", + alias_for: "padding-block-start", + }, + { + name: "-webkit-padding-after", + alias_for: "padding-block-end", + }, + { + name: "-webkit-logical-width", + alias_for: "inline-size", + }, + { + name: "-webkit-logical-height", + alias_for: "block-size", + }, + { + name: "-webkit-min-logical-width", + alias_for: "min-inline-size", + }, + { + name: "-webkit-min-logical-height", + alias_for: "min-block-size", + }, + { + name: "-webkit-max-logical-width", + alias_for: "max-inline-size", + }, + { + name: "-webkit-max-logical-height", + alias_for: "max-block-size", + }, + + // Properties that we ignore in the StyleBuilder. + // TODO(timloh): This seems wrong, most of these shouldn't reach the + // StyleBuilder + { + name: "all", + affected_by_all: false, + style_builder_template: "empty", + computable: false, + }, + // TODO(hjkim3323@gmail.com): Remove -internal-font-size-delta. + // fontSizeDelta execCommand does not need separate CSS property. + { + name: "-internal-font-size-delta", + property_methods: ["ParseSingleValue"], + style_builder_template: "empty", + }, + { + name: "-webkit-text-decorations-in-effect", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + inherited: true, + style_builder_template: "empty", + }, + + // Descriptor only names + { + name: "font-display", + is_descriptor: true, + is_property: false, + }, + { + name: "src", + is_descriptor: true, + is_property: false, + }, + { + name: "unicode-range", + is_descriptor: true, + is_property: false, + }, + { + name: "syntax", + is_descriptor: true, + is_property: false, + }, + { + name: "initial-value", + is_descriptor: true, + is_property: false, + }, + { + name: "inherits", + is_descriptor: true, + is_property: false, + }, + { + name: "ascent-override", + is_descriptor: true, + is_property: false, + }, + { + name: "descent-override", + is_descriptor: true, + is_property: false, + }, + { + name: "line-gap-override", + is_descriptor: true, + is_property: false, + }, + { + name: "system", + is_descriptor: true, + is_property: false, + }, + { + name: "negative", + is_descriptor: true, + is_property: false, + }, + { + name: "prefix", + is_descriptor: true, + is_property: false, + }, + { + name: "suffix", + is_descriptor: true, + is_property: false, + }, + { + name: "range", + is_descriptor: true, + is_property: false, + }, + { + name: "pad", + is_descriptor: true, + is_property: false, + }, + { + name: "fallback", + is_descriptor: true, + is_property: false, + }, + { + name: "symbols", + is_descriptor: true, + is_property: false, + }, + { + name: "additive-symbols", + is_descriptor: true, + is_property: false, + }, + { + name: "speak-as", + is_descriptor: true, + is_property: false, + }, + { + name: "size-adjust", + is_descriptor: true, + is_property: false, + }, + { + name: "base-palette", + is_descriptor: true, + is_property: false, + valid_for_permission_element: true, + }, + { + name: "override-colors", + is_descriptor: true, + is_property: false, + }, + { + name: "navigation", + is_descriptor: true, + is_property: false, + runtime_flag: "ViewTransitionOnNavigation", + }, + { + name: "inset-area", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"], + field_group: "*", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/style/inset_area.h"], + converter: "ConvertInsetArea", + default_value: "InsetArea()", + type_name: "InsetArea", + keywords: [ + "none", "top", "bottom", "center", "left", "right", "x-start", "x-end", + "y-start", "y-end", "start", "end", "self-start", "self-end", "all" + ], + typedom_types: ["Keyword"], + valid_for_position_try: true, + runtime_flag: "CSSAnchorPositioning", + valid_for_permission_element: true, + }, + + // Shorthands + { + name: "animation", + longhands: [ + "animation-duration", "animation-timing-function", "animation-delay", + "animation-iteration-count", "animation-direction", + "animation-fill-mode", "animation-play-state", "animation-name" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + supports_incremental_style: false, + valid_for_keyframe: false, + }, + { + // Variant of the "animation" shorthand which includes the + // animation-timeline and animation-range-* longhands. + name: "-alternative-animation-with-timeline", + alternative_of: "animation", + longhands: [ + "animation-duration", "animation-timing-function", + "animation-delay", "animation-iteration-count", "animation-direction", + "animation-fill-mode", "animation-play-state", "animation-name", + "animation-timeline", "animation-range-start", "animation-range-end" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + supports_incremental_style: false, + valid_for_keyframe: false, + runtime_flag: 'ScrollTimeline', + }, + { + // Variant of the "animation" shorthand which includes the + // animation-delay-start and animation-delay-end longhands. + name: "-alternative-animation-with-delay-start-end", + alternative_of: "-alternative-animation-with-timeline", + longhands: [ + "animation-duration", "animation-timing-function", + "animation-delay-start", "animation-delay-end", + "animation-iteration-count", "animation-direction", + "animation-fill-mode", "animation-play-state", "animation-name", + "animation-timeline", "animation-range-start", "animation-range-end" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + supports_incremental_style: false, + valid_for_keyframe: false, + runtime_flag: 'CSSAnimationDelayStartEnd', + }, + { + name: "animation-range", + longhands: [ + "animation-range-start", "animation-range-end", + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + supports_incremental_style: false, + valid_for_keyframe: false, + runtime_flag: 'ScrollTimeline', + }, + { + name: "background", + longhands: [ + "background-image", "background-position-x", "background-position-y", + "background-size", "background-repeat", + "background-attachment", "background-origin", "background-clip", + "background-color" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "background-position", + longhands: ["background-position-x", "background-position-y"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + computable: true, + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "border", + longhands: [ + "border-top-color", "border-top-style", "border-top-width", + "border-right-color", "border-right-style", "border-right-width", + "border-bottom-color", "border-bottom-style", "border-bottom-width", + "border-left-color", "border-left-style", "border-left-width", + "border-image-source", "border-image-slice", "border-image-width", + "border-image-outset", "border-image-repeat" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "border-block", + longhands: [ + "border-block-start-color", "border-block-start-style", "border-block-start-width", + "border-block-end-color", "border-block-end-style", "border-block-end-width" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "border-block-color", + longhands: ["border-block-start-color", "border-block-end-color"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "border-block-end", + longhands: [ + "border-block-end-width", "border-block-end-style", + "border-block-end-color" + ], + property_methods: ["ParseShorthand"], + logical_property_group: { + name: "border", + resolver: "block-end", + }, + valid_for_page_context: true, + }, + { + name: "border-block-start", + longhands: [ + "border-block-start-width", "border-block-start-style", + "border-block-start-color" + ], + property_methods: ["ParseShorthand"], + logical_property_group: { + name: "border", + resolver: "block-start", + }, + valid_for_page_context: true, + }, + { + name: "border-block-style", + longhands: ["border-block-start-style", "border-block-end-style"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "border-block-width", + longhands: ["border-block-start-width", "border-block-end-width"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "border-bottom", + longhands: [ + "border-bottom-width", "border-bottom-style", "border-bottom-color" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + logical_property_group: { + name: "border", + resolver: "bottom", + }, + valid_for_page_context: true, + }, + { + name: "border-color", + longhands: [ + "border-top-color", "border-right-color", "border-bottom-color", + "border-left-color" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "border-image", + longhands: [ + "border-image-source", "border-image-slice", "border-image-width", + "border-image-outset", "border-image-repeat" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "border-inline", + longhands: [ + "border-inline-start-color", "border-inline-start-style", "border-inline-start-width", + "border-inline-end-color", "border-inline-end-style", "border-inline-end-width" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "border-inline-color", + longhands: ["border-inline-start-color", "border-inline-end-color"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "border-inline-end", + longhands: [ + "border-inline-end-width", "border-inline-end-style", + "border-inline-end-color" + ], + property_methods: ["ParseShorthand"], + logical_property_group: { + name: "border", + resolver: "inline-end", + }, + valid_for_page_context: true, + }, + { + name: "border-inline-start", + longhands: [ + "border-inline-start-width", "border-inline-start-style", + "border-inline-start-color" + ], + property_methods: ["ParseShorthand"], + logical_property_group: { + name: "border", + resolver: "inline-start", + }, + valid_for_page_context: true, + }, + { + name: "border-inline-style", + longhands: ["border-inline-start-style", "border-inline-end-style"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "border-inline-width", + longhands: ["border-inline-start-width", "border-inline-end-width"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "border-left", + longhands: [ + "border-left-width", "border-left-style", "border-left-color" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + logical_property_group: { + name: "border", + resolver: "left", + }, + valid_for_page_context: true, + }, + { + name: "border-radius", + longhands: [ + "border-top-left-radius", "border-top-right-radius", + "border-bottom-right-radius", "border-bottom-left-radius" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_permission_element: true, + valid_for_page_context: true, + }, + { + name: "border-right", + longhands: [ + "border-right-width", "border-right-style", "border-right-color" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + logical_property_group: { + name: "border", + resolver: "right", + }, + valid_for_page_context: true, + }, + { + name: "border-spacing", + longhands: [ + "-webkit-border-horizontal-spacing", "-webkit-border-vertical-spacing" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "border-style", + longhands: [ + "border-top-style", "border-right-style", "border-bottom-style", + "border-left-style" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + keywords: ["none"], + valid_for_page_context: true, + }, + { + name: "border-top", + longhands: ["border-top-width", "border-top-style", "border-top-color"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + logical_property_group: { + name: "border", + resolver: "top", + }, + valid_for_page_context: true, + }, + { + name: "border-width", + longhands: [ + "border-top-width", "border-right-width", "border-bottom-width", + "border-left-width" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "contain-intrinsic-inline-size", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "contain-intrinsic-size", + resolver: "inline", + }, + typedom_types: ["Keyword", "Length"], + valid_for_permission_element: true, + }, + { + name: "contain-intrinsic-block-size", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "contain-intrinsic-size", + resolver: "block", + }, + typedom_types: ["Keyword", "Length"], + valid_for_permission_element: true, + }, + { + name: "contain-intrinsic-size", + longhands: [ + "contain-intrinsic-width", "contain-intrinsic-height" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + computable: true, + valid_for_permission_element: true, + }, + { + name: "container", + longhands: [ + "container-name", "container-type" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "flex", + longhands: ["flex-grow", "flex-shrink", "flex-basis"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "flex-flow", + longhands: ["flex-direction", "flex-wrap"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "font", + longhands: [ + "font-style", "font-variant-ligatures", "font-variant-caps", + "font-variant-numeric", "font-variant-east-asian", "font-variant-alternates", + "font-variant-position", "font-weight", "font-stretch", "font-size", + "line-height", "font-family", "font-optical-sizing", "font-size-adjust", + "font-kerning", "font-feature-settings", "font-variation-settings" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + // Changes to anything related to fonts require that we call style.UpdateFont(), + // which the incremental path does not do. + supports_incremental_style: false, + }, + { + name: "font-variant", + longhands: [ + "font-variant-ligatures", "font-variant-caps", "font-variant-alternates", + "font-variant-numeric", "font-variant-east-asian", "font-variant-position" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + is_descriptor: true, + computable: true, + // See comment on font. + supports_incremental_style: false, + }, + { + name: "font-synthesis", + longhands: ["font-synthesis-weight", "font-synthesis-style", "font-synthesis-small-caps"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + // See comment on font. + supports_incremental_style: false, + }, + { + name: "grid", + longhands: [ + "grid-template-rows", "grid-template-columns", "grid-template-areas", + "grid-auto-flow", "grid-auto-rows", "grid-auto-columns" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + layout_dependent: true, + }, + { + name: "place-content", + longhands: ["align-content", "justify-content"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "place-items", + longhands: ["align-items", "justify-items"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "place-self", + longhands: ["align-self", "justify-self"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_position_try: true, + }, + { + name: "grid-area", + longhands: [ + "grid-row-start", "grid-column-start", "grid-row-end", + "grid-column-end" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "grid-column", + longhands: ["grid-column-start", "grid-column-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "grid-column-gap", + longhands: ["column-gap"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "grid-row-gap", + longhands: ["row-gap"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "gap", + longhands: ["row-gap", "column-gap"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "grid-gap", + longhands: ["row-gap", "column-gap"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "grid-row", + longhands: ["grid-row-start", "grid-row-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "grid-template", + longhands: [ + "grid-template-rows", "grid-template-columns", "grid-template-areas" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + layout_dependent: true, + }, + { + name: "inset", + longhands: ["top", "right", "bottom", "left"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_position_try: true, + layout_dependent: true, + }, + { + name: "inset-block", + longhands: ["inset-block-start", "inset-block-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_position_try: true, + layout_dependent: true, + }, + { + name: "inset-inline", + longhands: ["inset-inline-start", "inset-inline-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_position_try: true, + layout_dependent: true, + }, + { + name: "list-style", + longhands: ["list-style-position", "list-style-image", "list-style-type"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "margin", + longhands: ["margin-top", "margin-right", "margin-bottom", "margin-left"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + layout_dependent: true, + valid_for_position_try: true, + valid_for_permission_element: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "margin-block", + longhands: ["margin-block-start", "margin-block-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + layout_dependent: true, + valid_for_position_try: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "margin-inline", + longhands: ["margin-inline-start", "margin-inline-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + layout_dependent: true, + valid_for_position_try: true, + valid_for_limited_page_context: true, + valid_for_page_context: true, + }, + { + name: "marker", + longhands: ["marker-start", "marker-mid", "marker-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "offset", + longhands: [ + "offset-position", "offset-path", "offset-distance", "offset-rotate", + "offset-anchor" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "outline", + longhands: ["outline-color", "outline-style", "outline-width"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "overflow", + longhands: ["overflow-x", "overflow-y"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + // See comment on overflow-x. + supports_incremental_style: false, + }, + { + name: "overscroll-behavior", + longhands: ["overscroll-behavior-x", "overscroll-behavior-y"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "padding", + longhands: [ + "padding-top", "padding-right", "padding-bottom", "padding-left" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + layout_dependent: true, + supports_incremental_style: true, + valid_for_page_context: true, + }, + { + name: "padding-block", + longhands: ["padding-block-start", "padding-block-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "padding-inline", + longhands: ["padding-inline-start", "padding-inline-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + valid_for_page_context: true, + }, + { + name: "page-break-after", + longhands: ["break-after"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "page-break-before", + longhands: ["break-before"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "page-break-inside", + longhands: ["break-inside"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "position-try", + longhands: ["position-try-order", "position-try-options"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + runtime_flag: "CSSPositionTryOrder", + }, + { + name: "scroll-margin", + longhands: ["scroll-margin-top", "scroll-margin-right", "scroll-margin-bottom", "scroll-margin-left"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "scroll-margin-block", + longhands: ["scroll-margin-block-start", "scroll-margin-block-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "scroll-margin-inline", + longhands: ["scroll-margin-inline-start", "scroll-margin-inline-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "scroll-padding", + longhands: [ + "scroll-padding-top", "scroll-padding-right", "scroll-padding-bottom", + "scroll-padding-left" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "scroll-padding-block", + longhands: ["scroll-padding-block-start", "scroll-padding-block-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "scroll-padding-inline", + longhands: ["scroll-padding-inline-start", "scroll-padding-inline-end"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "scroll-start", + longhands: ["scroll-start-block", "scroll-start-inline"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + runtime_flag: "CSSScrollStart", + }, + { + name: "scroll-start-target", + longhands: ["scroll-start-target-block", "scroll-start-target-inline"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + runtime_flag: "CSSScrollStart", + }, + { + name: "scroll-timeline", + longhands: ["scroll-timeline-name", "scroll-timeline-axis"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + runtime_flag: "ScrollTimeline", + }, + { + name: "text-decoration", + longhands: ["text-decoration-line", "text-decoration-thickness", "text-decoration-style", "text-decoration-color"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + computable: true, + valid_for_page_context: true, + }, + { + name: "transition", + longhands: [ + "transition-property", "transition-duration", + "transition-timing-function", "transition-delay", + "transition-behavior", + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + // Animation properites are never incremental. + supports_incremental_style: false, + }, + { + name: "view-timeline", + longhands: ["view-timeline-name", "view-timeline-axis"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + runtime_flag: "ScrollTimeline", + }, + { + name: "-alternative-view-timeline-with-inset", + alternative_of: "view-timeline", + longhands: ["view-timeline-name", "view-timeline-axis", "view-timeline-inset"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + runtime_flag: "CSSViewTimelineInsetShorthand", + }, + { + name: "-webkit-border-after", + alias_for: "border-block-end", + }, + { + name: "-webkit-border-before", + alias_for: "border-block-start", + }, + { + name: "-webkit-border-end", + alias_for: "border-inline-end", + }, + { + name: "-webkit-border-start", + alias_for: "border-inline-start", + }, + { + name: "-webkit-column-break-after", + longhands: ["break-after"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "-webkit-column-break-before", + longhands: ["break-before"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "-webkit-column-break-inside", + longhands: ["break-inside"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "column-rule", + longhands: [ + "column-rule-width", "column-rule-style", "column-rule-color" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "columns", + longhands: ["column-width", "column-count"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + // This alternative of mask is active when CSSMaskingInterop is enabled. + { + name: "-alternative-mask", + alternative_of: "mask", + longhands: [ + "mask-image", "-webkit-mask-position-x", + "-webkit-mask-position-y", "mask-size", "mask-repeat", "mask-origin", + "mask-clip", "mask-composite", "mask-mode" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-mask", + longhands: [ + "-webkit-mask-image", "-webkit-mask-position-x", + "-webkit-mask-position-y", "-webkit-mask-size", "-webkit-mask-repeat", + "-webkit-mask-origin", "-webkit-mask-clip" + ], + property_methods: ["ParseShorthand"], + }, + // This alternative of -webkit-mask is active when CSSMaskingInterop is + // enabled. + { + name: "-webkit-alternative-mask", + alternative_of: "-webkit-mask", + alias_for: "-alternative-mask", + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-mask-box-image", + longhands: [ + "-webkit-mask-box-image-source", "-webkit-mask-box-image-slice", + "-webkit-mask-box-image-width", "-webkit-mask-box-image-outset", + "-webkit-mask-box-image-repeat" + ], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + computable: true, + }, + { + name: "mask-position", + longhands: ["-webkit-mask-position-x", "-webkit-mask-position-y"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + computable: true, + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-alternative-mask-position", + alternative_of: "-webkit-mask-position", + alias_for: "mask-position", + computable: false, + runtime_flag: "CSSMaskingInterop", + }, + { + name: "-webkit-mask-position", + longhands: ["-webkit-mask-position-x", "-webkit-mask-position-y"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + computable: true, + }, + { + name: "text-emphasis", + longhands: ["text-emphasis-style", "text-emphasis-color"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + { + name: "-webkit-text-stroke", + longhands: ["-webkit-text-stroke-width", "-webkit-text-stroke-color"], + property_methods: ["ParseShorthand", "CSSValueFromComputedStyleInternal"], + }, + + // Visited properties. + { + name: "-internal-visited-color", + visited_property_for: "color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + inherited: true, + field_group: "inherited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor(Color::kBlack)", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + style_builder_custom_functions: ["initial", "inherit", "value"], + priority: 1, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + is_visited_highlight_colors: true, + }, + { + name: "-internal-visited-caret-color", + visited_property_for: "caret-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + inherited: true, + field_group: "*->inherited_visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_auto_color.h"], + default_value: "StyleAutoColor::AutoColor()", + type_name: "StyleAutoColor", + converter: "ConvertStyleAutoColor", + computed_style_protected_functions: ["getter"], + style_builder_template: "visited_color", + style_builder_template_args: { + initial_color: "StyleAutoColor::AutoColor", + }, + valid_for_highlight_legacy: true, + }, + { + name: "-internal-visited-column-rule-color", + visited_property_for: "column-rule-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + field_group: "*->visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + }, + { + name: "-internal-visited-background-color", + visited_property_for: "background-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + field_group: "*->visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor(Color::kTransparent)", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + style_builder_template_args: { + initial_color: "ComputedStyleInitialValues::InitialBackgroundColor", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + is_visited_highlight_colors: true, + }, + { + name: "-internal-visited-border-left-color", + visited_property_for: "border-left-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + field_group: "*->visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + valid_for_first_letter: true, + logical_property_group: { + name: "visited-border-color", + resolver: "left", + }, + }, + { + name: "-internal-visited-border-right-color", + visited_property_for: "border-right-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + field_group: "*->visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + valid_for_first_letter: true, + logical_property_group: { + name: "visited-border-color", + resolver: "right", + }, + }, + { + name: "-internal-visited-border-top-color", + visited_property_for: "border-top-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + field_group: "*->visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + valid_for_first_letter: true, + logical_property_group: { + name: "visited-border-color", + resolver: "top", + }, + }, + { + name: "-internal-visited-border-bottom-color", + visited_property_for: "border-bottom-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + field_group: "*->visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + valid_for_first_letter: true, + logical_property_group: { + name: "visited-border-color", + resolver: "bottom", + }, + }, + { + name: "-internal-visited-border-inline-start-color", + visited_property_for: "border-inline-start-color", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "visited-border-color", + resolver: "inline-start", + }, + valid_for_first_letter: true, + }, + { + name: "-internal-visited-border-inline-end-color", + visited_property_for: "border-inline-end-color", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "visited-border-color", + resolver: "inline-end", + }, + valid_for_first_letter: true, + }, + { + name: "-internal-visited-border-block-start-color", + visited_property_for: "border-block-start-color", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "visited-border-color", + resolver: "block-start", + }, + valid_for_first_letter: true, + }, + { + name: "-internal-visited-border-block-end-color", + visited_property_for: "border-block-end-color", + property_methods: ["ParseSingleValue"], + logical_property_group: { + name: "visited-border-color", + resolver: "block-end", + }, + valid_for_first_letter: true, + }, + { + name: "-internal-visited-fill", + visited_property_for: "fill", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + inherited: true, + field_group: "svg->fill", + field_template: "external", + type_name: "SVGPaint", + include_paths: ["third_party/blink/renderer/core/style/svg_paint.h"], + default_value: "SVGPaint(Color::kBlack)", + name_for_methods: "InternalVisitedFillPaint", + converter: "ConvertSVGPaint", + style_builder_template: "visited_color", + style_builder_template_args: { + initial_color: "ComputedStyleInitialValues::InitialFillPaint", + }, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "-internal-visited-outline-color", + visited_property_for: "outline-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + field_group: "*->visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + valid_for_cue: true, + }, + { + name: "-internal-visited-stroke", + visited_property_for: "stroke", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + inherited: true, + field_group: "svg->stroke", + field_template: "external", + type_name: "SVGPaint", + include_paths: ["third_party/blink/renderer/core/style/svg_paint.h"], + default_value: "SVGPaint()", + name_for_methods: "InternalVisitedStrokePaint", + converter: "ConvertSVGPaint", + style_builder_template: "visited_color", + style_builder_template_args: { + initial_color: "ComputedStyleInitialValues::InitialStrokePaint", + }, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "-internal-visited-text-decoration-color", + visited_property_for: "text-decoration-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + field_group: "*->visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "-internal-visited-text-emphasis-color", + visited_property_for: "text-emphasis-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + inherited: true, + field_group: "*->inherited_visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "-internal-visited-text-fill-color", + visited_property_for: "-webkit-text-fill-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + inherited: true, + field_group: "*->inherited_visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + { + name: "-internal-visited-text-stroke-color", + visited_property_for: "-webkit-text-stroke-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + inherited: true, + field_group: "*->inherited_visited", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "visited_color", + valid_for_highlight_legacy: true, + valid_for_highlight: true, + }, + + // Forced colors properties. + { + name: "-internal-forced-background-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + field_group: "*->forced_colors", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css_value_keywords.h", + "third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor(CSSValueID::kCanvas)", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "color", + style_builder_template_args: { + initial_color: "ComputedStyleInitialValues::InitialInternalForcedBackgroundColor", + }, + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + }, + { + name: "-internal-forced-border-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + field_group: "*->forced_colors", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_first_letter: true, + }, + { + name: "-internal-forced-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + inherited: true, + field_group: "*->inherited_forced_colors", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css_value_keywords.h", + "third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor(CSSValueID::kCanvastext)", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + style_builder_custom_functions: ["initial", "inherit", "value"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + }, + { + name: "-internal-forced-outline-color", + property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "ColorIncludingFallback"], + field_group: "*->forced_colors", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor::CurrentColor()", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + converter: "ConvertStyleColor", + style_builder_template: "color", + valid_for_cue: true, + }, + { + name: "-internal-forced-visited-color", + visited_property_for: "-internal-forced-color", + property_methods: ["ParseSingleValue", "ColorIncludingFallback"], + inherited: true, + field_group: "*->inherited_forced_colors", + field_template: "external", + include_paths: ["third_party/blink/renderer/core/css_value_keywords.h", + "third_party/blink/renderer/core/css/style_color.h"], + default_value: "StyleColor(CSSValueID::kCanvastext)", + type_name: "StyleColor", + computed_style_protected_functions: ["getter"], + style_builder_custom_functions: ["initial", "inherit", "value"], + valid_for_first_letter: true, + valid_for_first_line: true, + valid_for_cue: true, + valid_for_marker: true, + }, + + // Name: -internal-empty-line-height: + // Value: none | fabricated + // If the element is inline or contains visible text, this property has + // no effect. + // + // 'none' + // The box's intrinsic height is 0, and it defines no baseline. + // 'fabricated' + // The box has intrinsic height and baseline, computed from the current + // font metrics. + { + name: "-internal-empty-line-height", + property_methods: ["ParseSingleValue" ], + inherited: true, + field_group: "*", + field_template: "primitive", + type_name: "bool", + default_value: "false", + name_for_methods: "HasLineIfEmpty", + converter: "ConvertInternalEmptyLineHeight", + }, + { + name: "-internal-align-content-block", + property_methods: ["ParseSingleValue"], + inherited: false, + field_group: "*", + field_template: "primitive", + type_name: "bool", + default_value: "false", + name_for_methods: "AlignContentBlockCenter", + converter: "ConvertInternalAlignContentBlock", + }, + // Aliases; these map to the same CSSPropertyID + { + name: "-epub-caption-side", + alias_for: "caption-side", + }, + { + name: "-epub-text-combine", + alias_for: "-webkit-text-combine", + }, + { + name: "-epub-text-emphasis", + alias_for: "text-emphasis", + }, + { + name: "-epub-text-emphasis-color", + alias_for: "text-emphasis-color", + }, + { + name: "-epub-text-emphasis-style", + alias_for: "text-emphasis-style", + }, + { + name: "-epub-text-orientation", + alias_for: "-webkit-text-orientation", + }, + { + name: "-epub-text-transform", + alias_for: "text-transform", + }, + { + name: "-epub-word-break", + alias_for: "word-break", + }, + { + name: "-epub-writing-mode", + alias_for: "-webkit-writing-mode", + }, + { + name: "-webkit-align-content", + alias_for: "align-content", + }, + { + name: "-webkit-align-items", + alias_for: "align-items", + }, + { + name: "-webkit-align-self", + alias_for: "align-self", + }, + { + name: "-webkit-animation", + alias_for: "animation", + }, + { + // Since "animation" has an alternative property, "-webkit-animation" + // also needs to have an alternative property that is an alias of + // animation's alternative property. Unfortunately we can't just resolve + // -webkit-animation directly to animation's alternative, because we have + // to remember the -webkit-ness of the property to enable legacy parsing + // behavior. (See CSSParserLocalContext::UseAliasParsing). + name: "-webkit-alternative-animation-with-timeline", + alias_for: "-alternative-animation-with-timeline", + alternative_of: "-webkit-animation", + runtime_flag: "ScrollTimeline", + }, + { + name: "-webkit-alternative-animation-with-delay-start-end", + alias_for: "-alternative-animation-with-delay-start-end", + alternative_of: "-webkit-alternative-animation-with-timeline", + runtime_flag: "CSSAnimationDelayStartEnd", + }, + { + name: "-webkit-animation-delay", + alias_for: "animation-delay", + }, + { + name: "-webkit-alternative-animation-delay", + alias_for: "-alternative-animation-delay", + alternative_of: "-webkit-animation-delay", + runtime_flag: "CSSAnimationDelayStartEnd", + }, + { + name: "-webkit-animation-direction", + alias_for: "animation-direction", + }, + { + name: "-webkit-animation-duration", + alias_for: "animation-duration", + }, + { + name: "-webkit-animation-fill-mode", + alias_for: "animation-fill-mode", + }, + { + name: "-webkit-animation-iteration-count", + alias_for: "animation-iteration-count", + }, + { + name: "-webkit-animation-name", + alias_for: "animation-name", + }, + { + name: "-webkit-animation-play-state", + alias_for: "animation-play-state", + }, + { + name: "-webkit-animation-timing-function", + alias_for: "animation-timing-function", + }, + { + name: "-webkit-backface-visibility", + alias_for: "backface-visibility", + }, + { + name: "-webkit-background-clip", + alias_for: "background-clip", + }, + // -webkit-background-origin accepts "content", "padding", and "border" + // values. See crbug.com/604023 + { + name: "-webkit-background-origin", + alias_for: "background-origin" + }, + // "-webkit-background-size: 10px" behaves as "background-size: 10px 10px" + { + name: "-webkit-background-size", + alias_for: "background-size", + }, + { + name: "-webkit-border-bottom-left-radius", + alias_for: "border-bottom-left-radius", + }, + { + name: "-webkit-border-bottom-right-radius", + alias_for: "border-bottom-right-radius", + }, + // "-webkit-border-radius: 1px 2px" behaves as "border-radius: 1px / 2px" + { + name: "-webkit-border-radius", + alias_for: "border-radius", + }, + { + name: "-webkit-border-top-left-radius", + alias_for: "border-top-left-radius", + }, + { + name: "-webkit-border-top-right-radius", + alias_for: "border-top-right-radius", + }, + { + name: "-webkit-box-shadow", + alias_for: "box-shadow", + }, + { + name: "-webkit-box-sizing", + alias_for: "box-sizing", + }, + { + name: "-webkit-clip-path", + alias_for: "clip-path", + }, + { + name: "-webkit-column-count", + alias_for: "column-count", + }, + { + name: "-webkit-column-gap", + alias_for: "column-gap", + }, + { + name: "-webkit-column-rule", + alias_for: "column-rule", + }, + { + name: "-webkit-column-rule-color", + alias_for: "column-rule-color", + }, + { + name: "-webkit-column-rule-style", + alias_for: "column-rule-style", + }, + { + name: "-webkit-column-rule-width", + alias_for: "column-rule-width", + }, + { + name: "-webkit-column-span", + alias_for: "column-span", + }, + { + name: "-webkit-column-width", + alias_for: "column-width", + }, + { + name: "-webkit-columns", + alias_for: "columns", + }, + { + name: "-webkit-filter", + alias_for: "filter", + }, + { + name: "-webkit-flex", + alias_for: "flex", + }, + { + name: "-webkit-flex-basis", + alias_for: "flex-basis", + }, + { + name: "-webkit-flex-direction", + alias_for: "flex-direction", + }, + { + name: "-webkit-flex-flow", + alias_for: "flex-flow", + }, + { + name: "-webkit-flex-grow", + alias_for: "flex-grow", + }, + { + name: "-webkit-flex-shrink", + alias_for: "flex-shrink", + }, + { + name: "-webkit-flex-wrap", + alias_for: "flex-wrap", + }, + { + name: "-webkit-font-feature-settings", + alias_for: "font-feature-settings", + }, + { + name: "-webkit-hyphenate-character", + alias_for: "hyphenate-character", + }, + { + name: "-webkit-justify-content", + alias_for: "justify-content", + }, + { + name: "-webkit-opacity", + alias_for: "opacity", + }, + { + name: "-webkit-order", + alias_for: "order", + }, + { + name: "-webkit-perspective", + alias_for: "perspective", + }, + { + name: "-webkit-perspective-origin", + alias_for: "perspective-origin", + }, + { + name: "-webkit-shape-image-threshold", + alias_for: "shape-image-threshold", + }, + { + name: "-webkit-shape-margin", + alias_for: "shape-margin", + }, + { + name: "-webkit-shape-outside", + alias_for: "shape-outside", + }, + { + name: "-webkit-text-emphasis", + alias_for: "text-emphasis", + }, + { + name: "-webkit-text-emphasis-color", + alias_for: "text-emphasis-color", + }, + { + name: "-webkit-text-emphasis-position", + alias_for: "text-emphasis-position", + }, + { + name: "-webkit-text-emphasis-style", + alias_for: "text-emphasis-style", + }, + { + name: "-webkit-text-size-adjust", + alias_for: "text-size-adjust", + }, + { + name: "-webkit-transform", + alias_for: "transform", + }, + { + name: "-webkit-transform-origin", + alias_for: "transform-origin", + }, + { + name: "-webkit-transform-style", + alias_for: "transform-style", + }, + { + name: "-webkit-transition", + alias_for: "transition", + }, + { + name: "-webkit-transition-delay", + alias_for: "transition-delay", + }, + { + name: "-webkit-transition-duration", + alias_for: "transition-duration", + }, + { + name: "-webkit-transition-property", + alias_for: "transition-property", + }, + { + name: "-webkit-transition-timing-function", + alias_for: "transition-timing-function", + }, + { + name: "-webkit-user-select", + alias_for: "user-select", + }, + { + name: "word-wrap", + alias_for: "overflow-wrap", + }, + ], +} diff --git a/idl/core/css/css_properties_ranking.json5 b/idl/core/css/css_properties_ranking.json5 new file mode 100644 index 0000000..95d005a --- /dev/null +++ b/idl/core/css/css_properties_ranking.json5 @@ -0,0 +1,742 @@ +// DO NOT EDIT: This file is generated by manually running: +// third_party/blink/renderer/build/scripts/update_css_ranking.py +// +// The popularity ranking of all css properties the first properties is the most +// used property according to: https://www.chromestatus.com/metrics/css/popularity +{ + "data": [ + "IsStackingContextWithoutContainment", + "width", + "height", + "display", + "position", + "padding", + "border", + "margin", + "top", + "left", + "margin-top", + "color", + "font-size", + "background-color", + "text-align", + "opacity", + "font-weight", + "background", + "font-family", + "overflow", + "line-height", + "box-sizing", + "float", + "text-decoration", + "z-index", + "cursor", + "margin-left", + "border-radius", + "vertical-align", + "margin-bottom", + "margin-right", + "right", + "padding-left", + "padding-top", + "max-width", + "bottom", + "box-shadow", + "content", + "padding-right", + "transform", + "white-space", + "white-space-collapse", + "text-wrap", + "padding-bottom", + "min-height", + "background-image", + "border-bottom", + "visibility", + "background-position", + "outline", + "min-width", + "border-top", + "transition", + "border-color", + "background-repeat", + "text-transform", + "background-size", + "-webkit-transform", + "max-height", + "list-style", + "clear", + "font", + "font-style", + "justify-content", + "align-items", + "border-left", + "border-width", + "border-right", + "text-overflow", + "-webkit-box-sizing", + "-webkit-user-select", + "-webkit-user-select", + "overflow-y", + "pointer-events", + "-webkit-transition", + "border-style", + "flex-direction", + "animation", + "-webkit-font-smoothing", + "overflow-x", + "letter-spacing", + "-webkit-appearance", + "-webkit-appearance", + "-webkit-box-shadow", + "flex", + "word-wrap", + "word-wrap", + "-webkit-tap-highlight-color", + "-webkit-text-size-adjust", + "flex-wrap", + "fill", + "border-collapse", + "transform-origin", + "border-top-left-radius", + "list-style-type", + "border-bottom-left-radius", + "user-select", + "-webkit-animation", + "text-shadow", + "border-bottom-right-radius", + "word-break", + "clip", + "border-top-right-radius", + "flex-grow", + "-webkit-border-radius", + "border-bottom-color", + "border-top-color", + "flex-shrink", + "align-self", + "-webkit-box-orient", + "text-rendering", + "animation-timing-function", + "-webkit-box-align", + "direction", + "zoom", + "text-indent", + "-webkit-transform-origin", + "background-clip", + "border-spacing", + "-webkit-align-items", + "touch-action", + "-webkit-justify-content", + "outline-offset", + "src", + "border-left-color", + "transition-property", + "animation-name", + "animation-duration", + "border-right-color", + "stroke", + "filter", + "-webkit-line-clamp", + "-webkit-background-size", + "-webkit-box-pack", + "overflow-wrap", + "font-variant", + "-webkit-flex", + "transition-delay", + "variable", + "-webkit-box-flex", + "object-fit", + "flex-basis", + "animation-delay", + "border-bottom-width", + "transition-duration", + "animation-fill-mode", + "will-change", + "border-top-width", + "transition-timing-function", + "order", + "outline-width", + "stroke-width", + "outline-style", + "align-content", + "table-layout", + "appearance", + "border-right-width", + "resize", + "-webkit-backface-visibility", + "-webkit-flex-direction", + "-webkit-animation-timing-function", + "animation-iteration-count", + "flex-flow", + "backface-visibility", + "-webkit-box-direction", + "border-left-width", + "stroke-dasharray", + "stroke-dashoffset", + "-webkit-animation-name", + "-webkit-filter", + "-webkit-filter", + "-webkit-animation-duration", + "unicode-range", + "-webkit-flex-wrap", + "unicode-bidi", + "-webkit-transition-property", + "border-bottom-style", + "speak", + "word-spacing", + "text-size-adjust", + "border-top-style", + "-webkit-transition-duration", + "-webkit-flex-shrink", + "-webkit-flex-grow", + "-webkit-transition-timing-function", + "animation-direction", + "-webkit-animation-delay", + "contain", + "-webkit-animation-fill-mode", + "perspective", + "font-feature-settings", + "-webkit-mask-image", + "-webkit-animation-iteration-count", + "-webkit-align-self", + "image-rendering", + "-webkit-border-top-right-radius", + "clip-path", + "list-style-position", + "-webkit-border-top-left-radius", + "-webkit-border-bottom-right-radius", + "hyphens", + "-webkit-border-bottom-left-radius", + "transform-style", + "-webkit-flex-basis", + "font-display", + "-webkit-transition-delay", + "border-left-style", + "-webkit-flex-flow", + "background-position-x", + "background-attachment", + "border-right-style", + "outline-color", + "animation-play-state", + "margin-block-end", + "-webkit-align-content", + "background-origin", + "-webkit-background-clip", + "-webkit-background-clip", + "-webkit-font-feature-settings", + "-webkit-font-feature-settings", + "-webkit-perspective", + "-webkit-transform-style", + "font-stretch", + "stroke-linecap", + "quotes", + "-webkit-order", + "object-position", + "-webkit-box-ordinal-group", + "background-position-y", + "column-gap", + "scroll-boundary-behavior", + "scroll-boundary-behavior", + "counter-reset", + "counter-increment", + "-webkit-clip-path", + "-webkit-clip-path", + "margin-block-start", + "page-break-inside", + "size", + "column-count", + "-webkit-opacity", + "text-decoration-skip", + "padding-inline-end", + "border-image", + "-webkit-user-drag", + "fill-opacity", + "-webkit-animation-direction", + "-webkit-animation-direction", + "list-style-image", + "all", + "padding-inline-start", + "justify-self", + "text-decoration-color", + "grid-gap", + "page-break-after", + "overflow-anchor", + "empty-cells", + "font-variant-ligatures", + "grid-column", + "stroke-opacity", + "caret-color", + "grid-column-gap", + "margin-inline-start", + "backdrop-filter", + "-webkit-animation-play-state", + "scroll-behavior", + "perspective-origin", + "justify-items", + "margin-inline-end", + "caption-side", + "line-break", + "line-break", + "-webkit-column-gap", + "orphans", + "-webkit-text-fill-color", + "columns", + "mix-blend-mode", + "column-width", + "widows", + "grid-row-gap", + "grid-area", + "-webkit-column-count", + "tab-size", + "stop-color", + "aspect-ratio", + "text-decoration-line", + "column-rule", + "scroll-snap-align", + "scroll-snap-type", + "grid-row", + "border-image-slice", + "border-image-repeat", + "border-image-width", + "text-align-last", + "text-decoration-style", + "stroke-miterlimit", + "border-image-outset", + "grid-auto-flow", + "page-break-before", + "-webkit-box-reflect", + "grid-auto-rows", + "grid-column-start", + "-webkit-mask-size", + "grid-template-areas", + "grid-column-end", + "border-image-source", + "-webkit-margin-start", + "-webkit-margin-start", + "stroke-linejoin", + "column-fill", + "-webkit-print-color-adjust", + "fill-rule", + "font-kerning", + "-webkit-margin-top-collapse", + "color-scheme", + "font-variant-numeric", + "-webkit-margin-before", + "-webkit-margin-before", + "break-inside", + "shape-outside", + "-webkit-padding-start", + "-webkit-padding-start", + "grid-row-start", + "-webkit-margin-end", + "-webkit-margin-end", + "-webkit-user-modify", + "shape-image-threshold", + "-webkit-border-image", + "-webkit-column-width", + "-webkit-margin-after", + "-webkit-margin-after", + "-webkit-perspective-origin", + "-webkit-text-stroke-width", + "border-inline-end-width", + "grid-row-end", + "border-inline-start-width", + "text-decoration-skip-ink", + "-webkit-mask-position", + "background-blend-mode", + "-webkit-mask-repeat", + "scroll-boundary-behavior-y", + "scroll-boundary-behavior-y", + "inset-inline-end", + "content-visibility", + "inset", + "inset-inline-start", + "isolation", + "column-rule-color", + "gap", + "-webkit-column-rule", + "column-rule-style", + "-webkit-mask-box-image", + "-webkit-columns", + "-webkit-column-break-inside", + "grid-auto-columns", + "shape-rendering", + "-webkit-box-decoration-break", + "writing-mode", + "-webkit-box-lines", + "-webkit-text-stroke", + "page", + "scroll-snap-margin", + "scroll-snap-margin", + "-webkit-text-stroke-color", + "clip-rule", + "scroll-boundary-behavior-x", + "scroll-boundary-behavior-x", + "intrinsic-size", + "intrinsic-size", + "row-gap", + "-webkit-padding-end", + "-webkit-padding-end", + "-webkit-mask", + "-webkit-writing-mode", + "font-variant-caps", + "page-orientation", + "text-anchor", + "scroll-padding", + "mask", + "-webkit-background-origin", + "-webkit-background-origin", + "-webkit-text-security", + "place-items", + "forced-color-adjust", + "-webkit-line-break", + "text-underline-position", + "background-repeat-x", + "column-span", + "vector-effect", + "font-variant-east-asian", + "mask-type", + "dominant-baseline", + "stop-opacity", + "break-after", + "scroll-snap-stop", + "break-before", + "grid-template", + "alignment-baseline", + "column-rule-width", + "-webkit-app-region", + "r", + "image-orientation", + "text-decoration-thickness", + "border-inline-start-color", + "border-inline-end-color", + "-webkit-margin-collapse", + "text-orientation", + "-webkit-hyphenate-character", + "padding-block-start", + "cx", + "padding-block-end", + "d", + "min-inline-size", + "baseline-shift", + "inline-size", + "shape-margin", + "-webkit-mask-clip", + "scroll-padding-top", + "-webkit-column-span", + "block-size", + "rx", + "cy", + "-webkit-mask-origin", + "min-block-size", + "background-repeat-y", + "-webkit-rtl-ordering", + "border-block-end-width", + "border-block-end-color", + "border-inline-start-style", + "border-block-end-style", + "border-inline-end-style", + "border-block-start-width", + "-webkit-mask-composite", + "border-block-start-color", + "border-block-start-style", + "place-content", + "scroll-snap-margin-top", + "scroll-snap-margin-top", + "-webkit-text-emphasis-color", + "paint-order", + "font-variation-settings", + "-webkit-border-horizontal-spacing", + "-webkit-border-vertical-spacing", + "ruby-position", + "text-combine-upright", + "y", + "x", + "-webkit-mask-position-y", + "ry", + "-webkit-padding-before", + "-webkit-padding-before", + "-webkit-text-emphasis-position", + "-webkit-padding-after", + "-webkit-padding-after", + "-webkit-text-emphasis-style", + "marker", + "transform-box", + "-webkit-mask-position-x", + "color-interpolation-filters", + "place-self", + "-webkit-locale", + "color-interpolation", + "-webkit-border-before-color", + "-webkit-border-before-color", + "-webkit-text-decorations-in-effect", + "-webkit-border-before-width", + "-webkit-border-before-width", + "text-underline-offset", + "color-rendering", + "-webkit-text-orientation", + "flood-color", + "flood-opacity", + "marker-end", + "lighting-color", + "offset-path", + "marker-start", + "marker-mid", + "buffered-rendering", + "-webkit-text-combine", + "scroll-padding-left", + "offset-distance", + "-webkit-column-rule-color", + "offset-rotate", + "-webkit-mask-box-image-width", + "-webkit-margin-after-collapse", + "-webkit-margin-before-collapse", + "-webkit-column-rule-style", + "-webkit-mask-box-image-source", + "-webkit-mask-box-image-repeat", + "-webkit-mask-box-image-slice", + "-webkit-mask-box-image-outset", + "-webkit-border-before-style", + "-webkit-border-before-style", + "max-inline-size", + "-webkit-transform-origin-x", + "max-block-size", + "-webkit-column-break-after", + "-webkit-transform-origin-y", + "-webkit-column-break-before", + "font-optical-sizing", + "grid", + "-webkit-text-emphasis", + "scroll-padding-inline-start", + "scroll-snap-margin-block-end", + "scroll-snap-margin-block-end", + "scroll-snap-margin-inline-start", + "scroll-snap-margin-inline-start", + "scroll-snap-margin-block-start", + "scroll-snap-margin-block-start", + "scroll-padding-block-end", + "scroll-padding-block-start", + "scroll-snap-margin-inline-end", + "scroll-snap-margin-inline-end", + "scroll-padding-inline-end", + "scroll-padding-bottom", + "-webkit-box-flex-group", + "-webkit-perspective-origin-x", + "-webkit-perspective-origin-y", + "border-inline-end", + "-webkit-shape-outside", + "scroll-snap-margin-left", + "scroll-snap-margin-left", + "inset-block-end", + "-webkit-column-rule-width", + "overscroll-behavior-block", + "inset-block-start", + "overscroll-behavior-inline", + "scroll-snap-margin-right", + "scroll-snap-margin-right", + "scroll-padding-right", + "-webkit-border-end-color", + "-webkit-border-end-color", + "-webkit-border-end-width", + "-webkit-border-end-width", + "-webkit-ruby-position", + "-webkit-border-start-width", + "-webkit-border-start-width", + "-webkit-border-start-color", + "-webkit-border-start-color", + "scroll-snap-margin-bottom", + "scroll-snap-margin-bottom", + "-webkit-border-after-width", + "-webkit-border-after-width", + "-webkit-border-after-color", + "-webkit-border-after-color", + "border-inline-start", + "-webkit-border-end", + "-webkit-border-end", + "margin-inline", + "-webkit-margin-bottom-collapse", + "margin-block", + "padding-inline", + "border-start-end-radius", + "border-end-start-radius", + "border-end-end-radius", + "border-start-start-radius", + "-webkit-border-start", + "-webkit-border-start", + "counter-set", + "offset", + "border-block-end", + "padding-block", + "-webkit-min-logical-width", + "-webkit-min-logical-width", + "border-block-start", + "-webkit-border-after", + "-webkit-border-after", + "inset-inline", + "-webkit-shape-margin", + "inset-block", + "border-block-color", + "border-block", + "scroll-padding-inline", + "scroll-snap-margin-block", + "scroll-snap-margin-block", + "scroll-padding-block", + "scroll-snap-margin-inline", + "scroll-snap-margin-inline", + "-webkit-transform-origin-z", + "-webkit-border-before", + "-webkit-border-before", + "border-inline", + "-webkit-shape-image-threshold", + "-webkit-logical-width", + "-webkit-logical-width", + "-webkit-border-end-style", + "-webkit-border-end-style", + "offset-rotation", + "-webkit-logical-height", + "-webkit-logical-height", + "-webkit-font-size-delta", + "-webkit-border-start-style", + "-webkit-border-start-style", + "-webkit-max-logical-height", + "-webkit-max-logical-height", + "-webkit-max-logical-width", + "-webkit-max-logical-width", + "-webkit-min-logical-height", + "-webkit-min-logical-height", + "border-block-style", + "border-inline-color", + "border-inline-style", + "border-block-width", + "border-inline-width", + "motion", + "motion-offset", + "motion-offset", + "-webkit-border-after-style", + "-webkit-border-after-style", + "font-size-adjust", + "-epub-word-break", + "motion-path", + "motion-path", + "-epub-text-transform", + "-epub-writing-mode", + "scale", + "rotate", + "translate", + "-epub-text-combine", + "animation-timeline", + "scrollbar-gutter", + "snap-height", + "snap-height", + "offset-anchor", + "-webkit-mask-repeat-y", + "math-style", + "math-shift", + "math-depth", + "offset-position", + "-webkit-hyphenate-limit-lines", + "-webkit-mask-repeat-x", + "-epub-text-orientation", + "-epub-text-emphasis-color", + "-epub-text-emphasis-style", + "glyph-orientation-vertical", + "internal-callback", + "text-line-through", + "text-line-through-color", + "text-line-through-mode", + "text-line-through-style", + "text-line-through-width", + "text-overline", + "text-overline-color", + "text-overline-mode", + "text-overline-style", + "text-overline-width", + "text-underline", + "text-underline-color", + "text-underline-mode", + "text-underline-style", + "text-underline-width", + "-webkit-aspect-ratio", + "-webkit-background-composite", + "-webkit-border-fit", + "-webkit-color-correction", + "-webkit-column-axis", + "-webkit-column-progression", + "-webkit-box-decoration-break", + "-webkit-filter", + "-webkit-hyphenate-limit-after", + "-webkit-hyphenate-limit-before", + "-webkit-hyphens", + "-webkit-line-box-contain", + "-webkit-line-align", + "-webkit-line-grid", + "-webkit-line-snap", + "-webkit-marquee", + "-webkit-marquee-direction", + "-webkit-marquee-increment", + "-webkit-marquee-repetition", + "-webkit-marquee-speed", + "-webkit-marquee-style", + "-webkit-nbsp-mode", + "-webkit-flow-into", + "-webkit-flow-from", + "-webkit-region-fragment", + "-webkit-region-break-after", + "-webkit-region-break-before", + "-webkit-region-break-inside", + "shape-inside", + "shape-padding", + "-webkit-wrap-flow", + "-webkit-wrap-through", + "-webkit-wrap", + "-webkit-tap-highlight-color", + "-webkit-app-region", + "enable-background", + "color-profile", + "glyph-orientation-horizontal", + "kerning", + "-webkit-svg-shadow", + "-webkit-cursor-visibility", + "image-orientation", + "image-resolution", + "-webkit-blend-mode", + "-webkit-background-blend-mode", + "max-zoom", + "min-zoom", + "orientation", + "user-zoom", + "-webkit-dashboard-region", + "-webkit-overflow-scrolling", + "mask-source-type", + "touch-action-delay", + "scroll-blocks-on", + "motion-rotation", + "motion-rotation", + "-epub-caption-side", + "-epub-text-emphasis", + "scroll-snap-points-x", + "scroll-snap-points-y", + "scroll-snap-coordinate", + "scroll-snap-destination", + "apply-at-rule", + "viewport-fit", + "overflow-block", + "syntax", + "content-size", + "intrinsic-block-size", + "intrinsic-block-size", + "intrinsic-height", + "intrinsic-height", + "intrinsic-inline-size", + "intrinsic-inline-size", + "intrinsic-width", + "intrinsic-width", + "render-subtree", + "origin-trial-test-property", + "subtree-visibility", + "math-superscript-shift-style", + "start", + "accent-color", + ], + "properties": {} +} diff --git a/idl/core/css/css_property_rule.idl b/idl/core/css/css_property_rule.idl new file mode 100644 index 0000000..c7f02d7 --- /dev/null +++ b/idl/core/css/css_property_rule.idl @@ -0,0 +1,12 @@ +// Copyright 2019 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +[ + Exposed=Window +] interface CSSPropertyRule : CSSRule { + readonly attribute CSSOMString name; + readonly attribute CSSOMString syntax; + readonly attribute boolean inherits; + readonly attribute CSSOMString? initialValue; +}; diff --git a/idl/core/css/css_rule.idl b/idl/core/css/css_rule.idl new file mode 100644 index 0000000..7235a3b --- /dev/null +++ b/idl/core/css/css_rule.idl @@ -0,0 +1,56 @@ +/* + * Copyright (C) 2006, 2007, 2009 Apple Inc. All rights reserved. + * Copyright (C) 2006 Samuel Weinig + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public License + * along with this library; see the file COPYING.LIB. If not, write to + * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + * Boston, MA 02110-1301, USA. + */ + +// https://drafts.csswg.org/cssom/#the-cssrule-interface + +[ + Exposed=Window +] interface CSSRule { + const unsigned short STYLE_RULE = 1; + const unsigned short CHARSET_RULE = 2; + const unsigned short IMPORT_RULE = 3; + const unsigned short MEDIA_RULE = 4; + const unsigned short FONT_FACE_RULE = 5; + const unsigned short PAGE_RULE = 6; + // TODO(foolip): Implement CSSMarginRule. + // const unsigned short MARGIN_RULE = 9; + const unsigned short NAMESPACE_RULE = 10; + readonly attribute unsigned short type; + attribute DOMString cssText; + readonly attribute CSSRule? parentRule; + readonly attribute CSSStyleSheet? parentStyleSheet; + + // CSS Animations + // https://drafts.csswg.org/css-animations/#interface-cssrule + const unsigned short KEYFRAMES_RULE = 7; + const unsigned short KEYFRAME_RULE = 8; + + // CSS Counter Styles + // https://drafts.csswg.org/css-counter-styles-3/#extentions-to-cssrule-interface + const unsigned short COUNTER_STYLE_RULE = 11; + + // CSS Fonts Level 4 + // https://drafts.csswg.org/css-fonts-4/#font-feature-values + const unsigned short FONT_FEATURE_VALUES_RULE = 14; + + // CSS Conditional Rules + // https://drafts.csswg.org/css-conditional/#extentions-to-cssrule-interface + const unsigned short SUPPORTS_RULE = 12; +}; diff --git a/idl/core/css/css_rule_list.idl b/idl/core/css/css_rule_list.idl new file mode 100644 index 0000000..1ed135b --- /dev/null +++ b/idl/core/css/css_rule_list.idl @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2006, 2007, 2009 Apple Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY + * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://drafts.csswg.org/cssom/#the-cssrulelist-interface + +[ + Exposed=Window +] interface CSSRuleList { + [Measure] getter CSSRule? item(unsigned long index); + readonly attribute unsigned long length; +}; diff --git a/idl/core/css/css_scope_rule.idl b/idl/core/css/css_scope_rule.idl new file mode 100644 index 0000000..a488155 --- /dev/null +++ b/idl/core/css/css_scope_rule.idl @@ -0,0 +1,11 @@ +// Copyright 2022 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +[ + Exposed=Window, + RuntimeEnabled=CSSScope +] interface CSSScopeRule : CSSGroupingRule { + readonly attribute CSSOMString? start; + readonly attribute CSSOMString? end; +}; diff --git a/idl/core/css/css_starting_style_rule.idl b/idl/core/css/css_starting_style_rule.idl new file mode 100644 index 0000000..040d019 --- /dev/null +++ b/idl/core/css/css_starting_style_rule.idl @@ -0,0 +1,8 @@ +// Copyright 2023 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +[ + Exposed=Window +] interface CSSStartingStyleRule : CSSGroupingRule { +}; diff --git a/idl/core/css/css_style_declaration.idl b/idl/core/css/css_style_declaration.idl new file mode 100644 index 0000000..8f1cee0 --- /dev/null +++ b/idl/core/css/css_style_declaration.idl @@ -0,0 +1,46 @@ +/* + * Copyright (C) 2006, 2007, 2009 Apple Inc. All rights reserved. + * Copyright (C) 2006 Samuel Weinig + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public License + * along with this library; see the file COPYING.LIB. If not, write to + * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + * Boston, MA 02110-1301, USA. + */ + +// https://drafts.csswg.org/cssom/#the-cssstyledeclaration-interface + +[ + Exposed=Window +] interface CSSStyleDeclaration { + [CEReactions, RaisesException=Setter, SetterCallWith=ExecutionContext] attribute DOMString cssText; + readonly attribute unsigned long length; + [Affects=Nothing] getter DOMString item(unsigned long index); + DOMString getPropertyValue(DOMString property); + DOMString getPropertyPriority(DOMString property); + [CEReactions, RaisesException, CallWith=ExecutionContext] void setProperty(DOMString property, [LegacyNullToEmptyString] DOMString value, optional [LegacyNullToEmptyString] DOMString priority = ""); + // void setPropertyValue(DOMString property, [LegacyNullToEmptyString] DOMString value); + // void setPropertyPriority(DOMString property, [LegacyNullToEmptyString] DOMString priority); + [CEReactions, RaisesException] DOMString removeProperty(DOMString property); + readonly attribute CSSRule? parentRule; + [CEReactions, SetterCallWith=ExecutionContext, RaisesException=Setter] attribute [LegacyNullToEmptyString] DOMString cssFloat; + + // The camel-cased and dashed attribute getters have custom bindings. + // https://drafts.csswg.org/cssom/#dom-cssstyledeclaration-camel-cased-attribute + // https://drafts.csswg.org/cssom/#dom-cssstyledeclaration-dashed-attribute + [Affects=Nothing] getter DOMString (DOMString name); + // The type of `propertyValue` is `any` in order not to perform any type + // conversion which may have side effect (c.f. https://crbug.com/1310062 ). + [CEReactions, CallWith=ScriptState] setter void (DOMString property, any propertyValue); + deleter void (DOMString property); +}; diff --git a/idl/core/css/css_style_rule.idl b/idl/core/css/css_style_rule.idl new file mode 100644 index 0000000..94bac7f --- /dev/null +++ b/idl/core/css/css_style_rule.idl @@ -0,0 +1,34 @@ +/* + * Copyright (C) 2006, 2007 Apple Inc. All rights reserved. + * Copyright (C) 2006 Samuel Weinig + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public License + * along with this library; see the file COPYING.LIB. If not, write to + * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + * Boston, MA 02110-1301, USA. + */ + +// https://drafts.csswg.org/cssom/#the-cssstylerule-interface + +[ + Exposed=Window +] interface CSSStyleRule : CSSRule { + [SetterCallWith=ExecutionContext] attribute DOMString selectorText; + [SameObject, PutForwards=cssText] readonly attribute CSSStyleDeclaration style; + [SameObject, MeasureAs=CSSTypedOMStylePropertyMap] readonly attribute StylePropertyMap styleMap; + + // https://drafts.csswg.org/css-nesting-1/#cssom-style + [SameObject] readonly attribute CSSRuleList cssRules; + [RaisesException, CallWith=ExecutionContext] unsigned long insertRule(DOMString rule, optional unsigned long index = 0); + [RaisesException] void deleteRule(unsigned long index); +}; diff --git a/idl/core/css/css_style_sheet.idl b/idl/core/css/css_style_sheet.idl new file mode 100644 index 0000000..8057a34 --- /dev/null +++ b/idl/core/css/css_style_sheet.idl @@ -0,0 +1,39 @@ +/* + * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved. + * Copyright (C) 2006 Samuel Weinig + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public License + * along with this library; see the file COPYING.LIB. If not, write to + * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + * Boston, MA 02110-1301, USA. + */ + +// https://drafts.csswg.org/cssom/#the-cssstylesheet-interface + +[ + Exposed=Window +] interface CSSStyleSheet : StyleSheet { + [CallWith=Document, RaisesException] constructor(optional CSSStyleSheetInit options = {}); + readonly attribute CSSRule? ownerRule; + [SameObject, RaisesException] readonly attribute CSSRuleList cssRules; + [RaisesException] unsigned long insertRule(DOMString rule, optional unsigned long index = 0); + [RaisesException] void deleteRule(unsigned long index); + + [MeasureAs=CSSStyleSheetReplace, CallWith=ScriptState, RaisesException] Promise replace(DOMString text); + [MeasureAs=CSSStyleSheetReplaceSync, RaisesException] void replaceSync(DOMString text); + + // Non-standard APIs + [MeasureAs=CSSStyleSheetRules, RaisesException] readonly attribute CSSRuleList rules; + [MeasureAs=CSSStyleSheetAddRule, RaisesException] long addRule(optional DOMString selector = "undefined", optional DOMString style = "undefined", optional unsigned long index); + [MeasureAs=CSSStyleSheetRemoveRule, RaisesException] void removeRule(optional unsigned long index = 0); +}; diff --git a/idl/core/css/css_style_sheet_init.idl b/idl/core/css/css_style_sheet_init.idl new file mode 100644 index 0000000..001278c --- /dev/null +++ b/idl/core/css/css_style_sheet_init.idl @@ -0,0 +1,10 @@ +// Copyright 2018 The Chromium Authors +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +dictionary CSSStyleSheetInit { + (MediaList or DOMString) media = ""; + DOMString title = ""; + boolean alternate = false; + boolean disabled = false; +}; diff --git a/idl/core/css/css_supports_rule.idl b/idl/core/css/css_supports_rule.idl new file mode 100644 index 0000000..2cfb265 --- /dev/null +++ b/idl/core/css/css_supports_rule.idl @@ -0,0 +1,34 @@ +/* Copyright (C) 2012 Motorola Mobility Inc. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the distribution. + * 3. Neither the name of Motorola Mobility Inc. nor the names of its + * contributors may be used to endorse or promote products derived from this + * software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +// https://drafts.csswg.org/css-conditional/#the-csssupportsrule-interface + +[ + Exposed=Window +] interface CSSSupportsRule : CSSConditionRule { +}; diff --git a/idl/core/css/css_value_keywords.json5 b/idl/core/css/css_value_keywords.json5 new file mode 100644 index 0000000..d6b0e9c --- /dev/null +++ b/idl/core/css/css_value_keywords.json5 @@ -0,0 +1,1870 @@ +{ + // The mode argument is used to limit the keyword to be used only for certain + // CSSParserModes. Values that have the prefix -internal- are only allowed by + // CSSParserModes listed in CSSValueKeywordsWriter, which feeds the generated + // code for isValueAllowedInMode. + + parameters: { + mode: {}, + }, + + // + // CSS value names + // + + data: [ + + "inherit", + "initial", + // + // outline-style + // border-top-style + // border-bottom-style + // border-left-style + // border-right-style + // The order here must match the order of the EBorderStyle enum in ComputedStyleConstants.h. + "none", + "hidden", + "inset", + "groove", + "outset", + "ridge", + "dotted", + "dashed", + "solid", + "double", + + // + // font + // + "caption", + "icon", + "menu", + "message-box", + "small-caption", + "-webkit-mini-control", + "-webkit-small-control", + "-webkit-control", + "status-bar", + + // + // font-style + // + //normal + "italic", + "oblique", + // The following is only allowed in @font-face: + "all", + + // font-variant-ligatures: + // + // normal + "common-ligatures", + "no-common-ligatures", + "discretionary-ligatures", + "no-discretionary-ligatures", + "historical-ligatures", + "no-historical-ligatures", + "contextual", + "no-contextual", + + // font-variant-caps: + // + // normal + "small-caps", + "all-small-caps", + "petite-caps", + "all-petite-caps", + "unicase", + "titling-caps", + + // font-variant-caps: + // + // normal + "jis78", + "jis83", + "jis90", + "jis04", + "simplified", + "traditional", + "full-width", + "proportional-width", + "ruby", + + // font-variant-numeric + // normal + "lining-nums", + "oldstyle-nums", + "proportional-nums", + "tabular-nums", + "diagonal-fractions", + "stacked-fractions", + "ordinal", + "slashed-zero", + + // font-variant-alternates + "stylistic", + "historical-forms", + "styleset", + "character-variant", + "swash", + "ornaments", + "annotation", + + // + // font-weight + // + "normal", + "bold", + "bolder", + "lighter", + + // font-synthesis + // none + // style + // small-caps + "weight", + + // + // font-stretch + // + "ultra-condensed", + "extra-condensed", + "condensed", + "semi-condensed", + "semi-expanded", + "expanded", + "extra-expanded", + "ultra-expanded", + + // + // font-size + // + "xx-small", + "x-small", + "small", + "medium", + "large", + "x-large", + "xx-large", + "xxx-large", + "smaller", + "larger", + "-webkit-xxx-large", + // math + + // + // font-size-adjust + // + //none + "ex-height", + "cap-height", + "ch-width", + "ic-width", + // from-font + + // + // font-family ( in CSS 2.1) + // + // If you modify this list, please make sure you update css_parsing_utils's + // ConsumeGenericFamily, ComputedStyleUtils::IdentifierForFamily and + // FontFamily::InferredTypeFor accordingly. + "serif", + "sans-serif", + "cursive", + "fantasy", + "monospace", + "system-ui", + "-webkit-body", + "math", + + // + // font-display + // + //auto + //block + "swap", + "fallback", + "optional", + + // https://drafts.csswg.org/css-conditional-5/#typedef-supports-font-tech-fn + "font-tech", + "font-format", + + // + // font-palette animation + // + "palette-mix", + + // + // *-color + // + "aqua", + "black", + "blue", + "fuchsia", + "gray", + "green", + "lime", + "maroon", + "navy", + "olive", + "orange", + "purple", + "red", + "silver", + "teal", + "white", + "yellow", + "transparent", + "-webkit-link", + "-webkit-activelink", + "accentcolor", + "accentcolortext", + "activeborder", + "activecaption", + "activetext", + "appworkspace", + "background", + "buttonborder", + "buttonface", + "buttonhighlight", + "buttonshadow", + "buttontext", + "canvas", + "canvastext", + "captiontext", + "field", + "fieldtext", + "graytext", + "highlight", + "highlighttext", + "inactiveborder", + "inactivecaption", + "inactivecaptiontext", + "infobackground", + "infotext", + "linktext", + "mark", + "marktext", + "menutext", + "selecteditem", + "selecteditemtext", + "scrollbar", + "threeddarkshadow", + "threedface", + "threedhighlight", + "threedlightshadow", + "threedshadow", + "visitedtext", + "window", + "windowframe", + "windowtext", + "-internal-active-list-box-selection", + "-internal-active-list-box-selection-text", + "-internal-inactive-list-box-selection", + "-internal-inactive-list-box-selection-text", + { + name: "-webkit-focus-ring-color", + mode: "QuirksOrUASheet", + }, + "currentcolor", + "grey", + // + // Value used to implement the behavior in: + // https://quirks.spec.whatwg.org/#the-tables-inherit-color-from-body-quirk + "-internal-quirk-inherit", + // + // css-text-decor + // + "-internal-spelling-error-color", + "-internal-grammar-error-color", + + // + // "Extended" named colors + // + "aliceblue", + "antiquewhite", + "aquamarine", + "azure", + "beige", + "bisque", + "blanchedalmond", + "blueviolet", + "brown", + "burlywood", + "cadetblue", + "chartreuse", + "chocolate", + "coral", + "cornflowerblue", + "cornsilk", + "crimson", + "cyan", + "darkblue", + "darkcyan", + "darkgoldenrod", + "darkgray", + "darkgreen", + "darkgrey", + "darkkhaki", + "darkmagenta", + "darkolivegreen", + "darkorange", + "darkorchid", + "darkred", + "darksalmon", + "darkseagreen", + "darkslateblue", + "darkslategray", + "darkslategrey", + "darkturquoise", + "darkviolet", + "deeppink", + "deepskyblue", + "dimgray", + "dimgrey", + "dodgerblue", + "firebrick", + "floralwhite", + "forestgreen", + "gainsboro", + "ghostwhite", + "gold", + "goldenrod", + "greenyellow", + "honeydew", + "hotpink", + "indianred", + "indigo", + "ivory", + "khaki", + "lavender", + "lavenderblush", + "lawngreen", + "lemonchiffon", + "lightblue", + "lightcoral", + "lightcyan", + "lightgoldenrodyellow", + "lightgray", + "lightgreen", + "lightgrey", + "lightpink", + "lightsalmon", + "lightseagreen", + "lightskyblue", + "lightslategray", + "lightslategrey", + "lightsteelblue", + "lightyellow", + "limegreen", + "linen", + "magenta", + "mediumaquamarine", + "mediumblue", + "mediumorchid", + "mediumpurple", + "mediumseagreen", + "mediumslateblue", + "mediumspringgreen", + "mediumturquoise", + "mediumvioletred", + "midnightblue", + "mintcream", + "mistyrose", + "moccasin", + "navajowhite", + "oldlace", + "olivedrab", + "orangered", + "orchid", + "palegoldenrod", + "palegreen", + "paleturquoise", + "palevioletred", + "papayawhip", + "peachpuff", + "peru", + "pink", + "plum", + "powderblue", + "rebeccapurple", + "rosybrown", + "royalblue", + "saddlebrown", + "salmon", + "sandybrown", + "seagreen", + "seashell", + "sienna", + "skyblue", + "slateblue", + "slategray", + "slategrey", + "snow", + "springgreen", + "steelblue", + "tan", + "thistle", + "tomato", + "turquoise", + "violet", + "wheat", + "whitesmoke", + "yellowgreen", + + // + // background-repeat + // + "repeat", + "repeat-x", + "repeat-y", + "no-repeat", + // round + // space + // + // -webkit-mask-composite + // + "clear", + "copy", + "source-over", + "source-in", + "source-out", + "source-atop", + "destination-over", + "destination-in", + "destination-out", + "destination-atop", + "xor", + // highlight + "plus-lighter", + + // + // mask-composite + // + // "add", + "subtract", + "intersect", + "exclude", + + // + // vertical-align + // + "baseline", + "middle", + "sub", + "super", + "text-top", + "text-bottom", + "top", + "bottom", + // HTML alignment MIDDLE has no corresponding CSS alignment + "-webkit-baseline-middle", + // + // text-align + // The order and contents this block MUST match the kTextAlign[Last] cases + // of CSSParserFastPaths::IsValidKeywordPropertyAndValue(). + // + "-webkit-auto", + "left", + "right", + "center", + "justify", + "-webkit-left", + "-webkit-right", + "-webkit-center", + "-webkit-match-parent", + "-internal-center", + // + // float, clear, etc. + // + "inline-start", + "inline-end", + // + // list-style-position + // + "outside", + "inside", + // + // list-style-type + // + "disc", + "circle", + "square", + "disclosure-open", + "disclosure-closed", + "decimal", + //none + // + // The order must match the order found in IsDisplayOutside(). + "inline", + "block", + // The order must match the order found in IsDisplayInside(). + "flow-root", + "flow", + "table", + "flex", + "grid", + //"math", + //"ruby", + // The order must match the order found in IsDisplayBox(). + "contents", + //none + // The order must match the order found in IsDisplayInternal(). + "table-row-group", + "table-header-group", + "table-footer-group", + "table-row", + "table-column-group", + "table-column", + "table-cell", + "table-caption", + "ruby-text", + // The order must match the order found in IsDisplayLegacy(). + "inline-block", + "inline-table", + "inline-flex", + "inline-grid", + "-webkit-box", + "-webkit-inline-box", + "-webkit-flex", + "-webkit-inline-flex", + "layout", + "inline-layout", + "list-item", + // + // cursor + // The order of this enum must match the order found in CSSPropertyParser::ConsumeCursor(). + // + "auto", + "crosshair", + "default", + "pointer", + "move", + "vertical-text", + "cell", + "context-menu", + "alias", + // copy + "progress", + "no-drop", + "not-allowed", + "zoom-in", + "zoom-out", + "e-resize", + "ne-resize", + "nw-resize", + "n-resize", + "se-resize", + "sw-resize", + "s-resize", + "w-resize", + "ew-resize", + "ns-resize", + "nesw-resize", + "nwse-resize", + "col-resize", + "row-resize", + "text", + "wait", + "help", + "all-scroll", + "grab", + "grabbing", + "-webkit-grab", + "-webkit-grabbing", + "-webkit-zoom-in", + "-webkit-zoom-out", + // none + // + // direction + // + "ltr", + "rtl", + // + // text-transform + // + "capitalize", + "uppercase", + "lowercase", + //none + "math-auto", + // + // visibility + // + "visible", + //hidden + "collapse", + // + // white-space and its longhands (white-space-collapse and text-wrap) + // https://w3c.github.io/csswg-drafts/css-text-4/#white-space-property + // + "preserve", + "preserve-breaks", + "pretty", + // + // Unordered rest + // + "a3", + "a4", + "a5", + "above", + "absolute", + "always", + "avoid", + "b4", + "b5", + "below", + "bidi-override", + "blink", + "both", + "break-spaces", + "close-quote", + "embed", + "fixed", + "hand", + "hide", + "isolate", + "isolate-override", + "plaintext", + "-webkit-isolate", + "-webkit-isolate-override", + "-webkit-plaintext", + "jis-b5", + "jis-b4", + "landscape", + "ledger", + "legal", + "letter", + "line-through", + "local", + "no-close-quote", + "no-open-quote", + "nowrap", + "open-quote", + "overlay", + "overline", + "portrait", + "pre", + "pre-line", + "pre-wrap", + "relative", + "scroll", + "separate", + "show", + "static", + "thick", + "thin", + "underline", + "view", + "wavy", + + // math-shift + // normal + "compact", + + // math-style + // normal + // compact + + // CSS3 Values + // box-align + "stretch", + "start", + "end", + //center + //baseline + + // box-decoration-break + "clone", + "slice", + + // box-direction + // normal + "reverse", + + // box-orient + "horizontal", + "vertical", + "inline-axis", + "block-axis", + + // box-pack + // start + // end + // center + // justify + + // align-content + // start + // end + "flex-start", + "flex-end", + // center + "space-between", + "space-around", + "space-evenly", + // stretch + "unsafe", + "safe", + + // align-items / align-self + // flex-start + // flex-end + // center + // baseline + // last baseline, + // first baseline, + // stretch + "anchor-center", + + // justify-content + // start + // end + // flex-start + // flex-end + // center + // space-between + // space-around + // space-evenly + // stretch + // unsafe + // safe + + + // flex-flow + "row", + "row-reverse", + "column", + "column-reverse", + // nowrap + "wrap", + "wrap-reverse", + + // grid-auto-flow + "auto-flow", + "dense", + + // + // -webkit-user-modify + // + "read-only", + "read-write", + "read-write-plaintext-only", + + // + // -webkit-user-drag + // + "element", + + // + // CSS3 intrinsic dimension keywords + // + "-webkit-min-content", + "-webkit-max-content", + "-webkit-fill-available", + "-webkit-fit-content", + "min-content", + "max-content", + "fit-content", + + // + // text-autospace + // + // normal + "no-autospace", + + // + // text-box-edge + // + // "alphabetic", + // "text" + // + // not implemented + // "ideographic", + // "ideographic-ink", + "cap", + "ex", + "leading", + + // + // text-overflow + // + "clip", + "ellipsis", + + // + // text-decoration-line + // + "spelling-error", + "grammar-error", + + // + // text-decoration-skip-ink + // + // auto + // none + + // + // text-decoration-thickness + // + // auto + "from-font", + + // + // text-spacing-trim + // + // normal + "space-all", + "space-first", + "trim-start", + + // text-underline-position + // auto + // "from-font", + // under + // left + // right + + // + // word-break + // + "break-all", + "keep-all", + "auto-phrase", + + // + // word-wrap + // + "break-word", + + // + // nbsp-mode + // + "space", + + // + // -webkit-line-break + // + // auto + "loose", + // normal + "strict", + "after-white-space", + "anywhere", + + // hyphens + "manual", + + // -webkit-appearance + "checkbox", + "radio", + "button", + "listbox", + "-internal-media-control", + "menulist", + "menulist-button", + "meter", + "progress-bar", + "searchfield", + "textfield", + "textarea", + // TODO(crbug/924486) All appearance values that should not be accepted by the parser (high usage). + "inner-spin-button", + "push-button", + "square-button", + "slider-horizontal", + "searchfield-cancel-button", + // TODO(crbug/924486) All appearance values that should not be accepted by the parser (low usage). + "media-slider", + "media-sliderthumb", + "media-volume-slider", + "media-volume-sliderthumb", + "sliderthumb-horizontal", + "sliderthumb-vertical", + // TODO(crbug/1426629) All appearance values that should not be accepted by the parser (special case). + "slider-vertical", + // + // border-image + // + // stretch + // repeat + "round", + // TODO(crbug.com/1511354): "bikeshed" is a temporary name for stylable + //