Skip to main content

StyleDeclaration

Enum StyleDeclaration 

Source
pub enum StyleDeclaration {
Show 151 variants BoxSizing(BoxSizing), Opacity(PercentageNumber), AnimationName(AnimationNames), AnimationDuration(AnimationDurations), AnimationDelay(AnimationDurations), AnimationTimingFunction(AnimationTimingFunctions), AnimationIterationCount(AnimationIterationCounts), AnimationDirection(AnimationDirections), AnimationFillMode(AnimationFillModes), AnimationPlayState(AnimationPlayStates), Display(Display), Width(Length), Height(Length), MaxWidth(Length), MaxHeight(Length), MinWidth(Length), MinHeight(Length), AspectRatio(AspectRatio), PaddingTop(LengthDefaultsToZero), PaddingRight(LengthDefaultsToZero), PaddingBottom(LengthDefaultsToZero), PaddingLeft(LengthDefaultsToZero), MarginTop(LengthDefaultsToZero), MarginRight(LengthDefaultsToZero), MarginBottom(LengthDefaultsToZero), MarginLeft(LengthDefaultsToZero), Top(Length), Right(Length), Bottom(Length), Left(Length), FlexDirection(FlexDirection), JustifySelf(AlignItems), JustifyContent(JustifyContent), AlignContent(JustifyContent), JustifyItems(AlignItems), AlignItems(AlignItems), AlignSelf(AlignItems), FlexWrap(FlexWrap), FlexBasis(Option<Length>), Order(Order), ZIndex(ZIndex), Position(Position), Rotate(Option<Angle>), Scale(SpacePair<PercentageNumber>), Translate(SpacePair<Length>), Transform(Option<Transforms>), TransformOrigin(TransformOrigin), MaskImage(Option<BackgroundImages>), MaskSize(BackgroundSizes), MaskPosition(BackgroundPositions), MaskRepeat(BackgroundRepeats), ColumnGap(LengthDefaultsToZero), RowGap(LengthDefaultsToZero), FlexGrow(Option<FlexGrow>), FlexShrink(Option<FlexGrow>), BorderTopLeftRadius(SpacePair<LengthDefaultsToZero>), BorderTopRightRadius(SpacePair<LengthDefaultsToZero>), BorderBottomRightRadius(SpacePair<LengthDefaultsToZero>), BorderBottomLeftRadius(SpacePair<LengthDefaultsToZero>), BorderTopWidth(Length), BorderRightWidth(Length), BorderBottomWidth(Length), BorderLeftWidth(Length), BorderTopStyle(BorderStyle), BorderRightStyle(BorderStyle), BorderBottomStyle(BorderStyle), BorderLeftStyle(BorderStyle), BorderTopColor(ColorInput), BorderRightColor(ColorInput), BorderBottomColor(ColorInput), BorderLeftColor(ColorInput), OutlineWidth(Length), OutlineStyle(BorderStyle), OutlineColor(ColorInput), OutlineOffset(Length), ObjectFit(ObjectFit), OverflowX(Overflow), OverflowY(Overflow), ObjectPosition(ObjectPosition), BackgroundImage(Option<BackgroundImages>), BackgroundPosition(BackgroundPositions), BackgroundSize(BackgroundSizes), BackgroundRepeat(BackgroundRepeats), BackgroundBlendMode(BlendModes), BackgroundColor(ColorDefaultsToTransparent), BackgroundClip(BackgroundClip), BoxShadow(Option<BoxShadows>), GridAutoColumns(Option<GridTrackSizes>), GridAutoRows(Option<GridTrackSizes>), GridAutoFlow(GridAutoFlow), GridRowStart(GridPlacement), GridRowEnd(GridPlacement), GridColumnStart(GridPlacement), GridColumnEnd(GridPlacement), GridTemplateColumns(Option<GridTemplateComponents>), GridTemplateRows(Option<GridTemplateComponents>), GridTemplateAreas(Option<GridTemplateAreas>), TextOverflow(TextOverflow), TextFit(TextFit), TextTransform(TextTransform), FontStyle(FontStyle), FontStretch(FontStretch), Color(ColorInput), Filter(Filters), BackdropFilter(Filters), FontSize(FontSize), FontFamily(FontFamily), LineHeight(LineHeight), FontWeight(FontWeight), FontVariationSettings(FontVariationSettings), FontFeatureSettings(FontFeatureSettings), FontSynthesisWeight(FontSynthesic), FontSynthesisStyle(FontSynthesic), LineClamp(Option<LineClamp>), TextAlign(TextAlign), WebkitTextStrokeWidth(Option<LengthDefaultsToZero>), WebkitTextStrokeColor(Option<ColorInput>), WebkitTextFillColor(Option<ColorInput>), StrokeLinejoin(LineJoin), TextShadow(Option<TextShadows>), TextDecorationLine(Option<TextDecorationLines>), TextDecorationStyle(TextDecorationStyle), TextDecorationColor(ColorInput), TextDecorationThickness(TextDecorationThickness), TextDecorationSkipInk(TextDecorationSkipInk), TextIndent(TextIndent), LetterSpacing(Length), WordSpacing(Length), ImageRendering(ImageScalingAlgorithm), OverflowWrap(OverflowWrap), WordBreak(WordBreak), ClipPath(Option<BasicShape>), ClipRule(FillRule), WhiteSpaceCollapse(WhiteSpaceCollapse), TextWrapMode(TextWrapMode), TextWrapStyle(TextWrapStyle), Direction(Direction), Float(Float), Clear(Clear), Isolation(Isolation), MixBlendMode(BlendMode), Visibility(Visibility), VerticalAlign(VerticalAlign), Content(ContentValue), MarginInlineStart(LengthDefaultsToZero), MarginInlineEnd(LengthDefaultsToZero), PaddingInlineStart(LengthDefaultsToZero), PaddingInlineEnd(LengthDefaultsToZero), CustomProperty(String, String), Deferred(DeferredDeclaration), CssWideKeyword(LonghandId, CssWideKeyword),
}
Expand description

A single specified declaration stored in a declaration block.

Variants§

§

BoxSizing(BoxSizing)

An explicit specified value for a non-shorthand property.

§

Opacity(PercentageNumber)

An explicit specified value for a non-shorthand property.

§

AnimationName(AnimationNames)

An explicit specified value for a non-shorthand property.

§

AnimationDuration(AnimationDurations)

An explicit specified value for a non-shorthand property.

§

AnimationDelay(AnimationDurations)

An explicit specified value for a non-shorthand property.

§

AnimationTimingFunction(AnimationTimingFunctions)

An explicit specified value for a non-shorthand property.

§

AnimationIterationCount(AnimationIterationCounts)

An explicit specified value for a non-shorthand property.

§

AnimationDirection(AnimationDirections)

An explicit specified value for a non-shorthand property.

§

AnimationFillMode(AnimationFillModes)

An explicit specified value for a non-shorthand property.

§

AnimationPlayState(AnimationPlayStates)

An explicit specified value for a non-shorthand property.

§

Display(Display)

An explicit specified value for a non-shorthand property.

§

Width(Length)

An explicit specified value for a non-shorthand property.

§

Height(Length)

An explicit specified value for a non-shorthand property.

§

MaxWidth(Length)

An explicit specified value for a non-shorthand property.

§

MaxHeight(Length)

An explicit specified value for a non-shorthand property.

§

MinWidth(Length)

An explicit specified value for a non-shorthand property.

§

MinHeight(Length)

An explicit specified value for a non-shorthand property.

§

AspectRatio(AspectRatio)

An explicit specified value for a non-shorthand property.

§

PaddingTop(LengthDefaultsToZero)

An explicit specified value for a non-shorthand property.

§

PaddingRight(LengthDefaultsToZero)

An explicit specified value for a non-shorthand property.

§

PaddingBottom(LengthDefaultsToZero)

An explicit specified value for a non-shorthand property.

§

PaddingLeft(LengthDefaultsToZero)

An explicit specified value for a non-shorthand property.

§

MarginTop(LengthDefaultsToZero)

An explicit specified value for a non-shorthand property.

§

MarginRight(LengthDefaultsToZero)

An explicit specified value for a non-shorthand property.

§

MarginBottom(LengthDefaultsToZero)

An explicit specified value for a non-shorthand property.

§

MarginLeft(LengthDefaultsToZero)

An explicit specified value for a non-shorthand property.

§

Top(Length)

An explicit specified value for a non-shorthand property.

§

Right(Length)

An explicit specified value for a non-shorthand property.

§

Bottom(Length)

An explicit specified value for a non-shorthand property.

§

Left(Length)

An explicit specified value for a non-shorthand property.

§

FlexDirection(FlexDirection)

An explicit specified value for a non-shorthand property.

§

JustifySelf(AlignItems)

An explicit specified value for a non-shorthand property.

§

JustifyContent(JustifyContent)

An explicit specified value for a non-shorthand property.

§

AlignContent(JustifyContent)

An explicit specified value for a non-shorthand property.

§

JustifyItems(AlignItems)

An explicit specified value for a non-shorthand property.

§

AlignItems(AlignItems)

An explicit specified value for a non-shorthand property.

§

AlignSelf(AlignItems)

An explicit specified value for a non-shorthand property.

§

FlexWrap(FlexWrap)

An explicit specified value for a non-shorthand property.

§

FlexBasis(Option<Length>)

An explicit specified value for a non-shorthand property.

§

Order(Order)

An explicit specified value for a non-shorthand property.

§

ZIndex(ZIndex)

An explicit specified value for a non-shorthand property.

§

Position(Position)

An explicit specified value for a non-shorthand property.

§

Rotate(Option<Angle>)

An explicit specified value for a non-shorthand property.

§

Scale(SpacePair<PercentageNumber>)

An explicit specified value for a non-shorthand property.

§

Translate(SpacePair<Length>)

An explicit specified value for a non-shorthand property.

§

Transform(Option<Transforms>)

An explicit specified value for a non-shorthand property.

§

TransformOrigin(TransformOrigin)

An explicit specified value for a non-shorthand property.

§

MaskImage(Option<BackgroundImages>)

An explicit specified value for a non-shorthand property.

§

MaskSize(BackgroundSizes)

An explicit specified value for a non-shorthand property.

§

MaskPosition(BackgroundPositions)

An explicit specified value for a non-shorthand property.

§

MaskRepeat(BackgroundRepeats)

An explicit specified value for a non-shorthand property.

§

ColumnGap(LengthDefaultsToZero)

An explicit specified value for a non-shorthand property.

§

RowGap(LengthDefaultsToZero)

An explicit specified value for a non-shorthand property.

§

FlexGrow(Option<FlexGrow>)

An explicit specified value for a non-shorthand property.

§

FlexShrink(Option<FlexGrow>)

An explicit specified value for a non-shorthand property.

§

BorderTopLeftRadius(SpacePair<LengthDefaultsToZero>)

An explicit specified value for a non-shorthand property.

§

BorderTopRightRadius(SpacePair<LengthDefaultsToZero>)

An explicit specified value for a non-shorthand property.

§

BorderBottomRightRadius(SpacePair<LengthDefaultsToZero>)

An explicit specified value for a non-shorthand property.

§

BorderBottomLeftRadius(SpacePair<LengthDefaultsToZero>)

An explicit specified value for a non-shorthand property.

§

BorderTopWidth(Length)

An explicit specified value for a non-shorthand property.

§

BorderRightWidth(Length)

An explicit specified value for a non-shorthand property.

§

BorderBottomWidth(Length)

An explicit specified value for a non-shorthand property.

§

BorderLeftWidth(Length)

An explicit specified value for a non-shorthand property.

§

BorderTopStyle(BorderStyle)

An explicit specified value for a non-shorthand property.

§

BorderRightStyle(BorderStyle)

An explicit specified value for a non-shorthand property.

§

BorderBottomStyle(BorderStyle)

An explicit specified value for a non-shorthand property.

§

BorderLeftStyle(BorderStyle)

An explicit specified value for a non-shorthand property.

§

BorderTopColor(ColorInput)

An explicit specified value for a non-shorthand property.

§

BorderRightColor(ColorInput)

An explicit specified value for a non-shorthand property.

§

BorderBottomColor(ColorInput)

An explicit specified value for a non-shorthand property.

§

BorderLeftColor(ColorInput)

An explicit specified value for a non-shorthand property.

§

OutlineWidth(Length)

An explicit specified value for a non-shorthand property.

§

OutlineStyle(BorderStyle)

An explicit specified value for a non-shorthand property.

§

OutlineColor(ColorInput)

An explicit specified value for a non-shorthand property.

§

OutlineOffset(Length)

An explicit specified value for a non-shorthand property.

§

ObjectFit(ObjectFit)

An explicit specified value for a non-shorthand property.

§

OverflowX(Overflow)

An explicit specified value for a non-shorthand property.

§

OverflowY(Overflow)

An explicit specified value for a non-shorthand property.

§

ObjectPosition(ObjectPosition)

An explicit specified value for a non-shorthand property.

§

BackgroundImage(Option<BackgroundImages>)

An explicit specified value for a non-shorthand property.

§

BackgroundPosition(BackgroundPositions)

An explicit specified value for a non-shorthand property.

§

BackgroundSize(BackgroundSizes)

An explicit specified value for a non-shorthand property.

§

BackgroundRepeat(BackgroundRepeats)

An explicit specified value for a non-shorthand property.

§

BackgroundBlendMode(BlendModes)

An explicit specified value for a non-shorthand property.

§

BackgroundColor(ColorDefaultsToTransparent)

An explicit specified value for a non-shorthand property.

§

BackgroundClip(BackgroundClip)

An explicit specified value for a non-shorthand property.

§

BoxShadow(Option<BoxShadows>)

An explicit specified value for a non-shorthand property.

§

GridAutoColumns(Option<GridTrackSizes>)

An explicit specified value for a non-shorthand property.

§

GridAutoRows(Option<GridTrackSizes>)

An explicit specified value for a non-shorthand property.

§

GridAutoFlow(GridAutoFlow)

An explicit specified value for a non-shorthand property.

§

GridRowStart(GridPlacement)

An explicit specified value for a non-shorthand property.

§

GridRowEnd(GridPlacement)

An explicit specified value for a non-shorthand property.

§

GridColumnStart(GridPlacement)

An explicit specified value for a non-shorthand property.

§

GridColumnEnd(GridPlacement)

An explicit specified value for a non-shorthand property.

§

GridTemplateColumns(Option<GridTemplateComponents>)

An explicit specified value for a non-shorthand property.

§

GridTemplateRows(Option<GridTemplateComponents>)

An explicit specified value for a non-shorthand property.

§

GridTemplateAreas(Option<GridTemplateAreas>)

An explicit specified value for a non-shorthand property.

§

TextOverflow(TextOverflow)

An explicit specified value for a non-shorthand property.

§

TextFit(TextFit)

An explicit specified value for a non-shorthand property.

§

TextTransform(TextTransform)

An explicit specified value for a non-shorthand property.

§

FontStyle(FontStyle)

An explicit specified value for a non-shorthand property.

§

FontStretch(FontStretch)

An explicit specified value for a non-shorthand property.

§

Color(ColorInput)

An explicit specified value for a non-shorthand property.

§

Filter(Filters)

An explicit specified value for a non-shorthand property.

§

BackdropFilter(Filters)

An explicit specified value for a non-shorthand property.

§

FontSize(FontSize)

An explicit specified value for a non-shorthand property.

§

FontFamily(FontFamily)

An explicit specified value for a non-shorthand property.

§

LineHeight(LineHeight)

An explicit specified value for a non-shorthand property.

§

FontWeight(FontWeight)

An explicit specified value for a non-shorthand property.

§

FontVariationSettings(FontVariationSettings)

An explicit specified value for a non-shorthand property.

§

FontFeatureSettings(FontFeatureSettings)

An explicit specified value for a non-shorthand property.

§

FontSynthesisWeight(FontSynthesic)

An explicit specified value for a non-shorthand property.

§

FontSynthesisStyle(FontSynthesic)

An explicit specified value for a non-shorthand property.

§

LineClamp(Option<LineClamp>)

An explicit specified value for a non-shorthand property.

§

TextAlign(TextAlign)

An explicit specified value for a non-shorthand property.

§

WebkitTextStrokeWidth(Option<LengthDefaultsToZero>)

An explicit specified value for a non-shorthand property.

§

WebkitTextStrokeColor(Option<ColorInput>)

An explicit specified value for a non-shorthand property.

§

WebkitTextFillColor(Option<ColorInput>)

An explicit specified value for a non-shorthand property.

§

StrokeLinejoin(LineJoin)

An explicit specified value for a non-shorthand property.

§

TextShadow(Option<TextShadows>)

An explicit specified value for a non-shorthand property.

§

TextDecorationLine(Option<TextDecorationLines>)

An explicit specified value for a non-shorthand property.

§

TextDecorationStyle(TextDecorationStyle)

An explicit specified value for a non-shorthand property.

§

TextDecorationColor(ColorInput)

An explicit specified value for a non-shorthand property.

§

TextDecorationThickness(TextDecorationThickness)

An explicit specified value for a non-shorthand property.

§

TextDecorationSkipInk(TextDecorationSkipInk)

An explicit specified value for a non-shorthand property.

§

TextIndent(TextIndent)

An explicit specified value for a non-shorthand property.

§

LetterSpacing(Length)

An explicit specified value for a non-shorthand property.

§

WordSpacing(Length)

An explicit specified value for a non-shorthand property.

§

ImageRendering(ImageScalingAlgorithm)

An explicit specified value for a non-shorthand property.

§

OverflowWrap(OverflowWrap)

An explicit specified value for a non-shorthand property.

§

WordBreak(WordBreak)

An explicit specified value for a non-shorthand property.

§

ClipPath(Option<BasicShape>)

An explicit specified value for a non-shorthand property.

§

ClipRule(FillRule)

An explicit specified value for a non-shorthand property.

§

WhiteSpaceCollapse(WhiteSpaceCollapse)

An explicit specified value for a non-shorthand property.

§

TextWrapMode(TextWrapMode)

An explicit specified value for a non-shorthand property.

§

TextWrapStyle(TextWrapStyle)

An explicit specified value for a non-shorthand property.

§

Direction(Direction)

An explicit specified value for a non-shorthand property.

§

Float(Float)

An explicit specified value for a non-shorthand property.

§

Clear(Clear)

An explicit specified value for a non-shorthand property.

§

Isolation(Isolation)

An explicit specified value for a non-shorthand property.

§

MixBlendMode(BlendMode)

An explicit specified value for a non-shorthand property.

§

Visibility(Visibility)

An explicit specified value for a non-shorthand property.

§

VerticalAlign(VerticalAlign)

An explicit specified value for a non-shorthand property.

§

Content(ContentValue)

An explicit specified value for a non-shorthand property.

§

MarginInlineStart(LengthDefaultsToZero)

Logical-axis value, resolved to a physical side at apply time.

§

MarginInlineEnd(LengthDefaultsToZero)

Logical-axis value, resolved to a physical side at apply time.

§

PaddingInlineStart(LengthDefaultsToZero)

Logical-axis value, resolved to a physical side at apply time.

§

PaddingInlineEnd(LengthDefaultsToZero)

Logical-axis value, resolved to a physical side at apply time.

§

CustomProperty(String, String)

A custom property declaration such as --token: value.

§

Deferred(DeferredDeclaration)

A property value that must be resolved after var() substitution.

§

CssWideKeyword(LonghandId, CssWideKeyword)

A CSS-wide keyword targeting a longhand property.

Implementations§

Source§

impl StyleDeclaration

Source

pub fn box_sizing(value: BoxSizing) -> Self

Returns a declaration for this property.

Source

pub fn opacity(value: PercentageNumber) -> Self

Returns a declaration for this property.

Source

pub fn animation_name(value: AnimationNames) -> Self

Returns a declaration for this property.

Source

pub fn animation_duration(value: AnimationDurations) -> Self

Returns a declaration for this property.

Source

pub fn animation_delay(value: AnimationDurations) -> Self

Returns a declaration for this property.

Source

pub fn animation_timing_function(value: AnimationTimingFunctions) -> Self

Returns a declaration for this property.

Source

pub fn animation_iteration_count(value: AnimationIterationCounts) -> Self

Returns a declaration for this property.

Source

pub fn animation_direction(value: AnimationDirections) -> Self

Returns a declaration for this property.

Source

pub fn animation_fill_mode(value: AnimationFillModes) -> Self

Returns a declaration for this property.

Source

pub fn animation_play_state(value: AnimationPlayStates) -> Self

Returns a declaration for this property.

Source

pub fn display(value: Display) -> Self

Returns a declaration for this property.

Source

pub fn width(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn height(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn max_width(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn max_height(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn min_width(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn min_height(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn aspect_ratio(value: AspectRatio) -> Self

Returns a declaration for this property.

Source

pub fn padding_top(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn padding_right(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn padding_bottom(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn padding_left(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn margin_top(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn margin_right(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn margin_bottom(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn margin_left(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn top(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn right(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn bottom(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn left(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn flex_direction(value: FlexDirection) -> Self

Returns a declaration for this property.

Source

pub fn justify_self(value: AlignItems) -> Self

Returns a declaration for this property.

Source

pub fn justify_content(value: JustifyContent) -> Self

Returns a declaration for this property.

Source

pub fn align_content(value: JustifyContent) -> Self

Returns a declaration for this property.

Source

pub fn justify_items(value: AlignItems) -> Self

Returns a declaration for this property.

Source

pub fn align_items(value: AlignItems) -> Self

Returns a declaration for this property.

Source

pub fn align_self(value: AlignItems) -> Self

Returns a declaration for this property.

Source

pub fn flex_wrap(value: FlexWrap) -> Self

Returns a declaration for this property.

Source

pub fn flex_basis(value: Option<Length>) -> Self

Returns a declaration for this property.

Source

pub fn order(value: Order) -> Self

Returns a declaration for this property.

Source

pub fn z_index(value: ZIndex) -> Self

Returns a declaration for this property.

Source

pub fn position(value: Position) -> Self

Returns a declaration for this property.

Source

pub fn rotate(value: Option<Angle>) -> Self

Returns a declaration for this property.

Source

pub fn scale(value: SpacePair<PercentageNumber>) -> Self

Returns a declaration for this property.

Source

pub fn translate(value: SpacePair<Length>) -> Self

Returns a declaration for this property.

Source

pub fn transform(value: Option<Transforms>) -> Self

Returns a declaration for this property.

Source

pub fn transform_origin(value: TransformOrigin) -> Self

Returns a declaration for this property.

Source

pub fn mask_image(value: Option<BackgroundImages>) -> Self

Returns a declaration for this property.

Source

pub fn mask_size(value: BackgroundSizes) -> Self

Returns a declaration for this property.

Source

pub fn mask_position(value: BackgroundPositions) -> Self

Returns a declaration for this property.

Source

pub fn mask_repeat(value: BackgroundRepeats) -> Self

Returns a declaration for this property.

Source

pub fn column_gap(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn row_gap(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn flex_grow(value: Option<FlexGrow>) -> Self

Returns a declaration for this property.

Source

pub fn flex_shrink(value: Option<FlexGrow>) -> Self

Returns a declaration for this property.

Source

pub fn border_top_left_radius(value: SpacePair<LengthDefaultsToZero>) -> Self

Returns a declaration for this property.

Source

pub fn border_top_right_radius(value: SpacePair<LengthDefaultsToZero>) -> Self

Returns a declaration for this property.

Source

pub fn border_bottom_right_radius( value: SpacePair<LengthDefaultsToZero>, ) -> Self

Returns a declaration for this property.

Source

pub fn border_bottom_left_radius(value: SpacePair<LengthDefaultsToZero>) -> Self

Returns a declaration for this property.

Source

pub fn border_top_width(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn border_right_width(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn border_bottom_width(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn border_left_width(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn border_top_style(value: BorderStyle) -> Self

Returns a declaration for this property.

Source

pub fn border_right_style(value: BorderStyle) -> Self

Returns a declaration for this property.

Source

pub fn border_bottom_style(value: BorderStyle) -> Self

Returns a declaration for this property.

Source

pub fn border_left_style(value: BorderStyle) -> Self

Returns a declaration for this property.

Source

pub fn border_top_color(value: ColorInput) -> Self

Returns a declaration for this property.

Source

pub fn border_right_color(value: ColorInput) -> Self

Returns a declaration for this property.

Source

pub fn border_bottom_color(value: ColorInput) -> Self

Returns a declaration for this property.

Source

pub fn border_left_color(value: ColorInput) -> Self

Returns a declaration for this property.

Source

pub fn outline_width(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn outline_style(value: BorderStyle) -> Self

Returns a declaration for this property.

Source

pub fn outline_color(value: ColorInput) -> Self

Returns a declaration for this property.

Source

pub fn outline_offset(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn object_fit(value: ObjectFit) -> Self

Returns a declaration for this property.

Source

pub fn overflow_x(value: Overflow) -> Self

Returns a declaration for this property.

Source

pub fn overflow_y(value: Overflow) -> Self

Returns a declaration for this property.

Source

pub fn object_position(value: ObjectPosition) -> Self

Returns a declaration for this property.

Source

pub fn background_image(value: Option<BackgroundImages>) -> Self

Returns a declaration for this property.

Source

pub fn background_position(value: BackgroundPositions) -> Self

Returns a declaration for this property.

Source

pub fn background_size(value: BackgroundSizes) -> Self

Returns a declaration for this property.

Source

pub fn background_repeat(value: BackgroundRepeats) -> Self

Returns a declaration for this property.

Source

pub fn background_blend_mode(value: BlendModes) -> Self

Returns a declaration for this property.

Source

pub fn background_color(value: ColorDefaultsToTransparent) -> Self

Returns a declaration for this property.

Source

pub fn background_clip(value: BackgroundClip) -> Self

Returns a declaration for this property.

Source

pub fn box_shadow(value: Option<BoxShadows>) -> Self

Returns a declaration for this property.

Source

pub fn grid_auto_columns(value: Option<GridTrackSizes>) -> Self

Returns a declaration for this property.

Source

pub fn grid_auto_rows(value: Option<GridTrackSizes>) -> Self

Returns a declaration for this property.

Source

pub fn grid_auto_flow(value: GridAutoFlow) -> Self

Returns a declaration for this property.

Source

pub fn grid_row_start(value: GridPlacement) -> Self

Returns a declaration for this property.

Source

pub fn grid_row_end(value: GridPlacement) -> Self

Returns a declaration for this property.

Source

pub fn grid_column_start(value: GridPlacement) -> Self

Returns a declaration for this property.

Source

pub fn grid_column_end(value: GridPlacement) -> Self

Returns a declaration for this property.

Source

pub fn grid_template_columns(value: Option<GridTemplateComponents>) -> Self

Returns a declaration for this property.

Source

pub fn grid_template_rows(value: Option<GridTemplateComponents>) -> Self

Returns a declaration for this property.

Source

pub fn grid_template_areas(value: Option<GridTemplateAreas>) -> Self

Returns a declaration for this property.

Source

pub fn text_overflow(value: TextOverflow) -> Self

Returns a declaration for this property.

Source

pub fn text_fit(value: TextFit) -> Self

Returns a declaration for this property.

Source

pub fn text_transform(value: TextTransform) -> Self

Returns a declaration for this property.

Source

pub fn font_style(value: FontStyle) -> Self

Returns a declaration for this property.

Source

pub fn font_stretch(value: FontStretch) -> Self

Returns a declaration for this property.

Source

pub fn color(value: ColorInput) -> Self

Returns a declaration for this property.

Source

pub fn filter(value: Filters) -> Self

Returns a declaration for this property.

Source

pub fn backdrop_filter(value: Filters) -> Self

Returns a declaration for this property.

Source

pub fn font_size(value: FontSize) -> Self

Returns a declaration for this property.

Source

pub fn font_family(value: FontFamily) -> Self

Returns a declaration for this property.

Source

pub fn line_height(value: LineHeight) -> Self

Returns a declaration for this property.

Source

pub fn font_weight(value: FontWeight) -> Self

Returns a declaration for this property.

Source

pub fn font_variation_settings(value: FontVariationSettings) -> Self

Returns a declaration for this property.

Source

pub fn font_feature_settings(value: FontFeatureSettings) -> Self

Returns a declaration for this property.

Source

pub fn font_synthesis_weight(value: FontSynthesic) -> Self

Returns a declaration for this property.

Source

pub fn font_synthesis_style(value: FontSynthesic) -> Self

Returns a declaration for this property.

Source

pub fn line_clamp(value: Option<LineClamp>) -> Self

Returns a declaration for this property.

Source

pub fn text_align(value: TextAlign) -> Self

Returns a declaration for this property.

Source

pub fn webkit_text_stroke_width(value: Option<LengthDefaultsToZero>) -> Self

Returns a declaration for this property.

Source

pub fn webkit_text_stroke_color(value: Option<ColorInput>) -> Self

Returns a declaration for this property.

Source

pub fn webkit_text_fill_color(value: Option<ColorInput>) -> Self

Returns a declaration for this property.

Source

pub fn stroke_linejoin(value: LineJoin) -> Self

Returns a declaration for this property.

Source

pub fn text_shadow(value: Option<TextShadows>) -> Self

Returns a declaration for this property.

Source

pub fn text_decoration_line(value: Option<TextDecorationLines>) -> Self

Returns a declaration for this property.

Source

pub fn text_decoration_style(value: TextDecorationStyle) -> Self

Returns a declaration for this property.

Source

pub fn text_decoration_color(value: ColorInput) -> Self

Returns a declaration for this property.

Source

pub fn text_decoration_thickness(value: TextDecorationThickness) -> Self

Returns a declaration for this property.

Source

pub fn text_decoration_skip_ink(value: TextDecorationSkipInk) -> Self

Returns a declaration for this property.

Source

pub fn text_indent(value: TextIndent) -> Self

Returns a declaration for this property.

Source

pub fn letter_spacing(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn word_spacing(value: Length) -> Self

Returns a declaration for this property.

Source

pub fn image_rendering(value: ImageScalingAlgorithm) -> Self

Returns a declaration for this property.

Source

pub fn overflow_wrap(value: OverflowWrap) -> Self

Returns a declaration for this property.

Source

pub fn word_break(value: WordBreak) -> Self

Returns a declaration for this property.

Source

pub fn clip_path(value: Option<BasicShape>) -> Self

Returns a declaration for this property.

Source

pub fn clip_rule(value: FillRule) -> Self

Returns a declaration for this property.

Source

pub fn white_space_collapse(value: WhiteSpaceCollapse) -> Self

Returns a declaration for this property.

Source

pub fn text_wrap_mode(value: TextWrapMode) -> Self

Returns a declaration for this property.

Source

pub fn text_wrap_style(value: TextWrapStyle) -> Self

Returns a declaration for this property.

Source

pub fn direction(value: Direction) -> Self

Returns a declaration for this property.

Source

pub fn float(value: Float) -> Self

Returns a declaration for this property.

Source

pub fn clear(value: Clear) -> Self

Returns a declaration for this property.

Source

pub fn isolation(value: Isolation) -> Self

Returns a declaration for this property.

Source

pub fn mix_blend_mode(value: BlendMode) -> Self

Returns a declaration for this property.

Source

pub fn visibility(value: Visibility) -> Self

Returns a declaration for this property.

Source

pub fn vertical_align(value: VerticalAlign) -> Self

Returns a declaration for this property.

Source

pub fn content(value: ContentValue) -> Self

Returns a declaration for this property.

Source

pub fn margin_inline_start(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn margin_inline_end(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn padding_inline_start(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn padding_inline_end(value: LengthDefaultsToZero) -> Self

Returns a declaration for this property.

Source

pub fn longhand_id(&self) -> LonghandId

Source

pub fn apply_with_parent( self, style: &mut ComputedStyle, parent: &ComputedStyle, )

Source

pub fn apply_to_computed(&self, style: &mut ComputedStyle)

Source

pub fn merge_into_ref(&self, style: &mut Style)

Trait Implementations§

Source§

impl Clone for StyleDeclaration

Source§

fn clone(&self) -> StyleDeclaration

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for StyleDeclaration

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl PartialEq for StyleDeclaration

Source§

fn eq(&self, other: &StyleDeclaration) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl StructuralPartialEq for StyleDeclaration

Source§

impl ToCss for StyleDeclaration

Source§

fn to_css<W: Write>(&self, dest: &mut W) -> Result

Write the CSS representation of this value into dest.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> ErasedDestructor for T
where T: 'static,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.