@scalar/components 0.0.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.
Files changed (68) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +123 -0
  3. package/dist/components/ScalarButton/ScalarButton.spec.d.ts +2 -0
  4. package/dist/components/ScalarButton/ScalarButton.spec.d.ts.map +1 -0
  5. package/dist/components/ScalarButton/ScalarButton.stories.d.ts +889 -0
  6. package/dist/components/ScalarButton/ScalarButton.stories.d.ts.map +1 -0
  7. package/dist/components/ScalarButton/ScalarButton.vue.d.ts +55 -0
  8. package/dist/components/ScalarButton/ScalarButton.vue.d.ts.map +1 -0
  9. package/dist/components/ScalarButton/index.d.ts +2 -0
  10. package/dist/components/ScalarButton/index.d.ts.map +1 -0
  11. package/dist/components/ScalarIcon/ScalarIcon.spec.d.ts +2 -0
  12. package/dist/components/ScalarIcon/ScalarIcon.spec.d.ts.map +1 -0
  13. package/dist/components/ScalarIcon/ScalarIcon.stories.d.ts +71 -0
  14. package/dist/components/ScalarIcon/ScalarIcon.stories.d.ts.map +1 -0
  15. package/dist/components/ScalarIcon/ScalarIcon.vue.d.ts +17 -0
  16. package/dist/components/ScalarIcon/ScalarIcon.vue.d.ts.map +1 -0
  17. package/dist/components/ScalarIcon/SvgRenderer.d.ts +7 -0
  18. package/dist/components/ScalarIcon/SvgRenderer.d.ts.map +1 -0
  19. package/dist/components/ScalarIcon/icons/iconNames.d.ts +2 -0
  20. package/dist/components/ScalarIcon/icons/iconNames.d.ts.map +1 -0
  21. package/dist/components/ScalarIcon/icons/index.d.ts +4 -0
  22. package/dist/components/ScalarIcon/icons/index.d.ts.map +1 -0
  23. package/dist/components/ScalarIcon/index.d.ts +3 -0
  24. package/dist/components/ScalarIcon/index.d.ts.map +1 -0
  25. package/dist/components/ScalarIconButton/ScalarIconButton.spec.d.ts +2 -0
  26. package/dist/components/ScalarIconButton/ScalarIconButton.spec.d.ts.map +1 -0
  27. package/dist/components/ScalarIconButton/ScalarIconButton.stories.d.ts +57 -0
  28. package/dist/components/ScalarIconButton/ScalarIconButton.stories.d.ts.map +1 -0
  29. package/dist/components/ScalarIconButton/ScalarIconButton.vue.d.ts +35 -0
  30. package/dist/components/ScalarIconButton/ScalarIconButton.vue.d.ts.map +1 -0
  31. package/dist/components/ScalarIconButton/index.d.ts +2 -0
  32. package/dist/components/ScalarIconButton/index.d.ts.map +1 -0
  33. package/dist/components/ScalarLoading/ScalarLoading.spec.d.ts +2 -0
  34. package/dist/components/ScalarLoading/ScalarLoading.spec.d.ts.map +1 -0
  35. package/dist/components/ScalarLoading/ScalarLoading.stories.d.ts +326 -0
  36. package/dist/components/ScalarLoading/ScalarLoading.stories.d.ts.map +1 -0
  37. package/dist/components/ScalarLoading/ScalarLoading.vue.d.ts +48 -0
  38. package/dist/components/ScalarLoading/ScalarLoading.vue.d.ts.map +1 -0
  39. package/dist/components/ScalarLoading/index.d.ts +2 -0
  40. package/dist/components/ScalarLoading/index.d.ts.map +1 -0
  41. package/dist/components/ScalarModal/ScalarModal.spec.d.ts +2 -0
  42. package/dist/components/ScalarModal/ScalarModal.spec.d.ts.map +1 -0
  43. package/dist/components/ScalarModal/ScalarModal.stories.d.ts +202 -0
  44. package/dist/components/ScalarModal/ScalarModal.stories.d.ts.map +1 -0
  45. package/dist/components/ScalarModal/ScalarModal.vue.d.ts +52 -0
  46. package/dist/components/ScalarModal/ScalarModal.vue.d.ts.map +1 -0
  47. package/dist/components/ScalarModal/index.d.ts +2 -0
  48. package/dist/components/ScalarModal/index.d.ts.map +1 -0
  49. package/dist/components/ScalarTextField/ScalarTextField.spec.d.ts +2 -0
  50. package/dist/components/ScalarTextField/ScalarTextField.spec.d.ts.map +1 -0
  51. package/dist/components/ScalarTextField/ScalarTextField.stories.d.ts +992 -0
  52. package/dist/components/ScalarTextField/ScalarTextField.stories.d.ts.map +1 -0
  53. package/dist/components/ScalarTextField/ScalarTextField.vue.d.ts +73 -0
  54. package/dist/components/ScalarTextField/ScalarTextField.vue.d.ts.map +1 -0
  55. package/dist/components/ScalarTextField/index.d.ts +2 -0
  56. package/dist/components/ScalarTextField/index.d.ts.map +1 -0
  57. package/dist/index-6bb15e9f.js +1802 -0
  58. package/dist/index-c8ae42b3.cjs +4 -0
  59. package/dist/index.cjs +54 -0
  60. package/dist/index.d.ts +13 -0
  61. package/dist/index.d.ts.map +1 -0
  62. package/dist/index.js +3757 -0
  63. package/dist/index.umd.cjs +57 -0
  64. package/dist/style.css +1 -0
  65. package/package.json +92 -0
  66. package/src/tailwind/index.ts +1 -0
  67. package/src/tailwind/tailwind.css +18 -0
  68. package/src/tailwind/tailwind.theme.ts +65 -0
@@ -0,0 +1,4 @@
1
+ "use strict";var U={},L={};function Te(e,t){return t===void 0&&(t=Object),t&&typeof t.freeze=="function"?t.freeze(e):e}function _t(e,t){if(e===null||typeof e!="object")throw new TypeError("target is not an object");for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}var He=Te({HTML:"text/html",isHTML:function(e){return e===He.HTML},XML_APPLICATION:"application/xml",XML_TEXT:"text/xml",XML_XHTML_APPLICATION:"application/xhtml+xml",XML_SVG_IMAGE:"image/svg+xml"}),qe=Te({HTML:"http://www.w3.org/1999/xhtml",isHTML:function(e){return e===qe.HTML},SVG:"http://www.w3.org/2000/svg",XML:"http://www.w3.org/XML/1998/namespace",XMLNS:"http://www.w3.org/2000/xmlns/"});L.assign=_t;L.freeze=Te;L.MIME_TYPE=He;L.NAMESPACE=qe;var bt=L,K=bt.NAMESPACE;function Ot(e){return e!==""}function At(e){return e?e.split(/[\t\n\f\r ]+/).filter(Ot):[]}function xt(e,t){return e.hasOwnProperty(t)||(e[t]=!0),e}function Me(e){if(!e)return[];var t=At(e);return Object.keys(t.reduce(xt,{}))}function It(e){return function(t){return e&&e.indexOf(t)!==-1}}function te(e,t){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])}function b(e,t){var n=e.prototype;if(!(n instanceof t)){let r=function(){};r.prototype=t.prototype,r=new r,te(n,r),e.prototype=n=r}n.constructor!=e&&(typeof e!="function"&&console.error("unknown Class:"+e),n.constructor=e)}var O={},S=O.ELEMENT_NODE=1,Y=O.ATTRIBUTE_NODE=2,ue=O.TEXT_NODE=3,Be=O.CDATA_SECTION_NODE=4,Qe=O.ENTITY_REFERENCE_NODE=5,St=O.ENTITY_NODE=6,We=O.PROCESSING_INSTRUCTION_NODE=7,Ze=O.COMMENT_NODE=8,Ke=O.DOCUMENT_NODE=9,Je=O.DOCUMENT_TYPE_NODE=10,M=O.DOCUMENT_FRAGMENT_NODE=11,Ct=O.NOTATION_NODE=12,D={},T={};D.INDEX_SIZE_ERR=(T[1]="Index size error",1);D.DOMSTRING_SIZE_ERR=(T[2]="DOMString size error",2);var C=D.HIERARCHY_REQUEST_ERR=(T[3]="Hierarchy request error",3);D.WRONG_DOCUMENT_ERR=(T[4]="Wrong document",4);D.INVALID_CHARACTER_ERR=(T[5]="Invalid character",5);D.NO_DATA_ALLOWED_ERR=(T[6]="No data allowed",6);D.NO_MODIFICATION_ALLOWED_ERR=(T[7]="No modification allowed",7);var et=D.NOT_FOUND_ERR=(T[8]="Not found",8);D.NOT_SUPPORTED_ERR=(T[9]="Not supported",9);var Pe=D.INUSE_ATTRIBUTE_ERR=(T[10]="Attribute in use",10);D.INVALID_STATE_ERR=(T[11]="Invalid state",11);D.SYNTAX_ERR=(T[12]="Syntax error",12);D.INVALID_MODIFICATION_ERR=(T[13]="Invalid modification",13);D.NAMESPACE_ERR=(T[14]="Invalid namespace",14);D.INVALID_ACCESS_ERR=(T[15]="Invalid access",15);function y(e,t){if(t instanceof Error)var n=t;else n=this,Error.call(this,T[e]),this.message=T[e],Error.captureStackTrace&&Error.captureStackTrace(this,y);return n.code=e,t&&(this.message=this.message+": "+t),n}y.prototype=Error.prototype;te(D,y);function R(){}R.prototype={length:0,item:function(e){return this[e]||null},toString:function(e,t){for(var n=[],r=0;r<this.length;r++)V(this[r],n,e,t);return n.join("")},find:function(e){return Array.prototype.find.call(this,e)},filter:function(e){return Array.prototype.filter.call(this,e)},indexOf:function(e){return Array.prototype.indexOf.call(this,e)}};function H(e,t){this._node=e,this._refresh=t,ye(this)}function ye(e){var t=e._node._inc||e._node.ownerDocument._inc;if(e._inc!=t){var n=e._refresh(e._node);ht(e,"length",n.length),te(n,e),e._inc=t}}H.prototype.item=function(e){return ye(this),this[e]};b(H,R);function se(){}function tt(e,t){for(var n=e.length;n--;)if(e[n]===t)return n}function Ue(e,t,n,r){if(r?t[tt(t,r)]=n:t[t.length++]=n,e){n.ownerElement=e;var i=e.ownerDocument;i&&(r&&it(i,e,r),Rt(i,e,n))}}function Le(e,t,n){var r=tt(t,n);if(r>=0){for(var i=t.length-1;r<i;)t[r]=t[++r];if(t.length=i,e){var a=e.ownerDocument;a&&(it(a,e,n),n.ownerElement=null)}}else throw new y(et,new Error(e.tagName+"@"+n))}se.prototype={length:0,item:R.prototype.item,getNamedItem:function(e){for(var t=this.length;t--;){var n=this[t];if(n.nodeName==e)return n}},setNamedItem:function(e){var t=e.ownerElement;if(t&&t!=this._ownerElement)throw new y(Pe);var n=this.getNamedItem(e.nodeName);return Ue(this._ownerElement,this,e,n),n},setNamedItemNS:function(e){var t=e.ownerElement,n;if(t&&t!=this._ownerElement)throw new y(Pe);return n=this.getNamedItemNS(e.namespaceURI,e.localName),Ue(this._ownerElement,this,e,n),n},removeNamedItem:function(e){var t=this.getNamedItem(e);return Le(this._ownerElement,this,t),t},removeNamedItemNS:function(e,t){var n=this.getNamedItemNS(e,t);return Le(this._ownerElement,this,n),n},getNamedItemNS:function(e,t){for(var n=this.length;n--;){var r=this[n];if(r.localName==t&&r.namespaceURI==e)return r}return null}};function nt(){}nt.prototype={hasFeature:function(e,t){return!0},createDocument:function(e,t,n){var r=new ne;if(r.implementation=this,r.childNodes=new R,r.doctype=n||null,n&&r.appendChild(n),t){var i=r.createElementNS(e,t);r.appendChild(i)}return r},createDocumentType:function(e,t,n){var r=new le;return r.name=e,r.nodeName=e,r.publicId=t||"",r.systemId=n||"",r}};function p(){}p.prototype={firstChild:null,lastChild:null,previousSibling:null,nextSibling:null,attributes:null,parentNode:null,childNodes:null,ownerDocument:null,nodeValue:null,namespaceURI:null,prefix:null,localName:null,insertBefore:function(e,t){return ut(this,e,t)},replaceChild:function(e,t){this.insertBefore(e,t),t&&this.removeChild(t)},removeChild:function(e){return at(this,e)},appendChild:function(e){return this.insertBefore(e,null)},hasChildNodes:function(){return this.firstChild!=null},cloneNode:function(e){return Ne(this.ownerDocument||this,this,e)},normalize:function(){for(var e=this.firstChild;e;){var t=e.nextSibling;t&&t.nodeType==ue&&e.nodeType==ue?(this.removeChild(t),e.appendData(t.data)):(e.normalize(),e=t)}},isSupported:function(e,t){return this.ownerDocument.implementation.hasFeature(e,t)},hasAttributes:function(){return this.attributes.length>0},lookupPrefix:function(e){for(var t=this;t;){var n=t._nsMap;if(n){for(var r in n)if(Object.prototype.hasOwnProperty.call(n,r)&&n[r]===e)return r}t=t.nodeType==Y?t.ownerDocument:t.parentNode}return null},lookupNamespaceURI:function(e){for(var t=this;t;){var n=t._nsMap;if(n&&Object.prototype.hasOwnProperty.call(n,e))return n[e];t=t.nodeType==Y?t.ownerDocument:t.parentNode}return null},isDefaultNamespace:function(e){var t=this.lookupPrefix(e);return t==null}};function rt(e){return e=="<"&&"&lt;"||e==">"&&"&gt;"||e=="&"&&"&amp;"||e=='"'&&"&quot;"||"&#"+e.charCodeAt()+";"}te(O,p);te(O,p.prototype);function J(e,t){if(t(e))return!0;if(e=e.firstChild)do if(J(e,t))return!0;while(e=e.nextSibling)}function ne(){}function Rt(e,t,n){e&&e._inc++;var r=n.namespaceURI;r===K.XMLNS&&(t._nsMap[n.prefix?n.localName:""]=n.value)}function it(e,t,n,r){e&&e._inc++;var i=n.namespaceURI;i===K.XMLNS&&delete t._nsMap[n.prefix?n.localName:""]}function De(e,t,n){if(e&&e._inc){e._inc++;var r=t.childNodes;if(n)r[r.length++]=n;else{for(var i=t.firstChild,a=0;i;)r[a++]=i,i=i.nextSibling;r.length=a,delete r[r.length]}}}function at(e,t){var n=t.previousSibling,r=t.nextSibling;return n?n.nextSibling=r:e.firstChild=r,r?r.previousSibling=n:e.lastChild=n,t.parentNode=null,t.previousSibling=null,t.nextSibling=null,De(e.ownerDocument,e),t}function Mt(e){return e&&(e.nodeType===p.DOCUMENT_NODE||e.nodeType===p.DOCUMENT_FRAGMENT_NODE||e.nodeType===p.ELEMENT_NODE)}function Pt(e){return e&&(j(e)||ot(e)||G(e)||e.nodeType===p.DOCUMENT_FRAGMENT_NODE||e.nodeType===p.COMMENT_NODE||e.nodeType===p.PROCESSING_INSTRUCTION_NODE)}function G(e){return e&&e.nodeType===p.DOCUMENT_TYPE_NODE}function j(e){return e&&e.nodeType===p.ELEMENT_NODE}function ot(e){return e&&e.nodeType===p.TEXT_NODE}function ke(e,t){var n=e.childNodes||[];if(n.find(j)||G(t))return!1;var r=n.find(G);return!(t&&r&&n.indexOf(r)>n.indexOf(t))}function ut(e,t,n){if(!Mt(e))throw new y(C,"Unexpected parent node type "+e.nodeType);if(n&&n.parentNode!==e)throw new y(et,"child not in parent");if(!Pt(t)||G(t)&&e.nodeType!==p.DOCUMENT_NODE)throw new y(C,"Unexpected node type "+t.nodeType+" for parent node type "+e.nodeType);var r=e.childNodes||[],i=t.childNodes||[];if(e.nodeType===p.DOCUMENT_NODE){if(t.nodeType===p.DOCUMENT_FRAGMENT_NODE){let c=i.filter(j);if(c.length>1||i.find(ot))throw new y(C,"More than one element or text in fragment");if(c.length===1&&!ke(e,n))throw new y(C,"Element in fragment can not be inserted before doctype")}if(j(t)&&(r.find(j)||!ke(e,n)))throw new y(C,"Only one element can be added and only after doctype");if(G(t)){if(r.find(G))throw new y(C,"Only one doctype is allowed");let c=r.find(j);if(n&&r.indexOf(c)<r.indexOf(n))throw new y(C,"Doctype can only be inserted before an element");if(!n&&c)throw new y(C,"Doctype can not be appended since element is present")}}var a=t.parentNode;if(a&&a.removeChild(t),t.nodeType===M){var o=t.firstChild;if(o==null)return t;var s=t.lastChild}else o=s=t;var u=n?n.previousSibling:e.lastChild;o.previousSibling=u,s.nextSibling=n,u?u.nextSibling=o:e.firstChild=o,n==null?e.lastChild=s:n.previousSibling=s;do o.parentNode=e;while(o!==s&&(o=o.nextSibling));return De(e.ownerDocument||e,e),t.nodeType==M&&(t.firstChild=t.lastChild=null),t}function Ut(e,t){return t.parentNode&&t.parentNode.removeChild(t),t.parentNode=e,t.previousSibling=e.lastChild,t.nextSibling=null,t.previousSibling?t.previousSibling.nextSibling=t:e.firstChild=t,e.lastChild=t,De(e.ownerDocument,e,t),t}ne.prototype={nodeName:"#document",nodeType:Ke,doctype:null,documentElement:null,_inc:1,insertBefore:function(e,t){if(e.nodeType==M){for(var n=e.firstChild;n;){var r=n.nextSibling;this.insertBefore(n,t),n=r}return e}return ut(this,e,t),e.ownerDocument=this,this.documentElement===null&&e.nodeType===S&&(this.documentElement=e),e},removeChild:function(e){return this.documentElement==e&&(this.documentElement=null),at(this,e)},importNode:function(e,t){return pt(this,e,t)},getElementById:function(e){var t=null;return J(this.documentElement,function(n){if(n.nodeType==S&&n.getAttribute("id")==e)return t=n,!0}),t},getElementsByClassName:function(e){var t=Me(e);return new H(this,function(n){var r=[];return t.length>0&&J(n.documentElement,function(i){if(i!==n&&i.nodeType===S){var a=i.getAttribute("class");if(a){var o=e===a;if(!o){var s=Me(a);o=t.every(It(s))}o&&r.push(i)}}}),r})},createElement:function(e){var t=new k;t.ownerDocument=this,t.nodeName=e,t.tagName=e,t.localName=e,t.childNodes=new R;var n=t.attributes=new se;return n._ownerElement=t,t},createDocumentFragment:function(){var e=new fe;return e.ownerDocument=this,e.childNodes=new R,e},createTextNode:function(e){var t=new we;return t.ownerDocument=this,t.appendData(e),t},createComment:function(e){var t=new _e;return t.ownerDocument=this,t.appendData(e),t},createCDATASection:function(e){var t=new be;return t.ownerDocument=this,t.appendData(e),t},createProcessingInstruction:function(e,t){var n=new Ae;return n.ownerDocument=this,n.tagName=n.target=e,n.nodeValue=n.data=t,n},createAttribute:function(e){var t=new ce;return t.ownerDocument=this,t.name=e,t.nodeName=e,t.localName=e,t.specified=!0,t},createEntityReference:function(e){var t=new Oe;return t.ownerDocument=this,t.nodeName=e,t},createElementNS:function(e,t){var n=new k,r=t.split(":"),i=n.attributes=new se;return n.childNodes=new R,n.ownerDocument=this,n.nodeName=t,n.tagName=t,n.namespaceURI=e,r.length==2?(n.prefix=r[0],n.localName=r[1]):n.localName=t,i._ownerElement=n,n},createAttributeNS:function(e,t){var n=new ce,r=t.split(":");return n.ownerDocument=this,n.nodeName=t,n.name=t,n.namespaceURI=e,n.specified=!0,r.length==2?(n.prefix=r[0],n.localName=r[1]):n.localName=t,n}};b(ne,p);function k(){this._nsMap={}}k.prototype={nodeType:S,hasAttribute:function(e){return this.getAttributeNode(e)!=null},getAttribute:function(e){var t=this.getAttributeNode(e);return t&&t.value||""},getAttributeNode:function(e){return this.attributes.getNamedItem(e)},setAttribute:function(e,t){var n=this.ownerDocument.createAttribute(e);n.value=n.nodeValue=""+t,this.setAttributeNode(n)},removeAttribute:function(e){var t=this.getAttributeNode(e);t&&this.removeAttributeNode(t)},appendChild:function(e){return e.nodeType===M?this.insertBefore(e,null):Ut(this,e)},setAttributeNode:function(e){return this.attributes.setNamedItem(e)},setAttributeNodeNS:function(e){return this.attributes.setNamedItemNS(e)},removeAttributeNode:function(e){return this.attributes.removeNamedItem(e.nodeName)},removeAttributeNS:function(e,t){var n=this.getAttributeNodeNS(e,t);n&&this.removeAttributeNode(n)},hasAttributeNS:function(e,t){return this.getAttributeNodeNS(e,t)!=null},getAttributeNS:function(e,t){var n=this.getAttributeNodeNS(e,t);return n&&n.value||""},setAttributeNS:function(e,t,n){var r=this.ownerDocument.createAttributeNS(e,t);r.value=r.nodeValue=""+n,this.setAttributeNode(r)},getAttributeNodeNS:function(e,t){return this.attributes.getNamedItemNS(e,t)},getElementsByTagName:function(e){return new H(this,function(t){var n=[];return J(t,function(r){r!==t&&r.nodeType==S&&(e==="*"||r.tagName==e)&&n.push(r)}),n})},getElementsByTagNameNS:function(e,t){return new H(this,function(n){var r=[];return J(n,function(i){i!==n&&i.nodeType===S&&(e==="*"||i.namespaceURI===e)&&(t==="*"||i.localName==t)&&r.push(i)}),r})}};ne.prototype.getElementsByTagName=k.prototype.getElementsByTagName;ne.prototype.getElementsByTagNameNS=k.prototype.getElementsByTagNameNS;b(k,p);function ce(){}ce.prototype.nodeType=Y;b(ce,p);function re(){}re.prototype={data:"",substringData:function(e,t){return this.data.substring(e,e+t)},appendData:function(e){e=this.data+e,this.nodeValue=this.data=e,this.length=e.length},insertData:function(e,t){this.replaceData(e,0,t)},appendChild:function(e){throw new Error(T[C])},deleteData:function(e,t){this.replaceData(e,t,"")},replaceData:function(e,t,n){var r=this.data.substring(0,e),i=this.data.substring(e+t);n=r+n+i,this.nodeValue=this.data=n,this.length=n.length}};b(re,p);function we(){}we.prototype={nodeName:"#text",nodeType:ue,splitText:function(e){var t=this.data,n=t.substring(e);t=t.substring(0,e),this.data=this.nodeValue=t,this.length=t.length;var r=this.ownerDocument.createTextNode(n);return this.parentNode&&this.parentNode.insertBefore(r,this.nextSibling),r}};b(we,re);function _e(){}_e.prototype={nodeName:"#comment",nodeType:Ze};b(_e,re);function be(){}be.prototype={nodeName:"#cdata-section",nodeType:Be};b(be,re);function le(){}le.prototype.nodeType=Je;b(le,p);function st(){}st.prototype.nodeType=Ct;b(st,p);function ct(){}ct.prototype.nodeType=St;b(ct,p);function Oe(){}Oe.prototype.nodeType=Qe;b(Oe,p);function fe(){}fe.prototype.nodeName="#document-fragment";fe.prototype.nodeType=M;b(fe,p);function Ae(){}Ae.prototype.nodeType=We;b(Ae,p);function lt(){}lt.prototype.serializeToString=function(e,t,n){return ft.call(e,t,n)};p.prototype.toString=ft;function ft(e,t){var n=[],r=this.nodeType==9&&this.documentElement||this,i=r.prefix,a=r.namespaceURI;if(a&&i==null){var i=r.lookupPrefix(a);if(i==null)var o=[{namespace:a,prefix:null}]}return V(this,n,e,t,o),n.join("")}function $e(e,t,n){var r=e.prefix||"",i=e.namespaceURI;if(!i||r==="xml"&&i===K.XML||i===K.XMLNS)return!1;for(var a=n.length;a--;){var o=n[a];if(o.prefix===r)return o.namespace!==i}return!0}function Ee(e,t,n){e.push(" ",t,'="',n.replace(/[<>&"\t\n\r]/g,rt),'"')}function V(e,t,n,r,i){if(i||(i=[]),r)if(e=r(e),e){if(typeof e=="string"){t.push(e);return}}else return;switch(e.nodeType){case S:var a=e.attributes,o=a.length,d=e.firstChild,s=e.tagName;n=K.isHTML(e.namespaceURI)||n;var u=s;if(!n&&!e.prefix&&e.namespaceURI){for(var c,l=0;l<a.length;l++)if(a.item(l).name==="xmlns"){c=a.item(l).value;break}if(!c)for(var h=i.length-1;h>=0;h--){var f=i[h];if(f.prefix===""&&f.namespace===e.namespaceURI){c=f.namespace;break}}if(c!==e.namespaceURI)for(var h=i.length-1;h>=0;h--){var f=i[h];if(f.namespace===e.namespaceURI){f.prefix&&(u=f.prefix+":"+s);break}}}t.push("<",u);for(var N=0;N<o;N++){var _=a.item(N);_.prefix=="xmlns"?i.push({prefix:_.localName,namespace:_.value}):_.nodeName=="xmlns"&&i.push({prefix:"",namespace:_.value})}for(var N=0;N<o;N++){var _=a.item(N);if($e(_,n,i)){var E=_.prefix||"",m=_.namespaceURI;Ee(t,E?"xmlns:"+E:"xmlns",m),i.push({prefix:E,namespace:m})}V(_,t,n,r,i)}if(s===u&&$e(e,n,i)){var E=e.prefix||"",m=e.namespaceURI;Ee(t,E?"xmlns:"+E:"xmlns",m),i.push({prefix:E,namespace:m})}if(d||n&&!/^(?:meta|link|img|br|hr|input)$/i.test(s)){if(t.push(">"),n&&/^script$/i.test(s))for(;d;)d.data?t.push(d.data):V(d,t,n,r,i.slice()),d=d.nextSibling;else for(;d;)V(d,t,n,r,i.slice()),d=d.nextSibling;t.push("</",u,">")}else t.push("/>");return;case Ke:case M:for(var d=e.firstChild;d;)V(d,t,n,r,i.slice()),d=d.nextSibling;return;case Y:return Ee(t,e.name,e.value);case ue:return t.push(e.data.replace(/[<&>]/g,rt));case Be:return t.push("<![CDATA[",e.data,"]]>");case Ze:return t.push("<!--",e.data,"-->");case Je:var B=e.publicId,g=e.systemId;if(t.push("<!DOCTYPE ",e.name),B)t.push(" PUBLIC ",B),g&&g!="."&&t.push(" ",g),t.push(">");else if(g&&g!=".")t.push(" SYSTEM ",g,">");else{var x=e.internalSubset;x&&t.push(" [",x,"]"),t.push(">")}return;case We:return t.push("<?",e.target," ",e.data,"?>");case Qe:return t.push("&",e.nodeName,";");default:t.push("??",e.nodeName)}}function pt(e,t,n){var r;switch(t.nodeType){case S:r=t.cloneNode(!1),r.ownerDocument=e;case M:break;case Y:n=!0;break}if(r||(r=t.cloneNode(!1)),r.ownerDocument=e,r.parentNode=null,n)for(var i=t.firstChild;i;)r.appendChild(pt(e,i,n)),i=i.nextSibling;return r}function Ne(e,t,n){var r=new t.constructor;for(var i in t)if(Object.prototype.hasOwnProperty.call(t,i)){var a=t[i];typeof a!="object"&&a!=r[i]&&(r[i]=a)}switch(t.childNodes&&(r.childNodes=new R),r.ownerDocument=e,r.nodeType){case S:var o=t.attributes,s=r.attributes=new se,u=o.length;s._ownerElement=r;for(var c=0;c<u;c++)r.setAttributeNode(Ne(e,o.item(c),!0));break;case Y:n=!0}if(n)for(var l=t.firstChild;l;)r.appendChild(Ne(e,l,n)),l=l.nextSibling;return r}function ht(e,t,n){e[t]=n}try{if(Object.defineProperty){let e=function(t){switch(t.nodeType){case S:case M:var n=[];for(t=t.firstChild;t;)t.nodeType!==7&&t.nodeType!==8&&n.push(e(t)),t=t.nextSibling;return n.join("");default:return t.nodeValue}};Object.defineProperty(H.prototype,"length",{get:function(){return ye(this),this.$$length}}),Object.defineProperty(p.prototype,"textContent",{get:function(){return e(this)},set:function(t){switch(this.nodeType){case S:case M:for(;this.firstChild;)this.removeChild(this.firstChild);(t||String(t))&&this.appendChild(this.ownerDocument.createTextNode(t));break;default:this.data=t,this.value=t,this.nodeValue=t}}}),ht=function(t,n,r){t["$$"+n]=r}}}catch{}U.DocumentType=le;U.DOMException=y;U.DOMImplementation=nt;U.Element=k;U.Node=p;U.NodeList=R;U.XMLSerializer=lt;var pe={},mt={};(function(e){var t=L.freeze;e.XML_ENTITIES=t({amp:"&",apos:"'",gt:">",lt:"<",quot:'"'}),e.HTML_ENTITIES=t({lt:"<",gt:">",amp:"&",quot:'"',apos:"'",Agrave:"À",Aacute:"Á",Acirc:"Â",Atilde:"Ã",Auml:"Ä",Aring:"Å",AElig:"Æ",Ccedil:"Ç",Egrave:"È",Eacute:"É",Ecirc:"Ê",Euml:"Ë",Igrave:"Ì",Iacute:"Í",Icirc:"Î",Iuml:"Ï",ETH:"Ð",Ntilde:"Ñ",Ograve:"Ò",Oacute:"Ó",Ocirc:"Ô",Otilde:"Õ",Ouml:"Ö",Oslash:"Ø",Ugrave:"Ù",Uacute:"Ú",Ucirc:"Û",Uuml:"Ü",Yacute:"Ý",THORN:"Þ",szlig:"ß",agrave:"à",aacute:"á",acirc:"â",atilde:"ã",auml:"ä",aring:"å",aelig:"æ",ccedil:"ç",egrave:"è",eacute:"é",ecirc:"ê",euml:"ë",igrave:"ì",iacute:"í",icirc:"î",iuml:"ï",eth:"ð",ntilde:"ñ",ograve:"ò",oacute:"ó",ocirc:"ô",otilde:"õ",ouml:"ö",oslash:"ø",ugrave:"ù",uacute:"ú",ucirc:"û",uuml:"ü",yacute:"ý",thorn:"þ",yuml:"ÿ",nbsp:" ",iexcl:"¡",cent:"¢",pound:"£",curren:"¤",yen:"¥",brvbar:"¦",sect:"§",uml:"¨",copy:"©",ordf:"ª",laquo:"«",not:"¬",shy:"­­",reg:"®",macr:"¯",deg:"°",plusmn:"±",sup2:"²",sup3:"³",acute:"´",micro:"µ",para:"¶",middot:"·",cedil:"¸",sup1:"¹",ordm:"º",raquo:"»",frac14:"¼",frac12:"½",frac34:"¾",iquest:"¿",times:"×",divide:"÷",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪",int:"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",fnof:"ƒ",circ:"ˆ",tilde:"˜",ensp:" ",emsp:" ",thinsp:" ",zwnj:"‌",zwj:"‍",lrm:"‎",rlm:"‏",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",bull:"•",hellip:"…",permil:"‰",prime:"′",Prime:"″",lsaquo:"‹",rsaquo:"›",oline:"‾",euro:"€",trade:"™",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦"}),e.entityMap=e.HTML_ENTITIES})(mt);var xe={},ee=L.NAMESPACE,de=/[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,Xe=new RegExp("[\\-\\.0-9"+de.source.slice(1,-1)+"\\u00B7\\u0300-\\u036F\\u203F-\\u2040]"),ze=new RegExp("^"+de.source+Xe.source+"*(?::"+de.source+Xe.source+"*)?$"),Q=0,P=1,$=2,W=3,X=4,z=5,Z=6,ae=7;function q(e,t){this.message=e,this.locator=t,Error.captureStackTrace&&Error.captureStackTrace(this,q)}q.prototype=new Error;q.prototype.name=q.name;function vt(){}vt.prototype={parse:function(e,t,n){var r=this.domBuilder;r.startDocument(),Et(t,t={}),Lt(e,t,n,r,this.errorHandler),r.endDocument()}};function Lt(e,t,n,r,i){function a(v){if(v>65535){v-=65536;var I=55296+(v>>10),wt=56320+(v&1023);return String.fromCharCode(I,wt)}else return String.fromCharCode(v)}function o(v){var I=v.slice(1,-1);return Object.hasOwnProperty.call(n,I)?n[I]:I.charAt(0)==="#"?a(parseInt(I.substr(1).replace("x","0x"))):(i.error("entity not found:"+v),v)}function s(v){if(v>E){var I=e.substring(E,v).replace(/&#?\w+;/g,o);f&&u(E),r.characters(I,0,v-E),E=v}}function u(v,I){for(;v>=l&&(I=h.exec(e));)c=I.index,l=c+I[0].length,f.lineNumber++;f.columnNumber=v-c+1}for(var c=0,l=0,h=/.*(?:\r\n?|\n)|.*$/g,f=r.locator,N=[{currentNSMap:t}],_={},E=0;;){try{var m=e.indexOf("<",E);if(m<0){if(!e.substr(E).match(/^\s*$/)){var d=r.doc,B=d.createTextNode(e.substr(E));d.appendChild(B),r.currentElement=B}return}switch(m>E&&s(m),e.charAt(m+1)){case"/":var w=e.indexOf(">",m+3),g=e.substring(m+2,w).replace(/[ \t\n\r]+$/g,""),x=N.pop();w<0?(g=e.substring(m+2).replace(/[\s<].*/,""),i.error("end tag name: "+g+" is not complete:"+x.tagName),w=m+1+g.length):g.match(/\s</)&&(g=g.replace(/[\s<].*/,""),i.error("end tag name: "+g+" maybe not complete"),w=m+1+g.length);var he=x.localNSMap,Ie=x.tagName==g,yt=Ie||x.tagName&&x.tagName.toLowerCase()==g.toLowerCase();if(yt){if(r.endElement(x.uri,x.localName,g),he)for(var Se in he)Object.prototype.hasOwnProperty.call(he,Se)&&r.endPrefixMapping(Se);Ie||i.fatalError("end tag name: "+g+" is not match the current start tagName:"+x.tagName)}else N.push(x);w++;break;case"?":f&&u(m),w=Ft(e,m,r);break;case"!":f&&u(m),w=zt(e,m,r,i);break;default:f&&u(m);var A=new Nt,me=N[N.length-1].currentNSMap,w=kt(e,m,A,me,o,i),Ce=A.length;if(!A.closed&&Xt(e,w,A.tagName,_)&&(A.closed=!0,n.nbsp||i.warning("unclosed xml attribute")),f&&Ce){for(var Dt=Fe(f,{}),ve=0;ve<Ce;ve++){var Re=A[ve];u(Re.offset),Re.locator=Fe(f,{})}r.locator=Dt,je(A,r,me)&&N.push(A),r.locator=f}else je(A,r,me)&&N.push(A);ee.isHTML(A.uri)&&!A.closed?w=$t(e,w,A.tagName,o,r):w++}}catch(v){if(v instanceof q)throw v;i.error("element parse error: "+v),w=-1}w>E?E=w:s(Math.max(m,E)+1)}}function Fe(e,t){return t.lineNumber=e.lineNumber,t.columnNumber=e.columnNumber,t}function kt(e,t,n,r,i,a){function o(f,N,_){n.attributeNames.hasOwnProperty(f)&&a.fatalError("Attribute "+f+" redefined"),n.addValue(f,N.replace(/[\t\n\r]/g," ").replace(/&#?\w+;/g,i),_)}for(var s,u,c=++t,l=Q;;){var h=e.charAt(c);switch(h){case"=":if(l===P)s=e.slice(t,c),l=W;else if(l===$)l=W;else throw new Error("attribute equal must after attrName");break;case"'":case'"':if(l===W||l===P)if(l===P&&(a.warning('attribute value must after "="'),s=e.slice(t,c)),t=c+1,c=e.indexOf(h,t),c>0)u=e.slice(t,c),o(s,u,t-1),l=z;else throw new Error("attribute value no end '"+h+"' match");else if(l==X)u=e.slice(t,c),o(s,u,t),a.warning('attribute "'+s+'" missed start quot('+h+")!!"),t=c+1,l=z;else throw new Error('attribute value must after "="');break;case"/":switch(l){case Q:n.setTagName(e.slice(t,c));case z:case Z:case ae:l=ae,n.closed=!0;case X:case P:case $:break;default:throw new Error("attribute invalid close char('/')")}break;case"":return a.error("unexpected end of input"),l==Q&&n.setTagName(e.slice(t,c)),c;case">":switch(l){case Q:n.setTagName(e.slice(t,c));case z:case Z:case ae:break;case X:case P:u=e.slice(t,c),u.slice(-1)==="/"&&(n.closed=!0,u=u.slice(0,-1));case $:l===$&&(u=s),l==X?(a.warning('attribute "'+u+'" missed quot(")!'),o(s,u,t)):((!ee.isHTML(r[""])||!u.match(/^(?:disabled|checked|selected)$/i))&&a.warning('attribute "'+u+'" missed value!! "'+u+'" instead!!'),o(u,u,t));break;case W:throw new Error("attribute value missed!!")}return c;case"€":h=" ";default:if(h<=" ")switch(l){case Q:n.setTagName(e.slice(t,c)),l=Z;break;case P:s=e.slice(t,c),l=$;break;case X:var u=e.slice(t,c);a.warning('attribute "'+u+'" missed quot(")!!'),o(s,u,t);case z:l=Z;break}else switch(l){case $:n.tagName,(!ee.isHTML(r[""])||!s.match(/^(?:disabled|checked|selected)$/i))&&a.warning('attribute "'+s+'" missed value!! "'+s+'" instead2!!'),o(s,s,t),t=c,l=P;break;case z:a.warning('attribute space is required"'+s+'"!!');case Z:l=P,t=c;break;case W:l=X,t=c;break;case ae:throw new Error("elements closed character '/' and '>' must be connected to")}}c++}}function je(e,t,n){for(var r=e.tagName,i=null,h=e.length;h--;){var a=e[h],o=a.qName,s=a.value,f=o.indexOf(":");if(f>0)var u=a.prefix=o.slice(0,f),c=o.slice(f+1),l=u==="xmlns"&&c;else c=o,u=null,l=o==="xmlns"&&"";a.localName=c,l!==!1&&(i==null&&(i={},Et(n,n={})),n[l]=i[l]=s,a.uri=ee.XMLNS,t.startPrefixMapping(l,s))}for(var h=e.length;h--;){a=e[h];var u=a.prefix;u&&(u==="xml"&&(a.uri=ee.XML),u!=="xmlns"&&(a.uri=n[u||""]))}var f=r.indexOf(":");f>0?(u=e.prefix=r.slice(0,f),c=e.localName=r.slice(f+1)):(u=null,c=e.localName=r);var N=e.uri=n[u||""];if(t.startElement(N,c,r,e),e.closed){if(t.endElement(N,c,r),i)for(u in i)Object.prototype.hasOwnProperty.call(i,u)&&t.endPrefixMapping(u)}else return e.currentNSMap=n,e.localNSMap=i,!0}function $t(e,t,n,r,i){if(/^(?:script|textarea)$/i.test(n)){var a=e.indexOf("</"+n+">",t),o=e.substring(t+1,a);if(/[&<]/.test(o))return/^script$/i.test(n)?(i.characters(o,0,o.length),a):(o=o.replace(/&#?\w+;/g,r),i.characters(o,0,o.length),a)}return t+1}function Xt(e,t,n,r){var i=r[n];return i==null&&(i=e.lastIndexOf("</"+n+">"),i<t&&(i=e.lastIndexOf("</"+n)),r[n]=i),i<t}function Et(e,t){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])}function zt(e,t,n,r){var i=e.charAt(t+2);switch(i){case"-":if(e.charAt(t+3)==="-"){var a=e.indexOf("-->",t+4);return a>t?(n.comment(e,t+4,a-t-4),a+3):(r.error("Unclosed comment"),-1)}else return-1;default:if(e.substr(t+3,6)=="CDATA["){var a=e.indexOf("]]>",t+9);return n.startCDATA(),n.characters(e,t+9,a-t-9),n.endCDATA(),a+3}var o=jt(e,t),s=o.length;if(s>1&&/!doctype/i.test(o[0][0])){var u=o[1][0],c=!1,l=!1;s>3&&(/^public$/i.test(o[2][0])?(c=o[3][0],l=s>4&&o[4][0]):/^system$/i.test(o[2][0])&&(l=o[3][0]));var h=o[s-1];return n.startDTD(u,c,l),n.endDTD(),h.index+h[0].length}}return-1}function Ft(e,t,n){var r=e.indexOf("?>",t);if(r){var i=e.substring(t,r).match(/^<\?(\S*)\s*([\s\S]*?)\s*$/);return i?(i[0].length,n.processingInstruction(i[1],i[2]),r+2):-1}return-1}function Nt(){this.attributeNames={}}Nt.prototype={setTagName:function(e){if(!ze.test(e))throw new Error("invalid tagName:"+e);this.tagName=e},addValue:function(e,t,n){if(!ze.test(e))throw new Error("invalid attribute:"+e);this.attributeNames[e]=this.length,this[this.length++]={qName:e,value:t,offset:n}},length:0,getLocalName:function(e){return this[e].localName},getLocator:function(e){return this[e].locator},getQName:function(e){return this[e].qName},getURI:function(e){return this[e].uri},getValue:function(e){return this[e].value}};function jt(e,t){var n,r=[],i=/'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g;for(i.lastIndex=t,i.exec(e);n=i.exec(e);)if(r.push(n),n[1])return r}xe.XMLReader=vt;xe.ParseError=q;var Vt=L,Gt=U,Ve=mt,dt=xe,Yt=Gt.DOMImplementation,Ge=Vt.NAMESPACE,Ht=dt.ParseError,qt=dt.XMLReader;function gt(e){return e.replace(/\r[\n\u0085]/g,`
2
+ `).replace(/[\r\u0085\u2028]/g,`
3
+ `)}function Tt(e){this.options=e||{locator:{}}}Tt.prototype.parseFromString=function(e,t){var n=this.options,r=new qt,i=n.domBuilder||new ie,a=n.errorHandler,o=n.locator,s=n.xmlns||{},u=/\/x?html?$/.test(t),c=u?Ve.HTML_ENTITIES:Ve.XML_ENTITIES;o&&i.setDocumentLocator(o),r.errorHandler=Bt(a,i,o),r.domBuilder=n.domBuilder||i,u&&(s[""]=Ge.HTML),s.xml=s.xml||Ge.XML;var l=n.normalizeLineEndings||gt;return e&&typeof e=="string"?r.parse(l(e),s,c):r.errorHandler.error("invalid doc source"),i.doc};function Bt(e,t,n){if(!e){if(t instanceof ie)return t;e=t}var r={},i=e instanceof Function;n=n||{};function a(o){var s=e[o];!s&&i&&(s=e.length==2?function(u){e(o,u)}:e),r[o]=s&&function(u){s("[xmldom "+o+"] "+u+ge(n))}||function(){}}return a("warning"),a("error"),a("fatalError"),r}function ie(){this.cdata=!1}function F(e,t){t.lineNumber=e.lineNumber,t.columnNumber=e.columnNumber}ie.prototype={startDocument:function(){this.doc=new Yt().createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(e,t,n,r){var i=this.doc,a=i.createElementNS(e,n||t),o=r.length;oe(this,a),this.currentElement=a,this.locator&&F(this.locator,a);for(var s=0;s<o;s++){var e=r.getURI(s),u=r.getValue(s),n=r.getQName(s),c=i.createAttributeNS(e,n);this.locator&&F(r.getLocator(s),c),c.value=c.nodeValue=u,a.setAttributeNode(c)}},endElement:function(e,t,n){var r=this.currentElement;r.tagName,this.currentElement=r.parentNode},startPrefixMapping:function(e,t){},endPrefixMapping:function(e){},processingInstruction:function(e,t){var n=this.doc.createProcessingInstruction(e,t);this.locator&&F(this.locator,n),oe(this,n)},ignorableWhitespace:function(e,t,n){},characters:function(e,t,n){if(e=Ye.apply(this,arguments),e){if(this.cdata)var r=this.doc.createCDATASection(e);else var r=this.doc.createTextNode(e);this.currentElement?this.currentElement.appendChild(r):/^\s*$/.test(e)&&this.doc.appendChild(r),this.locator&&F(this.locator,r)}},skippedEntity:function(e){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(e){(this.locator=e)&&(e.lineNumber=0)},comment:function(e,t,n){e=Ye.apply(this,arguments);var r=this.doc.createComment(e);this.locator&&F(this.locator,r),oe(this,r)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(e,t,n){var r=this.doc.implementation;if(r&&r.createDocumentType){var i=r.createDocumentType(e,t,n);this.locator&&F(this.locator,i),oe(this,i),this.doc.doctype=i}},warning:function(e){console.warn("[xmldom warning] "+e,ge(this.locator))},error:function(e){console.error("[xmldom error] "+e,ge(this.locator))},fatalError:function(e){throw new Ht(e,this.locator)}};function ge(e){if(e)return`
4
+ @`+(e.systemId||"")+"#[line:"+e.lineNumber+",col:"+e.columnNumber+"]"}function Ye(e,t,n){return typeof e=="string"?e.substr(t,n):e.length>=t+n||t?new java.lang.String(e,t,n)+"":e}"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,function(e){ie.prototype[e]=function(){return null}});function oe(e,t){e.currentElement?e.currentElement.appendChild(t):e.doc.appendChild(t)}pe.__DOMHandler=ie;pe.normalizeLineEndings=gt;pe.DOMParser=Tt;var Qt=pe.DOMParser;const Wt=Object.freeze(Object.defineProperty({__proto__:null,DOMParser:Qt},Symbol.toStringTag,{value:"Module"}));exports.index=Wt;
package/dist/index.cjs ADDED
@@ -0,0 +1,54 @@
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const o=require("vue");function Ue(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(r=Ue(e[t]))&&(n&&(n+=" "),n+=r);else for(t in e)e[t]&&(n&&(n+=" "),n+=t);return n}function he(){for(var e,t,r=0,n="";r<arguments.length;)(e=arguments[r++])&&(t=Ue(e))&&(n&&(n+=" "),n+=t);return n}const ze=e=>typeof e=="boolean"?"".concat(e):e===0?"0":e,gt=e=>{const t=function(){for(var l=arguments.length,a=new Array(l),s=0;s<l;s++)a[s]=arguments[s];var i,u;return typeof(e==null||(i=e.hooks)===null||i===void 0?void 0:i["cx:done"])<"u"?e==null?void 0:e.hooks["cx:done"](he(a)):typeof(e==null||(u=e.hooks)===null||u===void 0?void 0:u.onComplete)<"u"?e==null?void 0:e.hooks.onComplete(he(a)):he(a)};return{compose:function(){for(var l=arguments.length,a=new Array(l),s=0;s<l;s++)a[s]=arguments[s];return i=>{const u=Object.fromEntries(Object.entries(i||{}).filter(c=>{let[p]=c;return!["class","className"].includes(p)}));return t(a.map(c=>c(u)),i==null?void 0:i.class,i==null?void 0:i.className)}},cva:l=>a=>{var s;if((l==null?void 0:l.variants)==null)return t(l==null?void 0:l.base,a==null?void 0:a.class,a==null?void 0:a.className);const{variants:i,defaultVariants:u}=l,c=Object.keys(i).map(d=>{const f=a==null?void 0:a[d],g=u==null?void 0:u[d],v=ze(f)||ze(g);return i[d][v]}),p={...u,...a&&Object.entries(a).reduce((d,f)=>{let[g,v]=f;return typeof v>"u"?d:{...d,[g]:v}},{})},m=l==null||(s=l.compoundVariants)===null||s===void 0?void 0:s.reduce((d,f)=>{let{class:g,className:v,...x}=f;return Object.entries(x).every(_=>{let[C,A]=_;const $=p[C];return Array.isArray(A)?A.includes($):$===A})?[...d,g,v]:d},[]);return t(l==null?void 0:l.base,c,m,a==null?void 0:a.class,a==null?void 0:a.className)},cx:t}},Te="-";function ht(e){const t=wt(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;function l(s){const i=s.split(Te);return i[0]===""&&i.length!==1&&i.shift(),Ge(i,t)||bt(s)}function a(s,i){const u=r[s]||[];return i&&n[s]?[...u,...n[s]]:u}return{getClassGroupId:l,getConflictingClassGroupIds:a}}function Ge(e,t){var s;if(e.length===0)return t.classGroupId;const r=e[0],n=t.nextPart.get(r),l=n?Ge(e.slice(1),n):void 0;if(l)return l;if(t.validators.length===0)return;const a=e.join(Te);return(s=t.validators.find(({validator:i})=>i(a)))==null?void 0:s.classGroupId}const je=/^\[(.+)\]$/;function bt(e){if(je.test(e)){const t=je.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}}function wt(e){const{theme:t,prefix:r}=e,n={nextPart:new Map,validators:[]};return xt(Object.entries(e.classGroups),r).forEach(([a,s])=>{ye(s,n,a,t)}),n}function ye(e,t,r,n){e.forEach(l=>{if(typeof l=="string"){const a=l===""?t:Ne(t,l);a.classGroupId=r;return}if(typeof l=="function"){if(yt(l)){ye(l(n),t,r,n);return}t.validators.push({validator:l,classGroupId:r});return}Object.entries(l).forEach(([a,s])=>{ye(s,Ne(t,a),r,n)})})}function Ne(e,t){let r=e;return t.split(Te).forEach(n=>{r.nextPart.has(n)||r.nextPart.set(n,{nextPart:new Map,validators:[]}),r=r.nextPart.get(n)}),r}function yt(e){return e.isThemeGetter}function xt(e,t){return t?e.map(([r,n])=>{const l=n.map(a=>typeof a=="string"?t+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(([s,i])=>[t+s,i])):a);return[r,l]}):e}function St(e){if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,n=new Map;function l(a,s){r.set(a,s),t++,t>e&&(t=0,n=r,r=new Map)}return{get(a){let s=r.get(a);if(s!==void 0)return s;if((s=n.get(a))!==void 0)return l(a,s),s},set(a,s){r.has(a)?r.set(a,s):l(a,s)}}}const qe="!";function Ct(e){const t=e.separator,r=t.length===1,n=t[0],l=t.length;return function(s){const i=[];let u=0,c=0,p;for(let v=0;v<s.length;v++){let x=s[v];if(u===0){if(x===n&&(r||s.slice(v,v+l)===t)){i.push(s.slice(c,v)),c=v+l;continue}if(x==="/"){p=v;continue}}x==="["?u++:x==="]"&&u--}const m=i.length===0?s:s.substring(c),d=m.startsWith(qe),f=d?m.substring(1):m,g=p&&p>c?p-c:void 0;return{modifiers:i,hasImportantModifier:d,baseClassName:f,maybePostfixModifierPosition:g}}}function kt(e){if(e.length<=1)return e;const t=[];let r=[];return e.forEach(n=>{n[0]==="["?(t.push(...r.sort(),n),r=[]):r.push(n)}),t.push(...r.sort()),t}function Et(e){return{cache:St(e.cacheSize),splitModifiers:Ct(e),...ht(e)}}const _t=/\s+/;function Mt(e,t){const{splitModifiers:r,getClassGroupId:n,getConflictingClassGroupIds:l}=t,a=new Set;return e.trim().split(_t).map(s=>{const{modifiers:i,hasImportantModifier:u,baseClassName:c,maybePostfixModifierPosition:p}=r(s);let m=n(p?c.substring(0,p):c),d=!!p;if(!m){if(!p)return{isTailwindClass:!1,originalClassName:s};if(m=n(c),!m)return{isTailwindClass:!1,originalClassName:s};d=!1}const f=kt(i).join(":");return{isTailwindClass:!0,modifierId:u?f+qe:f,classGroupId:m,originalClassName:s,hasPostfixModifier:d}}).reverse().filter(s=>{if(!s.isTailwindClass)return!0;const{modifierId:i,classGroupId:u,hasPostfixModifier:c}=s,p=i+u;return a.has(p)?!1:(a.add(p),l(u,c).forEach(m=>a.add(i+m)),!0)}).reverse().map(s=>s.originalClassName).join(" ")}function Tt(){let e=0,t,r,n="";for(;e<arguments.length;)(t=arguments[e++])&&(r=Ke(t))&&(n&&(n+=" "),n+=r);return n}function Ke(e){if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=Ke(e[n]))&&(r&&(r+=" "),r+=t);return r}function Re(e,...t){let r,n,l,a=s;function s(u){const c=t.reduce((p,m)=>m(p),e());return r=Et(c),n=r.cache.get,l=r.cache.set,a=i,i(u)}function i(u){const c=n(u);if(c)return c;const p=Mt(u,r);return l(u,p),p}return function(){return a(Tt.apply(null,arguments))}}function y(e){const t=r=>r[e]||[];return t.isThemeGetter=!0,t}const Ze=/^\[(?:([a-z-]+):)?(.+)\]$/i,Pt=/^\d+\/\d+$/,Lt=new Set(["px","full","screen"]),At=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Ot=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,$t=/^-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Bt=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/;function P(e){return R(e)||Lt.has(e)||Pt.test(e)}function F(e){return G(e,"length",Vt)}function R(e){return!!e&&!Number.isNaN(Number(e))}function ce(e){return G(e,"number",R)}function Q(e){return!!e&&Number.isInteger(Number(e))}function Ft(e){return e.endsWith("%")&&R(e.slice(0,-1))}function h(e){return Ze.test(e)}function z(e){return At.test(e)}const zt=new Set(["length","size","percentage"]);function jt(e){return G(e,zt,Xe)}function Nt(e){return G(e,"position",Xe)}const Rt=new Set(["image","url"]);function Dt(e){return G(e,Rt,Wt)}function It(e){return G(e,"",Ht)}function ee(){return!0}function G(e,t,r){const n=Ze.exec(e);return n?n[1]?typeof t=="string"?n[1]===t:t.has(n[1]):r(n[2]):!1}function Vt(e){return Ot.test(e)}function Xe(){return!1}function Ht(e){return $t.test(e)}function Wt(e){return Bt.test(e)}function De(){const e=y("colors"),t=y("spacing"),r=y("blur"),n=y("brightness"),l=y("borderColor"),a=y("borderRadius"),s=y("borderSpacing"),i=y("borderWidth"),u=y("contrast"),c=y("grayscale"),p=y("hueRotate"),m=y("invert"),d=y("gap"),f=y("gradientColorStops"),g=y("gradientColorStopPositions"),v=y("inset"),x=y("margin"),_=y("opacity"),C=y("padding"),A=y("saturate"),$=y("scale"),ae=y("sepia"),Z=y("skew"),se=y("space"),ie=y("translate"),X=()=>["auto","contain","none"],Y=()=>["auto","hidden","clip","visible","scroll"],J=()=>["auto",h,t],b=()=>[h,t],B=()=>["",P,F],H=()=>["auto",R,h],ue=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],W=()=>["solid","dashed","dotted","double","none"],w=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter"],S=()=>["start","end","center","between","around","evenly","stretch"],E=()=>["","0",h],M=()=>["auto","avoid","all","avoid-page","page","left","right","column"],O=()=>[R,ce],T=()=>[R,h];return{cacheSize:500,separator:":",theme:{colors:[ee],spacing:[P,F],blur:["none","",z,h],brightness:O(),borderColor:[e],borderRadius:["none","","full",z,h],borderSpacing:b(),borderWidth:B(),contrast:O(),grayscale:E(),hueRotate:T(),invert:E(),gap:b(),gradientColorStops:[e],gradientColorStopPositions:[Ft,F],inset:J(),margin:J(),opacity:O(),padding:b(),saturate:O(),scale:O(),sepia:E(),skew:T(),space:b(),translate:b()},classGroups:{aspect:[{aspect:["auto","square","video",h]}],container:["container"],columns:[{columns:[z]}],"break-after":[{"break-after":M()}],"break-before":[{"break-before":M()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none"]}],clear:[{clear:["left","right","both","none"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...ue(),h]}],overflow:[{overflow:Y()}],"overflow-x":[{"overflow-x":Y()}],"overflow-y":[{"overflow-y":Y()}],overscroll:[{overscroll:X()}],"overscroll-x":[{"overscroll-x":X()}],"overscroll-y":[{"overscroll-y":X()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[v]}],"inset-x":[{"inset-x":[v]}],"inset-y":[{"inset-y":[v]}],start:[{start:[v]}],end:[{end:[v]}],top:[{top:[v]}],right:[{right:[v]}],bottom:[{bottom:[v]}],left:[{left:[v]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Q,h]}],basis:[{basis:J()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",h]}],grow:[{grow:E()}],shrink:[{shrink:E()}],order:[{order:["first","last","none",Q,h]}],"grid-cols":[{"grid-cols":[ee]}],"col-start-end":[{col:["auto",{span:["full",Q,h]},h]}],"col-start":[{"col-start":H()}],"col-end":[{"col-end":H()}],"grid-rows":[{"grid-rows":[ee]}],"row-start-end":[{row:["auto",{span:[Q,h]},h]}],"row-start":[{"row-start":H()}],"row-end":[{"row-end":H()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",h]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",h]}],gap:[{gap:[d]}],"gap-x":[{"gap-x":[d]}],"gap-y":[{"gap-y":[d]}],"justify-content":[{justify:["normal",...S()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...S(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...S(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[C]}],px:[{px:[C]}],py:[{py:[C]}],ps:[{ps:[C]}],pe:[{pe:[C]}],pt:[{pt:[C]}],pr:[{pr:[C]}],pb:[{pb:[C]}],pl:[{pl:[C]}],m:[{m:[x]}],mx:[{mx:[x]}],my:[{my:[x]}],ms:[{ms:[x]}],me:[{me:[x]}],mt:[{mt:[x]}],mr:[{mr:[x]}],mb:[{mb:[x]}],ml:[{ml:[x]}],"space-x":[{"space-x":[se]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[se]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit",h,t]}],"min-w":[{"min-w":["min","max","fit",h,P]}],"max-w":[{"max-w":["0","none","full","min","max","fit","prose",{screen:[z]},z,h]}],h:[{h:[h,t,"auto","min","max","fit"]}],"min-h":[{"min-h":["min","max","fit",P,h]}],"max-h":[{"max-h":[h,t,"min","max","fit"]}],"font-size":[{text:["base",z,F]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",ce]}],"font-family":[{font:[ee]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",h]}],"line-clamp":[{"line-clamp":["none",R,ce]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",P,h]}],"list-image":[{"list-image":["none",h]}],"list-style-type":[{list:["none","disc","decimal",h]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[_]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[_]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...W(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",P,F]}],"underline-offset":[{"underline-offset":["auto",P,h]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],indent:[{indent:b()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",h]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",h]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[_]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ue(),Nt]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",jt]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Dt]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[g]}],"gradient-via-pos":[{via:[g]}],"gradient-to-pos":[{to:[g]}],"gradient-from":[{from:[f]}],"gradient-via":[{via:[f]}],"gradient-to":[{to:[f]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[i]}],"border-w-x":[{"border-x":[i]}],"border-w-y":[{"border-y":[i]}],"border-w-s":[{"border-s":[i]}],"border-w-e":[{"border-e":[i]}],"border-w-t":[{"border-t":[i]}],"border-w-r":[{"border-r":[i]}],"border-w-b":[{"border-b":[i]}],"border-w-l":[{"border-l":[i]}],"border-opacity":[{"border-opacity":[_]}],"border-style":[{border:[...W(),"hidden"]}],"divide-x":[{"divide-x":[i]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[i]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[_]}],"divide-style":[{divide:W()}],"border-color":[{border:[l]}],"border-color-x":[{"border-x":[l]}],"border-color-y":[{"border-y":[l]}],"border-color-t":[{"border-t":[l]}],"border-color-r":[{"border-r":[l]}],"border-color-b":[{"border-b":[l]}],"border-color-l":[{"border-l":[l]}],"divide-color":[{divide:[l]}],"outline-style":[{outline:["",...W()]}],"outline-offset":[{"outline-offset":[P,h]}],"outline-w":[{outline:[P,F]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:B()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[_]}],"ring-offset-w":[{"ring-offset":[P,F]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",z,It]}],"shadow-color":[{shadow:[ee]}],opacity:[{opacity:[_]}],"mix-blend":[{"mix-blend":w()}],"bg-blend":[{"bg-blend":w()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[n]}],contrast:[{contrast:[u]}],"drop-shadow":[{"drop-shadow":["","none",z,h]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[p]}],invert:[{invert:[m]}],saturate:[{saturate:[A]}],sepia:[{sepia:[ae]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[u]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[p]}],"backdrop-invert":[{"backdrop-invert":[m]}],"backdrop-opacity":[{"backdrop-opacity":[_]}],"backdrop-saturate":[{"backdrop-saturate":[A]}],"backdrop-sepia":[{"backdrop-sepia":[ae]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",h]}],duration:[{duration:T()}],ease:[{ease:["linear","in","out","in-out",h]}],delay:[{delay:T()}],animate:[{animate:["none","spin","ping","pulse","bounce",h]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[$]}],"scale-x":[{"scale-x":[$]}],"scale-y":[{"scale-y":[$]}],rotate:[{rotate:[Q,h]}],"translate-x":[{"translate-x":[ie]}],"translate-y":[{"translate-y":[ie]}],"skew-x":[{"skew-x":[Z]}],"skew-y":[{"skew-y":[Z]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",h]}],accent:[{accent:["auto",e]}],appearance:["appearance-none"],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",h]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":b()}],"scroll-mx":[{"scroll-mx":b()}],"scroll-my":[{"scroll-my":b()}],"scroll-ms":[{"scroll-ms":b()}],"scroll-me":[{"scroll-me":b()}],"scroll-mt":[{"scroll-mt":b()}],"scroll-mr":[{"scroll-mr":b()}],"scroll-mb":[{"scroll-mb":b()}],"scroll-ml":[{"scroll-ml":b()}],"scroll-p":[{"scroll-p":b()}],"scroll-px":[{"scroll-px":b()}],"scroll-py":[{"scroll-py":b()}],"scroll-ps":[{"scroll-ps":b()}],"scroll-pe":[{"scroll-pe":b()}],"scroll-pt":[{"scroll-pt":b()}],"scroll-pr":[{"scroll-pr":b()}],"scroll-pb":[{"scroll-pb":b()}],"scroll-pl":[{"scroll-pl":b()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",h]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[P,F,ce]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}}function Ut(e,{cacheSize:t,prefix:r,separator:n,extend:l={},override:a={}}){fe(e,"cacheSize",t),fe(e,"prefix",r),fe(e,"separator",n);for(const s in a)Gt(e[s],a[s]);for(const s in l)qt(e[s],l[s]);return e}function fe(e,t,r){r!==void 0&&(e[t]=r)}function Gt(e,t){if(t)for(const r in t)fe(e,r,t[r])}function qt(e,t){if(t)for(const r in t){const n=t[r];n!==void 0&&(e[r]=(e[r]||[]).concat(n))}}function Kt(e,...t){return typeof e=="function"?Re(De,e,...t):Re(()=>Ut(De(),e),...t)}const Zt=Kt({}),{cva:Pe,cx:U,compose:Fn}=gt({hooks:{onComplete:e=>Zt(e)}}),Xt={key:0,class:"loader-wrapper"},Yt=o.createStaticVNode('<path class="svg-path svg-check-mark" d="m 0 60 l 30 30 l 70 -80" data-v-0adb214b></path><path class="svg-path svg-x-mark" d="m 50 50 l 40 -40" data-v-0adb214b></path><path class="svg-path svg-x-mark" d="m 50 50 l 40 40" data-v-0adb214b></path><path class="svg-path svg-x-mark" d="m 50 50 l -40 -40" data-v-0adb214b></path><path class="svg-path svg-x-mark" d="m 50 50 l -40 40" data-v-0adb214b></path>',5),Jt={key:0,class:"circular-loader"};function Qt(){return o.reactive({valid:!1,invalid:!1,isLoading:!1,startLoading(){this.isLoading=!0},stopLoading(){this.isLoading=!1},isValid(e=800){this.valid=!0;const t=e-300;return new Promise(r=>setTimeout(()=>this.clear().then(()=>r(!0)),t))},isInvalid(e=1100){this.invalid=!0;const t=e-300;return new Promise(r=>setTimeout(()=>this.clear().then(()=>r(!0)),t))},clear(e=300){return this.valid=!1,this.invalid=!1,this.isLoading=!1,new Promise(t=>{setTimeout(()=>{t(!0)},e)})}})}const er=o.defineComponent({__name:"ScalarLoading",props:{loadingState:{},size:{default:"24px"}},setup(e){return o.useCssVars(t=>({c75a9dda:t.size})),(t,r)=>t.loadingState?(o.openBlock(),o.createElementBlock("div",Xt,[(o.openBlock(),o.createElementBlock("svg",{class:o.normalizeClass(["svg-loader",{"icon-is-valid":t.loadingState.valid,"icon-is-invalid":t.loadingState.invalid}]),viewBox:"0 0 100 100",xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink"},[Yt,t.loadingState.isLoading?(o.openBlock(),o.createElementBlock("g",Jt,[o.createElementVNode("circle",{class:o.normalizeClass(["loader-path",{"loader-path-off":t.loadingState.valid||t.loadingState.invalid}]),cx:"50",cy:"50",fill:"none",r:"20","stroke-width":"2"},null,2)])):o.createCommentVNode("",!0)],2))])):o.createCommentVNode("",!0)}});const Le=(e,t)=>{const r=e.__vccOpts||e;for(const[n,l]of t)r[n]=l;return r},Ae=Le(er,[["__scopeId","data-v-0adb214b"]]),tr=["aria-disabled","aria-label","title"],rr={key:1,class:"ml-2"},nr=Pe({base:"scalar-button row items-center justify-center rounded font-medium",variants:{isDisabled:{true:"bg-background-2 text-color-3 shadow-none"},isFullWidth:{true:"w-full"},isIconOnly:{true:"scalar-button-icon"},size:{md:"h-10 px-6 text-sm"},variant:{solid:["scalar-button-solid","hocus:bg-hover-btn-1 bg-back-btn-1 text-fore-btn-1 shadow-sm active:bg-back-btn-1 active:shadow-none"].join(" "),outlined:["scalar-button-outlined","active:bg-btn-1 hocus:bg-back-2 border border-border bg-transparent text-fore-1"].join(" "),ghost:["scalar-button-ghost","hocus:text-fore-2 bg-transparent text-fore-3 active:text-fore-2"].join(" "),danger:["scalar-button-danger","hocus:brightness-90 bg-error text-white active:brightness-90"].join(" ")}},compoundVariants:[{isDisabled:!0,variant:"ghost",class:"bg-transparent text-ghost"},{isIconOnly:!0,size:"md",class:"h-10 w-10 p-2"}]}),Oe=o.defineComponent({__name:"ScalarButton",props:{isDisabled:{type:Boolean,default:!1},isFullWidth:{type:Boolean,default:!1},loadingState:{},size:{default:"md"},variant:{default:"solid"},title:{}},setup(e){const t=o.useSlots(),r=o.computed(()=>{var l,a,s,i;return(i=(s=(a=(l=t.default)==null?void 0:l.call(t))==null?void 0:a[0])==null?void 0:s.children)==null?void 0:i.trim()}),n=o.computed(()=>!!(t.icon&&!t.default));return(l,a)=>(o.openBlock(),o.createElementBlock("button",{"aria-disabled":l.isDisabled,"aria-label":r.value||l.title,class:o.normalizeClass(o.unref(U)(o.unref(nr)({isFullWidth:l.isFullWidth,isIconOnly:n.value,isDisabled:l.isDisabled,size:l.size,variant:l.variant}),{"pl-9 pr-3":l.loadingState})),title:l.title||r.value,type:"button"},[l.$slots.icon?(o.openBlock(),o.createElementBlock("div",{key:0,class:o.normalizeClass(o.unref(U)({"mr-2":!n.value},"h-4 w-4"))},[o.renderSlot(l.$slots,"icon")],2)):o.createCommentVNode("",!0),o.renderSlot(l.$slots,"default"),l.loadingState?(o.openBlock(),o.createElementBlock("div",rr,[o.createVNode(o.unref(Ae),{loadingState:l.loadingState,size:"20px"},null,8,["loadingState"])])):o.createCommentVNode("",!0)],10,tr))}}),or=e=>Object.fromEntries(Array.from(e).map(t=>[t.name,t.value])),lr=e=>({raw:t})=>{const n=new e().parseFromString(t,"image/svg+xml");if(n.getElementsByTagName("parsererror").length)return;const l=n.documentElement,a=or(l.attributes),{width:s,height:i,...u}=a;return o.h("svg",{...u,innerHTML:l.innerHTML})},ar=o.defineAsyncComponent(async()=>{const e=typeof DOMParser>"u"?(await Promise.resolve().then(()=>require("./index-c8ae42b3.cjs")).then(r=>r.index)).DOMParser:DOMParser,t=lr(e);return t.props={raw:{type:String,required:!0}},t}),sr=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48">
2
+ <path fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="3.429"
3
+ d="M24 1.714v44.572M1.714 24h44.572" />
4
+ </svg>`,ir=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32.5 23.5" fill="currentColor">
5
+ <path d="M11.2 23.5 0 12.3l2.15-2.15 9.05 9.05L30.4 0l2.15 2.15z" />
6
+ </svg>`,ur=`<svg xmlns="http://www.w3.org/2000/svg" fill="none" stroke="currentColor" viewBox="0 0 24 24">
7
+ <path d="m19.5 8.25-7.5 7.5-7.5-7.5" />
8
+ </svg>`,cr=`<svg xmlns="http://www.w3.org/2000/svg" fill="none" stroke="currentColor" viewBox="0 0 24 24">
9
+ <path d="M15.75 19.5 8.25 12l7.5-7.5" />
10
+ </svg>`,dr=`<svg xmlns="http://www.w3.org/2000/svg" fill="none" stroke="currentColor" viewBox="0 0 24 24">
11
+ <path d="m8.25 4.5 7.5 7.5-7.5 7.5" />
12
+ </svg>`,pr=`<svg xmlns="http://www.w3.org/2000/svg" fill="none" stroke="currentColor" viewBox="0 0 24 24">
13
+ <path d="m4.5 15.75 7.5-7.5 7.5 7.5" />
14
+ </svg>`,fr=`<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 14 14">
15
+ <path stroke="currentColor" d="m12.5 1.5-11 11m0-11 11 11" />
16
+ </svg>`,mr=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor">
17
+ <path
18
+ d="M6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z" />
19
+ </svg>`,vr=`<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 1024 1024">
20
+ <path
21
+ d="M512 0a512 512 0 0 0-162 998c26 4 35-11 35-25l-1-95c-128 23-161-32-172-60-6-15-31-61-52-73-18-10-44-33-1-33 40-1 69 37 78 52 46 78 120 56 149 43 5-33 18-56 33-69-114-13-234-56-234-253 0-56 20-101 53-137-5-13-23-65 5-136 0 0 43-13 141 53a487 487 0 0 1 256 0c98-66 141-53 141-53 28 71 10 123 5 136 33 36 53 81 53 137 0 197-120 240-234 253 18 16 35 47 35 95l-1 140c0 14 9 30 35 25A512 512 0 0 0 512 0z" />
22
+ </svg>`,gr=`<svg
23
+ height="24"
24
+ viewBox="0 0 24 24"
25
+ width="24"
26
+ xmlns="http://www.w3.org/2000/svg">
27
+ <path
28
+ d="M24 12a1 1 0 0 0 -1 -1h-3.91a0.51 0.51 0 0 1 -0.49 -0.4 6.83 6.83 0 0 0 -0.94 -2.28 0.5 0.5 0 0 1 0.06 -0.63l2.77 -2.76a1 1 0 1 0 -1.42 -1.42l-2.76 2.77a0.5 0.5 0 0 1 -0.63 0.06 6.83 6.83 0 0 0 -2.28 -0.94 0.5 0.5 0 0 1 -0.4 -0.49V1a1 1 0 0 0 -2 0v3.91a0.51 0.51 0 0 1 -0.4 0.49 6.83 6.83 0 0 0 -2.28 0.94 0.5 0.5 0 0 1 -0.63 -0.06L4.93 3.51a1 1 0 0 0 -1.42 1.42l2.77 2.76a0.5 0.5 0 0 1 0.06 0.63 6.83 6.83 0 0 0 -0.94 2.28 0.5 0.5 0 0 1 -0.49 0.4H1a1 1 0 0 0 0 2h3.91a0.51 0.51 0 0 1 0.49 0.4 6.83 6.83 0 0 0 0.94 2.28 0.5 0.5 0 0 1 -0.06 0.63l-2.77 2.76a1 1 0 1 0 1.42 1.42l2.76 -2.77a0.5 0.5 0 0 1 0.63 -0.06 6.83 6.83 0 0 0 2.28 0.94 0.5 0.5 0 0 1 0.4 0.49V23a1 1 0 0 0 2 0v-3.91a0.51 0.51 0 0 1 0.4 -0.49 6.83 6.83 0 0 0 2.28 -0.94 0.5 0.5 0 0 1 0.63 0.06l2.76 2.77a1 1 0 1 0 1.42 -1.42l-2.77 -2.76a0.5 0.5 0 0 1 -0.06 -0.63 6.83 6.83 0 0 0 0.94 -2.28 0.5 0.5 0 0 1 0.49 -0.4H23a1 1 0 0 0 1 -1Zm-8.74 2.5A5.76 5.76 0 0 1 9.5 8.74a5.66 5.66 0 0 1 0.16 -1.31 0.49 0.49 0 0 1 0.34 -0.36 5.36 5.36 0 0 1 1.8 -0.31 5.47 5.47 0 0 1 5.46 5.46 5.36 5.36 0 0 1 -0.31 1.8 0.49 0.49 0 0 1 -0.35 0.32 5.53 5.53 0 0 1 -1.34 0.16Z"
29
+ fill="currentColor"
30
+ stroke-width="1"></path>
31
+ </svg>`,hr=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 593 593">
32
+ <path fill="currentColor" fill-rule="evenodd"
33
+ d="M347 0c6 0 12 5 12 12v134l94-95c5-5 13-5 17 0l72 72c4 4 5 12 0 16v1l-95 94h134c7 0 12 5 12 12v101c0 7-5 12-12 12H447l95 94c4 5 5 13 0 17l-72 72c-4 4-12 5-16 0h-1l-94-95v134c0 7-5 12-12 12H246c-7 0-12-5-12-12v-70c0-22 9-43 24-59l130-130c14-14 14-37 0-51L259 142a84 84 0 0 1-25-59V12c0-7 5-12 12-12h101ZM138 52h1l219 219c14 14 14 37 0 51L139 542c-4 5-12 5-17 0l-71-70c-4-5-5-12 0-17l95-96H12c-7 0-12-5-12-12V246c0-7 5-12 12-12h134l-95-94c-4-5-4-12 0-17l71-71c4-5 12-5 16 0Z" />
34
+ </svg>`,br=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 662 662">
35
+ <path fill-rule="evenodd" fill="currentColor"
36
+ d="M331 0a331 331 0 1 1 0 662 331 331 0 0 1 0-662Zm148.5 109 .6.9a187 187 0 1 1-297.6-.9 267 267 0 1 0 297 0Z" />
37
+ </svg>`,wr=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 620 620">
38
+ <path fill="currentColor"
39
+ d="M-.653 309.29c-.078 82.272 31.848 159.735 89.739 218.178l.283.283c122.379 121.247 319.824 121.184 440.16-.283 119.967-121.1 119.409-316.933-.998-437.339l-.99-.99C468.681 30.845 390.716-1.017 307.893-.67c-82.83.354-160.443 32.994-218.814 91.79C31.209 149.555-.724 227.025-.653 309.29Zm469.271-160.789.778.778c87.9 87.9 88.325 231.005.707 319.33-77.753 78.46-199.786 87.412-288.959 26.862l198.513-198.513-.007 166.361 83.68-.07v-306.22H157.11l-.008 83.6h160.584L121.994 436.323c-59.347-87.689-50.536-208.59 26.51-286.343C236.34 61.294 379.94 60.67 468.61 148.494Z" />
40
+ </svg>`,yr=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 642 642" fill="currentColor">
41
+ <path
42
+ d="M321 0a321 321 0 1 1 0 642 321 321 0 0 1 0-642Zm51.3 63L321 189.5 269.7 63l1 136.5-95.8-97.2L228 228l-125.7-53.1 97.2 95.8-136.5-1L189.5 321 63 372.3l136.5-1-97.2 95.8 125.7-53-53.1 125.6 95.8-97.2-1 136.5L321 452.5 372.3 579l-1-136.5 95.8 97.2-53-125.7 125.6 53.1-97.2-95.8 136.5 1L452.5 321 579 269.7l-136.5 1 97.2-95.8L414 228l53.1-125.7-95.8 97.2 1-136.5Z" />
43
+ </svg>`,xr=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 620 620" fill="currentColor">
44
+ <path
45
+ d="M529.2 90.8A310 310 0 1 0 90.8 529.2 310 310 0 0 0 529.2 90.8M122.4 498.2c-54.9-55-15.4-183.5 88.2-287 103.6-103.7 232.1-143.2 287-88.3 54.9 54.8 15.4 183.4-88.3 287-103.5 103.6-232 143.1-286.9 88.3m261.8-262.7A104.7 104.7 0 1 1 236 383.7a104.7 104.7 0 0 1 148.2-148.2" />
46
+ </svg>`,Sr=`<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" viewBox="0 0 14 14">
47
+ <path fill="none" stroke="currentColor" d="M14 3.4H0m14 7.2H0" />
48
+ </svg>`,Cr=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" fill="currentColor">
49
+ <path fill-rule="evenodd"
50
+ d="M12.6 11.2h.1l3 3a1 1 0 1 1-1.4 1.5l-3-3a1 1 0 0 1-.1-.1 7 7 0 1 1 1.4-1.4zM7 12A5 5 0 1 0 7 2a5 5 0 0 0 0 10z" />
51
+ </svg>`,Ie=Object.assign({"./Add.svg":sr,"./CheckMark.svg":ir,"./ChevronDown.svg":ur,"./ChevronLeft.svg":cr,"./ChevronRight.svg":dr,"./ChevronUp.svg":pr,"./Close.svg":fr,"./Ellipses.svg":mr,"./GitHub.svg":vr,"./LightDarkModeToggle.svg":gr,"./Logo.svg":hr,"./LogoAPI.svg":br,"./LogoClient.svg":wr,"./LogoMarket.svg":yr,"./LogoSwagger.svg":xr,"./Menu.svg":Sr,"./Search.svg":Cr}),kr=e=>{const t=`./${e}.svg`;return Ie[t]===void 0?(console.warn(`Could not find icon: ${e}`),""):Ie[t]},$e=o.defineComponent({__name:"ScalarIcon",props:{name:{}},setup(e){const t=e,r=o.computed(()=>kr(t.name));return(n,l)=>r.value?(o.openBlock(),o.createBlock(o.unref(ar),{key:0,class:"flow-icon",height:"100%",raw:r.value,width:"100%"},null,8,["raw"])):o.createCommentVNode("",!0)}}),Ye=o.defineComponent({__name:"ScalarIconButton",props:{label:{},icon:{},variant:{default:"ghost"}},setup(e){return(t,r)=>(o.openBlock(),o.createBlock(o.unref(Oe),{title:t.label,variant:t.variant},{icon:o.withCtx(()=>[o.createVNode(o.unref($e),{name:t.icon},null,8,["name"])]),_:1},8,["title","variant"]))}});function V(e,t,...r){if(e in t){let l=t[e];return typeof l=="function"?l(...r):l}let n=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map(l=>`"${l}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,V),n}var xe=(e=>(e[e.None=0]="None",e[e.RenderStrategy=1]="RenderStrategy",e[e.Static=2]="Static",e))(xe||{}),Er=(e=>(e[e.Unmount=0]="Unmount",e[e.Hidden=1]="Hidden",e))(Er||{});function L({visible:e=!0,features:t=0,ourProps:r,theirProps:n,...l}){var a;let s=Qe(n,r),i=Object.assign(l,{props:s});if(e||t&2&&s.static)return be(i);if(t&1){let u=(a=s.unmount)==null||a?0:1;return V(u,{0(){return null},1(){return be({...l,props:{...s,hidden:!0,style:{display:"none"}}})}})}return be(i)}function be({props:e,attrs:t,slots:r,slot:n,name:l}){var a,s;let{as:i,...u}=_r(e,["unmount","static"]),c=(a=r.default)==null?void 0:a.call(r,n),p={};if(n){let m=!1,d=[];for(let[f,g]of Object.entries(n))typeof g=="boolean"&&(m=!0),g===!0&&d.push(f);m&&(p["data-headlessui-state"]=d.join(" "))}if(i==="template"){if(c=Je(c??[]),Object.keys(u).length>0||Object.keys(t).length>0){let[m,...d]=c??[];if(!Mr(m)||d.length>0)throw new Error(['Passing props on "template"!',"",`The current component <${l} /> is rendering a "template".`,"However we need to passthrough the following props:",Object.keys(u).concat(Object.keys(t)).map(v=>v.trim()).filter((v,x,_)=>_.indexOf(v)===x).sort((v,x)=>v.localeCompare(x)).map(v=>` - ${v}`).join(`
52
+ `),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "template".',"Render a single element as the child so that we can forward the props onto that element."].map(v=>` - ${v}`).join(`
53
+ `)].join(`
54
+ `));let f=Qe((s=m.props)!=null?s:{},u),g=o.cloneVNode(m,f);for(let v in f)v.startsWith("on")&&(g.props||(g.props={}),g.props[v]=f[v]);return g}return Array.isArray(c)&&c.length===1?c[0]:c}return o.h(i,Object.assign({},u,p),{default:()=>c})}function Je(e){return e.flatMap(t=>t.type===o.Fragment?Je(t.children):[t])}function Qe(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},r={};for(let n of e)for(let l in n)l.startsWith("on")&&typeof n[l]=="function"?(r[l]!=null||(r[l]=[]),r[l].push(n[l])):t[l]=n[l];if(t.disabled||t["aria-disabled"])return Object.assign(t,Object.fromEntries(Object.keys(r).map(n=>[n,void 0])));for(let n in r)Object.assign(t,{[n](l,...a){let s=r[n];for(let i of s){if(l instanceof Event&&l.defaultPrevented)return;i(l,...a)}}});return t}function _r(e,t=[]){let r=Object.assign({},e);for(let n of t)n in r&&delete r[n];return r}function Mr(e){return e==null?!1:typeof e.type=="string"||typeof e.type=="object"||typeof e.type=="function"}let Tr=0;function Pr(){return++Tr}function q(){return Pr()}var et=(e=>(e.Space=" ",e.Enter="Enter",e.Escape="Escape",e.Backspace="Backspace",e.Delete="Delete",e.ArrowLeft="ArrowLeft",e.ArrowUp="ArrowUp",e.ArrowRight="ArrowRight",e.ArrowDown="ArrowDown",e.Home="Home",e.End="End",e.PageUp="PageUp",e.PageDown="PageDown",e.Tab="Tab",e))(et||{});function k(e){var t;return e==null||e.value==null?null:(t=e.value.$el)!=null?t:e.value}let Lr=Symbol("Context");var ne=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(ne||{});function Ar(){return o.inject(Lr,null)}var Or=Object.defineProperty,$r=(e,t,r)=>t in e?Or(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Ve=(e,t,r)=>($r(e,typeof t!="symbol"?t+"":t,r),r);class Br{constructor(){Ve(this,"current",this.detect()),Ve(this,"currentId",0)}set(t){this.current!==t&&(this.currentId=0,this.current=t)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return this.current==="server"}get isClient(){return this.current==="client"}detect(){return typeof window>"u"||typeof document>"u"?"server":"client"}}let ge=new Br;function K(e){if(ge.isServer)return null;if(e instanceof Node)return e.ownerDocument;if(e!=null&&e.hasOwnProperty("value")){let t=k(e);if(t)return t.ownerDocument}return document}let Se=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(e=>`${e}:not([tabindex='-1'])`).join(",");var j=(e=>(e[e.First=1]="First",e[e.Previous=2]="Previous",e[e.Next=4]="Next",e[e.Last=8]="Last",e[e.WrapAround=16]="WrapAround",e[e.NoScroll=32]="NoScroll",e))(j||{}),tt=(e=>(e[e.Error=0]="Error",e[e.Overflow=1]="Overflow",e[e.Success=2]="Success",e[e.Underflow=3]="Underflow",e))(tt||{}),Fr=(e=>(e[e.Previous=-1]="Previous",e[e.Next=1]="Next",e))(Fr||{});function zr(e=document.body){return e==null?[]:Array.from(e.querySelectorAll(Se)).sort((t,r)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(r.tabIndex||Number.MAX_SAFE_INTEGER)))}var rt=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(rt||{});function jr(e,t=0){var r;return e===((r=K(e))==null?void 0:r.body)?!1:V(t,{0(){return e.matches(Se)},1(){let n=e;for(;n!==null;){if(n.matches(Se))return!0;n=n.parentElement}return!1}})}var Nr=(e=>(e[e.Keyboard=0]="Keyboard",e[e.Mouse=1]="Mouse",e))(Nr||{});typeof window<"u"&&typeof document<"u"&&(document.addEventListener("keydown",e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",e=>{e.detail===1?delete document.documentElement.dataset.headlessuiFocusVisible:e.detail===0&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0));function I(e){e==null||e.focus({preventScroll:!0})}let Rr=["textarea","input"].join(",");function Dr(e){var t,r;return(r=(t=e==null?void 0:e.matches)==null?void 0:t.call(e,Rr))!=null?r:!1}function Ir(e,t=r=>r){return e.slice().sort((r,n)=>{let l=t(r),a=t(n);if(l===null||a===null)return 0;let s=l.compareDocumentPosition(a);return s&Node.DOCUMENT_POSITION_FOLLOWING?-1:s&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function me(e,t,{sorted:r=!0,relativeTo:n=null,skipElements:l=[]}={}){var a;let s=(a=Array.isArray(e)?e.length>0?e[0].ownerDocument:document:e==null?void 0:e.ownerDocument)!=null?a:document,i=Array.isArray(e)?r?Ir(e):e:zr(e);l.length>0&&i.length>1&&(i=i.filter(g=>!l.includes(g))),n=n??s.activeElement;let u=(()=>{if(t&5)return 1;if(t&10)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),c=(()=>{if(t&1)return 0;if(t&2)return Math.max(0,i.indexOf(n))-1;if(t&4)return Math.max(0,i.indexOf(n))+1;if(t&8)return i.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),p=t&32?{preventScroll:!0}:{},m=0,d=i.length,f;do{if(m>=d||m+d<=0)return 0;let g=c+m;if(t&16)g=(g+d)%d;else{if(g<0)return 3;if(g>=d)return 1}f=i[g],f==null||f.focus(p),m+=u}while(f!==s.activeElement);return t&6&&Dr(f)&&f.select(),2}function de(e,t,r){ge.isServer||o.watchEffect(n=>{document.addEventListener(e,t,r),n(()=>document.removeEventListener(e,t,r))})}function nt(e,t,r){ge.isServer||o.watchEffect(n=>{window.addEventListener(e,t,r),n(()=>window.removeEventListener(e,t,r))})}function Vr(e,t,r=o.computed(()=>!0)){function n(a,s){if(!r.value||a.defaultPrevented)return;let i=s(a);if(i===null||!i.getRootNode().contains(i))return;let u=function c(p){return typeof p=="function"?c(p()):Array.isArray(p)||p instanceof Set?p:[p]}(e);for(let c of u){if(c===null)continue;let p=c instanceof HTMLElement?c:k(c);if(p!=null&&p.contains(i)||a.composed&&a.composedPath().includes(p))return}return!jr(i,rt.Loose)&&i.tabIndex!==-1&&a.preventDefault(),t(a,i)}let l=o.ref(null);de("pointerdown",a=>{var s,i;r.value&&(l.value=((i=(s=a.composedPath)==null?void 0:s.call(a))==null?void 0:i[0])||a.target)},!0),de("mousedown",a=>{var s,i;r.value&&(l.value=((i=(s=a.composedPath)==null?void 0:s.call(a))==null?void 0:i[0])||a.target)},!0),de("click",a=>{l.value&&(n(a,()=>l.value),l.value=null)},!0),de("touchend",a=>n(a,()=>a.target instanceof HTMLElement?a.target:null),!0),nt("blur",a=>n(a,()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null),!0)}var ve=(e=>(e[e.None=1]="None",e[e.Focusable=2]="Focusable",e[e.Hidden=4]="Hidden",e))(ve||{});let Ce=o.defineComponent({name:"Hidden",props:{as:{type:[Object,String],default:"div"},features:{type:Number,default:1}},setup(e,{slots:t,attrs:r}){return()=>{let{features:n,...l}=e,a={"aria-hidden":(n&2)===2?!0:void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(n&4)===4&&(n&2)!==2&&{display:"none"}}};return L({ourProps:a,theirProps:l,slot:{},attrs:r,slots:t,name:"Hidden"})}}});function Hr(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function Be(e){typeof queueMicrotask=="function"?queueMicrotask(e):Promise.resolve().then(e).catch(t=>setTimeout(()=>{throw t}))}function Fe(){let e=[],t={addEventListener(r,n,l,a){return r.addEventListener(n,l,a),t.add(()=>r.removeEventListener(n,l,a))},requestAnimationFrame(...r){let n=requestAnimationFrame(...r);t.add(()=>cancelAnimationFrame(n))},nextFrame(...r){t.requestAnimationFrame(()=>{t.requestAnimationFrame(...r)})},setTimeout(...r){let n=setTimeout(...r);t.add(()=>clearTimeout(n))},microTask(...r){let n={current:!0};return Be(()=>{n.current&&r[0]()}),t.add(()=>{n.current=!1})},style(r,n,l){let a=r.style.getPropertyValue(n);return Object.assign(r.style,{[n]:l}),this.add(()=>{Object.assign(r.style,{[n]:a})})},group(r){let n=Fe();return r(n),this.add(()=>n.dispose())},add(r){return e.push(r),()=>{let n=e.indexOf(r);if(n>=0)for(let l of e.splice(n,1))l()}},dispose(){for(let r of e.splice(0))r()}};return t}var oe=(e=>(e[e.Forwards=0]="Forwards",e[e.Backwards=1]="Backwards",e))(oe||{});function Wr(){let e=o.ref(0);return nt("keydown",t=>{t.key==="Tab"&&(e.value=t.shiftKey?1:0)}),e}function ot(e,t,r,n){ge.isServer||o.watchEffect(l=>{e=e??window,e.addEventListener(t,r,n),l(()=>e.removeEventListener(t,r,n))})}function Ur(e){function t(){document.readyState!=="loading"&&(e(),document.removeEventListener("DOMContentLoaded",t))}typeof window<"u"&&typeof document<"u"&&(document.addEventListener("DOMContentLoaded",t),t())}function lt(e){if(!e)return new Set;if(typeof e=="function")return new Set(e());let t=new Set;for(let r of e.value){let n=k(r);n instanceof HTMLElement&&t.add(n)}return t}var at=(e=>(e[e.None=1]="None",e[e.InitialFocus=2]="InitialFocus",e[e.TabLock=4]="TabLock",e[e.FocusLock=8]="FocusLock",e[e.RestoreFocus=16]="RestoreFocus",e[e.All=30]="All",e))(at||{});let te=Object.assign(o.defineComponent({name:"FocusTrap",props:{as:{type:[Object,String],default:"div"},initialFocus:{type:Object,default:null},features:{type:Number,default:30},containers:{type:[Object,Function],default:o.ref(new Set)}},inheritAttrs:!1,setup(e,{attrs:t,slots:r,expose:n}){let l=o.ref(null);n({el:l,$el:l});let a=o.computed(()=>K(l)),s=o.ref(!1);o.onMounted(()=>s.value=!0),o.onUnmounted(()=>s.value=!1),qr({ownerDocument:a},o.computed(()=>s.value&&!!(e.features&16)));let i=Kr({ownerDocument:a,container:l,initialFocus:o.computed(()=>e.initialFocus)},o.computed(()=>s.value&&!!(e.features&2)));Zr({ownerDocument:a,container:l,containers:e.containers,previousActiveElement:i},o.computed(()=>s.value&&!!(e.features&8)));let u=Wr();function c(f){let g=k(l);g&&(v=>v())(()=>{V(u.value,{[oe.Forwards]:()=>{me(g,j.First,{skipElements:[f.relatedTarget]})},[oe.Backwards]:()=>{me(g,j.Last,{skipElements:[f.relatedTarget]})}})})}let p=o.ref(!1);function m(f){f.key==="Tab"&&(p.value=!0,requestAnimationFrame(()=>{p.value=!1}))}function d(f){if(!s.value)return;let g=lt(e.containers);k(l)instanceof HTMLElement&&g.add(k(l));let v=f.relatedTarget;v instanceof HTMLElement&&v.dataset.headlessuiFocusGuard!=="true"&&(st(g,v)||(p.value?me(k(l),V(u.value,{[oe.Forwards]:()=>j.Next,[oe.Backwards]:()=>j.Previous})|j.WrapAround,{relativeTo:f.target}):f.target instanceof HTMLElement&&I(f.target)))}return()=>{let f={},g={ref:l,onKeydown:m,onFocusout:d},{features:v,initialFocus:x,containers:_,...C}=e;return o.h(o.Fragment,[!!(v&4)&&o.h(Ce,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:c,features:ve.Focusable}),L({ourProps:g,theirProps:{...t,...C},slot:f,attrs:t,slots:r,name:"FocusTrap"}),!!(v&4)&&o.h(Ce,{as:"button",type:"button","data-headlessui-focus-guard":!0,onFocus:c,features:ve.Focusable})])}}}),{features:at}),N=[];Ur(()=>{function e(t){t.target instanceof HTMLElement&&t.target!==document.body&&N[0]!==t.target&&(N.unshift(t.target),N=N.filter(r=>r!=null&&r.isConnected),N.splice(10))}window.addEventListener("click",e,{capture:!0}),window.addEventListener("mousedown",e,{capture:!0}),window.addEventListener("focus",e,{capture:!0}),document.body.addEventListener("click",e,{capture:!0}),document.body.addEventListener("mousedown",e,{capture:!0}),document.body.addEventListener("focus",e,{capture:!0})});function Gr(e){let t=o.ref(N.slice());return o.watch([e],([r],[n])=>{n===!0&&r===!1?Be(()=>{t.value.splice(0)}):n===!1&&r===!0&&(t.value=N.slice())},{flush:"post"}),()=>{var r;return(r=t.value.find(n=>n!=null&&n.isConnected))!=null?r:null}}function qr({ownerDocument:e},t){let r=Gr(t);o.onMounted(()=>{o.watchEffect(()=>{var n,l;t.value||((n=e.value)==null?void 0:n.activeElement)===((l=e.value)==null?void 0:l.body)&&I(r())},{flush:"post"})}),o.onUnmounted(()=>{t.value&&I(r())})}function Kr({ownerDocument:e,container:t,initialFocus:r},n){let l=o.ref(null),a=o.ref(!1);return o.onMounted(()=>a.value=!0),o.onUnmounted(()=>a.value=!1),o.onMounted(()=>{o.watch([t,r,n],(s,i)=>{if(s.every((c,p)=>(i==null?void 0:i[p])===c)||!n.value)return;let u=k(t);u&&Be(()=>{var c,p;if(!a.value)return;let m=k(r),d=(c=e.value)==null?void 0:c.activeElement;if(m){if(m===d){l.value=d;return}}else if(u.contains(d)){l.value=d;return}m?I(m):me(u,j.First|j.NoScroll)===tt.Error&&console.warn("There are no focusable elements inside the <FocusTrap />"),l.value=(p=e.value)==null?void 0:p.activeElement})},{immediate:!0,flush:"post"})}),l}function Zr({ownerDocument:e,container:t,containers:r,previousActiveElement:n},l){var a;ot((a=e.value)==null?void 0:a.defaultView,"focus",s=>{if(!l.value)return;let i=lt(r);k(t)instanceof HTMLElement&&i.add(k(t));let u=n.value;if(!u)return;let c=s.target;c&&c instanceof HTMLElement?st(i,c)?(n.value=c,I(c)):(s.preventDefault(),s.stopPropagation(),I(u)):I(n.value)},!0)}function st(e,t){for(let r of e)if(r.contains(t))return!0;return!1}let we=new Map,re=new Map;function He(e,t=o.ref(!0)){o.watchEffect(r=>{var n;if(!t.value)return;let l=k(e);if(!l)return;r(function(){var s;if(!l)return;let i=(s=re.get(l))!=null?s:1;if(i===1?re.delete(l):re.set(l,i-1),i!==1)return;let u=we.get(l);u&&(u["aria-hidden"]===null?l.removeAttribute("aria-hidden"):l.setAttribute("aria-hidden",u["aria-hidden"]),l.inert=u.inert,we.delete(l))});let a=(n=re.get(l))!=null?n:0;re.set(l,a+1),a===0&&(we.set(l,{"aria-hidden":l.getAttribute("aria-hidden"),inert:l.inert}),l.setAttribute("aria-hidden","true"),l.inert=!0)})}let it=Symbol("ForcePortalRootContext");function Xr(){return o.inject(it,!1)}let ke=o.defineComponent({name:"ForcePortalRoot",props:{as:{type:[Object,String],default:"template"},force:{type:Boolean,default:!1}},setup(e,{slots:t,attrs:r}){return o.provide(it,e.force),()=>{let{force:n,...l}=e;return L({theirProps:l,ourProps:{},slot:{},slots:t,attrs:r,name:"ForcePortalRoot"})}}});function Yr(e){let t=K(e);if(!t){if(e===null)return null;throw new Error(`[Headless UI]: Cannot find ownerDocument for contextElement: ${e}`)}let r=t.getElementById("headlessui-portal-root");if(r)return r;let n=t.createElement("div");return n.setAttribute("id","headlessui-portal-root"),t.body.appendChild(n)}let ut=o.defineComponent({name:"Portal",props:{as:{type:[Object,String],default:"div"}},setup(e,{slots:t,attrs:r}){let n=o.ref(null),l=o.computed(()=>K(n)),a=Xr(),s=o.inject(ct,null),i=o.ref(a===!0||s==null?Yr(n.value):s.resolveTarget());o.watchEffect(()=>{a||s!=null&&(i.value=s.resolveTarget())});let u=o.inject(Ee,null);return o.onMounted(()=>{let c=k(n);c&&u&&o.onUnmounted(u.register(c))}),o.onUnmounted(()=>{var c,p;let m=(c=l.value)==null?void 0:c.getElementById("headlessui-portal-root");m&&i.value===m&&i.value.children.length<=0&&((p=i.value.parentElement)==null||p.removeChild(i.value))}),()=>{if(i.value===null)return null;let c={ref:n,"data-headlessui-portal":""};return o.h(o.Teleport,{to:i.value},L({ourProps:c,theirProps:e,slot:{},attrs:r,slots:t,name:"Portal"}))}}}),Ee=Symbol("PortalParentContext");function Jr(){let e=o.inject(Ee,null),t=o.ref([]);function r(a){return t.value.push(a),e&&e.register(a),()=>n(a)}function n(a){let s=t.value.indexOf(a);s!==-1&&t.value.splice(s,1),e&&e.unregister(a)}let l={register:r,unregister:n,portals:t};return[t,o.defineComponent({name:"PortalWrapper",setup(a,{slots:s}){return o.provide(Ee,l),()=>{var i;return(i=s.default)==null?void 0:i.call(s)}}})]}let ct=Symbol("PortalGroupContext"),Qr=o.defineComponent({name:"PortalGroup",props:{as:{type:[Object,String],default:"template"},target:{type:Object,default:null}},setup(e,{attrs:t,slots:r}){let n=o.reactive({resolveTarget(){return e.target}});return o.provide(ct,n),()=>{let{target:l,...a}=e;return L({theirProps:a,ourProps:{},slot:{},attrs:t,slots:r,name:"PortalGroup"})}}}),dt=Symbol("StackContext");var _e=(e=>(e[e.Add=0]="Add",e[e.Remove=1]="Remove",e))(_e||{});function en(){return o.inject(dt,()=>{})}function tn({type:e,enabled:t,element:r,onUpdate:n}){let l=en();function a(...s){n==null||n(...s),l(...s)}o.onMounted(()=>{o.watch(t,(s,i)=>{s?a(0,e,r):i===!0&&a(1,e,r)},{immediate:!0,flush:"sync"})}),o.onUnmounted(()=>{t.value&&a(1,e,r)}),o.provide(dt,a)}let pt=Symbol("DescriptionContext");function rn(){let e=o.inject(pt,null);if(e===null)throw new Error("Missing parent");return e}function nn({slot:e=o.ref({}),name:t="Description",props:r={}}={}){let n=o.ref([]);function l(a){return n.value.push(a),()=>{let s=n.value.indexOf(a);s!==-1&&n.value.splice(s,1)}}return o.provide(pt,{register:l,slot:e,name:t,props:r}),o.computed(()=>n.value.length>0?n.value.join(" "):void 0)}let on=o.defineComponent({name:"Description",props:{as:{type:[Object,String],default:"p"},id:{type:String,default:()=>`headlessui-description-${q()}`}},setup(e,{attrs:t,slots:r}){let n=rn();return o.onMounted(()=>o.onUnmounted(n.register(e.id))),()=>{let{name:l="Description",slot:a=o.ref({}),props:s={}}=n,{id:i,...u}=e,c={...Object.entries(s).reduce((p,[m,d])=>Object.assign(p,{[m]:o.unref(d)}),{}),id:i};return L({ourProps:c,theirProps:u,slot:a.value,attrs:t,slots:r,name:l})}}});function ln(e){let t=o.shallowRef(e.getSnapshot());return o.onUnmounted(e.subscribe(()=>{t.value=e.getSnapshot()})),t}function an(e,t){let r=e(),n=new Set;return{getSnapshot(){return r},subscribe(l){return n.add(l),()=>n.delete(l)},dispatch(l,...a){let s=t[l].call(r,...a);s&&(r=s,n.forEach(i=>i()))}}}function sn(){let e;return{before({doc:t}){var r;let n=t.documentElement;e=((r=t.defaultView)!=null?r:window).innerWidth-n.clientWidth},after({doc:t,d:r}){let n=t.documentElement,l=n.clientWidth-n.offsetWidth,a=e-l;r.style(n,"paddingRight",`${a}px`)}}}function un(){if(!Hr())return{};let e;return{before(){e=window.pageYOffset},after({doc:t,d:r,meta:n}){function l(s){return n.containers.flatMap(i=>i()).some(i=>i.contains(s))}if(window.getComputedStyle(t.documentElement).scrollBehavior!=="auto"){let s=Fe();s.style(t.documentElement,"scroll-behavior","auto"),r.add(()=>r.microTask(()=>s.dispose()))}r.style(t.body,"marginTop",`-${e}px`),window.scrollTo(0,0);let a=null;r.addEventListener(t,"click",s=>{if(s.target instanceof HTMLElement)try{let i=s.target.closest("a");if(!i)return;let{hash:u}=new URL(i.href),c=t.querySelector(u);c&&!l(c)&&(a=c)}catch{}},!0),r.addEventListener(t,"touchmove",s=>{s.target instanceof HTMLElement&&!l(s.target)&&s.preventDefault()},{passive:!1}),r.add(()=>{window.scrollTo(0,window.pageYOffset+e),a&&a.isConnected&&(a.scrollIntoView({block:"nearest"}),a=null)})}}}function cn(){return{before({doc:e,d:t}){t.style(e.documentElement,"overflow","hidden")}}}function dn(e){let t={};for(let r of e)Object.assign(t,r(t));return t}let D=an(()=>new Map,{PUSH(e,t){var r;let n=(r=this.get(e))!=null?r:{doc:e,count:0,d:Fe(),meta:new Set};return n.count++,n.meta.add(t),this.set(e,n),this},POP(e,t){let r=this.get(e);return r&&(r.count--,r.meta.delete(t)),this},SCROLL_PREVENT({doc:e,d:t,meta:r}){let n={doc:e,d:t,meta:dn(r)},l=[un(),sn(),cn()];l.forEach(({before:a})=>a==null?void 0:a(n)),l.forEach(({after:a})=>a==null?void 0:a(n))},SCROLL_ALLOW({d:e}){e.dispose()},TEARDOWN({doc:e}){this.delete(e)}});D.subscribe(()=>{let e=D.getSnapshot(),t=new Map;for(let[r]of e)t.set(r,r.documentElement.style.overflow);for(let r of e.values()){let n=t.get(r.doc)==="hidden",l=r.count!==0;(l&&!n||!l&&n)&&D.dispatch(r.count>0?"SCROLL_PREVENT":"SCROLL_ALLOW",r),r.count===0&&D.dispatch("TEARDOWN",r)}});function pn(e,t,r){let n=ln(D),l=o.computed(()=>{let a=e.value?n.value.get(e.value):void 0;return a?a.count>0:!1});return o.watch([e,t],([a,s],[i],u)=>{if(!a||!s)return;D.dispatch("PUSH",a,r);let c=!1;u(()=>{c||(D.dispatch("POP",i??a,r),c=!0)})},{immediate:!0}),l}function fn({defaultContainers:e=[],portals:t,mainTreeNodeRef:r}={}){let n=o.ref(null),l=K(n);function a(){var s;let i=[];for(let u of e)u!==null&&(u instanceof HTMLElement?i.push(u):"value"in u&&u.value instanceof HTMLElement&&i.push(u.value));if(t!=null&&t.value)for(let u of t.value)i.push(u);for(let u of(s=l==null?void 0:l.querySelectorAll("html > *, body > *"))!=null?s:[])u!==document.body&&u!==document.head&&u instanceof HTMLElement&&u.id!=="headlessui-portal-root"&&(u.contains(k(n))||i.some(c=>u.contains(c))||i.push(u));return i}return{resolveContainers:a,contains(s){return a().some(i=>i.contains(s))},mainTreeNodeRef:n,MainTreeNode(){return r!=null?null:o.h(Ce,{features:ve.Hidden,ref:n})}}}var mn=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(mn||{});let Me=Symbol("DialogContext");function le(e){let t=o.inject(Me,null);if(t===null){let r=new Error(`<${e} /> is missing a parent <Dialog /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,le),r}return t}let pe="DC8F892D-2EBD-447C-A4C8-A03058436FF4",vn=o.defineComponent({name:"Dialog",inheritAttrs:!1,props:{as:{type:[Object,String],default:"div"},static:{type:Boolean,default:!1},unmount:{type:Boolean,default:!0},open:{type:[Boolean,String],default:pe},initialFocus:{type:Object,default:null},id:{type:String,default:()=>`headlessui-dialog-${q()}`}},emits:{close:e=>!0},setup(e,{emit:t,attrs:r,slots:n,expose:l}){var a;let s=o.ref(!1);o.onMounted(()=>{s.value=!0});let i=o.ref(0),u=Ar(),c=o.computed(()=>e.open===pe&&u!==null?(u.value&ne.Open)===ne.Open:e.open),p=o.ref(null),m=o.computed(()=>K(p));if(l({el:p,$el:p}),!(e.open!==pe||u!==null))throw new Error("You forgot to provide an `open` prop to the `Dialog`.");if(typeof c.value!="boolean")throw new Error(`You provided an \`open\` prop to the \`Dialog\`, but the value is not a boolean. Received: ${c.value===pe?void 0:e.open}`);let d=o.computed(()=>s.value&&c.value?0:1),f=o.computed(()=>d.value===0),g=o.computed(()=>i.value>1),v=o.inject(Me,null)!==null,[x,_]=Jr(),{resolveContainers:C,mainTreeNodeRef:A,MainTreeNode:$}=fn({portals:x,defaultContainers:[o.computed(()=>{var w;return(w=B.panelRef.value)!=null?w:p.value})]}),ae=o.computed(()=>g.value?"parent":"leaf"),Z=o.computed(()=>u!==null?(u.value&ne.Closing)===ne.Closing:!1),se=o.computed(()=>v||Z.value?!1:f.value),ie=o.computed(()=>{var w,S,E;return(E=Array.from((S=(w=m.value)==null?void 0:w.querySelectorAll("body > *"))!=null?S:[]).find(M=>M.id==="headlessui-portal-root"?!1:M.contains(k(A))&&M instanceof HTMLElement))!=null?E:null});He(ie,se);let X=o.computed(()=>g.value?!0:f.value),Y=o.computed(()=>{var w,S,E;return(E=Array.from((S=(w=m.value)==null?void 0:w.querySelectorAll("[data-headlessui-portal]"))!=null?S:[]).find(M=>M.contains(k(A))&&M instanceof HTMLElement))!=null?E:null});He(Y,X),tn({type:"Dialog",enabled:o.computed(()=>d.value===0),element:p,onUpdate:(w,S)=>{if(S==="Dialog")return V(w,{[_e.Add]:()=>i.value+=1,[_e.Remove]:()=>i.value-=1})}});let J=nn({name:"DialogDescription",slot:o.computed(()=>({open:c.value}))}),b=o.ref(null),B={titleId:b,panelRef:o.ref(null),dialogState:d,setTitleId(w){b.value!==w&&(b.value=w)},close(){t("close",!1)}};o.provide(Me,B);let H=o.computed(()=>!(!f.value||g.value));Vr(C,(w,S)=>{B.close(),o.nextTick(()=>S==null?void 0:S.focus())},H);let ue=o.computed(()=>!(g.value||d.value!==0));ot((a=m.value)==null?void 0:a.defaultView,"keydown",w=>{ue.value&&(w.defaultPrevented||w.key===et.Escape&&(w.preventDefault(),w.stopPropagation(),B.close()))});let W=o.computed(()=>!(Z.value||d.value!==0||v));return pn(m,W,w=>{var S;return{containers:[...(S=w.containers)!=null?S:[],C]}}),o.watchEffect(w=>{if(d.value!==0)return;let S=k(p);if(!S)return;let E=new ResizeObserver(M=>{for(let O of M){let T=O.target.getBoundingClientRect();T.x===0&&T.y===0&&T.width===0&&T.height===0&&B.close()}});E.observe(S),w(()=>E.disconnect())}),()=>{let{id:w,open:S,initialFocus:E,...M}=e,O={...r,ref:p,id:w,role:"dialog","aria-modal":d.value===0?!0:void 0,"aria-labelledby":b.value,"aria-describedby":J.value},T={open:d.value===0};return o.h(ke,{force:!0},()=>[o.h(ut,()=>o.h(Qr,{target:p.value},()=>o.h(ke,{force:!1},()=>o.h(te,{initialFocus:E,containers:C,features:f.value?V(ae.value,{parent:te.features.RestoreFocus,leaf:te.features.All&~te.features.FocusLock}):te.features.None},()=>o.h(_,{},()=>L({ourProps:O,theirProps:{...M,...r},slot:T,attrs:r,slots:n,visible:d.value===0,features:xe.RenderStrategy|xe.Static,name:"Dialog"})))))),o.h($)])}}});o.defineComponent({name:"DialogOverlay",props:{as:{type:[Object,String],default:"div"},id:{type:String,default:()=>`headlessui-dialog-overlay-${q()}`}},setup(e,{attrs:t,slots:r}){let n=le("DialogOverlay");function l(a){a.target===a.currentTarget&&(a.preventDefault(),a.stopPropagation(),n.close())}return()=>{let{id:a,...s}=e;return L({ourProps:{id:a,"aria-hidden":!0,onClick:l},theirProps:s,slot:{open:n.dialogState.value===0},attrs:t,slots:r,name:"DialogOverlay"})}}});o.defineComponent({name:"DialogBackdrop",props:{as:{type:[Object,String],default:"div"},id:{type:String,default:()=>`headlessui-dialog-backdrop-${q()}`}},inheritAttrs:!1,setup(e,{attrs:t,slots:r,expose:n}){let l=le("DialogBackdrop"),a=o.ref(null);return n({el:a,$el:a}),o.onMounted(()=>{if(l.panelRef.value===null)throw new Error("A <DialogBackdrop /> component is being used, but a <DialogPanel /> component is missing.")}),()=>{let{id:s,...i}=e,u={id:s,ref:a,"aria-hidden":!0};return o.h(ke,{force:!0},()=>o.h(ut,()=>L({ourProps:u,theirProps:{...t,...i},slot:{open:l.dialogState.value===0},attrs:t,slots:r,name:"DialogBackdrop"})))}}});let gn=o.defineComponent({name:"DialogPanel",props:{as:{type:[Object,String],default:"div"},id:{type:String,default:()=>`headlessui-dialog-panel-${q()}`}},setup(e,{attrs:t,slots:r,expose:n}){let l=le("DialogPanel");n({el:l.panelRef,$el:l.panelRef});function a(s){s.stopPropagation()}return()=>{let{id:s,...i}=e,u={id:s,ref:l.panelRef,onClick:a};return L({ourProps:u,theirProps:i,slot:{open:l.dialogState.value===0},attrs:t,slots:r,name:"DialogPanel"})}}}),hn=o.defineComponent({name:"DialogTitle",props:{as:{type:[Object,String],default:"h2"},id:{type:String,default:()=>`headlessui-dialog-title-${q()}`}},setup(e,{attrs:t,slots:r}){let n=le("DialogTitle");return o.onMounted(()=>{n.setTitleId(e.id),o.onUnmounted(()=>n.setTitleId(null))}),()=>{let{id:l,...a}=e;return L({ourProps:{id:l},theirProps:a,slot:{open:n.dialogState.value===0},attrs:t,slots:r,name:"DialogTitle"})}}}),bn=on;const wn={class:"scalar-modal-layout fixed left-0 top-0 z-[1001] h-[100dvh] w-[100dvw] bg-backdrop p-5 opacity-0"},yn=()=>o.reactive({open:!1,show(){this.open=!0},hide(){this.open=!1}}),xn=o.defineComponent({__name:"ScalarModal",props:{state:{},title:{},bodyClass:{},maxWidth:{},size:{default:"md"},variant:{}},setup(e){const t=Pe({base:["scalar-modal","col relative mx-auto mb-0 mt-20 w-full rounded-lg bg-back-2 text-left leading-snug text-fore-1 opacity-0"].join(" "),variants:{size:{xs:"max-w-screen-xs",sm:"max-w-screen-sm",md:"max-w-screen-md",lg:"max-w-screen-lg"},variant:{history:"scalar-modal-history bg-back-1",search:"scalar-modal-search"}}});return(r,n)=>(o.openBlock(),o.createBlock(o.unref(vn),{open:r.state.open,onClose:n[0]||(n[0]=l=>r.state.hide())},{default:o.withCtx(()=>[o.createElementVNode("div",wn,[o.createVNode(o.unref(gn),{class:o.normalizeClass(o.unref(t)({size:r.size,variant:r.variant})),style:o.normalizeStyle({maxWidth:r.maxWidth})},{default:o.withCtx(()=>[r.title?(o.openBlock(),o.createBlock(o.unref(hn),{key:0,class:o.normalizeClass(["scalar-modal-header m-0 rounded-lg px-6 py-3 text-left text-xs font-semiBold text-fore-1",{"pb-0 pt-6":r.variant==="history"}])},{default:o.withCtx(()=>[o.createTextVNode(o.toDisplayString(r.title),1)]),_:1},8,["class"])):o.createCommentVNode("",!0),o.createVNode(o.unref(bn),{class:o.normalizeClass(["scalar-modal-body relative max-h-[calc(100dvh-240px)] overflow-y-auto rounded-lg bg-back-1 py-6 pb-4 pt-3",o.unref(U)(r.bodyClass,r.variant==="history"&&"pt-3",r.variant==="search"&&"col max-h-[440px] overflow-hidden p-0")])},{default:o.withCtx(()=>[o.renderSlot(r.$slots,"default",{},void 0,!0)]),_:3},8,["class"])]),_:3},8,["class","style"])])]),_:3},8,["open"]))}});const ft=Le(xn,[["__scopeId","data-v-63be7b4d"]]);function Sn(e){return o.getCurrentScope()?(o.onScopeDispose(e),!0):!1}function mt(e){return typeof e=="function"?e():o.unref(e)}const Cn=typeof window<"u"&&typeof document<"u";function We(e){var t;const r=mt(e);return(t=r==null?void 0:r.$el)!=null?t:r}const kn=Cn?window:void 0;function En(){const e=o.ref(!1);return o.getCurrentInstance()&&o.onMounted(()=>{e.value=!0}),e}function _n(e){const t=En();return o.computed(()=>(t.value,!!e()))}function Mn(e,t,r={}){const{window:n=kn,...l}=r;let a;const s=_n(()=>n&&"ResizeObserver"in n),i=()=>{a&&(a.disconnect(),a=void 0)},u=o.computed(()=>Array.isArray(e)?e.map(m=>We(m)):[We(e)]),c=o.watch(u,m=>{if(i(),s.value&&n){a=new ResizeObserver(t);for(const d of m)d&&a.observe(d,l)}},{immediate:!0,flush:"post",deep:!0}),p=()=>{i(),c()};return Sn(p),{isSupported:s,stop:p}}function Tn(e){const t=o.ref(e==null?void 0:e.element),r=o.ref(e==null?void 0:e.input),n=o.ref(1);function l(){var a,s;if(!t.value)return;let i="";t.value.style.height="1px",n.value=(a=t.value)==null?void 0:a.scrollHeight,e!=null&&e.styleTarget?mt(e.styleTarget).style.height=`${n.value}px`:i=`${n.value}px`,t.value.style.height=i,(s=e==null?void 0:e.onResize)==null||s.call(e)}return o.watch([r,t],()=>o.nextTick(l),{immediate:!0}),Mn(t,()=>l()),e!=null&&e.watch&&o.watch(e.watch,l,{immediate:!0,deep:!0}),{textarea:t,input:r,triggerResize:l}}let Pn=(e=21)=>crypto.getRandomValues(new Uint8Array(e)).reduce((t,r)=>(r&=63,r<36?t+=r.toString(36):r<62?t+=(r-26).toString(36).toUpperCase():r>62?t+="-":t+="_",t),"");const Ln={class:"scalar-input-container relative"},An=["for"],On={class:"icon-slot cursor-pointer text-ghost hover:text-fore-1 !empty:flex !empty:w-7 !empty:items-center !empty:pr-3"},$n=o.defineComponent({__name:"ScalarTextField",props:{modelValue:{},placeholder:{},label:{},labelShadowColor:{default:"var(--theme-background-2, var(--default-theme-background-2))"},error:{type:Boolean},isMultiline:{type:Boolean},helperText:{},emitOnBlur:{type:Boolean,default:!0},handleFieldSubmit:{},handleFieldChange:{},disableTrim:{type:Boolean,default:!1}},emits:["submit","update:modelValue"],setup(e,{emit:t}){const r=e,n=Pe({base:"scalar-input-wrapper relative flex items-center rounded border border-border",variants:{focus:{true:"scalar-input-wrapper-focus border-fore-3 has-actv-btn:border has-actv-btn:border-border"},error:{true:"scalar-input-wrapper-error border-error"}}}),l=o.useAttrs(),a=l.id||`id-${Pn()}`,s=o.ref(),i=o.ref(!1);let u;if(r.isMultiline){const{triggerResize:d}=Tn({element:s,input:r.modelValue});u=d}function c(d){const f=d.target.value;r.isMultiline&&u(),r.handleFieldChange?r.handleFieldChange(f):t("update:modelValue",f)}function p(d){const f=d.target,g=r.disableTrim||r.isMultiline?f.value:f.value.trim();r.handleFieldSubmit?r.handleFieldSubmit(g):t("submit",g)}function m(d){i.value=!1,r.emitOnBlur&&r.modelValue&&p(d)}return o.onMounted(()=>{var d;Object.prototype.hasOwnProperty.call(l,"autofocus")&&((d=s.value)==null||d.focus())}),(d,f)=>(o.openBlock(),o.createElementBlock("div",Ln,[o.createElementVNode("div",{class:o.normalizeClass(o.unref(n)({error:d.error,focus:i.value}))},[d.label?(o.openBlock(),o.createElementBlock("label",{key:0,class:o.normalizeClass(o.unref(U)("scalar-input-label pointer-events-none absolute left-0 top-0 mx-2 my-3 px-1 text-xs","shadow-current peer z-10 origin-top-left rounded text-fore-3 transition-transform")),for:o.unref(a),style:o.normalizeStyle({"box-shadow":`0 0 4px 4px ${d.labelShadowColor}`,"background-color":d.labelShadowColor})},o.toDisplayString(d.label),15,An)):o.createCommentVNode("",!0),(o.openBlock(),o.createBlock(o.resolveDynamicComponent(d.isMultiline?"textarea":"input"),o.mergeProps({id:o.unref(a)},d.$attrs,{ref_key:"input",ref:s,class:["scalar-input",o.unref(U)({"min-h-[77px]":d.isMultiline},"z-10 w-full resize-none appearance-none border-0 bg-transparent p-3 text-sm text-fore-1","outline-none transition-opacity peer-[]:opacity-0")],placeholder:d.placeholder,value:d.modelValue,onBlur:m,onFocus:f[0]||(f[0]=g=>i.value=!0),onInput:c,onKeyup:o.withKeys(p,["enter"])}),null,16,["id","class","placeholder","value","onKeyup"])),o.createElementVNode("div",On,[o.renderSlot(d.$slots,"default",{},void 0,!0)])],2),o.createElementVNode("span",{class:o.normalizeClass(o.unref(U)("helper-text mt-1.5 flex items-center text-xs text-error before:rounded-full before:font-black","before:mr-1.5 before:block before:h-4 before:w-4 before:text-center before:text-xxs before:leading-4","before:bg-error before:text-white before:content-['!'] empty:hidden"))},o.toDisplayString(d.helperText),3)]))}});const vt=Le($n,[["__scopeId","data-v-36fafda8"]]);const Bn={install:e=>{e.component("ScalarButton",Oe),e.component("ScalarIcon",$e),e.component("ScalarIconButton",Ye),e.component("ScalarLoading",Ae),e.component("ScalarModal",ft),e.component("ScalarTextField",vt)}};exports.ScalarButton=Oe;exports.ScalarIcon=$e;exports.ScalarIconButton=Ye;exports.ScalarLoading=Ae;exports.ScalarModal=ft;exports.ScalarTextField=vt;exports.default=Bn;exports.useLoadingState=Qt;exports.useModal=yn;
@@ -0,0 +1,13 @@
1
+ import type { App } from 'vue';
2
+ import { ScalarButton } from './components/ScalarButton';
3
+ import { ScalarIcon } from './components/ScalarIcon';
4
+ import { ScalarIconButton } from './components/ScalarIconButton';
5
+ import { ScalarLoading, useLoadingState } from './components/ScalarLoading';
6
+ import { ScalarModal, useModal } from './components/ScalarModal';
7
+ import { ScalarTextField } from './components/ScalarTextField';
8
+ declare const _default: {
9
+ install: (app: App) => void;
10
+ };
11
+ export default _default;
12
+ export { ScalarButton, ScalarIcon, ScalarIconButton, ScalarLoading, useLoadingState, ScalarModal, useModal, ScalarTextField, };
13
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,KAAK,CAAA;AAE9B,OAAO,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAA;AACxD,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAA;AACpD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAA;AAChE,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAA;AAC3E,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAA;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAA;AAC9D,OAAO,yBAAyB,CAAA;;mBAGf,GAAG;;AADpB,wBASC;AAED,OAAO,EACL,YAAY,EACZ,UAAU,EACV,gBAAgB,EAChB,aAAa,EACb,eAAe,EACf,WAAW,EACX,QAAQ,EACR,eAAe,GAChB,CAAA"}