@repobit/dex-system-design 3.0.3 → 3.1.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.
Files changed (150) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/README.md +35 -0
  3. package/dist/src/components/agent-endpoints/agent-endpoints.d.ts +1 -0
  4. package/dist/src/components/agent-endpoints/agent-endpoints.js +12 -12
  5. package/dist/src/components/agent-endpoints/agent-endpoints.js.map +1 -1
  6. package/dist/src/components/anchor/anchor-nav.d.ts +2 -1
  7. package/dist/src/components/anchor/anchor-nav.js +10 -10
  8. package/dist/src/components/anchor/anchor-nav.js.map +1 -1
  9. package/dist/src/components/audience-card/audience-card.css.js +1 -1
  10. package/dist/src/components/audience-card/audience-card.css.js.map +1 -1
  11. package/dist/src/components/audience-card/audience-card.d.ts +1 -0
  12. package/dist/src/components/audience-card/audience-card.js +8 -8
  13. package/dist/src/components/audience-card/audience-card.js.map +1 -1
  14. package/dist/src/components/awards/awards-flex.d.ts +3 -2
  15. package/dist/src/components/awards/awards-flex.js +16 -16
  16. package/dist/src/components/awards/awards-flex.js.map +1 -1
  17. package/dist/src/components/awards/awards-spotlight.d.ts +2 -1
  18. package/dist/src/components/awards/awards-spotlight.js +8 -8
  19. package/dist/src/components/awards/awards-spotlight.js.map +1 -1
  20. package/dist/src/components/awards/awards.d.ts +1 -1
  21. package/dist/src/components/bento-grid/bento-grid.d.ts +1 -0
  22. package/dist/src/components/bento-grid/bento-grid.js +10 -10
  23. package/dist/src/components/bento-grid/bento-grid.js.map +1 -1
  24. package/dist/src/components/bento-grid/bento-item.css.js +1 -1
  25. package/dist/src/components/bento-grid/bento-item.css.js.map +1 -1
  26. package/dist/src/components/bento-grid/bento-item.d.ts +1 -0
  27. package/dist/src/components/bento-grid/bento-item.js +9 -9
  28. package/dist/src/components/bento-grid/bento-item.js.map +1 -1
  29. package/dist/src/components/button/button.d.ts +1 -1
  30. package/dist/src/components/cards/card.d.ts +2 -2
  31. package/dist/src/components/cards/card.js +11 -11
  32. package/dist/src/components/cards/card.js.map +1 -1
  33. package/dist/src/components/carousel/carousel.d.ts +2 -2
  34. package/dist/src/components/carousel/carousel.js +6 -6
  35. package/dist/src/components/carousel/carousel.js.map +1 -1
  36. package/dist/src/components/comparison-panel/comparison-panel.d.ts +1 -0
  37. package/dist/src/components/comparison-panel/comparison-panel.js +12 -12
  38. package/dist/src/components/comparison-panel/comparison-panel.js.map +1 -1
  39. package/dist/src/components/compatibility-table/compatibility-table.d.ts +1 -0
  40. package/dist/src/components/compatibility-table/compatibility-table.js +14 -14
  41. package/dist/src/components/compatibility-table/compatibility-table.js.map +1 -1
  42. package/dist/src/components/cta-banner/cta-banner.d.ts +1 -0
  43. package/dist/src/components/cta-banner/cta-banner.js +8 -8
  44. package/dist/src/components/cta-banner/cta-banner.js.map +1 -1
  45. package/dist/src/components/grid/grid.css.js +1 -1
  46. package/dist/src/components/grid/grid.css.js.map +1 -1
  47. package/dist/src/components/grid/grid.d.ts +1 -0
  48. package/dist/src/components/grid/grid.js +4 -3
  49. package/dist/src/components/grid/grid.js.map +1 -1
  50. package/dist/src/components/header/header-code.d.ts +3 -2
  51. package/dist/src/components/header/header-code.js +13 -13
  52. package/dist/src/components/header/header-code.js.map +1 -1
  53. package/dist/src/components/heading/heading.d.ts +1 -1
  54. package/dist/src/components/heading/heading.js +5 -1
  55. package/dist/src/components/heading/heading.js.map +1 -1
  56. package/dist/src/components/hero/hero.d.ts +2 -1
  57. package/dist/src/components/hero/hero.js +9 -9
  58. package/dist/src/components/hero/hero.js.map +1 -1
  59. package/dist/src/components/install-options/install-options.d.ts +3 -2
  60. package/dist/src/components/install-options/install-options.js +17 -17
  61. package/dist/src/components/install-options/install-options.js.map +1 -1
  62. package/dist/src/components/link/link.d.ts +1 -1
  63. package/dist/src/components/list/list-item/list-item.d.ts +1 -1
  64. package/dist/src/components/logo-marquee/logo-marquee.d.ts +1 -0
  65. package/dist/src/components/logo-marquee/logo-marquee.js +5 -5
  66. package/dist/src/components/logo-marquee/logo-marquee.js.map +1 -1
  67. package/dist/src/components/motion-art/motion-art.js +1 -1
  68. package/dist/src/components/motion-art/motion-art.js.map +1 -1
  69. package/dist/src/components/overview/overview.d.ts +1 -0
  70. package/dist/src/components/overview/overview.js +7 -7
  71. package/dist/src/components/overview/overview.js.map +1 -1
  72. package/dist/src/components/page-switcher/page-switcher.d.ts +1 -0
  73. package/dist/src/components/page-switcher/page-switcher.js +5 -5
  74. package/dist/src/components/page-switcher/page-switcher.js.map +1 -1
  75. package/dist/src/components/pagination-dots/pagination-dots.d.ts +1 -1
  76. package/dist/src/components/partner-banner/partner-banner.d.ts +1 -0
  77. package/dist/src/components/partner-banner/partner-banner.js +7 -7
  78. package/dist/src/components/partner-banner/partner-banner.js.map +1 -1
  79. package/dist/src/components/post-card/post-card.d.ts +1 -0
  80. package/dist/src/components/post-card/post-card.js +5 -5
  81. package/dist/src/components/post-card/post-card.js.map +1 -1
  82. package/dist/src/components/process-steps/process-steps.d.ts +1 -0
  83. package/dist/src/components/process-steps/process-steps.js +7 -7
  84. package/dist/src/components/process-steps/process-steps.js.map +1 -1
  85. package/dist/src/components/quick-answer/quick-answer.d.ts +1 -0
  86. package/dist/src/components/quick-answer/quick-answer.js +7 -7
  87. package/dist/src/components/quick-answer/quick-answer.js.map +1 -1
  88. package/dist/src/components/review/review-grid.d.ts +1 -0
  89. package/dist/src/components/review/review-grid.js +3 -3
  90. package/dist/src/components/review/review-grid.js.map +1 -1
  91. package/dist/src/components/review/review.d.ts +1 -0
  92. package/dist/src/components/review/review.js +2 -2
  93. package/dist/src/components/review/review.js.map +1 -1
  94. package/dist/src/components/section-header/section-header.d.ts +1 -0
  95. package/dist/src/components/section-header/section-header.js +4 -4
  96. package/dist/src/components/section-header/section-header.js.map +1 -1
  97. package/dist/src/components/shared/controller.observer.d.ts +50 -0
  98. package/dist/src/components/shared/controller.observer.js +2 -0
  99. package/dist/src/components/shared/controller.observer.js.map +1 -0
  100. package/dist/src/components/spotlight-section/spotlight-section.d.ts +1 -0
  101. package/dist/src/components/spotlight-section/spotlight-section.js +7 -7
  102. package/dist/src/components/spotlight-section/spotlight-section.js.map +1 -1
  103. package/dist/src/components/stat/stat-highlight.d.ts +5 -5
  104. package/dist/src/components/stat/stat-highlight.js +2 -2
  105. package/dist/src/components/stat/stat-highlight.js.map +1 -1
  106. package/dist/src/components/stat/stat-tile.d.ts +1 -0
  107. package/dist/src/components/stat/stat-tile.js +5 -5
  108. package/dist/src/components/stat/stat-tile.js.map +1 -1
  109. package/dist/src/components/terminal/terminal-cursor.d.ts +1 -0
  110. package/dist/src/components/terminal/terminal-cursor.js +1 -1
  111. package/dist/src/components/terminal/terminal-cursor.js.map +1 -1
  112. package/dist/src/components/terminal/terminal-message.d.ts +4 -3
  113. package/dist/src/components/terminal/terminal-message.js +25 -25
  114. package/dist/src/components/terminal/terminal-message.js.map +1 -1
  115. package/dist/src/components/tooltip/tooltip.js +1 -1
  116. package/dist/src/components/tooltip/tooltip.js.map +1 -1
  117. package/dist/src/components/trust-panel/trust-panel.d.ts +1 -0
  118. package/dist/src/components/trust-panel/trust-panel.js +19 -19
  119. package/dist/src/components/trust-panel/trust-panel.js.map +1 -1
  120. package/dist/src/loader/create-loader.d.ts +13 -0
  121. package/dist/src/loader/create-loader.js +2 -0
  122. package/dist/src/loader/create-loader.js.map +1 -0
  123. package/dist/src/loader/loader.d.ts +44 -0
  124. package/dist/src/loader/loader.js +2 -0
  125. package/dist/src/loader/loader.js.map +1 -0
  126. package/dist/src/loader/registry.d.ts +2 -0
  127. package/dist/src/loader/registry.js +2 -0
  128. package/dist/src/loader/registry.js.map +1 -0
  129. package/dist/src/tokens/tokens.js +1 -1
  130. package/dist/src/tokens/tokens.js.map +1 -1
  131. package/package.json +12 -4
  132. package/schemas/component-manifest.json +8 -1
  133. package/dist/src/tokens/dark-derivation.d.ts +0 -70
  134. package/dist/src/tokens/dark-derivation.js +0 -2
  135. package/dist/src/tokens/dark-derivation.js.map +0 -1
  136. package/dist/src/tokens/dark-findings.d.ts +0 -59
  137. package/dist/src/tokens/dark-findings.js +0 -2
  138. package/dist/src/tokens/dark-findings.js.map +0 -1
  139. package/dist/src/tokens/story-chrome.d.ts +0 -72
  140. package/dist/src/tokens/story-chrome.js +0 -292
  141. package/dist/src/tokens/story-chrome.js.map +0 -1
  142. package/dist/src/tokens/token-map.d.ts +0 -114
  143. package/dist/src/tokens/token-map.js +0 -2
  144. package/dist/src/tokens/token-map.js.map +0 -1
  145. package/dist/src/tokens/token-purposes.d.ts +0 -63
  146. package/dist/src/tokens/token-purposes.js +0 -2
  147. package/dist/src/tokens/token-purposes.js.map +0 -1
  148. package/dist/src/tokens/type-ceiling-words.d.ts +0 -96
  149. package/dist/src/tokens/type-ceiling-words.js +0 -2
  150. package/dist/src/tokens/type-ceiling-words.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"page-switcher.js","names":["_decorate","__decorate","BdPageSwitcher","LitElement","_args","tokens","ensembleCSS","pageSwitcherStyles","href","active","nothing","title","property","defineElement"],"sources":["../../../../src/components/page-switcher/page-switcher.ts"],"sourcesContent":["import { LitElement, html, nothing } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\nimport { tokens } from \"#tokens/tokens.ts\";\nimport \"#components/icons/bd-ai-icon.ts\";\nimport \"#components/link/link.ts\";\nimport { pageSwitcherStyles } from \"./page-switcher.css.ts\";\nimport { ensembleCSS } from \"#shared/ensemble.css.ts\";\n\ninterface PageSwitcherItem {\n title? : string;\n href : string;\n active?: boolean;\n}\n\n/**\n * The product-level page navigation: a brand mark and one link per page, with\n * the page you are on marked.\n *\n * Two notes on the markup below, both measured rather than assumed.\n *\n * The ink is Position 2 of the wayfinding family review: colour means\n * AVAILABLE and neutral means current. Every item is variant=\"primary\", so a\n * resting item is --color-text-brand and hovers to --color-action-primary-active;\n * the current one carries `current`, which drops it to --color-text-primary at\n * weight 700 and takes the 3px indicator. bd-link's current-and-hovered rule\n * keeps it there under the pointer.\n *\n * The variant is no longer switched per item. It used to be primary for the\n * current one and secondary for the rest, which made the current item the only\n * blue one -- the inverse of what the indicator says -- and left the resting\n * items on the muted ramp. One variant plus `current` is the same information\n * with one fewer thing to keep in step.\n *\n * `current` is `page`, not the generic `true`. These items are pages; the\n * anchor nav's items are positions inside one page and say `location`. Both are\n * current-location markers and they are not the same claim. bd-link puts it on\n * its <a> as aria-current; written here as aria-current, on the bd-link\n * element, it was never announced -- the <a> is in bd-link's shadow root. The\n * look, the indicator below included, keys on the same attribute, so the item\n * cannot be drawn current without being announced so.\n */\n@defineElement(\"bd-page-switcher\")\nclass BdPageSwitcher extends LitElement {\n static styles = [tokens, ensembleCSS, pageSwitcherStyles];\n\n @property({ type: Array })\n items: PageSwitcherItem[] = []; // [{ title, href, active }]\n\n render() {\n return html`\n <div class=\"bd-ensemble inner\">\n <bd-ai-icon class=\"logo\" width=\"200\" height=\"24\"></bd-ai-icon>\n\n <nav aria-label=\"Product navigation\">\n ${this.items.map(({ title, href, active }) => html`\n <bd-link\n href=${href}\n variant=\"primary\"\n no-underline\n current=${active ? \"page\" : nothing}\n class=\"page-link\"\n >${title || nothing}</bd-link>\n `)}\n </nav>\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-page-switcher\": BdPageSwitcher;\n }\n}"],"mappings":"A,scA0CA,IACME,EADN,cAC6BC,CAAW,C,8BAIV,KAAA,MAAA,CAAC,C,QAHb,KAAA,OAAA,CAACE,EAAQC,EAAaC,CAAkB,C,CAKxD,QAAS,CACP,MAAO,EAAI;;;;;YAKH,KAAK,MAAM,KAAK,CAAE,QAAO,OAAM,YAAa,CAAI;;qBAEvCC,EAAK;;;wBAGFC,EAAS,OAASC,EAAQ;;eAEnCC,GAASD,EAAQ;WACrB,EAAE;;;KAIX,CACF,EAtBGV,EAAA,CAAAY,EAAS,CAAE,KAAM,KAAM,CAAC,CAAA,EAAAV,EAAA,UAAA,QAAA,IAAA,EAAA,EAJ1B,EAAAF,EAAA,CAAAa,EAAc,kBAAkB,CAAA,EAAAX,CAAA"}
1
+ {"version":3,"file":"page-switcher.js","names":["_decorate","__decorate","BdPageSwitcher","LitElement","_args","ensembleCSS","pageSwitcherStyles","href","active","nothing","title","property","defineElement"],"sources":["../../../../src/components/page-switcher/page-switcher.ts"],"sourcesContent":["import { LitElement, html, nothing } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\n// Installs the design tokens into document scope; see src/tokens/tokens.ts\nimport \"#tokens/tokens.ts\";\nimport \"#components/icons/bd-ai-icon.ts\";\nimport \"#components/link/link.ts\";\nimport { pageSwitcherStyles } from \"./page-switcher.css.ts\";\nimport { ensembleCSS } from \"#shared/ensemble.css.ts\";\n\ninterface PageSwitcherItem {\n title? : string;\n href : string;\n active?: boolean;\n}\n\n/**\n * The product-level page navigation: a brand mark and one link per page, with\n * the page you are on marked.\n *\n * Two notes on the markup below, both measured rather than assumed.\n *\n * The ink is Position 2 of the wayfinding family review: colour means\n * AVAILABLE and neutral means current. Every item is variant=\"primary\", so a\n * resting item is --color-text-brand and hovers to --color-action-primary-active;\n * the current one carries `current`, which drops it to --color-text-primary at\n * weight 700 and takes the 3px indicator. bd-link's current-and-hovered rule\n * keeps it there under the pointer.\n *\n * The variant is no longer switched per item. It used to be primary for the\n * current one and secondary for the rest, which made the current item the only\n * blue one -- the inverse of what the indicator says -- and left the resting\n * items on the muted ramp. One variant plus `current` is the same information\n * with one fewer thing to keep in step.\n *\n * `current` is `page`, not the generic `true`. These items are pages; the\n * anchor nav's items are positions inside one page and say `location`. Both are\n * current-location markers and they are not the same claim. bd-link puts it on\n * its <a> as aria-current; written here as aria-current, on the bd-link\n * element, it was never announced -- the <a> is in bd-link's shadow root. The\n * look, the indicator below included, keys on the same attribute, so the item\n * cannot be drawn current without being announced so.\n */\n@defineElement(\"bd-page-switcher\")\nclass BdPageSwitcher extends LitElement {\n static styles = [ensembleCSS, pageSwitcherStyles];\n\n @property({ type: Array })\n items: PageSwitcherItem[] = []; // [{ title, href, active }]\n\n render() {\n return html`\n <div class=\"bd-ensemble inner\">\n <bd-ai-icon class=\"logo\" width=\"200\" height=\"24\"></bd-ai-icon>\n\n <nav aria-label=\"Product navigation\">\n ${this.items.map(({ title, href, active }) => html`\n <bd-link\n href=${href}\n variant=\"primary\"\n no-underline\n current=${active ? \"page\" : nothing}\n class=\"page-link\"\n >${title || nothing}</bd-link>\n `)}\n </nav>\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-page-switcher\": BdPageSwitcher;\n }\n}"],"mappings":"A,qbA2CA,IACME,EADN,cAC6BC,CAAW,C,8BAIV,KAAA,MAAA,CAAC,C,QAHb,KAAA,OAAA,CAACE,EAAaC,CAAkB,C,CAKhD,QAAS,CACP,MAAO,EAAI;;;;;YAKH,KAAK,MAAM,KAAK,CAAE,QAAO,OAAM,YAAa,CAAI;;qBAEvCC,EAAK;;;wBAGFC,EAAS,OAASC,EAAQ;;eAEnCC,GAASD,EAAQ;WACrB,EAAE;;;KAIX,CACF,EAtBGT,EAAA,CAAAW,EAAS,CAAE,KAAM,KAAM,CAAC,CAAA,EAAAT,EAAA,UAAA,QAAA,IAAA,EAAA,EAJ1B,EAAAF,EAAA,CAAAY,EAAc,kBAAkB,CAAA,EAAAV,CAAA"}
@@ -27,7 +27,7 @@ declare class BdPaginationDots extends LitElement {
27
27
  _announcePlayState(): void;
28
28
  _select(n: number): void;
29
29
  _pick(n: number): void;
30
- render(): import("lit-html").TemplateResult<1> | typeof nothing;
30
+ render(): typeof nothing | import("lit-html").TemplateResult<1>;
31
31
  }
32
32
  declare global {
33
33
  interface HTMLElementTagNameMap {
@@ -1,4 +1,5 @@
1
1
  import { LitElement } from "lit";
2
+ import "../../tokens/tokens.js";
2
3
  import "../heading/heading.js";
3
4
  type HeadingTag = "h1" | "h2" | "h3" | "h4" | "h5" | "h6";
4
5
  /**
@@ -1,4 +1,4 @@
1
- import{defineElement as e}from"../shared/define-element.js";import{tokens as t}from"../../tokens/tokens.js";import n from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../heading/heading.js";import{ensembleCSS as r}from"../shared/ensemble.css.js";import{partnerBannerCSS as i}from"./partner-banner.css.js";import{LitElement as a,html as o,nothing as s}from"lit";import{property as c}from"lit/decorators.js";var l=class extends a{constructor(...e){super(...e),this.heading=``,this.quote=``,this.attribution=``,this.lead=``,this.as=`h2`}static{this.styles=[t,r,i]}_onActionsSlot(e){for(let t of e.target.assignedElements({flatten:!0}))`fullWidth`in t&&t.setAttribute(`fullwidth`,``)}render(){return o`
1
+ import{defineElement as e}from"../shared/define-element.js";import"../../tokens/tokens.js";import t from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../heading/heading.js";import{ensembleCSS as n}from"../shared/ensemble.css.js";import{partnerBannerCSS as r}from"./partner-banner.css.js";import{LitElement as i,html as a,nothing as o}from"lit";import{property as s}from"lit/decorators.js";var c=class extends i{constructor(...e){super(...e),this.heading=``,this.quote=``,this.attribution=``,this.lead=``,this.as=`h2`}static{this.styles=[n,r]}_onActionsSlot(e){for(let t of e.target.assignedElements({flatten:!0}))`fullWidth`in t&&t.setAttribute(`fullwidth`,``)}render(){return a`
2
2
  <section class="root">
3
3
  <div class="photo"><slot name="photo"></slot></div>
4
4
  <div class="band">
@@ -6,19 +6,19 @@ import{defineElement as e}from"../shared/define-element.js";import{tokens as t}f
6
6
  <div class="card">
7
7
  <div class="intro">
8
8
  <div class="lockup"><slot name="lockup"></slot></div>
9
- <bd-h as="${this.as}" visual-level="h2" color="on-brand" class="heading"><span class="text">${this.heading}</span></bd-h>
9
+ ${this.heading?a`<bd-h as="${this.as}" visual-level="h2" color="on-brand" class="heading"><span class="text">${this.heading}</span></bd-h>`:o}
10
10
  </div>
11
11
  <div class="detail">
12
- ${this.quote?o`<figure class="quote">
12
+ ${this.quote?a`<figure class="quote">
13
13
  <blockquote>${this.quote}</blockquote>
14
- ${this.attribution?o`<figcaption>${this.attribution}</figcaption>`:s}
15
- </figure>`:s}
16
- ${this.lead?o`<p class="lead">${this.lead}</p>`:s}
14
+ ${this.attribution?a`<figcaption>${this.attribution}</figcaption>`:o}
15
+ </figure>`:o}
16
+ ${this.lead?a`<p class="lead">${this.lead}</p>`:o}
17
17
  <div class="actions"><slot name="actions" @slotchange=${this._onActionsSlot}></slot></div>
18
18
  </div>
19
19
  </div>
20
20
  </div>
21
21
  </div>
22
22
  </section>
23
- `}};n([c({type:String})],l.prototype,`heading`,void 0),n([c({type:String})],l.prototype,`quote`,void 0),n([c({type:String})],l.prototype,`attribution`,void 0),n([c({type:String})],l.prototype,`lead`,void 0),n([c({type:String})],l.prototype,`as`,void 0),l=n([e(`bd-partner-banner`)],l);export{l as PartnerBanner};
23
+ `}};t([s({type:String})],c.prototype,`heading`,void 0),t([s({type:String})],c.prototype,`quote`,void 0),t([s({type:String})],c.prototype,`attribution`,void 0),t([s({type:String})],c.prototype,`lead`,void 0),t([s({type:String})],c.prototype,`as`,void 0),c=t([e(`bd-partner-banner`)],c);export{c as PartnerBanner};
24
24
  //# sourceMappingURL=partner-banner.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"partner-banner.js","names":["_decorate","__decorate","PartnerBanner","LitElement","_args","tokens","ensembleCSS","partnerBannerCSS","el","nothing","property","defineElement"],"sources":["../../../../src/components/partner-banner/partner-banner.ts"],"sourcesContent":["import { LitElement, html, nothing } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\nimport { tokens } from \"#tokens/tokens.ts\";\nimport \"#components/heading/heading.ts\";\nimport { ensembleCSS } from \"#shared/ensemble.css.ts\";\nimport { partnerBannerCSS } from \"./partner-banner.css.ts\";\n\ntype HeadingTag = \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\";\n\n/**\n * A partnership band: a full-bleed photo with a brand card that rises over\n * its lower edge, holding the partner lockup, a headline, a quote with its\n * attribution, a lead and two CTAs. The homepage's Ferrari section; drawn in\n * the foundation Figma file as Partner banner.\n *\n * Not bd-cta-banner, which has no image, and not bd-spotlight-section, which\n * sets its picture beside the copy rather than behind it.\n *\n * Slots: `photo` (an <img> or <picture>, cover-fitted), `lockup` (the partner\n * mark, drawn in the brand's ink), `actions` (white and outline-white\n * bd-button-links). Below md the card stops overlapping and becomes a solid\n * band under the photo, edge to edge, with the CTAs stacked at its full\n * width, as the phone frame draws them. From md they sit in a row, and one\n * that wraps grows to the row's width rather than keeping its own.\n */\n@defineElement(\"bd-partner-banner\")\nexport class PartnerBanner extends LitElement {\n static styles = [tokens, ensembleCSS, partnerBannerCSS];\n\n @property({ type: String })\n heading = \"\";\n @property({ type: String })\n quote = \"\";\n @property({ type: String })\n attribution = \"\";\n @property({ type: String })\n lead = \"\";\n @property({ type: String })\n as: HeadingTag = \"h2\";\n\n /* A bd-button-link fills its own box only through its fullwidth attribute,\n so the banner sets it on every CTA at every width and leaves the box's\n width to partner-banner.css.ts: the column's width on a phone, and from\n md the label's width until the row wraps, then the row's. That decides on\n the rendered labels, so a longer translation wraps and grows where the\n English fits on one line -- no breakpoint could know where that is. */\n _onActionsSlot(e: Event) {\n for (const el of (e.target as HTMLSlotElement).assignedElements({ flatten: true })) {\n if (\"fullWidth\" in el) el.setAttribute(\"fullwidth\", \"\");\n }\n }\n\n render() {\n return html`\n <section class=\"root\">\n <div class=\"photo\"><slot name=\"photo\"></slot></div>\n <div class=\"band\">\n <div class=\"bd-ensemble column\">\n <div class=\"card\">\n <div class=\"intro\">\n <div class=\"lockup\"><slot name=\"lockup\"></slot></div>\n <bd-h as=\"${this.as}\" visual-level=\"h2\" color=\"on-brand\" class=\"heading\"><span class=\"text\">${this.heading}</span></bd-h>\n </div>\n <div class=\"detail\">\n ${this.quote\n ? html`<figure class=\"quote\">\n <blockquote>${this.quote}</blockquote>\n ${this.attribution ? html`<figcaption>${this.attribution}</figcaption>` : nothing}\n </figure>`\n : nothing}\n ${this.lead ? html`<p class=\"lead\">${this.lead}</p>` : nothing}\n <div class=\"actions\"><slot name=\"actions\" @slotchange=${this._onActionsSlot}></slot></div>\n </div>\n </div>\n </div>\n </div>\n </section>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-partner-banner\": PartnerBanner;\n }\n}\n"],"mappings":"A,4aA2BO,IAAME,EAAN,cAA4BC,CAAW,C,8BAIlC,KAAA,QAAA,GAEF,KAAA,MAAA,GAEM,KAAA,YAAA,GAEP,KAAA,KAAA,GAEU,KAAA,GAAA,I,QAXD,KAAA,OAAA,CAACE,EAAQC,EAAaC,CAAgB,C,CAmBtD,eAAe,EAAU,CACvB,IAAK,IAAMC,KAAO,EAAE,OAA2B,iBAAiB,CAAE,QAAS,EAAK,CAAC,EAC3E,cAAeA,GAAIA,EAAG,aAAa,YAAa,EAAE,CAE1D,CAEA,QAAS,CACP,MAAO,EAAI;;;;;;;;4BAQa,KAAK,GAAG,0EAA0E,KAAK,QAAQ;;;kBAGzG,KAAK,MACH,CAAI;oCACY,KAAK,MAAM;wBACvB,KAAK,YAAc,CAAI,eAAe,KAAK,YAAY,eAAiBC,EAAQ;+BAEpFA,EAAQ;kBACV,KAAK,KAAO,CAAI,mBAAmB,KAAK,KAAK,MAAQA,EAAQ;wEACP,KAAK,eAAe;;;;;;KAO1F,CACF,EAlDGT,EAAA,CAAAU,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAR,EAAA,UAAA,UAAA,IAAA,EAAA,EAEzBF,EAAA,CAAAU,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAR,EAAA,UAAA,QAAA,IAAA,EAAA,EAEzBF,EAAA,CAAAU,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAR,EAAA,UAAA,cAAA,IAAA,EAAA,EAEzBF,EAAA,CAAAU,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAR,EAAA,UAAA,OAAA,IAAA,EAAA,EAEzBF,EAAA,CAAAU,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAR,EAAA,UAAA,KAAA,IAAA,EAAA,EAZ3B,EAAAF,EAAA,CAAAW,EAAc,mBAAmB,CAAA,EAAAT,CAAA,E"}
1
+ {"version":3,"file":"partner-banner.js","names":["_decorate","__decorate","PartnerBanner","LitElement","_args","ensembleCSS","partnerBannerCSS","el","nothing","property","defineElement"],"sources":["../../../../src/components/partner-banner/partner-banner.ts"],"sourcesContent":["import { LitElement, html, nothing } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\n// Installs the design tokens into document scope; see src/tokens/tokens.ts\nimport \"#tokens/tokens.ts\";\nimport \"#components/heading/heading.ts\";\nimport { ensembleCSS } from \"#shared/ensemble.css.ts\";\nimport { partnerBannerCSS } from \"./partner-banner.css.ts\";\n\ntype HeadingTag = \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\";\n\n/**\n * A partnership band: a full-bleed photo with a brand card that rises over\n * its lower edge, holding the partner lockup, a headline, a quote with its\n * attribution, a lead and two CTAs. The homepage's Ferrari section; drawn in\n * the foundation Figma file as Partner banner.\n *\n * Not bd-cta-banner, which has no image, and not bd-spotlight-section, which\n * sets its picture beside the copy rather than behind it.\n *\n * Slots: `photo` (an <img> or <picture>, cover-fitted), `lockup` (the partner\n * mark, drawn in the brand's ink), `actions` (white and outline-white\n * bd-button-links). Below md the card stops overlapping and becomes a solid\n * band under the photo, edge to edge, with the CTAs stacked at its full\n * width, as the phone frame draws them. From md they sit in a row, and one\n * that wraps grows to the row's width rather than keeping its own.\n */\n@defineElement(\"bd-partner-banner\")\nexport class PartnerBanner extends LitElement {\n static styles = [ensembleCSS, partnerBannerCSS];\n\n @property({ type: String })\n heading = \"\";\n @property({ type: String })\n quote = \"\";\n @property({ type: String })\n attribution = \"\";\n @property({ type: String })\n lead = \"\";\n @property({ type: String })\n as: HeadingTag = \"h2\";\n\n /* A bd-button-link fills its own box only through its fullwidth attribute,\n so the banner sets it on every CTA at every width and leaves the box's\n width to partner-banner.css.ts: the column's width on a phone, and from\n md the label's width until the row wraps, then the row's. That decides on\n the rendered labels, so a longer translation wraps and grows where the\n English fits on one line -- no breakpoint could know where that is. */\n _onActionsSlot(e: Event) {\n for (const el of (e.target as HTMLSlotElement).assignedElements({ flatten: true })) {\n if (\"fullWidth\" in el) el.setAttribute(\"fullwidth\", \"\");\n }\n }\n\n render() {\n return html`\n <section class=\"root\">\n <div class=\"photo\"><slot name=\"photo\"></slot></div>\n <div class=\"band\">\n <div class=\"bd-ensemble column\">\n <div class=\"card\">\n <div class=\"intro\">\n <div class=\"lockup\"><slot name=\"lockup\"></slot></div>\n ${this.heading\n ? html`<bd-h as=\"${this.as}\" visual-level=\"h2\" color=\"on-brand\" class=\"heading\"><span class=\"text\">${this.heading}</span></bd-h>`\n : nothing}\n </div>\n <div class=\"detail\">\n ${this.quote\n ? html`<figure class=\"quote\">\n <blockquote>${this.quote}</blockquote>\n ${this.attribution ? html`<figcaption>${this.attribution}</figcaption>` : nothing}\n </figure>`\n : nothing}\n ${this.lead ? html`<p class=\"lead\">${this.lead}</p>` : nothing}\n <div class=\"actions\"><slot name=\"actions\" @slotchange=${this._onActionsSlot}></slot></div>\n </div>\n </div>\n </div>\n </div>\n </section>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-partner-banner\": PartnerBanner;\n }\n}\n"],"mappings":"A,2ZA4BO,IAAME,EAAN,cAA4BC,CAAW,C,8BAIlC,KAAA,QAAA,GAEF,KAAA,MAAA,GAEM,KAAA,YAAA,GAEP,KAAA,KAAA,GAEU,KAAA,GAAA,I,QAXD,KAAA,OAAA,CAACE,EAAaC,CAAgB,C,CAmB9C,eAAe,EAAU,CACvB,IAAK,IAAMC,KAAO,EAAE,OAA2B,iBAAiB,CAAE,QAAS,EAAK,CAAC,EAC3E,cAAeA,GAAIA,EAAG,aAAa,YAAa,EAAE,CAE1D,CAEA,QAAS,CACP,MAAO,EAAI;;;;;;;;kBAQG,KAAK,QACH,CAAI,aAAa,KAAK,GAAG,0EAA0E,KAAK,QAAQ,gBAChHC,EAAQ;;;kBAGV,KAAK,MACH,CAAI;oCACY,KAAK,MAAM;wBACvB,KAAK,YAAc,CAAI,eAAe,KAAK,YAAY,eAAiBA,EAAQ;+BAEpFA,EAAQ;kBACV,KAAK,KAAO,CAAI,mBAAmB,KAAK,KAAK,MAAQA,EAAQ;wEACP,KAAK,eAAe;;;;;;KAO1F,CACF,EApDGR,EAAA,CAAAS,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAP,EAAA,UAAA,UAAA,IAAA,EAAA,EAEzBF,EAAA,CAAAS,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAP,EAAA,UAAA,QAAA,IAAA,EAAA,EAEzBF,EAAA,CAAAS,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAP,EAAA,UAAA,cAAA,IAAA,EAAA,EAEzBF,EAAA,CAAAS,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAP,EAAA,UAAA,OAAA,IAAA,EAAA,EAEzBF,EAAA,CAAAS,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAP,EAAA,UAAA,KAAA,IAAA,EAAA,EAZ3B,EAAAF,EAAA,CAAAU,EAAc,mBAAmB,CAAA,EAAAR,CAAA,E"}
@@ -1,4 +1,5 @@
1
1
  import { LitElement, type PropertyValues } from "lit";
2
+ import "../../tokens/tokens.js";
2
3
  import "../badge/badge.js";
3
4
  import "../icons/arrow-icon.js";
4
5
  declare const HEADING_TAGS: readonly ["h1", "h2", "h3", "h4", "h5", "h6"];
@@ -1,15 +1,15 @@
1
- import{defineElement as e}from"../shared/define-element.js";import{tokens as t}from"../../tokens/tokens.js";import n from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import{isOneOf as r}from"../shared/prop-vocabulary.js";import"../icons/arrow-icon.js";import"../badge/badge.js";import{postCardCSS as i}from"./post-card.css.js";import{LitElement as a,nothing as o}from"lit";import{property as s}from"lit/decorators.js";import{html as c,literal as l}from"lit/static-html.js";var u=[`h1`,`h2`,`h3`,`h4`,`h5`,`h6`],d={h1:l`h1`,h2:l`h2`,h3:l`h3`,h4:l`h4`,h5:l`h5`,h6:l`h6`},f=class extends a{constructor(...e){super(...e),this.href=``,this.heading=``,this.badge=``,this.image=``,this.imageAlt=``,this.readMore=`Read more`,this.as=`h3`}static{this.styles=[t,i]}willUpdate(e){e.has(`as`)&&!r(u,this.as)&&(this.as=`h3`)}_renderHeading(){let e=this.href?c`<a class="link" href="${this.href}">${this.heading}</a>`:this.heading,t=d[this.as];return c`<${t} class="heading">${e}</${t}>`}render(){return c`
1
+ import{defineElement as e}from"../shared/define-element.js";import"../../tokens/tokens.js";import t from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import{isOneOf as n}from"../shared/prop-vocabulary.js";import"../icons/arrow-icon.js";import"../badge/badge.js";import{postCardCSS as r}from"./post-card.css.js";import{LitElement as i,nothing as a}from"lit";import{property as o}from"lit/decorators.js";import{html as s,literal as c}from"lit/static-html.js";var l=[`h1`,`h2`,`h3`,`h4`,`h5`,`h6`],u={h1:c`h1`,h2:c`h2`,h3:c`h3`,h4:c`h4`,h5:c`h5`,h6:c`h6`},d=class extends i{constructor(...e){super(...e),this.href=``,this.heading=``,this.badge=``,this.image=``,this.imageAlt=``,this.readMore=`Read more`,this.as=`h3`}static{this.styles=[r]}willUpdate(e){e.has(`as`)&&!n(l,this.as)&&(this.as=`h3`)}_renderHeading(){let e=this.href?s`<a class="link" href="${this.href}">${this.heading}</a>`:this.heading,t=u[this.as];return s`<${t} class="heading">${e}</${t}>`}render(){return s`
2
2
  <article class="card">
3
3
  <div class="cover">
4
4
  <slot name="image">
5
- ${this.image?c`<img src="${this.image}" alt="${this.imageAlt}" loading="lazy">`:o}
5
+ ${this.image?s`<img src="${this.image}" alt="${this.imageAlt}" loading="lazy">`:a}
6
6
  </slot>
7
- ${this.badge?c`<bd-badge class="badge" tone="info" variant="shade" size="sm">${this.badge}</bd-badge>`:o}
7
+ ${this.badge?s`<bd-badge class="badge" tone="info" variant="shade" size="sm">${this.badge}</bd-badge>`:a}
8
8
  </div>
9
9
  <div class="body">
10
10
  ${this._renderHeading()}
11
- ${this.href?c`<span class="more" aria-hidden="true">${this.readMore}<bd-arrow-icon size="sm"></bd-arrow-icon></span>`:o}
11
+ ${this.href?s`<span class="more" aria-hidden="true">${this.readMore}<bd-arrow-icon size="sm"></bd-arrow-icon></span>`:a}
12
12
  </div>
13
13
  </article>
14
- `}};n([s({type:String})],f.prototype,`href`,void 0),n([s({type:String})],f.prototype,`heading`,void 0),n([s({type:String})],f.prototype,`badge`,void 0),n([s({type:String})],f.prototype,`image`,void 0),n([s({type:String,attribute:`image-alt`})],f.prototype,`imageAlt`,void 0),n([s({type:String,attribute:`read-more`})],f.prototype,`readMore`,void 0),n([s({type:String})],f.prototype,`as`,void 0),f=n([e(`bd-post-card`)],f);export{f as PostCard};
14
+ `}};t([o({type:String})],d.prototype,`href`,void 0),t([o({type:String})],d.prototype,`heading`,void 0),t([o({type:String})],d.prototype,`badge`,void 0),t([o({type:String})],d.prototype,`image`,void 0),t([o({type:String,attribute:`image-alt`})],d.prototype,`imageAlt`,void 0),t([o({type:String,attribute:`read-more`})],d.prototype,`readMore`,void 0),t([o({type:String})],d.prototype,`as`,void 0),d=t([e(`bd-post-card`)],d);export{d as PostCard};
15
15
  //# sourceMappingURL=post-card.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"post-card.js","names":["_decorate","__decorate","html$1","HEADING_TAGS","TAGS","PostCard","LitElement","_args","tokens","postCardCSS","changed","isOneOf","text","tag","nothing","property","defineElement"],"sources":["../../../../src/components/post-card/post-card.ts"],"sourcesContent":["import { LitElement, nothing, type PropertyValues } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { html, literal } from \"lit/static-html.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\nimport { isOneOf } from \"#shared/prop-vocabulary.ts\";\nimport { tokens } from \"#tokens/tokens.ts\";\nimport \"#components/badge/badge.ts\";\nimport \"#components/icons/arrow-icon.ts\";\nimport { postCardCSS } from \"./post-card.css.ts\";\n\n/* Every level, as bd-audience-card, bd-partner-banner and\n bd-awards-spotlight take: the outline is the page's to compose. This took\n h2 to h5, and h1 or h6 rendered an h3 without a word. */\nconst HEADING_TAGS = [\"h1\", \"h2\", \"h3\", \"h4\", \"h5\", \"h6\"] as const;\ntype HeadingTag = typeof HEADING_TAGS[number];\nconst TAGS = {\n h1: literal`h1`, h2: literal`h2`, h3: literal`h3`, h4: literal`h4`, h5: literal`h5`, h6: literal`h6`\n} as const satisfies Record<HeadingTag, unknown>;\n\n/**\n * An article card for a feed of posts: a cover with a category badge laid\n * over it, the title and a \"Read more\" with an arrow. The homepage's Latest\n * insights; drawn in the foundation Figma file as Post card.\n *\n * One link per card. The title is the link and its box is stretched over the\n * whole card, so a click anywhere follows it; \"Read more\" is the visual cue\n * and is hidden from a screen reader, which would otherwise hear the same\n * destination twice per card, three cards a row.\n *\n * Not blog-related-articles, which lives in the blog sub-system outside the\n * token system and has no \"Read more\" and no row form. Between md and lg\n * the card is a row, the cover on the left.\n */\n@defineElement(\"bd-post-card\")\nexport class PostCard extends LitElement {\n static styles = [tokens, postCardCSS];\n\n @property({ type: String })\n href = \"\";\n @property({ type: String })\n heading = \"\";\n @property({ type: String })\n badge = \"\";\n @property({ type: String })\n image = \"\";\n // the cover illustrates the title beside it, so it is decorative by default\n @property({ type: String, attribute: \"image-alt\" })\n imageAlt = \"\";\n @property({ type: String, attribute: \"read-more\" })\n readMore = \"Read more\";\n @property({ type: String })\n as: HeadingTag = \"h3\";\n\n willUpdate(changed: PropertyValues<this>) {\n if (changed.has(\"as\") && !isOneOf(HEADING_TAGS, this.as)) this.as = \"h3\";\n }\n\n _renderHeading() {\n const text = this.href\n ? html`<a class=\"link\" href=\"${this.href}\">${this.heading}</a>`\n : this.heading;\n const tag = TAGS[this.as];\n return html`<${tag} class=\"heading\">${text}</${tag}>`;\n }\n\n render() {\n return html`\n <article class=\"card\">\n <div class=\"cover\">\n <slot name=\"image\">\n ${this.image ? html`<img src=\"${this.image}\" alt=\"${this.imageAlt}\" loading=\"lazy\">` : nothing}\n </slot>\n ${this.badge\n ? html`<bd-badge class=\"badge\" tone=\"info\" variant=\"shade\" size=\"sm\">${this.badge}</bd-badge>`\n : nothing}\n </div>\n <div class=\"body\">\n ${this._renderHeading()}\n ${this.href\n ? html`<span class=\"more\" aria-hidden=\"true\">${this.readMore}<bd-arrow-icon size=\"sm\"></bd-arrow-icon></span>`\n : nothing}\n </div>\n </article>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-post-card\": PostCard;\n }\n}\n"],"mappings":"A,yeAaA,IAAMG,EAAe,CAAC,KAAM,KAAM,KAAM,KAAM,KAAM,IAAI,EAElDC,EAAO,CACX,GAAI,CAAO,KAAM,GAAI,CAAO,KAAM,GAAI,CAAO,KAAM,GAAI,CAAO,KAAM,GAAI,CAAO,KAAM,GAAI,CAAO,IAClG,EAiBaC,EAAN,cAAuBC,CAAW,C,8BAIhC,KAAA,KAAA,GAEG,KAAA,QAAA,GAEF,KAAA,MAAA,GAEA,KAAA,MAAA,GAGG,KAAA,SAAA,GAEA,KAAA,SAAA,YAEM,KAAA,GAAA,I,QAhBD,KAAA,OAAA,CAACE,EAAQC,CAAW,C,CAkBpC,WAAW,EAA+B,CACpCC,EAAQ,IAAI,IAAI,GAAK,CAACC,EAAQR,EAAc,KAAK,EAAE,IAAG,KAAK,GAAK,KACtE,CAEA,gBAAiB,CACf,IAAMS,EAAO,KAAK,KACd,CAAI,yBAAyB,KAAK,KAAK,IAAI,KAAK,QAAQ,MACxD,KAAK,QACHC,EAAMT,EAAK,KAAK,IACtB,MAAO,EAAI,IAAIS,EAAI,mBAAmBD,EAAK,IAAIC,EAAI,EACrD,CAEA,QAAS,CACP,MAAO,EAAI;;;;cAID,KAAK,MAAQ,CAAI,aAAa,KAAK,MAAM,SAAS,KAAK,SAAS,mBAAqBC,EAAQ;;YAE/F,KAAK,MACH,CAAI,iEAAiE,KAAK,MAAM,aAChFA,EAAQ;;;YAGV,KAAK,eAAe,EAAE;YACtB,KAAK,KACH,CAAI,yCAAyC,KAAK,SAAS,kDAC3DA,EAAQ;;;KAIpB,CACF,EAhDGd,EAAA,CAAAe,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAV,EAAA,UAAA,OAAA,IAAA,EAAA,EAEzBL,EAAA,CAAAe,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAV,EAAA,UAAA,UAAA,IAAA,EAAA,EAEzBL,EAAA,CAAAe,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAV,EAAA,UAAA,QAAA,IAAA,EAAA,EAEzBL,EAAA,CAAAe,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAV,EAAA,UAAA,QAAA,IAAA,EAAA,EAGzBL,EAAA,CAAAe,EAAS,CAAE,KAAM,OAAQ,UAAW,WAAY,CAAC,CAAA,EAAAV,EAAA,UAAA,WAAA,IAAA,EAAA,EAEjDL,EAAA,CAAAe,EAAS,CAAE,KAAM,OAAQ,UAAW,WAAY,CAAC,CAAA,EAAAV,EAAA,UAAA,WAAA,IAAA,EAAA,EAEjDL,EAAA,CAAAe,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAV,EAAA,UAAA,KAAA,IAAA,EAAA,EAjB3B,EAAAL,EAAA,CAAAgB,EAAc,cAAc,CAAA,EAAAX,CAAA,E"}
1
+ {"version":3,"file":"post-card.js","names":["_decorate","__decorate","html$1","HEADING_TAGS","TAGS","PostCard","LitElement","_args","postCardCSS","changed","isOneOf","text","tag","nothing","property","defineElement"],"sources":["../../../../src/components/post-card/post-card.ts"],"sourcesContent":["import { LitElement, nothing, type PropertyValues } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { html, literal } from \"lit/static-html.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\nimport { isOneOf } from \"#shared/prop-vocabulary.ts\";\n// Installs the design tokens into document scope; see src/tokens/tokens.ts\nimport \"#tokens/tokens.ts\";\nimport \"#components/badge/badge.ts\";\nimport \"#components/icons/arrow-icon.ts\";\nimport { postCardCSS } from \"./post-card.css.ts\";\n\n/* Every level, as bd-audience-card, bd-partner-banner and\n bd-awards-spotlight take: the outline is the page's to compose. This took\n h2 to h5, and h1 or h6 rendered an h3 without a word. */\nconst HEADING_TAGS = [\"h1\", \"h2\", \"h3\", \"h4\", \"h5\", \"h6\"] as const;\ntype HeadingTag = typeof HEADING_TAGS[number];\nconst TAGS = {\n h1: literal`h1`, h2: literal`h2`, h3: literal`h3`, h4: literal`h4`, h5: literal`h5`, h6: literal`h6`\n} as const satisfies Record<HeadingTag, unknown>;\n\n/**\n * An article card for a feed of posts: a cover with a category badge laid\n * over it, the title and a \"Read more\" with an arrow. The homepage's Latest\n * insights; drawn in the foundation Figma file as Post card.\n *\n * One link per card. The title is the link and its box is stretched over the\n * whole card, so a click anywhere follows it; \"Read more\" is the visual cue\n * and is hidden from a screen reader, which would otherwise hear the same\n * destination twice per card, three cards a row.\n *\n * Not blog-related-articles, which lives in the blog sub-system outside the\n * token system and has no \"Read more\" and no row form. Between md and lg\n * the card is a row, the cover on the left.\n */\n@defineElement(\"bd-post-card\")\nexport class PostCard extends LitElement {\n static styles = [postCardCSS];\n\n @property({ type: String })\n href = \"\";\n @property({ type: String })\n heading = \"\";\n @property({ type: String })\n badge = \"\";\n @property({ type: String })\n image = \"\";\n // the cover illustrates the title beside it, so it is decorative by default\n @property({ type: String, attribute: \"image-alt\" })\n imageAlt = \"\";\n @property({ type: String, attribute: \"read-more\" })\n readMore = \"Read more\";\n @property({ type: String })\n as: HeadingTag = \"h3\";\n\n willUpdate(changed: PropertyValues<this>) {\n if (changed.has(\"as\") && !isOneOf(HEADING_TAGS, this.as)) this.as = \"h3\";\n }\n\n _renderHeading() {\n const text = this.href\n ? html`<a class=\"link\" href=\"${this.href}\">${this.heading}</a>`\n : this.heading;\n const tag = TAGS[this.as];\n return html`<${tag} class=\"heading\">${text}</${tag}>`;\n }\n\n render() {\n return html`\n <article class=\"card\">\n <div class=\"cover\">\n <slot name=\"image\">\n ${this.image ? html`<img src=\"${this.image}\" alt=\"${this.imageAlt}\" loading=\"lazy\">` : nothing}\n </slot>\n ${this.badge\n ? html`<bd-badge class=\"badge\" tone=\"info\" variant=\"shade\" size=\"sm\">${this.badge}</bd-badge>`\n : nothing}\n </div>\n <div class=\"body\">\n ${this._renderHeading()}\n ${this.href\n ? html`<span class=\"more\" aria-hidden=\"true\">${this.readMore}<bd-arrow-icon size=\"sm\"></bd-arrow-icon></span>`\n : nothing}\n </div>\n </article>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-post-card\": PostCard;\n }\n}\n"],"mappings":"A,wdAcA,IAAMG,EAAe,CAAC,KAAM,KAAM,KAAM,KAAM,KAAM,IAAI,EAElDC,EAAO,CACX,GAAI,CAAO,KAAM,GAAI,CAAO,KAAM,GAAI,CAAO,KAAM,GAAI,CAAO,KAAM,GAAI,CAAO,KAAM,GAAI,CAAO,IAClG,EAiBaC,EAAN,cAAuBC,CAAW,C,8BAIhC,KAAA,KAAA,GAEG,KAAA,QAAA,GAEF,KAAA,MAAA,GAEA,KAAA,MAAA,GAGG,KAAA,SAAA,GAEA,KAAA,SAAA,YAEM,KAAA,GAAA,I,QAhBD,KAAA,OAAA,CAACE,CAAW,C,CAkB5B,WAAW,EAA+B,CACpCC,EAAQ,IAAI,IAAI,GAAK,CAACC,EAAQP,EAAc,KAAK,EAAE,IAAG,KAAK,GAAK,KACtE,CAEA,gBAAiB,CACf,IAAMQ,EAAO,KAAK,KACd,CAAI,yBAAyB,KAAK,KAAK,IAAI,KAAK,QAAQ,MACxD,KAAK,QACHC,EAAMR,EAAK,KAAK,IACtB,MAAO,EAAI,IAAIQ,EAAI,mBAAmBD,EAAK,IAAIC,EAAI,EACrD,CAEA,QAAS,CACP,MAAO,EAAI;;;;cAID,KAAK,MAAQ,CAAI,aAAa,KAAK,MAAM,SAAS,KAAK,SAAS,mBAAqBC,EAAQ;;YAE/F,KAAK,MACH,CAAI,iEAAiE,KAAK,MAAM,aAChFA,EAAQ;;;YAGV,KAAK,eAAe,EAAE;YACtB,KAAK,KACH,CAAI,yCAAyC,KAAK,SAAS,kDAC3DA,EAAQ;;;KAIpB,CACF,EAhDGb,EAAA,CAAAc,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAT,EAAA,UAAA,OAAA,IAAA,EAAA,EAEzBL,EAAA,CAAAc,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAT,EAAA,UAAA,UAAA,IAAA,EAAA,EAEzBL,EAAA,CAAAc,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAT,EAAA,UAAA,QAAA,IAAA,EAAA,EAEzBL,EAAA,CAAAc,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAT,EAAA,UAAA,QAAA,IAAA,EAAA,EAGzBL,EAAA,CAAAc,EAAS,CAAE,KAAM,OAAQ,UAAW,WAAY,CAAC,CAAA,EAAAT,EAAA,UAAA,WAAA,IAAA,EAAA,EAEjDL,EAAA,CAAAc,EAAS,CAAE,KAAM,OAAQ,UAAW,WAAY,CAAC,CAAA,EAAAT,EAAA,UAAA,WAAA,IAAA,EAAA,EAEjDL,EAAA,CAAAc,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAT,EAAA,UAAA,KAAA,IAAA,EAAA,EAjB3B,EAAAL,EAAA,CAAAe,EAAc,cAAc,CAAA,EAAAV,CAAA,E"}
@@ -1,4 +1,5 @@
1
1
  import { LitElement, nothing, type TemplateResult } from "lit";
2
+ import "../../tokens/tokens.js";
2
3
  import "../heading/heading.js";
3
4
  import "../icons/close-icon.js";
4
5
  import "../icons/globe-icon.js";
@@ -1,19 +1,19 @@
1
- import{defineElement as e}from"../shared/define-element.js";import{tokens as t}from"../../tokens/tokens.js";import n from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../heading/heading.js";import"../paragraph/paragraph.js";import{ensembleCSS as r}from"../shared/ensemble.css.js";import"../icons/close-icon.js";import"../icons/globe-icon.js";import"../icons/guide-icon.js";import i from"./process-steps.css.js";import{LitElement as a,html as o,nothing as s}from"lit";import{property as c}from"lit/decorators.js";var l=class extends a{constructor(...e){super(...e),this.title=``,this.description=``,this.steps=[]}static{this.styles=[t,r,i]}_renderIcon(e){return e?typeof e==`string`?o`<img src="${e}" alt="" class="bd-processsteps-icon-img" />`:e:s}render(){return o`
1
+ import{defineElement as e}from"../shared/define-element.js";import"../../tokens/tokens.js";import t from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../heading/heading.js";import"../paragraph/paragraph.js";import{ensembleCSS as n}from"../shared/ensemble.css.js";import"../icons/close-icon.js";import"../icons/globe-icon.js";import"../icons/guide-icon.js";import r from"./process-steps.css.js";import{LitElement as i,html as a,nothing as o}from"lit";import{property as s}from"lit/decorators.js";var c=class extends i{constructor(...e){super(...e),this.title=``,this.description=``,this.steps=[]}static{this.styles=[n,r]}_renderIcon(e){return e?typeof e==`string`?a`<img src="${e}" alt="" class="bd-processsteps-icon-img" />`:e:o}render(){return a`
2
2
  <div class="bd-ensemble bd-processsteps-container">
3
- ${this.title?o`
3
+ ${this.title?a`
4
4
  <bd-h as="h2" color="inverse" class="bd-processsteps-title">
5
5
  <slot name="title">${this.title}</slot>
6
6
  </bd-h>
7
- `:s}
7
+ `:o}
8
8
 
9
- ${this.description?o`
9
+ ${this.description?a`
10
10
  <bd-p variant="regular" class="bd-processsteps-description">
11
11
  <slot name="description">${this.description}</slot>
12
12
  </bd-p>
13
- `:s}
13
+ `:o}
14
14
 
15
15
  <div class="bd-processsteps-grid">
16
- ${this.steps.map(e=>o`
16
+ ${this.steps.map(e=>a`
17
17
  <div class="bd-processsteps-step">
18
18
  <div class="bd-processsteps-divider"></div>
19
19
  <div class="bd-processsteps-icon-wrap">${this._renderIcon(e.icon)}</div>
@@ -25,5 +25,5 @@ import{defineElement as e}from"../shared/define-element.js";import{tokens as t}f
25
25
 
26
26
  <slot name="steps"></slot>
27
27
  </div>
28
- `}};n([c({type:String})],l.prototype,`title`,void 0),n([c({type:String})],l.prototype,`description`,void 0),n([c({type:Array})],l.prototype,`steps`,void 0),l=n([e(`bd-process-steps`)],l);
28
+ `}};t([s({type:String})],c.prototype,`title`,void 0),t([s({type:String})],c.prototype,`description`,void 0),t([s({type:Array})],c.prototype,`steps`,void 0),c=t([e(`bd-process-steps`)],c);
29
29
  //# sourceMappingURL=process-steps.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"process-steps.js","names":["processStepsCSS","_decorate","__decorate","process_steps_css_default","ProcessSteps","LitElement","_args","tokens","ensembleCSS","icon","nothing","step","property","defineElement"],"sources":["../../../../src/components/process-steps/process-steps.ts"],"sourcesContent":["import { LitElement, html, nothing, type TemplateResult } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\nimport { tokens } from \"#tokens/tokens.ts\";\nimport \"#components/heading/heading.ts\";\nimport \"#components/icons/close-icon.ts\";\nimport \"#components/icons/globe-icon.ts\";\nimport \"#components/icons/guide-icon.ts\";\nimport \"#components/paragraph/paragraph.ts\";\nimport processStepsCSS from \"./process-steps.css.ts\";\nimport { ensembleCSS } from \"#shared/ensemble.css.ts\";\n\ninterface ProcessStep {\n icon? : TemplateResult | string;\n title : string;\n description: string;\n}\n\n@defineElement(\"bd-process-steps\")\nclass ProcessSteps extends LitElement {\n static styles = [tokens, ensembleCSS, processStepsCSS];\n\n @property({ type: String })\n title = \"\";\n @property({ type: String })\n description = \"\";\n @property({ type: Array })\n steps: ProcessStep[] = []; // [{ icon: TemplateResult|String, title: String, description: String }]\n\n _renderIcon(icon: ProcessStep[\"icon\"]) {\n if (!icon) return nothing;\n if (typeof icon === \"string\") {\n return html`<img src=\"${icon}\" alt=\"\" class=\"bd-processsteps-icon-img\" />`;\n }\n return icon;\n }\n\n /* color=\"inverse\" on both headings, because this module paints its own dark\n surface: process-steps.css.ts fills the section with\n linear-gradient(160deg, --color-neutral-800, #0b1626) and sets\n color: --color-text-inverse on the container.\n\n That container colour never reached the headings. bd-h sets its own colour\n inside its shadow root, so an inherited value cannot win: measured on the\n dark gradient, every bd-h rendered rgb(21, 23, 25) -- near-black ink on a\n near-black surface, about 1.0:1 -- while bd-p beside it correctly used\n --color-text-muted-inverse at rgb(166, 173, 180) and stayed readable. The\n section title and all three step titles were effectively invisible; it is\n visible in a screenshot and was measured to confirm it.\n\n bd-h already exposes the colour role, and footer-links-group does exactly\n this on the footer's dark surface, so this is the module selecting the\n right configuration for the surface it chose -- not a change to bd-h. */\n render() {\n return html`\n <div class=\"bd-ensemble bd-processsteps-container\">\n ${this.title\n ? html`\n <bd-h as=\"h2\" color=\"inverse\" class=\"bd-processsteps-title\">\n <slot name=\"title\">${this.title}</slot>\n </bd-h>\n `\n : nothing}\n\n ${this.description\n ? html`\n <bd-p variant=\"regular\" class=\"bd-processsteps-description\">\n <slot name=\"description\">${this.description}</slot>\n </bd-p>\n `\n : nothing}\n\n <div class=\"bd-processsteps-grid\">\n ${this.steps.map(\n (step) => html`\n <div class=\"bd-processsteps-step\">\n <div class=\"bd-processsteps-divider\"></div>\n <div class=\"bd-processsteps-icon-wrap\">${this._renderIcon(step.icon)}</div>\n <bd-h as=\"h4\" color=\"inverse\" class=\"bd-processsteps-step-title\">${step.title}</bd-h>\n <bd-p variant=\"regular\" class=\"bd-processsteps-step-description\">${step.description}</bd-p>\n </div>\n `\n )}\n </div>\n\n <slot name=\"steps\"></slot>\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-process-steps\": ProcessSteps;\n }\n}"],"mappings":"A,shBAkBA,IACMI,EADN,cAC2BC,CAAW,C,8BAI5B,KAAA,MAAA,GAEM,KAAA,YAAA,GAES,KAAA,MAAA,CAAC,C,QAPR,KAAA,OAAA,CAACE,EAAQC,EAAaR,CAAe,C,CASrD,YAAY,EAA2B,CAKrC,OAJKS,EACD,OAAOA,GAAS,SACX,CAAI,aAAaA,EAAK,8CAExBA,EAJWC,CAKpB,CAkBA,QAAS,CACP,MAAO,EAAI;;UAEL,KAAK,MACH,CAAI;;qCAEqB,KAAK,MAAM;;cAGpCA,EAAQ;;UAEV,KAAK,YACH,CAAI;;2CAE2B,KAAK,YAAY;;cAGhDA,EAAQ;;;YAGR,KAAK,MAAM,IACV,GAAS,CAAI;;;yDAG+B,KAAK,YAAYC,EAAK,IAAI,EAAE;mFACFA,EAAK,MAAM;mFACXA,EAAK,YAAY;;aAG1F,EAAE;;;;;KAMV,CACF,EAnEGV,EAAA,CAAAW,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAR,EAAA,UAAA,QAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAW,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAR,EAAA,UAAA,cAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAW,EAAS,CAAE,KAAM,KAAM,CAAC,CAAA,EAAAR,EAAA,UAAA,QAAA,IAAA,EAAA,EAR1B,EAAAH,EAAA,CAAAY,EAAc,kBAAkB,CAAA,EAAAT,CAAA"}
1
+ {"version":3,"file":"process-steps.js","names":["processStepsCSS","_decorate","__decorate","process_steps_css_default","ProcessSteps","LitElement","_args","ensembleCSS","icon","nothing","step","property","defineElement"],"sources":["../../../../src/components/process-steps/process-steps.ts"],"sourcesContent":["import { LitElement, html, nothing, type TemplateResult } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\n// Installs the design tokens into document scope; see src/tokens/tokens.ts\nimport \"#tokens/tokens.ts\";\nimport \"#components/heading/heading.ts\";\nimport \"#components/icons/close-icon.ts\";\nimport \"#components/icons/globe-icon.ts\";\nimport \"#components/icons/guide-icon.ts\";\nimport \"#components/paragraph/paragraph.ts\";\nimport processStepsCSS from \"./process-steps.css.ts\";\nimport { ensembleCSS } from \"#shared/ensemble.css.ts\";\n\ninterface ProcessStep {\n icon? : TemplateResult | string;\n title : string;\n description: string;\n}\n\n@defineElement(\"bd-process-steps\")\nclass ProcessSteps extends LitElement {\n static styles = [ensembleCSS, processStepsCSS];\n\n @property({ type: String })\n title = \"\";\n @property({ type: String })\n description = \"\";\n @property({ type: Array })\n steps: ProcessStep[] = []; // [{ icon: TemplateResult|String, title: String, description: String }]\n\n _renderIcon(icon: ProcessStep[\"icon\"]) {\n if (!icon) return nothing;\n if (typeof icon === \"string\") {\n return html`<img src=\"${icon}\" alt=\"\" class=\"bd-processsteps-icon-img\" />`;\n }\n return icon;\n }\n\n /* color=\"inverse\" on both headings, because this module paints its own dark\n surface: process-steps.css.ts fills the section with\n linear-gradient(160deg, --color-neutral-800, #0b1626) and sets\n color: --color-text-inverse on the container.\n\n That container colour never reached the headings. bd-h sets its own colour\n inside its shadow root, so an inherited value cannot win: measured on the\n dark gradient, every bd-h rendered rgb(21, 23, 25) -- near-black ink on a\n near-black surface, about 1.0:1 -- while bd-p beside it correctly used\n --color-text-muted-inverse at rgb(166, 173, 180) and stayed readable. The\n section title and all three step titles were effectively invisible; it is\n visible in a screenshot and was measured to confirm it.\n\n bd-h already exposes the colour role, and footer-links-group does exactly\n this on the footer's dark surface, so this is the module selecting the\n right configuration for the surface it chose -- not a change to bd-h. */\n render() {\n return html`\n <div class=\"bd-ensemble bd-processsteps-container\">\n ${this.title\n ? html`\n <bd-h as=\"h2\" color=\"inverse\" class=\"bd-processsteps-title\">\n <slot name=\"title\">${this.title}</slot>\n </bd-h>\n `\n : nothing}\n\n ${this.description\n ? html`\n <bd-p variant=\"regular\" class=\"bd-processsteps-description\">\n <slot name=\"description\">${this.description}</slot>\n </bd-p>\n `\n : nothing}\n\n <div class=\"bd-processsteps-grid\">\n ${this.steps.map(\n (step) => html`\n <div class=\"bd-processsteps-step\">\n <div class=\"bd-processsteps-divider\"></div>\n <div class=\"bd-processsteps-icon-wrap\">${this._renderIcon(step.icon)}</div>\n <bd-h as=\"h4\" color=\"inverse\" class=\"bd-processsteps-step-title\">${step.title}</bd-h>\n <bd-p variant=\"regular\" class=\"bd-processsteps-step-description\">${step.description}</bd-p>\n </div>\n `\n )}\n </div>\n\n <slot name=\"steps\"></slot>\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-process-steps\": ProcessSteps;\n }\n}"],"mappings":"A,qgBAmBA,IACMI,EADN,cAC2BC,CAAW,C,8BAI5B,KAAA,MAAA,GAEM,KAAA,YAAA,GAES,KAAA,MAAA,CAAC,C,QAPR,KAAA,OAAA,CAACE,EAAaP,CAAe,C,CAS7C,YAAY,EAA2B,CAKrC,OAJKQ,EACD,OAAOA,GAAS,SACX,CAAI,aAAaA,EAAK,8CAExBA,EAJWC,CAKpB,CAkBA,QAAS,CACP,MAAO,EAAI;;UAEL,KAAK,MACH,CAAI;;qCAEqB,KAAK,MAAM;;cAGpCA,EAAQ;;UAEV,KAAK,YACH,CAAI;;2CAE2B,KAAK,YAAY;;cAGhDA,EAAQ;;;YAGR,KAAK,MAAM,IACV,GAAS,CAAI;;;yDAG+B,KAAK,YAAYC,EAAK,IAAI,EAAE;mFACFA,EAAK,MAAM;mFACXA,EAAK,YAAY;;aAG1F,EAAE;;;;;KAMV,CACF,EAnEGT,EAAA,CAAAU,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAP,EAAA,UAAA,QAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAU,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAP,EAAA,UAAA,cAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAU,EAAS,CAAE,KAAM,KAAM,CAAC,CAAA,EAAAP,EAAA,UAAA,QAAA,IAAA,EAAA,EAR1B,EAAAH,EAAA,CAAAW,EAAc,kBAAkB,CAAA,EAAAR,CAAA"}
@@ -1,4 +1,5 @@
1
1
  import { LitElement } from "lit";
2
+ import "../../tokens/tokens.js";
2
3
  import "../paragraph/paragraph.js";
3
4
  import "../divider/divider-horizontal.js";
4
5
  interface QuickAnswerItem {
@@ -1,10 +1,10 @@
1
- import{defineElement as e}from"../shared/define-element.js";import{tokens as t}from"../../tokens/tokens.js";import n from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../paragraph/paragraph.js";import"../divider/divider-horizontal.js";import r from"./quick-answer.css.js";import{LitElement as i,html as a,nothing as o}from"lit";import{property as s}from"lit/decorators.js";var c=class extends i{constructor(...e){super(...e),this.label=`Quick answer`,this.text=``,this.items=[]}static{this.styles=[t,r]}render(){return a`
1
+ import{defineElement as e}from"../shared/define-element.js";import"../../tokens/tokens.js";import t from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../paragraph/paragraph.js";import"../divider/divider-horizontal.js";import n from"./quick-answer.css.js";import{LitElement as r,html as i,nothing as a}from"lit";import{property as o}from"lit/decorators.js";var s=class extends r{constructor(...e){super(...e),this.label=`Quick answer`,this.text=``,this.items=[]}static{this.styles=[n]}render(){return i`
2
2
  <div class="bd-quickanswer-container">
3
- ${this.label?a`
3
+ ${this.label?i`
4
4
  <bd-p variant="regular" font-weight="medium" class="bd-quickanswer-label">
5
5
  <slot name="label">${this.label}</slot>
6
6
  </bd-p>
7
- `:o}
7
+ `:a}
8
8
 
9
9
  <bd-p variant="large" class="bd-quickanswer-text">
10
10
  <slot name="text">${this.text}</slot>
@@ -12,21 +12,21 @@ import{defineElement as e}from"../shared/define-element.js";import{tokens as t}f
12
12
 
13
13
  <slot></slot>
14
14
 
15
- ${this.items&&this.items.length?a`
15
+ ${this.items&&this.items.length?i`
16
16
  <bd-divider-horizontal
17
17
  class="bd-quickanswer-divider"
18
18
  color="brand-subtle"
19
19
  opacity="1"
20
20
  ></bd-divider-horizontal>
21
21
  <div class="bd-quickanswer-meta">
22
- ${this.items.map(e=>a`
22
+ ${this.items.map(e=>i`
23
23
  <span class="bd-quickanswer-meta-item">
24
24
  <span class="bd-quickanswer-meta-label">${e.label}</span>
25
25
  <span class="bd-quickanswer-meta-value">${e.value}</span>
26
26
  </span>
27
27
  `)}
28
28
  </div>
29
- `:o}
29
+ `:a}
30
30
  </div>
31
- `}};n([s({type:String})],c.prototype,`label`,void 0),n([s({type:String})],c.prototype,`text`,void 0),n([s({type:Array})],c.prototype,`items`,void 0),c=n([e(`bd-quick-answer`)],c);
31
+ `}};t([o({type:String})],s.prototype,`label`,void 0),t([o({type:String})],s.prototype,`text`,void 0),t([o({type:Array})],s.prototype,`items`,void 0),s=t([e(`bd-quick-answer`)],s);
32
32
  //# sourceMappingURL=quick-answer.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"quick-answer.js","names":["quickAnswerCSS","_decorate","__decorate","quick_answer_css_default","QuickAnswer","LitElement","_args","tokens","nothing","item","property","defineElement"],"sources":["../../../../src/components/quick-answer/quick-answer.ts"],"sourcesContent":["import { LitElement, html, nothing } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\nimport { tokens } from \"#tokens/tokens.ts\";\nimport \"#components/paragraph/paragraph.ts\";\nimport quickAnswerCSS from \"./quick-answer.css.ts\";\nimport \"#components/divider/divider-horizontal.ts\";\n\ninterface QuickAnswerItem {\n label: string;\n value: string;\n}\n\n@defineElement(\"bd-quick-answer\")\nclass QuickAnswer extends LitElement {\n static styles = [tokens, quickAnswerCSS];\n\n @property({ type: String })\n label = \"Quick answer\";\n @property({ type: String })\n text = \"\";\n @property({ type: Array })\n items: QuickAnswerItem[] = []; // [{ label: String, value: String }]\n\n render() {\n return html`\n <div class=\"bd-quickanswer-container\">\n ${this.label\n ? html`\n <bd-p variant=\"regular\" font-weight=\"medium\" class=\"bd-quickanswer-label\">\n <slot name=\"label\">${this.label}</slot>\n </bd-p>\n `\n : nothing}\n\n <bd-p variant=\"large\" class=\"bd-quickanswer-text\">\n <slot name=\"text\">${this.text}</slot>\n </bd-p>\n\n <slot></slot>\n\n ${this.items && this.items.length\n ? html`\n <bd-divider-horizontal\n class=\"bd-quickanswer-divider\"\n color=\"brand-subtle\"\n opacity=\"1\"\n ></bd-divider-horizontal>\n <div class=\"bd-quickanswer-meta\">\n ${this.items.map(\n (item) => html`\n <span class=\"bd-quickanswer-meta-item\">\n <span class=\"bd-quickanswer-meta-label\">${item.label}</span>\n <span class=\"bd-quickanswer-meta-value\">${item.value}</span>\n </span>\n `\n )}\n </div>\n `\n : nothing}\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-quick-answer\": QuickAnswer;\n }\n}"],"mappings":"A,2YAaA,IACMI,EADN,cAC0BC,CAAW,C,8BAI3B,KAAA,MAAA,eAED,KAAA,KAAA,GAEoB,KAAA,MAAA,CAAC,C,QAPZ,KAAA,OAAA,CAACE,EAAQP,CAAc,C,CASvC,QAAS,CACP,MAAO,EAAI;;UAEL,KAAK,MACH,CAAI;;qCAEqB,KAAK,MAAM;;cAGpCQ,EAAQ;;;8BAGU,KAAK,KAAK;;;;;UAK9B,KAAK,OAAS,KAAK,MAAM,OACvB,CAAI;;;;;;;kBAOE,KAAK,MAAM,IACV,GAAS,CAAI;;gEAEgCC,EAAK,MAAM;gEACXA,EAAK,MAAM;;mBAG3D,EAAE;;cAGND,EAAQ;;KAGlB,CACF,EA9CGP,EAAA,CAAAS,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAN,EAAA,UAAA,QAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAS,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAN,EAAA,UAAA,OAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAS,EAAS,CAAE,KAAM,KAAM,CAAC,CAAA,EAAAN,EAAA,UAAA,QAAA,IAAA,EAAA,EAR1B,EAAAH,EAAA,CAAAU,EAAc,iBAAiB,CAAA,EAAAP,CAAA"}
1
+ {"version":3,"file":"quick-answer.js","names":["quickAnswerCSS","_decorate","__decorate","quick_answer_css_default","QuickAnswer","LitElement","_args","nothing","item","property","defineElement"],"sources":["../../../../src/components/quick-answer/quick-answer.ts"],"sourcesContent":["import { LitElement, html, nothing } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\n// Installs the design tokens into document scope; see src/tokens/tokens.ts\nimport \"#tokens/tokens.ts\";\nimport \"#components/paragraph/paragraph.ts\";\nimport quickAnswerCSS from \"./quick-answer.css.ts\";\nimport \"#components/divider/divider-horizontal.ts\";\n\ninterface QuickAnswerItem {\n label: string;\n value: string;\n}\n\n@defineElement(\"bd-quick-answer\")\nclass QuickAnswer extends LitElement {\n static styles = [quickAnswerCSS];\n\n @property({ type: String })\n label = \"Quick answer\";\n @property({ type: String })\n text = \"\";\n @property({ type: Array })\n items: QuickAnswerItem[] = []; // [{ label: String, value: String }]\n\n render() {\n return html`\n <div class=\"bd-quickanswer-container\">\n ${this.label\n ? html`\n <bd-p variant=\"regular\" font-weight=\"medium\" class=\"bd-quickanswer-label\">\n <slot name=\"label\">${this.label}</slot>\n </bd-p>\n `\n : nothing}\n\n <bd-p variant=\"large\" class=\"bd-quickanswer-text\">\n <slot name=\"text\">${this.text}</slot>\n </bd-p>\n\n <slot></slot>\n\n ${this.items && this.items.length\n ? html`\n <bd-divider-horizontal\n class=\"bd-quickanswer-divider\"\n color=\"brand-subtle\"\n opacity=\"1\"\n ></bd-divider-horizontal>\n <div class=\"bd-quickanswer-meta\">\n ${this.items.map(\n (item) => html`\n <span class=\"bd-quickanswer-meta-item\">\n <span class=\"bd-quickanswer-meta-label\">${item.label}</span>\n <span class=\"bd-quickanswer-meta-value\">${item.value}</span>\n </span>\n `\n )}\n </div>\n `\n : nothing}\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-quick-answer\": QuickAnswer;\n }\n}"],"mappings":"A,0XAcA,IACMI,EADN,cAC0BC,CAAW,C,8BAI3B,KAAA,MAAA,eAED,KAAA,KAAA,GAEoB,KAAA,MAAA,CAAC,C,QAPZ,KAAA,OAAA,CAACL,CAAc,C,CAS/B,QAAS,CACP,MAAO,EAAI;;UAEL,KAAK,MACH,CAAI;;qCAEqB,KAAK,MAAM;;cAGpCO,EAAQ;;;8BAGU,KAAK,KAAK;;;;;UAK9B,KAAK,OAAS,KAAK,MAAM,OACvB,CAAI;;;;;;;kBAOE,KAAK,MAAM,IACV,GAAS,CAAI;;gEAEgCC,EAAK,MAAM;gEACXA,EAAK,MAAM;;mBAG3D,EAAE;;cAGND,EAAQ;;KAGlB,CACF,EA9CGN,EAAA,CAAAQ,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAL,EAAA,UAAA,QAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAQ,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAL,EAAA,UAAA,OAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAQ,EAAS,CAAE,KAAM,KAAM,CAAC,CAAA,EAAAL,EAAA,UAAA,QAAA,IAAA,EAAA,EAR1B,EAAAH,EAAA,CAAAS,EAAc,iBAAiB,CAAA,EAAAN,CAAA"}
@@ -1,4 +1,5 @@
1
1
  import { LitElement } from "lit";
2
+ import "../../tokens/tokens.js";
2
3
  import "../heading/heading.js";
3
4
  import "./review.js";
4
5
  declare class BdReviewGrid extends LitElement {
@@ -1,6 +1,6 @@
1
- import{defineElement as e}from"../shared/define-element.js";import{tokens as t}from"../../tokens/tokens.js";import n from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../heading/heading.js";import{ensembleCSS as r}from"../shared/ensemble.css.js";import i from"./review-grid.css.js";import"./review.js";import{LitElement as a,html as o,nothing as s}from"lit";import{property as c,state as l}from"lit/decorators.js";var u=class extends a{constructor(...e){super(...e),this.title=``,this._columns=3}static{this.styles=[t,r,i]}get _items(){return[...this.children].filter(e=>e.tagName===`BD-REVIEW`)}_onSlotChange(){let e=this._items.length;this._columns=e<=0?1:Math.min(e,3)}render(){let e=this._columns===1;return o`
1
+ import{defineElement as e}from"../shared/define-element.js";import"../../tokens/tokens.js";import t from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../heading/heading.js";import{ensembleCSS as n}from"../shared/ensemble.css.js";import r from"./review-grid.css.js";import"./review.js";import{LitElement as i,html as a,nothing as o}from"lit";import{property as s,state as c}from"lit/decorators.js";var l=class extends i{constructor(...e){super(...e),this.title=``,this._columns=3}static{this.styles=[n,r]}get _items(){return[...this.children].filter(e=>e.tagName===`BD-REVIEW`)}_onSlotChange(){let e=this._items.length;this._columns=e<=0?1:Math.min(e,3)}render(){let e=this._columns===1;return a`
2
2
  <div class="bd-ensemble">
3
- ${this.title?o`<bd-h as="h2" class="bd-reviewgrid-title"><slot name="title">${this.title}</slot></bd-h>`:s}
3
+ ${this.title?a`<bd-h as="h2" class="bd-reviewgrid-title"><slot name="title">${this.title}</slot></bd-h>`:o}
4
4
 
5
5
  <div
6
6
  class="bd-reviewgrid-grid ${e?`bd-reviewgrid-grid--single`:``}"
@@ -10,5 +10,5 @@ import{defineElement as e}from"../shared/define-element.js";import{tokens as t}f
10
10
  <slot @slotchange=${this._onSlotChange}></slot>
11
11
  </div>
12
12
  </div>
13
- `}};n([c({type:String})],u.prototype,`title`,void 0),n([l()],u.prototype,`_columns`,void 0),u=n([e(`bd-review-grid`)],u);
13
+ `}};t([s({type:String})],l.prototype,`title`,void 0),t([c()],l.prototype,`_columns`,void 0),l=t([e(`bd-review-grid`)],l);
14
14
  //# sourceMappingURL=review-grid.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"review-grid.js","names":["reviewGridCSS","_decorate","__decorate","review_grid_css_default","BdReviewGrid","LitElement","_args","tokens","ensembleCSS","el","count","singleCard","nothing","property","state","defineElement"],"sources":["../../../../src/components/review/review-grid.ts"],"sourcesContent":["import { LitElement, html, nothing } from \"lit\";\nimport { property, state } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\nimport { tokens } from \"#tokens/tokens.ts\";\nimport \"#components/heading/heading.ts\";\nimport reviewGridCSS from \"./review-grid.css.ts\";\nimport { ensembleCSS } from \"#shared/ensemble.css.ts\";\nimport \"./review.ts\";\n\n\n@defineElement(\"bd-review-grid\")\nclass BdReviewGrid extends LitElement {\n static styles = [tokens, ensembleCSS, reviewGridCSS];\n\n @property({ type: String })\n title = \"\";\n @state()\n _columns = 3;\n\n get _items() {\n return [...this.children].filter((el) => el.tagName === \"BD-REVIEW\");\n }\n\n /* The grid is a list (role=\"list\" below), and each bd-review in it says it\n is one of its items itself (review.ts). */\n _onSlotChange() {\n const count = this._items.length;\n this._columns = count <= 0 ? 1 : Math.min(count, 3);\n }\n\n render() {\n const singleCard = this._columns === 1;\n\n return html`\n <div class=\"bd-ensemble\">\n ${this.title\n ? html`<bd-h as=\"h2\" class=\"bd-reviewgrid-title\"><slot name=\"title\">${this.title}</slot></bd-h>`\n : nothing}\n\n <div\n class=\"bd-reviewgrid-grid ${singleCard ? \"bd-reviewgrid-grid--single\" : \"\"}\"\n style=\"--bd-review-columns: ${this._columns};\"\n role=\"list\"\n >\n <slot @slotchange=${this._onSlotChange}></slot>\n </div>\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-review-grid\": BdReviewGrid;\n }\n}"],"mappings":"A,obAUA,IACMI,EADN,cAC2BC,CAAW,C,8BAI5B,KAAA,MAAA,GAEG,KAAA,SAAA,C,QALK,KAAA,OAAA,CAACE,EAAQC,EAAaR,CAAa,C,CAOnD,IAAI,QAAS,CACX,MAAO,CAAC,GAAG,KAAK,QAAQ,CAAC,CAAC,OAAQ,GAAOS,EAAG,UAAY,WAAW,CACrE,CAIA,eAAgB,CACd,IAAMC,EAAQ,KAAK,OAAO,OAC1B,KAAK,SAAWA,GAAS,EAAI,EAAI,KAAK,IAAIA,EAAO,CAAC,CACpD,CAEA,QAAS,CACP,IAAMC,EAAa,KAAK,WAAa,EAErC,MAAO,EAAI;;UAEL,KAAK,MACH,CAAI,gEAAgE,KAAK,MAAM,gBAC/EC,EAAQ;;;sCAGkBD,EAAa,6BAA+B,GAAG;wCAC7C,KAAK,SAAS;;;8BAGxB,KAAK,cAAc;;;KAI/C,CACF,EAnCGV,EAAA,CAAAY,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAT,EAAA,UAAA,QAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAa,EAAM,CAAA,EAAAV,EAAA,UAAA,WAAA,IAAA,EAAA,EANR,EAAAH,EAAA,CAAAc,EAAc,gBAAgB,CAAA,EAAAX,CAAA"}
1
+ {"version":3,"file":"review-grid.js","names":["reviewGridCSS","_decorate","__decorate","review_grid_css_default","BdReviewGrid","LitElement","_args","ensembleCSS","el","count","singleCard","nothing","property","state","defineElement"],"sources":["../../../../src/components/review/review-grid.ts"],"sourcesContent":["import { LitElement, html, nothing } from \"lit\";\nimport { property, state } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\n// Installs the design tokens into document scope; see src/tokens/tokens.ts\nimport \"#tokens/tokens.ts\";\nimport \"#components/heading/heading.ts\";\nimport reviewGridCSS from \"./review-grid.css.ts\";\nimport { ensembleCSS } from \"#shared/ensemble.css.ts\";\nimport \"./review.ts\";\n\n\n@defineElement(\"bd-review-grid\")\nclass BdReviewGrid extends LitElement {\n static styles = [ensembleCSS, reviewGridCSS];\n\n @property({ type: String })\n title = \"\";\n @state()\n _columns = 3;\n\n get _items() {\n return [...this.children].filter((el) => el.tagName === \"BD-REVIEW\");\n }\n\n /* The grid is a list (role=\"list\" below), and each bd-review in it says it\n is one of its items itself (review.ts). */\n _onSlotChange() {\n const count = this._items.length;\n this._columns = count <= 0 ? 1 : Math.min(count, 3);\n }\n\n render() {\n const singleCard = this._columns === 1;\n\n return html`\n <div class=\"bd-ensemble\">\n ${this.title\n ? html`<bd-h as=\"h2\" class=\"bd-reviewgrid-title\"><slot name=\"title\">${this.title}</slot></bd-h>`\n : nothing}\n\n <div\n class=\"bd-reviewgrid-grid ${singleCard ? \"bd-reviewgrid-grid--single\" : \"\"}\"\n style=\"--bd-review-columns: ${this._columns};\"\n role=\"list\"\n >\n <slot @slotchange=${this._onSlotChange}></slot>\n </div>\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-review-grid\": BdReviewGrid;\n }\n}"],"mappings":"A,maAWA,IACMI,EADN,cAC2BC,CAAW,C,8BAI5B,KAAA,MAAA,GAEG,KAAA,SAAA,C,QALK,KAAA,OAAA,CAACE,EAAaP,CAAa,C,CAO3C,IAAI,QAAS,CACX,MAAO,CAAC,GAAG,KAAK,QAAQ,CAAC,CAAC,OAAQ,GAAOQ,EAAG,UAAY,WAAW,CACrE,CAIA,eAAgB,CACd,IAAMC,EAAQ,KAAK,OAAO,OAC1B,KAAK,SAAWA,GAAS,EAAI,EAAI,KAAK,IAAIA,EAAO,CAAC,CACpD,CAEA,QAAS,CACP,IAAMC,EAAa,KAAK,WAAa,EAErC,MAAO,EAAI;;UAEL,KAAK,MACH,CAAI,gEAAgE,KAAK,MAAM,gBAC/EC,EAAQ;;;sCAGkBD,EAAa,6BAA+B,GAAG;wCAC7C,KAAK,SAAS;;;8BAGxB,KAAK,cAAc;;;KAI/C,CACF,EAnCGT,EAAA,CAAAW,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAR,EAAA,UAAA,QAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAY,EAAM,CAAA,EAAAT,EAAA,UAAA,WAAA,IAAA,EAAA,EANR,EAAAH,EAAA,CAAAa,EAAc,gBAAgB,CAAA,EAAAV,CAAA"}
@@ -1,4 +1,5 @@
1
1
  import { LitElement } from "lit";
2
+ import "../../tokens/tokens.js";
2
3
  import "../icons/quote-icon.js";
3
4
  import "../paragraph/paragraph.js";
4
5
  type Variant = "tint" | "neutral";
@@ -1,4 +1,4 @@
1
- import{defineElement as e}from"../shared/define-element.js";import{tokens as t}from"../../tokens/tokens.js";import n from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../paragraph/paragraph.js";import"../icons/quote-icon.js";import r from"./review.css.js";import{LitElement as i,html as a}from"lit";import{property as o}from"lit/decorators.js";var s=class extends i{static{this.styles=[t,r]}constructor(){super(),this.variant=`tint`,this._internals=this.attachInternals()}connectedCallback(){super.connectedCallback(),this._internals.role=this.parentElement?.localName===`bd-review-grid`?`listitem`:null}render(){return a`
1
+ import{defineElement as e}from"../shared/define-element.js";import"../../tokens/tokens.js";import t from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../paragraph/paragraph.js";import"../icons/quote-icon.js";import n from"./review.css.js";import{LitElement as r,html as i}from"lit";import{property as a}from"lit/decorators.js";var o=class extends r{static{this.styles=[n]}constructor(){super(),this.variant=`tint`,this._internals=this.attachInternals()}connectedCallback(){super.connectedCallback(),this._internals.role=this.parentElement?.localName===`bd-review-grid`?`listitem`:null}render(){return i`
2
2
  <div class="bd-review-card">
3
3
  <bd-quote-icon class="bd-review-mark" size="xl"></bd-quote-icon>
4
4
 
@@ -11,5 +11,5 @@ import{defineElement as e}from"../shared/define-element.js";import{tokens as t}f
11
11
  <span class="bd-review-date"><slot name="date"></slot></span>
12
12
  </div>
13
13
  </div>
14
- `}};n([o({type:String,reflect:!0})],s.prototype,`variant`,void 0),s=n([e(`bd-review`)],s);
14
+ `}};t([a({type:String,reflect:!0})],o.prototype,`variant`,void 0),o=t([e(`bd-review`)],o);
15
15
  //# sourceMappingURL=review.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"review.js","names":["reviewCSS","_decorate","__decorate","review_css_default","BdReview","LitElement","tokens","property","defineElement"],"sources":["../../../../src/components/review/review.ts"],"sourcesContent":["import { LitElement, html } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\nimport { tokens } from \"#tokens/tokens.ts\";\nimport \"#components/icons/quote-icon.ts\";\nimport \"#components/paragraph/paragraph.ts\";\nimport reviewCSS from \"./review.css.ts\";\n\ntype Variant = \"tint\" | \"neutral\";\n\n/**\n * A single testimonial/review card. Everything is slotted rather than\n * passed as props, so callers can put arbitrary markup (a bd-p, a link,\n * bold text) in any of the three slots:\n *\n * <bd-review variant=\"tint\">\n * <span slot=\"quote\">If you're looking to buy a security suite...</span>\n * <span slot=\"source\">PCMag</span>\n * <span slot=\"date\">February 3, 2026</span>\n * </bd-review>\n *\n * `variant` is the only prop, since it's an appearance switch (background\n * colour), not content:\n * \"tint\" — the brand's lightest wash (--status-brand-surface), so it\n * follows the business line's brand\n * \"neutral\" — a container ground (--color-surface-container)\n */\n\n@defineElement(\"bd-review\")\nclass BdReview extends LitElement {\n static styles = [tokens, reviewCSS];\n\n @property({ type: String, reflect: true })\n variant: Variant = \"tint\"; // \"tint\" | \"neutral\"\n\n _internals: ElementInternals;\n\n constructor() {\n super();\n this._internals = this.attachInternals();\n }\n\n /* In a bd-review-grid, a review is one item of the grid's list -- a list\n whose children are not list items is announced as an empty list, or not\n at all (axe: aria-required-children). The role is the element's own,\n through ElementInternals, as bd-breadcrumb-item's is: the grid used to\n write role=\"listitem\" onto the page's markup, where it stayed after the\n review left the list. A role the page writes on the element still wins,\n and outside a grid a review is no item of anything. */\n connectedCallback() {\n super.connectedCallback();\n this._internals.role = this.parentElement?.localName === \"bd-review-grid\" ? \"listitem\" : null;\n }\n\n render() {\n return html`\n <div class=\"bd-review-card\">\n <bd-quote-icon class=\"bd-review-mark\" size=\"xl\"></bd-quote-icon>\n\n <bd-p variant=\"regular\" class=\"bd-review-quote\">\n <slot name=\"quote\"></slot>\n </bd-p>\n\n <div class=\"bd-review-meta\">\n <bd-p variant=\"small\" font-weight=\"bold\" class=\"bd-review-source\"><slot name=\"source\"></slot></bd-p>\n <span class=\"bd-review-date\"><slot name=\"date\"></slot></span>\n </div>\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-review\": BdReview;\n }\n}"],"mappings":"A,8WA4BA,IACMI,EADN,cACuBC,CAAW,C,OAChB,KAAA,OAAA,CAACC,EAAQN,CAAS,C,CAOlC,aAAc,CACZ,MAAM,EALW,KAAA,QAAA,OAMjB,KAAK,WAAa,KAAK,gBAAgB,CACzC,CASA,mBAAoB,CAClB,MAAM,kBAAkB,EACxB,KAAK,WAAW,KAAO,KAAK,eAAe,YAAc,iBAAmB,WAAa,IAC3F,CAEA,QAAS,CACP,MAAO,EAAI;;;;;;;;;;;;;KAcb,CACF,EAtCGC,EAAA,CAAAM,EAAS,CAAE,KAAM,OAAQ,QAAS,EAAK,CAAC,CAAA,EAAAH,EAAA,UAAA,UAAA,IAAA,EAAA,EAJ1C,EAAAH,EAAA,CAAAO,EAAc,WAAW,CAAA,EAAAJ,CAAA"}
1
+ {"version":3,"file":"review.js","names":["reviewCSS","_decorate","__decorate","review_css_default","BdReview","LitElement","property","defineElement"],"sources":["../../../../src/components/review/review.ts"],"sourcesContent":["import { LitElement, html } from \"lit\";\nimport { property } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\n// Installs the design tokens into document scope; see src/tokens/tokens.ts\nimport \"#tokens/tokens.ts\";\nimport \"#components/icons/quote-icon.ts\";\nimport \"#components/paragraph/paragraph.ts\";\nimport reviewCSS from \"./review.css.ts\";\n\ntype Variant = \"tint\" | \"neutral\";\n\n/**\n * A single testimonial/review card. Everything is slotted rather than\n * passed as props, so callers can put arbitrary markup (a bd-p, a link,\n * bold text) in any of the three slots:\n *\n * <bd-review variant=\"tint\">\n * <span slot=\"quote\">If you're looking to buy a security suite...</span>\n * <span slot=\"source\">PCMag</span>\n * <span slot=\"date\">February 3, 2026</span>\n * </bd-review>\n *\n * `variant` is the only prop, since it's an appearance switch (background\n * colour), not content:\n * \"tint\" — the brand's lightest wash (--status-brand-surface), so it\n * follows the business line's brand\n * \"neutral\" — a container ground (--color-surface-container)\n */\n\n@defineElement(\"bd-review\")\nclass BdReview extends LitElement {\n static styles = [reviewCSS];\n\n @property({ type: String, reflect: true })\n variant: Variant = \"tint\"; // \"tint\" | \"neutral\"\n\n _internals: ElementInternals;\n\n constructor() {\n super();\n this._internals = this.attachInternals();\n }\n\n /* In a bd-review-grid, a review is one item of the grid's list -- a list\n whose children are not list items is announced as an empty list, or not\n at all (axe: aria-required-children). The role is the element's own,\n through ElementInternals, as bd-breadcrumb-item's is: the grid used to\n write role=\"listitem\" onto the page's markup, where it stayed after the\n review left the list. A role the page writes on the element still wins,\n and outside a grid a review is no item of anything. */\n connectedCallback() {\n super.connectedCallback();\n this._internals.role = this.parentElement?.localName === \"bd-review-grid\" ? \"listitem\" : null;\n }\n\n render() {\n return html`\n <div class=\"bd-review-card\">\n <bd-quote-icon class=\"bd-review-mark\" size=\"xl\"></bd-quote-icon>\n\n <bd-p variant=\"regular\" class=\"bd-review-quote\">\n <slot name=\"quote\"></slot>\n </bd-p>\n\n <div class=\"bd-review-meta\">\n <bd-p variant=\"small\" font-weight=\"bold\" class=\"bd-review-source\"><slot name=\"source\"></slot></bd-p>\n <span class=\"bd-review-date\"><slot name=\"date\"></slot></span>\n </div>\n </div>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-review\": BdReview;\n }\n}"],"mappings":"A,6VA6BA,IACMI,EADN,cACuBC,CAAW,C,OAChB,KAAA,OAAA,CAACL,CAAS,C,CAO1B,aAAc,CACZ,MAAM,EALW,KAAA,QAAA,OAMjB,KAAK,WAAa,KAAK,gBAAgB,CACzC,CASA,mBAAoB,CAClB,MAAM,kBAAkB,EACxB,KAAK,WAAW,KAAO,KAAK,eAAe,YAAc,iBAAmB,WAAa,IAC3F,CAEA,QAAS,CACP,MAAO,EAAI;;;;;;;;;;;;;KAcb,CACF,EAtCGC,EAAA,CAAAK,EAAS,CAAE,KAAM,OAAQ,QAAS,EAAK,CAAC,CAAA,EAAAF,EAAA,UAAA,UAAA,IAAA,EAAA,EAJ1C,EAAAH,EAAA,CAAAM,EAAc,WAAW,CAAA,EAAAH,CAAA"}
@@ -1,4 +1,5 @@
1
1
  import { LitElement, type PropertyValues } from "lit";
2
+ import "../../tokens/tokens.js";
2
3
  import "../heading/heading.js";
3
4
  import "../paragraph/paragraph.js";
4
5
  declare const LAYOUTS: readonly ["stacked", "split", "centered"];
@@ -1,12 +1,12 @@
1
- import{defineElement as e}from"../shared/define-element.js";import{tokens as t}from"../../tokens/tokens.js";import n from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../heading/heading.js";import{resolveEnum as r}from"../shared/prop-vocabulary.js";import"../paragraph/paragraph.js";import{ensembleCSS as i}from"../shared/ensemble.css.js";import{sectionHeaderCSS as a}from"./section-header.css.js";import{LitElement as o,html as s,nothing as c}from"lit";import{property as l,state as u}from"lit/decorators.js";var d=[`stacked`,`split`,`centered`],f=class extends o{constructor(...e){super(...e),this.eyebrow=``,this.heading=``,this.lead=``,this.as=`h2`,this.layout=`stacked`,this._hasLead=!1}static{this.styles=[t,i,a]}willUpdate(e){e.has(`layout`)&&(this.layout=r(this.layout,{allowed:d,fallback:`stacked`}))}_onLeadSlot(e){this._hasLead=e.target.assignedNodes({flatten:!0}).some(e=>e.nodeType===Node.ELEMENT_NODE||e.textContent.trim())}render(){let e=this.lead||this._hasLead;return s`
1
+ import{defineElement as e}from"../shared/define-element.js";import"../../tokens/tokens.js";import t from"../../_bundled/oxc-project_runtime/helpers/esm/decorate.js";import"../heading/heading.js";import{resolveEnum as n}from"../shared/prop-vocabulary.js";import"../paragraph/paragraph.js";import{ensembleCSS as r}from"../shared/ensemble.css.js";import{sectionHeaderCSS as i}from"./section-header.css.js";import{LitElement as a,html as o,nothing as s}from"lit";import{property as c,state as l}from"lit/decorators.js";var u=[`stacked`,`split`,`centered`],d=class extends a{constructor(...e){super(...e),this.eyebrow=``,this.heading=``,this.lead=``,this.as=`h2`,this.layout=`stacked`,this._hasLead=!1}static{this.styles=[r,i]}willUpdate(e){e.has(`layout`)&&(this.layout=n(this.layout,{allowed:u,fallback:`stacked`}))}_onLeadSlot(e){this._hasLead=e.target.assignedNodes({flatten:!0}).some(e=>e.nodeType===Node.ELEMENT_NODE||e.textContent.trim())}render(){let e=this.lead||this._hasLead;return o`
2
2
  <header class="bd-ensemble root">
3
- ${this.eyebrow?s`<bd-p variant="eyebrow" class="eyebrow"><span class="text">${this.eyebrow}</span></bd-p>`:c}
3
+ ${this.eyebrow?o`<bd-p variant="eyebrow" class="eyebrow"><span class="text">${this.eyebrow}</span></bd-p>`:s}
4
4
  <div class="row">
5
- <bd-h as="${this.as}" visual-level="h2" class="heading"><span class="text">${this.heading}</span></bd-h>
5
+ ${this.heading?o`<bd-h as="${this.as}" visual-level="h2" class="heading"><span class="text">${this.heading}</span></bd-h>`:s}
6
6
  <div class="lead" ?hidden=${!e}>
7
7
  <slot name="lead" @slotchange=${this._onLeadSlot}><span class="text">${this.lead}</span></slot>
8
8
  </div>
9
9
  </div>
10
10
  </header>
11
- `}};n([l({type:String})],f.prototype,`eyebrow`,void 0),n([l({type:String})],f.prototype,`heading`,void 0),n([l({type:String})],f.prototype,`lead`,void 0),n([l({type:String})],f.prototype,`as`,void 0),n([l({type:String,reflect:!0})],f.prototype,`layout`,void 0),n([u()],f.prototype,`_hasLead`,void 0),f=n([e(`bd-section-header`)],f);export{f as SectionHeader};
11
+ `}};t([c({type:String})],d.prototype,`eyebrow`,void 0),t([c({type:String})],d.prototype,`heading`,void 0),t([c({type:String})],d.prototype,`lead`,void 0),t([c({type:String})],d.prototype,`as`,void 0),t([c({type:String,reflect:!0})],d.prototype,`layout`,void 0),t([l()],d.prototype,`_hasLead`,void 0),d=t([e(`bd-section-header`)],d);export{d as SectionHeader};
12
12
  //# sourceMappingURL=section-header.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"section-header.js","names":["_decorate","__decorate","LAYOUTS","SectionHeader","LitElement","_args","tokens","ensembleCSS","sectionHeaderCSS","changed","resolveEnum","n","showLead","nothing","property","state","defineElement"],"sources":["../../../../src/components/section-header/section-header.ts"],"sourcesContent":["import { LitElement, html, nothing, type PropertyValues } from \"lit\";\nimport { property, state } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\nimport { tokens } from \"#tokens/tokens.ts\";\nimport \"#components/heading/heading.ts\";\nimport \"#components/paragraph/paragraph.ts\";\nimport { resolveEnum } from \"#shared/prop-vocabulary.ts\";\nimport { ensembleCSS } from \"#shared/ensemble.css.ts\";\nimport { sectionHeaderCSS } from \"./section-header.css.ts\";\n\nconst LAYOUTS = [\"stacked\", \"split\", \"centered\"] as const;\n\ntype Layout = typeof LAYOUTS[number];\ntype HeadingTag = \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\";\n\n/**\n * The header that opens a page section: an eyebrow, the section's h2 and a\n * lead. The homepage opens five sections with it -- AI, Why trust, Proven,\n * Insights and the solution splitter -- where each module used to spell its\n * own (bd-overview, bd-bento-grid, bd-trust-panel). Drawn in the foundation\n * Figma file as Section header.\n *\n * layout=\"split\" puts the headline and lead side by side from lg; below lg,\n * and in \"stacked\", everything stacks. layout=\"centered\" centres the three on\n * a narrower measure. Leave eyebrow and lead out for a title-only header.\n *\n * The lead is an attribute for plain copy, or the `lead` slot when it carries\n * a link -- `<bd-link inline underline>`, since colour alone measures 2.91:1\n * against the body text and fails WCAG 1.4.1. Slotted copy takes the lead's\n * role from here, so the page writes words, not typography.\n */\n@defineElement(\"bd-section-header\")\nexport class SectionHeader extends LitElement {\n static styles = [tokens, ensembleCSS, sectionHeaderCSS];\n\n @property({ type: String })\n eyebrow = \"\";\n @property({ type: String })\n heading = \"\";\n @property({ type: String })\n lead = \"\";\n // a page section's title: the outline is the page's, so it can say otherwise\n @property({ type: String })\n as: HeadingTag = \"h2\";\n @property({ type: String, reflect: true })\n layout: Layout = \"stacked\";\n @state()\n _hasLead = false;\n\n willUpdate(changed: PropertyValues<this>) {\n if (changed.has(\"layout\")) {\n this.layout = resolveEnum(this.layout, { allowed: LAYOUTS, fallback: \"stacked\" });\n }\n }\n\n _onLeadSlot(e: Event) {\n this._hasLead = (e.target as HTMLSlotElement).assignedNodes({ flatten: true })\n .some(n => n.nodeType === Node.ELEMENT_NODE || n.textContent!.trim());\n }\n\n render() {\n const showLead = this.lead || this._hasLead;\n return html`\n <header class=\"bd-ensemble root\">\n ${this.eyebrow\n ? html`<bd-p variant=\"eyebrow\" class=\"eyebrow\"><span class=\"text\">${this.eyebrow}</span></bd-p>`\n : nothing}\n <div class=\"row\">\n <bd-h as=\"${this.as}\" visual-level=\"h2\" class=\"heading\"><span class=\"text\">${this.heading}</span></bd-h>\n <div class=\"lead\" ?hidden=${!showLead}>\n <slot name=\"lead\" @slotchange=${this._onLeadSlot}><span class=\"text\">${this.lead}</span></slot>\n </div>\n </div>\n </header>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-section-header\": SectionHeader;\n }\n}\n"],"mappings":"A,ohBAUA,IAAME,EAAU,CAAC,UAAW,QAAS,UAAU,EAsBlCC,EAAN,cAA4BC,CAAW,C,8BAIlC,KAAA,QAAA,GAEA,KAAA,QAAA,GAEH,KAAA,KAAA,GAGU,KAAA,GAAA,KAEA,KAAA,OAAA,UAEN,KAAA,SAAA,E,QAdK,KAAA,OAAA,CAACE,EAAQC,EAAaC,CAAgB,C,CAgBtD,WAAW,EAA+B,CACpCC,EAAQ,IAAI,QAAQ,IACtB,KAAK,OAASC,EAAY,KAAK,OAAQ,CAAE,QAASR,EAAS,SAAU,SAAU,CAAC,EAEpF,CAEA,YAAY,EAAU,CACpB,KAAK,SAAY,EAAE,OAA2B,cAAc,CAAE,QAAS,EAAK,CAAC,CAAC,CAC3E,KAAK,GAAKS,EAAE,WAAa,KAAK,cAAgBA,EAAE,YAAa,KAAK,CAAC,CACxE,CAEA,QAAS,CACP,IAAMC,EAAW,KAAK,MAAQ,KAAK,SACnC,MAAO,EAAI;;UAEL,KAAK,QACH,CAAI,8DAA8D,KAAK,QAAQ,gBAC/EC,EAAQ;;sBAEE,KAAK,GAAG,yDAAyD,KAAK,QAAQ;sCAC9D,CAACD,EAAS;4CACJ,KAAK,YAAY,sBAAsB,KAAK,KAAK;;;;KAK3F,CACF,EAzCGZ,EAAA,CAAAc,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAX,EAAA,UAAA,UAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAc,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAX,EAAA,UAAA,UAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAc,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAX,EAAA,UAAA,OAAA,IAAA,EAAA,EAGzBH,EAAA,CAAAc,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAX,EAAA,UAAA,KAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAc,EAAS,CAAE,KAAM,OAAQ,QAAS,EAAK,CAAC,CAAA,EAAAX,EAAA,UAAA,SAAA,IAAA,EAAA,EAExCH,EAAA,CAAAe,EAAM,CAAA,EAAAZ,EAAA,UAAA,WAAA,IAAA,EAAA,EAfR,EAAAH,EAAA,CAAAgB,EAAc,mBAAmB,CAAA,EAAAb,CAAA,E"}
1
+ {"version":3,"file":"section-header.js","names":["_decorate","__decorate","LAYOUTS","SectionHeader","LitElement","_args","ensembleCSS","sectionHeaderCSS","changed","resolveEnum","n","showLead","nothing","property","state","defineElement"],"sources":["../../../../src/components/section-header/section-header.ts"],"sourcesContent":["import { LitElement, html, nothing, type PropertyValues } from \"lit\";\nimport { property, state } from \"lit/decorators.js\";\nimport { defineElement } from \"#shared/define-element.ts\";\n// Installs the design tokens into document scope; see src/tokens/tokens.ts\nimport \"#tokens/tokens.ts\";\nimport \"#components/heading/heading.ts\";\nimport \"#components/paragraph/paragraph.ts\";\nimport { resolveEnum } from \"#shared/prop-vocabulary.ts\";\nimport { ensembleCSS } from \"#shared/ensemble.css.ts\";\nimport { sectionHeaderCSS } from \"./section-header.css.ts\";\n\nconst LAYOUTS = [\"stacked\", \"split\", \"centered\"] as const;\n\ntype Layout = typeof LAYOUTS[number];\ntype HeadingTag = \"h1\" | \"h2\" | \"h3\" | \"h4\" | \"h5\" | \"h6\";\n\n/**\n * The header that opens a page section: an eyebrow, the section's h2 and a\n * lead. The homepage opens five sections with it -- AI, Why trust, Proven,\n * Insights and the solution splitter -- where each module used to spell its\n * own (bd-overview, bd-bento-grid, bd-trust-panel). Drawn in the foundation\n * Figma file as Section header.\n *\n * layout=\"split\" puts the headline and lead side by side from lg; below lg,\n * and in \"stacked\", everything stacks. layout=\"centered\" centres the three on\n * a narrower measure. Leave eyebrow and lead out for a title-only header.\n *\n * The lead is an attribute for plain copy, or the `lead` slot when it carries\n * a link -- `<bd-link inline underline>`, since colour alone measures 2.91:1\n * against the body text and fails WCAG 1.4.1. Slotted copy takes the lead's\n * role from here, so the page writes words, not typography.\n */\n@defineElement(\"bd-section-header\")\nexport class SectionHeader extends LitElement {\n static styles = [ensembleCSS, sectionHeaderCSS];\n\n @property({ type: String })\n eyebrow = \"\";\n @property({ type: String })\n heading = \"\";\n @property({ type: String })\n lead = \"\";\n // a page section's title: the outline is the page's, so it can say otherwise\n @property({ type: String })\n as: HeadingTag = \"h2\";\n @property({ type: String, reflect: true })\n layout: Layout = \"stacked\";\n @state()\n _hasLead = false;\n\n willUpdate(changed: PropertyValues<this>) {\n if (changed.has(\"layout\")) {\n this.layout = resolveEnum(this.layout, { allowed: LAYOUTS, fallback: \"stacked\" });\n }\n }\n\n _onLeadSlot(e: Event) {\n this._hasLead = (e.target as HTMLSlotElement).assignedNodes({ flatten: true })\n .some(n => n.nodeType === Node.ELEMENT_NODE || n.textContent!.trim());\n }\n\n render() {\n const showLead = this.lead || this._hasLead;\n return html`\n <header class=\"bd-ensemble root\">\n ${this.eyebrow\n ? html`<bd-p variant=\"eyebrow\" class=\"eyebrow\"><span class=\"text\">${this.eyebrow}</span></bd-p>`\n : nothing}\n <div class=\"row\">\n ${this.heading\n ? html`<bd-h as=\"${this.as}\" visual-level=\"h2\" class=\"heading\"><span class=\"text\">${this.heading}</span></bd-h>`\n : nothing}\n <div class=\"lead\" ?hidden=${!showLead}>\n <slot name=\"lead\" @slotchange=${this._onLeadSlot}><span class=\"text\">${this.lead}</span></slot>\n </div>\n </div>\n </header>\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"bd-section-header\": SectionHeader;\n }\n}\n"],"mappings":"A,mgBAWA,IAAME,EAAU,CAAC,UAAW,QAAS,UAAU,EAsBlCC,EAAN,cAA4BC,CAAW,C,8BAIlC,KAAA,QAAA,GAEA,KAAA,QAAA,GAEH,KAAA,KAAA,GAGU,KAAA,GAAA,KAEA,KAAA,OAAA,UAEN,KAAA,SAAA,E,QAdK,KAAA,OAAA,CAACE,EAAaC,CAAgB,C,CAgB9C,WAAW,EAA+B,CACpCC,EAAQ,IAAI,QAAQ,IACtB,KAAK,OAASC,EAAY,KAAK,OAAQ,CAAE,QAASP,EAAS,SAAU,SAAU,CAAC,EAEpF,CAEA,YAAY,EAAU,CACpB,KAAK,SAAY,EAAE,OAA2B,cAAc,CAAE,QAAS,EAAK,CAAC,CAAC,CAC3E,KAAK,GAAKQ,EAAE,WAAa,KAAK,cAAgBA,EAAE,YAAa,KAAK,CAAC,CACxE,CAEA,QAAS,CACP,IAAMC,EAAW,KAAK,MAAQ,KAAK,SACnC,MAAO,EAAI;;UAEL,KAAK,QACH,CAAI,8DAA8D,KAAK,QAAQ,gBAC/EC,EAAQ;;YAER,KAAK,QACH,CAAI,aAAa,KAAK,GAAG,yDAAyD,KAAK,QAAQ,gBAC/FA,EAAQ;sCACgB,CAACD,EAAS;4CACJ,KAAK,YAAY,sBAAsB,KAAK,KAAK;;;;KAK3F,CACF,EA3CGX,EAAA,CAAAa,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAV,EAAA,UAAA,UAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAa,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAV,EAAA,UAAA,UAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAa,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAV,EAAA,UAAA,OAAA,IAAA,EAAA,EAGzBH,EAAA,CAAAa,EAAS,CAAE,KAAM,MAAO,CAAC,CAAA,EAAAV,EAAA,UAAA,KAAA,IAAA,EAAA,EAEzBH,EAAA,CAAAa,EAAS,CAAE,KAAM,OAAQ,QAAS,EAAK,CAAC,CAAA,EAAAV,EAAA,UAAA,SAAA,IAAA,EAAA,EAExCH,EAAA,CAAAc,EAAM,CAAA,EAAAX,EAAA,UAAA,WAAA,IAAA,EAAA,EAfR,EAAAH,EAAA,CAAAe,EAAc,mBAAmB,CAAA,EAAAZ,CAAA,E"}
@@ -0,0 +1,50 @@
1
+ import type { ReactiveController, ReactiveControllerHost } from "lit";
2
+ type Observer = ResizeObserver | IntersectionObserver | MutationObserver;
3
+ /**
4
+ * A Resize-, Intersection- or MutationObserver a component keeps for as long
5
+ * as it is connected.
6
+ *
7
+ * Every component that observed something wrote the same three steps by hand
8
+ * -- observe once the shadow root has rendered, disconnect on disconnect,
9
+ * observe again on reconnect -- and the third was the one that went missing.
10
+ * firstUpdated runs once in an element's life, so an observer started there
11
+ * and disconnected in disconnectedCallback was gone for good the first time
12
+ * the element moved: a page decorating a block, a framework reordering a
13
+ * list, replaceChildren. bd-carousel-section stopped counting its stops,
14
+ * bd-card-section stopped aligning its rows, bd-anchor-nav's indicator
15
+ * stopped following its links and bd-stat-highlight never rolled, showing
16
+ * zeros. tooltip, light-carousel and logo-marquee had each fixed it on their
17
+ * own. This is the steps once, as MediaQueryController is for a media query.
18
+ *
19
+ * The component builds the observer -- what a delivery means stays its own
20
+ * -- and says what to observe. `observe` is called with the observer on the
21
+ * first update, once the shadow root exists, and again on every reconnect;
22
+ * it may observe nothing when what it looks for is not rendered. A component
23
+ * that is done for good calls stop(): bd-stat-highlight, once its figure has
24
+ * rolled.
25
+ *
26
+ * new ObserverController(this,
27
+ * () => new ResizeObserver(() => this._measure()),
28
+ * observer => observer.observe(this._track));
29
+ */
30
+ export declare class ObserverController<O extends Observer> implements ReactiveController {
31
+ private readonly _host;
32
+ private readonly _create;
33
+ private readonly _observe;
34
+ private _observer?;
35
+ private _attached;
36
+ private _stopped;
37
+ constructor(host: ReactiveControllerHost & {
38
+ hasUpdated: boolean;
39
+ }, create: () => O, observe: (observer: O) => void);
40
+ /** The observer, once it has been made. */
41
+ get observer(): O | undefined;
42
+ hostConnected(): void;
43
+ hostUpdated(): void;
44
+ hostDisconnected(): void;
45
+ /** Disconnects for good: no later connect observes again. */
46
+ stop(): void;
47
+ private _attach;
48
+ private _detach;
49
+ }
50
+ export {};
@@ -0,0 +1,2 @@
1
+ var e=class{constructor(e,t,n){this._attached=!1,this._stopped=!1,this._host=e,this._create=t,this._observe=n,e.addController(this)}get observer(){return this._observer}hostConnected(){this._host.hasUpdated&&this._attach()}hostUpdated(){this._attach()}hostDisconnected(){this._detach()}stop(){this._stopped=!0,this._detach()}_attach(){this._attached||this._stopped||(this._observer??=this._create(),this._attached=!0,this._observe(this._observer))}_detach(){this._observer?.disconnect(),this._attached=!1}};export{e as ObserverController};
2
+ //# sourceMappingURL=controller.observer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"controller.observer.js","names":["ObserverController","host","create","observe"],"sources":["../../../../src/components/shared/controller.observer.ts"],"sourcesContent":["import type { ReactiveController, ReactiveControllerHost } from 'lit';\n\ntype Observer = ResizeObserver | IntersectionObserver | MutationObserver;\n\n/**\n * A Resize-, Intersection- or MutationObserver a component keeps for as long\n * as it is connected.\n *\n * Every component that observed something wrote the same three steps by hand\n * -- observe once the shadow root has rendered, disconnect on disconnect,\n * observe again on reconnect -- and the third was the one that went missing.\n * firstUpdated runs once in an element's life, so an observer started there\n * and disconnected in disconnectedCallback was gone for good the first time\n * the element moved: a page decorating a block, a framework reordering a\n * list, replaceChildren. bd-carousel-section stopped counting its stops,\n * bd-card-section stopped aligning its rows, bd-anchor-nav's indicator\n * stopped following its links and bd-stat-highlight never rolled, showing\n * zeros. tooltip, light-carousel and logo-marquee had each fixed it on their\n * own. This is the steps once, as MediaQueryController is for a media query.\n *\n * The component builds the observer -- what a delivery means stays its own\n * -- and says what to observe. `observe` is called with the observer on the\n * first update, once the shadow root exists, and again on every reconnect;\n * it may observe nothing when what it looks for is not rendered. A component\n * that is done for good calls stop(): bd-stat-highlight, once its figure has\n * rolled.\n *\n * new ObserverController(this,\n * () => new ResizeObserver(() => this._measure()),\n * observer => observer.observe(this._track));\n */\nexport class ObserverController<O extends Observer> implements ReactiveController {\n private readonly _host : ReactiveControllerHost & { hasUpdated: boolean };\n private readonly _create : () => O;\n private readonly _observe: (observer: O) => void;\n private _observer? : O;\n private _attached = false;\n private _stopped = false;\n\n constructor(host: ReactiveControllerHost & { hasUpdated: boolean }, create: () => O, observe: (observer: O) => void) {\n this._host = host;\n this._create = create;\n this._observe = observe;\n host.addController(this);\n }\n\n /** The observer, once it has been made. */\n get observer() {\n return this._observer;\n }\n\n /* A reconnect: the shadow root is already there. A first connection waits\n for hostUpdated, because nothing is rendered yet. */\n hostConnected() {\n if (this._host.hasUpdated) this._attach();\n }\n\n /* Runs before the host's own firstUpdated, so `observe` finds what it looks\n for through the render root, not through a field firstUpdated sets. */\n hostUpdated() {\n this._attach();\n }\n\n hostDisconnected() {\n this._detach();\n }\n\n /** Disconnects for good: no later connect observes again. */\n stop() {\n this._stopped = true;\n this._detach();\n }\n\n private _attach() {\n if (this._attached || this._stopped) return;\n this._observer ??= this._create();\n this._attached = true;\n this._observe(this._observer);\n }\n\n private _detach() {\n this._observer?.disconnect();\n this._attached = false;\n }\n}\n"],"mappings":"AA+BA,IAAaA,EAAb,KAAkF,CAQhF,YAAY,EAAwD,EAAiB,EAAgC,CAHjG,KAAA,UAAA,GACD,KAAA,SAAA,GAGjB,KAAK,MAAQC,EACb,KAAK,QAAUC,EACf,KAAK,SAAWC,EAChBF,EAAK,cAAc,IAAI,CACzB,CAGA,IAAI,UAAW,CACb,OAAO,KAAK,SACd,CAIA,eAAgB,CACV,KAAK,MAAM,YAAY,KAAK,QAAQ,CAC1C,CAIA,aAAc,CACZ,KAAK,QAAQ,CACf,CAEA,kBAAmB,CACjB,KAAK,QAAQ,CACf,CAGA,MAAO,CACL,KAAK,SAAW,GAChB,KAAK,QAAQ,CACf,CAEA,SAAkB,CACZ,KAAK,WAAa,KAAK,WAC3B,KAAK,YAAc,KAAK,QAAQ,EAChC,KAAK,UAAY,GACjB,KAAK,SAAS,KAAK,SAAS,EAC9B,CAEA,SAAkB,CAChB,KAAK,WAAW,WAAW,EAC3B,KAAK,UAAY,EACnB,CACF,E"}
@@ -1,4 +1,5 @@
1
1
  import { LitElement } from "lit";
2
+ import "../../tokens/tokens.js";
2
3
  import "../heading/heading.js";
3
4
  import "../paragraph/paragraph.js";
4
5
  type SlotState = "_hasLeftIcon" | "_hasLeftButtons" | "_hasRightIcon" | "_hasRightButtons";