genus-ui 1.99.25 → 1.99.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.es.js
CHANGED
|
@@ -341,11 +341,9 @@ let q = class extends _ {
|
|
|
341
341
|
);
|
|
342
342
|
this._targetInput.value = t.marshaltext, this.inputValue = t.marshaltext, this._defaultValue = t.marshaltext;
|
|
343
343
|
let e = Number(this._targetInput.selectionStart);
|
|
344
|
-
if (t.marshaltext.length >= this._targetInput.value.length)
|
|
344
|
+
if (t.marshaltext.length >= this._targetInput.value.length)
|
|
345
345
|
for (let s = e; s <= t.marshaltext.length; s++)
|
|
346
|
-
|
|
347
|
-
return;
|
|
348
|
-
}
|
|
346
|
+
t.marshaltext[s - 1], this._targetInput.value[e - 1];
|
|
349
347
|
}
|
|
350
348
|
this.dispatchEvent(new CustomEvent("typed", { detail: i.target.value }));
|
|
351
349
|
}, this.renderInputControl = (i) => ({
|
|
@@ -1831,7 +1829,7 @@ var Hr = Object.defineProperty, Fr = Object.getOwnPropertyDescriptor, ge = (i, t
|
|
|
1831
1829
|
};
|
|
1832
1830
|
let Rt = class extends _ {
|
|
1833
1831
|
constructor() {
|
|
1834
|
-
super(...arguments), this.dataCardTitle = "", this.dataCardValue = "", this.dataCardIcon = "", this.
|
|
1832
|
+
super(...arguments), this.dataCardTitle = "", this.dataCardValue = "", this.dataCardIcon = "", this.dataCardLayoutDirection = "row", this.withoutIcon = !1, this.isLoading = 0;
|
|
1835
1833
|
}
|
|
1836
1834
|
render() {
|
|
1837
1835
|
return Pt(
|
|
@@ -1842,7 +1840,7 @@ let Rt = class extends _ {
|
|
|
1842
1840
|
<div class='loader-line loader-line-2'></div>
|
|
1843
1841
|
</div>
|
|
1844
1842
|
` : M`
|
|
1845
|
-
<div class='data-card data-card--${this.
|
|
1843
|
+
<div class='data-card data-card--${this.dataCardLayoutDirection} data-card--no-icon'>
|
|
1846
1844
|
<h4 class='data-card__title'>${this.dataCardTitle}</h4>
|
|
1847
1845
|
<p class='data-card__text'>${this.dataCardValue}</p>
|
|
1848
1846
|
</div>
|
|
@@ -1854,7 +1852,7 @@ let Rt = class extends _ {
|
|
|
1854
1852
|
<div class='loader-line loader-line-2'></div>
|
|
1855
1853
|
</div>
|
|
1856
1854
|
` : M`
|
|
1857
|
-
<div class='data-card data-card--${this.
|
|
1855
|
+
<div class='data-card data-card--${this.dataCardLayoutDirection}'>
|
|
1858
1856
|
<div class='icon-container'>
|
|
1859
1857
|
<img class='component-icon' src=${this.dataCardIcon} />
|
|
1860
1858
|
</div>
|
|
@@ -1877,7 +1875,7 @@ ge([
|
|
|
1877
1875
|
], Rt.prototype, "dataCardIcon", 2);
|
|
1878
1876
|
ge([
|
|
1879
1877
|
D({ attribute: "layout-direction" })
|
|
1880
|
-
], Rt.prototype, "
|
|
1878
|
+
], Rt.prototype, "dataCardLayoutDirection", 2);
|
|
1881
1879
|
ge([
|
|
1882
1880
|
D({ type: Boolean, attribute: "without-icon" })
|
|
1883
1881
|
], Rt.prototype, "withoutIcon", 2);
|
package/dist/index.umd.js
CHANGED
|
@@ -202,7 +202,7 @@
|
|
|
202
202
|
background: var(--icon-container-background-color, #f2f7f9);
|
|
203
203
|
grid-area: icc;
|
|
204
204
|
}
|
|
205
|
-
`,Qn="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='24px'%20height='24px'%20viewBox='0%200%2024%2024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cstyle%3e%20%23Profile%20{%20fill:%20%23203e70;%20}%20%3c/style%3e%3ctitle%3eIconly/Bold/Profile%3c/title%3e%3cg%20id='Iconly/Bold/Profile'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='Profile'%20transform='translate(4.000000,%202.000000)'%20fill='%23000000'%20fill-rule='nonzero'%3e%3cpath%20d='M8,13.1739317%20C12.338627,13.1739317%2016,13.8789388%2016,16.598966%20C16,19.3199932%2012.314618,20%208,20%20C3.66237339,20%205.68434189e-14,19.2949929%205.68434189e-14,16.5749657%20C5.68434189e-14,13.8539385%203.68538202,13.1739317%208,13.1739317%20Z%20M8,-6.03961325e-14%20C10.9391022,-6.03961325e-14%2013.2939852,2.35402354%2013.2939852,5.29105291%20C13.2939852,8.22808228%2010.9391022,10.5831058%208,10.5831058%20C5.06189821,10.5831058%202.70601476,8.22808228%202.70601476,5.29105291%20C2.70601476,2.35402354%205.06189821,-6.03961325e-14%208,-6.03961325e-14%20Z'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/svg%3e",Pn="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='24px'%20height='24px'%20viewBox='0%200%2024%2024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cstyle%3e%20%23Password%20{%20fill:%20%23203e70;%20}%20%3c/style%3e%3ctitle%3eIconly/Bold/Password%3c/title%3e%3cg%20id='Iconly/Bold/Password'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='Password'%20transform='translate(1.999700,%201.999200)'%20fill='%23000000'%20fill-rule='nonzero'%3e%3cpath%20d='M14.335,0%20C17.723,0%2020,2.378%2020,5.917%20L20,5.917%20L20,14.084%20C20,17.623%2017.723,20%2014.334,20%20L14.334,20%20L5.666,20%20C2.277,20%200,17.623%200,14.084%20L0,14.084%20L0,5.917%20C0,2.378%202.277,0%205.666,0%20L5.666,0%20Z%20M6.841,7.399%20C5.407,7.399%204.24,8.566%204.24,10%20C4.24,11.435%205.407,12.602%206.841,12.602%20C8.013,12.602%208.995,11.818%209.319,10.75%20L9.319,10.75%20L11.431,10.75%20L11.431,11.852%20C11.431,12.266%2011.767,12.602%2012.181,12.602%20C12.595,12.602%2012.931,12.266%2012.931,11.852%20L12.931,11.852%20L12.931,10.75%20L14.261,10.75%20L14.261,11.852%20C14.261,12.266%2014.597,12.602%2015.011,12.602%20C15.425,12.602%2015.761,12.266%2015.761,11.852%20L15.761,11.852%20L15.761,10%20C15.761,9.586%2015.425,9.25%2015.011,9.25%20L15.011,9.25%20L9.319,9.25%20C8.995,8.183%208.013,7.399%206.841,7.399%20Z%20M6.8411,8.8989%20C7.4481,8.8989%207.9431,9.3929%207.9431,10.0009%20C7.9431,10.6079%207.4481,11.1019%206.8411,11.1019%20C6.2341,11.1019%205.7391,10.6079%205.7391,10.0009%20C5.7391,9.3929%206.2341,8.8989%206.8411,8.8989%20Z'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/svg%3e",On="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='24px'%20height='24px'%20viewBox='0%200%2024%2024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cstyle%3e%20%23Message%20{%20fill:%20%23203e70;%20}%20%3c/style%3e%3ctitle%3eIconly/Bold/Message%3c/title%3e%3cg%20id='Iconly/Bold/Message'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='Message'%20transform='translate(2.000400,%203.000000)'%20fill='%23000000'%20fill-rule='nonzero'%3e%3cpath%20d='M14.939,0%20C16.28,0%2017.57,0.53%2018.519,1.481%20C19.469,2.43%2020,3.71%2020,5.05%20L20,5.05%20L20,12.95%20C20,15.74%2017.73,18%2014.939,18%20L14.939,18%20L5.06,18%20C2.269,18%200,15.74%200,12.95%20L0,12.95%20L0,5.05%20C0,2.26%202.259,0%205.06,0%20L5.06,0%20Z%20M16.07,5.2%20C15.86,5.189%2015.66,5.26%2015.509,5.4%20L15.509,5.4%20L11,9%20C10.42,9.481%209.589,9.481%209,9%20L9,9%20L4.5,5.4%20C4.189,5.17%203.759,5.2%203.5,5.47%20C3.23,5.74%203.2,6.17%203.429,6.47%20L3.429,6.47%20L3.56,6.6%20L8.11,10.15%20C8.67,10.59%209.349,10.83%2010.06,10.83%20C10.769,10.83%2011.46,10.59%2012.019,10.15%20L12.019,10.15%20L16.53,6.54%20L16.61,6.46%20C16.849,6.17%2016.849,5.75%2016.599,5.46%20C16.46,5.311%2016.269,5.22%2016.07,5.2%20Z'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/svg%3e",zn="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='24px'%20height='24px'%20viewBox='0%200%2024%2024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cstyle%3e%20%23Search%20{%20stroke:%20%23203e70;%20}%20%3c/style%3e%3ctitle%3eIconly/Light/Search%3c/title%3e%3cg%20id='Iconly/Light/Search'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%20stroke-linecap='round'%20stroke-linejoin='round'%3e%3cg%20id='Search'%20transform='translate(2.000000,%202.000000)'%20stroke='%23000000'%20stroke-width='1.5'%3e%3ccircle%20id='Ellipse_739'%20cx='9.76659044'%20cy='9.76659044'%20r='8.9885584'%3e%3c/circle%3e%3cline%20x1='16.0183067'%20y1='16.4851259'%20x2='19.5423342'%20y2='20.0000001'%20id='Line_181'%3e%3c/line%3e%3c/g%3e%3c/g%3e%3c/svg%3e",Ke="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20stroke='%23203e70'%20stroke-width='2'%20stroke-linecap='round'%20stroke-linejoin='round'%20class='feather%20feather-hash'%3e%3cline%20x1='4'%20y1='9'%20x2='20'%20y2='9'%3e%3c/line%3e%3cline%20x1='4'%20y1='15'%20x2='20'%20y2='15'%3e%3c/line%3e%3cline%20x1='10'%20y1='3'%20x2='8'%20y2='21'%3e%3c/line%3e%3cline%20x1='16'%20y1='3'%20x2='14'%20y2='21'%3e%3c/line%3e%3c/svg%3e";var Li={},Qt={};Object.defineProperty(Qt,"__esModule",{value:!0}),Qt.isCharExist=Qt.letterCount=Qt.setCharAt=void 0;function Ia(i,t,e){return t>i.length-1?i:i.substring(0,t)+e+i.substring(t+1)}Qt.setCharAt=Ia;function Ea(i,t){return i?i.split("").reduce((e,n)=>n===t?e+1:e,0):0}Qt.letterCount=Ea;function ka(i,t){if(!i)return 0;let e=0,n=!1;for(;e<t.length;){if(typeof t[e]=="number"||typeof t[e]=="string"){if(i.includes(t[e])){n=!0;break}}else t[e].test(i)&&(n=!0);e++}return!!n}Qt.isCharExist=ka,Object.defineProperty(Li,"__esModule",{value:!0});var Ln=Li.textMarshal=void 0;const ae=Qt;function Qa({input:i="",template:t="",disallowCharacters:e=[],isRepeat:{value:n,removeStart:s,removeEnd:o}={value:!1,removeStart:!1,removeEnd:!1}}){try{t=t.toLowerCase(),n==!0&&i.length>(0,ae.letterCount)(t,"x")&&(t=t.repeat(Math.ceil(i.length/(0,ae.letterCount)(t,"x")))),o&&t[0]!=="x"&&(t=(0,ae.setCharAt)(t,0,"")),s&&t[t.length-1]!=="x"&&(t=(0,ae.setCharAt)(t,t.length-1,""));let a=t,r=0,l="",A=0;for(;r<t.length;){if(A>i.length-1){t=t.substring(0,r),a=a.substring(0,r);break}if(t[r]==i[r]){r++,A++;continue}if(e&&(0,ae.isCharExist)(i[A],e)){A++;continue}t[r]=="x"&&(t=(0,ae.setCharAt)(t,r,i[A]),l=l+i[A],A++),r++}return{template:a,plaintext:l,marshaltext:t}}catch{return{template:"",plaintext:"",marshaltext:""}}}Ln=Li.textMarshal=Qa;var Pa=Object.defineProperty,Oa=Object.getOwnPropertyDescriptor,_=(i,t,e,n)=>{for(var s=n>1?void 0:n?Oa(t,e):t,o=i.length-1,a;o>=0;o--)(a=i[o])&&(s=(n?a(t,e,s):a(s))||s);return n&&s&&Pa(t,e,s),s};M.GenusTextBox=class extends f.LitElement{constructor(){super(),this.labelText="",this.inputValue="",this.inputType="text",this.formatInput="",this.inputName="",this.inputIcon="",this.placeholderText="",this.dataPattern="",this.disallowedCharacters="",this.withoutIcon=!1,this.withoutLabel=!1,this.withoutLabelIcon=!1,this.readOnly=!1,this._targetInput=null,this._defaultValue="",this.getInputValue=t=>{if(this._targetInput===null&&(this._targetInput=t.target),this.inputValue=this._targetInput.value,this._internals.setFormValue(this._targetInput.value),this.formatInput){let e=Ln({input:this._targetInput.value,template:this._targetInput.getAttribute("data-pattern"),disallowCharacters:[new RegExp(this.disallowedCharacters)]});this._targetInput.value=e.marshaltext,this.inputValue=e.marshaltext,this._defaultValue=e.marshaltext;let n=Number(this._targetInput.selectionStart);if(e.marshaltext.length>=this._targetInput.value.length)
|
|
205
|
+
`,Qn="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='24px'%20height='24px'%20viewBox='0%200%2024%2024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cstyle%3e%20%23Profile%20{%20fill:%20%23203e70;%20}%20%3c/style%3e%3ctitle%3eIconly/Bold/Profile%3c/title%3e%3cg%20id='Iconly/Bold/Profile'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='Profile'%20transform='translate(4.000000,%202.000000)'%20fill='%23000000'%20fill-rule='nonzero'%3e%3cpath%20d='M8,13.1739317%20C12.338627,13.1739317%2016,13.8789388%2016,16.598966%20C16,19.3199932%2012.314618,20%208,20%20C3.66237339,20%205.68434189e-14,19.2949929%205.68434189e-14,16.5749657%20C5.68434189e-14,13.8539385%203.68538202,13.1739317%208,13.1739317%20Z%20M8,-6.03961325e-14%20C10.9391022,-6.03961325e-14%2013.2939852,2.35402354%2013.2939852,5.29105291%20C13.2939852,8.22808228%2010.9391022,10.5831058%208,10.5831058%20C5.06189821,10.5831058%202.70601476,8.22808228%202.70601476,5.29105291%20C2.70601476,2.35402354%205.06189821,-6.03961325e-14%208,-6.03961325e-14%20Z'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/svg%3e",Pn="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='24px'%20height='24px'%20viewBox='0%200%2024%2024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cstyle%3e%20%23Password%20{%20fill:%20%23203e70;%20}%20%3c/style%3e%3ctitle%3eIconly/Bold/Password%3c/title%3e%3cg%20id='Iconly/Bold/Password'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='Password'%20transform='translate(1.999700,%201.999200)'%20fill='%23000000'%20fill-rule='nonzero'%3e%3cpath%20d='M14.335,0%20C17.723,0%2020,2.378%2020,5.917%20L20,5.917%20L20,14.084%20C20,17.623%2017.723,20%2014.334,20%20L14.334,20%20L5.666,20%20C2.277,20%200,17.623%200,14.084%20L0,14.084%20L0,5.917%20C0,2.378%202.277,0%205.666,0%20L5.666,0%20Z%20M6.841,7.399%20C5.407,7.399%204.24,8.566%204.24,10%20C4.24,11.435%205.407,12.602%206.841,12.602%20C8.013,12.602%208.995,11.818%209.319,10.75%20L9.319,10.75%20L11.431,10.75%20L11.431,11.852%20C11.431,12.266%2011.767,12.602%2012.181,12.602%20C12.595,12.602%2012.931,12.266%2012.931,11.852%20L12.931,11.852%20L12.931,10.75%20L14.261,10.75%20L14.261,11.852%20C14.261,12.266%2014.597,12.602%2015.011,12.602%20C15.425,12.602%2015.761,12.266%2015.761,11.852%20L15.761,11.852%20L15.761,10%20C15.761,9.586%2015.425,9.25%2015.011,9.25%20L15.011,9.25%20L9.319,9.25%20C8.995,8.183%208.013,7.399%206.841,7.399%20Z%20M6.8411,8.8989%20C7.4481,8.8989%207.9431,9.3929%207.9431,10.0009%20C7.9431,10.6079%207.4481,11.1019%206.8411,11.1019%20C6.2341,11.1019%205.7391,10.6079%205.7391,10.0009%20C5.7391,9.3929%206.2341,8.8989%206.8411,8.8989%20Z'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/svg%3e",On="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='24px'%20height='24px'%20viewBox='0%200%2024%2024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cstyle%3e%20%23Message%20{%20fill:%20%23203e70;%20}%20%3c/style%3e%3ctitle%3eIconly/Bold/Message%3c/title%3e%3cg%20id='Iconly/Bold/Message'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='Message'%20transform='translate(2.000400,%203.000000)'%20fill='%23000000'%20fill-rule='nonzero'%3e%3cpath%20d='M14.939,0%20C16.28,0%2017.57,0.53%2018.519,1.481%20C19.469,2.43%2020,3.71%2020,5.05%20L20,5.05%20L20,12.95%20C20,15.74%2017.73,18%2014.939,18%20L14.939,18%20L5.06,18%20C2.269,18%200,15.74%200,12.95%20L0,12.95%20L0,5.05%20C0,2.26%202.259,0%205.06,0%20L5.06,0%20Z%20M16.07,5.2%20C15.86,5.189%2015.66,5.26%2015.509,5.4%20L15.509,5.4%20L11,9%20C10.42,9.481%209.589,9.481%209,9%20L9,9%20L4.5,5.4%20C4.189,5.17%203.759,5.2%203.5,5.47%20C3.23,5.74%203.2,6.17%203.429,6.47%20L3.429,6.47%20L3.56,6.6%20L8.11,10.15%20C8.67,10.59%209.349,10.83%2010.06,10.83%20C10.769,10.83%2011.46,10.59%2012.019,10.15%20L12.019,10.15%20L16.53,6.54%20L16.61,6.46%20C16.849,6.17%2016.849,5.75%2016.599,5.46%20C16.46,5.311%2016.269,5.22%2016.07,5.2%20Z'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/svg%3e",zn="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='24px'%20height='24px'%20viewBox='0%200%2024%2024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cstyle%3e%20%23Search%20{%20stroke:%20%23203e70;%20}%20%3c/style%3e%3ctitle%3eIconly/Light/Search%3c/title%3e%3cg%20id='Iconly/Light/Search'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%20stroke-linecap='round'%20stroke-linejoin='round'%3e%3cg%20id='Search'%20transform='translate(2.000000,%202.000000)'%20stroke='%23000000'%20stroke-width='1.5'%3e%3ccircle%20id='Ellipse_739'%20cx='9.76659044'%20cy='9.76659044'%20r='8.9885584'%3e%3c/circle%3e%3cline%20x1='16.0183067'%20y1='16.4851259'%20x2='19.5423342'%20y2='20.0000001'%20id='Line_181'%3e%3c/line%3e%3c/g%3e%3c/g%3e%3c/svg%3e",Ke="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20stroke='%23203e70'%20stroke-width='2'%20stroke-linecap='round'%20stroke-linejoin='round'%20class='feather%20feather-hash'%3e%3cline%20x1='4'%20y1='9'%20x2='20'%20y2='9'%3e%3c/line%3e%3cline%20x1='4'%20y1='15'%20x2='20'%20y2='15'%3e%3c/line%3e%3cline%20x1='10'%20y1='3'%20x2='8'%20y2='21'%3e%3c/line%3e%3cline%20x1='16'%20y1='3'%20x2='14'%20y2='21'%3e%3c/line%3e%3c/svg%3e";var Li={},Qt={};Object.defineProperty(Qt,"__esModule",{value:!0}),Qt.isCharExist=Qt.letterCount=Qt.setCharAt=void 0;function Ia(i,t,e){return t>i.length-1?i:i.substring(0,t)+e+i.substring(t+1)}Qt.setCharAt=Ia;function Ea(i,t){return i?i.split("").reduce((e,n)=>n===t?e+1:e,0):0}Qt.letterCount=Ea;function ka(i,t){if(!i)return 0;let e=0,n=!1;for(;e<t.length;){if(typeof t[e]=="number"||typeof t[e]=="string"){if(i.includes(t[e])){n=!0;break}}else t[e].test(i)&&(n=!0);e++}return!!n}Qt.isCharExist=ka,Object.defineProperty(Li,"__esModule",{value:!0});var Ln=Li.textMarshal=void 0;const ae=Qt;function Qa({input:i="",template:t="",disallowCharacters:e=[],isRepeat:{value:n,removeStart:s,removeEnd:o}={value:!1,removeStart:!1,removeEnd:!1}}){try{t=t.toLowerCase(),n==!0&&i.length>(0,ae.letterCount)(t,"x")&&(t=t.repeat(Math.ceil(i.length/(0,ae.letterCount)(t,"x")))),o&&t[0]!=="x"&&(t=(0,ae.setCharAt)(t,0,"")),s&&t[t.length-1]!=="x"&&(t=(0,ae.setCharAt)(t,t.length-1,""));let a=t,r=0,l="",A=0;for(;r<t.length;){if(A>i.length-1){t=t.substring(0,r),a=a.substring(0,r);break}if(t[r]==i[r]){r++,A++;continue}if(e&&(0,ae.isCharExist)(i[A],e)){A++;continue}t[r]=="x"&&(t=(0,ae.setCharAt)(t,r,i[A]),l=l+i[A],A++),r++}return{template:a,plaintext:l,marshaltext:t}}catch{return{template:"",plaintext:"",marshaltext:""}}}Ln=Li.textMarshal=Qa;var Pa=Object.defineProperty,Oa=Object.getOwnPropertyDescriptor,_=(i,t,e,n)=>{for(var s=n>1?void 0:n?Oa(t,e):t,o=i.length-1,a;o>=0;o--)(a=i[o])&&(s=(n?a(t,e,s):a(s))||s);return n&&s&&Pa(t,e,s),s};M.GenusTextBox=class extends f.LitElement{constructor(){super(),this.labelText="",this.inputValue="",this.inputType="text",this.formatInput="",this.inputName="",this.inputIcon="",this.placeholderText="",this.dataPattern="",this.disallowedCharacters="",this.withoutIcon=!1,this.withoutLabel=!1,this.withoutLabelIcon=!1,this.readOnly=!1,this._targetInput=null,this._defaultValue="",this.getInputValue=t=>{if(this._targetInput===null&&(this._targetInput=t.target),this.inputValue=this._targetInput.value,this._internals.setFormValue(this._targetInput.value),this.formatInput){let e=Ln({input:this._targetInput.value,template:this._targetInput.getAttribute("data-pattern"),disallowCharacters:[new RegExp(this.disallowedCharacters)]});this._targetInput.value=e.marshaltext,this.inputValue=e.marshaltext,this._defaultValue=e.marshaltext;let n=Number(this._targetInput.selectionStart);if(e.marshaltext.length>=this._targetInput.value.length)for(let s=n;s<=e.marshaltext.length;s++)e.marshaltext[s-1],this._targetInput.value[n-1]}this.dispatchEvent(new CustomEvent("typed",{detail:t.target.value}))},this.renderInputControl=t=>({text:()=>{let n;return this.withoutIcon?n=f.html`
|
|
206
206
|
<div class='form-field form-field--without-icon'>
|
|
207
207
|
<label class='input-label'>${this.labelText}</label>
|
|
208
208
|
${this.readOnly?f.html`<input class='input-control input-control--without-icon' type='${t}' value=${this.inputValue} readonly />`:f.html`<input class='input-control input-control--without-icon' type='${t}' @input=${this.getInputValue} name='${this.inputName}' placeholder=${this.placeholderText} value=${this.inputValue} data-pattern=${this.dataPattern} />`}
|
|
@@ -1281,13 +1281,13 @@
|
|
|
1281
1281
|
width: var(--icon-width, 1.5625rem);
|
|
1282
1282
|
height: var(--icon-height, 1.5625rem);
|
|
1283
1283
|
}
|
|
1284
|
-
`;var yr=Object.defineProperty,Cr=Object.getOwnPropertyDescriptor,Vt=(i,t,e,n)=>{for(var s=n>1?void 0:n?Cr(t,e):t,o=i.length-1,a;o>=0;o--)(a=i[o])&&(s=(n?a(t,e,s):a(s))||s);return n&&s&&yr(t,e,s),s};M.GenusDataCard=class extends f.LitElement{constructor(){super(...arguments),this.dataCardTitle="",this.dataCardValue="",this.dataCardIcon="",this.
|
|
1284
|
+
`;var yr=Object.defineProperty,Cr=Object.getOwnPropertyDescriptor,Vt=(i,t,e,n)=>{for(var s=n>1?void 0:n?Cr(t,e):t,o=i.length-1,a;o>=0;o--)(a=i[o])&&(s=(n?a(t,e,s):a(s))||s);return n&&s&&yr(t,e,s),s};M.GenusDataCard=class extends f.LitElement{constructor(){super(...arguments),this.dataCardTitle="",this.dataCardValue="",this.dataCardIcon="",this.dataCardLayoutDirection="row",this.withoutIcon=!1,this.isLoading=0}render(){return Dt.when(this.withoutIcon,()=>this.isLoading?f.html`
|
|
1285
1285
|
<div class='data-card-loader data-card-loader--no-icon'>
|
|
1286
1286
|
<div class='loader-line loader-line-1'></div>
|
|
1287
1287
|
<div class='loader-line loader-line-2'></div>
|
|
1288
1288
|
</div>
|
|
1289
1289
|
`:f.html`
|
|
1290
|
-
<div class='data-card data-card--${this.
|
|
1290
|
+
<div class='data-card data-card--${this.dataCardLayoutDirection} data-card--no-icon'>
|
|
1291
1291
|
<h4 class='data-card__title'>${this.dataCardTitle}</h4>
|
|
1292
1292
|
<p class='data-card__text'>${this.dataCardValue}</p>
|
|
1293
1293
|
</div>
|
|
@@ -1298,14 +1298,14 @@
|
|
|
1298
1298
|
<div class='loader-line loader-line-2'></div>
|
|
1299
1299
|
</div>
|
|
1300
1300
|
`:f.html`
|
|
1301
|
-
<div class='data-card data-card--${this.
|
|
1301
|
+
<div class='data-card data-card--${this.dataCardLayoutDirection}'>
|
|
1302
1302
|
<div class='icon-container'>
|
|
1303
1303
|
<img class='component-icon' src=${this.dataCardIcon} />
|
|
1304
1304
|
</div>
|
|
1305
1305
|
<h4 class='data-card__title'>${this.dataCardTitle}</h4>
|
|
1306
1306
|
<p class='data-card__text'>${this.dataCardValue}</p>
|
|
1307
1307
|
</div>
|
|
1308
|
-
`)}},M.GenusDataCard.styles=[Dr,Yr,Br,Gr,xr],Vt([m.property({attribute:"card-title"})],M.GenusDataCard.prototype,"dataCardTitle",2),Vt([m.property({attribute:"card-value"})],M.GenusDataCard.prototype,"dataCardValue",2),Vt([m.property({attribute:"data-card-icon"})],M.GenusDataCard.prototype,"dataCardIcon",2),Vt([m.property({attribute:"layout-direction"})],M.GenusDataCard.prototype,"
|
|
1308
|
+
`)}},M.GenusDataCard.styles=[Dr,Yr,Br,Gr,xr],Vt([m.property({attribute:"card-title"})],M.GenusDataCard.prototype,"dataCardTitle",2),Vt([m.property({attribute:"card-value"})],M.GenusDataCard.prototype,"dataCardValue",2),Vt([m.property({attribute:"data-card-icon"})],M.GenusDataCard.prototype,"dataCardIcon",2),Vt([m.property({attribute:"layout-direction"})],M.GenusDataCard.prototype,"dataCardLayoutDirection",2),Vt([m.property({type:Boolean,attribute:"without-icon"})],M.GenusDataCard.prototype,"withoutIcon",2),Vt([m.property({attribute:"is-loading",type:Number})],M.GenusDataCard.prototype,"isLoading",2),M.GenusDataCard=Vt([m.customElement("genus-data-card")],M.GenusDataCard);const Nn=f.css`
|
|
1309
1309
|
.label-text, .options-label
|
|
1310
1310
|
{
|
|
1311
1311
|
font-family: var(--font-family, 'Sofia Pro Regular');
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@ export declare class GenusDataCard extends LitElement {
|
|
|
3
3
|
dataCardTitle: string;
|
|
4
4
|
dataCardValue: string;
|
|
5
5
|
dataCardIcon: string;
|
|
6
|
-
|
|
6
|
+
dataCardLayoutDirection: string;
|
|
7
7
|
withoutIcon: boolean;
|
|
8
8
|
isLoading: number;
|
|
9
9
|
static styles: import("lit").CSSResult[];
|