@fluid-topics/ft-input-label 0.2.2 → 0.2.6
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-input-label.d.ts +3 -0
- package/build/ft-input-label.inline-styles.js +108 -100
- package/build/ft-input-label.js +15 -1
- package/build/ft-input-label.light.js +103 -95
- package/build/ft-input-label.min.js +107 -99
- package/package.json +4 -4
|
@@ -4,115 +4,115 @@
|
|
|
4
4
|
* Copyright 2017 Google LLC
|
|
5
5
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
6
6
|
*/
|
|
7
|
-
var r;const l=globalThis.trustedTypes,s=l?l.createPolicy("lit-html",{createHTML:t=>t}):void 0,a=`lit$${(Math.random()+"").slice(9)}$`,p="?"+a,h=`<${p}>`,f=document,y=(t="")=>f.createComment(t),d=t=>null===t||"object"!=typeof t&&"function"!=typeof t,g=Array.isArray,u=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,c=/-->/g,b=/>/g,$=/>|[ \n\r](?:([^\s"'>=/]+)([ \n\r]*=[ \n\r]*(?:[^ \n\r"'`<>=]|("|')|))|$)/g,
|
|
7
|
+
var r;const l=globalThis.trustedTypes,s=l?l.createPolicy("lit-html",{createHTML:t=>t}):void 0,a=`lit$${(Math.random()+"").slice(9)}$`,p="?"+a,h=`<${p}>`,f=document,y=(t="")=>f.createComment(t),d=t=>null===t||"object"!=typeof t&&"function"!=typeof t,g=Array.isArray,u=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,c=/-->/g,b=/>/g,$=/>|[ \n\r](?:([^\s"'>=/]+)([ \n\r]*=[ \n\r]*(?:[^ \n\r"'`<>=]|("|')|))|$)/g,v=/'/g,x=/"/g,m=/^(?:script|style|textarea|title)$/i,w=(t=>(i,...e)=>({_$litType$:t,strings:i,values:e}))(1),z=Symbol.for("lit-noChange"),S=Symbol.for("lit-nothing"),_=new WeakMap,A=f.createTreeWalker(f,129,null,!1),E=(t,i)=>{const e=t.length-1,o=[];let n,r=2===i?"<svg>":"",l=u;for(let i=0;i<e;i++){const e=t[i];let s,p,f=-1,y=0;for(;y<e.length&&(l.lastIndex=y,p=l.exec(e),null!==p);)y=l.lastIndex,l===u?"!--"===p[1]?l=c:void 0!==p[1]?l=b:void 0!==p[2]?(m.test(p[2])&&(n=RegExp("</"+p[2],"g")),l=$):void 0!==p[3]&&(l=$):l===$?">"===p[0]?(l=null!=n?n:u,f=-1):void 0===p[1]?f=-2:(f=l.lastIndex-p[2].length,s=p[1],l=void 0===p[3]?$:'"'===p[3]?x:v):l===x||l===v?l=$:l===c||l===b?l=u:(l=$,n=void 0);const d=l===$&&t[i+1].startsWith("/>")?" ":"";r+=l===u?e+h:f>=0?(o.push(s),e.slice(0,f)+"$lit$"+e.slice(f)+a+d):e+a+(-2===f?(o.push(void 0),i):d)}const p=r+(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 I{constructor({strings:t,_$litType$:i},e){let o;this.parts=[];let n=0,r=0;const s=t.length-1,h=this.parts,[f,d]=E(t,i);if(this.el=I.createElement(f,e),A.currentNode=this.el.content,2===i){const t=this.el.content,i=t.firstChild;i.remove(),t.append(...i.childNodes)}for(;null!==(o=A.nextNode())&&h.length<s;){if(1===o.nodeType){if(o.hasAttributes()){const t=[];for(const i of o.getAttributeNames())if(i.endsWith("$lit$")||i.startsWith(a)){const e=d[r++];if(t.push(i),void 0!==e){const t=o.getAttribute(e.toLowerCase()+"$lit$").split(a),i=/([.?@])?(.*)/.exec(e);h.push({type:1,index:n,name:i[2],strings:t,ctor:"."===i[1]?M:"?"===i[1]?U:"@"===i[1]?j:C})}else h.push({type:6,index:n})}for(const i of t)o.removeAttribute(i)}if(m.test(o.tagName)){const t=o.textContent.split(a),i=t.length-1;if(i>0){o.textContent=l?l.emptyScript:"";for(let e=0;e<i;e++)o.append(t[e],y()),A.nextNode(),h.push({type:2,index:++n});o.append(t[i],y())}}}else if(8===o.nodeType)if(o.data===p)h.push({type:2,index:n});else{let t=-1;for(;-1!==(t=o.data.indexOf(a,t+1));)h.push({type:7,index:n}),t+=a.length-1}n++}}static createElement(t,i){const e=f.createElement("template");return e.innerHTML=t,e}}function N(t,i,e=t,o){var n,r,l,s;if(i===z)return i;let a=void 0!==o?null===(n=e._$Cl)||void 0===n?void 0:n[o]:e._$Cu;const p=d(i)?void 0:i._$litDirective$;return(null==a?void 0:a.constructor)!==p&&(null===(r=null==a?void 0:a._$AO)||void 0===r||r.call(a,!1),void 0===p?a=void 0:(a=new p(t),a._$AT(t,e,o)),void 0!==o?(null!==(l=(s=e)._$Cl)&&void 0!==l?l:s._$Cl=[])[o]=a:e._$Cu=a),void 0!==a&&(i=N(t,a._$AS(t,i.values),a,o)),i}class T{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,n=(null!==(i=null==t?void 0:t.creationScope)&&void 0!==i?i:f).importNode(e,!0);A.currentNode=n;let r=A.nextNode(),l=0,s=0,a=o[0];for(;void 0!==a;){if(l===a.index){let i;2===a.type?i=new Z(r,r.nextSibling,this,t):1===a.type?i=new a.ctor(r,a.name,a.strings,this,t):6===a.type&&(i=new k(r,this,t)),this.v.push(i),a=o[++s]}l!==(null==a?void 0:a.index)&&(r=A.nextNode(),l++)}return n}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 Z{constructor(t,i,e,o){var n;this.type=2,this._$AH=S,this._$AN=void 0,this._$AA=t,this._$AB=i,this._$AM=e,this.options=o,this._$Cg=null===(n=null==o?void 0:o.isConnected)||void 0===n||n}get _$AU(){var t,i;return null!==(i=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==i?i:this._$Cg}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=N(this,t,i),d(t)?t===S||null==t||""===t?(this._$AH!==S&&this._$AR(),this._$AH=S):t!==this._$AH&&t!==z&&this.$(t):void 0!==t._$litType$?this.T(t):void 0!==t.nodeType?this.k(t):(t=>{var i;return g(t)||"function"==typeof(null===(i=t)||void 0===i?void 0:i[Symbol.iterator])})(t)?this.S(t):this.$(t)}M(t,i=this._$AB){return this._$AA.parentNode.insertBefore(t,i)}k(t){this._$AH!==t&&(this._$AR(),this._$AH=this.M(t))}$(t){this._$AH!==S&&d(this._$AH)?this._$AA.nextSibling.data=t:this.k(f.createTextNode(t)),this._$AH=t}T(t){var i;const{values:e,_$litType$:o}=t,n="number"==typeof o?this._$AC(t):(void 0===o.el&&(o.el=I.createElement(o.h,this.options)),o);if((null===(i=this._$AH)||void 0===i?void 0:i._$AD)===n)this._$AH.m(e);else{const t=new T(n,this),i=t.p(this.options);t.m(e),this.k(i),this._$AH=t}}_$AC(t){let i=_.get(t.strings);return void 0===i&&_.set(t.strings,i=new I(t)),i}S(t){g(this._$AH)||(this._$AH=[],this._$AR());const i=this._$AH;let e,o=0;for(const n of t)o===i.length?i.push(e=new Z(this.M(y()),this.M(y()),this,this.options)):e=i[o],e._$AI(n),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._$Cg=t,null===(i=this._$AP)||void 0===i||i.call(this,t))}}class C{constructor(t,i,e,o,n){this.type=1,this._$AH=S,this._$AN=void 0,this.element=t,this.name=i,this._$AM=o,this.options=n,e.length>2||""!==e[0]||""!==e[1]?(this._$AH=Array(e.length-1).fill(new String),this.strings=e):this._$AH=S}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,i=this,e,o){const n=this.strings;let r=!1;if(void 0===n)t=N(this,t,i,0),r=!d(t)||t!==this._$AH&&t!==z,r&&(this._$AH=t);else{const o=t;let l,s;for(t=n[0],l=0;l<n.length-1;l++)s=N(this,o[e+l],i,l),s===z&&(s=this._$AH[l]),r||(r=!d(s)||s!==this._$AH[l]),s===S?t=S:t!==S&&(t+=(null!=s?s:"")+n[l+1]),this._$AH[l]=s}r&&!o&&this.C(t)}C(t){t===S?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class M extends C{constructor(){super(...arguments),this.type=3}C(t){this.element[this.name]=t===S?void 0:t}}const O=l?l.emptyScript:"";class U extends C{constructor(){super(...arguments),this.type=4}C(t){t&&t!==S?this.element.setAttribute(this.name,O):this.element.removeAttribute(this.name)}}class j extends C{constructor(t,i,e,o,n){super(t,i,e,o,n),this.type=5}_$AI(t,i=this){var e;if((t=null!==(e=N(this,t,i,0))&&void 0!==e?e:S)===z)return;const o=this._$AH,n=t===S&&o!==S||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,r=t!==S&&(o===S||n);n&&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 k{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){N(this,t)}}const B=window.litHtmlPolyfillSupport;null==B||B(I,Z),(null!==(r=globalThis.litHtmlVersions)&&void 0!==r?r:globalThis.litHtmlVersions=[]).push("2.2.4");
|
|
8
8
|
/**
|
|
9
9
|
* @license
|
|
10
10
|
* Copyright 2020 Google LLC
|
|
11
11
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
12
12
|
*/
|
|
13
|
-
const
|
|
13
|
+
const W=Symbol.for(""),G=t=>{var i,e;if((null===(i=t)||void 0===i?void 0:i.r)===W)return null===(e=t)||void 0===e?void 0:e._$litStatic$},R=t=>({_$litStatic$:t,r:W}),D=new Map,F=(t=>(i,...e)=>{const o=e.length;let n,r;const l=[],s=[];let a,p=0,h=!1;for(;p<o;){for(a=i[p];p<o&&void 0!==(r=e[p],n=G(r));)a+=n+i[++p],h=!0;s.push(r),l.push(a),p++}if(p===o&&l.push(i[o]),h){const t=l.join("$$lit$$");void 0===(i=D.get(t))&&(l.raw=l,D.set(t,i=l)),e=s}return t(i,...e)})(w);var H,K=function(t,i,e,o){for(var n,r=arguments.length,l=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,s=t.length-1;s>=0;s--)(n=t[s])&&(l=(r<3?n(l):r>3?n(i,e,l):n(i,e))||l);return r>3&&l&&Object.defineProperty(i,e,l),l};!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"}(H||(H={}));const L=i.FtCssVariable.extend("--ft-typography-font-family",i.designSystemVariables.titleFont),q=i.FtCssVariable.extend("--ft-typography-font-family",i.designSystemVariables.contentFont),J={fontFamily:q,fontSize:i.FtCssVariable.create("--ft-typography-font-size","SIZE","16px"),fontWeight:i.FtCssVariable.create("--ft-typography-font-weight","UNKNOWN","normal"),letterSpacing:i.FtCssVariable.create("--ft-typography-letter-spacing","SIZE","0.496px"),lineHeight:i.FtCssVariable.create("--ft-typography-line-height","SIZE","24px"),textTransform:i.FtCssVariable.create("--ft-typography-text-transform","UNKNOWN","inherit")},P=i.FtCssVariable.extend("--ft-typography-title-font-family",L),Q=i.FtCssVariable.extend("--ft-typography-title-font-size",J.fontSize,"20px"),V=i.FtCssVariable.extend("--ft-typography-title-font-weight",J.fontWeight,"normal"),X=i.FtCssVariable.extend("--ft-typography-title-letter-spacing",J.letterSpacing,"0.15px"),Y=i.FtCssVariable.extend("--ft-typography-title-line-height",J.lineHeight,"24px"),tt=i.FtCssVariable.extend("--ft-typography-title-text-transform",J.textTransform,"inherit"),it=i.FtCssVariable.extend("--ft-typography-title-dense-font-family",L),et=i.FtCssVariable.extend("--ft-typography-title-dense-font-size",J.fontSize,"14px"),ot=i.FtCssVariable.extend("--ft-typography-title-dense-font-weight",J.fontWeight,"normal"),nt=i.FtCssVariable.extend("--ft-typography-title-dense-letter-spacing",J.letterSpacing,"0.105px"),rt=i.FtCssVariable.extend("--ft-typography-title-dense-line-height",J.lineHeight,"24px"),lt=i.FtCssVariable.extend("--ft-typography-title-dense-text-transform",J.textTransform,"inherit"),st=i.FtCssVariable.extend("--ft-typography-subtitle1-font-family",q),at=i.FtCssVariable.extend("--ft-typography-subtitle1-font-size",J.fontSize,"16px"),pt=i.FtCssVariable.extend("--ft-typography-subtitle1-font-weight",J.fontWeight,"600"),ht=i.FtCssVariable.extend("--ft-typography-subtitle1-letter-spacing",J.letterSpacing,"0.144px"),ft=i.FtCssVariable.extend("--ft-typography-subtitle1-line-height",J.lineHeight,"24px"),yt=i.FtCssVariable.extend("--ft-typography-subtitle1-text-transform",J.textTransform,"inherit"),dt=i.FtCssVariable.extend("--ft-typography-subtitle2-font-family",q),gt=i.FtCssVariable.extend("--ft-typography-subtitle2-font-size",J.fontSize,"14px"),ut=i.FtCssVariable.extend("--ft-typography-subtitle2-font-weight",J.fontWeight,"normal"),ct=i.FtCssVariable.extend("--ft-typography-subtitle2-letter-spacing",J.letterSpacing,"0.098px"),bt=i.FtCssVariable.extend("--ft-typography-subtitle2-line-height",J.lineHeight,"24px"),$t=i.FtCssVariable.extend("--ft-typography-subtitle2-text-transform",J.textTransform,"inherit"),vt=i.FtCssVariable.extend("--ft-typography-body1-font-family",q),xt=i.FtCssVariable.extend("--ft-typography-body1-font-size",J.fontSize,"16px"),mt=i.FtCssVariable.extend("--ft-typography-body1-font-weight",J.fontWeight,"normal"),wt=i.FtCssVariable.extend("--ft-typography-body1-letter-spacing",J.letterSpacing,"0.496px"),zt=i.FtCssVariable.extend("--ft-typography-body1-line-height",J.lineHeight,"24px"),St=i.FtCssVariable.extend("--ft-typography-body1-text-transform",J.textTransform,"inherit"),_t=i.FtCssVariable.extend("--ft-typography-body2-font-family",q),At=i.FtCssVariable.extend("--ft-typography-body2-font-size",J.fontSize,"14px"),Et=i.FtCssVariable.extend("--ft-typography-body2-font-weight",J.fontWeight,"normal"),It=i.FtCssVariable.extend("--ft-typography-body2-letter-spacing",J.letterSpacing,"0.252px"),Nt=i.FtCssVariable.extend("--ft-typography-body2-line-height",J.lineHeight,"20px"),Tt=i.FtCssVariable.extend("--ft-typography-body2-text-transform",J.textTransform,"inherit"),Zt={fontFamily:i.FtCssVariable.extend("--ft-typography-caption-font-family",q),fontSize:i.FtCssVariable.extend("--ft-typography-caption-font-size",J.fontSize,"12px"),fontWeight:i.FtCssVariable.extend("--ft-typography-caption-font-weight",J.fontWeight,"normal"),letterSpacing:i.FtCssVariable.extend("--ft-typography-caption-letter-spacing",J.letterSpacing,"0.396px"),lineHeight:i.FtCssVariable.extend("--ft-typography-caption-line-height",J.lineHeight,"16px"),textTransform:i.FtCssVariable.extend("--ft-typography-caption-text-transform",J.textTransform,"inherit")},Ct=i.FtCssVariable.extend("--ft-typography-breadcrumb-font-family",q),Mt=i.FtCssVariable.extend("--ft-typography-breadcrumb-font-size",J.fontSize,"10px"),Ot=i.FtCssVariable.extend("--ft-typography-breadcrumb-font-weight",J.fontWeight,"normal"),Ut=i.FtCssVariable.extend("--ft-typography-breadcrumb-letter-spacing",J.letterSpacing,"0.33px"),jt=i.FtCssVariable.extend("--ft-typography-breadcrumb-line-height",J.lineHeight,"16px"),kt=i.FtCssVariable.extend("--ft-typography-breadcrumb-text-transform",J.textTransform,"inherit"),Bt=i.FtCssVariable.extend("--ft-typography-overline-font-family",q),Wt=i.FtCssVariable.extend("--ft-typography-overline-font-size",J.fontSize,"10px"),Gt=i.FtCssVariable.extend("--ft-typography-overline-font-weight",J.fontWeight,"normal"),Rt=i.FtCssVariable.extend("--ft-typography-overline-letter-spacing",J.letterSpacing,"1.5px"),Dt=i.FtCssVariable.extend("--ft-typography-overline-line-height",J.lineHeight,"16px"),Ft=i.FtCssVariable.extend("--ft-typography-overline-text-transform",J.textTransform,"uppercase"),Ht=i.FtCssVariable.extend("--ft-typography-button-font-family",q),Kt=i.FtCssVariable.extend("--ft-typography-button-font-size",J.fontSize,"14px"),Lt=i.FtCssVariable.extend("--ft-typography-button-font-weight",J.fontWeight,"600"),qt=i.FtCssVariable.extend("--ft-typography-button-letter-spacing",J.letterSpacing,"1.246px"),Jt=i.FtCssVariable.extend("--ft-typography-button-line-height",J.lineHeight,"16px"),Pt=i.FtCssVariable.extend("--ft-typography-button-text-transform",J.textTransform,"uppercase"),Qt=e.css`
|
|
14
14
|
.ft-typography--title {
|
|
15
|
-
font-family: ${
|
|
16
|
-
font-size: ${
|
|
17
|
-
font-weight: ${
|
|
18
|
-
letter-spacing: ${
|
|
19
|
-
line-height: ${
|
|
20
|
-
text-transform: ${
|
|
15
|
+
font-family: ${P};
|
|
16
|
+
font-size: ${Q};
|
|
17
|
+
font-weight: ${V};
|
|
18
|
+
letter-spacing: ${X};
|
|
19
|
+
line-height: ${Y};
|
|
20
|
+
text-transform: ${tt};
|
|
21
21
|
}
|
|
22
|
-
`,
|
|
22
|
+
`,Vt=e.css`
|
|
23
23
|
.ft-typography--title-dense {
|
|
24
|
-
font-family: ${
|
|
25
|
-
font-size: ${
|
|
26
|
-
font-weight: ${
|
|
27
|
-
letter-spacing: ${
|
|
28
|
-
line-height: ${
|
|
29
|
-
text-transform: ${
|
|
24
|
+
font-family: ${it};
|
|
25
|
+
font-size: ${et};
|
|
26
|
+
font-weight: ${ot};
|
|
27
|
+
letter-spacing: ${nt};
|
|
28
|
+
line-height: ${rt};
|
|
29
|
+
text-transform: ${lt};
|
|
30
30
|
}
|
|
31
|
-
`,
|
|
31
|
+
`,Xt=e.css`
|
|
32
32
|
.ft-typography--subtitle1 {
|
|
33
|
-
font-family: ${
|
|
34
|
-
font-size: ${
|
|
35
|
-
font-weight: ${
|
|
36
|
-
letter-spacing: ${
|
|
37
|
-
line-height: ${
|
|
38
|
-
text-transform: ${
|
|
33
|
+
font-family: ${st};
|
|
34
|
+
font-size: ${at};
|
|
35
|
+
font-weight: ${pt};
|
|
36
|
+
letter-spacing: ${ht};
|
|
37
|
+
line-height: ${ft};
|
|
38
|
+
text-transform: ${yt};
|
|
39
39
|
}
|
|
40
|
-
`,
|
|
40
|
+
`,Yt=e.css`
|
|
41
41
|
.ft-typography--subtitle2 {
|
|
42
|
-
font-family: ${
|
|
43
|
-
font-size: ${
|
|
44
|
-
font-weight: ${
|
|
45
|
-
letter-spacing: ${
|
|
46
|
-
line-height: ${
|
|
47
|
-
text-transform: ${
|
|
42
|
+
font-family: ${dt};
|
|
43
|
+
font-size: ${gt};
|
|
44
|
+
font-weight: ${ut};
|
|
45
|
+
letter-spacing: ${ct};
|
|
46
|
+
line-height: ${bt};
|
|
47
|
+
text-transform: ${$t};
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
-
`,
|
|
50
|
+
`,ti=e.css`
|
|
51
51
|
.ft-typography--body1 {
|
|
52
|
-
font-family: ${
|
|
53
|
-
font-size: ${
|
|
54
|
-
font-weight: ${
|
|
55
|
-
letter-spacing: ${
|
|
56
|
-
line-height: ${
|
|
57
|
-
text-transform: ${
|
|
52
|
+
font-family: ${vt};
|
|
53
|
+
font-size: ${xt};
|
|
54
|
+
font-weight: ${mt};
|
|
55
|
+
letter-spacing: ${wt};
|
|
56
|
+
line-height: ${zt};
|
|
57
|
+
text-transform: ${St};
|
|
58
58
|
}
|
|
59
|
-
`,
|
|
59
|
+
`,ii=e.css`
|
|
60
60
|
.ft-typography--body2 {
|
|
61
|
-
font-family: ${
|
|
62
|
-
font-size: ${
|
|
63
|
-
font-weight: ${
|
|
64
|
-
letter-spacing: ${
|
|
65
|
-
line-height: ${
|
|
66
|
-
text-transform: ${
|
|
61
|
+
font-family: ${_t};
|
|
62
|
+
font-size: ${At};
|
|
63
|
+
font-weight: ${Et};
|
|
64
|
+
letter-spacing: ${It};
|
|
65
|
+
line-height: ${Nt};
|
|
66
|
+
text-transform: ${Tt};
|
|
67
67
|
}
|
|
68
|
-
`,
|
|
68
|
+
`,ei=e.css`
|
|
69
69
|
.ft-typography--caption {
|
|
70
|
-
font-family: ${
|
|
71
|
-
font-size: ${
|
|
72
|
-
font-weight: ${
|
|
73
|
-
letter-spacing: ${
|
|
74
|
-
line-height: ${
|
|
75
|
-
text-transform: ${
|
|
70
|
+
font-family: ${Zt.fontFamily};
|
|
71
|
+
font-size: ${Zt.fontSize};
|
|
72
|
+
font-weight: ${Zt.fontWeight};
|
|
73
|
+
letter-spacing: ${Zt.letterSpacing};
|
|
74
|
+
line-height: ${Zt.lineHeight};
|
|
75
|
+
text-transform: ${Zt.textTransform};
|
|
76
76
|
}
|
|
77
|
-
`,
|
|
77
|
+
`,oi=e.css`
|
|
78
78
|
.ft-typography--breadcrumb {
|
|
79
|
-
font-family: ${
|
|
80
|
-
font-size: ${
|
|
81
|
-
font-weight: ${
|
|
82
|
-
letter-spacing: ${
|
|
83
|
-
line-height: ${
|
|
84
|
-
text-transform: ${
|
|
79
|
+
font-family: ${Ct};
|
|
80
|
+
font-size: ${Mt};
|
|
81
|
+
font-weight: ${Ot};
|
|
82
|
+
letter-spacing: ${Ut};
|
|
83
|
+
line-height: ${jt};
|
|
84
|
+
text-transform: ${kt};
|
|
85
85
|
}
|
|
86
|
-
`,
|
|
86
|
+
`,ni=e.css`
|
|
87
87
|
.ft-typography--overline {
|
|
88
|
-
font-family: ${
|
|
89
|
-
font-size: ${
|
|
90
|
-
font-weight: ${
|
|
91
|
-
letter-spacing: ${
|
|
92
|
-
line-height: ${
|
|
93
|
-
text-transform: ${
|
|
88
|
+
font-family: ${Bt};
|
|
89
|
+
font-size: ${Wt};
|
|
90
|
+
font-weight: ${Gt};
|
|
91
|
+
letter-spacing: ${Rt};
|
|
92
|
+
line-height: ${Dt};
|
|
93
|
+
text-transform: ${Ft};
|
|
94
94
|
}
|
|
95
|
-
`,
|
|
95
|
+
`,ri=e.css`
|
|
96
96
|
.ft-typography--button {
|
|
97
|
-
font-family: ${
|
|
98
|
-
font-size: ${
|
|
99
|
-
font-weight: ${
|
|
100
|
-
letter-spacing: ${
|
|
101
|
-
line-height: ${
|
|
102
|
-
text-transform: ${
|
|
97
|
+
font-family: ${Ht};
|
|
98
|
+
font-size: ${Kt};
|
|
99
|
+
font-weight: ${Lt};
|
|
100
|
+
letter-spacing: ${qt};
|
|
101
|
+
line-height: ${Jt};
|
|
102
|
+
text-transform: ${Pt};
|
|
103
103
|
}
|
|
104
|
-
`;class
|
|
105
|
-
<${
|
|
104
|
+
`;class li extends i.FtLitElement{constructor(){super(...arguments),this.variant=H.body1}render(){return this.element?F`
|
|
105
|
+
<${R(this.element)}
|
|
106
106
|
class="ft-typography ft-typography--${this.variant}">
|
|
107
107
|
<slot></slot>
|
|
108
|
-
</${
|
|
109
|
-
`:
|
|
108
|
+
</${R(this.element)}>
|
|
109
|
+
`:F`
|
|
110
110
|
<slot class="ft-typography ft-typography--${this.variant}"></slot>
|
|
111
|
-
`}}
|
|
111
|
+
`}}li.styles=[Qt,Vt,Xt,Yt,ti,ii,ei,oi,ni,ri,e.css`
|
|
112
112
|
.ft-typography {
|
|
113
113
|
vertical-align: inherit;
|
|
114
114
|
}
|
|
115
|
-
`],
|
|
115
|
+
`],K([o.property()],li.prototype,"element",void 0),K([o.property()],li.prototype,"variant",void 0),i.customElement("ft-typography")(li);var si=function(t,i,e,o){for(var n,r=arguments.length,l=r<3?i:null===o?o=Object.getOwnPropertyDescriptor(i,e):o,s=t.length-1;s>=0;s--)(n=t[s])&&(l=(r<3?n(l):r>3?n(i,e,l):n(i,e))||l);return r>3&&l&&Object.defineProperty(i,e,l),l};const ai={fontSize:i.FtCssVariable.create("--ft-input-label-font-size","SIZE","14px"),raisedFontSize:i.FtCssVariable.create("--ft-input-label-raised-font-size","SIZE","11px"),raisedZIndex:i.FtCssVariable.create("--ft-input-label-outlined-raised-z-index","NUMBER","2"),verticalSpacing:i.FtCssVariable.create("--ft-input-label-vertical-spacing","SIZE","4px"),horizontalSpacing:i.FtCssVariable.create("--ft-input-label-horizontal-spacing","SIZE","12px"),borderColor:i.FtCssVariable.extend("--ft-input-label-border-color",i.designSystemVariables.colorOutline),textColor:i.FtCssVariable.extend("--ft-input-label-text-color",i.designSystemVariables.colorOnSurfaceMedium),disabledTextColor:i.FtCssVariable.extend("--ft-input-label-disabled-text-color",i.designSystemVariables.colorOnSurfaceDisabled),colorSurface:i.FtCssVariable.external(i.designSystemVariables.colorSurface,"Design system"),borderRadiusS:i.FtCssVariable.external(i.designSystemVariables.borderRadiusS,"Design system"),colorError:i.FtCssVariable.external(i.designSystemVariables.colorError,"Design system")};class pi extends i.FtLitElement{constructor(){super(...arguments),this.text="",this.raised=!1,this.outlined=!1,this.disabled=!1,this.error=!1}render(){const t={"ft-input-label":!0,"ft-input-label--raised":this.raised,"ft-input-label--outlined":this.outlined,"ft-input-label--disabled":this.disabled,"ft-input-label--in-error":this.error};return e.html`
|
|
116
116
|
<div class="${n.classMap(t)}">
|
|
117
117
|
${this.text?e.html`
|
|
118
118
|
<div class="ft-input-label--text ft-typography--caption">
|
|
@@ -121,7 +121,7 @@ const B=t=>({_$litStatic$:t}),G=new Map,R=(t=>(i,...e)=>{var o;const n=e.length;
|
|
|
121
121
|
</div>
|
|
122
122
|
`:null}
|
|
123
123
|
</div>
|
|
124
|
-
`}}
|
|
124
|
+
`}}pi.elementDefinitions={},pi.styles=[ei,e.css`
|
|
125
125
|
.ft-input-label {
|
|
126
126
|
position: absolute;
|
|
127
127
|
inset: 0;
|
|
@@ -129,7 +129,11 @@ const B=t=>({_$litStatic$:t}),G=new Map,R=(t=>(i,...e)=>{var o;const n=e.length;
|
|
|
129
129
|
}
|
|
130
130
|
|
|
131
131
|
.ft-input-label {
|
|
132
|
-
border-color: ${
|
|
132
|
+
border-color: ${ai.borderColor};
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
.ft-input-label.ft-input-label--in-error {
|
|
136
|
+
border-color: ${ai.colorError}
|
|
133
137
|
}
|
|
134
138
|
|
|
135
139
|
.ft-input-label:before,
|
|
@@ -142,7 +146,7 @@ const B=t=>({_$litStatic$:t}),G=new Map,R=(t=>(i,...e)=>{var o;const n=e.length;
|
|
|
142
146
|
}
|
|
143
147
|
|
|
144
148
|
.ft-input-label:before {
|
|
145
|
-
width: ${
|
|
149
|
+
width: ${ai.horizontalSpacing};
|
|
146
150
|
flex-shrink: 0;
|
|
147
151
|
}
|
|
148
152
|
|
|
@@ -158,14 +162,18 @@ const B=t=>({_$litStatic$:t}),G=new Map,R=(t=>(i,...e)=>{var o;const n=e.length;
|
|
|
158
162
|
border-bottom-width: 1px;
|
|
159
163
|
border-bottom-style: solid;
|
|
160
164
|
border-color: inherit;
|
|
161
|
-
color: ${
|
|
165
|
+
color: ${ai.textColor};
|
|
162
166
|
transition: font-size 250ms, line-height 250ms, color 250ms;
|
|
163
|
-
${i.setVariable(
|
|
164
|
-
${i.setVariable(
|
|
167
|
+
${i.setVariable(Zt.fontSize,ai.fontSize)};
|
|
168
|
+
${i.setVariable(Zt.lineHeight,ai.fontSize)};
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
.ft-input-label--in-error .ft-input-label--text {
|
|
172
|
+
color: ${ai.colorError}
|
|
165
173
|
}
|
|
166
174
|
|
|
167
175
|
.ft-input-label--disabled .ft-input-label--text {
|
|
168
|
-
color: ${
|
|
176
|
+
color: ${ai.disabledTextColor};
|
|
169
177
|
}
|
|
170
178
|
|
|
171
179
|
.ft-input-label--hidden-text {
|
|
@@ -181,17 +189,17 @@ const B=t=>({_$litStatic$:t}),G=new Map,R=(t=>(i,...e)=>{var o;const n=e.length;
|
|
|
181
189
|
overflow: hidden;
|
|
182
190
|
white-space: nowrap;
|
|
183
191
|
text-overflow: ellipsis;
|
|
184
|
-
padding: ${
|
|
185
|
-
margin: calc(${
|
|
192
|
+
padding: ${ai.verticalSpacing} 4px;
|
|
193
|
+
margin: calc(${ai.verticalSpacing} * -1) 0;
|
|
186
194
|
}
|
|
187
195
|
|
|
188
196
|
.ft-input-label--raised .ft-input-label--text {
|
|
189
|
-
${i.setVariable(
|
|
190
|
-
${i.setVariable(
|
|
197
|
+
${i.setVariable(Zt.fontSize,ai.raisedFontSize)};
|
|
198
|
+
${i.setVariable(Zt.lineHeight,ai.raisedFontSize)};
|
|
191
199
|
}
|
|
192
200
|
|
|
193
201
|
.ft-input-label--raised .ft-input-label--floating-text {
|
|
194
|
-
top: ${
|
|
202
|
+
top: ${ai.verticalSpacing};
|
|
195
203
|
}
|
|
196
204
|
|
|
197
205
|
.ft-input-label--outlined .ft-input-label--text,
|
|
@@ -204,24 +212,24 @@ const B=t=>({_$litStatic$:t}),G=new Map,R=(t=>(i,...e)=>{var o;const n=e.length;
|
|
|
204
212
|
.ft-input-label--outlined:before {
|
|
205
213
|
border-left-width: 1px;
|
|
206
214
|
border-left-style: solid;
|
|
207
|
-
border-radius: ${
|
|
215
|
+
border-radius: ${ai.borderRadiusS} 0 0 ${ai.borderRadiusS};
|
|
208
216
|
}
|
|
209
217
|
|
|
210
218
|
.ft-input-label--outlined:after {
|
|
211
219
|
border-right-width: 1px;
|
|
212
220
|
border-right-style: solid;
|
|
213
|
-
border-radius: 0 ${
|
|
221
|
+
border-radius: 0 ${ai.borderRadiusS} ${ai.borderRadiusS} 0;
|
|
214
222
|
}
|
|
215
223
|
|
|
216
224
|
.ft-input-label--outlined.ft-input-label--raised .ft-input-label--floating-text {
|
|
217
225
|
padding: 2px 4px;
|
|
218
|
-
z-index: ${
|
|
219
|
-
background-color: ${
|
|
220
|
-
border-radius: ${
|
|
226
|
+
z-index: ${ai.raisedZIndex};
|
|
227
|
+
background-color: ${ai.colorSurface};
|
|
228
|
+
border-radius: ${ai.borderRadiusS};
|
|
221
229
|
top: calc((var(--ft-typography-caption-line-height) / -2) + 2px);
|
|
222
230
|
}
|
|
223
231
|
|
|
224
232
|
.ft-input-label--outlined.ft-input-label--raised .ft-input-label--text {
|
|
225
233
|
border-top: none;
|
|
226
234
|
}
|
|
227
|
-
`],
|
|
235
|
+
`],si([o.property({type:String})],pi.prototype,"text",void 0),si([o.property({type:Boolean})],pi.prototype,"raised",void 0),si([o.property({type:Boolean})],pi.prototype,"outlined",void 0),si([o.property({type:Boolean})],pi.prototype,"disabled",void 0),si([o.property({type:Boolean})],pi.prototype,"error",void 0),i.customElement("ft-input-label")(pi),t.FtInputLabel=pi,t.FtInputLabelCssVariables=ai,Object.defineProperty(t,"t",{value:!0})}({},ftGlobals.wcUtils,ftGlobals.lit,ftGlobals.litDecorators,ftGlobals.litClassMap);
|