blob: 50f8192285170a18336ee73e294980faee3646a4 [file] [log] [blame]
// 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() / anchor-size()
"left",
"right",
"top",
"bottom",
// anchor-size()
"width",
"height",
]
},
// When specified on a property/field, this will generate code within
// ComputedStyleBase::FieldInvalidationDiff to check if the property/field
// has changed, and if so set a flag indicating this.
//
// Example usage:
// if (field_diff & kBorderRadius) {
// diff.SetBorderRadiusChanged();
// }
//
// The diff can also be used to "guard" against more expensive checks, e.g:
// if ((field_diff & kOutline) && !OutlineVisuallyEqual(other)) {
// return true;
// }
//
// This is to be **only** used within ComputedStyle::VisualInvalidationDiff
// and will generally be more efficient than comparing fields directly.
invalidate: {
default: [],
valid_type: "list",
valid_values: [
"accent-color",
"background",
"background-color",
"background-current-color",
"blend-mode",
"border-image",
"border-outline-visited-color",
"border-radius",
"border-visual",
"border-width",
"clip",
"clip-path",
"color",
"compositing",
"corner-shape",
"filter-data",
"has-transform",
"inset",
"layout",
"margin",
"mask",
"opacity",
"outline",
"out-of-flow",
"paint",
"reshape",
"scroll-anchor",
"scrollbar-color",
"scrollbar-style",
"stroke",
"text-decoration",
"transform-data",
"transform-other",
"transform-property",
"visibility",
"visual-overflow",
"z-index",
],
},
// 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<String>', 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. Note that 'name_for_methods' also determines the name
// of the generated field on ComputedStyle.
// - 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", "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_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 <permission> 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: "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,
},
{
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,
},
{
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,
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: "animation-trigger-range-start",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"],
style_builder_template: "animation",
style_builder_template_args: {
attribute: "TriggerRangeStart",
},
separator: ",",
valid_for_marker: true,
runtime_flag: "AnimationTrigger",
},
{
name: "animation-trigger-range-end",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"],
style_builder_template: "animation",
style_builder_template_args: {
attribute: "TriggerRangeEnd",
},
separator: ",",
valid_for_marker: true,
runtime_flag: "AnimationTrigger",
},
{
name: "animation-trigger-exit-range-start",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"],
style_builder_template: "animation",
style_builder_template_args: {
attribute: "TriggerExitRangeStart",
},
separator: ",",
valid_for_marker: true,
runtime_flag: "AnimationTrigger",
},
{
name: "animation-trigger-exit-range-end",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"],
style_builder_template: "animation",
style_builder_template_args: {
attribute: "TriggerExitRangeEnd",
},
separator: ",",
valid_for_marker: true,
runtime_flag: "AnimationTrigger",
},
{
name: "animation-trigger-timeline",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"],
style_builder_template: "animation",
style_builder_template_args: {
attribute: "TriggerTimeline",
},
keywords: ["none", "auto"],
typedom_types: ["Keyword"],
separator: ",",
valid_for_marker: true,
runtime_flag: "AnimationTrigger",
},
{
name: "animation-trigger-type",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal", "InitialValue"],
style_builder_template: "animation",
style_builder_template_args: {
attribute: "TriggerType",
},
keywords: ["once", "repeat", "alternate", "state"],
typedom_types: ["Keyword"],
separator: ",",
valid_for_marker: true,
runtime_flag: "AnimationTrigger",
},
{
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",
keywords: ["normal", "allow-discrete"],
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,
},
{
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,
is_highlight_colors: true,
supports_incremental_style: true,
valid_for_permission_element: true,
valid_for_page_context: true,
invalidate: ["accent-color", "background-current-color", "border-visual", "color", "outline"],
},
{
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_page_context: true,
invalidate: ["reshape"],
},
{
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_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,
// 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,
// 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", "ic-height", "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,
// 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,
// 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,
// 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,
// 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,
// 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,
// 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,
// 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,
// 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,
// 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,
// See comment on font.
supports_incremental_style: false,
},
{
name: "font-variant-emoji",
property_methods: ["CSSValueFromComputedStyleInternal"],
inherited: true,
runtime_flag: "FontVariantEmoji",
font: true,
name_for_methods: "VariantEmoji",
type_name: "FontDescription::FontVariantEmoji",
converter: "ConvertFontVariantEmoji",
priority: 1,
keywords: ["normal", "text", "emoji", "unicode"],
typedom_types: ["Keyword"],
valid_for_first_letter: true,
valid_for_first_line: true,
valid_for_marker: true,
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"],
invalidate: ["layout"],
},
{
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,
invalidate: ["layout", "paint"],
},
{
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",
"sideways-rl", "sideways-lr"],
typedom_types: ["Keyword"],
default_value: "horizontal-tb",
type_name: "WritingMode",
style_builder_custom_functions: ["initial", "inherit", "value"],
priority: 1,
valid_for_page_context: true,
// Incremental code does not call DidChangeWritingMode(), which influences
// the font.
supports_incremental_style: false,
invalidate: ["layout", "paint"],
},
{
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,
invalidate: ["accent-color"],
},
{
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",
invalidate: ["layout"],
},
{
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",
invalidate: ["layout"],
},
{
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",
invalidate: ["layout", "paint"],
},
{
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,
invalidate: ["layout"],
},
{
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"],
valid_for_permission_element: true,
invalidate: ["layout"],
},
{
name: "anchor-scope",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal" ],
include_paths: ["third_party/blink/renderer/core/style/style_anchor_scope.h"],
type_name: "StyleAnchorScope",
default_value: "StyleAnchorScope()",
field_group: "*",
field_template: "external",
converter: "ConvertAnchorScope",
keywords: ["none", "all"],
typedom_types: ["Keyword"],
runtime_flag: "CSSAnchorScope",
valid_for_permission_element: true,
invalidate: ["layout"],
},
{
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,
invalidate: ["layout"],
},
{
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"],
invalidate: ["compositing"],
},
{
name: "backface-visibility",
property_methods: ["CSSValueFromComputedStyleInternal"],
field_group: "*",
field_template: "keyword",
keywords: ["visible", "hidden"],
typedom_types: ["Keyword"],
default_value: "visible",
invalidate: ["compositing"],
},
{
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,
invalidate: ["background-color"],
},
{
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"],
invalidate: ["layout", "paint"],
},
{
name: "baseline-source",
property_methods: ["CSSValueFromComputedStyleInternal"],
field_group: "box",
field_template: "keyword",
default_value: "auto",
keywords: ["auto", "first", "last"],
typedom_types: ["Keyword"],
invalidate: ["layout"],
},
{
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,
invalidate: ["border-visual"],
},
{
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,
invalidate: ["border-radius", "paint"],
},
{
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,
invalidate: ["border-radius", "paint"],
},
{
name: "border-bottom-style",
property_methods: ["ParseSingleValue", "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,
invalidate: ["border-width", "border-visual"],
},
{
name: "border-bottom-width",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"],
interpolable: true,
field_group: "box",
field_template: "external",
keywords: ["thin", "medium", "thick"],
default_value: "3",
typedom_types: ["Keyword", "Length"],
type_name: "int",
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,
invalidate: ["border-width", "border-visual"],
},
{
name: "border-collapse",
property_methods: ["CSSValueFromComputedStyleInternal"],
independent: true,
inherited: true,
field_template: "keyword",
keywords: ["separate", "collapse"],
typedom_types: ["Keyword"],
default_value: "separate",
invalidate: ["layout", "paint"],
},
{
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,
invalidate: ["border-visual"],
},
{
name: "border-left-style",
property_methods: ["ParseSingleValue", "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,
invalidate: ["border-width", "border-visual"],
},
{
name: "border-left-width",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"],
interpolable: true,
field_group: "box",
field_template: "external",
keywords: ["thin", "medium", "thick"],
default_value: "3",
typedom_types: ["Keyword", "Length"],
type_name: "int",
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,
invalidate: ["border-width", "border-visual"],
},
{
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,
invalidate: ["border-visual"],
},
{
name: "border-right-style",
property_methods: ["ParseSingleValue", "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,
invalidate: ["border-width", "border-visual"],
},
{
name: "border-right-width",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"],
interpolable: true,
field_group: "box",
field_template: "external",
keywords: ["thin", "medium", "thick"],
default_value: "3",
typedom_types: ["Keyword", "Length"],
type_name: "int",
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,
invalidate: ["border-width", "border-visual"],
},
{
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,
invalidate: ["border-visual"],
},
{
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,
invalidate: ["border-radius", "paint"],
},
{
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,
invalidate: ["border-radius", "paint"],
},
{
name: "border-top-style",
property_methods: ["ParseSingleValue", "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,
invalidate: ["border-width", "border-visual"],
},
{
name: "border-top-width",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"],
interpolable: true,
field_group: "box",
field_template: "external",
keywords: ["thin", "medium", "thick"],
default_value: "3",
typedom_types: ["Keyword", "Length"],
type_name: "int",
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,
invalidate: ["border-width", "border-visual"],
},
{
name: "bottom",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"],
interpolable: true,
layout_dependent: true,
field_group: "surround",
field_template: "<length>",
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,
invalidate: ["inset", "out-of-flow", "scroll-anchor"],
},
{
name: "box-decoration-break",
property_methods: ["CSSValueFromComputedStyleInternal"],
field_group: "box",
field_template: "keyword",
keywords: ["slice", "clone"],
default_value: "slice",
invalidate: ["layout", "paint"],
runtime_flag: "BoxDecorationBreak",
},
{
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: "Member",
default_value: "nullptr",
type_name: "ShadowList",
converter: "ConvertShadowList",
keywords: ["none"],
typedom_types: ["Keyword"],
valid_for_first_letter: true,
valid_for_first_line: true,
invalidate: ["paint", "visual-overflow"],
},
{
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,
invalidate: ["layout"],
},
{
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",
field_group: "*",
keywords: [
"auto", "avoid", "avoid-column", "avoid-page", "column", "left", "page",
"recto", "right", "verso"
],
typedom_types: ["Keyword"],
default_value: "auto",
type_name: "EBreakBetween",
invalidate: ["layout"],
},
{
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",
field_group: "*",
keywords: [
"auto", "avoid", "avoid-column", "avoid-page", "column", "left", "page",
"recto", "right", "verso"
],
typedom_types: ["Keyword"],
default_value: "auto",
type_name: "EBreakBetween",
invalidate: ["layout"],
},
{
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",
field_group: "*",
keywords: ["auto", "avoid", "avoid-column", "avoid-page"],
typedom_types: ["Keyword"],
default_value: "auto",
invalidate: ["layout"],
},
{
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",
invalidate: ["layout", "paint"],
},
{
name: "caret-animation",
property_methods: ["CSSValueFromComputedStyleInternal"],
inherited: true,
field_template: "keyword",
keywords: ["auto", "manual"],
default_value: "auto",
typedom_types: ["Keyword"],
invalidate: ["paint"],
runtime_flag: "CSSCaretAnimation",
},
{
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,
invalidate: ["color"],
},
{
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,
invalidate: ["layout", "paint"],
},
{
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"],
invalidate: ["clip"],
},
{
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"],
invalidate: ["clip-path"],
},
{
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"],
invalidate: ["paint"],
},
{
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"],
invalidate: ["paint"],
},
{
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"],
invalidate: ["paint"],
},
{
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<AtomicString>",
default_value: "Vector<AtomicString, 0>()",
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,
invalidate: ["layout", "paint"],
},
{
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<Containment>",
keywords: ["none", "strict", "content", "size", "layout", "style", "paint", "inline-size", "block-size"],
typedom_types: ["Keyword"],
computable: false,
valid_for_permission_element: true,
invalidate: ["layout"],
},
{
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,
invalidate: ["layout", "scroll-anchor"],
},
{
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,
invalidate: ["layout", "scroll-anchor"],
},
{
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<EContainerType, CSSValueID::kNormal>",
typedom_types: ["Keyword"],
valid_for_permission_element: true,
invalidate: ["layout"],
},
{
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,
valid_for_page_context: true,
supports_incremental_style: true,
},
{
name: "corner-bottom-left-shape",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"],
interpolable: true,
field_group: "surround",
field_template: "external",
default_value: "Superellipse::Round()",
include_paths: ["third_party/blink/renderer/core/style/superellipse.h"],
type_name: "Superellipse",
converter: "ConvertCornerShape",
valid_for_first_letter: true,
logical_property_group: {
name: "corner-shape",
resolver: "bottom-left",
},
runtime_flag: "CSSCornerShape",
valid_for_permission_element: true,
valid_for_page_context: true,
invalidate: ["border-radius", "paint"],
},
{
name: "corner-bottom-right-shape",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"],
interpolable: true,
field_group: "surround",
field_template: "external",
default_value: "Superellipse::Round()",
include_paths: ["third_party/blink/renderer/core/style/superellipse.h"],
type_name: "Superellipse",
converter: "ConvertCornerShape",
valid_for_first_letter: true,
logical_property_group: {
name: "corner-shape",
resolver: "bottom-right",
},
runtime_flag: "CSSCornerShape",
valid_for_permission_element: true,
valid_for_page_context: true,
invalidate: ["border-radius", "paint"],
},
{
name: "corner-top-left-shape",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"],
interpolable: true,
field_group: "surround",
field_template: "external",
default_value: "Superellipse::Round()",
include_paths: ["third_party/blink/renderer/core/style/superellipse.h"],
type_name: "Superellipse",
converter: "ConvertCornerShape",
valid_for_first_letter: true,
logical_property_group: {
name: "corner-shape",
resolver: "top-left",
},
runtime_flag: "CSSCornerShape",
valid_for_permission_element: true,
valid_for_page_context: true,
invalidate: ["border-radius", "paint"],
},
{
name: "corner-top-right-shape",
property_methods: ["ParseSingleValue", "CSSValueFromComputedStyleInternal"],
interpolable: true,
field_group: "surround",
field_template: "external",
default_value: "Superellipse::Round()",
include_paths: ["third_party/blink/renderer/core/style/superellipse.h"],
type_name: "Superellipse",
converter: "ConvertCornerShape",
valid_for_first_letter: true,
logical_property_group: {
name: "corner-shape",
resolver: "top-right",
},
runtime_flag: "CSSCornerShape",
valid_for_permission_element: true,
valid_for_page_context: true,
invalidate: ["border-radius", "paint"],
},
{
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",