@repobit/dex-system-design 2.5.1 → 2.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +84 -0
- package/README.md +2 -1
- package/package.json +14 -27
- package/schemas/component-manifest.json +226 -33
- package/schemas/manifest-omissions.json +23 -0
- package/src/components/accordion/accordion-bg.css.js +39 -30
- package/src/components/accordion/accordion-bg.js +17 -28
- package/src/components/accordion/accordion-bg.stories.js +5 -0
- package/src/components/accordion/accordion-panel.js +24 -0
- package/src/components/accordion/accordion.css.js +105 -111
- package/src/components/accordion/accordion.js +23 -37
- package/src/components/accordion/accordion.stories.js +5 -1
- package/src/components/anchor/anchor-nav.css.js +131 -53
- package/src/components/anchor/anchor-nav.js +276 -201
- package/src/components/annotation/annotation.css.js +7 -4
- package/src/components/architecture.stories.js +8 -7
- package/src/components/audience-card/audience-card.css.js +30 -4
- package/src/components/audience-card/audience-card.js +8 -13
- package/src/components/awards/awards-flex.css.js +23 -6
- package/src/components/awards/awards-flex.js +21 -6
- package/src/components/awards/awards-spotlight.css.js +25 -5
- package/src/components/awards/awards-spotlight.js +19 -7
- package/src/components/awards/awards.css.js +20 -8
- package/src/components/awards/awards.js +30 -91
- package/src/components/awards/awards.stories.js +5 -5
- package/src/components/awards/scroll-slides.js +128 -0
- package/src/components/back/back.css.js +2 -0
- package/src/components/badge/badge.css.js +15 -0
- package/src/components/bento-grid/bento-grid.css.js +105 -11
- package/src/components/bento-grid/bento-grid.js +37 -124
- package/src/components/bento-grid/bento-grid.stories.js +3 -2
- package/src/components/bento-grid/bento-item.css.js +71 -32
- package/src/components/bento-grid/bento-item.js +1 -30
- package/src/components/blockquote/blockquote.css.js +2 -2
- package/src/components/breadcrumb/breadcrumb.css.js +10 -9
- package/src/components/breadcrumb/breadcrumb.js +35 -34
- package/src/components/button/button.css.js +42 -17
- package/src/components/button/button.js +84 -3
- package/src/components/button/button.stories.js +17 -0
- package/src/components/card-features/card-features.css.js +23 -2
- package/src/components/card-features/card-features.js +6 -48
- package/src/components/cards/card.css.js +43 -14
- package/src/components/cards/card.js +43 -177
- package/src/components/cards/card.stories.js +8 -10
- package/src/components/carousel/carousel.css.js +101 -70
- package/src/components/carousel/carousel.js +107 -71
- package/src/components/carousel/carousel.stories.js +18 -16
- package/src/components/checkbox/checkbox.css.js +26 -9
- package/src/components/checkbox/checkbox.js +73 -39
- package/src/components/checkbox/checkbox.stories.js +35 -18
- package/src/components/compare/compare.css.js +68 -10
- package/src/components/compare/compare.js +40 -103
- package/src/components/compare/compare.stories.js +1 -1
- package/src/components/compatibility-table/compatibility-table.css.js +70 -37
- package/src/components/compatibility-table/compatibility-table.js +47 -40
- package/src/components/compatibility-table/compatibility-table.stories.js +78 -1
- package/src/components/display/display.css.js +7 -0
- package/src/components/dropdown/dropdown.css.js +20 -3
- package/src/components/dropdown/dropdown.js +57 -21
- package/src/components/dropdown/dropdown.stories.js +31 -9
- package/src/components/features/features.css.js +56 -21
- package/src/components/features/features.js +7 -117
- package/src/components/fieldset/fieldset.stories.js +68 -0
- package/src/components/footer/footer-images.js +34 -0
- package/src/components/footer/footer-links-group.css.js +10 -10
- package/src/components/footer/footer-locale.js +47 -0
- package/src/components/footer/footer-lp.js +27 -114
- package/src/components/footer/footer-lp.stories.js +2 -2
- package/src/components/footer/footer-nav-menu.css.js +2 -2
- package/src/components/footer/footer-nav-menu.js +8 -3
- package/src/components/footer/footer.css.js +238 -197
- package/src/components/footer/footer.js +109 -187
- package/src/components/footer/footer.stories.js +14 -4
- package/src/components/grid/grid.css.js +64 -5
- package/src/components/header/header-code.css.js +20 -11
- package/src/components/header/header-code.js +1 -1
- package/src/components/header/header.css.js +20 -14
- package/src/components/header/header.js +6 -7
- package/src/components/header/header.stories.js +29 -24
- package/src/components/heading/heading.css.js +11 -0
- package/src/components/hero/hero.js +10 -2
- package/src/components/highlight/highlight.css.js +30 -6
- package/src/components/icons/arrow-icon.js +4 -1
- package/src/components/icons/arrow-right-icon.js +5 -1
- package/src/components/icons/icon-element.js +18 -0
- package/src/components/image/image.js +29 -9
- package/src/components/image/image.stories.js +38 -2
- package/src/components/input/custom-form.stories.js +38 -7
- package/src/components/input/input-clipboard.css.js +15 -1
- package/src/components/input/input-clipboard.js +84 -21
- package/src/components/input/input.js +27 -7
- package/src/components/install-options/install-options.css.js +26 -6
- package/src/components/install-options/install-options.js +32 -8
- package/src/components/label/label.css.js +1 -1
- package/src/components/light-carousel/light-carousel.css.js +100 -48
- package/src/components/light-carousel/light-carousel.js +43 -5
- package/src/components/link/link.css.js +15 -15
- package/src/components/link/link.js +17 -1
- package/src/components/link/link.stories.js +20 -7
- package/src/components/list/list.css.js +3 -3
- package/src/components/logo-marquee/logo-marquee.css.js +12 -1
- package/src/components/logo-marquee/logo-marquee.js +33 -8
- package/src/components/logo-marquee/logo-marquee.stories.js +10 -4
- package/src/components/modal/modal.css.js +74 -40
- package/src/components/modal/modal.js +85 -74
- package/src/components/modal/modal.stories.js +27 -14
- package/src/components/motion-art/motion-art.js +67 -1
- package/src/components/page-switcher/page-switcher.css.js +27 -9
- package/src/components/page-switcher/page-switcher.js +11 -8
- package/src/components/partner-banner/partner-banner.css.js +2 -0
- package/src/components/picture/picture.css.js +4 -4
- package/src/components/picture/picture.js +13 -3
- package/src/components/picture/picture.stories.js +28 -2
- package/src/components/post-card/post-card.css.js +18 -3
- package/src/components/pricing-cards/adopt-styles.js +16 -0
- package/src/components/pricing-cards/new-pricing-card.js +2 -4
- package/src/components/pricing-cards/new-pricing-card.stories.js +20 -22
- package/src/components/pricing-cards/pricing-card-actions.css.js +8 -12
- package/src/components/pricing-cards/pricing-card-actions.js +26 -13
- package/src/components/pricing-cards/pricing-card-container.css.js +4 -3
- package/src/components/pricing-cards/pricing-card-container.js +10 -4
- package/src/components/pricing-cards/pricing-card-header.css.js +5 -4
- package/src/components/pricing-cards/pricing-card-header.js +18 -31
- package/src/components/pricing-cards/pricing-card-pricing.css.js +84 -61
- package/src/components/pricing-cards/pricing-card-pricing.js +38 -24
- package/src/components/pricing-cards/pricing-card-show-more.js +8 -3
- package/src/components/pricing-cards/pricing-card.css.js +75 -41
- package/src/components/pricing-cards/pricing-card.js +356 -308
- package/src/components/progress/progress.css.js +58 -13
- package/src/components/progress/progress.js +13 -10
- package/src/components/progress/progress.stories.js +9 -7
- package/src/components/radio/radio-group.css.js +42 -0
- package/src/components/radio/radio-group.js +89 -0
- package/src/components/radio/radio.css.js +63 -6
- package/src/components/radio/radio.js +173 -140
- package/src/components/radio/radio.stories.js +99 -44
- package/src/components/radio/toggle-radio.js +44 -0
- package/src/components/review/review-grid.css.js +5 -1
- package/src/components/review/review-grid.js +2 -0
- package/src/components/review/review.js +13 -0
- package/src/components/shared/announcer.js +37 -0
- package/src/components/shared/fill-width.css.js +33 -0
- package/src/components/shared/form-control.js +194 -0
- package/src/components/shared/form-field.css.js +31 -3
- package/src/components/shared/token-scales.js +75 -26
- package/src/components/spotlight-section/spotlight-section.js +2 -2
- package/src/components/stat/stat-highlight.js +1 -1
- package/src/components/stat/stat.css.js +18 -3
- package/src/components/switch/switch.css.js +58 -5
- package/src/components/switch/switch.js +53 -5
- package/src/components/switch/switch.stories.js +30 -8
- package/src/components/tab-list/tab-list.css.js +51 -13
- package/src/components/tab-list/tab-list.js +7 -2
- package/src/components/tab-list/tab-list.stories.js +2 -2
- package/src/components/tabs/tabs.css.js +18 -1
- package/src/components/tabs/tabs.js +119 -41
- package/src/components/terminal/terminal-message.css.js +6 -1
- package/src/components/termsOfUse/terms.css.js +4 -2
- package/src/components/textarea/textarea.js +22 -7
- package/src/components/textarea/textarea.stories.js +12 -9
- package/src/components/trust-panel/trust-panel.css.js +13 -3
- package/src/components/ultimate-security-demo.stories.js +5 -5
- package/src/components/video/video.css.js +5 -0
- package/src/components/video/video.js +5 -0
- package/src/components/video/video.stories.js +12 -0
- package/src/components/video-player/video-player.css.js +20 -8
- package/src/components/video-player/video-player.js +74 -20
- package/src/components/video-player/video-player.stories.js +17 -3
- package/src/tokens/brands.stories.js +1 -1
- package/src/tokens/themes/index.js +2 -2
- package/src/tokens/typography.stories.js +4 -3
- package/src/vendor/motion-art/README.md +4 -1
- package/src/components/footer/footer-lp.css.js +0 -159
|
@@ -6,15 +6,28 @@ export const anchorNavStyles = css`
|
|
|
6
6
|
display: block;
|
|
7
7
|
width: 100%;
|
|
8
8
|
background: var(--color-surface-default);
|
|
9
|
+
position: sticky;
|
|
10
|
+
top: var(--sticky-top, 0);
|
|
11
|
+
z-index: var(--z-sticky);
|
|
9
12
|
}
|
|
10
13
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
14
|
+
/* The shadow the bar casts while stuck. A scroll-state container query
|
|
15
|
+
reads the stuck state where the browser has one; elsewhere anchor-nav.js
|
|
16
|
+
sets .is-sticky. */
|
|
17
|
+
@supports (container-type: scroll-state) {
|
|
18
|
+
:host {
|
|
19
|
+
container: anchor-nav / scroll-state;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
@container anchor-nav scroll-state(stuck: top) {
|
|
23
|
+
nav {
|
|
24
|
+
box-shadow: var(--shadow-sm);
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
:host(.is-sticky) nav {
|
|
16
30
|
box-shadow: var(--shadow-sm);
|
|
17
|
-
z-index: var(--z-sticky);
|
|
18
31
|
}
|
|
19
32
|
|
|
20
33
|
nav {
|
|
@@ -27,11 +40,6 @@ export const anchorNavStyles = css`
|
|
|
27
40
|
border-bottom: var(--border-width-1) solid var(--color-border-container);
|
|
28
41
|
}
|
|
29
42
|
|
|
30
|
-
/* Când e sticky, păstrăm aceleași border-uri */
|
|
31
|
-
:host(.is-sticky) nav {
|
|
32
|
-
background: var(--color-surface-default);
|
|
33
|
-
}
|
|
34
|
-
|
|
35
43
|
.bd-anchor-nav__inner {
|
|
36
44
|
display: flex;
|
|
37
45
|
flex-wrap: wrap;
|
|
@@ -93,7 +101,7 @@ export const anchorNavStyles = css`
|
|
|
93
101
|
color: var(--color-text-primary);
|
|
94
102
|
/* No font-weight: body-regular, whose size this rule already asks for, is
|
|
95
103
|
normal -- and the inherited weight here is 400 too, measured, so the
|
|
96
|
-
declaration said nothing. .anchor-link
|
|
104
|
+
declaration said nothing. .anchor-link[current] still sets its own. */
|
|
97
105
|
display: inline-block;
|
|
98
106
|
font-size: var(--typography-body-regular-fontSize);
|
|
99
107
|
font-family: var(--typography-body-regular-fontFamily);
|
|
@@ -105,7 +113,7 @@ export const anchorNavStyles = css`
|
|
|
105
113
|
A host's padding does not extend the anchor inside it, so this rule used
|
|
106
114
|
to build a 44px-tall row around a 24px-tall target: measured 63x44 on the
|
|
107
115
|
host with a 63x24 <a> inside it, and elementsFromPoint 4px below the top
|
|
108
|
-
edge came back bd-anchor-nav > bd-root > div with no <a> in the stack at
|
|
116
|
+
edge came back bd-anchor-nav > bd-root (the former Storybook wrapper) > div with no <a> in the stack at
|
|
109
117
|
all. The top and bottom 10px of every item were dead, 45% of the height a
|
|
110
118
|
reader aims at.
|
|
111
119
|
|
|
@@ -122,30 +130,23 @@ export const anchorNavStyles = css`
|
|
|
122
130
|
padding: var(--spacing-10) var(--spacing-0);
|
|
123
131
|
}
|
|
124
132
|
|
|
125
|
-
|
|
133
|
+
/* [current] is the bd-link attribute that becomes aria-current on its <a>,
|
|
134
|
+
so the item is drawn current exactly when it is announced so. */
|
|
135
|
+
.anchor-link[current] {
|
|
126
136
|
/* no role: the active item in the anchor nav -- a state or modifier weight, not a text-content
|
|
127
137
|
type. See button.css.js's .button--bold for the argument. */
|
|
128
138
|
font-weight: var(--typography-fontWeight-semibold);
|
|
129
139
|
color: var(--color-text-primary);
|
|
130
140
|
}
|
|
131
141
|
|
|
132
|
-
/*
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
.anchor-link:hover {
|
|
142
|
-
text-decoration: none !important;
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
.anchor-link.active:hover {
|
|
146
|
-
color: var(--color-text-primary) !important;
|
|
147
|
-
text-decoration: none !important;
|
|
148
|
-
}
|
|
142
|
+
/* No underline or hover rules here. Three !important ones stood here --
|
|
143
|
+
text-decoration: none on every .anchor-link, hovered or not, and
|
|
144
|
+
text-primary on the hovered active one -- and all three landed on the
|
|
145
|
+
bd-link host, which draws no text: the underline and the colour belong to
|
|
146
|
+
the <a> in its shadow root. The no-underline attribute already keeps that
|
|
147
|
+
<a> undecorated, and bd-link's current-and-hovered rule keeps the
|
|
148
|
+
current item text-primary. Measured on all four Default items, at rest and hovered:
|
|
149
|
+
the same colour, decoration and weight with the rules and without. */
|
|
149
150
|
|
|
150
151
|
/* The offset has to equal the inner's padding-bottom, and it did not.
|
|
151
152
|
|
|
@@ -163,19 +164,25 @@ export const anchorNavStyles = css`
|
|
|
163
164
|
The indicator is now one element that slides between items rather than
|
|
164
165
|
an ::after per link, so the offset lives in _updateIndicator(), which
|
|
165
166
|
reads the inner's padding-bottom instead of a number -- the two move
|
|
166
|
-
together.
|
|
167
|
+
together.
|
|
168
|
+
|
|
169
|
+
It spans the whole row and is placed with translate and sized with
|
|
170
|
+
scale from its top-left corner, so a slide is drawn on the compositor;
|
|
171
|
+
it animated top and width, which re-laid it out every frame. Scaled to
|
|
172
|
+
nothing until the first placement. The anchor is the physical left
|
|
173
|
+
because the offsets it is given are physical. */
|
|
167
174
|
.anchor-indicator {
|
|
168
175
|
position: absolute;
|
|
169
176
|
left: var(--spacing-0);
|
|
170
177
|
top: var(--spacing-0);
|
|
171
|
-
width:
|
|
178
|
+
width: 100%;
|
|
172
179
|
height: var(--indicator-underline-height);
|
|
173
180
|
background-color: var(--indicator-color);
|
|
174
|
-
transform:
|
|
181
|
+
transform-origin: left top;
|
|
182
|
+
scale: 0 1;
|
|
175
183
|
transition:
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
width var(--indicator-underline-duration) var(--indicator-underline-easing);
|
|
184
|
+
translate var(--indicator-underline-duration) var(--indicator-underline-easing),
|
|
185
|
+
scale var(--indicator-underline-duration) var(--indicator-underline-easing);
|
|
179
186
|
pointer-events: none;
|
|
180
187
|
}
|
|
181
188
|
|
|
@@ -223,7 +230,7 @@ export const anchorNavStyles = css`
|
|
|
223
230
|
border: var(--border-width-1) solid var(--color-border-default);
|
|
224
231
|
border-radius: var(--shape-radius-lg);
|
|
225
232
|
cursor: pointer;
|
|
226
|
-
text-align:
|
|
233
|
+
text-align: start;
|
|
227
234
|
transition:
|
|
228
235
|
background var(--transition-duration-fast) var(--transition-easing-smooth),
|
|
229
236
|
border-color var(--transition-duration-fast) var(--transition-easing-smooth),
|
|
@@ -299,7 +306,7 @@ export const anchorNavStyles = css`
|
|
|
299
306
|
right: var(--spacing-0);
|
|
300
307
|
top: 100%;
|
|
301
308
|
z-index: var(--z-overlay);
|
|
302
|
-
max-height: min(
|
|
309
|
+
max-height: min(50dvh, 20rem);
|
|
303
310
|
overflow-y: auto;
|
|
304
311
|
background: var(--color-surface-default);
|
|
305
312
|
border: var(--border-width-1) solid var(--color-brand-200);
|
|
@@ -308,6 +315,31 @@ export const anchorNavStyles = css`
|
|
|
308
315
|
box-shadow: var(--shadow-md);
|
|
309
316
|
}
|
|
310
317
|
|
|
318
|
+
/* Where popover and anchor positioning both exist, anchor-nav.js makes the
|
|
319
|
+
panel a popover: the top layer replaces the z-index above, and light
|
|
320
|
+
dismiss replaces the document listeners. In the top layer the panel is
|
|
321
|
+
no longer inside the dropdown's box, so it is tied to the toggle instead,
|
|
322
|
+
at the place the absolute rule above puts it: under the toggle, as wide
|
|
323
|
+
as it. The rest undoes the popover's UA styles -- centred, fit-content,
|
|
324
|
+
padded, CanvasText. */
|
|
325
|
+
@supports (anchor-name: --a) {
|
|
326
|
+
.bd-anchor-nav__dropdown-toggle {
|
|
327
|
+
anchor-name: --bd-anchor-nav-toggle;
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
.bd-anchor-nav__dropdown-panel[popover] {
|
|
331
|
+
position-anchor: --bd-anchor-nav-toggle;
|
|
332
|
+
inset: auto;
|
|
333
|
+
top: anchor(bottom);
|
|
334
|
+
left: anchor(left);
|
|
335
|
+
width: anchor-size(width);
|
|
336
|
+
box-sizing: border-box;
|
|
337
|
+
margin: var(--spacing-0);
|
|
338
|
+
padding: var(--spacing-0);
|
|
339
|
+
color: inherit;
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
|
|
311
343
|
.bd-anchor-nav__dropdown-list {
|
|
312
344
|
list-style: none;
|
|
313
345
|
margin: var(--spacing-0);
|
|
@@ -333,7 +365,7 @@ export const anchorNavStyles = css`
|
|
|
333
365
|
dropdown -- and CLAUDE.md asks for at least 1.25 on anything that can. */
|
|
334
366
|
line-height: var(--typography-body-regular-lineHeight);
|
|
335
367
|
/* No font-weight: as .anchor-link above -- body-regular is normal and so is
|
|
336
|
-
the inherited value. The
|
|
368
|
+
the inherited value. The current option sets its own. */
|
|
337
369
|
/* text/brand, the same resting ink the desktop items take. This is the
|
|
338
370
|
same component below md showing the same items, so it expresses the same
|
|
339
371
|
meaning: colour is AVAILABLE and neutral is current. It read
|
|
@@ -345,7 +377,7 @@ export const anchorNavStyles = css`
|
|
|
345
377
|
border: none;
|
|
346
378
|
border-radius: var(--shape-radius-md);
|
|
347
379
|
cursor: pointer;
|
|
348
|
-
text-align:
|
|
380
|
+
text-align: start;
|
|
349
381
|
transition:
|
|
350
382
|
color var(--transition-duration-fast) var(--transition-easing-smooth),
|
|
351
383
|
background var(--transition-duration-fast) var(--transition-easing-smooth);
|
|
@@ -357,7 +389,7 @@ export const anchorNavStyles = css`
|
|
|
357
389
|
the --color-neutral-25 this hover sets measures 8.19:1; the blue-500 that
|
|
358
390
|
stood here before either role measured 4.34 and failed. The background is
|
|
359
391
|
the dropdown's own affordance and is not part of the ink contract. */
|
|
360
|
-
.bd-anchor-nav__dropdown-option:hover:not(
|
|
392
|
+
.bd-anchor-nav__dropdown-option:hover:not([aria-current]) {
|
|
361
393
|
color: var(--color-action-primary-active);
|
|
362
394
|
background: var(--color-neutral-25);
|
|
363
395
|
}
|
|
@@ -372,18 +404,21 @@ export const anchorNavStyles = css`
|
|
|
372
404
|
an interactive element in an engaged state -- but it made the current item
|
|
373
405
|
the bluest thing in the list while every other item was neutral. Under one
|
|
374
406
|
contract for the whole family that reading is inverted: colour marks what
|
|
375
|
-
you can go to, neutral marks where you are.
|
|
376
|
-
|
|
407
|
+
you can go to, neutral marks where you are.
|
|
408
|
+
|
|
409
|
+
Read off the option's aria-current, not a class kept beside it, so the
|
|
410
|
+
look and the announcement are one attribute. */
|
|
411
|
+
.bd-anchor-nav__dropdown-option[aria-current] {
|
|
377
412
|
/* no role: the weight that marks the current option -- a state or modifier
|
|
378
|
-
weight, not a text-content type. 700, the same as bd-link's
|
|
379
|
-
|
|
413
|
+
weight, not a text-content type. 700, the same as bd-link's current
|
|
414
|
+
link and bd-tab-list's selected tab. */
|
|
380
415
|
font-weight: var(--typography-fontWeight-bold);
|
|
381
416
|
background: var(--color-brand-50);
|
|
382
417
|
color: var(--color-text-primary);
|
|
383
418
|
}
|
|
384
419
|
|
|
385
420
|
/* The current option does not move under the pointer, as on the bars. */
|
|
386
|
-
.bd-anchor-nav__dropdown-option
|
|
421
|
+
.bd-anchor-nav__dropdown-option[aria-current]:hover {
|
|
387
422
|
color: var(--color-text-primary);
|
|
388
423
|
background: var(--color-brand-50);
|
|
389
424
|
}
|
|
@@ -402,6 +437,24 @@ export const anchorNavStyles = css`
|
|
|
402
437
|
display: none;
|
|
403
438
|
}
|
|
404
439
|
|
|
440
|
+
/* Forced colours repaint backgrounds as Canvas, which took the sliding
|
|
441
|
+
indicator and the current option's fill with them. Both opt out into
|
|
442
|
+
Highlight, as bd-tab-list's and bd-page-switcher's indicators do; the
|
|
443
|
+
option takes HighlightText on it. */
|
|
444
|
+
@media (forced-colors: active) {
|
|
445
|
+
.anchor-indicator {
|
|
446
|
+
forced-color-adjust: none;
|
|
447
|
+
background-color: Highlight;
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
.bd-anchor-nav__dropdown-option[aria-current],
|
|
451
|
+
.bd-anchor-nav__dropdown-option[aria-current]:hover {
|
|
452
|
+
forced-color-adjust: none;
|
|
453
|
+
background: Highlight;
|
|
454
|
+
color: HighlightText;
|
|
455
|
+
}
|
|
456
|
+
}
|
|
457
|
+
|
|
405
458
|
@keyframes bd-anchor-nav-dropdown-label-swap {
|
|
406
459
|
from { opacity: 0.35; transform: translateY(var(--spacing-4)); }
|
|
407
460
|
to { opacity: 1; transform: translateY(var(--spacing-0)); }
|
|
@@ -441,29 +494,54 @@ export const anchorNavStyles = css`
|
|
|
441
494
|
var(--transition-easing-smooth);
|
|
442
495
|
}
|
|
443
496
|
|
|
497
|
+
/* The CTA opens below the dropdown once the first section is behind the
|
|
498
|
+
reader. Its row grows from 0fr to 1fr: a grid track interpolates to the
|
|
499
|
+
content's own height, where the max-height that stood here had to
|
|
500
|
+
guess one -- 128px, which clipped a CTA whose label wraps at a large
|
|
501
|
+
text size. visibility follows, so a closed CTA is out of the tab order
|
|
502
|
+
as well as out of sight. */
|
|
444
503
|
.bd-cta {
|
|
445
504
|
align-self: stretch;
|
|
446
|
-
display:
|
|
447
|
-
|
|
448
|
-
max-height: var(--spacing-0);
|
|
505
|
+
display: grid;
|
|
506
|
+
grid-template-rows: 0fr;
|
|
449
507
|
opacity: 0;
|
|
508
|
+
visibility: hidden;
|
|
450
509
|
transform: translateY(calc(-1 * var(--spacing-8)));
|
|
451
510
|
pointer-events: none;
|
|
452
511
|
margin-top: calc(-1 * var(--spacing-16));
|
|
453
512
|
transition:
|
|
454
|
-
|
|
513
|
+
grid-template-rows var(--transition-duration-slow) var(--transition-easing-ease-out),
|
|
455
514
|
opacity var(--transition-duration-normal) var(--transition-easing-smooth),
|
|
456
515
|
transform var(--transition-duration-normal) var(--transition-easing-smooth),
|
|
457
|
-
margin-top var(--transition-duration-normal) var(--transition-easing-smooth)
|
|
516
|
+
margin-top var(--transition-duration-normal) var(--transition-easing-smooth),
|
|
517
|
+
visibility var(--transition-duration-slow);
|
|
518
|
+
}
|
|
519
|
+
|
|
520
|
+
/* The clip the row needs while it grows, held off the CTA by the width of
|
|
521
|
+
its focus ring -- an outline 2px out at a 2px offset -- so the ring is
|
|
522
|
+
not cut off: the old clip sat on the CTA's own edge and cut it on all
|
|
523
|
+
four sides. Padding and margin cancel, so nothing moves. */
|
|
524
|
+
.bd-cta__inner {
|
|
525
|
+
min-height: 0;
|
|
526
|
+
overflow: hidden;
|
|
527
|
+
padding: var(--spacing-4);
|
|
528
|
+
margin: calc(-1 * var(--spacing-4));
|
|
458
529
|
}
|
|
459
530
|
|
|
460
531
|
.bd-anchor-nav__inner[data-mobile-cta-visible] .bd-cta {
|
|
461
|
-
|
|
532
|
+
grid-template-rows: 1fr;
|
|
462
533
|
opacity: 1;
|
|
534
|
+
visibility: visible;
|
|
463
535
|
transform: translateY(var(--spacing-0));
|
|
464
536
|
pointer-events: auto;
|
|
465
537
|
margin-top: var(--spacing-0);
|
|
466
538
|
}
|
|
467
539
|
|
|
540
|
+
/* Full width on a phone, through bd-button's width hook. This was a
|
|
541
|
+
resize listener writing fullwidth on the page's own element. */
|
|
542
|
+
::slotted([slot="cta"]) {
|
|
543
|
+
--bd-button-width: 100%;
|
|
544
|
+
}
|
|
545
|
+
|
|
468
546
|
}
|
|
469
547
|
`;
|