@duetds/components
Version:
This package includes Duet Core Components and related tools.
1 lines • 4.26 kB
JavaScript
import{r as t,h as s,c as e}from"./p-6403d5dc.js";import{b as i,j as r}from"./p-da8c2c96.js";import{t as h}from"./p-8ad09b8a.js";const a=class{constructor(s){t(this,s),this.level="h2",this.margin="auto",this.border=!1,this.color="",this.theme=""}componentWillLoad(){"default"!==this.theme&&document.documentElement.classList.contains("duet-theme-turva")&&(this.theme="turva")}render(){const t={color:h[i(this.color)]},e=r(this.level);return s(e,{class:{"duet-heading":!0,"duet-heading-border":this.border,"duet-m-0":"none"===this.margin,[this.visualLevel?this.visualLevel:this.level]:!0,"duet-theme-turva":"turva"===this.theme},style:t},s("slot",null))}get element(){return e(this)}static get style(){return":host{position:relative;display:block}.duet-heading,:host{-webkit-appearance:none;-moz-appearance:none;appearance:none;-webkit-box-sizing:border-box;box-sizing:border-box;background:transparent;border:0;padding:0;margin:0;width:100%}.duet-heading{margin-bottom:16px!important;font-family:localtapiola-sans,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol;font-weight:800;line-height:1.25;letter-spacing:-.01rem;color:#00294d;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;-moz-font-feature-settings:\"ss01\";-webkit-font-feature-settings:\"ss01\";text-decoration:none;font-feature-settings:\"ss01\";font-variant-numeric:tabular-nums;font-style:normal}.duet-heading.duet-p-0{padding:0!important}.duet-heading.duet-m-0{margin:0!important}\@media only screen and (min-width:36em){.duet-heading{margin-bottom:20px!important}}.duet-heading.duet-theme-turva,.duet-theme-turva .duet-heading{-moz-font-feature-settings:\"liga\" 1;-webkit-font-feature-settings:\"liga\" 1;font-feature-settings:\"liga\" 1;font-family:turva-sans,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol;font-weight:700;color:#111;font-style:italic}.duet-heading.duet-heading-border{padding-bottom:20px;border-bottom:1px solid #e1e3e6}.duet-heading.h0{font-size:9.4vw}\@media (max-width:31.914893617rem){.duet-heading.h0{font-size:3rem}}\@media (min-width:47.8723404255rem){.duet-heading.h0{font-size:4.5rem}}\@media only screen and (max-width:22.5em){.duet-heading.h0{font-size:2.25rem}}.duet-heading.h1{font-size:7vw}\@media (max-width:32.1428571429rem){.duet-heading.h1{font-size:2.25rem}}\@media (min-width:42.8571428571rem){.duet-heading.h1{font-size:3rem}}\@media only screen and (max-width:22.5em){.duet-heading.h1{font-size:1.5rem}}.duet-heading.h2{font-size:5.8vw}\@media (max-width:25.8620689655rem){.duet-heading.h2{font-size:1.5rem}}\@media (min-width:38.7931034483rem){.duet-heading.h2{font-size:2.25rem}}\@media only screen and (max-width:22.5em){.duet-heading.h2{font-size:1.375rem}}.duet-heading.h3{margin-bottom:12px!important;font-size:4.2vw}\@media (max-width:29.7619047619rem){.duet-heading.h3{font-size:1.25rem}}\@media (min-width:35.7142857143rem){.duet-heading.h3{font-size:1.5rem}}.duet-heading.h3.duet-theme-turva,.duet-theme-turva .duet-heading.h3{font-style:normal}.duet-heading.h3.duet-heading-border{padding-bottom:20px}.duet-heading.h4{margin-bottom:8px!important;font-size:4vw;font-weight:600;letter-spacing:0}\@media (max-width:27.5rem){.duet-heading.h4{font-size:1.1rem}}\@media (min-width:31.25rem){.duet-heading.h4{font-size:1.25rem}}.duet-heading.h4.duet-theme-turva,.duet-theme-turva .duet-heading.h4{font-weight:700;font-style:normal}.duet-heading.h4.duet-heading-border{padding-bottom:20px}.duet-heading.h5{margin-bottom:8px!important;-webkit-font-smoothing:subpixel-antialiased;-moz-osx-font-smoothing:auto;letter-spacing:0;font-size:1rem;font-weight:600}.duet-heading.h5.duet-theme-turva,.duet-theme-turva .duet-heading.h5{font-weight:700;font-style:normal}.duet-heading.h5.duet-heading-border{padding-bottom:16px}.duet-heading.h6{margin-bottom:8px!important;-webkit-font-smoothing:subpixel-antialiased;-moz-osx-font-smoothing:auto;letter-spacing:0;font-size:.875rem;font-weight:600}.duet-heading.h6.duet-theme-turva,.duet-theme-turva .duet-heading.h6{font-weight:700;font-style:normal}.duet-heading.h6.duet-heading-border{padding-bottom:16px}"}};export{a as duet_heading};