@@ -60,20 +60,21 @@ This flexibility can be very useful,
60
60
but also very limiting--
61
61
often you want to position relative to <em> some</em> other element.
62
62
<dfn export>Anchor positioning</dfn>
63
- (via the <dfn export>anchor functions</dfn> ''anchor()'' and ''anchor-size()'' )
63
+ (via the 'position-anchor' and 'position-area' properties
64
+ and/or the <dfn export>anchor functions</dfn> ''anchor()'' and ''anchor-size()'' )
64
65
allows authors to achieve this,
65
- " anchoring" an [=absolutely-positioned=] element
66
+ “ anchoring” an [=absolutely-positioned=] element
66
67
to one or more other elements on the page,
67
68
while also allowing them to try several possible positions
68
- to find the "best" one that avoids overlap/overflow.
69
-
70
- For example, an author might want to position a tooltip
71
- centered and above the targeted element,
72
- unless that would place the tooltip offscreen,
73
- in which case it should be below the targeted element.
74
- This can be done with the following CSS:
69
+ to find the “best” one that avoids overlap/overflow.
75
70
76
71
<div class=example>
72
+ For example, an author might want to position a tooltip
73
+ centered and above the targeted element,
74
+ unless that would place the tooltip offscreen,
75
+ in which case it should be below the targeted element.
76
+ This can be done with the following CSS:
77
+
77
78
<pre class=lang-css>
78
79
.anchor {
79
80
anchor-name: --tooltip;
0 commit comments