@ptcwebops/ptcw-design 3.7.8 → 3.8.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/dist/cjs/icon-asset_19.cjs.entry.js +38 -11
- package/dist/cjs/ptc-form-checkbox_3.cjs.entry.js +11 -4
- package/dist/cjs/ptc-media-card.cjs.entry.js +1 -1
- package/dist/collection/components/ptc-form-checkbox/ptc-form-checkbox.css +25 -17
- package/dist/collection/components/ptc-form-checkbox/ptc-form-checkbox.js +11 -4
- package/dist/collection/components/ptc-media-card/ptc-media-card.js +1 -1
- package/dist/collection/components/ptc-mobile-select/ptc-mobile-select.js +35 -11
- package/dist/custom-elements/index.js +50 -16
- package/dist/esm/icon-asset_19.entry.js +38 -11
- package/dist/esm/ptc-form-checkbox_3.entry.js +11 -4
- package/dist/esm/ptc-media-card.entry.js +1 -1
- package/dist/ptcw-design/p-d00720e3.entry.js +68 -0
- package/dist/ptcw-design/p-e773bbc6.entry.js +1 -0
- package/dist/ptcw-design/p-ef7a4f53.entry.js +1 -0
- package/dist/ptcw-design/ptcw-design.esm.js +1 -1
- package/dist/types/components/ptc-form-checkbox/ptc-form-checkbox.d.ts +2 -1
- package/dist/types/components/ptc-mobile-select/ptc-mobile-select.d.ts +8 -0
- package/package.json +1 -1
- package/readme.md +1 -1
- package/dist/ptcw-design/p-26166dcf.entry.js +0 -1
- package/dist/ptcw-design/p-4d1ec425.entry.js +0 -68
- package/dist/ptcw-design/p-a413639a.entry.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,h as e,H as i}from"./p-9e0fd244.js";import{b as a}from"./p-b422900e.js";const s=class{constructor(e){t(this,e),this.videoEle=void 0,this.cardType="media-card",this.cardHref=void 0,this.target="_self",this.rel=void 0,this.activeBackgroundImage=void 0,this.hoverBackgroundImage=void 0,this.heading=void 0,this.headingTransform="none",this.category=void 0,this.ariaLabel=void 0,this.isHovered=!1}WatchStateHandler(t){this.videoEle&&(t?this.videoEle.play():this.videoEle.pause())}getCardText(){if("media-card"===this.cardType)return[e("div",{class:"card-wrap"},e("div",{class:"car-content"},e("h4",null,this.category," "),e("h3",null,this.heading)))]}componentDidLoad(){this.ariaLabel=this.getLastStringAfterSlash(this.cardHref)}getLastStringAfterSlash(t){const e=t.split("/");return e[e.length-1]}render(){const t=this.cardHref?"a":"div",s=".mp4"===a(this.hoverBackgroundImage),h=this.getCssClassMap();return e(i,{class:h,onmouseenter:()=>this.isHovered=!0,onmouseleave:()=>this.isHovered=!1,style:this.isHovered?{backgroundImage:`url(${this.hoverBackgroundImage})`}:{backgroundImage:`url(${this.activeBackgroundImage})`}},e("slot",{name:"seo-content"}),e(t,{class:"anchor-wrap",target:this.target,href:this.cardHref,rel:this.rel,"aria-label":this.cardHref?"Read more about "+this.ariaLabel:void 0},s&&e("video",{muted:!0,loop:!0,playsinline:!0,poster:this.activeBackgroundImage,ref:t=>this.videoEle=t,style:this.isHovered?{display:"block"}:{display:"none"}},e("source",{src:this.hoverBackgroundImage,type:"video/mp4"},"Your browser does not support the video tag.")),"media-card"===this.cardType&&e("ptc-overlay",{"filter-color":"black-2"}),"media-card"===this.cardType&&this.getCardText()))}getCssClassMap(){return{[this.cardType]:!0}}static get watchers(){return{isHovered:["WatchStateHandler"]}}};s.style="h1,h2,h3,h4,h5,h6,p,ul,li,ptc-subnav,ptc-tab-list,ptc-link{word-break:break-word;hyphens:manual;-webkit-hyphens:manual;-moz-hyphens:manual;-ms-hyphens:manual}@supports (hyphenate-limit-chars: 12 3 3){h1,h2,h3,h4,h5,h6,p,ul,li,ptc-subnav,ptc-tab-list,ptc-link{hyphens:auto;-webkit-hyphenate-limit-before:3;-webkit-hyphenate-limit-after:3;hyphenate-limit-chars:12 3 3;hyphenate-limit-lines:2;hyphenate-limit-last:always;hyphenate-limit-zone:6%;-webkit-hyphens:auto;-webkit-hyphenate-limit-before:3;-webkit-hyphenate-limit-after:3;-webkit-hyphenate-limit-chars:12 3 3;-webkit-hyphenate-limit-lines:2;-moz-hyphens:auto;-moz-hyphenate-limit-chars:12 3 3;-moz-hyphenate-limit-lines:2;-ms-hyphens:auto;-ms-hyphenate-limit-chars:12 3 3;-ms-hyphenate-limit-lines:2}}:host{display:block;position:relative;width:100%;background-size:cover;background-position:50%;background-repeat:no-repeat}:host .anchor-wrap{height:100%;width:100%;display:block;text-decoration:none;position:relative}:host video{object-fit:cover;height:100%;width:100%;z-index:0;position:absolute;left:0;right:0;top:0;bottom:0;display:none}:host(.media-card) ::slotted([slot=seo-content]){display:none}:host(.media-card) .card-wrap{display:flex;height:100%;width:100%;position:relative;z-index:1;min-height:329px;align-items:end}:host(.media-card) .card-wrap .car-content{padding:20px 30px 30px 30px}:host(.media-card) .card-wrap .car-content h4,:host(.media-card) .card-wrap .car-content h3{color:#fff}:host(.media-card) .card-wrap .car-content h3{position:relative;margin-bottom:0;font-size:var(--ptc-font-size-large);text-shadow:1px 3px 30px #000;line-height:var(--ptc-line-height-denser);display:inline;letter-spacing:1.1px}:host(.media-card) .card-wrap .car-content h3::before{content:\"\";width:100%;height:3px;background-image:url(\"data:image/svg+xml,%3Csvg width='60' height='1' viewBox='0 0 60 1' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Crect width='30' height='1' fill='%2333A13C'/%3E%3C/svg%3E\");background-repeat:repeat;position:absolute;background-size:initial;top:-10px}:host(.media-card) .card-wrap .car-content h4{text-shadow:1px 3px 30px var(--color-black);font-weight:var(--ptc-font-weight-semibold);display:block;font-size:var(--ptc-font-size-x-small);font-style:normal;font-stretch:normal;letter-spacing:0.6px}:host(.bureau-card){height:100%;position:relative}";export{s as ptc_media_card}
|