Closed Bug 1924210 Opened 1 year ago Closed 6 months ago

Implement layout support for implicit anchor element

Categories

(Core :: Layout: Positioned, enhancement)

enhancement
Points:
1

Tracking

()

RESOLVED FIXED
146 Branch
Tracking Status
firefox146 --- fixed

People

(Reporter: dshin, Assigned: jari)

References

(Blocks 1 open bug, Regressed 1 open bug)

Details

(Whiteboard: [anchorpositioning:m2])

Attachments

(3 files, 1 obsolete file)

Seems that there may be a HTML-attribute way to define anchor relationship on the way - See example 2.

Whiteboard: [anchorpositioning:m1]

In the spec I don't see an anchor attribute being defined (only a popover attribute):

https://html.spec.whatwg.org/multipage/indices.html#attributes-3

However, it seems that Google has added some WPT tests that support specifying an implicit anchor using an anchor attribute:

https://searchfox.org/mozilla-central/search?q=&path=tests%2F**%2Fthe-anchor-attribute-0&case=true&regexp=false

For example:

https://searchfox.org/mozilla-central/rev/8eb10f82706521e1b9cff8cd73119bb649a0cb2a/testing/web-platform/tests/html/dom/elements/global-attributes/the-anchor-attribute-001.tentative.html#28

Probably out of scope to support for M1, but something to be aware of that may come down the pike at some point if that get's spec'ed.

Blocks: css-anchor-position-1
No longer blocks: 1909330
See Also: → popover, 1925763
Summary: Implement support for implicit anchor element → Implement layout support for implicit anchor element

Also note that in the case of popover, the spec text for the popover attribute says:

...it will be rendered on top of other page content...

So we'll need to put it in the top, top-layer. (That is, this bug isn't as simple as just looking for an implicit element and passing that into pre-existing code.)

Whiteboard: [anchorpositioning:m1] → [anchorpositioning:pickup]
Whiteboard: [anchorpositioning:pickup] → [anchorpositioning:m1][anchorpositioning:pickup]
Whiteboard: [anchorpositioning:m1][anchorpositioning:pickup] → [anchorpositioning:m2][anchorpositioning:pickup]
Depends on: 1959187
See Also: → 1928128

Should probably be [anchorpositioning:reserve].

Whiteboard: [anchorpositioning:m2][anchorpositioning:pickup] → [anchorpositioning:triage][anchorpositioning:pickup]

Looking at popovers - it sets implicit anchor as part of its specs, where we need to trigger a reflow.

Points: --- → 1
Whiteboard: [anchorpositioning:triage][anchorpositioning:pickup] → [anchorpositioning:m2]
Blocks: 1928128
Assignee: nobody → jjalkanen
Status: NEW → ASSIGNED
No longer blocks: 1928128
Depends on: 1928128

This patch deals with anchor function and basic fully styleable pseudo element support.
Popovers, position-areas and place-selfs are not yet handled.

Attachment #9516463 - Attachment description: WIP: Bug 1924210 - Implement basic support for implicit anchors. r=#anchor-positioning-reviewers → Bug 1924210 - Implement basic support for implicit anchors. r=#anchor-positioning-reviewers
Attachment #9518749 - Attachment is obsolete: true
Regressions: 1994196

:jari did you want to mention this in the 146 release notes? Please nominate if so.

Flags: needinfo?(jjalkanen)

Late response but we discussed it and thought that this is not the right time to celebrate the achievement in the release notes

Flags: needinfo?(jjalkanen)
QA Whiteboard: [qa-triage-done-c147/b146]
Regressions: 2007941
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: