@atomic-ui/ui 0.12.1 → 0.13.1
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/custom-elements.json +130 -1
- package/dist/base/FieldElement.d.ts +20 -2
- package/dist/{chunk-2WHOBIOY.js → chunk-2BGOBD6Y.js} +2 -2
- package/dist/{chunk-FLAUZU7Y.js → chunk-2RC3QKYA.js} +84 -27
- package/dist/chunk-2RC3QKYA.js.map +1 -0
- package/dist/{chunk-BGHAANTP.js → chunk-5OCDXZXG.js} +3 -2
- package/dist/chunk-5OCDXZXG.js.map +1 -0
- package/dist/{chunk-UYTIJCCW.js → chunk-B2GWXXIW.js} +2 -2
- package/dist/{chunk-CFCFKLTN.js → chunk-EA3M6KPB.js} +11 -1
- package/dist/chunk-EA3M6KPB.js.map +1 -0
- package/dist/{chunk-R6YMSJR7.js → chunk-EFP7PJ6C.js} +68 -25
- package/dist/chunk-EFP7PJ6C.js.map +1 -0
- package/dist/{chunk-BAYSDP44.js → chunk-EIWICFXL.js} +51 -18
- package/dist/chunk-EIWICFXL.js.map +1 -0
- package/dist/{chunk-5IGBH4GL.js → chunk-EUOBFMWC.js} +2 -2
- package/dist/{chunk-FZWUQC42.js → chunk-F2MFV7RM.js} +2 -2
- package/dist/{chunk-3GPGDERO.js → chunk-G7CVRNY5.js} +2 -2
- package/dist/{chunk-2TNF7O43.js → chunk-LSEK5MEZ.js} +2 -2
- package/dist/{chunk-DXLEYNID.js → chunk-LVBYNQ45.js} +5 -3
- package/dist/chunk-LVBYNQ45.js.map +1 -0
- package/dist/{chunk-SOYKSPPX.js → chunk-NZSKUEYS.js} +18 -10
- package/dist/chunk-NZSKUEYS.js.map +1 -0
- package/dist/{chunk-5HCWL2YD.js → chunk-P5FAKEFK.js} +2 -2
- package/dist/{chunk-HSXLSJVG.js → chunk-PII4SJL5.js} +32 -16
- package/dist/chunk-PII4SJL5.js.map +1 -0
- package/dist/{chunk-ALFE35FS.js → chunk-QJBRENLI.js} +3 -3
- package/dist/{chunk-ALFE35FS.js.map → chunk-QJBRENLI.js.map} +1 -1
- package/dist/{chunk-3KAFK24X.js → chunk-RNFGIXJ7.js} +2 -2
- package/dist/{chunk-UBNCJROR.js → chunk-SRXC6ZPM.js} +11 -5
- package/dist/chunk-SRXC6ZPM.js.map +1 -0
- package/dist/{chunk-4MMRBNW7.js → chunk-WEX5RKVC.js} +10 -6
- package/dist/chunk-WEX5RKVC.js.map +1 -0
- package/dist/{chunk-CQT3VPYK.js → chunk-WT7MHYJR.js} +2 -2
- package/dist/{chunk-LXVPWTSY.js → chunk-ZOWOKIE4.js} +37 -21
- package/dist/chunk-ZOWOKIE4.js.map +1 -0
- package/dist/components/accordion.js +1 -1
- package/dist/components/app-bar.d.ts +22 -0
- package/dist/components/app-bar.js +3 -3
- package/dist/components/app-ui.d.ts +8 -0
- package/dist/components/app-ui.js +2 -2
- package/dist/components/button.js +1 -1
- package/dist/components/checkbox-group.js +2 -2
- package/dist/components/checkbox.js +2 -2
- package/dist/components/chip-group.js +2 -2
- package/dist/components/chip.js +1 -1
- package/dist/components/date-input.js +2 -2
- package/dist/components/dialog.js +1 -1
- package/dist/components/journey.js +2 -2
- package/dist/components/layout.js +1 -1
- package/dist/components/navigation.js +1 -1
- package/dist/components/page.js +1 -1
- package/dist/components/radio-group.js +2 -2
- package/dist/components/rows.js +1 -1
- package/dist/components/select.js +2 -2
- package/dist/components/switch.js +2 -2
- package/dist/components/text-input.js +2 -2
- package/dist/components/textarea.js +2 -2
- package/dist/index.js +21 -21
- package/dist/server.d.ts +42 -0
- package/dist/server.js +26 -0
- package/dist/server.js.map +1 -0
- package/dist/standalone/atomic-ui.js +833 -746
- package/dist/standalone/atomic-ui.js.map +3 -3
- package/package.json +6 -2
- package/dist/chunk-4MMRBNW7.js.map +0 -1
- package/dist/chunk-BAYSDP44.js.map +0 -1
- package/dist/chunk-BGHAANTP.js.map +0 -1
- package/dist/chunk-CFCFKLTN.js.map +0 -1
- package/dist/chunk-DXLEYNID.js.map +0 -1
- package/dist/chunk-FLAUZU7Y.js.map +0 -1
- package/dist/chunk-HSXLSJVG.js.map +0 -1
- package/dist/chunk-LXVPWTSY.js.map +0 -1
- package/dist/chunk-R6YMSJR7.js.map +0 -1
- package/dist/chunk-SOYKSPPX.js.map +0 -1
- package/dist/chunk-UBNCJROR.js.map +0 -1
- /package/dist/{chunk-2WHOBIOY.js.map → chunk-2BGOBD6Y.js.map} +0 -0
- /package/dist/{chunk-UYTIJCCW.js.map → chunk-B2GWXXIW.js.map} +0 -0
- /package/dist/{chunk-5IGBH4GL.js.map → chunk-EUOBFMWC.js.map} +0 -0
- /package/dist/{chunk-FZWUQC42.js.map → chunk-F2MFV7RM.js.map} +0 -0
- /package/dist/{chunk-3GPGDERO.js.map → chunk-G7CVRNY5.js.map} +0 -0
- /package/dist/{chunk-2TNF7O43.js.map → chunk-LSEK5MEZ.js.map} +0 -0
- /package/dist/{chunk-5HCWL2YD.js.map → chunk-P5FAKEFK.js.map} +0 -0
- /package/dist/{chunk-3KAFK24X.js.map → chunk-RNFGIXJ7.js.map} +0 -0
- /package/dist/{chunk-CQT3VPYK.js.map → chunk-WT7MHYJR.js.map} +0 -0
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-UNGAG44M.js";
|
|
4
4
|
import {
|
|
5
5
|
FieldElement
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-PII4SJL5.js";
|
|
7
7
|
import {
|
|
8
8
|
lockScroll,
|
|
9
9
|
unlockScroll
|
|
@@ -249,15 +249,18 @@ var ImpaktMenu = class extends ImpaktElement {
|
|
|
249
249
|
/* G2: a 1px ink border and the one shadow the design allows, the open menu's. */
|
|
250
250
|
.panel { position: absolute; z-index: 100; inset-block-start: calc(100% + ${space(1.5)}); inset-inline-start: 0; box-sizing: border-box; min-inline-size: 13rem; max-inline-size: min(24rem, 90vw); padding: ${space(2)} 0; background: ${t.surfaceCard}; border: ${t.borderThin} solid ${t.text}; border-radius: ${t.radiusXl}; box-shadow: var(--impakt-shadow-overlay, 0 16px 32px rgb(0 0 0 / 0.2)); animation: pop 120ms ease-out; }
|
|
251
251
|
.list, .group { margin: 0; padding: 0; list-style: none; }
|
|
252
|
-
.grouped
|
|
253
|
-
|
|
252
|
+
.grouped:not(:first-child) { border-block-start: ${t.borderThin} solid ${LINE_SOFT}; }
|
|
253
|
+
/* G2 group label (53:983): 12px above, 6px below, 18px in, IBM Plex Mono 14/1.4. */
|
|
254
|
+
.group-label { display: block; padding: ${space(3)} 18px 6px; font-family: ${t.fontMono}; font-size: 0.875rem; line-height: 1.4; color: ${t.textMuted}; }
|
|
254
255
|
.header { padding: ${space(2)} ${space(2.5)} ${space(2.5)}; margin-block-end: ${space(1.5)}; border-block-end: ${t.borderThin} solid ${t.border}; ${type("sm")} color: ${t.textMuted}; overflow-wrap: anywhere; }
|
|
255
256
|
:host([edge='end']) .panel, .panel.flip-end { inset-inline: auto 0; }
|
|
256
257
|
:host([edge='end']) .panel.flip-start { inset-inline: 0 auto; }
|
|
257
258
|
@keyframes pop { from { opacity: 0; transform: translateY(-${space(1)}); } }
|
|
258
|
-
.item { ${targetSize} box-sizing: border-box; display: flex; align-items: center; gap: ${space(2.5)}; inline-size: 100%; padding: ${space(3)} 18px; font: inherit; font-size: 1rem; line-height: 1.
|
|
259
|
+
.item { ${targetSize} box-sizing: border-box; display: flex; align-items: center; gap: ${space(2.5)}; inline-size: 100%; padding: ${space(3)} 18px; font: inherit; font-size: 1rem; line-height: 1.2; font-weight: ${fontWeight("medium")}; text-align: start; color: ${t.text}; text-decoration: none; background: none; border: 0; border-radius: 0; cursor: pointer; }
|
|
259
260
|
.item:hover, .item:focus { background: ${t.surfaceSubtle}; }
|
|
260
|
-
|
|
261
|
+
/* G2 item (53:985): the label in Archivo 16/1.2 and the note in IBM Plex Mono 14/1.4, on one line, the note at the end. */
|
|
262
|
+
.item .text { min-inline-size: 0; }
|
|
263
|
+
.item .meta { flex: none; margin-inline-start: auto; padding-inline-start: ${space(4)}; font-family: ${t.fontMono}; font-size: 0.875rem; line-height: 1.4; font-weight: ${fontWeight("regular")}; color: ${t.textMuted}; white-space: nowrap; }
|
|
261
264
|
.item[aria-current] { background: ${t.text}; color: var(--impakt-color-text-inverse, var(--impakt-solid-card, ${t.surfaceCard})); }
|
|
262
265
|
.item[aria-current] .meta { color: color-mix(in srgb, var(--impakt-color-text-inverse, var(--impakt-solid-card, ${t.surfaceCard})) 66%, ${t.text}); }
|
|
263
266
|
.item[aria-disabled='true'] { color: ${t.textMuted}; cursor: not-allowed; }
|
|
@@ -284,11 +287,15 @@ var ImpaktMenu = class extends ImpaktElement {
|
|
|
284
287
|
if (open) {
|
|
285
288
|
document.addEventListener("click", this.outside);
|
|
286
289
|
void this.updateComplete.then(() => {
|
|
287
|
-
this.keepOnScreen();
|
|
288
290
|
this.entries[focus === "last" ? this.entries.length - 1 : 0]?.focus();
|
|
289
291
|
});
|
|
290
292
|
} else document.removeEventListener("click", this.outside);
|
|
291
293
|
}
|
|
294
|
+
/** However it was opened, by the button or by setting `open`, the list is kept on the screen. */
|
|
295
|
+
updated(changed) {
|
|
296
|
+
super.updated?.(changed);
|
|
297
|
+
if (changed.has("open") && this.open) this.keepOnScreen();
|
|
298
|
+
}
|
|
292
299
|
/** Open towards the other edge when the list would run off the screen. */
|
|
293
300
|
keepOnScreen() {
|
|
294
301
|
const list = this.renderRoot.querySelector(".panel");
|
|
@@ -338,11 +345,12 @@ var ImpaktMenu = class extends ImpaktElement {
|
|
|
338
345
|
}
|
|
339
346
|
renderItem(item) {
|
|
340
347
|
const meta = item.meta || (item.current ? say("You are here") : "");
|
|
341
|
-
const inner = html`${iconSvg(item.icon, "18px")}<span class="text">${item.text}</span>${meta ? html`<span class="meta">${meta}</span>` : nothing}`;
|
|
348
|
+
const inner = html`${iconSvg(item.icon, "18px")}<span class="text" part="label">${item.text}</span>${meta ? html`<span class="meta" part="meta">${meta}</span>` : nothing}`;
|
|
342
349
|
const cls = `item ${item.tone === "danger" ? "danger" : ""}`;
|
|
343
350
|
const current = item.current ? "page" : nothing;
|
|
344
351
|
const disabled = item.disabled ? "true" : nothing;
|
|
345
|
-
|
|
352
|
+
const part = item.current ? "item current" : "item";
|
|
353
|
+
return html`<li role="none">${item.href && !item.disabled ? html`<a class=${cls} part=${part} role="menuitem" tabindex="-1" href=${item.href} aria-current=${current} @click=${(e) => this.choose(item, e)}>${inner}</a>` : html`<button class=${cls} part=${part} role="menuitem" tabindex="-1" type="button" aria-current=${current} aria-disabled=${disabled} @click=${(e) => this.choose(item, e)}>${inner}</button>`}</li>`;
|
|
346
354
|
}
|
|
347
355
|
/** The items in runs: each run of items with the same group, in order. Items with no group are a run with no label. */
|
|
348
356
|
get runs() {
|
|
@@ -366,7 +374,7 @@ var ImpaktMenu = class extends ImpaktElement {
|
|
|
366
374
|
${this.open ? html`<div class="panel" part="panel">${this.querySelector?.(':scope > [slot="header"]') ? html`<div class="header" part="header"><slot name="header"></slot></div>` : nothing}<ul class="list" part="list" id=${this.id_("list")} role="menu" aria-label=${this.label} @keydown=${this.listKey}>
|
|
367
375
|
${grouped ? runs.map((run, i) => {
|
|
368
376
|
const id = this.id_(`group-${i}`);
|
|
369
|
-
return html`<li role="none" class="grouped">${run.group ? html`<span class="group-label" id=${id} part="group-label">${run.group}</span>` : nothing}<ul class="group" role="group" aria-labelledby=${run.group ? id : nothing}>${run.items.map((item) => this.renderItem(item))}</ul></li>`;
|
|
377
|
+
return html`<li role="none" class="grouped" part="group">${run.group ? html`<span class="group-label" id=${id} part="group-label">${run.group}</span>` : nothing}<ul class="group" role="group" aria-labelledby=${run.group ? id : nothing}>${run.items.map((item) => this.renderItem(item))}</ul></li>`;
|
|
370
378
|
}) : (this.items ?? []).map((item) => this.renderItem(item))}
|
|
371
379
|
</ul></div>` : nothing}`;
|
|
372
380
|
}
|
|
@@ -687,4 +695,4 @@ export {
|
|
|
687
695
|
ImpaktEmptyState,
|
|
688
696
|
ImpaktSlotPicker
|
|
689
697
|
};
|
|
690
|
-
//# sourceMappingURL=chunk-
|
|
698
|
+
//# sourceMappingURL=chunk-NZSKUEYS.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/components/app-ui.ts"],"sourcesContent":["import { css, html, nothing, unsafeCSS, type TemplateResult } from 'lit';\nimport { say } from '../base/say';\nimport { pageLocale } from '../base/locale';\nimport { FieldElement } from '../base/FieldElement';\nimport { ImpaktElement } from '../base/ImpaktElement';\nimport { focusRing, targetSize, touchTarget, visuallyHidden } from '../base/styles';\nimport { lockScroll, unlockScroll } from '../base/scroll-lock';\nimport { fontWeight, space, spaceAround, t, type } from '../base/tokens';\nimport { iconSvg } from './icon';\n\n/**\n * A panel that slides in from the side: a basket, filters, a plot's details.\n *\n * It is a native `<dialog>` opened with `showModal()`, like the dialog, so the\n * focus trap, Escape, the inert page behind it and the return of focus all come\n * from the browser. The page behind it does not scroll while it is open. The\n * slide is a decoration and stops for anyone who has asked for reduced motion.\n * On a phone it fills the screen.\n *\n * With `side=\"bottom\"` it is a sheet that rises from the bottom edge, as a\n * phone's dialogs do: as wide as the screen, as tall as its content up to\n * nine tenths of the screen, with its top corners rounded.\n *\n * @category feedback\n * @icon drawer\n * @slot - The body of the panel.\n * @slot footer - Buttons pinned to the bottom of the panel.\n * @fires {CustomEvent<null>} impakt-close - When the panel is closed.\n */\nexport class ImpaktDrawer extends ImpaktElement {\n static properties = {\n open: { type: Boolean, reflect: true },\n heading: { type: String },\n side: { type: String, reflect: true },\n closeLabel: { type: String, attribute: 'close-label' },\n };\n declare open: boolean;\n declare heading: string;\n /** Which edge it comes in from. `bottom` is a sheet, for a phone. */\n declare side: 'left' | 'right' | 'bottom';\n declare closeLabel: string;\n\n constructor() {\n super();\n this.open = false;\n this.heading = '';\n this.side = 'right';\n this.closeLabel = 'Close';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n focusRing,\n touchTarget('.close'),\n css`\n dialog { box-sizing: border-box; display: none; flex-direction: column; inline-size: min(28rem, 100vw); max-inline-size: 100vw; block-size: 100dvh; max-block-size: 100dvh; margin: 0 0 0 auto; padding: 0; border: 0; color: ${t.text}; background: ${t.surfaceCard}; box-shadow: ${t.shadowXl}; animation: from-right 240ms cubic-bezier(0.16, 1, 0.3, 1); }\n dialog[open] { display: flex; }\n :host([side='left']) dialog { margin: 0 auto 0 0; animation-name: from-left; }\n :host([side='bottom']) dialog { inline-size: 100vw; block-size: fit-content; max-block-size: 90dvh; margin: auto 0 0 0; padding-block-end: env(safe-area-inset-bottom); border-radius: 28px 28px 0 0; animation-name: from-bottom; }\n :host([side='bottom']) .head { box-shadow: none; }\n :host([side='bottom']) .foot { box-shadow: none; }\n :host([side='bottom']) .foot ::slotted(*) { flex: 1; }\n @keyframes from-bottom { from { transform: translateY(100%); } }\n dialog::backdrop { background: color-mix(in srgb, ${t.text} 30%, transparent); backdrop-filter: blur(2px); }\n @keyframes from-right { from { transform: translateX(100%); } }\n @keyframes from-left { from { transform: translateX(-100%); } }\n .head { display: flex; align-items: center; justify-content: space-between; gap: ${space(3)}; padding: ${space(4)} ${space(5)}; box-shadow: 0 1px 0 color-mix(in srgb, ${t.text} 8%, transparent); }\n h2 { margin: 0; font-family: ${t.fontHeading}; ${type('xl')} font-weight: ${fontWeight('bold')}; color: ${t.textHeading}; }\n .close { ${targetSize} display: inline-flex; align-items: center; justify-content: center; padding: 0; color: ${t.text}; background: none; border: 0; border-radius: ${t.radius}; cursor: pointer; }\n .close:hover { background: ${t.surfaceSubtle}; }\n .body { flex: 1; overflow: auto; padding: ${space(5)}; }\n .foot { display: flex; gap: ${space(3)}; justify-content: flex-end; padding: ${space(4)} ${space(5)}; box-shadow: 0 -1px 0 color-mix(in srgb, ${t.text} 8%, transparent); }\n .foot[hidden] { display: none; }\n `,\n ];\n\n private hasFooter = false;\n\n private get dialog(): HTMLDialogElement | null {\n return this.renderRoot.querySelector('dialog');\n }\n\n updated(changed: Map<string, unknown>): void {\n if (!changed.has('open')) return;\n const dialog = this.dialog;\n if (!dialog) return;\n if (this.open) {\n if (typeof dialog.showModal === 'function') dialog.showModal();\n else dialog.setAttribute('open', '');\n lockScroll(this);\n } else {\n if (typeof dialog.close === 'function' && dialog.open) dialog.close();\n else dialog.removeAttribute('open');\n unlockScroll(this);\n }\n }\n\n disconnectedCallback(): void {\n super.disconnectedCallback();\n unlockScroll(this);\n }\n\n private close(): void {\n this.open = false;\n this.dispatchEvent(new CustomEvent('impakt-close', { bubbles: true, composed: true }));\n }\n\n private footerChanged(event: Event): void {\n this.hasFooter = (event.target as HTMLSlotElement).assignedNodes().length > 0;\n this.requestUpdate();\n }\n\n render(): TemplateResult {\n return html`<dialog part=\"dialog\" aria-labelledby=${this.heading ? this.id_('heading') : nothing}\n @cancel=${() => this.close()}\n @close=${() => {\n if (this.open) this.close();\n }}\n @click=${(event: Event) => {\n if (event.target === this.dialog) this.close();\n }}>\n <div class=\"head\">\n ${this.heading ? html`<h2 id=${this.id_('heading')}>${this.heading}</h2>` : html`<span></span>`}\n <button class=\"close\" type=\"button\" aria-label=${this.closeLabel} @click=${this.close}>${iconSvg('close', '20px')}</button>\n </div>\n <div class=\"body\" part=\"body\"><slot></slot></div>\n <div class=\"foot\" part=\"footer\" ?hidden=${!this.hasFooter}><slot name=\"footer\" @slotchange=${this.footerChanged}></slot></div>\n </dialog>`;\n }\n}\n\nconst TOAST_ICON: Record<string, string> = { neutral: 'info', success: 'check', warning: 'warning', danger: 'warning' };\n\n/**\n * A short message in the corner that goes away: \"Viewing booked\", \"Saved\".\n *\n * It says itself to a screen reader through a live region that is on the page\n * before the message is, and its timer stops while it is pointed at or focused.\n * Set `duration` to 0 to keep it up until it is closed. A message with a button,\n * such as Undo, stays until it is closed whatever the duration, because a\n * button that disappears on a timer cannot be pressed by someone who needs\n * longer (2.2.1). Escape closes it while focus is inside it. Anything a person\n * must act on belongs in an alert on the page.\n *\n * It never takes the page's clicks: only the message itself can be pressed, so\n * the page beside and behind the corner it sits in still works. On a phone it\n * spans the screen above the bottom edge, clear of the home bar and of a bottom\n * bar that sets `--impakt-bottom-bar`, and it rises without moving for anyone who\n * has asked for reduced motion.\n *\n * @category feedback\n * @icon toast\n * @fires {CustomEvent<null>} impakt-close - When the message goes away.\n * @fires {CustomEvent<null>} impakt-action - When its button is pressed.\n */\nexport class ImpaktToast extends ImpaktElement {\n static properties = {\n open: { type: Boolean, reflect: true },\n message: { type: String },\n tone: { type: String, reflect: true },\n duration: { type: Number },\n actionText: { type: String, attribute: 'action-text' },\n closeLabel: { type: String, attribute: 'close-label' },\n };\n declare open: boolean;\n declare message: string;\n declare tone: 'neutral' | 'success' | 'warning' | 'danger';\n /** How long it stays. 0 keeps it up until it is closed. */\n declare duration: number;\n declare actionText: string;\n declare closeLabel: string;\n\n private timer: ReturnType<typeof setTimeout> | undefined;\n\n constructor() {\n super();\n this.open = false;\n this.message = '';\n this.tone = 'neutral';\n this.duration = 6;\n this.actionText = '';\n this.closeLabel = 'Dismiss';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n focusRing,\n css`\n .region { position: fixed; inset-block-end: calc(${space(4)} + env(safe-area-inset-bottom, 0px) + var(--impakt-bottom-bar, 0px)); inset-inline-end: ${space(4)}; z-index: 1000; inline-size: min(24rem, calc(100vw - ${space(8)})); pointer-events: none; }\n @media (max-width: 40rem) { .region { inset-inline: ${space(3)}; inline-size: auto; inset-block-end: calc(${space(3)} + env(safe-area-inset-bottom, 0px) + var(--impakt-bottom-bar, 0px)); } }\n .toast { pointer-events: auto; max-block-size: 40vh; overflow: auto; display: flex; align-items: flex-start; gap: ${space(3)}; padding: ${space(3)} ${space(3)} ${space(3)} ${space(4)}; color: ${t.text}; background: ${t.surfaceCard}; border-radius: ${t.radiusXl}; box-shadow: ${t.shadowXl}, 0 0 0 1px color-mix(in srgb, ${t.text} 8%, transparent); animation: rise 220ms cubic-bezier(0.16, 1, 0.3, 1); }\n /* It rises without fading in, so its words are at full contrast from the first frame they are read in (1.4.3). */\n @keyframes rise { from { transform: translateY(${space(3)}); } }\n .mark { display: inline-flex; flex: none; margin-block-start: ${space(0.5)}; color: ${t.info}; }\n :host([tone='success']) .mark { color: ${t.success}; }\n :host([tone='warning']) .mark { color: ${t.warning}; }\n :host([tone='danger']) .mark { color: ${t.danger}; }\n .message { flex: 1; align-self: center; margin: 0; ${type('sm')} font-weight: ${fontWeight('medium')}; }\n .action, .close { ${targetSize} padding: 0 ${space(2)}; font: inherit; ${type('sm')} font-weight: ${fontWeight('semibold')}; color: ${t.link}; background: none; border: 0; border-radius: ${t.radius}; cursor: pointer; }\n .close { display: inline-flex; align-items: center; justify-content: center; color: ${t.textMuted}; }\n .action:hover, .close:hover { background: ${t.surfaceSubtle}; }\n `,\n touchTarget('.action, .close'),\n ];\n\n disconnectedCallback(): void {\n super.disconnectedCallback();\n this.stop();\n }\n\n updated(changed: Map<string, unknown>): void {\n if (changed.has('open') || changed.has('duration')) {\n this.stop();\n if (this.open) this.start();\n }\n }\n\n private start(): void {\n this.stop();\n if (this.duration > 0 && !this.actionText) this.timer = setTimeout(() => this.close(), this.duration * 1000);\n }\n\n private stop(): void {\n if (this.timer) clearTimeout(this.timer);\n this.timer = undefined;\n }\n\n private close(): void {\n this.stop();\n if (!this.open) return;\n this.open = false;\n this.dispatchEvent(new CustomEvent('impakt-close', { bubbles: true, composed: true }));\n }\n\n private action(): void {\n this.dispatchEvent(new CustomEvent('impakt-action', { bubbles: true, composed: true }));\n this.close();\n }\n\n render(): TemplateResult {\n return html`<div class=\"region\" role=\"status\" aria-live=\"polite\">\n ${\n this.open\n ? html`<div class=\"toast\" part=\"toast\" @mouseenter=${this.stop} @mouseleave=${this.start} @focusin=${this.stop} @focusout=${this.start}\n @keydown=${(e: KeyboardEvent) => {\n if (e.key === 'Escape') {\n e.preventDefault();\n this.close();\n }\n }}>\n <span class=\"mark\">${iconSvg(TOAST_ICON[this.tone] ?? 'info', '20px')}</span>\n <p class=\"message\">${this.message}</p>\n ${this.actionText ? html`<button class=\"action\" type=\"button\" @click=${this.action}>${this.actionText}</button>` : nothing}\n <button class=\"close\" type=\"button\" aria-label=${this.closeLabel} @click=${this.close}>${iconSvg('close', '16px')}</button>\n </div>`\n : nothing\n }\n </div>`;\n }\n}\n\nexport interface MenuItem {\n id?: string;\n text: string;\n /** Where it goes. Without one it fires impakt-select with its value. */\n href?: string;\n value?: string;\n icon?: string;\n tone?: '' | 'danger';\n /** A group name. Items with the same group are drawn together under it, as a labelled group, in the order the groups first appear. */\n group?: string;\n /** A short note on the right in the code face, such as \"Open\" or \"Coming soon\". It is read with the item. */\n meta?: string;\n /** The page you are on: an ink fill, `aria-current=\"page\"`, and \"You are here\" when there is no meta. */\n current?: boolean;\n /** Shown but not chosen, such as a tool still to come. It stays in the arrow-key order and says it is unavailable. */\n disabled?: boolean;\n}\n\n/** The G2 soft rule, until the theme carries it. */\nconst LINE_SOFT = unsafeCSS('var(--impakt-color-line-soft, #dcdcd8)');\n\n/**\n * A button that opens a short list of actions or links.\n *\n * It follows the ARIA menu button pattern: the arrow keys, Home and End move\n * through it, a letter moves to the next item that starts with it, Escape\n * closes it and puts focus back on the button, and a click anywhere else closes\n * it. A list that would run off the side of the screen opens towards the other\n * edge instead, so it never makes a phone scroll sideways.\n *\n * **The button can hold your own content.** Put an avatar and a name in the\n * `trigger` slot for an account menu; they replace the icon and label, and\n * become the button's accessible name, so include the words. Put who is signed\n * in, or any other note, in the `header` slot; it sits above the items and\n * outside the menu, so the arrow keys still move through the items alone.\n *\n * @category navigation\n * @icon menu\n * **Items can be grouped, noted and marked.** An item's `group` draws it under\n * a label in the code face, as a `group` named by that label, with a soft rule\n * above each group after the first. Its `meta` is a quiet note at the end. The\n * page you are on is `current`, an ink row with `aria-current=\"page\"`, and a\n * `disabled` item is still reached by the arrow keys but says it is unavailable\n * and does nothing (G2 tool switcher, frames 53:960 and 53:800).\n *\n * @slot trigger - What the button shows, in place of the icon and label.\n * @slot header - A note above the items, such as the name and email of who is signed in.\n * @csspart trigger - The button.\n * @csspart chevron - The arrow on the button.\n * @csspart panel - The box that opens, holding the header and the items.\n * @csspart header - The box round the header slot.\n * @csspart list - The list of items.\n * @csspart group - A group of items with its label, and the soft rule above it after the first.\n * @csspart group-label - A group's label, in the code face.\n * @csspart item - An item, a link or a button. The page you are on is also `current`.\n * @csspart current - The item for the page you are on.\n * @csspart label - An item's words.\n * @csspart meta - An item's quiet note at the end, such as \"Coming soon\".\n * @fires {CustomEvent<{ value: string }>} impakt-select - When an item without an address is chosen. The value is in detail.value.\n */\nexport class ImpaktMenu extends ImpaktElement {\n static properties = {\n label: { type: String },\n icon: { type: String },\n items: { type: Array },\n edge: { type: String, reflect: true },\n open: { type: Boolean, reflect: true },\n triggerLook: { type: String, reflect: true, attribute: 'trigger-look' },\n };\n declare label: string;\n declare icon: string;\n /** `button` is a bordered button with a chevron. `text` is plain words with \"▾\", \"▴\" when open, as a tool's name in a header is. */\n declare triggerLook: 'button' | 'text';\n declare items: MenuItem[];\n /** Which edge of the button the list lines up with. */\n declare edge: 'start' | 'end';\n declare open: boolean;\n\n constructor() {\n super();\n this.label = 'Menu';\n this.icon = '';\n this.items = [];\n this.edge = 'start';\n this.open = false;\n this.triggerLook = 'button';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n focusRing,\n touchTarget('.trigger, .item'),\n css`\n :host { position: relative; display: inline-block; }\n .trigger { ${targetSize} display: inline-flex; align-items: center; gap: ${space(2)}; padding: ${space(2)} ${space(3.5)}; font: inherit; ${type('sm')} font-weight: ${fontWeight('medium')}; color: ${t.text}; background: ${t.surfaceCard}; border: ${t.borderThin} solid ${t.text}; border-radius: ${t.radiusLg}; cursor: pointer; }\n :host([trigger-look='text']) .trigger { padding: ${space(1)} ${space(1)}; font-size: 1rem; line-height: 1.25; background: transparent; border-color: transparent; }\n :host([trigger-look='text']) .trigger:hover { background: transparent; text-decoration: underline; text-underline-offset: 0.2em; }\n .caret { font-size: 0.75em; line-height: 1; }\n .trigger:hover { background: ${t.surfaceSubtle}; }\n .chev { display: inline-flex; color: ${t.textMuted}; transition: transform 120ms ease-in-out; }\n :host([open]) .chev { transform: rotate(180deg); }\n /* G2: a 1px ink border and the one shadow the design allows, the open menu's. */\n .panel { position: absolute; z-index: 100; inset-block-start: calc(100% + ${space(1.5)}); inset-inline-start: 0; box-sizing: border-box; min-inline-size: 13rem; max-inline-size: min(24rem, 90vw); padding: ${space(2)} 0; background: ${t.surfaceCard}; border: ${t.borderThin} solid ${t.text}; border-radius: ${t.radiusXl}; box-shadow: var(--impakt-shadow-overlay, 0 16px 32px rgb(0 0 0 / 0.2)); animation: pop 120ms ease-out; }\n .list, .group { margin: 0; padding: 0; list-style: none; }\n .grouped:not(:first-child) { border-block-start: ${t.borderThin} solid ${LINE_SOFT}; }\n /* G2 group label (53:983): 12px above, 6px below, 18px in, IBM Plex Mono 14/1.4. */\n .group-label { display: block; padding: ${space(3)} 18px 6px; font-family: ${t.fontMono}; font-size: 0.875rem; line-height: 1.4; color: ${t.textMuted}; }\n .header { padding: ${space(2)} ${space(2.5)} ${space(2.5)}; margin-block-end: ${space(1.5)}; border-block-end: ${t.borderThin} solid ${t.border}; ${type('sm')} color: ${t.textMuted}; overflow-wrap: anywhere; }\n :host([edge='end']) .panel, .panel.flip-end { inset-inline: auto 0; }\n :host([edge='end']) .panel.flip-start { inset-inline: 0 auto; }\n @keyframes pop { from { opacity: 0; transform: translateY(-${space(1)}); } }\n .item { ${targetSize} box-sizing: border-box; display: flex; align-items: center; gap: ${space(2.5)}; inline-size: 100%; padding: ${space(3)} 18px; font: inherit; font-size: 1rem; line-height: 1.2; font-weight: ${fontWeight('medium')}; text-align: start; color: ${t.text}; text-decoration: none; background: none; border: 0; border-radius: 0; cursor: pointer; }\n .item:hover, .item:focus { background: ${t.surfaceSubtle}; }\n /* G2 item (53:985): the label in Archivo 16/1.2 and the note in IBM Plex Mono 14/1.4, on one line, the note at the end. */\n .item .text { min-inline-size: 0; }\n .item .meta { flex: none; margin-inline-start: auto; padding-inline-start: ${space(4)}; font-family: ${t.fontMono}; font-size: 0.875rem; line-height: 1.4; font-weight: ${fontWeight('regular')}; color: ${t.textMuted}; white-space: nowrap; }\n .item[aria-current] { background: ${t.text}; color: var(--impakt-color-text-inverse, var(--impakt-solid-card, ${t.surfaceCard})); }\n .item[aria-current] .meta { color: color-mix(in srgb, var(--impakt-color-text-inverse, var(--impakt-solid-card, ${t.surfaceCard})) 66%, ${t.text}); }\n .item[aria-disabled='true'] { color: ${t.textMuted}; cursor: not-allowed; }\n .item[aria-disabled='true']:hover { background: none; }\n .item[aria-disabled='true']:focus { background: ${t.surfaceSubtle}; }\n @media (forced-colors: active) { .panel { border-color: CanvasText; } .item[aria-current] { outline: 2px solid Highlight; outline-offset: -2px; } .item[aria-disabled='true'] { color: GrayText; } }\n .item.danger { color: ${t.dangerText}; }\n .item svg { flex: none; }\n `,\n ];\n\n private outside = (event: Event): void => {\n if (!event.composedPath().includes(this)) this.toggle(false);\n };\n\n disconnectedCallback(): void {\n super.disconnectedCallback();\n document.removeEventListener('click', this.outside);\n }\n\n private get entries(): HTMLElement[] {\n return Array.from(this.renderRoot.querySelectorAll<HTMLElement>('.item'));\n }\n\n private get trigger(): HTMLElement | null {\n return this.renderRoot.querySelector('.trigger');\n }\n\n private toggle(open: boolean, focus?: 'first' | 'last'): void {\n this.open = open;\n if (open) {\n document.addEventListener('click', this.outside);\n void this.updateComplete.then(() => {\n this.entries[focus === 'last' ? this.entries.length - 1 : 0]?.focus();\n });\n } else document.removeEventListener('click', this.outside);\n }\n\n /** However it was opened, by the button or by setting `open`, the list is kept on the screen. */\n protected updated(changed: Map<string, unknown>): void {\n super.updated?.(changed);\n if (changed.has('open') && this.open) this.keepOnScreen();\n }\n\n /** Open towards the other edge when the list would run off the screen. */\n private keepOnScreen(): void {\n const list = this.renderRoot.querySelector<HTMLElement>('.panel');\n if (!list) return;\n list.classList.remove('flip-start', 'flip-end');\n const box = list.getBoundingClientRect();\n const width = document.documentElement.clientWidth;\n if (box.right > width - 8) list.classList.add('flip-end');\n else if (box.left < 8) list.classList.add('flip-start');\n }\n\n private triggerKey(event: KeyboardEvent): void {\n if (event.key === 'ArrowDown' || event.key === 'ArrowUp') {\n event.preventDefault();\n this.toggle(true, event.key === 'ArrowUp' ? 'last' : 'first');\n }\n }\n\n private listKey(event: KeyboardEvent): void {\n const entries = this.entries;\n const at = entries.indexOf((this.renderRoot as ShadowRoot).activeElement as HTMLElement);\n const go: Record<string, number> = {\n ArrowDown: (at + 1) % entries.length,\n ArrowUp: (at - 1 + entries.length) % entries.length,\n Home: 0,\n End: entries.length - 1,\n };\n if (event.key in go) {\n event.preventDefault();\n entries[go[event.key]!]?.focus();\n } else if (event.key.length === 1 && /\\S/.test(event.key) && !event.ctrlKey && !event.metaKey && !event.altKey) {\n const letter = event.key.toLowerCase();\n const next = [...entries.slice(at + 1), ...entries.slice(0, at + 1)].find((e) => (e.textContent ?? '').trim().toLowerCase().startsWith(letter));\n next?.focus();\n } else if (event.key === 'Escape') {\n event.preventDefault();\n this.toggle(false);\n this.trigger?.focus();\n } else if (event.key === 'Tab') this.toggle(false);\n }\n\n private choose(item: MenuItem, event?: Event): void {\n if (item.disabled) {\n event?.preventDefault();\n return;\n }\n this.toggle(false);\n this.trigger?.focus();\n if (!item.href) this.dispatchEvent(new CustomEvent('impakt-select', { detail: { value: item.value ?? item.text }, bubbles: true, composed: true }));\n }\n\n private renderItem(item: MenuItem): TemplateResult {\n const meta = item.meta || (item.current ? say('You are here') : '');\n const inner = html`${iconSvg(item.icon, '18px')}<span class=\"text\" part=\"label\">${item.text}</span>${meta ? html`<span class=\"meta\" part=\"meta\">${meta}</span>` : nothing}`;\n const cls = `item ${item.tone === 'danger' ? 'danger' : ''}`;\n const current = item.current ? 'page' : nothing;\n const disabled = item.disabled ? 'true' : nothing;\n const part = item.current ? 'item current' : 'item';\n return html`<li role=\"none\">${\n item.href && !item.disabled\n ? html`<a class=${cls} part=${part} role=\"menuitem\" tabindex=\"-1\" href=${item.href} aria-current=${current} @click=${(e: Event) => this.choose(item, e)}>${inner}</a>`\n : html`<button class=${cls} part=${part} role=\"menuitem\" tabindex=\"-1\" type=\"button\" aria-current=${current} aria-disabled=${disabled} @click=${(e: Event) => this.choose(item, e)}>${inner}</button>`\n }</li>`;\n }\n\n /** The items in runs: each run of items with the same group, in order. Items with no group are a run with no label. */\n private get runs(): Array<{ group: string; items: MenuItem[] }> {\n const runs: Array<{ group: string; items: MenuItem[] }> = [];\n for (const item of this.items ?? []) {\n const group = item.group ?? '';\n const last = runs[runs.length - 1];\n const existing = group ? runs.find((r) => r.group === group) : undefined;\n if (existing) existing.items.push(item);\n else if (last && !group && !last.group) last.items.push(item);\n else runs.push({ group, items: [item] });\n }\n return runs;\n }\n\n render(): TemplateResult {\n const text = this.triggerLook === 'text';\n const runs = this.runs;\n const grouped = runs.some((r) => r.group);\n return html`<button class=\"trigger\" part=\"trigger\" type=\"button\" aria-haspopup=\"menu\" aria-expanded=${String(this.open)} aria-controls=${this.id_('list')}\n @click=${() => this.toggle(!this.open)} @keydown=${this.triggerKey}><slot name=\"trigger\">${iconSvg(this.icon, '18px')}${this.label}</slot>${\n text\n ? html`<span class=\"caret\" part=\"chevron\" aria-hidden=\"true\">${this.open ? '▴' : '▾'}</span>`\n : html`<span class=\"chev\" part=\"chevron\">${iconSvg('chevron-down', '16px')}</span>`\n }</button>\n ${\n this.open\n ? html`<div class=\"panel\" part=\"panel\">${\n this.querySelector?.(':scope > [slot=\"header\"]') ? html`<div class=\"header\" part=\"header\"><slot name=\"header\"></slot></div>` : nothing\n }<ul class=\"list\" part=\"list\" id=${this.id_('list')} role=\"menu\" aria-label=${this.label} @keydown=${this.listKey}>\n ${\n grouped\n ? runs.map((run, i) => {\n const id = this.id_(`group-${i}`);\n return html`<li role=\"none\" class=\"grouped\" part=\"group\">${run.group ? html`<span class=\"group-label\" id=${id} part=\"group-label\">${run.group}</span>` : nothing}<ul class=\"group\" role=\"group\" aria-labelledby=${run.group ? id : nothing}>${run.items.map((item) => this.renderItem(item))}</ul></li>`;\n })\n : (this.items ?? []).map((item) => this.renderItem(item))\n }\n </ul></div>`\n : nothing\n }`;\n }\n}\n\n/** Which page numbers to show: the ends and the neighbours, with gaps between. */\nexport function pageWindow(page: number, pages: number): Array<number | 'gap'> {\n const wanted = [...new Set([1, page - 1, page, page + 1, pages])].filter((n) => n >= 1 && n <= pages).sort((a, b) => a - b);\n return wanted.flatMap((n, i): Array<number | 'gap'> => {\n const previous = wanted[i - 1];\n if (previous === undefined || n === previous + 1) return [n];\n return n === previous + 2 ? [previous + 1, n] : ['gap', n];\n });\n}\n\n/**\n * Page numbers for a long list.\n *\n * Give it `href-pattern` and every number is a real link, with `{page}` swapped\n * for the number. Without one the numbers are buttons and it fires\n * `impakt-page`. On a narrow screen the numbers fold to \"Page 2 of 9\".\n *\n * @category navigation\n * @icon pagination\n * @fires {CustomEvent<{ page: number }>} impakt-page - When a page is chosen. The number is in detail.page.\n */\nexport class ImpaktPagination extends ImpaktElement {\n static properties = {\n page: { type: Number },\n pages: { type: Number },\n hrefPattern: { type: String, attribute: 'href-pattern' },\n label: { type: String },\n previousText: { type: String, attribute: 'previous-text' },\n nextText: { type: String, attribute: 'next-text' },\n };\n declare page: number;\n declare pages: number;\n declare hrefPattern: string;\n declare label: string;\n declare previousText: string;\n declare nextText: string;\n\n constructor() {\n super();\n this.page = 1;\n this.pages = 1;\n this.hrefPattern = '';\n this.label = 'Pages';\n this.previousText = 'Previous';\n this.nextText = 'Next';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n focusRing,\n touchTarget('.n, .step'),\n css`\n :host { display: block; container-type: inline-size; }\n nav { display: flex; align-items: center; justify-content: space-between; gap: ${space(2)}; }\n ul { display: flex; align-items: center; gap: ${space(1)}; margin: 0; padding: 0; list-style: none; }\n .n, .step { ${targetSize} box-sizing: border-box; display: inline-flex; align-items: center; justify-content: center; gap: ${space(1.5)}; min-inline-size: 44px; padding: 0 ${space(2.5)}; font: inherit; ${type('sm')} font-weight: ${fontWeight('medium')}; color: ${t.text}; text-decoration: none; background: none; border: 0; border-radius: ${t.radiusLg}; cursor: pointer; }\n .n:hover, .step:hover { background: ${t.surfaceSubtle}; }\n .n[aria-current] { color: ${t.onBrand}; background: ${t.brand}; font-weight: ${fontWeight('semibold')}; }\n .step[aria-disabled='true'] { color: ${t.textMuted}; opacity: 0.55; background: none; cursor: not-allowed; }\n .gap { color: ${t.textMuted}; padding: 0 ${space(1)}; }\n .count { display: none; ${type('sm')} color: ${t.textMuted}; }\n @container (max-width: 34rem) { ul { display: none; } .count { display: block; } }\n `,\n ];\n\n private go(page: number, event: Event): void {\n if (this.hrefPattern) return;\n event.preventDefault();\n this.page = page;\n this.dispatchEvent(new CustomEvent('impakt-page', { detail: { page }, bubbles: true, composed: true }));\n }\n\n private link(page: number, classes: string, content: unknown, label: string, current: boolean): TemplateResult {\n return this.hrefPattern\n ? html`<a class=${classes} href=${this.hrefPattern.replace('{page}', String(page))} aria-label=${label} aria-current=${current ? 'page' : nothing}>${content}</a>`\n : html`<button class=${classes} type=\"button\" aria-label=${label} aria-current=${current ? 'page' : nothing} @click=${(e: Event) => this.go(page, e)}>${content}</button>`;\n }\n\n private step(to: number, words: string, icon: string, off: boolean): TemplateResult {\n const content = icon === 'arrow-left' ? html`${iconSvg(icon, '16px')}${words}` : html`${words}${iconSvg(icon, '16px')}`;\n return off ? html`<span class=\"step\" aria-disabled=\"true\">${content}</span>` : this.link(to, 'step', content, words, false);\n }\n\n render(): TemplateResult {\n const page = Math.min(Math.max(this.page, 1), Math.max(this.pages, 1));\n return html`<nav aria-label=${this.label} part=\"nav\">\n ${this.step(page - 1, this.previousText, 'arrow-left', page <= 1)}\n <ul>${pageWindow(page, this.pages).map((n) => html`<li>${n === 'gap' ? html`<span class=\"gap\" aria-hidden=\"true\">…</span>` : this.link(n, 'n', n, say('Page {page}', { page: n }), n === page)}</li>`)}</ul>\n <span class=\"count\">${say('Page {page} of {pages}', { page, pages: this.pages })}</span>\n ${this.step(page + 1, this.nextText, 'arrow-right', page >= this.pages)}\n </nav>`;\n }\n}\n\nconst initialsOf = (name: string): string => {\n const words = name.trim().split(/\\s+/).filter(Boolean);\n return ((words[0]?.[0] ?? '') + (words.length > 1 ? words[words.length - 1]![0]! : '')).toUpperCase();\n};\n\n/**\n * A person's photo, or their initials when there is no photo or it fails.\n *\n * @category content\n * @icon avatar\n */\nexport class ImpaktAvatar extends ImpaktElement {\n static properties = {\n fullName: { type: String, attribute: 'full-name' },\n src: { type: String },\n size: { type: String, reflect: true },\n };\n declare fullName: string;\n declare src: string;\n /** `xs` is 22px, for a row of people in a header. */\n declare size: 'xs' | 'sm' | 'md' | 'lg' | 'xl';\n\n private failed = false;\n\n constructor() {\n super();\n this.fullName = '';\n this.src = '';\n this.size = 'md';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n css`\n :host { --size: 40px; display: inline-block; inline-size: var(--size); block-size: var(--size); vertical-align: middle; }\n :host([size='xs']) { --size: 22px; }\n :host([size='sm']) { --size: 32px; }\n :host([size='lg']) { --size: 56px; }\n :host([size='xl']) { --size: 80px; }\n .face { display: flex; align-items: center; justify-content: center; inline-size: 100%; block-size: 100%; overflow: hidden; color: ${t.brand}; background: ${t.brandSubtle}; border-radius: 50%; font-size: calc(var(--size) * 0.38); font-weight: ${fontWeight('semibold')}; }\n img { inline-size: 100%; block-size: 100%; object-fit: cover; }\n `,\n ];\n\n willUpdate(changed: Map<string, unknown>): void {\n if (changed.has('src')) this.failed = false;\n }\n\n render(): TemplateResult {\n if (this.src && !this.failed) {\n return html`<div class=\"face\"><img src=${this.src} alt=${this.fullName} @error=${() => {\n this.failed = true;\n this.requestUpdate();\n }} /></div>`;\n }\n return html`<div class=\"face\" role=\"img\" aria-label=${this.fullName || say('Person')}>${initialsOf(this.fullName) || iconSvg('user', '55%')}</div>`;\n }\n}\n\nexport interface AvatarItem {\n id?: string;\n name: string;\n src?: string;\n}\n\n/**\n * A few people overlapped in a row, with a count for the rest: the sales team,\n * the neighbours who have already moved in.\n *\n * @category content\n * @icon avatars\n */\nexport class ImpaktAvatarGroup extends ImpaktElement {\n static properties = {\n items: { type: Array },\n max: { type: Number },\n size: { type: String, reflect: true },\n moreLabel: { type: String, attribute: 'more-label' },\n };\n declare items: AvatarItem[];\n declare max: number;\n /** `xs` is 22px faces with a 1px ink outline, overlapped less, as in the G2 site header (frame 9:264). */\n declare size: 'xs' | 'sm' | 'md' | 'lg';\n /** How the people left out are described to a screen reader, after the number. */\n declare moreLabel: string;\n\n constructor() {\n super();\n this.items = [];\n this.max = 4;\n this.size = 'md';\n this.moreLabel = 'more people';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n css`\n ul { display: flex; margin: 0; padding: 0; list-style: none; }\n li { margin-inline-start: -${space(2.5)}; border-radius: 50%; box-shadow: 0 0 0 2px ${t.surfaceCard}; line-height: 0; }\n li:first-child { margin-inline-start: 0; }\n .more { display: flex; align-items: center; justify-content: center; inline-size: 40px; block-size: 40px; ${type('xs')} line-height: 1; font-weight: ${fontWeight('semibold')}; color: ${t.text}; background: ${t.surfaceSubtle}; border-radius: 50%; }\n :host([size='sm']) .more { inline-size: 32px; block-size: 32px; }\n :host([size='xs']) li { margin-inline-start: -${space(1)}; box-shadow: 0 0 0 1px ${t.text}; }\n :host([size='xs']) li:first-child { margin-inline-start: 0; }\n :host([size='xs']) .more { inline-size: 22px; block-size: 22px; font-size: 10px; }\n :host([size='lg']) .more { inline-size: 56px; block-size: 56px; }\n .sr { ${visuallyHidden} }\n `,\n ];\n\n render(): TemplateResult {\n const shown = this.items.slice(0, this.max);\n const rest = this.items.length - shown.length;\n return html`<ul part=\"list\">\n ${shown.map((item) => html`<li><impakt-avatar full-name=${item.name} src=${item.src ?? ''} size=${this.size}></impakt-avatar></li>`)}\n ${rest > 0 ? html`<li><span class=\"more\"><span aria-hidden=\"true\">+${rest}</span><span class=\"sr\">${rest} ${this.moreLabel}</span></span></li>` : nothing}\n </ul>`;\n }\n}\n\n/**\n * What a list says when it has nothing in it, and what to do about that.\n *\n * @category feedback\n * @icon empty\n * @role heading\n * @slot actions - The next thing to do, usually one button.\n */\nexport class ImpaktEmptyState extends ImpaktElement {\n static properties = {\n icon: { type: String },\n heading: { type: String },\n lead: { type: String },\n framed: { type: Boolean, reflect: true },\n headingLevel: { type: Number, attribute: 'heading-level' },\n spaceAbove: { type: String, reflect: true, attribute: 'space-above' },\n spaceBelow: { type: String, reflect: true, attribute: 'space-below' },\n };\n declare icon: string;\n declare heading: string;\n declare lead: string;\n /** Draws a dashed outline round it. */\n declare framed: boolean;\n declare headingLevel: 2 | 3 | 4;\n declare spaceAbove: 'none' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';\n declare spaceBelow: 'none' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';\n\n constructor() {\n super();\n this.icon = 'search';\n this.heading = '';\n this.lead = '';\n this.framed = false;\n this.headingLevel = 2;\n this.spaceAbove = 'none';\n this.spaceBelow = 'none';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n spaceAround,\n css`\n .wrap { display: flex; flex-direction: column; align-items: center; gap: ${space(2)}; padding: ${space(12)} ${space(6)}; text-align: center; }\n :host([framed]) .wrap { border: ${t.borderThin} dashed ${t.border}; border-radius: ${t.radiusXl}; }\n .mark { display: inline-flex; align-items: center; justify-content: center; inline-size: 56px; block-size: 56px; margin-block-end: ${space(2)}; color: ${t.brand}; background: ${t.brandSubtle}; border-radius: 50%; }\n .h { margin: 0; font-family: ${t.fontHeading}; ${type('xl')} font-weight: ${fontWeight('bold')}; color: ${t.textHeading}; }\n p { margin: 0; max-inline-size: 42ch; color: ${t.textMuted}; text-wrap: pretty; }\n .actions { display: flex; flex-wrap: wrap; justify-content: center; gap: ${space(3)}; margin-block-start: ${space(3)}; }\n `,\n ];\n\n render(): TemplateResult {\n return html`<div class=\"wrap\" part=\"wrap\">\n <span class=\"mark\">${iconSvg(this.icon, '26px')}</span>\n ${this.heading ? html`<div class=\"h\" role=\"heading\" aria-level=${this.headingLevel}>${this.heading}</div>` : nothing}\n ${this.lead ? html`<p>${this.lead}</p>` : nothing}\n <div class=\"actions\"><slot name=\"actions\"></slot></div>\n </div>`;\n }\n}\n\nexport interface SlotDay {\n id?: string;\n /** The day, as 2026-11-14. */\n date: string;\n /** The times on offer, separated by commas: 10:00, 11:30, 14:00. */\n times: string;\n}\n\nconst timesOf = (day: SlotDay | undefined): string[] =>\n String(day?.times ?? '')\n .split(',')\n .map((time) => time.trim())\n .filter(Boolean);\n\n/** A day's parts in the page's language. A date that cannot be read is shown as it was written. */\nfunction dayParts(date: string): { weekday: string; day: string; month: string } {\n const parsed = new Date(`${date}T00:00:00Z`);\n if (Number.isNaN(parsed.getTime())) return { weekday: '', day: date, month: '' };\n const locale = pageLocale();\n const part = (options: Intl.DateTimeFormatOptions): string => new Intl.DateTimeFormat(locale, { timeZone: 'UTC', ...options }).format(parsed);\n return { weekday: part({ weekday: 'short' }), day: part({ day: 'numeric' }), month: part({ month: 'short' }) };\n}\n\n/**\n * Choose a day, then a time: a viewing, a call back, a site visit.\n *\n * Both rows are native radios under the styling, so the arrow keys and screen\n * readers work as they do for any radio group. Its value is the day and time\n * together, as 2026-11-14T10:00.\n *\n * @category form\n * @icon calendar\n */\nexport class ImpaktSlotPicker extends FieldElement {\n static properties = {\n ...FieldElement.properties,\n days: { type: Array },\n dayLabel: { type: String, attribute: 'day-label' },\n timeLabel: { type: String, attribute: 'time-label' },\n emptyText: { type: String, attribute: 'empty-text' },\n };\n declare days: SlotDay[];\n declare dayLabel: string;\n declare timeLabel: string;\n /** What is said when no times are on offer. */\n declare emptyText: string;\n\n private day = '';\n\n constructor() {\n super();\n this.days = [];\n this.dayLabel = 'Day';\n this.timeLabel = 'Time';\n this.emptyText = 'No times are available at the moment.';\n }\n\n static styles = [\n ...FieldElement.styles,\n css`\n fieldset { min-inline-size: 0; margin: 0; padding: 0; border: 0; }\n legend { padding: 0; }\n .row-label { ${type('sm')} color: ${t.textMuted}; margin-block: ${space(2)}; }\n .days { display: flex; gap: ${space(2)}; overflow-x: auto; padding: ${space(1)}; margin: -${space(1)}; scrollbar-width: thin; }\n .times { display: grid; grid-template-columns: repeat(auto-fill, minmax(5.5rem, 1fr)); gap: ${space(2)}; }\n label { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; box-sizing: border-box; min-block-size: 44px; color: ${t.text}; background: ${t.surfaceCard}; border-radius: ${t.radiusLg}; box-shadow: inset 0 0 0 1px ${t.border}; cursor: pointer; transition: background-color 120ms ease-in-out; }\n label:hover { background: ${t.surfaceSubtle}; }\n label:has(input:checked) { color: ${t.onBrand}; background: ${t.brand}; box-shadow: none; }\n label:has(input:focus-visible) { box-shadow: ${t.focusShadow}; }\n input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }\n .day { flex: none; inline-size: 4.5rem; padding-block: ${space(2.5)}; }\n .weekday, .month { ${type('xs')} }\n .num { ${type('xl')} font-weight: ${fontWeight('semibold')}; }\n .time { padding: ${space(2)}; ${type('sm')} font-weight: ${fontWeight('medium')}; }\n .empty { margin: 0; color: ${t.textMuted}; }\n :host([invalid]) .days label, :host([invalid]) .times label { box-shadow: inset 0 0 0 1px ${t.danger}; }\n `,\n ];\n\n private get currentDay(): SlotDay | undefined {\n const wanted = this.day || this.value.split('T')[0];\n return this.days.find((day) => day.date === wanted) ?? this.days[0];\n }\n\n private chooseDay(date: string): void {\n this.day = date;\n if (this.value && !this.value.startsWith(`${date}T`)) this.setFormValue('');\n this.requestUpdate();\n }\n\n protected renderLabel(): TemplateResult {\n return html`<legend class=\"label\" part=\"label\">${this.label}${this.required ? html`<span class=\"required\"> (${this.requiredText})</span>` : nothing}</legend>`;\n }\n\n protected renderControl(): TemplateResult {\n const current = this.currentDay;\n if (!current) return html`<p class=\"empty\">${this.emptyText}</p>`;\n return html`\n <div class=\"row-label\" id=${this.id_('days')}>${this.dayLabel}</div>\n <div class=\"days\" part=\"days\" role=\"radiogroup\" aria-labelledby=${this.id_('days')}>\n ${this.days.map((day) => {\n const parts = dayParts(day.date);\n return html`<label class=\"day\"><input type=\"radio\" name=${`${this.uid}-day`} .checked=${day.date === current.date} ?disabled=${this.disabled} @change=${() => this.chooseDay(day.date)} />\n <span class=\"weekday\">${parts.weekday}</span><span class=\"num\">${parts.day}</span><span class=\"month\">${parts.month}</span></label>`;\n })}\n </div>\n <div class=\"row-label\" id=${this.id_('times')}>${this.timeLabel}</div>\n <div class=\"times\" part=\"times\" role=\"radiogroup\" aria-labelledby=${this.id_('times')}>\n ${timesOf(current).map((time, i) => {\n const value = `${current.date}T${time}`;\n return html`<label class=\"time\"><input type=\"radio\" name=${`${this.uid}-time`} .checked=${this.value === value} ?required=${this.required && i === 0} ?disabled=${this.disabled} @change=${() => this.setFormValue(value)} />${time}</label>`;\n })}\n </div>`;\n }\n\n render(): TemplateResult {\n return html`<fieldset part=\"fieldset\" ?disabled=${this.disabled} aria-describedby=${this.describedBy} aria-invalid=${this.error ? 'true' : nothing}>\n ${this.renderLabel()}\n ${this.description ? html`<div class=\"description\" id=${this.id_('description')} part=\"description\">${this.description}</div>` : nothing}\n ${this.renderControl()}\n <div class=\"error\" id=${this.id_('error')} part=\"error\" aria-live=\"polite\">${this.error || nothing}</div>\n </fieldset>`;\n }\n\n updated(changed: Map<string, unknown>): void {\n if (changed.has('error')) this.toggleAttribute('invalid', Boolean(this.error));\n }\n}\n\ncustomElements.define('impakt-drawer', ImpaktDrawer);\ncustomElements.define('impakt-toast', ImpaktToast);\ncustomElements.define('impakt-menu', ImpaktMenu);\ncustomElements.define('impakt-pagination', ImpaktPagination);\ncustomElements.define('impakt-avatar', ImpaktAvatar);\ncustomElements.define('impakt-avatar-group', ImpaktAvatarGroup);\ncustomElements.define('impakt-empty-state', ImpaktEmptyState);\ncustomElements.define('impakt-slot-picker', ImpaktSlotPicker);\ndeclare global {\n interface HTMLElementTagNameMap {\n 'impakt-drawer': ImpaktDrawer;\n 'impakt-toast': ImpaktToast;\n 'impakt-menu': ImpaktMenu;\n 'impakt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AO,EAAG,MAAK,gBAAgB,WAAW,QAAQ,KAAK,KAAK,CAAC;AAAA,EAC/E;AACF;AAEA,eAAe,OAAO,iBAAiB,YAAY;AACnD,eAAe,OAAO,gBAAgB,WAAW;AACjD,eAAe,OAAO,eAAe,UAAU;AAC/C,eAAe,OAAO,qBAAqB,gBAAgB;AAC3D,eAAe,OAAO,iBAAiB,YAAY;AACnD,eAAe,OAAO,uBAAuB,iBAAiB;AAC9D,eAAe,OAAO,sBAAsB,gBAAgB;AAC5D,eAAe,OAAO,sBAAsB,gBAAgB;","names":[]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
FieldElement
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-PII4SJL5.js";
|
|
4
4
|
import {
|
|
5
5
|
say
|
|
6
6
|
} from "./chunk-72WNCCDC.js";
|
|
@@ -137,4 +137,4 @@ customElements.define("impakt-date-input", ImpaktDateInput);
|
|
|
137
137
|
export {
|
|
138
138
|
ImpaktDateInput
|
|
139
139
|
};
|
|
140
|
-
//# sourceMappingURL=chunk-
|
|
140
|
+
//# sourceMappingURL=chunk-P5FAKEFK.js.map
|
|
@@ -8,7 +8,8 @@ import {
|
|
|
8
8
|
fontWeight,
|
|
9
9
|
lineHeight,
|
|
10
10
|
space,
|
|
11
|
-
t
|
|
11
|
+
t,
|
|
12
|
+
token
|
|
12
13
|
} from "./chunk-JTCTQBAX.js";
|
|
13
14
|
|
|
14
15
|
// packages/ui/src/base/FieldElement.ts
|
|
@@ -20,26 +21,40 @@ var fieldWidths = css`
|
|
|
20
21
|
:host([width='md']) { --impakt-field-width: 24ch; }
|
|
21
22
|
:host([width='lg']) { --impakt-field-width: 40ch; }
|
|
22
23
|
`;
|
|
24
|
+
var F = {
|
|
25
|
+
height: token("field.height", "44px"),
|
|
26
|
+
paddingBlock: token("field.padding-block", "10px"),
|
|
27
|
+
paddingInline: token("field.padding-inline", "12px"),
|
|
28
|
+
lineHeight: token("field.line-height", "normal"),
|
|
29
|
+
radius: token("field.radius", "8px"),
|
|
30
|
+
edge: token("field.edge", "0%"),
|
|
31
|
+
focusEdge: token("field.focus-edge", "0%"),
|
|
32
|
+
focusHalo: token("field.focus-halo", "6px")
|
|
33
|
+
};
|
|
23
34
|
var fieldControl = (selector) => {
|
|
24
35
|
const s = unsafeCSS(selector);
|
|
25
36
|
return css`
|
|
26
37
|
${s} {
|
|
27
38
|
inline-size: min(100%, var(--impakt-field-width));
|
|
28
|
-
min-block-size:
|
|
29
|
-
padding:
|
|
39
|
+
min-block-size: ${F.height};
|
|
40
|
+
padding: ${F.paddingBlock} ${F.paddingInline};
|
|
30
41
|
font-family: inherit;
|
|
31
42
|
font-size: ${fontSize("md")};
|
|
32
|
-
line-height:
|
|
43
|
+
line-height: ${F.lineHeight};
|
|
33
44
|
color: ${t.text};
|
|
34
45
|
background: var(--impakt-color-field-surface, ${t.surfaceCard});
|
|
35
|
-
border: ${t.borderThin} solid var(--impakt-color-field-border, ${t.text});
|
|
36
|
-
border-radius: ${
|
|
37
|
-
box-shadow: var(--impakt-shadow-field,
|
|
46
|
+
border: ${t.borderThin} solid var(--impakt-color-field-border, color-mix(in srgb, ${t.text} ${F.edge}, ${t.border}));
|
|
47
|
+
border-radius: ${F.radius};
|
|
48
|
+
box-shadow: var(--impakt-shadow-field, ${t.shadowXs});
|
|
38
49
|
transition: border-color 120ms ease-in-out, box-shadow 120ms ease-in-out;
|
|
39
50
|
}
|
|
51
|
+
${s}:hover:not(:disabled) {
|
|
52
|
+
border-color: var(--impakt-color-field-border, color-mix(in srgb, ${t.text} ${F.edge}, ${t.borderStrong}));
|
|
53
|
+
}
|
|
54
|
+
/* The focus ring, and the brand's halo round it where the brand draws one, so the field being typed in is plain at a glance. */
|
|
40
55
|
${s}:focus-visible {
|
|
41
|
-
border-color: ${t.text};
|
|
42
|
-
box-shadow: ${t.focusShadow};
|
|
56
|
+
border-color: color-mix(in srgb, ${t.text} ${F.focusEdge}, ${t.brand});
|
|
57
|
+
box-shadow: ${t.focusShadow}, 0 0 0 ${F.focusHalo} ${t.brandHalo};
|
|
43
58
|
}
|
|
44
59
|
${s}::placeholder {
|
|
45
60
|
color: ${t.textPlaceholder};
|
|
@@ -101,19 +116,20 @@ var FieldElement = class extends ImpaktElement {
|
|
|
101
116
|
margin-block-end: ${space(4)};
|
|
102
117
|
}
|
|
103
118
|
/*
|
|
104
|
-
* The question, in the
|
|
105
|
-
*
|
|
106
|
-
*
|
|
119
|
+
* The question, at 14px in the ink: semibold in the body face, or under Noire in the code
|
|
120
|
+
* face (G2). The brand sets the face and weight (field.label.*); a page can set it
|
|
121
|
+
* another way through these properties, such as the site's contact form, which sets its
|
|
122
|
+
* labels in capitals at 11px (frame 20:1157).
|
|
107
123
|
*/
|
|
108
124
|
.label {
|
|
109
125
|
display: block;
|
|
110
|
-
font-family: var(--impakt-field-label-font, ${t.
|
|
126
|
+
font-family: var(--impakt-field-label-font, ${t.fontBody});
|
|
111
127
|
font-size: var(--impakt-field-label-size, ${fontSize("sm")});
|
|
112
|
-
font-weight: var(--impakt-field-label-weight, ${fontWeight("
|
|
128
|
+
font-weight: var(--impakt-field-label-weight, ${fontWeight("semibold")});
|
|
113
129
|
letter-spacing: var(--impakt-field-label-tracking, normal);
|
|
114
130
|
text-transform: var(--impakt-field-label-transform, none);
|
|
115
131
|
line-height: ${lineHeight("normal")};
|
|
116
|
-
margin-block-end: ${space(
|
|
132
|
+
margin-block-end: var(--impakt-field-label-space, ${space(1)});
|
|
117
133
|
color: ${t.text};
|
|
118
134
|
}
|
|
119
135
|
.required {
|
|
@@ -231,4 +247,4 @@ export {
|
|
|
231
247
|
fieldControl,
|
|
232
248
|
FieldElement
|
|
233
249
|
};
|
|
234
|
-
//# sourceMappingURL=chunk-
|
|
250
|
+
//# sourceMappingURL=chunk-PII4SJL5.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/base/FieldElement.ts"],"sourcesContent":["import { html, css, nothing, unsafeCSS, type CSSResult, type TemplateResult } from 'lit';\nimport { ImpaktElement } from './ImpaktElement';\nimport { focusRing, visuallyHidden } from './styles';\nimport { fontSize, fontWeight, lineHeight, space, t, token } from './tokens';\n\n/**\n * The shared anatomy of a form control: a label, an optional description, a\n * control, and an error.\n *\n * This exists because the ARIA wiring between those four is where accessible\n * forms actually fail, and it fails the same way every time — a description\n * that is never announced, an error that appears silently, a label that points\n * at nothing. Written once, it is right once.\n *\n * Everything is rendered inside this component's own shadow root, including\n * the native control. That is not an implementation detail: `aria-describedby`\n * cannot cross a shadow boundary, so a component that slotted the input from\n * outside could not describe it. Keeping the whole relationship in one tree is\n * what makes the wiring work at all.\n */\n/**\n * How wide a single-line control is, from what it holds: a postcode is short,\n * an email address is long. A width that matches the answer is a hint about\n * what to type (1.3.5 is about the purpose, this is about the size). Applied by\n * the controls that take a `width`, through `--impakt-field-width`.\n */\nexport const fieldWidths = css`\n :host { --impakt-field-width: 100%; }\n :host([width='xs']) { --impakt-field-width: 8ch; }\n :host([width='sm']) { --impakt-field-width: 14ch; }\n :host([width='md']) { --impakt-field-width: 24ch; }\n :host([width='lg']) { --impakt-field-width: 40ch; }\n`;\n\n/**\n * The field's shape, from the brand (`field.*` in `@atomic-ui/design-tokens`). Each fallback is\n * the shape every brand derives: a 44px box with the grey border that darkens when pointed at,\n * and the brand's halo round the focus ring. The Impakt theme sets the G2 Noire shape over it:\n * a 50px box with an ink edge and the plain focus ring (frames 33:492 and 36:398).\n *\n * An edge is how much of the text colour it takes, mixed here rather than on the root, so a\n * band that repaints the text colour repaints the edge with it.\n */\nexport const F = {\n height: token('field.height', '44px'),\n paddingBlock: token('field.padding-block', '10px'),\n paddingInline: token('field.padding-inline', '12px'),\n lineHeight: token('field.line-height', 'normal'),\n radius: token('field.radius', '8px'),\n edge: token('field.edge', '0%'),\n focusEdge: token('field.focus-edge', '0%'),\n focusHalo: token('field.focus-halo', '6px'),\n};\n\n/**\n * The box a single control is drawn in, shared by the text input, the select and\n * the textarea so they match, in the brand's field shape (`F` above).\n * A product can still set `--impakt-shadow-field` or `--impakt-color-field-border`.\n */\nexport const fieldControl = (selector: string): CSSResult => {\n const s = unsafeCSS(selector);\n return css`\n ${s} {\n inline-size: min(100%, var(--impakt-field-width));\n min-block-size: ${F.height};\n padding: ${F.paddingBlock} ${F.paddingInline};\n font-family: inherit;\n font-size: ${fontSize('md')};\n line-height: ${F.lineHeight};\n color: ${t.text};\n background: var(--impakt-color-field-surface, ${t.surfaceCard});\n border: ${t.borderThin} solid var(--impakt-color-field-border, color-mix(in srgb, ${t.text} ${F.edge}, ${t.border}));\n border-radius: ${F.radius};\n box-shadow: var(--impakt-shadow-field, ${t.shadowXs});\n transition: border-color 120ms ease-in-out, box-shadow 120ms ease-in-out;\n }\n ${s}:hover:not(:disabled) {\n border-color: var(--impakt-color-field-border, color-mix(in srgb, ${t.text} ${F.edge}, ${t.borderStrong}));\n }\n /* The focus ring, and the brand's halo round it where the brand draws one, so the field being typed in is plain at a glance. */\n ${s}:focus-visible {\n border-color: color-mix(in srgb, ${t.text} ${F.focusEdge}, ${t.brand});\n box-shadow: ${t.focusShadow}, 0 0 0 ${F.focusHalo} ${t.brandHalo};\n }\n ${s}::placeholder {\n color: ${t.textPlaceholder};\n }\n ${s}:disabled {\n background: ${t.surfaceInset};\n cursor: not-allowed;\n }\n /* The border thickens as well as reddening, and the message below says it in words (1.4.1). */\n :host([invalid]) ${s} {\n border-color: ${t.danger};\n border-width: ${t.borderThick};\n }\n `;\n};\n\n/**\n * The base of every form control.\n *\n * @fires {CustomEvent<{ value: string }>} impakt-change - When the answer changes. The answer is in detail.value.\n */\nexport abstract class FieldElement extends ImpaktElement {\n /** Form controls participate in a `<form>` like native ones. */\n static formAssociated = true;\n\n static properties = {\n label: { type: String },\n name: { type: String },\n value: { type: String },\n description: { type: String },\n error: { type: String },\n required: { type: Boolean, reflect: true },\n disabled: { type: Boolean, reflect: true },\n readonly: { type: Boolean, reflect: true },\n requiredText: { type: String, attribute: 'required-text' },\n };\n\n declare label: string;\n declare name: string;\n declare value: string;\n declare description: string;\n declare error: string;\n declare required: boolean;\n declare disabled: boolean;\n declare readonly: boolean;\n /**\n * How \"you must answer this\" is said.\n *\n * Words, not an asterisk. 3.3.2 asks for labels or instructions, and an\n * asterisk is neither until a legend explains it — which puts the\n * explanation somewhere other than the field it explains. It is a property\n * so a partner can reword it, not so they can empty it.\n */\n declare requiredText: string;\n\n protected internals: ElementInternals | null = null;\n\n constructor() {\n super();\n this.label = '';\n this.name = '';\n this.value = '';\n this.description = '';\n this.error = '';\n this.required = false;\n this.disabled = false;\n this.readonly = false;\n this.requiredText = 'required';\n // happy-dom and older engines do not implement attachInternals. A control\n // that cannot associate with a form is still a usable control, so this\n // degrades rather than throwing on construction.\n try {\n this.internals = this.attachInternals();\n } catch {\n this.internals = null;\n }\n }\n\n static styles = [\n ...ImpaktElement.styles,\n focusRing,\n css`\n :host {\n display: block;\n margin-block-end: ${space(4)};\n }\n /*\n * The question, at 14px in the ink: semibold in the body face, or under Noire in the code\n * face (G2). The brand sets the face and weight (field.label.*); a page can set it\n * another way through these properties, such as the site's contact form, which sets its\n * labels in capitals at 11px (frame 20:1157).\n */\n .label {\n display: block;\n font-family: var(--impakt-field-label-font, ${t.fontBody});\n font-size: var(--impakt-field-label-size, ${fontSize('sm')});\n font-weight: var(--impakt-field-label-weight, ${fontWeight('semibold')});\n letter-spacing: var(--impakt-field-label-tracking, normal);\n text-transform: var(--impakt-field-label-transform, none);\n line-height: ${lineHeight('normal')};\n margin-block-end: var(--impakt-field-label-space, ${space(1)});\n color: ${t.text};\n }\n .required {\n font-weight: ${fontWeight('regular')};\n color: ${t.textMuted};\n }\n .description {\n font-size: ${fontSize('sm')};\n line-height: ${lineHeight('normal')};\n color: ${t.textMuted};\n margin-block-end: ${space(2)};\n }\n .error {\n font-size: ${fontSize('sm')};\n line-height: ${lineHeight('normal')};\n color: ${t.dangerText};\n margin-block-start: ${space(1)};\n display: flex;\n gap: ${space(1)};\n }\n .error:empty {\n display: none;\n }\n .visually-hidden {\n ${visuallyHidden}\n }\n /*\n * Only the control is dimmed. Dimming the whole host took the question,\n * the hint and the error below 4.5:1, and a disabled field still has to\n * say what it is and why it cannot be changed. The native disabled\n * control itself is exempt from the contrast criterion.\n */\n :host([disabled]) :is(input, select, textarea, button) {\n opacity: 0.6;\n cursor: not-allowed;\n }\n `,\n ];\n\n protected get controlId(): string {\n return this.id_('control');\n }\n\n /**\n * What the control points `aria-describedby` at.\n *\n * The error id is included only while there is an error. A describedby that\n * always names an empty element trains a screen-reader user to expect\n * nothing after the description, and then the one time it matters they have\n * already learned to ignore it.\n */\n protected get describedBy(): string | typeof nothing {\n const ids = [this.description ? this.id_('description') : '', this.error ? this.id_('error') : ''].filter(Boolean);\n return ids.length ? ids.join(' ') : nothing;\n }\n\n /**\n * Focusing the element focuses its control, so `el.focus()` from an app, a\n * React ref or the error summary's link lands where someone can type, rather\n * than on a host that cannot take focus and so silently does nothing.\n */\n focus(options?: FocusOptions): void {\n const control =\n this.renderRoot?.querySelector<HTMLElement>(`#${this.controlId}`) ?? this.renderRoot?.querySelector<HTMLElement>('input, select, textarea, button');\n if (control) control.focus(options);\n else super.focus(options);\n }\n\n /** Subclasses render the control itself; everything round it is here. */\n protected abstract renderControl(): TemplateResult;\n\n /**\n * `<label for>` by default. A group of controls — radios, checkboxes —\n * cannot use one, because `for` names a single control, so those override\n * this and render a `<fieldset>` and `<legend>` instead.\n */\n protected renderLabel(): TemplateResult {\n return html`\n <label class=\"label\" for=${this.controlId} part=\"label\">\n ${this.label}${this.required ? html`<span class=\"required\"> (${this.requiredText})</span>` : nothing}\n </label>\n `;\n }\n\n render(): TemplateResult {\n return html`\n ${this.renderLabel()}\n ${\n this.description\n ? html`<div class=\"description\" id=${this.id_('description')} part=\"description\">\n ${this.description}\n </div>`\n : nothing\n }\n ${this.renderControl()}\n <!--\n The error region is always present, even when empty. A live region\n inserted at the same moment as its content is announced unreliably\n across screen readers; one that already exists and is then filled is\n announced consistently. \"polite\" rather than \"assertive\" because a\n validation message should not interrupt what is being read.\n -->\n <div\n class=\"error\"\n id=${this.id_('error')}\n part=\"error\"\n aria-live=\"polite\"\n >\n ${this.error || nothing}\n </div>\n `;\n }\n\n /** Keep the form value in step with the control. */\n protected setFormValue(value: string): void {\n this.value = value;\n this.internals?.setFormValue(value);\n this.dispatchEvent(new CustomEvent('impakt-change', { detail: this.changeDetail(value), bubbles: true, composed: true }));\n }\n\n /** What `impakt-change` carries. A control with more to say than its value adds it here. */\n protected changeDetail(value: string): { value: string } {\n return { value };\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;AAAA,SAAS,MAAM,KAAK,SAAS,iBAAsD;AA0B5E,IAAM,cAAc;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAiBpB,IAAM,IAAI;AAAA,EACf,QAAQ,MAAM,gBAAgB,MAAM;AAAA,EACpC,cAAc,MAAM,uBAAuB,MAAM;AAAA,EACjD,eAAe,MAAM,wBAAwB,MAAM;AAAA,EACnD,YAAY,MAAM,qBAAqB,QAAQ;AAAA,EAC/C,QAAQ,MAAM,gBAAgB,KAAK;AAAA,EACnC,MAAM,MAAM,cAAc,IAAI;AAAA,EAC9B,WAAW,MAAM,oBAAoB,IAAI;AAAA,EACzC,WAAW,MAAM,oBAAoB,KAAK;AAC5C;AAOO,IAAM,eAAe,CAAC,aAAgC;AAC3D,QAAM,IAAI,UAAU,QAAQ;AAC5B,SAAO;AAAA,MACH,CAAC;AAAA;AAAA,wBAEiB,EAAE,MAAM;AAAA,iBACf,EAAE,YAAY,IAAI,EAAE,aAAa;AAAA;AAAA,mBAE/B,SAAS,IAAI,CAAC;AAAA,qBACZ,EAAE,UAAU;AAAA,eAClB,EAAE,IAAI;AAAA,sDACiC,EAAE,WAAW;AAAA,gBACnD,EAAE,UAAU,8DAA8D,EAAE,IAAI,IAAI,EAAE,IAAI,KAAK,EAAE,MAAM;AAAA,uBAChG,EAAE,MAAM;AAAA,+CACg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KAAK,GAAG,IAAI;AAAA,EACtC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,SAA8B;AAClC,UAAM,UACJ,KAAK,YAAY,cAA2B,IAAI,KAAK,SAAS,EAAE,KAAK,KAAK,YAAY,cAA2B,iCAAiC;AACpJ,QAAI,QAAS,SAAQ,MAAM,OAAO;AAAA,QAC7B,OAAM,MAAM,OAAO;AAAA,EAC1B;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAUU,cAA8B;AACtC,WAAO;AAAA,iCACsB,KAAK,SAAS;AAAA,UACrC,KAAK,KAAK,GAAG,KAAK,WAAW,gCAAgC,KAAK,YAAY,aAAa,OAAO;AAAA;AAAA;AAAA,EAG1G;AAAA,EAEA,SAAyB;AACvB,WAAO;AAAA,QACH,KAAK,YAAY,CAAC;AAAA,QAElB,KAAK,cACD,mCAAmC,KAAK,IAAI,aAAa,CAAC;AAAA,cACxD,KAAK,WAAW;AAAA,oBAElB,OACN;AAAA,QACE,KAAK,cAAc,CAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,aAUf,KAAK,IAAI,OAAO,CAAC;AAAA;AAAA;AAAA;AAAA,UAIpB,KAAK,SAAS,OAAO;AAAA;AAAA;AAAA,EAG7B;AAAA;AAAA,EAGU,aAAa,OAAqB;AAC1C,SAAK,QAAQ;AACb,SAAK,WAAW,aAAa,KAAK;AAClC,SAAK,cAAc,IAAI,YAAY,iBAAiB,EAAE,QAAQ,KAAK,aAAa,KAAK,GAAG,SAAS,MAAM,UAAU,KAAK,CAAC,CAAC;AAAA,EAC1H;AAAA;AAAA,EAGU,aAAa,OAAkC;AACvD,WAAO,EAAE,MAAM;AAAA,EACjB;AACF;","names":[]}
|
|
@@ -177,7 +177,7 @@ var ImpaktSection = class extends ImpaktElement {
|
|
|
177
177
|
:host([tone='brand']) { --impakt-solid-card: ${t.surfaceCard}; --impakt-solid-text: ${t.text}; --impakt-solid-heading: var(--impakt-color-text-heading, ${t.text}); --impakt-solid-muted: ${t.textMuted}; }
|
|
178
178
|
.band { box-sizing: border-box; border-radius: ${t.radiusLg}; }
|
|
179
179
|
/* --impakt-bleed is 0 while editing, so a full-width block stays inside the box it is being edited in. */
|
|
180
|
-
:host([bleed]) .band { border-radius: 0; margin-inline: calc(var(--impakt-bleed, 1) * (50% - 50vw)); padding-inline: max(${
|
|
180
|
+
:host([bleed]) .band { border-radius: 0; margin-inline: calc(var(--impakt-bleed, 1) * (50% - 50vw)); padding-inline: max(${token("section.gutter", "16px")}, calc(var(--impakt-bleed, 1) * (50vw - 50%))); }
|
|
181
181
|
:host([tone='subtle']) .band { background: ${t.surfaceSubtle}; }
|
|
182
182
|
:host([tone='inset']) .band { background: ${t.surfaceInset}; }
|
|
183
183
|
:host([tone='card']) .band { background: ${t.surfaceCard}; }
|
|
@@ -221,7 +221,7 @@ var ImpaktSection = class extends ImpaktElement {
|
|
|
221
221
|
:host([padding='md']) .band { padding-block: ${space(8)}; }
|
|
222
222
|
:host([padding='lg']) .band { padding-block: ${space(12)}; }
|
|
223
223
|
:host([padding='xl']) .band { padding-block: ${space(16)}; }
|
|
224
|
-
:host([padding='2xl']) .band { padding-block:
|
|
224
|
+
:host([padding='2xl']) .band { padding-block: ${token("section.padding-2xl", "clamp(56px, 8vw, 112px)")}; }
|
|
225
225
|
:host([padding='3xl']) .band { padding-block: clamp(${space(16)}, 10vw, ${space(30)}); }
|
|
226
226
|
.content { max-inline-size: var(--impakt-page-inner); margin-inline: auto; }
|
|
227
227
|
`
|
|
@@ -238,4 +238,4 @@ export {
|
|
|
238
238
|
ImpaktPage,
|
|
239
239
|
ImpaktSection
|
|
240
240
|
};
|
|
241
|
-
//# sourceMappingURL=chunk-
|
|
241
|
+
//# sourceMappingURL=chunk-QJBRENLI.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/page.ts"],"sourcesContent":["import { css, html, nothing, type TemplateResult } from 'lit';\nimport { onServer } from '../base/server';\nimport { ImpaktElement } from '../base/ImpaktElement';\nimport { focusRing } from '../base/styles';\nimport { space, spaceAround, t, token } from '../base/tokens';\n\n/** The widest a line of content runs, for each choice of `width`. */\nconst widths = css`\n :host { --impakt-page-inner: ${token('layout.page-width', '1200px')}; }\n :host([width='narrow']) { --impakt-page-inner: 760px; }\n :host([width='wide']) { --impakt-page-inner: 1440px; }\n :host([width='content']) { --impakt-page-inner: 1080px; }\n`;\n\n/**\n * The side margins, from the brand's layout: narrow on a phone, wider on a\n * tablet and a desktop. Measured against the page itself, so a page drawn in a\n * narrow preview gets phone margins whatever the window is.\n */\nconst margins = css`\n :host { --impakt-page-margin: ${token('layout.margin.phone', '16px')}; }\n @container impakt-page (min-width: 40rem) { .frame { --impakt-page-margin: ${token('layout.margin.tablet', '32px')}; } }\n @container impakt-page (min-width: 64rem) { .frame { --impakt-page-margin: ${token('layout.margin.desktop', '64px')}; } }\n`;\n\n/**\n * The frame every page sits in: a header, the page's own content, and a\n * footer, each kept to the brand's page width with the brand's side margins.\n *\n * A layout puts this at its root, with the site's header and footer in their\n * slots and the page content in the middle, so an app draws the same frame the\n * CMS shows. Without it, a page runs edge to edge.\n *\n * **It gives the page its landmarks.** The header, main content and footer are\n * `header`, `main` and `footer` elements, so a screen reader can jump between\n * them (1.3.1), and the first thing in the page is a \"Skip to content\" link\n * that appears when it has focus (2.4.1).\n *\n * @category layout\n * @icon layout\n * @slot header - The site's header: its logo, navigation and a call to action.\n * @slot - The page's own content.\n * @slot footer - The site's footer.\n */\nexport class ImpaktPage extends ImpaktElement {\n static properties = {\n width: { type: String, reflect: true },\n stickyHeader: { type: Boolean, reflect: true, attribute: 'sticky-header' },\n skipText: { type: String, attribute: 'skip-text' },\n noHeader: { type: Boolean, reflect: true, attribute: 'no-header' },\n noFooter: { type: Boolean, reflect: true, attribute: 'no-footer' },\n };\n /** How wide the content runs. Standard is the brand's page width; `content` is G2's 1080px column. */\n declare width: 'narrow' | 'standard' | 'content' | 'wide';\n /** Keep the header at the top of the screen while the page scrolls. */\n declare stickyHeader: boolean;\n /** The words of the link that skips past the header to the content. */\n declare skipText: string;\n /**\n * Leave the header landmark out. In a browser the page sees for itself whether a header was\n * given, so this is only for a page drawn on the server, where it cannot.\n */\n declare noHeader: boolean;\n /** Leave the footer landmark out, for a page drawn on the server with no footer. */\n declare noFooter: boolean;\n\n constructor() {\n super();\n this.width = 'standard';\n this.stickyHeader = false;\n this.skipText = 'Skip to content';\n this.noHeader = false;\n this.noFooter = false;\n }\n\n static styles = [\n ...ImpaktElement.styles,\n focusRing,\n widths,\n margins,\n css`\n :host { display: block; container: impakt-page / inline-size; }\n .frame { position: relative; display: flex; flex-direction: column; min-block-size: 100%; overflow-x: clip; }\n .inner { box-sizing: border-box; inline-size: 100%; max-inline-size: calc(var(--impakt-page-inner) + 2 * var(--impakt-page-margin)); margin-inline: auto; padding-inline: var(--impakt-page-margin); }\n header { background: ${token('color.surface.header', 'transparent')}; color: ${token('color.text.on-header', 'inherit')}; padding-block: ${space(4)}; }\n /* What sits in the header and footer takes their text colour, so words on a dark footer stay readable. */\n header { --impakt-color-text-default: ${token('color.text.on-header', 'inherit')}; --impakt-color-text-heading: ${token('color.text.on-header', 'inherit')}; --impakt-color-text-link: ${token('color.text.on-header', 'inherit')}; --impakt-color-text-link-hover: ${token('color.text.on-header', 'inherit')}; }\n footer { --impakt-color-text-default: ${token('color.text.on-footer', 'inherit')}; --impakt-color-text-heading: ${token('color.text.on-footer', 'inherit')}; --impakt-color-text-muted: ${token('color.text.on-footer', 'inherit')}; --impakt-color-text-link: ${token('color.text.on-footer', 'inherit')}; --impakt-color-text-link-hover: ${token('color.text.on-footer', 'inherit')}; }\n :host([sticky-header]) header { position: sticky; inset-block-start: 0; z-index: 10; }\n main { flex: 1; padding-block: ${space(6)} ${space(10)}; }\n main:focus { outline: none; }\n /* A page that opens on a full-picture hero: the header floats over it as a rounded bar. */\n :host([floating]) header { position: absolute; z-index: 20; inset-inline: 0; inset-block-start: var(--impakt-header-top, 0px); padding-block: ${space(6)} 0; background: transparent; border: 0; }\n :host([floating]) header .inner { inline-size: calc(100% - 2 * var(--impakt-page-margin)); max-inline-size: var(--impakt-page-inner); padding: ${space(3)} ${space(4)} ${space(3)} ${space(6)}; background: ${token('color.surface.header', '#fff')}; border-radius: ${t.radius2xl}; box-shadow: ${t.shadowLg}; }\n :host([floating]) main { padding-block-start: 0; }\n footer { background: ${token('color.surface.footer', 'transparent')}; color: ${token('color.text.on-footer', 'inherit')}; padding-block: ${space(8)}; border-block-start: ${t.borderThin} solid ${token('color.border.subtle', 'transparent')}; }\n .skip { position: absolute; inset-inline-start: ${space(2)}; inset-block-start: ${space(2)}; z-index: 20; padding: ${space(2)} ${space(4)}; background: ${t.surfaceCard}; color: ${t.link}; border-radius: ${t.radius}; transform: translateY(-200%); }\n .skip:not(:focus) { clip-path: inset(50%); }\n .skip:focus { transform: none; }\n .empty { display: none; }\n `,\n ];\n\n /**\n * Whether something was given for a slot. An element drawn on the server cannot see its own\n * children, so there the landmark is drawn unless `no-header` or `no-footer` says to leave it out.\n */\n private hasSlot(name: 'header' | 'footer'): boolean {\n if (name === 'header' ? this.noHeader : this.noFooter) return false;\n if (onServer) return true;\n return Array.from(this.children).some((c) => c.getAttribute('slot') === name);\n }\n\n private skip(event: Event): void {\n event.preventDefault();\n const main = this.renderRoot.querySelector('main');\n main?.focus();\n main?.scrollIntoView();\n }\n\n render(): TemplateResult {\n // The header and footer are left out when nothing is in them, so a page\n // with no site header has no empty landmark for a screen reader to land on.\n const header = this.hasSlot('header');\n const footer = this.hasSlot('footer');\n return html`<div class=\"frame\" part=\"frame\">\n <a class=\"skip\" href=\"#content\" part=\"skip\" @click=${this.skip}>${this.skipText}</a>\n ${header ? html`<header part=\"header\"><div class=\"inner\"><slot name=\"header\"></slot></div></header>` : nothing}\n <main id=\"content\" tabindex=\"-1\" part=\"main\"><div class=\"inner\"><slot></slot></div></main>\n ${footer ? html`<footer part=\"footer\"><div class=\"inner\"><slot name=\"footer\"></slot></div></footer>` : nothing}\n </div>`;\n }\n\n /**\n * The header floats when the page opens on a full-picture hero, sitting on the\n * picture itself, so nothing has to be set for it. It stays an ordinary bar\n * while editing, where the blocks are kept inside the page's box.\n */\n private place = (): void => {\n const hero = this.querySelector('impakt-hero[treatment=\"cover\"]');\n const editing = getComputedStyle(this).getPropertyValue('--impakt-bleed').trim() === '0';\n const floats = !!hero && !editing && this.opensOn(hero);\n this.toggleAttribute('floating', floats);\n if (!floats) return;\n const frame = this.renderRoot.querySelector('.frame');\n if (frame) this.style.setProperty('--impakt-header-top', `${Math.round(hero!.getBoundingClientRect().top - frame.getBoundingClientRect().top)}px`);\n };\n\n /** Whether nothing a reader would notice comes before this block, other than an announcement. */\n private opensOn(hero: Element): boolean {\n for (const element of Array.from(this.querySelectorAll('*'))) {\n if (element === hero) return true;\n if (element.closest('[slot=\"header\"],[slot=\"footer\"]')) continue;\n if (element.tagName.startsWith('IMPAKT-') && !/^IMPAKT-(STACK|SECTION|GRID|ANNOUNCEMENT)$/.test(element.tagName)) return false;\n }\n return false;\n }\n\n // A header or footer added after the first render still gets its landmark.\n connectedCallback(): void {\n super.connectedCallback();\n this.observer = new MutationObserver(() => this.requestUpdate());\n this.observer.observe(this, { childList: true, attributes: true, subtree: false, attributeFilter: ['slot'] });\n this.watcher = new MutationObserver(this.place);\n this.watcher.observe(this, { childList: true, subtree: true, attributes: true, attributeFilter: ['treatment'] });\n if (typeof ResizeObserver === 'function') {\n this.resize = new ResizeObserver(this.place);\n this.resize.observe(this);\n }\n }\n\n disconnectedCallback(): void {\n super.disconnectedCallback();\n this.observer?.disconnect();\n this.watcher?.disconnect();\n this.resize?.disconnect();\n }\n\n protected firstUpdated(): void {\n this.place();\n }\n\n private observer?: MutationObserver;\n private watcher?: MutationObserver;\n private resize?: ResizeObserver;\n}\n\n/**\n * A band across the whole width of the page, with its own background, and its\n * content kept to the page width inside it: a coloured strip of features, a\n * quote on a tinted background, a call to action at the foot of a page.\n *\n * Inside a Page it reaches the edges of the screen whatever the page width is,\n * so a page can alternate bands without any of them knowing the frame. Set\n * `bleed` off to keep the band to the page width, as a panel.\n *\n * @category layout\n * @icon section\n * @slot - The section's content.\n */\nexport class ImpaktSection extends ImpaktElement {\n static properties = {\n tone: { type: String, reflect: true },\n padding: { type: String, reflect: true },\n width: { type: String, reflect: true },\n bleed: { type: Boolean, reflect: true },\n pattern: { type: String, reflect: true },\n label: { type: String },\n spaceAbove: { type: String, reflect: true, attribute: 'space-above' },\n spaceBelow: { type: String, reflect: true, attribute: 'space-below' },\n };\n /**\n * The band's background. Text on it takes the matching colour, so it stays\n * readable. `board` is G2's blueprint grey (#E3E2DD). On `ink` the cards are\n * the raised ink (#1C1C1C) with a #2E2E2E rule, a primary button is the paper\n * with ink words and an outline button has a paper border.\n */\n declare tone: 'none' | 'subtle' | 'inset' | 'brand' | 'card' | 'ink' | 'accent' | 'board';\n /** Space inside the band, above and below its content. `3xl` is G2's 120px on a desktop and 64px on a phone. */\n declare padding: 'none' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | '3xl';\n /** How wide the content inside runs. `content` is G2's 1080px column. */\n declare width: 'narrow' | 'standard' | 'content' | 'wide';\n /** Run the background to the edges of the screen. */\n declare bleed: boolean;\n /**\n * Fine lines drawn across the band: a square grid, a closer blueprint grid,\n * upright columns or ruled lines. They are decoration, drawn in the band's\n * own text colour at a tenth of its strength, and are left out in a forced\n * colours mode.\n */\n declare pattern: 'none' | 'grid' | 'blueprint' | 'columns' | 'ruled';\n /** A name for the section, so a screen reader can find it in the page's regions. Leave empty for none. */\n declare label: string;\n declare spaceAbove: 'none' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';\n declare spaceBelow: 'none' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';\n\n constructor() {\n super();\n this.tone = 'none';\n this.padding = 'lg';\n this.width = 'standard';\n this.bleed = true;\n this.pattern = 'none';\n this.label = '';\n this.spaceAbove = 'none';\n this.spaceBelow = 'none';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n spaceAround,\n widths,\n css`\n :host { display: block; --impakt-page-margin: inherit; }\n /* What a solid card on a brand band goes back to, since the band repaints these for its own text. */\n :host([tone='brand']) { --impakt-solid-card: ${t.surfaceCard}; --impakt-solid-text: ${t.text}; --impakt-solid-heading: var(--impakt-color-text-heading, ${t.text}); --impakt-solid-muted: ${t.textMuted}; }\n .band { box-sizing: border-box; border-radius: ${t.radiusLg}; }\n /* --impakt-bleed is 0 while editing, so a full-width block stays inside the box it is being edited in. */\n :host([bleed]) .band { border-radius: 0; margin-inline: calc(var(--impakt-bleed, 1) * (50% - 50vw)); padding-inline: max(${space(4)}, calc(var(--impakt-bleed, 1) * (50vw - 50%))); }\n :host([tone='subtle']) .band { background: ${t.surfaceSubtle}; }\n :host([tone='inset']) .band { background: ${t.surfaceInset}; }\n :host([tone='card']) .band { background: ${t.surfaceCard}; }\n :host([tone='board']) .band { background: var(--impakt-color-surface-board, var(--ik-surface-board, #e3e2dd)); }\n /*\n * A toned band sets what a button and a solid mark on it need, and resets what\n * an outer band set, so a band inside another one, or a banner inside a band,\n * never draws with colours meant for the band round it. --impakt-color-text-inverse\n * is the colour that reads on the band's text colour: a dark button's words.\n */\n :host(:not([tone='none'])) .band { --impakt-button-primary: initial; --impakt-button-on-primary: initial; --impakt-button-primary-hover: initial; --impakt-color-text-inverse: initial; }\n :host([tone='brand']) .band { --impakt-color-text-inverse: ${t.brand}; }\n :host([tone='accent']) .band { --impakt-color-text-inverse: var(--impakt-solid-card); }\n :host([tone='brand']) .band { background: ${t.brand}; color: ${t.onBrand}; --impakt-eyebrow: ${t.onBrand}; --impakt-color-surface-card: color-mix(in srgb, ${t.onBrand} 10%, transparent); --impakt-color-text-heading: ${t.onBrand}; --impakt-color-text-default: ${t.onBrand}; --impakt-color-text-muted: ${t.onBrand}; --impakt-color-text-link: ${t.onBrand}; --impakt-color-text-link-hover: ${t.onBrand}; }\n /* Ink and accent bands take their colours from the host, because the band repaints the text colour for what is inside it. */\n :host([tone='ink']) { --impakt-band: ${t.text}; --impakt-band-on: ${t.surfaceCard}; --impakt-band-muted: color-mix(in srgb, ${t.surfaceCard} 78%, ${t.text}); --impakt-solid-card: ${t.surfaceCard}; --impakt-solid-text: ${t.text}; --impakt-solid-heading: var(--impakt-color-text-heading, ${t.text}); --impakt-solid-muted: ${t.textMuted}; }\n :host([tone='accent']) { --impakt-band: ${token('color.accent.default', '#ffd43b')}; --impakt-band-on: ${token('color.accent.on', '#1a1a1a')}; --impakt-band-muted: ${token('color.accent.on', '#1a1a1a')}; --impakt-solid-card: ${t.surfaceCard}; --impakt-solid-text: ${t.text}; --impakt-solid-heading: var(--impakt-color-text-heading, ${t.text}); --impakt-solid-muted: ${t.textMuted}; }\n :host(:is([tone='ink'], [tone='accent'])) .band { background-color: var(--impakt-band); color: var(--impakt-band-on); --impakt-eyebrow: var(--impakt-band-muted); --impakt-color-surface-card: color-mix(in srgb, var(--impakt-band-on) 10%, transparent); --impakt-color-text-heading: var(--impakt-band-on); --impakt-color-text-default: var(--impakt-band-on); --impakt-color-text-muted: var(--impakt-band-muted); --impakt-color-text-link: var(--impakt-band-on); --impakt-color-text-link-hover: var(--impakt-band-on); }\n /* On ink the cards are the raised ink with a darker rule (G2 ink-raised and line-inverse), not a wash. */\n :host([tone='ink']) .band {\n --impakt-color-text-inverse: var(--impakt-band);\n --impakt-button-primary: var(--impakt-band-on);\n --impakt-button-on-primary: var(--impakt-band);\n --impakt-button-primary-hover: color-mix(in srgb, var(--impakt-band-on) 86%, var(--impakt-band));\n /* Mixed from the band, so it is #1C1C1C on light ink and still a step off the band when dark turns the band over. */\n --impakt-color-surface-card: color-mix(in srgb, var(--impakt-band) 95%, var(--impakt-band-on));\n --impakt-color-line-soft: color-mix(in srgb, var(--impakt-band) 87%, var(--impakt-band-on));\n /* The accent reads on light-theme ink only; the theme leaves it unset in dark, where the band turns paper. */\n --impakt-site-menu-current: var(--impakt-color-accent-on-ink, currentColor);\n --impakt-steps-current: var(--impakt-color-accent-on-ink, currentColor);\n }\n /* The lines are a tenth of the band's own text colour, so they suit any tone. They carry no meaning. */\n :host([pattern]:not([pattern='none'])) .band { --impakt-pattern-line: color-mix(in srgb, currentColor 10%, transparent); }\n :host(:is([pattern='grid'], [pattern='blueprint'])) .band { background-image: linear-gradient(to right, var(--impakt-pattern-line) 1px, transparent 1px), linear-gradient(to bottom, var(--impakt-pattern-line) 1px, transparent 1px); background-size: 7rem 7rem; }\n :host([pattern='blueprint']) .band { background-size: 1.75rem 1.75rem; }\n :host([pattern='columns']) .band { background-image: linear-gradient(to right, var(--impakt-pattern-line) 1px, transparent 1px); background-size: 5.625rem 100%; }\n :host([pattern='ruled']) .band { background-image: linear-gradient(to bottom, var(--impakt-pattern-line) 1px, transparent 1px); background-size: 100% 2.5rem; }\n @media (forced-colors: active) { .band { background-image: none !important; } }\n :host(:not([bleed]):not([tone='none'])) .band { padding-inline: ${space(6)}; }\n :host([padding='sm']) .band { padding-block: ${space(4)}; }\n :host([padding='md']) .band { padding-block: ${space(8)}; }\n :host([padding='lg']) .band { padding-block: ${space(12)}; }\n :host([padding='xl']) .band { padding-block: ${space(16)}; }\n :host([padding='2xl']) .band { padding-block: clamp(${space(14)}, 8vw, ${space(28)}); }\n :host([padding='3xl']) .band { padding-block: clamp(${space(16)}, 10vw, ${space(30)}); }\n .content { max-inline-size: var(--impakt-page-inner); margin-inline: auto; }\n `,\n ];\n\n render(): TemplateResult {\n return html`<section class=\"band\" part=\"band\" aria-label=${this.label || nothing} role=${this.label ? nothing : 'presentation'}><div class=\"content\" part=\"content\"><slot></slot></div></section>`;\n }\n}\n\ncustomElements.define('impakt-page', ImpaktPage);\ncustomElements.define('impakt-section', ImpaktSection);\ndeclare global {\n interface HTMLElementTagNameMap {\n 'impakt-page': ImpaktPage;\n 'impakt-section': ImpaktSection;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;AAAA,SAAS,KAAK,MAAM,eAAoC;AAOxD,IAAM,SAAS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OAAO,eAAe,UAAU;AAC/C,eAAe,OAAO,kBAAkB,aAAa;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/components/page.ts"],"sourcesContent":["import { css, html, nothing, type TemplateResult } from 'lit';\nimport { onServer } from '../base/server';\nimport { ImpaktElement } from '../base/ImpaktElement';\nimport { focusRing } from '../base/styles';\nimport { space, spaceAround, t, token } from '../base/tokens';\n\n/** The widest a line of content runs, for each choice of `width`. */\nconst widths = css`\n :host { --impakt-page-inner: ${token('layout.page-width', '1200px')}; }\n :host([width='narrow']) { --impakt-page-inner: 760px; }\n :host([width='wide']) { --impakt-page-inner: 1440px; }\n :host([width='content']) { --impakt-page-inner: 1080px; }\n`;\n\n/**\n * The side margins, from the brand's layout: narrow on a phone, wider on a\n * tablet and a desktop. Measured against the page itself, so a page drawn in a\n * narrow preview gets phone margins whatever the window is.\n */\nconst margins = css`\n :host { --impakt-page-margin: ${token('layout.margin.phone', '16px')}; }\n @container impakt-page (min-width: 40rem) { .frame { --impakt-page-margin: ${token('layout.margin.tablet', '32px')}; } }\n @container impakt-page (min-width: 64rem) { .frame { --impakt-page-margin: ${token('layout.margin.desktop', '64px')}; } }\n`;\n\n/**\n * The frame every page sits in: a header, the page's own content, and a\n * footer, each kept to the brand's page width with the brand's side margins.\n *\n * A layout puts this at its root, with the site's header and footer in their\n * slots and the page content in the middle, so an app draws the same frame the\n * CMS shows. Without it, a page runs edge to edge.\n *\n * **It gives the page its landmarks.** The header, main content and footer are\n * `header`, `main` and `footer` elements, so a screen reader can jump between\n * them (1.3.1), and the first thing in the page is a \"Skip to content\" link\n * that appears when it has focus (2.4.1).\n *\n * @category layout\n * @icon layout\n * @slot header - The site's header: its logo, navigation and a call to action.\n * @slot - The page's own content.\n * @slot footer - The site's footer.\n */\nexport class ImpaktPage extends ImpaktElement {\n static properties = {\n width: { type: String, reflect: true },\n stickyHeader: { type: Boolean, reflect: true, attribute: 'sticky-header' },\n skipText: { type: String, attribute: 'skip-text' },\n noHeader: { type: Boolean, reflect: true, attribute: 'no-header' },\n noFooter: { type: Boolean, reflect: true, attribute: 'no-footer' },\n };\n /** How wide the content runs. Standard is the brand's page width; `content` is G2's 1080px column. */\n declare width: 'narrow' | 'standard' | 'content' | 'wide';\n /** Keep the header at the top of the screen while the page scrolls. */\n declare stickyHeader: boolean;\n /** The words of the link that skips past the header to the content. */\n declare skipText: string;\n /**\n * Leave the header landmark out. In a browser the page sees for itself whether a header was\n * given, so this is only for a page drawn on the server, where it cannot.\n */\n declare noHeader: boolean;\n /** Leave the footer landmark out, for a page drawn on the server with no footer. */\n declare noFooter: boolean;\n\n constructor() {\n super();\n this.width = 'standard';\n this.stickyHeader = false;\n this.skipText = 'Skip to content';\n this.noHeader = false;\n this.noFooter = false;\n }\n\n static styles = [\n ...ImpaktElement.styles,\n focusRing,\n widths,\n margins,\n css`\n :host { display: block; container: impakt-page / inline-size; }\n .frame { position: relative; display: flex; flex-direction: column; min-block-size: 100%; overflow-x: clip; }\n .inner { box-sizing: border-box; inline-size: 100%; max-inline-size: calc(var(--impakt-page-inner) + 2 * var(--impakt-page-margin)); margin-inline: auto; padding-inline: var(--impakt-page-margin); }\n header { background: ${token('color.surface.header', 'transparent')}; color: ${token('color.text.on-header', 'inherit')}; padding-block: ${space(4)}; }\n /* What sits in the header and footer takes their text colour, so words on a dark footer stay readable. */\n header { --impakt-color-text-default: ${token('color.text.on-header', 'inherit')}; --impakt-color-text-heading: ${token('color.text.on-header', 'inherit')}; --impakt-color-text-link: ${token('color.text.on-header', 'inherit')}; --impakt-color-text-link-hover: ${token('color.text.on-header', 'inherit')}; }\n footer { --impakt-color-text-default: ${token('color.text.on-footer', 'inherit')}; --impakt-color-text-heading: ${token('color.text.on-footer', 'inherit')}; --impakt-color-text-muted: ${token('color.text.on-footer', 'inherit')}; --impakt-color-text-link: ${token('color.text.on-footer', 'inherit')}; --impakt-color-text-link-hover: ${token('color.text.on-footer', 'inherit')}; }\n :host([sticky-header]) header { position: sticky; inset-block-start: 0; z-index: 10; }\n main { flex: 1; padding-block: ${space(6)} ${space(10)}; }\n main:focus { outline: none; }\n /* A page that opens on a full-picture hero: the header floats over it as a rounded bar. */\n :host([floating]) header { position: absolute; z-index: 20; inset-inline: 0; inset-block-start: var(--impakt-header-top, 0px); padding-block: ${space(6)} 0; background: transparent; border: 0; }\n :host([floating]) header .inner { inline-size: calc(100% - 2 * var(--impakt-page-margin)); max-inline-size: var(--impakt-page-inner); padding: ${space(3)} ${space(4)} ${space(3)} ${space(6)}; background: ${token('color.surface.header', '#fff')}; border-radius: ${t.radius2xl}; box-shadow: ${t.shadowLg}; }\n :host([floating]) main { padding-block-start: 0; }\n footer { background: ${token('color.surface.footer', 'transparent')}; color: ${token('color.text.on-footer', 'inherit')}; padding-block: ${space(8)}; border-block-start: ${t.borderThin} solid ${token('color.border.subtle', 'transparent')}; }\n .skip { position: absolute; inset-inline-start: ${space(2)}; inset-block-start: ${space(2)}; z-index: 20; padding: ${space(2)} ${space(4)}; background: ${t.surfaceCard}; color: ${t.link}; border-radius: ${t.radius}; transform: translateY(-200%); }\n .skip:not(:focus) { clip-path: inset(50%); }\n .skip:focus { transform: none; }\n .empty { display: none; }\n `,\n ];\n\n /**\n * Whether something was given for a slot. An element drawn on the server cannot see its own\n * children, so there the landmark is drawn unless `no-header` or `no-footer` says to leave it out.\n */\n private hasSlot(name: 'header' | 'footer'): boolean {\n if (name === 'header' ? this.noHeader : this.noFooter) return false;\n if (onServer) return true;\n return Array.from(this.children).some((c) => c.getAttribute('slot') === name);\n }\n\n private skip(event: Event): void {\n event.preventDefault();\n const main = this.renderRoot.querySelector('main');\n main?.focus();\n main?.scrollIntoView();\n }\n\n render(): TemplateResult {\n // The header and footer are left out when nothing is in them, so a page\n // with no site header has no empty landmark for a screen reader to land on.\n const header = this.hasSlot('header');\n const footer = this.hasSlot('footer');\n return html`<div class=\"frame\" part=\"frame\">\n <a class=\"skip\" href=\"#content\" part=\"skip\" @click=${this.skip}>${this.skipText}</a>\n ${header ? html`<header part=\"header\"><div class=\"inner\"><slot name=\"header\"></slot></div></header>` : nothing}\n <main id=\"content\" tabindex=\"-1\" part=\"main\"><div class=\"inner\"><slot></slot></div></main>\n ${footer ? html`<footer part=\"footer\"><div class=\"inner\"><slot name=\"footer\"></slot></div></footer>` : nothing}\n </div>`;\n }\n\n /**\n * The header floats when the page opens on a full-picture hero, sitting on the\n * picture itself, so nothing has to be set for it. It stays an ordinary bar\n * while editing, where the blocks are kept inside the page's box.\n */\n private place = (): void => {\n const hero = this.querySelector('impakt-hero[treatment=\"cover\"]');\n const editing = getComputedStyle(this).getPropertyValue('--impakt-bleed').trim() === '0';\n const floats = !!hero && !editing && this.opensOn(hero);\n this.toggleAttribute('floating', floats);\n if (!floats) return;\n const frame = this.renderRoot.querySelector('.frame');\n if (frame) this.style.setProperty('--impakt-header-top', `${Math.round(hero!.getBoundingClientRect().top - frame.getBoundingClientRect().top)}px`);\n };\n\n /** Whether nothing a reader would notice comes before this block, other than an announcement. */\n private opensOn(hero: Element): boolean {\n for (const element of Array.from(this.querySelectorAll('*'))) {\n if (element === hero) return true;\n if (element.closest('[slot=\"header\"],[slot=\"footer\"]')) continue;\n if (element.tagName.startsWith('IMPAKT-') && !/^IMPAKT-(STACK|SECTION|GRID|ANNOUNCEMENT)$/.test(element.tagName)) return false;\n }\n return false;\n }\n\n // A header or footer added after the first render still gets its landmark.\n connectedCallback(): void {\n super.connectedCallback();\n this.observer = new MutationObserver(() => this.requestUpdate());\n this.observer.observe(this, { childList: true, attributes: true, subtree: false, attributeFilter: ['slot'] });\n this.watcher = new MutationObserver(this.place);\n this.watcher.observe(this, { childList: true, subtree: true, attributes: true, attributeFilter: ['treatment'] });\n if (typeof ResizeObserver === 'function') {\n this.resize = new ResizeObserver(this.place);\n this.resize.observe(this);\n }\n }\n\n disconnectedCallback(): void {\n super.disconnectedCallback();\n this.observer?.disconnect();\n this.watcher?.disconnect();\n this.resize?.disconnect();\n }\n\n protected firstUpdated(): void {\n this.place();\n }\n\n private observer?: MutationObserver;\n private watcher?: MutationObserver;\n private resize?: ResizeObserver;\n}\n\n/**\n * A band across the whole width of the page, with its own background, and its\n * content kept to the page width inside it: a coloured strip of features, a\n * quote on a tinted background, a call to action at the foot of a page.\n *\n * Inside a Page it reaches the edges of the screen whatever the page width is,\n * so a page can alternate bands without any of them knowing the frame. Set\n * `bleed` off to keep the band to the page width, as a panel.\n *\n * @category layout\n * @icon section\n * @slot - The section's content.\n */\nexport class ImpaktSection extends ImpaktElement {\n static properties = {\n tone: { type: String, reflect: true },\n padding: { type: String, reflect: true },\n width: { type: String, reflect: true },\n bleed: { type: Boolean, reflect: true },\n pattern: { type: String, reflect: true },\n label: { type: String },\n spaceAbove: { type: String, reflect: true, attribute: 'space-above' },\n spaceBelow: { type: String, reflect: true, attribute: 'space-below' },\n };\n /**\n * The band's background. Text on it takes the matching colour, so it stays\n * readable. `board` is G2's blueprint grey (#E3E2DD). On `ink` the cards are\n * the raised ink (#1C1C1C) with a #2E2E2E rule, a primary button is the paper\n * with ink words and an outline button has a paper border.\n */\n declare tone: 'none' | 'subtle' | 'inset' | 'brand' | 'card' | 'ink' | 'accent' | 'board';\n /** Space inside the band, above and below its content. `3xl` is G2's 120px on a desktop and 64px on a phone. */\n declare padding: 'none' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | '3xl';\n /** How wide the content inside runs. `content` is G2's 1080px column. */\n declare width: 'narrow' | 'standard' | 'content' | 'wide';\n /** Run the background to the edges of the screen. */\n declare bleed: boolean;\n /**\n * Fine lines drawn across the band: a square grid, a closer blueprint grid,\n * upright columns or ruled lines. They are decoration, drawn in the band's\n * own text colour at a tenth of its strength, and are left out in a forced\n * colours mode.\n */\n declare pattern: 'none' | 'grid' | 'blueprint' | 'columns' | 'ruled';\n /** A name for the section, so a screen reader can find it in the page's regions. Leave empty for none. */\n declare label: string;\n declare spaceAbove: 'none' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';\n declare spaceBelow: 'none' | 'sm' | 'md' | 'lg' | 'xl' | '2xl';\n\n constructor() {\n super();\n this.tone = 'none';\n this.padding = 'lg';\n this.width = 'standard';\n this.bleed = true;\n this.pattern = 'none';\n this.label = '';\n this.spaceAbove = 'none';\n this.spaceBelow = 'none';\n }\n\n static styles = [\n ...ImpaktElement.styles,\n spaceAround,\n widths,\n css`\n :host { display: block; --impakt-page-margin: inherit; }\n /* What a solid card on a brand band goes back to, since the band repaints these for its own text. */\n :host([tone='brand']) { --impakt-solid-card: ${t.surfaceCard}; --impakt-solid-text: ${t.text}; --impakt-solid-heading: var(--impakt-color-text-heading, ${t.text}); --impakt-solid-muted: ${t.textMuted}; }\n .band { box-sizing: border-box; border-radius: ${t.radiusLg}; }\n /* --impakt-bleed is 0 while editing, so a full-width block stays inside the box it is being edited in. */\n :host([bleed]) .band { border-radius: 0; margin-inline: calc(var(--impakt-bleed, 1) * (50% - 50vw)); padding-inline: max(${token('section.gutter', '16px')}, calc(var(--impakt-bleed, 1) * (50vw - 50%))); }\n :host([tone='subtle']) .band { background: ${t.surfaceSubtle}; }\n :host([tone='inset']) .band { background: ${t.surfaceInset}; }\n :host([tone='card']) .band { background: ${t.surfaceCard}; }\n :host([tone='board']) .band { background: var(--impakt-color-surface-board, var(--ik-surface-board, #e3e2dd)); }\n /*\n * A toned band sets what a button and a solid mark on it need, and resets what\n * an outer band set, so a band inside another one, or a banner inside a band,\n * never draws with colours meant for the band round it. --impakt-color-text-inverse\n * is the colour that reads on the band's text colour: a dark button's words.\n */\n :host(:not([tone='none'])) .band { --impakt-button-primary: initial; --impakt-button-on-primary: initial; --impakt-button-primary-hover: initial; --impakt-color-text-inverse: initial; }\n :host([tone='brand']) .band { --impakt-color-text-inverse: ${t.brand}; }\n :host([tone='accent']) .band { --impakt-color-text-inverse: var(--impakt-solid-card); }\n :host([tone='brand']) .band { background: ${t.brand}; color: ${t.onBrand}; --impakt-eyebrow: ${t.onBrand}; --impakt-color-surface-card: color-mix(in srgb, ${t.onBrand} 10%, transparent); --impakt-color-text-heading: ${t.onBrand}; --impakt-color-text-default: ${t.onBrand}; --impakt-color-text-muted: ${t.onBrand}; --impakt-color-text-link: ${t.onBrand}; --impakt-color-text-link-hover: ${t.onBrand}; }\n /* Ink and accent bands take their colours from the host, because the band repaints the text colour for what is inside it. */\n :host([tone='ink']) { --impakt-band: ${t.text}; --impakt-band-on: ${t.surfaceCard}; --impakt-band-muted: color-mix(in srgb, ${t.surfaceCard} 78%, ${t.text}); --impakt-solid-card: ${t.surfaceCard}; --impakt-solid-text: ${t.text}; --impakt-solid-heading: var(--impakt-color-text-heading, ${t.text}); --impakt-solid-muted: ${t.textMuted}; }\n :host([tone='accent']) { --impakt-band: ${token('color.accent.default', '#ffd43b')}; --impakt-band-on: ${token('color.accent.on', '#1a1a1a')}; --impakt-band-muted: ${token('color.accent.on', '#1a1a1a')}; --impakt-solid-card: ${t.surfaceCard}; --impakt-solid-text: ${t.text}; --impakt-solid-heading: var(--impakt-color-text-heading, ${t.text}); --impakt-solid-muted: ${t.textMuted}; }\n :host(:is([tone='ink'], [tone='accent'])) .band { background-color: var(--impakt-band); color: var(--impakt-band-on); --impakt-eyebrow: var(--impakt-band-muted); --impakt-color-surface-card: color-mix(in srgb, var(--impakt-band-on) 10%, transparent); --impakt-color-text-heading: var(--impakt-band-on); --impakt-color-text-default: var(--impakt-band-on); --impakt-color-text-muted: var(--impakt-band-muted); --impakt-color-text-link: var(--impakt-band-on); --impakt-color-text-link-hover: var(--impakt-band-on); }\n /* On ink the cards are the raised ink with a darker rule (G2 ink-raised and line-inverse), not a wash. */\n :host([tone='ink']) .band {\n --impakt-color-text-inverse: var(--impakt-band);\n --impakt-button-primary: var(--impakt-band-on);\n --impakt-button-on-primary: var(--impakt-band);\n --impakt-button-primary-hover: color-mix(in srgb, var(--impakt-band-on) 86%, var(--impakt-band));\n /* Mixed from the band, so it is #1C1C1C on light ink and still a step off the band when dark turns the band over. */\n --impakt-color-surface-card: color-mix(in srgb, var(--impakt-band) 95%, var(--impakt-band-on));\n --impakt-color-line-soft: color-mix(in srgb, var(--impakt-band) 87%, var(--impakt-band-on));\n /* The accent reads on light-theme ink only; the theme leaves it unset in dark, where the band turns paper. */\n --impakt-site-menu-current: var(--impakt-color-accent-on-ink, currentColor);\n --impakt-steps-current: var(--impakt-color-accent-on-ink, currentColor);\n }\n /* The lines are a tenth of the band's own text colour, so they suit any tone. They carry no meaning. */\n :host([pattern]:not([pattern='none'])) .band { --impakt-pattern-line: color-mix(in srgb, currentColor 10%, transparent); }\n :host(:is([pattern='grid'], [pattern='blueprint'])) .band { background-image: linear-gradient(to right, var(--impakt-pattern-line) 1px, transparent 1px), linear-gradient(to bottom, var(--impakt-pattern-line) 1px, transparent 1px); background-size: 7rem 7rem; }\n :host([pattern='blueprint']) .band { background-size: 1.75rem 1.75rem; }\n :host([pattern='columns']) .band { background-image: linear-gradient(to right, var(--impakt-pattern-line) 1px, transparent 1px); background-size: 5.625rem 100%; }\n :host([pattern='ruled']) .band { background-image: linear-gradient(to bottom, var(--impakt-pattern-line) 1px, transparent 1px); background-size: 100% 2.5rem; }\n @media (forced-colors: active) { .band { background-image: none !important; } }\n :host(:not([bleed]):not([tone='none'])) .band { padding-inline: ${space(6)}; }\n :host([padding='sm']) .band { padding-block: ${space(4)}; }\n :host([padding='md']) .band { padding-block: ${space(8)}; }\n :host([padding='lg']) .band { padding-block: ${space(12)}; }\n :host([padding='xl']) .band { padding-block: ${space(16)}; }\n :host([padding='2xl']) .band { padding-block: ${token('section.padding-2xl', 'clamp(56px, 8vw, 112px)')}; }\n :host([padding='3xl']) .band { padding-block: clamp(${space(16)}, 10vw, ${space(30)}); }\n .content { max-inline-size: var(--impakt-page-inner); margin-inline: auto; }\n `,\n ];\n\n render(): TemplateResult {\n return html`<section class=\"band\" part=\"band\" aria-label=${this.label || nothing} role=${this.label ? nothing : 'presentation'}><div class=\"content\" part=\"content\"><slot></slot></div></section>`;\n }\n}\n\ncustomElements.define('impakt-page', ImpaktPage);\ncustomElements.define('impakt-section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AM,EAAE,CAAC;AAAA;AAAA;AAAA,IAGrF;AAAA;AAAA,EAEA,SAAyB;AACvB,WAAO,oDAAoD,KAAK,SAAS,OAAO,SAAS,KAAK,QAAQ,UAAU,cAAc;AAAA,EAChI;AACF;AAEA,eAAe,OAAO,eAAe,UAAU;AAC/C,eAAe,OAAO,kBAAkB,aAAa;","names":[]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
FieldElement
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-PII4SJL5.js";
|
|
4
4
|
import {
|
|
5
5
|
targetSize,
|
|
6
6
|
touchTarget,
|
|
@@ -310,4 +310,4 @@ export {
|
|
|
310
310
|
ImpaktSwitch,
|
|
311
311
|
ImpaktSegmentedControl
|
|
312
312
|
};
|
|
313
|
-
//# sourceMappingURL=chunk-
|
|
313
|
+
//# sourceMappingURL=chunk-RNFGIXJ7.js.map
|