@fluid-topics/ft-text-field 0.3.71 → 1.0.0-alpha.1
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-text-field-suggestion.css.d.ts +0 -1
- package/build/ft-text-field-suggestion.css.js +0 -1
- package/build/ft-text-field-suggestion.d.ts +0 -1
- package/build/ft-text-field-suggestion.js +2 -2
- package/build/ft-text-field-suggestion.properties.d.ts +0 -1
- package/build/ft-text-field-suggestion.properties.js +0 -1
- package/build/ft-text-field.css.d.ts +0 -1
- package/build/ft-text-field.css.js +0 -1
- package/build/ft-text-field.d.ts +0 -1
- package/build/ft-text-field.js +2 -2
- package/build/ft-text-field.light.js +167 -167
- package/build/ft-text-field.min.js +175 -185
- package/build/ft-text-field.properties.d.ts +0 -1
- package/build/ft-text-field.properties.js +0 -1
- package/build/index.d.ts +0 -1
- package/build/index.js +0 -1
- package/package.json +8 -8
|
@@ -4,138 +4,138 @@
|
|
|
4
4
|
* Copyright 2017 Google LLC
|
|
5
5
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
6
6
|
*/
|
|
7
|
-
var n;const r=window,a=r.trustedTypes,f=a?a.createPolicy("lit-html",{createHTML:t=>t}):void 0,p=`lit$${(Math.random()+"").slice(9)}$`,
|
|
7
|
+
var n;const r=window,a=r.trustedTypes,f=a?a.createPolicy("lit-html",{createHTML:t=>t}):void 0,p="$lit$",h=`lit$${(Math.random()+"").slice(9)}$`,d="?"+h,c=`<${d}>`,u=document,x=()=>u.createComment(""),g=t=>null===t||"object"!=typeof t&&"function"!=typeof t,y=Array.isArray,v="[ \t\n\f\r]",b=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,m=/-->/g,$=/>/g,w=RegExp(`>|${v}(?:([^\\s"'>=/]+)(${v}*=${v}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),k=/'/g,z=/"/g,S=/^(?:script|style|textarea|title)$/i,E=(t=>(e,...i)=>({_$litType$:t,strings:e,values:i}))(1),N=Symbol.for("lit-noChange"),j=Symbol.for("lit-nothing"),O=new WeakMap,C=u.createTreeWalker(u,129,null,!1),I=(t,e)=>{const i=t.length-1,o=[];let s,l=2===e?"<svg>":"",n=b;for(let e=0;e<i;e++){const i=t[e];let r,a,f=-1,d=0;for(;d<i.length&&(n.lastIndex=d,a=n.exec(i),null!==a);)d=n.lastIndex,n===b?"!--"===a[1]?n=m:void 0!==a[1]?n=$:void 0!==a[2]?(S.test(a[2])&&(s=RegExp("</"+a[2],"g")),n=w):void 0!==a[3]&&(n=w):n===w?">"===a[0]?(n=null!=s?s:b,f=-1):void 0===a[1]?f=-2:(f=n.lastIndex-a[2].length,r=a[1],n=void 0===a[3]?w:'"'===a[3]?z:k):n===z||n===k?n=w:n===m||n===$?n=b:(n=w,s=void 0);const u=n===w&&t[e+1].startsWith("/>")?" ":"";l+=n===b?i+c:f>=0?(o.push(r),i.slice(0,f)+p+i.slice(f)+h+u):i+h+(-2===f?(o.push(void 0),e):u)}const r=l+(t[i]||"<?>")+(2===e?"</svg>":"");if(!Array.isArray(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return[void 0!==f?f.createHTML(r):r,o]};class A{constructor({strings:t,_$litType$:e},i){let o;this.parts=[];let s=0,l=0;const n=t.length-1,r=this.parts,[f,c]=I(t,e);if(this.el=A.createElement(f,i),C.currentNode=this.el.content,2===e){const t=this.el.content,e=t.firstChild;e.remove(),t.append(...e.childNodes)}for(;null!==(o=C.nextNode())&&r.length<n;){if(1===o.nodeType){if(o.hasAttributes()){const t=[];for(const e of o.getAttributeNames())if(e.endsWith(p)||e.startsWith(h)){const i=c[l++];if(t.push(e),void 0!==i){const t=o.getAttribute(i.toLowerCase()+p).split(h),e=/([.?@])?(.*)/.exec(i);r.push({type:1,index:s,name:e[2],strings:t,ctor:"."===e[1]?U:"?"===e[1]?T:"@"===e[1]?R:_})}else r.push({type:6,index:s})}for(const e of t)o.removeAttribute(e)}if(S.test(o.tagName)){const t=o.textContent.split(h),e=t.length-1;if(e>0){o.textContent=a?a.emptyScript:"";for(let i=0;i<e;i++)o.append(t[i],x()),C.nextNode(),r.push({type:2,index:++s});o.append(t[e],x())}}}else if(8===o.nodeType)if(o.data===d)r.push({type:2,index:s});else{let t=-1;for(;-1!==(t=o.data.indexOf(h,t+1));)r.push({type:7,index:s}),t+=h.length-1}s++}}static createElement(t,e){const i=u.createElement("template");return i.innerHTML=t,i}}function D(t,e,i=t,o){var s,l,n,r;if(e===N)return e;let a=void 0!==o?null===(s=i._$Co)||void 0===s?void 0:s[o]:i._$Cl;const f=g(e)?void 0:e._$litDirective$;return(null==a?void 0:a.constructor)!==f&&(null===(l=null==a?void 0:a._$AO)||void 0===l||l.call(a,!1),void 0===f?a=void 0:(a=new f(t),a._$AT(t,i,o)),void 0!==o?(null!==(n=(r=i)._$Co)&&void 0!==n?n:r._$Co=[])[o]=a:i._$Cl=a),void 0!==a&&(e=D(t,a._$AS(t,e.values),a,o)),e}class B{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){var e;const{el:{content:i},parts:o}=this._$AD,s=(null!==(e=null==t?void 0:t.creationScope)&&void 0!==e?e:u).importNode(i,!0);C.currentNode=s;let l=C.nextNode(),n=0,r=0,a=o[0];for(;void 0!==a;){if(n===a.index){let e;2===a.type?e=new Z(l,l.nextSibling,this,t):1===a.type?e=new a.ctor(l,a.name,a.strings,this,t):6===a.type&&(e=new W(l,this,t)),this._$AV.push(e),a=o[++r]}n!==(null==a?void 0:a.index)&&(l=C.nextNode(),n++)}return s}v(t){let e=0;for(const i of this._$AV)void 0!==i&&(void 0!==i.strings?(i._$AI(t,i,e),e+=i.strings.length-2):i._$AI(t[e])),e++}}class Z{constructor(t,e,i,o){var s;this.type=2,this._$AH=j,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=i,this.options=o,this._$Cp=null===(s=null==o?void 0:o.isConnected)||void 0===s||s}get _$AU(){var t,e;return null!==(e=null===(t=this._$AM)||void 0===t?void 0:t._$AU)&&void 0!==e?e:this._$Cp}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===(null==t?void 0:t.nodeType)&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=D(this,t,e),g(t)?t===j||null==t||""===t?(this._$AH!==j&&this._$AR(),this._$AH=j):t!==this._$AH&&t!==N&&this._(t):void 0!==t._$litType$?this.g(t):void 0!==t.nodeType?this.$(t):(t=>y(t)||"function"==typeof(null==t?void 0:t[Symbol.iterator]))(t)?this.T(t):this._(t)}k(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}$(t){this._$AH!==t&&(this._$AR(),this._$AH=this.k(t))}_(t){this._$AH!==j&&g(this._$AH)?this._$AA.nextSibling.data=t:this.$(u.createTextNode(t)),this._$AH=t}g(t){var e;const{values:i,_$litType$:o}=t,s="number"==typeof o?this._$AC(t):(void 0===o.el&&(o.el=A.createElement(o.h,this.options)),o);if((null===(e=this._$AH)||void 0===e?void 0:e._$AD)===s)this._$AH.v(i);else{const t=new B(s,this),e=t.u(this.options);t.v(i),this.$(e),this._$AH=t}}_$AC(t){let e=O.get(t.strings);return void 0===e&&O.set(t.strings,e=new A(t)),e}T(t){y(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let i,o=0;for(const s of t)o===e.length?e.push(i=new Z(this.k(x()),this.k(x()),this,this.options)):i=e[o],i._$AI(s),o++;o<e.length&&(this._$AR(i&&i._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){var i;for(null===(i=this._$AP)||void 0===i||i.call(this,!1,!0,e);t&&t!==this._$AB;){const e=t.nextSibling;t.remove(),t=e}}setConnected(t){var e;void 0===this._$AM&&(this._$Cp=t,null===(e=this._$AP)||void 0===e||e.call(this,t))}}class _{constructor(t,e,i,o,s){this.type=1,this._$AH=j,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=s,i.length>2||""!==i[0]||""!==i[1]?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=j}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(t,e=this,i,o){const s=this.strings;let l=!1;if(void 0===s)t=D(this,t,e,0),l=!g(t)||t!==this._$AH&&t!==N,l&&(this._$AH=t);else{const o=t;let n,r;for(t=s[0],n=0;n<s.length-1;n++)r=D(this,o[i+n],e,n),r===N&&(r=this._$AH[n]),l||(l=!g(r)||r!==this._$AH[n]),r===j?t=j:t!==j&&(t+=(null!=r?r:"")+s[n+1]),this._$AH[n]=r}l&&!o&&this.j(t)}j(t){t===j?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,null!=t?t:"")}}class U extends _{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===j?void 0:t}}const M=a?a.emptyScript:"";class T extends _{constructor(){super(...arguments),this.type=4}j(t){t&&t!==j?this.element.setAttribute(this.name,M):this.element.removeAttribute(this.name)}}class R extends _{constructor(t,e,i,o,s){super(t,e,i,o,s),this.type=5}_$AI(t,e=this){var i;if((t=null!==(i=D(this,t,e,0))&&void 0!==i?i:j)===N)return;const o=this._$AH,s=t===j&&o!==j||t.capture!==o.capture||t.once!==o.once||t.passive!==o.passive,l=t!==j&&(o===j||s);s&&this.element.removeEventListener(this.name,this,o),l&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e,i;"function"==typeof this._$AH?this._$AH.call(null!==(i=null===(e=this.options)||void 0===e?void 0:e.host)&&void 0!==i?i:this.element,t):this._$AH.handleEvent(t)}}class W{constructor(t,e,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){D(this,t)}}const K=r.litHtmlPolyfillSupport;null==K||K(A,Z),(null!==(n=r.litHtmlVersions)&&void 0!==n?n:r.litHtmlVersions=[]).push("2.7.3");
|
|
8
8
|
/**
|
|
9
9
|
* @license
|
|
10
10
|
* Copyright 2018 Google LLC
|
|
11
11
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
12
12
|
*/
|
|
13
|
-
const
|
|
13
|
+
const F=Symbol.for(""),V=t=>{if((null==t?void 0:t.r)===F)return null==t?void 0:t._$litStatic$},G=t=>({_$litStatic$:t,r:F}),H=new Map,P=(t=>(e,...i)=>{const o=i.length;let s,l;const n=[],r=[];let a,f=0,p=!1;for(;f<o;){for(a=e[f];f<o&&void 0!==(l=i[f],s=V(l));)a+=s+e[++f],p=!0;f!==o&&r.push(l),n.push(a),f++}if(f===o&&n.push(e[o]),p){const t=n.join("$$lit$$");void 0===(e=H.get(t))&&(n.raw=n,H.set(t,e=n)),i=r}return t(e,...i)})(E);
|
|
14
14
|
/**
|
|
15
15
|
* @license
|
|
16
16
|
* Copyright 2020 Google LLC
|
|
17
17
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
18
|
-
*/var
|
|
18
|
+
*/var q;!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"}(q||(q={}));const L=e.FtCssVariableFactory.extend("--ft-typography-font-family",e.designSystemVariables.titleFont),X=e.FtCssVariableFactory.extend("--ft-typography-font-family",e.designSystemVariables.contentFont),Y={fontFamily:X,fontSize:e.FtCssVariableFactory.create("--ft-typography-font-size","SIZE","16px"),fontWeight:e.FtCssVariableFactory.create("--ft-typography-font-weight","UNKNOWN","normal"),letterSpacing:e.FtCssVariableFactory.create("--ft-typography-letter-spacing","SIZE","0.496px"),lineHeight:e.FtCssVariableFactory.create("--ft-typography-line-height","NUMBER","1.5"),textTransform:e.FtCssVariableFactory.create("--ft-typography-text-transform","UNKNOWN","inherit")},J=e.FtCssVariableFactory.extend("--ft-typography-title-font-family",L),Q=e.FtCssVariableFactory.extend("--ft-typography-title-font-size",Y.fontSize,"20px"),tt=e.FtCssVariableFactory.extend("--ft-typography-title-font-weight",Y.fontWeight,"normal"),et=e.FtCssVariableFactory.extend("--ft-typography-title-letter-spacing",Y.letterSpacing,"0.15px"),it=e.FtCssVariableFactory.extend("--ft-typography-title-line-height",Y.lineHeight,"1.2"),ot=e.FtCssVariableFactory.extend("--ft-typography-title-text-transform",Y.textTransform,"inherit"),st=e.FtCssVariableFactory.extend("--ft-typography-title-dense-font-family",L),lt=e.FtCssVariableFactory.extend("--ft-typography-title-dense-font-size",Y.fontSize,"14px"),nt=e.FtCssVariableFactory.extend("--ft-typography-title-dense-font-weight",Y.fontWeight,"normal"),rt=e.FtCssVariableFactory.extend("--ft-typography-title-dense-letter-spacing",Y.letterSpacing,"0.105px"),at=e.FtCssVariableFactory.extend("--ft-typography-title-dense-line-height",Y.lineHeight,"1.7"),ft=e.FtCssVariableFactory.extend("--ft-typography-title-dense-text-transform",Y.textTransform,"inherit"),pt=e.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-family",X),ht=e.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-size",Y.fontSize,"16px"),dt=e.FtCssVariableFactory.extend("--ft-typography-subtitle1-font-weight",Y.fontWeight,"600"),ct=e.FtCssVariableFactory.extend("--ft-typography-subtitle1-letter-spacing",Y.letterSpacing,"0.144px"),ut=e.FtCssVariableFactory.extend("--ft-typography-subtitle1-line-height",Y.lineHeight,"1.5"),xt=e.FtCssVariableFactory.extend("--ft-typography-subtitle1-text-transform",Y.textTransform,"inherit"),gt=e.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-family",X),yt=e.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-size",Y.fontSize,"14px"),vt=e.FtCssVariableFactory.extend("--ft-typography-subtitle2-font-weight",Y.fontWeight,"normal"),bt=e.FtCssVariableFactory.extend("--ft-typography-subtitle2-letter-spacing",Y.letterSpacing,"0.098px"),mt=e.FtCssVariableFactory.extend("--ft-typography-subtitle2-line-height",Y.lineHeight,"1.7"),$t=e.FtCssVariableFactory.extend("--ft-typography-subtitle2-text-transform",Y.textTransform,"inherit"),wt={fontFamily:e.FtCssVariableFactory.extend("--ft-typography-body1-font-family",X),fontSize:e.FtCssVariableFactory.extend("--ft-typography-body1-font-size",Y.fontSize,"16px"),fontWeight:e.FtCssVariableFactory.extend("--ft-typography-body1-font-weight",Y.fontWeight,"normal"),letterSpacing:e.FtCssVariableFactory.extend("--ft-typography-body1-letter-spacing",Y.letterSpacing,"0.496px"),lineHeight:e.FtCssVariableFactory.extend("--ft-typography-body1-line-height",Y.lineHeight,"1.5"),textTransform:e.FtCssVariableFactory.extend("--ft-typography-body1-text-transform",Y.textTransform,"inherit")},kt=e.FtCssVariableFactory.extend("--ft-typography-body2-font-family",X),zt=e.FtCssVariableFactory.extend("--ft-typography-body2-font-size",Y.fontSize,"14px"),St=e.FtCssVariableFactory.extend("--ft-typography-body2-font-weight",Y.fontWeight,"normal"),Et=e.FtCssVariableFactory.extend("--ft-typography-body2-letter-spacing",Y.letterSpacing,"0.252px"),Nt=e.FtCssVariableFactory.extend("--ft-typography-body2-line-height",Y.lineHeight,"1.4"),jt=e.FtCssVariableFactory.extend("--ft-typography-body2-text-transform",Y.textTransform,"inherit"),Ot={fontFamily:e.FtCssVariableFactory.extend("--ft-typography-caption-font-family",X),fontSize:e.FtCssVariableFactory.extend("--ft-typography-caption-font-size",Y.fontSize,"12px"),fontWeight:e.FtCssVariableFactory.extend("--ft-typography-caption-font-weight",Y.fontWeight,"normal"),letterSpacing:e.FtCssVariableFactory.extend("--ft-typography-caption-letter-spacing",Y.letterSpacing,"0.396px"),lineHeight:e.FtCssVariableFactory.extend("--ft-typography-caption-line-height",Y.lineHeight,"1.33"),textTransform:e.FtCssVariableFactory.extend("--ft-typography-caption-text-transform",Y.textTransform,"inherit")},Ct=e.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-family",X),It=e.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-size",Y.fontSize,"10px"),At=e.FtCssVariableFactory.extend("--ft-typography-breadcrumb-font-weight",Y.fontWeight,"normal"),Dt=e.FtCssVariableFactory.extend("--ft-typography-breadcrumb-letter-spacing",Y.letterSpacing,"0.33px"),Bt=e.FtCssVariableFactory.extend("--ft-typography-breadcrumb-line-height",Y.lineHeight,"1.6"),Zt=e.FtCssVariableFactory.extend("--ft-typography-breadcrumb-text-transform",Y.textTransform,"inherit"),_t=e.FtCssVariableFactory.extend("--ft-typography-overline-font-family",X),Ut=e.FtCssVariableFactory.extend("--ft-typography-overline-font-size",Y.fontSize,"10px"),Mt=e.FtCssVariableFactory.extend("--ft-typography-overline-font-weight",Y.fontWeight,"normal"),Tt=e.FtCssVariableFactory.extend("--ft-typography-overline-letter-spacing",Y.letterSpacing,"1.5px"),Rt=e.FtCssVariableFactory.extend("--ft-typography-overline-line-height",Y.lineHeight,"1.6"),Wt=e.FtCssVariableFactory.extend("--ft-typography-overline-text-transform",Y.textTransform,"uppercase"),Kt=e.FtCssVariableFactory.extend("--ft-typography-button-font-family",X),Ft=e.FtCssVariableFactory.extend("--ft-typography-button-font-size",Y.fontSize,"14px"),Vt=e.FtCssVariableFactory.extend("--ft-typography-button-font-weight",Y.fontWeight,"600"),Gt=e.FtCssVariableFactory.extend("--ft-typography-button-letter-spacing",Y.letterSpacing,"1.246px"),Ht=e.FtCssVariableFactory.extend("--ft-typography-button-line-height",Y.lineHeight,"1.15"),Pt=e.FtCssVariableFactory.extend("--ft-typography-button-text-transform",Y.textTransform,"uppercase"),qt=i.css`
|
|
19
19
|
.ft-typography--title {
|
|
20
|
-
font-family: ${
|
|
21
|
-
font-size: ${
|
|
22
|
-
font-weight: ${
|
|
23
|
-
letter-spacing: ${
|
|
24
|
-
line-height: ${
|
|
25
|
-
text-transform: ${
|
|
26
|
-
}
|
|
27
|
-
`,Pt=i.css`
|
|
28
|
-
.ft-typography--title-dense {
|
|
29
|
-
font-family: ${it};
|
|
30
|
-
font-size: ${ot};
|
|
31
|
-
font-weight: ${st};
|
|
32
|
-
letter-spacing: ${lt};
|
|
33
|
-
line-height: ${nt};
|
|
34
|
-
text-transform: ${rt};
|
|
35
|
-
}
|
|
36
|
-
`,qt=i.css`
|
|
37
|
-
.ft-typography--subtitle1 {
|
|
38
|
-
font-family: ${at};
|
|
39
|
-
font-size: ${ft};
|
|
40
|
-
font-weight: ${pt};
|
|
41
|
-
letter-spacing: ${ht};
|
|
42
|
-
line-height: ${dt};
|
|
43
|
-
text-transform: ${ct};
|
|
20
|
+
font-family: ${J};
|
|
21
|
+
font-size: ${Q};
|
|
22
|
+
font-weight: ${tt};
|
|
23
|
+
letter-spacing: ${et};
|
|
24
|
+
line-height: ${it};
|
|
25
|
+
text-transform: ${ot};
|
|
44
26
|
}
|
|
45
27
|
`,Lt=i.css`
|
|
46
|
-
.ft-typography--
|
|
47
|
-
font-family: ${
|
|
48
|
-
font-size: ${
|
|
49
|
-
font-weight: ${
|
|
50
|
-
letter-spacing: ${
|
|
51
|
-
line-height: ${
|
|
52
|
-
text-transform: ${
|
|
28
|
+
.ft-typography--title-dense {
|
|
29
|
+
font-family: ${st};
|
|
30
|
+
font-size: ${lt};
|
|
31
|
+
font-weight: ${nt};
|
|
32
|
+
letter-spacing: ${rt};
|
|
33
|
+
line-height: ${at};
|
|
34
|
+
text-transform: ${ft};
|
|
53
35
|
}
|
|
54
|
-
|
|
55
36
|
`,Xt=i.css`
|
|
56
|
-
.ft-typography--
|
|
57
|
-
font-family: ${
|
|
58
|
-
font-size: ${
|
|
59
|
-
font-weight: ${
|
|
60
|
-
letter-spacing: ${
|
|
61
|
-
line-height: ${
|
|
62
|
-
text-transform: ${
|
|
37
|
+
.ft-typography--subtitle1 {
|
|
38
|
+
font-family: ${pt};
|
|
39
|
+
font-size: ${ht};
|
|
40
|
+
font-weight: ${dt};
|
|
41
|
+
letter-spacing: ${ct};
|
|
42
|
+
line-height: ${ut};
|
|
43
|
+
text-transform: ${xt};
|
|
63
44
|
}
|
|
64
45
|
`,Yt=i.css`
|
|
65
|
-
.ft-typography--
|
|
66
|
-
font-family: ${
|
|
67
|
-
font-size: ${
|
|
68
|
-
font-weight: ${
|
|
69
|
-
letter-spacing: ${
|
|
70
|
-
line-height: ${
|
|
71
|
-
text-transform: ${
|
|
46
|
+
.ft-typography--subtitle2 {
|
|
47
|
+
font-family: ${gt};
|
|
48
|
+
font-size: ${yt};
|
|
49
|
+
font-weight: ${vt};
|
|
50
|
+
letter-spacing: ${bt};
|
|
51
|
+
line-height: ${mt};
|
|
52
|
+
text-transform: ${$t};
|
|
72
53
|
}
|
|
54
|
+
|
|
73
55
|
`,Jt=i.css`
|
|
74
|
-
.ft-typography--
|
|
75
|
-
font-family: ${
|
|
76
|
-
font-size: ${
|
|
77
|
-
font-weight: ${
|
|
78
|
-
letter-spacing: ${
|
|
79
|
-
line-height: ${
|
|
80
|
-
text-transform: ${
|
|
56
|
+
.ft-typography--body1 {
|
|
57
|
+
font-family: ${wt.fontFamily};
|
|
58
|
+
font-size: ${wt.fontSize};
|
|
59
|
+
font-weight: ${wt.fontWeight};
|
|
60
|
+
letter-spacing: ${wt.letterSpacing};
|
|
61
|
+
line-height: ${wt.lineHeight};
|
|
62
|
+
text-transform: ${wt.textTransform};
|
|
81
63
|
}
|
|
82
64
|
`,Qt=i.css`
|
|
83
|
-
.ft-typography--
|
|
84
|
-
font-family: ${
|
|
85
|
-
font-size: ${
|
|
86
|
-
font-weight: ${
|
|
87
|
-
letter-spacing: ${
|
|
88
|
-
line-height: ${
|
|
89
|
-
text-transform: ${
|
|
65
|
+
.ft-typography--body2 {
|
|
66
|
+
font-family: ${kt};
|
|
67
|
+
font-size: ${zt};
|
|
68
|
+
font-weight: ${St};
|
|
69
|
+
letter-spacing: ${Et};
|
|
70
|
+
line-height: ${Nt};
|
|
71
|
+
text-transform: ${jt};
|
|
90
72
|
}
|
|
91
73
|
`,te=i.css`
|
|
92
|
-
.ft-typography--
|
|
93
|
-
font-family: ${
|
|
94
|
-
font-size: ${
|
|
95
|
-
font-weight: ${
|
|
96
|
-
letter-spacing: ${
|
|
97
|
-
line-height: ${
|
|
98
|
-
text-transform: ${
|
|
74
|
+
.ft-typography--caption {
|
|
75
|
+
font-family: ${Ot.fontFamily};
|
|
76
|
+
font-size: ${Ot.fontSize};
|
|
77
|
+
font-weight: ${Ot.fontWeight};
|
|
78
|
+
letter-spacing: ${Ot.letterSpacing};
|
|
79
|
+
line-height: ${Ot.lineHeight};
|
|
80
|
+
text-transform: ${Ot.textTransform};
|
|
99
81
|
}
|
|
100
82
|
`,ee=i.css`
|
|
101
|
-
.ft-typography--
|
|
102
|
-
font-family: ${
|
|
103
|
-
font-size: ${
|
|
104
|
-
font-weight: ${
|
|
105
|
-
letter-spacing: ${
|
|
106
|
-
line-height: ${
|
|
107
|
-
text-transform: ${
|
|
83
|
+
.ft-typography--breadcrumb {
|
|
84
|
+
font-family: ${Ct};
|
|
85
|
+
font-size: ${It};
|
|
86
|
+
font-weight: ${At};
|
|
87
|
+
letter-spacing: ${Dt};
|
|
88
|
+
line-height: ${Bt};
|
|
89
|
+
text-transform: ${Zt};
|
|
108
90
|
}
|
|
109
91
|
`,ie=i.css`
|
|
92
|
+
.ft-typography--overline {
|
|
93
|
+
font-family: ${_t};
|
|
94
|
+
font-size: ${Ut};
|
|
95
|
+
font-weight: ${Mt};
|
|
96
|
+
letter-spacing: ${Tt};
|
|
97
|
+
line-height: ${Rt};
|
|
98
|
+
text-transform: ${Wt};
|
|
99
|
+
}
|
|
100
|
+
`,oe=i.css`
|
|
101
|
+
.ft-typography--button {
|
|
102
|
+
font-family: ${Kt};
|
|
103
|
+
font-size: ${Ft};
|
|
104
|
+
font-weight: ${Vt};
|
|
105
|
+
letter-spacing: ${Gt};
|
|
106
|
+
line-height: ${Ht};
|
|
107
|
+
text-transform: ${Pt};
|
|
108
|
+
}
|
|
109
|
+
`,se=i.css`
|
|
110
110
|
.ft-typography {
|
|
111
111
|
vertical-align: inherit;
|
|
112
112
|
}
|
|
113
|
-
`;var
|
|
114
|
-
<${
|
|
113
|
+
`;var le=function(t,e,i,o){for(var s,l=arguments.length,n=l<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,r=t.length-1;r>=0;r--)(s=t[r])&&(n=(l<3?s(n):l>3?s(e,i,n):s(e,i))||n);return l>3&&n&&Object.defineProperty(e,i,n),n};class ne extends e.FtLitElement{constructor(){super(...arguments),this.variant=q.body1}render(){return this.element?P`
|
|
114
|
+
<${G(this.element)}
|
|
115
115
|
class="ft-typography ft-typography--${this.variant}">
|
|
116
116
|
<slot></slot>
|
|
117
|
-
</${
|
|
118
|
-
`:
|
|
117
|
+
</${G(this.element)}>
|
|
118
|
+
`:P`
|
|
119
119
|
<slot class="ft-typography ft-typography--${this.variant}"></slot>
|
|
120
|
-
`}}
|
|
120
|
+
`}}ne.styles=[qt,Lt,Xt,Yt,Jt,Qt,te,ee,ie,oe,se],le([o.property()],ne.prototype,"element",void 0),le([o.property()],ne.prototype,"variant",void 0),e.customElement("ft-typography")(ne);const re={fontSize:e.FtCssVariableFactory.create("--ft-input-label-font-size","SIZE","14px"),raisedFontSize:e.FtCssVariableFactory.create("--ft-input-label-raised-font-size","SIZE","11px"),raisedZIndex:e.FtCssVariableFactory.create("--ft-input-label-outlined-raised-z-index","NUMBER","2"),verticalSpacing:e.FtCssVariableFactory.create("--ft-input-label-vertical-spacing","SIZE","4px"),horizontalSpacing:e.FtCssVariableFactory.create("--ft-input-label-horizontal-spacing","SIZE","12px"),labelMaxWidth:e.FtCssVariableFactory.create("--ft-input-label-max-width","SIZE","100%"),borderColor:e.FtCssVariableFactory.extend("--ft-input-label-border-color",e.designSystemVariables.colorOutline),textColor:e.FtCssVariableFactory.extend("--ft-input-label-text-color",e.designSystemVariables.colorOnSurfaceMedium),disabledTextColor:e.FtCssVariableFactory.extend("--ft-input-label-disabled-text-color",e.designSystemVariables.colorOnSurfaceDisabled),colorSurface:e.FtCssVariableFactory.external(e.designSystemVariables.colorSurface,"Design system"),borderRadiusS:e.FtCssVariableFactory.external(e.designSystemVariables.borderRadiusS,"Design system"),colorError:e.FtCssVariableFactory.external(e.designSystemVariables.colorError,"Design system")},ae=i.css`
|
|
121
121
|
.ft-input-label {
|
|
122
122
|
position: absolute;
|
|
123
123
|
inset: 0;
|
|
124
124
|
display: flex;
|
|
125
|
-
background-color: ${
|
|
126
|
-
border-radius: ${
|
|
125
|
+
background-color: ${re.colorSurface};
|
|
126
|
+
border-radius: ${re.borderRadiusS} ${re.borderRadiusS} 0 0;
|
|
127
127
|
}
|
|
128
128
|
|
|
129
129
|
.ft-input-label--outlined {
|
|
130
|
-
border-radius: ${
|
|
130
|
+
border-radius: ${re.borderRadiusS};
|
|
131
131
|
}
|
|
132
132
|
|
|
133
133
|
.ft-input-label {
|
|
134
|
-
border-color: ${
|
|
134
|
+
border-color: ${re.borderColor};
|
|
135
135
|
}
|
|
136
136
|
|
|
137
137
|
.ft-input-label.ft-input-label--in-error {
|
|
138
|
-
border-color: ${
|
|
138
|
+
border-color: ${re.colorError}
|
|
139
139
|
}
|
|
140
140
|
|
|
141
141
|
.ft-input-label:before,
|
|
@@ -148,7 +148,7 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
148
148
|
}
|
|
149
149
|
|
|
150
150
|
.ft-input-label:before {
|
|
151
|
-
width: calc(${
|
|
151
|
+
width: calc(${re.horizontalSpacing} - 4px);
|
|
152
152
|
flex-shrink: 0;
|
|
153
153
|
}
|
|
154
154
|
|
|
@@ -164,20 +164,20 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
164
164
|
border-bottom-width: 1px;
|
|
165
165
|
border-bottom-style: solid;
|
|
166
166
|
border-color: inherit;
|
|
167
|
-
color: ${
|
|
167
|
+
color: ${re.textColor};
|
|
168
168
|
transition: font-size 250ms, line-height 250ms, color 250ms;
|
|
169
|
-
max-width: calc(${
|
|
169
|
+
max-width: calc(${re.labelMaxWidth} - 2 * (${re.horizontalSpacing} - 4px)); /* -2px on spacing for label padding */
|
|
170
170
|
text-overflow: ellipsis;
|
|
171
|
-
${e.setVariable(
|
|
172
|
-
${e.setVariable(
|
|
171
|
+
${e.setVariable(Ot.fontSize,re.fontSize)};
|
|
172
|
+
${e.setVariable(Ot.lineHeight,re.fontSize)};
|
|
173
173
|
}
|
|
174
174
|
|
|
175
175
|
.ft-input-label--in-error .ft-input-label--text {
|
|
176
|
-
color: ${
|
|
176
|
+
color: ${re.colorError}
|
|
177
177
|
}
|
|
178
178
|
|
|
179
179
|
.ft-input-label--disabled .ft-input-label--text {
|
|
180
|
-
color: ${
|
|
180
|
+
color: ${re.disabledTextColor};
|
|
181
181
|
}
|
|
182
182
|
|
|
183
183
|
.ft-input-label--hidden-text {
|
|
@@ -194,19 +194,19 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
194
194
|
overflow: hidden;
|
|
195
195
|
white-space: nowrap;
|
|
196
196
|
text-overflow: ellipsis;
|
|
197
|
-
padding: ${
|
|
198
|
-
margin: calc(${
|
|
197
|
+
padding: ${re.verticalSpacing} 4px;
|
|
198
|
+
margin: calc(${re.verticalSpacing} * -1) 0;
|
|
199
199
|
max-width: 100%;
|
|
200
200
|
box-sizing: border-box;
|
|
201
201
|
}
|
|
202
202
|
|
|
203
203
|
.ft-input-label--raised .ft-input-label--text {
|
|
204
|
-
${e.setVariable(
|
|
205
|
-
${e.setVariable(
|
|
204
|
+
${e.setVariable(Ot.fontSize,re.raisedFontSize)};
|
|
205
|
+
${e.setVariable(Ot.lineHeight,re.raisedFontSize)};
|
|
206
206
|
}
|
|
207
207
|
|
|
208
208
|
.ft-input-label--raised .ft-input-label--floating-text {
|
|
209
|
-
top: ${
|
|
209
|
+
top: ${re.verticalSpacing};
|
|
210
210
|
}
|
|
211
211
|
|
|
212
212
|
.ft-input-label--outlined .ft-input-label--text,
|
|
@@ -219,27 +219,27 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
219
219
|
.ft-input-label--outlined:before {
|
|
220
220
|
border-left-width: 1px;
|
|
221
221
|
border-left-style: solid;
|
|
222
|
-
border-radius: ${
|
|
222
|
+
border-radius: ${re.borderRadiusS} 0 0 ${re.borderRadiusS};
|
|
223
223
|
}
|
|
224
224
|
|
|
225
225
|
.ft-input-label--outlined:after {
|
|
226
226
|
border-right-width: 1px;
|
|
227
227
|
border-right-style: solid;
|
|
228
|
-
border-radius: 0 ${
|
|
228
|
+
border-radius: 0 ${re.borderRadiusS} ${re.borderRadiusS} 0;
|
|
229
229
|
}
|
|
230
230
|
|
|
231
231
|
.ft-input-label--outlined.ft-input-label--raised .ft-input-label--floating-text {
|
|
232
232
|
padding: 2px 4px;
|
|
233
|
-
z-index: ${
|
|
234
|
-
background-color: ${
|
|
235
|
-
border-radius: ${
|
|
233
|
+
z-index: ${re.raisedZIndex};
|
|
234
|
+
background-color: ${re.colorSurface};
|
|
235
|
+
border-radius: ${re.borderRadiusS};
|
|
236
236
|
top: calc((var(--ft-typography-caption-line-height) / -2) + 2px);
|
|
237
237
|
}
|
|
238
238
|
|
|
239
239
|
.ft-input-label--outlined.ft-input-label--raised .ft-input-label--text {
|
|
240
240
|
border-top: none;
|
|
241
241
|
}
|
|
242
|
-
`;var
|
|
242
|
+
`;var fe=function(t,e,i,o){for(var s,l=arguments.length,n=l<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,r=t.length-1;r>=0;r--)(s=t[r])&&(n=(l<3?s(n):l>3?s(e,i,n):s(e,i))||n);return l>3&&n&&Object.defineProperty(e,i,n),n};class pe extends e.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 i.html`
|
|
243
243
|
<div class="${s.classMap(t)}">
|
|
244
244
|
${this.text?i.html`
|
|
245
245
|
<div class="ft-input-label--text ft-typography--caption">
|
|
@@ -248,7 +248,7 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
248
248
|
</div>
|
|
249
249
|
`:null}
|
|
250
250
|
</div>
|
|
251
|
-
`}}
|
|
251
|
+
`}}pe.elementDefinitions={},pe.styles=[te,ae],fe([o.property({type:String})],pe.prototype,"text",void 0),fe([o.property({type:Boolean})],pe.prototype,"raised",void 0),fe([o.property({type:Boolean})],pe.prototype,"outlined",void 0),fe([o.property({type:Boolean})],pe.prototype,"disabled",void 0),fe([o.property({type:Boolean})],pe.prototype,"error",void 0),e.customElement("ft-input-label")(pe);const he=e.FtCssVariableFactory.extend("--ft-ripple-color",e.designSystemVariables.colorContent),de={color:he,backgroundColor:e.FtCssVariableFactory.extend("--ft-ripple-background-color",he),opacityContentOnSurfacePressed:e.FtCssVariableFactory.external(e.designSystemVariables.opacityContentOnSurfacePressed,"Design system"),opacityContentOnSurfaceHover:e.FtCssVariableFactory.external(e.designSystemVariables.opacityContentOnSurfaceHover,"Design system"),opacityContentOnSurfaceFocused:e.FtCssVariableFactory.external(e.designSystemVariables.opacityContentOnSurfaceFocused,"Design system"),opacityContentOnSurfaceSelected:e.FtCssVariableFactory.external(e.designSystemVariables.opacityContentOnSurfaceSelected,"Design system")},ce=e.FtCssVariableFactory.extend("--ft-ripple-color",e.designSystemVariables.colorPrimary),ue=ce,xe=e.FtCssVariableFactory.extend("--ft-ripple-background-color",ce),ge=e.FtCssVariableFactory.extend("--ft-ripple-color",e.designSystemVariables.colorSecondary),ye=ge,ve=e.FtCssVariableFactory.extend("--ft-ripple-background-color",ge),be=i.css`
|
|
252
252
|
:host {
|
|
253
253
|
display: contents;
|
|
254
254
|
}
|
|
@@ -270,27 +270,27 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
270
270
|
}
|
|
271
271
|
|
|
272
272
|
.ft-ripple .ft-ripple--background {
|
|
273
|
-
background-color: ${
|
|
273
|
+
background-color: ${de.backgroundColor};
|
|
274
274
|
}
|
|
275
275
|
|
|
276
276
|
.ft-ripple .ft-ripple--effect {
|
|
277
|
-
background-color: ${
|
|
277
|
+
background-color: ${de.color};
|
|
278
278
|
}
|
|
279
279
|
|
|
280
280
|
.ft-ripple.ft-ripple--secondary .ft-ripple--background {
|
|
281
|
-
background-color: ${
|
|
281
|
+
background-color: ${ve};
|
|
282
282
|
}
|
|
283
283
|
|
|
284
284
|
.ft-ripple.ft-ripple--secondary .ft-ripple--effect {
|
|
285
|
-
background-color: ${
|
|
285
|
+
background-color: ${ye};
|
|
286
286
|
}
|
|
287
287
|
|
|
288
288
|
.ft-ripple.ft-ripple--primary .ft-ripple--background {
|
|
289
|
-
background-color: ${
|
|
289
|
+
background-color: ${xe};
|
|
290
290
|
}
|
|
291
291
|
|
|
292
292
|
.ft-ripple.ft-ripple--primary .ft-ripple--effect {
|
|
293
|
-
background-color: ${
|
|
293
|
+
background-color: ${ue};
|
|
294
294
|
}
|
|
295
295
|
|
|
296
296
|
.ft-ripple .ft-ripple--background {
|
|
@@ -322,22 +322,22 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
322
322
|
}
|
|
323
323
|
|
|
324
324
|
.ft-ripple.ft-ripple--hovered .ft-ripple--background {
|
|
325
|
-
opacity: ${
|
|
325
|
+
opacity: ${de.opacityContentOnSurfaceHover};
|
|
326
326
|
}
|
|
327
327
|
|
|
328
328
|
.ft-ripple.ft-ripple--selected .ft-ripple--background {
|
|
329
|
-
opacity: ${
|
|
329
|
+
opacity: ${de.opacityContentOnSurfaceSelected};
|
|
330
330
|
}
|
|
331
331
|
|
|
332
332
|
.ft-ripple.ft-ripple--focused .ft-ripple--background {
|
|
333
|
-
opacity: ${
|
|
333
|
+
opacity: ${de.opacityContentOnSurfaceFocused};
|
|
334
334
|
}
|
|
335
335
|
|
|
336
336
|
.ft-ripple.ft-ripple--pressed .ft-ripple--effect {
|
|
337
|
-
opacity: ${
|
|
337
|
+
opacity: ${de.opacityContentOnSurfacePressed};
|
|
338
338
|
transform: translate(-50%, -50%) scale(1);
|
|
339
339
|
}
|
|
340
|
-
`;var
|
|
340
|
+
`;var me,$e,we=function(t,e,i,o){for(var s,l=arguments.length,n=l<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,r=t.length-1;r>=0;r--)(s=t[r])&&(n=(l<3?s(n):l>3?s(e,i,n):s(e,i))||n);return l>3&&n&&Object.defineProperty(e,i,n),n};class ke extends e.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 e.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.setupDebouncer=new e.Debouncer(10),this.moveRipple=t=>{var e,i;let{x:o,y:s}=this.getCoordinates(t),l=null!==(i=null===(e=this.ripple)||void 0===e?void 0:e.getBoundingClientRect())&&void 0!==i?i:{x:0,y:0,width:0,height:0};this.originX=Math.round(null!=o?o-l.x:l.width/2),this.originY=Math.round(null!=s?s-l.y:l.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 i.html`
|
|
341
341
|
<style>
|
|
342
342
|
.ft-ripple .ft-ripple--effect,
|
|
343
343
|
.ft-ripple.ft-ripple--unbounded .ft-ripple--background {
|
|
@@ -354,7 +354,7 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
354
354
|
<div class="ft-ripple--background"></div>
|
|
355
355
|
<div class="ft-ripple--effect"></div>
|
|
356
356
|
</div>
|
|
357
|
-
`}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 e,i;super.updated(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(e=this.target)||void 0===e||e.removeAttribute("data-is-ft-ripple-target")):null===(i=this.target)||void 0===i||i.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(){super.connectedCallback(),this.setupDebouncer.run((()=>{var t;const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(e),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 e=(...t)=>e=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(e)},i=e("mouseup","contextmenu"),o=e("touchend","touchcancel"),s=t=>{["Enter"," "].includes(t.key)&&e("keyup")(t)};t.addEventListener("mouseover",this.startHover),t.addEventListener("mousemove",this.moveRipple),t.addEventListener("mouseleave",this.endHover),t.addEventListener("mousedown",i),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",i),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,this.target=void 0}}getCoordinates(t){const e=t,i=t;let o,s;return null!=e.x?({x:o,y:s}=e):null!=i.touches&&(o=i.touches[0].clientX,s=i.touches[0].clientY),{x:o,y:s}}isIgnored(t){if(this.disabled)return!0;if(null!=t)for(let e of t.composedPath()){if(e===this.target)break;if("hasAttribute"in e&&e.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.resizeObserver.disconnect(),this.endRipple()}}$e.elementDefinitions={},$e.styles=ye,me([o.property({type:Boolean})],$e.prototype,"primary",void 0),me([o.property({type:Boolean})],$e.prototype,"secondary",void 0),me([o.property({type:Boolean})],$e.prototype,"unbounded",void 0),me([o.property({type:Boolean})],$e.prototype,"activated",void 0),me([o.property({type:Boolean})],$e.prototype,"selected",void 0),me([o.property({type:Boolean})],$e.prototype,"disabled",void 0),me([o.state()],$e.prototype,"hovered",void 0),me([o.state()],$e.prototype,"focused",void 0),me([o.state()],$e.prototype,"pressed",void 0),me([o.state()],$e.prototype,"rippling",void 0),me([o.state()],$e.prototype,"rippleSize",void 0),me([o.state()],$e.prototype,"originX",void 0),me([o.state()],$e.prototype,"originY",void 0),me([o.query(".ft-ripple")],$e.prototype,"ripple",void 0),me([o.query(".ft-ripple--effect")],$e.prototype,"rippleEffect",void 0),e.customElement("ft-ripple")($e),function(t){t.THUMBS_DOWN="",t.THUMBS_DOWN_PLAIN="",t.THUMBS_UP="",t.THUMBS_UP_PLAIN="",t.STAR="",t.STAR_PLAIN="",t.DESKTOP="",t.TABLET_LANDSCAPE="",t.TABLET_PORTRAIT="",t.MOBILE_LANDSCAPE="",t.MOBILE_PORTRAIT="",t.ARROW_RIGHT_TO_LINE="",t.THIN_ARROW_UP="",t.CONTEXTUAL="",t.UNSTRUCTURED_DOC="",t.RESET="",t.THIN_ARROW_LEFT="",t.THIN_ARROW_RIGHT="",t.MY_COLLECTIONS="",t.OFFLINE_SETTINGS="",t.MY_LIBRARY="",t.RATE_PLAIN="",t.RATE="",t.FEEDBACK_PLAIN="",t.PAUSE="",t.PLAY="",t.RELATIVES_PLAIN="",t.RELATIVES="",t.SHORTCUT_MENU="",t.PRINT="",t.DEFAULT_ROLES="",t.ACCOUNT_SETTINGS="",t.ONLINE="",t.OFFLINE="",t.UPLOAD="",t.BOOK_PLAIN="",t.SYNC="",t.SHARED_PBK="",t.COLLECTIONS="",t.SEARCH_IN_PUBLICATION="",t.BOOKS="",t.LOCKER="",t.ARROW_DOWN="",t.ARROW_LEFT="",t.ARROW_RIGHT="",t.ARROW_UP="",t.SAVE="",t.MAILS_AND_NOTIFICATIONS="",t.DOT="",t.MINUS="",t.PLUS="",t.FILTERS="",t.STRIPE_ARROW_RIGHT="",t.STRIPE_ARROW_LEFT="",t.ATTACHMENTS="",t.ADD_BOOKMARK="",t.BOOKMARK="",t.EXPORT="",t.MENU="",t.TAG="",t.TAG_PLAIN="",t.COPY_TO_CLIPBOARD="",t.COLUMNS="",t.ARTICLE="",t.CLOSE_PLAIN="",t.CHECK_PLAIN="",t.LOGOUT="",t.SIGN_IN="",t.THIN_ARROW="",t.TRIANGLE_BOTTOM="",t.TRIANGLE_LEFT="",t.TRIANGLE_RIGHT="",t.TRIANGLE_TOP="",t.FACET_HAS_DESCENDANT="",t.MINUS_PLAIN="",t.PLUS_PLAIN="",t.INFO="",t.ICON_EXPAND="",t.ICON_COLLAPSE="",t.ADD_TO_PBK="",t.ALERT="",t.ADD_ALERT="",t.BACK_TO_SEARCH="",t.DOWNLOAD="",t.EDIT="",t.FEEDBACK="",t.MODIFY_PBK="",t.SCHEDULED="",t.SEARCH="",t.SHARE="󨃱",t.TOC="",t.WRITE_UGC="",t.TRASH="",t.EXTLINK="",t.CALENDAR="",t.BOOK="",t.DOWNLOAD_PLAIN="",t.CHECK="",t.TOPICS="",t.EYE="",t.DISC="",t.CIRCLE="",t.SHARED="",t.SORT_UNSORTED="",t.SORT_UP="",t.SORT_DOWN="",t.WORKING="",t.CLOSE="",t.ZOOM_OUT="",t.ZOOM_IN="",t.ZOOM_REALSIZE="",t.ZOOM_FULLSCREEN="",t.ADMIN_RESTRICTED="",t.ADMIN_THEME="",t.WARNING="",t.CONTEXT="",t.SEARCH_HOME="",t.STEPS="",t.HOME="",t.TRANSLATE="",t.USER="",t.ADMIN="",t.ANALYTICS="",t.ADMIN_KHUB="",t.ADMIN_USERS="",t.ADMIN_INTEGRATION="",t.ADMIN_PORTAL=""}(ve||(ve={})),function(t){t.UNKNOWN="",t.ABW="",t.AUDIO="",t.AVI="",t.CHM="",t.CODE="",t.CSV="",t.DITA="",t.EPUB="",t.EXCEL="",t.FLAC="",t.GIF="",t.GZIP="",t.HTML="",t.IMAGE="",t.JPEG="",t.JSON="",t.M4A="",t.MOV="",t.MP3="",t.MP4="",t.OGG="",t.PDF="",t.PNG="",t.POWERPOINT="",t.RAR="",t.STP="",t.TEXT="",t.VIDEO="",t.WAV="",t.WMA="",t.WORD="",t.XML="",t.YAML="",t.ZIP=""}(be||(be={})),new Map([...["abw"].map((t=>[t,be.ABW])),...["3gp","act","aiff","aac","amr","au","awb","dct","dss","dvf","gsm","iklax","ivs","mmf","mpc","msv","opus","ra","rm","raw","sln","tta","vox","wv"].map((t=>[t,be.AUDIO])),...["avi"].map((t=>[t,be.AVI])),...["chm","xhs"].map((t=>[t,be.CHM])),...["java","py","php","php3","php4","php5","js","javascript","rb","rbw","c","cpp","cxx","h","hh","hpp","hxx","sh","bash","zsh","tcsh","ksh","csh","vb","scala","pl","prl","perl","groovy","ceylon","aspx","jsp","scpt","applescript","bas","bat","lua","jsp","mk","cmake","css","sass","less","m","mm","xcodeproj"].map((t=>[t,be.CODE])),...["csv"].map((t=>[t,be.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,be.DITA])),...["epub"].map((t=>[t,be.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,be.EXCEL])),...["flac"].map((t=>[t,be.FLAC])),...["gif"].map((t=>[t,be.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,be.GZIP])),...["html","htm","xhtml"].map((t=>[t,be.HTML])),...["ai","vml","xps","img","cpt","psd","psp","xcf","svg","svg+xml","bmp","bpg","ppm","pgm","pbm","pnm","rif","tif","tiff","webp","wmf"].map((t=>[t,be.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,be.JPEG])),...["json"].map((t=>[t,be.JSON])),...["m4a","m4p"].map((t=>[t,be.M4A])),...["mov","qt"].map((t=>[t,be.MOV])),...["mp3"].map((t=>[t,be.MP3])),...["mp4","m4v"].map((t=>[t,be.MP4])),...["ogg","oga"].map((t=>[t,be.OGG])),...["pdf","ps"].map((t=>[t,be.PDF])),...["png"].map((t=>[t,be.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,be.POWERPOINT])),...["rar"].map((t=>[t,be.RAR])),...["stp"].map((t=>[t,be.STP])),...["txt","rtf","md","mdown"].map((t=>[t,be.TEXT])),...["webm","mkv","flv","vob","ogv","ogg","drc","mng","wmv","yuv","rm","rmvb","asf","mpg","mp2","mpeg","mpe","mpv","m2v","svi","3gp","3g2","mxf","roq","nsv"].map((t=>[t,be.VIDEO])),...["wav"].map((t=>[t,be.WAV])),...["wma"].map((t=>[t,be.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,be.WORD])),...["xml","xsl","rdf"].map((t=>[t,be.XML])),...["yaml","yml","x-yaml"].map((t=>[t,be.YAML])),...["zip"].map((t=>[t,be.ZIP]))]);const we=e.FtCssVariableFactory.create("--ft-icon-font-size","SIZE","24px"),ke=e.FtCssVariableFactory.extend("--ft-icon-fluid-topics-font-family",e.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","ft-icons")),ze=e.FtCssVariableFactory.extend("--ft-icon-file-format-font-family",e.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","ft-mime")),Se=e.FtCssVariableFactory.extend("--ft-icon-material-font-family",e.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","Material Icons")),Ee=e.FtCssVariableFactory.create("--ft-icon-vertical-align","UNKNOWN","unset"),Ne=i.css`
|
|
357
|
+
`}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 e,i;super.updated(t),t.has("disabled")&&(this.disabled?(this.endRipple(),null===(e=this.target)||void 0===e||e.removeAttribute("data-is-ft-ripple-target")):null===(i=this.target)||void 0===i||i.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(){super.connectedCallback(),this.setupDebouncer.run((()=>{var t;const e=null===(t=this.shadowRoot)||void 0===t?void 0:t.host.parentElement;e&&this.setupFor(e),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 e=(...t)=>e=>{t.forEach((t=>window.addEventListener(t,this.endPress,{once:!0}))),this.startPress(e)},i=e("mouseup","contextmenu"),o=e("touchend","touchcancel"),s=t=>{["Enter"," "].includes(t.key)&&e("keyup")(t)};t.addEventListener("mouseover",this.startHover),t.addEventListener("mousemove",this.moveRipple),t.addEventListener("mouseleave",this.endHover),t.addEventListener("mousedown",i),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",i),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,this.target=void 0}}getCoordinates(t){const e=t,i=t;let o,s;return null!=e.x?({x:o,y:s}=e):null!=i.touches&&(o=i.touches[0].clientX,s=i.touches[0].clientY),{x:o,y:s}}isIgnored(t){if(this.disabled)return!0;if(null!=t)for(let e of t.composedPath()){if(e===this.target)break;if("hasAttribute"in e&&e.hasAttribute("data-is-ft-ripple-target"))return!0}return!1}disconnectedCallback(){super.disconnectedCallback(),this.onDisconnect&&this.onDisconnect(),this.resizeObserver.disconnect(),this.endRipple()}}ke.elementDefinitions={},ke.styles=be,we([o.property({type:Boolean})],ke.prototype,"primary",void 0),we([o.property({type:Boolean})],ke.prototype,"secondary",void 0),we([o.property({type:Boolean})],ke.prototype,"unbounded",void 0),we([o.property({type:Boolean})],ke.prototype,"activated",void 0),we([o.property({type:Boolean})],ke.prototype,"selected",void 0),we([o.property({type:Boolean})],ke.prototype,"disabled",void 0),we([o.state()],ke.prototype,"hovered",void 0),we([o.state()],ke.prototype,"focused",void 0),we([o.state()],ke.prototype,"pressed",void 0),we([o.state()],ke.prototype,"rippling",void 0),we([o.state()],ke.prototype,"rippleSize",void 0),we([o.state()],ke.prototype,"originX",void 0),we([o.state()],ke.prototype,"originY",void 0),we([o.query(".ft-ripple")],ke.prototype,"ripple",void 0),we([o.query(".ft-ripple--effect")],ke.prototype,"rippleEffect",void 0),e.customElement("ft-ripple")(ke),function(t){t.THUMBS_DOWN="",t.THUMBS_DOWN_PLAIN="",t.THUMBS_UP="",t.THUMBS_UP_PLAIN="",t.STAR="",t.STAR_PLAIN="",t.DESKTOP="",t.TABLET_LANDSCAPE="",t.TABLET_PORTRAIT="",t.MOBILE_LANDSCAPE="",t.MOBILE_PORTRAIT="",t.ARROW_RIGHT_TO_LINE="",t.THIN_ARROW_UP="",t.CONTEXTUAL="",t.UNSTRUCTURED_DOC="",t.RESET="",t.THIN_ARROW_LEFT="",t.THIN_ARROW_RIGHT="",t.MY_COLLECTIONS="",t.OFFLINE_SETTINGS="",t.MY_LIBRARY="",t.RATE_PLAIN="",t.RATE="",t.FEEDBACK_PLAIN="",t.PAUSE="",t.PLAY="",t.RELATIVES_PLAIN="",t.RELATIVES="",t.SHORTCUT_MENU="",t.PRINT="",t.DEFAULT_ROLES="",t.ACCOUNT_SETTINGS="",t.ONLINE="",t.OFFLINE="",t.UPLOAD="",t.BOOK_PLAIN="",t.SYNC="",t.SHARED_PBK="",t.COLLECTIONS="",t.SEARCH_IN_PUBLICATION="",t.BOOKS="",t.LOCKER="",t.ARROW_DOWN="",t.ARROW_LEFT="",t.ARROW_RIGHT="",t.ARROW_UP="",t.SAVE="",t.MAILS_AND_NOTIFICATIONS="",t.DOT="",t.MINUS="",t.PLUS="",t.FILTERS="",t.STRIPE_ARROW_RIGHT="",t.STRIPE_ARROW_LEFT="",t.ATTACHMENTS="",t.ADD_BOOKMARK="",t.BOOKMARK="",t.EXPORT="",t.MENU="",t.TAG="",t.TAG_PLAIN="",t.COPY_TO_CLIPBOARD="",t.COLUMNS="",t.ARTICLE="",t.CLOSE_PLAIN="",t.CHECK_PLAIN="",t.LOGOUT="",t.SIGN_IN="",t.THIN_ARROW="",t.TRIANGLE_BOTTOM="",t.TRIANGLE_LEFT="",t.TRIANGLE_RIGHT="",t.TRIANGLE_TOP="",t.FACET_HAS_DESCENDANT="",t.MINUS_PLAIN="",t.PLUS_PLAIN="",t.INFO="",t.ICON_EXPAND="",t.ICON_COLLAPSE="",t.ADD_TO_PBK="",t.ALERT="",t.ADD_ALERT="",t.BACK_TO_SEARCH="",t.DOWNLOAD="",t.EDIT="",t.FEEDBACK="",t.MODIFY_PBK="",t.SCHEDULED="",t.SEARCH="",t.SHARE="󨃱",t.TOC="",t.WRITE_UGC="",t.TRASH="",t.EXTLINK="",t.CALENDAR="",t.BOOK="",t.DOWNLOAD_PLAIN="",t.CHECK="",t.TOPICS="",t.EYE="",t.DISC="",t.CIRCLE="",t.SHARED="",t.SORT_UNSORTED="",t.SORT_UP="",t.SORT_DOWN="",t.WORKING="",t.CLOSE="",t.ZOOM_OUT="",t.ZOOM_IN="",t.ZOOM_REALSIZE="",t.ZOOM_FULLSCREEN="",t.ADMIN_RESTRICTED="",t.ADMIN_THEME="",t.WARNING="",t.CONTEXT="",t.SEARCH_HOME="",t.STEPS="",t.HOME="",t.TRANSLATE="",t.USER="",t.ADMIN="",t.ANALYTICS="",t.ADMIN_KHUB="",t.ADMIN_USERS="",t.ADMIN_INTEGRATION="",t.ADMIN_PORTAL=""}(me||(me={})),function(t){t.UNKNOWN="",t.ABW="",t.AUDIO="",t.AVI="",t.CHM="",t.CODE="",t.CSV="",t.DITA="",t.EPUB="",t.EXCEL="",t.FLAC="",t.GIF="",t.GZIP="",t.HTML="",t.IMAGE="",t.JPEG="",t.JSON="",t.M4A="",t.MOV="",t.MP3="",t.MP4="",t.OGG="",t.PDF="",t.PNG="",t.POWERPOINT="",t.RAR="",t.STP="",t.TEXT="",t.VIDEO="",t.WAV="",t.WMA="",t.WORD="",t.XML="",t.YAML="",t.ZIP=""}($e||($e={})),new Map([...["abw"].map((t=>[t,$e.ABW])),...["3gp","act","aiff","aac","amr","au","awb","dct","dss","dvf","gsm","iklax","ivs","mmf","mpc","msv","opus","ra","rm","raw","sln","tta","vox","wv"].map((t=>[t,$e.AUDIO])),...["avi"].map((t=>[t,$e.AVI])),...["chm","xhs"].map((t=>[t,$e.CHM])),...["java","py","php","php3","php4","php5","js","javascript","rb","rbw","c","cpp","cxx","h","hh","hpp","hxx","sh","bash","zsh","tcsh","ksh","csh","vb","scala","pl","prl","perl","groovy","ceylon","aspx","jsp","scpt","applescript","bas","bat","lua","jsp","mk","cmake","css","sass","less","m","mm","xcodeproj"].map((t=>[t,$e.CODE])),...["csv"].map((t=>[t,$e.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,$e.DITA])),...["epub"].map((t=>[t,$e.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,$e.EXCEL])),...["flac"].map((t=>[t,$e.FLAC])),...["gif"].map((t=>[t,$e.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,$e.GZIP])),...["html","htm","xhtml"].map((t=>[t,$e.HTML])),...["ai","vml","xps","img","cpt","psd","psp","xcf","svg","svg+xml","bmp","bpg","ppm","pgm","pbm","pnm","rif","tif","tiff","webp","wmf"].map((t=>[t,$e.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,$e.JPEG])),...["json"].map((t=>[t,$e.JSON])),...["m4a","m4p"].map((t=>[t,$e.M4A])),...["mov","qt"].map((t=>[t,$e.MOV])),...["mp3"].map((t=>[t,$e.MP3])),...["mp4","m4v"].map((t=>[t,$e.MP4])),...["ogg","oga"].map((t=>[t,$e.OGG])),...["pdf","ps"].map((t=>[t,$e.PDF])),...["png"].map((t=>[t,$e.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,$e.POWERPOINT])),...["rar"].map((t=>[t,$e.RAR])),...["stp"].map((t=>[t,$e.STP])),...["txt","rtf","md","mdown"].map((t=>[t,$e.TEXT])),...["webm","mkv","flv","vob","ogv","ogg","drc","mng","wmv","yuv","rm","rmvb","asf","mpg","mp2","mpeg","mpe","mpv","m2v","svi","3gp","3g2","mxf","roq","nsv"].map((t=>[t,$e.VIDEO])),...["wav"].map((t=>[t,$e.WAV])),...["wma"].map((t=>[t,$e.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,$e.WORD])),...["xml","xsl","rdf"].map((t=>[t,$e.XML])),...["yaml","yml","x-yaml"].map((t=>[t,$e.YAML])),...["zip"].map((t=>[t,$e.ZIP]))]);const ze=e.FtCssVariableFactory.create("--ft-icon-font-size","SIZE","24px"),Se=e.FtCssVariableFactory.extend("--ft-icon-fluid-topics-font-family",e.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","ft-icons")),Ee=e.FtCssVariableFactory.extend("--ft-icon-file-format-font-family",e.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","ft-mime")),Ne=e.FtCssVariableFactory.extend("--ft-icon-material-font-family",e.FtCssVariableFactory.create("--ft-icon-font-family","UNKNOWN","Material Icons")),je=e.FtCssVariableFactory.create("--ft-icon-vertical-align","UNKNOWN","unset"),Oe=i.css`
|
|
358
358
|
:host, i.ft-icon {
|
|
359
359
|
display: inline-flex;
|
|
360
360
|
align-items: center;
|
|
@@ -363,14 +363,14 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
363
363
|
}
|
|
364
364
|
|
|
365
365
|
:host {
|
|
366
|
-
width: ${
|
|
367
|
-
height: ${
|
|
366
|
+
width: ${ze};
|
|
367
|
+
height: ${ze};
|
|
368
368
|
}
|
|
369
369
|
|
|
370
370
|
i.ft-icon {
|
|
371
371
|
width: 100%;
|
|
372
372
|
height: 100%;
|
|
373
|
-
font-size: ${
|
|
373
|
+
font-size: ${ze};
|
|
374
374
|
line-height: 1;
|
|
375
375
|
font-weight: normal;
|
|
376
376
|
text-transform: none;
|
|
@@ -381,32 +381,32 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
381
381
|
text-rendering: auto;
|
|
382
382
|
-webkit-font-smoothing: antialiased;
|
|
383
383
|
-moz-osx-font-smoothing: grayscale;
|
|
384
|
-
vertical-align: ${
|
|
384
|
+
vertical-align: ${je};
|
|
385
385
|
}
|
|
386
386
|
|
|
387
387
|
i.ft-icon.ft-icon--fluid-topics {
|
|
388
|
-
font-family: ${
|
|
388
|
+
font-family: ${Se}, ft-icons, fticons, sans-serif;
|
|
389
389
|
|
|
390
390
|
/* Ugly fix because font is broken */
|
|
391
|
-
font-size: calc(0.
|
|
391
|
+
font-size: calc(0.75 * ${ze});
|
|
392
392
|
position: relative;
|
|
393
|
-
top: -
|
|
393
|
+
top: -4%;
|
|
394
394
|
justify-content: center;
|
|
395
395
|
}
|
|
396
396
|
|
|
397
397
|
.ft-icon--file-format {
|
|
398
|
-
font-family: ${
|
|
398
|
+
font-family: ${Ee}, ft-mime, sans-serif;
|
|
399
399
|
}
|
|
400
400
|
|
|
401
401
|
.ft-icon--material {
|
|
402
|
-
font-family: ${
|
|
402
|
+
font-family: ${Ne}, "Material Icons", sans-serif;
|
|
403
403
|
}
|
|
404
|
-
`;var
|
|
405
|
-
<i class="ft-icon ${"ft-icon--"+
|
|
404
|
+
`;var Ce;!function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"}(Ce||(Ce={}));var Ie=function(t,e,i,o){for(var s,l=arguments.length,n=l<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,r=t.length-1;r>=0;r--)(s=t[r])&&(n=(l<3?s(n):l>3?s(e,i,n):s(e,i))||n);return l>3&&n&&Object.defineProperty(e,i,n),n};class Ae extends e.FtLitElement{constructor(){super(...arguments),this.resolvedIcon=i.nothing}render(){const t=this.variant&&Object.values(Ce).includes(this.variant)?this.variant:Ce.fluid_topics,e=t!==Ce.material||!!this.value;return i.html`
|
|
405
|
+
<i class="ft-icon ${"ft-icon--"+t}">
|
|
406
406
|
${l.unsafeHTML(this.resolvedIcon)}
|
|
407
|
-
<slot ?hidden=${
|
|
407
|
+
<slot ?hidden=${e}></slot>
|
|
408
408
|
</i>
|
|
409
|
-
`}get textContent(){var t,e;return null!==(e=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==e?e:""}update(t){super.update(t),["value","variant"].some((e=>t.has(e)))&&this.resolveIcon()}resolveIcon(){var t,e;let o=this.value||this.textContent;switch(this.variant){case
|
|
409
|
+
`}get textContent(){var t,e;return null!==(e=null===(t=this.slottedContent)||void 0===t?void 0:t.assignedNodes().map((t=>t.textContent)).join("").trim())&&void 0!==e?e:""}update(t){super.update(t),["value","variant"].some((e=>t.has(e)))&&this.resolveIcon()}resolveIcon(){var t,e;let o=this.value||this.textContent;switch(this.variant){case Ce.file_format:this.resolvedIcon=null!==(t=$e[o.replace("-","_").toUpperCase()])&&void 0!==t?t:o;break;case Ce.material:this.resolvedIcon=this.value||i.nothing;break;default:this.resolvedIcon=null!==(e=me[o.replace("-","_").toUpperCase()])&&void 0!==e?e:o}}firstUpdated(t){super.firstUpdated(t),setTimeout((()=>this.resolveIcon()))}}Ae.elementDefinitions={},Ae.styles=Oe,Ie([o.property()],Ae.prototype,"variant",void 0),Ie([o.property()],Ae.prototype,"value",void 0),Ie([o.state()],Ae.prototype,"resolvedIcon",void 0),Ie([o.query("slot")],Ae.prototype,"slottedContent",void 0),e.customElement("ft-icon")(Ae);const De={fontSize:e.FtCssVariableFactory.create("--ft-text-field-font-size","SIZE","14px"),labelSize:e.FtCssVariableFactory.create("--ft-text-field-label-size","SIZE","11px"),verticalSpacing:e.FtCssVariableFactory.create("--ft-text-field-vertical-spacing","SIZE","4px"),horizontalSpacing:e.FtCssVariableFactory.create("--ft-text-field-horizontal-spacing","SIZE","16px"),helperColor:e.FtCssVariableFactory.extend("--ft-text-field-helper-color",e.designSystemVariables.colorOnSurfaceMedium),colorPrimary:e.FtCssVariableFactory.external(e.designSystemVariables.colorPrimary,"Design system"),colorOnSurface:e.FtCssVariableFactory.external(e.designSystemVariables.colorOnSurface,"Design system"),colorOnSurfaceDisabled:e.FtCssVariableFactory.external(e.designSystemVariables.colorOnSurfaceDisabled,"Design system"),borderRadiusS:e.FtCssVariableFactory.external(e.designSystemVariables.borderRadiusS,"Design system"),colorError:e.FtCssVariableFactory.external(e.designSystemVariables.colorError,"Design system"),prefixColor:e.FtCssVariableFactory.extend("--ft-text-field-prefix-color",e.designSystemVariables.colorOnSurfaceMedium),iconColor:e.FtCssVariableFactory.extend("--ft-text-field-icon-color",e.designSystemVariables.colorOnSurfaceMedium),floatingZIndex:e.FtCssVariableFactory.create("--ft-text-field-floating-components-z-index","NUMBER","3"),colorSurface:e.FtCssVariableFactory.external(e.designSystemVariables.colorSurface,"Design system"),colorOutline:e.FtCssVariableFactory.external(e.designSystemVariables.colorOutline,"Design system"),elevation02:e.FtCssVariableFactory.external(e.designSystemVariables.elevation02,"Design system"),suggestSize:e.FtCssVariableFactory.create("--ft-text-field-suggest-size","SIZE","300px")},Be=i.css`
|
|
410
410
|
*:focus {
|
|
411
411
|
outline: none;
|
|
412
412
|
}
|
|
@@ -419,16 +419,16 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
419
419
|
}
|
|
420
420
|
|
|
421
421
|
ft-input-label {
|
|
422
|
-
${e.setVariable(
|
|
423
|
-
${e.setVariable(
|
|
424
|
-
${e.setVariable(
|
|
425
|
-
${e.setVariable(
|
|
422
|
+
${e.setVariable(re.fontSize,De.fontSize)};
|
|
423
|
+
${e.setVariable(re.raisedFontSize,De.labelSize)};
|
|
424
|
+
${e.setVariable(re.verticalSpacing,De.verticalSpacing)};
|
|
425
|
+
${e.setVariable(re.horizontalSpacing,De.horizontalSpacing)};
|
|
426
426
|
}
|
|
427
427
|
|
|
428
428
|
.ft-text-field--main-panel {
|
|
429
429
|
position: relative;
|
|
430
430
|
display: flex;
|
|
431
|
-
height: calc(4 * ${
|
|
431
|
+
height: calc(4 * ${De.verticalSpacing} + ${De.labelSize} + ${De.fontSize});
|
|
432
432
|
}
|
|
433
433
|
|
|
434
434
|
.ft-text-field--input-panel {
|
|
@@ -437,24 +437,24 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
437
437
|
display: flex;
|
|
438
438
|
align-items: center;
|
|
439
439
|
overflow: hidden;
|
|
440
|
-
padding: 0 ${
|
|
440
|
+
padding: 0 ${De.horizontalSpacing};
|
|
441
441
|
|
|
442
|
-
${e.setVariable(
|
|
443
|
-
${e.setVariable(
|
|
442
|
+
${e.setVariable(wt.fontSize,De.fontSize)};
|
|
443
|
+
${e.setVariable(wt.lineHeight,De.fontSize)};
|
|
444
444
|
}
|
|
445
445
|
|
|
446
446
|
.ft-text-field--input-panel ft-ripple {
|
|
447
|
-
${e.setVariable(
|
|
448
|
-
${e.setVariable(
|
|
447
|
+
${e.setVariable(de.opacityContentOnSurfaceHover,"0.08")};
|
|
448
|
+
${e.setVariable(de.opacityContentOnSurfacePressed,"0.04")};
|
|
449
449
|
}
|
|
450
450
|
|
|
451
451
|
.ft-text-field--filled.ft-text-field--with-label .ft-text-field--input-panel {
|
|
452
452
|
align-items: flex-end;
|
|
453
|
-
padding: 0 ${
|
|
453
|
+
padding: 0 ${De.horizontalSpacing} ${De.verticalSpacing} ${De.horizontalSpacing};
|
|
454
454
|
}
|
|
455
455
|
|
|
456
456
|
.ft-text-field--prefix {
|
|
457
|
-
color: ${
|
|
457
|
+
color: ${De.prefixColor};
|
|
458
458
|
margin-right: 2px;
|
|
459
459
|
flex-shrink: 1;
|
|
460
460
|
overflow: hidden;
|
|
@@ -473,15 +473,15 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
473
473
|
flex-shrink: 1;
|
|
474
474
|
min-width: 0; /* flex sets this to auto an prevents input from shrinking properly */
|
|
475
475
|
|
|
476
|
-
color: ${
|
|
477
|
-
padding: calc(2 * ${
|
|
476
|
+
color: ${De.colorOnSurface};
|
|
477
|
+
padding: calc(2 * ${De.verticalSpacing}) 0;
|
|
478
478
|
border: none;
|
|
479
479
|
background: none;
|
|
480
480
|
}
|
|
481
481
|
|
|
482
482
|
.ft-text-field--filled.ft-text-field--with-label .ft-text-field--input {
|
|
483
483
|
padding-bottom: 0;
|
|
484
|
-
padding-top: calc(${
|
|
484
|
+
padding-top: calc(${De.labelSize} + 2 * ${De.verticalSpacing});
|
|
485
485
|
}
|
|
486
486
|
|
|
487
487
|
.ft-text-field--input::-webkit-calendar-picker-indicator,
|
|
@@ -490,37 +490,37 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
490
490
|
}
|
|
491
491
|
|
|
492
492
|
.ft-text-field--disabled .ft-text-field--input {
|
|
493
|
-
color: ${
|
|
493
|
+
color: ${De.colorOnSurfaceDisabled};
|
|
494
494
|
}
|
|
495
495
|
|
|
496
496
|
.ft-text-field:not(.ft-text-field--disabled):focus-within ft-input-label {
|
|
497
|
-
${e.setVariable(
|
|
498
|
-
${e.setVariable(
|
|
497
|
+
${e.setVariable(re.borderColor,De.colorPrimary)};
|
|
498
|
+
${e.setVariable(re.textColor,De.colorPrimary)};
|
|
499
499
|
}
|
|
500
500
|
|
|
501
501
|
.ft-text-field--filled .ft-text-field--input-panel {
|
|
502
|
-
border-radius: ${
|
|
502
|
+
border-radius: ${De.borderRadiusS} ${De.borderRadiusS} 0 0;
|
|
503
503
|
}
|
|
504
504
|
|
|
505
505
|
.ft-text-field--outlined .ft-text-field--input-panel {
|
|
506
|
-
border-radius: ${
|
|
506
|
+
border-radius: ${De.borderRadiusS};
|
|
507
507
|
}
|
|
508
508
|
|
|
509
509
|
.ft-text-field--helper-text {
|
|
510
|
-
padding: 0 12px 0 ${
|
|
511
|
-
color: ${
|
|
510
|
+
padding: 0 12px 0 ${De.horizontalSpacing};
|
|
511
|
+
color: ${De.helperColor};
|
|
512
512
|
}
|
|
513
513
|
|
|
514
514
|
.ft-text-field--in-error .ft-text-field--input,
|
|
515
515
|
.ft-text-field--in-error .ft-text-field--helper-text,
|
|
516
516
|
.ft-text-field--in-error .ft-text-field--prefix {
|
|
517
|
-
color: ${
|
|
517
|
+
color: ${De.colorError};
|
|
518
518
|
}
|
|
519
519
|
|
|
520
520
|
.ft-text-field--icon {
|
|
521
521
|
align-self: center;
|
|
522
522
|
margin-left: 8px;
|
|
523
|
-
color: ${
|
|
523
|
+
color: ${De.iconColor};
|
|
524
524
|
}
|
|
525
525
|
|
|
526
526
|
.ft-text-field--container {
|
|
@@ -533,13 +533,13 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
533
533
|
position: absolute;
|
|
534
534
|
left: 0;
|
|
535
535
|
right: 0;
|
|
536
|
-
z-index: ${
|
|
537
|
-
background: ${
|
|
538
|
-
border: 1px solid ${
|
|
539
|
-
border-radius: 0 0 ${
|
|
540
|
-
box-shadow: ${
|
|
536
|
+
z-index: ${De.floatingZIndex};
|
|
537
|
+
background: ${De.colorSurface};
|
|
538
|
+
border: 1px solid ${De.colorOutline};
|
|
539
|
+
border-radius: 0 0 ${De.borderRadiusS} ${De.borderRadiusS};
|
|
540
|
+
box-shadow: ${De.elevation02};
|
|
541
541
|
outline: none;
|
|
542
|
-
max-height: ${
|
|
542
|
+
max-height: ${De.suggestSize};
|
|
543
543
|
overflow-y: auto;
|
|
544
544
|
}
|
|
545
545
|
|
|
@@ -556,9 +556,9 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
556
556
|
}
|
|
557
557
|
|
|
558
558
|
.ft-text-field--with-icon {
|
|
559
|
-
${e.setVariable(
|
|
559
|
+
${e.setVariable(re.labelMaxWidth,`calc(100% - ${ze} - ${re.horizontalSpacing})`)};
|
|
560
560
|
}
|
|
561
|
-
`;var
|
|
561
|
+
`;var Ze=function(t,e,i,o){for(var s,l=arguments.length,n=l<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,r=t.length-1;r>=0;r--)(s=t[r])&&(n=(l<3?s(n):l>3?s(e,i,n):s(e,i))||n);return l>3&&n&&Object.defineProperty(e,i,n),n};class _e extends e.FtLitElement{constructor(){super(...arguments),this._value="",this.dispatchedValue="",this.outlined=!1,this.disabled=!1,this.error=!1,this.prefix=null,this.filterSuggestions=!1,this.focused=!1,this.suggestionsOnTop=!1,this.hideSuggestions=!1,this.visibleSuggestions=[]}get value(){return this._value}set value(t){this.setInternalValue(t),this.dispatchedValue=t}setInternalValue(t){const e=this._value;this._value=t,this.requestUpdate("value",e)}focus(){var t;null===(t=this.input)||void 0===t||t.focus()}render(){const t={"ft-text-field":!0,"ft-text-field--filled":!this.outlined,"ft-text-field--outlined":this.outlined,"ft-text-field--disabled":this.disabled,"ft-text-field--has-value":!!this.value,"ft-text-field--with-label":!!this.label,"ft-text-field--in-error":this.error,"ft-text-field--with-prefix":!!this.prefix,"ft-text-field--hide-suggestions":0===this.visibleSuggestions.length||this.hideSuggestions,"ft-text-field--raised-label":this.focused||""!=this.value,"ft-text-field--with-icon":!!this.icon};return i.html`
|
|
562
562
|
<div class="${s.classMap(t)}">
|
|
563
563
|
<div class="ft-text-field--main-panel"
|
|
564
564
|
@keydown=${this.handleKeyboardNavigation}
|
|
@@ -578,7 +578,7 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
578
578
|
</ft-typography>
|
|
579
579
|
`:i.nothing}
|
|
580
580
|
<input type="text"
|
|
581
|
-
maxlength=${(t=>null!=t?t:
|
|
581
|
+
maxlength=${(t=>null!=t?t:j)(this.maxLength||void 0)}
|
|
582
582
|
aria-label="${this.label}"
|
|
583
583
|
class="ft-typography--body1 ft-text-field--input"
|
|
584
584
|
?disabled=${this.disabled}
|
|
@@ -604,7 +604,7 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
604
604
|
</ft-typography>
|
|
605
605
|
`:i.nothing}
|
|
606
606
|
</div>
|
|
607
|
-
`}updated(t){super.updated(t),(t.has("value")||t.has("filterSuggestions"))&&this.filterSuggestionsIfNeeded(),t.has("value")&&null!=t.get("value")&&(this.hideSuggestions=!1),t.has("dispatchedValue")&&null!=t.get("dispatchedValue")&&(this.hideSuggestions=!0)}filterSuggestionsIfNeeded(){this.filterSuggestions?(this.suggestions.forEach((t=>t.hidden=!t.getValue().toLowerCase().includes(this.value.toLowerCase()))),this.visibleSuggestions=this.suggestions.filter((t=>!t.hidden))):this.visibleSuggestions=this.suggestions}contentAvailableCallback(t){var e,i;if(super.contentAvailableCallback(t),!this.hideSuggestions&&this.visibleSuggestions.length>0){const t=null===(e=this.input)||void 0===e?void 0:e.getBoundingClientRect(),o=null===(i=this.suggestionsContainer)||void 0===i?void 0:i.getBoundingClientRect();t&&o&&(this.suggestionsOnTop=t.bottom+o.height>window.innerHeight&&t.top-o.height>0)}}setValue(t,e=!1){this.value!==t&&(this.setInternalValue(t),this.dispatchEvent(new CustomEvent("live-change",{detail:t}))),e&&this.dispatchedValue!==t&&(this.dispatchedValue=t,this.dispatchEvent(new CustomEvent("change",{detail:t})))}handleInput(t){var e;const i=(null===(e=this.input)||void 0===e?void 0:e.value)||"";this.setValue(i,"Escape"==t.key||"Enter"==t.key)}handleClick(){this.hideSuggestions=!1}handleKeyboardNavigation(t){var e;if("ArrowDown"===t.key||"ArrowUp"===t.key){t.preventDefault(),t.stopPropagation(),this.hideSuggestions=!1;const i=this.visibleSuggestions.findIndex((t=>t.matches(":focus-within")));let o;o="ArrowDown"===t.key?i<this.visibleSuggestions.length-1?i+1:0:i>0?i-1:this.visibleSuggestions.length-1,null===(e=this.visibleSuggestions[o])||void 0===e||e.focus()}"Escape"!=t.key&&"Enter"!=t.key||(this.hideSuggestions=!0)}onSuggestionSelected(t){var e;this.setValue(t.detail,!0),null===(e=this.input)||void 0===e||e.focus(),setTimeout((()=>this.hideSuggestions=!0),0)}onFocus(){this.focused=!0,this.hideSuggestions=!1}onMainPanelBlur(){var t,e;(null===(t=this.mainPanel)||void 0===t?void 0:t.matches(":focus-within"))||(this.focused=!1,this.setValue((null===(e=this.input)||void 0===e?void 0:e.value)||"",!0))}}
|
|
607
|
+
`}updated(t){super.updated(t),(t.has("value")||t.has("filterSuggestions"))&&this.filterSuggestionsIfNeeded(),t.has("value")&&null!=t.get("value")&&(this.hideSuggestions=!1),t.has("dispatchedValue")&&null!=t.get("dispatchedValue")&&(this.hideSuggestions=!0)}filterSuggestionsIfNeeded(){this.filterSuggestions?(this.suggestions.forEach((t=>t.hidden=!t.getValue().toLowerCase().includes(this.value.toLowerCase()))),this.visibleSuggestions=this.suggestions.filter((t=>!t.hidden))):this.visibleSuggestions=this.suggestions}contentAvailableCallback(t){var e,i;if(super.contentAvailableCallback(t),!this.hideSuggestions&&this.visibleSuggestions.length>0){const t=null===(e=this.input)||void 0===e?void 0:e.getBoundingClientRect(),o=null===(i=this.suggestionsContainer)||void 0===i?void 0:i.getBoundingClientRect();t&&o&&(this.suggestionsOnTop=t.bottom+o.height>window.innerHeight&&t.top-o.height>0)}}setValue(t,e=!1){this.value!==t&&(this.setInternalValue(t),this.dispatchEvent(new CustomEvent("live-change",{detail:t}))),e&&this.dispatchedValue!==t&&(this.dispatchedValue=t,this.dispatchEvent(new CustomEvent("change",{detail:t})))}handleInput(t){var e;const i=(null===(e=this.input)||void 0===e?void 0:e.value)||"";this.setValue(i,"Escape"==t.key||"Enter"==t.key)}handleClick(){this.hideSuggestions=!1}handleKeyboardNavigation(t){var e;if("ArrowDown"===t.key||"ArrowUp"===t.key){t.preventDefault(),t.stopPropagation(),this.hideSuggestions=!1;const i=this.visibleSuggestions.findIndex((t=>t.matches(":focus-within")));let o;o="ArrowDown"===t.key?i<this.visibleSuggestions.length-1?i+1:0:i>0?i-1:this.visibleSuggestions.length-1,null===(e=this.visibleSuggestions[o])||void 0===e||e.focus()}"Escape"!=t.key&&"Enter"!=t.key||(this.hideSuggestions=!0)}onSuggestionSelected(t){var e;this.setValue(t.detail,!0),null===(e=this.input)||void 0===e||e.focus(),setTimeout((()=>this.hideSuggestions=!0),0)}onFocus(){this.focused=!0,this.hideSuggestions=!1}onMainPanelBlur(){var t,e;(null===(t=this.mainPanel)||void 0===t?void 0:t.matches(":focus-within"))||(this.focused=!1,this.setValue((null===(e=this.input)||void 0===e?void 0:e.value)||"",!0))}}_e.elementDefinitions={"ft-input-label":pe,"ft-ripple":ke,"ft-typography":ne,"ft-icon":Ae},_e.styles=[Jt,Be],Ze([o.property()],_e.prototype,"label",void 0),Ze([o.property({noAccessor:!0})],_e.prototype,"value",null),Ze([o.state()],_e.prototype,"dispatchedValue",void 0),Ze([o.property()],_e.prototype,"helper",void 0),Ze([o.property({type:Boolean})],_e.prototype,"outlined",void 0),Ze([o.property({type:Boolean})],_e.prototype,"disabled",void 0),Ze([o.property({type:Boolean})],_e.prototype,"error",void 0),Ze([o.property()],_e.prototype,"prefix",void 0),Ze([o.property()],_e.prototype,"icon",void 0),Ze([o.property()],_e.prototype,"iconVariant",void 0),Ze([o.property({type:Boolean})],_e.prototype,"filterSuggestions",void 0),Ze([o.property({type:Number})],_e.prototype,"maxLength",void 0),Ze([o.state()],_e.prototype,"focused",void 0),Ze([o.state()],_e.prototype,"suggestionsOnTop",void 0),Ze([o.state()],_e.prototype,"hideSuggestions",void 0),Ze([o.state()],_e.prototype,"visibleSuggestions",void 0),Ze([o.query(".ft-text-field--main-panel")],_e.prototype,"mainPanel",void 0),Ze([o.query(".ft-text-field--input")],_e.prototype,"input",void 0),Ze([o.query(".ft-text-field--suggestions")],_e.prototype,"suggestionsContainer",void 0),Ze([o.queryAssignedElements({selector:"ft-text-field-suggestion"})],_e.prototype,"suggestions",void 0);const Ue=i.css`
|
|
608
608
|
.ft-text-field-suggestion {
|
|
609
609
|
position: relative;
|
|
610
610
|
padding: 8px 16px;
|
|
@@ -629,7 +629,7 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
629
629
|
slot {
|
|
630
630
|
pointer-events: none;
|
|
631
631
|
}
|
|
632
|
-
`;var
|
|
632
|
+
`;var Me=function(t,e,i,o){for(var s,l=arguments.length,n=l<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o,r=t.length-1;r>=0;r--)(s=t[r])&&(n=(l<3?s(n):l>3?s(e,i,n):s(e,i))||n);return l>3&&n&&Object.defineProperty(e,i,n),n};class Te extends CustomEvent{constructor(t){super("suggestion-selected",{detail:t,bubbles:!0,composed:!0})}}class Re extends e.FtLitElement{render(){return i.html`
|
|
633
633
|
<div class="ft-text-field-suggestion"
|
|
634
634
|
tabindex="-1"
|
|
635
635
|
@keydown=${this.onKeyDown}
|
|
@@ -641,4 +641,4 @@ const W=Symbol.for(""),K=t=>{if((null==t?void 0:t.r)===W)return null==t?void 0:t
|
|
|
641
641
|
<slot></slot>
|
|
642
642
|
</ft-typography>
|
|
643
643
|
</div>
|
|
644
|
-
`}focus(t){var e;null===(e=this.container)||void 0===e||e.focus(t)}click(){var t;null===(t=this.container)||void 0===t||t.click()}confirmSuggestion(){this.dispatchEvent(new
|
|
644
|
+
`}focus(t){var e;null===(e=this.container)||void 0===e||e.focus(t)}click(){var t;null===(t=this.container)||void 0===t||t.click()}confirmSuggestion(){this.dispatchEvent(new Te(this.getValue()))}getValue(){return this.value||this.textContent}get textContent(){return this.assignedNodes.map((t=>t.textContent)).join("").trim()}onKeyDown(t){["Enter"," "].includes(t.key)&&(t.preventDefault(),t.stopPropagation(),this.confirmSuggestion())}}Re.elementDefinitions={"ft-ripple":ke,"ft-typography":ne,"ft-icon":Ae},Re.styles=Ue,Me([o.property()],Re.prototype,"value",void 0),Me([o.query(".ft-text-field-suggestion")],Re.prototype,"container",void 0),Me([o.queryAssignedNodes()],Re.prototype,"assignedNodes",void 0),e.customElement("ft-text-field")(_e),e.customElement("ft-text-field-suggestion")(Re),t.FtTextField=_e,t.FtTextFieldCssVariables=De,t.FtTextFieldSuggestion=Re,t.SuggestionSelectedEvent=Te,t.styles=Be,t.suggestionStyles=Ue}({},ftGlobals.wcUtils,ftGlobals.lit,ftGlobals.litDecorators,ftGlobals.litClassMap,ftGlobals.litUnsafeHTML);
|