@brad-frost-web/eddie-recipes 0.49.0 → 0.50.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cdn/chunks/heading.DxaawzBz.js +103 -0
- package/cdn/eddie-recipes-autoloader.js +7 -6
- package/cdn/recipes/common/article-card/article-card.js +1 -1
- package/cdn/recipes/common/example-form/example-form.js +1 -1
- package/cdn/recipes/common/page-banner/page-banner.js +46 -40
- package/cdn/recipes/common/project-card/project-card.js +1 -1
- package/cdn/recipes/common/speaking-card/speaking-card.js +1 -1
- package/cdn/recipes/common/stat-card/stat-card.js +1 -1
- package/cdn/recipes/common/timeline-node/TimelineNodeKind.js +1 -1
- package/cdn/recipes/common/timeline-node/timeline-node.js +1 -1
- package/cdn/recipes/common/video-embed/video-embed.js +48 -0
- package/package.json +1 -1
- package/recipes/common/video-embed/video-embed.d.ts +112 -0
- package/recipes/common/video-embed/video-embed.d.ts.map +1 -0
- package/recipes/common/video-embed/video-embed.js +50 -0
- package/cdn/chunks/heading.Ca_LYMne.js +0 -64
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { r as y, b as a, n } from "./lit.EWazi_Sp.js";
|
|
2
|
+
import { E as p } from "./EdElement.Dqh0Nrbq.js";
|
|
3
|
+
const m = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}.ed-c-heading{text-wrap:var(--ed-heading-text-wrap, balance);margin:0}.ed-c-heading--wrap-balance{--ed-heading-text-wrap: balance}.ed-c-heading--wrap-pretty{--ed-heading-text-wrap: pretty}.ed-c-heading--wrap-normal{--ed-heading-text-wrap: normal}::slotted(a){color:inherit;text-decoration:none;border-block-end:var(--ed-theme-border-width-sm) solid transparent;transition:border-color var(--ed-theme-animation-fade-quick) var(--ed-theme-animation-ease)}::slotted(a:hover),::slotted(a:focus-visible){color:inherit;border-block-end-color:var(--ed-heading-link-color-border, var(--ed-theme-color-border-brand))}::slotted(a:focus-visible){outline:var(--ed-theme-border-width-lg) solid var(--ed-theme-focus-ring-color-border-default);outline-offset:var(--ed-theme-offset-focus-ring, .25rem)}.ed-c-heading--display-xl{font-family:var(--ed-theme-typography-display-xl-mobile-font-family);font-weight:var(--ed-theme-typography-display-xl-mobile-font-weight);font-size:var(--ed-theme-typography-display-xl-mobile-font-size);line-height:var(--ed-theme-typography-display-xl-mobile-line-height);letter-spacing:var(--ed-theme-typography-display-xl-mobile-letter-spacing);text-transform:var(--ed-theme-typography-display-xl-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--display-xl{font-family:var(--ed-theme-typography-display-xl-tablet-font-family);font-weight:var(--ed-theme-typography-display-xl-tablet-font-weight);font-size:var(--ed-theme-typography-display-xl-tablet-font-size);line-height:var(--ed-theme-typography-display-xl-tablet-line-height);letter-spacing:var(--ed-theme-typography-display-xl-tablet-letter-spacing);text-transform:var(--ed-theme-typography-display-xl-tablet-text-transform)}}@media all and (min-width:75rem){.ed-c-heading--display-xl{font-family:var(--ed-theme-typography-display-xl-font-family);font-weight:var(--ed-theme-typography-display-xl-font-weight);font-size:var(--ed-theme-typography-display-xl-font-size);line-height:var(--ed-theme-typography-display-xl-line-height);letter-spacing:var(--ed-theme-typography-display-xl-letter-spacing);text-transform:var(--ed-theme-typography-display-xl-text-transform)}}.ed-c-heading--display-lg{font-family:var(--ed-theme-typography-display-lg-mobile-font-family);font-weight:var(--ed-theme-typography-display-lg-mobile-font-weight);font-size:var(--ed-theme-typography-display-lg-mobile-font-size);line-height:var(--ed-theme-typography-display-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-display-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-display-lg-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--display-lg{font-family:var(--ed-theme-typography-display-lg-font-family);font-weight:var(--ed-theme-typography-display-lg-font-weight);font-size:var(--ed-theme-typography-display-lg-font-size);line-height:var(--ed-theme-typography-display-lg-line-height);letter-spacing:var(--ed-theme-typography-display-lg-letter-spacing);text-transform:var(--ed-theme-typography-display-lg-text-transform)}}.ed-c-heading--display-default{font-family:var(--ed-theme-typography-display-default-mobile-font-family);font-weight:var(--ed-theme-typography-display-default-mobile-font-weight);font-size:var(--ed-theme-typography-display-default-mobile-font-size);line-height:var(--ed-theme-typography-display-default-mobile-line-height);letter-spacing:var(--ed-theme-typography-display-default-mobile-letter-spacing);text-transform:var(--ed-theme-typography-display-default-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--display-default{font-family:var(--ed-theme-typography-display-default-font-family);font-weight:var(--ed-theme-typography-display-default-font-weight);font-size:var(--ed-theme-typography-display-default-font-size);line-height:var(--ed-theme-typography-display-default-line-height);letter-spacing:var(--ed-theme-typography-display-default-letter-spacing);text-transform:var(--ed-theme-typography-display-default-text-transform)}}.ed-c-heading--headline-lg{font-family:var(--ed-theme-typography-headline-lg-mobile-font-family);font-weight:var(--ed-theme-typography-headline-lg-mobile-font-weight);font-size:var(--ed-theme-typography-headline-lg-mobile-font-size);line-height:var(--ed-theme-typography-headline-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--headline-lg{font-family:var(--ed-theme-typography-headline-lg-font-family);font-weight:var(--ed-theme-typography-headline-lg-font-weight);font-size:var(--ed-theme-typography-headline-lg-font-size);line-height:var(--ed-theme-typography-headline-lg-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-text-transform)}}.ed-c-heading--headline-default{font-family:var(--ed-theme-typography-headline-default-mobile-font-family);font-weight:var(--ed-theme-typography-headline-default-mobile-font-weight);font-size:var(--ed-theme-typography-headline-default-mobile-font-size);line-height:var(--ed-theme-typography-headline-default-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-default-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-default-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--headline-default{font-family:var(--ed-theme-typography-headline-default-font-family);font-weight:var(--ed-theme-typography-headline-default-font-weight);font-size:var(--ed-theme-typography-headline-default-font-size);line-height:var(--ed-theme-typography-headline-default-line-height);letter-spacing:var(--ed-theme-typography-headline-default-letter-spacing);text-transform:var(--ed-theme-typography-headline-default-text-transform)}}.ed-c-heading--headline-sm{font-family:var(--ed-theme-typography-headline-sm-mobile-font-family);font-weight:var(--ed-theme-typography-headline-sm-mobile-font-weight);font-size:var(--ed-theme-typography-headline-sm-mobile-font-size);line-height:var(--ed-theme-typography-headline-sm-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-sm-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-sm-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--headline-sm{font-family:var(--ed-theme-typography-headline-sm-font-family);font-weight:var(--ed-theme-typography-headline-sm-font-weight);font-size:var(--ed-theme-typography-headline-sm-font-size);line-height:var(--ed-theme-typography-headline-sm-line-height);letter-spacing:var(--ed-theme-typography-headline-sm-letter-spacing);text-transform:var(--ed-theme-typography-headline-sm-text-transform)}}.ed-c-heading--title-lg{font-family:var(--ed-theme-typography-title-lg-mobile-font-family);font-weight:var(--ed-theme-typography-title-lg-mobile-font-weight);font-size:var(--ed-theme-typography-title-lg-mobile-font-size);line-height:var(--ed-theme-typography-title-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-title-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-title-lg-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--title-lg{font-family:var(--ed-theme-typography-title-lg-font-family);font-weight:var(--ed-theme-typography-title-lg-font-weight);font-size:var(--ed-theme-typography-title-lg-font-size);line-height:var(--ed-theme-typography-title-lg-line-height);letter-spacing:var(--ed-theme-typography-title-lg-letter-spacing);text-transform:var(--ed-theme-typography-title-lg-text-transform)}}.ed-c-heading--title-default{font-family:var(--ed-theme-typography-title-default-font-family);font-weight:var(--ed-theme-typography-title-default-font-weight);font-size:var(--ed-theme-typography-title-default-font-size);line-height:var(--ed-theme-typography-title-default-line-height);letter-spacing:var(--ed-theme-typography-title-default-letter-spacing);text-transform:var(--ed-theme-typography-title-default-text-transform)}.ed-c-heading--title-sm{font-family:var(--ed-theme-typography-title-sm-font-family);font-weight:var(--ed-theme-typography-title-sm-font-weight);font-size:var(--ed-theme-typography-title-sm-font-size);line-height:var(--ed-theme-typography-title-sm-line-height);letter-spacing:var(--ed-theme-typography-title-sm-letter-spacing);text-transform:var(--ed-theme-typography-title-sm-text-transform)}.ed-c-heading--label-lg{font-family:var(--ed-theme-typography-label-lg-font-family);font-weight:var(--ed-theme-typography-label-lg-font-weight);font-size:var(--ed-theme-typography-label-lg-font-size);line-height:var(--ed-theme-typography-label-lg-line-height);letter-spacing:var(--ed-theme-typography-label-lg-letter-spacing);text-transform:var(--ed-theme-typography-label-lg-text-transform)}.ed-c-heading--label-default{font-family:var(--ed-theme-typography-label-default-font-family);font-weight:var(--ed-theme-typography-label-default-font-weight);font-size:var(--ed-theme-typography-label-default-font-size);line-height:var(--ed-theme-typography-label-default-line-height);letter-spacing:var(--ed-theme-typography-label-default-letter-spacing);text-transform:var(--ed-theme-typography-label-default-text-transform)}.ed-c-heading--label-sm{font-family:var(--ed-theme-typography-label-sm-font-family);font-weight:var(--ed-theme-typography-label-sm-font-weight);font-size:var(--ed-theme-typography-label-sm-font-size);line-height:var(--ed-theme-typography-label-sm-line-height);letter-spacing:var(--ed-theme-typography-label-sm-letter-spacing);text-transform:var(--ed-theme-typography-label-sm-text-transform)}.ed-c-heading--body-lg{font-family:var(--ed-theme-typography-body-lg-font-family);font-weight:var(--ed-theme-typography-body-lg-font-weight);font-size:var(--ed-theme-typography-body-lg-font-size);line-height:var(--ed-theme-typography-body-lg-line-height);letter-spacing:var(--ed-theme-typography-body-lg-letter-spacing);text-transform:var(--ed-theme-typography-body-lg-text-transform)}.ed-c-heading--body-default{font-family:var(--ed-theme-typography-body-default-font-family);font-weight:var(--ed-theme-typography-body-default-font-weight);font-size:var(--ed-theme-typography-body-default-font-size);line-height:var(--ed-theme-typography-body-default-line-height);letter-spacing:var(--ed-theme-typography-body-default-letter-spacing);text-transform:var(--ed-theme-typography-body-default-text-transform)}.ed-c-heading--body-sm{font-family:var(--ed-theme-typography-body-sm-font-family);font-weight:var(--ed-theme-typography-body-sm-font-weight);font-size:var(--ed-theme-typography-body-sm-font-size);line-height:var(--ed-theme-typography-body-sm-line-height);letter-spacing:var(--ed-theme-typography-body-sm-letter-spacing);text-transform:var(--ed-theme-typography-body-sm-text-transform)}.ed-c-heading--meta-default{font-family:var(--ed-theme-typography-meta-default-font-family);font-weight:var(--ed-theme-typography-meta-default-font-weight);font-size:var(--ed-theme-typography-meta-default-font-size);line-height:var(--ed-theme-typography-meta-default-line-height);letter-spacing:var(--ed-theme-typography-meta-default-letter-spacing);text-transform:var(--ed-theme-typography-meta-default-text-transform)}.ed-c-heading--meta-sm{font-family:var(--ed-theme-typography-meta-sm-font-family);font-weight:var(--ed-theme-typography-meta-sm-font-weight);font-size:var(--ed-theme-typography-meta-sm-font-size);line-height:var(--ed-theme-typography-meta-sm-line-height);letter-spacing:var(--ed-theme-typography-meta-sm-letter-spacing);text-transform:var(--ed-theme-typography-meta-sm-text-transform)}', f = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}ed-heading[enhance]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading{text-wrap:var(--ed-heading-text-wrap, balance);margin:0}ed-heading[enhance]:not([variant])>h1{font-family:var(--ed-theme-typography-headline-lg-mobile-font-family);font-weight:var(--ed-theme-typography-headline-lg-mobile-font-weight);font-size:var(--ed-theme-typography-headline-lg-mobile-font-size);line-height:var(--ed-theme-typography-headline-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance]:not([variant])>h1{font-family:var(--ed-theme-typography-headline-lg-font-family);font-weight:var(--ed-theme-typography-headline-lg-font-weight);font-size:var(--ed-theme-typography-headline-lg-font-size);line-height:var(--ed-theme-typography-headline-lg-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-text-transform)}}ed-heading[enhance]:not([variant])>h2{font-family:var(--ed-theme-typography-headline-default-mobile-font-family);font-weight:var(--ed-theme-typography-headline-default-mobile-font-weight);font-size:var(--ed-theme-typography-headline-default-mobile-font-size);line-height:var(--ed-theme-typography-headline-default-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-default-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-default-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance]:not([variant])>h2{font-family:var(--ed-theme-typography-headline-default-font-family);font-weight:var(--ed-theme-typography-headline-default-font-weight);font-size:var(--ed-theme-typography-headline-default-font-size);line-height:var(--ed-theme-typography-headline-default-line-height);letter-spacing:var(--ed-theme-typography-headline-default-letter-spacing);text-transform:var(--ed-theme-typography-headline-default-text-transform)}}ed-heading[enhance]:not([variant])>h3{font-family:var(--ed-theme-typography-headline-sm-mobile-font-family);font-weight:var(--ed-theme-typography-headline-sm-mobile-font-weight);font-size:var(--ed-theme-typography-headline-sm-mobile-font-size);line-height:var(--ed-theme-typography-headline-sm-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-sm-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-sm-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance]:not([variant])>h3{font-family:var(--ed-theme-typography-headline-sm-font-family);font-weight:var(--ed-theme-typography-headline-sm-font-weight);font-size:var(--ed-theme-typography-headline-sm-font-size);line-height:var(--ed-theme-typography-headline-sm-line-height);letter-spacing:var(--ed-theme-typography-headline-sm-letter-spacing);text-transform:var(--ed-theme-typography-headline-sm-text-transform)}}ed-heading[enhance]:not([variant])>h4{font-family:var(--ed-theme-typography-title-lg-mobile-font-family);font-weight:var(--ed-theme-typography-title-lg-mobile-font-weight);font-size:var(--ed-theme-typography-title-lg-mobile-font-size);line-height:var(--ed-theme-typography-title-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-title-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-title-lg-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance]:not([variant])>h4{font-family:var(--ed-theme-typography-title-lg-font-family);font-weight:var(--ed-theme-typography-title-lg-font-weight);font-size:var(--ed-theme-typography-title-lg-font-size);line-height:var(--ed-theme-typography-title-lg-line-height);letter-spacing:var(--ed-theme-typography-title-lg-letter-spacing);text-transform:var(--ed-theme-typography-title-lg-text-transform)}}ed-heading[enhance]:not([variant])>h5{font-family:var(--ed-theme-typography-title-default-font-family);font-weight:var(--ed-theme-typography-title-default-font-weight);font-size:var(--ed-theme-typography-title-default-font-size);line-height:var(--ed-theme-typography-title-default-line-height);letter-spacing:var(--ed-theme-typography-title-default-letter-spacing);text-transform:var(--ed-theme-typography-title-default-text-transform)}ed-heading[enhance]:not([variant])>h6{font-family:var(--ed-theme-typography-title-sm-font-family);font-weight:var(--ed-theme-typography-title-sm-font-weight);font-size:var(--ed-theme-typography-title-sm-font-size);line-height:var(--ed-theme-typography-title-sm-line-height);letter-spacing:var(--ed-theme-typography-title-sm-letter-spacing);text-transform:var(--ed-theme-typography-title-sm-text-transform)}ed-heading[enhance][wrap=balance]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--wrap-balance{--ed-heading-text-wrap: balance}ed-heading[enhance][wrap=pretty]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--wrap-pretty{--ed-heading-text-wrap: pretty}ed-heading[enhance][wrap=normal]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--wrap-normal{--ed-heading-text-wrap: normal}ed-heading[enhance]>:is(h1,h2,h3,h4,h5,h6) a,.ed-c-heading a{color:inherit;text-decoration:none;border-block-end:var(--ed-theme-border-width-sm) solid transparent;transition:border-color var(--ed-theme-animation-fade-quick) var(--ed-theme-animation-ease)}ed-heading[enhance]>:is(h1,h2,h3,h4,h5,h6) a:hover,ed-heading[enhance]>:is(h1,h2,h3,h4,h5,h6) a:focus-visible,.ed-c-heading a:hover,.ed-c-heading a:focus-visible{color:inherit;border-block-end-color:var(--ed-heading-link-color-border, var(--ed-theme-color-border-brand))}ed-heading[enhance]>:is(h1,h2,h3,h4,h5,h6) a:focus-visible,.ed-c-heading a:focus-visible{outline:var(--ed-theme-border-width-lg) solid var(--ed-theme-focus-ring-color-border-default);outline-offset:var(--ed-theme-offset-focus-ring, .25rem)}ed-heading[enhance][variant=display-xl]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--display-xl{font-family:var(--ed-theme-typography-display-xl-mobile-font-family);font-weight:var(--ed-theme-typography-display-xl-mobile-font-weight);font-size:var(--ed-theme-typography-display-xl-mobile-font-size);line-height:var(--ed-theme-typography-display-xl-mobile-line-height);letter-spacing:var(--ed-theme-typography-display-xl-mobile-letter-spacing);text-transform:var(--ed-theme-typography-display-xl-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance][variant=display-xl]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--display-xl{font-family:var(--ed-theme-typography-display-xl-tablet-font-family);font-weight:var(--ed-theme-typography-display-xl-tablet-font-weight);font-size:var(--ed-theme-typography-display-xl-tablet-font-size);line-height:var(--ed-theme-typography-display-xl-tablet-line-height);letter-spacing:var(--ed-theme-typography-display-xl-tablet-letter-spacing);text-transform:var(--ed-theme-typography-display-xl-tablet-text-transform)}}@media all and (min-width:75rem){ed-heading[enhance][variant=display-xl]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--display-xl{font-family:var(--ed-theme-typography-display-xl-font-family);font-weight:var(--ed-theme-typography-display-xl-font-weight);font-size:var(--ed-theme-typography-display-xl-font-size);line-height:var(--ed-theme-typography-display-xl-line-height);letter-spacing:var(--ed-theme-typography-display-xl-letter-spacing);text-transform:var(--ed-theme-typography-display-xl-text-transform)}}ed-heading[enhance][variant=display-lg]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--display-lg{font-family:var(--ed-theme-typography-display-lg-mobile-font-family);font-weight:var(--ed-theme-typography-display-lg-mobile-font-weight);font-size:var(--ed-theme-typography-display-lg-mobile-font-size);line-height:var(--ed-theme-typography-display-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-display-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-display-lg-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance][variant=display-lg]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--display-lg{font-family:var(--ed-theme-typography-display-lg-font-family);font-weight:var(--ed-theme-typography-display-lg-font-weight);font-size:var(--ed-theme-typography-display-lg-font-size);line-height:var(--ed-theme-typography-display-lg-line-height);letter-spacing:var(--ed-theme-typography-display-lg-letter-spacing);text-transform:var(--ed-theme-typography-display-lg-text-transform)}}ed-heading[enhance][variant=display-default]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--display-default{font-family:var(--ed-theme-typography-display-default-mobile-font-family);font-weight:var(--ed-theme-typography-display-default-mobile-font-weight);font-size:var(--ed-theme-typography-display-default-mobile-font-size);line-height:var(--ed-theme-typography-display-default-mobile-line-height);letter-spacing:var(--ed-theme-typography-display-default-mobile-letter-spacing);text-transform:var(--ed-theme-typography-display-default-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance][variant=display-default]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--display-default{font-family:var(--ed-theme-typography-display-default-font-family);font-weight:var(--ed-theme-typography-display-default-font-weight);font-size:var(--ed-theme-typography-display-default-font-size);line-height:var(--ed-theme-typography-display-default-line-height);letter-spacing:var(--ed-theme-typography-display-default-letter-spacing);text-transform:var(--ed-theme-typography-display-default-text-transform)}}ed-heading[enhance][variant=headline-lg]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--headline-lg{font-family:var(--ed-theme-typography-headline-lg-mobile-font-family);font-weight:var(--ed-theme-typography-headline-lg-mobile-font-weight);font-size:var(--ed-theme-typography-headline-lg-mobile-font-size);line-height:var(--ed-theme-typography-headline-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance][variant=headline-lg]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--headline-lg{font-family:var(--ed-theme-typography-headline-lg-font-family);font-weight:var(--ed-theme-typography-headline-lg-font-weight);font-size:var(--ed-theme-typography-headline-lg-font-size);line-height:var(--ed-theme-typography-headline-lg-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-text-transform)}}ed-heading[enhance][variant=headline-default]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--headline-default{font-family:var(--ed-theme-typography-headline-default-mobile-font-family);font-weight:var(--ed-theme-typography-headline-default-mobile-font-weight);font-size:var(--ed-theme-typography-headline-default-mobile-font-size);line-height:var(--ed-theme-typography-headline-default-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-default-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-default-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance][variant=headline-default]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--headline-default{font-family:var(--ed-theme-typography-headline-default-font-family);font-weight:var(--ed-theme-typography-headline-default-font-weight);font-size:var(--ed-theme-typography-headline-default-font-size);line-height:var(--ed-theme-typography-headline-default-line-height);letter-spacing:var(--ed-theme-typography-headline-default-letter-spacing);text-transform:var(--ed-theme-typography-headline-default-text-transform)}}ed-heading[enhance][variant=headline-sm]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--headline-sm{font-family:var(--ed-theme-typography-headline-sm-mobile-font-family);font-weight:var(--ed-theme-typography-headline-sm-mobile-font-weight);font-size:var(--ed-theme-typography-headline-sm-mobile-font-size);line-height:var(--ed-theme-typography-headline-sm-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-sm-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-sm-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance][variant=headline-sm]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--headline-sm{font-family:var(--ed-theme-typography-headline-sm-font-family);font-weight:var(--ed-theme-typography-headline-sm-font-weight);font-size:var(--ed-theme-typography-headline-sm-font-size);line-height:var(--ed-theme-typography-headline-sm-line-height);letter-spacing:var(--ed-theme-typography-headline-sm-letter-spacing);text-transform:var(--ed-theme-typography-headline-sm-text-transform)}}ed-heading[enhance][variant=title-lg]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--title-lg{font-family:var(--ed-theme-typography-title-lg-mobile-font-family);font-weight:var(--ed-theme-typography-title-lg-mobile-font-weight);font-size:var(--ed-theme-typography-title-lg-mobile-font-size);line-height:var(--ed-theme-typography-title-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-title-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-title-lg-mobile-text-transform)}@media all and (min-width:48rem){ed-heading[enhance][variant=title-lg]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--title-lg{font-family:var(--ed-theme-typography-title-lg-font-family);font-weight:var(--ed-theme-typography-title-lg-font-weight);font-size:var(--ed-theme-typography-title-lg-font-size);line-height:var(--ed-theme-typography-title-lg-line-height);letter-spacing:var(--ed-theme-typography-title-lg-letter-spacing);text-transform:var(--ed-theme-typography-title-lg-text-transform)}}ed-heading[enhance][variant=title-default]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--title-default{font-family:var(--ed-theme-typography-title-default-font-family);font-weight:var(--ed-theme-typography-title-default-font-weight);font-size:var(--ed-theme-typography-title-default-font-size);line-height:var(--ed-theme-typography-title-default-line-height);letter-spacing:var(--ed-theme-typography-title-default-letter-spacing);text-transform:var(--ed-theme-typography-title-default-text-transform)}ed-heading[enhance][variant=title-sm]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--title-sm{font-family:var(--ed-theme-typography-title-sm-font-family);font-weight:var(--ed-theme-typography-title-sm-font-weight);font-size:var(--ed-theme-typography-title-sm-font-size);line-height:var(--ed-theme-typography-title-sm-line-height);letter-spacing:var(--ed-theme-typography-title-sm-letter-spacing);text-transform:var(--ed-theme-typography-title-sm-text-transform)}ed-heading[enhance][variant=label-lg]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--label-lg{font-family:var(--ed-theme-typography-label-lg-font-family);font-weight:var(--ed-theme-typography-label-lg-font-weight);font-size:var(--ed-theme-typography-label-lg-font-size);line-height:var(--ed-theme-typography-label-lg-line-height);letter-spacing:var(--ed-theme-typography-label-lg-letter-spacing);text-transform:var(--ed-theme-typography-label-lg-text-transform)}ed-heading[enhance][variant=label-default]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--label-default{font-family:var(--ed-theme-typography-label-default-font-family);font-weight:var(--ed-theme-typography-label-default-font-weight);font-size:var(--ed-theme-typography-label-default-font-size);line-height:var(--ed-theme-typography-label-default-line-height);letter-spacing:var(--ed-theme-typography-label-default-letter-spacing);text-transform:var(--ed-theme-typography-label-default-text-transform)}ed-heading[enhance][variant=label-sm]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--label-sm{font-family:var(--ed-theme-typography-label-sm-font-family);font-weight:var(--ed-theme-typography-label-sm-font-weight);font-size:var(--ed-theme-typography-label-sm-font-size);line-height:var(--ed-theme-typography-label-sm-line-height);letter-spacing:var(--ed-theme-typography-label-sm-letter-spacing);text-transform:var(--ed-theme-typography-label-sm-text-transform)}ed-heading[enhance][variant=body-lg]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--body-lg{font-family:var(--ed-theme-typography-body-lg-font-family);font-weight:var(--ed-theme-typography-body-lg-font-weight);font-size:var(--ed-theme-typography-body-lg-font-size);line-height:var(--ed-theme-typography-body-lg-line-height);letter-spacing:var(--ed-theme-typography-body-lg-letter-spacing);text-transform:var(--ed-theme-typography-body-lg-text-transform)}ed-heading[enhance][variant=body-default]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--body-default{font-family:var(--ed-theme-typography-body-default-font-family);font-weight:var(--ed-theme-typography-body-default-font-weight);font-size:var(--ed-theme-typography-body-default-font-size);line-height:var(--ed-theme-typography-body-default-line-height);letter-spacing:var(--ed-theme-typography-body-default-letter-spacing);text-transform:var(--ed-theme-typography-body-default-text-transform)}ed-heading[enhance][variant=body-sm]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--body-sm{font-family:var(--ed-theme-typography-body-sm-font-family);font-weight:var(--ed-theme-typography-body-sm-font-weight);font-size:var(--ed-theme-typography-body-sm-font-size);line-height:var(--ed-theme-typography-body-sm-line-height);letter-spacing:var(--ed-theme-typography-body-sm-letter-spacing);text-transform:var(--ed-theme-typography-body-sm-text-transform)}ed-heading[enhance][variant=meta-default]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--meta-default{font-family:var(--ed-theme-typography-meta-default-font-family);font-weight:var(--ed-theme-typography-meta-default-font-weight);font-size:var(--ed-theme-typography-meta-default-font-size);line-height:var(--ed-theme-typography-meta-default-line-height);letter-spacing:var(--ed-theme-typography-meta-default-letter-spacing);text-transform:var(--ed-theme-typography-meta-default-text-transform)}ed-heading[enhance][variant=meta-sm]>:is(h1,h2,h3,h4,h5,h6),.ed-c-heading--meta-sm{font-family:var(--ed-theme-typography-meta-sm-font-family);font-weight:var(--ed-theme-typography-meta-sm-font-weight);font-size:var(--ed-theme-typography-meta-sm-font-size);line-height:var(--ed-theme-typography-meta-sm-line-height);letter-spacing:var(--ed-theme-typography-meta-sm-letter-spacing);text-transform:var(--ed-theme-typography-meta-sm-text-transform)}';
|
|
4
|
+
var s = Object.defineProperty, d = (l, e, h, o) => {
|
|
5
|
+
for (var t = void 0, r = l.length - 1, g; r >= 0; r--)
|
|
6
|
+
(g = l[r]) && (t = g(e, h, t) || t);
|
|
7
|
+
return t && s(e, h, t), t;
|
|
8
|
+
};
|
|
9
|
+
class i extends p {
|
|
10
|
+
constructor() {
|
|
11
|
+
super(...arguments), this.tagName = "h2";
|
|
12
|
+
}
|
|
13
|
+
static get styles() {
|
|
14
|
+
return y(m);
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* The modifier-class map for a heading at semantic level `level`.
|
|
18
|
+
*
|
|
19
|
+
* Shared by both authoring modes so they cannot drift: `render()` passes the
|
|
20
|
+
* `tagName` property, and `enhanceLightDom()` passes the author's real tag —
|
|
21
|
+
* which is the whole reason the level is a parameter rather than read from
|
|
22
|
+
* `this`. An explicit `variant` always wins; the `level` only decides the
|
|
23
|
+
* default when `variant` is unset.
|
|
24
|
+
*/
|
|
25
|
+
headingModifiers(e) {
|
|
26
|
+
return {
|
|
27
|
+
"ed-c-heading--display-xl": this.variant === "display-xl",
|
|
28
|
+
"ed-c-heading--display-lg": this.variant === "display-lg",
|
|
29
|
+
"ed-c-heading--display-default": this.variant === "display-default",
|
|
30
|
+
"ed-c-heading--headline-lg": this.variant ? this.variant === "headline-lg" : e === "h1",
|
|
31
|
+
"ed-c-heading--headline-default": this.variant ? this.variant === "headline-default" : e === "h2",
|
|
32
|
+
"ed-c-heading--headline-sm": this.variant ? this.variant === "headline-sm" : e === "h3",
|
|
33
|
+
"ed-c-heading--title-lg": this.variant ? this.variant === "title-lg" : e === "h4",
|
|
34
|
+
"ed-c-heading--title-default": this.variant ? this.variant === "title-default" : e === "h5",
|
|
35
|
+
"ed-c-heading--title-sm": this.variant ? this.variant === "title-sm" : e === "h6",
|
|
36
|
+
"ed-c-heading--label-lg": this.variant === "label-lg",
|
|
37
|
+
"ed-c-heading--label-default": this.variant === "label-default",
|
|
38
|
+
"ed-c-heading--label-sm": this.variant === "label-sm",
|
|
39
|
+
"ed-c-heading--body-lg": this.variant === "body-lg",
|
|
40
|
+
"ed-c-heading--body-default": this.variant === "body-default",
|
|
41
|
+
"ed-c-heading--body-sm": this.variant === "body-sm",
|
|
42
|
+
"ed-c-heading--meta-default": this.variant === "meta-default",
|
|
43
|
+
"ed-c-heading--meta-sm": this.variant === "meta-sm",
|
|
44
|
+
"ed-c-heading--wrap-balance": this.wrap === "balance",
|
|
45
|
+
"ed-c-heading--wrap-pretty": this.wrap === "pretty",
|
|
46
|
+
"ed-c-heading--wrap-normal": this.wrap === "normal"
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Enhance mode (#1484): style the author's real heading in place instead of
|
|
51
|
+
* rendering one into a shadow root.
|
|
52
|
+
*
|
|
53
|
+
* Authored form:
|
|
54
|
+
* ```html
|
|
55
|
+
* <ed-heading enhance variant="display-lg">
|
|
56
|
+
* <h1 class="p-name">How I build design systems</h1>
|
|
57
|
+
* </ed-heading>
|
|
58
|
+
* ```
|
|
59
|
+
*
|
|
60
|
+
* The point is that the `<h1>` is in the document before this component (or
|
|
61
|
+
* any JS) runs: it is in the accessibility tree and the heading outline with
|
|
62
|
+
* scripting off, and microformat and SEO parsers can read it — none of which
|
|
63
|
+
* is true of a heading rendered into a shadow root.
|
|
64
|
+
*
|
|
65
|
+
* `tagName` is inert here. The author's own element decides the semantic
|
|
66
|
+
* level, which is the entire point of the mode; this method reads that level
|
|
67
|
+
* to pick the default typography preset when `variant` is unset.
|
|
68
|
+
*/
|
|
69
|
+
enhanceLightDom() {
|
|
70
|
+
this.injectGlobalStyles("ed-heading-styles", f);
|
|
71
|
+
const e = this.querySelector(":scope > h1, :scope > h2, :scope > h3, :scope > h4, :scope > h5, :scope > h6");
|
|
72
|
+
e && (e.classList.add("ed-c-heading"), this.styleModifier && e.classList.add(this.styleModifier), Object.entries(this.headingModifiers(e.localName)).forEach(([h, o]) => {
|
|
73
|
+
e.classList.toggle(h, o);
|
|
74
|
+
}));
|
|
75
|
+
}
|
|
76
|
+
render() {
|
|
77
|
+
const e = this.componentClassNames("ed-c-heading", this.headingModifiers(this.tagName));
|
|
78
|
+
switch (this.tagName) {
|
|
79
|
+
case "h1":
|
|
80
|
+
return a` <h1 class="${e}"><slot></slot></h1> `;
|
|
81
|
+
case "h2":
|
|
82
|
+
return a` <h2 class="${e}"><slot></slot></h2> `;
|
|
83
|
+
case "h3":
|
|
84
|
+
return a` <h3 class="${e}"><slot></slot></h3> `;
|
|
85
|
+
case "h4":
|
|
86
|
+
return a` <h4 class="${e}"><slot></slot></h4> `;
|
|
87
|
+
case "h5":
|
|
88
|
+
return a` <h5 class="${e}"><slot></slot></h5> `;
|
|
89
|
+
case "h6":
|
|
90
|
+
return a` <h6 class="${e}"><slot></slot></h6> `;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
d([
|
|
95
|
+
n()
|
|
96
|
+
], i.prototype, "variant");
|
|
97
|
+
d([
|
|
98
|
+
n()
|
|
99
|
+
], i.prototype, "tagName");
|
|
100
|
+
d([
|
|
101
|
+
n()
|
|
102
|
+
], i.prototype, "wrap");
|
|
103
|
+
customElements.get("ed-heading") === void 0 && customElements.define("ed-heading", i);
|
|
@@ -36,6 +36,7 @@ const s = {
|
|
|
36
36
|
"ed-r-timeline-node-video": "./recipes/common/timeline-node-video/timeline-node-video.js",
|
|
37
37
|
"ed-r-transport-button": "./recipes/common/transport-button/transport-button.js",
|
|
38
38
|
"ed-r-vertical-site-header": "./recipes/common/vertical-site-header/vertical-site-header.js",
|
|
39
|
+
"ed-r-video-embed": "./recipes/common/video-embed/video-embed.js",
|
|
39
40
|
"ed-r-visualzzz": "./recipes/common/visualzzz/visualzzz.js",
|
|
40
41
|
"ed-r-wah-link-list": "./recipes/we-are-here/wah-link-list/wah-link-list.js",
|
|
41
42
|
"ed-r-wah-logo": "./recipes/we-are-here/wah-logo/wah-logo.js",
|
|
@@ -56,12 +57,12 @@ function l() {
|
|
|
56
57
|
function a(e) {
|
|
57
58
|
i = e.endsWith("/") ? e : e + "/";
|
|
58
59
|
}
|
|
59
|
-
const
|
|
60
|
+
const d = /* @__PURE__ */ new Set();
|
|
60
61
|
async function m(e) {
|
|
61
|
-
if (
|
|
62
|
+
if (d.has(e) || customElements.get(e)) return;
|
|
62
63
|
const n = s[e];
|
|
63
64
|
if (n) {
|
|
64
|
-
|
|
65
|
+
d.add(e);
|
|
65
66
|
try {
|
|
66
67
|
await import(l() + n);
|
|
67
68
|
} catch (o) {
|
|
@@ -76,7 +77,7 @@ function r(e = document.body) {
|
|
|
76
77
|
s[t] && m(t);
|
|
77
78
|
}
|
|
78
79
|
}
|
|
79
|
-
const
|
|
80
|
+
const c = new MutationObserver((e) => {
|
|
80
81
|
for (const n of e)
|
|
81
82
|
for (const o of n.addedNodes)
|
|
82
83
|
if (o instanceof HTMLElement) {
|
|
@@ -85,8 +86,8 @@ const d = new MutationObserver((e) => {
|
|
|
85
86
|
}
|
|
86
87
|
});
|
|
87
88
|
document.readyState === "loading" ? document.addEventListener("DOMContentLoaded", () => {
|
|
88
|
-
r(),
|
|
89
|
-
}) : (r(),
|
|
89
|
+
r(), c.observe(document.body, { subtree: !0, childList: !0 });
|
|
90
|
+
}) : (r(), c.observe(document.body, { subtree: !0, childList: !0 }));
|
|
90
91
|
const p = "__EDDIE_RECIPES_VERSION__";
|
|
91
92
|
export {
|
|
92
93
|
p as EDDIE_RECIPES_VERSION,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { E as c } from "../../../chunks/EdElement.Dqh0Nrbq.js";
|
|
2
2
|
import "../../../chunks/card.peqD1u-M.js";
|
|
3
|
-
import "../../../chunks/heading.
|
|
3
|
+
import "../../../chunks/heading.DxaawzBz.js";
|
|
4
4
|
import { r as p, A as h, b as i, n as o } from "../../../chunks/lit.EWazi_Sp.js";
|
|
5
5
|
const f = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}:host{display:block}.ed-r-article-card__timestamp{font-family:var(--ed-theme-typography-meta-default-font-family);font-weight:var(--ed-theme-typography-meta-default-font-weight);font-size:var(--ed-theme-typography-meta-default-font-size);line-height:var(--ed-theme-typography-meta-default-line-height);letter-spacing:var(--ed-theme-typography-meta-default-letter-spacing);text-transform:var(--ed-theme-typography-meta-default-text-transform);margin:0;margin-block-end:.25rem;color:var(--ed-theme-color-content-subtle)}.ed-r-article-card__title{display:block}.ed-r-article-card__title:not(:last-child){margin-block-end:.5rem}.ed-r-article-card__title ::slotted(*){display:block;margin-block:0}.ed-r-article-card__excerpt{font-family:var(--ed-theme-typography-body-default-font-family);font-weight:var(--ed-theme-typography-body-default-font-weight);font-size:var(--ed-theme-typography-body-default-font-size);line-height:var(--ed-theme-typography-body-default-line-height);letter-spacing:var(--ed-theme-typography-body-default-letter-spacing);text-transform:var(--ed-theme-typography-body-default-text-transform);display:block}.ed-r-article-card__excerpt ::slotted(*){margin-block-start:0}.ed-r-article-card__excerpt ::slotted(:last-child){margin-block-end:0}';
|
|
6
6
|
var y = Object.defineProperty, l = (m, r, e, s) => {
|
|
@@ -5,7 +5,7 @@ import { E as N } from "../../../chunks/EdFormElement.DxDbDIOi.js";
|
|
|
5
5
|
import { n as $ } from "../../../chunks/index.browser.D527xXcp.js";
|
|
6
6
|
import "../../../chunks/icon.mc7zUxp5.js";
|
|
7
7
|
import "../../../chunks/select-field.DLVUo7yk.js";
|
|
8
|
-
import "../../../chunks/heading.
|
|
8
|
+
import "../../../chunks/heading.DxaawzBz.js";
|
|
9
9
|
const A = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}.ed-c-button-group{display:flex;align-items:center}.ed-c-button-group ::slotted(ed-button){margin-inline-end:1rem}.ed-c-button-group ::slotted(ed-button:last-child){margin-inline-end:0}.ed-c-button-group--stacked{flex-direction:column;align-items:initial}.ed-c-button-group--stacked ::slotted(ed-button){margin-block-end:.5rem}.ed-c-button-group--stacked ::slotted(ed-button:last-child){margin-block-end:0}.ed-c-button-group--responsive ::slotted(ed-button){margin-block-end:.5rem;margin-inline-end:0}@media all and (min-width:48rem){.ed-c-button-group--responsive ::slotted(ed-button){margin-inline-end:1rem;margin-block-end:0}}@media all and (max-width:48rem){.ed-c-button-group--responsive{flex-direction:column;align-items:initial}}';
|
|
10
10
|
var M = Object.defineProperty, U = (a, t, i, n) => {
|
|
11
11
|
for (var o = void 0, d = a.length - 1, r; d >= 0; d--)
|
|
@@ -1,29 +1,32 @@
|
|
|
1
1
|
import { E as p } from "../../../chunks/EdElement.Dqh0Nrbq.js";
|
|
2
2
|
import "../../../chunks/band.B0ez0GMJ.js";
|
|
3
3
|
import "../../../chunks/layout-container.C8MYJcgw.js";
|
|
4
|
-
import { r as
|
|
5
|
-
const y = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}.ed-c-page-header{margin-block-end:2rem}.ed-c-page-header__title{font-family:var(--ed-theme-typography-headline-lg-mobile-font-family);font-weight:var(--ed-theme-typography-headline-lg-mobile-font-weight);font-size:var(--ed-theme-typography-headline-lg-mobile-font-size);line-height:var(--ed-theme-typography-headline-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-page-header__title{font-family:var(--ed-theme-typography-headline-lg-font-family);font-weight:var(--ed-theme-typography-headline-lg-font-weight);font-size:var(--ed-theme-typography-headline-lg-font-size);line-height:var(--ed-theme-typography-headline-lg-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-text-transform)}}.ed-c-page-header__title{text-wrap:var(--ed-heading-text-wrap, balance);display:block;margin:0}.ed-c-page-header__title-after{display:inline-block;position:relative;inset-block-end:.625rem;margin-inline-start:1rem}.ed-c-page-header__description{font-family:var(--ed-theme-typography-body-default-font-family);font-weight:var(--ed-theme-typography-body-default-font-weight);font-size:var(--ed-theme-typography-body-default-font-size);line-height:var(--ed-theme-typography-body-default-line-height);letter-spacing:var(--ed-theme-typography-body-default-letter-spacing);text-transform:var(--ed-theme-typography-body-default-text-transform)}';
|
|
6
|
-
var
|
|
7
|
-
for (var e = void 0,
|
|
8
|
-
(o =
|
|
9
|
-
return e &&
|
|
4
|
+
import { r as m, b as r, A as d, n as l } from "../../../chunks/lit.EWazi_Sp.js";
|
|
5
|
+
const y = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}.ed-c-page-header{margin-block-end:2rem}.ed-c-page-header--center{text-align:center}.ed-c-page-header--center .ed-c-page-header__title--slotted{justify-content:center}.ed-c-page-header--right{text-align:right}.ed-c-page-header--right .ed-c-page-header__title--slotted{justify-content:flex-end}.ed-c-page-header__title{font-family:var(--ed-theme-typography-headline-lg-mobile-font-family);font-weight:var(--ed-theme-typography-headline-lg-mobile-font-weight);font-size:var(--ed-theme-typography-headline-lg-mobile-font-size);line-height:var(--ed-theme-typography-headline-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-page-header__title{font-family:var(--ed-theme-typography-headline-lg-font-family);font-weight:var(--ed-theme-typography-headline-lg-font-weight);font-size:var(--ed-theme-typography-headline-lg-font-size);line-height:var(--ed-theme-typography-headline-lg-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-text-transform)}}.ed-c-page-header__title{text-wrap:var(--ed-heading-text-wrap, balance);display:block;margin:0}.ed-c-page-header__title--slotted{display:flex;align-items:baseline;flex-wrap:wrap;gap:1rem}::slotted(:is(h1,h2,h3,h4,h5,h6)){margin:0}.ed-c-page-header__title-after{display:inline-block;position:relative;inset-block-end:.625rem;margin-inline-start:1rem}.ed-c-page-header__description{font-family:var(--ed-theme-typography-body-default-font-family);font-weight:var(--ed-theme-typography-body-default-font-weight);font-size:var(--ed-theme-typography-body-default-font-size);line-height:var(--ed-theme-typography-body-default-line-height);letter-spacing:var(--ed-theme-typography-body-default-letter-spacing);text-transform:var(--ed-theme-typography-body-default-text-transform)}';
|
|
6
|
+
var v = Object.defineProperty, c = (i, t, a, f) => {
|
|
7
|
+
for (var e = void 0, n = i.length - 1, o; n >= 0; n--)
|
|
8
|
+
(o = i[n]) && (e = o(t, a, e) || e);
|
|
9
|
+
return e && v(t, a, e), e;
|
|
10
10
|
};
|
|
11
|
-
class
|
|
11
|
+
class s extends p {
|
|
12
12
|
constructor() {
|
|
13
13
|
super(...arguments), this.heading = "Page header title";
|
|
14
14
|
}
|
|
15
15
|
static get styles() {
|
|
16
|
-
return
|
|
16
|
+
return m(y);
|
|
17
17
|
}
|
|
18
18
|
render() {
|
|
19
|
-
const t = this.componentClassNames("ed-c-page-header", {
|
|
20
|
-
|
|
19
|
+
const t = this.componentClassNames("ed-c-page-header", {
|
|
20
|
+
"ed-c-page-header--center": this.align === "center",
|
|
21
|
+
"ed-c-page-header--right": this.align === "right"
|
|
22
|
+
}), a = this.slotNotEmpty("titleAfter") ? r`<div class="ed-c-page-header__title-after">
|
|
23
|
+
<slot name="titleAfter"></slot>
|
|
24
|
+
</div>` : d;
|
|
25
|
+
return r`
|
|
21
26
|
<div class="${t}">
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
</div>`}
|
|
26
|
-
</h1>
|
|
27
|
+
${this.slotNotEmpty("heading") ? r`<div class="ed-c-page-header__title ed-c-page-header__title--slotted">
|
|
28
|
+
<slot name="heading"></slot>${a}
|
|
29
|
+
</div>` : r`<h1 class="ed-c-page-header__title">${this.heading}${a}</h1>`}
|
|
27
30
|
<div class="ed-c-page-header__description">
|
|
28
31
|
<slot></slot>
|
|
29
32
|
</div>
|
|
@@ -31,29 +34,32 @@ class m extends p {
|
|
|
31
34
|
`;
|
|
32
35
|
}
|
|
33
36
|
}
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
],
|
|
37
|
-
|
|
37
|
+
c([
|
|
38
|
+
l({ type: String })
|
|
39
|
+
], s.prototype, "heading");
|
|
40
|
+
c([
|
|
41
|
+
l()
|
|
42
|
+
], s.prototype, "align");
|
|
43
|
+
customElements.get("ed-page-header") === void 0 && customElements.define("ed-page-header", s);
|
|
38
44
|
const b = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}:host{display:block}.ed-r-page-banner__header{margin-block-end:.5rem}';
|
|
39
|
-
var _ = Object.defineProperty,
|
|
40
|
-
for (var e = void 0,
|
|
41
|
-
(o =
|
|
42
|
-
return e && _(t,
|
|
45
|
+
var _ = Object.defineProperty, g = (i, t, a, f) => {
|
|
46
|
+
for (var e = void 0, n = i.length - 1, o; n >= 0; n--)
|
|
47
|
+
(o = i[n]) && (e = o(t, a, e) || e);
|
|
48
|
+
return e && _(t, a, e), e;
|
|
43
49
|
};
|
|
44
|
-
class
|
|
50
|
+
class h extends p {
|
|
45
51
|
constructor() {
|
|
46
52
|
super(...arguments), this.heading = "";
|
|
47
53
|
}
|
|
48
54
|
static get styles() {
|
|
49
|
-
return
|
|
55
|
+
return m(b);
|
|
50
56
|
}
|
|
51
57
|
render() {
|
|
52
58
|
const t = this.componentClassNames("ed-r-page-banner", {});
|
|
53
|
-
return
|
|
59
|
+
return r`
|
|
54
60
|
<ed-band class="${t}" variant="${this.variant ?? d}">
|
|
55
61
|
<ed-layout-container variant="${this.containerVariant ?? d}">
|
|
56
|
-
${this.slotNotEmpty("header") ?
|
|
62
|
+
${this.slotNotEmpty("header") ? r`<div class="ed-r-page-banner__header">
|
|
57
63
|
<slot name="header"></slot>
|
|
58
64
|
</div>` : d}
|
|
59
65
|
<ed-page-header heading="${this.heading}">
|
|
@@ -66,9 +72,9 @@ class l extends p {
|
|
|
66
72
|
* query even when nothing is assigned to it, leaving a stray
|
|
67
73
|
* indent after every heading.
|
|
68
74
|
*/
|
|
69
|
-
this.slotNotEmpty("titleAfter") ?
|
|
75
|
+
this.slotNotEmpty("titleAfter") ? r`<slot name="titleAfter" slot="titleAfter"></slot>` : d}
|
|
70
76
|
</ed-page-header>
|
|
71
|
-
${this.slotNotEmpty("footer") ?
|
|
77
|
+
${this.slotNotEmpty("footer") ? r`<div class="ed-r-page-banner__footer">
|
|
72
78
|
<slot name="footer"></slot>
|
|
73
79
|
</div>` : d}
|
|
74
80
|
</ed-layout-container>
|
|
@@ -76,16 +82,16 @@ class l extends p {
|
|
|
76
82
|
`;
|
|
77
83
|
}
|
|
78
84
|
}
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
],
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
],
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
],
|
|
88
|
-
customElements.get("ed-r-page-banner") === void 0 && customElements.define("ed-r-page-banner",
|
|
85
|
+
g([
|
|
86
|
+
l()
|
|
87
|
+
], h.prototype, "heading");
|
|
88
|
+
g([
|
|
89
|
+
l({ reflect: !0 })
|
|
90
|
+
], h.prototype, "variant");
|
|
91
|
+
g([
|
|
92
|
+
l()
|
|
93
|
+
], h.prototype, "containerVariant");
|
|
94
|
+
customElements.get("ed-r-page-banner") === void 0 && customElements.define("ed-r-page-banner", h);
|
|
89
95
|
export {
|
|
90
|
-
|
|
96
|
+
h as EdRPageBanner
|
|
91
97
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { E as h } from "../../../chunks/EdElement.Dqh0Nrbq.js";
|
|
2
|
-
import "../../../chunks/heading.
|
|
2
|
+
import "../../../chunks/heading.DxaawzBz.js";
|
|
3
3
|
import "../../../chunks/text-passage.BEu9bNtm.js";
|
|
4
4
|
import { r as p, A as c, b as d, n as t } from "../../../chunks/lit.EWazi_Sp.js";
|
|
5
5
|
const m = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}.ed-r-project-card{display:flex;flex-direction:column;height:100%;border-width:var(--ed-theme-border-width-sm);border-style:solid;border-color:var(--ed-theme-color-border-subtle);border-radius:var(--ed-theme-border-radius-md);box-shadow:var(--ed-theme-box-shadow-md);background:var(--ed-theme-color-background-default);overflow:hidden}.ed-r-project-card__media{flex:none}.ed-r-project-card__img{display:block;width:100%;height:auto;object-fit:cover}.ed-r-project-card__body{display:flex;flex-direction:column;flex:1 0 auto;padding:1.5rem;gap:.5rem}.ed-r-project-card__title{display:block}.ed-r-project-card__link{color:inherit;text-decoration:none;border-block-end:var(--ed-theme-border-width-sm) solid transparent;transition:border-color var(--ed-theme-animation-fade-quick) var(--ed-theme-animation-ease)}.ed-r-project-card__link:hover,.ed-r-project-card__link:focus-visible{color:inherit;border-block-end-color:var(--ed-heading-link-color-border, var(--ed-theme-color-border-brand))}.ed-r-project-card__link:focus-visible{outline:var(--ed-theme-border-width-lg) solid var(--ed-theme-focus-ring-color-border-default);outline-offset:var(--ed-theme-offset-focus-ring, .25rem)}.ed-r-project-card__description{display:block}';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { E as c } from "../../../chunks/EdElement.Dqh0Nrbq.js";
|
|
2
2
|
import "../../../chunks/card.peqD1u-M.js";
|
|
3
|
-
import "../../../chunks/heading.
|
|
3
|
+
import "../../../chunks/heading.DxaawzBz.js";
|
|
4
4
|
import { r as g, b as a, A as n, n as o } from "../../../chunks/lit.EWazi_Sp.js";
|
|
5
5
|
const y = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}:host{display:block}.ed-r-speaking-card__meta{font-family:var(--ed-theme-typography-meta-default-font-family);font-weight:var(--ed-theme-typography-meta-default-font-weight);font-size:var(--ed-theme-typography-meta-default-font-size);line-height:var(--ed-theme-typography-meta-default-line-height);letter-spacing:var(--ed-theme-typography-meta-default-letter-spacing);text-transform:var(--ed-theme-typography-meta-default-text-transform);display:flex;flex-wrap:wrap;gap:.125rem;margin:0;margin-block-end:.25rem;color:var(--ed-theme-color-content-subtle)}.ed-r-speaking-card__separator{color:var(--ed-theme-color-content-subtle)}.ed-r-speaking-card__title{display:block}.ed-r-speaking-card__title:not(:last-child){margin-block-end:.25rem}.ed-r-speaking-card__title ::slotted(*){display:block;margin-block:0}.ed-r-speaking-card__note{font-family:var(--ed-theme-typography-body-default-font-family);font-weight:var(--ed-theme-typography-body-default-font-weight);font-size:var(--ed-theme-typography-body-default-font-size);line-height:var(--ed-theme-typography-body-default-line-height);letter-spacing:var(--ed-theme-typography-body-default-letter-spacing);text-transform:var(--ed-theme-typography-body-default-text-transform);display:block}.ed-r-speaking-card__note:not(:last-child){margin-block-end:.25rem}.ed-r-speaking-card__note ::slotted(*){margin-block-start:0;margin-block-end:.25rem}.ed-r-speaking-card__note ::slotted(:last-child){margin-block-end:0}.ed-r-speaking-card__materials{display:block}';
|
|
6
6
|
var f = Object.defineProperty, l = (m, e, t, i) => {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { E as h } from "../../../chunks/EdElement.Dqh0Nrbq.js";
|
|
2
2
|
import "../../../chunks/card.peqD1u-M.js";
|
|
3
|
-
import "../../../chunks/heading.
|
|
3
|
+
import "../../../chunks/heading.DxaawzBz.js";
|
|
4
4
|
import "../../../chunks/text-passage.BEu9bNtm.js";
|
|
5
5
|
import { r as m, A as c, b as o, n as s } from "../../../chunks/lit.EWazi_Sp.js";
|
|
6
6
|
const u = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}.ed-r-stat-card__label{display:block;margin-block-end:.25rem}.ed-r-stat-card__value{display:block;margin:0;font-variant-numeric:tabular-nums}.ed-r-stat-card__value:not(:last-child){margin-block-end:.25rem}.ed-r-stat-card__meta{display:block}.ed-r-stat-card--positive .ed-r-stat-card__value{color:var(--ed-theme-color-content-utility-success)}.ed-r-stat-card--warning .ed-r-stat-card__value{color:var(--ed-theme-color-content-utility-warning)}.ed-r-stat-card--danger .ed-r-stat-card__value{color:var(--ed-theme-color-content-utility-error)}';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { E as d } from "../../../chunks/EdElement.Dqh0Nrbq.js";
|
|
2
2
|
import "../../../chunks/timeline-node.CmEn0wf_.js";
|
|
3
|
-
import "../../../chunks/heading.
|
|
3
|
+
import "../../../chunks/heading.DxaawzBz.js";
|
|
4
4
|
import { A as o, b as m, n as i } from "../../../chunks/lit.EWazi_Sp.js";
|
|
5
5
|
var p = Object.defineProperty, r = (l, e, a, h) => {
|
|
6
6
|
for (var t = void 0, n = l.length - 1, c; n >= 0; n--)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { E as c } from "../../../chunks/EdElement.Dqh0Nrbq.js";
|
|
2
2
|
import "../../../chunks/timeline-node.CmEn0wf_.js";
|
|
3
|
-
import "../../../chunks/heading.
|
|
3
|
+
import "../../../chunks/heading.DxaawzBz.js";
|
|
4
4
|
import { r as p, b as r, A as d, n as i } from "../../../chunks/lit.EWazi_Sp.js";
|
|
5
5
|
const f = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}:host{display:block}.ed-r-timeline-node__body{display:flex;flex-direction:column;gap:.25rem;text-align:inherit}.ed-r-timeline-node__eyebrow{font-family:var(--ed-theme-typography-meta-default-font-family);font-weight:var(--ed-theme-typography-meta-default-font-weight);font-size:var(--ed-theme-typography-meta-default-font-size);line-height:var(--ed-theme-typography-meta-default-line-height);letter-spacing:var(--ed-theme-typography-meta-default-letter-spacing);text-transform:var(--ed-theme-typography-meta-default-text-transform);color:var(--ed-theme-color-content-subtle);text-transform:uppercase;letter-spacing:.04em}.ed-r-timeline-node__date{font-family:var(--ed-theme-typography-meta-default-font-family);font-weight:var(--ed-theme-typography-meta-default-font-weight);font-size:var(--ed-theme-typography-meta-default-font-size);line-height:var(--ed-theme-typography-meta-default-line-height);letter-spacing:var(--ed-theme-typography-meta-default-letter-spacing);text-transform:var(--ed-theme-typography-meta-default-text-transform);color:var(--ed-theme-color-content-subtle)}.ed-r-timeline-node__heading{display:block;color:var(--ed-c-timeline-node-heading-color, inherit)}.ed-r-timeline-node__link{color:inherit;text-decoration:none;border-block-end:var(--ed-theme-border-width-sm) solid transparent;transition:border-color var(--ed-theme-animation-fade-quick) var(--ed-theme-animation-ease)}.ed-r-timeline-node__link:hover,.ed-r-timeline-node__link:focus-visible{color:inherit;border-block-end-color:var(--ed-heading-link-color-border, var(--ed-theme-color-border-brand))}.ed-r-timeline-node__link:focus-visible{outline:var(--ed-theme-border-width-lg) solid var(--ed-theme-focus-ring-color-border-default);outline-offset:var(--ed-theme-offset-focus-ring, .25rem)}';
|
|
6
6
|
var g = Object.defineProperty, o = (l, a, n, h) => {
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { E as m } from "../../../chunks/EdElement.Dqh0Nrbq.js";
|
|
2
|
+
import { r as n, A as p, o as b, b as c, n as s } from "../../../chunks/lit.EWazi_Sp.js";
|
|
3
|
+
const v = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}:host{display:block;margin-block-end:2rem}.ed-r-video-embed{position:relative;overflow:hidden;aspect-ratio:16/9;background:var(--ed-theme-color-background-subtle)}.ed-r-video-embed__frame{position:absolute;inset:0;display:block;width:100%;height:100%;border:0}.ed-r-video-embed ::slotted(iframe){position:absolute;inset:0;display:block;width:100%!important;height:100%!important;border:0}.ed-r-video-embed--ratio-16-9{aspect-ratio:16/9}.ed-r-video-embed--ratio-21-9{aspect-ratio:21/9}.ed-r-video-embed--ratio-4-3{aspect-ratio:4/3}.ed-r-video-embed--ratio-3-2{aspect-ratio:3/2}.ed-r-video-embed--ratio-1-1{aspect-ratio:1/1}.ed-r-video-embed--ratio-4-5{aspect-ratio:4/5}.ed-r-video-embed--ratio-9-16{aspect-ratio:9/16}';
|
|
4
|
+
var h = Object.defineProperty, a = (i, t, o, f) => {
|
|
5
|
+
for (var e = void 0, d = i.length - 1, l; d >= 0; d--)
|
|
6
|
+
(l = i[d]) && (e = l(t, o, e) || e);
|
|
7
|
+
return e && h(t, o, e), e;
|
|
8
|
+
};
|
|
9
|
+
const u = ["16:9", "21:9", "4:3", "3:2", "1:1", "4:5", "9:16"];
|
|
10
|
+
class r extends m {
|
|
11
|
+
constructor() {
|
|
12
|
+
super(...arguments), this.videoTitle = "", this.ratio = "16:9";
|
|
13
|
+
}
|
|
14
|
+
static get styles() {
|
|
15
|
+
return n(v);
|
|
16
|
+
}
|
|
17
|
+
render() {
|
|
18
|
+
const t = this.componentClassNames("ed-r-video-embed", {
|
|
19
|
+
[`ed-r-video-embed--ratio-${this.ratio.replace(":", "-")}`]: u.includes(this.ratio)
|
|
20
|
+
}), o = this.querySelector(":scope > *:not([slot])") !== null;
|
|
21
|
+
return c`
|
|
22
|
+
<div class="${t}" part="frame">
|
|
23
|
+
${o || !this.src ? p : c`<iframe
|
|
24
|
+
class="ed-r-video-embed__frame"
|
|
25
|
+
src="${this.src}"
|
|
26
|
+
title="${b(this.videoTitle || void 0)}"
|
|
27
|
+
loading="lazy"
|
|
28
|
+
allow="accelerometer; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
|
29
|
+
allowfullscreen
|
|
30
|
+
></iframe>`}
|
|
31
|
+
<slot></slot>
|
|
32
|
+
</div>
|
|
33
|
+
`;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
a([
|
|
37
|
+
s()
|
|
38
|
+
], r.prototype, "src");
|
|
39
|
+
a([
|
|
40
|
+
s()
|
|
41
|
+
], r.prototype, "videoTitle");
|
|
42
|
+
a([
|
|
43
|
+
s({ reflect: !0 })
|
|
44
|
+
], r.prototype, "ratio");
|
|
45
|
+
customElements.get("ed-r-video-embed") === void 0 && customElements.define("ed-r-video-embed", r);
|
|
46
|
+
export {
|
|
47
|
+
r as EdRVideoEmbed
|
|
48
|
+
};
|
package/package.json
CHANGED
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
import { EdElement } from '@brad-frost-web/eddie-web-components/components/EdElement.js';
|
|
2
|
+
/**
|
|
3
|
+
* Shape vocabulary, deliberately identical to `ed-r-visualzzz` — the system's
|
|
4
|
+
* other third-party embed recipe. Two embeds with two different ratio
|
|
5
|
+
* spellings would be a papercut every consumer hits.
|
|
6
|
+
*/
|
|
7
|
+
declare const RATIOS: readonly ["16:9", "21:9", "4:3", "3:2", "1:1", "4:5", "9:16"];
|
|
8
|
+
type VideoEmbedRatio = typeof RATIOS[number];
|
|
9
|
+
/**
|
|
10
|
+
* Responsive wrapper for a third-party video embed (YouTube, Vimeo, or any
|
|
11
|
+
* provider that hands you an `<iframe>`).
|
|
12
|
+
*
|
|
13
|
+
* A provider's embed snippet ships fixed `width`/`height` attributes, so
|
|
14
|
+
* dropping it into a fluid column overflows on small screens. The long-standing
|
|
15
|
+
* fix is a ratio box with an absolutely-filled iframe, which every content site
|
|
16
|
+
* has historically hand-rolled as a local `.video-embed` class. This recipe is
|
|
17
|
+
* that pattern, owned by the system and sized from tokens (#1392).
|
|
18
|
+
*
|
|
19
|
+
* Two authoring forms, and the choice matters:
|
|
20
|
+
*
|
|
21
|
+
* ```html
|
|
22
|
+
* <!-- Slot the provider's own iframe. Preferred for existing content: a
|
|
23
|
+
* content transform can wrap what is already there without reconstructing
|
|
24
|
+
* the URL, and the provider's own params survive untouched. -->
|
|
25
|
+
* <ed-r-video-embed>
|
|
26
|
+
* <iframe src="https://www.youtube.com/embed/VIDEO_ID"
|
|
27
|
+
* title="Atomic Design — Brad Frost" allowfullscreen></iframe>
|
|
28
|
+
* </ed-r-video-embed>
|
|
29
|
+
*
|
|
30
|
+
* <!-- Or let the recipe build the iframe. Convenient for new content. -->
|
|
31
|
+
* <ed-r-video-embed src="https://www.youtube.com/embed/VIDEO_ID"
|
|
32
|
+
* videoTitle="Atomic Design — Brad Frost"></ed-r-video-embed>
|
|
33
|
+
* ```
|
|
34
|
+
*
|
|
35
|
+
* Slotted content always wins over `src`, so a page can mix both forms.
|
|
36
|
+
*
|
|
37
|
+
* @recipe declarative
|
|
38
|
+
*
|
|
39
|
+
* @use Embedding a YouTube or Vimeo video in a blog post or article body
|
|
40
|
+
* @use Wrapping legacy embed markup during a content migration — slot the existing `<iframe>` and the recipe supplies the responsive box around it
|
|
41
|
+
* @use Any third-party `<iframe>` that needs to hold a fixed aspect ratio in a fluid column
|
|
42
|
+
* @use Non-16:9 material — a vertical phone-shot clip is `ratio="9:16"`, a classic-TV-era clip is `ratio="4:3"`
|
|
43
|
+
*
|
|
44
|
+
* @dontuse For self-hosted video you control — use a native `<video>` element, which gives you real controls, captions, and preload behavior an iframe cannot
|
|
45
|
+
* @dontuse As a general third-party embed wrapper — the ratio vocabulary is video-shaped; use `ed-r-visualzzz` for embedded visuals and a purpose-built recipe for anything else
|
|
46
|
+
* @dontuse With `autoplay` in the embed URL — video that starts on its own is a WCAG 1.4.2 failure and is hostile on metered connections
|
|
47
|
+
* @dontuse To lazy-load a poster/facade and swap in the player on click — deliberately out of scope; this recipe always mounts the real iframe
|
|
48
|
+
*
|
|
49
|
+
* @a11y **Always name the video** — `videoTitle` when the recipe builds the iframe, or a `title` attribute on your own when you slot one. An `<iframe>` with no accessible name is announced as an unlabelled frame, so a screen-reader user has no idea what it contains — axe flags it as a serious violation (`frame-title`, WCAG 4.1.2). Name the video, not the medium: "Atomic Design — Brad Frost", never "YouTube video player" or "Video".
|
|
50
|
+
* @a11y Never add `autoplay` to the embed URL. Media that starts by itself fails WCAG 1.4.2 (Audio Control) when it runs past three seconds with no way to stop it, and it competes with a screen reader's own speech.
|
|
51
|
+
* @a11y The recipe reserves the video's space with `aspect-ratio` before the iframe loads, so the page does not reflow under a reader who has already started moving through it.
|
|
52
|
+
* @a11y `allowfullscreen` is set on the generated iframe so keyboard users can reach the player's fullscreen control; keep it when you slot your own.
|
|
53
|
+
* @a11y Captions are the provider's responsibility, not this recipe's — a video carrying dialogue needs real captions on the platform to meet WCAG 1.2.2, and no wrapper can supply them.
|
|
54
|
+
*
|
|
55
|
+
* @anatomy A ratio-constrained block (`aspect-ratio`, token background as the pre-load floor) containing exactly one `<iframe>` — either the author's slotted one or one the recipe builds from `src`, absolutely filling the box.
|
|
56
|
+
*
|
|
57
|
+
* @related ed-r-visualzzz — the other third-party embed recipe, for generative visuals rather than video; shares this ratio vocabulary
|
|
58
|
+
* @related ed-figure — wrap this in one when the video needs a caption
|
|
59
|
+
* @related ed-text-passage — the usual host, an article body
|
|
60
|
+
*
|
|
61
|
+
* @content The recipe renders no words of its own. The one string you own is `videoTitle`, and it is load-bearing: it is the video's accessible name. Write what the video IS ("Atomic Design — Brad Frost"), not what it is delivered by ("YouTube video player").
|
|
62
|
+
*
|
|
63
|
+
* @state Static. The only axis is `ratio`, which reserves the box's shape. There is no loading, error, or playing state — playback lives entirely inside the provider's iframe, and the recipe deliberately owns none of it.
|
|
64
|
+
*
|
|
65
|
+
* @slot - (default) The provider's own `<iframe>`. Slotting wins over `src`. Use this when the embed markup already exists — a content migration should wrap what is there rather than rebuild the URL.
|
|
66
|
+
*
|
|
67
|
+
* @csspart frame - The ratio-constrained box wrapping the iframe
|
|
68
|
+
*/
|
|
69
|
+
export declare class EdRVideoEmbed extends EdElement {
|
|
70
|
+
static get styles(): import('lit').CSSResult;
|
|
71
|
+
/**
|
|
72
|
+
* The provider's embed URL — the `/embed/` form, not the page you watch on.
|
|
73
|
+
* YouTube's `https://www.youtube.com/embed/VIDEO_ID`, Vimeo's
|
|
74
|
+
* `https://player.vimeo.com/video/VIDEO_ID`. A normal `watch?v=` link renders
|
|
75
|
+
* a refused-to-connect frame, because providers block framing of the watch page.
|
|
76
|
+
*
|
|
77
|
+
* Ignored when an `<iframe>` is slotted.
|
|
78
|
+
*/
|
|
79
|
+
src?: string;
|
|
80
|
+
/**
|
|
81
|
+
* The video's accessible name, forwarded to the generated iframe's `title`.
|
|
82
|
+
*
|
|
83
|
+
* Not optional in practice: an unnamed frame is announced as an unlabelled
|
|
84
|
+
* region, and axe flags it (`frame-title`). Name the video — "Atomic Design —
|
|
85
|
+
* Brad Frost" — not the medium. When you slot your own iframe, put the title
|
|
86
|
+
* on that element instead; this property only feeds the generated one.
|
|
87
|
+
*
|
|
88
|
+
* Named `videoTitle` rather than `title` on purpose. A reactive property
|
|
89
|
+
* called `title` would shadow `HTMLElement.prototype.title` (the same
|
|
90
|
+
* collision class as #1485) and, worse, a `title` attribute on the host paints
|
|
91
|
+
* a native browser tooltip over the whole embed on hover — which is not what
|
|
92
|
+
* anyone means by naming a video.
|
|
93
|
+
*/
|
|
94
|
+
videoTitle: string;
|
|
95
|
+
/**
|
|
96
|
+
* Shape of the reserved box. `16:9` is the modern default and right for
|
|
97
|
+
* nearly all web video; reach for the others when the source material is
|
|
98
|
+
* genuinely a different shape — `4:3` for pre-HD footage, `9:16` for a
|
|
99
|
+
* vertical phone clip.
|
|
100
|
+
*
|
|
101
|
+
* Matches `ed-r-visualzzz`'s vocabulary exactly.
|
|
102
|
+
*/
|
|
103
|
+
ratio: VideoEmbedRatio;
|
|
104
|
+
render(): import('lit-html').TemplateResult<1>;
|
|
105
|
+
}
|
|
106
|
+
declare global {
|
|
107
|
+
interface HTMLElementTagNameMap {
|
|
108
|
+
'ed-r-video-embed': EdRVideoEmbed;
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
export {};
|
|
112
|
+
//# sourceMappingURL=video-embed.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"video-embed.d.ts","sourceRoot":"","sources":["../../../../../packages/eddie-recipes/recipes/common/video-embed/video-embed.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,8DAA8D,CAAC;AAMzF;;;;GAIG;AACH,QAAA,MAAM,MAAM,+DAAgE,CAAC;AAE7E,KAAK,eAAe,GAAG,OAAO,MAAM,CAAC,MAAM,CAAC,CAAC;AAE7C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2DG;AACH,qBAAa,aAAc,SAAQ,SAAS;IAC1C,MAAM,KAAK,MAAM,4BAEhB;IAED;;;;;;;OAOG;IAEH,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb;;;;;;;;;;;;;OAaG;IAEH,UAAU,SAAM;IAEhB;;;;;;;OAOG;IAEH,KAAK,EAAE,eAAe,CAAU;IAEhC,MAAM;CA+BP;AAMD,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,kBAAkB,EAAE,aAAa,CAAC;KACnC;CACF"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { EdElement as n } from "@brad-frost-web/eddie-web-components/components/EdElement.js";
|
|
2
|
+
import { unsafeCSS as c, nothing as p, html as m } from "lit";
|
|
3
|
+
import { property as s } from "lit/decorators.js";
|
|
4
|
+
import { ifDefined as b } from "lit/directives/if-defined.js";
|
|
5
|
+
const h = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}:host{display:block;margin-block-end:2rem}.ed-r-video-embed{position:relative;overflow:hidden;aspect-ratio:16/9;background:var(--ed-theme-color-background-subtle)}.ed-r-video-embed__frame{position:absolute;inset:0;display:block;width:100%;height:100%;border:0}.ed-r-video-embed ::slotted(iframe){position:absolute;inset:0;display:block;width:100%!important;height:100%!important;border:0}.ed-r-video-embed--ratio-16-9{aspect-ratio:16/9}.ed-r-video-embed--ratio-21-9{aspect-ratio:21/9}.ed-r-video-embed--ratio-4-3{aspect-ratio:4/3}.ed-r-video-embed--ratio-3-2{aspect-ratio:3/2}.ed-r-video-embed--ratio-1-1{aspect-ratio:1/1}.ed-r-video-embed--ratio-4-5{aspect-ratio:4/5}.ed-r-video-embed--ratio-9-16{aspect-ratio:9/16}';
|
|
6
|
+
var v = Object.defineProperty, a = (i, t, o, u) => {
|
|
7
|
+
for (var e = void 0, d = i.length - 1, l; d >= 0; d--)
|
|
8
|
+
(l = i[d]) && (e = l(t, o, e) || e);
|
|
9
|
+
return e && v(t, o, e), e;
|
|
10
|
+
};
|
|
11
|
+
const f = ["16:9", "21:9", "4:3", "3:2", "1:1", "4:5", "9:16"];
|
|
12
|
+
class r extends n {
|
|
13
|
+
constructor() {
|
|
14
|
+
super(...arguments), this.videoTitle = "", this.ratio = "16:9";
|
|
15
|
+
}
|
|
16
|
+
static get styles() {
|
|
17
|
+
return c(h);
|
|
18
|
+
}
|
|
19
|
+
render() {
|
|
20
|
+
const t = this.componentClassNames("ed-r-video-embed", {
|
|
21
|
+
[`ed-r-video-embed--ratio-${this.ratio.replace(":", "-")}`]: f.includes(this.ratio)
|
|
22
|
+
}), o = this.querySelector(":scope > *:not([slot])") !== null;
|
|
23
|
+
return m`
|
|
24
|
+
<div class="${t}" part="frame">
|
|
25
|
+
${o || !this.src ? p : m`<iframe
|
|
26
|
+
class="ed-r-video-embed__frame"
|
|
27
|
+
src="${this.src}"
|
|
28
|
+
title="${b(this.videoTitle || void 0)}"
|
|
29
|
+
loading="lazy"
|
|
30
|
+
allow="accelerometer; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
|
31
|
+
allowfullscreen
|
|
32
|
+
></iframe>`}
|
|
33
|
+
<slot></slot>
|
|
34
|
+
</div>
|
|
35
|
+
`;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
a([
|
|
39
|
+
s()
|
|
40
|
+
], r.prototype, "src");
|
|
41
|
+
a([
|
|
42
|
+
s()
|
|
43
|
+
], r.prototype, "videoTitle");
|
|
44
|
+
a([
|
|
45
|
+
s({ reflect: !0 })
|
|
46
|
+
], r.prototype, "ratio");
|
|
47
|
+
customElements.get("ed-r-video-embed") === void 0 && customElements.define("ed-r-video-embed", r);
|
|
48
|
+
export {
|
|
49
|
+
r as EdRVideoEmbed
|
|
50
|
+
};
|
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
import { r as g, b as a, n as r } from "./lit.EWazi_Sp.js";
|
|
2
|
-
import { E as y } from "./EdElement.Dqh0Nrbq.js";
|
|
3
|
-
const p = '@charset "UTF-8";:root,:host{--size-base-unit: .5rem}*,::slotted(*),*:before,*:after{box-sizing:border-box}h1,h2,h3,h4,h5,h6{margin:0}.ed-c-heading{text-wrap:var(--ed-heading-text-wrap, balance);margin:0}.ed-c-heading--wrap-balance{--ed-heading-text-wrap: balance}.ed-c-heading--wrap-pretty{--ed-heading-text-wrap: pretty}.ed-c-heading--wrap-normal{--ed-heading-text-wrap: normal}::slotted(a){color:inherit;text-decoration:none;border-block-end:var(--ed-theme-border-width-sm) solid transparent;transition:border-color var(--ed-theme-animation-fade-quick) var(--ed-theme-animation-ease)}::slotted(a:hover),::slotted(a:focus-visible){color:inherit;border-block-end-color:var(--ed-heading-link-color-border, var(--ed-theme-color-border-brand))}::slotted(a:focus-visible){outline:var(--ed-theme-border-width-lg) solid var(--ed-theme-focus-ring-color-border-default);outline-offset:var(--ed-theme-offset-focus-ring, .25rem)}.ed-c-heading--display-xl{font-family:var(--ed-theme-typography-display-xl-mobile-font-family);font-weight:var(--ed-theme-typography-display-xl-mobile-font-weight);font-size:var(--ed-theme-typography-display-xl-mobile-font-size);line-height:var(--ed-theme-typography-display-xl-mobile-line-height);letter-spacing:var(--ed-theme-typography-display-xl-mobile-letter-spacing);text-transform:var(--ed-theme-typography-display-xl-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--display-xl{font-family:var(--ed-theme-typography-display-xl-tablet-font-family);font-weight:var(--ed-theme-typography-display-xl-tablet-font-weight);font-size:var(--ed-theme-typography-display-xl-tablet-font-size);line-height:var(--ed-theme-typography-display-xl-tablet-line-height);letter-spacing:var(--ed-theme-typography-display-xl-tablet-letter-spacing);text-transform:var(--ed-theme-typography-display-xl-tablet-text-transform)}}@media all and (min-width:75rem){.ed-c-heading--display-xl{font-family:var(--ed-theme-typography-display-xl-font-family);font-weight:var(--ed-theme-typography-display-xl-font-weight);font-size:var(--ed-theme-typography-display-xl-font-size);line-height:var(--ed-theme-typography-display-xl-line-height);letter-spacing:var(--ed-theme-typography-display-xl-letter-spacing);text-transform:var(--ed-theme-typography-display-xl-text-transform)}}.ed-c-heading--display-lg{font-family:var(--ed-theme-typography-display-lg-mobile-font-family);font-weight:var(--ed-theme-typography-display-lg-mobile-font-weight);font-size:var(--ed-theme-typography-display-lg-mobile-font-size);line-height:var(--ed-theme-typography-display-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-display-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-display-lg-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--display-lg{font-family:var(--ed-theme-typography-display-lg-font-family);font-weight:var(--ed-theme-typography-display-lg-font-weight);font-size:var(--ed-theme-typography-display-lg-font-size);line-height:var(--ed-theme-typography-display-lg-line-height);letter-spacing:var(--ed-theme-typography-display-lg-letter-spacing);text-transform:var(--ed-theme-typography-display-lg-text-transform)}}.ed-c-heading--display-default{font-family:var(--ed-theme-typography-display-default-mobile-font-family);font-weight:var(--ed-theme-typography-display-default-mobile-font-weight);font-size:var(--ed-theme-typography-display-default-mobile-font-size);line-height:var(--ed-theme-typography-display-default-mobile-line-height);letter-spacing:var(--ed-theme-typography-display-default-mobile-letter-spacing);text-transform:var(--ed-theme-typography-display-default-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--display-default{font-family:var(--ed-theme-typography-display-default-font-family);font-weight:var(--ed-theme-typography-display-default-font-weight);font-size:var(--ed-theme-typography-display-default-font-size);line-height:var(--ed-theme-typography-display-default-line-height);letter-spacing:var(--ed-theme-typography-display-default-letter-spacing);text-transform:var(--ed-theme-typography-display-default-text-transform)}}.ed-c-heading--headline-lg{font-family:var(--ed-theme-typography-headline-lg-mobile-font-family);font-weight:var(--ed-theme-typography-headline-lg-mobile-font-weight);font-size:var(--ed-theme-typography-headline-lg-mobile-font-size);line-height:var(--ed-theme-typography-headline-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--headline-lg{font-family:var(--ed-theme-typography-headline-lg-font-family);font-weight:var(--ed-theme-typography-headline-lg-font-weight);font-size:var(--ed-theme-typography-headline-lg-font-size);line-height:var(--ed-theme-typography-headline-lg-line-height);letter-spacing:var(--ed-theme-typography-headline-lg-letter-spacing);text-transform:var(--ed-theme-typography-headline-lg-text-transform)}}.ed-c-heading--headline-default{font-family:var(--ed-theme-typography-headline-default-mobile-font-family);font-weight:var(--ed-theme-typography-headline-default-mobile-font-weight);font-size:var(--ed-theme-typography-headline-default-mobile-font-size);line-height:var(--ed-theme-typography-headline-default-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-default-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-default-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--headline-default{font-family:var(--ed-theme-typography-headline-default-font-family);font-weight:var(--ed-theme-typography-headline-default-font-weight);font-size:var(--ed-theme-typography-headline-default-font-size);line-height:var(--ed-theme-typography-headline-default-line-height);letter-spacing:var(--ed-theme-typography-headline-default-letter-spacing);text-transform:var(--ed-theme-typography-headline-default-text-transform)}}.ed-c-heading--headline-sm{font-family:var(--ed-theme-typography-headline-sm-mobile-font-family);font-weight:var(--ed-theme-typography-headline-sm-mobile-font-weight);font-size:var(--ed-theme-typography-headline-sm-mobile-font-size);line-height:var(--ed-theme-typography-headline-sm-mobile-line-height);letter-spacing:var(--ed-theme-typography-headline-sm-mobile-letter-spacing);text-transform:var(--ed-theme-typography-headline-sm-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--headline-sm{font-family:var(--ed-theme-typography-headline-sm-font-family);font-weight:var(--ed-theme-typography-headline-sm-font-weight);font-size:var(--ed-theme-typography-headline-sm-font-size);line-height:var(--ed-theme-typography-headline-sm-line-height);letter-spacing:var(--ed-theme-typography-headline-sm-letter-spacing);text-transform:var(--ed-theme-typography-headline-sm-text-transform)}}.ed-c-heading--title-lg{font-family:var(--ed-theme-typography-title-lg-mobile-font-family);font-weight:var(--ed-theme-typography-title-lg-mobile-font-weight);font-size:var(--ed-theme-typography-title-lg-mobile-font-size);line-height:var(--ed-theme-typography-title-lg-mobile-line-height);letter-spacing:var(--ed-theme-typography-title-lg-mobile-letter-spacing);text-transform:var(--ed-theme-typography-title-lg-mobile-text-transform)}@media all and (min-width:48rem){.ed-c-heading--title-lg{font-family:var(--ed-theme-typography-title-lg-font-family);font-weight:var(--ed-theme-typography-title-lg-font-weight);font-size:var(--ed-theme-typography-title-lg-font-size);line-height:var(--ed-theme-typography-title-lg-line-height);letter-spacing:var(--ed-theme-typography-title-lg-letter-spacing);text-transform:var(--ed-theme-typography-title-lg-text-transform)}}.ed-c-heading--title-default{font-family:var(--ed-theme-typography-title-default-font-family);font-weight:var(--ed-theme-typography-title-default-font-weight);font-size:var(--ed-theme-typography-title-default-font-size);line-height:var(--ed-theme-typography-title-default-line-height);letter-spacing:var(--ed-theme-typography-title-default-letter-spacing);text-transform:var(--ed-theme-typography-title-default-text-transform)}.ed-c-heading--title-sm{font-family:var(--ed-theme-typography-title-sm-font-family);font-weight:var(--ed-theme-typography-title-sm-font-weight);font-size:var(--ed-theme-typography-title-sm-font-size);line-height:var(--ed-theme-typography-title-sm-line-height);letter-spacing:var(--ed-theme-typography-title-sm-letter-spacing);text-transform:var(--ed-theme-typography-title-sm-text-transform)}.ed-c-heading--label-lg{font-family:var(--ed-theme-typography-label-lg-font-family);font-weight:var(--ed-theme-typography-label-lg-font-weight);font-size:var(--ed-theme-typography-label-lg-font-size);line-height:var(--ed-theme-typography-label-lg-line-height);letter-spacing:var(--ed-theme-typography-label-lg-letter-spacing);text-transform:var(--ed-theme-typography-label-lg-text-transform)}.ed-c-heading--label-default{font-family:var(--ed-theme-typography-label-default-font-family);font-weight:var(--ed-theme-typography-label-default-font-weight);font-size:var(--ed-theme-typography-label-default-font-size);line-height:var(--ed-theme-typography-label-default-line-height);letter-spacing:var(--ed-theme-typography-label-default-letter-spacing);text-transform:var(--ed-theme-typography-label-default-text-transform)}.ed-c-heading--label-sm{font-family:var(--ed-theme-typography-label-sm-font-family);font-weight:var(--ed-theme-typography-label-sm-font-weight);font-size:var(--ed-theme-typography-label-sm-font-size);line-height:var(--ed-theme-typography-label-sm-line-height);letter-spacing:var(--ed-theme-typography-label-sm-letter-spacing);text-transform:var(--ed-theme-typography-label-sm-text-transform)}.ed-c-heading--body-lg{font-family:var(--ed-theme-typography-body-lg-font-family);font-weight:var(--ed-theme-typography-body-lg-font-weight);font-size:var(--ed-theme-typography-body-lg-font-size);line-height:var(--ed-theme-typography-body-lg-line-height);letter-spacing:var(--ed-theme-typography-body-lg-letter-spacing);text-transform:var(--ed-theme-typography-body-lg-text-transform)}.ed-c-heading--body-default{font-family:var(--ed-theme-typography-body-default-font-family);font-weight:var(--ed-theme-typography-body-default-font-weight);font-size:var(--ed-theme-typography-body-default-font-size);line-height:var(--ed-theme-typography-body-default-line-height);letter-spacing:var(--ed-theme-typography-body-default-letter-spacing);text-transform:var(--ed-theme-typography-body-default-text-transform)}.ed-c-heading--body-sm{font-family:var(--ed-theme-typography-body-sm-font-family);font-weight:var(--ed-theme-typography-body-sm-font-weight);font-size:var(--ed-theme-typography-body-sm-font-size);line-height:var(--ed-theme-typography-body-sm-line-height);letter-spacing:var(--ed-theme-typography-body-sm-letter-spacing);text-transform:var(--ed-theme-typography-body-sm-text-transform)}.ed-c-heading--meta-default{font-family:var(--ed-theme-typography-meta-default-font-family);font-weight:var(--ed-theme-typography-meta-default-font-weight);font-size:var(--ed-theme-typography-meta-default-font-size);line-height:var(--ed-theme-typography-meta-default-line-height);letter-spacing:var(--ed-theme-typography-meta-default-letter-spacing);text-transform:var(--ed-theme-typography-meta-default-text-transform)}.ed-c-heading--meta-sm{font-family:var(--ed-theme-typography-meta-sm-font-family);font-weight:var(--ed-theme-typography-meta-sm-font-weight);font-size:var(--ed-theme-typography-meta-sm-font-size);line-height:var(--ed-theme-typography-meta-sm-line-height);letter-spacing:var(--ed-theme-typography-meta-sm-letter-spacing);text-transform:var(--ed-theme-typography-meta-sm-text-transform)}';
|
|
4
|
-
var m = Object.defineProperty, d = (h, e, o, s) => {
|
|
5
|
-
for (var t = void 0, l = h.length - 1, n; l >= 0; l--)
|
|
6
|
-
(n = h[l]) && (t = n(e, o, t) || t);
|
|
7
|
-
return t && m(e, o, t), t;
|
|
8
|
-
};
|
|
9
|
-
class i extends y {
|
|
10
|
-
constructor() {
|
|
11
|
-
super(...arguments), this.tagName = "h2";
|
|
12
|
-
}
|
|
13
|
-
static get styles() {
|
|
14
|
-
return g(p);
|
|
15
|
-
}
|
|
16
|
-
render() {
|
|
17
|
-
const e = this.componentClassNames("ed-c-heading", {
|
|
18
|
-
"ed-c-heading--display-xl": this.variant === "display-xl",
|
|
19
|
-
"ed-c-heading--display-lg": this.variant === "display-lg",
|
|
20
|
-
"ed-c-heading--display-default": this.variant === "display-default",
|
|
21
|
-
"ed-c-heading--headline-lg": this.variant ? this.variant === "headline-lg" : this.tagName === "h1",
|
|
22
|
-
"ed-c-heading--headline-default": this.variant ? this.variant === "headline-default" : this.tagName === "h2",
|
|
23
|
-
"ed-c-heading--headline-sm": this.variant ? this.variant === "headline-sm" : this.tagName === "h3",
|
|
24
|
-
"ed-c-heading--title-lg": this.variant ? this.variant === "title-lg" : this.tagName === "h4",
|
|
25
|
-
"ed-c-heading--title-default": this.variant ? this.variant === "title-default" : this.tagName === "h5",
|
|
26
|
-
"ed-c-heading--title-sm": this.variant ? this.variant === "title-sm" : this.tagName === "h6",
|
|
27
|
-
"ed-c-heading--label-lg": this.variant === "label-lg",
|
|
28
|
-
"ed-c-heading--label-default": this.variant === "label-default",
|
|
29
|
-
"ed-c-heading--label-sm": this.variant === "label-sm",
|
|
30
|
-
"ed-c-heading--body-lg": this.variant === "body-lg",
|
|
31
|
-
"ed-c-heading--body-default": this.variant === "body-default",
|
|
32
|
-
"ed-c-heading--body-sm": this.variant === "body-sm",
|
|
33
|
-
"ed-c-heading--meta-default": this.variant === "meta-default",
|
|
34
|
-
"ed-c-heading--meta-sm": this.variant === "meta-sm",
|
|
35
|
-
"ed-c-heading--wrap-balance": this.wrap === "balance",
|
|
36
|
-
"ed-c-heading--wrap-pretty": this.wrap === "pretty",
|
|
37
|
-
"ed-c-heading--wrap-normal": this.wrap === "normal"
|
|
38
|
-
});
|
|
39
|
-
switch (this.tagName) {
|
|
40
|
-
case "h1":
|
|
41
|
-
return a` <h1 class="${e}"><slot></slot></h1> `;
|
|
42
|
-
case "h2":
|
|
43
|
-
return a` <h2 class="${e}"><slot></slot></h2> `;
|
|
44
|
-
case "h3":
|
|
45
|
-
return a` <h3 class="${e}"><slot></slot></h3> `;
|
|
46
|
-
case "h4":
|
|
47
|
-
return a` <h4 class="${e}"><slot></slot></h4> `;
|
|
48
|
-
case "h5":
|
|
49
|
-
return a` <h5 class="${e}"><slot></slot></h5> `;
|
|
50
|
-
case "h6":
|
|
51
|
-
return a` <h6 class="${e}"><slot></slot></h6> `;
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
d([
|
|
56
|
-
r()
|
|
57
|
-
], i.prototype, "variant");
|
|
58
|
-
d([
|
|
59
|
-
r()
|
|
60
|
-
], i.prototype, "tagName");
|
|
61
|
-
d([
|
|
62
|
-
r()
|
|
63
|
-
], i.prototype, "wrap");
|
|
64
|
-
customElements.get("ed-heading") === void 0 && customElements.define("ed-heading", i);
|