@fluid-topics/ft-card 0.3.11 → 0.3.13
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/build/ft-card.css.d.ts +12 -0
- package/build/ft-card.css.js +70 -0
- package/build/ft-card.d.ts +2 -15
- package/build/ft-card.js +4 -72
- package/build/ft-card.light.js +207 -212
- package/build/ft-card.min.js +147 -147
- package/build/ft-card.properties.d.ts +5 -0
- package/build/ft-card.properties.js +2 -0
- package/build/index.d.ts +2 -0
- package/build/index.js +2 -0
- package/package.json +5 -5
package/build/ft-card.light.js
CHANGED
|
@@ -1,278 +1,273 @@
|
|
|
1
|
-
!function(t,i,e,o,
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
width: ${this.rippleSize}px;
|
|
6
|
-
height: ${this.rippleSize}px;
|
|
7
|
-
}
|
|
1
|
+
!function(t,i,e,o,s){const r=i.FtCssVariableFactory.extend("--ft-ripple-color",i.designSystemVariables.colorContent),n=r,p=i.FtCssVariableFactory.extend("--ft-ripple-background-color",r),l=i.FtCssVariableFactory.external(i.designSystemVariables.opacityContentOnSurfacePressed,"Design system"),h=i.FtCssVariableFactory.external(i.designSystemVariables.opacityContentOnSurfaceHover,"Design system"),a=i.FtCssVariableFactory.external(i.designSystemVariables.opacityContentOnSurfaceFocused,"Design system"),f=i.FtCssVariableFactory.external(i.designSystemVariables.opacityContentOnSurfaceSelected,"Design system"),d=i.FtCssVariableFactory.extend("--ft-ripple-color",i.designSystemVariables.colorPrimary),y=d,c=i.FtCssVariableFactory.extend("--ft-ripple-background-color",d),g=i.FtCssVariableFactory.extend("--ft-ripple-color",i.designSystemVariables.colorSecondary),u=g,v=i.FtCssVariableFactory.extend("--ft-ripple-background-color",g),b=e.css`
|
|
2
|
+
:host {
|
|
3
|
+
display: contents;
|
|
4
|
+
}
|
|
8
5
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
<div class="${r.classMap(t)}">
|
|
15
|
-
<div class="ft-ripple--background"></div>
|
|
16
|
-
<div class="ft-ripple--effect"></div>
|
|
17
|
-
</div>
|
|
18
|
-
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.ripple&&this.resizeObserver.observe(this.ripple),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}updated(t){var i,e;super.updated(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(i=this.target)||void 0===i||i.removeAttribute("data-is-ft-ripple-target")):null===(e=this.target)||void 0===e||e.setAttribute("data-is-ft-ripple-target","true")),t.has("unbounded")&&this.setRippleSize()}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}setRippleSize(){if(this.ripple){const t=this.ripple.getBoundingClientRect();this.rippleSize=(this.unbounded?1:1.7)*Math.max(t.width,t.height)}}connectedCallback(){var t;super.connectedCallback();const i=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;i&&this.setupFor(i),this.setRippleSize()}setupFor(t){if(this.target===t)return;this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const i=(...t)=>i=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(i)},e=i("mouseup","contextmenu"),o=i("touchend","touchcancel"),r=t=>{["Enter"," "].includes(t.key)&&i("keyup")(t)};t.addEventListener("mouseover",this.startHover),t.addEventListener("mousemove",this.moveRipple),t.addEventListener("mouseleave",this.endHover),t.addEventListener("mousedown",e),t.addEventListener("touchstart",o),t.addEventListener("touchmove",this.moveRipple),t.addEventListener("keydown",r),t.addEventListener("focus",this.startFocus),t.addEventListener("blur",this.endFocus),t.addEventListener("focusin",this.startFocus),t.addEventListener("focusout",this.endFocus),this.onDisconnect=()=>{t.removeAttribute("data-is-ft-ripple-target"),t.removeEventListener("mouseover",this.startHover),t.removeEventListener("mousemove",this.moveRipple),t.removeEventListener("mouseleave",this.endHover),t.removeEventListener("mousedown",e),t.removeEventListener("touchstart",o),t.removeEventListener("touchmove",this.moveRipple),t.removeEventListener("keydown",r),t.removeEventListener("focus",this.startFocus),t.removeEventListener("blur",this.endFocus),t.removeEventListener("focusin",this.startFocus),t.removeEventListener("focusout",this.endFocus),this.onDisconnect=void 0}}getCoordinates(t){const i=t,e=t;let o,r;return null!=i.x?({x:o,y:r}=i):null!=e.touches&&(o=e.touches[0].clientX,r=e.touches[0].clientY),{x:o,y:r}}isIgnored(t){if(this.disabled)return!0;if(null!=t)for(let i of t.composedPath()){if(i===this.target)break;if("hasAttribute"in i&&i.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.resizeObserver.disconnect(),this.endRipple()}}v.elementDefinitions={},v.styles=e.css`
|
|
19
|
-
:host {
|
|
20
|
-
display: contents;
|
|
21
|
-
}
|
|
6
|
+
.ft-ripple {
|
|
7
|
+
position: absolute;
|
|
8
|
+
inset: 0;
|
|
9
|
+
pointer-events: none;
|
|
10
|
+
}
|
|
22
11
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
pointer-events: none;
|
|
27
|
-
}
|
|
12
|
+
.ft-ripple:not(.ft-ripple--unbounded) {
|
|
13
|
+
overflow: hidden;
|
|
14
|
+
}
|
|
28
15
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
16
|
+
.ft-ripple .ft-ripple--background,
|
|
17
|
+
.ft-ripple .ft-ripple--effect {
|
|
18
|
+
position: absolute;
|
|
19
|
+
opacity: 0;
|
|
20
|
+
}
|
|
32
21
|
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
opacity: 0;
|
|
37
|
-
}
|
|
22
|
+
.ft-ripple .ft-ripple--background {
|
|
23
|
+
background-color: ${p};
|
|
24
|
+
}
|
|
38
25
|
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
26
|
+
.ft-ripple .ft-ripple--effect {
|
|
27
|
+
background-color: ${n};
|
|
28
|
+
}
|
|
42
29
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
30
|
+
.ft-ripple.ft-ripple--secondary .ft-ripple--background {
|
|
31
|
+
background-color: ${v};
|
|
32
|
+
}
|
|
46
33
|
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
34
|
+
.ft-ripple.ft-ripple--secondary .ft-ripple--effect {
|
|
35
|
+
background-color: ${u};
|
|
36
|
+
}
|
|
50
37
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
38
|
+
.ft-ripple.ft-ripple--primary .ft-ripple--background {
|
|
39
|
+
background-color: ${c};
|
|
40
|
+
}
|
|
54
41
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
42
|
+
.ft-ripple.ft-ripple--primary .ft-ripple--effect {
|
|
43
|
+
background-color: ${y};
|
|
44
|
+
}
|
|
58
45
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
46
|
+
.ft-ripple .ft-ripple--background {
|
|
47
|
+
top: 0;
|
|
48
|
+
left: 0;
|
|
49
|
+
height: 100%;
|
|
50
|
+
width: 100%;
|
|
51
|
+
transition: opacity 75ms linear;
|
|
52
|
+
}
|
|
62
53
|
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
width: 100%;
|
|
68
|
-
transition: opacity 75ms linear;
|
|
69
|
-
}
|
|
54
|
+
.ft-ripple .ft-ripple--effect,
|
|
55
|
+
.ft-ripple.ft-ripple--unbounded .ft-ripple--background {
|
|
56
|
+
border-radius: 50%;
|
|
57
|
+
}
|
|
70
58
|
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
59
|
+
.ft-ripple .ft-ripple--effect {
|
|
60
|
+
transform: translate(-50%, -50%) scale(0.15);
|
|
61
|
+
transition: transform 300ms ease, opacity 75ms linear;
|
|
62
|
+
}
|
|
75
63
|
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
64
|
+
.ft-ripple.ft-ripple--unbounded .ft-ripple--effect,
|
|
65
|
+
.ft-ripple.ft-ripple--unbounded .ft-ripple--background {
|
|
66
|
+
left: 50%;
|
|
67
|
+
top: 50%;
|
|
68
|
+
}
|
|
80
69
|
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
top: 50%;
|
|
85
|
-
}
|
|
70
|
+
.ft-ripple.ft-ripple--unbounded .ft-ripple--background {
|
|
71
|
+
transform: translate(-50%, -50%);
|
|
72
|
+
}
|
|
86
73
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
74
|
+
.ft-ripple.ft-ripple--hovered .ft-ripple--background {
|
|
75
|
+
opacity: ${h};
|
|
76
|
+
}
|
|
90
77
|
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
78
|
+
.ft-ripple.ft-ripple--selected .ft-ripple--background {
|
|
79
|
+
opacity: ${f};
|
|
80
|
+
}
|
|
94
81
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
82
|
+
.ft-ripple.ft-ripple--focused .ft-ripple--background {
|
|
83
|
+
opacity: ${a};
|
|
84
|
+
}
|
|
98
85
|
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
86
|
+
.ft-ripple.ft-ripple--pressed .ft-ripple--effect {
|
|
87
|
+
opacity: ${l};
|
|
88
|
+
transform: translate(-50%, -50%) scale(1);
|
|
89
|
+
}
|
|
90
|
+
`;var $,m=function(t,i,e,o){for(var s,r=arguments.length,n=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,p=t.length-1;p>=0;p--)(s=t[p])&&(n=(r<3?s(n):r>3?s(i,e,n):s(i,e))||n);return r>3&&n&&Object.defineProperty(i,e,n),n};class x extends i.FtLitElement{constructor(){super(...arguments),this.primary=!1,this.secondary=!1,this.unbounded=!1,this.activated=!1,this.selected=!1,this.disabled=!1,this.hovered=!1,this.focused=!1,this.pressed=!1,this.rippling=!1,this.rippleSize=0,this.originX=0,this.originY=0,this.resizeObserver=new ResizeObserver((()=>this.setRippleSize())),this.debouncer=new i.Debouncer(1e3),this.onTransitionStart=t=>{"transform"===t.propertyName&&(this.rippling=this.pressed,this.debouncer.run((()=>this.rippling=!1)))},this.onTransitionEnd=t=>{"transform"===t.propertyName&&(this.rippling=!1)},this.moveRipple=t=>{var i,e;let{x:o,y:s}=this.getCoordinates(t),r=null!==(e=null===(i=this.ripple)||void 0===i?void 0:i.getBoundingClientRect())&&void 0!==e?e:{x:0,y:0,width:0,height:0};this.originX=Math.round(null!=o?o-r.x:r.width/2),this.originY=Math.round(null!=s?s-r.y:r.height/2)},this.startPress=t=>{this.moveRipple(t),this.pressed=!this.isIgnored(t)},this.endPress=()=>{this.pressed=!1},this.startHover=t=>{this.hovered=!this.isIgnored(t)},this.endHover=()=>{this.hovered=!1},this.startFocus=t=>{this.focused=!this.isIgnored(t)},this.endFocus=()=>{this.focused=!1}}render(){let t={"ft-ripple":!0,"ft-ripple--primary":this.primary,"ft-ripple--secondary":this.secondary,"ft-ripple--unbounded":this.unbounded,"ft-ripple--selected":(this.selected||this.activated)&&!this.disabled,"ft-ripple--pressed":(this.pressed||this.rippling)&&!this.disabled,"ft-ripple--hovered":this.hovered&&!this.disabled,"ft-ripple--focused":this.focused&&!this.disabled};return e.html`
|
|
91
|
+
<style>
|
|
92
|
+
.ft-ripple .ft-ripple--effect,
|
|
93
|
+
.ft-ripple.ft-ripple--unbounded .ft-ripple--background {
|
|
94
|
+
width: ${this.rippleSize}px;
|
|
95
|
+
height: ${this.rippleSize}px;
|
|
96
|
+
}
|
|
102
97
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
*/var O;const N=globalThis.trustedTypes,S=N?N.createPolicy("lit-html",{createHTML:t=>t}):void 0,R=`lit$${(Math.random()+"").slice(9)}$`,w="?"+R,U=`<${w}>`,E=document,F=(t="")=>E.createComment(t),M=t=>null===t||"object"!=typeof t&&"function"!=typeof t,C=Array.isArray,k=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,B=/-->/g,z=/>/g,P=RegExp(">|[ \t\n\f\r](?:([^\\s\"'>=/]+)([ \t\n\f\r]*=[ \t\n\f\r]*(?:[^ \t\n\f\r\"'`<>=]|(\"|')|))|$)","g"),L=/'/g,D=/"/g,W=/^(?:script|style|textarea|title)$/i,A=(t=>(i,...e)=>({_$litType$:t,strings:i,values:e}))(1),K=Symbol.for("lit-noChange"),_=Symbol.for("lit-nothing"),I=new WeakMap,H=E.createTreeWalker(E,129,null,!1),T=(t,i)=>{const e=t.length-1,o=[];let r,n=2===i?"<svg>":"",s=k;for(let i=0;i<e;i++){const e=t[i];let p,a,l=-1,f=0;for(;f<e.length&&(s.lastIndex=f,a=s.exec(e),null!==a);)f=s.lastIndex,s===k?"!--"===a[1]?s=B:void 0!==a[1]?s=z:void 0!==a[2]?(W.test(a[2])&&(r=RegExp("</"+a[2],"g")),s=P):void 0!==a[3]&&(s=P):s===P?">"===a[0]?(s=null!=r?r:k,l=-1):void 0===a[1]?l=-2:(l=s.lastIndex-a[2].length,p=a[1],s=void 0===a[3]?P:'"'===a[3]?D:L):s===D||s===L?s=P:s===B||s===z?s=k:(s=P,r=void 0);const h=s===P&&t[i+1].startsWith("/>")?" ":"";n+=s===k?e+U:l>=0?(o.push(p),e.slice(0,l)+"$lit$"+e.slice(l)+R+h):e+R+(-2===l?(o.push(void 0),i):h)}const p=n+(t[e]||"<?>")+(2===i?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==S?S.createHTML(p):p,o]};class j{constructor({strings:t,_$litType$:i},e){let o;this.parts=[];let r=0,n=0;const s=t.length-1,p=this.parts,[a,l]=T(t,i);if(this.el=j.createElement(a,e),H.currentNode=this.el.content,2===i){const t=this.el.content,i=t.firstChild;i.remove(),t.append(...i.childNodes)}for(;null!==(o=H.nextNode())&&p.length<s;){if(1===o.nodeType){if(o.hasAttributes()){const t=[];for(const i of o.getAttributeNames())if(i.endsWith("$lit$")||i.startsWith(R)){const e=l[n++];if(t.push(i),void 0!==e){const t=o.getAttribute(e.toLowerCase()+"$lit$").split(R),i=/([.?@])?(.*)/.exec(e);p.push({type:1,index:r,name:i[2],strings:t,ctor:"."===i[1]?Y:"?"===i[1]?J:"@"===i[1]?Q:V})}else p.push({type:6,index:r})}for(const i of t)o.removeAttribute(i)}if(W.test(o.tagName)){const t=o.textContent.split(R),i=t.length-1;if(i>0){o.textContent=N?N.emptyScript:"";for(let e=0;e<i;e++)o.append(t[e],F()),H.nextNode(),p.push({type:2,index:++r});o.append(t[i],F())}}}else if(8===o.nodeType)if(o.data===w)p.push({type:2,index:r});else{let t=-1;for(;-1!==(t=o.data.indexOf(R,t+1));)p.push({type:7,index:r}),t+=R.length-1}r++}}static createElement(t,i){const e=E.createElement("template");return e.innerHTML=t,e}}function Z(t,i,e=t,o){var r,n,s,p;if(i===K)return i;let a=void 0!==o?null===(r=e._$Cl)||void 0===r?void 0:r[o]:e._$Cu;const l=M(i)?void 0:i._$litDirective$;return(null==a?void 0:a.constructor)!==l&&(null===(n=null==a?void 0:a._$AO)||void 0===n||n.call(a,!1),void 0===l?a=void 0:(a=new l(t),a._$AT(t,e,o)),void 0!==o?(null!==(s=(p=e)._$Cl)&&void 0!==s?s:p._$Cl=[])[o]=a:e._$Cu=a),void 0!==a&&(i=Z(t,a._$AS(t,i.values),a,o)),i}class G{constructor(t,i){this.v=[],this._$AN=void 0,this._$AD=t,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}p(t){var i;const{el:{content:e},parts:o}=this._$AD,r=(null!==(i=null==t?void 0:t.creationScope)&&void 0!==i?i:E).importNode(e,!0);H.currentNode=r;let n=H.nextNode(),s=0,p=0,a=o[0];for(;void 0!==a;){if(s===a.index){let i;2===a.type?i=new X(n,n.nextSibling,this,t):1===a.type?i=new a.ctor(n,a.name,a.strings,this,t):6===a.type&&(i=new tt(n,this,t)),this.v.push(i),a=o[++p]}s!==(null==a?void 0:a.index)&&(n=H.nextNode(),s++)}return r}m(t){let i=0;for(const e of this.v)void 0!==e&&(void 0!==e.strings?(e._$AI(t,e,i),i+=e.strings.length-2):e._$AI(t[i])),i++}}class X{constructor(t,i,e,o){var r;this.type=2,this._$AH=_,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=e,this.options=o,this._$C_=null===(r=null==o?void 0:o.isConnected)||void 0===r||r}get _$AU(){var t,i;return null!==(i=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==i?i:this._$C_}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=Z(this,t,i),M(t)?t===_||null==t||""===t?(this._$AH!==_&&this._$AR(),this._$AH=_):t!==this._$AH&&t!==K&&this.T(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.k(t):(t=>C(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.S(t):this.T(t)}j(t,i=this._$AB){return this._$AA.parentNode.insertBefore(t,i)}k(t){this._$AH!==t&&(this._$AR(),this._$AH=this.j(t))}T(t){this._$AH!==_&&M(this._$AH)?this._$AA.nextSibling.data=t:this.k(E.createTextNode(t)),this._$AH=t}$(t){var i;const{values:e,_$litType$:o}=t,r="number"==typeof o?this._$AC(t):(void 0===o.el&&(o.el=j.createElement(o.h,this.options)),o);if((null===(i=this._$AH)||void 0===i?void 0:i._$AD)===r)this._$AH.m(e);else{const t=new G(r,this),i=t.p(this.options);t.m(e),this.k(i),this._$AH=t}}_$AC(t){let i=I.get(t.strings);return void 0===i&&I.set(t.strings,i=new j(t)),i}S(t){C(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let e,o=0;for(const r of t)o===i.length?i.push(e=new X(this.j(F()),this.j(F()),this,this.options)):e=i[o],e._$AI(r),o++;o<i.length&&(this._$AR(e&&e._$AB.nextSibling,o),i.length=o)}_$AR(t=this._$AA.nextSibling,i){var e;for(null===(e=this._$AP)||void 0===e||e.call(this,!1,!0,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i}}setConnected(t){var i;void 0===this._$AM&&(this._$C_=t,null===(i=this._$AP)||void 0===i||i.call(this,t))}}class V{constructor(t,i,e,o,r){this.type=1,this._$AH=_,this._$AN=void 0,this.element=t,this.name=i,this._$AM=o,this.options=r,e.length>2||""!==e[0]||""!==e[1]?(this._$AH=Array(e.length-1).fill(new String),this.strings=e):this._$AH=_}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,i=this,e,o){const r=this.strings;let n=!1;if(void 0===r)t=Z(this,t,i,0),n=!M(t)||t!==this._$AH&&t!==K,n&&(this._$AH=t);else{const o=t;let s,p;for(t=r[0],s=0;s<r.length-1;s++)p=Z(this,o[e+s],i,s),p===K&&(p=this._$AH[s]),n||(n=!M(p)||p!==this._$AH[s]),p===_?t=_:t!==_&&(t+=(null!=p?p:"")+r[s+1]),this._$AH[s]=p}n&&!o&&this.P(t)}P(t){t===_?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class Y extends V{constructor(){super(...arguments),this.type=3}P(t){this.element[this.name]=t===_?void 0:t}}const q=N?N.emptyScript:"";class J extends V{constructor(){super(...arguments),this.type=4}P(t){t&&t!==_?this.element.setAttribute(this.name,q):this.element.removeAttribute(this.name)}}class Q extends V{constructor(t,i,e,o,r){super(t,i,e,o,r),this.type=5}_$AI(t,i=this){var e;if((t=null!==(e=Z(this,t,i,0))&&void 0!==e?e:_)===K)return;const o=this._$AH,r=t===_&&o!==_||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,n=t!==_&&(o===_||r);r&&this.element.removeEventListener(this.name,this,o),n&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var i,e;"function"==typeof this._$AH?this._$AH.call(null!==(e=null===(i=this.options)||void 0===i?void 0:i.host)&&void 0!==e?e:this.element,t):this._$AH.handleEvent(t)}}class tt{constructor(t,i,e){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=e}get _$AU(){return this._$AM._$AU}_$AI(t){Z(this,t)}}const it=window.litHtmlPolyfillSupport;null==it||it(j,X),(null!==(O=globalThis.litHtmlVersions)&&void 0!==O?O:globalThis.litHtmlVersions=[]).push("2.2.7");
|
|
98
|
+
.ft-ripple .ft-ripple--effect {
|
|
99
|
+
left: ${this.originX}px;
|
|
100
|
+
top: ${this.originY}px;
|
|
101
|
+
}
|
|
102
|
+
</style>
|
|
103
|
+
<div class="${s.classMap(t)}">
|
|
104
|
+
<div class="ft-ripple--background"></div>
|
|
105
|
+
<div class="ft-ripple--effect"></div>
|
|
106
|
+
</div>
|
|
107
|
+
`}contentAvailableCallback(t){super.contentAvailableCallback(t),this.ripple&&this.resizeObserver.observe(this.ripple),this.rippleEffect&&this.rippleEffect.ontransitionstart!==this.onTransitionStart&&(this.rippleEffect.ontransitionstart=this.onTransitionStart,this.rippleEffect.ontransitionend=this.onTransitionEnd)}updated(t){var i,e;super.updated(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(i=this.target)||void 0===i||i.removeAttribute("data-is-ft-ripple-target")):null===(e=this.target)||void 0===e||e.setAttribute("data-is-ft-ripple-target","true")),t.has("unbounded")&&this.setRippleSize()}endRipple(){this.endHover(),this.endFocus(),this.endPress(),this.rippling=!1}setRippleSize(){if(this.ripple){const t=this.ripple.getBoundingClientRect();this.rippleSize=(this.unbounded?1:1.7)*Math.max(t.width,t.height)}}connectedCallback(){var t;super.connectedCallback();const i=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;i&&this.setupFor(i),this.setRippleSize()}setupFor(t){if(this.target===t)return;this.onDisconnect&&this.onDisconnect(),this.target=t,t.setAttribute("data-is-ft-ripple-target","true");const i=(...t)=>i=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(i)},e=i("mouseup","contextmenu"),o=i("touchend","touchcancel"),s=t=>{["Enter"," "].includes(t.key)&&i("keyup")(t)};t.addEventListener("mouseover",this.startHover),t.addEventListener("mousemove",this.moveRipple),t.addEventListener("mouseleave",this.endHover),t.addEventListener("mousedown",e),t.addEventListener("touchstart",o),t.addEventListener("touchmove",this.moveRipple),t.addEventListener("keydown",s),t.addEventListener("focus",this.startFocus),t.addEventListener("blur",this.endFocus),t.addEventListener("focusin",this.startFocus),t.addEventListener("focusout",this.endFocus),this.onDisconnect=()=>{t.removeAttribute("data-is-ft-ripple-target"),t.removeEventListener("mouseover",this.startHover),t.removeEventListener("mousemove",this.moveRipple),t.removeEventListener("mouseleave",this.endHover),t.removeEventListener("mousedown",e),t.removeEventListener("touchstart",o),t.removeEventListener("touchmove",this.moveRipple),t.removeEventListener("keydown",s),t.removeEventListener("focus",this.startFocus),t.removeEventListener("blur",this.endFocus),t.removeEventListener("focusin",this.startFocus),t.removeEventListener("focusout",this.endFocus),this.onDisconnect=void 0}}getCoordinates(t){const i=t,e=t;let o,s;return null!=i.x?({x:o,y:s}=i):null!=e.touches&&(o=e.touches[0].clientX,s=e.touches[0].clientY),{x:o,y:s}}isIgnored(t){if(this.disabled)return!0;if(null!=t)for(let i of t.composedPath()){if(i===this.target)break;if("hasAttribute"in i&&i.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.resizeObserver.disconnect(),this.endRipple()}}x.elementDefinitions={},x.styles=b,m([o.property({type:Boolean})],x.prototype,"primary",void 0),m([o.property({type:Boolean})],x.prototype,"secondary",void 0),m([o.property({type:Boolean})],x.prototype,"unbounded",void 0),m([o.property({type:Boolean})],x.prototype,"activated",void 0),m([o.property({type:Boolean})],x.prototype,"selected",void 0),m([o.property({type:Boolean})],x.prototype,"disabled",void 0),m([o.state()],x.prototype,"hovered",void 0),m([o.state()],x.prototype,"focused",void 0),m([o.state()],x.prototype,"pressed",void 0),m([o.state()],x.prototype,"rippling",void 0),m([o.state()],x.prototype,"rippleSize",void 0),m([o.state()],x.prototype,"originX",void 0),m([o.state()],x.prototype,"originY",void 0),m([o.query(".ft-ripple")],x.prototype,"ripple",void 0),m([o.query(".ft-ripple--effect")],x.prototype,"rippleEffect",void 0),i.customElement("ft-ripple")(x);const w=globalThis.trustedTypes,k=w?w.createPolicy("lit-html",{createHTML:t=>t}):void 0,z=`lit$${(Math.random()+"").slice(9)}$`,A="?"+z,S=`<${A}>`,_=document,N=(t="")=>_.createComment(t),O=t=>null===t||"object"!=typeof t&&"function"!=typeof t,D=Array.isArray,E=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,M=/-->/g,j=/>/g,T=RegExp(">|[ \t\n\f\r](?:([^\\s\"'>=/]+)([ \t\n\f\r]*=[ \t\n\f\r]*(?:[^ \t\n\f\r\"'`<>=]|(\"|')|))|$)","g"),B=/'/g,I=/"/g,R=/^(?:script|style|textarea|title)$/i,C=(t=>(i,...e)=>({_$litType$:t,strings:i,values:e}))(1),U=Symbol.for("lit-noChange"),Z=Symbol.for("lit-nothing"),G=new WeakMap,P=_.createTreeWalker(_,129,null,!1),W=(t,i)=>{const e=t.length-1,o=[];let s,r=2===i?"<svg>":"",n=E;for(let i=0;i<e;i++){const e=t[i];let p,l,h=-1,a=0;for(;a<e.length&&(n.lastIndex=a,l=n.exec(e),null!==l);)a=n.lastIndex,n===E?"!--"===l[1]?n=M:void 0!==l[1]?n=j:void 0!==l[2]?(R.test(l[2])&&(s=RegExp("</"+l[2],"g")),n=T):void 0!==l[3]&&(n=T):n===T?">"===l[0]?(n=null!=s?s:E,h=-1):void 0===l[1]?h=-2:(h=n.lastIndex-l[2].length,p=l[1],n=void 0===l[3]?T:'"'===l[3]?I:B):n===I||n===B?n=T:n===M||n===j?n=E:(n=T,s=void 0);const f=n===T&&t[i+1].startsWith("/>")?" ":"";r+=n===E?e+S:h>=0?(o.push(p),e.slice(0,h)+"$lit$"+e.slice(h)+z+f):e+z+(-2===h?(o.push(void 0),i):f)}const p=r+(t[e]||"<?>")+(2===i?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==k?k.createHTML(p):p,o]};class H{constructor({strings:t,_$litType$:i},e){let o;this.parts=[];let s=0,r=0;const n=t.length-1,p=this.parts,[l,h]=W(t,i);if(this.el=H.createElement(l,e),P.currentNode=this.el.content,2===i){const t=this.el.content,i=t.firstChild;i.remove(),t.append(...i.childNodes)}for(;null!==(o=P.nextNode())&&p.length<n;){if(1===o.nodeType){if(o.hasAttributes()){const t=[];for(const i of o.getAttributeNames())if(i.endsWith("$lit$")||i.startsWith(z)){const e=h[r++];if(t.push(i),void 0!==e){const t=o.getAttribute(e.toLowerCase()+"$lit$").split(z),i=/([.?@])?(.*)/.exec(e);p.push({type:1,index:s,name:i[2],strings:t,ctor:"."===i[1]?Y:"?"===i[1]?J:"@"===i[1]?Q:X})}else p.push({type:6,index:s})}for(const i of t)o.removeAttribute(i)}if(R.test(o.tagName)){const t=o.textContent.split(z),i=t.length-1;if(i>0){o.textContent=w?w.emptyScript:"";for(let e=0;e<i;e++)o.append(t[e],N()),P.nextNode(),p.push({type:2,index:++s});o.append(t[i],N())}}}else if(8===o.nodeType)if(o.data===A)p.push({type:2,index:s});else{let t=-1;for(;-1!==(t=o.data.indexOf(z,t+1));)p.push({type:7,index:s}),t+=z.length-1}s++}}static createElement(t,i){const e=_.createElement("template");return e.innerHTML=t,e}}function F(t,i,e=t,o){var s,r,n,p;if(i===U)return i;let l=void 0!==o?null===(s=e._$Cl)||void 0===s?void 0:s[o]:e._$Cu;const h=O(i)?void 0:i._$litDirective$;return(null==l?void 0:l.constructor)!==h&&(null===(r=null==l?void 0:l._$AO)||void 0===r||r.call(l,!1),void 0===h?l=void 0:(l=new h(t),l._$AT(t,e,o)),void 0!==o?(null!==(n=(p=e)._$Cl)&&void 0!==n?n:p._$Cl=[])[o]=l:e._$Cu=l),void 0!==l&&(i=F(t,l._$AS(t,i.values),l,o)),i}class K{constructor(t,i){this.v=[],this._$AN=void 0,this._$AD=t,this._$AM=i}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}p(t){var i;const{el:{content:e},parts:o}=this._$AD,s=(null!==(i=null==t?void 0:t.creationScope)&&void 0!==i?i:_).importNode(e,!0);P.currentNode=s;let r=P.nextNode(),n=0,p=0,l=o[0];for(;void 0!==l;){if(n===l.index){let i;2===l.type?i=new L(r,r.nextSibling,this,t):1===l.type?i=new l.ctor(r,l.name,l.strings,this,t):6===l.type&&(i=new V(r,this,t)),this.v.push(i),l=o[++p]}n!==(null==l?void 0:l.index)&&(r=P.nextNode(),n++)}return s}m(t){let i=0;for(const e of this.v)void 0!==e&&(void 0!==e.strings?(e._$AI(t,e,i),i+=e.strings.length-2):e._$AI(t[i])),i++}}class L{constructor(t,i,e,o){var s;this.type=2,this._$AH=Z,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=e,this.options=o,this._$C_=null===(s=null==o?void 0:o.isConnected)||void 0===s||s}get _$AU(){var t,i;return null!==(i=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==i?i:this._$C_}get parentNode(){let t=this._$AA.parentNode;const i=this._$AM;return void 0!==i&&11===t.nodeType&&(t=i.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,i=this){t=F(this,t,i),O(t)?t===Z||null==t||""===t?(this._$AH!==Z&&this._$AR(),this._$AH=Z):t!==this._$AH&&t!==U&&this.T(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.k(t):(t=>D(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.S(t):this.T(t)}j(t,i=this._$AB){return this._$AA.parentNode.insertBefore(t,i)}k(t){this._$AH!==t&&(this._$AR(),this._$AH=this.j(t))}T(t){this._$AH!==Z&&O(this._$AH)?this._$AA.nextSibling.data=t:this.k(_.createTextNode(t)),this._$AH=t}$(t){var i;const{values:e,_$litType$:o}=t,s="number"==typeof o?this._$AC(t):(void 0===o.el&&(o.el=H.createElement(o.h,this.options)),o);if((null===(i=this._$AH)||void 0===i?void 0:i._$AD)===s)this._$AH.m(e);else{const t=new K(s,this),i=t.p(this.options);t.m(e),this.k(i),this._$AH=t}}_$AC(t){let i=G.get(t.strings);return void 0===i&&G.set(t.strings,i=new H(t)),i}S(t){D(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let e,o=0;for(const s of t)o===i.length?i.push(e=new L(this.j(N()),this.j(N()),this,this.options)):e=i[o],e._$AI(s),o++;o<i.length&&(this._$AR(e&&e._$AB.nextSibling,o),i.length=o)}_$AR(t=this._$AA.nextSibling,i){var e;for(null===(e=this._$AP)||void 0===e||e.call(this,!1,!0,i);t&&t!==this._$AB;){const i=t.nextSibling;t.remove(),t=i}}setConnected(t){var i;void 0===this._$AM&&(this._$C_=t,null===(i=this._$AP)||void 0===i||i.call(this,t))}}class X{constructor(t,i,e,o,s){this.type=1,this._$AH=Z,this._$AN=void 0,this.element=t,this.name=i,this._$AM=o,this.options=s,e.length>2||""!==e[0]||""!==e[1]?(this._$AH=Array(e.length-1).fill(new String),this.strings=e):this._$AH=Z}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,i=this,e,o){const s=this.strings;let r=!1;if(void 0===s)t=F(this,t,i,0),r=!O(t)||t!==this._$AH&&t!==U,r&&(this._$AH=t);else{const o=t;let n,p;for(t=s[0],n=0;n<s.length-1;n++)p=F(this,o[e+n],i,n),p===U&&(p=this._$AH[n]),r||(r=!O(p)||p!==this._$AH[n]),p===Z?t=Z:t!==Z&&(t+=(null!=p?p:"")+s[n+1]),this._$AH[n]=p}r&&!o&&this.P(t)}P(t){t===Z?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class Y extends X{constructor(){super(...arguments),this.type=3}P(t){this.element[this.name]=t===Z?void 0:t}}const q=w?w.emptyScript:"";class J extends X{constructor(){super(...arguments),this.type=4}P(t){t&&t!==Z?this.element.setAttribute(this.name,q):this.element.removeAttribute(this.name)}}class Q extends X{constructor(t,i,e,o,s){super(t,i,e,o,s),this.type=5}_$AI(t,i=this){var e;if((t=null!==(e=F(this,t,i,0))&&void 0!==e?e:Z)===U)return;const o=this._$AH,s=t===Z&&o!==Z||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,r=t!==Z&&(o===Z||s);s&&this.element.removeEventListener(this.name,this,o),r&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var i,e;"function"==typeof this._$AH?this._$AH.call(null!==(e=null===(i=this.options)||void 0===i?void 0:i.host)&&void 0!==e?e:this.element,t):this._$AH.handleEvent(t)}}class V{constructor(t,i,e){this.element=t,this.type=6,this._$AN=void 0,this._$AM=i,this.options=e}get _$AU(){return this._$AM._$AU}_$AI(t){F(this,t)}}const tt=window.litHtmlPolyfillSupport;null==tt||tt(H,L),(null!==($=globalThis.litHtmlVersions)&&void 0!==$?$:globalThis.litHtmlVersions=[]).push("2.2.7");
|
|
113
108
|
/**
|
|
114
109
|
* @license
|
|
115
110
|
* Copyright 2020 Google LLC
|
|
116
111
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
117
112
|
*/
|
|
118
|
-
const
|
|
113
|
+
const it=Symbol.for(""),et=t=>{if((null==t?void 0:t.r)===it)return null==t?void 0:t._$litStatic$},ot=t=>({_$litStatic$:t,r:it}),st=new Map,rt=(t=>(i,...e)=>{const o=e.length;let s,r;const n=[],p=[];let l,h=0,a=!1;for(;h<o;){for(l=i[h];h<o&&void 0!==(r=e[h],s=et(r));)l+=s+i[++h],a=!0;p.push(r),n.push(l),h++}if(h===o&&n.push(i[o]),a){const t=n.join("$$lit$$");void 0===(i=st.get(t))&&(n.raw=n,st.set(t,i=n)),e=p}return t(i,...e)})(C);var nt;!function(t){t.title="title",t.title_dense="title-dense",t.subtitle1="subtitle1",t.subtitle2="subtitle2",t.body1="body1",t.body2="body2",t.caption="caption",t.breadcrumb="breadcrumb",t.overline="overline",t.button="button"}(nt||(nt={}));const pt=i.FtCssVariableFactory.extend("--ft-typography-font-family",i.designSystemVariables.titleFont),lt=i.FtCssVariableFactory.extend("--ft-typography-font-family",i.designSystemVariables.contentFont),ht={fontFamily:lt,fontSize:i.FtCssVariableFactory.create("--ft-typography-font-size","SIZE","16px"),fontWeight:i.FtCssVariableFactory.create("--ft-typography-font-weight","UNKNOWN","normal"),letterSpacing:i.FtCssVariableFactory.create("--ft-typography-letter-spacing","SIZE","0.496px"),lineHeight:i.FtCssVariableFactory.create("--ft-typography-line-height","NUMBER","1.5"),textTransform:i.FtCssVariableFactory.create("--ft-typography-text-transform","UNKNOWN","inherit")},at=i.FtCssVariableFactory.extend("--ft-typography-title-font-family",pt),ft=i.FtCssVariableFactory.extend("--ft-typography-title-font-size",ht.fontSize,"20px"),dt=i.FtCssVariableFactory.extend("--ft-typography-title-font-weight",ht.fontWeight,"normal"),yt=i.FtCssVariableFactory.extend("--ft-typography-title-letter-spacing",ht.letterSpacing,"0.15px"),ct=i.FtCssVariableFactory.extend("--ft-typography-title-line-height",ht.lineHeight,"1.2"),gt=i.FtCssVariableFactory.extend("--ft-typography-title-text-transform",ht.textTransform,"inherit"),ut=i.FtCssVariableFactory.extend("--ft-typography-title-dense-font-family",pt),vt=i.FtCssVariableFactory.extend("--ft-typography-title-dense-font-size",ht.fontSize,"14px"),bt=i.FtCssVariableFactory.extend("--ft-typography-title-dense-font-weight",ht.fontWeight,"normal"),$t=i.FtCssVariableFactory.extend("--ft-typography-title-dense-letter-spacing",ht.letterSpacing,"0.105px"),mt=i.FtCssVariableFactory.extend("--ft-typography-title-dense-line-height",ht.lineHeight,"1.7"),xt=i.FtCssVariableFactory.extend("--ft-typography-title-dense-text-transform",ht.textTransform,"inherit"),wt=i.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-family",lt),kt=i.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-size",ht.fontSize,"16px"),zt=i.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-weight",ht.fontWeight,"600"),At=i.FtCssVariableFactory.extend("--ft-typography-subtitle1-letter-spacing",ht.letterSpacing,"0.144px"),St=i.FtCssVariableFactory.extend("--ft-typography-subtitle1-line-height",ht.lineHeight,"1.5"),_t=i.FtCssVariableFactory.extend("--ft-typography-subtitle1-text-transform",ht.textTransform,"inherit"),Nt=i.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-family",lt),Ot=i.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-size",ht.fontSize,"14px"),Dt=i.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-weight",ht.fontWeight,"normal"),Et=i.FtCssVariableFactory.extend("--ft-typography-subtitle2-letter-spacing",ht.letterSpacing,"0.098px"),Mt=i.FtCssVariableFactory.extend("--ft-typography-subtitle2-line-height",ht.lineHeight,"1.7"),jt=i.FtCssVariableFactory.extend("--ft-typography-subtitle2-text-transform",ht.textTransform,"inherit"),Tt=i.FtCssVariableFactory.extend("--ft-typography-body1-font-family",lt),Bt=i.FtCssVariableFactory.extend("--ft-typography-body1-font-size",ht.fontSize,"16px"),It=i.FtCssVariableFactory.extend("--ft-typography-body1-font-weight",ht.fontWeight,"normal"),Rt=i.FtCssVariableFactory.extend("--ft-typography-body1-letter-spacing",ht.letterSpacing,"0.496px"),Ct=i.FtCssVariableFactory.extend("--ft-typography-body1-line-height",ht.lineHeight,"1.5"),Ut=i.FtCssVariableFactory.extend("--ft-typography-body1-text-transform",ht.textTransform,"inherit"),Zt=i.FtCssVariableFactory.extend("--ft-typography-body2-font-family",lt),Gt=i.FtCssVariableFactory.extend("--ft-typography-body2-font-size",ht.fontSize,"14px"),Pt=i.FtCssVariableFactory.extend("--ft-typography-body2-font-weight",ht.fontWeight,"normal"),Wt=i.FtCssVariableFactory.extend("--ft-typography-body2-letter-spacing",ht.letterSpacing,"0.252px"),Ht=i.FtCssVariableFactory.extend("--ft-typography-body2-line-height",ht.lineHeight,"1.4"),Ft=i.FtCssVariableFactory.extend("--ft-typography-body2-text-transform",ht.textTransform,"inherit"),Kt=i.FtCssVariableFactory.extend("--ft-typography-caption-font-family",lt),Lt=i.FtCssVariableFactory.extend("--ft-typography-caption-font-size",ht.fontSize,"12px"),Xt=i.FtCssVariableFactory.extend("--ft-typography-caption-font-weight",ht.fontWeight,"normal"),Yt=i.FtCssVariableFactory.extend("--ft-typography-caption-letter-spacing",ht.letterSpacing,"0.396px"),qt=i.FtCssVariableFactory.extend("--ft-typography-caption-line-height",ht.lineHeight,"1.33"),Jt=i.FtCssVariableFactory.extend("--ft-typography-caption-text-transform",ht.textTransform,"inherit"),Qt=i.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-family",lt),Vt=i.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-size",ht.fontSize,"10px"),ti=i.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-weight",ht.fontWeight,"normal"),ii=i.FtCssVariableFactory.extend("--ft-typography-breadcrumb-letter-spacing",ht.letterSpacing,"0.33px"),ei=i.FtCssVariableFactory.extend("--ft-typography-breadcrumb-line-height",ht.lineHeight,"1.6"),oi=i.FtCssVariableFactory.extend("--ft-typography-breadcrumb-text-transform",ht.textTransform,"inherit"),si=i.FtCssVariableFactory.extend("--ft-typography-overline-font-family",lt),ri=i.FtCssVariableFactory.extend("--ft-typography-overline-font-size",ht.fontSize,"10px"),ni=i.FtCssVariableFactory.extend("--ft-typography-overline-font-weight",ht.fontWeight,"normal"),pi=i.FtCssVariableFactory.extend("--ft-typography-overline-letter-spacing",ht.letterSpacing,"1.5px"),li=i.FtCssVariableFactory.extend("--ft-typography-overline-line-height",ht.lineHeight,"1.6"),hi=i.FtCssVariableFactory.extend("--ft-typography-overline-text-transform",ht.textTransform,"uppercase"),ai=i.FtCssVariableFactory.extend("--ft-typography-button-font-family",lt),fi=i.FtCssVariableFactory.extend("--ft-typography-button-font-size",ht.fontSize,"14px"),di=i.FtCssVariableFactory.extend("--ft-typography-button-font-weight",ht.fontWeight,"600"),yi=i.FtCssVariableFactory.extend("--ft-typography-button-letter-spacing",ht.letterSpacing,"1.246px"),ci=i.FtCssVariableFactory.extend("--ft-typography-button-line-height",ht.lineHeight,"1.15"),gi=i.FtCssVariableFactory.extend("--ft-typography-button-text-transform",ht.textTransform,"uppercase"),ui=e.css`
|
|
119
114
|
.ft-typography--title {
|
|
120
|
-
font-family: ${
|
|
121
|
-
font-size: ${
|
|
115
|
+
font-family: ${at};
|
|
116
|
+
font-size: ${ft};
|
|
122
117
|
font-weight: ${dt};
|
|
123
|
-
letter-spacing: ${
|
|
124
|
-
line-height: ${
|
|
125
|
-
text-transform: ${
|
|
118
|
+
letter-spacing: ${yt};
|
|
119
|
+
line-height: ${ct};
|
|
120
|
+
text-transform: ${gt};
|
|
126
121
|
}
|
|
127
122
|
`,vi=e.css`
|
|
128
123
|
.ft-typography--title-dense {
|
|
129
|
-
font-family: ${
|
|
124
|
+
font-family: ${ut};
|
|
130
125
|
font-size: ${vt};
|
|
131
|
-
font-weight: ${
|
|
126
|
+
font-weight: ${bt};
|
|
132
127
|
letter-spacing: ${$t};
|
|
133
|
-
line-height: ${
|
|
134
|
-
text-transform: ${
|
|
128
|
+
line-height: ${mt};
|
|
129
|
+
text-transform: ${xt};
|
|
135
130
|
}
|
|
136
|
-
`,
|
|
131
|
+
`,bi=e.css`
|
|
137
132
|
.ft-typography--subtitle1 {
|
|
138
|
-
font-family: ${
|
|
139
|
-
font-size: ${
|
|
140
|
-
font-weight: ${
|
|
141
|
-
letter-spacing: ${
|
|
142
|
-
line-height: ${
|
|
143
|
-
text-transform: ${
|
|
133
|
+
font-family: ${wt};
|
|
134
|
+
font-size: ${kt};
|
|
135
|
+
font-weight: ${zt};
|
|
136
|
+
letter-spacing: ${At};
|
|
137
|
+
line-height: ${St};
|
|
138
|
+
text-transform: ${_t};
|
|
144
139
|
}
|
|
145
140
|
`,$i=e.css`
|
|
146
141
|
.ft-typography--subtitle2 {
|
|
147
|
-
font-family: ${
|
|
148
|
-
font-size: ${
|
|
149
|
-
font-weight: ${
|
|
150
|
-
letter-spacing: ${
|
|
151
|
-
line-height: ${
|
|
152
|
-
text-transform: ${
|
|
142
|
+
font-family: ${Nt};
|
|
143
|
+
font-size: ${Ot};
|
|
144
|
+
font-weight: ${Dt};
|
|
145
|
+
letter-spacing: ${Et};
|
|
146
|
+
line-height: ${Mt};
|
|
147
|
+
text-transform: ${jt};
|
|
153
148
|
}
|
|
154
149
|
|
|
155
|
-
`,
|
|
150
|
+
`,mi=e.css`
|
|
156
151
|
.ft-typography--body1 {
|
|
157
|
-
font-family: ${
|
|
158
|
-
font-size: ${
|
|
159
|
-
font-weight: ${
|
|
160
|
-
letter-spacing: ${
|
|
161
|
-
line-height: ${
|
|
162
|
-
text-transform: ${
|
|
152
|
+
font-family: ${Tt};
|
|
153
|
+
font-size: ${Bt};
|
|
154
|
+
font-weight: ${It};
|
|
155
|
+
letter-spacing: ${Rt};
|
|
156
|
+
line-height: ${Ct};
|
|
157
|
+
text-transform: ${Ut};
|
|
163
158
|
}
|
|
164
|
-
`,
|
|
159
|
+
`,xi=e.css`
|
|
165
160
|
.ft-typography--body2 {
|
|
166
|
-
font-family: ${
|
|
167
|
-
font-size: ${
|
|
168
|
-
font-weight: ${
|
|
169
|
-
letter-spacing: ${
|
|
170
|
-
line-height: ${
|
|
171
|
-
text-transform: ${
|
|
161
|
+
font-family: ${Zt};
|
|
162
|
+
font-size: ${Gt};
|
|
163
|
+
font-weight: ${Pt};
|
|
164
|
+
letter-spacing: ${Wt};
|
|
165
|
+
line-height: ${Ht};
|
|
166
|
+
text-transform: ${Ft};
|
|
172
167
|
}
|
|
173
|
-
`,
|
|
168
|
+
`,wi=e.css`
|
|
174
169
|
.ft-typography--caption {
|
|
175
|
-
font-family: ${
|
|
176
|
-
font-size: ${
|
|
177
|
-
font-weight: ${
|
|
178
|
-
letter-spacing: ${
|
|
179
|
-
line-height: ${
|
|
180
|
-
text-transform: ${
|
|
170
|
+
font-family: ${Kt};
|
|
171
|
+
font-size: ${Lt};
|
|
172
|
+
font-weight: ${Xt};
|
|
173
|
+
letter-spacing: ${Yt};
|
|
174
|
+
line-height: ${qt};
|
|
175
|
+
text-transform: ${Jt};
|
|
181
176
|
}
|
|
182
|
-
`,
|
|
177
|
+
`,ki=e.css`
|
|
183
178
|
.ft-typography--breadcrumb {
|
|
184
|
-
font-family: ${
|
|
185
|
-
font-size: ${
|
|
186
|
-
font-weight: ${
|
|
187
|
-
letter-spacing: ${
|
|
188
|
-
line-height: ${
|
|
189
|
-
text-transform: ${
|
|
179
|
+
font-family: ${Qt};
|
|
180
|
+
font-size: ${Vt};
|
|
181
|
+
font-weight: ${ti};
|
|
182
|
+
letter-spacing: ${ii};
|
|
183
|
+
line-height: ${ei};
|
|
184
|
+
text-transform: ${oi};
|
|
190
185
|
}
|
|
191
|
-
`,
|
|
186
|
+
`,zi=e.css`
|
|
192
187
|
.ft-typography--overline {
|
|
193
188
|
font-family: ${si};
|
|
194
|
-
font-size: ${
|
|
195
|
-
font-weight: ${
|
|
196
|
-
letter-spacing: ${
|
|
197
|
-
line-height: ${
|
|
189
|
+
font-size: ${ri};
|
|
190
|
+
font-weight: ${ni};
|
|
191
|
+
letter-spacing: ${pi};
|
|
192
|
+
line-height: ${li};
|
|
198
193
|
text-transform: ${hi};
|
|
199
194
|
}
|
|
200
|
-
`,
|
|
195
|
+
`,Ai=e.css`
|
|
201
196
|
.ft-typography--button {
|
|
202
|
-
font-family: ${
|
|
203
|
-
font-size: ${
|
|
197
|
+
font-family: ${ai};
|
|
198
|
+
font-size: ${fi};
|
|
204
199
|
font-weight: ${di};
|
|
205
|
-
letter-spacing: ${
|
|
206
|
-
line-height: ${
|
|
207
|
-
text-transform: ${
|
|
200
|
+
letter-spacing: ${yi};
|
|
201
|
+
line-height: ${ci};
|
|
202
|
+
text-transform: ${gi};
|
|
203
|
+
}
|
|
204
|
+
`,Si=e.css`
|
|
205
|
+
.ft-typography {
|
|
206
|
+
vertical-align: inherit;
|
|
208
207
|
}
|
|
209
|
-
`;class
|
|
210
|
-
<${
|
|
208
|
+
`;var _i=function(t,i,e,o){for(var s,r=arguments.length,n=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,p=t.length-1;p>=0;p--)(s=t[p])&&(n=(r<3?s(n):r>3?s(i,e,n):s(i,e))||n);return r>3&&n&&Object.defineProperty(i,e,n),n};class Ni extends i.FtLitElement{constructor(){super(...arguments),this.variant=nt.body1}render(){return this.element?rt`
|
|
209
|
+
<${ot(this.element)}
|
|
211
210
|
class="ft-typography ft-typography--${this.variant}">
|
|
212
211
|
<slot></slot>
|
|
213
|
-
</${
|
|
214
|
-
`:
|
|
212
|
+
</${ot(this.element)}>
|
|
213
|
+
`:rt`
|
|
215
214
|
<slot class="ft-typography ft-typography--${this.variant}"></slot>
|
|
216
|
-
`}}
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
`],at([o.property()],Ei.prototype,"element",void 0),at([o.property()],Ei.prototype,"variant",void 0),i.customElement("ft-typography")(Ei);var Fi=function(t,i,e,o){for(var r,n=arguments.length,s=n<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,p=t.length-1;p>=0;p--)(r=t[p])&&(s=(n<3?r(s):n>3?r(i,e,s):r(i,e))||s);return n>3&&s&&Object.defineProperty(i,e,s),s};const Mi={padding:i.FtCssVariableFactory.create("--ft-card-padding","SIZE","12px"),colorPrimary:i.FtCssVariableFactory.external($.colorPrimary,"Design system"),colorSurface:i.FtCssVariableFactory.external($.colorSurface,"Design system"),colorOnSurfaceMedium:i.FtCssVariableFactory.external($.colorOnSurfaceMedium,"Design system"),colorOnSurfaceHigh:i.FtCssVariableFactory.external($.colorOnSurfaceHigh,"Design system"),borderRadiusM:i.FtCssVariableFactory.external($.borderRadiusM,"Design system"),elevation02:i.FtCssVariableFactory.external($.elevation02,"Design system"),elevation04:i.FtCssVariableFactory.external($.elevation04,"Design system")};class Ci extends i.FtLitElement{constructor(){super(...arguments),this.title="",this.selected=!1}static get styles(){return e.css`
|
|
221
|
-
:host {
|
|
222
|
-
display: block;
|
|
223
|
-
}
|
|
215
|
+
`}}Ni.styles=[ui,vi,bi,$i,mi,xi,wi,ki,zi,Ai,Si],_i([o.property()],Ni.prototype,"element",void 0),_i([o.property()],Ni.prototype,"variant",void 0),i.customElement("ft-typography")(Ni);const Oi={padding:i.FtCssVariableFactory.create("--ft-card-padding","SIZE","12px"),colorPrimary:i.FtCssVariableFactory.external(i.designSystemVariables.colorPrimary,"Design system"),colorSurface:i.FtCssVariableFactory.external(i.designSystemVariables.colorSurface,"Design system"),colorOnSurfaceMedium:i.FtCssVariableFactory.external(i.designSystemVariables.colorOnSurfaceMedium,"Design system"),colorOnSurfaceHigh:i.FtCssVariableFactory.external(i.designSystemVariables.colorOnSurfaceHigh,"Design system"),borderRadiusM:i.FtCssVariableFactory.external(i.designSystemVariables.borderRadiusM,"Design system"),elevation02:i.FtCssVariableFactory.external(i.designSystemVariables.elevation02,"Design system"),elevation04:i.FtCssVariableFactory.external(i.designSystemVariables.elevation04,"Design system")},Di=e.css`
|
|
216
|
+
:host {
|
|
217
|
+
display: block;
|
|
218
|
+
}
|
|
224
219
|
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
220
|
+
#container {
|
|
221
|
+
padding: ${Oi.padding};
|
|
222
|
+
border-radius: ${Oi.borderRadiusM};
|
|
223
|
+
box-shadow: ${Oi.elevation02};
|
|
224
|
+
position: relative;
|
|
225
|
+
width: 100%;
|
|
226
|
+
height: 100%;
|
|
227
|
+
display: block;
|
|
228
|
+
box-sizing: border-box;
|
|
229
|
+
background-color: ${Oi.colorSurface};
|
|
230
|
+
transition: box-shadow 0.2s linear, color 0.2s linear;
|
|
231
|
+
}
|
|
237
232
|
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
233
|
+
#container:hover {
|
|
234
|
+
box-shadow: ${Oi.elevation04};
|
|
235
|
+
}
|
|
241
236
|
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
237
|
+
#container.selected {
|
|
238
|
+
outline: solid 2px ${Oi.colorPrimary};
|
|
239
|
+
box-shadow: ${Oi.elevation04};
|
|
240
|
+
}
|
|
246
241
|
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
242
|
+
#header:not([hidden]) {
|
|
243
|
+
display: flex;
|
|
244
|
+
margin-bottom: 8px;
|
|
245
|
+
}
|
|
251
246
|
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
247
|
+
#header-content {
|
|
248
|
+
margin-left: 4px;
|
|
249
|
+
}
|
|
255
250
|
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
251
|
+
.title {
|
|
252
|
+
text-overflow: ellipsis;
|
|
253
|
+
overflow: hidden;
|
|
254
|
+
color: ${Oi.colorOnSurfaceHigh};
|
|
255
|
+
}
|
|
261
256
|
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
257
|
+
#content {
|
|
258
|
+
opacity: 1;
|
|
259
|
+
font-size: 15px;
|
|
260
|
+
height: 100%;
|
|
261
|
+
color: ${Oi.colorOnSurfaceMedium};
|
|
262
|
+
}
|
|
268
263
|
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
264
|
+
#action {
|
|
265
|
+
position: absolute;
|
|
266
|
+
top: 0;
|
|
267
|
+
right: 0;
|
|
268
|
+
color: ${Oi.colorOnSurfaceHigh};
|
|
269
|
+
}
|
|
270
|
+
`;var Ei=function(t,i,e,o){for(var s,r=arguments.length,n=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,p=t.length-1;p>=0;p--)(s=t[p])&&(n=(r<3?s(n):r>3?s(i,e,n):s(i,e))||n);return r>3&&n&&Object.defineProperty(i,e,n),n};class Mi extends i.FtLitElement{constructor(){super(...arguments),this.title="",this.selected=!1}render(){return e.html`
|
|
276
271
|
<div id="container" part="container" class=${this.selected?"selected":""}>
|
|
277
272
|
<ft-ripple primary></ft-ripple>
|
|
278
273
|
<div id="header" ?hidden=${!this.title} part="header">
|
|
@@ -288,4 +283,4 @@ const et=Symbol.for(""),ot=t=>{if((null==t?void 0:t.r)===et)return null==t?void
|
|
|
288
283
|
<slot name="action"></slot>
|
|
289
284
|
</div>
|
|
290
285
|
</div>
|
|
291
|
-
`}}
|
|
286
|
+
`}}Mi.elementDefinitions={"ft-ripple":x,"ft-typography":Ni},Mi.styles=Di,Ei([o.property()],Mi.prototype,"title",void 0),Ei([o.property({type:Boolean})],Mi.prototype,"selected",void 0),i.customElement("ft-card")(Mi),t.FtCard=Mi,t.FtCardCssVariables=Oi,t.styles=Di,Object.defineProperty(t,"t",{value:!0})}({},ftGlobals.wcUtils,ftGlobals.lit,ftGlobals.litDecorators,ftGlobals.litClassMap);
|