Closed Bug 1898887 Opened 5 months ago Closed 5 months ago

Implement parsing of CSS 'inset-area' property (subsequently renamed 'position-area`)

Categories

(Core :: CSS Parsing and Computation, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
128 Branch
Tracking Status
firefox128 --- fixed

People

(Reporter: jwatt, Assigned: jwatt)

References

(Blocks 2 open bugs)

Details

(Whiteboard: [anchorpositioning:m1])

Attachments

(3 files)

Defined as:

none | <inset-area>

<inset-area> = [
  [ left | right | span-left | span-right
  | x-start | x-end | span-x-start | span-x-end
  | x-self-start | x-self-end | span-x-self-start | span-x-self-end
    | center | span-all ]
  ||
  [ top | bottom | span-top | span-bottom
  | y-start | y-end | span-y-start | span-y-end
  | y-self-start | y-self-end | span-y-self-start | span-y-self-end
    | center | span-all ]
|
  [ block-start | block-end | span-block-start | span-block-end
    | center | span-all ]
  ||
  [ inline-start | inline-end | span-inline-start | span-inline-end
    | center| span-all ]
|
  [ self-block-start | self-block-end | span-self-block-start | span-self-block-end
    | span-all ]
  ||
  [ self-inline-start | self-inline-end | span-self-inline-start | span-self-inline-end
    | span-all ]
|
  [ start | end | span-start | span-end
    | center | span-all ]{1,2}
|
  [ self-start | self-end | span-self-start | span-self-end
    | center | span-all ]{1,2}
]

Giving my own names to the components of each of these five span types, I might have:

[
  <horizontal-span> || <vertical-span>
  |
  <logical-block-span> || <logical-inline-span>
  |
  <logical-block-span-self> || <logical-inline-span-self>
  |
  <inferred-span>{1,2}
  |
  <inferred-span-self>{1,2}
]

Note that each of the five span types have unique keywords, except for the common keywords center and span-all.

My plan for implementing these is to create five sub-types in Rust code (one for each row above), implemented with bitflags!(). My current names are:

InsetAreaSpanAxis
InsetAreaSpanLogical
InsetAreaSpanLogicalSelf
InsetAreaSpanInferred
InsetAreaSpanInferredSelf

The InsetArea type is then an enum of these five types.

Pushed by jwatt@jwatt.org: https://hg.mozilla.org/integration/autoland/rev/a567d2740874 Implement parsing of CSS 'inset-area' property. r=emilio,firefox-style-system-reviewers https://hg.mozilla.org/integration/autoland/rev/d7b6d89a795e p2. Enable layout.css.anchor-positioning.enabled for css/css-anchor-position/inset-area-parsing.html. r=emilio
Status: NEW → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → 128 Branch
Blocks: 1900234
Attachment #9404223 - Attachment is obsolete: true
Attachment #9404223 - Attachment is obsolete: false
Blocks: 1909336
Summary: Implement parsing of CSS 'inset-area' property → Implement parsing of CSS 'inset-area' property (subsequently renamed 'position-area`)
Blocks: 1909358
Whiteboard: [anchorpositioning:m1]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: