@solvimon/solvimon-web 0.1.0-alpha.3 → 0.1.0-alpha.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +70 -42
- package/dist/{BillingInformation.vue_vue_type_script_setup_true_lang-BD3CrJzj.js → BillingInformation.vue_vue_type_script_setup_true_lang-BouYyZhD.js} +1 -1
- package/dist/{BillingInformation.vue_vue_type_script_setup_true_lang-DQAp1xwu.mjs → BillingInformation.vue_vue_type_script_setup_true_lang-CvUwy_tp.mjs} +2 -2
- package/dist/{ContentWithAsideLayout-DczcgSrt.js → ContentWithAsideLayout-BjJufFeN.js} +1 -1
- package/dist/{ContentWithAsideLayout-CRsFr9TH.mjs → ContentWithAsideLayout-CKbnuXMU.mjs} +1 -1
- package/dist/{InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-D0ie9Krt.mjs → InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-DaEPSNrY.mjs} +1 -1
- package/dist/{InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-BE3I7Oe1.js → InvoiceDetailsBlock.vue_vue_type_script_setup_true_lang-sbmK2un9.js} +1 -1
- package/dist/{PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-DVDOsMnT.mjs → PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-CLU-8-Ao.mjs} +1 -1
- package/dist/{PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-sNdlKgdU.js → PaymentHistoryBlock.vue_vue_type_script_setup_true_lang-NRmK7iN3.js} +1 -1
- package/dist/{PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-Sn1Jq19s.js → PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-Ck_1lRDB.js} +1 -1
- package/dist/{PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-DJEZEEwZ.mjs → PaymentIntegrationForm.vue_vue_type_script_setup_true_lang-DFCX2tcj.mjs} +3 -3
- package/dist/{PricingGroupContent.vue_vue_type_script_setup_true_lang-Bifo4jTH.js → PricingGroupContent.vue_vue_type_script_setup_true_lang-BOZurit_.js} +1 -1
- package/dist/{PricingGroupContent.vue_vue_type_script_setup_true_lang-DWp42_G4.mjs → PricingGroupContent.vue_vue_type_script_setup_true_lang-DAwMy1l8.mjs} +1 -1
- package/dist/{SubscriptionsList.vue_vue_type_script_setup_true_lang-Bp5RvQVS.mjs → SubscriptionsList.vue_vue_type_script_setup_true_lang-Cj4cnM8z.mjs} +4 -4
- package/dist/{SubscriptionsList.vue_vue_type_script_setup_true_lang-yyhwzYSM.js → SubscriptionsList.vue_vue_type_script_setup_true_lang-D49i1DHa.js} +1 -1
- package/dist/{component-DEo_ndpK.mjs → component-B0RYS5uK.mjs} +5 -7
- package/dist/component-BeqkeC9h.js +1 -0
- package/dist/components/BillingInformation/BillingInformation.ce.d.ts +1 -1
- package/dist/components/BillingInformation/BillingInformation.cjs.js +1 -1
- package/dist/components/BillingInformation/BillingInformation.es.js +3 -3
- package/dist/components/BillingInformationForm/BillingInformationForm.ce.d.ts +1 -1
- package/dist/components/BillingInformationForm/BillingInformationForm.cjs.js +1 -1
- package/dist/components/BillingInformationForm/BillingInformationForm.es.js +2 -2
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.ce.d.ts +1 -1
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.cjs.js +1 -1
- package/dist/components/CustomerPaymentMethods/CustomerPaymentMethods.es.js +3 -3
- package/dist/components/Invoice/Invoice.ce.d.ts +1 -1
- package/dist/components/Invoice/Invoice.cjs.js +1 -1
- package/dist/components/Invoice/Invoice.es.js +26 -49
- package/dist/components/InvoiceDetails/InvoiceDetails.ce.d.ts +1 -1
- package/dist/components/InvoiceDetails/InvoiceDetails.cjs.js +1 -1
- package/dist/components/InvoiceDetails/InvoiceDetails.es.js +3 -3
- package/dist/components/InvoicesList/InvoicesList.ce.d.ts +1 -1
- package/dist/components/InvoicesList/InvoicesList.cjs.js +1 -1
- package/dist/components/InvoicesList/InvoicesList.es.js +11 -6
- package/dist/components/PaymentHistory/PaymentHistory.ce.d.ts +1 -1
- package/dist/components/PaymentHistory/PaymentHistory.cjs.js +1 -1
- package/dist/components/PaymentHistory/PaymentHistory.es.js +3 -3
- package/dist/components/PaymentMethodForm/PaymentMethodForm.ce.d.ts +1 -1
- package/dist/components/PaymentMethodForm/PaymentMethodForm.cjs.js +1 -1
- package/dist/components/PaymentMethodForm/PaymentMethodForm.es.js +4 -4
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.ce.d.ts +1 -1
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.cjs.js +1 -1
- package/dist/components/SubscriptionSchedules/SubscriptionSchedules.es.js +2 -2
- package/dist/components/SubscriptionsList/SubscriptionsList.ce.d.ts +1 -1
- package/dist/components/SubscriptionsList/SubscriptionsList.cjs.js +1 -1
- package/dist/components/SubscriptionsList/SubscriptionsList.es.js +4 -4
- package/dist/components/WalletBalances/WalletBalances.ce.d.ts +1 -1
- package/dist/components/WalletBalances/WalletBalances.cjs.js +1 -1
- package/dist/components/WalletBalances/WalletBalances.es.js +2 -2
- package/dist/core/index.cjs.js +1 -1
- package/dist/core/index.es.js +1 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.es.js +1 -1
- package/dist/{invoices-BW1notiX.js → invoices-CUrXmVXe.js} +1 -1
- package/dist/{invoices-M5oYVch6.mjs → invoices-CoEBP5UT.mjs} +1 -1
- package/dist/{paymentMethods-CqKUfc3w.mjs → paymentMethods-C2gWIbEr.mjs} +1 -1
- package/dist/{paymentMethods-BX80t2zk.js → paymentMethods-D_rYLg3F.js} +1 -1
- package/dist/{payments-BHv4hCeJ.js → payments-ClJySb0d.js} +1 -1
- package/dist/{payments-CosaPZwo.mjs → payments-DLjkq_hN.mjs} +1 -1
- package/dist/{registry-BwKEYOf7.js → registry-EPF-VAYZ.js} +1 -1
- package/dist/{registry-Cag1Jj7P.mjs → registry-bo_7pcbl.mjs} +2 -2
- package/dist/screens/Checkout/Checkout.ce.d.ts +1 -1
- package/dist/screens/Checkout/Checkout.cjs.js +1 -1
- package/dist/screens/Checkout/Checkout.es.js +8 -8
- package/dist/screens/CustomerOverview/CustomerOverview.ce.d.ts +1 -1
- package/dist/screens/CustomerOverview/CustomerOverview.cjs.js +1 -1
- package/dist/screens/CustomerOverview/CustomerOverview.es.js +9 -9
- package/dist/screens/UpgradeSubscription/UpgradeSubscription.ce.d.ts +1 -1
- package/dist/screens/UpgradeSubscription/UpgradeSubscription.cjs.js +1 -1
- package/dist/screens/UpgradeSubscription/UpgradeSubscription.es.js +5 -5
- package/dist/{subscriptions-Bs4DIE8f.mjs → subscriptions-BepBTXR5.mjs} +1 -1
- package/dist/{subscriptions-CnxvsBXd.js → subscriptions-DERHtyHo.js} +1 -1
- package/dist/{useActionDispatchProvider-CgRcOqv3.mjs → useActionDispatchProvider-B_SkyymZ.mjs} +1 -1
- package/dist/{useActionDispatchProvider-Cru69mAl.js → useActionDispatchProvider-D4OtXsNA.js} +1 -1
- package/dist/{useCustomer-DlcjY3fP.mjs → useCustomer-C0RKKfGJ.mjs} +1 -1
- package/dist/{useCustomer-B0NK96dA.js → useCustomer-CEFUPIDZ.js} +1 -1
- package/dist/{useCustomerPaymentMethodOptions-C-8BLzqb.js → useCustomerPaymentMethodOptions-BgCFkLeQ.js} +1 -1
- package/dist/{useCustomerPaymentMethodOptions-BzEquyUV.mjs → useCustomerPaymentMethodOptions-BlFH4zxG.mjs} +3 -3
- package/dist/{useIncrementalLoading-C7ToTmZK.mjs → useIncrementalLoading-BqD4k_-r.mjs} +1 -1
- package/dist/{useIncrementalLoading-D60Vttil.js → useIncrementalLoading-CDpeHhKs.js} +1 -1
- package/dist/{useInvoiceData-CcueV3We.mjs → useInvoiceData-7mqBeSPa.mjs} +2 -2
- package/dist/{useInvoiceData-DstXfI7t.js → useInvoiceData-DvNf2402.js} +1 -1
- package/dist/{useInvoicesList-CXng3aUm.mjs → useInvoicesList-B5vYDRyl.mjs} +4 -4
- package/dist/{useInvoicesList-DmzjgMlW.js → useInvoicesList-CBqZG_rw.js} +1 -1
- package/dist/{usePaymentMethods-Db-1R6rI.mjs → usePaymentMethods-4Io2ZHlo.mjs} +2 -2
- package/dist/{usePaymentMethods-DCGVRXA4.js → usePaymentMethods-BdZkt6re.js} +1 -1
- package/dist/{useWalletBalanceItems-CHkLaccm.mjs → useWalletBalanceItems-B0NZuM3W.mjs} +1 -1
- package/dist/{useWalletBalanceItems-BZyiAhcV.js → useWalletBalanceItems-CzV3PcJH.js} +1 -1
- package/package.json +3 -3
- package/dist/component-XHQYFLA_.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=require("vue");var t,n,r,o,i,a,l,s,c=Object.defineProperty,d=(e,t,n)=>((e,t,n)=>t in e?c(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n)(e,t+"",n);function u(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function p(){if(o)return r;o=1;const e=n?t:(n=1,t={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}),i={};for(const t of Object.keys(e))i[e[t]]=t;const a={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};r=a;for(const t of Object.keys(a)){if(!("channels"in a[t]))throw new Error("missing channels property: "+t);if(!("labels"in a[t]))throw new Error("missing channel labels property: "+t);if(a[t].labels.length!==a[t].channels)throw new Error("channel and label counts mismatch: "+t);const{channels:e,labels:n}=a[t];delete a[t].channels,delete a[t].labels,Object.defineProperty(a[t],"channels",{value:e}),Object.defineProperty(a[t],"labels",{value:n})}function l(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}return a.rgb.hsl=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,o=Math.min(t,n,r),i=Math.max(t,n,r),a=i-o;let l,s;i===o?l=0:t===i?l=(n-r)/a:n===i?l=2+(r-t)/a:r===i&&(l=4+(t-n)/a),l=Math.min(60*l,360),l<0&&(l+=360);const c=(o+i)/2;return s=i===o?0:c<=.5?a/(i+o):a/(2-i-o),[l,100*s,100*c]},a.rgb.hsv=function(e){let t,n,r,o,i;const a=e[0]/255,l=e[1]/255,s=e[2]/255,c=Math.max(a,l,s),d=c-Math.min(a,l,s),u=function(e){return(c-e)/6/d+.5};return 0===d?(o=0,i=0):(i=d/c,t=u(a),n=u(l),r=u(s),a===c?o=r-n:l===c?o=1/3+t-r:s===c&&(o=2/3+n-t),o<0?o+=1:o>1&&(o-=1)),[360*o,100*i,100*c]},a.rgb.hwb=function(e){const t=e[0],n=e[1];let r=e[2];const o=a.rgb.hsl(e)[0],i=1/255*Math.min(t,Math.min(n,r));return r=1-1/255*Math.max(t,Math.max(n,r)),[o,100*i,100*r]},a.rgb.cmyk=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,o=Math.min(1-t,1-n,1-r);return[100*((1-t-o)/(1-o)||0),100*((1-n-o)/(1-o)||0),100*((1-r-o)/(1-o)||0),100*o]},a.rgb.keyword=function(t){const n=i[t];if(n)return n;let r,o=1/0;for(const i of Object.keys(e)){const n=l(t,e[i]);n<o&&(o=n,r=i)}return r},a.keyword.rgb=function(t){return e[t]},a.rgb.xyz=function(e){let t=e[0]/255,n=e[1]/255,r=e[2]/255;t=t>.04045?((t+.055)/1.055)**2.4:t/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92;return[100*(.4124*t+.3576*n+.1805*r),100*(.2126*t+.7152*n+.0722*r),100*(.0193*t+.1192*n+.9505*r)]},a.rgb.lab=function(e){const t=a.rgb.xyz(e);let n=t[0],r=t[1],o=t[2];n/=95.047,r/=100,o/=108.883,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,o=o>.008856?o**(1/3):7.787*o+16/116;return[116*r-16,500*(n-r),200*(r-o)]},a.hsl.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;let o,i,a;if(0===n)return a=255*r,[a,a,a];o=r<.5?r*(1+n):r+n-r*n;const l=2*r-o,s=[0,0,0];for(let c=0;c<3;c++)i=t+1/3*-(c-1),i<0&&i++,i>1&&i--,a=6*i<1?l+6*(o-l)*i:2*i<1?o:3*i<2?l+(o-l)*(2/3-i)*6:l,s[c]=255*a;return s},a.hsl.hsv=function(e){const t=e[0];let n=e[1]/100,r=e[2]/100,o=n;const i=Math.max(r,.01);r*=2,n*=r<=1?r:2-r,o*=i<=1?i:2-i;return[t,100*(0===r?2*o/(i+o):2*n/(r+n)),100*((r+n)/2)]},a.hsv.rgb=function(e){const t=e[0]/60,n=e[1]/100;let r=e[2]/100;const o=Math.floor(t)%6,i=t-Math.floor(t),a=255*r*(1-n),l=255*r*(1-n*i),s=255*r*(1-n*(1-i));switch(r*=255,o){case 0:return[r,s,a];case 1:return[l,r,a];case 2:return[a,r,s];case 3:return[a,l,r];case 4:return[s,a,r];case 5:return[r,a,l]}},a.hsv.hsl=function(e){const t=e[0],n=e[1]/100,r=e[2]/100,o=Math.max(r,.01);let i,a;a=(2-n)*r;const l=(2-n)*o;return i=n*o,i/=l<=1?l:2-l,i=i||0,a/=2,[t,100*i,100*a]},a.hwb.rgb=function(e){const t=e[0]/360;let n=e[1]/100,r=e[2]/100;const o=n+r;let i;o>1&&(n/=o,r/=o);const a=Math.floor(6*t),l=1-r;i=6*t-a,1&a&&(i=1-i);const s=n+i*(l-n);let c,d,u;switch(a){default:case 6:case 0:c=l,d=s,u=n;break;case 1:c=s,d=l,u=n;break;case 2:c=n,d=l,u=s;break;case 3:c=n,d=s,u=l;break;case 4:c=s,d=n,u=l;break;case 5:c=l,d=n,u=s}return[255*c,255*d,255*u]},a.cmyk.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,o=e[3]/100;return[255*(1-Math.min(1,t*(1-o)+o)),255*(1-Math.min(1,n*(1-o)+o)),255*(1-Math.min(1,r*(1-o)+o))]},a.xyz.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100;let o,i,a;return o=3.2406*t+-1.5372*n+-.4986*r,i=-.9689*t+1.8758*n+.0415*r,a=.0557*t+-.204*n+1.057*r,o=o>.0031308?1.055*o**(1/2.4)-.055:12.92*o,i=i>.0031308?1.055*i**(1/2.4)-.055:12.92*i,a=a>.0031308?1.055*a**(1/2.4)-.055:12.92*a,o=Math.min(Math.max(0,o),1),i=Math.min(Math.max(0,i),1),a=Math.min(Math.max(0,a),1),[255*o,255*i,255*a]},a.xyz.lab=function(e){let t=e[0],n=e[1],r=e[2];t/=95.047,n/=100,r/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116;return[116*n-16,500*(t-n),200*(n-r)]},a.lab.xyz=function(e){let t,n,r;n=(e[0]+16)/116,t=e[1]/500+n,r=n-e[2]/200;const o=n**3,i=t**3,a=r**3;return n=o>.008856?o:(n-16/116)/7.787,t=i>.008856?i:(t-16/116)/7.787,r=a>.008856?a:(r-16/116)/7.787,t*=95.047,n*=100,r*=108.883,[t,n,r]},a.lab.lch=function(e){const t=e[0],n=e[1],r=e[2];let o;o=360*Math.atan2(r,n)/2/Math.PI,o<0&&(o+=360);return[t,Math.sqrt(n*n+r*r),o]},a.lch.lab=function(e){const t=e[0],n=e[1],r=e[2]/360*2*Math.PI;return[t,n*Math.cos(r),n*Math.sin(r)]},a.rgb.ansi16=function(e,t=null){const[n,r,o]=e;let i=null===t?a.rgb.hsv(e)[2]:t;if(i=Math.round(i/50),0===i)return 30;let l=30+(Math.round(o/255)<<2|Math.round(r/255)<<1|Math.round(n/255));return 2===i&&(l+=60),l},a.hsv.ansi16=function(e){return a.rgb.ansi16(a.hsv.rgb(e),e[2])},a.rgb.ansi256=function(e){const t=e[0],n=e[1],r=e[2];if(t===n&&n===r)return t<8?16:t>248?231:Math.round((t-8)/247*24)+232;return 16+36*Math.round(t/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5)},a.ansi16.rgb=function(e){let t=e%10;if(0===t||7===t)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];const n=.5*(1+~~(e>50));return[(1&t)*n*255,(t>>1&1)*n*255,(t>>2&1)*n*255]},a.ansi256.rgb=function(e){if(e>=232){const t=10*(e-232)+8;return[t,t,t]}let t;e-=16;return[Math.floor(e/36)/5*255,Math.floor((t=e%36)/6)/5*255,t%6/5*255]},a.rgb.hex=function(e){const t=(((255&Math.round(e[0]))<<16)+((255&Math.round(e[1]))<<8)+(255&Math.round(e[2]))).toString(16).toUpperCase();return"000000".substring(t.length)+t},a.hex.rgb=function(e){const t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];let n=t[0];3===t[0].length&&(n=n.split("").map(e=>e+e).join(""));const r=parseInt(n,16);return[r>>16&255,r>>8&255,255&r]},a.rgb.hcg=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,o=Math.max(Math.max(t,n),r),i=Math.min(Math.min(t,n),r),a=o-i;let l,s;return l=a<1?i/(1-a):0,s=a<=0?0:o===t?(n-r)/a%6:o===n?2+(r-t)/a:4+(t-n)/a,s/=6,s%=1,[360*s,100*a,100*l]},a.hsl.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=n<.5?2*t*n:2*t*(1-n);let o=0;return r<1&&(o=(n-.5*r)/(1-r)),[e[0],100*r,100*o]},a.hsv.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=t*n;let o=0;return r<1&&(o=(n-r)/(1-r)),[e[0],100*r,100*o]},a.hcg.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;if(0===n)return[255*r,255*r,255*r];const o=[0,0,0],i=t%1*6,a=i%1,l=1-a;let s=0;switch(Math.floor(i)){case 0:o[0]=1,o[1]=a,o[2]=0;break;case 1:o[0]=l,o[1]=1,o[2]=0;break;case 2:o[0]=0,o[1]=1,o[2]=a;break;case 3:o[0]=0,o[1]=l,o[2]=1;break;case 4:o[0]=a,o[1]=0,o[2]=1;break;default:o[0]=1,o[1]=0,o[2]=l}return s=(1-n)*r,[255*(n*o[0]+s),255*(n*o[1]+s),255*(n*o[2]+s)]},a.hcg.hsv=function(e){const t=e[1]/100,n=t+e[2]/100*(1-t);let r=0;return n>0&&(r=t/n),[e[0],100*r,100*n]},a.hcg.hsl=function(e){const t=e[1]/100,n=e[2]/100*(1-t)+.5*t;let r=0;return n>0&&n<.5?r=t/(2*n):n>=.5&&n<1&&(r=t/(2*(1-n))),[e[0],100*r,100*n]},a.hcg.hwb=function(e){const t=e[1]/100,n=t+e[2]/100*(1-t);return[e[0],100*(n-t),100*(1-n)]},a.hwb.hcg=function(e){const t=e[1]/100,n=1-e[2]/100,r=n-t;let o=0;return r<1&&(o=(n-r)/(1-r)),[e[0],100*r,100*o]},a.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]},a.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]},a.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]},a.gray.hsl=function(e){return[0,0,e[0]]},a.gray.hsv=a.gray.hsl,a.gray.hwb=function(e){return[0,100,e[0]]},a.gray.cmyk=function(e){return[0,0,0,e[0]]},a.gray.lab=function(e){return[e[0],0,0]},a.gray.hex=function(e){const t=255&Math.round(e[0]/100*255),n=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(n.length)+n},a.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]},r}function h(){if(a)return i;a=1;const e=p();function t(t){const n=function(){const t={},n=Object.keys(e);for(let e=n.length,r=0;r<e;r++)t[n[r]]={distance:-1,parent:null};return t}(),r=[t];for(n[t].distance=0;r.length;){const t=r.pop(),o=Object.keys(e[t]);for(let e=o.length,i=0;i<e;i++){const e=o[i],a=n[e];-1===a.distance&&(a.distance=n[t].distance+1,a.parent=t,r.unshift(e))}}return n}function n(e,t){return function(n){return t(e(n))}}function r(t,r){const o=[r[t].parent,t];let i=e[r[t].parent][t],a=r[t].parent;for(;r[a].parent;)o.unshift(r[a].parent),i=n(e[r[a].parent][a],i),a=r[a].parent;return i.conversion=o,i}return i=function(e){const n=t(e),o={},i=Object.keys(n);for(let t=i.length,a=0;a<t;a++){const e=i[a];null!==n[e].parent&&(o[e]=r(e,n))}return o},i}var m=function(){if(s)return l;s=1;const e=p(),t=h(),n={};return Object.keys(e).forEach(r=>{n[r]={},Object.defineProperty(n[r],"channels",{value:e[r].channels}),Object.defineProperty(n[r],"labels",{value:e[r].labels});const o=t(r);Object.keys(o).forEach(e=>{const t=o[e];n[r][e]=function(e){const t=function(...t){const n=t[0];if(null==n)return n;n.length>1&&(t=n);const r=e(t);if("object"==typeof r)for(let e=r.length,o=0;o<e;o++)r[o]=Math.round(r[o]);return r};return"conversion"in e&&(t.conversion=e.conversion),t}(t),n[r][e].raw=function(e){const t=function(...t){const n=t[0];return null==n?n:(n.length>1&&(t=n),e(t))};return"conversion"in e&&(t.conversion=e.conversion),t}(t)})}),l=n}();const f=u(m);var g=function(e,t){return(g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)};function v(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}g(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var y=function(){return y=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},y.apply(this,arguments)};function b(e,t,n){if(2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}function w(e,t){var n=t&&t.cache?t.cache:z,r=t&&t.serializer?t.serializer:V;return(t&&t.strategy?t.strategy:C)(e,{cache:n,serializer:r})}function k(e,t,n,r){var o,i=null==(o=r)||"number"==typeof o||"boolean"==typeof o?r:n(r),a=t.get(i);return void 0===a&&(a=e.call(this,r),t.set(i,a)),a}function x(e,t,n){var r=Array.prototype.slice.call(arguments,3),o=n(r),i=t.get(o);return void 0===i&&(i=e.apply(this,r),t.set(o,i)),i}function _(e,t,n,r,o){return n.bind(t,e,r,o)}function C(e,t){return _(e,this,1===e.length?k:x,t.cache.create(),t.serializer)}"function"==typeof SuppressedError&&SuppressedError;var E,S,B,N,M,T,V=function(){return JSON.stringify(arguments)},A=function(){function e(){this.cache=Object.create(null)}return e.prototype.get=function(e){return this.cache[e]},e.prototype.set=function(e,t){this.cache[e]=t},e}(),z={create:function(){return new A}},O={variadic:function(e,t){return _(e,this,x,t.cache.create(),t.serializer)}};function I(e){return e.type===B.literal}function D(e){return e.type===B.argument}function P(e){return e.type===B.number}function $(e){return e.type===B.date}function L(e){return e.type===B.time}function R(e){return e.type===B.select}function H(e){return e.type===B.plural}function F(e){return e.type===B.pound}function j(e){return e.type===B.tag}function U(e){return!(!e||"object"!=typeof e||e.type!==M.number)}function G(e){return!(!e||"object"!=typeof e||e.type!==M.dateTime)}(S=E||(E={}))[S.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",S[S.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",S[S.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",S[S.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",S[S.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",S[S.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",S[S.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",S[S.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",S[S.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",S[S.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",S[S.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",S[S.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",S[S.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",S[S.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",S[S.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",S[S.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",S[S.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",S[S.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",S[S.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",S[S.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",S[S.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",S[S.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",S[S.INVALID_TAG=23]="INVALID_TAG",S[S.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",S[S.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",S[S.UNCLOSED_TAG=27]="UNCLOSED_TAG",(N=B||(B={}))[N.literal=0]="literal",N[N.argument=1]="argument",N[N.number=2]="number",N[N.date=3]="date",N[N.time=4]="time",N[N.select=5]="select",N[N.plural=6]="plural",N[N.pound=7]="pound",N[N.tag=8]="tag",(T=M||(M={}))[T.number=0]="number",T[T.dateTime=1]="dateTime";var q=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,Z=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function W(e){var t={};return e.replace(Z,function(e){var n=e.length;switch(e[0]){case"G":t.era=4===n?"long":5===n?"narrow":"short";break;case"y":t.year=2===n?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":t.month=["numeric","2-digit","short","long","narrow"][n-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":t.day=["numeric","2-digit"][n-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":t.weekday=4===n?"long":5===n?"narrow":"short";break;case"e":if(n<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][n-4];break;case"c":if(n<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][n-4];break;case"a":t.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":t.hourCycle="h12",t.hour=["numeric","2-digit"][n-1];break;case"H":t.hourCycle="h23",t.hour=["numeric","2-digit"][n-1];break;case"K":t.hourCycle="h11",t.hour=["numeric","2-digit"][n-1];break;case"k":t.hourCycle="h24",t.hour=["numeric","2-digit"][n-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":t.minute=["numeric","2-digit"][n-1];break;case"s":t.second=["numeric","2-digit"][n-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":t.timeZoneName=n<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""}),t}var K=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;function J(e){return e.replace(/^(.*?)-/,"")}var Y=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,X=/^(@+)?(\+|#+)?[rs]?$/g,Q=/(\*)(0+)|(#+)(0+)|(0+)/g,ee=/^(0+)$/;function te(e){var t={};return"r"===e[e.length-1]?t.roundingPriority="morePrecision":"s"===e[e.length-1]&&(t.roundingPriority="lessPrecision"),e.replace(X,function(e,n,r){return"string"!=typeof r?(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length):"+"===r?t.minimumSignificantDigits=n.length:"#"===n[0]?t.maximumSignificantDigits=n.length:(t.minimumSignificantDigits=n.length,t.maximumSignificantDigits=n.length+("string"==typeof r?r.length:0)),""}),t}function ne(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function re(e){var t;if("E"===e[0]&&"E"===e[1]?(t={notation:"engineering"},e=e.slice(2)):"E"===e[0]&&(t={notation:"scientific"},e=e.slice(1)),t){var n=e.slice(0,2);if("+!"===n?(t.signDisplay="always",e=e.slice(2)):"+?"===n&&(t.signDisplay="exceptZero",e=e.slice(2)),!ee.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function oe(e){var t=ne(e);return t||{}}function ie(e){for(var t={},n=0,r=e;n<r.length;n++){var o=r[n];switch(o.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=o.options[0];continue;case"group-off":case",_":t.useGrouping=!1;continue;case"precision-integer":case".":t.maximumFractionDigits=0;continue;case"measure-unit":case"unit":t.style="unit",t.unit=J(o.options[0]);continue;case"compact-short":case"K":t.notation="compact",t.compactDisplay="short";continue;case"compact-long":case"KK":t.notation="compact",t.compactDisplay="long";continue;case"scientific":t=y(y(y({},t),{notation:"scientific"}),o.options.reduce(function(e,t){return y(y({},e),oe(t))},{}));continue;case"engineering":t=y(y(y({},t),{notation:"engineering"}),o.options.reduce(function(e,t){return y(y({},e),oe(t))},{}));continue;case"notation-simple":t.notation="standard";continue;case"unit-width-narrow":t.currencyDisplay="narrowSymbol",t.unitDisplay="narrow";continue;case"unit-width-short":t.currencyDisplay="code",t.unitDisplay="short";continue;case"unit-width-full-name":t.currencyDisplay="name",t.unitDisplay="long";continue;case"unit-width-iso-code":t.currencyDisplay="symbol";continue;case"scale":t.scale=parseFloat(o.options[0]);continue;case"rounding-mode-floor":t.roundingMode="floor";continue;case"rounding-mode-ceiling":t.roundingMode="ceil";continue;case"rounding-mode-down":t.roundingMode="trunc";continue;case"rounding-mode-up":t.roundingMode="expand";continue;case"rounding-mode-half-even":t.roundingMode="halfEven";continue;case"rounding-mode-half-down":t.roundingMode="halfTrunc";continue;case"rounding-mode-half-up":t.roundingMode="halfExpand";continue;case"integer-width":if(o.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");o.options[0].replace(Q,function(e,n,r,o,i,a){if(n)t.minimumIntegerDigits=r.length;else{if(o&&i)throw new Error("We currently do not support maximum integer digits");if(a)throw new Error("We currently do not support exact integer digits")}return""});continue}if(ee.test(o.stem))t.minimumIntegerDigits=o.stem.length;else if(Y.test(o.stem)){if(o.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");o.stem.replace(Y,function(e,n,r,o,i,a){return"*"===r?t.minimumFractionDigits=n.length:o&&"#"===o[0]?t.maximumFractionDigits=o.length:i&&a?(t.minimumFractionDigits=i.length,t.maximumFractionDigits=i.length+a.length):(t.minimumFractionDigits=n.length,t.maximumFractionDigits=n.length),""});var i=o.options[0];"w"===i?t=y(y({},t),{trailingZeroDisplay:"stripIfInteger"}):i&&(t=y(y({},t),te(i)))}else if(X.test(o.stem))t=y(y({},t),te(o.stem));else{var a=ne(o.stem);a&&(t=y(y({},t),a));var l=re(o.stem);l&&(t=y(y({},t),l))}}return t}var ae,le={"001":["H","h"],419:["h","H","hB","hb"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["h","H","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["h","H","hB","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["h","H","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["h","H","hB","hb"],CU:["h","H","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["h","H","hB","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["h","H","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["h","H","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["h","H","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["h","H","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["h","H","hB","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["h","H","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["h","H","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["h","H","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"en-HK":["h","hb","H","hB"],"en-IL":["H","h","hb","hB"],"en-MY":["h","hb","H","hB"],"es-BR":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]};function se(e){var t=e.hourCycle;if(void 0===t&&e.hourCycles&&e.hourCycles.length&&(t=e.hourCycles[0]),t)switch(t){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw new Error("Invalid hourCycle")}var n,r=e.language;return"root"!==r&&(n=e.maximize().region),(le[n||""]||le[r||""]||le["".concat(r,"-001")]||le["001"])[0]}var ce=new RegExp("^".concat(q.source,"*")),de=new RegExp("".concat(q.source,"*$"));function ue(e,t){return{start:e,end:t}}var pe=!!String.prototype.startsWith&&"_a".startsWith("a",1),he=!!String.fromCodePoint,me=!!Object.fromEntries,fe=!!String.prototype.codePointAt,ge=!!String.prototype.trimStart,ve=!!String.prototype.trimEnd,ye=!!Number.isSafeInteger?Number.isSafeInteger:function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},be=!0;try{be="a"===(null===(ae=Be("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu").exec("a"))||void 0===ae?void 0:ae[0])}catch(pR){be=!1}var we,ke=pe?function(e,t,n){return e.startsWith(t,n)}:function(e,t,n){return e.slice(n,n+t.length)===t},xe=he?String.fromCodePoint:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n,r="",o=e.length,i=0;o>i;){if((n=e[i++])>1114111)throw RangeError(n+" is not a valid code point");r+=n<65536?String.fromCharCode(n):String.fromCharCode(55296+((n-=65536)>>10),n%1024+56320)}return r},_e=me?Object.fromEntries:function(e){for(var t={},n=0,r=e;n<r.length;n++){var o=r[n],i=o[0],a=o[1];t[i]=a}return t},Ce=fe?function(e,t){return e.codePointAt(t)}:function(e,t){var n=e.length;if(!(t<0||t>=n)){var r,o=e.charCodeAt(t);return o<55296||o>56319||t+1===n||(r=e.charCodeAt(t+1))<56320||r>57343?o:r-56320+(o-55296<<10)+65536}},Ee=ge?function(e){return e.trimStart()}:function(e){return e.replace(ce,"")},Se=ve?function(e){return e.trimEnd()}:function(e){return e.replace(de,"")};function Be(e,t){return new RegExp(e,t)}if(be){var Ne=Be("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");we=function(e,t){var n;return Ne.lastIndex=t,null!==(n=Ne.exec(e)[1])&&void 0!==n?n:""}}else we=function(e,t){for(var n=[];;){var r=Ce(e,t);if(void 0===r||Oe(r)||Ie(r))break;n.push(r),t+=r>=65536?2:1}return xe.apply(void 0,n)};var Me,Te,Ve=function(){function e(e,t){void 0===t&&(t={}),this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.locale=t.locale,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}return e.prototype.parse=function(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},e.prototype.parseMessage=function(e,t,n){for(var r=[];!this.isEOF();){var o=this.char();if(123===o){if((i=this.parseArgument(e,n)).err)return i;r.push(i.val)}else{if(125===o&&e>0)break;if(35!==o||"plural"!==t&&"selectordinal"!==t){if(60===o&&!this.ignoreTag&&47===this.peek()){if(n)break;return this.error(E.UNMATCHED_CLOSING_TAG,ue(this.clonePosition(),this.clonePosition()))}if(60===o&&!this.ignoreTag&&Ae(this.peek()||0)){if((i=this.parseTag(e,t)).err)return i;r.push(i.val)}else{var i;if((i=this.parseLiteral(e,t)).err)return i;r.push(i.val)}}else{var a=this.clonePosition();this.bump(),r.push({type:B.pound,location:ue(a,this.clonePosition())})}}}return{val:r,err:null}},e.prototype.parseTag=function(e,t){var n=this.clonePosition();this.bump();var r=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:B.literal,value:"<".concat(r,"/>"),location:ue(n,this.clonePosition())},err:null};if(this.bumpIf(">")){var o=this.parseMessage(e+1,t,!0);if(o.err)return o;var i=o.val,a=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!Ae(this.char()))return this.error(E.INVALID_TAG,ue(a,this.clonePosition()));var l=this.clonePosition();return r!==this.parseTagName()?this.error(E.UNMATCHED_CLOSING_TAG,ue(l,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:B.tag,value:r,children:i,location:ue(n,this.clonePosition())},err:null}:this.error(E.INVALID_TAG,ue(a,this.clonePosition())))}return this.error(E.UNCLOSED_TAG,ue(n,this.clonePosition()))}return this.error(E.INVALID_TAG,ue(n,this.clonePosition()))},e.prototype.parseTagName=function(){var e=this.offset();for(this.bump();!this.isEOF()&&ze(this.char());)this.bump();return this.message.slice(e,this.offset())},e.prototype.parseLiteral=function(e,t){for(var n=this.clonePosition(),r="";;){var o=this.tryParseQuote(t);if(o)r+=o;else{var i=this.tryParseUnquoted(e,t);if(i)r+=i;else{var a=this.tryParseLeftAngleBracket();if(!a)break;r+=a}}}var l=ue(n,this.clonePosition());return{val:{type:B.literal,value:r,location:l},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return this.isEOF()||60!==this.char()||!this.ignoreTag&&(Ae(e=this.peek()||0)||47===e)?null:(this.bump(),"<");var e},e.prototype.tryParseQuote=function(e){if(this.isEOF()||39!==this.char())return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if("plural"===e||"selectordinal"===e)break;return null;default:return null}this.bump();var t=[this.char()];for(this.bump();!this.isEOF();){var n=this.char();if(39===n){if(39!==this.peek()){this.bump();break}t.push(39),this.bump()}else t.push(n);this.bump()}return xe.apply(void 0,t)},e.prototype.tryParseUnquoted=function(e,t){if(this.isEOF())return null;var n=this.char();return 60===n||123===n||35===n&&("plural"===t||"selectordinal"===t)||125===n&&e>0?null:(this.bump(),xe(n))},e.prototype.parseArgument=function(e,t){var n=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(E.EXPECT_ARGUMENT_CLOSING_BRACE,ue(n,this.clonePosition()));if(125===this.char())return this.bump(),this.error(E.EMPTY_ARGUMENT,ue(n,this.clonePosition()));var r=this.parseIdentifierIfPossible().value;if(!r)return this.error(E.MALFORMED_ARGUMENT,ue(n,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(E.EXPECT_ARGUMENT_CLOSING_BRACE,ue(n,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:B.argument,value:r,location:ue(n,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(E.EXPECT_ARGUMENT_CLOSING_BRACE,ue(n,this.clonePosition())):this.parseArgumentOptions(e,t,r,n);default:return this.error(E.MALFORMED_ARGUMENT,ue(n,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),n=we(this.message,t),r=t+n.length;return this.bumpTo(r),{value:n,location:ue(e,this.clonePosition())}},e.prototype.parseArgumentOptions=function(e,t,n,r){var o,i=this.clonePosition(),a=this.parseIdentifierIfPossible().value,l=this.clonePosition();switch(a){case"":return this.error(E.EXPECT_ARGUMENT_TYPE,ue(i,l));case"number":case"date":case"time":this.bumpSpace();var s=null;if(this.bumpIf(",")){this.bumpSpace();var c=this.clonePosition();if((v=this.parseSimpleArgStyleIfPossible()).err)return v;if(0===(h=Se(v.val)).length)return this.error(E.EXPECT_ARGUMENT_STYLE,ue(this.clonePosition(),this.clonePosition()));s={style:h,styleLocation:ue(c,this.clonePosition())}}if((b=this.tryParseArgumentClose(r)).err)return b;var d=ue(r,this.clonePosition());if(s&&ke(null==s?void 0:s.style,"::",0)){var u=Ee(s.style.slice(2));if("number"===a)return(v=this.parseNumberSkeletonFromString(u,s.styleLocation)).err?v:{val:{type:B.number,value:n,location:d,style:v.val},err:null};if(0===u.length)return this.error(E.EXPECT_DATE_TIME_SKELETON,d);var p=u;this.locale&&(p=function(e,t){for(var n="",r=0;r<e.length;r++){var o=e.charAt(r);if("j"===o){for(var i=0;r+1<e.length&&e.charAt(r+1)===o;)i++,r++;var a=1+(1&i),l=i<2?1:3+(i>>1),s=se(t);for("H"!=s&&"k"!=s||(l=0);l-- >0;)n+="a";for(;a-- >0;)n=s+n}else n+="J"===o?"H":o}return n}(u,this.locale));var h={type:M.dateTime,pattern:p,location:s.styleLocation,parsedOptions:this.shouldParseSkeletons?W(p):{}};return{val:{type:"date"===a?B.date:B.time,value:n,location:d,style:h},err:null}}return{val:{type:"number"===a?B.number:"date"===a?B.date:B.time,value:n,location:d,style:null!==(o=null==s?void 0:s.style)&&void 0!==o?o:null},err:null};case"plural":case"selectordinal":case"select":var m=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(E.EXPECT_SELECT_ARGUMENT_OPTIONS,ue(m,y({},m)));this.bumpSpace();var f=this.parseIdentifierIfPossible(),g=0;if("select"!==a&&"offset"===f.value){if(!this.bumpIf(":"))return this.error(E.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,ue(this.clonePosition(),this.clonePosition()));var v;if(this.bumpSpace(),(v=this.tryParseDecimalInteger(E.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,E.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE)).err)return v;this.bumpSpace(),f=this.parseIdentifierIfPossible(),g=v.val}var b,w=this.tryParsePluralOrSelectOptions(e,a,t,f);if(w.err)return w;if((b=this.tryParseArgumentClose(r)).err)return b;var k=ue(r,this.clonePosition());return"select"===a?{val:{type:B.select,value:n,options:_e(w.val),location:k},err:null}:{val:{type:B.plural,value:n,options:_e(w.val),offset:g,pluralType:"plural"===a?"cardinal":"ordinal",location:k},err:null};default:return this.error(E.INVALID_ARGUMENT_TYPE,ue(i,l))}},e.prototype.tryParseArgumentClose=function(e){return this.isEOF()||125!==this.char()?this.error(E.EXPECT_ARGUMENT_CLOSING_BRACE,ue(e,this.clonePosition())):(this.bump(),{val:!0,err:null})},e.prototype.parseSimpleArgStyleIfPossible=function(){for(var e=0,t=this.clonePosition();!this.isEOF();){switch(this.char()){case 39:this.bump();var n=this.clonePosition();if(!this.bumpUntil("'"))return this.error(E.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,ue(n,this.clonePosition()));this.bump();break;case 123:e+=1,this.bump();break;case 125:if(!(e>0))return{val:this.message.slice(t.offset,this.offset()),err:null};e-=1;break;default:this.bump()}}return{val:this.message.slice(t.offset,this.offset()),err:null}},e.prototype.parseNumberSkeletonFromString=function(e,t){var n=[];try{n=function(e){if(0===e.length)throw new Error("Number skeleton cannot be empty");for(var t=[],n=0,r=e.split(K).filter(function(e){return e.length>0});n<r.length;n++){var o=r[n].split("/");if(0===o.length)throw new Error("Invalid number skeleton");for(var i=o[0],a=o.slice(1),l=0,s=a;l<s.length;l++)if(0===s[l].length)throw new Error("Invalid number skeleton");t.push({stem:i,options:a})}return t}(e)}catch(r){return this.error(E.INVALID_NUMBER_SKELETON,t)}return{val:{type:M.number,tokens:n,location:t,parsedOptions:this.shouldParseSkeletons?ie(n):{}},err:null}},e.prototype.tryParsePluralOrSelectOptions=function(e,t,n,r){for(var o,i=!1,a=[],l=new Set,s=r.value,c=r.location;;){if(0===s.length){var d=this.clonePosition();if("select"===t||!this.bumpIf("="))break;var u=this.tryParseDecimalInteger(E.EXPECT_PLURAL_ARGUMENT_SELECTOR,E.INVALID_PLURAL_ARGUMENT_SELECTOR);if(u.err)return u;c=ue(d,this.clonePosition()),s=this.message.slice(d.offset,this.offset())}if(l.has(s))return this.error("select"===t?E.DUPLICATE_SELECT_ARGUMENT_SELECTOR:E.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,c);"other"===s&&(i=!0),this.bumpSpace();var p=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===t?E.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:E.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,ue(this.clonePosition(),this.clonePosition()));var h=this.parseMessage(e+1,t,n);if(h.err)return h;var m=this.tryParseArgumentClose(p);if(m.err)return m;a.push([s,{value:h.val,location:ue(p,this.clonePosition())}]),l.add(s),this.bumpSpace(),s=(o=this.parseIdentifierIfPossible()).value,c=o.location}return 0===a.length?this.error("select"===t?E.EXPECT_SELECT_ARGUMENT_SELECTOR:E.EXPECT_PLURAL_ARGUMENT_SELECTOR,ue(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!i?this.error(E.MISSING_OTHER_CLAUSE,ue(this.clonePosition(),this.clonePosition())):{val:a,err:null}},e.prototype.tryParseDecimalInteger=function(e,t){var n=1,r=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(n=-1);for(var o=!1,i=0;!this.isEOF();){var a=this.char();if(!(a>=48&&a<=57))break;o=!0,i=10*i+(a-48),this.bump()}var l=ue(r,this.clonePosition());return o?ye(i*=n)?{val:i,err:null}:this.error(t,l):this.error(e,l)},e.prototype.offset=function(){return this.position.offset},e.prototype.isEOF=function(){return this.offset()===this.message.length},e.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},e.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=Ce(this.message,e);if(void 0===t)throw Error("Offset ".concat(e," is at invalid UTF-16 code unit boundary"));return t},e.prototype.error=function(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}},e.prototype.bump=function(){if(!this.isEOF()){var e=this.char();10===e?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e<65536?1:2)}},e.prototype.bumpIf=function(e){if(ke(this.message,e,this.offset())){for(var t=0;t<e.length;t++)this.bump();return!0}return!1},e.prototype.bumpUntil=function(e){var t=this.offset(),n=this.message.indexOf(e,t);return n>=0?(this.bumpTo(n),!0):(this.bumpTo(this.message.length),!1)},e.prototype.bumpTo=function(e){if(this.offset()>e)throw Error("targetOffset ".concat(e," must be greater than or equal to the current offset ").concat(this.offset()));for(e=Math.min(e,this.message.length);;){var t=this.offset();if(t===e)break;if(t>e)throw Error("targetOffset ".concat(e," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},e.prototype.bumpSpace=function(){for(;!this.isEOF()&&Oe(this.char());)this.bump()},e.prototype.peek=function(){if(this.isEOF())return null;var e=this.char(),t=this.offset(),n=this.message.charCodeAt(t+(e>=65536?2:1));return null!=n?n:null},e}();function Ae(e){return e>=97&&e<=122||e>=65&&e<=90}function ze(e){return 45===e||46===e||e>=48&&e<=57||95===e||e>=97&&e<=122||e>=65&&e<=90||183==e||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8255&&e<=8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=65536&&e<=983039}function Oe(e){return e>=9&&e<=13||32===e||133===e||e>=8206&&e<=8207||8232===e||8233===e}function Ie(e){return e>=33&&e<=35||36===e||e>=37&&e<=39||40===e||41===e||42===e||43===e||44===e||45===e||e>=46&&e<=47||e>=58&&e<=59||e>=60&&e<=62||e>=63&&e<=64||91===e||92===e||93===e||94===e||96===e||123===e||124===e||125===e||126===e||161===e||e>=162&&e<=165||166===e||167===e||169===e||171===e||172===e||174===e||176===e||177===e||182===e||187===e||191===e||215===e||247===e||e>=8208&&e<=8213||e>=8214&&e<=8215||8216===e||8217===e||8218===e||e>=8219&&e<=8220||8221===e||8222===e||8223===e||e>=8224&&e<=8231||e>=8240&&e<=8248||8249===e||8250===e||e>=8251&&e<=8254||e>=8257&&e<=8259||8260===e||8261===e||8262===e||e>=8263&&e<=8273||8274===e||8275===e||e>=8277&&e<=8286||e>=8592&&e<=8596||e>=8597&&e<=8601||e>=8602&&e<=8603||e>=8604&&e<=8607||8608===e||e>=8609&&e<=8610||8611===e||e>=8612&&e<=8613||8614===e||e>=8615&&e<=8621||8622===e||e>=8623&&e<=8653||e>=8654&&e<=8655||e>=8656&&e<=8657||8658===e||8659===e||8660===e||e>=8661&&e<=8691||e>=8692&&e<=8959||e>=8960&&e<=8967||8968===e||8969===e||8970===e||8971===e||e>=8972&&e<=8991||e>=8992&&e<=8993||e>=8994&&e<=9e3||9001===e||9002===e||e>=9003&&e<=9083||9084===e||e>=9085&&e<=9114||e>=9115&&e<=9139||e>=9140&&e<=9179||e>=9180&&e<=9185||e>=9186&&e<=9254||e>=9255&&e<=9279||e>=9280&&e<=9290||e>=9291&&e<=9311||e>=9472&&e<=9654||9655===e||e>=9656&&e<=9664||9665===e||e>=9666&&e<=9719||e>=9720&&e<=9727||e>=9728&&e<=9838||9839===e||e>=9840&&e<=10087||10088===e||10089===e||10090===e||10091===e||10092===e||10093===e||10094===e||10095===e||10096===e||10097===e||10098===e||10099===e||10100===e||10101===e||e>=10132&&e<=10175||e>=10176&&e<=10180||10181===e||10182===e||e>=10183&&e<=10213||10214===e||10215===e||10216===e||10217===e||10218===e||10219===e||10220===e||10221===e||10222===e||10223===e||e>=10224&&e<=10239||e>=10240&&e<=10495||e>=10496&&e<=10626||10627===e||10628===e||10629===e||10630===e||10631===e||10632===e||10633===e||10634===e||10635===e||10636===e||10637===e||10638===e||10639===e||10640===e||10641===e||10642===e||10643===e||10644===e||10645===e||10646===e||10647===e||10648===e||e>=10649&&e<=10711||10712===e||10713===e||10714===e||10715===e||e>=10716&&e<=10747||10748===e||10749===e||e>=10750&&e<=11007||e>=11008&&e<=11055||e>=11056&&e<=11076||e>=11077&&e<=11078||e>=11079&&e<=11084||e>=11085&&e<=11123||e>=11124&&e<=11125||e>=11126&&e<=11157||11158===e||e>=11159&&e<=11263||e>=11776&&e<=11777||11778===e||11779===e||11780===e||11781===e||e>=11782&&e<=11784||11785===e||11786===e||11787===e||11788===e||11789===e||e>=11790&&e<=11798||11799===e||e>=11800&&e<=11801||11802===e||11803===e||11804===e||11805===e||e>=11806&&e<=11807||11808===e||11809===e||11810===e||11811===e||11812===e||11813===e||11814===e||11815===e||11816===e||11817===e||e>=11818&&e<=11822||11823===e||e>=11824&&e<=11833||e>=11834&&e<=11835||e>=11836&&e<=11839||11840===e||11841===e||11842===e||e>=11843&&e<=11855||e>=11856&&e<=11857||11858===e||e>=11859&&e<=11903||e>=12289&&e<=12291||12296===e||12297===e||12298===e||12299===e||12300===e||12301===e||12302===e||12303===e||12304===e||12305===e||e>=12306&&e<=12307||12308===e||12309===e||12310===e||12311===e||12312===e||12313===e||12314===e||12315===e||12316===e||12317===e||e>=12318&&e<=12319||12320===e||12336===e||64830===e||64831===e||e>=65093&&e<=65094}function De(e){e.forEach(function(e){if(delete e.location,R(e)||H(e))for(var t in e.options)delete e.options[t].location,De(e.options[t].value);else P(e)&&U(e.style)||($(e)||L(e))&&G(e.style)?delete e.style.location:j(e)&&De(e.children)})}function Pe(e,t){void 0===t&&(t={}),t=y({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var n=new Ve(e,t).parse();if(n.err){var r=SyntaxError(E[n.err.kind]);throw r.location=n.err.location,r.originalMessage=n.err.message,r}return(null==t?void 0:t.captureLocation)||De(n.val),n.val}(Te=Me||(Me={})).MISSING_VALUE="MISSING_VALUE",Te.INVALID_VALUE="INVALID_VALUE",Te.MISSING_INTL_API="MISSING_INTL_API";var $e,Le,Re=function(e){function t(t,n,r){var o=e.call(this,t)||this;return o.code=n,o.originalMessage=r,o}return v(t,e),t.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},t}(Error),He=function(e){function t(t,n,r,o){return e.call(this,'Invalid values for "'.concat(t,'": "').concat(n,'". Options are "').concat(Object.keys(r).join('", "'),'"'),Me.INVALID_VALUE,o)||this}return v(t,e),t}(Re),Fe=function(e){function t(t,n,r){return e.call(this,'Value for "'.concat(t,'" must be of type ').concat(n),Me.INVALID_VALUE,r)||this}return v(t,e),t}(Re),je=function(e){function t(t,n){return e.call(this,'The intl string context variable "'.concat(t,'" was not provided to the string "').concat(n,'"'),Me.MISSING_VALUE,n)||this}return v(t,e),t}(Re);function Ue(e){return"function"==typeof e}function Ge(e,t,n,r,o,i,a){if(1===e.length&&I(e[0]))return[{type:$e.literal,value:e[0].value}];for(var l=[],s=0,c=e;s<c.length;s++){var d=c[s];if(I(d))l.push({type:$e.literal,value:d.value});else if(F(d))"number"==typeof i&&l.push({type:$e.literal,value:n.getNumberFormat(t).format(i)});else{var u=d.value;if(!o||!(u in o))throw new je(u,a);var p=o[u];if(D(d))p&&"string"!=typeof p&&"number"!=typeof p||(p="string"==typeof p||"number"==typeof p?String(p):""),l.push({type:"string"==typeof p?$e.literal:$e.object,value:p});else if($(d)){var h="string"==typeof d.style?r.date[d.style]:G(d.style)?d.style.parsedOptions:void 0;l.push({type:$e.literal,value:n.getDateTimeFormat(t,h).format(p)})}else if(L(d)){h="string"==typeof d.style?r.time[d.style]:G(d.style)?d.style.parsedOptions:r.time.medium;l.push({type:$e.literal,value:n.getDateTimeFormat(t,h).format(p)})}else if(P(d)){(h="string"==typeof d.style?r.number[d.style]:U(d.style)?d.style.parsedOptions:void 0)&&h.scale&&(p*=h.scale||1),l.push({type:$e.literal,value:n.getNumberFormat(t,h).format(p)})}else{if(j(d)){var m=d.children,f=d.value,g=o[f];if(!Ue(g))throw new Fe(f,"function",a);var v=g(Ge(m,t,n,r,o,i).map(function(e){return e.value}));Array.isArray(v)||(v=[v]),l.push.apply(l,v.map(function(e){return{type:"string"==typeof e?$e.literal:$e.object,value:e}}))}if(R(d)){if(!(y=d.options[p]||d.options.other))throw new He(d.value,p,Object.keys(d.options),a);l.push.apply(l,Ge(y.value,t,n,r,o))}else if(H(d)){var y;if(!(y=d.options["=".concat(p)])){if(!Intl.PluralRules)throw new Re('Intl.PluralRules is not available in this environment.\nTry polyfilling it using "@formatjs/intl-pluralrules"\n',Me.MISSING_INTL_API,a);var b=n.getPluralRules(t,{type:d.pluralType}).select(p-(d.offset||0));y=d.options[b]||d.options.other}if(!y)throw new He(d.value,p,Object.keys(d.options),a);l.push.apply(l,Ge(y.value,t,n,r,o,p-(d.offset||0)))}else;}}}return function(e){return e.length<2?e:e.reduce(function(e,t){var n=e[e.length-1];return n&&n.type===$e.literal&&t.type===$e.literal?n.value+=t.value:e.push(t),e},[])}(l)}function qe(e,t){return t?Object.keys(e).reduce(function(n,r){var o,i;return n[r]=(o=e[r],(i=t[r])?y(y(y({},o||{}),i||{}),Object.keys(o).reduce(function(e,t){return e[t]=y(y({},o[t]),i[t]||{}),e},{})):o),n},y({},e)):e}function Ze(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}(Le=$e||($e={}))[Le.literal=0]="literal",Le[Le.object=1]="object";var We,Ke,Je=function(){function e(t,n,r,o){void 0===n&&(n=e.defaultLocale);var i,a=this;if(this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(e){var t=a.formatToParts(e);if(1===t.length)return t[0].value;var n=t.reduce(function(e,t){return e.length&&t.type===$e.literal&&"string"==typeof e[e.length-1]?e[e.length-1]+=t.value:e.push(t.value),e},[]);return n.length<=1?n[0]||"":n},this.formatToParts=function(e){return Ge(a.ast,a.locales,a.formatters,a.formats,e,void 0,a.message)},this.resolvedOptions=function(){var e;return{locale:(null===(e=a.resolvedLocale)||void 0===e?void 0:e.toString())||Intl.NumberFormat.supportedLocalesOf(a.locales)[0]}},this.getAst=function(){return a.ast},this.locales=n,this.resolvedLocale=e.resolveLocale(n),"string"==typeof t){if(this.message=t,!e.__parse)throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");var l=o||{};l.formatters;var s=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}(l,["formatters"]);this.ast=e.__parse(t,y(y({},s),{locale:this.resolvedLocale}))}else this.ast=t;if(!Array.isArray(this.ast))throw new TypeError("A message must be provided as a String or AST.");this.formats=qe(e.formats,r),this.formatters=o&&o.formatters||(void 0===(i=this.formatterCache)&&(i={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:w(function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.NumberFormat).bind.apply(e,b([void 0],t,!1)))},{cache:Ze(i.number),strategy:O.variadic}),getDateTimeFormat:w(function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.DateTimeFormat).bind.apply(e,b([void 0],t,!1)))},{cache:Ze(i.dateTime),strategy:O.variadic}),getPluralRules:w(function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.PluralRules).bind.apply(e,b([void 0],t,!1)))},{cache:Ze(i.pluralRules),strategy:O.variadic})})}return Object.defineProperty(e,"defaultLocale",{get:function(){return e.memoizedDefaultLocale||(e.memoizedDefaultLocale=(new Intl.NumberFormat).resolvedOptions().locale),e.memoizedDefaultLocale},enumerable:!1,configurable:!0}),e.memoizedDefaultLocale=null,e.resolveLocale=function(e){if(void 0!==Intl.Locale){var t=Intl.NumberFormat.supportedLocalesOf(e);return t.length>0?new Intl.Locale(t[0]):new Intl.Locale("string"==typeof e?e:e[0])}},e.__parse=Pe,e.formats={number:{integer:{maximumFractionDigits:0},currency:{style:"currency"},percent:{style:"percent"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},e}();(Ke=We||(We={})).FORMAT_ERROR="FORMAT_ERROR",Ke.UNSUPPORTED_FORMATTER="UNSUPPORTED_FORMATTER",Ke.INVALID_CONFIG="INVALID_CONFIG",Ke.MISSING_DATA="MISSING_DATA",Ke.MISSING_TRANSLATION="MISSING_TRANSLATION";var Ye=function(e){function t(n,r,o){var i=this,a=o?o instanceof Error?o:new Error(String(o)):void 0;return(i=e.call(this,"[@formatjs/intl Error ".concat(n,"] ").concat(r,"\n").concat(a?"\n".concat(a.message,"\n").concat(a.stack):""))||this).code=n,"function"==typeof Error.captureStackTrace&&Error.captureStackTrace(i,t),i}return v(t,e),t}(Error),Xe=function(e){function t(t,n){return e.call(this,We.UNSUPPORTED_FORMATTER,t,n)||this}return v(t,e),t}(Ye),Qe=function(e){function t(t,n){return e.call(this,We.INVALID_CONFIG,t,n)||this}return v(t,e),t}(Ye),et=function(e){function t(t,n){return e.call(this,We.MISSING_DATA,t,n)||this}return v(t,e),t}(Ye),tt=function(e){function t(t,n,r){var o=e.call(this,We.FORMAT_ERROR,"".concat(t,"\nLocale: ").concat(n,"\n"),r)||this;return o.locale=n,o}return v(t,e),t}(Ye),nt=function(e){function t(t,n,r,o){var i=e.call(this,"".concat(t,"\nMessageID: ").concat(null==r?void 0:r.id,"\nDefault Message: ").concat(null==r?void 0:r.defaultMessage,"\nDescription: ").concat(null==r?void 0:r.description,"\n"),n,o)||this;return i.descriptor=r,i.locale=n,i}return v(t,e),t}(tt),rt=function(e){function t(t,n){var r=e.call(this,We.MISSING_TRANSLATION,'Missing message: "'.concat(t.id,'" for locale "').concat(n,'", using ').concat(t.defaultMessage?"default message (".concat("string"==typeof t.defaultMessage?t.defaultMessage:t.defaultMessage.map(function(e){var t;return null!==(t=e.value)&&void 0!==t?t:JSON.stringify(e)}).join(),")"):"id"," as fallback."))||this;return r.descriptor=t,r}return v(t,e),t}(Ye);function ot(e,t,n){return void 0===n&&(n={}),t.reduce(function(t,r){return r in e?t[r]=e[r]:r in n&&(t[r]=n[r]),t},{})}var it={formats:{},messages:{},timeZone:void 0,defaultLocale:"en",defaultFormats:{},fallbackOnEmptyString:!0,onError:function(e){process.env.NODE_ENV},onWarn:function(e){process.env.NODE_ENV}};function at(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}function lt(e,t,n,r){var o,i=e&&e[t];if(i&&(o=i[n]),o)return o;r(new Xe("No ".concat(t," format named: ").concat(n)))}function st(e,t){return Object.keys(e).reduce(function(n,r){return n[r]=y({timeZone:t},e[r]),n},{})}function ct(e,t){return Object.keys(y(y({},e),t)).reduce(function(n,r){return n[r]=y(y({},e[r]||{}),t[r]||{}),n},{})}function dt(e,t){if(!t)return e;var n=Je.formats;return y(y(y({},n),e),{date:ct(st(n.date,t),st(e.date||{},t)),time:ct(st(n.time,t),st(e.time||{},t))})}var ut=function(e,t,n,r,o){var i=e.locale,a=e.formats,l=e.messages,s=e.defaultLocale,c=e.defaultFormats,d=e.fallbackOnEmptyString,u=e.onError,p=e.timeZone,h=e.defaultRichTextElements;void 0===n&&(n={id:""});var m=n.id,f=n.defaultMessage;!function(e,t,n){if(void 0===n&&(n=Error),!e)throw new n(t)}(!!m,"[@formatjs/intl] An `id` must be provided to format a message. You can either:\n1. Configure your build toolchain with [babel-plugin-formatjs](https://formatjs.github.io/docs/tooling/babel-plugin)\nor [@formatjs/ts-transformer](https://formatjs.github.io/docs/tooling/ts-transformer) OR\n2. Configure your `eslint` config to include [eslint-plugin-formatjs](https://formatjs.github.io/docs/tooling/linter#enforce-id)\nto autofix this issue");var g=String(m),v=l&&Object.prototype.hasOwnProperty.call(l,g)&&l[g];if(Array.isArray(v)&&1===v.length&&v[0].type===B.literal)return v[0].value;if(!r&&v&&"string"==typeof v&&!h)return v.replace(/'\{(.*?)\}'/gi,"{$1}");if(r=y(y({},h),r||{}),a=dt(a,p),c=dt(c,p),!v){if(!1===d&&""===v)return v;if((!f||i&&i.toLowerCase()!==s.toLowerCase())&&u(new rt(n,i)),f)try{return t.getMessageFormat(f,s,c,o).format(r)}catch(b){return u(new nt('Error formatting default message for: "'.concat(g,'", rendering default message verbatim'),i,n,b)),"string"==typeof f?f:g}return g}try{return t.getMessageFormat(v,i,a,y({formatters:t},o||{})).format(r)}catch(b){u(new nt('Error formatting message: "'.concat(g,'", using ').concat(f?"default message":"id"," as fallback."),i,n,b))}if(f)try{return t.getMessageFormat(f,s,c,o).format(r)}catch(b){u(new nt('Error formatting the default message for: "'.concat(g,'", rendering message verbatim'),i,n,b))}return"string"==typeof v?v:"string"==typeof f?f:g},pt=["formatMatcher","timeZone","hour12","weekday","era","year","month","day","hour","minute","second","timeZoneName","hourCycle","dateStyle","timeStyle","calendar","numberingSystem","fractionalSecondDigits"];function ht(e,t,n,r){var o=e.locale,i=e.formats,a=e.onError,l=e.timeZone;void 0===r&&(r={});var s=r.format,c=y(y({},l&&{timeZone:l}),s&<(i,t,s,a)),d=ot(r,pt,c);return"time"!==t||d.hour||d.minute||d.second||d.timeStyle||d.dateStyle||(d=y(y({},d),{hour:"numeric",minute:"numeric"})),n(o,d)}function mt(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var o=n[0],i=n[1],a=void 0===i?{}:i,l="string"==typeof o?new Date(o||0):o;try{return ht(e,"date",t,a).format(l)}catch(s){e.onError(new tt("Error formatting date.",e.locale,s))}return String(l)}function ft(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var o=n[0],i=n[1],a=void 0===i?{}:i,l="string"==typeof o?new Date(o||0):o;try{return ht(e,"time",t,a).format(l)}catch(s){e.onError(new tt("Error formatting time.",e.locale,s))}return String(l)}function gt(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var o=n[0],i=n[1],a=n[2],l=void 0===a?{}:a,s="string"==typeof o?new Date(o||0):o,c="string"==typeof i?new Date(i||0):i;try{return ht(e,"dateTimeRange",t,l).formatRange(s,c)}catch(d){e.onError(new tt("Error formatting date time range.",e.locale,d))}return String(s)}function vt(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var o=n[0],i=n[1],a=void 0===i?{}:i,l="string"==typeof o?new Date(o||0):o;try{return ht(e,"date",t,a).formatToParts(l)}catch(s){e.onError(new tt("Error formatting date.",e.locale,s))}return[]}function yt(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var o=n[0],i=n[1],a=void 0===i?{}:i,l="string"==typeof o?new Date(o||0):o;try{return ht(e,"time",t,a).formatToParts(l)}catch(s){e.onError(new tt("Error formatting time.",e.locale,s))}return[]}var bt=["style","type","fallback","languageDisplay"];function wt(e,t,n,r){var o=e.locale,i=e.onError;Intl.DisplayNames||i(new Re('Intl.DisplayNames is not available in this environment.\nTry polyfilling it using "@formatjs/intl-displaynames"\n',Me.MISSING_INTL_API));var a=ot(r,bt);try{return t(o,a).of(n)}catch(l){i(new tt("Error formatting display name.",o,l))}}var kt=["type","style"],xt=Date.now();function _t(e,t,n,r){void 0===r&&(r={});var o=Ct(e,t,n,r).reduce(function(e,t){var n=t.value;return"string"!=typeof n?e.push(n):"string"==typeof e[e.length-1]?e[e.length-1]+=n:e.push(n),e},[]);return 1===o.length?o[0]:0===o.length?"":o}function Ct(e,t,n,r){var o=e.locale,i=e.onError;void 0===r&&(r={}),Intl.ListFormat||i(new Re('Intl.ListFormat is not available in this environment.\nTry polyfilling it using "@formatjs/intl-listformat"\n',Me.MISSING_INTL_API));var a=ot(r,kt);try{var l={},s=Array.from(n).map(function(e,t){if("object"==typeof e&&null!==e){var n=function(e){return"".concat(xt,"_").concat(e,"_").concat(xt)}(t);return l[n]=e,n}return String(e)});return t(o,a).formatToParts(s).map(function(e){return"literal"===e.type?e:y(y({},e),{value:l[e.value]||e.value})})}catch(c){i(new tt("Error formatting list.",o,c))}return n}var Et=["type"];function St(e,t,n,r){var o=e.locale,i=e.onError;void 0===r&&(r={}),Intl.PluralRules||i(new Re('Intl.PluralRules is not available in this environment.\nTry polyfilling it using "@formatjs/intl-pluralrules"\n',Me.MISSING_INTL_API));var a=ot(r,Et);try{return t(o,a).select(n)}catch(l){i(new tt("Error formatting plural.",o,l))}return"other"}var Bt=["numeric","style"];function Nt(e,t,n,r,o){void 0===o&&(o={}),r||(r="second"),Intl.RelativeTimeFormat||e.onError(new Re('Intl.RelativeTimeFormat is not available in this environment.\nTry polyfilling it using "@formatjs/intl-relativetimeformat"\n',Me.MISSING_INTL_API));try{return function(e,t,n){var r=e.locale,o=e.formats,i=e.onError;void 0===n&&(n={});var a=n.format,l=!!a&<(o,"relative",a,i)||{};return t(r,ot(n,Bt,l))}(e,t,o).format(n,r)}catch(i){e.onError(new tt("Error formatting relative time.",e.locale,i))}return String(n)}var Mt=["style","currency","unit","unitDisplay","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","currencyDisplay","currencySign","notation","signDisplay","unit","unitDisplay","numberingSystem","trailingZeroDisplay","roundingPriority","roundingIncrement","roundingMode"];function Tt(e,t,n){var r=e.locale,o=e.formats,i=e.onError;void 0===n&&(n={});var a=n.format,l=a&<(o,"number",a,i)||{};return t(r,ot(n,Mt,l))}function Vt(e,t,n,r){void 0===r&&(r={});try{return Tt(e,t,r).format(n)}catch(o){e.onError(new tt("Error formatting number.",e.locale,o))}return String(n)}function At(e,t,n,r){void 0===r&&(r={});try{return Tt(e,t,r).formatToParts(n)}catch(o){e.onError(new tt("Error formatting number.",e.locale,o))}return[]}function zt(e){var t;e.onWarn&&e.defaultRichTextElements&&"string"==typeof((t=e.messages||{})?t[Object.keys(t)[0]]:void 0)&&e.onWarn('[@formatjs/intl] "defaultRichTextElements" was specified but "message" was not pre-compiled. \nPlease consider using "@formatjs/cli" to pre-compile your messages for performance.\nFor more details see https://formatjs.github.io/docs/getting-started/message-distribution')}function Ot(e,t){var n=function(e){void 0===e&&(e={dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}});var t=Intl.RelativeTimeFormat,n=Intl.ListFormat,r=Intl.DisplayNames,o=w(function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.DateTimeFormat).bind.apply(e,b([void 0],t,!1)))},{cache:at(e.dateTime),strategy:O.variadic}),i=w(function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.NumberFormat).bind.apply(e,b([void 0],t,!1)))},{cache:at(e.number),strategy:O.variadic}),a=w(function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return new((e=Intl.PluralRules).bind.apply(e,b([void 0],t,!1)))},{cache:at(e.pluralRules),strategy:O.variadic});return{getDateTimeFormat:o,getNumberFormat:i,getMessageFormat:w(function(e,t,n,r){return new Je(e,t,n,y({formatters:{getNumberFormat:i,getDateTimeFormat:o,getPluralRules:a}},r||{}))},{cache:at(e.message),strategy:O.variadic}),getRelativeTimeFormat:w(function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return new(t.bind.apply(t,b([void 0],e,!1)))},{cache:at(e.relativeTime),strategy:O.variadic}),getPluralRules:a,getListFormat:w(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return new(n.bind.apply(n,b([void 0],e,!1)))},{cache:at(e.list),strategy:O.variadic}),getDisplayNames:w(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return new(r.bind.apply(r,b([void 0],e,!1)))},{cache:at(e.displayNames),strategy:O.variadic})}}(t),r=y(y({},it),e),o=r.locale,i=r.defaultLocale,a=r.onError;return o?!Intl.NumberFormat.supportedLocalesOf(o).length&&a?a(new et('Missing locale data for locale: "'.concat(o,'" in Intl.NumberFormat. Using default locale: "').concat(i,'" as fallback. See https://formatjs.github.io/docs/react-intl#runtime-requirements for more details'))):!Intl.DateTimeFormat.supportedLocalesOf(o).length&&a&&a(new et('Missing locale data for locale: "'.concat(o,'" in Intl.DateTimeFormat. Using default locale: "').concat(i,'" as fallback. See https://formatjs.github.io/docs/react-intl#runtime-requirements for more details'))):(a&&a(new Qe('"locale" was not configured, using "'.concat(i,'" as fallback. See https://formatjs.github.io/docs/react-intl/api#intlshape for more details'))),r.locale=r.defaultLocale||"en"),zt(r),y(y({},r),{formatters:n,formatNumber:Vt.bind(null,r,n.getNumberFormat),formatNumberToParts:At.bind(null,r,n.getNumberFormat),formatRelativeTime:Nt.bind(null,r,n.getRelativeTimeFormat),formatDate:mt.bind(null,r,n.getDateTimeFormat),formatDateToParts:vt.bind(null,r,n.getDateTimeFormat),formatTime:ft.bind(null,r,n.getDateTimeFormat),formatDateTimeRange:gt.bind(null,r,n.getDateTimeFormat),formatTimeToParts:yt.bind(null,r,n.getDateTimeFormat),formatPlural:St.bind(null,r,n.getPluralRules),formatMessage:ut.bind(null,r,n),$t:ut.bind(null,r,n),formatList:_t.bind(null,r,n.getListFormat),formatListToParts:Ct.bind(null,r,n.getListFormat),formatDisplayName:wt.bind(null,r,n.getDisplayNames)})}const It=Symbol("ErrorProvider"),Dt=()=>{const t=e.inject(It);if(!t)throw new Error("ErrorHandlingProvider is not provided");return t},Pt=e=>e.match(/^(Etc\/)?GMT/)?e.includes("-")?e.replace(/^(Etc\/)?GMT-/,"Etc/GMT+"):e.includes("+")?e.replace(/^(Etc\/)?GMT\+/,"Etc/GMT-"):e:e;function $t(e){this.content=e}function Lt(e,t,n){for(let r=0;;r++){if(r==e.childCount||r==t.childCount)return e.childCount==t.childCount?null:n;let o=e.child(r),i=t.child(r);if(o!=i){if(!o.sameMarkup(i))return n;if(o.isText&&o.text!=i.text){for(let e=0;o.text[e]==i.text[e];e++)n++;return n}if(o.content.size||i.content.size){let e=Lt(o.content,i.content,n+1);if(null!=e)return e}n+=o.nodeSize}else n+=o.nodeSize}}function Rt(e,t,n,r){for(let o=e.childCount,i=t.childCount;;){if(0==o||0==i)return o==i?null:{a:n,b:r};let a=e.child(--o),l=t.child(--i),s=a.nodeSize;if(a!=l){if(!a.sameMarkup(l))return{a:n,b:r};if(a.isText&&a.text!=l.text){let e=0,t=Math.min(a.text.length,l.text.length);for(;e<t&&a.text[a.text.length-e-1]==l.text[l.text.length-e-1];)e++,n--,r--;return{a:n,b:r}}if(a.content.size||l.content.size){let e=Rt(a.content,l.content,n-1,r-1);if(e)return e}n-=s,r-=s}else n-=s,r-=s}}$t.prototype={constructor:$t,find:function(e){for(var t=0;t<this.content.length;t+=2)if(this.content[t]===e)return t;return-1},get:function(e){var t=this.find(e);return-1==t?void 0:this.content[t+1]},update:function(e,t,n){var r=n&&n!=e?this.remove(n):this,o=r.find(e),i=r.content.slice();return-1==o?i.push(n||e,t):(i[o+1]=t,n&&(i[o]=n)),new $t(i)},remove:function(e){var t=this.find(e);if(-1==t)return this;var n=this.content.slice();return n.splice(t,2),new $t(n)},addToStart:function(e,t){return new $t([e,t].concat(this.remove(e).content))},addToEnd:function(e,t){var n=this.remove(e).content.slice();return n.push(e,t),new $t(n)},addBefore:function(e,t,n){var r=this.remove(t),o=r.content.slice(),i=r.find(e);return o.splice(-1==i?o.length:i,0,t,n),new $t(o)},forEach:function(e){for(var t=0;t<this.content.length;t+=2)e(this.content[t],this.content[t+1])},prepend:function(e){return(e=$t.from(e)).size?new $t(e.content.concat(this.subtract(e).content)):this},append:function(e){return(e=$t.from(e)).size?new $t(this.subtract(e).content.concat(e.content)):this},subtract:function(e){var t=this;e=$t.from(e);for(var n=0;n<e.content.length;n+=2)t=t.remove(e.content[n]);return t},toObject:function(){var e={};return this.forEach(function(t,n){e[t]=n}),e},get size(){return this.content.length>>1}},$t.from=function(e){if(e instanceof $t)return e;var t=[];if(e)for(var n in e)t.push(n,e[n]);return new $t(t)};class Ht{constructor(e,t){if(this.content=e,this.size=t||0,null==t)for(let n=0;n<e.length;n++)this.size+=e[n].nodeSize}nodesBetween(e,t,n,r=0,o){for(let i=0,a=0;a<t;i++){let l=this.content[i],s=a+l.nodeSize;if(s>e&&!1!==n(l,r+a,o||null,i)&&l.content.size){let o=a+1;l.nodesBetween(Math.max(0,e-o),Math.min(l.content.size,t-o),n,r+o)}a=s}}descendants(e){this.nodesBetween(0,this.size,e)}textBetween(e,t,n,r){let o="",i=!0;return this.nodesBetween(e,t,(a,l)=>{let s=a.isText?a.text.slice(Math.max(e,l)-l,t-l):a.isLeaf?r?"function"==typeof r?r(a):r:a.type.spec.leafText?a.type.spec.leafText(a):"":"";a.isBlock&&(a.isLeaf&&s||a.isTextblock)&&n&&(i?i=!1:o+=n),o+=s},0),o}append(e){if(!e.size)return this;if(!this.size)return e;let t=this.lastChild,n=e.firstChild,r=this.content.slice(),o=0;for(t.isText&&t.sameMarkup(n)&&(r[r.length-1]=t.withText(t.text+n.text),o=1);o<e.content.length;o++)r.push(e.content[o]);return new Ht(r,this.size+e.size)}cut(e,t=this.size){if(0==e&&t==this.size)return this;let n=[],r=0;if(t>e)for(let o=0,i=0;i<t;o++){let a=this.content[o],l=i+a.nodeSize;l>e&&((i<e||l>t)&&(a=a.isText?a.cut(Math.max(0,e-i),Math.min(a.text.length,t-i)):a.cut(Math.max(0,e-i-1),Math.min(a.content.size,t-i-1))),n.push(a),r+=a.nodeSize),i=l}return new Ht(n,r)}cutByIndex(e,t){return e==t?Ht.empty:0==e&&t==this.content.length?this:new Ht(this.content.slice(e,t))}replaceChild(e,t){let n=this.content[e];if(n==t)return this;let r=this.content.slice(),o=this.size+t.nodeSize-n.nodeSize;return r[e]=t,new Ht(r,o)}addToStart(e){return new Ht([e].concat(this.content),this.size+e.nodeSize)}addToEnd(e){return new Ht(this.content.concat(e),this.size+e.nodeSize)}eq(e){if(this.content.length!=e.content.length)return!1;for(let t=0;t<this.content.length;t++)if(!this.content[t].eq(e.content[t]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(e){let t=this.content[e];if(!t)throw new RangeError("Index "+e+" out of range for "+this);return t}maybeChild(e){return this.content[e]||null}forEach(e){for(let t=0,n=0;t<this.content.length;t++){let r=this.content[t];e(r,n,t),n+=r.nodeSize}}findDiffStart(e,t=0){return Lt(this,e,t)}findDiffEnd(e,t=this.size,n=e.size){return Rt(this,e,t,n)}findIndex(e){if(0==e)return jt(0,e);if(e==this.size)return jt(this.content.length,e);if(e>this.size||e<0)throw new RangeError(`Position ${e} outside of fragment (${this})`);for(let t=0,n=0;;t++){let r=n+this.child(t).nodeSize;if(r>=e)return r==e?jt(t+1,r):jt(t,n);n=r}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(e=>e.toJSON()):null}static fromJSON(e,t){if(!t)return Ht.empty;if(!Array.isArray(t))throw new RangeError("Invalid input for Fragment.fromJSON");return new Ht(t.map(e.nodeFromJSON))}static fromArray(e){if(!e.length)return Ht.empty;let t,n=0;for(let r=0;r<e.length;r++){let o=e[r];n+=o.nodeSize,r&&o.isText&&e[r-1].sameMarkup(o)?(t||(t=e.slice(0,r)),t[t.length-1]=o.withText(t[t.length-1].text+o.text)):t&&t.push(o)}return new Ht(t||e,n)}static from(e){if(!e)return Ht.empty;if(e instanceof Ht)return e;if(Array.isArray(e))return this.fromArray(e);if(e.attrs)return new Ht([e],e.nodeSize);throw new RangeError("Can not convert "+e+" to a Fragment"+(e.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}Ht.empty=new Ht([],0);const Ft={index:0,offset:0};function jt(e,t){return Ft.index=e,Ft.offset=t,Ft}function Ut(e,t){if(e===t)return!0;if(!e||"object"!=typeof e||!t||"object"!=typeof t)return!1;let n=Array.isArray(e);if(Array.isArray(t)!=n)return!1;if(n){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!Ut(e[n],t[n]))return!1}else{for(let n in e)if(!(n in t)||!Ut(e[n],t[n]))return!1;for(let n in t)if(!(n in e))return!1}return!0}let Gt=class e{constructor(e,t){this.type=e,this.attrs=t}addToSet(e){let t,n=!1;for(let r=0;r<e.length;r++){let o=e[r];if(this.eq(o))return e;if(this.type.excludes(o.type))t||(t=e.slice(0,r));else{if(o.type.excludes(this.type))return e;!n&&o.type.rank>this.type.rank&&(t||(t=e.slice(0,r)),t.push(this),n=!0),t&&t.push(o)}}return t||(t=e.slice()),n||t.push(this),t}removeFromSet(e){for(let t=0;t<e.length;t++)if(this.eq(e[t]))return e.slice(0,t).concat(e.slice(t+1));return e}isInSet(e){for(let t=0;t<e.length;t++)if(this.eq(e[t]))return!0;return!1}eq(e){return this==e||this.type==e.type&&Ut(this.attrs,e.attrs)}toJSON(){let e={type:this.type.name};for(let t in this.attrs){e.attrs=this.attrs;break}return e}static fromJSON(e,t){if(!t)throw new RangeError("Invalid input for Mark.fromJSON");let n=e.marks[t.type];if(!n)throw new RangeError(`There is no mark type ${t.type} in this schema`);let r=n.create(t.attrs);return n.checkAttrs(r.attrs),r}static sameSet(e,t){if(e==t)return!0;if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!e[n].eq(t[n]))return!1;return!0}static setFrom(t){if(!t||Array.isArray(t)&&0==t.length)return e.none;if(t instanceof e)return[t];let n=t.slice();return n.sort((e,t)=>e.type.rank-t.type.rank),n}};Gt.none=[];class qt extends Error{}class Zt{constructor(e,t,n){this.content=e,this.openStart=t,this.openEnd=n}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(e,t){let n=Kt(this.content,e+this.openStart,t);return n&&new Zt(n,this.openStart,this.openEnd)}removeBetween(e,t){return new Zt(Wt(this.content,e+this.openStart,t+this.openStart),this.openStart,this.openEnd)}eq(e){return this.content.eq(e.content)&&this.openStart==e.openStart&&this.openEnd==e.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let e={content:this.content.toJSON()};return this.openStart>0&&(e.openStart=this.openStart),this.openEnd>0&&(e.openEnd=this.openEnd),e}static fromJSON(e,t){if(!t)return Zt.empty;let n=t.openStart||0,r=t.openEnd||0;if("number"!=typeof n||"number"!=typeof r)throw new RangeError("Invalid input for Slice.fromJSON");return new Zt(Ht.fromJSON(e,t.content),n,r)}static maxOpen(e,t=!0){let n=0,r=0;for(let o=e.firstChild;o&&!o.isLeaf&&(t||!o.type.spec.isolating);o=o.firstChild)n++;for(let o=e.lastChild;o&&!o.isLeaf&&(t||!o.type.spec.isolating);o=o.lastChild)r++;return new Zt(e,n,r)}}function Wt(e,t,n){let{index:r,offset:o}=e.findIndex(t),i=e.maybeChild(r),{index:a,offset:l}=e.findIndex(n);if(o==t||i.isText){if(l!=n&&!e.child(a).isText)throw new RangeError("Removing non-flat range");return e.cut(0,t).append(e.cut(n))}if(r!=a)throw new RangeError("Removing non-flat range");return e.replaceChild(r,i.copy(Wt(i.content,t-o-1,n-o-1)))}function Kt(e,t,n,r){let{index:o,offset:i}=e.findIndex(t),a=e.maybeChild(o);if(i==t||a.isText)return r&&!r.canReplace(o,o,n)?null:e.cut(0,t).append(n).append(e.cut(t));let l=Kt(a.content,t-i-1,n,a);return l&&e.replaceChild(o,a.copy(l))}function Jt(e,t,n){if(n.openStart>e.depth)throw new qt("Inserted content deeper than insertion position");if(e.depth-n.openStart!=t.depth-n.openEnd)throw new qt("Inconsistent open depths");return Yt(e,t,n,0)}function Yt(e,t,n,r){let o=e.index(r),i=e.node(r);if(o==t.index(r)&&r<e.depth-n.openStart){let a=Yt(e,t,n,r+1);return i.copy(i.content.replaceChild(o,a))}if(n.content.size){if(n.openStart||n.openEnd||e.depth!=r||t.depth!=r){let{start:o,end:a}=function(e,t){let n=t.depth-e.openStart,r=t.node(n).copy(e.content);for(let o=n-1;o>=0;o--)r=t.node(o).copy(Ht.from(r));return{start:r.resolveNoCache(e.openStart+n),end:r.resolveNoCache(r.content.size-e.openEnd-n)}}(n,e);return nn(i,rn(e,o,a,t,r))}{let r=e.parent,o=r.content;return nn(r,o.cut(0,e.parentOffset).append(n.content).append(o.cut(t.parentOffset)))}}return nn(i,on(e,t,r))}function Xt(e,t){if(!t.type.compatibleContent(e.type))throw new qt("Cannot join "+t.type.name+" onto "+e.type.name)}function Qt(e,t,n){let r=e.node(n);return Xt(r,t.node(n)),r}function en(e,t){let n=t.length-1;n>=0&&e.isText&&e.sameMarkup(t[n])?t[n]=e.withText(t[n].text+e.text):t.push(e)}function tn(e,t,n,r){let o=(t||e).node(n),i=0,a=t?t.index(n):o.childCount;e&&(i=e.index(n),e.depth>n?i++:e.textOffset&&(en(e.nodeAfter,r),i++));for(let l=i;l<a;l++)en(o.child(l),r);t&&t.depth==n&&t.textOffset&&en(t.nodeBefore,r)}function nn(e,t){return e.type.checkContent(t),e.copy(t)}function rn(e,t,n,r,o){let i=e.depth>o&&Qt(e,t,o+1),a=r.depth>o&&Qt(n,r,o+1),l=[];return tn(null,e,o,l),i&&a&&t.index(o)==n.index(o)?(Xt(i,a),en(nn(i,rn(e,t,n,r,o+1)),l)):(i&&en(nn(i,on(e,t,o+1)),l),tn(t,n,o,l),a&&en(nn(a,on(n,r,o+1)),l)),tn(r,null,o,l),new Ht(l)}function on(e,t,n){let r=[];if(tn(null,e,n,r),e.depth>n){en(nn(Qt(e,t,n+1),on(e,t,n+1)),r)}return tn(t,null,n,r),new Ht(r)}Zt.empty=new Zt(Ht.empty,0,0);class an{constructor(e,t,n){this.pos=e,this.path=t,this.parentOffset=n,this.depth=t.length/3-1}resolveDepth(e){return null==e?this.depth:e<0?this.depth+e:e}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(e){return this.path[3*this.resolveDepth(e)]}index(e){return this.path[3*this.resolveDepth(e)+1]}indexAfter(e){return e=this.resolveDepth(e),this.index(e)+(e!=this.depth||this.textOffset?1:0)}start(e){return 0==(e=this.resolveDepth(e))?0:this.path[3*e-1]+1}end(e){return e=this.resolveDepth(e),this.start(e)+this.node(e).content.size}before(e){if(!(e=this.resolveDepth(e)))throw new RangeError("There is no position before the top-level node");return e==this.depth+1?this.pos:this.path[3*e-1]}after(e){if(!(e=this.resolveDepth(e)))throw new RangeError("There is no position after the top-level node");return e==this.depth+1?this.pos:this.path[3*e-1]+this.path[3*e].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let e=this.parent,t=this.index(this.depth);if(t==e.childCount)return null;let n=this.pos-this.path[this.path.length-1],r=e.child(t);return n?e.child(t).cut(n):r}get nodeBefore(){let e=this.index(this.depth),t=this.pos-this.path[this.path.length-1];return t?this.parent.child(e).cut(0,t):0==e?null:this.parent.child(e-1)}posAtIndex(e,t){t=this.resolveDepth(t);let n=this.path[3*t],r=0==t?0:this.path[3*t-1]+1;for(let o=0;o<e;o++)r+=n.child(o).nodeSize;return r}marks(){let e=this.parent,t=this.index();if(0==e.content.size)return Gt.none;if(this.textOffset)return e.child(t).marks;let n=e.maybeChild(t-1),r=e.maybeChild(t);if(!n){let e=n;n=r,r=e}let o=n.marks;for(var i=0;i<o.length;i++)!1!==o[i].type.spec.inclusive||r&&o[i].isInSet(r.marks)||(o=o[i--].removeFromSet(o));return o}marksAcross(e){let t=this.parent.maybeChild(this.index());if(!t||!t.isInline)return null;let n=t.marks,r=e.parent.maybeChild(e.index());for(var o=0;o<n.length;o++)!1!==n[o].type.spec.inclusive||r&&n[o].isInSet(r.marks)||(n=n[o--].removeFromSet(n));return n}sharedDepth(e){for(let t=this.depth;t>0;t--)if(this.start(t)<=e&&this.end(t)>=e)return t;return 0}blockRange(e=this,t){if(e.pos<this.pos)return e.blockRange(this);for(let n=this.depth-(this.parent.inlineContent||this.pos==e.pos?1:0);n>=0;n--)if(e.pos<=this.end(n)&&(!t||t(this.node(n))))return new dn(this,e,n);return null}sameParent(e){return this.pos-this.parentOffset==e.pos-e.parentOffset}max(e){return e.pos>this.pos?e:this}min(e){return e.pos<this.pos?e:this}toString(){let e="";for(let t=1;t<=this.depth;t++)e+=(e?"/":"")+this.node(t).type.name+"_"+this.index(t-1);return e+":"+this.parentOffset}static resolve(e,t){if(!(t>=0&&t<=e.content.size))throw new RangeError("Position "+t+" out of range");let n=[],r=0,o=t;for(let i=e;;){let{index:e,offset:t}=i.content.findIndex(o),a=o-t;if(n.push(i,e,r+t),!a)break;if(i=i.child(e),i.isText)break;o=a-1,r+=t+1}return new an(t,n,o)}static resolveCached(e,t){let n=cn.get(e);if(n)for(let o=0;o<n.elts.length;o++){let e=n.elts[o];if(e.pos==t)return e}else cn.set(e,n=new ln);let r=n.elts[n.i]=an.resolve(e,t);return n.i=(n.i+1)%sn,r}}class ln{constructor(){this.elts=[],this.i=0}}const sn=12,cn=new WeakMap;class dn{constructor(e,t,n){this.$from=e,this.$to=t,this.depth=n}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}}const un=Object.create(null);let pn=class e{constructor(e,t,n,r=Gt.none){this.type=e,this.attrs=t,this.marks=r,this.content=n||Ht.empty}get children(){return this.content.content}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(e){return this.content.child(e)}maybeChild(e){return this.content.maybeChild(e)}forEach(e){this.content.forEach(e)}nodesBetween(e,t,n,r=0){this.content.nodesBetween(e,t,n,r,this)}descendants(e){this.nodesBetween(0,this.content.size,e)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(e,t,n,r){return this.content.textBetween(e,t,n,r)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(e){return this==e||this.sameMarkup(e)&&this.content.eq(e.content)}sameMarkup(e){return this.hasMarkup(e.type,e.attrs,e.marks)}hasMarkup(e,t,n){return this.type==e&&Ut(this.attrs,t||e.defaultAttrs||un)&&Gt.sameSet(this.marks,n||Gt.none)}copy(t=null){return t==this.content?this:new e(this.type,this.attrs,t,this.marks)}mark(t){return t==this.marks?this:new e(this.type,this.attrs,this.content,t)}cut(e,t=this.content.size){return 0==e&&t==this.content.size?this:this.copy(this.content.cut(e,t))}slice(e,t=this.content.size,n=!1){if(e==t)return Zt.empty;let r=this.resolve(e),o=this.resolve(t),i=n?0:r.sharedDepth(t),a=r.start(i),l=r.node(i).content.cut(r.pos-a,o.pos-a);return new Zt(l,r.depth-i,o.depth-i)}replace(e,t,n){return Jt(this.resolve(e),this.resolve(t),n)}nodeAt(e){for(let t=this;;){let{index:n,offset:r}=t.content.findIndex(e);if(t=t.maybeChild(n),!t)return null;if(r==e||t.isText)return t;e-=r+1}}childAfter(e){let{index:t,offset:n}=this.content.findIndex(e);return{node:this.content.maybeChild(t),index:t,offset:n}}childBefore(e){if(0==e)return{node:null,index:0,offset:0};let{index:t,offset:n}=this.content.findIndex(e);if(n<e)return{node:this.content.child(t),index:t,offset:n};let r=this.content.child(t-1);return{node:r,index:t-1,offset:n-r.nodeSize}}resolve(e){return an.resolveCached(this,e)}resolveNoCache(e){return an.resolve(this,e)}rangeHasMark(e,t,n){let r=!1;return t>e&&this.nodesBetween(e,t,e=>(n.isInSet(e.marks)&&(r=!0),!r)),r}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let e=this.type.name;return this.content.size&&(e+="("+this.content.toStringInner()+")"),mn(this.marks,e)}contentMatchAt(e){let t=this.type.contentMatch.matchFragment(this.content,0,e);if(!t)throw new Error("Called contentMatchAt on a node with invalid content");return t}canReplace(e,t,n=Ht.empty,r=0,o=n.childCount){let i=this.contentMatchAt(e).matchFragment(n,r,o),a=i&&i.matchFragment(this.content,t);if(!a||!a.validEnd)return!1;for(let l=r;l<o;l++)if(!this.type.allowsMarks(n.child(l).marks))return!1;return!0}canReplaceWith(e,t,n,r){if(r&&!this.type.allowsMarks(r))return!1;let o=this.contentMatchAt(e).matchType(n),i=o&&o.matchFragment(this.content,t);return!!i&&i.validEnd}canAppend(e){return e.content.size?this.canReplace(this.childCount,this.childCount,e.content):this.type.compatibleContent(e.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let e=Gt.none;for(let t=0;t<this.marks.length;t++){let n=this.marks[t];n.type.checkAttrs(n.attrs),e=n.addToSet(e)}if(!Gt.sameSet(e,this.marks))throw new RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(e=>e.type.name)}`);this.content.forEach(e=>e.check())}toJSON(){let e={type:this.type.name};for(let t in this.attrs){e.attrs=this.attrs;break}return this.content.size&&(e.content=this.content.toJSON()),this.marks.length&&(e.marks=this.marks.map(e=>e.toJSON())),e}static fromJSON(e,t){if(!t)throw new RangeError("Invalid input for Node.fromJSON");let n;if(t.marks){if(!Array.isArray(t.marks))throw new RangeError("Invalid mark data for Node.fromJSON");n=t.marks.map(e.markFromJSON)}if("text"==t.type){if("string"!=typeof t.text)throw new RangeError("Invalid text node in JSON");return e.text(t.text,n)}let r=Ht.fromJSON(e,t.content),o=e.nodeType(t.type).create(t.attrs,r,n);return o.type.checkAttrs(o.attrs),o}};pn.prototype.text=void 0;class hn extends pn{constructor(e,t,n,r){if(super(e,t,null,r),!n)throw new RangeError("Empty text nodes are not allowed");this.text=n}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):mn(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(e,t){return this.text.slice(e,t)}get nodeSize(){return this.text.length}mark(e){return e==this.marks?this:new hn(this.type,this.attrs,this.text,e)}withText(e){return e==this.text?this:new hn(this.type,this.attrs,e,this.marks)}cut(e=0,t=this.text.length){return 0==e&&t==this.text.length?this:this.withText(this.text.slice(e,t))}eq(e){return this.sameMarkup(e)&&this.text==e.text}toJSON(){let e=super.toJSON();return e.text=this.text,e}}function mn(e,t){for(let n=e.length-1;n>=0;n--)t=e[n].type.name+"("+t+")";return t}class fn{constructor(e){this.validEnd=e,this.next=[],this.wrapCache=[]}static parse(e,t){let n=new gn(e,t);if(null==n.next)return fn.empty;let r=vn(n);n.next&&n.err("Unexpected trailing text");let o=function(e){let t=Object.create(null);return n(_n(e,0));function n(r){let o=[];r.forEach(t=>{e[t].forEach(({term:t,to:n})=>{if(!t)return;let r;for(let e=0;e<o.length;e++)o[e][0]==t&&(r=o[e][1]);_n(e,n).forEach(e=>{r||o.push([t,r=[]]),-1==r.indexOf(e)&&r.push(e)})})});let i=t[r.join(",")]=new fn(r.indexOf(e.length-1)>-1);for(let e=0;e<o.length;e++){let r=o[e][1].sort(xn);i.next.push({type:o[e][0],next:t[r.join(",")]||n(r)})}return i}}(function(e){let t=[[]];return o(i(e,0),n()),t;function n(){return t.push([])-1}function r(e,n,r){let o={term:r,to:n};return t[e].push(o),o}function o(e,t){e.forEach(e=>e.to=t)}function i(e,t){if("choice"==e.type)return e.exprs.reduce((e,n)=>e.concat(i(n,t)),[]);if("seq"!=e.type){if("star"==e.type){let a=n();return r(t,a),o(i(e.expr,a),a),[r(a)]}if("plus"==e.type){let a=n();return o(i(e.expr,t),a),o(i(e.expr,a),a),[r(a)]}if("opt"==e.type)return[r(t)].concat(i(e.expr,t));if("range"==e.type){let a=t;for(let t=0;t<e.min;t++){let t=n();o(i(e.expr,a),t),a=t}if(-1==e.max)o(i(e.expr,a),a);else for(let t=e.min;t<e.max;t++){let t=n();r(a,t),o(i(e.expr,a),t),a=t}return[r(a)]}if("name"==e.type)return[r(t,void 0,e.value)];throw new Error("Unknown expr type")}for(let r=0;;r++){let a=i(e.exprs[r],t);if(r==e.exprs.length-1)return a;o(a,t=n())}}}(r));return function(e,t){for(let n=0,r=[e];n<r.length;n++){let e=r[n],o=!e.validEnd,i=[];for(let t=0;t<e.next.length;t++){let{type:n,next:a}=e.next[t];i.push(n.name),!o||n.isText||n.hasRequiredAttrs()||(o=!1),-1==r.indexOf(a)&&r.push(a)}o&&t.err("Only non-generatable nodes ("+i.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}(o,n),o}matchType(e){for(let t=0;t<this.next.length;t++)if(this.next[t].type==e)return this.next[t].next;return null}matchFragment(e,t=0,n=e.childCount){let r=this;for(let o=t;r&&o<n;o++)r=r.matchType(e.child(o).type);return r}get inlineContent(){return 0!=this.next.length&&this.next[0].type.isInline}get defaultType(){for(let e=0;e<this.next.length;e++){let{type:t}=this.next[e];if(!t.isText&&!t.hasRequiredAttrs())return t}return null}compatible(e){for(let t=0;t<this.next.length;t++)for(let n=0;n<e.next.length;n++)if(this.next[t].type==e.next[n].type)return!0;return!1}fillBefore(e,t=!1,n=0){let r=[this];return function o(i,a){let l=i.matchFragment(e,n);if(l&&(!t||l.validEnd))return Ht.from(a.map(e=>e.createAndFill()));for(let e=0;e<i.next.length;e++){let{type:t,next:n}=i.next[e];if(!t.isText&&!t.hasRequiredAttrs()&&-1==r.indexOf(n)){r.push(n);let e=o(n,a.concat(t));if(e)return e}}return null}(this,[])}findWrapping(e){for(let n=0;n<this.wrapCache.length;n+=2)if(this.wrapCache[n]==e)return this.wrapCache[n+1];let t=this.computeWrapping(e);return this.wrapCache.push(e,t),t}computeWrapping(e){let t=Object.create(null),n=[{match:this,type:null,via:null}];for(;n.length;){let r=n.shift(),o=r.match;if(o.matchType(e)){let e=[];for(let t=r;t.type;t=t.via)e.push(t.type);return e.reverse()}for(let e=0;e<o.next.length;e++){let{type:i,next:a}=o.next[e];i.isLeaf||i.hasRequiredAttrs()||i.name in t||r.type&&!a.validEnd||(n.push({match:i.contentMatch,type:i,via:r}),t[i.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(e){if(e>=this.next.length)throw new RangeError(`There's no ${e}th edge in this content match`);return this.next[e]}toString(){let e=[];return function t(n){e.push(n);for(let r=0;r<n.next.length;r++)-1==e.indexOf(n.next[r].next)&&t(n.next[r].next)}(this),e.map((t,n)=>{let r=n+(t.validEnd?"*":" ")+" ";for(let o=0;o<t.next.length;o++)r+=(o?", ":"")+t.next[o].type.name+"->"+e.indexOf(t.next[o].next);return r}).join("\n")}}fn.empty=new fn(!0);class gn{constructor(e,t){this.string=e,this.nodeTypes=t,this.inline=null,this.pos=0,this.tokens=e.split(/\s*(?=\b|\W|$)/),""==this.tokens[this.tokens.length-1]&&this.tokens.pop(),""==this.tokens[0]&&this.tokens.shift()}get next(){return this.tokens[this.pos]}eat(e){return this.next==e&&(this.pos++||!0)}err(e){throw new SyntaxError(e+" (in content expression '"+this.string+"')")}}function vn(e){let t=[];do{t.push(yn(e))}while(e.eat("|"));return 1==t.length?t[0]:{type:"choice",exprs:t}}function yn(e){let t=[];do{t.push(bn(e))}while(e.next&&")"!=e.next&&"|"!=e.next);return 1==t.length?t[0]:{type:"seq",exprs:t}}function bn(e){let t=function(e){if(e.eat("(")){let t=vn(e);return e.eat(")")||e.err("Missing closing paren"),t}if(!/\W/.test(e.next)){let t=function(e,t){let n=e.nodeTypes,r=n[t];if(r)return[r];let o=[];for(let i in n){let e=n[i];e.isInGroup(t)&&o.push(e)}0==o.length&&e.err("No node type or group '"+t+"' found");return o}(e,e.next).map(t=>(null==e.inline?e.inline=t.isInline:e.inline!=t.isInline&&e.err("Mixing inline and block content"),{type:"name",value:t}));return e.pos++,1==t.length?t[0]:{type:"choice",exprs:t}}e.err("Unexpected token '"+e.next+"'")}(e);for(;;)if(e.eat("+"))t={type:"plus",expr:t};else if(e.eat("*"))t={type:"star",expr:t};else if(e.eat("?"))t={type:"opt",expr:t};else{if(!e.eat("{"))break;t=kn(e,t)}return t}function wn(e){/\D/.test(e.next)&&e.err("Expected number, got '"+e.next+"'");let t=Number(e.next);return e.pos++,t}function kn(e,t){let n=wn(e),r=n;return e.eat(",")&&(r="}"!=e.next?wn(e):-1),e.eat("}")||e.err("Unclosed braced range"),{type:"range",min:n,max:r,expr:t}}function xn(e,t){return t-e}function _n(e,t){let n=[];return function t(r){let o=e[r];if(1==o.length&&!o[0].term)return t(o[0].to);n.push(r);for(let e=0;e<o.length;e++){let{term:r,to:i}=o[e];r||-1!=n.indexOf(i)||t(i)}}(t),n.sort(xn)}function Cn(e){let t=Object.create(null);for(let n in e){let r=e[n];if(!r.hasDefault)return null;t[n]=r.default}return t}function En(e,t){let n=Object.create(null);for(let r in e){let o=t&&t[r];if(void 0===o){let t=e[r];if(!t.hasDefault)throw new RangeError("No value supplied for attribute "+r);o=t.default}n[r]=o}return n}function Sn(e,t,n,r){for(let o in t)if(!(o in e))throw new RangeError(`Unsupported attribute ${o} for ${n} of type ${o}`);for(let o in e){let n=e[o];n.validate&&n.validate(t[o])}}function Bn(e,t){let n=Object.create(null);if(t)for(let r in t)n[r]=new Mn(e,r,t[r]);return n}let Nn=class e{constructor(e,t,n){this.name=e,this.schema=t,this.spec=n,this.markSet=null,this.groups=n.group?n.group.split(" "):[],this.attrs=Bn(e,n.attrs),this.defaultAttrs=Cn(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(n.inline||"text"==e),this.isText="text"==e}get isInline(){return!this.isBlock}get isTextblock(){return this.isBlock&&this.inlineContent}get isLeaf(){return this.contentMatch==fn.empty}get isAtom(){return this.isLeaf||!!this.spec.atom}isInGroup(e){return this.groups.indexOf(e)>-1}get whitespace(){return this.spec.whitespace||(this.spec.code?"pre":"normal")}hasRequiredAttrs(){for(let e in this.attrs)if(this.attrs[e].isRequired)return!0;return!1}compatibleContent(e){return this==e||this.contentMatch.compatible(e.contentMatch)}computeAttrs(e){return!e&&this.defaultAttrs?this.defaultAttrs:En(this.attrs,e)}create(e=null,t,n){if(this.isText)throw new Error("NodeType.create can't construct text nodes");return new pn(this,this.computeAttrs(e),Ht.from(t),Gt.setFrom(n))}createChecked(e=null,t,n){return t=Ht.from(t),this.checkContent(t),new pn(this,this.computeAttrs(e),t,Gt.setFrom(n))}createAndFill(e=null,t,n){if(e=this.computeAttrs(e),(t=Ht.from(t)).size){let e=this.contentMatch.fillBefore(t);if(!e)return null;t=e.append(t)}let r=this.contentMatch.matchFragment(t),o=r&&r.fillBefore(Ht.empty,!0);return o?new pn(this,e,t.append(o),Gt.setFrom(n)):null}validContent(e){let t=this.contentMatch.matchFragment(e);if(!t||!t.validEnd)return!1;for(let n=0;n<e.childCount;n++)if(!this.allowsMarks(e.child(n).marks))return!1;return!0}checkContent(e){if(!this.validContent(e))throw new RangeError(`Invalid content for node ${this.name}: ${e.toString().slice(0,50)}`)}checkAttrs(e){Sn(this.attrs,e,"node",this.name)}allowsMarkType(e){return null==this.markSet||this.markSet.indexOf(e)>-1}allowsMarks(e){if(null==this.markSet)return!0;for(let t=0;t<e.length;t++)if(!this.allowsMarkType(e[t].type))return!1;return!0}allowedMarks(e){if(null==this.markSet)return e;let t;for(let n=0;n<e.length;n++)this.allowsMarkType(e[n].type)?t&&t.push(e[n]):t||(t=e.slice(0,n));return t?t.length?t:Gt.none:e}static compile(t,n){let r=Object.create(null);t.forEach((t,o)=>r[t]=new e(t,n,o));let o=n.spec.topNode||"doc";if(!r[o])throw new RangeError("Schema is missing its top node type ('"+o+"')");if(!r.text)throw new RangeError("Every schema needs a 'text' type");for(let e in r.text.attrs)throw new RangeError("The text node type should not have attributes");return r}};class Mn{constructor(e,t,n){this.hasDefault=Object.prototype.hasOwnProperty.call(n,"default"),this.default=n.default,this.validate="string"==typeof n.validate?function(e,t,n){let r=n.split("|");return n=>{let o=null===n?"null":typeof n;if(r.indexOf(o)<0)throw new RangeError(`Expected value of type ${r} for attribute ${t} on type ${e}, got ${o}`)}}(e,t,n.validate):n.validate}get isRequired(){return!this.hasDefault}}class Tn{constructor(e,t,n,r){this.name=e,this.rank=t,this.schema=n,this.spec=r,this.attrs=Bn(e,r.attrs),this.excluded=null;let o=Cn(this.attrs);this.instance=o?new Gt(this,o):null}create(e=null){return!e&&this.instance?this.instance:new Gt(this,En(this.attrs,e))}static compile(e,t){let n=Object.create(null),r=0;return e.forEach((e,o)=>n[e]=new Tn(e,r++,t,o)),n}removeFromSet(e){for(var t=0;t<e.length;t++)e[t].type==this&&(e=e.slice(0,t).concat(e.slice(t+1)),t--);return e}isInSet(e){for(let t=0;t<e.length;t++)if(e[t].type==this)return e[t]}checkAttrs(e){Sn(this.attrs,e,"mark",this.name)}excludes(e){return this.excluded.indexOf(e)>-1}}let Vn=class{constructor(e){this.linebreakReplacement=null,this.cached=Object.create(null);let t=this.spec={};for(let r in e)t[r]=e[r];t.nodes=$t.from(e.nodes),t.marks=$t.from(e.marks||{}),this.nodes=Nn.compile(this.spec.nodes,this),this.marks=Tn.compile(this.spec.marks,this);let n=Object.create(null);for(let r in this.nodes){if(r in this.marks)throw new RangeError(r+" can not be both a node and a mark");let e=this.nodes[r],t=e.spec.content||"",o=e.spec.marks;if(e.contentMatch=n[t]||(n[t]=fn.parse(t,this.nodes)),e.inlineContent=e.contentMatch.inlineContent,e.spec.linebreakReplacement){if(this.linebreakReplacement)throw new RangeError("Multiple linebreak nodes defined");if(!e.isInline||!e.isLeaf)throw new RangeError("Linebreak replacement nodes must be inline leaf nodes");this.linebreakReplacement=e}e.markSet="_"==o?null:o?An(this,o.split(" ")):""!=o&&e.inlineContent?null:[]}for(let r in this.marks){let e=this.marks[r],t=e.spec.excludes;e.excluded=null==t?[e]:""==t?[]:An(this,t.split(" "))}this.nodeFromJSON=e=>pn.fromJSON(this,e),this.markFromJSON=e=>Gt.fromJSON(this,e),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached.wrappings=Object.create(null)}node(e,t=null,n,r){if("string"==typeof e)e=this.nodeType(e);else{if(!(e instanceof Nn))throw new RangeError("Invalid node type: "+e);if(e.schema!=this)throw new RangeError("Node type from different schema used ("+e.name+")")}return e.createChecked(t,n,r)}text(e,t){let n=this.nodes.text;return new hn(n,n.defaultAttrs,e,Gt.setFrom(t))}mark(e,t){return"string"==typeof e&&(e=this.marks[e]),e.create(t)}nodeType(e){let t=this.nodes[e];if(!t)throw new RangeError("Unknown node type: "+e);return t}};function An(e,t){let n=[];for(let r=0;r<t.length;r++){let o=t[r],i=e.marks[o],a=i;if(i)n.push(i);else for(let t in e.marks){let r=e.marks[t];("_"==o||r.spec.group&&r.spec.group.split(" ").indexOf(o)>-1)&&n.push(a=r)}if(!a)throw new SyntaxError("Unknown mark type: '"+t[r]+"'")}return n}let zn=class e{constructor(e,t){this.schema=e,this.rules=t,this.tags=[],this.styles=[];let n=this.matchedStyles=[];t.forEach(e=>{if(function(e){return null!=e.tag}(e))this.tags.push(e);else if(function(e){return null!=e.style}(e)){let t=/[^=]*/.exec(e.style)[0];n.indexOf(t)<0&&n.push(t),this.styles.push(e)}}),this.normalizeLists=!this.tags.some(t=>{if(!/^(ul|ol)\b/.test(t.tag)||!t.node)return!1;let n=e.nodes[t.node];return n.contentMatch.matchType(n)})}parse(e,t={}){let n=new Ln(this,t,!1);return n.addAll(e,Gt.none,t.from,t.to),n.finish()}parseSlice(e,t={}){let n=new Ln(this,t,!0);return n.addAll(e,Gt.none,t.from,t.to),Zt.maxOpen(n.finish())}matchTag(e,t,n){for(let r=n?this.tags.indexOf(n)+1:0;r<this.tags.length;r++){let n=this.tags[r];if(Rn(e,n.tag)&&(void 0===n.namespace||e.namespaceURI==n.namespace)&&(!n.context||t.matchesContext(n.context))){if(n.getAttrs){let t=n.getAttrs(e);if(!1===t)continue;n.attrs=t||void 0}return n}}}matchStyle(e,t,n,r){for(let o=r?this.styles.indexOf(r)+1:0;o<this.styles.length;o++){let r=this.styles[o],i=r.style;if(!(0!=i.indexOf(e)||r.context&&!n.matchesContext(r.context)||i.length>e.length&&(61!=i.charCodeAt(e.length)||i.slice(e.length+1)!=t))){if(r.getAttrs){let e=r.getAttrs(t);if(!1===e)continue;r.attrs=e||void 0}return r}}}static schemaRules(e){let t=[];function n(e){let n=null==e.priority?50:e.priority,r=0;for(;r<t.length;r++){let e=t[r];if((null==e.priority?50:e.priority)<n)break}t.splice(r,0,e)}for(let r in e.marks){let t=e.marks[r].spec.parseDOM;t&&t.forEach(e=>{n(e=Hn(e)),e.mark||e.ignore||e.clearMark||(e.mark=r)})}for(let r in e.nodes){let t=e.nodes[r].spec.parseDOM;t&&t.forEach(e=>{n(e=Hn(e)),e.node||e.ignore||e.mark||(e.node=r)})}return t}static fromSchema(t){return t.cached.domParser||(t.cached.domParser=new e(t,e.schemaRules(t)))}};const On={address:!0,article:!0,aside:!0,blockquote:!0,canvas:!0,dd:!0,div:!0,dl:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,li:!0,noscript:!0,ol:!0,output:!0,p:!0,pre:!0,section:!0,table:!0,tfoot:!0,ul:!0},In={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},Dn={ol:!0,ul:!0};function Pn(e,t,n){return null!=t?(t?1:0)|("full"===t?2:0):e&&"pre"==e.whitespace?3:-5&n}class $n{constructor(e,t,n,r,o,i){this.type=e,this.attrs=t,this.marks=n,this.solid=r,this.options=i,this.content=[],this.activeMarks=Gt.none,this.match=o||(4&i?null:e.contentMatch)}findWrapping(e){if(!this.match){if(!this.type)return[];let t=this.type.contentMatch.fillBefore(Ht.from(e));if(!t){let t,n=this.type.contentMatch;return(t=n.findWrapping(e.type))?(this.match=n,t):null}this.match=this.type.contentMatch.matchFragment(t)}return this.match.findWrapping(e.type)}finish(e){if(!(1&this.options)){let e,t=this.content[this.content.length-1];if(t&&t.isText&&(e=/[ \t\r\n\u000c]+$/.exec(t.text))){let n=t;t.text.length==e[0].length?this.content.pop():this.content[this.content.length-1]=n.withText(n.text.slice(0,n.text.length-e[0].length))}}let t=Ht.from(this.content);return!e&&this.match&&(t=t.append(this.match.fillBefore(Ht.empty,!0))),this.type?this.type.create(this.attrs,t,this.marks):t}inlineContext(e){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:e.parentNode&&!On.hasOwnProperty(e.parentNode.nodeName.toLowerCase())}}class Ln{constructor(e,t,n){this.parser=e,this.options=t,this.isOpen=n,this.open=0,this.localPreserveWS=!1;let r,o=t.topNode,i=Pn(null,t.preserveWhitespace,0)|(n?4:0);r=o?new $n(o.type,o.attrs,Gt.none,!0,t.topMatch||o.type.contentMatch,i):new $n(n?null:e.schema.topNodeType,null,Gt.none,!0,null,i),this.nodes=[r],this.find=t.findPositions,this.needsBlock=!1}get top(){return this.nodes[this.open]}addDOM(e,t){3==e.nodeType?this.addTextNode(e,t):1==e.nodeType&&this.addElement(e,t)}addTextNode(e,t){let n=e.nodeValue,r=this.top,o=2&r.options?"full":this.localPreserveWS||(1&r.options)>0,{schema:i}=this.parser;if("full"===o||r.inlineContext(e)||/[^ \t\r\n\u000c]/.test(n)){if(o)if("full"===o)n=n.replace(/\r\n?/g,"\n");else if(i.linebreakReplacement&&/[\r\n]/.test(n)&&this.top.findWrapping(i.linebreakReplacement.create())){let e=n.split(/\r?\n|\r/);for(let n=0;n<e.length;n++)n&&this.insertNode(i.linebreakReplacement.create(),t,!0),e[n]&&this.insertNode(i.text(e[n]),t,!/\S/.test(e[n]));n=""}else n=n.replace(/\r?\n|\r/g," ");else if(n=n.replace(/[ \t\r\n\u000c]+/g," "),/^[ \t\r\n\u000c]/.test(n)&&this.open==this.nodes.length-1){let t=r.content[r.content.length-1],o=e.previousSibling;(!t||o&&"BR"==o.nodeName||t.isText&&/[ \t\r\n\u000c]$/.test(t.text))&&(n=n.slice(1))}n&&this.insertNode(i.text(n),t,!/\S/.test(n)),this.findInText(e)}else this.findInside(e)}addElement(e,t,n){let r=this.localPreserveWS,o=this.top;("PRE"==e.tagName||/pre/.test(e.style&&e.style.whiteSpace))&&(this.localPreserveWS=!0);let i,a=e.nodeName.toLowerCase();Dn.hasOwnProperty(a)&&this.parser.normalizeLists&&function(e){for(let t=e.firstChild,n=null;t;t=t.nextSibling){let e=1==t.nodeType?t.nodeName.toLowerCase():null;e&&Dn.hasOwnProperty(e)&&n?(n.appendChild(t),t=n):"li"==e?n=t:e&&(n=null)}}(e);let l=this.options.ruleFromNode&&this.options.ruleFromNode(e)||(i=this.parser.matchTag(e,this,n));e:if(l?l.ignore:In.hasOwnProperty(a))this.findInside(e),this.ignoreFallback(e,t);else if(!l||l.skip||l.closeParent){l&&l.closeParent?this.open=Math.max(0,this.open-1):l&&l.skip.nodeType&&(e=l.skip);let n,r=this.needsBlock;if(On.hasOwnProperty(a))o.content.length&&o.content[0].isInline&&this.open&&(this.open--,o=this.top),n=!0,o.type||(this.needsBlock=!0);else if(!e.firstChild){this.leafFallback(e,t);break e}let i=l&&l.skip?t:this.readStyles(e,t);i&&this.addAll(e,i),n&&this.sync(o),this.needsBlock=r}else{let n=this.readStyles(e,t);n&&this.addElementByRule(e,l,n,!1===l.consuming?i:void 0)}this.localPreserveWS=r}leafFallback(e,t){"BR"==e.nodeName&&this.top.type&&this.top.type.inlineContent&&this.addTextNode(e.ownerDocument.createTextNode("\n"),t)}ignoreFallback(e,t){"BR"!=e.nodeName||this.top.type&&this.top.type.inlineContent||this.findPlace(this.parser.schema.text("-"),t,!0)}readStyles(e,t){let n=e.style;if(n&&n.length)for(let r=0;r<this.parser.matchedStyles.length;r++){let e=this.parser.matchedStyles[r],o=n.getPropertyValue(e);if(o)for(let n;;){let r=this.parser.matchStyle(e,o,this,n);if(!r)break;if(r.ignore)return null;if(t=r.clearMark?t.filter(e=>!r.clearMark(e)):t.concat(this.parser.schema.marks[r.mark].create(r.attrs)),!1!==r.consuming)break;n=r}}return t}addElementByRule(e,t,n,r){let o,i;if(t.node)if(i=this.parser.schema.nodes[t.node],i.isLeaf)this.insertNode(i.create(t.attrs),n,"BR"==e.nodeName)||this.leafFallback(e,n);else{let e=this.enter(i,t.attrs||null,n,t.preserveWhitespace);e&&(o=!0,n=e)}else{let e=this.parser.schema.marks[t.mark];n=n.concat(e.create(t.attrs))}let a=this.top;if(i&&i.isLeaf)this.findInside(e);else if(r)this.addElement(e,n,r);else if(t.getContent)this.findInside(e),t.getContent(e,this.parser.schema).forEach(e=>this.insertNode(e,n,!1));else{let r=e;"string"==typeof t.contentElement?r=e.querySelector(t.contentElement):"function"==typeof t.contentElement?r=t.contentElement(e):t.contentElement&&(r=t.contentElement),this.findAround(e,r,!0),this.addAll(r,n),this.findAround(e,r,!1)}o&&this.sync(a)&&this.open--}addAll(e,t,n,r){let o=n||0;for(let i=n?e.childNodes[n]:e.firstChild,a=null==r?null:e.childNodes[r];i!=a;i=i.nextSibling,++o)this.findAtPoint(e,o),this.addDOM(i,t);this.findAtPoint(e,o)}findPlace(e,t,n){let r,o;for(let i=this.open,a=0;i>=0;i--){let t=this.nodes[i],l=t.findWrapping(e);if(l&&(!r||r.length>l.length+a)&&(r=l,o=t,!l.length))break;if(t.solid){if(n)break;a+=2}}if(!r)return null;this.sync(o);for(let i=0;i<r.length;i++)t=this.enterInner(r[i],null,t,!1);return t}insertNode(e,t,n){if(e.isInline&&this.needsBlock&&!this.top.type){let e=this.textblockFromContext();e&&(t=this.enterInner(e,null,t))}let r=this.findPlace(e,t,n);if(r){this.closeExtra();let t=this.top;t.match&&(t.match=t.match.matchType(e.type));let n=Gt.none;for(let o of r.concat(e.marks))(t.type?t.type.allowsMarkType(o.type):Fn(o.type,e.type))&&(n=o.addToSet(n));return t.content.push(e.mark(n)),!0}return!1}enter(e,t,n,r){let o=this.findPlace(e.create(t),n,!1);return o&&(o=this.enterInner(e,t,n,!0,r)),o}enterInner(e,t,n,r=!1,o){this.closeExtra();let i=this.top;i.match=i.match&&i.match.matchType(e);let a=Pn(e,o,i.options);4&i.options&&0==i.content.length&&(a|=4);let l=Gt.none;return n=n.filter(t=>!(i.type?i.type.allowsMarkType(t.type):Fn(t.type,e))||(l=t.addToSet(l),!1)),this.nodes.push(new $n(e,t,l,r,null,a)),this.open++,n}closeExtra(e=!1){let t=this.nodes.length-1;if(t>this.open){for(;t>this.open;t--)this.nodes[t-1].content.push(this.nodes[t].finish(e));this.nodes.length=this.open+1}}finish(){return this.open=0,this.closeExtra(this.isOpen),this.nodes[0].finish(!(!this.isOpen&&!this.options.topOpen))}sync(e){for(let t=this.open;t>=0;t--){if(this.nodes[t]==e)return this.open=t,!0;this.localPreserveWS&&(this.nodes[t].options|=1)}return!1}get currentPos(){this.closeExtra();let e=0;for(let t=this.open;t>=0;t--){let n=this.nodes[t].content;for(let t=n.length-1;t>=0;t--)e+=n[t].nodeSize;t&&e++}return e}findAtPoint(e,t){if(this.find)for(let n=0;n<this.find.length;n++)this.find[n].node==e&&this.find[n].offset==t&&(this.find[n].pos=this.currentPos)}findInside(e){if(this.find)for(let t=0;t<this.find.length;t++)null==this.find[t].pos&&1==e.nodeType&&e.contains(this.find[t].node)&&(this.find[t].pos=this.currentPos)}findAround(e,t,n){if(e!=t&&this.find)for(let r=0;r<this.find.length;r++)if(null==this.find[r].pos&&1==e.nodeType&&e.contains(this.find[r].node)){t.compareDocumentPosition(this.find[r].node)&(n?2:4)&&(this.find[r].pos=this.currentPos)}}findInText(e){if(this.find)for(let t=0;t<this.find.length;t++)this.find[t].node==e&&(this.find[t].pos=this.currentPos-(e.nodeValue.length-this.find[t].offset))}matchesContext(e){if(e.indexOf("|")>-1)return e.split(/\s*\|\s*/).some(this.matchesContext,this);let t=e.split("/"),n=this.options.context,r=!(this.isOpen||n&&n.parent.type!=this.nodes[0].type),o=-(n?n.depth+1:0)+(r?0:1),i=(e,a)=>{for(;e>=0;e--){let l=t[e];if(""==l){if(e==t.length-1||0==e)continue;for(;a>=o;a--)if(i(e-1,a))return!0;return!1}{let e=a>0||0==a&&r?this.nodes[a].type:n&&a>=o?n.node(a-o).type:null;if(!e||e.name!=l&&!e.isInGroup(l))return!1;a--}}return!0};return i(t.length-1,this.open)}textblockFromContext(){let e=this.options.context;if(e)for(let t=e.depth;t>=0;t--){let n=e.node(t).contentMatchAt(e.indexAfter(t)).defaultType;if(n&&n.isTextblock&&n.defaultAttrs)return n}for(let t in this.parser.schema.nodes){let e=this.parser.schema.nodes[t];if(e.isTextblock&&e.defaultAttrs)return e}}}function Rn(e,t){return(e.matches||e.msMatchesSelector||e.webkitMatchesSelector||e.mozMatchesSelector).call(e,t)}function Hn(e){let t={};for(let n in e)t[n]=e[n];return t}function Fn(e,t){let n=t.schema.nodes;for(let r in n){let o=n[r];if(!o.allowsMarkType(e))continue;let i=[],a=e=>{i.push(e);for(let n=0;n<e.edgeCount;n++){let{type:r,next:o}=e.edge(n);if(r==t)return!0;if(i.indexOf(o)<0&&a(o))return!0}};if(a(o.contentMatch))return!0}}class jn{constructor(e,t){this.nodes=e,this.marks=t}serializeFragment(e,t={},n){n||(n=Gn(t).createDocumentFragment());let r=n,o=[];return e.forEach(e=>{if(o.length||e.marks.length){let n=0,i=0;for(;n<o.length&&i<e.marks.length;){let t=e.marks[i];if(this.marks[t.type.name]){if(!t.eq(o[n][0])||!1===t.type.spec.spanning)break;n++,i++}else i++}for(;n<o.length;)r=o.pop()[1];for(;i<e.marks.length;){let n=e.marks[i++],a=this.serializeMark(n,e.isInline,t);a&&(o.push([n,r]),r.appendChild(a.dom),r=a.contentDOM||a.dom)}}r.appendChild(this.serializeNodeInner(e,t))}),n}serializeNodeInner(e,t){let{dom:n,contentDOM:r}=Wn(Gn(t),this.nodes[e.type.name](e),null,e.attrs);if(r){if(e.isLeaf)throw new RangeError("Content hole not allowed in a leaf node spec");this.serializeFragment(e.content,t,r)}return n}serializeNode(e,t={}){let n=this.serializeNodeInner(e,t);for(let r=e.marks.length-1;r>=0;r--){let o=this.serializeMark(e.marks[r],e.isInline,t);o&&((o.contentDOM||o.dom).appendChild(n),n=o.dom)}return n}serializeMark(e,t,n={}){let r=this.marks[e.type.name];return r&&Wn(Gn(n),r(e,t),null,e.attrs)}static renderSpec(e,t,n=null,r){return Wn(e,t,n,r)}static fromSchema(e){return e.cached.domSerializer||(e.cached.domSerializer=new jn(this.nodesFromSchema(e),this.marksFromSchema(e)))}static nodesFromSchema(e){let t=Un(e.nodes);return t.text||(t.text=e=>e.text),t}static marksFromSchema(e){return Un(e.marks)}}function Un(e){let t={};for(let n in e){let r=e[n].spec.toDOM;r&&(t[n]=r)}return t}function Gn(e){return e.document||window.document}const qn=new WeakMap;function Zn(e){let t=qn.get(e);return void 0===t&&qn.set(e,t=function(e){let t=null;function n(e){if(e&&"object"==typeof e)if(Array.isArray(e))if("string"==typeof e[0])t||(t=[]),t.push(e);else for(let t=0;t<e.length;t++)n(e[t]);else for(let t in e)n(e[t])}return n(e),t}(e)),t}function Wn(e,t,n,r){if("string"==typeof t)return{dom:e.createTextNode(t)};if(null!=t.nodeType)return{dom:t};if(t.dom&&null!=t.dom.nodeType)return t;let o,i=t[0];if("string"!=typeof i)throw new RangeError("Invalid array passed to renderSpec");if(r&&(o=Zn(r))&&o.indexOf(t)>-1)throw new RangeError("Using an array from an attribute object as a DOM spec. This may be an attempted cross site scripting attack.");let a,l=i.indexOf(" ");l>0&&(n=i.slice(0,l),i=i.slice(l+1));let s=n?e.createElementNS(n,i):e.createElement(i),c=t[1],d=1;if(c&&"object"==typeof c&&null==c.nodeType&&!Array.isArray(c)){d=2;for(let e in c)if(null!=c[e]){let t=e.indexOf(" ");t>0?s.setAttributeNS(e.slice(0,t),e.slice(t+1),c[e]):"style"==e&&s.style?s.style.cssText=c[e]:s.setAttribute(e,c[e])}}for(let u=d;u<t.length;u++){let o=t[u];if(0===o){if(u<t.length-1||u>d)throw new RangeError("Content hole must be the only child of its parent node");return{dom:s,contentDOM:s}}{let{dom:t,contentDOM:i}=Wn(e,o,n,r);if(s.appendChild(t),i){if(a)throw new RangeError("Multiple content holes");a=i}}}return{dom:s,contentDOM:a}}const Kn=Math.pow(2,16);function Jn(e,t){return e+t*Kn}function Yn(e){return 65535&e}class Xn{constructor(e,t,n){this.pos=e,this.delInfo=t,this.recover=n}get deleted(){return(8&this.delInfo)>0}get deletedBefore(){return(5&this.delInfo)>0}get deletedAfter(){return(6&this.delInfo)>0}get deletedAcross(){return(4&this.delInfo)>0}}class Qn{constructor(e,t=!1){if(this.ranges=e,this.inverted=t,!e.length&&Qn.empty)return Qn.empty}recover(e){let t=0,n=Yn(e);if(!this.inverted)for(let r=0;r<n;r++)t+=this.ranges[3*r+2]-this.ranges[3*r+1];return this.ranges[3*n]+t+function(e){return(e-(65535&e))/Kn}(e)}mapResult(e,t=1){return this._map(e,t,!1)}map(e,t=1){return this._map(e,t,!0)}_map(e,t,n){let r=0,o=this.inverted?2:1,i=this.inverted?1:2;for(let a=0;a<this.ranges.length;a+=3){let l=this.ranges[a]-(this.inverted?r:0);if(l>e)break;let s=this.ranges[a+o],c=this.ranges[a+i],d=l+s;if(e<=d){let o=l+r+((s?e==l?-1:e==d?1:t:t)<0?0:c);if(n)return o;let i=e==(t<0?l:d)?null:Jn(a/3,e-l),u=e==l?2:e==d?1:4;return(t<0?e!=l:e!=d)&&(u|=8),new Xn(o,u,i)}r+=c-s}return n?e+r:new Xn(e+r,0,null)}touches(e,t){let n=0,r=Yn(t),o=this.inverted?2:1,i=this.inverted?1:2;for(let a=0;a<this.ranges.length;a+=3){let t=this.ranges[a]-(this.inverted?n:0);if(t>e)break;let l=this.ranges[a+o];if(e<=t+l&&a==3*r)return!0;n+=this.ranges[a+i]-l}return!1}forEach(e){let t=this.inverted?2:1,n=this.inverted?1:2;for(let r=0,o=0;r<this.ranges.length;r+=3){let i=this.ranges[r],a=i-(this.inverted?o:0),l=i+(this.inverted?0:o),s=this.ranges[r+t],c=this.ranges[r+n];e(a,a+s,l,l+c),o+=c-s}}invert(){return new Qn(this.ranges,!this.inverted)}toString(){return(this.inverted?"-":"")+JSON.stringify(this.ranges)}static offset(e){return 0==e?Qn.empty:new Qn(e<0?[0,-e,0]:[0,0,e])}}Qn.empty=new Qn([]);class er{constructor(e,t,n=0,r=(e?e.length:0)){this.mirror=t,this.from=n,this.to=r,this._maps=e||[],this.ownData=!(e||t)}get maps(){return this._maps}slice(e=0,t=this.maps.length){return new er(this._maps,this.mirror,e,t)}appendMap(e,t){this.ownData||(this._maps=this._maps.slice(),this.mirror=this.mirror&&this.mirror.slice(),this.ownData=!0),this.to=this._maps.push(e),null!=t&&this.setMirror(this._maps.length-1,t)}appendMapping(e){for(let t=0,n=this._maps.length;t<e._maps.length;t++){let r=e.getMirror(t);this.appendMap(e._maps[t],null!=r&&r<t?n+r:void 0)}}getMirror(e){if(this.mirror)for(let t=0;t<this.mirror.length;t++)if(this.mirror[t]==e)return this.mirror[t+(t%2?-1:1)]}setMirror(e,t){this.mirror||(this.mirror=[]),this.mirror.push(e,t)}appendMappingInverted(e){for(let t=e.maps.length-1,n=this._maps.length+e._maps.length;t>=0;t--){let r=e.getMirror(t);this.appendMap(e._maps[t].invert(),null!=r&&r>t?n-r-1:void 0)}}invert(){let e=new er;return e.appendMappingInverted(this),e}map(e,t=1){if(this.mirror)return this._map(e,t,!0);for(let n=this.from;n<this.to;n++)e=this._maps[n].map(e,t);return e}mapResult(e,t=1){return this._map(e,t,!1)}_map(e,t,n){let r=0;for(let o=this.from;o<this.to;o++){let n=this._maps[o].mapResult(e,t);if(null!=n.recover){let t=this.getMirror(o);if(null!=t&&t>o&&t<this.to){o=t,e=this._maps[t].recover(n.recover);continue}}r|=n.delInfo,e=n.pos}return n?e:new Xn(e,r,null)}}const tr=Object.create(null);class nr{getMap(){return Qn.empty}merge(e){return null}static fromJSON(e,t){if(!t||!t.stepType)throw new RangeError("Invalid input for Step.fromJSON");let n=tr[t.stepType];if(!n)throw new RangeError(`No step type ${t.stepType} defined`);return n.fromJSON(e,t)}static jsonID(e,t){if(e in tr)throw new RangeError("Duplicate use of step JSON ID "+e);return tr[e]=t,t.prototype.jsonID=e,t}}class rr{constructor(e,t){this.doc=e,this.failed=t}static ok(e){return new rr(e,null)}static fail(e){return new rr(null,e)}static fromReplace(e,t,n,r){try{return rr.ok(e.replace(t,n,r))}catch(o){if(o instanceof qt)return rr.fail(o.message);throw o}}}function or(e,t,n){let r=[];for(let o=0;o<e.childCount;o++){let i=e.child(o);i.content.size&&(i=i.copy(or(i.content,t,i))),i.isInline&&(i=t(i,n,o)),r.push(i)}return Ht.fromArray(r)}class ir extends nr{constructor(e,t,n){super(),this.from=e,this.to=t,this.mark=n}apply(e){let t=e.slice(this.from,this.to),n=e.resolve(this.from),r=n.node(n.sharedDepth(this.to)),o=new Zt(or(t.content,(e,t)=>e.isAtom&&t.type.allowsMarkType(this.mark.type)?e.mark(this.mark.addToSet(e.marks)):e,r),t.openStart,t.openEnd);return rr.fromReplace(e,this.from,this.to,o)}invert(){return new ar(this.from,this.to,this.mark)}map(e){let t=e.mapResult(this.from,1),n=e.mapResult(this.to,-1);return t.deleted&&n.deleted||t.pos>=n.pos?null:new ir(t.pos,n.pos,this.mark)}merge(e){return e instanceof ir&&e.mark.eq(this.mark)&&this.from<=e.to&&this.to>=e.from?new ir(Math.min(this.from,e.from),Math.max(this.to,e.to),this.mark):null}toJSON(){return{stepType:"addMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(e,t){if("number"!=typeof t.from||"number"!=typeof t.to)throw new RangeError("Invalid input for AddMarkStep.fromJSON");return new ir(t.from,t.to,e.markFromJSON(t.mark))}}nr.jsonID("addMark",ir);class ar extends nr{constructor(e,t,n){super(),this.from=e,this.to=t,this.mark=n}apply(e){let t=e.slice(this.from,this.to),n=new Zt(or(t.content,e=>e.mark(this.mark.removeFromSet(e.marks)),e),t.openStart,t.openEnd);return rr.fromReplace(e,this.from,this.to,n)}invert(){return new ir(this.from,this.to,this.mark)}map(e){let t=e.mapResult(this.from,1),n=e.mapResult(this.to,-1);return t.deleted&&n.deleted||t.pos>=n.pos?null:new ar(t.pos,n.pos,this.mark)}merge(e){return e instanceof ar&&e.mark.eq(this.mark)&&this.from<=e.to&&this.to>=e.from?new ar(Math.min(this.from,e.from),Math.max(this.to,e.to),this.mark):null}toJSON(){return{stepType:"removeMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(e,t){if("number"!=typeof t.from||"number"!=typeof t.to)throw new RangeError("Invalid input for RemoveMarkStep.fromJSON");return new ar(t.from,t.to,e.markFromJSON(t.mark))}}nr.jsonID("removeMark",ar);class lr extends nr{constructor(e,t){super(),this.pos=e,this.mark=t}apply(e){let t=e.nodeAt(this.pos);if(!t)return rr.fail("No node at mark step's position");let n=t.type.create(t.attrs,null,this.mark.addToSet(t.marks));return rr.fromReplace(e,this.pos,this.pos+1,new Zt(Ht.from(n),0,t.isLeaf?0:1))}invert(e){let t=e.nodeAt(this.pos);if(t){let e=this.mark.addToSet(t.marks);if(e.length==t.marks.length){for(let n=0;n<t.marks.length;n++)if(!t.marks[n].isInSet(e))return new lr(this.pos,t.marks[n]);return new lr(this.pos,this.mark)}}return new sr(this.pos,this.mark)}map(e){let t=e.mapResult(this.pos,1);return t.deletedAfter?null:new lr(t.pos,this.mark)}toJSON(){return{stepType:"addNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(e,t){if("number"!=typeof t.pos)throw new RangeError("Invalid input for AddNodeMarkStep.fromJSON");return new lr(t.pos,e.markFromJSON(t.mark))}}nr.jsonID("addNodeMark",lr);class sr extends nr{constructor(e,t){super(),this.pos=e,this.mark=t}apply(e){let t=e.nodeAt(this.pos);if(!t)return rr.fail("No node at mark step's position");let n=t.type.create(t.attrs,null,this.mark.removeFromSet(t.marks));return rr.fromReplace(e,this.pos,this.pos+1,new Zt(Ht.from(n),0,t.isLeaf?0:1))}invert(e){let t=e.nodeAt(this.pos);return t&&this.mark.isInSet(t.marks)?new lr(this.pos,this.mark):this}map(e){let t=e.mapResult(this.pos,1);return t.deletedAfter?null:new sr(t.pos,this.mark)}toJSON(){return{stepType:"removeNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(e,t){if("number"!=typeof t.pos)throw new RangeError("Invalid input for RemoveNodeMarkStep.fromJSON");return new sr(t.pos,e.markFromJSON(t.mark))}}nr.jsonID("removeNodeMark",sr);class cr extends nr{constructor(e,t,n,r=!1){super(),this.from=e,this.to=t,this.slice=n,this.structure=r}apply(e){return this.structure&&ur(e,this.from,this.to)?rr.fail("Structure replace would overwrite content"):rr.fromReplace(e,this.from,this.to,this.slice)}getMap(){return new Qn([this.from,this.to-this.from,this.slice.size])}invert(e){return new cr(this.from,this.from+this.slice.size,e.slice(this.from,this.to))}map(e){let t=e.mapResult(this.from,1),n=e.mapResult(this.to,-1);return t.deletedAcross&&n.deletedAcross?null:new cr(t.pos,Math.max(t.pos,n.pos),this.slice,this.structure)}merge(e){if(!(e instanceof cr)||e.structure||this.structure)return null;if(this.from+this.slice.size!=e.from||this.slice.openEnd||e.slice.openStart){if(e.to!=this.from||this.slice.openStart||e.slice.openEnd)return null;{let t=this.slice.size+e.slice.size==0?Zt.empty:new Zt(e.slice.content.append(this.slice.content),e.slice.openStart,this.slice.openEnd);return new cr(e.from,this.to,t,this.structure)}}{let t=this.slice.size+e.slice.size==0?Zt.empty:new Zt(this.slice.content.append(e.slice.content),this.slice.openStart,e.slice.openEnd);return new cr(this.from,this.to+(e.to-e.from),t,this.structure)}}toJSON(){let e={stepType:"replace",from:this.from,to:this.to};return this.slice.size&&(e.slice=this.slice.toJSON()),this.structure&&(e.structure=!0),e}static fromJSON(e,t){if("number"!=typeof t.from||"number"!=typeof t.to)throw new RangeError("Invalid input for ReplaceStep.fromJSON");return new cr(t.from,t.to,Zt.fromJSON(e,t.slice),!!t.structure)}}nr.jsonID("replace",cr);class dr extends nr{constructor(e,t,n,r,o,i,a=!1){super(),this.from=e,this.to=t,this.gapFrom=n,this.gapTo=r,this.slice=o,this.insert=i,this.structure=a}apply(e){if(this.structure&&(ur(e,this.from,this.gapFrom)||ur(e,this.gapTo,this.to)))return rr.fail("Structure gap-replace would overwrite content");let t=e.slice(this.gapFrom,this.gapTo);if(t.openStart||t.openEnd)return rr.fail("Gap is not a flat range");let n=this.slice.insertAt(this.insert,t.content);return n?rr.fromReplace(e,this.from,this.to,n):rr.fail("Content does not fit in gap")}getMap(){return new Qn([this.from,this.gapFrom-this.from,this.insert,this.gapTo,this.to-this.gapTo,this.slice.size-this.insert])}invert(e){let t=this.gapTo-this.gapFrom;return new dr(this.from,this.from+this.slice.size+t,this.from+this.insert,this.from+this.insert+t,e.slice(this.from,this.to).removeBetween(this.gapFrom-this.from,this.gapTo-this.from),this.gapFrom-this.from,this.structure)}map(e){let t=e.mapResult(this.from,1),n=e.mapResult(this.to,-1),r=this.from==this.gapFrom?t.pos:e.map(this.gapFrom,-1),o=this.to==this.gapTo?n.pos:e.map(this.gapTo,1);return t.deletedAcross&&n.deletedAcross||r<t.pos||o>n.pos?null:new dr(t.pos,n.pos,r,o,this.slice,this.insert,this.structure)}toJSON(){let e={stepType:"replaceAround",from:this.from,to:this.to,gapFrom:this.gapFrom,gapTo:this.gapTo,insert:this.insert};return this.slice.size&&(e.slice=this.slice.toJSON()),this.structure&&(e.structure=!0),e}static fromJSON(e,t){if("number"!=typeof t.from||"number"!=typeof t.to||"number"!=typeof t.gapFrom||"number"!=typeof t.gapTo||"number"!=typeof t.insert)throw new RangeError("Invalid input for ReplaceAroundStep.fromJSON");return new dr(t.from,t.to,t.gapFrom,t.gapTo,Zt.fromJSON(e,t.slice),t.insert,!!t.structure)}}function ur(e,t,n){let r=e.resolve(t),o=n-t,i=r.depth;for(;o>0&&i>0&&r.indexAfter(i)==r.node(i).childCount;)i--,o--;if(o>0){let e=r.node(i).maybeChild(r.indexAfter(i));for(;o>0;){if(!e||e.isLeaf)return!0;e=e.firstChild,o--}}return!1}function pr(e,t,n,r=n.contentMatch,o=!0){let i=e.doc.nodeAt(t),a=[],l=t+1;for(let s=0;s<i.childCount;s++){let t=i.child(s),c=l+t.nodeSize,d=r.matchType(t.type);if(d){r=d;for(let r=0;r<t.marks.length;r++)n.allowsMarkType(t.marks[r].type)||e.step(new ar(l,c,t.marks[r]));if(o&&t.isText&&"pre"!=n.whitespace){let e,r,o=/\r?\n|\r/g;for(;e=o.exec(t.text);)r||(r=new Zt(Ht.from(n.schema.text(" ",n.allowedMarks(t.marks))),0,0)),a.push(new cr(l+e.index,l+e.index+e[0].length,r))}}else a.push(new cr(l,c,Zt.empty));l=c}if(!r.validEnd){let t=r.fillBefore(Ht.empty,!0);e.replace(l,l,new Zt(t,0,0))}for(let s=a.length-1;s>=0;s--)e.step(a[s])}function hr(e,t,n){return(0==t||e.canReplace(t,e.childCount))&&(n==e.childCount||e.canReplace(0,n))}function mr(e){let t=e.parent.content.cutByIndex(e.startIndex,e.endIndex);for(let n=e.depth,r=0,o=0;;--n){let i=e.$from.node(n),a=e.$from.index(n)+r,l=e.$to.indexAfter(n)-o;if(n<e.depth&&i.canReplace(a,l,t))return n;if(0==n||i.type.spec.isolating||!hr(i,a,l))break;a&&(r=1),l<i.childCount&&(o=1)}return null}function fr(e,t,n=null,r=e){let o=function(e,t){let{parent:n,startIndex:r,endIndex:o}=e,i=n.contentMatchAt(r).findWrapping(t);if(!i)return null;let a=i.length?i[0]:t;return n.canReplaceWith(r,o,a)?i:null}(e,t),i=o&&function(e,t){let{parent:n,startIndex:r,endIndex:o}=e,i=n.child(r),a=t.contentMatch.findWrapping(i.type);if(!a)return null;let l=(a.length?a[a.length-1]:t).contentMatch;for(let s=r;l&&s<o;s++)l=l.matchType(n.child(s).type);return l&&l.validEnd?a:null}(r,t);return i?o.map(gr).concat({type:t,attrs:n}).concat(i.map(gr)):null}function gr(e){return{type:e,attrs:null}}function vr(e,t,n,r){t.forEach((o,i)=>{if(o.isText){let a,l=/\r?\n|\r/g;for(;a=l.exec(o.text);){let o=e.mapping.slice(r).map(n+1+i+a.index);e.replaceWith(o,o+1,t.type.schema.linebreakReplacement.create())}}})}function yr(e,t,n,r){t.forEach((o,i)=>{if(o.type==o.type.schema.linebreakReplacement){let o=e.mapping.slice(r).map(n+1+i);e.replaceWith(o,o+1,t.type.schema.text("\n"))}})}function br(e,t,n=1,r){let o=e.resolve(t),i=o.depth-n,a=r&&r[r.length-1]||o.parent;if(i<0||o.parent.type.spec.isolating||!o.parent.canReplace(o.index(),o.parent.childCount)||!a.type.validContent(o.parent.content.cutByIndex(o.index(),o.parent.childCount)))return!1;for(let c=o.depth-1,d=n-2;c>i;c--,d--){let e=o.node(c),t=o.index(c);if(e.type.spec.isolating)return!1;let n=e.content.cutByIndex(t,e.childCount),i=r&&r[d+1];i&&(n=n.replaceChild(0,i.type.create(i.attrs)));let a=r&&r[d]||e;if(!e.canReplace(t+1,e.childCount)||!a.type.validContent(n))return!1}let l=o.indexAfter(i),s=r&&r[0];return o.node(i).canReplaceWith(l,l,s?s.type:o.node(i+1).type)}function wr(e,t){let n=e.resolve(t),r=n.index();return kr(n.nodeBefore,n.nodeAfter)&&n.parent.canReplace(r,r+1)}function kr(e,t){return!(!e||!t||e.isLeaf||!function(e,t){t.content.size||e.type.compatibleContent(t.type);let n=e.contentMatchAt(e.childCount),{linebreakReplacement:r}=e.type.schema;for(let o=0;o<t.childCount;o++){let i=t.child(o),a=i.type==r?e.type.schema.nodes.text:i.type;if(n=n.matchType(a),!n)return!1;if(!e.type.allowsMarks(i.marks))return!1}return n.validEnd}(e,t))}function xr(e,t,n=-1){let r=e.resolve(t);for(let o=r.depth;;o--){let e,i,a=r.index(o);if(o==r.depth?(e=r.nodeBefore,i=r.nodeAfter):n>0?(e=r.node(o+1),a++,i=r.node(o).maybeChild(a)):(e=r.node(o).maybeChild(a-1),i=r.node(o+1)),e&&!e.isTextblock&&kr(e,i)&&r.node(o).canReplace(a,a+1))return t;if(0==o)break;t=n<0?r.before(o):r.after(o)}}function _r(e,t,n){let r=e.resolve(t);if(!n.content.size)return t;let o=n.content;for(let i=0;i<n.openStart;i++)o=o.firstChild.content;for(let i=1;i<=(0==n.openStart&&n.size?2:1);i++)for(let e=r.depth;e>=0;e--){let t=e==r.depth?0:r.pos<=(r.start(e+1)+r.end(e+1))/2?-1:1,n=r.index(e)+(t>0?1:0),a=r.node(e),l=!1;if(1==i)l=a.canReplace(n,n,o);else{let e=a.contentMatchAt(n).findWrapping(o.firstChild.type);l=e&&a.canReplaceWith(n,n,e[0])}if(l)return 0==t?r.pos:t<0?r.before(e+1):r.after(e+1)}return null}function Cr(e,t,n=t,r=Zt.empty){if(t==n&&!r.size)return null;let o=e.resolve(t),i=e.resolve(n);return Er(o,i,r)?new cr(t,n,r):new Sr(o,i,r).fit()}function Er(e,t,n){return!n.openStart&&!n.openEnd&&e.start()==t.start()&&e.parent.canReplace(e.index(),t.index(),n.content)}nr.jsonID("replaceAround",dr);class Sr{constructor(e,t,n){this.$from=e,this.$to=t,this.unplaced=n,this.frontier=[],this.placed=Ht.empty;for(let r=0;r<=e.depth;r++){let t=e.node(r);this.frontier.push({type:t.type,match:t.contentMatchAt(e.indexAfter(r))})}for(let r=e.depth;r>0;r--)this.placed=Ht.from(e.node(r).copy(this.placed))}get depth(){return this.frontier.length-1}fit(){for(;this.unplaced.size;){let e=this.findFittable();e?this.placeNodes(e):this.openMore()||this.dropNode()}let e=this.mustMoveInline(),t=this.placed.size-this.depth-this.$from.depth,n=this.$from,r=this.close(e<0?this.$to:n.doc.resolve(e));if(!r)return null;let o=this.placed,i=n.depth,a=r.depth;for(;i&&a&&1==o.childCount;)o=o.firstChild.content,i--,a--;let l=new Zt(o,i,a);return e>-1?new dr(n.pos,e,this.$to.pos,this.$to.end(),l,t):l.size||n.pos!=this.$to.pos?new cr(n.pos,r.pos,l):null}findFittable(){let e=this.unplaced.openStart;for(let t=this.unplaced.content,n=0,r=this.unplaced.openEnd;n<e;n++){let o=t.firstChild;if(t.childCount>1&&(r=0),o.type.spec.isolating&&r<=n){e=n;break}t=o.content}for(let t=1;t<=2;t++)for(let n=1==t?e:this.unplaced.openStart;n>=0;n--){let e,r=null;n?(r=Mr(this.unplaced.content,n-1).firstChild,e=r.content):e=this.unplaced.content;let o=e.firstChild;for(let i=this.depth;i>=0;i--){let e,{type:a,match:l}=this.frontier[i],s=null;if(1==t&&(o?l.matchType(o.type)||(s=l.fillBefore(Ht.from(o),!1)):r&&a.compatibleContent(r.type)))return{sliceDepth:n,frontierDepth:i,parent:r,inject:s};if(2==t&&o&&(e=l.findWrapping(o.type)))return{sliceDepth:n,frontierDepth:i,parent:r,wrap:e};if(r&&l.matchType(r.type))break}}}openMore(){let{content:e,openStart:t,openEnd:n}=this.unplaced,r=Mr(e,t);return!(!r.childCount||r.firstChild.isLeaf)&&(this.unplaced=new Zt(e,t+1,Math.max(n,r.size+t>=e.size-n?t+1:0)),!0)}dropNode(){let{content:e,openStart:t,openEnd:n}=this.unplaced,r=Mr(e,t);if(r.childCount<=1&&t>0){let o=e.size-t<=t+r.size;this.unplaced=new Zt(Br(e,t-1,1),t-1,o?t-1:n)}else this.unplaced=new Zt(Br(e,t,1),t,n)}placeNodes({sliceDepth:e,frontierDepth:t,parent:n,inject:r,wrap:o}){for(;this.depth>t;)this.closeFrontierNode();if(o)for(let m=0;m<o.length;m++)this.openFrontierNode(o[m]);let i=this.unplaced,a=n?n.content:i.content,l=i.openStart-e,s=0,c=[],{match:d,type:u}=this.frontier[t];if(r){for(let e=0;e<r.childCount;e++)c.push(r.child(e));d=d.matchFragment(r)}let p=a.size+e-(i.content.size-i.openEnd);for(;s<a.childCount;){let e=a.child(s),t=d.matchType(e.type);if(!t)break;s++,(s>1||0==l||e.content.size)&&(d=t,c.push(Tr(e.mark(u.allowedMarks(e.marks)),1==s?l:0,s==a.childCount?p:-1)))}let h=s==a.childCount;h||(p=-1),this.placed=Nr(this.placed,t,Ht.from(c)),this.frontier[t].match=d,h&&p<0&&n&&n.type==this.frontier[this.depth].type&&this.frontier.length>1&&this.closeFrontierNode();for(let m=0,f=a;m<p;m++){let e=f.lastChild;this.frontier.push({type:e.type,match:e.contentMatchAt(e.childCount)}),f=e.content}this.unplaced=h?0==e?Zt.empty:new Zt(Br(i.content,e-1,1),e-1,p<0?i.openEnd:e-1):new Zt(Br(i.content,e,s),i.openStart,i.openEnd)}mustMoveInline(){if(!this.$to.parent.isTextblock)return-1;let e,t=this.frontier[this.depth];if(!t.type.isTextblock||!Vr(this.$to,this.$to.depth,t.type,t.match,!1)||this.$to.depth==this.depth&&(e=this.findCloseLevel(this.$to))&&e.depth==this.depth)return-1;let{depth:n}=this.$to,r=this.$to.after(n);for(;n>1&&r==this.$to.end(--n);)++r;return r}findCloseLevel(e){e:for(let t=Math.min(this.depth,e.depth);t>=0;t--){let{match:n,type:r}=this.frontier[t],o=t<e.depth&&e.end(t+1)==e.pos+(e.depth-(t+1)),i=Vr(e,t,r,n,o);if(i){for(let n=t-1;n>=0;n--){let{match:t,type:r}=this.frontier[n],o=Vr(e,n,r,t,!0);if(!o||o.childCount)continue e}return{depth:t,fit:i,move:o?e.doc.resolve(e.after(t+1)):e}}}}close(e){let t=this.findCloseLevel(e);if(!t)return null;for(;this.depth>t.depth;)this.closeFrontierNode();t.fit.childCount&&(this.placed=Nr(this.placed,t.depth,t.fit)),e=t.move;for(let n=t.depth+1;n<=e.depth;n++){let t=e.node(n),r=t.type.contentMatch.fillBefore(t.content,!0,e.index(n));this.openFrontierNode(t.type,t.attrs,r)}return e}openFrontierNode(e,t=null,n){let r=this.frontier[this.depth];r.match=r.match.matchType(e),this.placed=Nr(this.placed,this.depth,Ht.from(e.create(t,n))),this.frontier.push({type:e,match:e.contentMatch})}closeFrontierNode(){let e=this.frontier.pop().match.fillBefore(Ht.empty,!0);e.childCount&&(this.placed=Nr(this.placed,this.frontier.length,e))}}function Br(e,t,n){return 0==t?e.cutByIndex(n,e.childCount):e.replaceChild(0,e.firstChild.copy(Br(e.firstChild.content,t-1,n)))}function Nr(e,t,n){return 0==t?e.append(n):e.replaceChild(e.childCount-1,e.lastChild.copy(Nr(e.lastChild.content,t-1,n)))}function Mr(e,t){for(let n=0;n<t;n++)e=e.firstChild.content;return e}function Tr(e,t,n){if(t<=0)return e;let r=e.content;return t>1&&(r=r.replaceChild(0,Tr(r.firstChild,t-1,1==r.childCount?n-1:0))),t>0&&(r=e.type.contentMatch.fillBefore(r).append(r),n<=0&&(r=r.append(e.type.contentMatch.matchFragment(r).fillBefore(Ht.empty,!0)))),e.copy(r)}function Vr(e,t,n,r,o){let i=e.node(t),a=o?e.indexAfter(t):e.index(t);if(a==i.childCount&&!n.compatibleContent(i.type))return null;let l=r.fillBefore(i.content,!0,a);return l&&!function(e,t,n){for(let r=n;r<t.childCount;r++)if(!e.allowsMarks(t.child(r).marks))return!0;return!1}(n,i.content,a)?l:null}function Ar(e){return e.spec.defining||e.spec.definingForContent}function zr(e,t,n,r,o){if(t<n){let o=e.firstChild;e=e.replaceChild(0,o.copy(zr(o.content,t+1,n,r,o)))}if(t>r){let t=o.contentMatchAt(0),n=t.fillBefore(e).append(e);e=n.append(t.matchFragment(n).fillBefore(Ht.empty,!0))}return e}function Or(e,t){let n=[];for(let r=Math.min(e.depth,t.depth);r>=0;r--){let o=e.start(r);if(o<e.pos-(e.depth-r)||t.end(r)>t.pos+(t.depth-r)||e.node(r).type.spec.isolating||t.node(r).type.spec.isolating)break;(o==t.start(r)||r==e.depth&&r==t.depth&&e.parent.inlineContent&&t.parent.inlineContent&&r&&t.start(r-1)==o-1)&&n.push(r)}return n}class Ir extends nr{constructor(e,t,n){super(),this.pos=e,this.attr=t,this.value=n}apply(e){let t=e.nodeAt(this.pos);if(!t)return rr.fail("No node at attribute step's position");let n=Object.create(null);for(let o in t.attrs)n[o]=t.attrs[o];n[this.attr]=this.value;let r=t.type.create(n,null,t.marks);return rr.fromReplace(e,this.pos,this.pos+1,new Zt(Ht.from(r),0,t.isLeaf?0:1))}getMap(){return Qn.empty}invert(e){return new Ir(this.pos,this.attr,e.nodeAt(this.pos).attrs[this.attr])}map(e){let t=e.mapResult(this.pos,1);return t.deletedAfter?null:new Ir(t.pos,this.attr,this.value)}toJSON(){return{stepType:"attr",pos:this.pos,attr:this.attr,value:this.value}}static fromJSON(e,t){if("number"!=typeof t.pos||"string"!=typeof t.attr)throw new RangeError("Invalid input for AttrStep.fromJSON");return new Ir(t.pos,t.attr,t.value)}}nr.jsonID("attr",Ir);class Dr extends nr{constructor(e,t){super(),this.attr=e,this.value=t}apply(e){let t=Object.create(null);for(let r in e.attrs)t[r]=e.attrs[r];t[this.attr]=this.value;let n=e.type.create(t,e.content,e.marks);return rr.ok(n)}getMap(){return Qn.empty}invert(e){return new Dr(this.attr,e.attrs[this.attr])}map(e){return this}toJSON(){return{stepType:"docAttr",attr:this.attr,value:this.value}}static fromJSON(e,t){if("string"!=typeof t.attr)throw new RangeError("Invalid input for DocAttrStep.fromJSON");return new Dr(t.attr,t.value)}}nr.jsonID("docAttr",Dr);let Pr=class extends Error{};Pr=function e(t){let n=Error.call(this,t);return n.__proto__=e.prototype,n},(Pr.prototype=Object.create(Error.prototype)).constructor=Pr,Pr.prototype.name="TransformError";class $r{constructor(e){this.doc=e,this.steps=[],this.docs=[],this.mapping=new er}get before(){return this.docs.length?this.docs[0]:this.doc}step(e){let t=this.maybeStep(e);if(t.failed)throw new Pr(t.failed);return this}maybeStep(e){let t=e.apply(this.doc);return t.failed||this.addStep(e,t.doc),t}get docChanged(){return this.steps.length>0}changedRange(){let e=1e9,t=-1e9;for(let n=0;n<this.mapping.maps.length;n++){let r=this.mapping.maps[n];n&&(e=r.map(e,1),t=r.map(t,-1)),r.forEach((n,r,o,i)=>{e=Math.min(e,o),t=Math.max(t,i)})}return 1e9==e?null:{from:e,to:t}}addStep(e,t){this.docs.push(this.doc),this.steps.push(e),this.mapping.appendMap(e.getMap()),this.doc=t}replace(e,t=e,n=Zt.empty){let r=Cr(this.doc,e,t,n);return r&&this.step(r),this}replaceWith(e,t,n){return this.replace(e,t,new Zt(Ht.from(n),0,0))}delete(e,t){return this.replace(e,t,Zt.empty)}insert(e,t){return this.replaceWith(e,e,t)}replaceRange(e,t,n){return function(e,t,n,r){if(!r.size)return e.deleteRange(t,n);let o=e.doc.resolve(t),i=e.doc.resolve(n);if(Er(o,i,r))return e.step(new cr(t,n,r));let a=Or(o,i);0==a[a.length-1]&&a.pop();let l=-(o.depth+1);a.unshift(l);for(let p=o.depth,h=o.pos-1;p>0;p--,h--){let e=o.node(p).type.spec;if(e.defining||e.definingAsContext||e.isolating)break;a.indexOf(p)>-1?l=p:o.before(p)==h&&a.splice(1,0,-p)}let s=a.indexOf(l),c=[],d=r.openStart;for(let p=r.content,h=0;;h++){let e=p.firstChild;if(c.push(e),h==r.openStart)break;p=e.content}for(let p=d-1;p>=0;p--){let e=c[p],t=Ar(e.type);if(t&&!e.sameMarkup(o.node(Math.abs(l)-1)))d=p;else if(t||!e.type.isTextblock)break}for(let p=r.openStart;p>=0;p--){let t=(p+d+1)%(r.openStart+1),l=c[t];if(l)for(let c=0;c<a.length;c++){let d=a[(c+s)%a.length],u=!0;d<0&&(u=!1,d=-d);let p=o.node(d-1),h=o.index(d-1);if(p.canReplaceWith(h,h,l.type,l.marks))return e.replace(o.before(d),u?i.after(d):n,new Zt(zr(r.content,0,r.openStart,t),t,r.openEnd))}}let u=e.steps.length;for(let p=a.length-1;p>=0&&(e.replace(t,n,r),!(e.steps.length>u));p--){let e=a[p];e<0||(t=o.before(e),n=i.after(e))}}(this,e,t,n),this}replaceRangeWith(e,t,n){return function(e,t,n,r){if(!r.isInline&&t==n&&e.doc.resolve(t).parent.content.size){let o=function(e,t,n){let r=e.resolve(t);if(r.parent.canReplaceWith(r.index(),r.index(),n))return t;if(0==r.parentOffset)for(let o=r.depth-1;o>=0;o--){let e=r.index(o);if(r.node(o).canReplaceWith(e,e,n))return r.before(o+1);if(e>0)return null}if(r.parentOffset==r.parent.content.size)for(let o=r.depth-1;o>=0;o--){let e=r.indexAfter(o);if(r.node(o).canReplaceWith(e,e,n))return r.after(o+1);if(e<r.node(o).childCount)return null}return null}(e.doc,t,r.type);null!=o&&(t=n=o)}e.replaceRange(t,n,new Zt(Ht.from(r),0,0))}(this,e,t,n),this}deleteRange(e,t){return function(e,t,n){let r=e.doc.resolve(t),o=e.doc.resolve(n),i=Or(r,o);for(let a=0;a<i.length;a++){let t=i[a],n=a==i.length-1;if(n&&0==t||r.node(t).type.contentMatch.validEnd)return e.delete(r.start(t),o.end(t));if(t>0&&(n||r.node(t-1).canReplace(r.index(t-1),o.indexAfter(t-1))))return e.delete(r.before(t),o.after(t))}for(let a=1;a<=r.depth&&a<=o.depth;a++)if(t-r.start(a)==r.depth-a&&n>r.end(a)&&o.end(a)-n!=o.depth-a&&r.start(a-1)==o.start(a-1)&&r.node(a-1).canReplace(r.index(a-1),o.index(a-1)))return e.delete(r.before(a),n);e.delete(t,n)}(this,e,t),this}lift(e,t){return function(e,t,n){let{$from:r,$to:o,depth:i}=t,a=r.before(i+1),l=o.after(i+1),s=a,c=l,d=Ht.empty,u=0;for(let m=i,f=!1;m>n;m--)f||r.index(m)>0?(f=!0,d=Ht.from(r.node(m).copy(d)),u++):s--;let p=Ht.empty,h=0;for(let m=i,f=!1;m>n;m--)f||o.after(m+1)<o.end(m)?(f=!0,p=Ht.from(o.node(m).copy(p)),h++):c++;e.step(new dr(s,c,a,l,new Zt(d.append(p),u,h),d.size-u,!0))}(this,e,t),this}join(e,t=1){return function(e,t,n){let r=null,{linebreakReplacement:o}=e.doc.type.schema,i=e.doc.resolve(t-n),a=i.node().type;if(o&&a.inlineContent){let e="pre"==a.whitespace,t=!!a.contentMatch.matchType(o);e&&!t?r=!1:!e&&t&&(r=!0)}let l=e.steps.length;if(!1===r){let r=e.doc.resolve(t+n);yr(e,r.node(),r.before(),l)}a.inlineContent&&pr(e,t+n-1,a,i.node().contentMatchAt(i.index()),null==r);let s=e.mapping.slice(l),c=s.map(t-n);if(e.step(new cr(c,s.map(t+n,-1),Zt.empty,!0)),!0===r){let t=e.doc.resolve(c);vr(e,t.node(),t.before(),e.steps.length)}}(this,e,t),this}wrap(e,t){return function(e,t,n){let r=Ht.empty;for(let a=n.length-1;a>=0;a--){if(r.size){let e=n[a].type.contentMatch.matchFragment(r);if(!e||!e.validEnd)throw new RangeError("Wrapper type given to Transform.wrap does not form valid content of its parent wrapper")}r=Ht.from(n[a].type.create(n[a].attrs,r))}let o=t.start,i=t.end;e.step(new dr(o,i,o,i,new Zt(r,0,0),n.length,!0))}(this,e,t),this}setBlockType(e,t=e,n,r=null){return function(e,t,n,r,o){if(!r.isTextblock)throw new RangeError("Type given to setBlockType should be a textblock");let i=e.steps.length;e.doc.nodesBetween(t,n,(t,n)=>{let a="function"==typeof o?o(t):o;if(t.isTextblock&&!t.hasMarkup(r,a)&&function(e,t,n){let r=e.resolve(t),o=r.index();return r.parent.canReplaceWith(o,o+1,n)}(e.doc,e.mapping.slice(i).map(n),r)){let o=null;if(r.schema.linebreakReplacement){let e="pre"==r.whitespace,t=!!r.contentMatch.matchType(r.schema.linebreakReplacement);e&&!t?o=!1:!e&&t&&(o=!0)}!1===o&&yr(e,t,n,i),pr(e,e.mapping.slice(i).map(n,1),r,void 0,null===o);let l=e.mapping.slice(i),s=l.map(n,1),c=l.map(n+t.nodeSize,1);return e.step(new dr(s,c,s+1,c-1,new Zt(Ht.from(r.create(a,null,t.marks)),0,0),1,!0)),!0===o&&vr(e,t,n,i),!1}})}(this,e,t,n,r),this}setNodeMarkup(e,t,n=null,r){return function(e,t,n,r,o){let i=e.doc.nodeAt(t);if(!i)throw new RangeError("No node at given position");n||(n=i.type);let a=n.create(r,null,o||i.marks);if(i.isLeaf)return e.replaceWith(t,t+i.nodeSize,a);if(!n.validContent(i.content))throw new RangeError("Invalid content for node type "+n.name);e.step(new dr(t,t+i.nodeSize,t+1,t+i.nodeSize-1,new Zt(Ht.from(a),0,0),1,!0))}(this,e,t,n,r),this}setNodeAttribute(e,t,n){return this.step(new Ir(e,t,n)),this}setDocAttribute(e,t){return this.step(new Dr(e,t)),this}addNodeMark(e,t){return this.step(new lr(e,t)),this}removeNodeMark(e,t){let n=this.doc.nodeAt(e);if(!n)throw new RangeError("No node at position "+e);if(t instanceof Gt)t.isInSet(n.marks)&&this.step(new sr(e,t));else{let r,o=n.marks,i=[];for(;r=t.isInSet(o);)i.push(new sr(e,r)),o=r.removeFromSet(o);for(let e=i.length-1;e>=0;e--)this.step(i[e])}return this}split(e,t=1,n){return function(e,t,n=1,r){let o=e.doc.resolve(t),i=Ht.empty,a=Ht.empty;for(let l=o.depth,s=o.depth-n,c=n-1;l>s;l--,c--){i=Ht.from(o.node(l).copy(i));let e=r&&r[c];a=Ht.from(e?e.type.create(e.attrs,a):o.node(l).copy(a))}e.step(new cr(t,t,new Zt(i.append(a),n,n),!0))}(this,e,t,n),this}addMark(e,t,n){return function(e,t,n,r){let o,i,a=[],l=[];e.doc.nodesBetween(t,n,(e,s,c)=>{if(!e.isInline)return;let d=e.marks;if(!r.isInSet(d)&&c.type.allowsMarkType(r.type)){let c=Math.max(s,t),u=Math.min(s+e.nodeSize,n),p=r.addToSet(d);for(let e=0;e<d.length;e++)d[e].isInSet(p)||(o&&o.to==c&&o.mark.eq(d[e])?o.to=u:a.push(o=new ar(c,u,d[e])));i&&i.to==c?i.to=u:l.push(i=new ir(c,u,r))}}),a.forEach(t=>e.step(t)),l.forEach(t=>e.step(t))}(this,e,t,n),this}removeMark(e,t,n){return function(e,t,n,r){let o=[],i=0;e.doc.nodesBetween(t,n,(e,a)=>{if(!e.isInline)return;i++;let l=null;if(r instanceof Tn){let t,n=e.marks;for(;t=r.isInSet(n);)(l||(l=[])).push(t),n=t.removeFromSet(n)}else r?r.isInSet(e.marks)&&(l=[r]):l=e.marks;if(l&&l.length){let r=Math.min(a+e.nodeSize,n);for(let e=0;e<l.length;e++){let n,s=l[e];for(let e=0;e<o.length;e++){let t=o[e];t.step==i-1&&s.eq(o[e].style)&&(n=t)}n?(n.to=r,n.step=i):o.push({style:s,from:Math.max(a,t),to:r,step:i})}}}),o.forEach(t=>e.step(new ar(t.from,t.to,t.style)))}(this,e,t,n),this}clearIncompatible(e,t,n){return pr(this,e,t,n),this}}const Lr=Object.create(null);class Rr{constructor(e,t,n){this.$anchor=e,this.$head=t,this.ranges=n||[new Hr(e.min(t),e.max(t))]}get anchor(){return this.$anchor.pos}get head(){return this.$head.pos}get from(){return this.$from.pos}get to(){return this.$to.pos}get $from(){return this.ranges[0].$from}get $to(){return this.ranges[0].$to}get empty(){let e=this.ranges;for(let t=0;t<e.length;t++)if(e[t].$from.pos!=e[t].$to.pos)return!1;return!0}content(){return this.$from.doc.slice(this.from,this.to,!0)}replace(e,t=Zt.empty){let n=t.content.lastChild,r=null;for(let a=0;a<t.openEnd;a++)r=n,n=n.lastChild;let o=e.steps.length,i=this.ranges;for(let a=0;a<i.length;a++){let{$from:l,$to:s}=i[a],c=e.mapping.slice(o);e.replaceRange(c.map(l.pos),c.map(s.pos),a?Zt.empty:t),0==a&&Yr(e,o,(n?n.isInline:r&&r.isTextblock)?-1:1)}}replaceWith(e,t){let n=e.steps.length,r=this.ranges;for(let o=0;o<r.length;o++){let{$from:i,$to:a}=r[o],l=e.mapping.slice(n),s=l.map(i.pos),c=l.map(a.pos);o?e.deleteRange(s,c):(e.replaceRangeWith(s,c,t),Yr(e,n,t.isInline?-1:1))}}static findFrom(e,t,n=!1){let r=e.parent.inlineContent?new Ur(e):Jr(e.node(0),e.parent,e.pos,e.index(),t,n);if(r)return r;for(let o=e.depth-1;o>=0;o--){let r=t<0?Jr(e.node(0),e.node(o),e.before(o+1),e.index(o),t,n):Jr(e.node(0),e.node(o),e.after(o+1),e.index(o)+1,t,n);if(r)return r}return null}static near(e,t=1){return this.findFrom(e,t)||this.findFrom(e,-t)||new Wr(e.node(0))}static atStart(e){return Jr(e,e,0,0,1)||new Wr(e)}static atEnd(e){return Jr(e,e,e.content.size,e.childCount,-1)||new Wr(e)}static fromJSON(e,t){if(!t||!t.type)throw new RangeError("Invalid input for Selection.fromJSON");let n=Lr[t.type];if(!n)throw new RangeError(`No selection type ${t.type} defined`);return n.fromJSON(e,t)}static jsonID(e,t){if(e in Lr)throw new RangeError("Duplicate use of selection JSON ID "+e);return Lr[e]=t,t.prototype.jsonID=e,t}getBookmark(){return Ur.between(this.$anchor,this.$head).getBookmark()}}Rr.prototype.visible=!0;class Hr{constructor(e,t){this.$from=e,this.$to=t}}let Fr=!1;function jr(e){Fr||e.parent.inlineContent||(Fr=!0)}class Ur extends Rr{constructor(e,t=e){jr(e),jr(t),super(e,t)}get $cursor(){return this.$anchor.pos==this.$head.pos?this.$head:null}map(e,t){let n=e.resolve(t.map(this.head));if(!n.parent.inlineContent)return Rr.near(n);let r=e.resolve(t.map(this.anchor));return new Ur(r.parent.inlineContent?r:n,n)}replace(e,t=Zt.empty){if(super.replace(e,t),t==Zt.empty){let t=this.$from.marksAcross(this.$to);t&&e.ensureMarks(t)}}eq(e){return e instanceof Ur&&e.anchor==this.anchor&&e.head==this.head}getBookmark(){return new Gr(this.anchor,this.head)}toJSON(){return{type:"text",anchor:this.anchor,head:this.head}}static fromJSON(e,t){if("number"!=typeof t.anchor||"number"!=typeof t.head)throw new RangeError("Invalid input for TextSelection.fromJSON");return new Ur(e.resolve(t.anchor),e.resolve(t.head))}static create(e,t,n=t){let r=e.resolve(t);return new this(r,n==t?r:e.resolve(n))}static between(e,t,n){let r=e.pos-t.pos;if(n&&!r||(n=r>=0?1:-1),!t.parent.inlineContent){let e=Rr.findFrom(t,n,!0)||Rr.findFrom(t,-n,!0);if(!e)return Rr.near(t,n);t=e.$head}return e.parent.inlineContent||(0==r||(e=(Rr.findFrom(e,-n,!0)||Rr.findFrom(e,n,!0)).$anchor).pos<t.pos!=r<0)&&(e=t),new Ur(e,t)}}Rr.jsonID("text",Ur);class Gr{constructor(e,t){this.anchor=e,this.head=t}map(e){return new Gr(e.map(this.anchor),e.map(this.head))}resolve(e){return Ur.between(e.resolve(this.anchor),e.resolve(this.head))}}class qr extends Rr{constructor(e){let t=e.nodeAfter,n=e.node(0).resolve(e.pos+t.nodeSize);super(e,n),this.node=t}map(e,t){let{deleted:n,pos:r}=t.mapResult(this.anchor),o=e.resolve(r);return n?Rr.near(o):new qr(o)}content(){return new Zt(Ht.from(this.node),0,0)}eq(e){return e instanceof qr&&e.anchor==this.anchor}toJSON(){return{type:"node",anchor:this.anchor}}getBookmark(){return new Zr(this.anchor)}static fromJSON(e,t){if("number"!=typeof t.anchor)throw new RangeError("Invalid input for NodeSelection.fromJSON");return new qr(e.resolve(t.anchor))}static create(e,t){return new qr(e.resolve(t))}static isSelectable(e){return!e.isText&&!1!==e.type.spec.selectable}}qr.prototype.visible=!1,Rr.jsonID("node",qr);class Zr{constructor(e){this.anchor=e}map(e){let{deleted:t,pos:n}=e.mapResult(this.anchor);return t?new Gr(n,n):new Zr(n)}resolve(e){let t=e.resolve(this.anchor),n=t.nodeAfter;return n&&qr.isSelectable(n)?new qr(t):Rr.near(t)}}class Wr extends Rr{constructor(e){super(e.resolve(0),e.resolve(e.content.size))}replace(e,t=Zt.empty){if(t==Zt.empty){e.delete(0,e.doc.content.size);let t=Rr.atStart(e.doc);t.eq(e.selection)||e.setSelection(t)}else super.replace(e,t)}toJSON(){return{type:"all"}}static fromJSON(e){return new Wr(e)}map(e){return new Wr(e)}eq(e){return e instanceof Wr}getBookmark(){return Kr}}Rr.jsonID("all",Wr);const Kr={map(){return this},resolve:e=>new Wr(e)};function Jr(e,t,n,r,o,i=!1){if(t.inlineContent)return Ur.create(e,n);for(let a=r-(o>0?0:1);o>0?a<t.childCount:a>=0;a+=o){let r=t.child(a);if(r.isAtom){if(!i&&qr.isSelectable(r))return qr.create(e,n-(o<0?r.nodeSize:0))}else{let t=Jr(e,r,n+o,o<0?r.childCount:0,o,i);if(t)return t}n+=r.nodeSize*o}return null}function Yr(e,t,n){let r=e.steps.length-1;if(r<t)return;let o,i=e.steps[r];(i instanceof cr||i instanceof dr)&&(e.mapping.maps[r].forEach((e,t,n,r)=>{null==o&&(o=r)}),e.setSelection(Rr.near(e.doc.resolve(o),n)))}function Xr(e,t){return t&&e?e.bind(t):e}class Qr{constructor(e,t,n){this.name=e,this.init=Xr(t.init,n),this.apply=Xr(t.apply,n)}}function eo(e,t,n){for(let r in e){let o=e[r];o instanceof Function?o=o.bind(t):"handleDOMEvents"==r&&(o=eo(o,t,{})),n[r]=o}return n}new Qr("doc",{init:e=>e.doc||e.schema.topNodeType.createAndFill(),apply:e=>e.doc}),new Qr("selection",{init:(e,t)=>e.selection||Rr.atStart(t.doc),apply:e=>e.selection}),new Qr("storedMarks",{init:e=>e.storedMarks||null,apply:(e,t,n,r)=>r.selection.$cursor?e.storedMarks:null}),new Qr("scrollToSelection",{init:()=>0,apply:(e,t)=>e.scrolledIntoView?t+1:t});class to{constructor(e){this.spec=e,this.props={},e.props&&eo(e.props,this,this.props),this.key=e.key?e.key.key:ro("plugin")}getState(e){return e[this.key]}}const no=Object.create(null);function ro(e){return e in no?e+"$"+ ++no[e]:(no[e]=0,e+"$")}class oo{constructor(e="key"){this.key=ro(e)}get(e){return e.config.pluginsByKey[this.key]}getState(e){return e[this.key]}}const io=(e,t)=>!e.selection.empty&&(t&&t(e.tr.deleteSelection().scrollIntoView()),!0);function ao(e,t){let{$cursor:n}=e.selection;return!n||(t?!t.endOfTextblock("backward",e):n.parentOffset>0)?null:n}const lo=(e,t,n)=>{let r=ao(e,n);if(!r)return!1;let o=po(r);if(!o){let n=r.blockRange(),o=n&&mr(n);return null!=o&&(t&&t(e.tr.lift(n,o).scrollIntoView()),!0)}let i=o.nodeBefore;if(xo(e,o,t,-1))return!0;if(0==r.parent.content.size&&(co(i,"end")||qr.isSelectable(i)))for(let a=r.depth;;a--){let n=Cr(e.doc,r.before(a),r.after(a),Zt.empty);if(n&&n.slice.size<n.to-n.from){if(t){let r=e.tr.step(n);r.setSelection(co(i,"end")?Rr.findFrom(r.doc.resolve(r.mapping.map(o.pos,-1)),-1):qr.create(r.doc,o.pos-i.nodeSize)),t(r.scrollIntoView())}return!0}if(1==a||r.node(a-1).childCount>1)break}return!(!i.isAtom||o.depth!=r.depth-1)&&(t&&t(e.tr.delete(o.pos-i.nodeSize,o.pos).scrollIntoView()),!0)};function so(e,t,n){let r=t.nodeBefore,o=t.pos-1;for(;!r.isTextblock;o--){if(r.type.spec.isolating)return!1;let e=r.lastChild;if(!e)return!1;r=e}let i=t.nodeAfter,a=t.pos+1;for(;!i.isTextblock;a++){if(i.type.spec.isolating)return!1;let e=i.firstChild;if(!e)return!1;i=e}let l=Cr(e.doc,o,a,Zt.empty);if(!l||l.from!=o||l instanceof cr&&l.slice.size>=a-o)return!1;if(n){let t=e.tr.step(l);t.setSelection(Ur.create(t.doc,o)),n(t.scrollIntoView())}return!0}function co(e,t,n=!1){for(let r=e;r;r="start"==t?r.firstChild:r.lastChild){if(r.isTextblock)return!0;if(n&&1!=r.childCount)return!1}return!1}const uo=(e,t,n)=>{let{$head:r,empty:o}=e.selection,i=r;if(!o)return!1;if(r.parent.isTextblock){if(n?!n.endOfTextblock("backward",e):r.parentOffset>0)return!1;i=po(r)}let a=i&&i.nodeBefore;return!(!a||!qr.isSelectable(a))&&(t&&t(e.tr.setSelection(qr.create(e.doc,i.pos-a.nodeSize)).scrollIntoView()),!0)};function po(e){if(!e.parent.type.spec.isolating)for(let t=e.depth-1;t>=0;t--){if(e.index(t)>0)return e.doc.resolve(e.before(t+1));if(e.node(t).type.spec.isolating)break}return null}function ho(e,t){let{$cursor:n}=e.selection;return!n||(t?!t.endOfTextblock("forward",e):n.parentOffset<n.parent.content.size)?null:n}const mo=(e,t,n)=>{let r=ho(e,n);if(!r)return!1;let o=go(r);if(!o)return!1;let i=o.nodeAfter;if(xo(e,o,t,1))return!0;if(0==r.parent.content.size&&(co(i,"start")||qr.isSelectable(i))){let n=Cr(e.doc,r.before(),r.after(),Zt.empty);if(n&&n.slice.size<n.to-n.from){if(t){let r=e.tr.step(n);r.setSelection(co(i,"start")?Rr.findFrom(r.doc.resolve(r.mapping.map(o.pos)),1):qr.create(r.doc,r.mapping.map(o.pos))),t(r.scrollIntoView())}return!0}}return!(!i.isAtom||o.depth!=r.depth-1)&&(t&&t(e.tr.delete(o.pos,o.pos+i.nodeSize).scrollIntoView()),!0)},fo=(e,t,n)=>{let{$head:r,empty:o}=e.selection,i=r;if(!o)return!1;if(r.parent.isTextblock){if(n?!n.endOfTextblock("forward",e):r.parentOffset<r.parent.content.size)return!1;i=go(r)}let a=i&&i.nodeAfter;return!(!a||!qr.isSelectable(a))&&(t&&t(e.tr.setSelection(qr.create(e.doc,i.pos)).scrollIntoView()),!0)};function go(e){if(!e.parent.type.spec.isolating)for(let t=e.depth-1;t>=0;t--){let n=e.node(t);if(e.index(t)+1<n.childCount)return e.doc.resolve(e.after(t+1));if(n.type.spec.isolating)break}return null}const vo=(e,t)=>{let{$head:n,$anchor:r}=e.selection;return!(!n.parent.type.spec.code||!n.sameParent(r))&&(t&&t(e.tr.insertText("\n").scrollIntoView()),!0)};function yo(e){for(let t=0;t<e.edgeCount;t++){let{type:n}=e.edge(t);if(n.isTextblock&&!n.hasRequiredAttrs())return n}return null}const bo=(e,t)=>{let n=e.selection,{$from:r,$to:o}=n;if(n instanceof Wr||r.parent.inlineContent||o.parent.inlineContent)return!1;let i=yo(o.parent.contentMatchAt(o.indexAfter()));if(!i||!i.isTextblock)return!1;if(t){let n=(!r.parentOffset&&o.index()<o.parent.childCount?r:o).pos,a=e.tr.insert(n,i.createAndFill());a.setSelection(Ur.create(a.doc,n+1)),t(a.scrollIntoView())}return!0},wo=(e,t)=>{let{$cursor:n}=e.selection;if(!n||n.parent.content.size)return!1;if(n.depth>1&&n.after()!=n.end(-1)){let r=n.before();if(br(e.doc,r))return t&&t(e.tr.split(r).scrollIntoView()),!0}let r=n.blockRange(),o=r&&mr(r);return null!=o&&(t&&t(e.tr.lift(r,o).scrollIntoView()),!0)};const ko=(e,t)=>{let{$from:n,$to:r}=e.selection;if(e.selection instanceof qr&&e.selection.node.isBlock)return!(!n.parentOffset||!br(e.doc,n.pos)||(t&&t(e.tr.split(n.pos).scrollIntoView()),0));if(!n.depth)return!1;let o,i,a=[],l=!1,s=!1;for(let p=n.depth;;p--){if(n.node(p).isBlock){l=n.end(p)==n.pos+(n.depth-p),s=n.start(p)==n.pos-(n.depth-p),i=yo(n.node(p-1).contentMatchAt(n.indexAfter(p-1))),a.unshift(l&&i?{type:i}:null),o=p;break}if(1==p)return!1;a.unshift(null)}let c=e.tr;(e.selection instanceof Ur||e.selection instanceof Wr)&&c.deleteSelection();let d=c.mapping.map(n.pos),u=br(c.doc,d,a.length,a);if(u||(a[0]=i?{type:i}:null,u=br(c.doc,d,a.length,a)),!u)return!1;if(c.split(d,a.length,a),!l&&s&&n.node(o).type!=i){let e=c.mapping.map(n.before(o)),t=c.doc.resolve(e);i&&n.node(o-1).canReplaceWith(t.index(),t.index()+1,i)&&c.setNodeMarkup(c.mapping.map(n.before(o)),i)}return t&&t(c.scrollIntoView()),!0};function xo(e,t,n,r){let o,i,a=t.nodeBefore,l=t.nodeAfter,s=a.type.spec.isolating||l.type.spec.isolating;if(!s&&function(e,t,n){let r=t.nodeBefore,o=t.nodeAfter,i=t.index();return!(!(r&&o&&r.type.compatibleContent(o.type))||(!r.content.size&&t.parent.canReplace(i-1,i)?(n&&n(e.tr.delete(t.pos-r.nodeSize,t.pos).scrollIntoView()),0):!t.parent.canReplace(i,i+1)||!o.isTextblock&&!wr(e.doc,t.pos)||(n&&n(e.tr.join(t.pos).scrollIntoView()),0)))}(e,t,n))return!0;let c=!s&&t.parent.canReplace(t.index(),t.index()+1);if(c&&(o=(i=a.contentMatchAt(a.childCount)).findWrapping(l.type))&&i.matchType(o[0]||l.type).validEnd){if(n){let r=t.pos+l.nodeSize,i=Ht.empty;for(let e=o.length-1;e>=0;e--)i=Ht.from(o[e].create(null,i));i=Ht.from(a.copy(i));let s=e.tr.step(new dr(t.pos-1,r,t.pos,r,new Zt(i,1,0),o.length,!0)),c=s.doc.resolve(r+2*o.length);c.nodeAfter&&c.nodeAfter.type==a.type&&wr(s.doc,c.pos)&&s.join(c.pos),n(s.scrollIntoView())}return!0}let d=l.type.spec.isolating||r>0&&s?null:Rr.findFrom(t,1),u=d&&d.$from.blockRange(d.$to),p=u&&mr(u);if(null!=p&&p>=t.depth)return n&&n(e.tr.lift(u,p).scrollIntoView()),!0;if(c&&co(l,"start",!0)&&co(a,"end")){let r=a,o=[];for(;o.push(r),!r.isTextblock;)r=r.lastChild;let i=l,s=1;for(;!i.isTextblock;i=i.firstChild)s++;if(r.canReplace(r.childCount,r.childCount,i.content)){if(n){let r=Ht.empty;for(let e=o.length-1;e>=0;e--)r=Ht.from(o[e].copy(r));n(e.tr.step(new dr(t.pos-o.length,t.pos+l.nodeSize,t.pos+s,t.pos+l.nodeSize-s,new Zt(r,o.length,0),0,!0)).scrollIntoView())}return!0}}return!1}function _o(e){return function(t,n){let r=t.selection,o=e<0?r.$from:r.$to,i=o.depth;for(;o.node(i).isInline;){if(!i)return!1;i--}return!!o.node(i).isTextblock&&(n&&n(t.tr.setSelection(Ur.create(t.doc,e<0?o.start(i):o.end(i)))),!0)}}const Co=_o(-1),Eo=_o(1);function So(e,t=null){return function(n,r){let o=!1;for(let i=0;i<n.selection.ranges.length&&!o;i++){let{$from:{pos:r},$to:{pos:a}}=n.selection.ranges[i];n.doc.nodesBetween(r,a,(r,i)=>{if(o)return!1;if(r.isTextblock&&!r.hasMarkup(e,t))if(r.type==e)o=!0;else{let t=n.doc.resolve(i),r=t.index();o=t.parent.canReplaceWith(r,r+1,e)}})}if(!o)return!1;if(r){let o=n.tr;for(let r=0;r<n.selection.ranges.length;r++){let{$from:{pos:i},$to:{pos:a}}=n.selection.ranges[r];o.setBlockType(i,a,e,t)}r(o.scrollIntoView())}return!0}}function Bo(...e){return function(t,n,r){for(let o=0;o<e.length;o++)if(e[o](t,n,r))return!0;return!1}}function No(e,t=null){return function(n,r){let{$from:o,$to:i}=n.selection,a=o.blockRange(i);if(!a)return!1;let l=r?n.tr:null;return!!function(e,t,n,r=null){let o=!1,i=t,a=t.$from.doc;if(t.depth>=2&&t.$from.node(t.depth-1).type.compatibleContent(n)&&0==t.startIndex){if(0==t.$from.index(t.depth-1))return!1;let e=a.resolve(t.start-2);i=new dn(e,e,t.depth),t.endIndex<t.parent.childCount&&(t=new dn(t.$from,a.resolve(t.$to.end(t.depth)),t.depth)),o=!0}let l=fr(i,n,r,t);if(!l)return!1;e&&function(e,t,n,r,o){let i=Ht.empty;for(let d=n.length-1;d>=0;d--)i=Ht.from(n[d].type.create(n[d].attrs,i));e.step(new dr(t.start-(r?2:0),t.end,t.start,t.end,new Zt(i,0,0),n.length,!0));let a=0;for(let d=0;d<n.length;d++)n[d].type==o&&(a=d+1);let l=n.length-a,s=t.start+n.length-(r?2:0),c=t.parent;for(let d=t.startIndex,u=t.endIndex,p=!0;d<u;d++,p=!1)!p&&br(e.doc,s,l)&&(e.split(s,l),s+=2*l),s+=c.child(d).nodeSize}(e,t,l,o,n);return!0}(l,a,e,t)&&(r&&r(l.scrollIntoView()),!0)}}function Mo(e){return function(t,n){let{$from:r,$to:o}=t.selection,i=r.blockRange(o,t=>t.childCount>0&&t.firstChild.type==e);return!!i&&(!n||(r.node(i.depth-1).type==e?function(e,t,n,r){let o=e.tr,i=r.end,a=r.$to.end(r.depth);i<a&&(o.step(new dr(i-1,a,i,a,new Zt(Ht.from(n.create(null,r.parent.copy())),1,0),1,!0)),r=new dn(o.doc.resolve(r.$from.pos),o.doc.resolve(a),r.depth));const l=mr(r);if(null==l)return!1;o.lift(r,l);let s=o.doc.resolve(o.mapping.map(i,-1)-1);wr(o.doc,s.pos)&&s.nodeBefore.type==s.nodeAfter.type&&o.join(s.pos);return t(o.scrollIntoView()),!0}(t,n,e,i):function(e,t,n){let r=e.tr,o=n.parent;for(let h=n.end,m=n.endIndex-1,f=n.startIndex;m>f;m--)h-=o.child(m).nodeSize,r.delete(h-1,h+1);let i=r.doc.resolve(n.start),a=i.nodeAfter;if(r.mapping.map(n.end)!=n.start+i.nodeAfter.nodeSize)return!1;let l=0==n.startIndex,s=n.endIndex==o.childCount,c=i.node(-1),d=i.index(-1);if(!c.canReplace(d+(l?0:1),d+1,a.content.append(s?Ht.empty:Ht.from(o))))return!1;let u=i.pos,p=u+a.nodeSize;return r.step(new dr(u-(l?1:0),p+(s?1:0),u+1,p-1,new Zt((l?Ht.empty:Ht.from(o.copy(Ht.empty))).append(s?Ht.empty:Ht.from(o.copy(Ht.empty))),l?0:1,s?0:1),l?0:1)),t(r.scrollIntoView()),!0}(t,n,i)))}}Bo(io,lo,uo),Bo(io,mo,fo),Bo(vo,bo,wo,ko),"undefined"!=typeof navigator?/Mac|iP(hone|[oa]d)/.test(navigator.platform):"undefined"!=typeof os&&os.platform&&os.platform();const To=function(e){for(var t=0;;t++)if(!(e=e.previousSibling))return t},Vo=function(e,t,n,r){return n&&(zo(e,t,n,r,-1)||zo(e,t,n,r,1))},Ao=/^(img|br|input|textarea|hr)$/i;function zo(e,t,n,r,o){for(var i;;){if(e==n&&t==r)return!0;if(t==(o<0?0:Oo(e))){let n=e.parentNode;if(!n||1!=n.nodeType||Io(e)||Ao.test(e.nodeName)||"false"==e.contentEditable)return!1;t=To(e)+(o<0?0:1),e=n}else{if(1!=e.nodeType)return!1;{let n=e.childNodes[t+(o<0?-1:0)];if(1==n.nodeType&&"false"==n.contentEditable){if(!(null===(i=n.pmViewDesc)||void 0===i?void 0:i.ignoreForSelection))return!1;t+=o}else e=n,t=o<0?Oo(e):0}}}}function Oo(e){return 3==e.nodeType?e.nodeValue.length:e.childNodes.length}function Io(e){let t;for(let n=e;n&&!(t=n.pmViewDesc);n=n.parentNode);return t&&t.node&&t.node.isBlock&&(t.dom==e||t.contentDOM==e)}const Do=function(e){return e.focusNode&&Vo(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)};function Po(e,t){let n=document.createEvent("Event");return n.initEvent("keydown",!0,!0),n.keyCode=e,n.key=n.code=t,n}const $o="undefined"!=typeof navigator?navigator:null,Lo="undefined"!=typeof document?document:null,Ro=$o&&$o.userAgent||"",Ho=/Edge\/(\d+)/.exec(Ro),Fo=/MSIE \d/.exec(Ro),jo=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(Ro),Uo=!!(Fo||jo||Ho),Go=Fo?document.documentMode:jo?+jo[1]:Ho?+Ho[1]:0,qo=!Uo&&/gecko\/(\d+)/i.test(Ro);qo&&(/Firefox\/(\d+)/.exec(Ro)||[0,0])[1];const Zo=!Uo&&/Chrome\/(\d+)/.exec(Ro),Wo=!!Zo,Ko=Zo?+Zo[1]:0,Jo=!Uo&&!!$o&&/Apple Computer/.test($o.vendor),Yo=Jo&&(/Mobile\/\w+/.test(Ro)||!!$o&&$o.maxTouchPoints>2),Xo=Yo||!!$o&&/Mac/.test($o.platform),Qo=!!$o&&/Win/.test($o.platform),ei=/Android \d/.test(Ro),ti=!!Lo&&"webkitFontSmoothing"in Lo.documentElement.style,ni=ti?+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]:0;function ri(e,t=null){let n=e.domSelectionRange(),r=e.state.doc;if(!n.focusNode)return null;let o=e.docView.nearestDesc(n.focusNode),i=o&&0==o.size,a=e.docView.posFromDOM(n.focusNode,n.focusOffset,1);if(a<0)return null;let l,s,c=r.resolve(a);if(Do(n)){for(l=a;o&&!o.node;)o=o.parent;let e=o.node;if(o&&e.isAtom&&qr.isSelectable(e)&&o.parent&&(!e.isInline||!function(e,t,n){for(let r=0==t,o=t==Oo(e);r||o;){if(e==n)return!0;let t=To(e);if(!(e=e.parentNode))return!1;r=r&&0==t,o=o&&t==Oo(e)}}(n.focusNode,n.focusOffset,o.dom))){let e=o.posBefore;s=new qr(a==e?c:r.resolve(e))}}else{if(n instanceof e.dom.ownerDocument.defaultView.Selection&&n.rangeCount>1){let t=a,o=a;for(let r=0;r<n.rangeCount;r++){let i=n.getRangeAt(r);t=Math.min(t,e.docView.posFromDOM(i.startContainer,i.startOffset,1)),o=Math.max(o,e.docView.posFromDOM(i.endContainer,i.endOffset,-1))}if(t<0)return null;[l,a]=o==e.state.selection.anchor?[o,t]:[t,o],c=r.resolve(a)}else l=e.docView.posFromDOM(n.anchorNode,n.anchorOffset,1);if(l<0)return null}let d=r.resolve(l);if(!s){s=ui(e,d,c,"pointer"==t||e.state.selection.head<c.pos&&!i?1:-1)}return s}function oi(e){return e.editable?e.hasFocus():function(e){let t=e.domSelectionRange();if(!t.anchorNode)return!1;try{return e.dom.contains(3==t.anchorNode.nodeType?t.anchorNode.parentNode:t.anchorNode)&&(e.editable||e.dom.contains(3==t.focusNode.nodeType?t.focusNode.parentNode:t.focusNode))}catch(pR){return!1}}(e)&&document.activeElement&&document.activeElement.contains(e.dom)}function ii(e,t=!1){let n=e.state.selection;if(function(e,t){if(t instanceof qr){let n=e.docView.descAt(t.from);n!=e.lastSelectedViewDesc&&(di(e),n&&n.selectNode(),e.lastSelectedViewDesc=n)}else di(e)}(e,n),oi(e)){if(!t&&e.input.mouseDown&&e.input.mouseDown.allowDefault&&Wo){let t=e.domSelectionRange(),n=e.domObserver.currentSelection;if(t.anchorNode&&n.anchorNode&&Vo(t.anchorNode,t.anchorOffset,n.anchorNode,n.anchorOffset))return e.input.mouseDown.delayedSelectionSync=!0,void e.domObserver.setCurSelection()}if(e.domObserver.disconnectSelection(),e.cursorWrapper)!function(e){let t=e.domSelection();if(!t)return;let n=e.cursorWrapper.dom,r="IMG"==n.nodeName;r?t.collapse(n.parentNode,To(n)+1):t.collapse(n,0);!r&&!e.state.selection.visible&&Uo&&Go<=11&&(n.disabled=!0,n.disabled=!1)}(e);else{let r,o,{anchor:i,head:a}=n;!ai||n instanceof Ur||(n.$from.parent.inlineContent||(r=li(e,n.from)),n.empty||n.$from.parent.inlineContent||(o=li(e,n.to))),e.docView.setSelection(i,a,e,t),ai&&(r&&ci(r),o&&ci(o)),n.visible?e.dom.classList.remove("ProseMirror-hideselection"):(e.dom.classList.add("ProseMirror-hideselection"),"onselectionchange"in document&&function(e){let t=e.dom.ownerDocument;t.removeEventListener("selectionchange",e.input.hideSelectionGuard);let n=e.domSelectionRange(),r=n.anchorNode,o=n.anchorOffset;t.addEventListener("selectionchange",e.input.hideSelectionGuard=()=>{n.anchorNode==r&&n.anchorOffset==o||(t.removeEventListener("selectionchange",e.input.hideSelectionGuard),setTimeout(()=>{oi(e)&&!e.state.selection.visible||e.dom.classList.remove("ProseMirror-hideselection")},20))})}(e))}e.domObserver.setCurSelection(),e.domObserver.connectSelection()}}const ai=Jo||Wo&&Ko<63;function li(e,t){let{node:n,offset:r}=e.docView.domFromPos(t,0),o=r<n.childNodes.length?n.childNodes[r]:null,i=r?n.childNodes[r-1]:null;if(Jo&&o&&"false"==o.contentEditable)return si(o);if(!(o&&"false"!=o.contentEditable||i&&"false"!=i.contentEditable)){if(o)return si(o);if(i)return si(i)}}function si(e){return e.contentEditable="true",Jo&&e.draggable&&(e.draggable=!1,e.wasDraggable=!0),e}function ci(e){e.contentEditable="false",e.wasDraggable&&(e.draggable=!0,e.wasDraggable=null)}function di(e){e.lastSelectedViewDesc&&(e.lastSelectedViewDesc.parent&&e.lastSelectedViewDesc.deselectNode(),e.lastSelectedViewDesc=void 0)}function ui(e,t,n,r){return e.someProp("createSelectionBetween",r=>r(e,t,n))||Ur.between(t,n,r)}function pi(e,t){let{$anchor:n,$head:r}=e.selection,o=t>0?n.max(r):n.min(r),i=o.parent.inlineContent?o.depth?e.doc.resolve(t>0?o.after():o.before()):null:o;return i&&Rr.findFrom(i,t)}function hi(e,t){return e.dispatch(e.state.tr.setSelection(t).scrollIntoView()),!0}function mi(e,t,n){let r=e.state.selection;if(!(r instanceof Ur)){if(r instanceof qr&&r.node.isInline)return hi(e,new Ur(t>0?r.$to:r.$from));{let n=pi(e.state,t);return!!n&&hi(e,n)}}if(n.indexOf("s")>-1){let{$head:n}=r,o=n.textOffset?null:t<0?n.nodeBefore:n.nodeAfter;if(!o||o.isText||!o.isLeaf)return!1;let i=e.state.doc.resolve(n.pos+o.nodeSize*(t<0?-1:1));return hi(e,new Ur(r.$anchor,i))}if(!r.empty)return!1;if(e.endOfTextblock(t>0?"forward":"backward")){let n=pi(e.state,t);return!!(n&&n instanceof qr)&&hi(e,n)}if(!(Xo&&n.indexOf("m")>-1)){let n,o=r.$head,i=o.textOffset?null:t<0?o.nodeBefore:o.nodeAfter;if(!i||i.isText)return!1;let a=t<0?o.pos-i.nodeSize:o.pos;return!!(i.isAtom||(n=e.docView.descAt(a))&&!n.contentDOM)&&(qr.isSelectable(i)?hi(e,new qr(t<0?e.state.doc.resolve(o.pos-i.nodeSize):o)):!!ti&&hi(e,new Ur(e.state.doc.resolve(t<0?a:a+i.nodeSize))))}}function fi(e){return 3==e.nodeType?e.nodeValue.length:e.childNodes.length}function gi(e,t){let n=e.pmViewDesc;return n&&0==n.size&&(t<0||e.nextSibling||"BR"!=e.nodeName)}function vi(e,t){return t<0?function(e){let t=e.domSelectionRange(),n=t.focusNode,r=t.focusOffset;if(!n)return;let o,i,a=!1;qo&&1==n.nodeType&&r<fi(n)&&gi(n.childNodes[r],-1)&&(a=!0);for(;;)if(r>0){if(1!=n.nodeType)break;{let e=n.childNodes[r-1];if(gi(e,-1))o=n,i=--r;else{if(3!=e.nodeType)break;n=e,r=n.nodeValue.length}}}else{if(yi(n))break;{let t=n.previousSibling;for(;t&&gi(t,-1);)o=n.parentNode,i=To(t),t=t.previousSibling;if(t)n=t,r=fi(n);else{if(n=n.parentNode,n==e.dom)break;r=0}}}a?bi(e,n,r):o&&bi(e,o,i)}(e):function(e){let t=e.domSelectionRange(),n=t.focusNode,r=t.focusOffset;if(!n)return;let o,i,a=fi(n);for(;;)if(r<a){if(1!=n.nodeType)break;if(!gi(n.childNodes[r],1))break;o=n,i=++r}else{if(yi(n))break;{let t=n.nextSibling;for(;t&&gi(t,1);)o=t.parentNode,i=To(t)+1,t=t.nextSibling;if(t)n=t,r=0,a=fi(n);else{if(n=n.parentNode,n==e.dom)break;r=a=0}}}o&&bi(e,o,i)}(e)}function yi(e){let t=e.pmViewDesc;return t&&t.node&&t.node.isBlock}function bi(e,t,n){if(3!=t.nodeType){let e,r;(r=function(e,t){for(;e&&t==e.childNodes.length&&!Io(e);)t=To(e)+1,e=e.parentNode;for(;e&&t<e.childNodes.length;){let n=e.childNodes[t];if(3==n.nodeType)return n;if(1==n.nodeType&&"false"==n.contentEditable)break;e=n,t=0}}(t,n))?(t=r,n=0):(e=function(e,t){for(;e&&!t&&!Io(e);)t=To(e),e=e.parentNode;for(;e&&t;){let n=e.childNodes[t-1];if(3==n.nodeType)return n;if(1==n.nodeType&&"false"==n.contentEditable)break;t=(e=n).childNodes.length}}(t,n))&&(t=e,n=e.nodeValue.length)}let r=e.domSelection();if(!r)return;if(Do(r)){let e=document.createRange();e.setEnd(t,n),e.setStart(t,n),r.removeAllRanges(),r.addRange(e)}else r.extend&&r.extend(t,n);e.domObserver.setCurSelection();let{state:o}=e;setTimeout(()=>{e.state==o&&ii(e)},50)}function wi(e,t){let n=e.state.doc.resolve(t);if(!Wo&&!Qo&&n.parent.inlineContent){let r=e.coordsAtPos(t);if(t>n.start()){let n=e.coordsAtPos(t-1),o=(n.top+n.bottom)/2;if(o>r.top&&o<r.bottom&&Math.abs(n.left-r.left)>1)return n.left<r.left?"ltr":"rtl"}if(t<n.end()){let n=e.coordsAtPos(t+1),o=(n.top+n.bottom)/2;if(o>r.top&&o<r.bottom&&Math.abs(n.left-r.left)>1)return n.left>r.left?"ltr":"rtl"}}return"rtl"==getComputedStyle(e.dom).direction?"rtl":"ltr"}function ki(e,t,n){let r=e.state.selection;if(r instanceof Ur&&!r.empty||n.indexOf("s")>-1)return!1;if(Xo&&n.indexOf("m")>-1)return!1;let{$from:o,$to:i}=r;if(!o.parent.inlineContent||e.endOfTextblock(t<0?"up":"down")){let n=pi(e.state,t);if(n&&n instanceof qr)return hi(e,n)}if(!o.parent.inlineContent){let n=t<0?o:i,a=r instanceof Wr?Rr.near(n,t):Rr.findFrom(n,t);return!!a&&hi(e,a)}return!1}function xi(e,t){if(!(e.state.selection instanceof Ur))return!0;let{$head:n,$anchor:r,empty:o}=e.state.selection;if(!n.sameParent(r))return!0;if(!o)return!1;if(e.endOfTextblock(t>0?"forward":"backward"))return!0;let i=!n.textOffset&&(t<0?n.nodeBefore:n.nodeAfter);if(i&&!i.isText){let r=e.state.tr;return t<0?r.delete(n.pos-i.nodeSize,n.pos):r.delete(n.pos,n.pos+i.nodeSize),e.dispatch(r),!0}return!1}function _i(e,t,n){e.domObserver.stop(),t.contentEditable=n,e.domObserver.start()}function Ci(e,t){let n=t.keyCode,r=function(e){let t="";return e.ctrlKey&&(t+="c"),e.metaKey&&(t+="m"),e.altKey&&(t+="a"),e.shiftKey&&(t+="s"),t}(t);if(8==n||Xo&&72==n&&"c"==r)return xi(e,-1)||vi(e,-1);if(46==n&&!t.shiftKey||Xo&&68==n&&"c"==r)return xi(e,1)||vi(e,1);if(13==n||27==n)return!0;if(37==n||Xo&&66==n&&"c"==r){let t=37==n?"ltr"==wi(e,e.state.selection.from)?-1:1:-1;return mi(e,t,r)||vi(e,t)}if(39==n||Xo&&70==n&&"c"==r){let t=39==n?"ltr"==wi(e,e.state.selection.from)?1:-1:1;return mi(e,t,r)||vi(e,t)}return 38==n||Xo&&80==n&&"c"==r?ki(e,-1,r)||vi(e,-1):40==n||Xo&&78==n&&"c"==r?function(e){if(!Jo||e.state.selection.$head.parentOffset>0)return!1;let{focusNode:t,focusOffset:n}=e.domSelectionRange();if(t&&1==t.nodeType&&0==n&&t.firstChild&&"false"==t.firstChild.contentEditable){let n=t.firstChild;_i(e,n,"true"),setTimeout(()=>_i(e,n,"false"),20)}return!1}(e)||ki(e,1,r)||vi(e,1):r==(Xo?"m":"c")&&(66==n||73==n||89==n||90==n)}function Ei(e,t){e.someProp("transformCopied",n=>{t=n(t,e)});let n=[],{content:r,openStart:o,openEnd:i}=t;for(;o>1&&i>1&&1==r.childCount&&1==r.firstChild.childCount;){o--,i--;let e=r.firstChild;n.push(e.type.name,e.attrs!=e.type.defaultAttrs?e.attrs:null),r=e.content}let a=e.someProp("clipboardSerializer")||jn.fromSchema(e.state.schema),l=Ii(),s=l.createElement("div");s.appendChild(a.serializeFragment(r,{document:l}));let c,d=s.firstChild,u=0;for(;d&&1==d.nodeType&&(c=zi[d.nodeName.toLowerCase()]);){for(let e=c.length-1;e>=0;e--){let t=l.createElement(c[e]);for(;s.firstChild;)t.appendChild(s.firstChild);s.appendChild(t),u++}d=s.firstChild}return d&&1==d.nodeType&&d.setAttribute("data-pm-slice",`${o} ${i}${u?` -${u}`:""} ${JSON.stringify(n)}`),{dom:s,text:e.someProp("clipboardTextSerializer",n=>n(t,e))||t.content.textBetween(0,t.content.size,"\n\n"),slice:t}}function Si(e,t,n,r,o){let i,a,l=o.parent.type.spec.code;if(!n&&!t)return null;let s=!!t&&(r||l||!n);if(s){if(e.someProp("transformPastedText",n=>{t=n(t,l||r,e)}),l)return a=new Zt(Ht.from(e.state.schema.text(t.replace(/\r\n?/g,"\n"))),0,0),e.someProp("transformPasted",t=>{a=t(a,e,!0)}),a;let n=e.someProp("clipboardTextParser",n=>n(t,o,r,e));if(n)a=n;else{let n=o.marks(),{schema:r}=e.state,a=jn.fromSchema(r);i=document.createElement("div"),t.split(/(?:\r\n?|\n)+/).forEach(e=>{let t=i.appendChild(document.createElement("p"));e&&t.appendChild(a.serializeNode(r.text(e,n)))})}}else e.someProp("transformPastedHTML",t=>{n=t(n,e)}),i=function(e){let t=/^(\s*<meta [^>]*>)*/.exec(e);t&&(e=e.slice(t[0].length));let n,r=Ii().createElement("div"),o=/<([a-z][^>\s]+)/i.exec(e);(n=o&&zi[o[1].toLowerCase()])&&(e=n.map(e=>"<"+e+">").join("")+e+n.map(e=>"</"+e+">").reverse().join(""));if(r.innerHTML=function(e){let t=window.trustedTypes;if(!t)return e;Di||(Di=t.defaultPolicy||t.createPolicy("ProseMirrorClipboard",{createHTML:e=>e}));return Di.createHTML(e)}(e),n)for(let i=0;i<n.length;i++)r=r.querySelector(n[i])||r;return r}(n),ti&&function(e){let t=e.querySelectorAll(Wo?"span:not([class]):not([style])":"span.Apple-converted-space");for(let n=0;n<t.length;n++){let r=t[n];1==r.childNodes.length&&" "==r.textContent&&r.parentNode&&r.parentNode.replaceChild(e.ownerDocument.createTextNode(" "),r)}}(i);let c=i&&i.querySelector("[data-pm-slice]"),d=c&&/^(\d+) (\d+)(?: -(\d+))? (.*)/.exec(c.getAttribute("data-pm-slice")||"");if(d&&d[3])for(let u=+d[3];u>0;u--){let e=i.firstChild;for(;e&&1!=e.nodeType;)e=e.nextSibling;if(!e)break;i=e}if(!a){let t=e.someProp("clipboardParser")||e.someProp("domParser")||zn.fromSchema(e.state.schema);a=t.parseSlice(i,{preserveWhitespace:!(!s&&!d),context:o,ruleFromNode:e=>"BR"!=e.nodeName||e.nextSibling||!e.parentNode||Bi.test(e.parentNode.nodeName)?null:{ignore:!0}})}if(d)a=function(e,t){if(!e.size)return e;let n,r=e.content.firstChild.type.schema;try{n=JSON.parse(t)}catch(l){return e}let{content:o,openStart:i,openEnd:a}=e;for(let s=n.length-2;s>=0;s-=2){let e=r.nodes[n[s]];if(!e||e.hasRequiredAttrs())break;o=Ht.from(e.create(n[s+1],o)),i++,a++}return new Zt(o,i,a)}(Ai(a,+d[1],+d[2]),d[4]);else if(a=Zt.maxOpen(function(e,t){if(e.childCount<2)return e;for(let n=t.depth;n>=0;n--){let r,o=t.node(n).contentMatchAt(t.index(n)),i=[];if(e.forEach(e=>{if(!i)return;let t,n=o.findWrapping(e.type);if(!n)return i=null;if(t=i.length&&r.length&&Mi(n,r,e,i[i.length-1],0))i[i.length-1]=t;else{i.length&&(i[i.length-1]=Ti(i[i.length-1],r.length));let t=Ni(e,n);i.push(t),o=o.matchType(t.type),r=n}}),i)return Ht.from(i)}return e}(a.content,o),!0),a.openStart||a.openEnd){let e=0,t=0;for(let n=a.content.firstChild;e<a.openStart&&!n.type.spec.isolating;e++,n=n.firstChild);for(let n=a.content.lastChild;t<a.openEnd&&!n.type.spec.isolating;t++,n=n.lastChild);a=Ai(a,e,t)}return e.someProp("transformPasted",t=>{a=t(a,e,s)}),a}const Bi=/^(a|abbr|acronym|b|cite|code|del|em|i|ins|kbd|label|output|q|ruby|s|samp|span|strong|sub|sup|time|u|tt|var)$/i;function Ni(e,t,n=0){for(let r=t.length-1;r>=n;r--)e=t[r].create(null,Ht.from(e));return e}function Mi(e,t,n,r,o){if(o<e.length&&o<t.length&&e[o]==t[o]){let i=Mi(e,t,n,r.lastChild,o+1);if(i)return r.copy(r.content.replaceChild(r.childCount-1,i));if(r.contentMatchAt(r.childCount).matchType(o==e.length-1?n.type:e[o+1]))return r.copy(r.content.append(Ht.from(Ni(n,e,o+1))))}}function Ti(e,t){if(0==t)return e;let n=e.content.replaceChild(e.childCount-1,Ti(e.lastChild,t-1)),r=e.contentMatchAt(e.childCount).fillBefore(Ht.empty,!0);return e.copy(n.append(r))}function Vi(e,t,n,r,o,i){let a=t<0?e.firstChild:e.lastChild,l=a.content;return e.childCount>1&&(i=0),o<r-1&&(l=Vi(l,t,n,r,o+1,i)),o>=n&&(l=t<0?a.contentMatchAt(0).fillBefore(l,i<=o).append(l):l.append(a.contentMatchAt(a.childCount).fillBefore(Ht.empty,!0))),e.replaceChild(t<0?0:e.childCount-1,a.copy(l))}function Ai(e,t,n){return t<e.openStart&&(e=new Zt(Vi(e.content,-1,t,e.openStart,0,e.openEnd),t,e.openEnd)),n<e.openEnd&&(e=new Zt(Vi(e.content,1,n,e.openEnd,0,0),e.openStart,n)),e}const zi={thead:["table"],tbody:["table"],tfoot:["table"],caption:["table"],colgroup:["table"],col:["table","colgroup"],tr:["table","tbody"],td:["table","tbody","tr"],th:["table","tbody","tr"]};let Oi=null;function Ii(){return Oi||(Oi=document.implementation.createHTMLDocument("title"))}let Di=null;const Pi={},$i={};function Li(e,t){e.input.lastSelectionOrigin=t,e.input.lastSelectionTime=Date.now()}function Ri(e){return{left:e.clientX,top:e.clientY}}function Hi(e,t,n,r,o){if(-1==r)return!1;let i=e.state.doc.resolve(r);for(let a=i.depth+1;a>0;a--)if(e.someProp(t,t=>a>i.depth?t(e,n,i.nodeAfter,i.before(a),o,!0):t(e,n,i.node(a),i.before(a),o,!1)))return!0;return!1}function Fi(e,t,n){if(e.focused||e.focus(),e.state.selection.eq(t))return;let r=e.state.tr.setSelection(t);r.setMeta("pointer",!0),e.dispatch(r)}function ji(e,t,n,r,o){return Hi(e,"handleClickOn",t,n,r)||e.someProp("handleClick",n=>n(e,t,r))||(o?function(e,t){if(-1==t)return!1;let n,r,o=e.state.selection;o instanceof qr&&(n=o.node);let i=e.state.doc.resolve(t);for(let a=i.depth+1;a>0;a--){let e=a>i.depth?i.nodeAfter:i.node(a);if(qr.isSelectable(e)){r=n&&o.$from.depth>0&&a>=o.$from.depth&&i.before(o.$from.depth+1)==o.$from.pos?i.before(o.$from.depth):i.before(a);break}}return null!=r&&(Fi(e,qr.create(e.state.doc,r)),!0)}(e,n):function(e,t){if(-1==t)return!1;let n=e.state.doc.resolve(t),r=n.nodeAfter;return!!(r&&r.isAtom&&qr.isSelectable(r))&&(Fi(e,new qr(n)),!0)}(e,n))}function Ui(e,t,n,r){return Hi(e,"handleDoubleClickOn",t,n,r)||e.someProp("handleDoubleClick",n=>n(e,t,r))}function Gi(e,t,n,r){return Hi(e,"handleTripleClickOn",t,n,r)||e.someProp("handleTripleClick",n=>n(e,t,r))||function(e,t,n){if(0!=n.button)return!1;let r=e.state.doc;if(-1==t)return!!r.inlineContent&&(Fi(e,Ur.create(r,0,r.content.size)),!0);let o=r.resolve(t);for(let i=o.depth+1;i>0;i--){let t=i>o.depth?o.nodeAfter:o.node(i),n=o.before(i);if(t.inlineContent)Fi(e,Ur.create(r,n+1,n+1+t.content.size));else{if(!qr.isSelectable(t))continue;Fi(e,qr.create(r,n))}return!0}}(e,n,r)}function qi(e){return Qi(e)}$i.keydown=(e,t)=>{let n=t;if(e.input.shiftKey=16==n.keyCode||n.shiftKey,!Ki(e,n)&&(e.input.lastKeyCode=n.keyCode,e.input.lastKeyCodeTime=Date.now(),!ei||!Wo||13!=n.keyCode))if(229!=n.keyCode&&e.domObserver.forceFlush(),!Yo||13!=n.keyCode||n.ctrlKey||n.altKey||n.metaKey)e.someProp("handleKeyDown",t=>t(e,n))||Ci(e,n)?n.preventDefault():Li(e,"key");else{let t=Date.now();e.input.lastIOSEnter=t,e.input.lastIOSEnterFallbackTimeout=setTimeout(()=>{e.input.lastIOSEnter==t&&(e.someProp("handleKeyDown",t=>t(e,Po(13,"Enter"))),e.input.lastIOSEnter=0)},200)}},$i.keyup=(e,t)=>{16==t.keyCode&&(e.input.shiftKey=!1)},$i.keypress=(e,t)=>{let n=t;if(Ki(e,n)||!n.charCode||n.ctrlKey&&!n.altKey||Xo&&n.metaKey)return;if(e.someProp("handleKeyPress",t=>t(e,n)))return void n.preventDefault();let r=e.state.selection;if(!(r instanceof Ur&&r.$from.sameParent(r.$to))){let t=String.fromCharCode(n.charCode),o=()=>e.state.tr.insertText(t).scrollIntoView();/[\r\n]/.test(t)||e.someProp("handleTextInput",n=>n(e,r.$from.pos,r.$to.pos,t,o))||e.dispatch(o()),n.preventDefault()}};const Zi=Xo?"metaKey":"ctrlKey";Pi.mousedown=(e,t)=>{let n=t;e.input.shiftKey=n.shiftKey;let r=qi(e),o=Date.now(),i="singleClick";o-e.input.lastClick.time<500&&function(e,t){let n=t.x-e.clientX,r=t.y-e.clientY;return n*n+r*r<100}(n,e.input.lastClick)&&!n[Zi]&&e.input.lastClick.button==n.button&&("singleClick"==e.input.lastClick.type?i="doubleClick":"doubleClick"==e.input.lastClick.type&&(i="tripleClick")),e.input.lastClick={time:o,x:n.clientX,y:n.clientY,type:i,button:n.button};let a=e.posAtCoords(Ri(n));a&&("singleClick"==i?(e.input.mouseDown&&e.input.mouseDown.done(),e.input.mouseDown=new Wi(e,a,n,!!r)):("doubleClick"==i?Ui:Gi)(e,a.pos,a.inside,n)?n.preventDefault():Li(e,"pointer"))};class Wi{constructor(e,t,n,r){let o,i;if(this.view=e,this.pos=t,this.event=n,this.flushed=r,this.delayedSelectionSync=!1,this.mightDrag=null,this.startDoc=e.state.doc,this.selectNode=!!n[Zi],this.allowDefault=n.shiftKey,t.inside>-1)o=e.state.doc.nodeAt(t.inside),i=t.inside;else{let n=e.state.doc.resolve(t.pos);o=n.parent,i=n.depth?n.before():0}const a=r?null:n.target,l=a?e.docView.nearestDesc(a,!0):null;this.target=l&&1==l.nodeDOM.nodeType?l.nodeDOM:null;let{selection:s}=e.state;(0==n.button&&o.type.spec.draggable&&!1!==o.type.spec.selectable||s instanceof qr&&s.from<=i&&s.to>i)&&(this.mightDrag={node:o,pos:i,addAttr:!(!this.target||this.target.draggable),setUneditable:!(!this.target||!qo||this.target.hasAttribute("contentEditable"))}),this.target&&this.mightDrag&&(this.mightDrag.addAttr||this.mightDrag.setUneditable)&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&(this.target.draggable=!0),this.mightDrag.setUneditable&&setTimeout(()=>{this.view.input.mouseDown==this&&this.target.setAttribute("contentEditable","false")},20),this.view.domObserver.start()),e.root.addEventListener("mouseup",this.up=this.up.bind(this)),e.root.addEventListener("mousemove",this.move=this.move.bind(this)),Li(e,"pointer")}done(){this.view.root.removeEventListener("mouseup",this.up),this.view.root.removeEventListener("mousemove",this.move),this.mightDrag&&this.target&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&this.target.removeAttribute("draggable"),this.mightDrag.setUneditable&&this.target.removeAttribute("contentEditable"),this.view.domObserver.start()),this.delayedSelectionSync&&setTimeout(()=>ii(this.view)),this.view.input.mouseDown=null}up(e){if(this.done(),!this.view.dom.contains(e.target))return;let t=this.pos;this.view.state.doc!=this.startDoc&&(t=this.view.posAtCoords(Ri(e))),this.updateAllowDefault(e),this.allowDefault||!t?Li(this.view,"pointer"):ji(this.view,t.pos,t.inside,e,this.selectNode)?e.preventDefault():0==e.button&&(this.flushed||Jo&&this.mightDrag&&!this.mightDrag.node.isAtom||Wo&&!this.view.state.selection.visible&&Math.min(Math.abs(t.pos-this.view.state.selection.from),Math.abs(t.pos-this.view.state.selection.to))<=2)?(Fi(this.view,Rr.near(this.view.state.doc.resolve(t.pos))),e.preventDefault()):Li(this.view,"pointer")}move(e){this.updateAllowDefault(e),Li(this.view,"pointer"),0==e.buttons&&this.done()}updateAllowDefault(e){!this.allowDefault&&(Math.abs(this.event.x-e.clientX)>4||Math.abs(this.event.y-e.clientY)>4)&&(this.allowDefault=!0)}}function Ki(e,t){return!!e.composing||!!(Jo&&Math.abs(t.timeStamp-e.input.compositionEndedAt)<500)&&(e.input.compositionEndedAt=-2e8,!0)}Pi.touchstart=e=>{e.input.lastTouch=Date.now(),qi(e),Li(e,"pointer")},Pi.touchmove=e=>{e.input.lastTouch=Date.now(),Li(e,"pointer")},Pi.contextmenu=e=>qi(e);const Ji=ei?5e3:-1;function Yi(e,t){clearTimeout(e.input.composingTimeout),t>-1&&(e.input.composingTimeout=setTimeout(()=>Qi(e),t))}function Xi(e){for(e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=function(){let e=document.createEvent("Event");return e.initEvent("event",!0,!0),e.timeStamp}());e.input.compositionNodes.length>0;)e.input.compositionNodes.pop().markParentsDirty()}function Qi(e,t=!1){if(!(ei&&e.domObserver.flushingSoon>=0)){if(e.domObserver.forceFlush(),Xi(e),t||e.docView&&e.docView.dirty){let n=ri(e),r=e.state.selection;return n&&!n.eq(r)?e.dispatch(e.state.tr.setSelection(n)):!e.markCursor&&!t||r.$from.node(r.$from.sharedDepth(r.to)).inlineContent?e.updateState(e.state):e.dispatch(e.state.tr.deleteSelection()),!0}return!1}}$i.compositionstart=$i.compositionupdate=e=>{if(!e.composing){e.domObserver.flush();let{state:t}=e,n=t.selection.$to;if(t.selection instanceof Ur&&(t.storedMarks||!n.textOffset&&n.parentOffset&&n.nodeBefore.marks.some(e=>!1===e.type.spec.inclusive)||Wo&&Qo&&function(e){let{focusNode:t,focusOffset:n}=e.domSelectionRange();if(!t||1!=t.nodeType||n>=t.childNodes.length)return!1;let r=t.childNodes[n];return 1==r.nodeType&&"false"==r.contentEditable}(e)))e.markCursor=e.state.storedMarks||n.marks(),Qi(e,!0),e.markCursor=null;else if(Qi(e,!t.selection.empty),qo&&t.selection.empty&&n.parentOffset&&!n.textOffset&&n.nodeBefore.marks.length){let t=e.domSelectionRange();for(let n=t.focusNode,r=t.focusOffset;n&&1==n.nodeType&&0!=r;){let t=r<0?n.lastChild:n.childNodes[r-1];if(!t)break;if(3==t.nodeType){let n=e.domSelection();n&&n.collapse(t,t.nodeValue.length);break}n=t,r=-1}}e.input.composing=!0}Yi(e,Ji)},$i.compositionend=(e,t)=>{e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=t.timeStamp,e.input.compositionPendingChanges=e.domObserver.pendingRecords().length?e.input.compositionID:0,e.input.compositionNode=null,e.input.badSafariComposition?e.domObserver.forceFlush():e.input.compositionPendingChanges&&Promise.resolve().then(()=>e.domObserver.flush()),e.input.compositionID++,Yi(e,20))};const ea=Uo&&Go<15||Yo&&ni<604;function ta(e,t,n,r,o){let i=Si(e,t,n,r,e.state.selection.$from);if(e.someProp("handlePaste",t=>t(e,o,i||Zt.empty)))return!0;if(!i)return!1;let a=function(e){return 0==e.openStart&&0==e.openEnd&&1==e.content.childCount?e.content.firstChild:null}(i),l=a?e.state.tr.replaceSelectionWith(a,r):e.state.tr.replaceSelection(i);return e.dispatch(l.scrollIntoView().setMeta("paste",!0).setMeta("uiEvent","paste")),!0}function na(e){let t=e.getData("text/plain")||e.getData("Text");if(t)return t;let n=e.getData("text/uri-list");return n?n.replace(/\r?\n/g," "):""}Pi.copy=$i.cut=(e,t)=>{let n=t,r=e.state.selection,o="cut"==n.type;if(r.empty)return;let i=ea?null:n.clipboardData,a=r.content(),{dom:l,text:s}=Ei(e,a);i?(n.preventDefault(),i.clearData(),i.setData("text/html",l.innerHTML),i.setData("text/plain",s)):function(e,t){if(!e.dom.parentNode)return;let n=e.dom.parentNode.appendChild(document.createElement("div"));n.appendChild(t),n.style.cssText="position: fixed; left: -10000px; top: 10px";let r=getSelection(),o=document.createRange();o.selectNodeContents(t),e.dom.blur(),r.removeAllRanges(),r.addRange(o),setTimeout(()=>{n.parentNode&&n.parentNode.removeChild(n),e.focus()},50)}(e,l),o&&e.dispatch(e.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent","cut"))},$i.paste=(e,t)=>{let n=t;if(e.composing&&!ei)return;let r=ea?null:n.clipboardData,o=e.input.shiftKey&&45!=e.input.lastKeyCode;r&&ta(e,na(r),r.getData("text/html"),o,n)?n.preventDefault():function(e,t){if(!e.dom.parentNode)return;let n=e.input.shiftKey||e.state.selection.$from.parent.type.spec.code,r=e.dom.parentNode.appendChild(document.createElement(n?"textarea":"div"));n||(r.contentEditable="true"),r.style.cssText="position: fixed; left: -10000px; top: 10px",r.focus();let o=e.input.shiftKey&&45!=e.input.lastKeyCode;setTimeout(()=>{e.focus(),r.parentNode&&r.parentNode.removeChild(r),n?ta(e,r.value,null,o,t):ta(e,r.textContent,r.innerHTML,o,t)},50)}(e,n)};class ra{constructor(e,t,n){this.slice=e,this.move=t,this.node=n}}const oa=Xo?"altKey":"ctrlKey";function ia(e,t){let n=e.someProp("dragCopies",e=>!e(t));return null!=n?n:!t[oa]}Pi.dragstart=(e,t)=>{let n=t,r=e.input.mouseDown;if(r&&r.done(),!n.dataTransfer)return;let o,i=e.state.selection,a=i.empty?null:e.posAtCoords(Ri(n));if(a&&a.pos>=i.from&&a.pos<=(i instanceof qr?i.to-1:i.to));else if(r&&r.mightDrag)o=qr.create(e.state.doc,r.mightDrag.pos);else if(n.target&&1==n.target.nodeType){let t=e.docView.nearestDesc(n.target,!0);t&&t.node.type.spec.draggable&&t!=e.docView&&(o=qr.create(e.state.doc,t.posBefore))}let l=(o||e.state.selection).content(),{dom:s,text:c,slice:d}=Ei(e,l);(!n.dataTransfer.files.length||!Wo||Ko>120)&&n.dataTransfer.clearData(),n.dataTransfer.setData(ea?"Text":"text/html",s.innerHTML),n.dataTransfer.effectAllowed="copyMove",ea||n.dataTransfer.setData("text/plain",c),e.dragging=new ra(d,ia(e,n),o)},Pi.dragend=e=>{let t=e.dragging;window.setTimeout(()=>{e.dragging==t&&(e.dragging=null)},50)},$i.dragover=$i.dragenter=(e,t)=>t.preventDefault(),$i.drop=(e,t)=>{try{!function(e,t,n){if(!t.dataTransfer)return;let r=e.posAtCoords(Ri(t));if(!r)return;let o=e.state.doc.resolve(r.pos),i=n&&n.slice;i?e.someProp("transformPasted",t=>{i=t(i,e,!1)}):i=Si(e,na(t.dataTransfer),ea?null:t.dataTransfer.getData("text/html"),!1,o);let a=!(!n||!ia(e,t));if(e.someProp("handleDrop",n=>n(e,t,i||Zt.empty,a)))return void t.preventDefault();if(!i)return;t.preventDefault();let l=i?_r(e.state.doc,o.pos,i):o.pos;null==l&&(l=o.pos);let s=e.state.tr;if(a){let{node:e}=n;e?e.replace(s):s.deleteSelection()}let c=s.mapping.map(l),d=0==i.openStart&&0==i.openEnd&&1==i.content.childCount,u=s.doc;d?s.replaceRangeWith(c,c,i.content.firstChild):s.replaceRange(c,c,i);if(s.doc.eq(u))return;let p=s.doc.resolve(c);if(d&&qr.isSelectable(i.content.firstChild)&&p.nodeAfter&&p.nodeAfter.sameMarkup(i.content.firstChild))s.setSelection(new qr(p));else{let t=s.mapping.map(l);s.mapping.maps[s.mapping.maps.length-1].forEach((e,n,r,o)=>t=o),s.setSelection(ui(e,p,s.doc.resolve(t)))}e.focus(),e.dispatch(s.setMeta("uiEvent","drop"))}(e,t,e.dragging)}finally{e.dragging=null}},Pi.focus=e=>{e.input.lastFocus=Date.now(),e.focused||(e.domObserver.stop(),e.dom.classList.add("ProseMirror-focused"),e.domObserver.start(),e.focused=!0,setTimeout(()=>{e.docView&&e.hasFocus()&&!e.domObserver.currentSelection.eq(e.domSelectionRange())&&ii(e)},20))},Pi.blur=(e,t)=>{let n=t;e.focused&&(e.domObserver.stop(),e.dom.classList.remove("ProseMirror-focused"),e.domObserver.start(),n.relatedTarget&&e.dom.contains(n.relatedTarget)&&e.domObserver.currentSelection.clear(),e.focused=!1)},Pi.beforeinput=(e,t)=>{if(Wo&&ei&&"deleteContentBackward"==t.inputType){e.domObserver.flushSoon();let{domChangeCount:t}=e.input;setTimeout(()=>{if(e.input.domChangeCount!=t)return;if(e.dom.blur(),e.focus(),e.someProp("handleKeyDown",t=>t(e,Po(8,"Backspace"))))return;let{$cursor:n}=e.state.selection;n&&n.pos>0&&e.dispatch(e.state.tr.delete(n.pos-1,n.pos).scrollIntoView())},50)}};for(let os in $i)Pi[os]=$i[os];function aa(e,t){if(e==t)return!0;for(let n in e)if(e[n]!==t[n])return!1;for(let n in t)if(!(n in e))return!1;return!0}class la{constructor(e,t){this.toDOM=e,this.spec=t||pa,this.side=this.spec.side||0}map(e,t,n,r){let{pos:o,deleted:i}=e.mapResult(t.from+r,this.side<0?-1:1);return i?null:new da(o-n,o-n,this)}valid(){return!0}eq(e){return this==e||e instanceof la&&(this.spec.key&&this.spec.key==e.spec.key||this.toDOM==e.toDOM&&aa(this.spec,e.spec))}destroy(e){this.spec.destroy&&this.spec.destroy(e)}}class sa{constructor(e,t){this.attrs=e,this.spec=t||pa}map(e,t,n,r){let o=e.map(t.from+r,this.spec.inclusiveStart?-1:1)-n,i=e.map(t.to+r,this.spec.inclusiveEnd?1:-1)-n;return o>=i?null:new da(o,i,this)}valid(e,t){return t.from<t.to}eq(e){return this==e||e instanceof sa&&aa(this.attrs,e.attrs)&&aa(this.spec,e.spec)}static is(e){return e.type instanceof sa}destroy(){}}class ca{constructor(e,t){this.attrs=e,this.spec=t||pa}map(e,t,n,r){let o=e.mapResult(t.from+r,1);if(o.deleted)return null;let i=e.mapResult(t.to+r,-1);return i.deleted||i.pos<=o.pos?null:new da(o.pos-n,i.pos-n,this)}valid(e,t){let n,{index:r,offset:o}=e.content.findIndex(t.from);return o==t.from&&!(n=e.child(r)).isText&&o+n.nodeSize==t.to}eq(e){return this==e||e instanceof ca&&aa(this.attrs,e.attrs)&&aa(this.spec,e.spec)}destroy(){}}class da{constructor(e,t,n){this.from=e,this.to=t,this.type=n}copy(e,t){return new da(e,t,this.type)}eq(e,t=0){return this.type.eq(e.type)&&this.from+t==e.from&&this.to+t==e.to}map(e,t,n){return this.type.map(e,this,t,n)}static widget(e,t,n){return new da(e,e,new la(t,n))}static inline(e,t,n,r){return new da(e,t,new sa(n,r))}static node(e,t,n,r){return new da(e,t,new ca(n,r))}get spec(){return this.type.spec}get inline(){return this.type instanceof sa}get widget(){return this.type instanceof la}}const ua=[],pa={};class ha{constructor(e,t){this.local=e.length?e:ua,this.children=t.length?t:ua}static create(e,t){return t.length?ba(t,e,0,pa):ma}find(e,t,n){let r=[];return this.findInner(null==e?0:e,null==t?1e9:t,r,0,n),r}findInner(e,t,n,r,o){for(let i=0;i<this.local.length;i++){let a=this.local[i];a.from<=t&&a.to>=e&&(!o||o(a.spec))&&n.push(a.copy(a.from+r,a.to+r))}for(let i=0;i<this.children.length;i+=3)if(this.children[i]<t&&this.children[i+1]>e){let a=this.children[i]+1;this.children[i+2].findInner(e-a,t-a,n,r+a,o)}}map(e,t,n){return this==ma||0==e.maps.length?this:this.mapInner(e,t,0,0,n||pa)}mapInner(e,t,n,r,o){let i;for(let a=0;a<this.local.length;a++){let l=this.local[a].map(e,n,r);l&&l.type.valid(t,l)?(i||(i=[])).push(l):o.onRemove&&o.onRemove(this.local[a].spec)}return this.children.length?function(e,t,n,r,o,i,a){let l=e.slice();for(let c=0,d=i;c<n.maps.length;c++){let e=0;n.maps[c].forEach((t,n,r,o)=>{let i=o-r-(n-t);for(let a=0;a<l.length;a+=3){let r=l[a+1];if(r<0||t>r+d-e)continue;let o=l[a]+d-e;n>=o?l[a+1]=t<=o?-2:-1:t>=d&&i&&(l[a]+=i,l[a+1]+=i)}e+=i}),d=n.maps[c].map(d,-1)}let s=!1;for(let c=0;c<l.length;c+=3)if(l[c+1]<0){if(-2==l[c+1]){s=!0,l[c+1]=-1;continue}let t=n.map(e[c]+i),d=t-o;if(d<0||d>=r.content.size){s=!0;continue}let u=n.map(e[c+1]+i,-1)-o,{index:p,offset:h}=r.content.findIndex(d),m=r.maybeChild(p);if(m&&h==d&&h+m.nodeSize==u){let r=l[c+2].mapInner(n,m,t+1,e[c]+i+1,a);r!=ma?(l[c]=d,l[c+1]=u,l[c+2]=r):(l[c+1]=-2,s=!0)}else s=!0}if(s){let s=function(e,t,n,r,o,i,a){function l(e,t){for(let i=0;i<e.local.length;i++){let l=e.local[i].map(r,o,t);l?n.push(l):a.onRemove&&a.onRemove(e.local[i].spec)}for(let n=0;n<e.children.length;n+=3)l(e.children[n+2],e.children[n]+t+1)}for(let s=0;s<e.length;s+=3)-1==e[s+1]&&l(e[s+2],t[s]+i+1);return n}(l,e,t,n,o,i,a),c=ba(s,r,0,a);t=c.local;for(let e=0;e<l.length;e+=3)l[e+1]<0&&(l.splice(e,3),e-=3);for(let e=0,t=0;e<c.children.length;e+=3){let n=c.children[e];for(;t<l.length&&l[t]<n;)t+=3;l.splice(t,0,c.children[e],c.children[e+1],c.children[e+2])}}return new ha(t.sort(wa),l)}(this.children,i||[],e,t,n,r,o):i?new ha(i.sort(wa),ua):ma}add(e,t){return t.length?this==ma?ha.create(e,t):this.addInner(e,t,0):this}addInner(e,t,n){let r,o=0;e.forEach((e,i)=>{let a,l=i+n;if(a=va(t,e,l)){for(r||(r=this.children.slice());o<r.length&&r[o]<i;)o+=3;r[o]==i?r[o+2]=r[o+2].addInner(e,a,l+1):r.splice(o,0,i,i+e.nodeSize,ba(a,e,l+1,pa)),o+=3}});let i=ga(o?ya(t):t,-n);for(let a=0;a<i.length;a++)i[a].type.valid(e,i[a])||i.splice(a--,1);return new ha(i.length?this.local.concat(i).sort(wa):this.local,r||this.children)}remove(e){return 0==e.length||this==ma?this:this.removeInner(e,0)}removeInner(e,t){let n=this.children,r=this.local;for(let o=0;o<n.length;o+=3){let r,i=n[o]+t,a=n[o+1]+t;for(let t,n=0;n<e.length;n++)(t=e[n])&&t.from>i&&t.to<a&&(e[n]=null,(r||(r=[])).push(t));if(!r)continue;n==this.children&&(n=this.children.slice());let l=n[o+2].removeInner(r,i+1);l!=ma?n[o+2]=l:(n.splice(o,3),o-=3)}if(r.length)for(let o,i=0;i<e.length;i++)if(o=e[i])for(let e=0;e<r.length;e++)r[e].eq(o,t)&&(r==this.local&&(r=this.local.slice()),r.splice(e--,1));return n==this.children&&r==this.local?this:r.length||n.length?new ha(r,n):ma}forChild(e,t){if(this==ma)return this;if(t.isLeaf)return ha.empty;let n,r;for(let a=0;a<this.children.length;a+=3)if(this.children[a]>=e){this.children[a]==e&&(n=this.children[a+2]);break}let o=e+1,i=o+t.content.size;for(let a=0;a<this.local.length;a++){let e=this.local[a];if(e.from<i&&e.to>o&&e.type instanceof sa){let t=Math.max(o,e.from)-o,n=Math.min(i,e.to)-o;t<n&&(r||(r=[])).push(e.copy(t,n))}}if(r){let e=new ha(r.sort(wa),ua);return n?new fa([e,n]):e}return n||ma}eq(e){if(this==e)return!0;if(!(e instanceof ha)||this.local.length!=e.local.length||this.children.length!=e.children.length)return!1;for(let t=0;t<this.local.length;t++)if(!this.local[t].eq(e.local[t]))return!1;for(let t=0;t<this.children.length;t+=3)if(this.children[t]!=e.children[t]||this.children[t+1]!=e.children[t+1]||!this.children[t+2].eq(e.children[t+2]))return!1;return!0}locals(e){return ka(this.localsInner(e))}localsInner(e){if(this==ma)return ua;if(e.inlineContent||!this.local.some(sa.is))return this.local;let t=[];for(let n=0;n<this.local.length;n++)this.local[n].type instanceof sa||t.push(this.local[n]);return t}forEachSet(e){e(this)}}ha.empty=new ha([],[]),ha.removeOverlap=ka;const ma=ha.empty;class fa{constructor(e){this.members=e}map(e,t){const n=this.members.map(n=>n.map(e,t,pa));return fa.from(n)}forChild(e,t){if(t.isLeaf)return ha.empty;let n=[];for(let r=0;r<this.members.length;r++){let o=this.members[r].forChild(e,t);o!=ma&&(o instanceof fa?n=n.concat(o.members):n.push(o))}return fa.from(n)}eq(e){if(!(e instanceof fa)||e.members.length!=this.members.length)return!1;for(let t=0;t<this.members.length;t++)if(!this.members[t].eq(e.members[t]))return!1;return!0}locals(e){let t,n=!0;for(let r=0;r<this.members.length;r++){let o=this.members[r].localsInner(e);if(o.length)if(t){n&&(t=t.slice(),n=!1);for(let e=0;e<o.length;e++)t.push(o[e])}else t=o}return t?ka(n?t:t.sort(wa)):ua}static from(e){switch(e.length){case 0:return ma;case 1:return e[0];default:return new fa(e.every(e=>e instanceof ha)?e:e.reduce((e,t)=>e.concat(t instanceof ha?t:t.members),[]))}}forEachSet(e){for(let t=0;t<this.members.length;t++)this.members[t].forEachSet(e)}}function ga(e,t){if(!t||!e.length)return e;let n=[];for(let r=0;r<e.length;r++){let o=e[r];n.push(new da(o.from+t,o.to+t,o.type))}return n}function va(e,t,n){if(t.isLeaf)return null;let r=n+t.nodeSize,o=null;for(let i,a=0;a<e.length;a++)(i=e[a])&&i.from>n&&i.to<r&&((o||(o=[])).push(i),e[a]=null);return o}function ya(e){let t=[];for(let n=0;n<e.length;n++)null!=e[n]&&t.push(e[n]);return t}function ba(e,t,n,r){let o=[],i=!1;t.forEach((t,a)=>{let l=va(e,t,a+n);if(l){i=!0;let e=ba(l,t,n+a+1,r);e!=ma&&o.push(a,a+t.nodeSize,e)}});let a=ga(i?ya(e):e,-n).sort(wa);for(let l=0;l<a.length;l++)a[l].type.valid(t,a[l])||(r.onRemove&&r.onRemove(a[l].spec),a.splice(l--,1));return a.length||o.length?new ha(a,o):ma}function wa(e,t){return e.from-t.from||e.to-t.to}function ka(e){let t=e;for(let n=0;n<t.length-1;n++){let r=t[n];if(r.from!=r.to)for(let o=n+1;o<t.length;o++){let i=t[o];if(i.from!=r.from){i.from<r.to&&(t==e&&(t=e.slice()),t[n]=r.copy(r.from,i.from),xa(t,o,r.copy(i.from,r.to)));break}i.to!=r.to&&(t==e&&(t=e.slice()),t[o]=i.copy(i.from,r.to),xa(t,o+1,i.copy(r.to,i.to)))}}return t}function xa(e,t,n){for(;t<e.length&&wa(n,e[t])>0;)t++;e.splice(t,0,n)}for(var _a={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},Ca={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},Ea="undefined"!=typeof navigator&&/Mac/.test(navigator.platform),Sa="undefined"!=typeof navigator&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent),Ba=0;Ba<10;Ba++)_a[48+Ba]=_a[96+Ba]=String(Ba);for(Ba=1;Ba<=24;Ba++)_a[Ba+111]="F"+Ba;for(Ba=65;Ba<=90;Ba++)_a[Ba]=String.fromCharCode(Ba+32),Ca[Ba]=String.fromCharCode(Ba);for(var Na in _a)Ca.hasOwnProperty(Na)||(Ca[Na]=_a[Na]);const Ma="undefined"!=typeof navigator&&/Mac|iP(hone|[oa]d)/.test(navigator.platform),Ta="undefined"!=typeof navigator&&/Win/.test(navigator.platform);function Va(e){let t,n,r,o,i=e.split(/-(?!$)/),a=i[i.length-1];"Space"==a&&(a=" ");for(let l=0;l<i.length-1;l++){let e=i[l];if(/^(cmd|meta|m)$/i.test(e))o=!0;else if(/^a(lt)?$/i.test(e))t=!0;else if(/^(c|ctrl|control)$/i.test(e))n=!0;else if(/^s(hift)?$/i.test(e))r=!0;else{if(!/^mod$/i.test(e))throw new Error("Unrecognized modifier name: "+e);Ma?o=!0:n=!0}}return t&&(a="Alt-"+a),n&&(a="Ctrl-"+a),o&&(a="Meta-"+a),r&&(a="Shift-"+a),a}function Aa(e,t,n=!0){return t.altKey&&(e="Alt-"+e),t.ctrlKey&&(e="Ctrl-"+e),t.metaKey&&(e="Meta-"+e),n&&t.shiftKey&&(e="Shift-"+e),e}var za=Object.defineProperty,Oa=(e,t)=>{for(var n in t)za(e,n,{get:t[n],enumerable:!0})};function Ia(e){const{state:t,transaction:n}=e;let{selection:r}=n,{doc:o}=n,{storedMarks:i}=n;return{...t,apply:t.apply.bind(t),applyTransaction:t.applyTransaction.bind(t),plugins:t.plugins,schema:t.schema,reconfigure:t.reconfigure.bind(t),toJSON:t.toJSON.bind(t),get storedMarks(){return i},get selection(){return r},get doc(){return o},get tr(){return r=n.selection,o=n.doc,i=n.storedMarks,n}}}var Da=class{constructor(e){this.editor=e.editor,this.rawCommands=this.editor.extensionManager.commands,this.customState=e.state}get hasCustomState(){return!!this.customState}get state(){return this.customState||this.editor.state}get commands(){const{rawCommands:e,editor:t,state:n}=this,{view:r}=t,{tr:o}=n,i=this.buildProps(o);return Object.fromEntries(Object.entries(e).map(([e,t])=>[e,(...e)=>{const n=t(...e)(i);return o.getMeta("preventDispatch")||this.hasCustomState||r.dispatch(o),n}]))}get chain(){return()=>this.createChain()}get can(){return()=>this.createCan()}createChain(e,t=!0){const{rawCommands:n,editor:r,state:o}=this,{view:i}=r,a=[],l=!!e,s=e||o.tr,c={...Object.fromEntries(Object.entries(n).map(([e,n])=>[e,(...e)=>{const r=this.buildProps(s,t),o=n(...e)(r);return a.push(o),c}])),run:()=>(l||!t||s.getMeta("preventDispatch")||this.hasCustomState||i.dispatch(s),a.every(e=>!0===e))};return c}createCan(e){const{rawCommands:t,state:n}=this,r=!1,o=e||n.tr,i=this.buildProps(o,r);return{...Object.fromEntries(Object.entries(t).map(([e,t])=>[e,(...e)=>t(...e)({...i,dispatch:void 0})])),chain:()=>this.createChain(o,r)}}buildProps(e,t=!0){const{rawCommands:n,editor:r,state:o}=this,{view:i}=r,a={tr:e,editor:r,view:i,state:Ia({state:o,transaction:e}),dispatch:t?()=>{}:void 0,chain:()=>this.createChain(e,t),can:()=>this.createCan(e),get commands(){return Object.fromEntries(Object.entries(n).map(([e,t])=>[e,(...e)=>t(...e)(a)]))}};return a}},Pa={};Oa(Pa,{blur:()=>$a,clearContent:()=>La,clearNodes:()=>Ra,command:()=>Ha,createParagraphNear:()=>Fa,cut:()=>ja,deleteCurrentNode:()=>Ua,deleteNode:()=>qa,deleteRange:()=>Za,deleteSelection:()=>Wa,enter:()=>Ka,exitCode:()=>Ja,extendMarkRange:()=>nl,first:()=>rl,focus:()=>sl,forEach:()=>cl,insertContent:()=>dl,insertContentAt:()=>ml,joinBackward:()=>vl,joinDown:()=>gl,joinForward:()=>yl,joinItemBackward:()=>bl,joinItemForward:()=>wl,joinTextblockBackward:()=>kl,joinTextblockForward:()=>xl,joinUp:()=>fl,keyboardShortcut:()=>Cl,lift:()=>Sl,liftEmptyBlock:()=>Bl,liftListItem:()=>Nl,newlineInCode:()=>Ml,resetAttributes:()=>Al,scrollIntoView:()=>zl,selectAll:()=>Ol,selectNodeBackward:()=>Il,selectNodeForward:()=>Dl,selectParentNode:()=>Pl,selectTextblockEnd:()=>$l,selectTextblockStart:()=>Ll,setContent:()=>Rl,setMark:()=>is,setMeta:()=>as,setNode:()=>ls,setNodeSelection:()=>ss,setTextDirection:()=>cs,setTextSelection:()=>ds,sinkListItem:()=>us,splitBlock:()=>hs,splitListItem:()=>ms,toggleList:()=>vs,toggleMark:()=>ys,toggleNode:()=>bs,toggleWrap:()=>ws,undoInputRule:()=>ks,unsetAllMarks:()=>xs,unsetMark:()=>_s,unsetTextDirection:()=>Cs,updateAttributes:()=>Es,wrapIn:()=>Ss,wrapInList:()=>Bs});var $a=()=>({editor:e,view:t})=>(requestAnimationFrame(()=>{var n;e.isDestroyed||(t.dom.blur(),null==(n=null==window?void 0:window.getSelection())||n.removeAllRanges())}),!0),La=(e=!0)=>({commands:t})=>t.setContent("",{emitUpdate:e}),Ra=()=>({state:e,tr:t,dispatch:n})=>{const{selection:r}=t,{ranges:o}=r;return!n||(o.forEach(({$from:n,$to:r})=>{e.doc.nodesBetween(n.pos,r.pos,(e,n)=>{if(e.type.isText)return;const{doc:r,mapping:o}=t,i=r.resolve(o.map(n)),a=r.resolve(o.map(n+e.nodeSize)),l=i.blockRange(a);if(!l)return;const s=mr(l);if(e.type.isTextblock){const{defaultType:e}=i.parent.contentMatchAt(i.index());t.setNodeMarkup(l.start,e)}(s||0===s)&&t.lift(l,s)})}),!0)},Ha=e=>t=>e(t),Fa=()=>({state:e,dispatch:t})=>bo(e,t),ja=(e,t)=>({editor:n,tr:r})=>{const{state:o}=n,i=o.doc.slice(e.from,e.to);r.deleteRange(e.from,e.to);const a=r.mapping.map(t);return r.insert(a,i.content),r.setSelection(new Ur(r.doc.resolve(Math.max(a-1,0)))),!0},Ua=()=>({tr:e,dispatch:t})=>{const{selection:n}=e,r=n.$anchor.node();if(r.content.size>0)return!1;const o=e.selection.$anchor;for(let i=o.depth;i>0;i-=1){if(o.node(i).type===r.type){if(t){const t=o.before(i),n=o.after(i);e.delete(t,n).scrollIntoView()}return!0}}return!1};function Ga(e,t){if("string"==typeof e){if(!t.nodes[e])throw Error(`There is no node type named '${e}'. Maybe you forgot to add the extension?`);return t.nodes[e]}return e}var qa=e=>({tr:t,state:n,dispatch:r})=>{const o=Ga(e,n.schema),i=t.selection.$anchor;for(let e=i.depth;e>0;e-=1){if(i.node(e).type===o){if(r){const n=i.before(e),r=i.after(e);t.delete(n,r).scrollIntoView()}return!0}}return!1},Za=e=>({tr:t,dispatch:n})=>{const{from:r,to:o}=e;return n&&t.delete(r,o),!0},Wa=()=>({state:e,dispatch:t})=>io(e,t),Ka=()=>({commands:e})=>e.keyboardShortcut("Enter"),Ja=()=>({state:e,dispatch:t})=>((e,t)=>{let{$head:n,$anchor:r}=e.selection;if(!n.parent.type.spec.code||!n.sameParent(r))return!1;let o=n.node(-1),i=n.indexAfter(-1),a=yo(o.contentMatchAt(i));if(!a||!o.canReplaceWith(i,i,a))return!1;if(t){let r=n.after(),o=e.tr.replaceWith(r,r,a.createAndFill());o.setSelection(Rr.near(o.doc.resolve(r),1)),t(o.scrollIntoView())}return!0})(e,t);function Ya(e,t,n={strict:!0}){const r=Object.keys(t);return!r.length||r.every(r=>{return n.strict?t[r]===e[r]:(o=t[r],"[object RegExp]"===Object.prototype.toString.call(o)?t[r].test(e[r]):t[r]===e[r]);var o})}function Xa(e,t,n={}){return e.find(e=>e.type===t&&Ya(Object.fromEntries(Object.keys(n).map(t=>[t,e.attrs[t]])),n))}function Qa(e,t,n={}){return!!Xa(e,t,n)}function el(e,t,n){var r;if(!e||!t)return;let o=e.parent.childAfter(e.parentOffset);if(o.node&&o.node.marks.some(e=>e.type===t)||(o=e.parent.childBefore(e.parentOffset)),!o.node||!o.node.marks.some(e=>e.type===t))return;n=n||(null==(r=o.node.marks[0])?void 0:r.attrs);if(!Xa([...o.node.marks],t,n))return;let i=o.index,a=e.start()+o.offset,l=i+1,s=a+o.node.nodeSize;for(;i>0&&Qa([...e.parent.child(i-1).marks],t,n);)i-=1,a-=e.parent.child(i).nodeSize;for(;l<e.parent.childCount&&Qa([...e.parent.child(l).marks],t,n);)s+=e.parent.child(l).nodeSize,l+=1;return{from:a,to:s}}function tl(e,t){if("string"==typeof e){if(!t.marks[e])throw Error(`There is no mark type named '${e}'. Maybe you forgot to add the extension?`);return t.marks[e]}return e}var nl=(e,t={})=>({tr:n,state:r,dispatch:o})=>{const i=tl(e,r.schema),{doc:a,selection:l}=n,{$from:s,from:c,to:d}=l;if(o){const e=el(s,i,t);if(e&&e.from<=c&&e.to>=d){const t=Ur.create(a,e.from,e.to);n.setSelection(t)}}return!0},rl=e=>t=>{const n="function"==typeof e?e(t):e;for(let e=0;e<n.length;e+=1)if(n[e](t))return!0;return!1};function ol(e){return e instanceof Ur}function il(e=0,t=0,n=0){return Math.min(Math.max(e,t),n)}function al(){return"Android"===navigator.platform||/android/i.test(navigator.userAgent)}function ll(){return["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in document}var sl=(e=null,t={})=>({editor:n,view:r,tr:o,dispatch:i})=>{t={scrollIntoView:!0,...t};const a=()=>{(ll()||al())&&r.dom.focus(),"undefined"==typeof navigator||!/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||ll()||al()||r.dom.focus({preventScroll:!0}),requestAnimationFrame(()=>{n.isDestroyed||(r.focus(),(null==t?void 0:t.scrollIntoView)&&n.commands.scrollIntoView())})};try{if(r.hasFocus()&&null===e||!1===e)return!0}catch{return!1}if(i&&null===e&&!ol(n.state.selection))return a(),!0;const l=function(e,t=null){if(!t)return null;const n=Rr.atStart(e),r=Rr.atEnd(e);if("start"===t||!0===t)return n;if("end"===t)return r;const o=n.from,i=r.to;return"all"===t?Ur.create(e,il(0,o,i),il(e.content.size,o,i)):Ur.create(e,il(t,o,i),il(t,o,i))}(o.doc,e)||n.state.selection,s=n.state.selection.eq(l);return i&&(s||o.setSelection(l),s&&o.storedMarks&&o.setStoredMarks(o.storedMarks),a()),!0},cl=(e,t)=>n=>e.every((e,r)=>t(e,{...n,index:r})),dl=(e,t)=>({tr:n,commands:r})=>r.insertContentAt({from:n.selection.from,to:n.selection.to},e,t),ul=e=>{const t=e.childNodes;for(let n=t.length-1;n>=0;n-=1){const r=t[n];3===r.nodeType&&r.nodeValue&&/^(\n\s\s|\n)$/.test(r.nodeValue)?e.removeChild(r):1===r.nodeType&&ul(r)}return e};function pl(e){if("undefined"==typeof window)throw new Error("[tiptap error]: there is no window object available, so this function cannot be used");const t=`<body>${e}</body>`,n=(new window.DOMParser).parseFromString(t,"text/html").body;return ul(n)}function hl(e,t,n){if(e instanceof pn||e instanceof Ht)return e;n={slice:!0,parseOptions:{},...n};const r="string"==typeof e;if("object"==typeof e&&null!==e)try{if(Array.isArray(e)&&e.length>0)return Ht.fromArray(e.map(e=>t.nodeFromJSON(e)));const r=t.nodeFromJSON(e);return n.errorOnInvalidContent&&r.check(),r}catch(o){if(n.errorOnInvalidContent)throw new Error("[tiptap error]: Invalid JSON content",{cause:o});return hl("",t,n)}if(r){if(n.errorOnInvalidContent){let r=!1,o="";const i=new Vn({topNode:t.spec.topNode,marks:t.spec.marks,nodes:t.spec.nodes.append({__tiptap__private__unknown__catch__all__node:{content:"inline*",group:"block",parseDOM:[{tag:"*",getAttrs:e=>(r=!0,o="string"==typeof e?e:e.outerHTML,null)}]}})});if(n.slice?zn.fromSchema(i).parseSlice(pl(e),n.parseOptions):zn.fromSchema(i).parse(pl(e),n.parseOptions),n.errorOnInvalidContent&&r)throw new Error("[tiptap error]: Invalid HTML content",{cause:new Error(`Invalid element found: ${o}`)})}const r=zn.fromSchema(t);return n.slice?r.parseSlice(pl(e),n.parseOptions).content:r.parse(pl(e),n.parseOptions)}return hl("",t,n)}var ml=(e,t,n)=>({tr:r,dispatch:o,editor:i})=>{var a;if(o){let o;const s=e=>{i.emit("contentError",{editor:i,error:e,disableCollaboration:()=>{"collaboration"in i.storage&&"object"==typeof i.storage.collaboration&&i.storage.collaboration&&(i.storage.collaboration.isDisabled=!0)}})},c={preserveWhitespace:"full",...(n={parseOptions:i.options.parseOptions,updateSelection:!0,applyInputRules:!1,applyPasteRules:!1,...n}).parseOptions};if(!n.errorOnInvalidContent&&!i.options.enableContentCheck&&i.options.emitContentError)try{hl(t,i.schema,{parseOptions:c,errorOnInvalidContent:!0})}catch(l){s(l)}try{o=hl(t,i.schema,{parseOptions:c,errorOnInvalidContent:null!=(a=n.errorOnInvalidContent)?a:i.options.enableContentCheck})}catch(l){return s(l),!1}let{from:d,to:u}="number"==typeof e?{from:e,to:e}:{from:e.from,to:e.to},p=!0,h=!0;if(("type"in o?[o]:o).forEach(e=>{e.check(),p=!!p&&(e.isText&&0===e.marks.length),h=!!h&&e.isBlock}),d===u&&h){const{parent:e}=r.doc.resolve(d);e.isTextblock&&!e.type.spec.code&&!e.childCount&&(d-=1,u+=1)}let m;if(p){if(Array.isArray(t))m=t.map(e=>e.text||"").join("");else if(t instanceof Ht){let e="";t.forEach(t=>{t.text&&(e+=t.text)}),m=e}else m="object"==typeof t&&t&&t.text?t.text:t;r.insertText(m,d,u)}else{m=o;const e=r.doc.resolve(d),t=e.node(),n=0===e.parentOffset,i=t.isText||t.isTextblock,a=t.content.size>0;n&&i&&a&&(d=Math.max(0,d-1)),r.replaceWith(d,u,m)}n.updateSelection&&function(e,t,n){const r=e.steps.length-1;if(r<t)return;const o=e.steps[r];if(!(o instanceof cr||o instanceof dr))return;const i=e.mapping.maps[r];let a=0;i.forEach((e,t,n,r)=>{0===a&&(a=r)}),e.setSelection(Rr.near(e.doc.resolve(a),n))}(r,r.steps.length-1,-1),n.applyInputRules&&r.setMeta("applyInputRules",{from:d,text:m}),n.applyPasteRules&&r.setMeta("applyPasteRules",{from:d,text:m})}return!0},fl=()=>({state:e,dispatch:t})=>((e,t)=>{let n,r=e.selection,o=r instanceof qr;if(o){if(r.node.isTextblock||!wr(e.doc,r.from))return!1;n=r.from}else if(n=xr(e.doc,r.from,-1),null==n)return!1;if(t){let r=e.tr.join(n);o&&r.setSelection(qr.create(r.doc,n-e.doc.resolve(n).nodeBefore.nodeSize)),t(r.scrollIntoView())}return!0})(e,t),gl=()=>({state:e,dispatch:t})=>((e,t)=>{let n,r=e.selection;if(r instanceof qr){if(r.node.isTextblock||!wr(e.doc,r.to))return!1;n=r.to}else if(n=xr(e.doc,r.to,1),null==n)return!1;return t&&t(e.tr.join(n).scrollIntoView()),!0})(e,t),vl=()=>({state:e,dispatch:t})=>lo(e,t),yl=()=>({state:e,dispatch:t})=>mo(e,t),bl=()=>({state:e,dispatch:t,tr:n})=>{try{const r=xr(e.doc,e.selection.$from.pos,-1);return null!=r&&(n.join(r,2),t&&t(n),!0)}catch{return!1}},wl=()=>({state:e,dispatch:t,tr:n})=>{try{const r=xr(e.doc,e.selection.$from.pos,1);return null!=r&&(n.join(r,2),t&&t(n),!0)}catch{return!1}},kl=()=>({state:e,dispatch:t})=>((e,t,n)=>{let r=ao(e,n);if(!r)return!1;let o=po(r);return!!o&&so(e,o,t)})(e,t),xl=()=>({state:e,dispatch:t})=>((e,t,n)=>{let r=ho(e,n);if(!r)return!1;let o=go(r);return!!o&&so(e,o,t)})(e,t);function _l(){return"undefined"!=typeof navigator&&/Mac/.test(navigator.platform)}var Cl=e=>({editor:t,view:n,tr:r,dispatch:o})=>{const i=function(e){const t=e.split(/-(?!$)/);let n,r,o,i,a=t[t.length-1];"Space"===a&&(a=" ");for(let l=0;l<t.length-1;l+=1){const e=t[l];if(/^(cmd|meta|m)$/i.test(e))i=!0;else if(/^a(lt)?$/i.test(e))n=!0;else if(/^(c|ctrl|control)$/i.test(e))r=!0;else if(/^s(hift)?$/i.test(e))o=!0;else{if(!/^mod$/i.test(e))throw new Error(`Unrecognized modifier name: ${e}`);ll()||_l()?i=!0:r=!0}}return n&&(a=`Alt-${a}`),r&&(a=`Ctrl-${a}`),i&&(a=`Meta-${a}`),o&&(a=`Shift-${a}`),a}(e).split(/-(?!$)/),a=i.find(e=>!["Alt","Ctrl","Meta","Shift"].includes(e)),l=new KeyboardEvent("keydown",{key:"Space"===a?" ":a,altKey:i.includes("Alt"),ctrlKey:i.includes("Ctrl"),metaKey:i.includes("Meta"),shiftKey:i.includes("Shift"),bubbles:!0,cancelable:!0}),s=t.captureTransaction(()=>{n.someProp("handleKeyDown",e=>e(n,l))});return null==s||s.steps.forEach(e=>{const t=e.map(r.mapping);t&&o&&r.maybeStep(t)}),!0};function El(e,t,n={}){const{from:r,to:o,empty:i}=e.selection,a=t?Ga(t,e.schema):null,l=[];e.doc.nodesBetween(r,o,(e,t)=>{if(e.isText)return;const n=Math.max(r,t),i=Math.min(o,t+e.nodeSize);l.push({node:e,from:n,to:i})});const s=o-r,c=l.filter(e=>!a||a.name===e.node.type.name).filter(e=>Ya(e.node.attrs,n,{strict:!1}));if(i)return!!c.length;return c.reduce((e,t)=>e+t.to-t.from,0)>=s}var Sl=(e,t={})=>({state:n,dispatch:r})=>!!El(n,Ga(e,n.schema),t)&&((e,t)=>{let{$from:n,$to:r}=e.selection,o=n.blockRange(r),i=o&&mr(o);return null!=i&&(t&&t(e.tr.lift(o,i).scrollIntoView()),!0)})(n,r),Bl=()=>({state:e,dispatch:t})=>wo(e,t),Nl=e=>({state:t,dispatch:n})=>Mo(Ga(e,t.schema))(t,n),Ml=()=>({state:e,dispatch:t})=>vo(e,t);function Tl(e,t){return t.nodes[e]?"node":t.marks[e]?"mark":null}function Vl(e,t){const n="string"==typeof t?[t]:t;return Object.keys(e).reduce((t,r)=>(n.includes(r)||(t[r]=e[r]),t),{})}var Al=(e,t)=>({tr:n,state:r,dispatch:o})=>{let i=null,a=null;const l=Tl("string"==typeof e?e:e.name,r.schema);if(!l)return!1;"node"===l&&(i=Ga(e,r.schema)),"mark"===l&&(a=tl(e,r.schema));let s=!1;return n.selection.ranges.forEach(e=>{r.doc.nodesBetween(e.$from.pos,e.$to.pos,(e,r)=>{i&&i===e.type&&(s=!0,o&&n.setNodeMarkup(r,void 0,Vl(e.attrs,t))),a&&e.marks.length&&e.marks.forEach(i=>{a===i.type&&(s=!0,o&&n.addMark(r,r+e.nodeSize,a.create(Vl(i.attrs,t))))})})}),s},zl=()=>({tr:e,dispatch:t})=>(t&&e.scrollIntoView(),!0),Ol=()=>({tr:e,dispatch:t})=>{if(t){const t=new Wr(e.doc);e.setSelection(t)}return!0},Il=()=>({state:e,dispatch:t})=>uo(e,t),Dl=()=>({state:e,dispatch:t})=>fo(e,t),Pl=()=>({state:e,dispatch:t})=>((e,t)=>{let n,{$from:r,to:o}=e.selection,i=r.sharedDepth(o);return 0!=i&&(n=r.before(i),t&&t(e.tr.setSelection(qr.create(e.doc,n))),!0)})(e,t),$l=()=>({state:e,dispatch:t})=>Eo(e,t),Ll=()=>({state:e,dispatch:t})=>Co(e,t);var Rl=(e,{errorOnInvalidContent:t,emitUpdate:n=!0,parseOptions:r={}}={})=>({editor:o,tr:i,dispatch:a,commands:l})=>{const{doc:s}=i;if("full"!==r.preserveWhitespace){const l=function(e,t,n={},r={}){return hl(e,t,{slice:!1,parseOptions:n,errorOnInvalidContent:r.errorOnInvalidContent})}(e,o.schema,r,{errorOnInvalidContent:null!=t?t:o.options.enableContentCheck});return a&&i.replaceWith(0,s.content.size,l).setMeta("preventUpdate",!n),!0}return a&&i.setMeta("preventUpdate",!n),l.insertContentAt({from:0,to:s.content.size},e,{parseOptions:r,errorOnInvalidContent:null!=t?t:o.options.enableContentCheck})};function Hl(e,t){const n=tl(t,e.schema),{from:r,to:o,empty:i}=e.selection,a=[];i?(e.storedMarks&&a.push(...e.storedMarks),a.push(...e.selection.$head.marks())):e.doc.nodesBetween(r,o,e=>{a.push(...e.marks)});const l=a.find(e=>e.type.name===n.name);return l?{...l.attrs}:{}}function Fl(e,t){const n=new $r(e);return t.forEach(e=>{e.steps.forEach(e=>{n.step(e)})}),n}function jl(e){return t=>function(e,t){for(let n=e.depth;n>0;n-=1){const r=e.node(n);if(t(r))return{pos:n>0?e.before(n):0,start:e.start(n),depth:n,node:r}}}(t.$from,e)}function Ul(e,t,n){if(void 0===e.config[t]&&e.parent)return Ul(e.parent,t,n);if("function"==typeof e.config[t]){return e.config[t].bind({...n,parent:e.parent?Ul(e.parent,t,n):null})}return e.config[t]}function Gl(e,t=void 0,...n){return function(e){return"function"==typeof e}(e)?t?e.bind(t)(...n):e(...n):e}function ql(e){return{baseExtensions:e.filter(e=>"extension"===e.type),nodeExtensions:e.filter(e=>"node"===e.type),markExtensions:e.filter(e=>"mark"===e.type)}}function Zl(e){const t=[],n=function(e){const t=[];let n="",r=!1,o=!1,i=0;const a=e.length;for(let l=0;l<a;l+=1){const a=e[l];if("'"!==a||o)if('"'!==a||r){if(!r&&!o){if("("===a){i+=1,n+=a;continue}if(")"===a&&i>0){i-=1,n+=a;continue}if(";"===a&&0===i){t.push(n),n="";continue}}n+=a}else o=!o,n+=a;else r=!r,n+=a}return n&&t.push(n),t}(e||""),r=n.length;for(let o=0;o<r;o+=1){const e=n[o],r=e.indexOf(":");if(-1===r)continue;const i=e.slice(0,r).trim(),a=e.slice(r+1).trim();i&&a&&t.push([i,a])}return t}function Wl(...e){return e.filter(e=>!!e).reduce((e,t)=>{const n={...e};return Object.entries(t).forEach(([e,t])=>{if(n[e])if("class"===e){const r=t?String(t).split(" "):[],o=n[e]?n[e].split(" "):[],i=r.filter(e=>!o.includes(e));n[e]=[...o,...i].join(" ")}else if("style"===e){const r=new Map([...Zl(n[e]),...Zl(t)]);n[e]=Array.from(r.entries()).map(([e,t])=>`${e}: ${t}`).join("; ")}else n[e]=t;else n[e]=t}),n},{})}function Kl(e,t){const n=Tl("string"==typeof t?t:t.name,e.schema);return"node"===n?function(e,t){const n=Ga(t,e.schema),{from:r,to:o}=e.selection,i=[];e.doc.nodesBetween(r,o,e=>{i.push(e)});const a=i.reverse().find(e=>e.type.name===n.name);return a?{...a.attrs}:{}}(e,t):"mark"===n?Hl(e,t):{}}function Jl(e){const t=function(e,t=JSON.stringify){const n={};return e.filter(e=>{const r=t(e);return!Object.prototype.hasOwnProperty.call(n,r)&&(n[r]=!0)})}(e);return 1===t.length?t:t.filter((e,n)=>{const r=t.filter((e,t)=>t!==n);return!r.some(t=>e.oldRange.from>=t.oldRange.from&&e.oldRange.to<=t.oldRange.to&&e.newRange.from>=t.newRange.from&&e.newRange.to<=t.newRange.to)})}function Yl(e){const{mapping:t,steps:n}=e,r=[];return t.maps.forEach((e,o)=>{const i=[];if(e.ranges.length)e.forEach((e,t)=>{i.push({from:e,to:t})});else{const{from:e,to:t}=n[o];if(void 0===e||void 0===t)return;i.push({from:e,to:t})}i.forEach(({from:e,to:n})=>{const i=t.slice(o).map(e,-1),a=t.slice(o).map(n),l=t.invert().map(i,-1),s=t.invert().map(a);r.push({oldRange:{from:l,to:s},newRange:{from:i,to:a}})})}),Jl(r)}function Xl(e,t,n){const r=[];return e===t?n.resolve(e).marks().forEach(t=>{const o=el(n.resolve(e),t.type);o&&r.push({mark:t,...o})}):n.nodesBetween(e,t,(e,t)=>{e&&void 0!==(null==e?void 0:e.nodeSize)&&r.push(...e.marks.map(n=>({from:t,to:t+e.nodeSize,mark:n})))}),r}function Ql(e,t,n){return Object.fromEntries(Object.entries(n).filter(([n])=>{const r=e.find(e=>e.type===t&&e.name===n);return!!r&&r.attribute.keepOnSplit}))}function es(e,t){const{nodeExtensions:n}=ql(t),r=n.find(t=>t.name===e);if(!r)return!1;const o=Gl(Ul(r,"group",{name:r.name,options:r.options,storage:r.storage}));return"string"==typeof o&&o.split(" ").includes("list")}function ts(e,{checkChildren:t=!0,ignoreWhitespace:n=!1}={}){var r;if(n){if("hardBreak"===e.type.name)return!0;if(e.isText)return/^\s*$/m.test(null!=(r=e.text)?r:"")}if(e.isText)return!e.text;if(e.isAtom||e.isLeaf)return!1;if(0===e.content.childCount)return!0;if(t){let r=!0;return e.content.forEach(e=>{!1!==r&&(ts(e,{ignoreWhitespace:n,checkChildren:t})||(r=!1))}),r}return!1}function ns(e){return e instanceof qr}var rs=class e{constructor(e){this.position=e}static fromJSON(t){return new e(t.position)}toJSON(){return{position:this.position}}};var is=(e,t={})=>({tr:n,state:r,dispatch:o})=>{const{selection:i}=n,{empty:a,ranges:l}=i,s=tl(e,r.schema);if(o)if(a){const e=Hl(r,s);n.addStoredMark(s.create({...e,...t}))}else l.forEach(e=>{const o=e.$from.pos,i=e.$to.pos;r.doc.nodesBetween(o,i,(e,r)=>{const a=Math.max(r,o),l=Math.min(r+e.nodeSize,i);e.marks.find(e=>e.type===s)?e.marks.forEach(e=>{s===e.type&&n.addMark(a,l,s.create({...e.attrs,...t}))}):n.addMark(a,l,s.create(t))})});return function(e,t,n){var r;const{selection:o}=t;let i=null;if(ol(o)&&(i=o.$cursor),i){const t=null!=(r=e.storedMarks)?r:i.marks();return i.parent.type.allowsMarkType(n)&&(!!n.isInSet(t)||!t.some(e=>e.type.excludes(n)))}const{ranges:a}=o;return a.some(({$from:t,$to:r})=>{let o=0===t.depth&&e.doc.inlineContent&&e.doc.type.allowsMarkType(n);return e.doc.nodesBetween(t.pos,r.pos,(e,t,r)=>{if(o)return!1;if(e.isInline){const t=!r||r.type.allowsMarkType(n),i=!!n.isInSet(e.marks)||!e.marks.some(e=>e.type.excludes(n));o=t&&i}return!o}),o})}(r,n,s)},as=(e,t)=>({tr:n})=>(n.setMeta(e,t),!0),ls=(e,t={})=>({state:n,dispatch:r,chain:o})=>{const i=Ga(e,n.schema);let a;return n.selection.$anchor.sameParent(n.selection.$head)&&(a=n.selection.$anchor.parent.attrs),!!i.isTextblock&&o().command(({commands:e})=>!!So(i,{...a,...t})(n)||e.clearNodes()).command(({state:e})=>So(i,{...a,...t})(e,r)).run()},ss=e=>({tr:t,dispatch:n})=>{if(n){const{doc:n}=t,r=il(e,0,n.content.size),o=qr.create(n,r);t.setSelection(o)}return!0},cs=(e,t)=>({tr:n,state:r,dispatch:o})=>{const{selection:i}=r;let a,l;return"number"==typeof t?(a=t,l=t):t&&"from"in t&&"to"in t?(a=t.from,l=t.to):(a=i.from,l=i.to),o&&n.doc.nodesBetween(a,l,(t,r)=>{t.isText||n.setNodeMarkup(r,void 0,{...t.attrs,dir:e})}),!0},ds=e=>({tr:t,dispatch:n})=>{if(n){const{doc:n}=t,{from:r,to:o}="number"==typeof e?{from:e,to:e}:e,i=Ur.atStart(n).from,a=Ur.atEnd(n).to,l=il(r,i,a),s=il(o,i,a),c=Ur.create(n,l,s);t.setSelection(c)}return!0},us=e=>({state:t,dispatch:n})=>{const r=Ga(e,t.schema);return(o=r,function(e,t){let{$from:n,$to:r}=e.selection,i=n.blockRange(r,e=>e.childCount>0&&e.firstChild.type==o);if(!i)return!1;let a=i.startIndex;if(0==a)return!1;let l=i.parent,s=l.child(a-1);if(s.type!=o)return!1;if(t){let n=s.lastChild&&s.lastChild.type==l.type,r=Ht.from(n?o.create():null),a=new Zt(Ht.from(o.create(null,Ht.from(l.type.create(null,r)))),n?3:1,0),c=i.start,d=i.end;t(e.tr.step(new dr(c-(n?3:1),d,c,d,a,1,!0)).scrollIntoView())}return!0})(t,n);var o};function ps(e,t){const n=e.storedMarks||e.selection.$to.parentOffset&&e.selection.$from.marks();if(n){const r=n.filter(e=>null==t?void 0:t.includes(e.type.name));e.tr.ensureMarks(r)}}var hs=({keepMarks:e=!0}={})=>({tr:t,state:n,dispatch:r,editor:o})=>{const{selection:i,doc:a}=t,{$from:l,$to:s}=i,c=Ql(o.extensionManager.attributes,l.node().type.name,l.node().attrs);if(i instanceof qr&&i.node.isBlock)return!(!l.parentOffset||!br(a,l.pos))&&(r&&(e&&ps(n,o.extensionManager.splittableMarks),t.split(l.pos).scrollIntoView()),!0);if(!l.parent.isBlock)return!1;const d=s.parentOffset===s.parent.content.size,u=0===l.depth?void 0:function(e){for(let t=0;t<e.edgeCount;t+=1){const{type:n}=e.edge(t);if(n.isTextblock&&!n.hasRequiredAttrs())return n}return null}(l.node(-1).contentMatchAt(l.indexAfter(-1)));let p=d&&u?[{type:u,attrs:c}]:void 0,h=br(t.doc,t.mapping.map(l.pos),1,p);if(p||h||!br(t.doc,t.mapping.map(l.pos),1,u?[{type:u}]:void 0)||(h=!0,p=u?[{type:u,attrs:c}]:void 0),r){if(h&&(i instanceof Ur&&t.deleteSelection(),t.split(t.mapping.map(l.pos),1,p),u&&!d&&!l.parentOffset&&l.parent.type!==u)){const e=t.mapping.map(l.before()),n=t.doc.resolve(e);l.node(-1).canReplaceWith(n.index(),n.index()+1,u)&&t.setNodeMarkup(t.mapping.map(l.before()),u)}e&&ps(n,o.extensionManager.splittableMarks),t.scrollIntoView()}return h},ms=(e,t={})=>({tr:n,state:r,dispatch:o,editor:i})=>{var a;const l=Ga(e,r.schema),{$from:s,$to:c}=r.selection,d=r.selection.node;if(d&&d.isBlock||s.depth<2||!s.sameParent(c))return!1;const u=s.node(-1);if(u.type!==l)return!1;const p=i.extensionManager.attributes;if(0===s.parent.content.size&&s.node(-1).childCount===s.indexAfter(-1)){if(2===s.depth||s.node(-3).type!==l||s.index(-2)!==s.node(-2).childCount-1)return!1;if(o){let e=Ht.empty;const r=s.index(-1)?1:s.index(-2)?2:3;for(let t=s.depth-r;t>=s.depth-3;t-=1)e=Ht.from(s.node(t).copy(e));const o=s.indexAfter(-1)<s.node(-2).childCount?1:s.indexAfter(-2)<s.node(-3).childCount?2:3,i={...Ql(p,s.node().type.name,s.node().attrs),...t},c=(null==(a=l.contentMatch.defaultType)?void 0:a.createAndFill(i))||void 0;e=e.append(Ht.from(l.createAndFill(null,c)||void 0));const d=s.before(s.depth-(r-1));n.replace(d,s.after(-o),new Zt(e,4-r,0));let u=-1;n.doc.nodesBetween(d,n.doc.content.size,(e,t)=>{if(u>-1)return!1;e.isTextblock&&0===e.content.size&&(u=t+1)}),u>-1&&n.setSelection(Ur.near(n.doc.resolve(u))),n.scrollIntoView()}return!0}const h=c.pos===s.end()?u.contentMatchAt(0).defaultType:null,m={...Ql(p,u.type.name,u.attrs),...t},f={...Ql(p,s.node().type.name,s.node().attrs),...t};n.delete(s.pos,c.pos);const g=h?[{type:l,attrs:m},{type:h,attrs:f}]:[{type:l,attrs:m}];if(!br(n.doc,s.pos,2))return!1;if(o){const{selection:e,storedMarks:t}=r,{splittableMarks:a}=i.extensionManager,l=t||e.$to.parentOffset&&e.$from.marks();if(n.split(s.pos,2,g).scrollIntoView(),!l||!o)return!0;const c=l.filter(e=>a.includes(e.type.name));n.ensureMarks(c)}return!0},fs=(e,t)=>{const n=jl(e=>e.type===t)(e.selection);if(!n)return!0;const r=e.doc.resolve(Math.max(0,n.pos-1)).before(n.depth);if(void 0===r)return!0;const o=e.doc.nodeAt(r);return n.node.type!==(null==o?void 0:o.type)||!wr(e.doc,n.pos)||(e.join(n.pos),!0)},gs=(e,t)=>{const n=jl(e=>e.type===t)(e.selection);if(!n)return!0;const r=e.doc.resolve(n.start).after(n.depth);if(void 0===r)return!0;const o=e.doc.nodeAt(r);return n.node.type!==(null==o?void 0:o.type)||!wr(e.doc,r)||(e.join(r),!0)},vs=(e,t,n,r={})=>({editor:o,tr:i,state:a,dispatch:l,chain:s,commands:c,can:d})=>{const{extensions:u,splittableMarks:p}=o.extensionManager,h=Ga(e,a.schema),m=Ga(t,a.schema),{selection:f,storedMarks:g}=a,{$from:v,$to:y}=f,b=v.blockRange(y),w=g||f.$to.parentOffset&&f.$from.marks();if(!b)return!1;const k=jl(e=>es(e.type.name,u))(f);if(b.depth>=1&&k&&b.depth-k.depth<=1){if(k.node.type===h)return c.liftListItem(m);if(es(k.node.type.name,u)&&h.validContent(k.node.content)&&l)return s().command(()=>(i.setNodeMarkup(k.pos,h),!0)).command(()=>fs(i,h)).command(()=>gs(i,h)).run()}return n&&w&&l?s().command(()=>{const e=d().wrapInList(h,r),t=w.filter(e=>p.includes(e.type.name));return i.ensureMarks(t),!!e||c.clearNodes()}).wrapInList(h,r).command(()=>fs(i,h)).command(()=>gs(i,h)).run():s().command(()=>!!d().wrapInList(h,r)||c.clearNodes()).wrapInList(h,r).command(()=>fs(i,h)).command(()=>gs(i,h)).run()},ys=(e,t={},n={})=>({state:r,commands:o})=>{const{extendEmptyMarkRange:i=!1}=n,a=tl(e,r.schema),l=function(e,t,n={}){const{empty:r,ranges:o}=e.selection,i=t?tl(t,e.schema):null;if(r)return!!(e.storedMarks||e.selection.$from.marks()).filter(e=>!i||i.name===e.type.name).find(e=>Ya(e.attrs,n,{strict:!1}));let a=0;const l=[];if(o.forEach(({$from:t,$to:n})=>{const r=t.pos,o=n.pos;e.doc.nodesBetween(r,o,(e,t)=>{if(i&&e.inlineContent&&!e.type.allowsMarkType(i))return!1;if(!e.isText&&!e.marks.length)return;const n=Math.max(r,t),s=Math.min(o,t+e.nodeSize);a+=s-n,l.push(...e.marks.map(e=>({mark:e,from:n,to:s})))})}),0===a)return!1;const s=l.filter(e=>!i||i.name===e.mark.type.name).filter(e=>Ya(e.mark.attrs,n,{strict:!1})).reduce((e,t)=>e+t.to-t.from,0),c=l.filter(e=>!i||e.mark.type!==i&&e.mark.type.excludes(i)).reduce((e,t)=>e+t.to-t.from,0);return(s>0?s+c:s)>=a}(r,a,t);return l?o.unsetMark(a,{extendEmptyMarkRange:i}):o.setMark(a,t)},bs=(e,t,n={})=>({state:r,commands:o})=>{const i=Ga(e,r.schema),a=Ga(t,r.schema),l=El(r,i,n);let s;return r.selection.$anchor.sameParent(r.selection.$head)&&(s=r.selection.$anchor.parent.attrs),l?o.setNode(a,s):o.setNode(i,{...s,...n})},ws=(e,t={})=>({state:n,commands:r})=>{const o=Ga(e,n.schema);return El(n,o,t)?r.lift(o):r.wrapIn(o,t)},ks=()=>({state:e,dispatch:t})=>{const n=e.plugins;for(let r=0;r<n.length;r+=1){const o=n[r];let i;if(o.spec.isInputRules&&(i=o.getState(e))){if(t){const t=e.tr,n=i.transform;for(let e=n.steps.length-1;e>=0;e-=1)t.step(n.steps[e].invert(n.docs[e]));if(i.text){const n=t.doc.resolve(i.from).marks();t.replaceWith(i.from,i.to,e.schema.text(i.text,n))}else t.delete(i.from,i.to)}return!0}}return!1},xs=()=>({tr:e,dispatch:t})=>{const{selection:n}=e,{empty:r,ranges:o}=n;return r||t&&o.forEach(t=>{e.removeMark(t.$from.pos,t.$to.pos)}),!0},_s=(e,t={})=>({tr:n,state:r,dispatch:o})=>{var i;const{extendEmptyMarkRange:a=!1}=t,{selection:l}=n,s=tl(e,r.schema),{$from:c,empty:d,ranges:u}=l;if(!o)return!0;if(d&&a){let{from:e,to:t}=l;const r=null==(i=c.marks().find(e=>e.type===s))?void 0:i.attrs,o=el(c,s,r);o&&(e=o.from,t=o.to),n.removeMark(e,t,s)}else u.forEach(e=>{n.removeMark(e.$from.pos,e.$to.pos,s)});return n.removeStoredMark(s),!0},Cs=e=>({tr:t,state:n,dispatch:r})=>{const{selection:o}=n;let i,a;return"number"==typeof e?(i=e,a=e):e&&"from"in e&&"to"in e?(i=e.from,a=e.to):(i=o.from,a=o.to),r&&t.doc.nodesBetween(i,a,(e,n)=>{if(e.isText)return;const r={...e.attrs};delete r.dir,t.setNodeMarkup(n,void 0,r)}),!0},Es=(e,t={})=>({tr:n,state:r,dispatch:o})=>{let i=null,a=null;const l=Tl("string"==typeof e?e:e.name,r.schema);if(!l)return!1;"node"===l&&(i=Ga(e,r.schema)),"mark"===l&&(a=tl(e,r.schema));let s=!1;return n.selection.ranges.forEach(e=>{const l=e.$from.pos,c=e.$to.pos;let d,u,p,h;n.selection.empty?r.doc.nodesBetween(l,c,(e,t)=>{i&&i===e.type&&(s=!0,p=Math.max(t,l),h=Math.min(t+e.nodeSize,c),d=t,u=e)}):r.doc.nodesBetween(l,c,(e,r)=>{r<l&&i&&i===e.type&&(s=!0,p=Math.max(r,l),h=Math.min(r+e.nodeSize,c),d=r,u=e),r>=l&&r<=c&&(i&&i===e.type&&(s=!0,o&&n.setNodeMarkup(r,void 0,{...e.attrs,...t})),a&&e.marks.length&&e.marks.forEach(i=>{if(a===i.type&&(s=!0,o)){const o=Math.max(r,l),s=Math.min(r+e.nodeSize,c);n.addMark(o,s,a.create({...i.attrs,...t}))}}))}),u&&(void 0!==d&&o&&n.setNodeMarkup(d,void 0,{...u.attrs,...t}),a&&u.marks.length&&u.marks.forEach(e=>{a===e.type&&o&&n.addMark(p,h,a.create({...e.attrs,...t}))}))}),s},Ss=(e,t={})=>({state:n,dispatch:r})=>function(e,t=null){return function(n,r){let{$from:o,$to:i}=n.selection,a=o.blockRange(i),l=a&&fr(a,e,t);return!!l&&(r&&r(n.tr.wrap(a,l).scrollIntoView()),!0)}}(Ga(e,n.schema),t)(n,r),Bs=(e,t={})=>({state:n,dispatch:r})=>No(Ga(e,n.schema),t)(n,r),Ns=class{constructor(e){var t;this.find=e.find,this.handler=e.handler,this.undoable=null==(t=e.undoable)||t}};function Ms(e){return"Object"===function(e){return Object.prototype.toString.call(e).slice(8,-1)}(e)&&(e.constructor===Object&&Object.getPrototypeOf(e)===Object.prototype)}function Ts(e,t){const n={...e};return Ms(e)&&Ms(t)&&Object.keys(t).forEach(r=>{Ms(t[r])&&Ms(e[r])?n[r]=Ts(e[r],t[r]):n[r]=t[r]}),n}var Vs=class{constructor(e={}){this.type="extendable",this.parent=null,this.child=null,this.name="",this.config={name:this.name},this.config={...this.config,...e},this.name=this.config.name}get options(){return{...Gl(Ul(this,"addOptions",{name:this.name}))||{}}}get storage(){return{...Gl(Ul(this,"addStorage",{name:this.name,options:this.options}))||{}}}configure(e={}){const t=this.extend({...this.config,addOptions:()=>Ts(this.options,e)});return t.name=this.name,t.parent=this.parent,t}extend(e={}){const t=new this.constructor({...this.config,...e});return t.parent=this,this.child=t,t.name="name"in e?e.name:t.parent.name,t}},As=class e extends Vs{constructor(){super(...arguments),this.type="mark"}static create(t={}){const n="function"==typeof t?t():t;return new e(n)}static handleExit({editor:e,mark:t}){const{tr:n}=e.state,r=e.state.selection.$from;if(r.pos===r.end()){const o=r.marks();if(!!!o.find(e=>(null==e?void 0:e.type.name)===t.name))return!1;const i=o.find(e=>(null==e?void 0:e.type.name)===t.name);return i&&n.removeStoredMark(i),n.insertText(" ",r.pos),e.view.dispatch(n),!0}return!1}configure(e){return super.configure(e)}extend(e){const t="function"==typeof e?e():e;return super.extend(t)}},zs=class{constructor(e){this.find=e.find,this.handler=e.handler}};Oa({},{ClipboardTextSerializer:()=>Is,Commands:()=>Ds,Delete:()=>Ps,Drop:()=>$s,Editable:()=>Ls,FocusEvents:()=>Hs,Keymap:()=>Fs,Paste:()=>js,Tabindex:()=>Us,TextDirection:()=>Gs,focusEventsPluginKey:()=>Rs});var Os=class e extends Vs{constructor(){super(...arguments),this.type="extension"}static create(t={}){const n="function"==typeof t?t():t;return new e(n)}configure(e){return super.configure(e)}extend(e){const t="function"==typeof e?e():e;return super.extend(t)}},Is=Os.create({name:"clipboardTextSerializer",addOptions:()=>({blockSeparator:void 0}),addProseMirrorPlugins(){return[new to({key:new oo("clipboardTextSerializer"),props:{clipboardTextSerializer:()=>{const{editor:e}=this,{state:t,schema:n}=e,{doc:r,selection:o}=t,{ranges:i}=o,a=Math.min(...i.map(e=>e.$from.pos)),l=Math.max(...i.map(e=>e.$to.pos)),s=function(e){return Object.fromEntries(Object.entries(e.nodes).filter(([,e])=>e.spec.toText).map(([e,t])=>[e,t.spec.toText]))}(n);return function(e,t,n){const{from:r,to:o}=t,{blockSeparator:i="\n\n",textSerializers:a={}}=n||{};let l="";return e.nodesBetween(r,o,(e,n,s,c)=>{var d;e.isBlock&&n>r&&(l+=i);const u=null==a?void 0:a[e.type.name];if(u)return s&&(l+=u({node:e,pos:n,parent:s,index:c,range:t})),!1;e.isText&&(l+=null==(d=null==e?void 0:e.text)?void 0:d.slice(Math.max(r,n)-n,o-n))}),l}(r,{from:a,to:l},{...void 0!==this.options.blockSeparator?{blockSeparator:this.options.blockSeparator}:{},textSerializers:s})}}})]}}),Ds=Os.create({name:"commands",addCommands:()=>({...Pa})}),Ps=Os.create({name:"delete",onUpdate({transaction:e,appendedTransactions:t}){var n,r,o;const i=()=>{var n,r,o,i;if(null!=(i=null==(o=null==(r=null==(n=this.editor.options.coreExtensionOptions)?void 0:n.delete)?void 0:r.filterTransaction)?void 0:o.call(r,e))?i:e.getMeta("y-sync$"))return;const a=Fl(e.before,[e,...t]);Yl(a).forEach(t=>{a.mapping.mapResult(t.oldRange.from).deletedAfter&&a.mapping.mapResult(t.oldRange.to).deletedBefore&&a.before.nodesBetween(t.oldRange.from,t.oldRange.to,(n,r)=>{const o=r+n.nodeSize-2,i=t.oldRange.from<=r&&o<=t.oldRange.to;this.editor.emit("delete",{type:"node",node:n,from:r,to:o,newFrom:a.mapping.map(r),newTo:a.mapping.map(o),deletedRange:t.oldRange,newRange:t.newRange,partial:!i,editor:this.editor,transaction:e,combinedTransform:a})})});const l=a.mapping;a.steps.forEach((t,n)=>{var r,o;if(t instanceof ar){const i=l.slice(n).map(t.from,-1),s=l.slice(n).map(t.to),c=l.invert().map(i,-1),d=l.invert().map(s),u=null==(r=a.doc.nodeAt(i-1))?void 0:r.marks.some(e=>e.eq(t.mark)),p=null==(o=a.doc.nodeAt(s))?void 0:o.marks.some(e=>e.eq(t.mark));this.editor.emit("delete",{type:"mark",mark:t.mark,from:t.from,to:t.to,deletedRange:{from:c,to:d},newRange:{from:i,to:s},partial:Boolean(p||u),editor:this.editor,transaction:e,combinedTransform:a})}})};null==(o=null==(r=null==(n=this.editor.options.coreExtensionOptions)?void 0:n.delete)?void 0:r.async)||o?setTimeout(i,0):i()}}),$s=Os.create({name:"drop",addProseMirrorPlugins(){return[new to({key:new oo("tiptapDrop"),props:{handleDrop:(e,t,n,r)=>{this.editor.emit("drop",{editor:this.editor,event:t,slice:n,moved:r})}}})]}}),Ls=Os.create({name:"editable",addProseMirrorPlugins(){return[new to({key:new oo("editable"),props:{editable:()=>this.editor.options.editable}})]}}),Rs=new oo("focusEvents"),Hs=Os.create({name:"focusEvents",addProseMirrorPlugins(){const{editor:e}=this;return[new to({key:Rs,props:{handleDOMEvents:{focus:(t,n)=>{e.isFocused=!0;const r=e.state.tr.setMeta("focus",{event:n}).setMeta("addToHistory",!1);return t.dispatch(r),!1},blur:(t,n)=>{e.isFocused=!1;const r=e.state.tr.setMeta("blur",{event:n}).setMeta("addToHistory",!1);return t.dispatch(r),!1}}}})]}}),Fs=Os.create({name:"keymap",addKeyboardShortcuts(){const e=()=>this.editor.commands.first(({commands:e})=>[()=>e.undoInputRule(),()=>e.command(({tr:t})=>{const{selection:n,doc:r}=t,{empty:o,$anchor:i}=n,{pos:a,parent:l}=i,s=i.parent.isTextblock&&a>0?t.doc.resolve(a-1):i,c=s.parent.type.spec.isolating,d=i.pos-i.parentOffset,u=c&&1===s.parent.childCount?d===i.pos:Rr.atStart(r).from===a;return!(!o||!l.type.isTextblock||l.textContent.length||!u||u&&"paragraph"===i.parent.type.name)&&e.clearNodes()}),()=>e.deleteSelection(),()=>e.joinBackward(),()=>e.selectNodeBackward()]),t=()=>this.editor.commands.first(({commands:e})=>[()=>e.deleteSelection(),()=>e.deleteCurrentNode(),()=>e.joinForward(),()=>e.selectNodeForward()]),n={Enter:()=>this.editor.commands.first(({commands:e})=>[()=>e.newlineInCode(),()=>e.createParagraphNear(),()=>e.liftEmptyBlock(),()=>e.splitBlock()]),"Mod-Enter":()=>this.editor.commands.exitCode(),Backspace:e,"Mod-Backspace":e,"Shift-Backspace":e,Delete:t,"Mod-Delete":t,"Mod-a":()=>this.editor.commands.selectAll()},r={...n},o={...n,"Ctrl-h":e,"Alt-Backspace":e,"Ctrl-d":t,"Ctrl-Alt-Backspace":t,"Alt-Delete":t,"Alt-d":t,"Ctrl-a":()=>this.editor.commands.selectTextblockStart(),"Ctrl-e":()=>this.editor.commands.selectTextblockEnd()};return ll()||_l()?o:r},addProseMirrorPlugins(){return[new to({key:new oo("clearDocument"),appendTransaction:(e,t,n)=>{if(e.some(e=>e.getMeta("composition")))return;const r=e.some(e=>e.docChanged)&&!t.doc.eq(n.doc),o=e.some(e=>e.getMeta("preventClearDocument"));if(!r||o)return;const{empty:i,from:a,to:l}=t.selection,s=Rr.atStart(t.doc).from,c=Rr.atEnd(t.doc).to;if(i||!(a===s&&l===c))return;if(!ts(n.doc))return;const d=n.tr,u=Ia({state:n,transaction:d}),{commands:p}=new Da({editor:this.editor,state:u});return p.clearNodes(),d.steps.length?d:void 0}})]}}),js=Os.create({name:"paste",addProseMirrorPlugins(){return[new to({key:new oo("tiptapPaste"),props:{handlePaste:(e,t,n)=>{this.editor.emit("paste",{editor:this.editor,event:t,slice:n})}}})]}}),Us=Os.create({name:"tabindex",addProseMirrorPlugins(){return[new to({key:new oo("tabindex"),props:{attributes:()=>this.editor.isEditable?{tabindex:"0"}:{}}})]}}),Gs=Os.create({name:"textDirection",addOptions:()=>({direction:void 0}),addGlobalAttributes(){if(!this.options.direction)return[];const{nodeExtensions:e}=ql(this.extensions);return[{types:e.filter(e=>"text"!==e.name).map(e=>e.name),attributes:{dir:{default:this.options.direction,parseHTML:e=>{const t=e.getAttribute("dir");return!t||"ltr"!==t&&"rtl"!==t&&"auto"!==t?this.options.direction:t},renderHTML:e=>e.dir?{dir:e.dir}:{}}}}]},addProseMirrorPlugins(){return[new to({key:new oo("textDirection"),props:{attributes:()=>{const e=this.options.direction;return e?{dir:e}:{}}}})]}});function qs(e){return new Ns({find:e.find,handler:({state:t,range:n,match:r})=>{const o=Gl(e.getAttributes,void 0,r);if(!1===o||null===o)return null;const{tr:i}=t,a=r[r.length-1],l=r[0];if(a){const r=l.search(/\S/),s=n.from+l.indexOf(a),c=s+a.length;if(Xl(n.from,n.to,t.doc).filter(t=>t.mark.type.excluded.find(n=>n===e.type&&n!==t.mark.type)).filter(e=>e.to>s).length)return null;c<n.to&&i.delete(c,n.to),s>n.from&&i.delete(n.from+r,s);const d=n.from+r+a.length;i.addMark(n.from+r,d,e.type.create(o||{})),i.removeStoredMark(e.type)}},undoable:e.undoable})}function Zs(e){return new Ns({find:e.find,handler:({state:t,range:n,match:r})=>{const o=t.doc.resolve(n.from),i=Gl(e.getAttributes,void 0,r)||{};if(!o.node(-1).canReplaceWith(o.index(-1),o.indexAfter(-1),e.type))return null;t.tr.delete(n.from,n.to).setBlockType(n.from,n.from,e.type,i)},undoable:e.undoable})}function Ws(e){return new Ns({find:e.find,handler:({state:t,range:n,match:r,chain:o})=>{const i=Gl(e.getAttributes,void 0,r)||{},a=t.tr.delete(n.from,n.to),l=a.doc.resolve(n.from).blockRange(),s=l&&fr(l,e.type,i);if(!s)return null;if(a.wrap(l,s),e.keepMarks&&e.editor){const{selection:n,storedMarks:r}=t,{splittableMarks:o}=e.editor.extensionManager,i=r||n.$to.parentOffset&&n.$from.marks();if(i){const e=i.filter(e=>o.includes(e.type.name));a.ensureMarks(e)}}if(e.keepAttributes){const t="bulletList"===e.type.name||"orderedList"===e.type.name?"listItem":"taskList";o().updateAttributes(t,i).run()}const c=a.doc.resolve(n.from-1).nodeBefore;c&&c.type===e.type&&wr(a.doc,n.from-1)&&(!e.joinPredicate||e.joinPredicate(r,c))&&a.join(n.from-1)},undoable:e.undoable})}function Ks(e){if(!(null==e?void 0:e.trim()))return{};const t={},n=[],r=e.replace(/["']([^"']*)["']/g,e=>(n.push(e),`__QUOTED_${n.length-1}__`)),o=r.match(/(?:^|\s)\.([a-zA-Z][\w-]*)/g);if(o){const e=o.map(e=>e.trim().slice(1));t.class=e.join(" ")}const i=r.match(/(?:^|\s)#([a-zA-Z][\w-]*)/);i&&(t.id=i[1]);Array.from(r.matchAll(/([a-zA-Z][\w-]*)\s*=\s*(__QUOTED_\d+__)/g)).forEach(([,e,r])=>{var o;const i=parseInt((null==(o=r.match(/__QUOTED_(\d+)__/))?void 0:o[1])||"0",10),a=n[i];a&&(t[e]=a.slice(1,-1))});const a=r.replace(/(?:^|\s)\.([a-zA-Z][\w-]*)/g,"").replace(/(?:^|\s)#([a-zA-Z][\w-]*)/g,"").replace(/([a-zA-Z][\w-]*)\s*=\s*__QUOTED_\d+__/g,"").trim();if(a){a.split(/\s+/).filter(Boolean).forEach(e=>{e.match(/^[a-zA-Z][\w-]*$/)&&(t[e]=!0)})}return t}function Js(e){if(!e||0===Object.keys(e).length)return"";const t=[];if(e.class){String(e.class).split(/\s+/).filter(Boolean).forEach(e=>t.push(`.${e}`))}return e.id&&t.push(`#${e.id}`),Object.entries(e).forEach(([e,n])=>{"class"!==e&&"id"!==e&&(!0===n?t.push(e):!1!==n&&null!=n&&t.push(`${e}="${String(n)}"`))}),t.join(" ")}function Ys(e){const{nodeName:t,name:n,parseAttributes:r=Ks,serializeAttributes:o=Js,defaultAttributes:i={},requiredAttributes:a=[],allowedAttributes:l}=e,s=n||t;return{parseMarkdown:(e,n)=>{const r={...i,...e.attributes};return n.createNode(t,r,[])},markdownTokenizer:{name:t,level:"block",start(e){var t;const n=new RegExp(`^:::${s}(?:\\s|$)`,"m"),r=null==(t=e.match(n))?void 0:t.index;return void 0!==r?r:-1},tokenize(e,n,o){const i=new RegExp(`^:::${s}(?:\\s+\\{([^}]*)\\})?\\s*:::(?:\\n|$)`),l=e.match(i);if(!l)return;const c=l[1]||"",d=r(c);return a.find(e=>!(e in d))?void 0:{type:t,raw:l[0],attributes:d}}},renderMarkdown:e=>{const t=(e=>{if(!l)return e;const t={};return l.forEach(n=>{n in e&&(t[n]=e[n])}),t})(e.attrs||{}),n=o(t);return`:::${s}${n?` {${n}}`:""} :::`}}}function Xs(e){const{nodeName:t,name:n,getContent:r,parseAttributes:o=Ks,serializeAttributes:i=Js,defaultAttributes:a={},content:l="block",allowedAttributes:s}=e,c=n||t;return{parseMarkdown:(e,n)=>{let o;if(r){const t=r(e);o="string"==typeof t?[{type:"text",text:t}]:t}else o="block"===l?n.parseChildren(e.tokens||[]):n.parseInline(e.tokens||[]);const i={...a,...e.attributes};return n.createNode(t,i,o)},markdownTokenizer:{name:t,level:"block",start(e){var t;const n=new RegExp(`^:::${c}`,"m"),r=null==(t=e.match(n))?void 0:t.index;return void 0!==r?r:-1},tokenize(e,n,r){var i;const a=new RegExp(`^:::${c}(?:\\s+\\{([^}]*)\\})?\\s*\\n`),s=e.match(a);if(!s)return;const[d,u=""]=s,p=o(u);let h=1;const m=d.length;let f="";const g=/^:::([\w-]*)(\s.*)?/gm,v=e.slice(m);for(g.lastIndex=0;;){const n=g.exec(v);if(null===n)break;const o=n.index,a=n[1];if(!(null==(i=n[2])?void 0:i.endsWith(":::")))if(a)h+=1;else if(h-=1,0===h){const i=v.slice(0,o);f=i.trim();const a=e.slice(0,m+o+n[0].length);let s=[];if(f)if("block"===l)for(s=r.blockTokens(i),s.forEach(e=>{!e.text||e.tokens&&0!==e.tokens.length||(e.tokens=r.inlineTokens(e.text))});s.length>0;){const e=s[s.length-1];if("paragraph"!==e.type||e.text&&""!==e.text.trim())break;s.pop()}else s=r.inlineTokens(f);return{type:t,raw:a,attributes:p,content:f,tokens:s}}}}},renderMarkdown:(e,t)=>{const n=(e=>{if(!s)return e;const t={};return s.forEach(n=>{n in e&&(t[n]=e[n])}),t})(e.attrs||{}),r=i(n),o=r?` {${r}}`:"",a=t.renderChildren(e.content||[],"\n\n");return`:::${c}${o}\n\n${a}\n\n:::`}}}function Qs(e){if(!e.trim())return{};const t={},n=/(\w+)=(?:"([^"]*)"|'([^']*)')/g;let r=n.exec(e);for(;null!==r;){const[,o,i,a]=r;t[o]=i||a,r=n.exec(e)}return t}function ec(e){return Object.entries(e).filter(([,e])=>null!=e).map(([e,t])=>`${e}="${t}"`).join(" ")}function tc(e){const{nodeName:t,name:n,getContent:r,parseAttributes:o=Qs,serializeAttributes:i=ec,defaultAttributes:a={},selfClosing:l=!1,allowedAttributes:s}=e,c=n||t,d=c.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return{parseMarkdown:(e,n)=>{const o={...a,...e.attributes};if(l)return n.createNode(t,o);const i=r?r(e):e.content||"";return i?n.createNode(t,o,[n.createTextNode(i)]):n.createNode(t,o,[])},markdownTokenizer:{name:t,level:"inline",start(e){const t=l?new RegExp(`\\[${d}\\s*[^\\]]*\\]`):new RegExp(`\\[${d}\\s*[^\\]]*\\][\\s\\S]*?\\[\\/${d}\\]`),n=e.match(t),r=null==n?void 0:n.index;return void 0!==r?r:-1},tokenize(e,n,r){const i=l?new RegExp(`^\\[${d}\\s*([^\\]]*)\\]`):new RegExp(`^\\[${d}\\s*([^\\]]*)\\]([\\s\\S]*?)\\[\\/${d}\\]`),a=e.match(i);if(!a)return;let s="",c="";if(l){const[,e]=a;c=e}else{const[,e,t]=a;c=e,s=t||""}const u=o(c.trim());return{type:t,raw:a[0],content:s.trim(),attributes:u}}},renderMarkdown:e=>{let t="";r?t=r(e):e.content&&e.content.length>0&&(t=e.content.filter(e=>"text"===e.type).map(e=>e.text).join(""));const n=(e=>{if(!s)return e;const t={};return s.forEach(n=>{const r="string"==typeof n?n:n.name,o="string"==typeof n?void 0:n.skipIfDefault;if(r in e){const n=e[r];if(void 0!==o&&n===o)return;t[r]=n}}),t})(e.attrs||{}),o=i(n),a=o?` ${o}`:"";return l?`[${c}${a}]`:`[${c}${a}]${t}[/${c}]`}}}function nc(e,t,n){var r,o,i,a;const l=e.split("\n"),s=[];let c="",d=0;const u=t.baseIndentSize||2;for(;d<l.length;){const e=l[d],p=e.match(t.itemPattern);if(!p){if(s.length>0)break;if(""===e.trim()){d+=1,c=`${c}${e}\n`;continue}return}const h=t.extractItemData(p),{indentLevel:m,mainContent:f}=h;c=`${c}${e}\n`;const g=[f];for(d+=1;d<l.length;){const e=l[d];if(""===e.trim()){const t=l.slice(d+1).findIndex(e=>""!==e.trim());if(-1===t)break;if(((null==(o=null==(r=l[d+1+t].match(/^(\s*)/))?void 0:r[1])?void 0:o.length)||0)>m){g.push(e),c=`${c}${e}\n`,d+=1;continue}break}if(!(((null==(a=null==(i=e.match(/^(\s*)/))?void 0:i[1])?void 0:a.length)||0)>m))break;g.push(e),c=`${c}${e}\n`,d+=1}let v;const y=g.slice(1);if(y.length>0){const e=y.map(e=>e.slice(m+u)).join("\n");e.trim()&&(v=t.customNestedParser?t.customNestedParser(e):n.blockTokens(e))}const b=t.createToken(h,v);s.push(b)}if(0!==s.length)return{items:s,raw:c}}function rc(e,t,n,r){if(!e||!Array.isArray(e.content))return"";const o="function"==typeof n?n(r):n,[i,...a]=e.content,l=[`${o}${t.renderChildren([i])}`];return a&&a.length>0&&a.forEach(e=>{const n=t.renderChildren([e]);if(n){const e=n.split("\n").map(e=>e?t.indent(e):"").join("\n");l.push(e)}}),l.join("\n")}Oa({},{createAtomBlockMarkdownSpec:()=>Ys,createBlockMarkdownSpec:()=>Xs,createInlineMarkdownSpec:()=>tc,parseAttributes:()=>Ks,parseIndentedBlocks:()=>nc,renderNestedMarkdownContent:()=>rc,serializeAttributes:()=>Js});var oc=class e extends Vs{constructor(){super(...arguments),this.type="node"}static create(t={}){const n="function"==typeof t?t():t;return new e(n)}configure(e){return super.configure(e)}extend(e){const t="function"==typeof e?e():e;return super.extend(t)}},ic=class{constructor(e,t,n){this.isDragging=!1,this.component=e,this.editor=t.editor,this.options={stopEvent:null,ignoreMutation:null,...n},this.extension=t.extension,this.node=t.node,this.decorations=t.decorations,this.innerDecorations=t.innerDecorations,this.view=t.view,this.HTMLAttributes=t.HTMLAttributes,this.getPos=t.getPos,this.mount()}mount(){}get dom(){return this.editor.view.dom}get contentDOM(){return null}onDragStart(e){var t,n,r,o,i,a,l;const{view:s}=this.editor,c=e.target,d=3===c.nodeType?null==(t=c.parentElement)?void 0:t.closest("[data-drag-handle]"):c.closest("[data-drag-handle]");if(!this.dom||(null==(n=this.contentDOM)?void 0:n.contains(c))||!d)return;let u=0,p=0;if(this.dom!==d){const t=this.dom.getBoundingClientRect(),n=d.getBoundingClientRect(),l=null!=(o=e.offsetX)?o:null==(r=e.nativeEvent)?void 0:r.offsetX,s=null!=(a=e.offsetY)?a:null==(i=e.nativeEvent)?void 0:i.offsetY;u=n.x-t.x+l,p=n.y-t.y+s}const h=this.dom.cloneNode(!0);try{const e=this.dom.getBoundingClientRect();h.style.width=`${Math.round(e.width)}px`,h.style.height=`${Math.round(e.height)}px`,h.style.boxSizing="border-box",h.style.pointerEvents="none"}catch{}let m=null;try{m=document.createElement("div"),m.style.position="absolute",m.style.top="-9999px",m.style.left="-9999px",m.style.pointerEvents="none",m.appendChild(h),document.body.appendChild(m),null==(l=e.dataTransfer)||l.setDragImage(h,u,p)}finally{m&&setTimeout(()=>{try{null==m||m.remove()}catch{}},0)}const f=this.getPos();if("number"!=typeof f)return;const g=qr.create(s.state.doc,f),v=s.state.tr.setSelection(g);s.dispatch(v)}stopEvent(e){var t;if(!this.dom)return!1;if("function"==typeof this.options.stopEvent)return this.options.stopEvent({event:e});const n=e.target;if(!(this.dom.contains(n)&&!(null==(t=this.contentDOM)?void 0:t.contains(n))))return!1;const r=e.type.startsWith("drag"),o="drop"===e.type;if((["INPUT","BUTTON","SELECT","TEXTAREA"].includes(n.tagName)||n.isContentEditable)&&!o&&!r)return!0;const{isEditable:i}=this.editor,{isDragging:a}=this,l=!!this.node.type.spec.draggable,s=qr.isSelectable(this.node),c="copy"===e.type,d="paste"===e.type,u="cut"===e.type,p="mousedown"===e.type;if(!l&&s&&r&&e.target===this.dom&&e.preventDefault(),l&&r&&!a&&e.target===this.dom)return e.preventDefault(),!1;if(l&&i&&!a&&p){const e=n.closest("[data-drag-handle]");e&&(this.dom===e||this.dom.contains(e))&&(this.isDragging=!0,document.addEventListener("dragend",()=>{this.isDragging=!1},{once:!0}),document.addEventListener("drop",()=>{this.isDragging=!1},{once:!0}),document.addEventListener("mouseup",()=>{this.isDragging=!1},{once:!0}))}return!(a||o||c||d||u||p&&s)}ignoreMutation(e){if(!this.dom||!this.contentDOM)return!0;if("function"==typeof this.options.ignoreMutation)return this.options.ignoreMutation({mutation:e});if(this.node.isLeaf||this.node.isAtom)return!0;if("selection"===e.type)return!1;if(this.dom.contains(e.target)&&"childList"===e.type&&(ll()||al())&&this.editor.isFocused){if([...Array.from(e.addedNodes),...Array.from(e.removedNodes)].every(e=>e.isContentEditable))return!1}return this.contentDOM===e.target&&"attributes"===e.type||!this.contentDOM.contains(e.target)}updateAttributes(e){this.editor.commands.command(({tr:t})=>{const n=this.getPos();return"number"==typeof n&&(t.setNodeMarkup(n,void 0,{...this.node.attrs,...e}),!0)})}deleteNode(){const e=this.getPos();if("number"!=typeof e)return;const t=e+this.node.nodeSize;this.editor.commands.deleteRange({from:e,to:t})}};function ac(e){return new zs({find:e.find,handler:({state:t,range:n,match:r,pasteEvent:o})=>{const i=Gl(e.getAttributes,void 0,r,o);if(!1===i||null===i)return null;const{tr:a}=t,l=r[r.length-1],s=r[0];let c=n.to;if(l){const r=s.search(/\S/),o=n.from+s.indexOf(l),d=o+l.length;if(Xl(n.from,n.to,t.doc).filter(t=>t.mark.type.excluded.find(n=>n===e.type&&n!==t.mark.type)).filter(e=>e.to>o).length)return null;d<n.to&&a.delete(d,n.to),o>n.from&&a.delete(n.from+r,o),c=n.from+r+l.length,a.addMark(n.from+r,c,e.type.create(i||{})),a.removeStoredMark(e.type)}}})}e.defineComponent({name:"EditorContent",props:{editor:{default:null,type:Object}},setup(t){const n=e.ref(),r=e.getCurrentInstance();return e.watchEffect(()=>{const o=t.editor;o&&o.options.element&&n.value&&e.nextTick(()=>{var t;if(!n.value||!(null==(t=o.view.dom)?void 0:t.parentNode))return;const i=e.unref(n.value);n.value.append(...o.view.dom.parentNode.childNodes),o.contentComponent=r.ctx._,r&&(o.appContext={...r.appContext,provides:r.provides}),o.setOptions({element:i}),o.createNodeViews()})}),e.onBeforeUnmount(()=>{const e=t.editor;e&&(e.contentComponent=null,e.appContext=null)}),{rootEl:n}},render(){return e.h("div",{ref:e=>{this.rootEl=e}})}}),e.defineComponent({name:"NodeViewContent",props:{as:{type:String,default:"div"}},render(){return e.h(this.as,{style:{whiteSpace:"pre-wrap"},"data-node-view-content":""})}});var lc=e.defineComponent({name:"NodeViewWrapper",props:{as:{type:String,default:"div"}},inject:["onDragStart","decorationClasses"],render(){var t,n;return e.h(this.as,{class:this.decorationClasses,style:{whiteSpace:"normal"},"data-node-view-wrapper":"",onDragstart:this.onDragStart},null==(n=(t=this.$slots).default)?void 0:n.call(t))}}),sc=class{constructor(t,{props:n={},editor:r}){this.destroyed=!1,this.editor=r,this.component=e.markRaw(t),this.el=document.createElement("div"),this.props=e.reactive(n),this.renderedComponent=this.renderComponent()}get element(){return this.renderedComponent.el}get ref(){var e,t,n,r;return(null==(t=null==(e=this.renderedComponent.vNode)?void 0:e.component)?void 0:t.exposed)?this.renderedComponent.vNode.component.exposed:null==(r=null==(n=this.renderedComponent.vNode)?void 0:n.component)?void 0:r.proxy}renderComponent(){if(this.destroyed)return this.renderedComponent;let t=e.h(this.component,this.props);this.editor.appContext&&(t.appContext=this.editor.appContext),"undefined"!=typeof document&&this.el&&e.render(t,this.el);return{vNode:t,destroy:()=>{this.el&&e.render(null,this.el),this.el=null,t=null},el:this.el?this.el.firstElementChild:null}}updateProps(e={}){this.destroyed||(Object.entries(e).forEach(([e,t])=>{this.props[e]=t}),this.renderComponent())}destroy(){this.destroyed||(this.destroyed=!0,this.renderedComponent.destroy())}};e.defineComponent({name:"MarkViewContent",props:{as:{type:String,default:"span"}},render(){return e.h(this.as,{style:{whiteSpace:"inherit"},"data-mark-view-content":""})}});var cc=class extends ic{constructor(){super(...arguments),this.cachedExtensionWithSyncedStorage=null}get extensionWithSyncedStorage(){if(!this.cachedExtensionWithSyncedStorage){const e=this.editor,t=this.extension;this.cachedExtensionWithSyncedStorage=new Proxy(t,{get(n,r,o){var i;return"storage"===r?null!=(i=e.storage[t.name])?i:{}:Reflect.get(n,r,o)}})}return this.cachedExtensionWithSyncedStorage}mount(){const t={editor:this.editor,node:this.node,decorations:this.decorations,innerDecorations:this.innerDecorations,view:this.view,selected:!1,extension:this.extensionWithSyncedStorage,HTMLAttributes:this.HTMLAttributes,getPos:()=>this.getPos(),updateAttributes:(e={})=>this.updateAttributes(e),deleteNode:()=>this.deleteNode()},n=this.onDragStart.bind(this);this.decorationClasses=e.ref(this.getDecorationClasses());const r=e.defineComponent({extends:{...this.component},props:Object.keys(t),template:this.component.template,setup:t=>{var r,o;return e.provide("onDragStart",n),e.provide("decorationClasses",this.decorationClasses),null==(o=(r=this.component).setup)?void 0:o.call(r,t,{expose:()=>{}})},__scopeId:this.component.__scopeId,__cssModules:this.component.__cssModules,__name:this.component.__name,__file:this.component.__file});this.handleSelectionUpdate=this.handleSelectionUpdate.bind(this),this.editor.on("selectionUpdate",this.handleSelectionUpdate),this.renderer=new sc(r,{editor:this.editor,props:t})}get dom(){if(!this.renderer.element||!this.renderer.element.hasAttribute("data-node-view-wrapper"))throw Error("Please use the NodeViewWrapper component for your node view.");return this.renderer.element}get contentDOM(){return this.node.isLeaf?null:this.dom.querySelector("[data-node-view-content]")}handleSelectionUpdate(){const{from:e,to:t}=this.editor.state.selection,n=this.getPos();if("number"==typeof n)if(e<=n&&t>=n+this.node.nodeSize){if(this.renderer.props.selected)return;this.selectNode()}else{if(!this.renderer.props.selected)return;this.deselectNode()}}update(e,t,n){const r=e=>{this.decorationClasses.value=this.getDecorationClasses(),this.renderer.updateProps(e)};if("function"==typeof this.options.update){const o=this.node,i=this.decorations,a=this.innerDecorations;return this.node=e,this.decorations=t,this.innerDecorations=n,this.options.update({oldNode:o,oldDecorations:i,newNode:e,newDecorations:t,oldInnerDecorations:a,innerDecorations:n,updateProps:()=>r({node:e,decorations:t,innerDecorations:n,extension:this.extensionWithSyncedStorage})})}return e.type===this.node.type&&(e===this.node&&this.decorations===t&&this.innerDecorations===n||(this.node=e,this.decorations=t,this.innerDecorations=n,r({node:e,decorations:t,innerDecorations:n,extension:this.extensionWithSyncedStorage})),!0)}selectNode(){this.renderer.updateProps({selected:!0}),this.renderer.element&&this.renderer.element.classList.add("ProseMirror-selectednode")}deselectNode(){this.renderer.updateProps({selected:!1}),this.renderer.element&&this.renderer.element.classList.remove("ProseMirror-selectednode")}getDecorationClasses(){return this.decorations.flatMap(e=>e.type.attrs.class).join(" ")}destroy(){this.renderer.destroy(),this.editor.off("selectionUpdate",this.handleSelectionUpdate)}};const dc={"primary-light":{base:"bg-primary-50",baseDark:"bg-primary-100",text:"text-primary-800"},primary:{base:"bg-primary-100",baseDark:"bg-primary-200",text:"text-primary-800"},secondary:{base:"bg-secondary-100",baseDark:"bg-secondary-200",text:"text-secondary-800"},dark:{base:"bg-gray-100",baseDark:"bg-gray-200",text:"text-gray-800"},red:{base:"bg-red-100",baseDark:"bg-red-200",text:"text-red-800"},green:{base:"bg-green-100",baseDark:"bg-green-200",text:"text-green-800"},blue:{base:"bg-blue-100",baseDark:"bg-blue-200",text:"text-blue-800"},teal:{base:"bg-teal-100",baseDark:"bg-teal-200",text:"text-teal-800"},"teal-light":{base:"bg-teal-50",baseDark:"bg-teal-200",text:"text-teal-800"},yellow:{base:"bg-yellow-100",baseDark:"bg-yellow-200",text:"text-yellow-800"},indigo:{base:"bg-indigo-100",baseDark:"bg-indigo-200",text:"text-indigo-800"},purple:{base:"bg-purple-100",baseDark:"bg-purple-200",text:"text-purple-800"},pink:{base:"bg-pink-100",baseDark:"bg-pink-200",text:"text-pink-800"},orange:{base:"bg-orange-100",baseDark:"bg-orange-200",text:"text-orange-800"},black:{base:"bg-black",baseDark:"bg-gray-900",text:"text-white"}},uc={class:"w-full h-full",xmlns:"http://www.w3.org/2000/svg",viewbox:"0 0 48 48"},pc=["xlink:href"],hc=e.defineComponent({__name:"Icon",props:{icon:{},size:{default:"sm"},variant:{default:"default"}},setup(t){const n={"2xs":"w-[14px] h-[14px]",xs:"w-[16px] h-[16px]",sm:"w-[20px] h-[20px]",base:"w-[22px] h-[22px]",md:"w-[24px] h-[24px]",lg:"w-[32px] h-[32px]",xl:"w-[48px] h-[48px]"};return(r,o)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["inline-flex items-center justify-center leading-none align-middle icon",[n[t.size],{"rounded selection:drop-shadow-sm border bg-gray-50":"contained"===t.variant}]])},[(e.openBlock(),e.createElementBlock("svg",uc,[e.createElementVNode("use",{"xlink:href":`#${t.icon}`},null,8,pc)]))],2))}}),mc=e.defineComponent({__name:"Chip",props:{color:{default:"primary"},content:{},dark:{type:Boolean,default:!1},removable:{type:Boolean,default:!1},size:{default:"md"},textClass:{},tag:{default:"span"},hasChipBefore:{type:Boolean},hasChipAfter:{type:Boolean}},emits:["removed"],setup(t){const n=t,r=e.computed(()=>dc[n.color][n.dark?"baseDark":"base"]),o=e.computed(()=>dc[n.color].text);return(n,i)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.tag),e.mergeProps(n.$attrs,{class:["inline-flex items-center gap-1 rounded pl-2 whitespace-nowrap",{"pr-2":!t.removable,"h-4 px-2":"xs"===t.size,"h-4":"sm"===t.size,"h-5":"md"===t.size,"h-6":"lg"===t.size,"rounded-r-none":t.hasChipAfter,"rounded-l-none":t.hasChipBefore,[r.value]:!!r.value}]}),{default:e.withCtx(()=>[e.createElementVNode("span",{class:e.normalizeClass([[o.value,t.textClass,"xs"===t.size?"text-[11px]":"text-xs"],"flex-grow text-center"])},[e.renderSlot(n.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.content),1)])],2),t.removable?(e.openBlock(),e.createElementBlock("button",{key:0,class:e.normalizeClass([{"h-5 w-4":"sm"===t.size,"h-5 w-5":"md"===t.size,"h-5 w-6":"lg"===t.size,[r.value]:!!r.value},"flex items-center justify-center rounded h-full aspect-square"]),type:"button",title:"Remove",onClick:i[0]||(i[0]=e=>n.$emit("removed"))},[e.createVNode(e.unref(hc),{class:e.normalizeClass(o.value),icon:"close",size:"xs"},null,8,["class"])],2)):e.createCommentVNode("",!0)]),_:3},16,["class"]))}}),fc=e=>{if(e.tag)return e.tag;switch(e.variant){case"heading-1":return"h1";case"heading-2":return"h2";case"heading-3":return"h3";default:return"p"}},gc=e.defineComponent({__name:"Typography",props:{id:{},tag:{},variant:{default:"body"},noSpacing:{type:Boolean,default:!1},center:{type:Boolean,default:!1},mono:{type:Boolean,default:!1},shade:{},weight:{}},setup(t,{expose:n}){const r=t,o=e.computed(()=>fc(r)),i=e.computed(()=>(e=>{switch(e.variant){case"heading-1":return"text-2xl";case"heading-2":case"body-lg":return"text-lg";case"heading-3":return"text-md";case"body-xs":return"text-xs";case"body-sm":return"text-sm";case"caps-heading":return"inline-block text-2xs uppercase font-bold";case"label":return"block text-sm font-medium";default:return""}})(r)),a=e.computed(()=>(e=>{if(e.noSpacing)return"";if("p"===fc(e))switch(e.variant){case"body-sm":return"my-1";case"body":case"body-lg":return"my-2";default:return""}return""})(r)),l=e.computed(()=>(e=>{if(e.weight)switch(e.weight){case"bold":return"font-bold";case"semibold":return"font-semibold";default:return"font-normal"}return e.variant&&["heading-1","heading-2","heading-3"].includes(e.variant)?"font-semibold":""})(r)),s=e.computed(()=>(e=>{if("caps-heading"===e.variant)return"text-gray-600";if("label"===e.variant)return"text-gray-600";switch(e.shade){case"light":return"text-gray-700";case"lighter":return"text-gray-500";case"lightest":return"text-gray-300";default:return"text-inherit"}})(r)),c=e.computed(()=>r.center?"text-center":""),d=e.ref(null);return n({el:d}),(n,r)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.value),e.mergeProps(n.$attrs,{ref_key:"el",ref:d,class:[i.value,a.value,c.value,l.value,s.value,t.mono?"font-mono":void 0].join(" ")}),{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},16,["class"]))}}),vc=["aria-label","data-entity-details-type","data-entity-details-title","data-entity-details-name","data-entity-details-country","data-entity-details-country-code","data-entity-details-address-line-1","data-entity-details-address-line-2"],yc={class:"flex flex-row items-center gap-2"},bc={class:"flex flex-col"},wc={key:0,class:"flex items-center gap-2"},kc={class:"flex items-center gap-2"},xc={key:0,class:"invisible opacity-0 transition-opacity group-focus-within:visible group-focus-within:opacity-100 group-hover:visible group-hover:opacity-100"},_c={key:1,class:"text-primary text-lg"},Cc={key:0},Ec=e.defineComponent({__name:"EntityDetailsCard",props:{title:{},name:{},country:{},countryCode:{},addressLines:{},entityType:{}},setup(t){const n=e.computed(()=>t.countryCode?t.country?`Country code ${t.countryCode}, ${t.country}`:`Country code ${t.countryCode}`:"");return(r,o)=>{var i,a,l;return e.openBlock(),e.createElementBlock("section",{class:"group flex flex-col",role:"group","aria-label":t.title,"data-entity-details-type":t.entityType??"","data-entity-details-title":t.title,"data-entity-details-name":t.name??"","data-entity-details-country":t.country??"","data-entity-details-country-code":t.countryCode??"","data-entity-details-address-line-1":(null==(i=t.addressLines)?void 0:i[0])??"","data-entity-details-address-line-2":(null==(a=t.addressLines)?void 0:a[1])??""},[e.createElementVNode("div",yc,[e.createVNode(gc,{tag:"div",weight:"bold",class:"text-wrap text-sm"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.title),1)]),_:1})]),e.createElementVNode("div",bc,[t.name?(e.openBlock(),e.createElementBlock("div",wc,[e.createElementVNode("div",kc,[e.createVNode(gc,{variant:"body-sm",class:"text-wrap",shade:"light"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.name),1)]),_:1}),t.countryCode?(e.openBlock(),e.createBlock(mc,{key:0,color:"dark",size:"md","aria-label":n.value},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.countryCode),1)]),_:1},8,["aria-label"])):e.createCommentVNode("",!0)]),r.$slots.actions?(e.openBlock(),e.createElementBlock("div",xc,[e.renderSlot(r.$slots,"actions")])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),(null==(l=t.addressLines)?void 0:l.length)||t.country?(e.openBlock(),e.createElementBlock("address",_c,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.addressLines,(t,n)=>(e.openBlock(),e.createElementBlock("div",{key:`${t}-${n}`},[e.createVNode(gc,{shade:"light",variant:"body-sm"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t),1)]),_:2},1024)]))),128)),t.country?(e.openBlock(),e.createElementBlock("div",Cc,[e.createVNode(gc,{shade:"light",variant:"body-sm"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.country),1)]),_:1})])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])],8,vc)}}}),Sc=e.defineComponent({__name:"EntityDetailsRowNodeView",props:{node:{}},setup(t){const n=t,r=e=>"string"!=typeof e?"":e.trim(),o=(e,t)=>"boolean"!=typeof e?t:e,i=(e,t)=>[r(e),r(t)].filter(Boolean),a=e.computed(()=>n.node.attrs),l=e.computed(()=>o(a.value.showCustomer,!0)),s=e.computed(()=>o(a.value.showSupplier,!0)),c=e.computed(()=>r(a.value.customerTitle)),d=e.computed(()=>r(a.value.customerName)),u=e.computed(()=>r(a.value.customerCountry)),p=e.computed(()=>r(a.value.customerCountryCode)),h=e.computed(()=>i(a.value.customerAddressLine1,a.value.customerAddressLine2)),m=e.computed(()=>r(a.value.supplierTitle)),f=e.computed(()=>r(a.value.supplierName)),g=e.computed(()=>r(a.value.supplierCountry)),v=e.computed(()=>r(a.value.supplierCountryCode)),y=e.computed(()=>i(a.value.supplierAddressLine1,a.value.supplierAddressLine2)),b=e.computed(()=>({"data-show-customer":String(l.value),"data-show-supplier":String(s.value),"data-customer-title":c.value,"data-customer-name":d.value,"data-customer-country":u.value,"data-customer-country-code":p.value,"data-customer-address-line-1":h.value[0]??"","data-customer-address-line-2":h.value[1]??"","data-supplier-title":m.value,"data-supplier-name":f.value,"data-supplier-country":g.value,"data-supplier-country-code":v.value,"data-supplier-address-line-1":y.value[0]??"","data-supplier-address-line-2":y.value[1]??"","data-editor-entity-details-row":"true"}));return(t,n)=>(e.openBlock(),e.createBlock(e.unref(lc),e.mergeProps({as:"div",class:"editor-entity-details-row mb-6 grid gap-6 sm:grid-cols-2",contenteditable:"false"},b.value),{default:e.withCtx(()=>[l.value?(e.openBlock(),e.createBlock(Ec,{key:0,title:c.value,name:d.value,country:u.value,"country-code":p.value,"address-lines":h.value,"entity-type":"customer"},null,8,["title","name","country","country-code","address-lines"])):e.createCommentVNode("",!0),s.value?(e.openBlock(),e.createBlock(Ec,{key:1,title:m.value,name:f.value,country:g.value,"country-code":v.value,"address-lines":y.value,"entity-type":"supplier"},null,8,["title","name","country","country-code","address-lines"])):e.createCommentVNode("",!0)]),_:1},16))}}),Bc="data-editor-entity-details-row",Nc=`div[${Bc}="true"]`,Mc=(e,t)=>({default:t,parseHTML:t=>"true"===(t.getAttribute(e)??void 0),renderHTML:t=>({[e]:String(Boolean(t[Vc(e)]))})}),Tc=(e,t="")=>({default:t,parseHTML:n=>n.getAttribute(e)??t,renderHTML:n=>({[e]:"string"==typeof n[Vc(e)]?n[Vc(e)]:t})}),Vc=e=>e.replace(/^data-/,"").split("-").map((e,t)=>{var n;return 0===t?e:`${(null==(n=e[0])?void 0:n.toUpperCase())??""}${e.slice(1)}`}).join("");oc.create({name:"entityDetailsRow",group:"block",atom:!0,selectable:!0,addAttributes:()=>({showCustomer:Mc("data-show-customer",!0),showSupplier:Mc("data-show-supplier",!0),customerTitle:Tc("data-customer-title"),customerName:Tc("data-customer-name"),customerCountryCode:Tc("data-customer-country-code"),customerAddressLine1:Tc("data-customer-address-line-1"),customerAddressLine2:Tc("data-customer-address-line-2"),supplierTitle:Tc("data-supplier-title"),supplierName:Tc("data-supplier-name"),supplierCountryCode:Tc("data-supplier-country-code"),supplierAddressLine1:Tc("data-supplier-address-line-1"),supplierAddressLine2:Tc("data-supplier-address-line-2")}),parseHTML:()=>[{tag:Nc}],renderHTML:({HTMLAttributes:e})=>["div",Wl(e,{[Bc]:"true",class:"editor-entity-details-row",contenteditable:"false"})],addNodeView(){return e=Sc,n=>{if(!n.editor.contentComponent)return{};const r="function"==typeof e&&"__vccOpts"in e?e.__vccOpts:e;return new cc(r,n,t)};var e,t}});var Ac=(e,t)=>{if("slot"===e)return 0;if(e instanceof Function)return e(t);const{children:n,...r}=null!=t?t:{};if("svg"===e)throw new Error("SVG elements are not supported in the JSX syntax, use the array syntax instead");return[e,r,n]},zc=/^\s*>\s$/,Oc=oc.create({name:"blockquote",addOptions:()=>({HTMLAttributes:{}}),content:"block+",group:"block",defining:!0,parseHTML:()=>[{tag:"blockquote"}],renderHTML({HTMLAttributes:e}){return Ac("blockquote",{...Wl(this.options.HTMLAttributes,e),children:Ac("slot",{})})},parseMarkdown:(e,t)=>t.createNode("blockquote",void 0,t.parseChildren(e.tokens||[])),renderMarkdown:(e,t)=>{if(!e.content)return"";const n=[];return e.content.forEach(e=>{const r=t.renderChildren([e]).split("\n").map(e=>""===e.trim()?">":`> ${e}`);n.push(r.join("\n"))}),n.join("\n>\n")},addCommands(){return{setBlockquote:()=>({commands:e})=>e.wrapIn(this.name),toggleBlockquote:()=>({commands:e})=>e.toggleWrap(this.name),unsetBlockquote:()=>({commands:e})=>e.lift(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-b":()=>this.editor.commands.toggleBlockquote()}},addInputRules(){return[Ws({find:zc,type:this.type})]}}),Ic=/(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))$/,Dc=/(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))/g,Pc=/(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))$/,$c=/(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))/g,Lc=As.create({name:"bold",addOptions:()=>({HTMLAttributes:{}}),parseHTML(){return[{tag:"strong"},{tag:"b",getAttrs:e=>"normal"!==e.style.fontWeight&&null},{style:"font-weight=400",clearMark:e=>e.type.name===this.name},{style:"font-weight",getAttrs:e=>/^(bold(er)?|[5-9]\d{2,})$/.test(e)&&null}]},renderHTML({HTMLAttributes:e}){return Ac("strong",{...Wl(this.options.HTMLAttributes,e),children:Ac("slot",{})})},markdownTokenName:"strong",parseMarkdown:(e,t)=>t.applyMark("bold",t.parseInline(e.tokens||[])),renderMarkdown:(e,t)=>`**${t.renderChildren(e)}**`,addCommands(){return{setBold:()=>({commands:e})=>e.setMark(this.name),toggleBold:()=>({commands:e})=>e.toggleMark(this.name),unsetBold:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-b":()=>this.editor.commands.toggleBold(),"Mod-B":()=>this.editor.commands.toggleBold()}},addInputRules(){return[qs({find:Ic,type:this.type}),qs({find:Pc,type:this.type})]},addPasteRules(){return[ac({find:Dc,type:this.type}),ac({find:$c,type:this.type})]}}),Rc=/(^|[^`])`([^`]+)`(?!`)$/,Hc=/(^|[^`])`([^`]+)`(?!`)/g,Fc=As.create({name:"code",addOptions:()=>({HTMLAttributes:{}}),excludes:"_",code:!0,exitable:!0,parseHTML:()=>[{tag:"code"}],renderHTML({HTMLAttributes:e}){return["code",Wl(this.options.HTMLAttributes,e),0]},markdownTokenName:"codespan",parseMarkdown:(e,t)=>t.applyMark("code",[{type:"text",text:e.text||""}]),renderMarkdown:(e,t)=>e.content?`\`${t.renderChildren(e.content)}\``:"",addCommands(){return{setCode:()=>({commands:e})=>e.setMark(this.name),toggleCode:()=>({commands:e})=>e.toggleMark(this.name),unsetCode:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-e":()=>this.editor.commands.toggleCode()}},addInputRules(){return[qs({find:Rc,type:this.type})]},addPasteRules(){return[ac({find:Hc,type:this.type})]}}),jc=/^```([a-z]+)?[\s\n]$/,Uc=/^~~~([a-z]+)?[\s\n]$/,Gc=oc.create({name:"codeBlock",addOptions:()=>({languageClassPrefix:"language-",exitOnTripleEnter:!0,exitOnArrowDown:!0,defaultLanguage:null,enableTabIndentation:!1,tabSize:4,HTMLAttributes:{}}),content:"text*",marks:"",group:"block",code:!0,defining:!0,addAttributes(){return{language:{default:this.options.defaultLanguage,parseHTML:e=>{var t;const{languageClassPrefix:n}=this.options;if(!n)return null;const r=[...(null==(t=e.firstElementChild)?void 0:t.classList)||[]].filter(e=>e.startsWith(n)).map(e=>e.replace(n,""))[0];return r||null},rendered:!1}}},parseHTML:()=>[{tag:"pre",preserveWhitespace:"full"}],renderHTML({node:e,HTMLAttributes:t}){return["pre",Wl(this.options.HTMLAttributes,t),["code",{class:e.attrs.language?this.options.languageClassPrefix+e.attrs.language:null},0]]},markdownTokenName:"code",parseMarkdown:(e,t)=>{var n;return!1===(null==(n=e.raw)?void 0:n.startsWith("```"))&&"indented"!==e.codeBlockStyle?[]:t.createNode("codeBlock",{language:e.lang||null},e.text?[t.createTextNode(e.text)]:[])},renderMarkdown:(e,t)=>{var n;let r="";const o=(null==(n=e.attrs)?void 0:n.language)||"";if(e.content){r=[`\`\`\`${o}`,t.renderChildren(e.content),"```"].join("\n")}else r=`\`\`\`${o}\n\n\`\`\``;return r},addCommands(){return{setCodeBlock:e=>({commands:t})=>t.setNode(this.name,e),toggleCodeBlock:e=>({commands:t})=>t.toggleNode(this.name,"paragraph",e)}},addKeyboardShortcuts(){return{"Mod-Alt-c":()=>this.editor.commands.toggleCodeBlock(),Backspace:()=>{const{empty:e,$anchor:t}=this.editor.state.selection,n=1===t.pos;return!(!e||t.parent.type.name!==this.name)&&(!(!n&&t.parent.textContent.length)&&this.editor.commands.clearNodes())},Tab:({editor:e})=>{var t;if(!this.options.enableTabIndentation)return!1;const n=null!=(t=this.options.tabSize)?t:4,{state:r}=e,{selection:o}=r,{$from:i,empty:a}=o;if(i.parent.type!==this.type)return!1;const l=" ".repeat(n);return a?e.commands.insertContent(l):e.commands.command(({tr:e})=>{const{from:t,to:n}=o,i=r.doc.textBetween(t,n,"\n","\n").split("\n").map(e=>l+e).join("\n");return e.replaceWith(t,n,r.schema.text(i)),!0})},"Shift-Tab":({editor:e})=>{var t;if(!this.options.enableTabIndentation)return!1;const n=null!=(t=this.options.tabSize)?t:4,{state:r}=e,{selection:o}=r,{$from:i,empty:a}=o;return i.parent.type===this.type&&(a?e.commands.command(({tr:e})=>{var t;const{pos:o}=i,a=i.start(),l=i.end(),s=r.doc.textBetween(a,l,"\n","\n").split("\n");let c=0,d=0;const u=o-a;for(let n=0;n<s.length;n+=1){if(d+s[n].length>=u){c=n;break}d+=s[n].length+1}const p=(null==(t=s[c].match(/^ */))?void 0:t[0])||"",h=Math.min(p.length,n);if(0===h)return!0;let m=a;for(let n=0;n<c;n+=1)m+=s[n].length+1;e.delete(m,m+h);return o-m<=h&&e.setSelection(Ur.create(e.doc,m)),!0}):e.commands.command(({tr:e})=>{const{from:t,to:i}=o,a=r.doc.textBetween(t,i,"\n","\n").split("\n").map(e=>{var t;const r=(null==(t=e.match(/^ */))?void 0:t[0])||"",o=Math.min(r.length,n);return e.slice(o)}).join("\n");return e.replaceWith(t,i,r.schema.text(a)),!0}))},Enter:({editor:e})=>{if(!this.options.exitOnTripleEnter)return!1;const{state:t}=e,{selection:n}=t,{$from:r,empty:o}=n;if(!o||r.parent.type!==this.type)return!1;const i=r.parentOffset===r.parent.nodeSize-2,a=r.parent.textContent.endsWith("\n\n");return!(!i||!a)&&e.chain().command(({tr:e})=>(e.delete(r.pos-2,r.pos),!0)).exitCode().run()},ArrowDown:({editor:e})=>{if(!this.options.exitOnArrowDown)return!1;const{state:t}=e,{selection:n,doc:r}=t,{$from:o,empty:i}=n;if(!i||o.parent.type!==this.type)return!1;if(!(o.parentOffset===o.parent.nodeSize-2))return!1;const a=o.after();if(void 0===a)return!1;return r.nodeAt(a)?e.commands.command(({tr:e})=>(e.setSelection(Rr.near(r.resolve(a))),!0)):e.commands.exitCode()}}},addInputRules(){return[Zs({find:jc,type:this.type,getAttributes:e=>({language:e[1]})}),Zs({find:Uc,type:this.type,getAttributes:e=>({language:e[1]})})]},addProseMirrorPlugins(){return[new to({key:new oo("codeBlockVSCodeHandler"),props:{handlePaste:(e,t)=>{if(!t.clipboardData)return!1;if(this.editor.isActive(this.type.name))return!1;const n=t.clipboardData.getData("text/plain"),r=t.clipboardData.getData("vscode-editor-data"),o=r?JSON.parse(r):void 0,i=null==o?void 0:o.mode;if(!n||!i)return!1;const{tr:a,schema:l}=e.state,s=l.text(n.replace(/\r\n?/g,"\n"));return a.replaceSelectionWith(this.type.create({language:i},s)),a.selection.$from.parent.type!==this.type&&a.setSelection(Ur.near(a.doc.resolve(Math.max(0,a.selection.from-2)))),a.setMeta("paste",!0),e.dispatch(a),!0}}})]}}),qc=oc.create({name:"doc",topNode:!0,content:"block+",renderMarkdown:(e,t)=>e.content?t.renderChildren(e.content,"\n\n"):""}),Zc=oc.create({name:"hardBreak",markdownTokenName:"br",addOptions:()=>({keepMarks:!0,HTMLAttributes:{}}),inline:!0,group:"inline",selectable:!1,linebreakReplacement:!0,parseHTML:()=>[{tag:"br"}],renderHTML({HTMLAttributes:e}){return["br",Wl(this.options.HTMLAttributes,e)]},renderText:()=>"\n",renderMarkdown:()=>" \n",parseMarkdown:()=>({type:"hardBreak"}),addCommands(){return{setHardBreak:()=>({commands:e,chain:t,state:n,editor:r})=>e.first([()=>e.exitCode(),()=>e.command(()=>{const{selection:e,storedMarks:o}=n;if(e.$from.parent.type.spec.isolating)return!1;const{keepMarks:i}=this.options,{splittableMarks:a}=r.extensionManager,l=o||e.$to.parentOffset&&e.$from.marks();return t().insertContent({type:this.name}).command(({tr:e,dispatch:t})=>{if(t&&l&&i){const t=l.filter(e=>a.includes(e.type.name));e.ensureMarks(t)}return!0}).run()})])}},addKeyboardShortcuts(){return{"Mod-Enter":()=>this.editor.commands.setHardBreak(),"Shift-Enter":()=>this.editor.commands.setHardBreak()}}}),Wc=oc.create({name:"heading",addOptions:()=>({levels:[1,2,3,4,5,6],HTMLAttributes:{}}),content:"inline*",group:"block",defining:!0,addAttributes:()=>({level:{default:1,rendered:!1}}),parseHTML(){return this.options.levels.map(e=>({tag:`h${e}`,attrs:{level:e}}))},renderHTML({node:e,HTMLAttributes:t}){return[`h${this.options.levels.includes(e.attrs.level)?e.attrs.level:this.options.levels[0]}`,Wl(this.options.HTMLAttributes,t),0]},parseMarkdown:(e,t)=>t.createNode("heading",{level:e.depth||1},t.parseInline(e.tokens||[])),renderMarkdown:(e,t)=>{var n;const r=(null==(n=e.attrs)?void 0:n.level)?parseInt(e.attrs.level,10):1,o="#".repeat(r);return e.content?`${o} ${t.renderChildren(e.content)}`:""},addCommands(){return{setHeading:e=>({commands:t})=>!!this.options.levels.includes(e.level)&&t.setNode(this.name,e),toggleHeading:e=>({commands:t})=>!!this.options.levels.includes(e.level)&&t.toggleNode(this.name,"paragraph",e)}},addKeyboardShortcuts(){return this.options.levels.reduce((e,t)=>({...e,[`Mod-Alt-${t}`]:()=>this.editor.commands.toggleHeading({level:t})}),{})},addInputRules(){return this.options.levels.map(e=>Zs({find:new RegExp(`^(#{${Math.min(...this.options.levels)},${e}})\\s$`),type:this.type,getAttributes:{level:e}}))}}),Kc=oc.create({name:"horizontalRule",addOptions:()=>({HTMLAttributes:{},nextNodeType:"paragraph"}),group:"block",parseHTML:()=>[{tag:"hr"}],renderHTML({HTMLAttributes:e}){return["hr",Wl(this.options.HTMLAttributes,e)]},markdownTokenName:"hr",parseMarkdown:(e,t)=>t.createNode("horizontalRule"),renderMarkdown:()=>"---",addCommands(){return{setHorizontalRule:()=>({chain:e,state:t})=>{if(!function(e,t){const{selection:n}=e,{$from:r}=n;if(n instanceof qr){const e=r.index();return r.parent.canReplaceWith(e,e+1,t)}let o=r.depth;for(;o>=0;){const e=r.index(o);if(r.node(o).contentMatchAt(e).matchType(t))return!0;o-=1}return!1}(t,t.schema.nodes[this.name]))return!1;const{selection:n}=t,{$to:r}=n,o=e();return ns(n)?o.insertContentAt(r.pos,{type:this.name}):o.insertContent({type:this.name}),o.command(({state:e,tr:t,dispatch:n})=>{if(n){const{$to:n}=t.selection,r=n.end();if(n.nodeAfter)n.nodeAfter.isTextblock?t.setSelection(Ur.create(t.doc,n.pos+1)):n.nodeAfter.isBlock?t.setSelection(qr.create(t.doc,n.pos)):t.setSelection(Ur.create(t.doc,n.pos));else{const o=e.schema.nodes[this.options.nextNodeType]||n.parent.type.contentMatch.defaultType,i=null==o?void 0:o.create();i&&(t.insert(r,i),t.setSelection(Ur.create(t.doc,r+1)))}t.scrollIntoView()}return!0}).run()}}},addInputRules(){return[(e={find:/^(?:---|—-|___\s|\*\*\*\s)$/,type:this.type},new Ns({find:e.find,handler:({state:t,range:n,match:r})=>{const o=Gl(e.getAttributes,void 0,r)||{},{tr:i}=t,a=n.from;let l=n.to;const s=e.type.create(o);if(r[1]){let e=a+r[0].lastIndexOf(r[1]);e>l?e=l:l=e+r[1].length;const t=r[0][r[0].length-1];i.insertText(t,a+r[0].length-1),i.replaceWith(e,l,s)}else if(r[0]){const t=e.type.isInline?a:a-1;i.insert(t,e.type.create(o)).delete(i.mapping.map(a),i.mapping.map(l))}i.scrollIntoView()},undoable:e.undoable}))];var e}}),Jc=/(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))$/,Yc=/(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))/g,Xc=/(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))$/,Qc=/(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))/g,ed=As.create({name:"italic",addOptions:()=>({HTMLAttributes:{}}),parseHTML(){return[{tag:"em"},{tag:"i",getAttrs:e=>"normal"!==e.style.fontStyle&&null},{style:"font-style=normal",clearMark:e=>e.type.name===this.name},{style:"font-style=italic"}]},renderHTML({HTMLAttributes:e}){return["em",Wl(this.options.HTMLAttributes,e),0]},addCommands(){return{setItalic:()=>({commands:e})=>e.setMark(this.name),toggleItalic:()=>({commands:e})=>e.toggleMark(this.name),unsetItalic:()=>({commands:e})=>e.unsetMark(this.name)}},markdownTokenName:"em",parseMarkdown:(e,t)=>t.applyMark("italic",t.parseInline(e.tokens||[])),renderMarkdown:(e,t)=>`*${t.renderChildren(e)}*`,addKeyboardShortcuts(){return{"Mod-i":()=>this.editor.commands.toggleItalic(),"Mod-I":()=>this.editor.commands.toggleItalic()}},addInputRules(){return[qs({find:Jc,type:this.type}),qs({find:Xc,type:this.type})]},addPasteRules(){return[ac({find:Yc,type:this.type}),ac({find:Qc,type:this.type})]}});const td="numeric",nd="ascii",rd="alpha",od="asciinumeric",id="alphanumeric",ad="domain",ld="emoji",sd="scheme",cd="slashscheme",dd="whitespace";function ud(e,t){return e in t||(t[e]=[]),t[e]}function pd(e,t,n){t[td]&&(t[od]=!0,t[id]=!0),t[nd]&&(t[od]=!0,t[rd]=!0),t[od]&&(t[id]=!0),t[rd]&&(t[id]=!0),t[id]&&(t[ad]=!0),t[ld]&&(t[ad]=!0);for(const r in t){const t=ud(r,n);t.indexOf(e)<0&&t.push(e)}}function hd(e=null){this.j={},this.jr=[],this.jd=null,this.t=e}hd.groups={},hd.prototype={accepts(){return!!this.t},go(e){const t=this,n=t.j[e];if(n)return n;for(let r=0;r<t.jr.length;r++){const n=t.jr[r][0],o=t.jr[r][1];if(o&&n.test(e))return o}return t.jd},has(e,t=!1){return t?e in this.j:!!this.go(e)},ta(e,t,n,r){for(let o=0;o<e.length;o++)this.tt(e[o],t,n,r)},tr(e,t,n,r){let o;return r=r||hd.groups,t&&t.j?o=t:(o=new hd(t),n&&r&&pd(t,n,r)),this.jr.push([e,o]),o},ts(e,t,n,r){let o=this;const i=e.length;if(!i)return o;for(let a=0;a<i-1;a++)o=o.tt(e[a]);return o.tt(e[i-1],t,n,r)},tt(e,t,n,r){r=r||hd.groups;const o=this;if(t&&t.j)return o.j[e]=t,t;const i=t;let a,l=o.go(e);if(l?(a=new hd,Object.assign(a.j,l.j),a.jr.push.apply(a.jr,l.jr),a.jd=l.jd,a.t=l.t):a=new hd,i){if(r)if(a.t&&"string"==typeof a.t){const e=Object.assign(function(e,t){const n={};for(const r in t)t[r].indexOf(e)>=0&&(n[r]=!0);return n}(a.t,r),n);pd(i,e,r)}else n&&pd(i,n,r);a.t=i}return o.j[e]=a,a}};const md=(e,t,n,r,o)=>e.ta(t,n,r,o),fd=(e,t,n,r,o)=>e.tr(t,n,r,o),gd=(e,t,n,r,o)=>e.ts(t,n,r,o),vd=(e,t,n,r,o)=>e.tt(t,n,r,o),yd="WORD",bd="UWORD",wd="ASCIINUMERICAL",kd="ALPHANUMERICAL",xd="LOCALHOST",_d="TLD",Cd="UTLD",Ed="SCHEME",Sd="SLASH_SCHEME",Bd="NUM",Nd="WS",Md="NL",Td="OPENBRACE",Vd="CLOSEBRACE",Ad="OPENBRACKET",zd="CLOSEBRACKET",Od="OPENPAREN",Id="CLOSEPAREN",Dd="OPENANGLEBRACKET",Pd="CLOSEANGLEBRACKET",$d="FULLWIDTHLEFTPAREN",Ld="FULLWIDTHRIGHTPAREN",Rd="LEFTCORNERBRACKET",Hd="RIGHTCORNERBRACKET",Fd="LEFTWHITECORNERBRACKET",jd="RIGHTWHITECORNERBRACKET",Ud="FULLWIDTHLESSTHAN",Gd="FULLWIDTHGREATERTHAN",qd="AMPERSAND",Zd="APOSTROPHE",Wd="ASTERISK",Kd="AT",Jd="BACKSLASH",Yd="BACKTICK",Xd="CARET",Qd="COLON",eu="COMMA",tu="DOLLAR",nu="DOT",ru="EQUALS",ou="EXCLAMATION",iu="HYPHEN",au="PERCENT",lu="PIPE",su="PLUS",cu="POUND",du="QUERY",uu="QUOTE",pu="FULLWIDTHMIDDLEDOT",hu="SEMI",mu="SLASH",fu="TILDE",gu="UNDERSCORE",vu="EMOJI",yu="SYM";var bu=Object.freeze({__proto__:null,ALPHANUMERICAL:kd,AMPERSAND:qd,APOSTROPHE:Zd,ASCIINUMERICAL:wd,ASTERISK:Wd,AT:Kd,BACKSLASH:Jd,BACKTICK:Yd,CARET:Xd,CLOSEANGLEBRACKET:Pd,CLOSEBRACE:Vd,CLOSEBRACKET:zd,CLOSEPAREN:Id,COLON:Qd,COMMA:eu,DOLLAR:tu,DOT:nu,EMOJI:vu,EQUALS:ru,EXCLAMATION:ou,FULLWIDTHGREATERTHAN:Gd,FULLWIDTHLEFTPAREN:$d,FULLWIDTHLESSTHAN:Ud,FULLWIDTHMIDDLEDOT:pu,FULLWIDTHRIGHTPAREN:Ld,HYPHEN:iu,LEFTCORNERBRACKET:Rd,LEFTWHITECORNERBRACKET:Fd,LOCALHOST:xd,NL:Md,NUM:Bd,OPENANGLEBRACKET:Dd,OPENBRACE:Td,OPENBRACKET:Ad,OPENPAREN:Od,PERCENT:au,PIPE:lu,PLUS:su,POUND:cu,QUERY:du,QUOTE:uu,RIGHTCORNERBRACKET:Hd,RIGHTWHITECORNERBRACKET:jd,SCHEME:Ed,SEMI:hu,SLASH:mu,SLASH_SCHEME:Sd,SYM:yu,TILDE:fu,TLD:_d,UNDERSCORE:gu,UTLD:Cd,UWORD:bd,WORD:yd,WS:Nd});const wu=/[a-z]/,ku=new RegExp("\\p{L}","u"),xu=new RegExp("\\p{Emoji}","u"),_u=/\d/,Cu=/\s/;let Eu=null,Su=null;function Bu(e,t){const n=function(e){const t=[],n=e.length;let r=0;for(;r<n;){let o,i=e.charCodeAt(r),a=i<55296||i>56319||r+1===n||(o=e.charCodeAt(r+1))<56320||o>57343?e[r]:e.slice(r,r+2);t.push(a),r+=a.length}return t}(t.replace(/[A-Z]/g,e=>e.toLowerCase())),r=n.length,o=[];let i=0,a=0;for(;a<r;){let l=e,s=null,c=0,d=null,u=-1,p=-1;for(;a<r&&(s=l.go(n[a]));)l=s,l.accepts()?(u=0,p=0,d=l):u>=0&&(u+=n[a].length,p++),c+=n[a].length,i+=n[a].length,a++;i-=u,a-=p,c-=u,o.push({t:d.t,v:t.slice(i-c,i),s:i-c,e:i})}return o}function Nu(e,t,n,r,o){let i;const a=t.length;for(let l=0;l<a-1;l++){const n=t[l];e.j[n]?i=e.j[n]:(i=new hd(r),i.jr=o.slice(),e.j[n]=i),e=i}return i=new hd(n),i.jr=o.slice(),e.j[t[a-1]]=i,i}function Mu(e){const t=[],n=[];let r=0;for(;r<e.length;){let o=0;for(;"0123456789".indexOf(e[r+o])>=0;)o++;if(o>0){t.push(n.join(""));for(let t=parseInt(e.substring(r,r+o),10);t>0;t--)n.pop();r+=o}else n.push(e[r]),r++}return t}const Tu={defaultProtocol:"http",events:null,format:Au,formatHref:Au,nl2br:!1,tagName:"a",target:null,rel:null,validate:!0,truncate:1/0,className:null,attributes:null,ignoreTags:[],render:null};function Vu(e,t=null){let n=Object.assign({},Tu);e&&(n=Object.assign(n,e instanceof Vu?e.o:e));const r=n.ignoreTags,o=[];for(let i=0;i<r.length;i++)o.push(r[i].toUpperCase());this.o=n,t&&(this.defaultRender=t),this.ignoreTags=o}function Au(e){return e}function zu(e,t){this.t="token",this.v=e,this.tk=t}function Ou(e,t){class n extends zu{constructor(t,n){super(t,n),this.t=e}}for(const r in t)n.prototype[r]=t[r];return n.t=e,n}Vu.prototype={o:Tu,ignoreTags:[],defaultRender:e=>e,check(e){return this.get("validate",e.toString(),e)},get(e,t,n){const r=null!=t;let o=this.o[e];return o?("object"==typeof o?(o=n.t in o?o[n.t]:Tu[e],"function"==typeof o&&r&&(o=o(t,n))):"function"==typeof o&&r&&(o=o(t,n.t,n)),o):o},getObj(e,t,n){let r=this.o[e];return"function"==typeof r&&null!=t&&(r=r(t,n.t,n)),r},render(e){const t=e.render(this);return(this.get("render",null,e)||this.defaultRender)(t,e.t,e)}},zu.prototype={isLink:!1,toString(){return this.v},toHref(e){return this.toString()},toFormattedString(e){const t=this.toString(),n=e.get("truncate",t,this),r=e.get("format",t,this);return n&&r.length>n?r.substring(0,n)+"…":r},toFormattedHref(e){return e.get("formatHref",this.toHref(e.get("defaultProtocol")),this)},startIndex(){return this.tk[0].s},endIndex(){return this.tk[this.tk.length-1].e},toObject(e=Tu.defaultProtocol){return{type:this.t,value:this.toString(),isLink:this.isLink,href:this.toHref(e),start:this.startIndex(),end:this.endIndex()}},toFormattedObject(e){return{type:this.t,value:this.toFormattedString(e),isLink:this.isLink,href:this.toFormattedHref(e),start:this.startIndex(),end:this.endIndex()}},validate(e){return e.get("validate",this.toString(),this)},render(e){const t=this,n=this.toHref(e.get("defaultProtocol")),r=e.get("formatHref",n,this),o=e.get("tagName",n,t),i=this.toFormattedString(e),a={},l=e.get("className",n,t),s=e.get("target",n,t),c=e.get("rel",n,t),d=e.getObj("attributes",n,t),u=e.getObj("events",n,t);return a.href=r,l&&(a.class=l),s&&(a.target=s),c&&(a.rel=c),d&&Object.assign(a,d),{tagName:o,attributes:a,content:i,eventListeners:u}}};const Iu=Ou("email",{isLink:!0,toHref(){return"mailto:"+this.toString()}}),Du=Ou("text"),Pu=Ou("nl"),$u=Ou("url",{isLink:!0,toHref(e=Tu.defaultProtocol){return this.hasProtocol()?this.v:`${e}://${this.v}`},hasProtocol(){const e=this.tk;return e.length>=2&&e[0].t!==xd&&e[1].t===Qd}}),Lu=e=>new hd(e);function Ru(e,t,n){const r=n[0].s,o=n[n.length-1].e;return new e(t.slice(r,o),n)}const Hu="undefined"!=typeof console&&console&&console.warn||(()=>{}),Fu={scanner:null,parser:null,tokenQueue:[],pluginQueue:[],customSchemes:[],initialized:!1};function ju(e,t=!1){if(Fu.initialized&&Hu(`linkifyjs: already initialized - will not register custom scheme "${e}" until manual call of linkify.init(). Register all schemes and plugins before invoking linkify the first time.`),!/^[0-9a-z]+(-[0-9a-z]+)*$/.test(e))throw new Error('linkifyjs: incorrect scheme format.\n1. Must only contain digits, lowercase ASCII letters or "-"\n2. Cannot start or end with "-"\n3. "-" cannot repeat');Fu.customSchemes.push([e,t])}function Uu(){Fu.scanner=function(e=[]){const t={};hd.groups=t;const n=new hd;null==Eu&&(Eu=Mu("aaa1rp3bb0ott3vie4c1le2ogado5udhabi7c0ademy5centure6ountant0s9o1tor4d0s1ult4e0g1ro2tna4f0l1rica5g0akhan5ency5i0g1rbus3force5tel5kdn3l0ibaba4pay4lfinanz6state5y2sace3tom5m0azon4ericanexpress7family11x2fam3ica3sterdam8nalytics7droid5quan4z2o0l2partments8p0le4q0uarelle8r0ab1mco4chi3my2pa2t0e3s0da2ia2sociates9t0hleta5torney7u0ction5di0ble3o3spost5thor3o0s4w0s2x0a2z0ure5ba0by2idu3namex4d1k2r0celona5laycard4s5efoot5gains6seball5ketball8uhaus5yern5b0c1t1va3cg1n2d1e0ats2uty4er2rlin4st0buy5t2f1g1h0arti5i0ble3d1ke2ng0o3o1z2j1lack0friday9ockbuster8g1omberg7ue3m0s1w2n0pparibas9o0ats3ehringer8fa2m1nd2o0k0ing5sch2tik2on4t1utique6x2r0adesco6idgestone9oadway5ker3ther5ussels7s1t1uild0ers6siness6y1zz3v1w1y1z0h3ca0b1fe2l0l1vinklein9m0era3p2non3petown5ital0one8r0avan4ds2e0er0s4s2sa1e1h1ino4t0ering5holic7ba1n1re3c1d1enter4o1rn3f0a1d2g1h0anel2nel4rity4se2t2eap3intai5ristmas6ome4urch5i0priani6rcle4sco3tadel4i0c2y3k1l0aims4eaning6ick2nic1que6othing5ud3ub0med6m1n1o0ach3des3ffee4llege4ogne5m0mbank4unity6pany2re3uter5sec4ndos3struction8ulting7tact3ractors9oking4l1p2rsica5untry4pon0s4rses6pa2r0edit0card4union9icket5own3s1uise0s6u0isinella9v1w1x1y0mru3ou3z2dad1nce3ta1e1ing3sun4y2clk3ds2e0al0er2s3gree4livery5l1oitte5ta3mocrat6ntal2ist5si0gn4v2hl2iamonds6et2gital5rect0ory7scount3ver5h2y2j1k1m1np2o0cs1tor4g1mains5t1wnload7rive4tv2ubai3nlop4pont4rban5vag2r2z2earth3t2c0o2deka3u0cation8e1g1mail3erck5nergy4gineer0ing9terprises10pson4quipment8r0icsson6ni3s0q1tate5t1u0rovision8s2vents5xchange6pert3osed4ress5traspace10fage2il1rwinds6th3mily4n0s2rm0ers5shion4t3edex3edback6rrari3ero6i0delity5o2lm2nal1nce1ial7re0stone6mdale6sh0ing5t0ness6j1k1lickr3ghts4r2orist4wers5y2m1o0o0d1tball6rd1ex2sale4um3undation8x2r0ee1senius7l1ogans4ntier7tr2ujitsu5n0d2rniture7tbol5yi3ga0l0lery3o1up4me0s3p1rden4y2b0iz3d0n2e0a1nt0ing5orge5f1g0ee3h1i0ft0s3ves2ing5l0ass3e1obal2o4m0ail3bh2o1x2n1odaddy5ld0point6f2o0dyear5g0le4p1t1v2p1q1r0ainger5phics5tis4een3ipe3ocery4up4s1t1u0cci3ge2ide2tars5ru3w1y2hair2mburg5ngout5us3bo2dfc0bank7ealth0care8lp1sinki6re1mes5iphop4samitsu7tachi5v2k0t2m1n1ockey4ldings5iday5medepot5goods5s0ense7nda3rse3spital5t0ing5t0els3mail5use3w2r1sbc3t1u0ghes5yatt3undai7ibm2cbc2e1u2d1e0ee3fm2kano4l1m0amat4db2mo0bilien9n0c1dustries8finiti5o2g1k1stitute6urance4e4t0ernational10uit4vestments10o1piranga7q1r0ish4s0maili5t0anbul7t0au2v3jaguar4va3cb2e0ep2tzt3welry6io2ll2m0p2nj2o0bs1urg4t1y2p0morgan6rs3uegos4niper7kaufen5ddi3e0rryhotels6properties14fh2g1h1i0a1ds2m1ndle4tchen5wi3m1n1oeln3matsu5sher5p0mg2n2r0d1ed3uokgroup8w1y0oto4z2la0caixa5mborghini8er3nd0rover6xess5salle5t0ino3robe5w0yer5b1c1ds2ease3clerc5frak4gal2o2xus4gbt3i0dl2fe0insurance9style7ghting6ke2lly3mited4o2ncoln4k2ve1ing5k1lc1p2oan0s3cker3us3l1ndon4tte1o3ve3pl0financial11r1s1t0d0a3u0ndbeck6xe1ury5v1y2ma0drid4if1son4keup4n0agement7go3p1rket0ing3s4riott5shalls7ttel5ba2c0kinsey7d1e0d0ia3et2lbourne7me1orial6n0u2rckmsd7g1h1iami3crosoft7l1ni1t2t0subishi9k1l0b1s2m0a2n1o0bi0le4da2e1i1m1nash3ey2ster5rmon3tgage6scow4to0rcycles9v0ie4p1q1r1s0d2t0n1r2u0seum3ic4v1w1x1y1z2na0b1goya4me2vy3ba2c1e0c1t0bank4flix4work5ustar5w0s2xt0direct7us4f0l2g0o2hk2i0co2ke1on3nja3ssan1y5l1o0kia3rton4w0ruz3tv4p1r0a1w2tt2u1yc2z2obi1server7ffice5kinawa6layan0group9lo3m0ega4ne1g1l0ine5oo2pen3racle3nge4g0anic5igins6saka4tsuka4t2vh3pa0ge2nasonic7ris2s1tners4s1y3y2ccw3e0t2f0izer5g1h0armacy6d1ilips5one2to0graphy6s4ysio5ics1tet2ures6d1n0g1k2oneer5zza4k1l0ace2y0station9umbing5s3m1n0c2ohl2ker3litie5rn2st3r0axi3ess3ime3o0d0uctions8f1gressive8mo2perties3y5tection8u0dential9s1t1ub2w0c2y2qa1pon3uebec3st5racing4dio4e0ad1lestate6tor2y4cipes5d0stone5umbrella9hab3ise0n3t2liance6n0t0als5pair3ort3ublican8st0aurant8view0s5xroth6ich0ardli6oh3l1o1p2o0cks3deo3gers4om3s0vp3u0gby3hr2n2w0e2yukyu6sa0arland6fe0ty4kura4le1on3msclub4ung5ndvik0coromant12ofi4p1rl2s1ve2xo3b0i1s2c0b1haeffler7midt4olarships8ol3ule3warz5ience5ot3d1e0arch3t2cure1ity6ek2lect4ner3rvices6ven3w1x0y3fr2g1h0angrila6rp3ell3ia1ksha5oes2p0ping5uji3w3i0lk2na1gles5te3j1k0i0n2y0pe4l0ing4m0art3ile4n0cf3o0ccer3ial4ftbank4ware6hu2lar2utions7ng1y2y2pa0ce3ort2t3r0l2s1t0ada2ples4r1tebank4farm7c0group6ockholm6rage3e3ream4udio2y3yle4u0cks3pplies3y2ort5rf1gery5zuki5v1watch4iss4x1y0dney4stems6z2tab1ipei4lk2obao4rget4tamotors6r2too4x0i3c0i2d0k2eam2ch0nology8l1masek5nnis4va3f1g1h0d1eater2re6iaa2ckets5enda4ps2res2ol4j0maxx4x2k0maxx5l1m0all4n1o0day3kyo3ols3p1ray3shiba5tal3urs3wn2yota3s3r0ade1ing4ining5vel0ers0insurance16ust3v2t1ube2i1nes3shu4v0s2w1z2ua1bank3s2g1k1nicom3versity8o2ol2ps2s1y1z2va0cations7na1guard7c1e0gas3ntures6risign5mögensberater2ung14sicherung10t2g1i0ajes4deo3g1king4llas4n1p1rgin4sa1ion4va1o3laanderen9n1odka3lvo3te1ing3o2yage5u2wales2mart4ter4ng0gou5tch0es6eather0channel12bcam3er2site5d0ding5ibo2r3f1hoswho6ien2ki2lliamhill9n0dows4e1ners6me2olterskluwer11odside6rk0s2ld3w2s1tc1f3xbox3erox4ihuan4n2xx2yz3yachts4hoo3maxun5ndex5e1odobashi7ga2kohama6u0tube6t1un3za0ppos4ra3ero3ip2m1one3uerich6w2")),null==Su&&(Su=Mu("ελ1υ2бг1ел3дети4ею2католик6ом3мкд2он1сква6онлайн5рг3рус2ф2сайт3рб3укр3қаз3հայ3ישראל5קום3ابوظبي5رامكو5لاردن4بحرين5جزائر5سعودية6عليان5مغرب5مارات5یران5بارت2زار4يتك3ھارت5تونس4سودان3رية5شبكة4عراق2ب2مان4فلسطين6قطر3كاثوليك6وم3مصر2ليسيا5وريتانيا7قع4همراه5پاکستان7ڀارت4कॉम3नेट3भारत0म्3ोत5संगठन5বাংলা5ভারত2ৰত4ਭਾਰਤ4ભારત4ଭାରତ4இந்தியா6லங்கை6சிங்கப்பூர்11భారత్5ಭಾರತ4ഭാരതം5ලංකා4คอม3ไทย3ລາວ3გე2みんな3アマゾン4クラウド4グーグル4コム2ストア3セール3ファッション6ポイント4世界2中信1国1國1文网3亚马逊3企业2佛山2信息2健康2八卦2公司1益2台湾1灣2商城1店1标2嘉里0大酒店5在线2大拿2天主教3娱乐2家電2广东2微博2慈善2我爱你3手机2招聘2政务1府2新加坡2闻2时尚2書籍2机构2淡马锡3游戏2澳門2点看2移动2组织机构4网址1店1站1络2联通2谷歌2购物2通販2集团2電訊盈科4飞利浦3食品2餐厅2香格里拉3港2닷넷1컴2삼성2한국2")),vd(n,"'",Zd),vd(n,"{",Td),vd(n,"}",Vd),vd(n,"[",Ad),vd(n,"]",zd),vd(n,"(",Od),vd(n,")",Id),vd(n,"<",Dd),vd(n,">",Pd),vd(n,"(",$d),vd(n,")",Ld),vd(n,"「",Rd),vd(n,"」",Hd),vd(n,"『",Fd),vd(n,"』",jd),vd(n,"<",Ud),vd(n,">",Gd),vd(n,"&",qd),vd(n,"*",Wd),vd(n,"@",Kd),vd(n,"`",Yd),vd(n,"^",Xd),vd(n,":",Qd),vd(n,",",eu),vd(n,"$",tu),vd(n,".",nu),vd(n,"=",ru),vd(n,"!",ou),vd(n,"-",iu),vd(n,"%",au),vd(n,"|",lu),vd(n,"+",su),vd(n,"#",cu),vd(n,"?",du),vd(n,'"',uu),vd(n,"/",mu),vd(n,";",hu),vd(n,"~",fu),vd(n,"_",gu),vd(n,"\\",Jd),vd(n,"・",pu);const r=fd(n,_u,Bd,{[td]:!0});fd(r,_u,r);const o=fd(r,wu,wd,{[od]:!0}),i=fd(r,ku,kd,{[id]:!0}),a=fd(n,wu,yd,{[nd]:!0});fd(a,_u,o),fd(a,wu,a),fd(o,_u,o),fd(o,wu,o);const l=fd(n,ku,bd,{[rd]:!0});fd(l,wu),fd(l,_u,i),fd(l,ku,l),fd(i,_u,i),fd(i,wu),fd(i,ku,i);const s=vd(n,"\n",Md,{[dd]:!0}),c=vd(n,"\r",Nd,{[dd]:!0}),d=fd(n,Cu,Nd,{[dd]:!0});vd(n,"",d),vd(c,"\n",s),vd(c,"",d),fd(c,Cu,d),vd(d,"\r"),vd(d,"\n"),fd(d,Cu,d),vd(d,"",d);const u=fd(n,xu,vu,{[ld]:!0});vd(u,"#"),fd(u,xu,u),vd(u,"️",u);const p=vd(u,"");vd(p,"#"),fd(p,xu,u);const h=[[wu,a],[_u,o]],m=[[wu,null],[ku,l],[_u,i]];for(let f=0;f<Eu.length;f++)Nu(n,Eu[f],_d,yd,h);for(let f=0;f<Su.length;f++)Nu(n,Su[f],Cd,bd,m);pd(_d,{tld:!0,ascii:!0},t),pd(Cd,{utld:!0,alpha:!0},t),Nu(n,"file",Ed,yd,h),Nu(n,"mailto",Ed,yd,h),Nu(n,"http",Sd,yd,h),Nu(n,"https",Sd,yd,h),Nu(n,"ftp",Sd,yd,h),Nu(n,"ftps",Sd,yd,h),pd(Ed,{scheme:!0,ascii:!0},t),pd(Sd,{slashscheme:!0,ascii:!0},t),e=e.sort((e,t)=>e[0]>t[0]?1:-1);for(let f=0;f<e.length;f++){const t=e[f][0],r=e[f][1]?{[sd]:!0}:{[cd]:!0};t.indexOf("-")>=0?r[ad]=!0:wu.test(t)?_u.test(t)?r[od]=!0:r[nd]=!0:r[td]=!0,gd(n,t,t,r)}return gd(n,"localhost",xd,{ascii:!0}),n.jd=new hd(yu),{start:n,tokens:Object.assign({groups:t},bu)}}(Fu.customSchemes);for(let e=0;e<Fu.tokenQueue.length;e++)Fu.tokenQueue[e][1]({scanner:Fu.scanner});Fu.parser=function({groups:e}){const t=e.domain.concat([qd,Wd,Kd,Jd,Yd,Xd,tu,ru,iu,Bd,au,lu,su,cu,mu,yu,fu,gu]),n=[Zd,Qd,eu,nu,ou,au,du,uu,hu,Dd,Pd,Td,Vd,zd,Ad,Od,Id,$d,Ld,Rd,Hd,Fd,jd,Ud,Gd],r=[qd,Zd,Wd,Jd,Yd,Xd,tu,ru,iu,Td,Vd,au,lu,su,cu,du,mu,yu,fu,gu],o=Lu(),i=vd(o,fu);md(i,r,i),md(i,e.domain,i);const a=Lu(),l=Lu(),s=Lu();md(o,e.domain,a),md(o,e.scheme,l),md(o,e.slashscheme,s),md(a,r,i),md(a,e.domain,a);const c=vd(a,Kd);vd(i,Kd,c),vd(l,Kd,c),vd(s,Kd,c);const d=vd(i,nu);md(d,r,i),md(d,e.domain,i);const u=Lu();md(c,e.domain,u),md(u,e.domain,u);const p=vd(u,nu);md(p,e.domain,u);const h=Lu(Iu);md(p,e.tld,h),md(p,e.utld,h),vd(c,xd,h);const m=vd(u,iu);vd(m,iu,m),md(m,e.domain,u),md(h,e.domain,u),vd(h,nu,p),vd(h,iu,m);const f=vd(h,Qd);md(f,e.numeric,Iu);const g=vd(a,iu),v=vd(a,nu);vd(g,iu,g),md(g,e.domain,a),md(v,r,i),md(v,e.domain,a);const y=Lu($u);md(v,e.tld,y),md(v,e.utld,y),md(y,e.domain,a),md(y,r,i),vd(y,nu,v),vd(y,iu,g),vd(y,Kd,c);const b=vd(y,Qd),w=Lu($u);md(b,e.numeric,w);const k=Lu($u),x=Lu();md(k,t,k),md(k,n,x),md(x,t,k),md(x,n,x),vd(y,mu,k),vd(w,mu,k);const _=vd(l,Qd),C=vd(s,Qd),E=vd(C,mu),S=vd(E,mu);md(l,e.domain,a),vd(l,nu,v),vd(l,iu,g),md(s,e.domain,a),vd(s,nu,v),vd(s,iu,g),md(_,e.domain,k),vd(_,mu,k),vd(_,du,k),md(S,e.domain,k),md(S,t,k),vd(S,mu,k);const B=[[Td,Vd],[Ad,zd],[Od,Id],[Dd,Pd],[$d,Ld],[Rd,Hd],[Fd,jd],[Ud,Gd]];for(let N=0;N<B.length;N++){const[e,r]=B[N],o=vd(k,e);vd(x,e,o),vd(o,r,k);const i=Lu($u);md(o,t,i);const a=Lu();md(o,n),md(i,t,i),md(i,n,a),md(a,t,i),md(a,n,a),vd(i,r,k),vd(a,r,k)}return vd(o,xd,y),vd(o,Md,Pu),{start:o,tokens:bu}}(Fu.scanner.tokens);for(let e=0;e<Fu.pluginQueue.length;e++)Fu.pluginQueue[e][1]({scanner:Fu.scanner,parser:Fu.parser});return Fu.initialized=!0,Fu}function Gu(e){return Fu.initialized||Uu(),function(e,t,n){let r=n.length,o=0,i=[],a=[];for(;o<r;){let l=e,s=null,c=null,d=0,u=null,p=-1;for(;o<r&&!(s=l.go(n[o].t));)a.push(n[o++]);for(;o<r&&(c=s||l.go(n[o].t));)s=null,l=c,l.accepts()?(p=0,u=l):p>=0&&p++,o++,d++;if(p<0)o-=d,o<r&&(a.push(n[o]),o++);else{a.length>0&&(i.push(Ru(Du,t,a)),a=[]),o-=p,d-=p;const e=u.t,r=n.slice(o-d,o);i.push(Ru(e,t,r))}}return a.length>0&&i.push(Ru(Du,t,a)),i}(Fu.parser.start,e,Bu(Fu.scanner.start,e))}function qu(e,t=null,n=null){if(t&&"object"==typeof t){if(n)throw Error(`linkifyjs: Invalid link type ${t}; must be a string`);n=t,t=null}const r=new Vu(n),o=Gu(e),i=[];for(let a=0;a<o.length;a++){const e=o[a];!e.isLink||t&&e.t!==t||!r.check(e)||i.push(e.toFormattedObject(r))}return i}Gu.scan=Bu;var Zu="[\0- -\u2029 ]",Wu=new RegExp(Zu),Ku=new RegExp(`${Zu}$`),Ju=new RegExp(Zu,"g");function Yu(e,t){const n=["http","https","ftp","ftps","mailto","tel","callto","sms","cid","xmpp"];return t&&t.forEach(e=>{const t="string"==typeof e?e:e.scheme;t&&n.push(t)}),!e||e.replace(Ju,"").match(new RegExp(`^(?:(?:${n.join("|")}):|[^a-z]|[a-z0-9+.-]+(?:[^a-z+.-:]|$))`,"i"))}var Xu=As.create({name:"link",priority:1e3,keepOnSplit:!1,exitable:!0,onCreate(){this.options.validate&&!this.options.shouldAutoLink&&(this.options.shouldAutoLink=this.options.validate),this.options.protocols.forEach(e=>{"string"!=typeof e?ju(e.scheme,e.optionalSlashes):ju(e)})},onDestroy(){hd.groups={},Fu.scanner=null,Fu.parser=null,Fu.tokenQueue=[],Fu.pluginQueue=[],Fu.customSchemes=[],Fu.initialized=!1},inclusive(){return this.options.autolink},addOptions:()=>({openOnClick:!0,enableClickSelection:!1,linkOnPaste:!0,autolink:!0,protocols:[],defaultProtocol:"http",HTMLAttributes:{target:"_blank",rel:"noopener noreferrer nofollow",class:null},isAllowedUri:(e,t)=>!!Yu(e,t.protocols),validate:e=>!!e,shouldAutoLink:e=>{const t=/^[a-z][a-z0-9+.-]*:\/\//i.test(e),n=/^[a-z][a-z0-9+.-]*:/i.test(e);if(t||n&&!e.includes("@"))return!0;const r=(e.includes("@")?e.split("@").pop():e).split(/[/?#:]/)[0];return!/^\d{1,3}(\.\d{1,3}){3}$/.test(r)&&!!/\./.test(r)}}),addAttributes(){return{href:{default:null,parseHTML:e=>e.getAttribute("href")},target:{default:this.options.HTMLAttributes.target},rel:{default:this.options.HTMLAttributes.rel},class:{default:this.options.HTMLAttributes.class},title:{default:null}}},parseHTML(){return[{tag:"a[href]",getAttrs:e=>{const t=e.getAttribute("href");return!(!t||!this.options.isAllowedUri(t,{defaultValidate:e=>!!Yu(e,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol}))&&null}}]},renderHTML({HTMLAttributes:e}){return this.options.isAllowedUri(e.href,{defaultValidate:e=>!!Yu(e,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})?["a",Wl(this.options.HTMLAttributes,e),0]:["a",Wl(this.options.HTMLAttributes,{...e,href:""}),0]},markdownTokenName:"link",parseMarkdown:(e,t)=>t.applyMark("link",t.parseInline(e.tokens||[]),{href:e.href,title:e.title||null}),renderMarkdown:(e,t)=>{var n,r,o,i;const a=null!=(r=null==(n=e.attrs)?void 0:n.href)?r:"",l=null!=(i=null==(o=e.attrs)?void 0:o.title)?i:"",s=t.renderChildren(e);return l?`[${s}](${a} "${l}")`:`[${s}](${a})`},addCommands(){return{setLink:e=>({chain:t})=>{const{href:n}=e;return!!this.options.isAllowedUri(n,{defaultValidate:e=>!!Yu(e,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})&&t().setMark(this.name,e).setMeta("preventAutolink",!0).run()},toggleLink:e=>({chain:t})=>{const{href:n}=e||{};return!(n&&!this.options.isAllowedUri(n,{defaultValidate:e=>!!Yu(e,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol}))&&t().toggleMark(this.name,e,{extendEmptyMarkRange:!0}).setMeta("preventAutolink",!0).run()},unsetLink:()=>({chain:e})=>e().unsetMark(this.name,{extendEmptyMarkRange:!0}).setMeta("preventAutolink",!0).run()}},addPasteRules(){return[ac({find:e=>{const t=[];if(e){const{protocols:n,defaultProtocol:r}=this.options,o=qu(e).filter(e=>e.isLink&&this.options.isAllowedUri(e.value,{defaultValidate:e=>!!Yu(e,n),protocols:n,defaultProtocol:r}));o.length&&o.forEach(e=>{this.options.shouldAutoLink(e.value)&&t.push({text:e.value,data:{href:e.href},index:e.start})})}return t},type:this.type,getAttributes:e=>{var t;return{href:null==(t=e.data)?void 0:t.href}}})]},addProseMirrorPlugins(){const e=[],{protocols:t,defaultProtocol:n}=this.options;var r;return this.options.autolink&&e.push((r={type:this.type,defaultProtocol:this.options.defaultProtocol,validate:e=>this.options.isAllowedUri(e,{defaultValidate:e=>!!Yu(e,t),protocols:t,defaultProtocol:n}),shouldAutoLink:this.options.shouldAutoLink},new to({key:new oo("autolink"),appendTransaction:(e,t,n)=>{const o=e.some(e=>e.docChanged)&&!t.doc.eq(n.doc),i=e.some(e=>e.getMeta("preventAutolink"));if(!o||i)return;const{tr:a}=n;return Yl(Fl(t.doc,[...e])).forEach(({newRange:e})=>{const t=function(e,t,n){const r=[];return e.nodesBetween(t.from,t.to,(e,t)=>{n(e)&&r.push({node:e,pos:t})}),r}(n.doc,e,e=>e.isTextblock);let o,i;if(t.length>1)o=t[0],i=n.doc.textBetween(o.pos,o.pos+o.node.nodeSize,void 0," ");else if(t.length){const r=n.doc.textBetween(e.from,e.to," "," ");if(!Ku.test(r))return;o=t[0],i=n.doc.textBetween(o.pos,e.to,void 0," ")}if(o&&i){const e=i.split(Wu).filter(Boolean);if(e.length<=0)return!1;const t=e[e.length-1],s=o.pos+i.lastIndexOf(t);if(!t)return!1;const c=Gu(t).map(e=>e.toObject(r.defaultProtocol));if(!(1===(l=c).length?l[0].isLink:3===l.length&&l[1].isLink&&["()","[]"].includes(l[0].value+l[2].value)))return!1;c.filter(e=>e.isLink).map(e=>({...e,from:s+e.start+1,to:s+e.end+1})).filter(e=>!n.schema.marks.code||!n.doc.rangeHasMark(e.from,e.to,n.schema.marks.code)).filter(e=>r.validate(e.value)).filter(e=>r.shouldAutoLink(e.value)).forEach(e=>{Xl(e.from,e.to,n.doc).some(e=>e.mark.type===r.type)||a.addMark(e.from,e.to,r.type.create({href:e.href}))})}var l}),a.steps.length?a:void 0}}))),e.push(function(e){return new to({key:new oo("handleClickLink"),props:{handleClick:(t,n,r)=>{var o,i;if(0!==r.button)return!1;if(!t.editable)return!1;let a=null;if(r.target instanceof HTMLAnchorElement)a=r.target;else{const t=r.target;if(!t)return!1;const n=e.editor.view.dom;a=t.closest("a"),a&&!n.contains(a)&&(a=null)}if(!a)return!1;let l=!1;if(e.enableClickSelection&&(l=e.editor.commands.extendMarkRange(e.type.name)),e.openOnClick){const n=Kl(t.state,e.type.name),r=null!=(o=a.href)?o:n.href,s=null!=(i=a.target)?i:n.target;r&&(window.open(r,s),l=!0)}return l}}})}({type:this.type,editor:this.editor,openOnClick:"whenNotEditable"===this.options.openOnClick||this.options.openOnClick,enableClickSelection:this.options.enableClickSelection})),this.options.linkOnPaste&&e.push(function(e){return new to({key:new oo("handlePasteLink"),props:{handlePaste:(t,n,r)=>{const{shouldAutoLink:o}=e,{state:i}=t,{selection:a}=i,{empty:l}=a;if(l)return!1;let s="";r.content.forEach(e=>{s+=e.textContent});const c=qu(s,{defaultProtocol:e.defaultProtocol}).find(e=>e.isLink&&e.value===s);return!(!s||!c||void 0!==o&&!o(c.value))&&e.editor.commands.setMark(e.type,{href:c.href})}}})}({editor:this.editor,defaultProtocol:this.options.defaultProtocol,type:this.type,shouldAutoLink:this.options.shouldAutoLink})),e}}),Qu=Object.defineProperty,ep="textStyle",tp=/^\s*([-+*])\s$/,np=oc.create({name:"bulletList",addOptions:()=>({itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}),group:"block list",content(){return`${this.options.itemTypeName}+`},parseHTML:()=>[{tag:"ul"}],renderHTML({HTMLAttributes:e}){return["ul",Wl(this.options.HTMLAttributes,e),0]},markdownTokenName:"list",parseMarkdown:(e,t)=>"list"!==e.type||e.ordered?[]:{type:"bulletList",content:e.items?t.parseChildren(e.items):[]},renderMarkdown:(e,t)=>e.content?t.renderChildren(e.content,"\n"):"",markdownOptions:{indentsContent:!0},addCommands(){return{toggleBulletList:()=>({commands:e,chain:t})=>this.options.keepAttributes?t().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes("listItem",this.editor.getAttributes(ep)).run():e.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-8":()=>this.editor.commands.toggleBulletList()}},addInputRules(){let e=Ws({find:tp,type:this.type});return(this.options.keepMarks||this.options.keepAttributes)&&(e=Ws({find:tp,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:()=>this.editor.getAttributes(ep),editor:this.editor})),[e]}}),rp=oc.create({name:"listItem",addOptions:()=>({HTMLAttributes:{},bulletListTypeName:"bulletList",orderedListTypeName:"orderedList"}),content:"paragraph block*",defining:!0,parseHTML:()=>[{tag:"li"}],renderHTML({HTMLAttributes:e}){return["li",Wl(this.options.HTMLAttributes,e),0]},markdownTokenName:"list_item",parseMarkdown:(e,t)=>{if("list_item"!==e.type)return[];let n=[];if(e.tokens&&e.tokens.length>0){if(e.tokens.some(e=>"paragraph"===e.type))n=t.parseChildren(e.tokens);else{const r=e.tokens[0];if(r&&"text"===r.type&&r.tokens&&r.tokens.length>0){if(n=[{type:"paragraph",content:t.parseInline(r.tokens)}],e.tokens.length>1){const r=e.tokens.slice(1),o=t.parseChildren(r);n.push(...o)}}else n=t.parseChildren(e.tokens)}}return 0===n.length&&(n=[{type:"paragraph",content:[]}]),{type:"listItem",content:n}},renderMarkdown:(e,t,n)=>rc(e,t,e=>{var t,n;if("bulletList"===e.parentType)return"- ";if("orderedList"===e.parentType){return`${((null==(n=null==(t=e.meta)?void 0:t.parentAttrs)?void 0:n.start)||1)+e.index}. `}return"- "},n),addKeyboardShortcuts(){return{Enter:()=>this.editor.commands.splitListItem(this.name),Tab:()=>this.editor.commands.sinkListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)}}});((e,t)=>{for(var n in t)Qu(e,n,{get:t[n],enumerable:!0})})({},{findListItemPos:()=>op,getNextListDepth:()=>ip,handleBackspace:()=>cp,handleDelete:()=>pp,hasListBefore:()=>ap,hasListItemAfter:()=>hp,hasListItemBefore:()=>lp,listItemHasSubList:()=>sp,nextListIsDeeper:()=>dp,nextListIsHigher:()=>up});var op=(e,t)=>{const{$from:n}=t.selection,r=Ga(e,t.schema);let o=null,i=n.depth,a=n.pos,l=null;for(;i>0&&null===l;)o=n.node(i),o.type===r?l=i:(i-=1,a-=1);return null===l?null:{$pos:t.doc.resolve(a),depth:l}},ip=(e,t)=>{const n=op(e,t);if(!n)return!1;const[,r]=((e,t,n,r=20)=>{const o=e.doc.resolve(n);let i=r,a=null;for(;i>0&&null===a;){const e=o.node(i);(null==e?void 0:e.type.name)===t?a=e:i-=1}return[a,i]})(t,e,n.$pos.pos+4);return r},ap=(e,t,n)=>{const{$anchor:r}=e.selection,o=Math.max(0,r.pos-2),i=e.doc.resolve(o).node();return!(!i||!n.includes(i.type.name))},lp=(e,t)=>{var n;const{$anchor:r}=t.selection,o=t.doc.resolve(r.pos-2);return 0!==o.index()&&(null==(n=o.nodeBefore)?void 0:n.type.name)===e},sp=(e,t,n)=>{if(!n)return!1;const r=Ga(e,t.schema);let o=!1;return n.descendants(e=>{e.type===r&&(o=!0)}),o},cp=(e,t,n)=>{if(e.commands.undoInputRule())return!0;if(e.state.selection.from!==e.state.selection.to)return!1;if(!El(e.state,t)&&ap(e.state,t,n)){const{$anchor:n}=e.state.selection,r=e.state.doc.resolve(n.before()-1),o=[];r.node().descendants((e,n)=>{e.type.name===t&&o.push({node:e,pos:n})});const i=o.at(-1);if(!i)return!1;const a=e.state.doc.resolve(r.start()+i.pos+1);return e.chain().cut({from:n.start()-1,to:n.end()+1},a.end()).joinForward().run()}if(!El(e.state,t))return!1;if(!(e=>{const{$from:t,$to:n}=e.selection;return!(t.parentOffset>0||t.pos!==n.pos)})(e.state))return!1;const r=op(t,e.state);if(!r)return!1;const o=e.state.doc.resolve(r.$pos.pos-2).node(r.depth),i=sp(t,e.state,o);return lp(t,e.state)&&!i?e.commands.joinItemBackward():e.chain().liftListItem(t).run()},dp=(e,t)=>{const n=ip(e,t),r=op(e,t);return!(!r||!n)&&n>r.depth},up=(e,t)=>{const n=ip(e,t),r=op(e,t);return!(!r||!n)&&n<r.depth},pp=(e,t)=>{if(!El(e.state,t))return!1;if(!((e,t)=>{const{$from:n,$to:r,$anchor:o}=e.selection;if(t){const n=jl(e=>e.type.name===t)(e.selection);if(!n)return!1;const r=e.doc.resolve(n.pos+1);return o.pos+1===r.end()}return!(r.parentOffset<r.parent.nodeSize-2||n.pos!==r.pos)})(e.state,t))return!1;const{selection:n}=e.state,{$from:r,$to:o}=n;return!(!n.empty&&r.sameParent(o))&&(dp(t,e.state)?e.chain().focus(e.state.selection.from+4).lift(t).joinBackward().run():up(t,e.state)?e.chain().joinForward().joinBackward().run():e.commands.joinItemForward())},hp=(e,t)=>{var n;const{$anchor:r}=t.selection,o=t.doc.resolve(r.pos-r.parentOffset-2);return o.index()!==o.parent.childCount-1&&(null==(n=o.nodeAfter)?void 0:n.type.name)===e},mp=Os.create({name:"listKeymap",addOptions:()=>({listTypes:[{itemName:"listItem",wrapperNames:["bulletList","orderedList"]},{itemName:"taskItem",wrapperNames:["taskList"]}]}),addKeyboardShortcuts(){return{Delete:({editor:e})=>{let t=!1;return this.options.listTypes.forEach(({itemName:n})=>{void 0!==e.state.schema.nodes[n]&&pp(e,n)&&(t=!0)}),t},"Mod-Delete":({editor:e})=>{let t=!1;return this.options.listTypes.forEach(({itemName:n})=>{void 0!==e.state.schema.nodes[n]&&pp(e,n)&&(t=!0)}),t},Backspace:({editor:e})=>{let t=!1;return this.options.listTypes.forEach(({itemName:n,wrapperNames:r})=>{void 0!==e.state.schema.nodes[n]&&cp(e,n,r)&&(t=!0)}),t},"Mod-Backspace":({editor:e})=>{let t=!1;return this.options.listTypes.forEach(({itemName:n,wrapperNames:r})=>{void 0!==e.state.schema.nodes[n]&&cp(e,n,r)&&(t=!0)}),t}}}}),fp=/^(\s*)(\d+)\.\s+(.*)$/,gp=/^\s/;function vp(e,t,n){var r;const o=[];let i=0;for(;i<e.length;){const a=e[i];if(a.indent===t){const l=a.content.split("\n"),s=(null==(r=l[0])?void 0:r.trim())||"",c=[];s&&c.push({type:"paragraph",raw:s,tokens:n.inlineTokens(s)});const d=l.slice(1).join("\n").trim();if(d){const e=n.blockTokens(d);c.push(...e)}let u=i+1;const p=[];for(;u<e.length&&e[u].indent>t;)p.push(e[u]),u+=1;if(p.length>0){const e=Math.min(...p.map(e=>e.indent)),t=vp(p,e,n);c.push({type:"list",ordered:!0,start:p[0].number,items:t,raw:p.map(e=>e.raw).join("\n")})}o.push({type:"list_item",raw:a.raw,tokens:c}),i=u}else i+=1}return o}var yp="textStyle",bp=/^(\d+)\.\s$/,wp=oc.create({name:"orderedList",addOptions:()=>({itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}),group:"block list",content(){return`${this.options.itemTypeName}+`},addAttributes:()=>({start:{default:1,parseHTML:e=>e.hasAttribute("start")?parseInt(e.getAttribute("start")||"",10):1},type:{default:null,parseHTML:e=>e.getAttribute("type")}}),parseHTML:()=>[{tag:"ol"}],renderHTML({HTMLAttributes:e}){const{start:t,...n}=e;return 1===t?["ol",Wl(this.options.HTMLAttributes,n),0]:["ol",Wl(this.options.HTMLAttributes,e),0]},markdownTokenName:"list",parseMarkdown:(e,t)=>{if("list"!==e.type||!e.ordered)return[];const n=e.start||1,r=e.items?function(e,t){return e.map(e=>{if("list_item"!==e.type)return t.parseChildren([e])[0];const n=[];return e.tokens&&e.tokens.length>0&&e.tokens.forEach(e=>{if("paragraph"===e.type||"list"===e.type||"blockquote"===e.type||"code"===e.type)n.push(...t.parseChildren([e]));else if("text"===e.type&&e.tokens){const r=t.parseChildren([e]);n.push({type:"paragraph",content:r})}else{const r=t.parseChildren([e]);r.length>0&&n.push(...r)}}),{type:"listItem",content:n}})}(e.items,t):[];return 1!==n?{type:"orderedList",attrs:{start:n},content:r}:{type:"orderedList",content:r}},renderMarkdown:(e,t)=>e.content?t.renderChildren(e.content,"\n"):"",markdownTokenizer:{name:"orderedList",level:"block",start:e=>{const t=e.match(/^(\s*)(\d+)\.\s+/),n=null==t?void 0:t.index;return void 0!==n?n:-1},tokenize:(e,t,n)=>{var r;const o=e.split("\n"),[i,a]=function(e){const t=[];let n=0,r=0;for(;n<e.length;){const o=e[n],i=o.match(fp);if(!i)break;const[,a,l,s]=i,c=a.length;let d=s,u=n+1;const p=[o];for(;u<e.length;){const t=e[u];if(t.match(fp))break;if(""===t.trim())p.push(t),d+="\n",u+=1;else{if(!t.match(gp))break;p.push(t),d+=`\n${t.slice(c+2)}`,u+=1}}t.push({indent:c,number:parseInt(l,10),content:d.trim(),raw:p.join("\n")}),r=u,n=u}return[t,r]}(o);if(0===i.length)return;const l=vp(i,0,n);if(0===l.length)return;return{type:"list",ordered:!0,start:(null==(r=i[0])?void 0:r.number)||1,items:l,raw:o.slice(0,a).join("\n")}}},markdownOptions:{indentsContent:!0},addCommands(){return{toggleOrderedList:()=>({commands:e,chain:t})=>this.options.keepAttributes?t().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes("listItem",this.editor.getAttributes(yp)).run():e.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-7":()=>this.editor.commands.toggleOrderedList()}},addInputRules(){let e=Ws({find:bp,type:this.type,getAttributes:e=>({start:+e[1]}),joinPredicate:(e,t)=>t.childCount+t.attrs.start===+e[1]});return(this.options.keepMarks||this.options.keepAttributes)&&(e=Ws({find:bp,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:e=>({start:+e[1],...this.editor.getAttributes(yp)}),joinPredicate:(e,t)=>t.childCount+t.attrs.start===+e[1],editor:this.editor})),[e]}}),kp=/^\s*(\[([( |x])?\])\s$/,xp=oc.create({name:"taskItem",addOptions:()=>({nested:!1,HTMLAttributes:{},taskListTypeName:"taskList",a11y:void 0}),content(){return this.options.nested?"paragraph block*":"paragraph+"},defining:!0,addAttributes:()=>({checked:{default:!1,keepOnSplit:!1,parseHTML:e=>{const t=e.getAttribute("data-checked");return""===t||"true"===t},renderHTML:e=>({"data-checked":e.checked})}}),parseHTML(){return[{tag:`li[data-type="${this.name}"]`,priority:51}]},renderHTML({node:e,HTMLAttributes:t}){return["li",Wl(this.options.HTMLAttributes,t,{"data-type":this.name}),["label",["input",{type:"checkbox",checked:e.attrs.checked?"checked":null}],["span"]],["div",0]]},parseMarkdown:(e,t)=>{const n=[];if(e.tokens&&e.tokens.length>0?n.push(t.createNode("paragraph",{},t.parseInline(e.tokens))):e.text?n.push(t.createNode("paragraph",{},[t.createNode("text",{text:e.text})])):n.push(t.createNode("paragraph",{},[])),e.nestedTokens&&e.nestedTokens.length>0){const r=t.parseChildren(e.nestedTokens);n.push(...r)}return t.createNode("taskItem",{checked:e.checked||!1},n)},renderMarkdown:(e,t)=>{var n;return rc(e,t,`- [${(null==(n=e.attrs)?void 0:n.checked)?"x":" "}] `)},addKeyboardShortcuts(){const e={Enter:()=>this.editor.commands.splitListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)};return this.options.nested?{...e,Tab:()=>this.editor.commands.sinkListItem(this.name)}:e},addNodeView(){return({node:e,HTMLAttributes:t,getPos:n,editor:r})=>{const o=document.createElement("li"),i=document.createElement("label"),a=document.createElement("span"),l=document.createElement("input"),s=document.createElement("div"),c=e=>{var t,n;l.ariaLabel=(null==(n=null==(t=this.options.a11y)?void 0:t.checkboxLabel)?void 0:n.call(t,e,l.checked))||`Task item checkbox for ${e.textContent||"empty task item"}`};c(e),i.contentEditable="false",l.type="checkbox",l.addEventListener("mousedown",e=>e.preventDefault()),l.addEventListener("change",t=>{if(!r.isEditable&&!this.options.onReadOnlyChecked)return void(l.checked=!l.checked);const{checked:o}=t.target;r.isEditable&&"function"==typeof n&&r.chain().focus(void 0,{scrollIntoView:!1}).command(({tr:e})=>{const t=n();if("number"!=typeof t)return!1;const r=e.doc.nodeAt(t);return e.setNodeMarkup(t,void 0,{...null==r?void 0:r.attrs,checked:o}),!0}).run(),!r.isEditable&&this.options.onReadOnlyChecked&&(this.options.onReadOnlyChecked(e,o)||(l.checked=!l.checked))}),Object.entries(this.options.HTMLAttributes).forEach(([e,t])=>{o.setAttribute(e,t)}),o.dataset.checked=e.attrs.checked,l.checked=e.attrs.checked,i.append(l,a),o.append(i,s),Object.entries(t).forEach(([e,t])=>{o.setAttribute(e,t)});let d=new Set(Object.keys(t));return{dom:o,contentDOM:s,update:e=>{if(e.type!==this.type)return!1;o.dataset.checked=e.attrs.checked,l.checked=e.attrs.checked,c(e);const t=function(e,t){return t.filter(t=>t.type===e.type.name).filter(e=>e.attribute.rendered).map(t=>t.attribute.renderHTML?t.attribute.renderHTML(e.attrs)||{}:{[t.name]:e.attrs[t.name]}).reduce((e,t)=>Wl(e,t),{})}(e,r.extensionManager.attributes),n=new Set(Object.keys(t)),i=this.options.HTMLAttributes;return d.forEach(e=>{n.has(e)||(e in i?o.setAttribute(e,i[e]):o.removeAttribute(e))}),Object.entries(t).forEach(([e,t])=>{null==t?e in i?o.setAttribute(e,i[e]):o.removeAttribute(e):o.setAttribute(e,t)}),d=n,!0}}}},addInputRules(){return[Ws({find:kp,type:this.type,getAttributes:e=>({checked:"x"===e[e.length-1]})})]}}),_p=oc.create({name:"taskList",addOptions:()=>({itemTypeName:"taskItem",HTMLAttributes:{}}),group:"block list",content(){return`${this.options.itemTypeName}+`},parseHTML(){return[{tag:`ul[data-type="${this.name}"]`,priority:51}]},renderHTML({HTMLAttributes:e}){return["ul",Wl(this.options.HTMLAttributes,e,{"data-type":this.name}),0]},parseMarkdown:(e,t)=>t.createNode("taskList",{},t.parseChildren(e.items||[])),renderMarkdown:(e,t)=>e.content?t.renderChildren(e.content,"\n"):"",markdownTokenizer:{name:"taskList",level:"block",start(e){var t;const n=null==(t=e.match(/^\s*[-+*]\s+\[([ xX])\]\s+/))?void 0:t.index;return void 0!==n?n:-1},tokenize(e,t,n){const r=e=>{const t=nc(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:"x"===e[3].toLowerCase()}),createToken:(e,t)=>({type:"taskItem",raw:"",mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:r},n);return t?[{type:"taskList",raw:t.raw,items:t.items}]:n.blockTokens(e)},o=nc(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:"x"===e[3].toLowerCase()}),createToken:(e,t)=>({type:"taskItem",raw:"",mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:r},n);if(o)return{type:"taskList",raw:o.raw,items:o.items}}},markdownOptions:{indentsContent:!0},addCommands(){return{toggleTaskList:()=>({commands:e})=>e.toggleList(this.name,this.options.itemTypeName)}},addKeyboardShortcuts(){return{"Mod-Shift-9":()=>this.editor.commands.toggleTaskList()}}});Os.create({name:"listKit",addExtensions(){const e=[];return!1!==this.options.bulletList&&e.push(np.configure(this.options.bulletList)),!1!==this.options.listItem&&e.push(rp.configure(this.options.listItem)),!1!==this.options.listKeymap&&e.push(mp.configure(this.options.listKeymap)),!1!==this.options.orderedList&&e.push(wp.configure(this.options.orderedList)),!1!==this.options.taskItem&&e.push(xp.configure(this.options.taskItem)),!1!==this.options.taskList&&e.push(_p.configure(this.options.taskList)),e}});var Cp=" ",Ep=oc.create({name:"paragraph",priority:1e3,addOptions:()=>({HTMLAttributes:{}}),group:"block",content:"inline*",parseHTML:()=>[{tag:"p"}],renderHTML({HTMLAttributes:e}){return["p",Wl(this.options.HTMLAttributes,e),0]},parseMarkdown:(e,t)=>{const n=e.tokens||[];if(1===n.length&&"image"===n[0].type)return t.parseChildren([n[0]]);const r=t.parseInline(n);return 1!==r.length||"text"!==r[0].type||r[0].text!==Cp&&" "!==r[0].text?t.createNode("paragraph",void 0,r):t.createNode("paragraph",void 0,[])},renderMarkdown:(e,t)=>{if(!e)return"";const n=Array.isArray(e.content)?e.content:[];return 0===n.length?Cp:t.renderChildren(n)},addCommands(){return{setParagraph:()=>({commands:e})=>e.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}}),Sp=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))$/,Bp=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))/g,Np=As.create({name:"strike",addOptions:()=>({HTMLAttributes:{}}),parseHTML:()=>[{tag:"s"},{tag:"del"},{tag:"strike"},{style:"text-decoration",consuming:!1,getAttrs:e=>!!e.includes("line-through")&&{}}],renderHTML({HTMLAttributes:e}){return["s",Wl(this.options.HTMLAttributes,e),0]},markdownTokenName:"del",parseMarkdown:(e,t)=>t.applyMark("strike",t.parseInline(e.tokens||[])),renderMarkdown:(e,t)=>`~~${t.renderChildren(e)}~~`,addCommands(){return{setStrike:()=>({commands:e})=>e.setMark(this.name),toggleStrike:()=>({commands:e})=>e.toggleMark(this.name),unsetStrike:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-s":()=>this.editor.commands.toggleStrike()}},addInputRules(){return[qs({find:Sp,type:this.type})]},addPasteRules(){return[ac({find:Bp,type:this.type})]}}),Mp=oc.create({name:"text",group:"inline",parseMarkdown:e=>({type:"text",text:e.text||""}),renderMarkdown:e=>e.text||""}),Tp=As.create({name:"underline",addOptions:()=>({HTMLAttributes:{}}),parseHTML:()=>[{tag:"u"},{style:"text-decoration",consuming:!1,getAttrs:e=>!!e.includes("underline")&&{}}],renderHTML({HTMLAttributes:e}){return["u",Wl(this.options.HTMLAttributes,e),0]},parseMarkdown(e,t){return t.applyMark(this.name||"underline",t.parseInline(e.tokens||[]))},renderMarkdown:(e,t)=>`++${t.renderChildren(e)}++`,markdownTokenizer:{name:"underline",level:"inline",start:e=>e.indexOf("++"),tokenize(e,t,n){const r=/^(\+\+)([\s\S]+?)(\+\+)/.exec(e);if(!r)return;const o=r[2].trim();return{type:"underline",raw:r[0],text:o,tokens:n.inlineTokens(o)}}},addCommands(){return{setUnderline:()=>({commands:e})=>e.setMark(this.name),toggleUnderline:()=>({commands:e})=>e.toggleMark(this.name),unsetUnderline:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-u":()=>this.editor.commands.toggleUnderline(),"Mod-U":()=>this.editor.commands.toggleUnderline()}}});function Vp(e={}){return new to({view:t=>new Ap(t,e)})}class Ap{constructor(e,t){var n;this.editorView=e,this.cursorPos=null,this.element=null,this.timeout=-1,this.width=null!==(n=t.width)&&void 0!==n?n:1,this.color=!1===t.color?void 0:t.color||"black",this.class=t.class,this.handlers=["dragover","dragend","drop","dragleave"].map(t=>{let n=e=>{this[t](e)};return e.dom.addEventListener(t,n),{name:t,handler:n}})}destroy(){this.handlers.forEach(({name:e,handler:t})=>this.editorView.dom.removeEventListener(e,t))}update(e,t){null!=this.cursorPos&&t.doc!=e.state.doc&&(this.cursorPos>e.state.doc.content.size?this.setCursor(null):this.updateOverlay())}setCursor(e){e!=this.cursorPos&&(this.cursorPos=e,null==e?(this.element.parentNode.removeChild(this.element),this.element=null):this.updateOverlay())}updateOverlay(){let e,t=this.editorView.state.doc.resolve(this.cursorPos),n=!t.parent.inlineContent,r=this.editorView.dom,o=r.getBoundingClientRect(),i=o.width/r.offsetWidth,a=o.height/r.offsetHeight;if(n){let n=t.nodeBefore,r=t.nodeAfter;if(n||r){let t=this.editorView.nodeDOM(this.cursorPos-(n?n.nodeSize:0));if(t){let o=t.getBoundingClientRect(),i=n?o.bottom:o.top;n&&r&&(i=(i+this.editorView.nodeDOM(this.cursorPos).getBoundingClientRect().top)/2);let l=this.width/2*a;e={left:o.left,right:o.right,top:i-l,bottom:i+l}}}}if(!e){let t=this.editorView.coordsAtPos(this.cursorPos),n=this.width/2*i;e={left:t.left-n,right:t.left+n,top:t.top,bottom:t.bottom}}let l,s,c=this.editorView.dom.offsetParent;if(this.element||(this.element=c.appendChild(document.createElement("div")),this.class&&(this.element.className=this.class),this.element.style.cssText="position: absolute; z-index: 50; pointer-events: none;",this.color&&(this.element.style.backgroundColor=this.color)),this.element.classList.toggle("prosemirror-dropcursor-block",n),this.element.classList.toggle("prosemirror-dropcursor-inline",!n),!c||c==document.body&&"static"==getComputedStyle(c).position)l=-pageXOffset,s=-pageYOffset;else{let e=c.getBoundingClientRect(),t=e.width/c.offsetWidth,n=e.height/c.offsetHeight;l=e.left-c.scrollLeft*t,s=e.top-c.scrollTop*n}this.element.style.left=(e.left-l)/i+"px",this.element.style.top=(e.top-s)/a+"px",this.element.style.width=(e.right-e.left)/i+"px",this.element.style.height=(e.bottom-e.top)/a+"px"}scheduleRemoval(e){clearTimeout(this.timeout),this.timeout=setTimeout(()=>this.setCursor(null),e)}dragover(e){if(!this.editorView.editable)return;let t=this.editorView.posAtCoords({left:e.clientX,top:e.clientY}),n=t&&t.inside>=0&&this.editorView.state.doc.nodeAt(t.inside),r=n&&n.type.spec.disableDropCursor,o="function"==typeof r?r(this.editorView,t,e):r;if(t&&!o){let e=t.pos;if(this.editorView.dragging&&this.editorView.dragging.slice){let t=_r(this.editorView.state.doc,e,this.editorView.dragging.slice);null!=t&&(e=t)}this.setCursor(e),this.scheduleRemoval(5e3)}}dragend(){this.scheduleRemoval(20)}drop(){this.scheduleRemoval(20)}dragleave(e){this.editorView.dom.contains(e.relatedTarget)||this.setCursor(null)}}class zp extends Rr{constructor(e){super(e,e)}map(e,t){let n=e.resolve(t.map(this.head));return zp.valid(n)?new zp(n):Rr.near(n)}content(){return Zt.empty}eq(e){return e instanceof zp&&e.head==this.head}toJSON(){return{type:"gapcursor",pos:this.head}}static fromJSON(e,t){if("number"!=typeof t.pos)throw new RangeError("Invalid input for GapCursor.fromJSON");return new zp(e.resolve(t.pos))}getBookmark(){return new Op(this.anchor)}static valid(e){let t=e.parent;if(t.isTextblock||!function(e){for(let t=e.depth;t>=0;t--){let n=e.index(t),r=e.node(t);if(0!=n)for(let e=r.child(n-1);;e=e.lastChild){if(0==e.childCount&&!e.inlineContent||Ip(e.type))return!0;if(e.inlineContent)return!1}else if(r.type.spec.isolating)return!0}return!0}(e)||!function(e){for(let t=e.depth;t>=0;t--){let n=e.indexAfter(t),r=e.node(t);if(n!=r.childCount)for(let e=r.child(n);;e=e.firstChild){if(0==e.childCount&&!e.inlineContent||Ip(e.type))return!0;if(e.inlineContent)return!1}else if(r.type.spec.isolating)return!0}return!0}(e))return!1;let n=t.type.spec.allowGapCursor;if(null!=n)return n;let r=t.contentMatchAt(e.index()).defaultType;return r&&r.isTextblock}static findGapCursorFrom(e,t,n=!1){e:for(;;){if(!n&&zp.valid(e))return e;let r=e.pos,o=null;for(let n=e.depth;;n--){let i=e.node(n);if(t>0?e.indexAfter(n)<i.childCount:e.index(n)>0){o=i.child(t>0?e.indexAfter(n):e.index(n)-1);break}if(0==n)return null;r+=t;let a=e.doc.resolve(r);if(zp.valid(a))return a}for(;;){let i=t>0?o.firstChild:o.lastChild;if(!i){if(o.isAtom&&!o.isText&&!qr.isSelectable(o)){e=e.doc.resolve(r+o.nodeSize*t),n=!1;continue e}break}o=i,r+=t;let a=e.doc.resolve(r);if(zp.valid(a))return a}return null}}}zp.prototype.visible=!1,zp.findFrom=zp.findGapCursorFrom,Rr.jsonID("gapcursor",zp);class Op{constructor(e){this.pos=e}map(e){return new Op(e.map(this.pos))}resolve(e){let t=e.resolve(this.pos);return zp.valid(t)?new zp(t):Rr.near(t)}}function Ip(e){return e.isAtom||e.spec.isolating||e.spec.createGapCursor}const Dp=function(e){let t=function(e){let t=Object.create(null);for(let n in e)t[Va(n)]=e[n];return t}(e);return function(e,n){let r,o=function(e){var t=!(Ea&&e.metaKey&&e.shiftKey&&!e.ctrlKey&&!e.altKey||Sa&&e.shiftKey&&e.key&&1==e.key.length||"Unidentified"==e.key)&&e.key||(e.shiftKey?Ca:_a)[e.keyCode]||e.key||"Unidentified";return"Esc"==t&&(t="Escape"),"Del"==t&&(t="Delete"),"Left"==t&&(t="ArrowLeft"),"Up"==t&&(t="ArrowUp"),"Right"==t&&(t="ArrowRight"),"Down"==t&&(t="ArrowDown"),t}(n),i=t[Aa(o,n)];if(i&&i(e.state,e.dispatch,e))return!0;if(1==o.length&&" "!=o){if(n.shiftKey){let r=t[Aa(o,n,!1)];if(r&&r(e.state,e.dispatch,e))return!0}if((n.altKey||n.metaKey||n.ctrlKey)&&!(Ta&&n.ctrlKey&&n.altKey)&&(r=_a[n.keyCode])&&r!=o){let o=t[Aa(r,n)];if(o&&o(e.state,e.dispatch,e))return!0}}return!1}}({ArrowLeft:Pp("horiz",-1),ArrowRight:Pp("horiz",1),ArrowUp:Pp("vert",-1),ArrowDown:Pp("vert",1)});function Pp(e,t){const n="vert"==e?t>0?"down":"up":t>0?"right":"left";return function(e,r,o){let i=e.selection,a=t>0?i.$to:i.$from,l=i.empty;if(i instanceof Ur){if(!o.endOfTextblock(n)||0==a.depth)return!1;l=!1,a=e.doc.resolve(t>0?a.after():a.before())}let s=zp.findGapCursorFrom(a,t,l);return!!s&&(r&&r(e.tr.setSelection(new zp(s))),!0)}}function $p(e,t,n){if(!e||!e.editable)return!1;let r=e.state.doc.resolve(t);if(!zp.valid(r))return!1;let o=e.posAtCoords({left:n.clientX,top:n.clientY});return!(o&&o.inside>-1&&qr.isSelectable(e.state.doc.nodeAt(o.inside)))&&(e.dispatch(e.state.tr.setSelection(new zp(r))),!0)}function Lp(e,t){if("insertCompositionText"!=t.inputType||!(e.state.selection instanceof zp))return!1;let{$from:n}=e.state.selection,r=n.parent.contentMatchAt(n.index()).findWrapping(e.state.schema.nodes.text);if(!r)return!1;let o=Ht.empty;for(let a=r.length-1;a>=0;a--)o=Ht.from(r[a].createAndFill(null,o));let i=e.state.tr.replace(n.pos,n.pos,new Zt(o,0,0));return i.setSelection(Ur.near(i.doc.resolve(n.pos+1))),e.dispatch(i),!1}function Rp(e){if(!(e.selection instanceof zp))return null;let t=document.createElement("div");return t.className="ProseMirror-gapcursor",ha.create(e.doc,[da.widget(e.selection.head,t,{key:"gapcursor"})])}var Hp=200,Fp=function(){};Fp.prototype.append=function(e){return e.length?(e=Fp.from(e),!this.length&&e||e.length<Hp&&this.leafAppend(e)||this.length<Hp&&e.leafPrepend(this)||this.appendInner(e)):this},Fp.prototype.prepend=function(e){return e.length?Fp.from(e).append(this):this},Fp.prototype.appendInner=function(e){return new Up(this,e)},Fp.prototype.slice=function(e,t){return void 0===e&&(e=0),void 0===t&&(t=this.length),e>=t?Fp.empty:this.sliceInner(Math.max(0,e),Math.min(this.length,t))},Fp.prototype.get=function(e){if(!(e<0||e>=this.length))return this.getInner(e)},Fp.prototype.forEach=function(e,t,n){void 0===t&&(t=0),void 0===n&&(n=this.length),t<=n?this.forEachInner(e,t,n,0):this.forEachInvertedInner(e,t,n,0)},Fp.prototype.map=function(e,t,n){void 0===t&&(t=0),void 0===n&&(n=this.length);var r=[];return this.forEach(function(t,n){return r.push(e(t,n))},t,n),r},Fp.from=function(e){return e instanceof Fp?e:e&&e.length?new jp(e):Fp.empty};var jp=function(e){function t(t){e.call(this),this.values=t}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={length:{configurable:!0},depth:{configurable:!0}};return t.prototype.flatten=function(){return this.values},t.prototype.sliceInner=function(e,n){return 0==e&&n==this.length?this:new t(this.values.slice(e,n))},t.prototype.getInner=function(e){return this.values[e]},t.prototype.forEachInner=function(e,t,n,r){for(var o=t;o<n;o++)if(!1===e(this.values[o],r+o))return!1},t.prototype.forEachInvertedInner=function(e,t,n,r){for(var o=t-1;o>=n;o--)if(!1===e(this.values[o],r+o))return!1},t.prototype.leafAppend=function(e){if(this.length+e.length<=Hp)return new t(this.values.concat(e.flatten()))},t.prototype.leafPrepend=function(e){if(this.length+e.length<=Hp)return new t(e.flatten().concat(this.values))},n.length.get=function(){return this.values.length},n.depth.get=function(){return 0},Object.defineProperties(t.prototype,n),t}(Fp);Fp.empty=new jp([]);var Up=function(e){function t(t,n){e.call(this),this.left=t,this.right=n,this.length=t.length+n.length,this.depth=Math.max(t.depth,n.depth)+1}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.flatten=function(){return this.left.flatten().concat(this.right.flatten())},t.prototype.getInner=function(e){return e<this.left.length?this.left.get(e):this.right.get(e-this.left.length)},t.prototype.forEachInner=function(e,t,n,r){var o=this.left.length;return!(t<o&&!1===this.left.forEachInner(e,t,Math.min(n,o),r))&&(!(n>o&&!1===this.right.forEachInner(e,Math.max(t-o,0),Math.min(this.length,n)-o,r+o))&&void 0)},t.prototype.forEachInvertedInner=function(e,t,n,r){var o=this.left.length;return!(t>o&&!1===this.right.forEachInvertedInner(e,t-o,Math.max(n,o)-o,r+o))&&(!(n<o&&!1===this.left.forEachInvertedInner(e,Math.min(t,o),n,r))&&void 0)},t.prototype.sliceInner=function(e,t){if(0==e&&t==this.length)return this;var n=this.left.length;return t<=n?this.left.slice(e,t):e>=n?this.right.slice(e-n,t-n):this.left.slice(e,n).append(this.right.slice(0,t-n))},t.prototype.leafAppend=function(e){var n=this.right.leafAppend(e);if(n)return new t(this.left,n)},t.prototype.leafPrepend=function(e){var n=this.left.leafPrepend(e);if(n)return new t(n,this.right)},t.prototype.appendInner=function(e){return this.left.depth>=Math.max(this.right.depth,e.depth)+1?new t(this.left,new t(this.right,e)):new t(this,e)},t}(Fp);class Gp{constructor(e,t){this.items=e,this.eventCount=t}popEvent(e,t){if(0==this.eventCount)return null;let n,r,o=this.items.length;for(;;o--){if(this.items.get(o-1).selection){--o;break}}t&&(n=this.remapping(o,this.items.length),r=n.maps.length);let i,a,l=e.tr,s=[],c=[];return this.items.forEach((e,t)=>{if(!e.step)return n||(n=this.remapping(o,t+1),r=n.maps.length),r--,void c.push(e);if(n){c.push(new qp(e.map));let t,o=e.step.map(n.slice(r));o&&l.maybeStep(o).doc&&(t=l.mapping.maps[l.mapping.maps.length-1],s.push(new qp(t,void 0,void 0,s.length+c.length))),r--,t&&n.appendMap(t,r)}else l.maybeStep(e.step);return e.selection?(i=n?e.selection.map(n.slice(r)):e.selection,a=new Gp(this.items.slice(0,o).append(c.reverse().concat(s)),this.eventCount-1),!1):void 0},this.items.length,0),{remaining:a,transform:l,selection:i}}addTransform(e,t,n,r){let o=[],i=this.eventCount,a=this.items,l=!r&&a.length?a.get(a.length-1):null;for(let c=0;c<e.steps.length;c++){let n,s=e.steps[c].invert(e.docs[c]),d=new qp(e.mapping.maps[c],s,t);(n=l&&l.merge(d))&&(d=n,c?o.pop():a=a.slice(0,a.length-1)),o.push(d),t&&(i++,t=void 0),r||(l=d)}let s=i-n.depth;return s>Wp&&(a=function(e,t){let n;return e.forEach((e,r)=>{if(e.selection&&0==t--)return n=r,!1}),e.slice(n)}(a,s),i-=s),new Gp(a.append(o),i)}remapping(e,t){let n=new er;return this.items.forEach((t,r)=>{let o=null!=t.mirrorOffset&&r-t.mirrorOffset>=e?n.maps.length-t.mirrorOffset:void 0;n.appendMap(t.map,o)},e,t),n}addMaps(e){return 0==this.eventCount?this:new Gp(this.items.append(e.map(e=>new qp(e))),this.eventCount)}rebased(e,t){if(!this.eventCount)return this;let n=[],r=Math.max(0,this.items.length-t),o=e.mapping,i=e.steps.length,a=this.eventCount;this.items.forEach(e=>{e.selection&&a--},r);let l=t;this.items.forEach(t=>{let r=o.getMirror(--l);if(null==r)return;i=Math.min(i,r);let s=o.maps[r];if(t.step){let i=e.steps[r].invert(e.docs[r]),c=t.selection&&t.selection.map(o.slice(l+1,r));c&&a++,n.push(new qp(s,i,c))}else n.push(new qp(s))},r);let s=[];for(let u=t;u<i;u++)s.push(new qp(o.maps[u]));let c=this.items.slice(0,r).append(s).append(n),d=new Gp(c,a);return d.emptyItemCount()>500&&(d=d.compress(this.items.length-n.length)),d}emptyItemCount(){let e=0;return this.items.forEach(t=>{t.step||e++}),e}compress(e=this.items.length){let t=this.remapping(0,e),n=t.maps.length,r=[],o=0;return this.items.forEach((i,a)=>{if(a>=e)r.push(i),i.selection&&o++;else if(i.step){let e=i.step.map(t.slice(n)),a=e&&e.getMap();if(n--,a&&t.appendMap(a,n),e){let l=i.selection&&i.selection.map(t.slice(n));l&&o++;let s,c=new qp(a.invert(),e,l),d=r.length-1;(s=r.length&&r[d].merge(c))?r[d]=s:r.push(c)}}else i.map&&n--},this.items.length,0),new Gp(Fp.from(r.reverse()),o)}}Gp.empty=new Gp(Fp.empty,0);let qp=class e{constructor(e,t,n,r){this.map=e,this.step=t,this.selection=n,this.mirrorOffset=r}merge(t){if(this.step&&t.step&&!t.selection){let n=t.step.merge(this.step);if(n)return new e(n.getMap().invert(),n,this.selection)}}};class Zp{constructor(e,t,n,r,o){this.done=e,this.undone=t,this.prevRanges=n,this.prevTime=r,this.prevComposition=o}}const Wp=20;function Kp(e){let t=[];for(let n=e.length-1;n>=0&&0==t.length;n--)e[n].forEach((e,n,r,o)=>t.push(r,o));return t}function Jp(e,t){if(!e)return null;let n=[];for(let r=0;r<e.length;r+=2){let o=t.map(e[r],1),i=t.map(e[r+1],-1);o<=i&&n.push(o,i)}return n}let Yp=!1,Xp=null;function Qp(e){let t=e.plugins;if(Xp!=t){Yp=!1,Xp=t;for(let e=0;e<t.length;e++)if(t[e].spec.historyPreserveItems){Yp=!0;break}}return Yp}const eh=new oo("history"),th=new oo("closeHistory");function nh(e={}){return e={depth:e.depth||100,newGroupDelay:e.newGroupDelay||500},new to({key:eh,state:{init:()=>new Zp(Gp.empty,Gp.empty,null,0,-1),apply:(t,n,r)=>function(e,t,n,r){let o,i=n.getMeta(eh);if(i)return i.historyState;n.getMeta(th)&&(e=new Zp(e.done,e.undone,null,0,-1));let a=n.getMeta("appendedTransaction");if(0==n.steps.length)return e;if(a&&a.getMeta(eh))return a.getMeta(eh).redo?new Zp(e.done.addTransform(n,void 0,r,Qp(t)),e.undone,Kp(n.mapping.maps),e.prevTime,e.prevComposition):new Zp(e.done,e.undone.addTransform(n,void 0,r,Qp(t)),null,e.prevTime,e.prevComposition);if(!1===n.getMeta("addToHistory")||a&&!1===a.getMeta("addToHistory"))return(o=n.getMeta("rebased"))?new Zp(e.done.rebased(n,o),e.undone.rebased(n,o),Jp(e.prevRanges,n.mapping),e.prevTime,e.prevComposition):new Zp(e.done.addMaps(n.mapping.maps),e.undone.addMaps(n.mapping.maps),Jp(e.prevRanges,n.mapping),e.prevTime,e.prevComposition);{let o=n.getMeta("composition"),i=0==e.prevTime||!a&&e.prevComposition!=o&&(e.prevTime<(n.time||0)-r.newGroupDelay||!function(e,t){if(!t)return!1;if(!e.docChanged)return!0;let n=!1;return e.mapping.maps[0].forEach((e,r)=>{for(let o=0;o<t.length;o+=2)e<=t[o+1]&&r>=t[o]&&(n=!0)}),n}(n,e.prevRanges)),l=a?Jp(e.prevRanges,n.mapping):Kp(n.mapping.maps);return new Zp(e.done.addTransform(n,i?t.selection.getBookmark():void 0,r,Qp(t)),Gp.empty,l,n.time,null==o?e.prevComposition:o)}}(n,r,t,e)},config:e,props:{handleDOMEvents:{beforeinput(e,t){let n=t.inputType,r="historyUndo"==n?oh:"historyRedo"==n?ih:null;return!(!r||!e.editable)&&(t.preventDefault(),r(e.state,e.dispatch))}}}})}function rh(e,t){return(t,n)=>{let r=eh.getState(t);if(!r||0==(e?r.undone:r.done).eventCount)return!1;if(n){let o=function(e,t,n){let r=Qp(t),o=eh.get(t).spec.config,i=(n?e.undone:e.done).popEvent(t,r);if(!i)return null;let a=i.selection.resolve(i.transform.doc),l=(n?e.done:e.undone).addTransform(i.transform,t.selection.getBookmark(),o,r),s=new Zp(n?l:i.remaining,n?i.remaining:l,null,0,-1);return i.transform.setSelection(a).setMeta(eh,{redo:n,historyState:s})}(r,t,e);o&&n(o.scrollIntoView())}return!0}}const oh=rh(!1),ih=rh(!0);Os.create({name:"characterCount",addOptions:()=>({limit:null,mode:"textSize",textCounter:e=>e.length,wordCounter:e=>e.split(" ").filter(e=>""!==e).length}),addStorage:()=>({characters:()=>0,words:()=>0}),onBeforeCreate(){this.storage.characters=e=>{const t=(null==e?void 0:e.node)||this.editor.state.doc;if("textSize"===((null==e?void 0:e.mode)||this.options.mode)){const e=t.textBetween(0,t.content.size,void 0," ");return this.options.textCounter(e)}return t.nodeSize},this.storage.words=e=>{const t=(null==e?void 0:e.node)||this.editor.state.doc,n=t.textBetween(0,t.content.size," "," ");return this.options.wordCounter(n)}},addProseMirrorPlugins(){let e=!1;return[new to({key:new oo("characterCount"),appendTransaction:(t,n,r)=>{if(e)return;const o=this.options.limit;if(null==o||0===o)return void(e=!0);const i=this.storage.characters({node:r.doc});if(i>o){const t=0,n=i-o,a=r.tr.deleteRange(t,n);return e=!0,a}e=!0},filterTransaction:(e,t)=>{const n=this.options.limit;if(!e.docChanged||0===n||null==n)return!0;const r=this.storage.characters({node:t.doc}),o=this.storage.characters({node:e.doc});if(o<=n)return!0;if(r>n&&o>n&&o<=r)return!0;if(r>n&&o>n&&o>r)return!1;if(!e.getMeta("paste"))return!1;const i=e.selection.$head.pos,a=i-(o-n),l=i;e.deleteRange(a,l);return!(this.storage.characters({node:e.doc})>n)}})]}});var ah=Os.create({name:"dropCursor",addOptions:()=>({color:"currentColor",width:1,class:void 0}),addProseMirrorPlugins(){return[Vp(this.options)]}});Os.create({name:"focus",addOptions:()=>({className:"has-focus",mode:"all"}),addProseMirrorPlugins(){return[new to({key:new oo("focus"),props:{decorations:({doc:e,selection:t})=>{const{isEditable:n,isFocused:r}=this.editor,{anchor:o}=t,i=[];if(!n||!r)return ha.create(e,[]);let a=0;"deepest"===this.options.mode&&e.descendants((e,t)=>{if(e.isText)return;if(!(o>=t&&o<=t+e.nodeSize-1))return!1;a+=1});let l=0;return e.descendants((e,t)=>{if(e.isText)return!1;if(!(o>=t&&o<=t+e.nodeSize-1))return!1;l+=1;if("deepest"===this.options.mode&&a-l>0||"shallowest"===this.options.mode&&l>1)return"deepest"===this.options.mode;i.push(da.node(t,t+e.nodeSize,{class:this.options.className}))}),ha.create(e,i)}}})]}});var lh=Os.create({name:"gapCursor",addProseMirrorPlugins:()=>[new to({props:{decorations:Rp,createSelectionBetween:(e,t,n)=>t.pos==n.pos&&zp.valid(n)?new zp(n):null,handleClick:$p,handleKeyDown:Dp,handleDOMEvents:{beforeinput:Lp}}})],extendNodeSchema(e){var t;return{allowGapCursor:null!=(t=Gl(Ul(e,"allowGapCursor",{name:e.name,options:e.options,storage:e.storage})))?t:null}}}),sh="placeholder";function ch({types:e,node:t}){return t&&Array.isArray(e)&&e.includes(t.type)||(null==t?void 0:t.type)===e}Os.create({name:"placeholder",addOptions:()=>({emptyEditorClass:"is-editor-empty",emptyNodeClass:"is-empty",dataAttribute:sh,placeholder:"Write something …",showOnlyWhenEditable:!0,showOnlyCurrent:!0,includeChildren:!1}),addProseMirrorPlugins(){const e=this.options.dataAttribute?`data-${t=this.options.dataAttribute,t.replace(/\s+/g,"-").replace(/[^a-zA-Z0-9-]/g,"").replace(/^[0-9-]+/,"").replace(/^-+/,"").toLowerCase()}`:`data-${sh}`;var t;return[new to({key:new oo("placeholder"),props:{decorations:({doc:t,selection:n})=>{const r=this.editor.isEditable||!this.options.showOnlyWhenEditable,{anchor:o}=n,i=[];if(!r)return null;const a=this.editor.isEmpty;return t.descendants((t,n)=>{const r=o>=n&&o<=n+t.nodeSize,l=!t.isLeaf&&ts(t);if((r||!this.options.showOnlyCurrent)&&l){const o=[this.options.emptyNodeClass];a&&o.push(this.options.emptyEditorClass);const l=da.node(n,n+t.nodeSize,{class:o.join(" "),[e]:"function"==typeof this.options.placeholder?this.options.placeholder({editor:this.editor,node:t,pos:n,hasAnchor:r}):this.options.placeholder});i.push(l)}return this.options.includeChildren}),ha.create(t,i)}}})]}}),Os.create({name:"selection",addOptions:()=>({className:"selection"}),addProseMirrorPlugins(){const{editor:e,options:t}=this;return[new to({key:new oo("selection"),props:{decorations:n=>n.selection.empty||e.isFocused||!e.isEditable||ns(n.selection)||e.view.dragging?null:ha.create(n.doc,[da.inline(n.selection.from,n.selection.to,{class:t.className})])}})]}});var dh=Os.create({name:"trailingNode",addOptions:()=>({node:void 0,notAfter:[]}),addProseMirrorPlugins(){var e;const t=new oo(this.name),n=this.options.node||(null==(e=this.editor.schema.topNodeType.contentMatch.defaultType)?void 0:e.name)||"paragraph",r=Object.entries(this.editor.schema.nodes).map(([,e])=>e).filter(e=>(this.options.notAfter||[]).concat(n).includes(e.name));return[new to({key:t,appendTransaction:(e,r,o)=>{const{doc:i,tr:a,schema:l}=o,s=t.getState(o),c=i.content.size,d=l.nodes[n];if(s)return a.insert(c,d.create())},state:{init:(e,t)=>!ch({node:t.tr.doc.lastChild,types:r}),apply:(e,t)=>{if(!e.docChanged)return t;if(e.getMeta("__uniqueIDTransaction"))return t;return!ch({node:e.doc.lastChild,types:r})}}})]}}),uh=Os.create({name:"undoRedo",addOptions:()=>({depth:100,newGroupDelay:500}),addCommands:()=>({undo:()=>({state:e,dispatch:t})=>oh(e,t),redo:()=>({state:e,dispatch:t})=>ih(e,t)}),addProseMirrorPlugins(){return[nh(this.options)]},addKeyboardShortcuts(){return{"Mod-z":()=>this.editor.commands.undo(),"Shift-Mod-z":()=>this.editor.commands.redo(),"Mod-y":()=>this.editor.commands.redo(),"Mod-я":()=>this.editor.commands.undo(),"Shift-Mod-я":()=>this.editor.commands.redo()}}});Os.create({name:"starterKit",addExtensions(){var e,t,n,r;const o=[];return!1!==this.options.bold&&o.push(Lc.configure(this.options.bold)),!1!==this.options.blockquote&&o.push(Oc.configure(this.options.blockquote)),!1!==this.options.bulletList&&o.push(np.configure(this.options.bulletList)),!1!==this.options.code&&o.push(Fc.configure(this.options.code)),!1!==this.options.codeBlock&&o.push(Gc.configure(this.options.codeBlock)),!1!==this.options.document&&o.push(qc.configure(this.options.document)),!1!==this.options.dropcursor&&o.push(ah.configure(this.options.dropcursor)),!1!==this.options.gapcursor&&o.push(lh.configure(this.options.gapcursor)),!1!==this.options.hardBreak&&o.push(Zc.configure(this.options.hardBreak)),!1!==this.options.heading&&o.push(Wc.configure(this.options.heading)),!1!==this.options.undoRedo&&o.push(uh.configure(this.options.undoRedo)),!1!==this.options.horizontalRule&&o.push(Kc.configure(this.options.horizontalRule)),!1!==this.options.italic&&o.push(ed.configure(this.options.italic)),!1!==this.options.listItem&&o.push(rp.configure(this.options.listItem)),!1!==this.options.listKeymap&&o.push(mp.configure(null==(e=this.options)?void 0:e.listKeymap)),!1!==this.options.link&&o.push(Xu.configure(null==(t=this.options)?void 0:t.link)),!1!==this.options.orderedList&&o.push(wp.configure(this.options.orderedList)),!1!==this.options.paragraph&&o.push(Ep.configure(this.options.paragraph)),!1!==this.options.strike&&o.push(Np.configure(this.options.strike)),!1!==this.options.text&&o.push(Mp.configure(this.options.text)),!1!==this.options.underline&&o.push(Tp.configure(null==(n=this.options)?void 0:n.underline)),!1!==this.options.trailingNode&&o.push(dh.configure(null==(r=this.options)?void 0:r.trailingNode)),o}}),new oo("suggestion");const ph=Math.min,hh=Math.max,mh=Math.round,fh=Math.floor,gh=e=>({x:e,y:e}),vh={left:"right",right:"left",bottom:"top",top:"bottom"},yh={start:"end",end:"start"};function bh(e,t){return"function"==typeof e?e(t):e}function wh(e){return e.split("-")[0]}function kh(e){return e.split("-")[1]}function xh(e){return"y"===e?"height":"width"}const _h=new Set(["top","bottom"]);function Ch(e){return _h.has(wh(e))?"y":"x"}function Eh(e){return"x"===Ch(e)?"y":"x"}function Sh(e){return e.replace(/start|end/g,e=>yh[e])}const Bh=["left","right"],Nh=["right","left"],Mh=["top","bottom"],Th=["bottom","top"];function Vh(e,t,n,r){const o=kh(e);let i=function(e,t,n){switch(e){case"top":case"bottom":return n?t?Nh:Bh:t?Bh:Nh;case"left":case"right":return t?Mh:Th;default:return[]}}(wh(e),"start"===n,r);return o&&(i=i.map(e=>e+"-"+o),t&&(i=i.concat(i.map(Sh)))),i}function Ah(e){return e.replace(/left|right|bottom|top/g,e=>vh[e])}function zh(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function Oh(e,t,n){let{reference:r,floating:o}=e;const i=Ch(t),a=Eh(t),l=xh(a),s=wh(t),c="y"===i,d=r.x+r.width/2-o.width/2,u=r.y+r.height/2-o.height/2,p=r[l]/2-o[l]/2;let h;switch(s){case"top":h={x:d,y:r.y-o.height};break;case"bottom":h={x:d,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:u};break;case"left":h={x:r.x-o.width,y:u};break;default:h={x:r.x,y:r.y}}switch(kh(t)){case"start":h[a]-=p*(n&&c?-1:1);break;case"end":h[a]+=p*(n&&c?-1:1)}return h}async function Ih(e,t){var n;void 0===t&&(t={});const{x:r,y:o,platform:i,rects:a,elements:l,strategy:s}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:p=!1,padding:h=0}=bh(t,e),m=function(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}(h),f=l[p?"floating"===u?"reference":"floating":u],g=zh(await i.getClippingRect({element:null==(n=await(null==i.isElement?void 0:i.isElement(f)))||n?f:f.contextElement||await(null==i.getDocumentElement?void 0:i.getDocumentElement(l.floating)),boundary:c,rootBoundary:d,strategy:s})),v="floating"===u?{x:r,y:o,width:a.floating.width,height:a.floating.height}:a.reference,y=await(null==i.getOffsetParent?void 0:i.getOffsetParent(l.floating)),b=await(null==i.isElement?void 0:i.isElement(y))&&await(null==i.getScale?void 0:i.getScale(y))||{x:1,y:1},w=zh(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:v,offsetParent:y,strategy:s}):v);return{top:(g.top-w.top+m.top)/b.y,bottom:(w.bottom-g.bottom+m.bottom)/b.y,left:(g.left-w.left+m.left)/b.x,right:(w.right-g.right+m.right)/b.x}}const Dh=new Set(["left","top"]);function Ph(){return"undefined"!=typeof window}function $h(e){return Hh(e)?(e.nodeName||"").toLowerCase():"#document"}function Lh(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function Rh(e){var t;return null==(t=(Hh(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function Hh(e){return!!Ph()&&(e instanceof Node||e instanceof Lh(e).Node)}function Fh(e){return!!Ph()&&(e instanceof Element||e instanceof Lh(e).Element)}function jh(e){return!!Ph()&&(e instanceof HTMLElement||e instanceof Lh(e).HTMLElement)}function Uh(e){return!(!Ph()||"undefined"==typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof Lh(e).ShadowRoot)}const Gh=new Set(["inline","contents"]);function qh(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=om(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!Gh.has(o)}const Zh=new Set(["table","td","th"]);function Wh(e){return Zh.has($h(e))}const Kh=[":popover-open",":modal"];function Jh(e){return Kh.some(t=>{try{return e.matches(t)}catch(n){return!1}})}const Yh=["transform","translate","scale","rotate","perspective"],Xh=["transform","translate","scale","rotate","perspective","filter"],Qh=["paint","layout","strict","content"];function em(e){const t=tm(),n=Fh(e)?om(e):e;return Yh.some(e=>!!n[e]&&"none"!==n[e])||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||Xh.some(e=>(n.willChange||"").includes(e))||Qh.some(e=>(n.contain||"").includes(e))}function tm(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}const nm=new Set(["html","body","#document"]);function rm(e){return nm.has($h(e))}function om(e){return Lh(e).getComputedStyle(e)}function im(e){return Fh(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function am(e){if("html"===$h(e))return e;const t=e.assignedSlot||e.parentNode||Uh(e)&&e.host||Rh(e);return Uh(t)?t.host:t}function lm(e){const t=am(e);return rm(t)?e.ownerDocument?e.ownerDocument.body:e.body:jh(t)&&qh(t)?t:lm(t)}function sm(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);const o=lm(e),i=o===(null==(r=e.ownerDocument)?void 0:r.body),a=Lh(o);if(i){const e=cm(a);return t.concat(a,a.visualViewport||[],qh(o)?o:[],e&&n?sm(e):[])}return t.concat(o,sm(o,[],n))}function cm(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function dm(e){const t=om(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=jh(e),i=o?e.offsetWidth:n,a=o?e.offsetHeight:r,l=mh(n)!==i||mh(r)!==a;return l&&(n=i,r=a),{width:n,height:r,$:l}}function um(e){return Fh(e)?e:e.contextElement}function pm(e){const t=um(e);if(!jh(t))return gh(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:i}=dm(t);let a=(i?mh(n.width):n.width)/r,l=(i?mh(n.height):n.height)/o;return a&&Number.isFinite(a)||(a=1),l&&Number.isFinite(l)||(l=1),{x:a,y:l}}const hm=gh(0);function mm(e){const t=Lh(e);return tm()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:hm}function fm(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const o=e.getBoundingClientRect(),i=um(e);let a=gh(1);t&&(r?Fh(r)&&(a=pm(r)):a=pm(e));const l=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==Lh(e))&&t}(i,n,r)?mm(i):gh(0);let s=(o.left+l.x)/a.x,c=(o.top+l.y)/a.y,d=o.width/a.x,u=o.height/a.y;if(i){const e=Lh(i),t=r&&Fh(r)?Lh(r):r;let n=e,o=cm(n);for(;o&&r&&t!==n;){const e=pm(o),t=o.getBoundingClientRect(),r=om(o),i=t.left+(o.clientLeft+parseFloat(r.paddingLeft))*e.x,a=t.top+(o.clientTop+parseFloat(r.paddingTop))*e.y;s*=e.x,c*=e.y,d*=e.x,u*=e.y,s+=i,c+=a,n=Lh(o),o=cm(n)}}return zh({width:d,height:u,x:s,y:c})}function gm(e,t){const n=im(e).scrollLeft;return t?t.left+n:fm(Rh(e)).left+n}function vm(e,t){const n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-gm(e,n),y:n.top+t.scrollTop}}const ym=new Set(["absolute","fixed"]);function bm(e,t,n){let r;if("viewport"===t)r=function(e,t){const n=Lh(e),r=Rh(e),o=n.visualViewport;let i=r.clientWidth,a=r.clientHeight,l=0,s=0;if(o){i=o.width,a=o.height;const e=tm();(!e||e&&"fixed"===t)&&(l=o.offsetLeft,s=o.offsetTop)}const c=gm(r);if(c<=0){const e=r.ownerDocument,t=e.body,n=getComputedStyle(t),o="CSS1Compat"===e.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,a=Math.abs(r.clientWidth-t.clientWidth-o);a<=25&&(i-=a)}else c<=25&&(i+=c);return{width:i,height:a,x:l,y:s}}(e,n);else if("document"===t)r=function(e){const t=Rh(e),n=im(e),r=e.ownerDocument.body,o=hh(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=hh(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+gm(e);const l=-n.scrollTop;return"rtl"===om(r).direction&&(a+=hh(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:a,y:l}}(Rh(e));else if(Fh(t))r=function(e,t){const n=fm(e,!0,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=jh(e)?pm(e):gh(1);return{width:e.clientWidth*i.x,height:e.clientHeight*i.y,x:o*i.x,y:r*i.y}}(t,n);else{const n=mm(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return zh(r)}function wm(e,t){const n=am(e);return!(n===t||!Fh(n)||rm(n))&&("fixed"===om(n).position||wm(n,t))}function km(e,t,n){const r=jh(t),o=Rh(t),i="fixed"===n,a=fm(e,!0,i,t);let l={scrollLeft:0,scrollTop:0};const s=gh(0);function c(){s.x=gm(o)}if(r||!r&&!i)if(("body"!==$h(t)||qh(o))&&(l=im(t)),r){const e=fm(t,!0,i,t);s.x=e.x+t.clientLeft,s.y=e.y+t.clientTop}else o&&c();i&&!r&&o&&c();const d=!o||r||i?gh(0):vm(o,l);return{x:a.left+l.scrollLeft-s.x-d.x,y:a.top+l.scrollTop-s.y-d.y,width:a.width,height:a.height}}function xm(e){return"static"===om(e).position}function _m(e,t){if(!jh(e)||"fixed"===om(e).position)return null;if(t)return t(e);let n=e.offsetParent;return Rh(e)===n&&(n=n.ownerDocument.body),n}function Cm(e,t){const n=Lh(e);if(Jh(e))return n;if(!jh(e)){let t=am(e);for(;t&&!rm(t);){if(Fh(t)&&!xm(t))return t;t=am(t)}return n}let r=_m(e,t);for(;r&&Wh(r)&&xm(r);)r=_m(r,t);return r&&rm(r)&&xm(r)&&!em(r)?n:r||function(e){let t=am(e);for(;jh(t)&&!rm(t);){if(em(t))return t;if(Jh(t))return null;t=am(t)}return null}(e)||n}const Em={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const i="fixed"===o,a=Rh(r),l=!!t&&Jh(t.floating);if(r===a||l&&i)return n;let s={scrollLeft:0,scrollTop:0},c=gh(1);const d=gh(0),u=jh(r);if((u||!u&&!i)&&(("body"!==$h(r)||qh(a))&&(s=im(r)),jh(r))){const e=fm(r);c=pm(r),d.x=e.x+r.clientLeft,d.y=e.y+r.clientTop}const p=!a||u||i?gh(0):vm(a,s);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-s.scrollLeft*c.x+d.x+p.x,y:n.y*c.y-s.scrollTop*c.y+d.y+p.y}},getDocumentElement:Rh,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[..."clippingAncestors"===n?Jh(t)?[]:function(e,t){const n=t.get(e);if(n)return n;let r=sm(e,[],!1).filter(e=>Fh(e)&&"body"!==$h(e)),o=null;const i="fixed"===om(e).position;let a=i?am(e):e;for(;Fh(a)&&!rm(a);){const t=om(a),n=em(a);n||"fixed"!==t.position||(o=null),(i?!n&&!o:!n&&"static"===t.position&&o&&ym.has(o.position)||qh(a)&&!n&&wm(e,a))?r=r.filter(e=>e!==a):o=t,a=am(a)}return t.set(e,r),r}(t,this._c):[].concat(n),r],a=i[0],l=i.reduce((e,n)=>{const r=bm(t,n,o);return e.top=hh(r.top,e.top),e.right=ph(r.right,e.right),e.bottom=ph(r.bottom,e.bottom),e.left=hh(r.left,e.left),e},bm(t,a,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}},getOffsetParent:Cm,getElementRects:async function(e){const t=this.getOffsetParent||Cm,n=this.getDimensions,r=await n(e.floating);return{reference:km(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:n}=dm(e);return{width:t,height:n}},getScale:pm,isElement:Fh,isRTL:function(e){return"rtl"===om(e).direction}};function Sm(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Bm(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:s=!1}=r,c=um(e),d=o||i?[...c?sm(c):[],...sm(t)]:[];d.forEach(e=>{o&&e.addEventListener("scroll",n,{passive:!0}),i&&e.addEventListener("resize",n)});const u=c&&l?function(e,t){let n,r=null;const o=Rh(e);function i(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return function a(l,s){void 0===l&&(l=!1),void 0===s&&(s=1),i();const c=e.getBoundingClientRect(),{left:d,top:u,width:p,height:h}=c;if(l||t(),!p||!h)return;const m={rootMargin:-fh(u)+"px "+-fh(o.clientWidth-(d+p))+"px "+-fh(o.clientHeight-(u+h))+"px "+-fh(d)+"px",threshold:hh(0,ph(1,s))||1};let f=!0;function g(t){const r=t[0].intersectionRatio;if(r!==s){if(!f)return a();r?a(!1,r):n=setTimeout(()=>{a(!1,1e-7)},1e3)}1!==r||Sm(c,e.getBoundingClientRect())||a(),f=!1}try{r=new IntersectionObserver(g,{...m,root:o.ownerDocument})}catch(v){r=new IntersectionObserver(g,m)}r.observe(e)}(!0),i}(c,n):null;let p,h=-1,m=null;a&&(m=new ResizeObserver(e=>{let[r]=e;r&&r.target===c&&m&&(m.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var e;null==(e=m)||e.observe(t)})),n()}),c&&!s&&m.observe(c),m.observe(t));let f=s?fm(e):null;return s&&function t(){const r=fm(e);f&&!Sm(f,r)&&n();f=r,p=requestAnimationFrame(t)}(),n(),()=>{var e;d.forEach(e=>{o&&e.removeEventListener("scroll",n),i&&e.removeEventListener("resize",n)}),null==u||u(),null==(e=m)||e.disconnect(),m=null,s&&cancelAnimationFrame(p)}}const Nm=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:i,placement:a,middlewareData:l}=t,s=await async function(e,t){const{placement:n,platform:r,elements:o}=e,i=await(null==r.isRTL?void 0:r.isRTL(o.floating)),a=wh(n),l=kh(n),s="y"===Ch(n),c=Dh.has(a)?-1:1,d=i&&s?-1:1,u=bh(t,e);let{mainAxis:p,crossAxis:h,alignmentAxis:m}="number"==typeof u?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return l&&"number"==typeof m&&(h="end"===l?-1*m:m),s?{x:h*d,y:p*c}:{x:p*c,y:h*d}}(t,e);return a===(null==(n=l.offset)?void 0:n.placement)&&null!=(r=l.arrow)&&r.alignmentOffset?{}:{x:o+s.x,y:i+s.y,data:{...s,placement:a}}}}},Mm=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:i,rects:a,initialPlacement:l,platform:s,elements:c}=t,{mainAxis:d=!0,crossAxis:u=!0,fallbackPlacements:p,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:f=!0,...g}=bh(e,t);if(null!=(n=i.arrow)&&n.alignmentOffset)return{};const v=wh(o),y=Ch(l),b=wh(l)===l,w=await(null==s.isRTL?void 0:s.isRTL(c.floating)),k=p||(b||!f?[Ah(l)]:function(e){const t=Ah(e);return[Sh(e),t,Sh(t)]}(l)),x="none"!==m;!p&&x&&k.push(...Vh(l,f,m,w));const _=[l,...k],C=await s.detectOverflow(t,g),E=[];let S=(null==(r=i.flip)?void 0:r.overflows)||[];if(d&&E.push(C[v]),u){const e=function(e,t,n){void 0===n&&(n=!1);const r=kh(e),o=Eh(e),i=xh(o);let a="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[i]>t.floating[i]&&(a=Ah(a)),[a,Ah(a)]}(o,a,w);E.push(C[e[0]],C[e[1]])}if(S=[...S,{placement:o,overflows:E}],!E.every(e=>e<=0)){var B,N;const e=((null==(B=i.flip)?void 0:B.index)||0)+1,t=_[e];if(t){if(!("alignment"===u&&y!==Ch(t))||S.every(e=>Ch(e.placement)!==y||e.overflows[0]>0))return{data:{index:e,overflows:S},reset:{placement:t}}}let n=null==(N=S.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:N.placement;if(!n)switch(h){case"bestFit":{var M;const e=null==(M=S.filter(e=>{if(x){const t=Ch(e.placement);return t===y||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:M[0];e&&(n=e);break}case"initialPlacement":n=l}if(o!==n)return{reset:{placement:n}}}return{}}}},Tm=(e,t,n)=>{const r=new Map,o={platform:Em,...n},i={...o.platform,_c:r};return(async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:a}=n,l=i.filter(Boolean),s=await(null==a.isRTL?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:u}=Oh(c,r,s),p=r,h={},m=0;for(let g=0;g<l.length;g++){var f;const{name:n,fn:i}=l[g],{x:v,y:y,data:b,reset:w}=await i({x:d,y:u,initialPlacement:r,placement:p,strategy:o,middlewareData:h,rects:c,platform:{...a,detectOverflow:null!=(f=a.detectOverflow)?f:Ih},elements:{reference:e,floating:t}});d=null!=v?v:d,u=null!=y?y:u,h={...h,[n]:{...h[n],...b}},w&&m<=50&&(m++,"object"==typeof w&&(w.placement&&(p=w.placement),w.rects&&(c=!0===w.rects?await a.getElementRects({reference:e,floating:t,strategy:o}):w.rects),({x:d,y:u}=Oh(c,p,s))),g=-1)}return{x:d,y:u,placement:p,strategy:o,middlewareData:h}})(e,t,{...o,platform:i})},Vm=()=>new Map,Am=e=>{const t=Vm();return e.forEach((e,n)=>{t.set(n,e)}),t},zm=(e,t,n)=>{let r=e.get(t);return void 0===r&&e.set(t,r=n()),r},Om=()=>new Set,Im=e=>e[e.length-1],Dm=(e,t)=>{for(let n=0;n<t.length;n++)e.push(t[n])},Pm=Array.from,$m=(e,t)=>{for(let n=0;n<e.length;n++)if(!t(e[n],n,e))return!1;return!0},Lm=(e,t)=>{for(let n=0;n<e.length;n++)if(t(e[n],n,e))return!0;return!1},Rm=Array.isArray;class Hm{constructor(){this._observers=Vm()}on(e,t){return zm(this._observers,e,Om).add(t),t}once(e,t){const n=(...r)=>{this.off(e,n),t(...r)};this.on(e,n)}off(e,t){const n=this._observers.get(e);void 0!==n&&(n.delete(t),0===n.size&&this._observers.delete(e))}emit(e,t){return Pm((this._observers.get(e)||Vm()).values()).forEach(e=>e(...t))}destroy(){this._observers=Vm()}}const Fm=Math.floor,jm=Math.abs,Um=(e,t)=>e<t?e:t,Gm=(e,t)=>e>t?e:t,qm=e=>0!==e?e<0:1/e<0,Zm=64,Wm=128,Km=127,Jm=Number.MAX_SAFE_INTEGER,Ym=Number.MIN_SAFE_INTEGER,Xm=Number.isInteger||(e=>"number"==typeof e&&isFinite(e)&&Fm(e)===e),Qm=String.fromCharCode,ef=/^\s*/g,tf=/([A-Z])/g,nf=(e,t)=>(e=>e.replace(ef,""))(e.replace(tf,e=>`${t}${(e=>e.toLowerCase())(e)}`)),rf="undefined"!=typeof TextEncoder?new TextEncoder:null,of=rf?e=>rf.encode(e):e=>{const t=unescape(encodeURIComponent(e)),n=t.length,r=new Uint8Array(n);for(let o=0;o<n;o++)r[o]=t.codePointAt(o);return r};let af="undefined"==typeof TextDecoder?null:new TextDecoder("utf-8",{fatal:!0,ignoreBOM:!0});af&&1===af.decode(new Uint8Array).length&&(af=null);const lf=(e,t)=>((e,t)=>{const n=new Array(e);for(let r=0;r<e;r++)n[r]=t(r,n);return n})(t,()=>e).join("");class sf{constructor(){this.cpos=0,this.cbuf=new Uint8Array(100),this.bufs=[]}}const cf=()=>new sf,df=e=>{const t=new Uint8Array((e=>{let t=e.cpos;for(let n=0;n<e.bufs.length;n++)t+=e.bufs[n].length;return t})(e));let n=0;for(let r=0;r<e.bufs.length;r++){const o=e.bufs[r];t.set(o,n),n+=o.length}return t.set(new Uint8Array(e.cbuf.buffer,0,e.cpos),n),t},uf=(e,t)=>{const n=e.cbuf.length;e.cpos===n&&(e.bufs.push(e.cbuf),e.cbuf=new Uint8Array(2*n),e.cpos=0),e.cbuf[e.cpos++]=t},pf=uf,hf=(e,t)=>{for(;t>Km;)uf(e,Wm|Km&t),t=Fm(t/128);uf(e,Km&t)},mf=(e,t)=>{const n=qm(t);for(n&&(t=-t),uf(e,(t>63?Wm:0)|(n?Zm:0)|63&t),t=Fm(t/64);t>0;)uf(e,(t>Km?Wm:0)|Km&t),t=Fm(t/128)},ff=new Uint8Array(3e4),gf=ff.length/3,vf=rf&&rf.encodeInto?(e,t)=>{if(t.length<gf){const n=rf.encodeInto(t,ff).written||0;hf(e,n);for(let t=0;t<n;t++)uf(e,ff[t])}else bf(e,of(t))}:(e,t)=>{const n=unescape(encodeURIComponent(t)),r=n.length;hf(e,r);for(let o=0;o<r;o++)uf(e,n.codePointAt(o))},yf=(e,t)=>{const n=e.cbuf.length,r=e.cpos,o=Um(n-r,t.length),i=t.length-o;e.cbuf.set(t.subarray(0,o),r),e.cpos+=o,i>0&&(e.bufs.push(e.cbuf),e.cbuf=new Uint8Array(Gm(2*n,i)),e.cbuf.set(t.subarray(o)),e.cpos=i)},bf=(e,t)=>{hf(e,t.byteLength),yf(e,t)},wf=(e,t)=>{((e,t)=>{const n=e.cbuf.length;n-e.cpos<t&&(e.bufs.push(new Uint8Array(e.cbuf.buffer,0,e.cpos)),e.cbuf=new Uint8Array(2*Gm(n,t)),e.cpos=0)})(e,t);const n=new DataView(e.cbuf.buffer,e.cpos,t);return e.cpos+=t,n},kf=new DataView(new ArrayBuffer(4)),xf=(e,t)=>{switch(typeof t){case"string":uf(e,119),vf(e,t);break;case"number":Xm(t)&&jm(t)<=2147483647?(uf(e,125),mf(e,t)):(n=t,kf.setFloat32(0,n),kf.getFloat32(0)===n?(uf(e,124),((e,t)=>{wf(e,4).setFloat32(0,t,!1)})(e,t)):(uf(e,123),((e,t)=>{wf(e,8).setFloat64(0,t,!1)})(e,t)));break;case"bigint":uf(e,122),((e,t)=>{wf(e,8).setBigInt64(0,t,!1)})(e,t);break;case"object":if(null===t)uf(e,126);else if(Rm(t)){uf(e,117),hf(e,t.length);for(let n=0;n<t.length;n++)xf(e,t[n])}else if(t instanceof Uint8Array)uf(e,116),bf(e,t);else{uf(e,118);const n=Object.keys(t);hf(e,n.length);for(let r=0;r<n.length;r++){const o=n[r];vf(e,o),xf(e,t[o])}}break;case"boolean":uf(e,t?120:121);break;default:uf(e,127)}var n};class _f extends sf{constructor(e){super(),this.w=e,this.s=null,this.count=0}write(e){this.s===e?this.count++:(this.count>0&&hf(this,this.count-1),this.count=1,this.w(this,e),this.s=e)}}const Cf=e=>{e.count>0&&(mf(e.encoder,1===e.count?e.s:-e.s),e.count>1&&hf(e.encoder,e.count-2))};class Ef{constructor(){this.encoder=new sf,this.s=0,this.count=0}write(e){this.s===e?this.count++:(Cf(this),this.count=1,this.s=e)}toUint8Array(){return Cf(this),df(this.encoder)}}const Sf=e=>{if(e.count>0){const t=2*e.diff+(1===e.count?0:1);mf(e.encoder,t),e.count>1&&hf(e.encoder,e.count-2)}};class Bf{constructor(){this.encoder=new sf,this.s=0,this.count=0,this.diff=0}write(e){this.diff===e-this.s?(this.s=e,this.count++):(Sf(this),this.count=1,this.diff=e-this.s,this.s=e)}toUint8Array(){return Sf(this),df(this.encoder)}}class Nf{constructor(){this.sarr=[],this.s="",this.lensE=new Ef}write(e){this.s+=e,this.s.length>19&&(this.sarr.push(this.s),this.s=""),this.lensE.write(e.length)}toUint8Array(){const e=new sf;return this.sarr.push(this.s),this.s="",vf(e,this.sarr.join("")),yf(e,this.lensE.toUint8Array()),df(e)}}const Mf=e=>new Error(e),Tf=()=>{throw Mf("Method unimplemented")},Vf=()=>{throw Mf("Unexpected case")},Af=Mf("Unexpected end of array"),zf=Mf("Integer out of Range");class Of{constructor(e){this.arr=e,this.pos=0}}const If=e=>new Of(e),Df=e=>((e,t)=>{const n=new Uint8Array(e.arr.buffer,e.pos+e.arr.byteOffset,t);return e.pos+=t,n})(e,$f(e)),Pf=e=>e.arr[e.pos++],$f=e=>{let t=0,n=1;const r=e.arr.length;for(;e.pos<r;){const r=e.arr[e.pos++];if(t+=(r&Km)*n,n*=128,r<Wm)return t;if(t>Jm)throw zf}throw Af},Lf=e=>{let t=e.arr[e.pos++],n=63&t,r=64;const o=(t&Zm)>0?-1:1;if(0===(t&Wm))return o*n;const i=e.arr.length;for(;e.pos<i;){if(t=e.arr[e.pos++],n+=(t&Km)*r,r*=128,t<Wm)return o*n;if(n>Jm)throw zf}throw Af},Rf=af?e=>af.decode(Df(e)):e=>{let t=$f(e);if(0===t)return"";{let n=String.fromCodePoint(Pf(e));if(--t<100)for(;t--;)n+=String.fromCodePoint(Pf(e));else for(;t>0;){const r=t<1e4?t:1e4,o=e.arr.subarray(e.pos,e.pos+r);e.pos+=r,n+=String.fromCodePoint.apply(null,o),t-=r}return decodeURIComponent(escape(n))}},Hf=(e,t)=>{const n=new DataView(e.arr.buffer,e.arr.byteOffset+e.pos,t);return e.pos+=t,n},Ff=[e=>{},e=>null,Lf,e=>Hf(e,4).getFloat32(0,!1),e=>Hf(e,8).getFloat64(0,!1),e=>Hf(e,8).getBigInt64(0,!1),e=>!1,e=>!0,Rf,e=>{const t=$f(e),n={};for(let r=0;r<t;r++){n[Rf(e)]=jf(e)}return n},e=>{const t=$f(e),n=[];for(let r=0;r<t;r++)n.push(jf(e));return n},Df],jf=e=>Ff[127-Pf(e)](e);class Uf extends Of{constructor(e,t){super(e),this.reader=t,this.s=null,this.count=0}read(){var e;return 0===this.count&&(this.s=this.reader(this),(e=this).pos!==e.arr.length?this.count=$f(this)+1:this.count=-1),this.count--,this.s}}class Gf extends Of{constructor(e){super(e),this.s=0,this.count=0}read(){if(0===this.count){this.s=Lf(this);const e=qm(this.s);this.count=1,e&&(this.s=-this.s,this.count=$f(this)+2)}return this.count--,this.s}}class qf extends Of{constructor(e){super(e),this.s=0,this.count=0,this.diff=0}read(){if(0===this.count){const e=Lf(this),t=1&e;this.diff=Fm(e/2),this.count=1,t&&(this.count=$f(this)+2)}return this.s+=this.diff,this.count--,this.s}}class Zf{constructor(e){this.decoder=new Gf(e),this.str=Rf(this.decoder),this.spos=0}read(){const e=this.spos+this.decoder.read(),t=this.str.slice(this.spos,e);return this.spos=e,t}}const Wf=crypto.getRandomValues.bind(crypto),Kf=Math.random,Jf=()=>Wf(new Uint32Array(1))[0],Yf="10000000-1000-4000-8000-100000000000",Xf=()=>Yf.replace(/[018]/g,e=>(e^Jf()&15>>e/4).toString(16)),Qf=Date.now,eg=e=>new Promise(e);Promise.all.bind(Promise);const tg=e=>void 0===e?null:e;let ng=new class{constructor(){this.map=new Map}setItem(e,t){this.map.set(e,t)}getItem(e){return this.map.get(e)}},rg=!0;try{"undefined"!=typeof localStorage&&localStorage&&(ng=localStorage,rg=!1)}catch(hR){}const og=ng,ig=Symbol("Equality"),ag=(e,t)=>{var n;return e===t||!!(null==(n=null==e?void 0:e[ig])?void 0:n.call(e,t))||!1},lg=Object.assign,sg=Object.keys,cg=e=>sg(e).length,dg=(e,t)=>{for(const n in e)if(!t(e[n],n))return!1;return!0},ug=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),pg=Object.freeze,hg=e=>{for(const t in e){const n=e[t];"object"!=typeof n&&"function"!=typeof n||hg(e[t])}return pg(e)},mg=(e,t,n=0)=>{try{for(;n<e.length;n++)e[n](...t)}finally{n<e.length&&mg(e,t,n+1)}},fg=(e,t)=>{if(e===t)return!0;if(null==e||null==t||e.constructor!==t.constructor&&(e.constructor||Object)!==(t.constructor||Object))return!1;if(null!=e[ig])return e[ig](t);switch(e.constructor){case ArrayBuffer:e=new Uint8Array(e),t=new Uint8Array(t);case Uint8Array:if(e.byteLength!==t.byteLength)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;break;case Set:if(e.size!==t.size)return!1;for(const n of e)if(!t.has(n))return!1;break;case Map:if(e.size!==t.size)return!1;for(const n of e.keys())if(!t.has(n)||!fg(e.get(n),t.get(n)))return!1;break;case void 0:case Object:if(cg(e)!==cg(t))return!1;for(const n in e)if(!ug(e,n)||!fg(e[n],t[n]))return!1;break;case Array:if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(!fg(e[n],t[n]))return!1;break;default:return!1}return!0},gg="undefined"!=typeof process&&process.release&&/node|io\.js/.test(process.release.name)&&"[object process]"===Object.prototype.toString.call("undefined"!=typeof process?process:0),vg="undefined"!=typeof window&&"undefined"!=typeof document&&!gg;let yg;const bg=e=>(()=>{if(void 0===yg)if(gg){yg=Vm();const e=process.argv;let t=null;for(let n=0;n<e.length;n++){const r=e[n];"-"===r[0]?(null!==t&&yg.set(t,""),t=r):null!==t&&(yg.set(t,r),t=null)}null!==t&&yg.set(t,"")}else"object"==typeof location?(yg=Vm(),(location.search||"?").slice(1).split("&").forEach(e=>{if(0!==e.length){const[t,n]=e.split("=");yg.set(`--${nf(t,"-")}`,n),yg.set(`-${nf(t,"-")}`,n)}})):yg=Vm();return yg})().has(e),wg=e=>tg(gg?process.env[e.toUpperCase().replaceAll("-","_")]:og.getItem(e)),kg=e=>bg("--"+e)||null!==wg(e),xg=kg("production");var _g;gg&&(_g=process.env.FORCE_COLOR,["true","1","2"].includes(_g))||!bg("--no-colors")&&!kg("no-color")&&(!gg||process.stdout.isTTY)&&(!gg||bg("--color")||null!==wg("COLORTERM")||(wg("TERM")||"").includes("color"));const Cg=vg?e=>{let t="";for(let n=0;n<e.byteLength;n++)t+=Qm(e[n]);return btoa(t)}:e=>Buffer.from(e.buffer,e.byteOffset,e.byteLength).toString("base64"),Eg=e=>(e=>{const t=cf();return e(t),df(t)})(t=>xf(t,e));class Sg{constructor(e,t){this.left=e,this.right=t}}const Bg=(e,t)=>new Sg(e,t),Ng=e=>e.next()>=.5,Mg=(e,t,n)=>Fm(e.next()*(n+1-t)+t),Tg=(e,t,n)=>Fm(e.next()*(n+1-t)+t),Vg=(e,t,n)=>Tg(e,t,n),Ag=e=>Qm(Vg(e,97,122)),zg=(e,t)=>t[Vg(e,0,t.length-1)],Og=Symbol("0schema");class Ig{constructor(){this._rerrs=[]}extend(e,t,n,r=null){this._rerrs.push({path:e,expected:t,has:n,message:r})}toString(){const e=[];for(let t=this._rerrs.length-1;t>0;t--){const n=this._rerrs[t];e.push(lf(" ",2*(this._rerrs.length-t))+`${null!=n.path?`[${n.path}] `:""}${n.has} doesn't match ${n.expected}. ${n.message}`)}return e.join("\n")}}const Dg=(e,t)=>e===t||null!=e&&null!=t&&e.constructor===t.constructor&&(e[ig]?ag(e,t):Rm(e)?$m(e,e=>Lm(t,t=>Dg(e,t))):"object"==typeof e&&dg(e,(e,n)=>Dg(e,t[n])));class Pg{extends(e){let[t,n]=[this.shape,e.shape];return this.constructor._dilutes&&([n,t]=[t,n]),Dg(t,n)}equals(e){return this.constructor===e.constructor&&fg(this.shape,e.shape)}[Og](){return!0}[ig](e){return this.equals(e)}validate(e){return this.check(e)}check(e,t){Tf()}get nullable(){return hv(this,Nv)}get optional(){return new Wg(this)}cast(e){return Av(e,this),e}expect(e){return Av(e,this),e}}d(Pg,"_dilutes",!1);class $g extends Pg{constructor(e,t){super(),this.shape=e,this._c=t}check(e,t=void 0){const n=(null==e?void 0:e.constructor)===this.shape&&(null==this._c||this._c(e));return!n&&(null==t||t.extend(null,this.shape.name,null==e?void 0:e.constructor.name,(null==e?void 0:e.constructor)!==this.shape?"Constructor match failed":"Check failed")),n}}const Lg=(e,t=null)=>new $g(e,t);Lg($g);class Rg extends Pg{constructor(e){super(),this.shape=e}check(e,t){const n=this.shape(e);return!n&&(null==t||t.extend(null,"custom prop",null==e?void 0:e.constructor.name,"failed to check custom prop")),n}}const Hg=e=>new Rg(e);Lg(Rg);class Fg extends Pg{constructor(e){super(),this.shape=e}check(e,t){const n=this.shape.some(t=>t===e);return!n&&(null==t||t.extend(null,this.shape.join(" | "),e.toString())),n}}const jg=(...e)=>new Fg(e),Ug=Lg(Fg),Gg=RegExp.escape||(e=>e.replace(/[().|&,$^[\]]/g,e=>"\\"+e)),qg=e=>_v.check(e)?[Gg(e)]:Ug.check(e)?e.shape.map(e=>e+""):xv.check(e)?["[+-]?\\d+.?\\d*"]:Cv.check(e)?[".*"]:mv.check(e)?e.shape.map(qg).flat(1):void Vf();Lg(class extends Pg{constructor(e){super(),this.shape=e,this._r=new RegExp("^"+e.map(qg).map(e=>`(${e.join("|")})`).join("")+"$")}check(e,t){const n=null!=this._r.exec(e);return!n&&(null==t||t.extend(null,this._r.toString(),e.toString(),"String doesn't match string template.")),n}});const Zg=Symbol("optional");class Wg extends Pg{constructor(e){super(),this.shape=e}check(e,t){const n=void 0===e||this.shape.check(e);return!n&&(null==t||t.extend(null,"undefined (optional)","()")),n}get[Zg](){return!0}}const Kg=Lg(Wg);Lg(class extends Pg{check(e,t){return null==t||t.extend(null,"never",typeof e),!1}});const Jg=class e extends Pg{constructor(e,t=!1){super(),this.shape=e,this._isPartial=t}get partial(){return new e(this.shape,!0)}check(e,t){return null==e?(null==t||t.extend(null,"object","null"),!1):dg(this.shape,(n,r)=>{const o=this._isPartial&&!ug(e,r)||n.check(e[r],t);return!o&&(null==t||t.extend(r.toString(),n.toString(),typeof e[r],"Object property does not match")),o})}};d(Jg,"_dilutes",!0);let Yg=Jg;const Xg=Lg(Yg),Qg=Hg(e=>null!=e&&(e.constructor===Object||null==e.constructor));class ev extends Pg{constructor(e,t){super(),this.shape={keys:e,values:t}}check(e,t){return null!=e&&dg(e,(n,r)=>{const o=this.shape.keys.check(r,t);return!o&&(null==t||t.extend(r+"","Record",typeof e,o?"Key doesn't match schema":"Value doesn't match value")),o&&this.shape.values.check(n,t)})}}const tv=(e,t)=>new ev(e,t),nv=Lg(ev);class rv extends Pg{constructor(e){super(),this.shape=e}check(e,t){return null!=e&&dg(this.shape,(n,r)=>{const o=n.check(e[r],t);return!o&&(null==t||t.extend(r.toString(),"Tuple",typeof n)),o})}}Lg(rv);class ov extends Pg{constructor(e){super(),this.shape=1===e.length?e[0]:new pv(e)}check(e,t){const n=Rm(e)&&$m(e,e=>this.shape.check(e));return!n&&(null==t||t.extend(null,"Array","")),n}}const iv=(...e)=>new ov(e),av=Lg(ov),lv=Hg(e=>Rm(e));class sv extends Pg{constructor(e,t){super(),this.shape=e,this._c=t}check(e,t){const n=e instanceof this.shape&&(null==this._c||this._c(e));return!n&&(null==t||t.extend(null,this.shape.name,null==e?void 0:e.constructor.name)),n}}Lg(sv);const cv=((e,t=null)=>new sv(e,t))(Pg);const dv=Lg(class extends Pg{constructor(e){super(),this.len=e.length-1,this.args=((...e)=>new rv(e))(...e.slice(-1)),this.res=e[this.len]}check(e,t){const n=e.constructor===Function&&e.length<=this.len;return!n&&(null==t||t.extend(null,"function",typeof e)),n}}),uv=Hg(e=>"function"==typeof e);Lg(class extends Pg{constructor(e){super(),this.shape=e}check(e,t){const n=$m(this.shape,n=>n.check(e,t));return!n&&(null==t||t.extend(null,"Intersectinon",typeof e)),n}},e=>e.shape.length>0);class pv extends Pg{constructor(e){super(),this.shape=e}check(e,t){const n=Lm(this.shape,n=>n.check(e,t));return null==t||t.extend(null,"Union",typeof e),n}}d(pv,"_dilutes",!0);const hv=(...e)=>e.findIndex(e=>mv.check(e))>=0?hv(...e.map(e=>Vv(e)).map(e=>mv.check(e)?e.shape:[e]).flat(1)):1===e.length?e[0]:new pv(e),mv=Lg(pv),fv=()=>!0,gv=Hg(fv),vv=Lg(Rg,e=>e.shape===fv),yv=Hg(e=>"bigint"==typeof e),bv=Hg(e=>e===yv),wv=Hg(e=>"symbol"==typeof e);Hg(e=>e===wv);const kv=Hg(e=>"number"==typeof e),xv=Hg(e=>e===kv),_v=Hg(e=>"string"==typeof e),Cv=Hg(e=>e===_v),Ev=Hg(e=>"boolean"==typeof e),Sv=Hg(e=>e===Ev),Bv=jg(void 0);Lg(Fg,e=>1===e.shape.length&&void 0===e.shape[0]),jg(void 0);const Nv=jg(null),Mv=Lg(Fg,e=>1===e.shape.length&&null===e.shape[0]);Lg(Uint8Array),Lg($g,e=>e.shape===Uint8Array);const Tv=hv(kv,_v,Nv,Bv,yv,Ev,wv);(()=>{const e=iv(gv),t=tv(_v,gv),n=hv(kv,_v,Nv,Ev,e,t);e.shape=n,t.shape.values=n})();const Vv=e=>{if(cv.check(e))return e;if(Qg.check(e)){const t={};for(const n in e)t[n]=Vv(e[n]);return new Yg(t)}return lv.check(e)?hv(...e.map(Vv)):Tv.check(e)?jg(e):uv.check(e)?Lg(e):void Vf()},Av=xg?()=>{}:(e,t)=>{const n=new Ig;if(!t.check(e,n))throw Mf(`Expected value to be of type ${t.constructor.name}.\n${n.toString()}`)};class zv{constructor(e){this.patterns=[],this.$state=e}if(e,t){return this.patterns.push({if:Vv(e),h:t}),this}else(e){return this.if(gv,e)}done(){return(e,t)=>{for(let n=0;n<this.patterns.length;n++){const r=this.patterns[n];if(r.if.check(e))return r.h(e,t)}throw Mf("Unhandled pattern")}}}const Ov=(Iv=gv,new zv(Iv)).if(xv,(e,t)=>Mg(t,Ym,Jm)).if(Cv,(e,t)=>((e,t=0,n=20)=>{const r=Vg(e,t,n);let o="";for(let i=0;i<r;i++)o+=Ag(e);return o})(t)).if(Sv,(e,t)=>Ng(t)).if(bv,(e,t)=>BigInt(Mg(t,Ym,Jm))).if(mv,(e,t)=>Dv(t,zg(t,e.shape))).if(Xg,(e,t)=>{const n={};for(const r in e.shape){let o=e.shape[r];if(Kg.check(o)){if(Ng(t))continue;o=o.shape}n[r]=Ov(o,t)}return n}).if(av,(e,t)=>{const n=[],r=Tg(t,0,42);for(let o=0;o<r;o++)n.push(Dv(t,e.shape));return n}).if(Ug,(e,t)=>zg(t,e.shape)).if(Mv,(e,t)=>null).if(dv,(e,t)=>{const n=Dv(t,e.res);return()=>n}).if(vv,(e,t)=>Dv(t,zg(t,[kv,_v,Nv,Bv,yv,Ev,iv(kv),tv(hv("a","b","c"),kv)]))).if(nv,(e,t)=>{const n={},r=Mg(t,0,3);for(let o=0;o<r;o++){const r=Dv(t,e.shape.keys),o=Dv(t,e.shape.values);n[r]=o}return n}).done();var Iv;const Dv=(e,t)=>Ov(Vv(t),e),Pv="undefined"!=typeof document?document:{};Hg(e=>e.nodeType===Hv),"undefined"!=typeof DOMParser&&new DOMParser,Hg(e=>e.nodeType===$v),Hg(e=>e.nodeType===Lv);const $v=Pv.ELEMENT_NODE,Lv=Pv.TEXT_NODE,Rv=Pv.DOCUMENT_NODE,Hv=Pv.DOCUMENT_FRAGMENT_NODE;Hg(e=>e.nodeType===Rv);const Fv=(jv=clearTimeout,class{constructor(e){this._=e}destroy(){jv(this._)}});var jv;const Uv=(e,t)=>new Fv(setTimeout(t,e)),Gv=Symbol,qv=Gv(),Zv=Gv(),Wv=Gv(),Kv=Gv(),Jv=Gv(),Yv=Gv(),Xv=Gv(),Qv=Gv(),ey=Gv(),ty=(Bg("font-weight","bold"),Bg("font-weight","normal"),Bg("color","blue"),Bg("color","green"),Bg("color","grey"),Bg("color","red"),Bg("color","purple"),Bg("color","orange"),Bg("color","black"),(...e)=>{e.unshift(Qv),ny.forEach(t=>t.print(e))}),ny=Om(),ry=e=>({[Symbol.iterator](){return this},next:e}),oy=(e,t)=>ry(()=>{const{done:n,value:r}=e.next();return{done:n,value:n?void 0:t(r)}});class iy{constructor(e,t){this.clock=e,this.len=t}}class ay{constructor(){this.clients=new Map}}const ly=(e,t,n)=>t.clients.forEach((t,r)=>{const o=e.doc.store.clients.get(r);if(null!=o){const r=o[o.length-1],i=r.id.clock+r.length;for(let a=0,l=t[a];a<t.length&&l.clock<i;l=t[++a])tb(e,o,l.clock,l.len,n)}}),sy=(e,t)=>{const n=e.clients.get(t.client);return void 0!==n&&null!==((e,t)=>{let n=0,r=e.length-1;for(;n<=r;){const o=Fm((n+r)/2),i=e[o],a=i.clock;if(a<=t){if(t<a+i.len)return o;n=o+1}else r=o-1}return null})(n,t.clock)},cy=e=>{e.clients.forEach(e=>{let t,n;for(e.sort((e,t)=>e.clock-t.clock),t=1,n=1;t<e.length;t++){const r=e[n-1],o=e[t];r.clock+r.len>=o.clock?r.len=Gm(r.len,o.clock+o.len-r.clock):(n<t&&(e[n]=o),n++)}e.length=n})},dy=e=>{const t=new ay;for(let n=0;n<e.length;n++)e[n].clients.forEach((r,o)=>{if(!t.clients.has(o)){const i=r.slice();for(let t=n+1;t<e.length;t++)Dm(i,e[t].clients.get(o)||[]);t.clients.set(o,i)}});return cy(t),t},uy=(e,t,n,r)=>{zm(e.clients,t,()=>[]).push(new iy(n,r))},py=()=>new ay,hy=(e,t)=>{hf(e.restEncoder,t.clients.size),Pm(t.clients.entries()).sort((e,t)=>t[0]-e[0]).forEach(([t,n])=>{e.resetDsCurVal(),hf(e.restEncoder,t);const r=n.length;hf(e.restEncoder,r);for(let o=0;o<r;o++){const t=n[o];e.writeDsClock(t.clock),e.writeDsLen(t.len)}})},my=(e,t,n)=>{const r=new ay,o=$f(e.restDecoder);for(let i=0;i<o;i++){e.resetDsCurVal();const o=$f(e.restDecoder),i=$f(e.restDecoder),a=n.clients.get(o)||[],l=Wy(n,o);for(let n=0;n<i;n++){const n=e.readDsClock(),i=n+e.readDsLen();if(n<l){l<i&&uy(r,o,l,i-l);let e=Jy(a,n),s=a[e];for(!s.deleted&&s.id.clock<n&&(a.splice(e+1,0,Fw(t,s,n-s.id.clock)),e++);e<a.length&&(s=a[e++],s.id.clock<i);)s.deleted||(i<s.id.clock+s.length&&a.splice(e,0,Fw(t,s,i-s.id.clock)),s.delete(t))}else uy(r,o,n,i-n)}}if(r.clients.size>0){const e=new xy;return hf(e.restEncoder,0),hy(e,r),e.toUint8Array()}return null},fy=Jf;class gy extends Hm{constructor({guid:e=Xf(),collectionid:t=null,gc:n=!0,gcFilter:r=()=>!0,meta:o=null,autoLoad:i=!1,shouldLoad:a=!0}={}){super(),this.gc=n,this.gcFilter=r,this.clientID=fy(),this.guid=e,this.collectionid=t,this.share=new Map,this.store=new qy,this._transaction=null,this._transactionCleanups=[],this.subdocs=new Set,this._item=null,this.shouldLoad=a,this.autoLoad=i,this.meta=o,this.isLoaded=!1,this.isSynced=!1,this.isDestroyed=!1,this.whenLoaded=eg(e=>{this.on("load",()=>{this.isLoaded=!0,e(this)})});const l=()=>eg(e=>{const t=n=>{void 0!==n&&!0!==n||(this.off("sync",t),e())};this.on("sync",t)});this.on("sync",e=>{!1===e&&this.isSynced&&(this.whenSynced=l()),this.isSynced=void 0===e||!0===e,this.isSynced&&!this.isLoaded&&this.emit("load",[this])}),this.whenSynced=l()}load(){const e=this._item;null===e||this.shouldLoad||lb(e.parent.doc,e=>{e.subdocsLoaded.add(this)},null,!0),this.shouldLoad=!0}getSubdocs(){return this.subdocs}getSubdocGuids(){return new Set(Pm(this.subdocs).map(e=>e.guid))}transact(e,t=null){return lb(this,e,t)}get(e,t=Mb){const n=zm(this.share,e,()=>{const e=new t;return e._integrate(this,null),e}),r=n.constructor;if(t!==Mb&&r!==t){if(r===Mb){const r=new t;r._map=n._map,n._map.forEach(e=>{for(;null!==e;e=e.left)e.parent=r}),r._start=n._start;for(let e=r._start;null!==e;e=e.right)e.parent=r;return r._length=n._length,this.share.set(e,r),r._integrate(this,null),r}throw new Error(`Type with the name ${e} has already been defined with a different constructor`)}return n}getArray(e=""){return this.get(e,Wb)}getText(e=""){return this.get(e,pw)}getMap(e=""){return this.get(e,Jb)}getXmlElement(e=""){return this.get(e,fw)}getXmlFragment(e=""){return this.get(e,mw)}toJSON(){const e={};return this.share.forEach((t,n)=>{e[n]=t.toJSON()}),e}destroy(){this.isDestroyed=!0,Pm(this.subdocs).forEach(e=>e.destroy());const e=this._item;if(null!==e){this._item=null;const t=e.content;t.doc=new gy({guid:this.guid,...t.opts,shouldLoad:!1}),t.doc._item=e,lb(e.parent.doc,n=>{const r=t.doc;e.deleted||n.subdocsAdded.add(r),n.subdocsRemoved.add(this)},null,!0)}this.emit("destroyed",[!0]),this.emit("destroy",[this]),super.destroy()}}class vy{constructor(e){this.dsCurrVal=0,this.restDecoder=e}resetDsCurVal(){this.dsCurrVal=0}readDsClock(){return this.dsCurrVal+=$f(this.restDecoder),this.dsCurrVal}readDsLen(){const e=$f(this.restDecoder)+1;return this.dsCurrVal+=e,e}}class yy extends vy{constructor(e){super(e),this.keys=[],$f(e),this.keyClockDecoder=new qf(Df(e)),this.clientDecoder=new Gf(Df(e)),this.leftClockDecoder=new qf(Df(e)),this.rightClockDecoder=new qf(Df(e)),this.infoDecoder=new Uf(Df(e),Pf),this.stringDecoder=new Zf(Df(e)),this.parentInfoDecoder=new Uf(Df(e),Pf),this.typeRefDecoder=new Gf(Df(e)),this.lenDecoder=new Gf(Df(e))}readLeftID(){return new Vy(this.clientDecoder.read(),this.leftClockDecoder.read())}readRightID(){return new Vy(this.clientDecoder.read(),this.rightClockDecoder.read())}readClient(){return this.clientDecoder.read()}readInfo(){return this.infoDecoder.read()}readString(){return this.stringDecoder.read()}readParentInfo(){return 1===this.parentInfoDecoder.read()}readTypeRef(){return this.typeRefDecoder.read()}readLen(){return this.lenDecoder.read()}readAny(){return jf(this.restDecoder)}readBuf(){return Df(this.restDecoder)}readJSON(){return jf(this.restDecoder)}readKey(){const e=this.keyClockDecoder.read();if(e<this.keys.length)return this.keys[e];{const e=this.stringDecoder.read();return this.keys.push(e),e}}}class by{constructor(){this.restEncoder=cf()}toUint8Array(){return df(this.restEncoder)}resetDsCurVal(){}writeDsClock(e){hf(this.restEncoder,e)}writeDsLen(e){hf(this.restEncoder,e)}}class wy extends by{writeLeftID(e){hf(this.restEncoder,e.client),hf(this.restEncoder,e.clock)}writeRightID(e){hf(this.restEncoder,e.client),hf(this.restEncoder,e.clock)}writeClient(e){hf(this.restEncoder,e)}writeInfo(e){pf(this.restEncoder,e)}writeString(e){vf(this.restEncoder,e)}writeParentInfo(e){hf(this.restEncoder,e?1:0)}writeTypeRef(e){hf(this.restEncoder,e)}writeLen(e){hf(this.restEncoder,e)}writeAny(e){xf(this.restEncoder,e)}writeBuf(e){bf(this.restEncoder,e)}writeJSON(e){vf(this.restEncoder,JSON.stringify(e))}writeKey(e){vf(this.restEncoder,e)}}class ky{constructor(){this.restEncoder=cf(),this.dsCurrVal=0}toUint8Array(){return df(this.restEncoder)}resetDsCurVal(){this.dsCurrVal=0}writeDsClock(e){const t=e-this.dsCurrVal;this.dsCurrVal=e,hf(this.restEncoder,t)}writeDsLen(e){0===e&&Vf(),hf(this.restEncoder,e-1),this.dsCurrVal+=e}}class xy extends ky{constructor(){super(),this.keyMap=new Map,this.keyClock=0,this.keyClockEncoder=new Bf,this.clientEncoder=new Ef,this.leftClockEncoder=new Bf,this.rightClockEncoder=new Bf,this.infoEncoder=new _f(pf),this.stringEncoder=new Nf,this.parentInfoEncoder=new _f(pf),this.typeRefEncoder=new Ef,this.lenEncoder=new Ef}toUint8Array(){const e=cf();return hf(e,0),bf(e,this.keyClockEncoder.toUint8Array()),bf(e,this.clientEncoder.toUint8Array()),bf(e,this.leftClockEncoder.toUint8Array()),bf(e,this.rightClockEncoder.toUint8Array()),bf(e,df(this.infoEncoder)),bf(e,this.stringEncoder.toUint8Array()),bf(e,df(this.parentInfoEncoder)),bf(e,this.typeRefEncoder.toUint8Array()),bf(e,this.lenEncoder.toUint8Array()),yf(e,df(this.restEncoder)),df(e)}writeLeftID(e){this.clientEncoder.write(e.client),this.leftClockEncoder.write(e.clock)}writeRightID(e){this.clientEncoder.write(e.client),this.rightClockEncoder.write(e.clock)}writeClient(e){this.clientEncoder.write(e)}writeInfo(e){this.infoEncoder.write(e)}writeString(e){this.stringEncoder.write(e)}writeParentInfo(e){this.parentInfoEncoder.write(e?1:0)}writeTypeRef(e){this.typeRefEncoder.write(e)}writeLen(e){this.lenEncoder.write(e)}writeAny(e){xf(this.restEncoder,e)}writeBuf(e){bf(this.restEncoder,e)}writeJSON(e){xf(this.restEncoder,e)}writeKey(e){const t=this.keyMap.get(e);void 0===t?(this.keyClockEncoder.write(this.keyClock++),this.stringEncoder.write(e)):this.keyClockEncoder.write(t)}}const _y=(e,t,n)=>{const r=new Map;n.forEach((e,n)=>{Wy(t,n)>e&&r.set(n,e)}),Zy(t).forEach((e,t)=>{n.has(t)||r.set(t,0)}),hf(e.restEncoder,r.size),Pm(r.entries()).sort((e,t)=>t[0]-e[0]).forEach(([n,r])=>{((e,t,n,r)=>{r=Gm(r,t[0].id.clock);const o=Jy(t,r);hf(e.restEncoder,t.length-o),e.writeClient(n),hf(e.restEncoder,r);const i=t[o];i.write(e,r-i.id.clock);for(let a=o+1;a<t.length;a++)t[a].write(e,0)})(e,t.clients.get(n),n,r)})},Cy=(e,t,n,r=new yy(e))=>lb(t,e=>{e.local=!1;let t=!1;const n=e.doc,o=n.store,i=((e,t)=>{const n=Vm(),r=$f(e.restDecoder);for(let o=0;o<r;o++){const r=$f(e.restDecoder),o=new Array(r),i=e.readClient();let a=$f(e.restDecoder);n.set(i,{i:0,refs:o});for(let n=0;n<r;n++){const r=e.readInfo();switch(31&r){case 0:{const t=e.readLen();o[n]=new ww(zy(i,a),t),a+=t;break}case 10:{const t=$f(e.restDecoder);o[n]=new Ww(zy(i,a),t),a+=t;break}default:{const l=!(192&r),s=new Gw(zy(i,a),null,(r&Wm)===Wm?e.readLeftID():null,null,(r&Zm)===Zm?e.readRightID():null,l?e.readParentInfo()?t.get(e.readString()):e.readLeftID():null,!l||32&~r?null:e.readString(),qw(e,r));o[n]=s,a+=s.length}}}}return n})(r,n),a=((e,t,n)=>{const r=[];let o=Pm(n.keys()).sort((e,t)=>e-t);if(0===o.length)return null;const i=()=>{if(0===o.length)return null;let e=n.get(o[o.length-1]);for(;e.refs.length===e.i;){if(o.pop(),!(o.length>0))return null;e=n.get(o[o.length-1])}return e};let a=i();if(null===a)return null;const l=new qy,s=new Map,c=(e,t)=>{const n=s.get(e);(null==n||n>t)&&s.set(e,t)};let d=a.refs[a.i++];const u=new Map,p=()=>{for(const e of r){const t=e.id.client,r=n.get(t);r?(r.i--,l.clients.set(t,r.refs.slice(r.i)),n.delete(t),r.i=0,r.refs=[]):l.clients.set(t,[e]),o=o.filter(e=>e!==t)}r.length=0};for(;;){if(d.constructor!==Ww){const o=zm(u,d.id.client,()=>Wy(t,d.id.client))-d.id.clock;if(o<0)r.push(d),c(d.id.client,d.id.clock-1),p();else{const i=d.getMissing(e,t);if(null!==i){r.push(d);const e=n.get(i)||{refs:[],i:0};if(e.refs.length!==e.i){d=e.refs[e.i++];continue}c(i,Wy(t,i)),p()}else(0===o||o<d.length)&&(d.integrate(e,o),u.set(d.id.client,d.id.clock+d.length))}}if(r.length>0)d=r.pop();else if(null!==a&&a.i<a.refs.length)d=a.refs[a.i++];else{if(a=i(),null===a)break;d=a.refs[a.i++]}}if(l.clients.size>0){const e=new xy;return _y(e,l,new Map),hf(e.restEncoder,0),{missing:s,update:e.toUint8Array()}}return null})(e,o,i),l=o.pendingStructs;if(l){for(const[e,n]of l.missing)if(n<Wy(o,e)){t=!0;break}if(a){for(const[e,t]of a.missing){const n=l.missing.get(e);(null==n||n>t)&&l.missing.set(e,t)}l.update=fb([l.update,a.update])}}else o.pendingStructs=a;const s=my(r,e,o);if(o.pendingDs){const t=new yy(If(o.pendingDs));$f(t.restDecoder);const n=my(t,e,o);o.pendingDs=s&&n?fb([s,n]):s||n}else o.pendingDs=s;if(t){const t=o.pendingStructs.update;o.pendingStructs=null,Ey(e.doc,t)}},n,!1),Ey=(e,t,n,r=yy)=>{const o=If(t);Cy(o,e,n,new r(o))};class Sy{constructor(){this.l=[]}}const By=()=>new Sy,Ny=(e,t)=>e.l.push(t),My=(e,t)=>{const n=e.l;n.length;e.l=n.filter(e=>t!==e),e.l.length},Ty=(e,t,n)=>mg(e.l,[t,n]);class Vy{constructor(e,t){this.client=e,this.clock=t}}const Ay=(e,t)=>e===t||null!==e&&null!==t&&e.client===t.client&&e.clock===t.clock,zy=(e,t)=>new Vy(e,t),Oy=e=>{for(const[t,n]of e.doc.share.entries())if(n===e)return t;throw Vf()},Iy=(e,t)=>{for(;null!==t;){if(t.parent===e)return!0;t=t.parent._item}return!1};class Dy{constructor(e,t,n,r=0){this.type=e,this.tname=t,this.item=n,this.assoc=r}}class Py{constructor(e,t,n=0){this.type=e,this.index=t,this.assoc=n}}const $y=(e,t,n)=>{let r=null,o=null;return null===e._item?o=Oy(e):r=zy(e._item.id.client,e._item.id.clock),new Dy(r,o,t,n)},Ly=(e,t,n=0)=>{let r=e._start;if(n<0){if(0===t)return $y(e,null,n);t--}for(;null!==r;){if(!r.deleted&&r.countable){if(r.length>t)return $y(e,zy(r.id.client,r.id.clock+t),n);t-=r.length}if(null===r.right&&n<0)return $y(e,r.lastId,n);r=r.right}return $y(e,null,n)},Ry=(e,t,n=!0)=>{const r=t.store,o=e.item,i=e.type,a=e.tname,l=e.assoc;let s=null,c=0;if(null!==o){if(Wy(r,o.client)<=o.clock)return null;const e=n?Rw(r,o):((e,t)=>{const n=Yy(e,t);return{item:n,diff:t.clock-n.id.clock}})(r,o),t=e.item;if(!(t instanceof Gw))return null;if(s=t.parent,null===s._item||!s._item.deleted){c=t.deleted||!t.countable?0:e.diff+(l>=0?0:1);let n=t.left;for(;null!==n;)!n.deleted&&n.countable&&(c+=n.length),n=n.left}}else{if(null!==a)s=t.get(a);else{if(null===i)throw Vf();{if(Wy(r,i.client)<=i.clock)return null;const{item:e}=n?Rw(r,i):{item:Yy(r,i)};if(!(e instanceof Gw&&e.content instanceof Lw))return null;s=e.content.type}}c=l>=0?s._length:0}return((e,t,n=0)=>new Py(e,t,n))(s,c,e.assoc)};class Hy{constructor(e,t){this.ds=e,this.sv=t}}const Fy=(e,t)=>new Hy(e,t),jy=e=>Fy((e=>{const t=py();return e.clients.forEach((e,n)=>{const r=[];for(let t=0;t<e.length;t++){const n=e[t];if(n.deleted){const o=n.id.clock;let i=n.length;if(t+1<e.length)for(let n=e[t+1];t+1<e.length&&n.deleted;n=e[1+ ++t])i+=n.length;r.push(new iy(o,i))}}r.length>0&&t.clients.set(n,r)}),t})(e.store),Zy(e.store)),Uy=(e,t)=>void 0===t?!e.deleted:t.sv.has(e.id.client)&&(t.sv.get(e.id.client)||0)>e.id.clock&&!sy(t.ds,e.id),Gy=(e,t)=>{const n=zm(e.meta,Gy,Om),r=e.doc.store;n.has(t)||(t.sv.forEach((t,n)=>{t<Wy(r,n)&&Qy(e,zy(n,t))}),ly(e,t.ds,e=>{}),n.add(t))};class qy{constructor(){this.clients=new Map,this.pendingStructs=null,this.pendingDs=null}}const Zy=e=>{const t=new Map;return e.clients.forEach((e,n)=>{const r=e[e.length-1];t.set(n,r.id.clock+r.length)}),t},Wy=(e,t)=>{const n=e.clients.get(t);if(void 0===n)return 0;const r=n[n.length-1];return r.id.clock+r.length},Ky=(e,t)=>{let n=e.clients.get(t.id.client);if(void 0===n)n=[],e.clients.set(t.id.client,n);else{const e=n[n.length-1];if(e.id.clock+e.length!==t.id.clock)throw Vf()}n.push(t)},Jy=(e,t)=>{let n=0,r=e.length-1,o=e[r],i=o.id.clock;if(i===t)return r;let a=Fm(t/(i+o.length-1)*r);for(;n<=r;){if(o=e[a],i=o.id.clock,i<=t){if(t<i+o.length)return a;n=a+1}else r=a-1;a=Fm((n+r)/2)}throw Vf()},Yy=(e,t)=>{const n=e.clients.get(t.client);return n[Jy(n,t.clock)]},Xy=(e,t,n)=>{const r=Jy(t,n),o=t[r];return o.id.clock<n&&o instanceof Gw?(t.splice(r+1,0,Fw(e,o,n-o.id.clock)),r+1):r},Qy=(e,t)=>{const n=e.doc.store.clients.get(t.client);return n[Xy(e,n,t.clock)]},eb=(e,t,n)=>{const r=t.clients.get(n.client),o=Jy(r,n.clock),i=r[o];return n.clock!==i.id.clock+i.length-1&&i.constructor!==ww&&r.splice(o+1,0,Fw(e,i,n.clock-i.id.clock+1)),i},tb=(e,t,n,r,o)=>{if(0===r)return;const i=n+r;let a,l=Xy(e,t,n);do{a=t[l++],i<a.id.clock+a.length&&Xy(e,t,i),o(a)}while(l<t.length&&t[l].id.clock<i)};class nb{constructor(e,t,n){this.doc=e,this.deleteSet=new ay,this.beforeState=Zy(e.store),this.afterState=new Map,this.changed=new Map,this.changedParentTypes=new Map,this._mergeStructs=[],this.origin=t,this.meta=new Map,this.local=n,this.subdocsAdded=new Set,this.subdocsRemoved=new Set,this.subdocsLoaded=new Set,this._needFormattingCleanup=!1}}const rb=(e,t)=>!(0===t.deleteSet.clients.size&&!((e,t)=>{for(const[n,r]of e)if(t(r,n))return!0;return!1})(t.afterState,(e,n)=>t.beforeState.get(n)!==e))&&(cy(t.deleteSet),((e,t)=>{_y(e,t.doc.store,t.beforeState)})(e,t),hy(e,t.deleteSet),!0),ob=(e,t,n)=>{const r=t._item;(null===r||r.id.clock<(e.beforeState.get(r.id.client)||0)&&!r.deleted)&&zm(e.changed,t,Om).add(n)},ib=(e,t)=>{let n=e[t],r=e[t-1],o=t;for(;o>0&&(r.deleted===n.deleted&&r.constructor===n.constructor&&r.mergeWith(n));n=r,r=e[--o-1])n instanceof Gw&&null!==n.parentSub&&n.parent._map.get(n.parentSub)===n&&n.parent._map.set(n.parentSub,r);const i=t-o;return i&&e.splice(t+1-i,i),i},ab=(e,t)=>{if(t<e.length){const n=e[t],r=n.doc,o=r.store,i=n.deleteSet,a=n._mergeStructs;try{cy(i),n.afterState=Zy(n.doc.store),r.emit("beforeObserverCalls",[n,r]);const e=[];n.changed.forEach((t,r)=>e.push(()=>{null!==r._item&&r._item.deleted||r._callObserver(n,t)})),e.push(()=>{n.changedParentTypes.forEach((t,r)=>{r._dEH.l.length>0&&(null===r._item||!r._item.deleted)&&((t=t.filter(e=>null===e.target._item||!e.target._item.deleted)).forEach(e=>{e.currentTarget=r,e._path=null}),t.sort((e,t)=>e.path.length-t.path.length),e.push(()=>{Ty(r._dEH,t,n)}))}),e.push(()=>r.emit("afterTransaction",[n,r])),e.push(()=>{n._needFormattingCleanup&&cw(n)})}),mg(e,[])}finally{r.gc&&((e,t,n)=>{for(const[r,o]of e.clients.entries()){const e=t.clients.get(r);for(let r=o.length-1;r>=0;r--){const i=o[r],a=i.clock+i.len;for(let r=Jy(e,i.clock),o=e[r];r<e.length&&o.id.clock<a;o=e[++r]){const o=e[r];if(i.clock+i.len<=o.id.clock)break;o instanceof Gw&&o.deleted&&!o.keep&&n(o)&&o.gc(t,!1)}}}})(i,o,r.gcFilter),((e,t)=>{e.clients.forEach((e,n)=>{const r=t.clients.get(n);for(let t=e.length-1;t>=0;t--){const n=e[t];for(let e=Um(r.length-1,1+Jy(r,n.clock+n.len-1)),t=r[e];e>0&&t.id.clock>=n.clock;t=r[e])e-=1+ib(r,e)}})})(i,o),n.afterState.forEach((e,t)=>{const r=n.beforeState.get(t)||0;if(r!==e){const e=o.clients.get(t),n=Gm(Jy(e,r),1);for(let t=e.length-1;t>=n;)t-=1+ib(e,t)}});for(let e=a.length-1;e>=0;e--){const{client:t,clock:n}=a[e].id,r=o.clients.get(t),i=Jy(r,n);i+1<r.length&&ib(r,i+1)>1||i>0&&ib(r,i)}if(n.local||n.afterState.get(r.clientID)===n.beforeState.get(r.clientID)||(((...e)=>{ny.forEach(t=>t.print(e))})(Qv,qv,"[yjs] ",Zv,Yv,"Changed the client-id because another client seems to be using it."),r.clientID=fy()),r.emit("afterTransactionCleanup",[n,r]),r._observers.has("update")){const e=new wy;rb(e,n)&&r.emit("update",[e.toUint8Array(),n.origin,r,n])}if(r._observers.has("updateV2")){const e=new xy;rb(e,n)&&r.emit("updateV2",[e.toUint8Array(),n.origin,r,n])}const{subdocsAdded:l,subdocsLoaded:s,subdocsRemoved:c}=n;(l.size>0||c.size>0||s.size>0)&&(l.forEach(e=>{e.clientID=r.clientID,null==e.collectionid&&(e.collectionid=r.collectionid),r.subdocs.add(e)}),c.forEach(e=>r.subdocs.delete(e)),r.emit("subdocs",[{loaded:s,added:l,removed:c},r,n]),c.forEach(e=>e.destroy())),e.length<=t+1?(r._transactionCleanups=[],r.emit("afterAllTransactions",[r,e])):ab(e,t+1)}}},lb=(e,t,n=null,r=!0)=>{const o=e._transactionCleanups;let i=!1,a=null;null===e._transaction&&(i=!0,e._transaction=new nb(e,n,r),o.push(e._transaction),1===o.length&&e.emit("beforeAllTransactions",[e]),e.emit("beforeTransaction",[e._transaction,e]));try{a=t(e._transaction)}finally{if(i){const t=e._transaction===o[0];e._transaction=null,t&&ab(o,0)}}return a};class sb{constructor(e,t){this.insertions=t,this.deletions=e,this.meta=new Map}}const cb=(e,t,n)=>{ly(e,n.deletions,n=>{n instanceof Gw&&t.scope.some(t=>t===e.doc||Iy(t,n))&&Hw(n,!1)})},db=(e,t,n)=>{let r=null;const o=e.doc,i=e.scope;lb(o,n=>{for(;t.length>0&&null===e.currStackItem;){const r=o.store,a=t.pop(),l=new Set,s=[];let c=!1;ly(n,a.insertions,e=>{if(e instanceof Gw){if(null!==e.redone){let{item:t,diff:o}=Rw(r,e.id);o>0&&(t=Qy(n,zy(t.id.client,t.id.clock+o))),e=t}!e.deleted&&i.some(t=>t===n.doc||Iy(t,e))&&s.push(e)}}),ly(n,a.deletions,e=>{e instanceof Gw&&i.some(t=>t===n.doc||Iy(t,e))&&!sy(a.insertions,e.id)&&l.add(e)}),l.forEach(t=>{c=null!==Uw(n,t,l,a.insertions,e.ignoreRemoteMapChanges,e)||c});for(let t=s.length-1;t>=0;t--){const r=s[t];e.deleteFilter(r)&&(r.delete(n),c=!0)}e.currStackItem=c?a:null}n.changed.forEach((e,t)=>{e.has(null)&&t._searchMarker&&(t._searchMarker.length=0)}),r=n},e);const a=e.currStackItem;if(null!=a){const t=r.changedParentTypes;e.emit("stack-item-popped",[{stackItem:a,type:n,changedParentTypes:t,origin:e},e]),e.currStackItem=null}return a};class ub extends Hm{constructor(e,{captureTimeout:t=500,captureTransaction:n=e=>!0,deleteFilter:r=()=>!0,trackedOrigins:o=new Set([null]),ignoreRemoteMapChanges:i=!1,doc:a=(Rm(e)?e[0].doc:e instanceof gy?e:e.doc)}={}){super(),this.scope=[],this.doc=a,this.addToScope(e),this.deleteFilter=r,o.add(this),this.trackedOrigins=o,this.captureTransaction=n,this.undoStack=[],this.redoStack=[],this.undoing=!1,this.redoing=!1,this.currStackItem=null,this.lastChange=0,this.ignoreRemoteMapChanges=i,this.captureTimeout=t,this.afterTransactionHandler=e=>{if(!(this.captureTransaction(e)&&this.scope.some(t=>e.changedParentTypes.has(t)||t===this.doc)&&(this.trackedOrigins.has(e.origin)||e.origin&&this.trackedOrigins.has(e.origin.constructor))))return;const t=this.undoing,n=this.redoing,r=t?this.redoStack:this.undoStack;t?this.stopCapturing():n||this.clear(!1,!0);const o=new ay;e.afterState.forEach((t,n)=>{const r=e.beforeState.get(n)||0,i=t-r;i>0&&uy(o,n,r,i)});const i=Qf();let a=!1;if(this.lastChange>0&&i-this.lastChange<this.captureTimeout&&r.length>0&&!t&&!n){const t=r[r.length-1];t.deletions=dy([t.deletions,e.deleteSet]),t.insertions=dy([t.insertions,o])}else r.push(new sb(e.deleteSet,o)),a=!0;t||n||(this.lastChange=i),ly(e,e.deleteSet,t=>{t instanceof Gw&&this.scope.some(n=>n===e.doc||Iy(n,t))&&Hw(t,!0)});const l=[{stackItem:r[r.length-1],origin:e.origin,type:t?"redo":"undo",changedParentTypes:e.changedParentTypes},this];a?this.emit("stack-item-added",l):this.emit("stack-item-updated",l)},this.doc.on("afterTransaction",this.afterTransactionHandler),this.doc.on("destroy",()=>{this.destroy()})}addToScope(e){const t=new Set(this.scope);(e=Rm(e)?e:[e]).forEach(e=>{t.has(e)||(t.add(e),(e instanceof Mb?e.doc!==this.doc:e!==this.doc)&&ty("[yjs#509] Not same Y.Doc"),this.scope.push(e))})}addTrackedOrigin(e){this.trackedOrigins.add(e)}removeTrackedOrigin(e){this.trackedOrigins.delete(e)}clear(e=!0,t=!0){(e&&this.canUndo()||t&&this.canRedo())&&this.doc.transact(n=>{e&&(this.undoStack.forEach(e=>cb(n,this,e)),this.undoStack=[]),t&&(this.redoStack.forEach(e=>cb(n,this,e)),this.redoStack=[]),this.emit("stack-cleared",[{undoStackCleared:e,redoStackCleared:t}])})}stopCapturing(){this.lastChange=0}undo(){let e;this.undoing=!0;try{e=db(this,this.undoStack,"undo")}finally{this.undoing=!1}return e}redo(){let e;this.redoing=!0;try{e=db(this,this.redoStack,"redo")}finally{this.redoing=!1}return e}canUndo(){return this.undoStack.length>0}canRedo(){return this.redoStack.length>0}destroy(){this.trackedOrigins.delete(this),this.doc.off("afterTransaction",this.afterTransactionHandler),super.destroy()}}class pb{constructor(e,t){this.gen=function*(e){const t=$f(e.restDecoder);for(let n=0;n<t;n++){const t=$f(e.restDecoder),n=e.readClient();let r=$f(e.restDecoder);for(let o=0;o<t;o++){const t=e.readInfo();if(10===t){const t=$f(e.restDecoder);yield new Ww(zy(n,r),t),r+=t}else if(31&t){const o=!(192&t),i=new Gw(zy(n,r),null,(t&Wm)===Wm?e.readLeftID():null,null,(t&Zm)===Zm?e.readRightID():null,o?e.readParentInfo()?e.readString():e.readLeftID():null,!o||32&~t?null:e.readString(),qw(e,t));yield i,r+=i.length}else{const t=e.readLen();yield new ww(zy(n,r),t),r+=t}}}}(e),this.curr=null,this.done=!1,this.filterSkips=t,this.next()}next(){do{this.curr=this.gen.next().value||null}while(this.filterSkips&&null!==this.curr&&this.curr.constructor===Ww);return this.curr}}class hb{constructor(e){this.currClient=0,this.startClock=0,this.written=0,this.encoder=e,this.clientStructs=[]}}const mb=(e,t)=>{if(e.constructor===ww){const{client:n,clock:r}=e.id;return new ww(zy(n,r+t),e.length-t)}if(e.constructor===Ww){const{client:n,clock:r}=e.id;return new Ww(zy(n,r+t),e.length-t)}{const n=e,{client:r,clock:o}=n.id;return new Gw(zy(r,o+t),null,zy(r,o+t-1),null,n.rightOrigin,n.parent,n.parentSub,n.content.splice(t))}},fb=(e,t=yy,n=xy)=>{if(1===e.length)return e[0];const r=e.map(e=>new t(If(e)));let o=r.map(e=>new pb(e,!0)),i=null;const a=new n,l=new hb(a);for(;o=o.filter(e=>null!==e.curr),o.sort((e,t)=>{if(e.curr.id.client===t.curr.id.client){const n=e.curr.id.clock-t.curr.id.clock;return 0===n?e.curr.constructor===t.curr.constructor?0:e.curr.constructor===Ww?1:-1:n}return t.curr.id.client-e.curr.id.client}),0!==o.length;){const e=o[0],t=e.curr.id.client;if(null!==i){let n=e.curr,r=!1;for(;null!==n&&n.id.clock+n.length<=i.struct.id.clock+i.struct.length&&n.id.client>=i.struct.id.client;)n=e.next(),r=!0;if(null===n||n.id.client!==t||r&&n.id.clock>i.struct.id.clock+i.struct.length)continue;if(t!==i.struct.id.client)vb(l,i.struct,i.offset),i={struct:n,offset:0},e.next();else if(i.struct.id.clock+i.struct.length<n.id.clock)if(i.struct.constructor===Ww)i.struct.length=n.id.clock+n.length-i.struct.id.clock;else{vb(l,i.struct,i.offset);const e=n.id.clock-i.struct.id.clock-i.struct.length;i={struct:new Ww(zy(t,i.struct.id.clock+i.struct.length),e),offset:0}}else{const t=i.struct.id.clock+i.struct.length-n.id.clock;t>0&&(i.struct.constructor===Ww?i.struct.length-=t:n=mb(n,t)),i.struct.mergeWith(n)||(vb(l,i.struct,i.offset),i={struct:n,offset:0},e.next())}}else i={struct:e.curr,offset:0},e.next();for(let n=e.curr;null!==n&&n.id.client===t&&n.id.clock===i.struct.id.clock+i.struct.length&&n.constructor!==Ww;n=e.next())vb(l,i.struct,i.offset),i={struct:n,offset:0}}null!==i&&(vb(l,i.struct,i.offset),i=null),yb(l);const s=r.map(e=>(e=>{const t=new ay,n=$f(e.restDecoder);for(let r=0;r<n;r++){e.resetDsCurVal();const n=$f(e.restDecoder),r=$f(e.restDecoder);if(r>0){const o=zm(t.clients,n,()=>[]);for(let t=0;t<r;t++)o.push(new iy(e.readDsClock(),e.readDsLen()))}}return t})(e)),c=dy(s);return hy(a,c),a.toUint8Array()},gb=e=>{e.written>0&&(e.clientStructs.push({written:e.written,restEncoder:df(e.encoder.restEncoder)}),e.encoder.restEncoder=cf(),e.written=0)},vb=(e,t,n)=>{e.written>0&&e.currClient!==t.id.client&&gb(e),0===e.written&&(e.currClient=t.id.client,e.encoder.writeClient(t.id.client),hf(e.encoder.restEncoder,t.id.clock+n)),t.write(e.encoder,n),e.written++},yb=e=>{gb(e);const t=e.encoder.restEncoder;hf(t,e.clientStructs.length);for(let n=0;n<e.clientStructs.length;n++){const r=e.clientStructs[n];hf(t,r.written),yf(t,r.restEncoder)}},bb="You must not compute changes after the event-handler fired.";class wb{constructor(e,t){this.target=e,this.currentTarget=e,this.transaction=t,this._changes=null,this._keys=null,this._delta=null,this._path=null}get path(){return this._path||(this._path=kb(this.currentTarget,this.target))}deletes(e){return sy(this.transaction.deleteSet,e.id)}get keys(){if(null===this._keys){if(0===this.transaction.doc._transactionCleanups.length)throw Mf(bb);const e=new Map,t=this.target;this.transaction.changed.get(t).forEach(n=>{if(null!==n){const r=t._map.get(n);let o,i;if(this.adds(r)){let e=r.left;for(;null!==e&&this.adds(e);)e=e.left;if(this.deletes(r)){if(null===e||!this.deletes(e))return;o="delete",i=Im(e.content.getContent())}else null!==e&&this.deletes(e)?(o="update",i=Im(e.content.getContent())):(o="add",i=void 0)}else{if(!this.deletes(r))return;o="delete",i=Im(r.content.getContent())}e.set(n,{action:o,oldValue:i})}}),this._keys=e}return this._keys}get delta(){return this.changes.delta}adds(e){return e.id.clock>=(this.transaction.beforeState.get(e.id.client)||0)}get changes(){let e=this._changes;if(null===e){if(0===this.transaction.doc._transactionCleanups.length)throw Mf(bb);const t=this.target,n=Om(),r=Om(),o=[];e={added:n,deleted:r,delta:o,keys:this.keys};if(this.transaction.changed.get(t).has(null)){let e=null;const i=()=>{e&&o.push(e)};for(let o=t._start;null!==o;o=o.right)o.deleted?this.deletes(o)&&!this.adds(o)&&(null!==e&&void 0!==e.delete||(i(),e={delete:0}),e.delete+=o.length,r.add(o)):this.adds(o)?(null!==e&&void 0!==e.insert||(i(),e={insert:[]}),e.insert=e.insert.concat(o.content.getContent()),n.add(o)):(null!==e&&void 0!==e.retain||(i(),e={retain:0}),e.retain+=o.length);null!==e&&void 0===e.retain&&i()}this._changes=e}return e}}const kb=(e,t)=>{const n=[];for(;null!==t._item&&t!==e;){if(null!==t._item.parentSub)n.unshift(t._item.parentSub);else{let e=0,r=t._item.parent._start;for(;r!==t._item&&null!==r;)!r.deleted&&r.countable&&(e+=r.length),r=r.right;n.unshift(e)}t=t._item.parent}return n},xb=()=>{ty("Invalid access: Add Yjs type to a document before reading data.")};let _b=0;class Cb{constructor(e,t){e.marker=!0,this.p=e,this.index=t,this.timestamp=_b++}}const Eb=(e,t,n)=>{e.p.marker=!1,e.p=t,t.marker=!0,e.index=n,e.timestamp=_b++},Sb=(e,t)=>{if(null===e._start||0===t||null===e._searchMarker)return null;const n=0===e._searchMarker.length?null:e._searchMarker.reduce((e,n)=>jm(t-e.index)<jm(t-n.index)?e:n);let r=e._start,o=0;for(null!==n&&(r=n.p,o=n.index,(e=>{e.timestamp=_b++})(n));null!==r.right&&o<t;){if(!r.deleted&&r.countable){if(t<o+r.length)break;o+=r.length}r=r.right}for(;null!==r.left&&o>t;)r=r.left,!r.deleted&&r.countable&&(o-=r.length);for(;null!==r.left&&r.left.id.client===r.id.client&&r.left.id.clock+r.left.length===r.id.clock;)r=r.left,!r.deleted&&r.countable&&(o-=r.length);return null!==n&&jm(n.index-o)<r.parent.length/80?(Eb(n,r,o),n):((e,t,n)=>{if(e.length>=80){const r=e.reduce((e,t)=>e.timestamp<t.timestamp?e:t);return Eb(r,t,n),r}{const r=new Cb(t,n);return e.push(r),r}})(e._searchMarker,r,o)},Bb=(e,t,n)=>{for(let r=e.length-1;r>=0;r--){const o=e[r];if(n>0){let t=o.p;for(t.marker=!1;t&&(t.deleted||!t.countable);)t=t.left,t&&!t.deleted&&t.countable&&(o.index-=t.length);if(null===t||!0===t.marker){e.splice(r,1);continue}o.p=t,t.marker=!0}(t<o.index||n>0&&t===o.index)&&(o.index=Gm(t,o.index+n))}},Nb=(e,t,n)=>{const r=e,o=t.changedParentTypes;for(;zm(o,e,()=>[]).push(n),null!==e._item;)e=e._item.parent;Ty(r._eH,n,t)};class Mb{constructor(){this._item=null,this._map=new Map,this._start=null,this.doc=null,this._length=0,this._eH=By(),this._dEH=By(),this._searchMarker=null}get parent(){return this._item?this._item.parent:null}_integrate(e,t){this.doc=e,this._item=t}_copy(){throw Tf()}clone(){throw Tf()}_write(e){}get _first(){let e=this._start;for(;null!==e&&e.deleted;)e=e.right;return e}_callObserver(e,t){!e.local&&this._searchMarker&&(this._searchMarker.length=0)}observe(e){Ny(this._eH,e)}observeDeep(e){Ny(this._dEH,e)}unobserve(e){My(this._eH,e)}unobserveDeep(e){My(this._dEH,e)}toJSON(){}}const Tb=(e,t,n)=>{e.doc??xb(),t<0&&(t=e._length+t),n<0&&(n=e._length+n);let r=n-t;const o=[];let i=e._start;for(;null!==i&&r>0;){if(i.countable&&!i.deleted){const e=i.content.getContent();if(e.length<=t)t-=e.length;else{for(let n=t;n<e.length&&r>0;n++)o.push(e[n]),r--;t=0}}i=i.right}return o},Vb=e=>{e.doc??xb();const t=[];let n=e._start;for(;null!==n;){if(n.countable&&!n.deleted){const e=n.content.getContent();for(let n=0;n<e.length;n++)t.push(e[n])}n=n.right}return t},Ab=(e,t)=>{const n=[];let r=e._start;for(;null!==r;){if(r.countable&&Uy(r,t)){const e=r.content.getContent();for(let t=0;t<e.length;t++)n.push(e[t])}r=r.right}return n},zb=(e,t)=>{let n=0,r=e._start;for(e.doc??xb();null!==r;){if(r.countable&&!r.deleted){const o=r.content.getContent();for(let r=0;r<o.length;r++)t(o[r],n++,e)}r=r.right}},Ob=(e,t)=>{const n=[];return zb(e,(r,o)=>{n.push(t(r,o,e))}),n},Ib=e=>{let t=e._start,n=null,r=0;return{[Symbol.iterator](){return this},next:()=>{if(null===n){for(;null!==t&&t.deleted;)t=t.right;if(null===t)return{done:!0,value:void 0};n=t.content.getContent(),r=0,t=t.right}const e=n[r++];return n.length<=r&&(n=null),{done:!1,value:e}}}},Db=(e,t)=>{e.doc??xb();const n=Sb(e,t);let r=e._start;for(null!==n&&(r=n.p,t-=n.index);null!==r;r=r.right)if(!r.deleted&&r.countable){if(t<r.length)return r.content.getContent()[t];t-=r.length}},Pb=(e,t,n,r)=>{let o=n;const i=e.doc,a=i.clientID,l=i.store,s=null===n?t._start:n.right;let c=[];const d=()=>{c.length>0&&(o=new Gw(zy(a,Wy(l,a)),o,o&&o.lastId,s,s&&s.id,t,null,new Mw(c)),o.integrate(e,0),c=[])};r.forEach(n=>{if(null===n)c.push(n);else switch(n.constructor){case Number:case Object:case Boolean:case Array:case String:c.push(n);break;default:switch(d(),n.constructor){case Uint8Array:case ArrayBuffer:o=new Gw(zy(a,Wy(l,a)),o,o&&o.lastId,s,s&&s.id,t,null,new kw(new Uint8Array(n))),o.integrate(e,0);break;case gy:o=new Gw(zy(a,Wy(l,a)),o,o&&o.lastId,s,s&&s.id,t,null,new Cw(n)),o.integrate(e,0);break;default:if(!(n instanceof Mb))throw new Error("Unexpected content type in insert operation");o=new Gw(zy(a,Wy(l,a)),o,o&&o.lastId,s,s&&s.id,t,null,new Lw(n)),o.integrate(e,0)}}}),d()},$b=()=>Mf("Length exceeded!"),Lb=(e,t,n,r)=>{if(n>t._length)throw $b();if(0===n)return t._searchMarker&&Bb(t._searchMarker,n,r.length),Pb(e,t,null,r);const o=n,i=Sb(t,n);let a=t._start;for(null!==i&&(a=i.p,0===(n-=i.index)&&(a=a.prev,n+=a&&a.countable&&!a.deleted?a.length:0));null!==a;a=a.right)if(!a.deleted&&a.countable){if(n<=a.length){n<a.length&&Qy(e,zy(a.id.client,a.id.clock+n));break}n-=a.length}return t._searchMarker&&Bb(t._searchMarker,o,r.length),Pb(e,t,a,r)},Rb=(e,t,n,r)=>{if(0===r)return;const o=n,i=r,a=Sb(t,n);let l=t._start;for(null!==a&&(l=a.p,n-=a.index);null!==l&&n>0;l=l.right)!l.deleted&&l.countable&&(n<l.length&&Qy(e,zy(l.id.client,l.id.clock+n)),n-=l.length);for(;r>0&&null!==l;)l.deleted||(r<l.length&&Qy(e,zy(l.id.client,l.id.clock+r)),l.delete(e),r-=l.length),l=l.right;if(r>0)throw $b();t._searchMarker&&Bb(t._searchMarker,o,-i+r)},Hb=(e,t,n)=>{const r=t._map.get(n);void 0!==r&&r.delete(e)},Fb=(e,t,n,r)=>{const o=t._map.get(n)||null,i=e.doc,a=i.clientID;let l;if(null==r)l=new Mw([r]);else switch(r.constructor){case Number:case Object:case Boolean:case Array:case String:case Date:case BigInt:l=new Mw([r]);break;case Uint8Array:l=new kw(r);break;case gy:l=new Cw(r);break;default:if(!(r instanceof Mb))throw new Error("Unexpected content type");l=new Lw(r)}new Gw(zy(a,Wy(i.store,a)),o,o&&o.lastId,null,null,t,n,l).integrate(e,0)},jb=(e,t)=>{e.doc??xb();const n=e._map.get(t);return void 0===n||n.deleted?void 0:n.content.getContent()[n.length-1]},Ub=e=>{const t={};return e.doc??xb(),e._map.forEach((e,n)=>{e.deleted||(t[n]=e.content.getContent()[e.length-1])}),t},Gb=(e,t)=>{e.doc??xb();const n=e._map.get(t);return void 0!==n&&!n.deleted},qb=e=>{return e.doc??xb(),t=e._map.entries(),n=e=>!e[1].deleted,ry(()=>{let e;do{e=t.next()}while(!e.done&&!n(e.value));return e});var t,n};class Zb extends wb{}class Wb extends Mb{constructor(){super(),this._prelimContent=[],this._searchMarker=[]}static from(e){const t=new Wb;return t.push(e),t}_integrate(e,t){super._integrate(e,t),this.insert(0,this._prelimContent),this._prelimContent=null}_copy(){return new Wb}clone(){const e=new Wb;return e.insert(0,this.toArray().map(e=>e instanceof Mb?e.clone():e)),e}get length(){return this.doc??xb(),this._length}_callObserver(e,t){super._callObserver(e,t),Nb(this,e,new Zb(this,e))}insert(e,t){null!==this.doc?lb(this.doc,n=>{Lb(n,this,e,t)}):this._prelimContent.splice(e,0,...t)}push(e){null!==this.doc?lb(this.doc,t=>{((e,t,n)=>{let r=(t._searchMarker||[]).reduce((e,t)=>t.index>e.index?t:e,{index:0,p:t._start}).p;if(r)for(;r.right;)r=r.right;Pb(e,t,r,n)})(t,this,e)}):this._prelimContent.push(...e)}unshift(e){this.insert(0,e)}delete(e,t=1){null!==this.doc?lb(this.doc,n=>{Rb(n,this,e,t)}):this._prelimContent.splice(e,t)}get(e){return Db(this,e)}toArray(){return Vb(this)}slice(e=0,t=this.length){return Tb(this,e,t)}toJSON(){return this.map(e=>e instanceof Mb?e.toJSON():e)}map(e){return Ob(this,e)}forEach(e){zb(this,e)}[Symbol.iterator](){return Ib(this)}_write(e){e.writeTypeRef(Aw)}}class Kb extends wb{constructor(e,t,n){super(e,t),this.keysChanged=n}}class Jb extends Mb{constructor(e){super(),this._prelimContent=null,this._prelimContent=void 0===e?new Map:new Map(e)}_integrate(e,t){super._integrate(e,t),this._prelimContent.forEach((e,t)=>{this.set(t,e)}),this._prelimContent=null}_copy(){return new Jb}clone(){const e=new Jb;return this.forEach((t,n)=>{e.set(n,t instanceof Mb?t.clone():t)}),e}_callObserver(e,t){Nb(this,e,new Kb(this,e,t))}toJSON(){this.doc??xb();const e={};return this._map.forEach((t,n)=>{if(!t.deleted){const r=t.content.getContent()[t.length-1];e[n]=r instanceof Mb?r.toJSON():r}}),e}get size(){return[...qb(this)].length}keys(){return oy(qb(this),e=>e[0])}values(){return oy(qb(this),e=>e[1].content.getContent()[e[1].length-1])}entries(){return oy(qb(this),e=>[e[0],e[1].content.getContent()[e[1].length-1]])}forEach(e){this.doc??xb(),this._map.forEach((t,n)=>{t.deleted||e(t.content.getContent()[t.length-1],n,this)})}[Symbol.iterator](){return this.entries()}delete(e){null!==this.doc?lb(this.doc,t=>{Hb(t,this,e)}):this._prelimContent.delete(e)}set(e,t){return null!==this.doc?lb(this.doc,n=>{Fb(n,this,e,t)}):this._prelimContent.set(e,t),t}get(e){return jb(this,e)}has(e){return Gb(this,e)}clear(){null!==this.doc?lb(this.doc,e=>{this.forEach(function(t,n,r){Hb(e,r,n)})}):this._prelimContent.clear()}_write(e){e.writeTypeRef(zw)}}const Yb=(e,t)=>e===t||"object"==typeof e&&"object"==typeof t&&e&&t&&((e,t)=>e===t||cg(e)===cg(t)&&dg(e,(e,n)=>(void 0!==e||ug(t,n))&&ag(t[n],e)))(e,t);class Xb{constructor(e,t,n,r){this.left=e,this.right=t,this.index=n,this.currentAttributes=r}forward(){if(null===this.right&&Vf(),this.right.content.constructor===Sw)this.right.deleted||nw(this.currentAttributes,this.right.content);else this.right.deleted||(this.index+=this.right.length);this.left=this.right,this.right=this.right.right}}const Qb=(e,t,n)=>{for(;null!==t.right&&n>0;){if(t.right.content.constructor===Sw)t.right.deleted||nw(t.currentAttributes,t.right.content);else t.right.deleted||(n<t.right.length&&Qy(e,zy(t.right.id.client,t.right.id.clock+n)),t.index+=t.right.length,n-=t.right.length);t.left=t.right,t.right=t.right.right}return t},ew=(e,t,n,r)=>{const o=new Map,i=r?Sb(t,n):null;if(i){const t=new Xb(i.p.left,i.p,i.index,o);return Qb(e,t,n-i.index)}{const r=new Xb(null,t._start,0,o);return Qb(e,r,n)}},tw=(e,t,n,r)=>{for(;null!==n.right&&(!0===n.right.deleted||n.right.content.constructor===Sw&&Yb(r.get(n.right.content.key),n.right.content.value));)n.right.deleted||r.delete(n.right.content.key),n.forward();const o=e.doc,i=o.clientID;r.forEach((r,a)=>{const l=n.left,s=n.right,c=new Gw(zy(i,Wy(o.store,i)),l,l&&l.lastId,s,s&&s.id,t,null,new Sw(a,r));c.integrate(e,0),n.right=c,n.forward()})},nw=(e,t)=>{const{key:n,value:r}=t;null===r?e.delete(n):e.set(n,r)},rw=(e,t)=>{for(;null!==e.right&&(e.right.deleted||e.right.content.constructor===Sw&&Yb(t[e.right.content.key]??null,e.right.content.value));)e.forward()},ow=(e,t,n,r)=>{const o=e.doc,i=o.clientID,a=new Map;for(const l in r){const s=r[l],c=n.currentAttributes.get(l)??null;if(!Yb(c,s)){a.set(l,c);const{left:r,right:d}=n;n.right=new Gw(zy(i,Wy(o.store,i)),r,r&&r.lastId,d,d&&d.id,t,null,new Sw(l,s)),n.right.integrate(e,0),n.forward()}}return a},iw=(e,t,n,r,o)=>{n.currentAttributes.forEach((e,t)=>{void 0===o[t]&&(o[t]=null)});const i=e.doc,a=i.clientID;rw(n,o);const l=ow(e,t,n,o),s=r.constructor===String?new Tw(r):r instanceof Mb?new Lw(r):new Ew(r);let{left:c,right:d,index:u}=n;t._searchMarker&&Bb(t._searchMarker,n.index,s.getLength()),d=new Gw(zy(a,Wy(i.store,a)),c,c&&c.lastId,d,d&&d.id,t,null,s),d.integrate(e,0),n.right=d,n.index=u,n.forward(),tw(e,t,n,l)},aw=(e,t,n,r,o)=>{const i=e.doc,a=i.clientID;rw(n,o);const l=ow(e,t,n,o);e:for(;null!==n.right&&(r>0||l.size>0&&(n.right.deleted||n.right.content.constructor===Sw));){if(!n.right.deleted)switch(n.right.content.constructor){case Sw:{const{key:t,value:i}=n.right.content,a=o[t];if(void 0!==a){if(Yb(a,i))l.delete(t);else{if(0===r)break e;l.set(t,i)}n.right.delete(e)}else n.currentAttributes.set(t,i);break}default:r<n.right.length&&Qy(e,zy(n.right.id.client,n.right.id.clock+r)),r-=n.right.length}n.forward()}if(r>0){let o="";for(;r>0;r--)o+="\n";n.right=new Gw(zy(a,Wy(i.store,a)),n.left,n.left&&n.left.lastId,n.right,n.right&&n.right.id,t,null,new Tw(o)),n.right.integrate(e,0),n.forward()}tw(e,t,n,l)},lw=(e,t,n,r,o)=>{let i=t;const a=Vm();for(;i&&(!i.countable||i.deleted);){if(!i.deleted&&i.content.constructor===Sw){const e=i.content;a.set(e.key,e)}i=i.right}let l=0,s=!1;for(;t!==i;){if(n===t&&(s=!0),!t.deleted){const n=t.content;switch(n.constructor){case Sw:{const{key:i,value:c}=n,d=r.get(i)??null;a.get(i)===n&&d!==c||(t.delete(e),l++,s||(o.get(i)??null)!==c||d===c||(null===d?o.delete(i):o.set(i,d))),s||t.deleted||nw(o,n);break}}}t=t.right}return l},sw=e=>{let t=0;return lb(e.doc,n=>{let r=e._start,o=e._start,i=Vm();const a=Am(i);for(;o;){if(!1===o.deleted)if(o.content.constructor===Sw)nw(a,o.content);else t+=lw(n,r,o,i,a),i=Am(a),r=o;o=o.right}}),t},cw=e=>{const t=new Set,n=e.doc;for(const[r,o]of e.afterState.entries()){const i=e.beforeState.get(r)||0;o!==i&&tb(e,n.store.clients.get(r),i,o,e=>{e.deleted||e.content.constructor!==Sw||e.constructor===ww||t.add(e.parent)})}lb(n,n=>{ly(e,e.deleteSet,e=>{if(e instanceof ww||!e.parent._hasFormatting||t.has(e.parent))return;const r=e.parent;e.content.constructor===Sw?t.add(r):((e,t)=>{for(;t&&t.right&&(t.right.deleted||!t.right.countable);)t=t.right;const n=new Set;for(;t&&(t.deleted||!t.countable);){if(!t.deleted&&t.content.constructor===Sw){const r=t.content.key;n.has(r)?t.delete(e):n.add(r)}t=t.left}})(n,e)});for(const e of t)sw(e)})},dw=(e,t,n)=>{const r=n,o=Am(t.currentAttributes),i=t.right;for(;n>0&&null!==t.right;){if(!1===t.right.deleted)switch(t.right.content.constructor){case Lw:case Ew:case Tw:n<t.right.length&&Qy(e,zy(t.right.id.client,t.right.id.clock+n)),n-=t.right.length,t.right.delete(e)}t.forward()}i&&lw(e,i,t.right,o,t.currentAttributes);const a=(t.left||t.right).parent;return a._searchMarker&&Bb(a._searchMarker,t.index,-r+n),t};class uw extends wb{constructor(e,t,n){super(e,t),this.childListChanged=!1,this.keysChanged=new Set,n.forEach(e=>{null===e?this.childListChanged=!0:this.keysChanged.add(e)})}get changes(){if(null===this._changes){const e={keys:this.keys,delta:this.delta,added:new Set,deleted:new Set};this._changes=e}return this._changes}get delta(){if(null===this._delta){const e=this.target.doc,t=[];lb(e,e=>{const n=new Map,r=new Map;let o=this.target._start,i=null;const a={};let l="",s=0,c=0;const d=()=>{if(null!==i){let e=null;switch(i){case"delete":c>0&&(e={delete:c}),c=0;break;case"insert":("object"==typeof l||l.length>0)&&(e={insert:l},n.size>0&&(e.attributes={},n.forEach((t,n)=>{null!==t&&(e.attributes[n]=t)}))),l="";break;case"retain":s>0&&(e={retain:s},(e=>{for(const t in e)return!1;return!0})(a)||(e.attributes=lg({},a))),s=0}e&&t.push(e),i=null}};for(;null!==o;){switch(o.content.constructor){case Lw:case Ew:this.adds(o)?this.deletes(o)||(d(),i="insert",l=o.content.getContent()[0],d()):this.deletes(o)?("delete"!==i&&(d(),i="delete"),c+=1):o.deleted||("retain"!==i&&(d(),i="retain"),s+=1);break;case Tw:this.adds(o)?this.deletes(o)||("insert"!==i&&(d(),i="insert"),l+=o.content.str):this.deletes(o)?("delete"!==i&&(d(),i="delete"),c+=o.length):o.deleted||("retain"!==i&&(d(),i="retain"),s+=o.length);break;case Sw:{const{key:t,value:l}=o.content;if(this.adds(o)){if(!this.deletes(o)){const s=n.get(t)??null;Yb(s,l)?null!==l&&o.delete(e):("retain"===i&&d(),Yb(l,r.get(t)??null)?delete a[t]:a[t]=l)}}else if(this.deletes(o)){r.set(t,l);const e=n.get(t)??null;Yb(e,l)||("retain"===i&&d(),a[t]=e)}else if(!o.deleted){r.set(t,l);const n=a[t];void 0!==n&&(Yb(n,l)?null!==n&&o.delete(e):("retain"===i&&d(),null===l?delete a[t]:a[t]=l))}o.deleted||("insert"===i&&d(),nw(n,o.content));break}}o=o.right}for(d();t.length>0;){const e=t[t.length-1];if(void 0===e.retain||void 0!==e.attributes)break;t.pop()}}),this._delta=t}return this._delta}}class pw extends Mb{constructor(e){super(),this._pending=void 0!==e?[()=>this.insert(0,e)]:[],this._searchMarker=[],this._hasFormatting=!1}get length(){return this.doc??xb(),this._length}_integrate(e,t){super._integrate(e,t);try{this._pending.forEach(e=>e())}catch(hR){}this._pending=null}_copy(){return new pw}clone(){const e=new pw;return e.applyDelta(this.toDelta()),e}_callObserver(e,t){super._callObserver(e,t);const n=new uw(this,e,t);Nb(this,e,n),!e.local&&this._hasFormatting&&(e._needFormattingCleanup=!0)}toString(){this.doc??xb();let e="",t=this._start;for(;null!==t;)!t.deleted&&t.countable&&t.content.constructor===Tw&&(e+=t.content.str),t=t.right;return e}toJSON(){return this.toString()}applyDelta(e,{sanitize:t=!0}={}){null!==this.doc?lb(this.doc,n=>{const r=new Xb(null,this._start,0,new Map);for(let o=0;o<e.length;o++){const i=e[o];if(void 0!==i.insert){const a=t||"string"!=typeof i.insert||o!==e.length-1||null!==r.right||"\n"!==i.insert.slice(-1)?i.insert:i.insert.slice(0,-1);("string"!=typeof a||a.length>0)&&iw(n,this,r,a,i.attributes||{})}else void 0!==i.retain?aw(n,this,r,i.retain,i.attributes||{}):void 0!==i.delete&&dw(n,r,i.delete)}}):this._pending.push(()=>this.applyDelta(e))}toDelta(e,t,n){this.doc??xb();const r=[],o=new Map,i=this.doc;let a="",l=this._start;function s(){if(a.length>0){const e={};let t=!1;o.forEach((n,r)=>{t=!0,e[r]=n});const n={insert:a};t&&(n.attributes=e),r.push(n),a=""}}const c=()=>{for(;null!==l;){if(Uy(l,e)||void 0!==t&&Uy(l,t))switch(l.content.constructor){case Tw:{const r=o.get("ychange");void 0===e||Uy(l,e)?void 0===t||Uy(l,t)?void 0!==r&&(s(),o.delete("ychange")):void 0!==r&&r.user===l.id.client&&"added"===r.type||(s(),o.set("ychange",n?n("added",l.id):{type:"added"})):void 0!==r&&r.user===l.id.client&&"removed"===r.type||(s(),o.set("ychange",n?n("removed",l.id):{type:"removed"})),a+=l.content.str;break}case Lw:case Ew:{s();const e={insert:l.content.getContent()[0]};if(o.size>0){const t={};e.attributes=t,o.forEach((e,n)=>{t[n]=e})}r.push(e);break}case Sw:Uy(l,e)&&(s(),nw(o,l.content))}l=l.right}s()};return e||t?lb(i,n=>{e&&Gy(n,e),t&&Gy(n,t),c()},"cleanup"):c(),r}insert(e,t,n){if(t.length<=0)return;const r=this.doc;null!==r?lb(r,r=>{const o=ew(r,this,e,!n);n||(n={},o.currentAttributes.forEach((e,t)=>{n[t]=e})),iw(r,this,o,t,n)}):this._pending.push(()=>this.insert(e,t,n))}insertEmbed(e,t,n){const r=this.doc;null!==r?lb(r,r=>{const o=ew(r,this,e,!n);iw(r,this,o,t,n||{})}):this._pending.push(()=>this.insertEmbed(e,t,n||{}))}delete(e,t){if(0===t)return;const n=this.doc;null!==n?lb(n,n=>{dw(n,ew(n,this,e,!0),t)}):this._pending.push(()=>this.delete(e,t))}format(e,t,n){if(0===t)return;const r=this.doc;null!==r?lb(r,r=>{const o=ew(r,this,e,!1);null!==o.right&&aw(r,this,o,t,n)}):this._pending.push(()=>this.format(e,t,n))}removeAttribute(e){null!==this.doc?lb(this.doc,t=>{Hb(t,this,e)}):this._pending.push(()=>this.removeAttribute(e))}setAttribute(e,t){null!==this.doc?lb(this.doc,n=>{Fb(n,this,e,t)}):this._pending.push(()=>this.setAttribute(e,t))}getAttribute(e){return jb(this,e)}getAttributes(){return Ub(this)}_write(e){e.writeTypeRef(Ow)}}class hw{constructor(e,t=()=>!0){this._filter=t,this._root=e,this._currentNode=e._start,this._firstCall=!0,e.doc??xb()}[Symbol.iterator](){return this}next(){let e=this._currentNode,t=e&&e.content&&e.content.type;if(null!==e&&(!this._firstCall||e.deleted||!this._filter(t)))do{if(t=e.content.type,e.deleted||t.constructor!==fw&&t.constructor!==mw||null===t._start)for(;null!==e;){const t=e.next;if(null!==t){e=t;break}e=e.parent===this._root?null:e.parent._item}else e=t._start}while(null!==e&&(e.deleted||!this._filter(e.content.type)));return this._firstCall=!1,null===e?{value:void 0,done:!0}:(this._currentNode=e,{value:e.content.type,done:!1})}}class mw extends Mb{constructor(){super(),this._prelimContent=[]}get firstChild(){const e=this._first;return e?e.content.getContent()[0]:null}_integrate(e,t){super._integrate(e,t),this.insert(0,this._prelimContent),this._prelimContent=null}_copy(){return new mw}clone(){const e=new mw;return e.insert(0,this.toArray().map(e=>e instanceof Mb?e.clone():e)),e}get length(){return this.doc??xb(),null===this._prelimContent?this._length:this._prelimContent.length}createTreeWalker(e){return new hw(this,e)}querySelector(e){e=e.toUpperCase();const t=new hw(this,t=>t.nodeName&&t.nodeName.toUpperCase()===e).next();return t.done?null:t.value}querySelectorAll(e){return e=e.toUpperCase(),Pm(new hw(this,t=>t.nodeName&&t.nodeName.toUpperCase()===e))}_callObserver(e,t){Nb(this,e,new gw(this,t,e))}toString(){return Ob(this,e=>e.toString()).join("")}toJSON(){return this.toString()}toDOM(e=document,t={},n){const r=e.createDocumentFragment();return void 0!==n&&n._createAssociation(r,this),zb(this,o=>{r.insertBefore(o.toDOM(e,t,n),null)}),r}insert(e,t){null!==this.doc?lb(this.doc,n=>{Lb(n,this,e,t)}):this._prelimContent.splice(e,0,...t)}insertAfter(e,t){if(null!==this.doc)lb(this.doc,n=>{const r=e&&e instanceof Mb?e._item:e;Pb(n,this,r,t)});else{const n=this._prelimContent,r=null===e?0:n.findIndex(t=>t===e)+1;if(0===r&&null!==e)throw Mf("Reference item not found");n.splice(r,0,...t)}}delete(e,t=1){null!==this.doc?lb(this.doc,n=>{Rb(n,this,e,t)}):this._prelimContent.splice(e,t)}toArray(){return Vb(this)}push(e){this.insert(this.length,e)}unshift(e){this.insert(0,e)}get(e){return Db(this,e)}slice(e=0,t=this.length){return Tb(this,e,t)}forEach(e){zb(this,e)}_write(e){e.writeTypeRef(Dw)}}class fw extends mw{constructor(e="UNDEFINED"){super(),this.nodeName=e,this._prelimAttrs=new Map}get nextSibling(){const e=this._item?this._item.next:null;return e?e.content.type:null}get prevSibling(){const e=this._item?this._item.prev:null;return e?e.content.type:null}_integrate(e,t){super._integrate(e,t),this._prelimAttrs.forEach((e,t)=>{this.setAttribute(t,e)}),this._prelimAttrs=null}_copy(){return new fw(this.nodeName)}clone(){const e=new fw(this.nodeName);return((e,t)=>{for(const n in e)t(e[n],n)})(this.getAttributes(),(t,n)=>{e.setAttribute(n,t)}),e.insert(0,this.toArray().map(e=>e instanceof Mb?e.clone():e)),e}toString(){const e=this.getAttributes(),t=[],n=[];for(const i in e)n.push(i);n.sort();const r=n.length;for(let i=0;i<r;i++){const r=n[i];t.push(r+'="'+e[r]+'"')}const o=this.nodeName.toLocaleLowerCase();return`<${o}${t.length>0?" "+t.join(" "):""}>${super.toString()}</${o}>`}removeAttribute(e){null!==this.doc?lb(this.doc,t=>{Hb(t,this,e)}):this._prelimAttrs.delete(e)}setAttribute(e,t){null!==this.doc?lb(this.doc,n=>{Fb(n,this,e,t)}):this._prelimAttrs.set(e,t)}getAttribute(e){return jb(this,e)}hasAttribute(e){return Gb(this,e)}getAttributes(e){return e?((e,t)=>{const n={};return e._map.forEach((e,r)=>{let o=e;for(;null!==o&&(!t.sv.has(o.id.client)||o.id.clock>=(t.sv.get(o.id.client)||0));)o=o.left;null!==o&&Uy(o,t)&&(n[r]=o.content.getContent()[o.length-1])}),n})(this,e):Ub(this)}toDOM(e=document,t={},n){const r=e.createElement(this.nodeName),o=this.getAttributes();for(const i in o){const e=o[i];"string"==typeof e&&r.setAttribute(i,e)}return zb(this,o=>{r.appendChild(o.toDOM(e,t,n))}),void 0!==n&&n._createAssociation(r,this),r}_write(e){e.writeTypeRef(Iw),e.writeKey(this.nodeName)}}class gw extends wb{constructor(e,t,n){super(e,n),this.childListChanged=!1,this.attributesChanged=new Set,t.forEach(e=>{null===e?this.childListChanged=!0:this.attributesChanged.add(e)})}}class vw extends Jb{constructor(e){super(),this.hookName=e}_copy(){return new vw(this.hookName)}clone(){const e=new vw(this.hookName);return this.forEach((t,n)=>{e.set(n,t)}),e}toDOM(e=document,t={},n){const r=t[this.hookName];let o;return o=void 0!==r?r.createDom(this):document.createElement(this.hookName),o.setAttribute("data-yjs-hook",this.hookName),void 0!==n&&n._createAssociation(o,this),o}_write(e){e.writeTypeRef(Pw),e.writeKey(this.hookName)}}class yw extends pw{get nextSibling(){const e=this._item?this._item.next:null;return e?e.content.type:null}get prevSibling(){const e=this._item?this._item.prev:null;return e?e.content.type:null}_copy(){return new yw}clone(){const e=new yw;return e.applyDelta(this.toDelta()),e}toDOM(e=document,t,n){const r=e.createTextNode(this.toString());return void 0!==n&&n._createAssociation(r,this),r}toString(){return this.toDelta().map(e=>{const t=[];for(const r in e.attributes){const n=[];for(const t in e.attributes[r])n.push({key:t,value:e.attributes[r][t]});n.sort((e,t)=>e.key<t.key?-1:1),t.push({nodeName:r,attrs:n})}t.sort((e,t)=>e.nodeName<t.nodeName?-1:1);let n="";for(let r=0;r<t.length;r++){const e=t[r];n+=`<${e.nodeName}`;for(let t=0;t<e.attrs.length;t++){const r=e.attrs[t];n+=` ${r.key}="${r.value}"`}n+=">"}n+=e.insert;for(let r=t.length-1;r>=0;r--)n+=`</${t[r].nodeName}>`;return n}).join("")}toJSON(){return this.toString()}_write(e){e.writeTypeRef($w)}}class bw{constructor(e,t){this.id=e,this.length=t}get deleted(){throw Tf()}mergeWith(e){return!1}write(e,t,n){throw Tf()}integrate(e,t){throw Tf()}}class ww extends bw{get deleted(){return!0}delete(){}mergeWith(e){return this.constructor===e.constructor&&(this.length+=e.length,!0)}integrate(e,t){t>0&&(this.id.clock+=t,this.length-=t),Ky(e.doc.store,this)}write(e,t){e.writeInfo(0),e.writeLen(this.length-t)}getMissing(e,t){return null}}class kw{constructor(e){this.content=e}getLength(){return 1}getContent(){return[this.content]}isCountable(){return!0}copy(){return new kw(this.content)}splice(e){throw Tf()}mergeWith(e){return!1}integrate(e,t){}delete(e){}gc(e){}write(e,t){e.writeBuf(this.content)}getRef(){return 3}}class xw{constructor(e){this.len=e}getLength(){return this.len}getContent(){return[]}isCountable(){return!1}copy(){return new xw(this.len)}splice(e){const t=new xw(this.len-e);return this.len=e,t}mergeWith(e){return this.len+=e.len,!0}integrate(e,t){uy(e.deleteSet,t.id.client,t.id.clock,this.len),t.markDeleted()}delete(e){}gc(e){}write(e,t){e.writeLen(this.len-t)}getRef(){return 1}}const _w=(e,t)=>new gy({guid:e,...t,shouldLoad:t.shouldLoad||t.autoLoad||!1});class Cw{constructor(e){e._item,this.doc=e;const t={};this.opts=t,e.gc||(t.gc=!1),e.autoLoad&&(t.autoLoad=!0),null!==e.meta&&(t.meta=e.meta)}getLength(){return 1}getContent(){return[this.doc]}isCountable(){return!0}copy(){return new Cw(_w(this.doc.guid,this.opts))}splice(e){throw Tf()}mergeWith(e){return!1}integrate(e,t){this.doc._item=t,e.subdocsAdded.add(this.doc),this.doc.shouldLoad&&e.subdocsLoaded.add(this.doc)}delete(e){e.subdocsAdded.has(this.doc)?e.subdocsAdded.delete(this.doc):e.subdocsRemoved.add(this.doc)}gc(e){}write(e,t){e.writeString(this.doc.guid),e.writeAny(this.opts)}getRef(){return 9}}class Ew{constructor(e){this.embed=e}getLength(){return 1}getContent(){return[this.embed]}isCountable(){return!0}copy(){return new Ew(this.embed)}splice(e){throw Tf()}mergeWith(e){return!1}integrate(e,t){}delete(e){}gc(e){}write(e,t){e.writeJSON(this.embed)}getRef(){return 5}}class Sw{constructor(e,t){this.key=e,this.value=t}getLength(){return 1}getContent(){return[]}isCountable(){return!1}copy(){return new Sw(this.key,this.value)}splice(e){throw Tf()}mergeWith(e){return!1}integrate(e,t){const n=t.parent;n._searchMarker=null,n._hasFormatting=!0}delete(e){}gc(e){}write(e,t){e.writeKey(this.key),e.writeJSON(this.value)}getRef(){return 6}}class Bw{constructor(e){this.arr=e}getLength(){return this.arr.length}getContent(){return this.arr}isCountable(){return!0}copy(){return new Bw(this.arr)}splice(e){const t=new Bw(this.arr.slice(e));return this.arr=this.arr.slice(0,e),t}mergeWith(e){return this.arr=this.arr.concat(e.arr),!0}integrate(e,t){}delete(e){}gc(e){}write(e,t){const n=this.arr.length;e.writeLen(n-t);for(let r=t;r<n;r++){const t=this.arr[r];e.writeString(void 0===t?"undefined":JSON.stringify(t))}}getRef(){return 2}}const Nw="development"===wg("node_env");class Mw{constructor(e){this.arr=e,Nw&&hg(e)}getLength(){return this.arr.length}getContent(){return this.arr}isCountable(){return!0}copy(){return new Mw(this.arr)}splice(e){const t=new Mw(this.arr.slice(e));return this.arr=this.arr.slice(0,e),t}mergeWith(e){return this.arr=this.arr.concat(e.arr),!0}integrate(e,t){}delete(e){}gc(e){}write(e,t){const n=this.arr.length;e.writeLen(n-t);for(let r=t;r<n;r++){const t=this.arr[r];e.writeAny(t)}}getRef(){return 8}}class Tw{constructor(e){this.str=e}getLength(){return this.str.length}getContent(){return this.str.split("")}isCountable(){return!0}copy(){return new Tw(this.str)}splice(e){const t=new Tw(this.str.slice(e));this.str=this.str.slice(0,e);const n=this.str.charCodeAt(e-1);return n>=55296&&n<=56319&&(this.str=this.str.slice(0,e-1)+"�",t.str="�"+t.str.slice(1)),t}mergeWith(e){return this.str+=e.str,!0}integrate(e,t){}delete(e){}gc(e){}write(e,t){e.writeString(0===t?this.str:this.str.slice(t))}getRef(){return 4}}const Vw=[e=>new Wb,e=>new Jb,e=>new pw,e=>new fw(e.readKey()),e=>new mw,e=>new vw(e.readKey()),e=>new yw],Aw=0,zw=1,Ow=2,Iw=3,Dw=4,Pw=5,$w=6;class Lw{constructor(e){this.type=e}getLength(){return 1}getContent(){return[this.type]}isCountable(){return!0}copy(){return new Lw(this.type._copy())}splice(e){throw Tf()}mergeWith(e){return!1}integrate(e,t){this.type._integrate(e.doc,t)}delete(e){let t=this.type._start;for(;null!==t;)t.deleted?t.id.clock<(e.beforeState.get(t.id.client)||0)&&e._mergeStructs.push(t):t.delete(e),t=t.right;this.type._map.forEach(t=>{t.deleted?t.id.clock<(e.beforeState.get(t.id.client)||0)&&e._mergeStructs.push(t):t.delete(e)}),e.changed.delete(this.type)}gc(e){let t=this.type._start;for(;null!==t;)t.gc(e,!0),t=t.right;this.type._start=null,this.type._map.forEach(t=>{for(;null!==t;)t.gc(e,!0),t=t.left}),this.type._map=new Map}write(e,t){this.type._write(e)}getRef(){return 7}}const Rw=(e,t)=>{let n,r=t,o=0;do{o>0&&(r=zy(r.client,r.clock+o)),n=Yy(e,r),o=r.clock-n.id.clock,r=n.redone}while(null!==r&&n instanceof Gw);return{item:n,diff:o}},Hw=(e,t)=>{for(;null!==e&&e.keep!==t;)e.keep=t,e=e.parent._item},Fw=(e,t,n)=>{const{client:r,clock:o}=t.id,i=new Gw(zy(r,o+n),t,zy(r,o+n-1),t.right,t.rightOrigin,t.parent,t.parentSub,t.content.splice(n));return t.deleted&&i.markDeleted(),t.keep&&(i.keep=!0),null!==t.redone&&(i.redone=zy(t.redone.client,t.redone.clock+n)),t.right=i,null!==i.right&&(i.right.left=i),e._mergeStructs.push(i),null!==i.parentSub&&null===i.right&&i.parent._map.set(i.parentSub,i),t.length=n,i},jw=(e,t)=>Lm(e,e=>sy(e.deletions,t)),Uw=(e,t,n,r,o,i)=>{const a=e.doc,l=a.store,s=a.clientID,c=t.redone;if(null!==c)return Qy(e,c);let d,u=t.parent._item,p=null;if(null!==u&&!0===u.deleted){if(null===u.redone&&(!n.has(u)||null===Uw(e,u,n,r,o,i)))return null;for(;null!==u.redone;)u=Qy(e,u.redone)}const h=null===u?t.parent:u.content.type;if(null===t.parentSub){for(p=t.left,d=t;null!==p;){let t=p;for(;null!==t&&t.parent._item!==u;)t=null===t.redone?null:Qy(e,t.redone);if(null!==t&&t.parent._item===u){p=t;break}p=p.left}for(;null!==d;){let t=d;for(;null!==t&&t.parent._item!==u;)t=null===t.redone?null:Qy(e,t.redone);if(null!==t&&t.parent._item===u){d=t;break}d=d.right}}else if(d=null,t.right&&!o){for(p=t;null!==p&&null!==p.right&&(p.right.redone||sy(r,p.right.id)||jw(i.undoStack,p.right.id)||jw(i.redoStack,p.right.id));)for(p=p.right;p.redone;)p=Qy(e,p.redone);if(p&&null!==p.right)return null}else p=h._map.get(t.parentSub)||null;const m=Wy(l,s),f=zy(s,m),g=new Gw(f,p,p&&p.lastId,d,d&&d.id,h,t.parentSub,t.content.copy());return t.redone=f,Hw(g,!0),g.integrate(e,0),g};class Gw extends bw{constructor(e,t,n,r,o,i,a,l){super(e,l.getLength()),this.origin=n,this.left=t,this.right=r,this.rightOrigin=o,this.parent=i,this.parentSub=a,this.redone=null,this.content=l,this.info=this.content.isCountable()?2:0}set marker(e){(8&this.info)>0!==e&&(this.info^=8)}get marker(){return(8&this.info)>0}get keep(){return(1&this.info)>0}set keep(e){this.keep!==e&&(this.info^=1)}get countable(){return(2&this.info)>0}get deleted(){return(4&this.info)>0}set deleted(e){this.deleted!==e&&(this.info^=4)}markDeleted(){this.info|=4}getMissing(e,t){if(this.origin&&this.origin.client!==this.id.client&&this.origin.clock>=Wy(t,this.origin.client))return this.origin.client;if(this.rightOrigin&&this.rightOrigin.client!==this.id.client&&this.rightOrigin.clock>=Wy(t,this.rightOrigin.client))return this.rightOrigin.client;if(this.parent&&this.parent.constructor===Vy&&this.id.client!==this.parent.client&&this.parent.clock>=Wy(t,this.parent.client))return this.parent.client;if(this.origin&&(this.left=eb(e,t,this.origin),this.origin=this.left.lastId),this.rightOrigin&&(this.right=Qy(e,this.rightOrigin),this.rightOrigin=this.right.id),this.left&&this.left.constructor===ww||this.right&&this.right.constructor===ww)this.parent=null;else if(this.parent){if(this.parent.constructor===Vy){const e=Yy(t,this.parent);e.constructor===ww?this.parent=null:this.parent=e.content.type}}else this.left&&this.left.constructor===Gw?(this.parent=this.left.parent,this.parentSub=this.left.parentSub):this.right&&this.right.constructor===Gw&&(this.parent=this.right.parent,this.parentSub=this.right.parentSub);return null}integrate(e,t){if(t>0&&(this.id.clock+=t,this.left=eb(e,e.doc.store,zy(this.id.client,this.id.clock-1)),this.origin=this.left.lastId,this.content=this.content.splice(t),this.length-=t),this.parent){if(!this.left&&(!this.right||null!==this.right.left)||this.left&&this.left.right!==this.right){let t,n=this.left;if(null!==n)t=n.right;else if(null!==this.parentSub)for(t=this.parent._map.get(this.parentSub)||null;null!==t&&null!==t.left;)t=t.left;else t=this.parent._start;const r=new Set,o=new Set;for(;null!==t&&t!==this.right;){if(o.add(t),r.add(t),Ay(this.origin,t.origin)){if(t.id.client<this.id.client)n=t,r.clear();else if(Ay(this.rightOrigin,t.rightOrigin))break}else{if(null===t.origin||!o.has(Yy(e.doc.store,t.origin)))break;r.has(Yy(e.doc.store,t.origin))||(n=t,r.clear())}t=t.right}this.left=n}if(null!==this.left){const e=this.left.right;this.right=e,this.left.right=this}else{let e;if(null!==this.parentSub)for(e=this.parent._map.get(this.parentSub)||null;null!==e&&null!==e.left;)e=e.left;else e=this.parent._start,this.parent._start=this;this.right=e}null!==this.right?this.right.left=this:null!==this.parentSub&&(this.parent._map.set(this.parentSub,this),null!==this.left&&this.left.delete(e)),null===this.parentSub&&this.countable&&!this.deleted&&(this.parent._length+=this.length),Ky(e.doc.store,this),this.content.integrate(e,this),ob(e,this.parent,this.parentSub),(null!==this.parent._item&&this.parent._item.deleted||null!==this.parentSub&&null!==this.right)&&this.delete(e)}else new ww(this.id,this.length).integrate(e,0)}get next(){let e=this.right;for(;null!==e&&e.deleted;)e=e.right;return e}get prev(){let e=this.left;for(;null!==e&&e.deleted;)e=e.left;return e}get lastId(){return 1===this.length?this.id:zy(this.id.client,this.id.clock+this.length-1)}mergeWith(e){if(this.constructor===e.constructor&&Ay(e.origin,this.lastId)&&this.right===e&&Ay(this.rightOrigin,e.rightOrigin)&&this.id.client===e.id.client&&this.id.clock+this.length===e.id.clock&&this.deleted===e.deleted&&null===this.redone&&null===e.redone&&this.content.constructor===e.content.constructor&&this.content.mergeWith(e.content)){const t=this.parent._searchMarker;return t&&t.forEach(t=>{t.p===e&&(t.p=this,!this.deleted&&this.countable&&(t.index-=this.length))}),e.keep&&(this.keep=!0),this.right=e.right,null!==this.right&&(this.right.left=this),this.length+=e.length,!0}return!1}delete(e){if(!this.deleted){const t=this.parent;this.countable&&null===this.parentSub&&(t._length-=this.length),this.markDeleted(),uy(e.deleteSet,this.id.client,this.id.clock,this.length),ob(e,t,this.parentSub),this.content.delete(e)}}gc(e,t){if(!this.deleted)throw Vf();this.content.gc(e),t?((e,t,n)=>{const r=e.clients.get(t.id.client);r[Jy(r,t.id.clock)]=n})(e,this,new ww(this.id,this.length)):this.content=new xw(this.length)}write(e,t){const n=t>0?zy(this.id.client,this.id.clock+t-1):this.origin,r=this.rightOrigin,o=this.parentSub,i=31&this.content.getRef()|(null===n?0:Wm)|(null===r?0:Zm)|(null===o?0:32);if(e.writeInfo(i),null!==n&&e.writeLeftID(n),null!==r&&e.writeRightID(r),null===n&&null===r){const t=this.parent;if(void 0!==t._item){const n=t._item;if(null===n){const n=Oy(t);e.writeParentInfo(!0),e.writeString(n)}else e.writeParentInfo(!1),e.writeLeftID(n.id)}else t.constructor===String?(e.writeParentInfo(!0),e.writeString(t)):t.constructor===Vy?(e.writeParentInfo(!1),e.writeLeftID(t)):Vf();null!==o&&e.writeString(o)}this.content.write(e,t)}}const qw=(e,t)=>Zw[31&t](e),Zw=[()=>{Vf()},e=>new xw(e.readLen()),e=>{const t=e.readLen(),n=[];for(let r=0;r<t;r++){const t=e.readString();"undefined"===t?n.push(void 0):n.push(JSON.parse(t))}return new Bw(n)},e=>new kw(e.readBuf()),e=>new Tw(e.readString()),e=>new Ew(e.readJSON()),e=>new Sw(e.readKey(),e.readJSON()),e=>new Lw(Vw[e.readTypeRef()](e)),e=>{const t=e.readLen(),n=[];for(let r=0;r<t;r++)n.push(e.readAny());return new Mw(n)},e=>new Cw(_w(e.readString(),e.readAny())),()=>{Vf()}];class Ww extends bw{get deleted(){return!0}delete(){}mergeWith(e){return this.constructor===e.constructor&&(this.length+=e.length,!0)}integrate(e,t){Vf()}write(e,t){e.writeInfo(10),hf(e.restEncoder,this.length-t)}getMissing(e,t){return null}}const Kw="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},Jw="__ $YJS$ __";Kw[Jw],Kw[Jw]=!0;const Yw=/[\uD800-\uDBFF]/,Xw=/[\uDC00-\uDFFF]/,Qw=(e,t)=>{let n=0,r=0;for(;n<e.length&&n<t.length&&e[n]===t[n];)n++;for(n>0&&Yw.test(e[n-1])&&n--;r+n<e.length&&r+n<t.length&&e[e.length-r-1]===t[t.length-r-1];)r++;return r>0&&Xw.test(e[e.length-r])&&r--,{index:n,remove:e.length-n-r,insert:t.slice(n,t.length-r)}},ek=(e,t)=>e>>>t|e<<32-t,tk=e=>ek(e,2)^ek(e,13)^ek(e,22),nk=e=>ek(e,6)^ek(e,11)^ek(e,25),rk=e=>ek(e,7)^ek(e,18)^e>>>3,ok=e=>ek(e,17)^ek(e,19)^e>>>10,ik=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),ak=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]);class lk{constructor(){const e=new ArrayBuffer(320);this._H=new Uint32Array(e,0,8),this._H.set(ak),this._W=new Uint32Array(e,64,64)}_updateHash(){const e=this._H,t=this._W;for(let d=16;d<64;d++)t[d]=ok(t[d-2])+t[d-7]+rk(t[d-15])+t[d-16];let n=e[0],r=e[1],o=e[2],i=e[3],a=e[4],l=e[5],s=e[6],c=e[7];for(let d,u,p=0;p<64;p++)d=c+nk(a)+(a&l^~a&s)+ik[p]+t[p]>>>0,u=tk(n)+(n&r^n&o^r&o)>>>0,c=s,s=l,l=a,a=i+d>>>0,i=o,o=r,r=n,n=d+u>>>0;e[0]+=n,e[1]+=r,e[2]+=o,e[3]+=i,e[4]+=a,e[5]+=l,e[6]+=s,e[7]+=c}digest(e){let t=0;for(;t+56<=e.length;){let n=0;for(;n<16&&t+3<e.length;n++)this._W[n]=e[t++]<<24|e[t++]<<16|e[t++]<<8|e[t++];if(t%64!=0){for(this._W.fill(0,n,16);t<e.length;)this._W[n]|=e[t]<<8*(3-t%4),t++;this._W[n]|=Wm<<8*(3-t%4)}this._updateHash()}const n=t%64!=0;this._W.fill(0,0,16);let r=0;for(;t<e.length;r++)for(let n=3;n>=0&&t<e.length;n--)this._W[r]|=e[t++]<<8*n;n||(this._W[r-(t%4==0?0:1)]|=Wm<<8*(3-t%4)),this._W[14]=e.byteLength/536870912,this._W[15]=8*e.byteLength,this._updateHash();const o=new Uint8Array(32);for(let i=0;i<this._H.length;i++)for(let e=0;e<4;e++)o[4*i+e]=this._H[i]>>>8*(3-e);return o}}const sk=new oo("y-sync"),ck=new oo("y-undo");new oo("yjs-cursor");const dk=e=>{return Cg((e=>{for(let t=6;t<e.length;t++)e[t%6]=e[t%6]^e[t];return e.slice(0,6)})((t=Eg(e),(new lk).digest(t))));var t},uk=(e,t)=>void 0===t?!e.deleted:t.sv.has(e.id.client)&&t.sv.get(e.id.client)>e.id.clock&&!sy(t.ds,e.id),pk=[{light:"#ecd44433",dark:"#ecd444"}],hk=(e,t,n)=>{if(!e.has(n)){if(e.size<t.length){const n=Om();e.forEach(e=>n.add(e)),t=t.filter(e=>!n.has(e))}e.set(n,(r=t)[Fm(Kf()*r.length)])}var r;return e.get(n)},mk=(e,t)=>{const n=e.doc.resolve(t);return n.nodeAfter?qr.create(e.doc,t):Ur.near(n)},fk=(e,t)=>({type:t.selection.jsonID,anchor:Ik(t.selection.anchor,e.type,e.mapping),head:Ik(t.selection.head,e.type,e.mapping)});class gk{constructor(e,t=new Map){this.type=e,this.prosemirrorView=null,this.mux=(()=>{let e=!0;return(t,n)=>{if(e){e=!1;try{t()}finally{e=!0}}else void 0!==n&&n()}})(),this.mapping=t,this.isOMark=new Map,this._observeFunction=this._typeChanged.bind(this),this.doc=e.doc,this.beforeTransactionSelection=null,this.beforeAllTransactions=()=>{null===this.beforeTransactionSelection&&null!=this.prosemirrorView&&(this.beforeTransactionSelection=fk(this,this.prosemirrorView.state))},this.afterAllTransactions=()=>{this.beforeTransactionSelection=null},this._domSelectionInView=null}get _tr(){return this.prosemirrorView.state.tr.setMeta("addToHistory",!1)}_isLocalCursorInView(){return!!this.prosemirrorView.hasFocus()&&(vg&&null===this._domSelectionInView&&(Uv(0,()=>{this._domSelectionInView=null}),this._domSelectionInView=this._isDomSelectionInView()),this._domSelectionInView)}_isDomSelectionInView(){const e=this.prosemirrorView._root.getSelection();if(null==e||null==e.anchorNode)return!1;const t=this.prosemirrorView._root.createRange();t.setStart(e.anchorNode,e.anchorOffset),t.setEnd(e.focusNode,e.focusOffset);0===t.getClientRects().length&&t.startContainer&&t.collapsed&&t.selectNodeContents(t.startContainer);const n=t.getBoundingClientRect(),r=Pv.documentElement;return n.bottom>=0&&n.right>=0&&n.left<=(window.innerWidth||r.clientWidth||0)&&n.top<=(window.innerHeight||r.clientHeight||0)}renderSnapshot(e,t){t||(t=Fy(py(),new Map)),this.prosemirrorView.dispatch(this._tr.setMeta(sk,{snapshot:e,prevSnapshot:t}))}unrenderSnapshot(){this.mapping.clear(),this.mux(()=>{const e=this.type.toArray().map(e=>yk(e,this.prosemirrorView.state.schema,this)).filter(e=>null!==e),t=this._tr.replace(0,this.prosemirrorView.state.doc.content.size,new Zt(Ht.from(e),0,0));t.setMeta(sk,{snapshot:null,prevSnapshot:null}),this.prosemirrorView.dispatch(t)})}_forceRerender(){this.mapping.clear(),this.mux(()=>{const e=null!==this.beforeTransactionSelection?null:this.prosemirrorView.state.selection,t=this.type.toArray().map(e=>yk(e,this.prosemirrorView.state.schema,this)).filter(e=>null!==e),n=this._tr.replace(0,this.prosemirrorView.state.doc.content.size,new Zt(Ht.from(t),0,0));if(e){const t=Um(Gm(e.anchor,0),n.doc.content.size),r=Um(Gm(e.head,0),n.doc.content.size);n.setSelection(Ur.create(n.doc,t,r))}this.prosemirrorView.dispatch(n.setMeta(sk,{isChangeOrigin:!0,binding:this}))})}_renderSnapshot(e,t,n){let r=this.doc,o=this.type;if(e||(e=jy(this.doc)),e instanceof Uint8Array||t instanceof Uint8Array)if(e instanceof Uint8Array&&t instanceof Uint8Array||Vf(),r=new gy({gc:!1}),Ey(r,t),t=jy(r),Ey(r,e),e=jy(r),null===o._item){const e=Array.from(this.doc.share.keys()).find(e=>this.doc.share.get(e)===this.type);o=r.getXmlFragment(e)}else{const e=r.store.clients.get(o._item.id.client)??[],t=e[Jy(e,o._item.id.clock)].content;o=t.type}this.mapping.clear(),this.mux(()=>{r.transact(r=>{const i=n.permanentUserData;i&&i.dss.forEach(e=>{ly(r,e,e=>{})});const a=(e,t)=>{const r="added"===e?i.getUserByClientId(t.client):i.getUserByDeletedId(t);return{user:r,type:e,color:hk(n.colorMapping,n.colors,r)}},l=Ab(o,new Hy(t.ds,e.sv)).map(n=>!n._item.deleted||uk(n._item,e)||uk(n._item,t)?yk(n,this.prosemirrorView.state.schema,{mapping:new Map,isOMark:new Map},e,t,a):null).filter(e=>null!==e),s=this._tr.replace(0,this.prosemirrorView.state.doc.content.size,new Zt(Ht.from(l),0,0));this.prosemirrorView.dispatch(s.setMeta(sk,{isChangeOrigin:!0}))},sk)})}_typeChanged(e,t){if(null==this.prosemirrorView)return;const n=sk.getState(this.prosemirrorView.state);0!==e.length&&null==n.snapshot&&null==n.prevSnapshot?this.mux(()=>{const e=(e,t)=>this.mapping.delete(t);ly(t,t.deleteSet,e=>{if(e.constructor===Gw){const t=e.content.type;t&&this.mapping.delete(t)}}),t.changed.forEach(e),t.changedParentTypes.forEach(e);const n=this.type.toArray().map(e=>vk(e,this.prosemirrorView.state.schema,this)).filter(e=>null!==e);let r=this._tr.replace(0,this.prosemirrorView.state.doc.content.size,new Zt(Ht.from(n),0,0));((e,t,n)=>{if(null!==t&&null!==t.anchor&&null!==t.head)if("all"===t.type)e.setSelection(new Wr(e.doc));else if("node"===t.type){const r=Pk(n.doc,n.type,t.anchor,n.mapping);e.setSelection(mk(e,r))}else{const r=Pk(n.doc,n.type,t.anchor,n.mapping),o=Pk(n.doc,n.type,t.head,n.mapping);null!==r&&null!==o&&e.setSelection(Ur.between(e.doc.resolve(r),e.doc.resolve(o)))}})(r,this.beforeTransactionSelection,this),r=r.setMeta(sk,{isChangeOrigin:!0,isUndoRedoOperation:t.origin instanceof ub}),null!==this.beforeTransactionSelection&&this._isLocalCursorInView()&&r.scrollIntoView(),this.prosemirrorView.dispatch(r)}):this.renderSnapshot(n.snapshot,n.prevSnapshot)}_prosemirrorChanged(e){this.doc.transact(()=>{zk(this.doc,this.type,e,this),this.beforeTransactionSelection=fk(this,this.prosemirrorView.state)},sk)}initView(e){null!=this.prosemirrorView&&this.destroy(),this.prosemirrorView=e,this.doc.on("beforeAllTransactions",this.beforeAllTransactions),this.doc.on("afterAllTransactions",this.afterAllTransactions),this.type.observeDeep(this._observeFunction)}destroy(){null!=this.prosemirrorView&&(this.prosemirrorView=null,this.type.unobserveDeep(this._observeFunction),this.doc.off("beforeAllTransactions",this.beforeAllTransactions),this.doc.off("afterAllTransactions",this.afterAllTransactions))}}const vk=(e,t,n,r,o,i)=>{const a=n.mapping.get(e);if(void 0===a){if(e instanceof fw)return yk(e,t,n,r,o,i);throw Tf()}return a},yk=(e,t,n,r,o,i)=>{const a=[],l=e=>{var l,s;if(e instanceof fw){const l=vk(e,t,n,r,o,i);null!==l&&a.push(l)}else{const c=null==(s=null==(l=e._item.right)?void 0:l.content)?void 0:s.type;c instanceof pw&&!c._item.deleted&&c._item.id.client===c.doc.clientID&&(e.applyDelta([{retain:e.length},...c.toDelta()]),c.doc.transact(e=>{c._item.delete(e)}));const d=bk(e,t,n,r,o,i);null!==d&&d.forEach(e=>{null!==e&&a.push(e)})}};void 0===r||void 0===o?e.toArray().forEach(l):Ab(e,new Hy(o.ds,r.sv)).forEach(l);try{const l=e.getAttributes(r);void 0!==r&&(uk(e._item,r)?uk(e._item,o)||(l.ychange=i?i("added",e._item.id):{type:"added"}):l.ychange=i?i("removed",e._item.id):{type:"removed"});const s=t.node(e.nodeName,l,a);return n.mapping.set(e,s),s}catch(hR){return e.doc.transact(t=>{e._item.delete(t)},sk),n.mapping.delete(e),null}},bk=(e,t,n,r,o,i)=>{const a=[],l=e.toDelta(r,o,i);try{for(let e=0;e<l.length;e++){const n=l[e];a.push(t.text(n.insert,Vk(n.attributes,t)))}}catch(hR){return e.doc.transact(t=>{e._item.delete(t)},sk),null}return a},wk=(e,t)=>e instanceof Array?((e,t)=>{const n=new yw,r=e.map(e=>({insert:e.text,attributes:Ak(e.marks,t)}));return n.applyDelta(r),t.mapping.set(n,e),n})(e,t):((e,t)=>{const n=new fw(e.type.name);for(const r in e.attrs){const t=e.attrs[r];null!==t&&"ychange"!==r&&n.setAttribute(r,t)}return n.insert(0,_k(e).map(e=>wk(e,t))),t.mapping.set(n,e),n})(e,t),kk=e=>"object"==typeof e&&null!==e,xk=(e,t)=>{const n=Object.keys(e).filter(t=>null!==e[t]);let r=n.length===Object.keys(t).filter(e=>null!==t[e]).length;for(let o=0;o<n.length&&r;o++){const i=n[o],a=e[i],l=t[i];r="ychange"===i||a===l||kk(a)&&kk(l)&&xk(a,l)}return r},_k=e=>{const t=e.content.content,n=[];for(let r=0;r<t.length;r++){const e=t[r];if(e.isText){const e=[];for(let n=t[r];r<t.length&&n.isText;n=t[++r])e.push(n);r--,n.push(e)}else n.push(e)}return n},Ck=(e,t)=>{const n=e.toDelta();return n.length===t.length&&n.every((e,n)=>e.insert===t[n].text&&sg(e.attributes||{}).length===t[n].marks.length&&dg(e.attributes,(e,r)=>{var o;const i=Tk(r),a=t[n].marks;return!!a.find(e=>e.type.name===i)&&xk(e,null==(o=a.find(e=>e.type.name===i))?void 0:o.attrs)}))},Ek=(e,t)=>{if(e instanceof fw&&!(t instanceof Array)&&Ok(e,t)){const n=_k(t);return e._length===n.length&&xk(e.getAttributes(),t.attrs)&&e.toArray().every((e,t)=>Ek(e,n[t]))}return e instanceof yw&&t instanceof Array&&Ck(e,t)},Sk=(e,t)=>e===t||e instanceof Array&&t instanceof Array&&e.length===t.length&&e.every((e,n)=>t[n]===e),Bk=(e,t,n)=>{const r=e.toArray(),o=_k(t),i=o.length,a=r.length,l=Um(a,i);let s=0,c=0,d=!1;for(;s<l;s++){const e=r[s],t=o[s];if(Sk(n.mapping.get(e),t))d=!0;else if(!Ek(e,t))break}for(;s+c<l;c++){const e=r[a-c-1],t=o[i-c-1];if(Sk(n.mapping.get(e),t))d=!0;else if(!Ek(e,t))break}return{equalityFactor:s+c,foundMappedChild:d}},Nk=(e,t,n)=>{n.mapping.set(e,t);const{nAttrs:r,str:o}=(e=>{let t="",n=e._start;const r={};for(;null!==n;)n.deleted||(n.countable&&n.content instanceof Tw?t+=n.content.str:n.content instanceof Sw&&(r[n.content.key]=null)),n=n.right;return{str:t,nAttrs:r}})(e),i=t.map(e=>({insert:e.text,attributes:Object.assign({},r,Ak(e.marks,n))})),{insert:a,remove:l,index:s}=Qw(o,i.map(e=>e.insert).join(""));e.delete(s,l),e.insert(s,a),e.applyDelta(i.map(e=>({retain:e.insert.length,attributes:e.attributes})))},Mk=/(.*)(--[a-zA-Z0-9+/=]{8})$/,Tk=e=>{var t;return(null==(t=Mk.exec(e))?void 0:t[1])??e},Vk=(e,t)=>{const n=[];for(const r in e)n.push(t.mark(Tk(r),e[r]));return n},Ak=(e,t)=>{const n={};return e.forEach(e=>{if("ychange"!==e.type.name){const r=zm(t.isOMark,e.type,()=>!e.type.excludes(e.type));n[r?`${e.type.name}--${dk(e.toJSON())}`:e.type.name]=e.attrs}}),n},zk=(e,t,n,r)=>{if(t instanceof fw&&t.nodeName!==n.type.name)throw new Error("node name mismatch!");if(r.mapping.set(t,n),t instanceof fw){const e=t.getAttributes(),r=n.attrs;for(const n in r)null!==r[n]?e[n]!==r[n]&&"ychange"!==n&&t.setAttribute(n,r[n]):t.removeAttribute(n);for(const n in e)void 0===r[n]&&t.removeAttribute(n)}const o=_k(n),i=o.length,a=t.toArray(),l=a.length,s=Um(i,l);let c=0,d=0;for(;c<s;c++){const e=a[c],t=o[c];if(!Sk(r.mapping.get(e),t)){if(!Ek(e,t))break;r.mapping.set(e,t)}}for(;d+c+1<s;d++){const e=a[l-d-1],t=o[i-d-1];if(!Sk(r.mapping.get(e),t)){if(!Ek(e,t))break;r.mapping.set(e,t)}}e.transact(()=>{for(;l-c-d>0&&i-c-d>0;){const n=a[c],s=o[c],u=a[l-d-1],p=o[i-d-1];if(n instanceof yw&&s instanceof Array)Ck(n,s)||Nk(n,s,r),c+=1;else{let o=n instanceof fw&&Ok(n,s),i=u instanceof fw&&Ok(u,p);if(o&&i){const e=Bk(n,s,r),t=Bk(u,p,r);e.foundMappedChild&&!t.foundMappedChild?i=!1:!e.foundMappedChild&&t.foundMappedChild||e.equalityFactor<t.equalityFactor?o=!1:i=!1}o?(zk(e,n,s,r),c+=1):i?(zk(e,u,p,r),d+=1):(r.mapping.delete(t.get(c)),t.delete(c,1),t.insert(c,[wk(s,r)]),c+=1)}}const n=l-c-d;if(1===l&&0===i&&a[0]instanceof yw?(r.mapping.delete(a[0]),a[0].delete(0,a[0].length)):n>0&&(t.slice(c,c+n).forEach(e=>r.mapping.delete(e)),t.delete(c,n)),c+d<i){const e=[];for(let t=c;t<i-d;t++)e.push(wk(o[t],r));t.insert(c,e)}},sk)},Ok=(e,t)=>!(t instanceof Array)&&e.nodeName===t.type.name,Ik=(e,t,n)=>{if(0===e)return Ly(t,0,-1);let r=null===t._first?null:t._first.content.type;for(;null!==r&&t!==r;){if(r instanceof yw){if(r._length>=e)return Ly(r,e,-1);if(e-=r._length,null!==r._item&&null!==r._item.next)r=r._item.next.content.type;else{do{r=null===r._item?null:r._item.parent,e--}while(r!==t&&null!==r&&null!==r._item&&null===r._item.next);null!==r&&r!==t&&(r=null===r._item?null:r._item.next.content.type)}}else{const o=(n.get(r)||{nodeSize:0}).nodeSize;if(null!==r._first&&e<o)r=r._first.content.type,e--;else{if(1===e&&0===r._length&&o>1)return new Dy(null===r._item?null:r._item.id,null===r._item?Oy(r):null,null);if(e-=o,null!==r._item&&null!==r._item.next)r=r._item.next.content.type;else{if(0===e)return r=null===r._item?r:r._item.parent,new Dy(null===r._item?null:r._item.id,null===r._item?Oy(r):null,null);do{r=r._item.parent,e--}while(r!==t&&null===r._item.next);r!==t&&(r=r._item.next.content.type)}}}if(null===r)throw Vf();if(0===e&&r.constructor!==yw&&r!==t)return Dk(r._item.parent,r._item)}return Ly(t,t._length,-1)},Dk=(e,t)=>{let n=null,r=null;return null===e._item?r=Oy(e):n=zy(e._item.id.client,e._item.id.clock),new Dy(n,r,t.id)},Pk=(e,t,n,r)=>{const o=Ry(n,e);if(null===o||o.type!==t&&!Iy(t,o.type._item))return null;let i=o.type,a=0;if(i.constructor===yw)a=o.index;else if(null===i._item||!i._item.deleted){let e=i._first,t=0;for(;t<i._length&&t<o.index&&null!==e;){if(!e.deleted){const n=e.content.type;t++,a+=n instanceof yw?n._length:r.get(n).nodeSize}e=e.right}a+=1}for(;i!==t&&null!==i._item;){const e=i._item.parent;if(null===e._item||!e._item.deleted){a+=1;let t=e._first;for(;null!==t;){const e=t.content.type;if(e===i)break;t.deleted||(a+=e instanceof yw?e._length:r.get(e).nodeSize),t=t.right}}i=e}return a-1};const $k=new Set(["paragraph"]),Lk=({protectedNodes:e=$k,trackedOrigins:t=[],undoManager:n=null}={})=>new to({key:ck,state:{init:(r,o)=>{const i=sk.getState(o),a=n||new ub(i.type,{trackedOrigins:new Set([sk].concat(t)),deleteFilter:t=>((e,t)=>!(e instanceof Gw&&e.content instanceof Lw&&(e.content.type instanceof pw||e.content.type instanceof fw&&t.has(e.content.type.nodeName))&&0!==e.content.type._length))(t,e),captureTransaction:e=>!1!==e.meta.get("addToHistory")});return{undoManager:a,prevSel:null,hasUndoOps:a.undoStack.length>0,hasRedoOps:a.redoStack.length>0}},apply:(e,t,n,r)=>{const o=sk.getState(r).binding,i=t.undoManager,a=i.undoStack.length>0,l=i.redoStack.length>0;return o?{undoManager:i,prevSel:fk(o,n),hasUndoOps:a,hasRedoOps:l}:a!==t.hasUndoOps||l!==t.hasRedoOps?Object.assign({},t,{hasUndoOps:i.undoStack.length>0,hasRedoOps:i.redoStack.length>0}):t}},view:e=>{const t=sk.getState(e.state),n=ck.getState(e.state).undoManager;return n.on("stack-item-added",({stackItem:n})=>{const r=t.binding;r&&n.meta.set(r,ck.getState(e.state).prevSel)}),n.on("stack-item-popped",({stackItem:e})=>{const n=t.binding;n&&(n.beforeTransactionSelection=e.meta.get(n)||n.beforeTransactionSelection)}),{destroy:()=>{n.destroy()}}}});function Rk(e){return!!e.getMeta(sk)}function Hk(e,t){const n=sk.getState(e);return Ik(t,n.type,n.binding.mapping)}var Fk=class e extends rs{constructor(e,t){super(e),this.yRelativePosition=t}static fromJSON(t){return new e(t.position,t.yRelativePosition)}toJSON(){return{position:this.position,yRelativePosition:this.yRelativePosition}}};function jk(e,t,n){const r=e instanceof Fk?e.yRelativePosition:null;if(Rk(t)&&r){const e=function(e,t){const n=sk.getState(e);return Pk(n.doc,n.type,t,n.binding.mapping)||0}(n,r);return{position:new Fk(e,r),mapResult:null}}const o=function(e,t){const n=t.mapping.mapResult(e.position);return{position:new rs(n.pos),mapResult:n}}(e,t),i=o.position.position;return{position:new Fk(i,null!=r?r:Hk(n,i)),mapResult:o.mapResult}}function Uk(e){if(!e.length)return ha.empty;const t=[],n=e[0].$from.node(0);return e.forEach(e=>{const n=e.$from.pos,r=e.$from.nodeAfter;r&&t.push(da.node(n,n+r.nodeSize,{class:"ProseMirror-selectednoderange"}))}),ha.create(n,t)}function Gk(e,t,n){const r=[],o=e.node(0);"number"==typeof n&&n>=0||(n=e.sameParent(t)?Math.max(0,e.sharedDepth(t.pos)-1):e.sharedDepth(t.pos));const i=new dn(e,t,n),a=0===i.depth?0:o.resolve(i.start).posAtIndex(0);return i.parent.forEach((e,t)=>{const n=a+t,l=n+e.nodeSize;if(n<i.start||n>=i.end)return;const s=new Hr(o.resolve(n),o.resolve(l));r.push(s)}),r}Os.create({name:"collaboration",priority:1e3,addOptions:()=>({document:null,field:"default",fragment:null,provider:null}),addStorage:()=>({isDisabled:!1}),onCreate(){this.editor.extensionManager.extensions.find(e=>"undoRedo"===e.name)},onBeforeCreate(){this.editor.utils.getUpdatedPosition=(e,t)=>jk(e,t,this.editor.state),this.editor.utils.createMappablePosition=e=>function(e,t){const n=Hk(t,e);return new Fk(e,n)}(e,this.editor.state)},addCommands:()=>({undo:()=>({tr:e,state:t,dispatch:n})=>{e.setMeta("preventDispatch",!0);return 0!==ck.getState(t).undoManager.undoStack.length&&(!n||(e=>{const t=ck.getState(e).undoManager;if(null!=t)return t.undo(),!0})(t))},redo:()=>({tr:e,state:t,dispatch:n})=>{e.setMeta("preventDispatch",!0);return 0!==ck.getState(t).undoManager.redoStack.length&&(!n||(e=>{const t=ck.getState(e).undoManager;if(null!=t)return t.redo(),!0})(t))}}),addKeyboardShortcuts(){return{"Mod-z":()=>this.editor.commands.undo(),"Mod-y":()=>this.editor.commands.redo(),"Shift-Mod-z":()=>this.editor.commands.redo()}},addProseMirrorPlugins(){var e;const t=this.options.fragment?this.options.fragment:this.options.document.getXmlFragment(this.options.field),n=Lk(this.options.yUndoOptions),r=n.spec.view;n.spec.view=e=>{const{undoManager:t}=ck.getState(e.state);t.restore&&(t.restore(),t.restore=()=>{});const n=r?r(e):void 0;return{destroy:()=>{const e=t.trackedOrigins.has(t),r=t._observers;t.restore=()=>{e&&t.trackedOrigins.add(t),t.doc.on("afterTransaction",t.afterTransactionHandler),t._observers=r},(null==n?void 0:n.destroy)&&n.destroy()}}};const o={...this.options.ySyncOptions,onFirstRender:this.options.onFirstRender},i=((e,{colors:t=pk,colorMapping:n=new Map,permanentUserData:r=null,onFirstRender:o=()=>{},mapping:i}={})=>{let a=!1;const l=new gk(e,i),s=new to({props:{editable:e=>{const t=sk.getState(e);return null==t.snapshot&&null==t.prevSnapshot}},key:sk,state:{init:(o,i)=>({type:e,doc:e.doc,binding:l,snapshot:null,prevSnapshot:null,isChangeOrigin:!1,isUndoRedoOperation:!1,addToHistory:!0,colors:t,colorMapping:n,permanentUserData:r}),apply:(e,t)=>{const n=e.getMeta(sk);if(void 0!==n){t=Object.assign({},t);for(const e in n)t[e]=n[e]}return t.addToHistory=!1!==e.getMeta("addToHistory"),t.isChangeOrigin=void 0!==n&&!!n.isChangeOrigin,t.isUndoRedoOperation=void 0!==n&&!!n.isChangeOrigin&&!!n.isUndoRedoOperation,null!==l.prosemirrorView&&(void 0===n||null==n.snapshot&&null==n.prevSnapshot||Uv(0,()=>{null!=l.prosemirrorView&&(null==n.restore?l._renderSnapshot(n.snapshot,n.prevSnapshot,t):(l._renderSnapshot(n.snapshot,n.snapshot,t),delete t.restore,delete t.snapshot,delete t.prevSnapshot,l.mux(()=>{l._prosemirrorChanged(l.prosemirrorView.state.doc)})))})),t}},view:e=>(l.initView(e),null==i&&l._forceRerender(),o(),{update:()=>{const t=s.getState(e.state);if(null==t.snapshot&&null==t.prevSnapshot&&(a||null!==e.state.doc.content.findDiffStart(e.state.doc.type.createAndFill().content))){if(a=!0,!1===t.addToHistory&&!t.isChangeOrigin){const t=ck.getState(e.state),n=t&&t.undoManager;n&&n.stopCapturing()}l.mux(()=>{t.doc.transact(n=>{n.meta.set("addToHistory",t.addToHistory),l._prosemirrorChanged(e.state.doc)},sk)})}},destroy:()=>{l.destroy()}})});return s})(t,o);return this.editor.options.enableContentCheck&&(null==(e=t.doc)||e.on("beforeTransaction",()=>{try{const e=function(e){const t=e.toArray(),n=e=>{let t;if(e instanceof yw)t=e.toDelta().map(e=>{const t={type:"text",text:e.insert};return e.attributes&&(t.marks=Object.keys(e.attributes).map(t=>{const n=e.attributes[t],r={type:Tk(t)};return Object.keys(n)&&(r.attrs=n),r})),t});else if(e instanceof fw){t={type:e.nodeName};const r=e.getAttributes();Object.keys(r).length&&(t.attrs=r);const o=e.toArray();o.length&&(t.content=o.map(n).flat())}else Vf();return t};return{type:"doc",content:t.map(n)}}(t);if(0===e.content.length)return;this.editor.schema.nodeFromJSON(e).check()}catch(e){return this.editor.emit("contentError",{error:e,editor:this.editor,disableCollaboration:()=>{var e;null==(e=t.doc)||e.destroy(),this.storage.isDisabled=!0}}),!1}})),[i,n,this.editor.options.enableContentCheck&&new to({key:new oo("filterInvalidContent"),filterTransaction:()=>{var e;return!1===this.storage.isDisabled||(null==(e=t.doc)||e.destroy(),!0)}})].filter(Boolean)}});var qk=class e{constructor(e,t){this.anchor=e,this.head=t}map(t){return new e(t.map(this.anchor),t.map(this.head))}resolve(e){const t=e.resolve(this.anchor),n=e.resolve(this.head);return new Zk(t,n)}},Zk=class e extends Rr{constructor(e,t,n,r=1){const{doc:o}=e,i=e===t,a=e.pos===o.content.size&&t.pos===o.content.size,l=i&&!a?o.resolve(t.pos+(r>0?1:-1)):t,s=i&&a?o.resolve(e.pos-(r>0?1:-1)):e,c=Gk(s.min(l),s.max(l),n);super(l.pos>=e.pos?c[0].$from:c[c.length-1].$to,l.pos>=e.pos?c[c.length-1].$to:c[0].$from,c),this.depth=n}get $to(){return this.ranges[this.ranges.length-1].$to}eq(t){return t instanceof e&&t.$from.pos===this.$from.pos&&t.$to.pos===this.$to.pos}map(t,n){const r=t.resolve(n.map(this.anchor)),o=t.resolve(n.map(this.head));return new e(r,o)}toJSON(){return{type:"nodeRange",anchor:this.anchor,head:this.head}}get isForwards(){return this.head>=this.anchor}get isBackwards(){return!this.isForwards}extendBackwards(){const{doc:t}=this.$from;if(this.isForwards&&this.ranges.length>1){const t=this.ranges.slice(0,-1),n=t[0].$from,r=t[t.length-1].$to;return new e(n,r,this.depth)}const n=this.ranges[0],r=t.resolve(Math.max(0,n.$from.pos-1));return new e(this.$anchor,r,this.depth)}extendForwards(){const{doc:t}=this.$from;if(this.isBackwards&&this.ranges.length>1){const t=this.ranges.slice(1),n=t[0].$from,r=t[t.length-1].$to;return new e(r,n,this.depth)}const n=this.ranges[this.ranges.length-1],r=t.resolve(Math.min(t.content.size,n.$to.pos+1));return new e(this.$anchor,r,this.depth)}static fromJSON(t,n){return new e(t.resolve(n.anchor),t.resolve(n.head))}static create(e,t,n,r,o=1){return new this(e.resolve(t),e.resolve(n),r,o)}getBookmark(){return new qk(this.anchor,this.head)}};function Wk(e){return e instanceof Zk}function Kk(e){const t=e.cloneNode(!0),n=[e,...Array.from(e.getElementsByTagName("*"))],r=[t,...Array.from(t.getElementsByTagName("*"))];return n.forEach((e,t)=>{r[t].style.cssText=function(e){let t="";const n=getComputedStyle(e);for(let r=0;r<n.length;r+=1)t+=`${n[r]}:${n.getPropertyValue(n[r])};`;return t}(e)}),t}Zk.prototype.visible=!1,Os.create({name:"nodeRange",addOptions:()=>({depth:void 0,key:"Mod"}),addKeyboardShortcuts(){return{"Shift-ArrowUp":({editor:e})=>{const{depth:t}=this.options,{view:n,state:r}=e,{doc:o,selection:i,tr:a}=r,{anchor:l,head:s}=i;if(!Wk(i)){const e=Zk.create(o,l,s,t,-1);return a.setSelection(e),n.dispatch(a),!0}const c=i.extendBackwards();return a.setSelection(c),n.dispatch(a),!0},"Shift-ArrowDown":({editor:e})=>{const{depth:t}=this.options,{view:n,state:r}=e,{doc:o,selection:i,tr:a}=r,{anchor:l,head:s}=i;if(!Wk(i)){const e=Zk.create(o,l,s,t);return a.setSelection(e),n.dispatch(a),!0}const c=i.extendForwards();return a.setSelection(c),n.dispatch(a),!0},"Mod-a":({editor:e})=>{const{depth:t}=this.options,{view:n,state:r}=e,{doc:o,tr:i}=r,a=Zk.create(o,0,o.content.size,t);return i.setSelection(a),n.dispatch(i),!0}}},onSelectionUpdate(){const{selection:e}=this.editor.state;Wk(e)&&this.editor.view.dom.classList.add("ProseMirror-noderangeselection")},addProseMirrorPlugins(){let e=!1,t=!1;return[new to({key:new oo("nodeRange"),props:{attributes:()=>e?{class:"ProseMirror-noderangeselection"}:{class:""},handleDOMEvents:{mousedown:(e,n)=>{const{key:r}=this.options,o=/Mac/.test(navigator.platform),i=!!n.shiftKey,a=!!n.ctrlKey,l=!!n.altKey,s=!!n.metaKey;return(null==r||"Shift"===r&&i||"Control"===r&&a||"Alt"===r&&l||"Meta"===r&&s||"Mod"===r&&(o?s:a))&&(t=!0),!!t&&(document.addEventListener("mouseup",()=>{t=!1;const{state:n}=e,{doc:r,selection:o,tr:i}=n,{$anchor:a,$head:l}=o;if(a.sameParent(l))return;const s=Zk.create(r,a.pos,l.pos,this.options.depth);i.setSelection(s),e.dispatch(i)},{once:!0}),!1)}},decorations:n=>{const{selection:r}=n,o=Wk(r);if(e=!1,!t)return o?(e=!0,Uk(r.ranges)):null;const{$from:i,$to:a}=r;if(!o&&i.sameParent(a))return null;const l=Gk(i,a,this.options.depth);return l.length?(e=!0,Uk(l)):null}}})]}});var Jk=[{id:"listItemFirstChild",evaluate:({parent:e,isFirst:t})=>{if(!t)return 0;return e&&["listItem","taskItem"].includes(e.type.name)?1e3:0}},{id:"listWrapperDeprioritize",evaluate:({node:e})=>{const t=e.firstChild;return t&&["listItem","taskItem"].includes(t.type.name)?1e3:0}},{id:"tableStructure",evaluate:({node:e,parent:t})=>["tableRow","tableCell","tableHeader"].includes(e.type.name)||t&&"tableHeader"===t.type.name?1e3:0},{id:"inlineContent",evaluate:({node:e})=>e.isInline||e.isText?1e3:0}],Yk={edges:["left","top"],threshold:12,strength:500};function Xk(e){return void 0===e||"left"===e?{...Yk}:"right"===e?{edges:["right","top"],threshold:12,strength:500}:"both"===e?{edges:["left","right","top"],threshold:12,strength:500}:"none"===e?{edges:[],threshold:0,strength:0}:{...Yk,...e}}function Qk(e,t,n,r){let o=1e3,i=!1;if(t.every(t=>{const n=t.evaluate(e);return o-=n,!(o<=0)||(i=!0,!1)}),i)return-1;const a=e.view.nodeDOM(e.pos);return o-=function(e,t,n,r){return t&&0!==n.edges.length&&function(e,t,n){if(0===n.edges.length)return!1;const r=t.getBoundingClientRect(),{threshold:o,edges:i}=n;return i.some(t=>"left"===t?e.x-r.left<o:"right"===t?r.right-e.x<o:"top"===t?e.y-r.top<o:"bottom"===t&&r.bottom-e.y<o)}(e,t,n)?n.strength*r:0}(r,a,n,e.depth),o<=0?-1:o}function ex(e,t,n){const r=Array.from({length:t},(e,n)=>t-1-n);return r.some(t=>n.includes(e.node(t).type.name))}function tx(e){return Number.isFinite(e.top)&&Number.isFinite(e.bottom)&&Number.isFinite(e.left)&&Number.isFinite(e.right)&&e.width>0&&e.height>0}var nx=e=>{const{x:t,y:n,editor:r,nestedOptions:o}=e,{view:i,state:a}=r,l=function(e,t,n,r=5){if(!Number.isFinite(t)||!Number.isFinite(n))return null;const o=e.dom,i=o.firstElementChild,a=o.lastElementChild;if(!i||!a)return null;const l=i.getBoundingClientRect(),s=a.getBoundingClientRect();if(!tx(l)||!tx(s))return null;const c=Math.min(Math.max(l.top+r,n),s.bottom-r),d=Math.abs(l.left-s.left)<.5,u=Math.abs(l.right-s.right)<.5;let p=l;d&&u&&(p=l);const h=Math.min(Math.max(p.left+r,t),p.right-r);return Number.isFinite(h)&&Number.isFinite(c)?{x:h,y:c}:null}(i,t,n,5);if(!l)return{resultElement:null,resultNode:null,pos:null};const{x:s,y:c}=l;if(null==o?void 0:o.enabled){const e=function(e,t,n){if(!Number.isFinite(t.x)||!Number.isFinite(t.y))return null;const r=e.posAtCoords({left:t.x,top:t.y});if(!r)return null;const{doc:o}=e.state,i=o.resolve(r.pos),a=[];n.defaultRules&&a.push(...Jk),a.push(...n.rules);const l=Array.from({length:i.depth},(e,t)=>i.depth-t),s=l.map(r=>{const o=i.node(r),l=i.before(r);if(n.allowedContainers&&r>0&&!ex(i,r,n.allowedContainers))return null;const s=r>0?i.node(r-1):null,c=r>0?i.index(r-1):0,d=Qk({node:o,pos:l,depth:r,parent:s,index:c,isFirst:0===c,isLast:c===(s?s.childCount:1)-1,$pos:i,view:e},a,n.edgeDetection,t);return d<0?null:{node:o,pos:l,depth:r,score:d,dom:e.nodeDOM(l)}}).filter(e=>null!==e),c=i.nodeAfter;if(c&&c.isAtom&&!c.isInline){const o=r.pos,l=i.depth+1,d=i.parent,u=i.index(),p=d.childCount;let h=!0;if(n.allowedContainers&&(h=ex(i,l,n.allowedContainers)),h){const r=Qk({node:c,pos:o,depth:l,parent:d,index:u,isFirst:0===u,isLast:u===p-1,$pos:i,view:e},a,n.edgeDetection,t);if(r>=0){const t=e.nodeDOM(o);t&&s.push({node:c,pos:o,depth:l,score:r,dom:t})}}}if(0===s.length)return null;s.sort((e,t)=>t.score!==e.score?t.score-e.score:t.depth-e.depth);const d=s[0];return d.dom?{node:d.node,pos:d.pos,dom:d.dom}:null}(i,{x:s,y:c},o);return e?{resultElement:e.dom,resultNode:e.node,pos:e.pos}:{resultElement:null,resultNode:null,pos:null}}const d=i.root.elementsFromPoint(s,c);let u,p;if(Array.prototype.some.call(d,e=>{if(!i.dom.contains(e))return!1;const t=function(e,t){let n=e;for(;(null==n?void 0:n.parentElement)&&n.parentElement!==t.dom;)n=n.parentElement;return(null==n?void 0:n.parentElement)===t.dom?n:void 0}(e,i);return!!t&&(u=t,!0)}),!u)return{resultElement:null,resultNode:null,pos:null};try{p=i.posAtDOM(u,0)}catch{return{resultElement:null,resultNode:null,pos:null}}const h=a.doc.nodeAt(p);if(!h){const e=a.doc.resolve(p),t=e.parent;return{resultElement:u,resultNode:t,pos:e.start()}}return{resultElement:u,resultNode:h,pos:p}};function rx(e){var t;null==(t=e.parentNode)||t.removeChild(e)}function ox(e,t,n,r){const{view:o}=t;if(!e.dataTransfer)return;const{empty:i,$from:a,$to:l}=o.state.selection,s=function(e,t,n,r){const{doc:o}=t.view.state;if((null==n?void 0:n.enabled)&&(null==r?void 0:r.node)&&r.pos>=0){const e=r.pos,t=r.pos+r.node.nodeSize;return[{$from:o.resolve(e),$to:o.resolve(t)}]}const i=nx({editor:t,x:e.clientX,y:e.clientY,nestedOptions:n});if(!i.resultNode||null===i.pos)return[];const a=i.resultNode.isText||i.resultNode.isAtom?0:-1;return Gk(o.resolve(i.pos),o.resolve(i.pos+i.resultNode.nodeSize+a),0)}(e,t,n,r),c=Gk(a,l,0),d=c.some(e=>s.find(t=>t.$from===e.$from&&t.$to===e.$to)),u=i||!d?s:c;if(!u.length)return;const{tr:p}=o.state,h=document.createElement("div"),m=u[0].$from.pos,f=u[u.length-1].$to.pos;let g,v;(null==n?void 0:n.enabled)&&(null==r?void 0:r.node)?(g=o.state.doc.slice(m,f),v=qr.create(o.state.doc,m)):(v=Zk.create(o.state.doc,m,f),g=v.content()),u.forEach(e=>{const t=Kk(o.nodeDOM(e.$from.pos));h.append(t)}),h.style.position="absolute",h.style.top="-10000px",document.body.append(h),e.dataTransfer.clearData(),e.dataTransfer.setDragImage(h,0,0);const y=v instanceof qr?v:void 0;o.dragging={slice:g,move:!0,node:y},p.setSelection(v),o.dispatch(p),document.addEventListener("drop",()=>rx(h),{once:!0})}var ix=(e,t)=>{const n=e.resolve(t),{depth:r}=n;if(0===r)return t;return n.pos-n.parentOffset-1},ax=(e,t)=>{const n=e.nodeAt(t),r=e.resolve(t);let{depth:o}=r,i=n;for(;o>0;){const e=r.node(o);o-=1,0===o&&(i=e)}return i},lx=(e,t)=>{const n=sk.getState(e);return n?Ik(t,n.type,n.binding.mapping):null},sx=(e,t)=>{let n=t;for(;(null==n?void 0:n.parentNode)&&n.parentNode!==e.dom;)n=n.parentNode;return n},cx=new oo("dragHandle"),dx=({pluginKey:e=cx,element:t,editor:n,computePositionConfig:r,getReferencedVirtualElement:o,onNodeChange:i,onElementDragStart:a,onElementDragEnd:l,nestedOptions:s})=>{const c=document.createElement("div");let d,u=!1,p=null,h=-1,m=null,f=null;function g(){t&&(t.style.visibility="hidden",t.style.pointerEvents="none")}function v(e){const n=(null==o?void 0:o())||{getBoundingClientRect:()=>e.getBoundingClientRect()};Tm(n,t,r).then(e=>{Object.assign(t.style,{position:e.strategy,left:`${e.x}px`,top:`${e.y}px`})})}function y(e){null==a||a(e),ox(e,n,s,{node:p,pos:h}),t&&(t.dataset.dragging="true"),setTimeout(()=>{t&&(t.style.pointerEvents="none")},0)}function b(e){null==l||l(e),g(),t&&(t.style.pointerEvents="auto",t.dataset.dragging="false")}function w(){if("undefined"!=typeof navigator&&/Firefox/.test(navigator.userAgent)){const e=n.view.dom;requestAnimationFrame(()=>{e.isContentEditable&&(e.contentEditable="false",e.contentEditable="true")})}}return t.addEventListener("dragstart",y),t.addEventListener("dragend",b),document.addEventListener("drop",w),c.appendChild(t),{unbind(){t.removeEventListener("dragstart",y),t.removeEventListener("dragend",b),document.removeEventListener("drop",w),m&&(cancelAnimationFrame(m),m=null,f=null)},plugin:new to({key:"string"==typeof e?new oo(e):e,state:{init:()=>({locked:!1}),apply(e,r,o,a){const l=e.getMeta("lockDragHandle"),s=e.getMeta("hideDragHandle");if(void 0!==l&&(u=l),s)return g(),u=!1,p=null,h=-1,null==i||i({editor:n,node:null,pos:-1}),r;if(e.docChanged&&-1!==h&&t)if(Rk(e)){const e=((e,t)=>{const n=sk.getState(e);return n?Pk(n.doc,n.type,t,n.binding.mapping)||0:-1})(a,d);e!==h&&(h=e)}else{const t=e.mapping.map(h);t!==h&&(h=t,d=lx(a,h))}return r}},view:e=>{var r;return t.draggable=!0,t.style.pointerEvents="auto",t.dataset.dragging="false",null==(r=n.view.dom.parentElement)||r.appendChild(c),c.style.pointerEvents="none",c.style.position="absolute",c.style.top="0",c.style.left="0",{update(r,o){if(!t)return;if(!n.isEditable)return void g();if(t.draggable=!u,e.state.doc.eq(o.doc)||-1===h)return;let a=e.nodeDOM(h);if(a=sx(e,a),a===e.dom)return;if(1!==(null==a?void 0:a.nodeType))return;const l=e.posAtDOM(a,0),s=ax(n.state.doc,l),c=ix(n.state.doc,l);p=s,h=c,d=lx(e.state,h),null==i||i({editor:n,node:p,pos:h}),v(a)},destroy(){t.removeEventListener("dragstart",y),t.removeEventListener("dragend",b),document.removeEventListener("drop",w),m&&(cancelAnimationFrame(m),m=null,f=null),t&&rx(c)}}},props:{handleDOMEvents:{keydown:e=>!(!t||u)&&(!!e.hasFocus()&&(g(),p=null,h=-1,null==i||i({editor:n,node:null,pos:-1}),!1)),mouseleave:(e,t)=>(u||t.target&&!c.contains(t.relatedTarget)&&(g(),p=null,h=-1,null==i||i({editor:n,node:null,pos:-1})),!1),mousemove:(e,r)=>!(!t||u)&&(f={x:r.clientX,y:r.clientY},m||(m=requestAnimationFrame(()=>{if(m=null,!f)return;const{x:r,y:o}=f;f=null;const a=nx({x:r,y:o,editor:n,nestedOptions:s});if(!a.resultElement)return;let l=a.resultElement,c=a.resultNode,u=a.pos;if(!(null==s?void 0:s.enabled)){if(l=sx(e,l),l===e.dom)return;if(1!==(null==l?void 0:l.nodeType))return;const t=e.posAtDOM(l,0);c=ax(n.state.doc,t),u=ix(n.state.doc,t)}c!==p&&(p=c,h=null!=u?u:-1,d=lx(e.state,h),null==i||i({editor:n,node:p,pos:h}),v(l),t&&(n.isEditable?(t.style.visibility="",t.style.pointerEvents="auto"):g()))})),!1)}}})}};function ux(e){var t,n;return!1===e||void 0===e?{enabled:!1,rules:[],defaultRules:!0,allowedContainers:void 0,edgeDetection:Xk("none")}:!0===e?{enabled:!0,rules:[],defaultRules:!0,allowedContainers:void 0,edgeDetection:Xk("left")}:{enabled:!0,rules:null!=(t=e.rules)?t:[],defaultRules:null==(n=e.defaultRules)||n,allowedContainers:e.allowedContainers,edgeDetection:Xk(e.edgeDetection)}}var px={placement:"left-start",strategy:"absolute"};Os.create({name:"dragHandle",addOptions:()=>({render(){const e=document.createElement("div");return e.classList.add("drag-handle"),e},computePositionConfig:{},locked:!1,onNodeChange:()=>null,onElementDragStart:void 0,onElementDragEnd:void 0,nested:!1}),addCommands(){return{lockDragHandle:()=>({editor:e})=>(this.options.locked=!0,e.commands.setMeta("lockDragHandle",this.options.locked)),unlockDragHandle:()=>({editor:e})=>(this.options.locked=!1,e.commands.setMeta("lockDragHandle",this.options.locked)),toggleDragHandle:()=>({editor:e})=>(this.options.locked=!this.options.locked,e.commands.setMeta("lockDragHandle",this.options.locked))}},addProseMirrorPlugins(){const e=this.options.render(),t=ux(this.options.nested);return[dx({computePositionConfig:{...px,...this.options.computePositionConfig},getReferencedVirtualElement:this.options.getReferencedVirtualElement,element:e,editor:this.editor,onNodeChange:this.options.onNodeChange,onElementDragStart:this.options.onElementDragStart,onElementDragEnd:this.options.onElementDragEnd,nestedOptions:t}).plugin]}}),e.defineComponent({name:"DragHandleVue",props:{pluginKey:{type:[String,Object],default:cx},editor:{type:Object,required:!0},computePositionConfig:{type:Object,default:()=>({})},onNodeChange:{type:Function,default:null},onElementDragStart:{type:Function,default:null},onElementDragEnd:{type:Function,default:null},class:{type:String,default:"drag-handle"},nested:{type:[Boolean,Object],default:!1}},setup(t,{slots:n}){const r=e.ref(null),o=e.shallowRef(null),i=()=>{const{editor:e,pluginKey:n,onNodeChange:i,onElementDragEnd:a,onElementDragStart:l,computePositionConfig:s,nested:c}=t;if(!r.value)return;if(!t.editor||t.editor.isDestroyed)return;const d=ux(c),u=dx({editor:e,element:r.value,pluginKey:n,computePositionConfig:{...px,...s},onNodeChange:i,onElementDragStart:l,onElementDragEnd:a,nestedOptions:d});o.value=u,t.editor.registerPlugin(u.plugin)},a=()=>{var e,n;o.value&&(t.editor&&!t.editor.isDestroyed&&t.editor.unregisterPlugin(t.pluginKey),null==(n=(e=o.value).unbind)||n.call(e),o.value=null)};return e.onMounted(async()=>{await e.nextTick(),i()}),e.watch(()=>t.nested,()=>{a(),i()},{deep:!0}),e.onBeforeUnmount(()=>{a()}),()=>{var o;return e.h("div",{ref:r,class:t.class,style:{visibility:"hidden",position:"absolute"},"data-dragging":"false"},null==(o=n.default)?void 0:o.call(n))}}});const hx={"47FYwb":"Cancel",N2IrpM:"Confirm",Vl9vDx:"units","customer_billing_information.billing_address_label":"Billing address","customer_billing_information.email_address_label":"Email address","customer_billing_information.name_label":"Name","customer_billing_information.title":"Billing information","customer_billing_information.vat_number_label":"VAT number","customer_overview.billing_information.no_billing_information_available":"No billing information to display.","download_button.download_failed_message":"Download failed, please try again later","editor.placeholder":"Enter text or type ‘/’ for commands","editorComponent.entityDetailsFallbackTitles.customerTitle":"Customer details","editorComponent.entityDetailsFallbackTitles.supplierTitle":"Supplier details","editorComponent.slashCommands.addCustomerDetailsDescription":"Insert customer details block","editorComponent.slashCommands.addCustomerDetailsTitle":"Add Customer Details","editorComponent.slashCommands.addPartyDetailsDescription":"Insert customer and supplier details in one row","editorComponent.slashCommands.addPartyDetailsTitle":"Add Party Details","editorComponent.slashCommands.addSupplierDetailsDescription":"Insert supplier details block","editorComponent.slashCommands.addSupplierDetailsTitle":"Add Supplier Details","editorComponent.slashCommands.customerFallbackTitle":"Customer details","editorComponent.slashCommands.dividerDescription":"Insert a horizontal rule","editorComponent.slashCommands.dividerTitle":"Divider","editorComponent.slashCommands.headingDescription":"Start writing with heading.","editorComponent.slashCommands.headingTitle":"Heading","editorComponent.slashCommands.supplierFallbackTitle":"Supplier details","editorComponent.slashCommands.textDescription":"Start writing with plain text","editorComponent.slashCommands.textTitle":"Text","error_notification.default_error_message":"Something went wrong","form_validation.tax_id.invalid_format":"Invalid tax ID format. Example: {example}","generic.not_available":"N/A","invoice.add_invoice_line":"Add invoice line","invoice.adjustment_chip_body":"Adjustment","invoice.already_deducted_table_heading":"Already deducted","invoice.amount_discount":"{amount} discount","invoice.amount_due_table_heading":"Amount due","invoice.amount_table_heading":"Amount","invoice.commitment":"commitment","invoice.commitment_heading":"Commitment","invoice.discounts_table_heading":"Discounts","invoice.download_pdf_button":"Download PDF","invoice.due_on_label":"Due on {date}","invoice.line.band_maximum_number":"Maximum number","invoice.line.band_minimum_amount":"Band minimum amount","invoice.line.band_minimum_number":"Minimum number","invoice.line.excl.tax":"Excl. tax","invoice.line.incl.tax":"Incl. tax","invoice.line.included":"included","invoice.line.original_currency":"Original currency","invoice.line.pass_through":"Pass through","invoice.line.price_bound_maximum_amount":"Maximum amount","invoice.line.price_bound_within_bounds":"Within bounds","invoice.line.units_included":"units included","invoice.markup_percentage":"{percentage}% markup","invoice.markups_table_heading":"Markups","invoice.paid_chip":"Paid","invoice.paid_on_label":"Paid on {date}","invoice.percentage_discount":"{percentage}% discount","invoice.service_period_heading":"Service period - {start_at} - {end_at}","invoice.table_header.base amount":"Base amount","invoice.table_header.discount":"Discount","invoice.table_header.markup":"Markup","invoice.table_header.price":"Price","invoice.table_header.quantity":"Quantity","invoice.table_header.sub_total":"Subtotal","invoice.table_header.tax amount":"Tax amount","invoice.table_header.tax type":"Tax type","invoice.table_header.tax_percentage":"Percentage","invoice.table_header.tax_rate":"Tax rate","invoice.table_header.total":"Total","invoice.table_header.total_excluding_taxes":"Total excluding taxes","invoice.table_header.total_including_taxes":"Total including taxes","invoice.table_header.total_including_taxes_customer_facing":"Total due today","invoice.table_header.unit":"Unit","invoice.table_heading.commitments":"Commitments","invoice.table_heading.discounts":"Discounts","invoice.table_heading.markups":"Markups","invoice.table_heading.one_offs":"One-off's","invoice.table_heading.products":"Products","invoice.tax_notes.local_vat_applied_for_missing_tax_id":"Local VAT applied instead of reverse charge mechanism because customer VAT number is missing and this is an intra-EU sale","invoice.tax_notes.no_charge_provided_outside_eu":"No VAT charged – services provided outside the EU","invoice.tax_notes.not_applicable_article":"TVA non applicable – Article 294, 1 du CGI","invoice.tax_notes.reverse_charge":"Reverse charge - Art 196 of the VAT Directive 2006/ 112/EC","invoice.tax_notes.reverse_charge_outside_eu":"No VAT – Service supplied outside the EU (Art. 44 EU VAT Directive)","invoice.tax_notes.reverse_charge_tax_registration":"[1] - Reverse charge","invoice.tax_notes.reverse_charge_tax_registration_outside_eu":"Out of scope for EU VAT","invoice.taxes_table_heading":"Taxes","invoice.title":"Details","invoice.totals_table_heading":"Totals","invoice_preview.after_trial_heading":"After trial","invoice_preview.taxes_heading":"Taxes","invoice_preview.taxes_not_determined_by_billing_information_tooltip":"Will be determined by billing information","invoice_preview.total_due_today_heading":"Total due today","invoice_preview.total_excluding_taxes_heading":"Total excluding taxes","invoice_preview.total_including_taxes_heading":"Total including taxes","invoice_preview.total_paid_heading":"Total paid",lWOCGz:"unit","payment_methods.default_chip.label":"Default","payment_methods.inactive_chip.label":"Inactive","pricing_detail.billing_cycle":"Billing cycle",pricing_item_pricing:"{pricing} per {billing_period}","pricing_item_pricing.flat_top_up":"Flat top up pricing","pricing_item_pricing.none":"Not billed","pricing_item_pricing.pass_through":"Pass through pricing","pricing_item_pricing.per_seat":"Per seat","pricing_item_pricing.stair_step":"Stair step pricing","pricing_item_pricing.tiered":"Tiered pricing","pricing_item_pricing.tiered_top_up":"Tiered top up pricing","pricing_item_pricing.top_tiered":"Top tiered pricing","pricing_item_pricing.unsupported_pricing_error":"Unsupported pricing","promotion.code.expiry":"Never expires","slashCommandList.emptyState":"No matching commands","taxId.invalid":"Invalid tax ID","time_period.day.full":"daily","time_period.day.plural":"days","time_period.day.singular":"day","time_period.month.full":"monthly","time_period.month.plural":"months","time_period.month.singular":"month","time_period.week.full":"weekly","time_period.week.plural":"weeks","time_period.week.singular":"week","time_period.year.full":"yearly","time_period.year.plural":"years","time_period.year.singular":"year","timezone_select.option.inherit_from_platform":"Inherit from platform","ui.CalloutRow.moreActions":"More actions"},mx=Symbol(),fx={hour:"2-digit",minute:"2-digit",second:"2-digit"},gx=e=>e.includes("US"),vx={dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}},yx=[180,300,60],bx=[360,240,120,0];function wx(e,t,n){const r=e.sort((e,n)=>Math.abs(e-t)-Math.abs(n-t))[0]-t;return Math.round(n*r*.5)}function kx(e){const t=function(e){const t=e.replace("#","");return`#${3===t.length?t.replace(/(.)/g,"$1$1"):t.padEnd(6,"0")}`}(e),n={500:t},r={50:.95,100:.9,200:.75,300:.6,400:.3,600:.9,700:.75,800:.6,900:.45,950:.29};return[50,100,200,300,400].forEach(e=>{n[e]=function(e,t){if(!e)return"";const[n,r,o]=f.hex.hsv(e),i=n+wx(yx,n,t),a=r-Math.round(r*t),l=o+Math.round((100-o)*t);return`#${f.hsv.hex([i,a,l])}`}(t,r[e])}),[600,700,800,900,950].forEach(e=>{n[e]=function(e,t){if(!e)return"";const n=1-t,[r,o,i]=f.hex.hsv(e),a=r+wx(bx,r,n),l=o+Math.round((100-o)*n),s=i-Math.round(i*n);return`#${f.hsv.hex([a,l,s])}`}(t,r[e])}),n}const xx=e.defineComponent({__name:"BrandProvider",props:{primaryColor:{default:"#000000"},secondaryColor:{default:"#444444"},isShadowRoot:{type:Boolean,default:!1}},setup(t){const n=t,r=e.computed(()=>kx(n.primaryColor)),o=e.computed(()=>kx(n.secondaryColor)),i=e.computed(()=>n.isShadowRoot?":host":":root");return(t,n)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent("style"),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(i.value)+" { --color-primary-50: "+e.toDisplayString(r.value[50])+"; --color-primary-100: "+e.toDisplayString(r.value[100])+"; --color-primary-200: "+e.toDisplayString(r.value[200])+"; --color-primary-300: "+e.toDisplayString(r.value[300])+"; --color-primary-400: "+e.toDisplayString(r.value[400])+"; --color-primary-500: "+e.toDisplayString(r.value[500])+"; --color-primary-600: "+e.toDisplayString(r.value[600])+"; --color-primary-700: "+e.toDisplayString(r.value[700])+"; --color-primary-800: "+e.toDisplayString(r.value[800])+"; --color-primary-900: "+e.toDisplayString(r.value[900])+" --color-secondary-50: "+e.toDisplayString(o.value[50])+"; --color-secondary-100: "+e.toDisplayString(o.value[100])+"; --color-secondary-200: "+e.toDisplayString(o.value[200])+"; --color-secondary-300: "+e.toDisplayString(o.value[300])+"; --color-secondary-400: "+e.toDisplayString(o.value[400])+"; --color-secondary-500: "+e.toDisplayString(o.value[500])+"; --color-secondary-600: "+e.toDisplayString(o.value[600])+"; --color-secondary-700: "+e.toDisplayString(o.value[700])+"; --color-secondary-800: "+e.toDisplayString(o.value[800])+"; --color-secondary-900: "+e.toDisplayString(o.value[900])+" } ",1)]),_:1}))}}),_x=[{key:"AF",value:"Afghanistan"},{key:"AX",value:"Aland Islands"},{key:"AL",value:"Albania"},{key:"DZ",value:"Algeria"},{key:"AS",value:"American Samoa"},{key:"AD",value:"Andorra"},{key:"AO",value:"Angola"},{key:"AI",value:"Anguilla"},{key:"AQ",value:"Antarctica"},{key:"AG",value:"Antigua And Barbuda"},{key:"AR",value:"Argentina"},{key:"AM",value:"Armenia"},{key:"AW",value:"Aruba"},{key:"AU",value:"Australia"},{key:"AT",value:"Austria"},{key:"AZ",value:"Azerbaijan"},{key:"BS",value:"Bahamas"},{key:"BH",value:"Bahrain"},{key:"BD",value:"Bangladesh"},{key:"BB",value:"Barbados"},{key:"BY",value:"Belarus"},{key:"BE",value:"Belgium"},{key:"BZ",value:"Belize"},{key:"BJ",value:"Benin"},{key:"BM",value:"Bermuda"},{key:"BT",value:"Bhutan"},{key:"BO",value:"Bolivia"},{key:"BA",value:"Bosnia And Herzegovina"},{key:"BW",value:"Botswana"},{key:"BV",value:"Bouvet Island"},{key:"BR",value:"Brazil"},{key:"IO",value:"British Indian Ocean Territory"},{key:"BN",value:"Brunei Darussalam"},{key:"BG",value:"Bulgaria"},{key:"BF",value:"Burkina Faso"},{key:"BI",value:"Burundi"},{key:"KH",value:"Cambodia"},{key:"CM",value:"Cameroon"},{key:"CA",value:"Canada"},{key:"CV",value:"Cape Verde"},{key:"KY",value:"Cayman Islands"},{key:"CF",value:"Central African Republic"},{key:"TD",value:"Chad"},{key:"CL",value:"Chile"},{key:"CN",value:"China"},{key:"CX",value:"Christmas Island"},{key:"CC",value:"Cocos (Keeling) Islands"},{key:"CO",value:"Colombia"},{key:"KM",value:"Comoros"},{key:"CG",value:"Congo"},{key:"CD",value:"Congo, Democratic Republic"},{key:"CK",value:"Cook Islands"},{key:"CR",value:"Costa Rica"},{key:"CI",value:'Cote D"Ivoire'},{key:"HR",value:"Croatia"},{key:"CU",value:"Cuba"},{key:"CW",value:"Curaçao"},{key:"CY",value:"Cyprus"},{key:"CZ",value:"Czech Republic"},{key:"DK",value:"Denmark"},{key:"DJ",value:"Djibouti"},{key:"DM",value:"Dominica"},{key:"DO",value:"Dominican Republic"},{key:"EC",value:"Ecuador"},{key:"EG",value:"Egypt"},{key:"SV",value:"El Salvador"},{key:"GQ",value:"Equatorial Guinea"},{key:"ER",value:"Eritrea"},{key:"EE",value:"Estonia"},{key:"ET",value:"Ethiopia"},{key:"FK",value:"Falkland Islands (Malvinas)"},{key:"FO",value:"Faroe Islands"},{key:"FJ",value:"Fiji"},{key:"FI",value:"Finland"},{key:"FR",value:"France"},{key:"GF",value:"French Guiana"},{key:"PF",value:"French Polynesia"},{key:"TF",value:"French Southern Territories"},{key:"GA",value:"Gabon"},{key:"GM",value:"Gambia"},{key:"GE",value:"Georgia"},{key:"DE",value:"Germany"},{key:"GH",value:"Ghana"},{key:"GI",value:"Gibraltar"},{key:"GR",value:"Greece"},{key:"GL",value:"Greenland"},{key:"GD",value:"Grenada"},{key:"GP",value:"Guadeloupe"},{key:"GU",value:"Guam"},{key:"GT",value:"Guatemala"},{key:"GG",value:"Guernsey"},{key:"GN",value:"Guinea"},{key:"GW",value:"Guinea-Bissau"},{key:"GY",value:"Guyana"},{key:"HT",value:"Haiti"},{key:"HM",value:"Heard Island & Mcdonald Islands"},{key:"VA",value:"Holy See (Vatican City State)"},{key:"HN",value:"Honduras"},{key:"HK",value:"Hong Kong"},{key:"HU",value:"Hungary"},{key:"IS",value:"Iceland"},{key:"IN",value:"India"},{key:"ID",value:"Indonesia"},{key:"IR",value:"Iran, Islamic Republic Of"},{key:"IQ",value:"Iraq"},{key:"IE",value:"Ireland"},{key:"IM",value:"Isle Of Man"},{key:"IL",value:"Israel"},{key:"IT",value:"Italy"},{key:"JM",value:"Jamaica"},{key:"JP",value:"Japan"},{key:"JE",value:"Jersey"},{key:"JO",value:"Jordan"},{key:"KZ",value:"Kazakhstan"},{key:"KE",value:"Kenya"},{key:"KI",value:"Kiribati"},{key:"KR",value:"Korea"},{key:"KP",value:"North Korea"},{key:"KW",value:"Kuwait"},{key:"KG",value:"Kyrgyzstan"},{key:"LA",value:'Lao People"s Democratic Republic'},{key:"LV",value:"Latvia"},{key:"LB",value:"Lebanon"},{key:"LS",value:"Lesotho"},{key:"LR",value:"Liberia"},{key:"LY",value:"Libyan Arab Jamahiriya"},{key:"LI",value:"Liechtenstein"},{key:"LT",value:"Lithuania"},{key:"LU",value:"Luxembourg"},{key:"MO",value:"Macao"},{key:"MK",value:"Macedonia"},{key:"MG",value:"Madagascar"},{key:"MW",value:"Malawi"},{key:"MY",value:"Malaysia"},{key:"MV",value:"Maldives"},{key:"ML",value:"Mali"},{key:"MT",value:"Malta"},{key:"MH",value:"Marshall Islands"},{key:"MQ",value:"Martinique"},{key:"MR",value:"Mauritania"},{key:"MU",value:"Mauritius"},{key:"YT",value:"Mayotte"},{key:"MX",value:"Mexico"},{key:"FM",value:"Micronesia, Federated States Of"},{key:"MD",value:"Moldova"},{key:"MC",value:"Monaco"},{key:"MN",value:"Mongolia"},{key:"ME",value:"Montenegro"},{key:"MS",value:"Montserrat"},{key:"MA",value:"Morocco"},{key:"MZ",value:"Mozambique"},{key:"MM",value:"Myanmar"},{key:"NA",value:"Namibia"},{key:"NR",value:"Nauru"},{key:"NP",value:"Nepal"},{key:"NL",value:"Netherlands"},{key:"AN",value:"Netherlands Antilles"},{key:"NC",value:"New Caledonia"},{key:"NZ",value:"New Zealand"},{key:"NI",value:"Nicaragua"},{key:"NE",value:"Niger"},{key:"NG",value:"Nigeria"},{key:"NU",value:"Niue"},{key:"NF",value:"Norfolk Island"},{key:"MP",value:"Northern Mariana Islands"},{key:"NO",value:"Norway"},{key:"OM",value:"Oman"},{key:"PK",value:"Pakistan"},{key:"PW",value:"Palau"},{key:"PS",value:"Palestinian Territory, Occupied"},{key:"PA",value:"Panama"},{key:"PG",value:"Papua New Guinea"},{key:"PY",value:"Paraguay"},{key:"PE",value:"Peru"},{key:"PH",value:"Philippines"},{key:"PN",value:"Pitcairn"},{key:"PL",value:"Poland"},{key:"PT",value:"Portugal"},{key:"PR",value:"Puerto Rico"},{key:"QA",value:"Qatar"},{key:"RE",value:"Reunion"},{key:"RO",value:"Romania"},{key:"RU",value:"Russian Federation"},{key:"RW",value:"Rwanda"},{key:"BL",value:"Saint Barthelemy"},{key:"SH",value:"Saint Helena"},{key:"KN",value:"Saint Kitts And Nevis"},{key:"LC",value:"Saint Lucia"},{key:"MF",value:"Saint Martin"},{key:"PM",value:"Saint Pierre And Miquelon"},{key:"VC",value:"Saint Vincent And Grenadines"},{key:"WS",value:"Samoa"},{key:"SM",value:"San Marino"},{key:"ST",value:"Sao Tome And Principe"},{key:"SA",value:"Saudi Arabia"},{key:"SN",value:"Senegal"},{key:"RS",value:"Serbia"},{key:"SC",value:"Seychelles"},{key:"SL",value:"Sierra Leone"},{key:"SG",value:"Singapore"},{key:"SK",value:"Slovakia"},{key:"SI",value:"Slovenia"},{key:"SB",value:"Solomon Islands"},{key:"SO",value:"Somalia"},{key:"ZA",value:"South Africa"},{key:"GS",value:"South Georgia And Sandwich Isl."},{key:"ES",value:"Spain"},{key:"LK",value:"Sri Lanka"},{key:"SD",value:"Sudan"},{key:"SR",value:"Suriname"},{key:"SJ",value:"Svalbard And Jan Mayen"},{key:"SZ",value:"Swaziland"},{key:"SE",value:"Sweden"},{key:"CH",value:"Switzerland"},{key:"SY",value:"Syrian Arab Republic"},{key:"TW",value:"Taiwan"},{key:"TJ",value:"Tajikistan"},{key:"TZ",value:"Tanzania"},{key:"TH",value:"Thailand"},{key:"TL",value:"Timor-Leste"},{key:"TG",value:"Togo"},{key:"TK",value:"Tokelau"},{key:"TO",value:"Tonga"},{key:"TT",value:"Trinidad And Tobago"},{key:"TN",value:"Tunisia"},{key:"TR",value:"Turkey"},{key:"TM",value:"Turkmenistan"},{key:"TC",value:"Turks And Caicos Islands"},{key:"TV",value:"Tuvalu"},{key:"UG",value:"Uganda"},{key:"UA",value:"Ukraine"},{key:"AE",value:"United Arab Emirates"},{key:"GB",value:"United Kingdom"},{key:"US",value:"United States"},{key:"UM",value:"United States Outlying Islands"},{key:"UY",value:"Uruguay"},{key:"UZ",value:"Uzbekistan"},{key:"VU",value:"Vanuatu"},{key:"VE",value:"Venezuela"},{key:"VN",value:"Vietnam"},{key:"VG",value:"Virgin Islands, British"},{key:"VI",value:"Virgin Islands, U.S."},{key:"WF",value:"Wallis And Futuna"},{key:"EH",value:"Western Sahara"},{key:"YE",value:"Yemen"},{key:"ZM",value:"Zambia"},{key:"ZW",value:"Zimbabwe"}],Cx=e=>{if(!e)return"";const t=e.toLowerCase();return t.charAt(0).toUpperCase()+t.slice(1)},Ex=(e,t)=>{const n=document.createElement("a");n.href=e,n.download=t,n.click(),setTimeout(()=>{window.URL.revokeObjectURL(e)},250)},Sx={DAY:{literal:{singular:"Day",plural:"Days"},full:"Daily"},WEEK:{literal:{singular:"Week",plural:"Weeks"},full:"Weekly"},MONTH:{literal:{singular:"Month",plural:"Months"},full:"Monthly"},YEAR:{literal:{singular:"Year",plural:"Years"},full:"Yearly"}},Bx=(e,t)=>new Intl.NumberFormat((e=>{if(null==e?void 0:e.locale)return e.locale;if("undefined"!=typeof window){const e=localStorage.getItem("numberFormat");if(e)return e}return"en-US"})(t),{style:"currency",currency:e.currency,maximumFractionDigits:10}).format(+e.quantity),Nx=e=>Cx((e??"").replace(/_/g," ")),Mx=(e,t={short:!1,hideValueForExactPeriods:!1,prefix:"every"})=>{const n=e.value??1,r=Sx[e.type].literal[1===+n?"singular":"plural"].toLowerCase();return`${t.prefix&&!t.short?`${t.prefix} `:""}${t.hideValueForExactPeriods&&1===n?r:`${n} ${r}`}`},Tx=(e=[])=>{const t=e.filter(e=>null!=e&&""!==e);if(1===t.length)return t[0];return t.every(e=>e===t[0])?t[0]:[...t.slice(0,t.length-2),t.slice(t.length-2,t.length).join(" & ")].join(", ")},Vx=(e,t=!0)=>{const n=Tx((e.products??[]).map(e=>e.name??""));return e.name?t?`${e.name} - ${n}`:e.name:n};var Ax="object"==typeof global&&global&&global.Object===Object&&global,zx="object"==typeof self&&self&&self.Object===Object&&self,Ox=Ax||zx||Function("return this")(),Ix=Ox.Symbol,Dx=Object.prototype,Px=Dx.hasOwnProperty,$x=Dx.toString,Lx=Ix?Ix.toStringTag:void 0;var Rx=Object.prototype.toString;var Hx=Ix?Ix.toStringTag:void 0;function Fx(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Hx&&Hx in Object(e)?function(e){var t=Px.call(e,Lx),n=e[Lx];try{e[Lx]=void 0;var r=!0}catch(hR){}var o=$x.call(e);return r&&(t?e[Lx]=n:delete e[Lx]),o}(e):function(e){return Rx.call(e)}(e)}function jx(e){return null!=e&&"object"==typeof e}function Ux(e){return"symbol"==typeof e||jx(e)&&"[object Symbol]"==Fx(e)}function Gx(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}var qx=Array.isArray,Zx=Ix?Ix.prototype:void 0,Wx=Zx?Zx.toString:void 0;function Kx(e){if("string"==typeof e)return e;if(qx(e))return Gx(e,Kx)+"";if(Ux(e))return Wx?Wx.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function Jx(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Yx(e){return e}function Xx(e){if(!Jx(e))return!1;var t=Fx(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}var Qx,e_=Ox["__core-js_shared__"],t_=(Qx=/[^.]+$/.exec(e_&&e_.keys&&e_.keys.IE_PROTO||""))?"Symbol(src)_1."+Qx:"";var n_=Function.prototype.toString;function r_(e){if(null!=e){try{return n_.call(e)}catch(hR){}try{return e+""}catch(hR){}}return""}var o_=/^\[object .+?Constructor\]$/,i_=Function.prototype,a_=Object.prototype,l_=i_.toString,s_=a_.hasOwnProperty,c_=RegExp("^"+l_.call(s_).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function d_(e){return!(!Jx(e)||(t=e,t_&&t_ in t))&&(Xx(e)?c_:o_).test(r_(e));var t}function u_(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return d_(n)?n:void 0}var p_=u_(Ox,"WeakMap");var h_=Date.now;function m_(e){return function(){return e}}var f_,g_,v_,y_=function(){try{var e=u_(Object,"defineProperty");return e({},"",{}),e}catch(hR){}}(),b_=y_?function(e,t){return y_(e,"toString",{configurable:!0,enumerable:!1,value:m_(t),writable:!0})}:Yx,w_=(f_=b_,g_=0,v_=0,function(){var e=h_(),t=16-(e-v_);if(v_=e,t>0){if(++g_>=800)return arguments[0]}else g_=0;return f_.apply(void 0,arguments)});function k_(e){return e!=e}function x_(e,t){return!!(null==e?0:e.length)&&function(e,t,n){return t==t?function(e,t,n){for(var r=n-1,o=e.length;++r<o;)if(e[r]===t)return r;return-1}(e,t,n):function(e,t,n){for(var r=e.length,o=n+-1;++o<r;)if(t(e[o],o,e))return o;return-1}(e,k_,n)}(e,t,0)>-1}var __=/^(?:0|[1-9]\d*)$/;function C_(e,t){var n=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&__.test(e))&&e>-1&&e%1==0&&e<t}function E_(e,t,n){"__proto__"==t&&y_?y_(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function S_(e,t){return e===t||e!=e&&t!=t}var B_=Object.prototype.hasOwnProperty;function N_(e,t,n){var r=e[t];B_.call(e,t)&&S_(r,n)&&(void 0!==n||t in e)||E_(e,t,n)}var M_=Math.max;function T_(e,t,n){return t=M_(void 0===t?e.length-1:t,0),function(){for(var r=arguments,o=-1,i=M_(r.length-t,0),a=Array(i);++o<i;)a[o]=r[t+o];o=-1;for(var l=Array(t+1);++o<t;)l[o]=r[o];return l[t]=n(a),function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}(e,this,l)}}function V_(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}function A_(e){return null!=e&&V_(e.length)&&!Xx(e)}var z_=Object.prototype;function O_(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||z_)}function I_(e){return jx(e)&&"[object Arguments]"==Fx(e)}var D_=Object.prototype,P_=D_.hasOwnProperty,$_=D_.propertyIsEnumerable,L_=I_(function(){return arguments}())?I_:function(e){return jx(e)&&P_.call(e,"callee")&&!$_.call(e,"callee")};var R_="object"==typeof exports&&exports&&!exports.nodeType&&exports,H_=R_&&"object"==typeof module&&module&&!module.nodeType&&module,F_=H_&&H_.exports===R_?Ox.Buffer:void 0,j_=(F_?F_.isBuffer:void 0)||function(){return!1},U_={};function G_(e){return function(t){return e(t)}}U_["[object Float32Array]"]=U_["[object Float64Array]"]=U_["[object Int8Array]"]=U_["[object Int16Array]"]=U_["[object Int32Array]"]=U_["[object Uint8Array]"]=U_["[object Uint8ClampedArray]"]=U_["[object Uint16Array]"]=U_["[object Uint32Array]"]=!0,U_["[object Arguments]"]=U_["[object Array]"]=U_["[object ArrayBuffer]"]=U_["[object Boolean]"]=U_["[object DataView]"]=U_["[object Date]"]=U_["[object Error]"]=U_["[object Function]"]=U_["[object Map]"]=U_["[object Number]"]=U_["[object Object]"]=U_["[object RegExp]"]=U_["[object Set]"]=U_["[object String]"]=U_["[object WeakMap]"]=!1;var q_="object"==typeof exports&&exports&&!exports.nodeType&&exports,Z_=q_&&"object"==typeof module&&module&&!module.nodeType&&module,W_=Z_&&Z_.exports===q_&&Ax.process,K_=function(){try{var e=Z_&&Z_.require&&Z_.require("util").types;return e||W_&&W_.binding&&W_.binding("util")}catch(hR){}}(),J_=K_&&K_.isTypedArray,Y_=J_?G_(J_):function(e){return jx(e)&&V_(e.length)&&!!U_[Fx(e)]},X_=Object.prototype.hasOwnProperty;function Q_(e,t){var n=qx(e),r=!n&&L_(e),o=!n&&!r&&j_(e),i=!n&&!r&&!o&&Y_(e),a=n||r||o||i,l=a?function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}(e.length,String):[],s=l.length;for(var c in e)!t&&!X_.call(e,c)||a&&("length"==c||o&&("offset"==c||"parent"==c)||i&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||C_(c,s))||l.push(c);return l}function eC(e,t){return function(n){return e(t(n))}}var tC=eC(Object.keys,Object),nC=Object.prototype.hasOwnProperty;function rC(e){if(!O_(e))return tC(e);var t=[];for(var n in Object(e))nC.call(e,n)&&"constructor"!=n&&t.push(n);return t}function oC(e){return A_(e)?Q_(e):rC(e)}var iC=Object.prototype.hasOwnProperty;function aC(e){if(!Jx(e))return function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}(e);var t=O_(e),n=[];for(var r in e)("constructor"!=r||!t&&iC.call(e,r))&&n.push(r);return n}function lC(e){return A_(e)?Q_(e,!0):aC(e)}var sC=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,cC=/^\w*$/;function dC(e,t){if(qx(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Ux(e))||(cC.test(e)||!sC.test(e)||null!=t&&e in Object(t))}var uC=u_(Object,"create");var pC=Object.prototype.hasOwnProperty;var hC=Object.prototype.hasOwnProperty;function mC(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function fC(e,t){for(var n=e.length;n--;)if(S_(e[n][0],t))return n;return-1}mC.prototype.clear=function(){this.__data__=uC?uC(null):{},this.size=0},mC.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},mC.prototype.get=function(e){var t=this.__data__;if(uC){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return pC.call(t,e)?t[e]:void 0},mC.prototype.has=function(e){var t=this.__data__;return uC?void 0!==t[e]:hC.call(t,e)},mC.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=uC&&void 0===t?"__lodash_hash_undefined__":t,this};var gC=Array.prototype.splice;function vC(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}vC.prototype.clear=function(){this.__data__=[],this.size=0},vC.prototype.delete=function(e){var t=this.__data__,n=fC(t,e);return!(n<0)&&(n==t.length-1?t.pop():gC.call(t,n,1),--this.size,!0)},vC.prototype.get=function(e){var t=this.__data__,n=fC(t,e);return n<0?void 0:t[n][1]},vC.prototype.has=function(e){return fC(this.__data__,e)>-1},vC.prototype.set=function(e,t){var n=this.__data__,r=fC(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this};var yC=u_(Ox,"Map");function bC(e,t){var n=e.__data__;return function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}(t)?n["string"==typeof t?"string":"hash"]:n.map}function wC(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}wC.prototype.clear=function(){this.size=0,this.__data__={hash:new mC,map:new(yC||vC),string:new mC}},wC.prototype.delete=function(e){var t=bC(this,e).delete(e);return this.size-=t?1:0,t},wC.prototype.get=function(e){return bC(this,e).get(e)},wC.prototype.has=function(e){return bC(this,e).has(e)},wC.prototype.set=function(e,t){var n=bC(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this};function kC(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(kC.Cache||wC),n}kC.Cache=wC;var xC=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,_C=/\\(\\)?/g,CC=function(e){var t=kC(e,function(e){return 500===n.size&&n.clear(),e}),n=t.cache;return t}(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(xC,function(e,n,r,o){t.push(r?o.replace(_C,"$1"):n||e)}),t});function EC(e){return null==e?"":Kx(e)}function SC(e,t){return qx(e)?e:dC(e,t)?[e]:CC(EC(e))}function BC(e){if("string"==typeof e||Ux(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function NC(e,t){for(var n=0,r=(t=SC(t,e)).length;null!=e&&n<r;)e=e[BC(t[n++])];return n&&n==r?e:void 0}function MC(e,t,n){var r=null==e?void 0:NC(e,t);return void 0===r?n:r}function TC(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}var VC=Ix?Ix.isConcatSpreadable:void 0;function AC(e){return qx(e)||L_(e)||!!(VC&&e&&e[VC])}function zC(e,t,n,r,o){var i=-1,a=e.length;for(n||(n=AC),o||(o=[]);++i<a;){var l=e[i];n(l)?TC(o,l):r||(o[o.length]=l)}return o}function OC(e){return(null==e?0:e.length)?zC(e):[]}function IC(e){return w_(T_(e,void 0,OC),e+"")}var DC=eC(Object.getPrototypeOf,Object),PC=Function.prototype,$C=Object.prototype,LC=PC.toString,RC=$C.hasOwnProperty,HC=LC.call(Object);function FC(e){var t=this.__data__=new vC(e);this.size=t.size}FC.prototype.clear=function(){this.__data__=new vC,this.size=0},FC.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},FC.prototype.get=function(e){return this.__data__.get(e)},FC.prototype.has=function(e){return this.__data__.has(e)},FC.prototype.set=function(e,t){var n=this.__data__;if(n instanceof vC){var r=n.__data__;if(!yC||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new wC(r)}return n.set(e,t),this.size=n.size,this};var jC="object"==typeof exports&&exports&&!exports.nodeType&&exports,UC=jC&&"object"==typeof module&&module&&!module.nodeType&&module,GC=UC&&UC.exports===jC?Ox.Buffer:void 0;function qC(){return[]}GC&&GC.allocUnsafe;var ZC=Object.prototype.propertyIsEnumerable,WC=Object.getOwnPropertySymbols,KC=WC?function(e){return null==e?[]:(e=Object(e),function(e,t){for(var n=-1,r=null==e?0:e.length,o=0,i=[];++n<r;){var a=e[n];t(a,n,e)&&(i[o++]=a)}return i}(WC(e),function(t){return ZC.call(e,t)}))}:qC,JC=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)TC(t,KC(e)),e=DC(e);return t}:qC;function YC(e,t,n){var r=t(e);return qx(e)?r:TC(r,n(e))}function XC(e){return YC(e,oC,KC)}function QC(e){return YC(e,lC,JC)}var eE=u_(Ox,"DataView"),tE=u_(Ox,"Promise"),nE=u_(Ox,"Set"),rE="[object Map]",oE="[object Promise]",iE="[object Set]",aE="[object WeakMap]",lE="[object DataView]",sE=r_(eE),cE=r_(yC),dE=r_(tE),uE=r_(nE),pE=r_(p_),hE=Fx;(eE&&hE(new eE(new ArrayBuffer(1)))!=lE||yC&&hE(new yC)!=rE||tE&&hE(tE.resolve())!=oE||nE&&hE(new nE)!=iE||p_&&hE(new p_)!=aE)&&(hE=function(e){var t=Fx(e),n="[object Object]"==t?e.constructor:void 0,r=n?r_(n):"";if(r)switch(r){case sE:return lE;case cE:return rE;case dE:return oE;case uE:return iE;case pE:return aE}return t});var mE=Object.prototype.hasOwnProperty;var fE=Ox.Uint8Array;function gE(e){var t=new e.constructor(e.byteLength);return new fE(t).set(new fE(e)),t}var vE=/\w*$/;var yE=Ix?Ix.prototype:void 0,bE=yE?yE.valueOf:void 0;function wE(e,t,n){var r,o,i,a,l,s=e.constructor;switch(t){case"[object ArrayBuffer]":return gE(e);case"[object Boolean]":case"[object Date]":return new s(+e);case"[object DataView]":return l=gE((a=e).buffer),new a.constructor(l,a.byteOffset,a.byteLength);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return function(e){var t=gE(e.buffer);return new e.constructor(t,e.byteOffset,e.length)}(e);case"[object Map]":case"[object Set]":return new s;case"[object Number]":case"[object String]":return new s(e);case"[object RegExp]":return(i=new(o=e).constructor(o.source,vE.exec(o))).lastIndex=o.lastIndex,i;case"[object Symbol]":return r=e,bE?Object(bE.call(r)):{}}}var kE=K_&&K_.isMap,xE=kE?G_(kE):function(e){return jx(e)&&"[object Map]"==hE(e)};var _E=K_&&K_.isSet,CE=_E?G_(_E):function(e){return jx(e)&&"[object Set]"==hE(e)},EE="[object Arguments]",SE="[object Function]",BE="[object Object]",NE={};function ME(e,t,n,r,o,i){var a;if(n&&(a=o?n(e,r,o,i):n(e)),void 0!==a)return a;if(!Jx(e))return e;var l=qx(e);if(l)a=function(e){var t=e.length,n=new e.constructor(t);return t&&"string"==typeof e[0]&&mE.call(e,"index")&&(n.index=e.index,n.input=e.input),n}(e);else{var s=hE(e),c=s==SE||"[object GeneratorFunction]"==s;if(j_(e))return e.slice();if(s==BE||s==EE||c&&!o)a={};else{if(!NE[s])return o?e:{};a=wE(e,s)}}i||(i=new FC);var d=i.get(e);if(d)return d;i.set(e,a),CE(e)?e.forEach(function(r){a.add(ME(r,t,n,r,e,i))}):xE(e)&&e.forEach(function(r,o){a.set(o,ME(r,t,n,o,e,i))});var u=l?void 0:QC(e);return function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););}(u||e,function(r,o){u&&(r=e[o=r]),N_(a,o,ME(r,t,n,o,e,i))}),a}NE[EE]=NE["[object Array]"]=NE["[object ArrayBuffer]"]=NE["[object DataView]"]=NE["[object Boolean]"]=NE["[object Date]"]=NE["[object Float32Array]"]=NE["[object Float64Array]"]=NE["[object Int8Array]"]=NE["[object Int16Array]"]=NE["[object Int32Array]"]=NE["[object Map]"]=NE["[object Number]"]=NE[BE]=NE["[object RegExp]"]=NE["[object Set]"]=NE["[object String]"]=NE["[object Symbol]"]=NE["[object Uint8Array]"]=NE["[object Uint8ClampedArray]"]=NE["[object Uint16Array]"]=NE["[object Uint32Array]"]=!0,NE["[object Error]"]=NE[SE]=NE["[object WeakMap]"]=!1;function TE(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new wC;++t<n;)this.add(e[t])}function VE(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}function AE(e,t){return e.has(t)}TE.prototype.add=TE.prototype.push=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this},TE.prototype.has=function(e){return this.__data__.has(e)};function zE(e,t,n,r,o,i){var a=1&n,l=e.length,s=t.length;if(l!=s&&!(a&&s>l))return!1;var c=i.get(e),d=i.get(t);if(c&&d)return c==t&&d==e;var u=-1,p=!0,h=2&n?new TE:void 0;for(i.set(e,t),i.set(t,e);++u<l;){var m=e[u],f=t[u];if(r)var g=a?r(f,m,u,t,e,i):r(m,f,u,e,t,i);if(void 0!==g){if(g)continue;p=!1;break}if(h){if(!VE(t,function(e,t){if(!AE(h,t)&&(m===e||o(m,e,n,r,i)))return h.push(t)})){p=!1;break}}else if(m!==f&&!o(m,f,n,r,i)){p=!1;break}}return i.delete(e),i.delete(t),p}function OE(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function IE(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}var DE=Ix?Ix.prototype:void 0,PE=DE?DE.valueOf:void 0;var $E=Object.prototype.hasOwnProperty;var LE="[object Arguments]",RE="[object Array]",HE="[object Object]",FE=Object.prototype.hasOwnProperty;function jE(e,t,n,r,o,i){var a=qx(e),l=qx(t),s=a?RE:hE(e),c=l?RE:hE(t),d=(s=s==LE?HE:s)==HE,u=(c=c==LE?HE:c)==HE,p=s==c;if(p&&j_(e)){if(!j_(t))return!1;a=!0,d=!1}if(p&&!d)return i||(i=new FC),a||Y_(e)?zE(e,t,n,r,o,i):function(e,t,n,r,o,i,a){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!i(new fE(e),new fE(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return S_(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var l=OE;case"[object Set]":var s=1&r;if(l||(l=IE),e.size!=t.size&&!s)return!1;var c=a.get(e);if(c)return c==t;r|=2,a.set(e,t);var d=zE(l(e),l(t),r,o,i,a);return a.delete(e),d;case"[object Symbol]":if(PE)return PE.call(e)==PE.call(t)}return!1}(e,t,s,n,r,o,i);if(!(1&n)){var h=d&&FE.call(e,"__wrapped__"),m=u&&FE.call(t,"__wrapped__");if(h||m){var f=h?e.value():e,g=m?t.value():t;return i||(i=new FC),o(f,g,n,r,i)}}return!!p&&(i||(i=new FC),function(e,t,n,r,o,i){var a=1&n,l=XC(e),s=l.length;if(s!=XC(t).length&&!a)return!1;for(var c=s;c--;){var d=l[c];if(!(a?d in t:$E.call(t,d)))return!1}var u=i.get(e),p=i.get(t);if(u&&p)return u==t&&p==e;var h=!0;i.set(e,t),i.set(t,e);for(var m=a;++c<s;){var f=e[d=l[c]],g=t[d];if(r)var v=a?r(g,f,d,t,e,i):r(f,g,d,e,t,i);if(!(void 0===v?f===g||o(f,g,n,r,i):v)){h=!1;break}m||(m="constructor"==d)}if(h&&!m){var y=e.constructor,b=t.constructor;y==b||!("constructor"in e)||!("constructor"in t)||"function"==typeof y&&y instanceof y&&"function"==typeof b&&b instanceof b||(h=!1)}return i.delete(e),i.delete(t),h}(e,t,n,r,o,i))}function UE(e,t,n,r,o){return e===t||(null==e||null==t||!jx(e)&&!jx(t)?e!=e&&t!=t:jE(e,t,n,r,UE,o))}function GE(e){return e==e&&!Jx(e)}function qE(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}}function ZE(e){var t=function(e){for(var t=oC(e),n=t.length;n--;){var r=t[n],o=e[r];t[n]=[r,o,GE(o)]}return t}(e);return 1==t.length&&t[0][2]?qE(t[0][0],t[0][1]):function(n){return n===e||function(e,t,n,r){var o=n.length,i=o;if(null==e)return!i;for(e=Object(e);o--;){var a=n[o];if(a[2]?a[1]!==e[a[0]]:!(a[0]in e))return!1}for(;++o<i;){var l=(a=n[o])[0],s=e[l],c=a[1];if(a[2]){if(void 0===s&&!(l in e))return!1}else if(!UE(c,s,3,r,new FC))return!1}return!0}(n,0,t)}}function WE(e,t){return null!=e&&t in Object(e)}function KE(e,t,n){for(var r=-1,o=(t=SC(t,e)).length,i=!1;++r<o;){var a=BC(t[r]);if(!(i=null!=e&&n(e,a)))break;e=e[a]}return i||++r!=o?i:!!(o=null==e?0:e.length)&&V_(o)&&C_(a,o)&&(qx(e)||L_(e))}function JE(e,t){return null!=e&&KE(e,t,WE)}function YE(e){return dC(e)?(t=BC(e),function(e){return null==e?void 0:e[t]}):function(e){return function(t){return NC(t,e)}}(e);var t}function XE(e){return"function"==typeof e?e:null==e?Yx:"object"==typeof e?qx(e)?(t=e[0],n=e[1],dC(t)&&GE(n)?qE(BC(t),n):function(e){var r=MC(e,t);return void 0===r&&r===n?JE(e,t):UE(n,r,3)}):ZE(e):YE(e);var t,n}var QE=function(e,t,n){for(var r=-1,o=Object(e),i=n(e),a=i.length;a--;){var l=i[++r];if(!1===t(o[l],l,o))break}return e};var eS,tS=(eS=function(e,t){return e&&QE(e,t,oC)},function(e,t){if(null==e)return e;if(!A_(e))return eS(e,t);for(var n=e.length,r=-1,o=Object(e);++r<n&&!1!==t(o[r],r,o););return e});function nS(e){return jx(e)&&A_(e)}function rS(e,t,n){for(var r=-1,o=null==e?0:e.length;++r<o;)if(n(t,e[r]))return!0;return!1}function oS(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}var iS=function(e,t){return w_(T_(e,t,Yx),e+"")}(function(e,t){var n=oS(t);return nS(n)&&(n=void 0),nS(e)?function(e,t,n,r){var o=-1,i=x_,a=!0,l=e.length,s=[],c=t.length;if(!l)return s;r?(i=rS,a=!1):t.length>=200&&(i=AE,a=!1,t=new TE(t));e:for(;++o<l;){var d=e[o],u=d;if(d=r||0!==d?d:0,a&&u==u){for(var p=c;p--;)if(t[p]===u)continue e;s.push(d)}else i(t,u,r)||s.push(d)}return s}(e,zC(t,0,nS,!0),0,n):[]});var aS,lS=(aS=oC,function(e){var t,n,r,o=hE(e);return"[object Map]"==o?OE(e):"[object Set]"==o?(t=e,n=-1,r=Array(t.size),t.forEach(function(e){r[++n]=[e,e]}),r):function(e,t){return Gx(t,function(t){return[t,e[t]]})}(e,aS(e))}),sS=/[\\^$.*+?()[\]{}|]/g,cS=RegExp(sS.source);var dS=Object.prototype.hasOwnProperty;function uS(e,t){return null!=e&&dS.call(e,t)}function pS(e,t){return null!=e&&KE(e,t,uS)}function hS(e,t){return t.length<2?e:NC(e,function(e,t,n){var r=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(n=n>o?o:n)<0&&(n+=o),o=t>n?0:n-t>>>0,t>>>=0;for(var i=Array(o);++r<o;)i[r]=e[r+t];return i}(t,0,-1))}function mS(e){return!0===e||!1===e||jx(e)&&"[object Boolean]"==Fx(e)}var fS=Object.prototype.hasOwnProperty;function gS(e){if(null==e)return!0;if(A_(e)&&(qx(e)||"string"==typeof e||"function"==typeof e.splice||j_(e)||Y_(e)||L_(e)))return!e.length;var t=hE(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(O_(e))return!rC(e).length;for(var n in e)if(fS.call(e,n))return!1;return!0}function vS(e,t){return UE(e,t)}function yS(e){return void 0===e}var bS=Object.prototype.hasOwnProperty;function wS(e,t){var n=-1,r=(t=SC(t,e)).length;if(!r)return!0;for(;++n<r;){var o=BC(t[n]);if("__proto__"===o&&!bS.call(e,"__proto__"))return!1;if(("constructor"===o||"prototype"===o)&&n<r-1)return!1}var i=hS(e,t);return null==i||delete i[BC(oS(t))]}function kS(e){return function(e){if(!jx(e)||"[object Object]"!=Fx(e))return!1;var t=DC(e);if(null===t)return!0;var n=RC.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&LC.call(n)==HC}(e)?void 0:e}var xS=IC(function(e,t){var n={};if(null==e)return n;var r=!1;t=Gx(t,function(t){return t=SC(t,e),r||(r=t.length>1),t}),function(e,t,n){var r=!n;n||(n={});for(var o=-1,i=t.length;++o<i;){var a=t[o],l=void 0;void 0===l&&(l=e[a]),r?E_(n,a,l):N_(n,a,l)}}(e,QC(e),n),r&&(n=ME(n,7,kS));for(var o=t.length;o--;)wS(n,t[o]);return n});function _S(e,t,n,r){if(!Jx(e))return e;for(var o=-1,i=(t=SC(t,e)).length,a=i-1,l=e;null!=l&&++o<i;){var s=BC(t[o]),c=n;if("__proto__"===s||"constructor"===s||"prototype"===s)return e;if(o!=a){var d=l[s];void 0===(c=void 0)&&(c=Jx(d)?d:C_(t[o+1])?[]:{})}N_(l,s,c),l=l[s]}return e}function CS(e,t){if(e!==t){var n=void 0!==e,r=null===e,o=e==e,i=Ux(e),a=void 0!==t,l=null===t,s=t==t,c=Ux(t);if(!l&&!c&&!i&&e>t||i&&a&&s&&!l&&!c||r&&a&&s||!n&&s||!o)return 1;if(!r&&!i&&!c&&e<t||c&&n&&o&&!r&&!i||l&&n&&o||!a&&o||!s)return-1}return 0}function ES(e,t,n){t=t.length?Gx(t,function(e){return qx(e)?function(t){return NC(t,1===e.length?e[0]:e)}:e}):[Yx];var r=-1;t=Gx(t,G_(XE));var o=function(e,t){var n=-1,r=A_(e)?Array(e.length):[];return tS(e,function(e,o,i){r[++n]=t(e,o,i)}),r}(e,function(e,n,o){return{criteria:Gx(t,function(t){return t(e)}),index:++r,value:e}});return function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}(o,function(e,t){return function(e,t,n){for(var r=-1,o=e.criteria,i=t.criteria,a=o.length,l=n.length;++r<a;){var s=CS(o[r],i[r]);if(s)return r>=l?s:s*("desc"==n[r]?-1:1)}return e.index-t.index}(e,t,n)})}function SS(e,t){return function(e,t,n){for(var r=-1,o=t.length,i={};++r<o;){var a=t[r],l=NC(e,a);n(l,a)&&_S(i,SC(a,e),l)}return i}(e,t,function(t,n){return JE(e,n)})}var BS=IC(function(e,t){return null==e?{}:SS(e,t)});function NS(e,t){return e&&e.length?function(e,t){for(var n=-1,r=e.length,o=0,i=[];++n<r;){var a=e[n],l=t?t(a):a;if(!n||!S_(l,s)){var s=l;i[o++]=0===a?0:a}}return i}(e,XE(t)):[]}var MS=0;function TS(e){var t=++MS;return EC(e)+t}const VS=e=>{var t,n;return[...(null==(t=e.enabled_pricings)?void 0:t.map(({pricing_id:e})=>e))??[],...(null==(n=e.override_pricings)?void 0:n.map(e=>"id"in e?e.id:e.original_pricing_id))??[]]},AS=(e,t)=>{var n;const r=e=>null==e?void 0:e.map(e=>{var t;return{...e,configs:null==(t=e.configs)?void 0:t.map(o)}}),o=e=>{var n,r,i;const a=null==(n=t.included_volumes)?void 0:n.find(t=>t.pricing_item_config_id===e.id),l=null==(r=t.seats_values)?void 0:r.find(t=>t.pricing_item_config_id===e.id);return{...e,...!gS(a)&&{default_included_volume:BS(a,["amount","number","reset_type"])},...!gS(l)&&{default_seats_value:BS(l,"number")},conditions:e.conditions?{...e.conditions,configs:null==(i=e.conditions.configs)?void 0:i.map(o)}:void 0}};return{...e,entitlements:(e=>{var n,r,o;const i=t=>{var n;return null==(n=e.products)?void 0:n.some(e=>{var n;return null==(n=e.features)?void 0:n.some(e=>e.id===t.feature_id)})},a=(null==(r=null==(n=t.entitlements)?void 0:n.filter(e=>i(e)))?void 0:r.reduce((t,n)=>{var r,o;const i=null==(o=null==(r=e.entitlements)?void 0:r.find(e=>e.feature_id===n.feature_id))?void 0:o.feature;return i?[...t,{...n,feature:i}]:t},[]))??[];if(gS(a))return e.entitlements;return[...(null==(o=e.entitlements)?void 0:o.filter(e=>i(e)&&!(null==a?void 0:a.some(t=>t.feature_id===e.feature_id))))??[],...a]})(e),items:null==(n=e.items)?void 0:n.map(e=>{return{...e,...e.configs&&{configs:e.configs.map(o)},...e.billing_period_configs&&{billing_period_configs:r(e.billing_period_configs)},...e.pricing_currency_configs&&{pricing_currency_configs:(t=e.pricing_currency_configs,null==t?void 0:t.map(e=>{var t;return{...e,configs:null==(t=e.configs)?void 0:t.map(o),billing_period_configs:r(e.billing_period_configs)}}))}};var t})}},zS=(e,t,n={displayDisabledAddonPricings:!1})=>{var r,o;const i=e=>n.displayDisabledAddonPricings||"ADDON"!==e.product_type||((e,t)=>{var n,r;return!(!(null==(n=e.enabled_pricings)?void 0:n.some(({pricing_id:e})=>e===t.id))&&!(null==(r=e.override_pricings)?void 0:r.some(e=>"id"in e&&e.id===t.id||e.original_pricing_id===t.id)))})(t,e);return{...e,pricing_categories:null==(o=null==(r=e.pricing_categories)?void 0:r.map(e=>{var n,r,o,a;return{...e,pricing_groups:null==(r=null==(n=e.pricing_groups)?void 0:n.map(e=>{var n,r;return{...e,pricings:null==(r=null==(n=e.pricings)?void 0:n.filter(i))?void 0:r.map(e=>AS(e,t))}}))?void 0:r.filter(e=>!gS(e.pricings)),pricings:null==(a=null==(o=e.pricings)?void 0:o.filter(i))?void 0:a.map(e=>AS(e,t))}}))?void 0:o.filter(e=>n.displayDisabledAddonPricings||!(gS(e.pricing_groups)&&gS(e.pricings)))}},OS=e=>"REVENUE"===e.type,IS=e=>"DEDUCTION"===e.type,DS=e=>["AT_MOST_ONE","EXACTLY_ONE"].includes(e.selection_constraint),PS={equals:"equals",notEquals:"does not equal",in:"equals one of",inOutput:"equals",notIn:"does not equal one of",notInOutput:"does not equal",greaterThan:"greater than",greaterThanOrEquals:"greater than or equal to",lessThan:"less than",lessThanOrEquals:"less than or equal to",empty:"is empty",notEmpty:"is not empty",contains:"contains",notContains:"does not contain",or:"or",unsupported:"unsupported",unknown:"Unknown"},$S=(e=PS)=>({propertyName:t,comparator:n,value:r,values:o},{hasFormatting:i}={})=>{const a=((e=PS)=>[{comparator:"CONTAINS",forType:["STRING"],requiresInput:!0,symbol:"CONTAINS",label:{input:e.contains,output:e.contains}},{comparator:"NOT_CONTAINS",forType:["STRING"],requiresInput:!0,symbol:"NOT CONTAINS",label:{input:e.notContains,output:e.notContains}},{comparator:"EMPTY",forType:["STRING"],requiresInput:!1,symbol:"EMPTY",label:{input:e.empty,output:e.empty}},{comparator:"NOT_EMPTY",forType:["STRING"],requiresInput:!1,symbol:"NOT EMPTY",label:{input:e.notEmpty,output:e.notEmpty}},{comparator:"EQUALS",forType:["NUMBER","STRING","ENUM"],requiresInput:!0,symbol:"=",label:{input:e.equals,output:e.equals}},{comparator:"NOT_EQUALS",forType:["NUMBER","STRING","ENUM"],requiresInput:!0,symbol:"!=",label:{input:e.notEquals,output:e.notEquals}},{comparator:"IN",forType:["NUMBER","STRING","ENUM"],requiresInput:!0,symbol:"IN ()",label:{input:e.in,output:e.inOutput}},{comparator:"NOT_IN",forType:["NUMBER","STRING","ENUM"],requiresInput:!0,symbol:"NOT IN()",label:{input:e.notIn,output:e.notInOutput}},{comparator:"GREATER_THAN",forType:["NUMBER"],requiresInput:!0,symbol:">",label:{input:e.greaterThan,output:e.greaterThan}},{comparator:"GREATER_THAN_OR_EQUALS",forType:["NUMBER"],requiresInput:!0,symbol:">=",label:{input:e.greaterThanOrEquals,output:e.greaterThanOrEquals}},{comparator:"LESS_THAN",forType:["NUMBER"],requiresInput:!0,symbol:"<",label:{input:e.lessThan,output:e.lessThan}},{comparator:"LESS_THAN_OR_EQUALS",forType:["NUMBER"],requiresInput:!0,symbol:"<=",label:{input:e.lessThanOrEquals,output:e.lessThanOrEquals}}])(e).find(e=>e.comparator===n),l=null==o?void 0:o.reduce((t,n,r,o)=>{const a=i?`<strong class="font-semibold">${n}</strong>`:n;return r===o.length-1?`${t} ${(null==e?void 0:e.or)??"or"} ${a}`:0===r?a:[t,a].join(", ")},"");return a?["IN","NOT_IN"].includes(a.comparator)&&o?i?`<strong>${t}</strong> ${a.label.output} <strong>${l}</strong>`:`${t} ${a.label.output} ${l}`:i?`<strong class="font-semibold">${t}</strong> ${a.label.output} <strong class="font-semibold">${r}</strong>`:`${t} ${a.label.output} ${r}`:(null==e?void 0:e.unsupported)??"Unsupported comparator"},LS=(e,t)=>!!e.type&&t.includes(e.type),RS=e=>LS(e,["FLAT_TOP_UP","TIERED_TOP_UP","STAIR_STEP_TOP_UP"]),HS=e=>LS(e,["TIERED","TIERED_TOP_UP"]),FS=e=>LS(e,["STAIR_STEP","STAIR_STEP_TOP_UP"]),jS=e=>{var t,n;return[e,...(null==(n=null==(t=e.conditions)?void 0:t.configs)?void 0:n.flatMap(e=>jS(e)))??[]]},US=e=>({pricing:t,item:n,config:r})=>{var o,i,a,l;return[(null==t?void 0:t.name)??(null==(i=null==(o=null==t?void 0:t.products)?void 0:o[0])?void 0:i.name),null==(l=null==(a=null==n?void 0:n.product_items)?void 0:a[0])?void 0:l.name,r&&(s=r,(null==(c=s.conditions)?void 0:c.name)?null==(d=s.conditions)?void 0:d.name:(null==(u=s.conditions)?void 0:u.meter_properties)?((e=PS)=>(t,n)=>t.map(t=>$S(e)(t,n)).join(" and "))(e)(null==(p=s.conditions)?void 0:p.meter_properties.map(e=>{var t;return{propertyName:(null==(t=null==e?void 0:e.meter_property)?void 0:t.name)??"Unknown",comparator:e.comparator,value:e.value,values:e.values}}),{hasFormatting:!1}):void 0)].filter(Boolean).join(" - ");var s,c,d,u,p},GS=e=>!!e&&"number"in e,qS=e=>!!e&&"count"in e,ZS=e=>!!e&&"amount"in e,WS=e=>"ORGANIZATION"===e.type,KS=e=>"INDIVIDUAL"===e.type,JS=e=>t=>t?t.tier_top_bound&&GS(t.tier_top_bound)?e.formatNumber(+t.tier_top_bound.number):qS(t.tier_top_bound)?e.formatNumber(+t.tier_top_bound.count):ZS(t.tier_top_bound)?Bx(t.tier_top_bound.amount):void 0:0,YS=e=>(t,n,r)=>r===n.length-1?e.infinite:t.tier_top_bound&&"number"in t.tier_top_bound&&GS(t.tier_top_bound)?e.formatNumber(+t.tier_top_bound.number):t.tier_top_bound&&"count"in t.tier_top_bound&&qS(t.tier_top_bound)?e.formatNumber(+t.tier_top_bound.count):t.tier_top_bound&&"amount"in t.tier_top_bound&&ZS(t.tier_top_bound)?Bx(t.tier_top_bound.amount):void 0,XS=(e,t)=>{var n,r;return null==(r=null==(n=e.markup)?void 0:n.pricing_item_configs)?void 0:r.find(({ids:e})=>null==e?void 0:e.includes(t.id))},QS=t=>t.every(t=>t.type===e.Comment||(t.type===e.Text&&"string"==typeof t.children&&!t.children.trim()||!(t.type!==e.Fragment||!QS(t.children)))),eB=e=>gS(e)&&"boolean"!=typeof e?null:e,tB=e=>e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'"),nB=({from:e,to:t,nullifyEmptyValues:n=!1})=>{const r=function(e){for(var t=-1,n=null==e?0:e.length,r={};++t<n;){var o=e[t];E_(r,o[0],o[1])}return r}(iS(lS(t),lS(e),vS));return n?Object.entries(r).reduce((e,[t,n])=>({...e,[t]:eB(n)}),{}):r};function rB(e){var t;return(null==(t=_x.find(t=>t.key===e))?void 0:t.value)??e}const oB=["US","CA"];function iB(e){if(oB.includes(e.country)){const t=aB([e.line1,e.line2],", "),n=aB([e.state,e.postal_code]," "),r=rB(e.country);return aB([t,e.city,n,r],", ")}const t=aB([e.line1,e.line2]," "),n=aB([e.postal_code,e.city]," "),r=rB(e.country);return aB([t,n,e.state,r],", ")}function aB(e,t){return e.filter(Boolean).join(t)}const lB=(e,t)=>{const n=new Date(e),r=new Date(t),o=r.getFullYear()-n.getFullYear(),i=new Date(n);if(i.setFullYear(i.getFullYear()+o),o>0&&i.getTime()===r.getTime())return{type:"YEAR",value:o};const a=12*(r.getFullYear()-n.getFullYear())+(r.getMonth()-n.getMonth()),l=new Date(n);if(l.setMonth(l.getMonth()+a),a>0&&l.getTime()===r.getTime())return{type:"MONTH",value:a};const s=Math.round((r.getTime()-n.getTime())/864e5);return s>0&&s%7==0?{type:"WEEK",value:s/7}:{type:"DAY",value:s}},sB=e=>KS(e)?cB(e.individual.name):WS(e)?e.organization.legal_name:void 0,cB=e=>{if(e)return[e.first_name,e.infix,e.last_name].filter(e=>e).join(" ")};const dB=(e,t)=>e.find(e=>e.currency===t),uB=(e,t)=>{var n,r;return null==(r=null==(n=e.find(e=>e.currency===t))?void 0:n.configs)?void 0:r[0]},pB=(e,t)=>{var n,r;return null==(r=null==(n=e.find(e=>vS(e.billing_period,t)))?void 0:n.configs)?void 0:r[0]},hB=["innerHTML"],mB=e.defineComponent({__name:"IconSpriteProvider",setup(t){const n=e.ref(null);return e.onMounted(async()=>{const e=await Promise.resolve().then(()=>require("./sprite-i5T7eZnk-C55G-dBo.js"));n.value=e.default}),(t,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[n.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"hidden",innerHTML:n.value},null,8,hB)):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default")],64))}}),fB=(e,t)=>{const n=e.__vccOpts||e;for(const[r,o]of t)n[r]=o;return n},gB=()=>{const t=e.ref(!1);return e.onMounted(()=>{t.value=!0}),t},vB=t=>{const n=(null==t?void 0:t.initialToggledItems)??[],r=(null==t?void 0:t.closeOthers)??!1,o=e.ref(n??[]);return{toggledItems:o,toggle:e=>((e,t=!1)=>{const n=o.value.find(t=>t===e);o.value=t?e===n?[]:[e]:n?o.value.filter(t=>t!==e):[...o.value,e]})(e,r),getIsOpen:e=>o.value.includes(e),toggleAll:e=>{0!==e.length&&(o.value.length===e.length?o.value=[]:o.value=e)}}},yB=(t=[])=>{const n=e.ref(t);return[n,e=>{const t=n.value.find(t=>t===e);n.value="number"==typeof t?n.value.filter(t=>t!==e):[...n.value,e]}]};function bB(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function wB(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bB(Object(n),!0).forEach(function(t){kB(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bB(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function kB(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function xB(t){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return Object.keys(t).reduce((r,o)=>(n.includes(o)||(r[o]=e.unref(t[o])),r),{})}function _B(e){return"function"==typeof e}function CB(e,t,n){let r=e;const o=t.split(".");for(let i=0;i<o.length;i++){if(!r[o[i]])return n;r=r[o[i]]}return r}function EB(t,n,r){return e.computed(()=>t.some(e=>CB(n,e,{[r]:!1})[r]))}function SB(t,n,r){return e.computed(()=>t.reduce((e,t)=>{const o=CB(n,t,{[r]:!1})[r]||[];return e.concat(o)},[]))}function BB(t,n,r,o){return t.call(o,e.unref(n),e.unref(r),o)}function NB(e){return void 0!==e.$valid?!e.$valid:!e}function MB(t,n,r,o,i,a,l,s,c,d,u){const p=e.ref(!1),h=t.$params||{},m=e.ref(null);let f,g;t.$async?({$invalid:f,$unwatch:g}=function(t,n,r,o,i,a,l){let{$lazy:s,$rewardEarly:c}=i,d=arguments.length>7&&void 0!==arguments[7]?arguments[7]:[],u=arguments.length>8?arguments[8]:void 0,p=arguments.length>9?arguments[9]:void 0,h=arguments.length>10?arguments[10]:void 0;const m=e.ref(!!o.value),f=e.ref(0);r.value=!1;const g=e.watch([n,o].concat(d,h),()=>{if(s&&!o.value||c&&!p.value&&!r.value)return;let e;try{e=BB(t,n,u,l)}catch(i){e=Promise.reject(i)}f.value++,r.value=!!f.value,m.value=!1,Promise.resolve(e).then(e=>{f.value--,r.value=!!f.value,a.value=e,m.value=NB(e)}).catch(e=>{f.value--,r.value=!!f.value,a.value=e,m.value=!0})},{immediate:!0,deep:"object"==typeof n});return{$invalid:m,$unwatch:g}}(t.$validator,n,p,r,o,m,i,t.$watchTargets,c,d,u)):({$invalid:f,$unwatch:g}=function(t,n,r,o,i,a,l,s){let{$lazy:c,$rewardEarly:d}=o;return{$unwatch:()=>({}),$invalid:e.computed(()=>{if(c&&!r.value||d&&!s.value)return!1;let e=!0;try{const r=BB(t,n,l,a);i.value=r,e=NB(r)}catch(o){i.value=o}return e})}}(t.$validator,n,r,o,m,i,c,d));const v=t.$message;return{$message:_B(v)?e.computed(()=>v(xB({$pending:p,$invalid:f,$params:xB(h),$model:n,$response:m,$validator:a,$propertyPath:s,$property:l}))):v||"",$params:h,$pending:p,$invalid:f,$response:m,$unwatch:g}}function TB(t){let{validations:n,state:r,key:o,parentKey:i,childResults:a,resultsCache:l,globalConfig:s={},instance:c,externalResults:d}=t;const u=i?`${i}.${o}`:o,{rules:p,nestedValidators:h,config:m,validationGroups:f}=function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const n=e.unref(t),r=Object.keys(n),o={},i={},a={};let l=null;return r.forEach(e=>{const t=n[e];switch(!0){case _B(t.$validator):o[e]=t;break;case _B(t):o[e]={$validator:t};break;case"$validationGroups"===e:l=t;break;case e.startsWith("$"):a[e]=t;break;default:i[e]=t}}),{rules:o,nestedValidators:i,config:a,validationGroups:l}}(n),g=wB(wB({},s),m),v=o?e.computed(()=>{const t=e.unref(r);return t?e.unref(t[o]):void 0}):r,y=wB({},e.unref(d)||{}),b=e.computed(()=>{const t=e.unref(d);return o?t?e.unref(t[o]):void 0:t}),w=function(t,n,r,o,i,a,l,s,c){const d=Object.keys(t),u=o.get(i,t),p=e.ref(!1),h=e.ref(!1),m=e.ref(0);if(u){if(!u.$partial)return u;u.$unwatch(),p.value=u.$dirty.value}const f={$dirty:p,$path:i,$touch:()=>{p.value||(p.value=!0)},$reset:()=>{p.value&&(p.value=!1)},$commit:()=>{}};return d.length?(d.forEach(e=>{f[e]=MB(t[e],n,f.$dirty,a,l,e,r,i,c,h,m)}),f.$externalResults=e.computed(()=>s.value?[].concat(s.value).map((e,t)=>({$propertyPath:i,$property:r,$validator:"$externalResults",$uid:`${i}-externalResult-${t}`,$message:e,$params:{},$response:null,$pending:!1})):[]),f.$invalid=e.computed(()=>{const t=d.some(t=>e.unref(f[t].$invalid));return h.value=t,!!f.$externalResults.value.length||t}),f.$pending=e.computed(()=>d.some(t=>e.unref(f[t].$pending))),f.$error=e.computed(()=>!!f.$dirty.value&&(f.$pending.value||f.$invalid.value)),f.$silentErrors=e.computed(()=>d.filter(t=>e.unref(f[t].$invalid)).map(t=>{const n=f[t];return e.reactive({$propertyPath:i,$property:r,$validator:t,$uid:`${i}-${t}`,$message:n.$message,$params:n.$params,$response:n.$response,$pending:n.$pending})}).concat(f.$externalResults.value)),f.$errors=e.computed(()=>f.$dirty.value?f.$silentErrors.value:[]),f.$unwatch=()=>d.forEach(e=>{f[e].$unwatch()}),f.$commit=()=>{h.value=!0,m.value=Date.now()},o.set(i,t,f),f):(u&&o.set(i,t,f),f)}(p,v,o,l,u,g,c,b,r),k=function(e,t,n,r,o,i,a){const l=Object.keys(e);return l.length?l.reduce((l,s)=>(l[s]=TB({validations:e[s],state:t,key:s,parentKey:n,resultsCache:r,globalConfig:o,instance:i,externalResults:a}),l),{}):{}}(h,v,u,l,g,c,b),x={};f&&Object.entries(f).forEach(e=>{let[t,n]=e;x[t]={$invalid:EB(n,k,"$invalid"),$error:EB(n,k,"$error"),$pending:EB(n,k,"$pending"),$errors:SB(n,k,"$errors"),$silentErrors:SB(n,k,"$silentErrors")}});const{$dirty:_,$errors:C,$invalid:E,$anyDirty:S,$error:B,$pending:N,$touch:M,$reset:T,$silentErrors:V,$commit:A}=function(t,n,r){const o=e.computed(()=>[n,r].filter(e=>e).reduce((t,n)=>t.concat(Object.values(e.unref(n))),[])),i=e.computed({get:()=>t.$dirty.value||!!o.value.length&&o.value.every(e=>e.$dirty),set(e){t.$dirty.value=e}}),a=e.computed(()=>{const n=e.unref(t.$silentErrors)||[],r=o.value.filter(t=>(e.unref(t).$silentErrors||[]).length).reduce((e,t)=>e.concat(...t.$silentErrors),[]);return n.concat(r)}),l=e.computed(()=>{const n=e.unref(t.$errors)||[],r=o.value.filter(t=>(e.unref(t).$errors||[]).length).reduce((e,t)=>e.concat(...t.$errors),[]);return n.concat(r)}),s=e.computed(()=>o.value.some(e=>e.$invalid)||e.unref(t.$invalid)||!1),c=e.computed(()=>o.value.some(t=>e.unref(t.$pending))||e.unref(t.$pending)||!1),d=e.computed(()=>o.value.some(e=>e.$dirty)||o.value.some(e=>e.$anyDirty)||i.value),u=e.computed(()=>!!i.value&&(c.value||s.value)),p=()=>{t.$touch(),o.value.forEach(e=>{e.$touch()})};return o.value.length&&o.value.every(e=>e.$dirty)&&p(),{$dirty:i,$errors:l,$invalid:s,$anyDirty:d,$error:u,$pending:c,$touch:p,$reset:()=>{t.$reset(),o.value.forEach(e=>{e.$reset()})},$silentErrors:a,$commit:()=>{t.$commit(),o.value.forEach(e=>{e.$commit()})}}}(w,k,a),z=o?e.computed({get:()=>e.unref(v),set:t=>{_.value=!0;const n=e.unref(r),i=e.unref(d);i&&(i[o]=y[o]),e.isRef(n[o])?n[o].value=t:n[o]=t}}):null;return o&&g.$autoDirty&&e.watch(v,()=>{_.value||M();const t=e.unref(d);t&&(t[o]=y[o])},{flush:"sync"}),e.reactive(wB(wB(wB({},w),{},{$model:z,$dirty:_,$error:B,$errors:C,$invalid:E,$anyDirty:S,$pending:N,$touch:M,$reset:T,$path:u||"__root",$silentErrors:V,$validate:async function(){return M(),g.$rewardEarly&&(A(),await e.nextTick()),await e.nextTick(),new Promise(t=>{if(!N.value)return t(!E.value);const n=e.watch(N,()=>{t(!E.value),n()})})},$commit:A},a&&{$getResultsForChild:function(e){return(a.value||{})[e]},$clearExternalResults:function(){e.isRef(d)?d.value=y:0===Object.keys(y).length?Object.keys(d).forEach(e=>{delete d[e]}):Object.assign(d,y)},$validationGroups:x}),k))}class VB{constructor(){this.storage=new Map}set(e,t,n){this.storage.set(e,{rules:t,result:n})}checkRulesValidity(t,n,r){const o=Object.keys(r),i=Object.keys(n);if(i.length!==o.length)return!1;return!!i.every(e=>o.includes(e))&&i.every(t=>!n[t].$params||Object.keys(n[t].$params).every(o=>e.unref(r[t].$params[o])===e.unref(n[t].$params[o])))}get(e,t){const n=this.storage.get(e);if(!n)return;const{rules:r,result:o}=n,i=this.checkRulesValidity(e,t,r),a=o.$unwatch?o.$unwatch:()=>({});return i?o:{$dirty:o.$dirty,$partial:!0,$unwatch:a}}}const AB={COLLECT_ALL:!0,COLLECT_NONE:!1},zB=Symbol("vuelidate#injectChildResults"),OB=Symbol("vuelidate#removeChildResults");function IB(t){return new Proxy(t,{get:(t,n)=>"object"==typeof t[n]?IB(t[n]):e.computed(()=>t[n])})}let DB=0;function PB(t,n){var r;let o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};1===arguments.length&&(o=t,t=void 0,n=void 0);let{$registerAs:i,$scope:a=AB.COLLECT_ALL,$stopPropagation:l,$externalResults:s,currentVueInstance:c}=o;const d=c||(null===(r=e.getCurrentInstance())||void 0===r?void 0:r.proxy),u=d?d.$options:{};i||(DB+=1,i=`_vuelidate_${DB}`);const p=e.ref({}),h=new VB,{childResults:m,sendValidationResultsToParent:f,removeValidationResultsFromParent:g}=d?function(t){let{$scope:n,instance:r}=t;const o={},i=e.ref([]),a=e.computed(()=>i.value.reduce((t,n)=>(t[n]=e.unref(o[n]),t),{}));r.__vuelidateInjectInstances=[].concat(r.__vuelidateInjectInstances||[],function(e,t){let{$registerAs:r,$scope:a,$stopPropagation:l}=t;l||n===AB.COLLECT_NONE||a===AB.COLLECT_NONE||n!==AB.COLLECT_ALL&&n!==a||(o[r]=e,i.value.push(r))}),r.__vuelidateRemoveInstances=[].concat(r.__vuelidateRemoveInstances||[],function(e){i.value=i.value.filter(t=>t!==e),delete o[e]});const l=e.inject(zB,[]);e.provide(zB,r.__vuelidateInjectInstances);const s=e.inject(OB,[]);return e.provide(OB,r.__vuelidateRemoveInstances),{childResults:a,sendValidationResultsToParent:l,removeValidationResultsFromParent:s}}({$scope:a,instance:d}):{childResults:e.ref({})};if(!t&&u.validations){const t=u.validations;n=e.ref({}),e.onBeforeMount(()=>{n.value=d,e.watch(()=>_B(t)?t.call(n.value,new IB(n.value)):t,e=>{p.value=TB({validations:e,state:n,childResults:m,resultsCache:h,globalConfig:o,instance:d,externalResults:s||d.vuelidateExternalResults})},{immediate:!0})}),o=u.validationsConfig||o}else{const r=e.isRef(t)||function(t){return e.isReactive(t)||e.isReadonly(t)}(t)?t:e.reactive(t||{});e.watch(r,e=>{p.value=TB({validations:e,state:n,childResults:m,resultsCache:h,globalConfig:o,instance:null!=d?d:{},externalResults:s})},{immediate:!0})}return d&&(f.forEach(e=>e(p,{$registerAs:i,$scope:a,$stopPropagation:l})),e.onBeforeUnmount(()=>g.forEach(e=>e(i)))),e.computed(()=>wB(wB({},e.unref(p.value)),m.value))}function $B(){const{$t:t}=HB(),n=e.computed(()=>({DAY:{literal:{singular:t({defaultMessage:"day",id:"time_period.day.singular",description:"The singular form of the day time period"}),plural:t({defaultMessage:"days",id:"time_period.day.plural",description:"The plural form of the day time period"})},full:t({defaultMessage:"daily",id:"time_period.day.full",description:"The full form of the day time period"})},WEEK:{literal:{singular:t({defaultMessage:"week",id:"time_period.week.singular",description:"The singular form of the week time period"}),plural:t({defaultMessage:"weeks",id:"time_period.week.plural",description:"The plural form of the week time period"})},full:t({defaultMessage:"weekly",id:"time_period.week.full",description:"The full form of the week time period"})},MONTH:{literal:{singular:t({defaultMessage:"month",id:"time_period.month.singular",description:"The singular form of the month time period"}),plural:t({defaultMessage:"months",id:"time_period.month.plural",description:"The plural form of the month time period"})},full:t({defaultMessage:"monthly",id:"time_period.month.full",description:"The full form of the month time period"})},YEAR:{literal:{singular:t({defaultMessage:"year",id:"time_period.year.singular",description:"The singular form of the year time period"}),plural:t({defaultMessage:"years",id:"time_period.year.plural",description:"The plural form of the year time period"})},full:t({defaultMessage:"yearly",id:"time_period.year.full",description:"The full form of the year time period"})}}));return{map:n,formatTimePeriod:(e,t={short:!1,hideValueForExactPeriods:!1,singular:!1})=>{const r=e.value??1,o=n.value[e.type].literal[t.singular||1===+r?"singular":"plural"].toLowerCase();return`${t.prefix&&!t.short?`${t.prefix} `:""}${t.hideValueForExactPeriods&&1===r?o:`${r} ${o}`}`},formatTimePeriodLiteral:(e,t={singular:!1})=>n.value[e].literal[t.singular?"singular":"plural"]}}function LB({currency:e,billingPeriod:t}={}){const{$t:n}=HB(),{formatTimePeriod:r}=$B();return{renderPricingForPricingItem:({pricingItem:o})=>{var i,a,l,s,c,d,u,p,h,m,f;const g=null==(i=o.product_items)?void 0:i[0],v=function({pricingItem:e,currency:t,billingPeriod:n}){var r,o,i,a,l,s;if(null==(r=e.pricing_currency_configs)?void 0:r.length){const r=dB(e.pricing_currency_configs,t);if((null==(o=null==r?void 0:r.billing_period_configs)?void 0:o.length)&&n){const e=pB(r.billing_period_configs,n);if(e)return e}if(r){const t=r.fallback_currency;if(t){const n=uB(e.pricing_currency_configs,t);if(n)return n}if(null==(i=r.configs)?void 0:i.length)return r.configs[0]}}if(null==(a=e.billing_period_configs)?void 0:a.length){const t=pB(e.billing_period_configs,n);if(t)return t}if(null==(l=e.configs)?void 0:l.length)return null==(s=e.configs)?void 0:s[0]}({pricingItem:o,currency:null==e?void 0:e.value,billingPeriod:null==t?void 0:t.value});return v?"PER_SEAT"===(null==g?void 0:g.model_type)?n({defaultMessage:"Per seat",id:"pricing_item_pricing.per_seat",description:"The pricing item pricing for a per seat pricing item"}):"ONE_OFF"===(null==g?void 0:g.model_type)&&(null==(l=null==(a=v.bands)?void 0:a[0])?void 0:l.fixed_amount)?Bx(null==(c=null==(s=v.bands)?void 0:s[0])?void 0:c.fixed_amount):"FLAT"===v.type&&(null==(u=null==(d=v.bands)?void 0:d[0])?void 0:u.amount)?n({defaultMessage:"{pricing} per {billing_period}",id:"pricing_item_pricing",description:"The pricing item pricing"},{pricing:Bx(v.bands[0].amount),billing_period:r((null==v?void 0:v.billing_period)??{type:"MONTH",value:1},{short:!0,hideValueForExactPeriods:!0})}):"FIXED"===v.type&&(null==(h=null==(p=v.bands)?void 0:p[0])?void 0:h.fixed_amount)?n({defaultMessage:"{pricing} per {billing_period}",id:"pricing_item_pricing",description:"The pricing item pricing"},{pricing:Bx(null==(f=null==(m=v.bands)?void 0:m[0])?void 0:f.fixed_amount),billing_period:r((null==v?void 0:v.billing_period)??{type:"MONTH",value:1},{short:!0,hideValueForExactPeriods:!0})}):"TIERED"===v.type?n({defaultMessage:"Tiered pricing",id:"pricing_item_pricing.tiered",description:"The pricing item pricing for a tiered pricing item"}):"TOP_TIERED"===v.type?n({defaultMessage:"Top tiered pricing",id:"pricing_item_pricing.top_tiered",description:"The pricing item pricing for a top tiered pricing item"}):"STAIR_STEP"===v.type?n({defaultMessage:"Stair step pricing",id:"pricing_item_pricing.stair_step",description:"The pricing item pricing for a stair step pricing item"}):"PASS_THROUGH"===v.type?n({defaultMessage:"Pass through pricing",id:"pricing_item_pricing.pass_through",description:"The pricing item pricing for a pass through pricing item"}):"NONE"===v.type?n({defaultMessage:"Not billed",id:"pricing_item_pricing.none",description:"The pricing item pricing for a not billed pricing item"}):"FLAT_TOP_UP"===v.type?n({defaultMessage:"Flat top up pricing",id:"pricing_item_pricing.flat_top_up",description:"The pricing item pricing for a flat top up pricing item"}):"TIERED_TOP_UP"===v.type?n({defaultMessage:"Tiered top up pricing",id:"pricing_item_pricing.tiered_top_up",description:"The pricing item pricing for a tiered top up pricing item"}):n({defaultMessage:"Unsupported pricing",id:"pricing_item_pricing.unsupported_pricing_error",description:"Text displayed when the pricing item pricing is unsupported"}):n({defaultMessage:"Unsupported pricing",id:"pricing_item_pricing.unsupported_pricing_error",description:"Text displayed when the pricing item pricing is unsupported"})}}}const RB=e.defineComponent({__name:"IntlProvider",props:{locale:{},dateLocale:{},messages:{},showTimezones:{type:Boolean,default:!0}},setup(t){const n=t;return e.provide(mx,(({locale:t,dateLocale:n,messages:r})=>{const{onError:o}=Dt(),i=e.computed(()=>t.value||"en-US"),a=e.computed(()=>n.value||i.value),l=e.computed(()=>({...hx,...r.value})),s=Ot({locale:i.value,messages:l.value},vx);e.watch(i,e=>{s.locale=e}),e.watch(l,e=>{s.messages=e});const c=({id:e,defaultMessage:t,description:n},r)=>s.formatMessage({id:e,defaultMessage:t,description:n},r),d=e=>{const t={year:"numeric",month:"2-digit",day:"2-digit",timeZone:e.timezone&&Pt(e.timezone)},n=gx(a.value)?{...t,month:"short",day:"numeric"}:t,r=gx(a.value)?{...fx,hour12:!0}:fx;try{switch(e.format){case"date":return new Intl.DateTimeFormat(a.value,n).format(new Date(e.date));case"dateTime":return new Intl.DateTimeFormat(a.value,{...n,...r}).format(new Date(e.date))}}catch(i){return null==o||o(new Error("Failed to format date",{cause:i})),d({...e,timezone:void 0,offsetType:"local",format:"dateTime"})}};return{...s,$t:c,formatMessage:c,formatDate:d}})({locale:e.computed(()=>n.locale),dateLocale:e.computed(()=>n.dateLocale),messages:e.computed(()=>n.messages)})),(t,n)=>e.renderSlot(t.$slots,"default")}}),HB=()=>{const t=e.inject(mx);if(!t)throw new Error("IntlProvider is not provided");return t},FB=e.defineComponent({__name:"ErrorHandlingProvider",props:{onError:{type:Function}},setup(t){const n=t;return e.provide(It,n),(t,n)=>e.renderSlot(t.$slots,"default")}}),jB="py-2 px-4 text-sm",UB={danger:"text-red-700",dark:"text-gray-700",info:"text-blue-700",success:"text-green-700",warning:"text-yellow-700"},GB={danger:"bg-red-100",dark:"bg-gray-100",info:"bg-blue-100",success:"bg-green-100",warning:"bg-yellow-100"},qB={danger:"border-t-4 border-red-500",dark:"border-t-4 border-gray-500",info:"border-t-4 border-blue-500",success:"border-t-4 border-green-500",warning:"border-t-4 border-yellow-500"},ZB="ml-auto -mx-1.5 -my-1.5 rounded focus:ring-2 p-1.5 inline-flex h-8 w-8",WB={danger:"hover:bg-red-200 focus:ring-red-400 bg-red-100 text-red-500",dark:"hover:bg-gray-200 focus:ring-gray-400 bg-gray-100 text-gray-500",info:"hover:bg-blue-200 focus:ring-blue-400 bg-blue-100 text-blue-500",success:"bg-green-100 text-green-500 focus:ring-green-400 hover:bg-green-200",warning:"focus:ring-yellow-400 hover:bg-yellow-200 bg-yellow-100 text-yellow-500"};const KB={key:0,class:"ml-auto inline-flex items-center"},JB=e.defineComponent({__name:"Alert",props:{type:{default:"info"},title:{default:""},closable:{type:Boolean,default:!1},icon:{type:Boolean,default:!0},border:{type:Boolean,default:!1},inline:{type:Boolean,default:!0}},setup(t){const n=t,{alertClasses:r,textClasses:o,closeClasses:i,contentClasses:a,titleClasses:l}=function(t){const n=e.computed(()=>[jB,GB[t.type.value],r.value,t.border.value?qB[t.type.value]:"rounded",t.inline.value?"flex items-center":""].filter(e=>!!e).join(" ")),r=e.computed(()=>UB[t.type.value]??""),o=e.computed(()=>[ZB,WB[t.type.value]??""].filter(e=>!!e).join(" ")),i=e.computed(()=>t.inline.value?t.icon.value||t.title.value?t.title.value?"grow ml-1":"grow ml-2":"":"my-2"),a=e.computed(()=>t.icon.value&&t.inline.value?["font-medium ml-2",t.inline.value?"":"text-lg"].filter(e=>!!e).join(" "):["font-medium",t.inline.value?"":"text-lg ml-2"].filter(e=>!!e).join(" "));return{alertClasses:n,textClasses:r,closeClasses:o,contentClasses:i,titleClasses:a}}(e.toRefs(n)),s=e.ref(!0),c=()=>{s.value=!1};return(n,d)=>s.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(e.unref(r)),role:"alert"},[e.createElementVNode("div",{class:e.normalizeClass(t.inline?"flex":"flex items-center")},[t.icon?(e.openBlock(),e.createElementBlock("svg",{key:0,class:e.normalizeClass(["flex-shrink-0","w-5","h-5",e.unref(o)]),fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},[...d[0]||(d[0]=[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a1 1 0 000 2v3a1 1 0 001 1h1a1 1 0 100-2v-3a1 1 0 00-1-1H9z","clip-rule":"evenodd"},null,-1)])],2)):e.createCommentVNode("",!0),t.title?(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass(e.unref(l))},e.toDisplayString(t.title),3)):e.createCommentVNode("",!0),!t.inline&&t.closable?(e.openBlock(),e.createElementBlock("button",{key:2,type:"button",class:e.normalizeClass(e.unref(i)),"aria-label":"Close",onClick:c},[...d[1]||(d[1]=[e.createElementVNode("span",{class:"sr-only"},"Dismiss",-1),e.createElementVNode("svg",{class:"w-5 h-5",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z","clip-rule":"evenodd"})],-1)])],2)):e.createCommentVNode("",!0)],2),e.createElementVNode("div",{class:e.normalizeClass(e.unref(a))},[e.renderSlot(n.$slots,"default")],2),n.$slots.actions?(e.openBlock(),e.createElementBlock("div",KB,[e.renderSlot(n.$slots,"actions")])):e.createCommentVNode("",!0),t.inline&&t.closable?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:e.normalizeClass(e.unref(i)),"aria-label":"Close",onClick:c},[...d[2]||(d[2]=[e.createElementVNode("span",{class:"sr-only"},"Dismiss",-1),e.createElementVNode("svg",{class:"w-5 h-5",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z","clip-rule":"evenodd"})],-1)])],2)):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0)}}),YB=e.defineComponent({__name:"Amount",props:{value:{},highlighted:{type:Boolean,default:!1}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("span",e.mergeProps(n.$attrs,{class:[{"text-primary-600 font-semibold":t.highlighted},"inline-block"]}),e.toDisplayString(e.unref(Bx)(t.value)),17))}),XB=e.defineComponent({__name:"Avatar",props:{initials:{},imageSrc:{},size:{default:"md"},round:{type:Boolean,default:!1},variant:{default:"light"},colorHash:{},font:{default:"icon"}},setup(t){const n=t,r={xs:"w-4 h-4",sm:"w-5 h-5",md:"w-6 h-6",lg:"w-8 h-8",xl:"w-12 h-12"},o={xs:"text-base",sm:"text-lg",md:"text-2xl",lg:"text-4xl",xl:"text-6xl"},i=(t=>{const n=e.ref();return e.watch(()=>t,()=>{n.value=(e=>{let t=0;for(let r=0;r<e.length;r++)t=e.charCodeAt(r)+((t<<5)-t);let n="#";for(let r=0;r<3;r++)n+=("00"+(t>>8*r&255).toString(16)).substr(-2);return n})(t)},{immediate:!0}),n})(n.colorHash??n.initials??"A"),a=e.computed(()=>({backgroundImage:n.imageSrc?`url(${n.imageSrc})`:`linear-gradient(140deg, ${i.value}60 0%, #DCF3FD 75%)`}));return(i,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["flex shrink-0 justify-center items-center rounded overflow-hidden bg-cover bg-primary-100",{[r[n.size]]:!0,"rounded-full":t.round,"border border-black border-opacity-5":"dark"===t.variant}]),style:e.normalizeStyle(a.value)},[t.initials&&!t.imageSrc?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(["font-semibold font-regular text-2xl",{[o[n.size]]:!0,"font-regular":"icon"===t.font,"font-inter drop-shadow-sm":"regular"===t.font,"text-white/70":"light"===t.variant,"text-black/10":"dark"===t.variant}])},e.toDisplayString(t.initials.toUpperCase()),3)):e.createCommentVNode("",!0)],6))}}),QB={type:"button",color:"primary",variant:"primary",size:"md",pill:!1,square:!1,loading:!1,disabled:!1,iconPrefix:void 0,iconSuffix:void 0,tag:"button"},eN="transition-colors transition-opacity",tN={blue:"text-white bg-blue-600 focus:ring-4 focus:ring-blue-300 font-medium rounded focus:outline-none",red:"text-white bg-red-700 focus:ring-4 focus:ring-red-300 font-medium rounded focus:outline-none",green:"text-white bg-green-700 focus:ring-4 focus:ring-green-300 font-medium rounded focus:outline-none",gray:"text-white bg-gray-800 focus:ring-4 focus:ring-gray-300 font-medium rounded focus:outline-none",primary:"text-white bg-primary-600 focus:ring-4 focus:ring-primary-300 font-medium rounded focus:outline-non",yellow:"text-white bg-yellow-800 focus:ring-4 focus:ring-yellow-300 font-medium rounded focus:outline-none"},nN={blue:"hover:bg-blue-700",red:"hover:bg-red-800",green:"hover:bg-green-800",gray:"hover:bg-gray-50",primary:"hover:bg-primary-700",yellow:"hover:bg-yellow-700"},rN={blue:"text-blue-600 bg-white border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center",red:"text-red-700 bg-white border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center",green:"text-green-700 bg-white border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center",gray:"text-gray-800 bg-white border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center",primary:"text-primary-600 bg-white border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center",yellow:"text-yellow-600 bg-white border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center"},oN={blue:"text-blue-600 hover:bg-gray-50 border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center",red:"text-red-700 hover:bg-gray-50 border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center",green:"text-green-700 hover:bg-gray-50 border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center",gray:"text-gray-800 hover:bg-gray-50 border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center",primary:"text-primary-600 hover:bg-gray-50 border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center",yellow:"text-yellow-600 hover:bg-gray-50 border border-gray-200 focus:ring-4 focus:outline-none focus:ring-gray-50 font-medium rounded text-sm text-center"},iN={blue:"text-blue-600 bg-none border-none focus:ring-4 focus:outline-none focus:ring-gray-300 font-medium rounded text-sm text-center",red:"text-red-700 bg-none border-none focus:ring-4 focus:outline-none focus:ring-gray-300 font-medium rounded text-sm text-center",green:"text-green-700 bg-none border-none focus:ring-4 focus:outline-none focus:ring-gray-300 font-medium rounded text-sm text-center",gray:"text-gray-800 bg-none border-none focus:ring-4 focus:outline-none focus:ring-gray-300 font-medium rounded text-sm text-center",primary:"text-primary-600 bg-none border-none focus:ring-4 focus:outline-none focus:ring-gray-300 font-medium rounded text-sm text-center",yellow:"text-yellow-700 bg-none border-none focus:ring-4 focus:outline-none focus:ring-gray-300 font-medium rounded text-sm text-center"},aN={blue:"hover:text-white hover:bg-blue-700",red:"hover:text-white hover:bg-red-800",green:"hover:text-white hover:bg-green-800",gray:"hover:bg-gray-50",primary:"hover:text-white hover:bg-primary-700",yellow:"hover:text-white hover:bg-yellow-700"},lN={xs:"p-0.5",sm:"p-1.5",md:"p-2",lg:"p-3"},sN={xs:"w-5 h-5",sm:"w-8 h-8",md:"w-10 h-10",lg:"w-12 h-12"};function cN(t){const n=e.useSlots(),r=e.computed(()=>{var e;return(null==(e=t.square)?void 0:e.value)?sN[t.size.value]:lN[t.size.value]}),o=e.computed(()=>{const e=t.color.value||QB.color,o=t.variant.value||QB.variant,i=t.loading.value,a=t.disabled.value;let l={},s={};switch(o){case"ghost":s=iN,l=aN;break;case"transparent":s=iN;break;case"outline":s=rN,l=oN;break;default:s=tN,l=nN}const c=s[e],d=i||a?"":l[e];return[eN,c,d,r.value,t.pill.value?"!rounded-full":"",t.disabled.value||t.loading.value?"cursor-not-allowed opacity-50":"",n.prefix||t.iconPrefix||n.suffix||t.loading.value?"inline-flex items-center":""].filter(e=>!!e).join(" ")}),i=e.computed(()=>t.loading.value?"opacity-0":"");return{contentClasses:e.computed(()=>{switch(t.size.value){case"xs":case"sm":return"mx-1";case"md":return"mx-1.5";case"lg":return"mx-2";default:return""}}),wrapperClasses:o,spanClasses:i}}const dN={0:"w-0 h-0",.5:"w-0.5 h-0.5",1:"w-1 h-1",1.5:"w-1.5 h-1.5",10:"w-10 h-10",11:"w-11 h-11",12:"w-12 h-12",2:"w-2 h-2",2.5:"w-2.5 h-2.5",3:"w-3 h-3",4:"w-4 h-4",5:"w-5 h-5",6:"w-6 h-6",7:"w-7 h-7",8:"w-8 h-8",9:"w-9 h-9",px:"w-px h-px"},uN={primary:"fill-primary-600",blue:"fill-blue-600",gray:"fill-gray-600",green:"fill-green-500",pink:"fill-pink-600",purple:"fill-purple-600",red:"fill-red-600",yellow:"fill-yellow-400",white:"fill-white"};const pN=e.defineComponent({__name:"Spinner",props:{size:{default:"4"},color:{default:"primary"}},setup(t){const n=t,{spinnerClasses:r}=function(t){const n=e.computed(()=>dN[t.size.value]),r=e.computed(()=>uN[t.color.value]),o="text-gray-200",i="animate-spin";return{spinnerClasses:e.computed(()=>[n.value,o,r.value,i].join(" "))}}(e.toRefs(n));return(t,n)=>(e.openBlock(),e.createElementBlock("svg",{role:"status",class:e.normalizeClass(e.unref(r)),viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[...n[0]||(n[0]=[e.createElementVNode("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"},null,-1),e.createElementVNode("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"currentFill"},null,-1)])],2))}});const hN={key:0,class:"absolute bottom-0 left-0 right-0 top-0 flex items-center justify-center bg-inherit"},mN={key:0,class:"flex items-center justify-center"},fN={key:2,class:"flex items-center justify-center"},gN=e.defineComponent({__name:"Button",props:e.mergeDefaults({type:{},variant:{},color:{},size:{},pill:{type:Boolean},square:{type:Boolean},loading:{type:Boolean},disabled:{type:Boolean},iconPrefix:{},iconSuffix:{},tag:{}},QB),emits:["click"],setup(t,{emit:n}){const r=t,o=n,i=e.computed(()=>{switch(r.size){case"xs":return"2xs";case"sm":return"xs";default:return"sm"}}),a=e.computed(()=>"xs"===i.value?"4":"5"),l=e.computed(()=>["xs","sm"].includes(r.size)?"body-xs":"body-sm"),{wrapperClasses:s,spanClasses:c,contentClasses:d}=cN(e.toRefs(r)),{color:u}=function(t){const n={lg:"5",md:"4",sm:"3",xs:"2"};return{size:e.computed(()=>n[t.size.value]),color:e.computed(()=>"primary"===t.variant.value?"white":t.color.value)}}(e.toRefs(r)),{handleClick:p}=function(t=500){const n=e.ref(!1);return{isClicked:n,handleClick:function(e){if(!n.value){n.value=!0;try{e()}finally{setTimeout(()=>{n.value=!1},t)}}}}}(),h=e.computed(()=>"button"===r.tag&&(r.disabled||r.loading)),m=e=>{p(()=>{o("click",e)})};return(n,r)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.tag),{class:e.normalizeClass([e.unref(s),"relative shrink-0 items-center justify-center overflow-clip whitespace-nowrap"]),type:"button"===t.tag?t.type:void 0,disabled:h.value,onClick:m},{default:e.withCtx(()=>[t.loading?(e.openBlock(),e.createElementBlock("span",hN,[e.createVNode(e.unref(pN),{size:a.value,color:e.unref(u)},null,8,["size","color"])])):e.createCommentVNode("",!0),e.createElementVNode("span",{class:e.normalizeClass([e.unref(c),"flex items-center justify-center"])},[t.iconPrefix||n.$slots.prefix?(e.openBlock(),e.createElementBlock("span",mN,[e.renderSlot(n.$slots,"prefix",{},()=>[e.createVNode(e.unref(hc),{icon:t.iconPrefix,size:i.value,class:"overflow-clip"},null,8,["icon","size"])])])):e.createCommentVNode("",!0),n.$slots.default?(e.openBlock(),e.createBlock(e.unref(gc),{key:1,tag:"span",variant:l.value,class:e.normalizeClass(e.unref(d))},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},8,["variant","class"])):e.createCommentVNode("",!0),t.iconSuffix||n.$slots.suffix?(e.openBlock(),e.createElementBlock("span",fN,[e.renderSlot(n.$slots,"suffix",{},()=>[e.createVNode(e.unref(hc),{icon:t.iconSuffix,size:i.value},null,8,["icon","size"])])])):e.createCommentVNode("",!0)],2)]),_:3},8,["class","type","disabled"]))}});function vN(e){var t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=vN(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}const yN=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),bN="-",wN=[],kN=e=>{const t=CN(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{if(e.startsWith("[")&&e.endsWith("]"))return _N(e);const n=e.split(bN),r=""===n[0]&&n.length>1?1:0;return xN(n,r,t)},getConflictingClassGroupIds:(e,t)=>{if(t){const t=r[e],o=n[e];return t?o?((e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n})(o,t):t:o||wN}return n[e]||wN}}},xN=(e,t,n)=>{if(0===e.length-t)return n.classGroupId;const r=e[t],o=n.nextPart.get(r);if(o){const n=xN(e,t+1,o);if(n)return n}const i=n.validators;if(null===i)return;const a=0===t?e.join(bN):e.slice(t).join(bN),l=i.length;for(let s=0;s<l;s++){const e=i[s];if(e.validator(a))return e.classGroupId}},_N=e=>-1===e.slice(1,-1).indexOf(":")?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?"arbitrary.."+r:void 0})(),CN=e=>{const{theme:t,classGroups:n}=e;return EN(n,t)},EN=(e,t)=>{const n=yN();for(const r in e){const o=e[r];SN(o,n,r,t)}return n},SN=(e,t,n,r)=>{const o=e.length;for(let i=0;i<o;i++){const o=e[i];BN(o,t,n,r)}},BN=(e,t,n,r)=>{"string"!=typeof e?"function"!=typeof e?TN(e,t,n,r):MN(e,t,n,r):NN(e,t,n)},NN=(e,t,n)=>{(""===e?t:VN(t,e)).classGroupId=n},MN=(e,t,n,r)=>{AN(e)?SN(e(r),t,n,r):(null===t.validators&&(t.validators=[]),t.validators.push(((e,t)=>({classGroupId:e,validator:t}))(n,e)))},TN=(e,t,n,r)=>{const o=Object.entries(e),i=o.length;for(let a=0;a<i;a++){const[e,i]=o[a];SN(i,VN(t,e),n,r)}},VN=(e,t)=>{let n=e;const r=t.split(bN),o=r.length;for(let i=0;i<o;i++){const e=r[i];let t=n.nextPart.get(e);t||(t=yN(),n.nextPart.set(e,t)),n=t}return n},AN=e=>"isThemeGetter"in e&&!0===e.isThemeGetter,zN=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const o=(o,i)=>{n[o]=i,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(e){let t=n[e];return void 0!==t?t:void 0!==(t=r[e])?(o(e,t),t):void 0},set(e,t){e in n?n[e]=t:o(e,t)}}},ON=[],IN=(e,t,n,r,o)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:o}),DN=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=e=>{const t=[];let n,r=0,o=0,i=0;const a=e.length;for(let d=0;d<a;d++){const a=e[d];if(0===r&&0===o){if(":"===a){t.push(e.slice(i,d)),i=d+1;continue}if("/"===a){n=d;continue}}"["===a?r++:"]"===a?r--:"("===a?o++:")"===a&&o--}const l=0===t.length?e:e.slice(i);let s=l,c=!1;l.endsWith("!")?(s=l.slice(0,-1),c=!0):l.startsWith("!")&&(s=l.slice(1),c=!0);return IN(t,c,s,n&&n>i?n-i:void 0)};if(t){const e=t+":",n=r;r=t=>t.startsWith(e)?n(t.slice(e.length)):IN(ON,!1,t,void 0,!0)}if(n){const e=r;r=t=>n({className:t,parseClassName:e})}return r},PN=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((e,n)=>{t.set(e,1e6+n)}),e=>{const n=[];let r=[];for(let o=0;o<e.length;o++){const i=e[o],a="["===i[0],l=t.has(i);a||l?(r.length>0&&(r.sort(),n.push(...r),r=[]),n.push(i)):r.push(i)}return r.length>0&&(r.sort(),n.push(...r)),n}},$N=/\s+/,LN=e=>{if("string"==typeof e)return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=LN(e[r]))&&(n&&(n+=" "),n+=t);return n},RN=(e,...t)=>{let n,r,o,i;const a=e=>{const t=r(e);if(t)return t;const i=((e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o,sortModifiers:i}=t,a=[],l=e.trim().split($N);let s="";for(let c=l.length-1;c>=0;c-=1){const e=l[c],{isExternal:t,modifiers:d,hasImportantModifier:u,baseClassName:p,maybePostfixModifierPosition:h}=n(e);if(t){s=e+(s.length>0?" "+s:s);continue}let m=!!h,f=r(m?p.substring(0,h):p);if(!f){if(!m){s=e+(s.length>0?" "+s:s);continue}if(f=r(p),!f){s=e+(s.length>0?" "+s:s);continue}m=!1}const g=0===d.length?"":1===d.length?d[0]:i(d).join(":"),v=u?g+"!":g,y=v+f;if(a.indexOf(y)>-1)continue;a.push(y);const b=o(f,m);for(let n=0;n<b.length;++n){const e=b[n];a.push(v+e)}s=e+(s.length>0?" "+s:s)}return s})(e,n);return o(e,i),i};return i=l=>{const s=t.reduce((e,t)=>t(e),e());return n=(e=>({cache:zN(e.cacheSize),parseClassName:DN(e),sortModifiers:PN(e),...kN(e)}))(s),r=n.cache.get,o=n.cache.set,i=a,a(l)},(...e)=>i(((...e)=>{let t,n,r=0,o="";for(;r<e.length;)(t=e[r++])&&(n=LN(t))&&(o&&(o+=" "),o+=n);return o})(...e))},HN=[],FN=e=>{const t=t=>t[e]||HN;return t.isThemeGetter=!0,t},jN=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,UN=/^\((?:(\w[\w-]*):)?(.+)\)$/i,GN=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,qN=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,ZN=/\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$/,WN=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,KN=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,JN=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,YN=e=>GN.test(e),XN=e=>!!e&&!Number.isNaN(Number(e)),QN=e=>!!e&&Number.isInteger(Number(e)),eM=e=>e.endsWith("%")&&XN(e.slice(0,-1)),tM=e=>qN.test(e),nM=()=>!0,rM=e=>ZN.test(e)&&!WN.test(e),oM=()=>!1,iM=e=>KN.test(e),aM=e=>JN.test(e),lM=e=>!cM(e)&&!vM(e),sM=e=>EM(e,MM,oM),cM=e=>jN.test(e),dM=e=>EM(e,TM,rM),uM=e=>EM(e,VM,XN),pM=e=>EM(e,zM,nM),hM=e=>EM(e,AM,oM),mM=e=>EM(e,BM,oM),fM=e=>EM(e,NM,aM),gM=e=>EM(e,OM,iM),vM=e=>UN.test(e),yM=e=>SM(e,TM),bM=e=>SM(e,AM),wM=e=>SM(e,BM),kM=e=>SM(e,MM),xM=e=>SM(e,NM),_M=e=>SM(e,OM,!0),CM=e=>SM(e,zM,!0),EM=(e,t,n)=>{const r=jN.exec(e);return!!r&&(r[1]?t(r[1]):n(r[2]))},SM=(e,t,n=!1)=>{const r=UN.exec(e);return!!r&&(r[1]?t(r[1]):n)},BM=e=>"position"===e||"percentage"===e,NM=e=>"image"===e||"url"===e,MM=e=>"length"===e||"size"===e||"bg-size"===e,TM=e=>"length"===e,VM=e=>"number"===e,AM=e=>"family-name"===e,zM=e=>"number"===e||"weight"===e,OM=e=>"shadow"===e,IM=RN(()=>{const e=FN("color"),t=FN("font"),n=FN("text"),r=FN("font-weight"),o=FN("tracking"),i=FN("leading"),a=FN("breakpoint"),l=FN("container"),s=FN("spacing"),c=FN("radius"),d=FN("shadow"),u=FN("inset-shadow"),p=FN("text-shadow"),h=FN("drop-shadow"),m=FN("blur"),f=FN("perspective"),g=FN("aspect"),v=FN("ease"),y=FN("animate"),b=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom",vM,cM],w=()=>[vM,cM,s],k=()=>[YN,"full","auto",...w()],x=()=>[QN,"none","subgrid",vM,cM],_=()=>["auto",{span:["full",QN,vM,cM]},QN,vM,cM],C=()=>[QN,"auto",vM,cM],E=()=>["auto","min","max","fr",vM,cM],S=()=>["auto",...w()],B=()=>[YN,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...w()],N=()=>[YN,"screen","full","dvw","lvw","svw","min","max","fit",...w()],M=()=>[YN,"screen","full","lh","dvh","lvh","svh","min","max","fit",...w()],T=()=>[e,vM,cM],V=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom",wM,mM,{position:[vM,cM]}],A=()=>["auto","cover","contain",kM,sM,{size:[vM,cM]}],z=()=>[eM,yM,dM],O=()=>["","none","full",c,vM,cM],I=()=>["",XN,yM,dM],D=()=>[XN,eM,wM,mM],P=()=>["","none",m,vM,cM],$=()=>["none",XN,vM,cM],L=()=>["none",XN,vM,cM],R=()=>[XN,vM,cM],H=()=>[YN,"full",...w()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[tM],breakpoint:[tM],color:[nM],container:[tM],"drop-shadow":[tM],ease:["in","out","in-out"],font:[lM],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[tM],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[tM],shadow:[tM],spacing:["px",XN],text:[tM],"text-shadow":[tM],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",YN,cM,vM,g]}],container:["container"],columns:[{columns:[XN,cM,vM,l]}],"break-after":[{"break-after":["auto","avoid","all","avoid-page","page","left","right","column"]}],"break-before":[{"break-before":["auto","avoid","all","avoid-page","page","left","right","column"]}],"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"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:b()}],overflow:[{overflow:["auto","hidden","clip","visible","scroll"]}],"overflow-x":[{"overflow-x":["auto","hidden","clip","visible","scroll"]}],"overflow-y":[{"overflow-y":["auto","hidden","clip","visible","scroll"]}],overscroll:[{overscroll:["auto","contain","none"]}],"overscroll-x":[{"overscroll-x":["auto","contain","none"]}],"overscroll-y":[{"overscroll-y":["auto","contain","none"]}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:k()}],"inset-x":[{"inset-x":k()}],"inset-y":[{"inset-y":k()}],start:[{"inset-s":k(),start:k()}],end:[{"inset-e":k(),end:k()}],"inset-bs":[{"inset-bs":k()}],"inset-be":[{"inset-be":k()}],top:[{top:k()}],right:[{right:k()}],bottom:[{bottom:k()}],left:[{left:k()}],visibility:["visible","invisible","collapse"],z:[{z:[QN,"auto",vM,cM]}],basis:[{basis:[YN,"full","auto",l,...w()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[XN,YN,"auto","initial","none",cM]}],grow:[{grow:["",XN,vM,cM]}],shrink:[{shrink:["",XN,vM,cM]}],order:[{order:[QN,"first","last","none",vM,cM]}],"grid-cols":[{"grid-cols":x()}],"col-start-end":[{col:_()}],"col-start":[{"col-start":C()}],"col-end":[{"col-end":C()}],"grid-rows":[{"grid-rows":x()}],"row-start-end":[{row:_()}],"row-start":[{"row-start":C()}],"row-end":[{"row-end":C()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":E()}],"auto-rows":[{"auto-rows":E()}],gap:[{gap:w()}],"gap-x":[{"gap-x":w()}],"gap-y":[{"gap-y":w()}],"justify-content":[{justify:["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe","normal"]}],"justify-items":[{"justify-items":["start","end","center","stretch","center-safe","end-safe","normal"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch","center-safe","end-safe"]}],"align-content":[{content:["normal","start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"]}],"align-items":[{items:["start","end","center","stretch","center-safe","end-safe",{baseline:["","last"]}]}],"align-self":[{self:["auto","start","end","center","stretch","center-safe","end-safe",{baseline:["","last"]}]}],"place-content":[{"place-content":["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"]}],"place-items":[{"place-items":["start","end","center","stretch","center-safe","end-safe","baseline"]}],"place-self":[{"place-self":["auto","start","end","center","stretch","center-safe","end-safe"]}],p:[{p:w()}],px:[{px:w()}],py:[{py:w()}],ps:[{ps:w()}],pe:[{pe:w()}],pbs:[{pbs:w()}],pbe:[{pbe:w()}],pt:[{pt:w()}],pr:[{pr:w()}],pb:[{pb:w()}],pl:[{pl:w()}],m:[{m:S()}],mx:[{mx:S()}],my:[{my:S()}],ms:[{ms:S()}],me:[{me:S()}],mbs:[{mbs:S()}],mbe:[{mbe:S()}],mt:[{mt:S()}],mr:[{mr:S()}],mb:[{mb:S()}],ml:[{ml:S()}],"space-x":[{"space-x":w()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":w()}],"space-y-reverse":["space-y-reverse"],size:[{size:B()}],"inline-size":[{inline:["auto",...N()]}],"min-inline-size":[{"min-inline":["auto",...N()]}],"max-inline-size":[{"max-inline":["none",...N()]}],"block-size":[{block:["auto",...M()]}],"min-block-size":[{"min-block":["auto",...M()]}],"max-block-size":[{"max-block":["none",...M()]}],w:[{w:[l,"screen",...B()]}],"min-w":[{"min-w":[l,"screen","none",...B()]}],"max-w":[{"max-w":[l,"screen","none","prose",{screen:[a]},...B()]}],h:[{h:["screen","lh",...B()]}],"min-h":[{"min-h":["screen","lh","none",...B()]}],"max-h":[{"max-h":["screen","lh",...B()]}],"font-size":[{text:["base",n,yM,dM]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,CM,pM]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",eM,cM]}],"font-family":[{font:[bM,hM,t]}],"font-features":[{"font-features":[cM]}],"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-fractions"],tracking:[{tracking:[o,vM,cM]}],"line-clamp":[{"line-clamp":[XN,"none",vM,uM]}],leading:[{leading:[i,...w()]}],"list-image":[{"list-image":["none",vM,cM]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",vM,cM]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:T()}],"text-color":[{text:T()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:["solid","dashed","dotted","double","wavy"]}],"text-decoration-thickness":[{decoration:[XN,"from-font","auto",vM,dM]}],"text-decoration-color":[{decoration:T()}],"underline-offset":[{"underline-offset":[XN,"auto",vM,cM]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:w()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",vM,cM]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",vM,cM]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:V()}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","space","round"]}]}],"bg-size":[{bg:A()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},QN,vM,cM],radial:["",vM,cM],conic:[QN,vM,cM]},xM,fM]}],"bg-color":[{bg:T()}],"gradient-from-pos":[{from:z()}],"gradient-via-pos":[{via:z()}],"gradient-to-pos":[{to:z()}],"gradient-from":[{from:T()}],"gradient-via":[{via:T()}],"gradient-to":[{to:T()}],rounded:[{rounded:O()}],"rounded-s":[{"rounded-s":O()}],"rounded-e":[{"rounded-e":O()}],"rounded-t":[{"rounded-t":O()}],"rounded-r":[{"rounded-r":O()}],"rounded-b":[{"rounded-b":O()}],"rounded-l":[{"rounded-l":O()}],"rounded-ss":[{"rounded-ss":O()}],"rounded-se":[{"rounded-se":O()}],"rounded-ee":[{"rounded-ee":O()}],"rounded-es":[{"rounded-es":O()}],"rounded-tl":[{"rounded-tl":O()}],"rounded-tr":[{"rounded-tr":O()}],"rounded-br":[{"rounded-br":O()}],"rounded-bl":[{"rounded-bl":O()}],"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-bs":[{"border-bs":I()}],"border-w-be":[{"border-be":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()}],"divide-x":[{"divide-x":I()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":I()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:["solid","dashed","dotted","double","hidden","none"]}],"divide-style":[{divide:["solid","dashed","dotted","double","hidden","none"]}],"border-color":[{border:T()}],"border-color-x":[{"border-x":T()}],"border-color-y":[{"border-y":T()}],"border-color-s":[{"border-s":T()}],"border-color-e":[{"border-e":T()}],"border-color-bs":[{"border-bs":T()}],"border-color-be":[{"border-be":T()}],"border-color-t":[{"border-t":T()}],"border-color-r":[{"border-r":T()}],"border-color-b":[{"border-b":T()}],"border-color-l":[{"border-l":T()}],"divide-color":[{divide:T()}],"outline-style":[{outline:["solid","dashed","dotted","double","none","hidden"]}],"outline-offset":[{"outline-offset":[XN,vM,cM]}],"outline-w":[{outline:["",XN,yM,dM]}],"outline-color":[{outline:T()}],shadow:[{shadow:["","none",d,_M,gM]}],"shadow-color":[{shadow:T()}],"inset-shadow":[{"inset-shadow":["none",u,_M,gM]}],"inset-shadow-color":[{"inset-shadow":T()}],"ring-w":[{ring:I()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:T()}],"ring-offset-w":[{"ring-offset":[XN,dM]}],"ring-offset-color":[{"ring-offset":T()}],"inset-ring-w":[{"inset-ring":I()}],"inset-ring-color":[{"inset-ring":T()}],"text-shadow":[{"text-shadow":["none",p,_M,gM]}],"text-shadow-color":[{"text-shadow":T()}],opacity:[{opacity:[XN,vM,cM]}],"mix-blend":[{"mix-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"]}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[XN]}],"mask-image-linear-from-pos":[{"mask-linear-from":D()}],"mask-image-linear-to-pos":[{"mask-linear-to":D()}],"mask-image-linear-from-color":[{"mask-linear-from":T()}],"mask-image-linear-to-color":[{"mask-linear-to":T()}],"mask-image-t-from-pos":[{"mask-t-from":D()}],"mask-image-t-to-pos":[{"mask-t-to":D()}],"mask-image-t-from-color":[{"mask-t-from":T()}],"mask-image-t-to-color":[{"mask-t-to":T()}],"mask-image-r-from-pos":[{"mask-r-from":D()}],"mask-image-r-to-pos":[{"mask-r-to":D()}],"mask-image-r-from-color":[{"mask-r-from":T()}],"mask-image-r-to-color":[{"mask-r-to":T()}],"mask-image-b-from-pos":[{"mask-b-from":D()}],"mask-image-b-to-pos":[{"mask-b-to":D()}],"mask-image-b-from-color":[{"mask-b-from":T()}],"mask-image-b-to-color":[{"mask-b-to":T()}],"mask-image-l-from-pos":[{"mask-l-from":D()}],"mask-image-l-to-pos":[{"mask-l-to":D()}],"mask-image-l-from-color":[{"mask-l-from":T()}],"mask-image-l-to-color":[{"mask-l-to":T()}],"mask-image-x-from-pos":[{"mask-x-from":D()}],"mask-image-x-to-pos":[{"mask-x-to":D()}],"mask-image-x-from-color":[{"mask-x-from":T()}],"mask-image-x-to-color":[{"mask-x-to":T()}],"mask-image-y-from-pos":[{"mask-y-from":D()}],"mask-image-y-to-pos":[{"mask-y-to":D()}],"mask-image-y-from-color":[{"mask-y-from":T()}],"mask-image-y-to-color":[{"mask-y-to":T()}],"mask-image-radial":[{"mask-radial":[vM,cM]}],"mask-image-radial-from-pos":[{"mask-radial-from":D()}],"mask-image-radial-to-pos":[{"mask-radial-to":D()}],"mask-image-radial-from-color":[{"mask-radial-from":T()}],"mask-image-radial-to-color":[{"mask-radial-to":T()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"]}],"mask-image-conic-pos":[{"mask-conic":[XN]}],"mask-image-conic-from-pos":[{"mask-conic-from":D()}],"mask-image-conic-to-pos":[{"mask-conic-to":D()}],"mask-image-conic-from-color":[{"mask-conic-from":T()}],"mask-image-conic-to-color":[{"mask-conic-to":T()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:V()}],"mask-repeat":[{mask:["no-repeat",{repeat:["","x","y","space","round"]}]}],"mask-size":[{mask:A()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",vM,cM]}],filter:[{filter:["","none",vM,cM]}],blur:[{blur:P()}],brightness:[{brightness:[XN,vM,cM]}],contrast:[{contrast:[XN,vM,cM]}],"drop-shadow":[{"drop-shadow":["","none",h,_M,gM]}],"drop-shadow-color":[{"drop-shadow":T()}],grayscale:[{grayscale:["",XN,vM,cM]}],"hue-rotate":[{"hue-rotate":[XN,vM,cM]}],invert:[{invert:["",XN,vM,cM]}],saturate:[{saturate:[XN,vM,cM]}],sepia:[{sepia:["",XN,vM,cM]}],"backdrop-filter":[{"backdrop-filter":["","none",vM,cM]}],"backdrop-blur":[{"backdrop-blur":P()}],"backdrop-brightness":[{"backdrop-brightness":[XN,vM,cM]}],"backdrop-contrast":[{"backdrop-contrast":[XN,vM,cM]}],"backdrop-grayscale":[{"backdrop-grayscale":["",XN,vM,cM]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[XN,vM,cM]}],"backdrop-invert":[{"backdrop-invert":["",XN,vM,cM]}],"backdrop-opacity":[{"backdrop-opacity":[XN,vM,cM]}],"backdrop-saturate":[{"backdrop-saturate":[XN,vM,cM]}],"backdrop-sepia":[{"backdrop-sepia":["",XN,vM,cM]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":w()}],"border-spacing-x":[{"border-spacing-x":w()}],"border-spacing-y":[{"border-spacing-y":w()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",vM,cM]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[XN,"initial",vM,cM]}],ease:[{ease:["linear","initial",v,vM,cM]}],delay:[{delay:[XN,vM,cM]}],animate:[{animate:["none",y,vM,cM]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[f,vM,cM]}],"perspective-origin":[{"perspective-origin":b()}],rotate:[{rotate:$()}],"rotate-x":[{"rotate-x":$()}],"rotate-y":[{"rotate-y":$()}],"rotate-z":[{"rotate-z":$()}],scale:[{scale:L()}],"scale-x":[{"scale-x":L()}],"scale-y":[{"scale-y":L()}],"scale-z":[{"scale-z":L()}],"scale-3d":["scale-3d"],skew:[{skew:R()}],"skew-x":[{"skew-x":R()}],"skew-y":[{"skew-y":R()}],transform:[{transform:[vM,cM,"","none","gpu","cpu"]}],"transform-origin":[{origin:b()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:H()}],"translate-x":[{"translate-x":H()}],"translate-y":[{"translate-y":H()}],"translate-z":[{"translate-z":H()}],"translate-none":["translate-none"],accent:[{accent:T()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:T()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],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",vM,cM]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":w()}],"scroll-mx":[{"scroll-mx":w()}],"scroll-my":[{"scroll-my":w()}],"scroll-ms":[{"scroll-ms":w()}],"scroll-me":[{"scroll-me":w()}],"scroll-mbs":[{"scroll-mbs":w()}],"scroll-mbe":[{"scroll-mbe":w()}],"scroll-mt":[{"scroll-mt":w()}],"scroll-mr":[{"scroll-mr":w()}],"scroll-mb":[{"scroll-mb":w()}],"scroll-ml":[{"scroll-ml":w()}],"scroll-p":[{"scroll-p":w()}],"scroll-px":[{"scroll-px":w()}],"scroll-py":[{"scroll-py":w()}],"scroll-ps":[{"scroll-ps":w()}],"scroll-pe":[{"scroll-pe":w()}],"scroll-pbs":[{"scroll-pbs":w()}],"scroll-pbe":[{"scroll-pbe":w()}],"scroll-pt":[{"scroll-pt":w()}],"scroll-pr":[{"scroll-pr":w()}],"scroll-pb":[{"scroll-pb":w()}],"scroll-pl":[{"scroll-pl":w()}],"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",vM,cM]}],fill:[{fill:["none",...T()]}],"stroke-w":[{stroke:[XN,yM,dM,uM]}],stroke:[{stroke:["none",...T()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","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","pbs","pbe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"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"],"line-clamp":["display","overflow"],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-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","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-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","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"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","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-pbs","scroll-pbe","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"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}});function DM(...e){return IM(function(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=vN(e))&&(r&&(r+=" "),r+=t);return r}(e))}const PM=e.defineComponent({__name:"Card",props:{borderStyle:{default:"solid"},spacing:{default:"md"},cappedWidth:{type:Boolean,default:!1},variant:{default:"default"},shadowSize:{default:"sm"},borderRadius:{default:"base"},title:{},rootClass:{},wrapperClass:{}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["flex flex-col",e.unref(DM)("grouped"===t.variant?"border border-dashed border-opacity-50":"gap-1","md"===t.borderRadius?"rounded-md":"","lg"===t.borderRadius?"rounded-lg":"","base"===t.borderRadius?"rounded":"","grouped"===t.variant?t.rootClass:"",t.wrapperClass)])},[t.title||n.$slots.title?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(e.unref(DM)("flex items-center justify-between","sm"===t.spacing?"p-1.5":"","md"===t.spacing?"p-3":"","lg"===t.spacing?"p-6":""))},[e.renderSlot(n.$slots,"title",{},()=>[e.createVNode(e.unref(gc),{tag:"span",variant:"grouped"===t.variant?"caps-heading":"body-sm",weight:"semibold","no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.title),1)]),_:1},8,["variant"])]),e.renderSlot(n.$slots,"right")],2)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass([e.unref(DM)("sm"===t.spacing?"p-1.5":"","md"===t.spacing?"p-3":"","lg"===t.spacing?"p-6":"","solid"===t.borderStyle&&"sm"===t.shadowSize?"shadow-sm":"","solid"===t.borderStyle&&"md"===t.shadowSize?"shadow-md":"","solid"===t.borderStyle&&"lg"===t.shadowSize?"shadow-lg":"","dashed"===t.borderStyle?"border-dashed border-opacity-50":"","none"===t.shadowSize&&"default"===t.variant?"border-gray-100":"","error"===t.variant?"border-red-600":"","warning"===t.variant?"border-yellow-400":"","primary"===t.variant?"border-primary-400":"",t.cappedWidth?"max-w-220":"","base"===t.borderRadius?"rounded":"","md"===t.borderRadius?"rounded-md":"","lg"===t.borderRadius?"rounded-lg":"","grouped"===t.variant?"border-b-0 border-l-0 border-r-0":"","grouped"===t.variant?"rounded-t-none":"","primary"===t.variant?"bg-blue-50/50":"","default"===t.variant?"bg-white":"",t.rootClass?`${t.rootClass}`:""),"border"]),"data-testid":"card"},[e.renderSlot(n.$slots,"default")],2)],2))}),$M={class:"grow text-ellipsis overflow-hidden"},LM=e.defineComponent({__name:"IconTitle",props:{title:{},subTitle:{},icon:{},variant:{default:"default"},suffix:{},size:{default:"md"},avatar:{type:Boolean,default:!1},uppercase:{type:Boolean,default:!0},resourceId:{}},setup(t){const n=t,r=e.computed(()=>{switch(n.variant){case"transparent":return"";case"warning":return"bg-gradient-to-br backdrop-blur-sm from-orange-600/20 to-yellow-200/20";case"neutral":return"bg-neutral-100";default:return"bg-gradient-to-br backdrop-blur-sm from-peach-100/20 to-mint-100/20"}});return(n,o)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["flex items-center",{"gap-4":["md","lg"].includes(t.size),"gap-3":"sm"===t.size,"gap-2":"xs"===t.size&&"transparent"!==t.variant,"gap-1":"xs"===t.size&&"transparent"===t.variant}])},[t.icon?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass([{[r.value]:!0,"w-9 h-9":["md","lg"].includes(t.size),"w-8 h-8":"sm"===t.size,"w-6 h-6":"xs"===t.size},"rounded-md flex items-center justify-center shrink-0"])},[t.icon?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,size:["sm","xs"].includes(t.size)?"xs":"md",icon:t.icon},null,8,["size","icon"])):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0),t.avatar&&t.title?(e.openBlock(),e.createBlock(e.unref(XB),{key:1,initials:t.title.slice(0,1),"color-hash":t.title,size:["sm","xs"].includes(t.size)?"lg":"xl"},null,8,["initials","color-hash","size"])):e.createCommentVNode("",!0),e.createElementVNode("div",$M,[t.title||n.$slots.default?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass([{"text-3xl":"lg"===t.size,"text-2xl":"md"===t.size,"text-base":"sm"===t.size,"text-xs text-gray-600":"xs"===t.size,"text-gray-900":"xs"!==t.size,uppercase:"xs"===t.size&&t.uppercase},"flex font-semibold items-center"])},[e.renderSlot(n.$slots,"prefix"),e.renderSlot(n.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.title),1)]),e.renderSlot(n.$slots,"suffix",{},()=>[e.createTextVNode(e.toDisplayString(t.suffix),1)])],2)):e.createCommentVNode("",!0),t.subTitle||n.$slots.subTitle&&!e.unref(QS)(n.$slots.subTitle({}))?(e.openBlock(),e.createBlock(e.unref(gc),{key:1,variant:"body-sm",shade:"lighter"},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"subTitle",{},()=>[e.createTextVNode(e.toDisplayString(t.subTitle),1)])]),_:3})):e.createCommentVNode("",!0)])],2))}}),RM={class:"grow items-center truncate"},HM=e.defineComponent({__name:"CardHeader",props:{icon:{},iconVariant:{default:"neutral"},title:{},subTitle:{},spacing:{default:"md"},size:{default:"sm"},variant:{default:"default"},uppercase:{type:Boolean,default:!0}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["flex items-center",{"px-2 pt-2":"xs"===t.spacing,"px-4 pt-2":"sm"===t.spacing,"pb-2":["xs","sm"].includes(t.spacing)&&"bordered"===t.variant,"px-4 pt-4":"md"===t.spacing,"pb-4":"md"===t.spacing&&"bordered"===t.variant,"px-8 pt-6":"lg"===t.spacing,"pb-6":"lg"===t.spacing&&"bordered"===t.variant,"border-b border-gray-100":"bordered"===t.variant}])},[e.createElementVNode("div",RM,[e.createVNode(e.unref(LM),{icon:t.icon,title:t.title,"sub-title":t.subTitle,variant:t.iconVariant,size:t.size,uppercase:t.uppercase},{prefix:e.withCtx(()=>[e.renderSlot(n.$slots,"prefix")]),default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),subTitle:e.withCtx(()=>[e.renderSlot(n.$slots,"subTitle")]),suffix:e.withCtx(()=>[e.renderSlot(n.$slots,"title-suffix")]),_:3},8,["icon","title","sub-title","variant","size","uppercase"])]),e.renderSlot(n.$slots,"right")],2))}),FM=e.defineComponent({__name:"CardContent",props:{spacing:{default:"md"}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass({"p-2":"xs"===t.spacing,"px-4 py-3":"sm"===t.spacing,"p-4":"md"===t.spacing,"px-8 py-6":"lg"===t.spacing})},[e.renderSlot(n.$slots,"default")],2))}),jM=e.defineComponent({__name:"FullClickableBlock",props:{tag:{default:"div"}},setup:t=>(n,r)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.tag),{class:"relative"},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3}))}),UM={class:"after:absolute after:inset-0 appearance-none"};const GM=fB({},[["render",function(t,n){return e.openBlock(),e.createElementBlock("button",UM,[e.renderSlot(t.$slots,"default")])}]]);var qM;const ZM="undefined"!=typeof window,WM=()=>{},KM=ZM&&(null==(qM=null==window?void 0:window.navigator)?void 0:qM.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function JM(t){return"function"==typeof t?t():e.unref(t)}function YM(t){return!!e.getCurrentScope()&&(e.onScopeDispose(t),!0)}function XM(e){var t;const n=JM(e);return null!=(t=null==n?void 0:n.$el)?t:n}const QM=ZM?window:void 0;function eT(...t){let n,r,o,i;if("string"==typeof t[0]||Array.isArray(t[0])?([r,o,i]=t,n=QM):[n,r,o,i]=t,!n)return WM;Array.isArray(r)||(r=[r]),Array.isArray(o)||(o=[o]);const a=[],l=()=>{a.forEach(e=>e()),a.length=0},s=e.watch(()=>[XM(n),JM(i)],([e,t])=>{l(),e&&a.push(...r.flatMap(n=>o.map(r=>((e,t,n,r)=>(e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)))(e,n,r,t))))},{immediate:!0,flush:"post"}),c=()=>{s(),l()};return YM(c),c}let tT=!1;function nT(...e){let t,n,r={};3===e.length?(t=e[0],n=e[1],r=e[2]):2===e.length?"object"==typeof e[1]?(t=!0,n=e[0],r=e[1]):(t=e[0],n=e[1]):(t=!0,n=e[0]);const{target:o=QM,eventName:i="keydown",passive:a=!1}=r,l="function"==typeof(s=t)?s:"string"==typeof s?e=>e.key===s:Array.isArray(s)?e=>s.includes(e.key):()=>!0;var s;return eT(o,i,e=>{l(e)&&n(e)},a)}function rT(t,n=!1){const r=e.ref(),o=()=>r.value=Boolean(t());return o(),function(t,n=!0){e.getCurrentInstance()?e.onMounted(t):n?t():e.nextTick(t)}(o,n),r}function oT(t,n={}){const{window:r=QM}=n,o=rT(()=>r&&"matchMedia"in r&&"function"==typeof r.matchMedia);let i;const a=e.ref(!1),l=()=>{i&&("removeEventListener"in i?i.removeEventListener("change",s):i.removeListener(s))},s=()=>{var n;o.value&&(l(),i=r.matchMedia((n=t,"function"==typeof n?e.computed(n):e.ref(n)).value),a.value=i.matches,"addEventListener"in i?i.addEventListener("change",s):i.addListener(s))};return e.watchEffect(s),YM(()=>l()),a}const iT={sm:640,md:768,lg:1024,xl:1280,"2xl":1536};var aT=Object.defineProperty,lT=Object.getOwnPropertySymbols,sT=Object.prototype.hasOwnProperty,cT=Object.prototype.propertyIsEnumerable,dT=(e,t,n)=>t in e?aT(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;function uT(e,t={}){function n(t,n){let r=e[t];return null!=n&&(r=function(e,t){var n;if("number"==typeof e)return e+t;const r=(null==(n=e.match(/^-?[0-9]+\.?[0-9]*/))?void 0:n[0])||"",o=e.slice(r.length),i=parseFloat(r)+t;return Number.isNaN(i)?e:i+o}(r,n)),"number"==typeof r&&(r=`${r}px`),r}const{window:r=QM}=t;function o(e){return!!r&&r.matchMedia(e).matches}const i=e=>oT(`(min-width: ${n(e)})`,t),a=Object.keys(e).reduce((e,t)=>(Object.defineProperty(e,t,{get:()=>i(t),enumerable:!0,configurable:!0}),e),{});return((e,t)=>{for(var n in t||(t={}))sT.call(t,n)&&dT(e,n,t[n]);if(lT)for(var n of lT(t))cT.call(t,n)&&dT(e,n,t[n]);return e})({greater:e=>oT(`(min-width: ${n(e,.1)})`,t),greaterOrEqual:i,smaller:e=>oT(`(max-width: ${n(e,-.1)})`,t),smallerOrEqual:e=>oT(`(max-width: ${n(e)})`,t),between:(e,r)=>oT(`(min-width: ${n(e)}) and (max-width: ${n(r,-.1)})`,t),isGreater:e=>o(`(min-width: ${n(e,.1)})`),isGreaterOrEqual:e=>o(`(min-width: ${n(e)})`),isSmaller:e=>o(`(max-width: ${n(e,-.1)})`),isSmallerOrEqual:e=>o(`(max-width: ${n(e)})`),isInBetween:(e,t)=>o(`(min-width: ${n(e)}) and (max-width: ${n(t,-.1)})`)},a)}const pT="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},hT="__vueuse_ssr_handlers__";pT[hT]=pT[hT]||{};var mT,fT,gT=Object.getOwnPropertySymbols,vT=Object.prototype.hasOwnProperty,yT=Object.prototype.propertyIsEnumerable;function bT(t,n,r={}){const o=r,{window:i=QM}=o,a=((e,t)=>{var n={};for(var r in e)vT.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&gT)for(var r of gT(e))t.indexOf(r)<0&&yT.call(e,r)&&(n[r]=e[r]);return n})(o,["window"]);let l;const s=rT(()=>i&&"ResizeObserver"in i),c=()=>{l&&(l.disconnect(),l=void 0)},d=e.watch(()=>XM(t),e=>{c(),s.value&&i&&e&&(l=new ResizeObserver(n),l.observe(e,a))},{immediate:!0,flush:"post"}),u=()=>{c(),d()};return YM(u),{isSupported:s,stop:u}}function wT(t,n={width:0,height:0},r={}){const{window:o=QM,box:i="content-box"}=r,a=e.computed(()=>{var e,n;return null==(n=null==(e=XM(t))?void 0:e.namespaceURI)?void 0:n.includes("svg")}),l=e.ref(n.width),s=e.ref(n.height);return bT(t,([e])=>{const n="border-box"===i?e.borderBoxSize:"content-box"===i?e.contentBoxSize:e.devicePixelContentBoxSize;if(o&&a.value){const e=XM(t);if(e){const t=o.getComputedStyle(e);l.value=parseFloat(t.width),s.value=parseFloat(t.height)}}else if(n){const e=Array.isArray(n)?n:[n];l.value=e.reduce((e,{inlineSize:t})=>e+t,0),s.value=e.reduce((e,{blockSize:t})=>e+t,0)}else l.value=e.contentRect.width,s.value=e.contentRect.height},r),e.watch(()=>XM(t),e=>{l.value=e?n.width:0,s.value=e?n.height:0}),{width:l,height:s}}(fT=mT||(mT={})).UP="UP",fT.RIGHT="RIGHT",fT.DOWN="DOWN",fT.LEFT="LEFT",fT.NONE="NONE";var kT=Object.defineProperty,xT=Object.getOwnPropertySymbols,_T=Object.prototype.hasOwnProperty,CT=Object.prototype.propertyIsEnumerable,ET=(e,t,n)=>t in e?kT(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;function ST(t,n,r,o={}){var i,a,l;const{clone:s=!1,passive:c=!1,eventName:d,deep:u=!1,defaultValue:p}=o,h=e.getCurrentInstance(),m=r||(null==h?void 0:h.emit)||(null==(i=null==h?void 0:h.$emit)?void 0:i.bind(h))||(null==(l=null==(a=null==h?void 0:h.proxy)?void 0:a.$emit)?void 0:l.bind(null==h?void 0:h.proxy));let f=d;n||(n="modelValue"),f=d||f||`update:${n.toString()}`;const g=e=>{return s?(e=>"function"==typeof e)(s)?s(e):(t=e,JSON.parse(JSON.stringify(t))):e;var t},v=()=>void 0!==t[n]?g(t[n]):p;if(c){const r=v(),o=e.ref(r);return e.watch(()=>t[n],e=>o.value=g(e)),e.watch(o,e=>{(e!==t[n]||u)&&m(f,e)},{deep:u}),o}return e.computed({get:()=>v(),set(e){m(f,e)}})}((e,t)=>{for(var n in t||(t={}))_T.call(t,n)&&ET(e,n,t[n]);if(xT)for(var n of xT(t))CT.call(t,n)&&ET(e,n,t[n])})({linear:function(e){return e}},{easeInSine:[.12,0,.39,0],easeOutSine:[.61,1,.88,1],easeInOutSine:[.37,0,.63,1],easeInQuad:[.11,0,.5,0],easeOutQuad:[.5,1,.89,1],easeInOutQuad:[.45,0,.55,1],easeInCubic:[.32,0,.67,0],easeOutCubic:[.33,1,.68,1],easeInOutCubic:[.65,0,.35,1],easeInQuart:[.5,0,.75,0],easeOutQuart:[.25,1,.5,1],easeInOutQuart:[.76,0,.24,1],easeInQuint:[.64,0,.78,0],easeOutQuint:[.22,1,.36,1],easeInOutQuint:[.83,0,.17,1],easeInExpo:[.7,0,.84,0],easeOutExpo:[.16,1,.3,1],easeInOutExpo:[.87,0,.13,1],easeInCirc:[.55,0,1,.45],easeOutCirc:[0,.55,.45,1],easeInOutCirc:[.85,0,.15,1],easeInBack:[.36,0,.66,-.56],easeOutBack:[.34,1.56,.64,1],easeInOutBack:[.68,-.6,.32,1.6]});const BT={key:0},NT=e.defineComponent({__name:"CollapsibleCard",props:{isOpen:{type:Boolean,default:!1},isControlled:{type:Boolean},title:{},icon:{},iconVariant:{},spacing:{default:"md"},borderStyle:{},isExpandContentHidden:{type:Boolean,default:!1},cappedWidth:{type:Boolean},variant:{},shadowSize:{},borderRadius:{},rootClass:{},wrapperClass:{}},emits:["toggle","toggled"],setup(t,{emit:n}){const r=t,o=n,[i,a]=function(t=!1,n={}){const{truthyValue:r=!0,falsyValue:o=!1}=n,i=e.isRef(t),a=e.ref(t);function l(e){if(arguments.length)return a.value=e,a.value;{const e=JM(r);return a.value=a.value===e?JM(o):e,a.value}}return i?l:[a,l]}(!r.isOpen),l=()=>{r.isControlled?o("toggle"):a()};return e.watch(()=>i.value,e=>{o("toggled",e)}),e.watch(()=>r.isOpen,e=>{r.isControlled&&a(!e)}),(n,r)=>(e.openBlock(),e.createBlock(e.unref(PM),{spacing:"none","root-class":"ease-in-out duration-200 hover:shadow-md","border-style":t.borderStyle},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"pre-header"),e.createVNode(e.unref(HM),{"data-testid":"card-header",title:t.title,icon:t.icon,"icon-variant":t.iconVariant,spacing:t.spacing,class:e.normalizeClass(["cursor-pointer",{"pb-4":"md"===t.spacing,"pb-6":"lg"===t.spacing}]),variant:"bordered",tabindex:"0",onClick:e.withModifiers(l,["stop"]),onKeyup:e.withKeys(l,["enter"])},e.createSlots({prefix:e.withCtx(()=>[e.renderSlot(n.$slots,"title-prefix")]),default:e.withCtx(()=>[e.renderSlot(n.$slots,"title")]),"title-suffix":e.withCtx(()=>[e.renderSlot(n.$slots,"title-suffix")]),_:2},[t.isExpandContentHidden?void 0:{name:"right",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"right"),e.createVNode(e.unref(hc),{icon:e.unref(i)?"unfold_more":"unfold_less",size:"md"},null,8,["icon"])]),key:"0"}]),1032,["title","icon","icon-variant","spacing","class"]),t.isExpandContentHidden?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(dV),{key:0},{default:e.withCtx(()=>[e.unref(i)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",BT,[e.createVNode(e.unref(FM),{spacing:t.spacing,class:"pt-0"},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},8,["spacing"])]))]),_:3}))]),_:3},8,["border-style"]))}}),MT="w-6",TT=e.defineComponent({__name:"CollapsibleList",props:{type:{default:"ordered"},hasAddButton:{type:Boolean},i18n:{}},emits:["add"],setup(t){const n=t,r=e.computed(()=>"ordered"===n.type?"ol":"ul");return(n,o)=>{var i;return e.openBlock(),e.createElementBlock("div",null,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.value),null,{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3})),e.createElementVNode("div",{class:e.normalizeClass(["flex flex-col items-center justify-center",e.unref(MT)])},[t.hasAddButton?(e.openBlock(),e.createBlock(e.unref(gN),{key:0,square:"","aria-label":(null==(i=t.i18n)?void 0:i.addButtonLabel)??"Add item",color:"gray",variant:"outline",size:"sm","icon-prefix":"add",onClick:o[0]||(o[0]=e=>n.$emit("add"))},null,8,["aria-label"])):e.createCommentVNode("",!0)],2)])}}}),VT={tooltipCollapse:"Close",tooltipExpand:"Open"},AT={class:"flex flex-col"},zT=["aria-label"],OT={class:"flex grow justify-between items-center select-none"},IT={class:"flex gap-2 items-center"},DT={key:0},PT={class:"flex gap-6"},$T={class:"pt-5 grow"},LT={key:0,class:"pb-6"},RT=e.defineComponent({__name:"CollapsibleListItem",props:{hasContinuedPreline:{type:Boolean,default:!0},itemNumber:{default:1},i18n:{default:()=>VT},isOpen:{type:Boolean},hideCollapseIcon:{type:Boolean,default:!1}},emits:["toggle"],setup(t){const n=t,r=e.computed(()=>n.isOpen?"unfold_less":"unfold_more");return(n,o)=>(e.openBlock(),e.createElementBlock("li",AT,[e.createElementVNode("button",{type:"button",class:"flex gap-6 items-center","aria-label":t.isOpen?t.i18n.tooltipCollapse:t.i18n.tooltipExpand,onClick:o[0]||(o[0]=e.withModifiers(e=>n.$emit("toggle"),["stop"]))},[e.createElementVNode("div",{class:e.normalizeClass(["flex items-center justify-center border rounded bg-white h-6 shadow-sm select-none",e.unref(MT)])},[e.renderSlot(n.$slots,"icon",{},()=>[e.createVNode(e.unref(gc),{tag:"span",variant:"body-xs",weight:"semibold"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.itemNumber),1)]),_:1})])],2),e.createElementVNode("div",OT,[e.createElementVNode("div",null,[e.renderSlot(n.$slots,"left")]),e.createElementVNode("div",IT,[n.$slots.right?(e.openBlock(),e.createElementBlock("div",DT,[e.renderSlot(n.$slots,"right")])):e.createCommentVNode("",!0),t.hideCollapseIcon?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(hc),{key:1,icon:r.value,size:"sm",class:"h-6"},null,8,["icon"]))])])],8,zT),e.createElementVNode("div",PT,[e.createElementVNode("div",{class:e.normalizeClass(["flex justify-center relative shrink-0",e.unref(MT)])},[e.createElementVNode("div",{class:e.normalizeClass(["w-0.5 h-full pointer-events-none",[t.hasContinuedPreline?"bg-gray-100":"bg-gradient-to-b from-gray-100 to-transparent"]])},null,2)],2),e.createElementVNode("div",$T,[e.createVNode(e.unref(dV),null,{default:e.withCtx(()=>[t.isOpen?(e.openBlock(),e.createElementBlock("div",LT,[e.renderSlot(n.$slots,"default")])):e.createCommentVNode("",!0)]),_:3})])])]))}}),HT=e.defineComponent({__name:"ListGroup",props:{width:{default:"default"}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("ul",{class:e.normalizeClass(["overflow-hidden text-sm font-medium text-gray-900 bg-white border border-gray-200 rounded",{"w-48":"default"===t.width,"w-64":"wide"===t.width}])},[e.renderSlot(n.$slots,"default")],2))}),FT={key:0},jT={key:1},UT=e.defineComponent({__name:"ListGroupItem",props:{disabled:{type:Boolean,default:!1},onClick:{},dataTestid:{},variant:{}},setup:t=>(n,r)=>(e.openBlock(),e.createBlock(e.unref(jM),{tag:"li",class:e.normalizeClass(["w-full px-4 py-2 border-b border-gray-200 transition-colors",{block:!t.disabled&&t.onClick,"hover:bg-gray-50 hover:text-gray-900 focus-within:bg-gray-50 focus-within:text-gray-900":!t.disabled&&t.onClick&&"danger"!==t.variant,"hover:bg-red-50 text-red-700 focus-within:bg-red-50 focus-within:text-red-700":!t.disabled&&t.onClick&&"danger"===t.variant,"bg-gray-50 text-gray-400 cursor-not-allowed":t.disabled}]),onClick:r[1]||(r[1]=e.withModifiers(()=>{},["stop"]))},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.onClick?e.unref(GM):"span"),{class:"flex items-start w-full gap-2 focus:outline-none active:outline-none text-left",disabled:t.onClick?t.disabled:void 0,type:t.onClick?"button":void 0,"data-testid":t.dataTestid,onClick:r[0]||(r[0]=e=>{var n;return null==(n=t.onClick)?void 0:n.call(t)})},{default:e.withCtx(()=>[n.$slots.prefix?(e.openBlock(),e.createElementBlock("div",FT,[e.renderSlot(n.$slots,"prefix")])):e.createCommentVNode("",!0),e.renderSlot(n.$slots,"default"),n.$slots.suffix?(e.openBlock(),e.createElementBlock("div",jT,[e.renderSlot(n.$slots,"suffix")])):e.createCommentVNode("",!0)]),_:3},8,["disabled","type","data-testid"])),n.$slots.description?(e.openBlock(),e.createBlock(e.unref(gc),{key:0,tag:"span",variant:"body-xs",class:"mt-0.5 font-normal",shade:t.disabled?"lightest":"lighter"},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"description")]),_:3},8,["shade"])):e.createCommentVNode("",!0)]),_:3},8,["class"]))}),GT=e.defineComponent({__name:"ContextMenuItem",props:{icon:{},label:{},description:{},labelSuffixComponent:{},labelPrefixComponent:{},onClick:{type:Function},classes:{},variant:{},testId:{},disabled:{type:Boolean}},setup:t=>(n,r)=>(e.openBlock(),e.createBlock(e.unref(UT),{class:e.normalizeClass(["border-none",{[`${t.classes}`]:!!t.classes}]),"data-testid":t.testId,disabled:t.disabled,variant:t.variant,onClick:t.onClick},e.createSlots({default:e.withCtx(()=>[t.labelPrefixComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelPrefixComponent.component),e.normalizeProps(e.mergeProps({key:0},t.labelPrefixComponent.props)),null,16)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(t.label),1),t.labelSuffixComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelSuffixComponent.component),e.mergeProps({key:1},t.labelSuffixComponent.props,{class:"ml-2"}),null,16)):e.createCommentVNode("",!0)]),_:2},[t.icon?{name:"prefix",fn:e.withCtx(()=>[e.createVNode(e.unref(hc),{icon:t.icon},null,8,["icon"])]),key:"0"}:void 0,t.description?{name:"description",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.description),1)]),key:"1"}:void 0]),1032,["class","data-testid","disabled","variant","onClick"]))}),qT="relative translate-y-1/2 top-1/2 border-t border-gray-100",ZT=e.defineComponent({__name:"DividerText",props:{spacing:{default:"none"},textPosition:{default:"left"},hasOuterDivider:{type:Boolean,default:!1},text:{}},setup(t){const n=t,{leftDividerClasses:r,rightDividerClasses:o}=(t=>({leftDividerClasses:e.computed(()=>{let e=`${qT}`;return t.hasOuterDivider&&"left"===t.textPosition?e+=" w-2":e+=" grow",e}),rightDividerClasses:e.computed(()=>{let e=`${qT}`;return t.hasOuterDivider&&"right"===t.textPosition?e+=" w-2":e+=" grow",e})}))(n);return(n,i)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["flex gap-2",{"my-2":"xs"===t.spacing,"my-4":"sm"===t.spacing,"my-6":"md"===t.spacing,"my-8":"lg"===t.spacing,"my-10":"xl"===t.spacing}])},["left"===t.textPosition&&t.hasOuterDivider||["center","right"].includes(t.textPosition)?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(e.unref(r))},null,2)):e.createCommentVNode("",!0),e.renderSlot(n.$slots,"default",{},()=>[e.createVNode(e.unref(gc),{tag:"span","no-spacing":"",variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.text),1)]),_:1})]),"right"===t.textPosition&&t.hasOuterDivider||["center","left"].includes(t.textPosition)?(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass(e.unref(o))},null,2)):e.createCommentVNode("",!0)],2))}}),WT=e.defineComponent({__name:"Divider",props:{spacing:{default:"md"}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("hr",{class:e.normalizeClass({"my-1":"xxs"===t.spacing,"my-2":"xs"===t.spacing,"my-4":"sm"===t.spacing,"my-6":"md"===t.spacing,"my-8":"lg"===t.spacing,"my-10":"xl"===t.spacing})},null,2))}),KT=e.defineComponent({__name:"ContextMenuGroup",props:{label:{},items:{}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(e.unref(ZT),{"has-outer-divider":""},{default:e.withCtx(()=>[e.createVNode(e.unref(gc),{class:"py-2",variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.label),1)]),_:1})]),_:1}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(t,n)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:n},["divider"===t?(e.openBlock(),e.createBlock(e.unref(WT),{key:0})):t.label?(e.openBlock(),e.createBlock(GT,{key:1,label:t.label,"on-click":t.onClick,icon:t.icon,variant:t.variant,classes:t.classes,"label-suffix-component":t.labelSuffixComponent,"label-prefix-component":t.labelPrefixComponent},null,8,["label","on-click","icon","variant","classes","label-suffix-component","label-prefix-component"])):e.createCommentVNode("",!0)],64))),128))],64))});function JT(e){if(function(e){return null!=e&&"object"==typeof e&&"$el"in e}(e)){const t=e.$el;return Hh(t)&&"#comment"===$h(t)?null:t}return e}function YT(t){return"function"==typeof t?t():e.unref(t)}function XT(e){if("undefined"==typeof window)return 1;return(e.ownerDocument.defaultView||window).devicePixelRatio||1}function QT(e,t){const n=XT(e);return Math.round(t*n)/n}function eV(t,n,r){void 0===r&&(r={});const o=r.whileElementsMounted,i=e.computed(()=>{var e;return null==(e=YT(r.open))||e}),a=e.computed(()=>YT(r.middleware)),l=e.computed(()=>{var e;return null!=(e=YT(r.placement))?e:"bottom"}),s=e.computed(()=>{var e;return null!=(e=YT(r.strategy))?e:"absolute"}),c=e.computed(()=>{var e;return null==(e=YT(r.transform))||e}),d=e.computed(()=>JT(t.value)),u=e.computed(()=>JT(n.value)),p=e.ref(0),h=e.ref(0),m=e.ref(s.value),f=e.ref(l.value),g=e.shallowRef({}),v=e.ref(!1),y=e.computed(()=>{const e={position:m.value,left:"0",top:"0"};if(!u.value)return e;const t=QT(u.value,p.value),n=QT(u.value,h.value);return c.value?{...e,transform:"translate("+t+"px, "+n+"px)",...XT(u.value)>=1.5&&{willChange:"transform"}}:{position:m.value,left:t+"px",top:n+"px"}});let b;function w(){if(null==d.value||null==u.value)return;const e=i.value;Tm(d.value,u.value,{middleware:a.value,placement:l.value,strategy:s.value}).then(t=>{p.value=t.x,h.value=t.y,m.value=t.strategy,f.value=t.placement,g.value=t.middlewareData,v.value=!1!==e})}function k(){"function"==typeof b&&(b(),b=void 0)}return e.watch([a,l,s,i],w,{flush:"sync"}),e.watch([d,u],function(){k(),void 0!==o?null==d.value||null==u.value||(b=o(d.value,u.value,w)):w()},{flush:"sync"}),e.watch(i,function(){i.value||(v.value=!1)},{flush:"sync"}),e.getCurrentScope()&&e.onScopeDispose(k),{x:e.shallowReadonly(p),y:e.shallowReadonly(h),strategy:e.shallowReadonly(m),placement:e.shallowReadonly(f),middlewareData:e.shallowReadonly(g),isPositioned:e.shallowReadonly(v),floatingStyles:y,update:w}}const tV=["id"],nV=e.defineComponent({__name:"Portal",props:{to:{},name:{},disabled:{type:Boolean}},setup(t){const n=t;return e.onMounted(()=>{if(!n.name&&!n.to)throw new Error("Define either the `to` or the `name` prop.")}),(n,r)=>t.name?(e.openBlock(),e.createElementBlock("div",{key:0,id:`portal-${t.name}`},null,8,tV)):t.to?(e.openBlock(),e.createBlock(e.Teleport,{key:1,to:`#portal-${t.to}`,disabled:t.disabled},[e.renderSlot(n.$slots,"default")],8,["to","disabled"])):e.createCommentVNode("",!0)}}),rV=(t,n=!0,r=[])=>(t.forEach(t=>{if(null!==t)if("object"==typeof t)if(Array.isArray(t))rV(t,n,r);else if(t.type===e.Fragment){if(null===t.children)return;Array.isArray(t.children)&&rV(t.children,n,r)}else t.type!==e.Comment&&r.push(t);else"string"!=typeof t&&"number"!=typeof t||r.push(e.createTextVNode(String(t)))}),r),oV={focus:["onFocus","onBlur"],click:["onClick"],hover:["onMouseenter","onMouseleave"]};const iV=e.defineComponent({name:"SlotListener",props:{trigger:{type:String,default:"click"}},emits:["click","focus","blur","mouseenter","mouseleave"],setup:(e,{emit:t})=>({handleClick:e=>{t("click",e)},handleBlur:e=>{t("blur",e)},handleFocus:e=>{t("focus",e)},handleMouseLeave:e=>{t("mouseleave",e)},handleMouseEnter:e=>{t("mouseenter",e)}}),render(){const{$slots:e}=this,t={onClick:this.handleClick,onMouseenter:this.handleMouseEnter,onMouseleave:this.handleMouseLeave,onFocus:this.handleFocus,onBlur:this.handleBlur},n=((e,t="default",n)=>{const r=e[t];if(!r)return null;const o=rV(r(n));return 1===o.length?o[0]:null})(e,"default"),r=[t];(null==n?void 0:n.props)&&r.push(BS(n.props,"onClick","onMouseenter","onMouseleave","onFocus","onBlur"));var o,i;return n&&(o=n,i={onBlur:e=>{r.forEach(t=>{var n;null==(n=null==t?void 0:t.onBlur)||n.call(t,e)})},onFocus:e=>{r.forEach(t=>{var n;null==(n=null==t?void 0:t.onFocus)||n.call(t,e)})},onClick:e=>{r.forEach(t=>{var n;null==(n=null==t?void 0:t.onClick)||n.call(t,e)})},onMouseenter:e=>{r.forEach(t=>{var n;null==(n=null==t?void 0:t.onMouseenter)||n.call(t,e)})},onMouseleave:e=>{r.forEach(t=>{var n;null==(n=null==t?void 0:t.onMouseleave)||n.call(t,e)})}},Object.entries(oV).forEach(([,e])=>{e.forEach(e=>{o.props?o.props=Object.assign({},o.props):o.props={};const t=o.props[e],n=i[e];o.props[e]=t?(...e)=>{t(...e),n(...e)}:n})})),n}}),aV={class:"inline-flex items-center"},lV=e.defineComponent({__name:"Dropdown",props:{placement:{default:"bottom-end"},text:{default:""},transition:{default:""},offset:{default:8},disabled:{type:Boolean},isPortalDisabled:{type:Boolean},dropdownClass:{}},setup(t){const n=t,r=e.ref(!1),o=()=>r.value=!1,i=()=>{n.disabled||(r.value=!r.value)},a={bottom:"to-bottom","bottom-start":"to-bottom","bottom-end":"to-bottom",left:"to-left","left-start":"to-left","left-end":"to-left",right:"to-right","right-start":"to-right","right-end":"to-right",top:"to-top","top-start":"to-top","top-end":"to-top"},l=e.ref(),s=e.ref(),c=e.ref(),d=e.computed(()=>null===n.transition?a[n.placement]:n.transition),{floatingStyles:u}=eV(c,s,{whileElementsMounted:Bm,placement:n.placement,middleware:[Nm(n.offset),Mm()]});return function(e,t,n={}){const{window:r=QM,ignore:o=[],capture:i=!0,detectIframe:a=!1}=n;if(!r)return;KM&&!tT&&(tT=!0,Array.from(r.document.body.children).forEach(e=>e.addEventListener("click",WM)));let l=!0;const s=e=>o.some(t=>{if("string"==typeof t)return Array.from(r.document.querySelectorAll(t)).some(t=>t===e.target||e.composedPath().includes(t));{const n=XM(t);return n&&(e.target===n||e.composedPath().includes(n))}}),c=[eT(r,"click",n=>{const r=XM(e);r&&r!==n.target&&!n.composedPath().includes(r)&&(0===n.detail&&(l=!s(n)),l?t(n):l=!0)},{passive:!0,capture:i}),eT(r,"pointerdown",t=>{const n=XM(e);n&&(l=!t.composedPath().includes(n)&&!s(t))},{passive:!0}),a&&eT(r,"blur",n=>{var o;const i=XM(e);"IFRAME"!==(null==(o=r.document.activeElement)?void 0:o.tagName)||(null==i?void 0:i.contains(r.document.activeElement))||t(n)})].filter(Boolean)}(c,()=>{r.value&&(r.value=!1)}),nT("Escape",()=>{r.value=!1}),(n,a)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"wrapper",ref:c,class:"inline-flex relative"},[e.createElementVNode("div",aV,[e.createVNode(e.unref(iV),{onClick:i},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"trigger",{visible:r.value},()=>[e.createVNode(e.unref(gN),{ref_key:"trigger",ref:l},{suffix:e.withCtx(()=>[...a[0]||(a[0]=[e.createElementVNode("svg",{class:"w-4 h-4 ml-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M19 9l-7 7-7-7"})],-1)])]),default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.text)+" ",1)]),_:1},512)],!0)]),_:3})]),e.createVNode(e.unref(nV),{to:e.unref("dropdown"),disabled:t.isPortalDisabled},{default:e.withCtx(()=>[e.createVNode(e.Transition,{name:d.value},{default:e.withCtx(()=>[r.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"content",ref:s,style:e.normalizeStyle(e.unref(u)),class:e.normalizeClass(["z-60 bg-white divide-y divide-gray-100 rounded shadow",t.dropdownClass])},[e.createVNode(e.unref(iV),{onClick:o},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default",{},void 0,!0)]),_:3})],6)):e.createCommentVNode("",!0)]),_:3},8,["name"])]),_:3},8,["to","disabled"])],512))}}),sV=fB(lV,[["__scopeId","data-v-ce4df87e"]]),cV="data-expand-transition-style",dV=e.defineComponent({__name:"Expand",setup(t){const n=e=>{const t=e.getRootNode();if(t instanceof ShadowRoot){if(t.querySelector(`style[${cV}]`))return;const e=document.createElement("style");e.setAttribute(cV,"true"),e.textContent="\n .expand-enter-active,\n .expand-leave-active {\n transition: height 300ms ease-in-out;\n overflow: hidden;\n }\n\n .expand-enter,\n .expand-leave-to {\n height: 0;\n }\n ",t.appendChild(e)}},r=e=>{n(e);const t=e,r=getComputedStyle(t).width;t.style.width=r,t.style.position="absolute",t.style.visibility="hidden",t.style.height="auto";const o=getComputedStyle(t).height;t.style.width="",t.style.position="",t.style.visibility="",t.style.height="0",requestAnimationFrame(()=>{t.style.height=o})},o=e=>{e.style.height="auto"},i=e=>{n(e);const t=e,r=getComputedStyle(t).height;t.style.height=r,requestAnimationFrame(()=>{t.style.height="0"})};return(t,n)=>(e.openBlock(),e.createBlock(e.Transition,{name:"expand",onEnter:r,onLeave:i,onAfterEnter:o},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default")]),_:3}))}});const uV=fB({},[["render",function(t,n){return e.openBlock(),e.createBlock(e.TransitionGroup,{"enter-active-class":"duration-100 ease-out transform-gpu","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"duration-100 ease-in transform-gpu","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default")]),_:3})}]]),pV=e.defineComponent({__name:"ContextMenu",props:{items:{},icon:{default:"more_vert"},square:{type:Boolean,default:!1},outlined:{type:Boolean},width:{},disabled:{type:Boolean},isPortalDisabled:{type:Boolean},triggerSize:{default:"sm"},dropdownClass:{}},setup(t){const n=t,r=e.useSlots(),o=e.computed(()=>{var e,t;return n.disabled||(null==(t=(null==(e=n.items)?void 0:e.flatMap(e=>"divider"!==e&&"items"in e?e.items:e))??[])?void 0:t.filter(e=>"divider"!==e).every(e=>e.disabled))&&!r.default});return(n,r)=>(e.openBlock(),e.createBlock(e.unref(uV),null,{default:e.withCtx(()=>{var i;return[(null==(i=t.items)?void 0:i.length)||n.$slots.default||t.disabled?(e.openBlock(),e.createBlock(e.unref(sV),e.mergeProps({key:0,"is-portal-disabled":o.value},n.$attrs,{"dropdown-class":t.dropdownClass}),{trigger:e.withCtx(({visible:i})=>[e.renderSlot(n.$slots,"trigger",{visible:i},()=>[e.createVNode(e.unref(gN),{type:"button",pill:!t.square,square:"",color:"gray",variant:"outline",size:t.triggerSize,class:e.normalizeClass({"border-none":!t.outlined}),"data-testid":"context-menu",disabled:o.value,"icon-prefix":t.icon,onClick:r[0]||(r[0]=e.withModifiers(()=>{},["stop"]))},null,8,["pill","size","class","disabled","icon-prefix"])])]),default:e.withCtx(()=>[t.items||n.$slots.default?(e.openBlock(),e.createBlock(e.unref(HT),{key:0,width:t.width,class:"z-60 p-0.5"},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"header"),t.items?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(t.items,(n,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:r},["divider"===n&&r<t.items.length-1?(e.openBlock(),e.createBlock(e.unref(WT),{key:0,spacing:"none"})):"divider"===n||"items"in n?"divider"!==n?(e.openBlock(),e.createBlock(KT,{key:2,class:"rounded-sm",label:n.label,items:n.items},null,8,["label","items"])):e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(GT,{key:1,label:n.label,variant:n.variant,icon:n.icon,"label-suffix-component":n.labelSuffixComponent,"label-prefix-component":n.labelPrefixComponent,description:n.description,classes:n.classes,"test-id":n.testId,disabled:n.disabled,onClick:n.onClick},null,8,["label","variant","icon","label-suffix-component","label-prefix-component","description","classes","test-id","disabled","onClick"]))],64))),128)):e.createCommentVNode("",!0),e.renderSlot(n.$slots,"default")]),_:3},8,["width"])):e.createCommentVNode("",!0)]),_:3},16,["is-portal-disabled","dropdown-class"])):e.createCommentVNode("",!0)]}),_:3}))}}),hV=e=>`input-${e}`,mV={key:0,class:"text-gray-500 font-normal text-xs"},fV=e.defineComponent({__name:"LabelContent",props:{tag:{default:"label"},required:{type:Boolean},name:{},screenReaderOnly:{type:Boolean},i18n:{},optionalLabel:{}},setup:t=>(n,r)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.tag),e.mergeProps(n.$attrs,{class:["block text-sm font-medium text-gray-900",{"sr-only":t.screenReaderOnly}]}),{default:e.withCtx(()=>{var r;return[e.renderSlot(n.$slots,"default"),t.required?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",mV," ("+e.toDisplayString((null==(r=t.i18n)?void 0:r.optionalLabel)??"optional")+") ",1))]}),_:3},16,["class"]))}),gV=Symbol("tooltip"),vV=Symbol("tooltip-dark-mode"),yV={key:0,class:"px-3 mb-1"},bV=e.defineComponent({__name:"Tooltip",props:{variant:{default:"default"},placement:{default:"bottom-end"},offset:{default:4},maxWidth:{default:"xs"},rootClass:{},title:{},isDarkMode:{type:Boolean}},setup(t){const n=t,r=e.ref(),o=e.ref(null),i=e.ref(!1),a=e.inject(gV),{floatingStyles:l}=eV(r,o,{whileElementsMounted:Bm,placement:n.placement,middleware:[Nm(n.offset),Mm()]});return e.provide(vV,n.isDarkMode),(n,s)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("span",e.mergeProps(n.$attrs,{ref_key:"triggerRef",ref:r,class:"relative leading-none",onMouseenter:s[0]||(s[0]=e=>i.value=!0),onMouseleave:s[1]||(s[1]=e=>i.value=!1)}),[e.createElementVNode("span",{class:"absolute",style:e.normalizeStyle({inset:`-${t.offset}px`})},null,4),e.renderSlot(n.$slots,"default")],16),e.unref(a)?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:e.unref(a)},[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"tooltipRef",ref:o,style:e.normalizeStyle(e.unref(l)),class:e.normalizeClass(["border z-70 shadow-md",[t.rootClass,`max-w-${t.maxWidth}`,{"border-gray-200 rounded bg-white":!t.isDarkMode,"border-gray-700 rounded bg-gray-700":t.isDarkMode}]]),onMouseenter:s[2]||(s[2]=e=>i.value=!0),onMouseleave:s[3]||(s[3]=e=>i.value=!1)},[e.createElementVNode("div",{class:e.normalizeClass(["rounded",{"border-gray-50 bg-gray-50":"outline"===t.variant&&!t.isDarkMode,"border-gray-600 bg-gray-600":"outline"===t.variant&&t.isDarkMode,"border-4":"outline"===t.variant&&!t.title,"border-2":"outline"===t.variant&&t.title,"pt-0":!!t.title}])},[t.title?(e.openBlock(),e.createElementBlock("div",yV,[e.createVNode(e.unref(gc),{variant:"caps-heading",shade:"lighter",class:e.normalizeClass({"!text-gray-100":t.isDarkMode}),"no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.title),1)]),_:1},8,["class"])])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["py-2 rounded",{"bg-white":"outline"===t.variant&&!t.isDarkMode,"bg-gray-700":"outline"===t.variant&&t.isDarkMode}])},[e.renderSlot(n.$slots,"tooltip")],2)],2)],38)):e.createCommentVNode("",!0)],8,["to"])):e.createCommentVNode("",!0)],64))}}),wV={class:"flex items-center justify-between mb-1"},kV={class:"flex items-center gap-1"},xV={key:0,class:"leading-none"},_V=e.defineComponent({inheritAttrs:!1,__name:"Label",props:{tag:{default:"label"},required:{type:Boolean},name:{},screenReaderOnly:{type:Boolean},i18n:{}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("div",wV,[e.createElementVNode("div",kV,[n.$slots.tooltip?(e.openBlock(),e.createBlock(bV,{key:0,variant:"outline",class:"flex"},{default:e.withCtx(()=>{var r;return[e.createVNode(fV,e.mergeProps({...n.$props,...n.$attrs},{i18n:{optionalLabel:null==(r=t.i18n)?void 0:r.optionalLabel}}),{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},16,["i18n"]),e.createVNode(hc,{icon:"help",size:"2xs",class:"rounded drop-shadow-sm hover:bg-gray-50 hover:cursor-default"})]}),tooltip:e.withCtx(()=>[e.renderSlot(n.$slots,"tooltip")]),_:3})):(e.openBlock(),e.createBlock(fV,e.normalizeProps(e.mergeProps({key:1},{...n.$props,...n.$attrs})),{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},16))]),n.$slots.suffix?(e.openBlock(),e.createElementBlock("div",xV,[e.renderSlot(n.$slots,"suffix")])):e.createCommentVNode("",!0)]))}),CV=e.defineComponent({__name:"FormMessage",props:{message:{},variant:{default:"error"},capitalizeFirstLetter:{type:Boolean,default:!0}},setup(t){const n=t,r=e.computed(()=>{let e="text-xs";return"default"===n.variant&&(e+=" text-slate-400"),"error"===n.variant&&(e+=" text-red-600"),"warning"===n.variant&&(e+=" text-yellow-600"),n.capitalizeFirstLetter&&(e+=" first-letter:capitalize"),e});return(n,o)=>"object"!=typeof t.message||"value"in t.message?t.message||n.$slots.default?(e.openBlock(),e.createElementBlock("p",{key:1,class:e.normalizeClass(r.value)},[e.renderSlot(n.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.message),1)])],2)):e.createCommentVNode("",!0):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(t.message,({$uid:t,$message:n})=>(e.openBlock(),e.createElementBlock("p",{key:t,class:e.normalizeClass(r.value)},e.toDisplayString(n),3))),128))}}),EV={sm:"h-8",md:"h-10",lg:"h-12",xl:"h-16"};const SV=["data-testid"],BV={class:"relative"},NV={class:"relative grow"},MV=["id","disabled","type","value","name","form"],TV=["id","value","disabled","type","name","form"],VV={key:1,class:"mt-2 text-sm text-gray-500"},AV=e.defineComponent({__name:"Input",props:e.mergeModels({label:{default:""},labelScreenReaderOnly:{type:Boolean},disabled:{type:Boolean,default:!1},type:{default:"text"},asTextType:{type:Boolean,default:!1},size:{default:"md"},prefixClass:{},suffixClass:{},wrapperClass:{default:""},inputClass:{},rootClass:{default:""},required:{type:Boolean,default:!1},id:{},checked:{type:Boolean},value:{},hasShadow:{type:Boolean,default:!1},hasFocusStyles:{type:Boolean,default:!0},form:{},ring:{type:Boolean,default:!0},error:{},name:{},prefixHasBorder:{type:Boolean,default:!0},placeholder:{}},{modelValue:{},modelModifiers:{}}),emits:e.mergeModels(["blur"],["update:modelValue"]),setup(t){const n=t,r=e.useModel(t,"modelValue"),o="number"===n.type&&n.asTextType,i=n.name??TS("name"),a=e=>{o&&(r.value=e.target.value)},l=n.id??TS(`${i}-`),s=e=>{if("number"===n.type){e.target.blur()}},{wrapperClasses:c,inputClasses:d,labelClasses:u,prefixClasses:p,suffixClasses:h}=function({size:t,disabled:n,labelScreenReaderOnly:r,ring:o,hasShadow:i,hasFocusStyles:a,type:l,prefixHasBorder:s,wrapperClass:c,inputClass:d,prefixClass:u,suffixClass:p}){const h=e.computed(()=>(null==n?void 0:n.value)??!1),m=e.computed(()=>"checkbox"===(null==l?void 0:l.value)),f=e.computed(()=>!1!==(null==a?void 0:a.value)),g=e.computed(()=>({"block text-sm font-medium text-gray-900":!0,"sr-only":null==r?void 0:r.value})),v=e.computed(()=>({"rounded border border-gray-300 overflow-hidden":!0,"cursor-not-allowed bg-gray-50 border-transparent":h.value,"bg-white":!h.value,"focus-within:border-primary-500 focus-within:outline-1 focus-within:outline focus-within:outline-primary-500":f.value,"focus-within:ring-primary-500":null==o?void 0:o.value,"shadow-sm focus-within:shadow-sm":null==i?void 0:i.value})),y=e.computed(()=>({"text-gray-900 text-sm block w-full border-0 focus:border-transparent focus:outline-0 focus:ring-0 bg-transparent":!0,"p-2":m.value,"px-4":!m.value,[EV[t.value]]:!m.value,"cursor-default":h.value})),b=e.computed(()=>({"z-10 flex shrink-0 items-center":!0,"px-3":null==s?void 0:s.value,"pl-3":!(null==s?void 0:s.value),"border-r border-gray-300":null==s?void 0:s.value,"border-none":!(null==s?void 0:s.value)}));return{wrapperClasses:e.computed(()=>DM(v.value,null==c?void 0:c.value)),inputClasses:e.computed(()=>DM(y.value,null==d?void 0:d.value)),prefixClasses:e.computed(()=>DM(b.value,null==u?void 0:u.value)),suffixClasses:e.computed(()=>DM("align-end z-10 flex shrink-0 items-center gap-2 border-l border-gray-300 px-4",null==p?void 0:p.value)),labelClasses:g}}(e.toRefs(n));return(n,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(t.rootClass),"data-testid":e.unref(hV)(e.unref(i))},[t.label?(e.openBlock(),e.createBlock(_V,{key:0,class:e.normalizeClass(e.unref(u)),for:e.unref(l),required:t.required},e.createSlots({suffix:e.withCtx(()=>[e.renderSlot(n.$slots,"label-suffix")]),default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.label)+" ",1)]),_:2},[n.$slots.tooltip?{name:"tooltip",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"tooltip")]),key:"0"}:void 0]),1032,["class","for","required"])):e.createCommentVNode("",!0),e.createElementVNode("div",BV,[e.createElementVNode("div",{class:e.normalizeClass(["flex",e.unref(c)])},[n.$slots.prefix?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(e.unref(p))},[e.renderSlot(n.$slots,"prefix")],2)):e.createCommentVNode("",!0),e.createElementVNode("div",NV,[e.unref(o)?(e.openBlock(),e.createElementBlock("input",e.mergeProps({key:0},n.$attrs,{id:e.unref(l),disabled:t.disabled,type:t.type,class:e.unref(d),value:r.value,name:e.unref(i),form:t.form,autocomplete:"off",onKeyup:a,onChange:a,onBlur:m[0]||(m[0]=e=>n.$emit("blur")),onWheel:s}),null,16,MV)):e.withDirectives((e.openBlock(),e.createElementBlock("input",e.mergeProps({key:1},n.$attrs,{id:e.unref(l),"onUpdate:modelValue":m[1]||(m[1]=e=>r.value=e),value:"checkbox"===t.type?t.value:r.value,disabled:t.disabled,type:t.type,name:e.unref(i),form:t.form,class:e.unref(d),autocomplete:"off",onBlur:m[2]||(m[2]=e=>n.$emit("blur")),onWheel:s}),null,16,TV)),[[e.vModelDynamic,r.value]]),e.renderSlot(n.$slots,"input")]),n.$slots.suffix?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(e.unref(h))},[e.renderSlot(n.$slots,"suffix")],2)):e.createCommentVNode("",!0)],2),e.renderSlot(n.$slots,"adornment-end")]),!e.unref(gS)(t.error)||n.$slots.helper?(e.openBlock(),e.createElementBlock("div",VV,[e.unref(gS)(t.error)?n.$slots.helper?e.renderSlot(n.$slots,"helper",{key:1}):e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(CV,{key:0,message:t.error},null,8,["message"]))])):e.createCommentVNode("",!0)],10,SV))}}),zV={class:"flex items-center pt-1"},OV={class:"px-1.5 text-gray-500 text-xs font-semibold"};const IV=fB({},[["render",function(t,n){return e.openBlock(),e.createElementBlock("div",zV,[n[0]||(n[0]=e.createElementVNode("div",{class:"border-t w-2"},null,-1)),e.createElementVNode("span",OV,[e.renderSlot(t.$slots,"default")]),n[1]||(n[1]=e.createElementVNode("div",{class:"border-t grow"},null,-1))])}]]),DV=["aria-selected","aria-disabled","data-testid"],PV=["id","value","checked","disabled"],$V=["for"],LV={class:"flex items-center gap-1"},RV={class:"flex flex-grow flex-col"},HV={class:"flex flex-grow gap-2"},FV={class:"flex flex-grow flex-col"},jV={class:"flex flex-grow gap-2 items-center"},UV=e.defineComponent({__name:"SearchSelectInputOption",props:{multiple:{type:Boolean},search:{},condensed:{type:Boolean},label:{},checked:{type:Boolean},disabled:{type:Boolean},subLabel:{},labelPrefixComponent:{},labelSuffixComponent:{},labelInlineComponent:{},value:{},labelSrOnly:{type:Boolean}},emits:["value-changed"],setup(t,{emit:n}){const r=n,o=t,i=e=>{const t=e.target,n={value:t.value,checked:t.checked};r("value-changed",n)},a=()=>{o.multiple||o.disabled||r("value-changed",{value:o.value})},l=e.computed(()=>(e=>`checkbox-item-${e}`)(o.value)),s=e.computed(()=>tB(o.search??""));return(n,r)=>(e.openBlock(),e.createElementBlock("li",{role:"option","aria-selected":t.checked,"aria-disabled":t.disabled,class:e.normalizeClass([{"hover:bg-gray-100":!t.disabled},"flex relative"]),"data-testid":l.value,tabindex:"0",onClick:a,onKeydown:e.withKeys(a,["enter"])},[t.multiple?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("input",e.mergeProps(n.$attrs,{id:l.value,ref:"inputRef",value:t.value,checked:t.checked,disabled:t.disabled,type:"checkbox",class:["absolute top-[50%] -translate-y-2 left-3.5 w-4 h-4 bg-gray-100 border-gray-300 rounded focus:ring-blue-500 focus:ring-2",t.disabled?"text-gray-400 placeholder-gray-500":"text-blue-600"],tabindex:"-1",onChange:i}),null,16,PV),e.createElementVNode("label",{for:l.value,class:e.normalizeClass([t.disabled?"text-gray-400":"text-gray-900 rounded","w-full px-4 py-3 pl-10 text-sm font-medium"])},[e.createElementVNode("div",LV,[t.labelPrefixComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelPrefixComponent.component),e.normalizeProps(e.mergeProps({key:0},t.labelPrefixComponent.props)),null,16)):e.createCommentVNode("",!0),e.createElementVNode("div",RV,[e.createElementVNode("div",HV,[e.createVNode(e.unref(Qz),{text:t.label,search:s.value,class:e.normalizeClass(["font-semibold",{"sr-only":t.labelSrOnly}])},null,8,["text","search","class"]),t.labelInlineComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelInlineComponent.component),e.normalizeProps(e.mergeProps({key:0},t.labelInlineComponent.props)),null,16)):e.createCommentVNode("",!0),t.subLabel&&t.condensed?(e.openBlock(),e.createBlock(e.unref(Qz),{key:1,class:"text-xs text-slate-500",text:t.subLabel,search:s.value},null,8,["text","search"])):e.createCommentVNode("",!0)]),t.subLabel&&!t.condensed?(e.openBlock(),e.createBlock(e.unref(Qz),{key:0,class:"text-xs text-slate-500",text:t.subLabel,search:s.value},null,8,["text","search"])):e.createCommentVNode("",!0)]),t.labelSuffixComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelSuffixComponent.component),e.normalizeProps(e.mergeProps({key:1},t.labelSuffixComponent.props)),null,16)):e.createCommentVNode("",!0)])],10,$V)],64)):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["w-full px-4 text-sm font-medium flex items-center gap-3",[t.condensed?"p-2":"py-3",t.disabled??"cursor-not-allowed",!t.disabled&&"cursor-pointer"]])},[t.labelPrefixComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelPrefixComponent.component),e.normalizeProps(e.mergeProps({key:0},t.labelPrefixComponent.props)),null,16)):e.createCommentVNode("",!0),e.createElementVNode("div",FV,[e.createElementVNode("div",jV,[e.createVNode(e.unref(Qz),{text:t.label,search:e.unref(tB)(t.search??""),class:e.normalizeClass(["font-semibold",{"text-gray-400":t.disabled}])},null,8,["text","search","class"]),t.labelInlineComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelInlineComponent.component),e.normalizeProps(e.mergeProps({key:0},t.labelInlineComponent.props)),null,16)):e.createCommentVNode("",!0),t.subLabel&&t.condensed?(e.openBlock(),e.createBlock(e.unref(Qz),{key:1,class:"text-xs text-slate-500",text:t.subLabel,search:s.value},null,8,["text","search"])):e.createCommentVNode("",!0)]),t.subLabel&&!t.condensed?(e.openBlock(),e.createBlock(e.unref(Qz),{key:0,class:"text-xs text-slate-500",text:t.subLabel,search:s.value},null,8,["text","search"])):e.createCommentVNode("",!0)]),t.labelSuffixComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelSuffixComponent.component),e.normalizeProps(e.mergeProps({key:1},t.labelSuffixComponent.props)),null,16)):e.createCommentVNode("",!0)],2))],42,DV))}}),GV={class:"flex flex-col rounded-bl rounded-br"},qV={key:0,class:"px-5 py-5 text-sm text-slate-400"},ZV={key:0},WV=["innerHTML"],KV={key:0},JV={class:"mt-1 px-3 py-2 text-sm text-slate-600"},YV={key:2,class:"border-t border-gray-200"},XV=e.defineComponent({__name:"SearchSelectInputOptions",props:{i18n:{},model:{},search:{},multiple:{type:Boolean},condensed:{type:Boolean},hasLargeDropdown:{type:Boolean},addOnly:{type:Boolean},options:{}},emits:["value-changed"],setup(t,{emit:n}){const r=n,o=t,i=e=>r("value-changed",e),a=e.computed(()=>{var e,t;const n=o.search?`<span class="font-bold">"${tB(o.search)}"</span>`:"";return(null==(t=null==(e=o.i18n)?void 0:e.noResults)?void 0:t.call(e,n))??`No matches found for ${n}.`}),l=e.computed(()=>""===o.search),s=e.computed(()=>NS(o.options,"group").reduce((e,t)=>""===t.value?e:{...e,[t.value]:t.group},{}));return(n,r)=>{var c,d;return e.openBlock(),e.createElementBlock("div",GV,[0===t.options.length?(e.openBlock(),e.createElementBlock("div",qV,[l.value?(e.openBlock(),e.createElementBlock("span",ZV,e.toDisplayString((null==(c=o.i18n)?void 0:c.noOptionsAvailable)??"No available options."),1)):(e.openBlock(),e.createElementBlock("span",{key:1,innerHTML:a.value},null,8,WV))])):(e.openBlock(),e.createElementBlock("ul",{key:1,class:e.normalizeClass(["list-none overflow-y-auto text-gray-700",[t.hasLargeDropdown?"max-h-76":"max-h-48"]])},[t.addOnly?(e.openBlock(),e.createElementBlock("div",KV,[e.createElementVNode("p",JV,e.toDisplayString((null==(d=t.i18n)?void 0:d.addOnly)??"You can only select currently unselected options."),1)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,({label:n,subLabel:r,value:o,checked:a,disabled:l,labelInlineComponent:c,labelSuffixComponent:d,labelSrOnly:u,labelPrefixComponent:p,hidden:h,searchValues:m})=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:o},[s.value[o]?(e.openBlock(),e.createBlock(IV,{key:0},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(s.value[o]),1)]),_:2},1024)):e.createCommentVNode("",!0),h?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(UV,{key:1,label:n,"sub-label":r,value:o,checked:a,disabled:l,search:m?"":t.search,multiple:t.multiple,condensed:t.condensed,"label-suffix-component":d,"label-prefix-component":p,"label-inline-component":c,"label-sr-only":u,onValueChanged:i},null,8,["label","sub-label","value","checked","disabled","search","multiple","condensed","label-suffix-component","label-prefix-component","label-inline-component","label-sr-only"]))],64))),128))],2)),n.$slots["list-footer-content"]?(e.openBlock(),e.createElementBlock("div",YV,[e.renderSlot(n.$slots,"list-footer-content")])):e.createCommentVNode("",!0)])}}}),QV=Symbol("search-select-input"),eA={class:"flex flex-col gap-2"},tA=["aria-expanded"],nA={class:"flex items-center gap-2"},rA={key:0},oA={class:"flex items-center gap-2"},iA={key:0,class:"flex flex-wrap gap-2"},aA=["innerHTML"],lA=e.defineComponent({__name:"SearchSelectInput",props:e.mergeModels({addOnly:{type:Boolean,default:!1},disabled:{type:Boolean},i18n:{},label:{},labelScreenReaderOnly:{type:Boolean},singleModelValue:{},multiModelValue:{},options:{default:()=>[]},optionsOrder:{default:()=>["asc","asc"]},optionsOrderProperties:{default:()=>["group","label"]},required:{type:Boolean,default:!1},rootClass:{},size:{default:"md"},withChips:{type:Boolean,default:!1},chipColor:{},error:{},hasReset:{type:Boolean},name:{},hasLargeDropdown:{type:Boolean,default:!1},showSuffixInClosedInput:{type:Boolean},showSuffixLabelInInput:{type:Boolean},condensed:{type:Boolean},form:{}},{search:{default:""},searchModifiers:{}}),emits:e.mergeModels(["update:singleModelValue","update:multiModelValue","blur","change","focus","add-option"],["update:search"]),setup(t,{expose:n,emit:r}){var o;const i=t,a=e.inject(QV),l=null==(o=e.getCurrentInstance())?void 0:o.vnode.props,s=!(null==l?void 0:l["onUpdate:search"]),c=e.computed(()=>Array.isArray(i.multiModelValue)),d=e.ref(i.singleModelValue),u=r,p=ST(i,"singleModelValue",u),h=ST(i,"multiModelValue",u),m=e.ref(h.value??[]);e.watch(()=>i.multiModelValue,e=>{e&&(m.value=e)});const f=e.useModel(t,"search"),g=e.computed({get:()=>c.value?m.value??[]:"string"==typeof p.value?[p.value]:[],set(e){c.value?m.value=e:p.value=(null==e?void 0:e[0])??""}}),v=e.computed(()=>A.value.filter(e=>{var t;return null==(t=g.value)?void 0:t.includes(e.value)})),y=e.computed(()=>v.value[0]),b=gB(),w=e.ref(!1),k=e.ref(),x=e.ref(),_=e.ref(),C=()=>k.value?Array.from(k.value.querySelectorAll('li[tabindex="0"], button:not([disabled])')):[],E=()=>{var e;let t=document.activeElement;for(;null==(e=null==t?void 0:t.shadowRoot)?void 0:e.activeElement;)t=t.shadowRoot.activeElement;return t},S=()=>{if(!x.value)return null;let e=x.value.querySelector("input");if(e)return e;const t=x.value.querySelectorAll("*");for(const n of t)if(n.shadowRoot&&(e=n.shadowRoot.querySelector("input"),e))return e;return null},B=e=>{var t,n;if(!w.value)return;const r=C(),o=S();if(E()===o)switch(e.key){case"ArrowDown":r.length>0&&(e.preventDefault(),null==(t=r[0])||t.focus());break;case"Tab":!e.shiftKey&&r.length>0&&(e.preventDefault(),null==(n=r[0])||n.focus());break;case"Escape":e.preventDefault(),F(),f.value=""}},N=t=>{var n,r,o,i;const a=C(),l=E(),s=a.indexOf(l),c=S();switch(t.key){case"ArrowDown":s<a.length-1&&(t.preventDefault(),null==(n=a[s+1])||n.focus());break;case"ArrowUp":t.preventDefault(),s<=0?null==c||c.focus():null==(r=a[s-1])||r.focus();break;case"Tab":t.shiftKey?s<=0?(t.preventDefault(),null==c||c.focus()):(t.preventDefault(),null==(o=a[s-1])||o.focus()):s>=a.length-1?(t.preventDefault(),F(),f.value="",null==c||c.focus()):(t.preventDefault(),null==(i=a[s+1])||i.focus());break;case"Escape":t.preventDefault(),F(),f.value="",e.nextTick(()=>{null==c||c.focus()})}},{floatingStyles:M}=eV(x,k,{whileElementsMounted:Bm,placement:"bottom",middleware:[Nm(4),Mm({mainAxis:!0})]}),{width:T}=wT(x),V=e=>{var t;return i.disabled||!i.disabled&&i.addOnly&&!!(null==(t=d.value)?void 0:t.includes(e))},A=e.computed(()=>{const e=i.options.map(e=>({...e,checked:g.value.includes(e.value),disabled:e.disabled??V(e.value)})),t=[...e,...0===f.value.length&&D.value?D.value.filter(t=>!e.some(e=>e.value===t.value)):[]];return i.optionsOrderProperties&&!gS(i.optionsOrderProperties)?(n=t,r=i.optionsOrderProperties,o=i.optionsOrder,null==n?[]:(qx(r)||(r=null==r?[]:[r]),qx(o)||(o=null==o?[]:[o]),ES(n,r,o))):t;var n,r,o}),z=e=>A.value.filter(t=>e.some(e=>t.value===e)),O=e.computed(()=>z(g.value)),I=e.computed(()=>O.value[0]),D=e.ref([]),P=({value:e,checked:t})=>{let n;c.value?n=t?[...g.value,e]:g.value.filter(t=>t!==e):(n=[e],w.value=!1,f.value=""),D.value=z(n),g.value=n,u("change")},$=e.computed(()=>g.value.length>0&&!i.disabled&&!(1===g.value.length&&""===g.value[0])),L=()=>{g.value=[],m.value=[]},R=()=>{f.value=""},H=e.computed(()=>s?A.value.filter(e=>{const t=tB(f.value.toLowerCase());return e.searchValues?e.searchValues.some(e=>e.toLowerCase().match(t)):(e.label??"").toLowerCase().match(t)}):A.value),F=()=>{c.value&&(h.value=m.value),w.value=!1};e.watch(m,()=>{w.value||vS(h.value,m.value)||!c.value||(h.value=m.value)});eT("mousedown",e=>{const t=e.composedPath();k.value&&t.includes(k.value)||x.value&&t.includes(x.value)||w.value&&(F(),f.value="")});const j=e.computed(()=>{var e,t,n,r,o,a;return c.value&&w.value?(null==(e=i.i18n)?void 0:e.placeholderSearch)??"Search":c.value&&1===O.value.length?null==(t=I.value)?void 0:t.label:c.value&&O.value.length>=2?`${null==(n=I.value)?void 0:n.label} +${O.value.length-1}`:p.value||I.value?w.value?(null==(o=i.i18n)?void 0:o.placeholderSearch)??"Search":i.singleModelValue||I.value?null==(a=A.value.find(e=>{var t;return e.value===(null==(t=y.value)?void 0:t.value)}))?void 0:a.label:"":(null==(r=i.i18n)?void 0:r.placeholderDefault)??"Select an option"}),U=e.computed(()=>""===f.value),G=!!(null==l?void 0:l.onAddOption),q=()=>{u("add-option"),F()},Z=e.computed(()=>{var e;return!w.value&&!c.value&&(null==(e=I.value)?void 0:e.labelPrefixComponent)}),W=`search-select-options-${Math.random().toString(36).substring(2,9)}`;return n({flushMemoryCachedSelectedOptions:()=>D.value=[]}),(n,r)=>{var o,i,l;return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",eA,[e.createElementVNode("div",{ref_key:"wrapperRef",ref:x,class:e.normalizeClass(["relative flex items-end",{[`${t.rootClass}`]:t.rootClass,"z-30":w.value}]),role:"combobox","aria-expanded":w.value,"aria-haspopup":!0,"aria-controls":W,onKeydown:B},[e.createVNode(e.unref(AV),{ref_key:"inputRef",ref:_,modelValue:f.value,"onUpdate:modelValue":r[2]||(r[2]=e=>f.value=e),required:t.required,label:t.label,name:t.name,form:t.form,"label-screen-reader-only":t.labelScreenReaderOnly,placeholder:j.value,class:e.normalizeClass(["grow",{"placeholder:text-gray-900":!w.value&&(!c.value&&e.unref(p)||c.value&&!e.unref(gS)(t.multiModelValue))}]),"wrapper-class":{"border-transparent border border-b-gray-200 focus-within:border-b relative z-10 rounded-b-none":w.value},"suffix-class":"border-l-0 pl-0",disabled:t.disabled,size:t.size,error:t.error,"prefix-has-border":!Z.value,"aria-autocomplete":"list",onFocus:r[3]||(r[3]=()=>w.value=!0),onBlur:r[4]||(r[4]=e=>n.$emit("blur"))},e.createSlots({"label-suffix":e.withCtx(()=>[e.renderSlot(n.$slots,"label-suffix")]),suffix:e.withCtx(()=>{var n,o;return[e.createElementVNode("div",oA,[w.value||c.value||!(null==(n=I.value)?void 0:n.labelInlineComponent)||t.showSuffixInClosedInput&&!t.showSuffixLabelInInput?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(I.value.labelInlineComponent.component),e.normalizeProps(e.mergeProps({key:0},I.value.labelInlineComponent.props)),null,16)),!w.value&&!c.value&&(null==(o=I.value)?void 0:o.labelSuffixComponent)&&t.showSuffixInClosedInput?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(I.value.labelSuffixComponent.component),e.normalizeProps(e.mergeProps({key:1},I.value.labelSuffixComponent.props)),null,16)):e.createCommentVNode("",!0),$.value&&t.hasReset?(e.openBlock(),e.createBlock(e.unref(fA),{key:2,icon:"close",size:"sm",variant:"ghost",color:"gray",type:"button",onMousedown:r[0]||(r[0]=e.withModifiers(()=>{},["prevent"])),onClick:L})):e.createCommentVNode("",!0),U.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(fA),{key:3,icon:"close",size:"sm",variant:"ghost",color:"gray",type:"button",onClick:R})),e.createVNode(e.unref(fA),{class:"-mr-3",icon:w.value?"keyboard_arrow_up":"keyboard_arrow_down",size:"sm",variant:"ghost",color:"gray",type:"button",disabled:t.disabled,onClick:r[1]||(r[1]=e=>w.value=!w.value)},null,8,["icon","disabled"])])]}),_:2},[n.$slots.tooltip?{name:"tooltip",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"tooltip")]),key:"0"}:void 0,Z.value||!s?{name:"prefix",fn:e.withCtx(()=>{var t;return[e.createElementVNode("div",nA,[Z.value&&(null==(t=I.value)?void 0:t.labelPrefixComponent)?(e.openBlock(),e.createElementBlock("div",rA,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(I.value.labelPrefixComponent.component),e.normalizeProps(e.guardReactiveProps(I.value.labelPrefixComponent.props)),null,16))])):s?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(hc),{key:1,icon:"search",size:"sm"}))])]}),key:"1"}:void 0,n.$slots.helper?{name:"helper",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"helper")]),key:"2"}:void 0]),1032,["modelValue","required","label","name","form","label-screen-reader-only","placeholder","wrapper-class","class","disabled","size","error","prefix-has-border"])],42,tA),t.withChips?(e.openBlock(),e.createElementBlock("div",iA,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(O.value,({value:n,label:r})=>(e.openBlock(),e.createBlock(e.unref(mc),{key:n,removable:!V(n),color:t.chipColor,onRemoved:e=>P({value:n,checked:!1})},{default:e.withCtx(()=>[e.createElementVNode("span",{innerHTML:r},null,8,aA)]),_:2},1032,["removable","color","onRemoved"]))),128))])):e.createCommentVNode("",!0)]),e.unref(b)&&e.unref(a)?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:e.unref(a)},[w.value&&!t.disabled?(e.openBlock(),e.createElementBlock("div",{key:0,id:W,ref_key:"optionsRef",ref:k,role:"listbox",style:e.normalizeStyle(e.unref(M)),class:"z-70 rounded border border-gray-200 bg-white drop-shadow-md",onMouseenter:r[5]||(r[5]=e=>w.value=!0),onKeydown:N},[e.createElementVNode("div",{class:"rounded pt-0",style:e.normalizeStyle({width:`${e.unref(T)}px`})},[e.createVNode(XV,{i18n:{addOnly:null==(o=t.i18n)?void 0:o.addOnly,noResults:null==(i=t.i18n)?void 0:i.noResults,noOptionsAvailable:null==(l=t.i18n)?void 0:l.noOptionsAvailable},options:H.value,multiple:c.value,search:f.value,model:g.value,"add-only":t.addOnly,"allows-multiple-values":!!c.value,condensed:t.condensed,"has-large-dropdown":t.hasLargeDropdown,onValueChanged:P},{"list-footer-content":e.withCtx(()=>[G?(e.openBlock(),e.createBlock(e.unref(gN),{key:0,variant:"ghost",class:"w-full rounded-t-none",type:"button","icon-prefix":"add",onClick:q},{default:e.withCtx(()=>{var n;return[e.createTextVNode(e.toDisplayString(null==(n=t.i18n)?void 0:n.addOption),1)]}),_:1})):e.createCommentVNode("",!0),c.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["flex items-center justify-between",{"py-2":!n.$slots["list-footer-content"]}])},[$.value?(e.openBlock(),e.createBlock(e.unref(gN),{key:0,type:"button",variant:"ghost",size:"sm",class:"ml-2",onClick:L},{default:e.withCtx(()=>{var n;return[e.createTextVNode(e.toDisplayString((null==(n=t.i18n)?void 0:n.multipleValuesClearButtonText)??"Clear"),1)]}),_:1})):e.createCommentVNode("",!0),e.createElementVNode("div",null,[e.renderSlot(n.$slots,"list-footer-content",{close:F})]),e.createVNode(e.unref(gN),{type:"button",size:"sm",class:"mr-2","data-testid":e.unref("select-search-done-button"),onClick:F},{default:e.withCtx(()=>{var n;return[e.createTextVNode(e.toDisplayString((null==(n=t.i18n)?void 0:n.multipleValuesDoneButtonText)??"Done"),1)]}),_:1},8,["data-testid"])],2)):e.renderSlot(n.$slots,"list-footer-content",{key:2,close:F})]),_:3},8,["i18n","options","multiple","search","model","add-only","allows-multiple-values","condensed","has-large-dropdown"])],4)],36)):e.createCommentVNode("",!0)],8,["to"])):e.createCommentVNode("",!0)],64)}}}),sA=e.defineComponent({__name:"SearchSelectInputTeleportProvider",setup(t){const n=e.ref(null);return e.provide(QV,n),(t,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.renderSlot(t.$slots,"default"),e.createElementVNode("div",{ref_key:"teleportTarget",ref:n,"data-search-select-teleport-target":""},null,512)],64))}}),cA={"w-fit":!0,relative:!0,"inline-flex":!0,"items-center":!0},dA={xl:"w-16 h-8 after:top-0.5 after:left-0.5 after:h-7 after:w-7",lg:"w-14 h-7 after:top-0.5 after:left-0.5 after:h-6 after:w-6",md:"w-11 h-6 after:top-0.5 after:left-0.5 after:h-5 after:w-5",sm:"w-9 h-5 after:top-0.5 after:left-0.5 after:h-4 after:w-4",xs:"w-7 h-4 after:top-0.5 after:left-0.5 after:h-3 after:w-3"},uA={red:"peer-focus:ring-red-300 peer-checked:bg-red-600",green:"peer-focus:ring-green-300 peer-checked:bg-green-600",purple:"peer-focus:ring-purple-300 peer-checked:bg-purple-600",yellow:"peer-focus:ring-yellow-300 peer-checked:bg-yellow-400",teal:"peer-focus:ring-teal-300 peer-checked:bg-teal-600",orange:"peer-focus:ring-orange-300 peer-checked:bg-orange-500"},pA=["disabled"],hA=e.defineComponent({__name:"Toggle",props:{modelValue:{type:Boolean,default:!1},labelPosition:{default:"after"},size:{default:"md"},disabled:{type:Boolean,default:!1},color:{default:""},hasBackground:{type:Boolean,default:!1},noSpacing:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(t,{emit:n}){const r=t,o=n,i=e.computed({get:()=>r.modelValue,set(e){o("update:modelValue",e)}}),{labelClasses:a,toggleSize:l,toggleClasses:s,toggleColor:c,toggleBallClasses:d}=(t=>{const n=e.computed(()=>{var e,n;return{...cA,"cursor-pointer":!(null==(e=t.disabled)?void 0:e.value),"cursor-default":!!(null==(n=t.disabled)?void 0:n.value)}}),r=e.computed(()=>{var e,n;return{'peer-focus:outline-none peer-focus:ring-4 peer-focus:ring-primary-300 rounded-full peer peer-checked:after:translate-x-full peer-checked:after:border-white after:content-[""] after:absolute after:top-0.5 after:left-0.5 after:border-gray-300 after:border after:rounded-full after:transition-all':!0,"bg-gray-200 peer-checked:bg-primary-600 after:bg-white":!(null==(e=t.disabled)?void 0:e.value),"bg-gray-100 peer-checked:bg-primary-200 after:bg-gray-200":null==(n=t.disabled)?void 0:n.value}});return{labelClasses:n,toggleSize:e.computed(()=>dA[t.size.value]),toggleClasses:r,toggleColor:e.computed(()=>uA[t.color.value]),toggleBallClasses:e.computed(()=>"grow text-sm font-medium text-gray-900")}})(e.toRefs(r));return(n,r)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["inline-flex items-center gap-1.5",{"flex-row-reverse":"before"===t.labelPosition,"rounded bg-gray-50 border-l-4 border-gray-200":t.hasBackground,"p-2":!t.noSpacing}]),onClick:r[1]||(r[1]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("div",{class:e.normalizeClass(e.unref(a))},[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":r[0]||(r[0]=e=>i.value=e),disabled:t.disabled,class:"sr-only peer",type:"checkbox"},null,8,pA),[[e.vModelCheckbox,i.value]]),e.createElementVNode("span",{class:e.normalizeClass([e.unref(s),e.unref(l),e.unref(c)])},null,2)],2),n.$slots["inline-label"]?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(e.unref(d))},[e.renderSlot(n.$slots,"inline-label")],2)):e.createCommentVNode("",!0)],2))}}),mA=e.defineComponent({__name:"CountrySelect",props:{label:{},singleModelValue:{},multiModelValue:{},error:{},required:{type:Boolean,default:!0},hasReset:{type:Boolean},disabled:{type:Boolean},form:{}},emits:["update:modelValue","update:singleModelValue"],setup(t,{emit:n}){const r=t,o=ST(r,"singleModelValue"),i=ST(r,"multiModelValue"),a=n;return(n,r)=>(e.openBlock(),e.createBlock(lA,{"multi-model-value":e.unref(i),"onUpdate:multiModelValue":r[0]||(r[0]=t=>e.isRef(i)?i.value=t:null),"single-model-value":e.unref(o),"onUpdate:singleModelValue":[r[1]||(r[1]=t=>e.isRef(o)?o.value=t:null),r[2]||(r[2]=e=>{a("update:modelValue",e)})],"root-class":n.$attrs.class,label:t.label,options:e.unref(_x).map(({key:e,value:t})=>({label:t,value:e})),error:t.error,"has-reset":t.hasReset,disabled:t.disabled,required:t.required,"with-chips":!!t.multiModelValue,form:t.form},{"label-suffix":e.withCtx(()=>[e.renderSlot(n.$slots,"label-suffix")]),_:3},8,["multi-model-value","single-model-value","root-class","label","options","error","has-reset","disabled","required","with-chips","form"]))}});const fA=e.defineComponent({inheritAttrs:!1,__name:"IconButton",props:{tooltip:{},icon:{},type:{},variant:{},color:{},size:{},pill:{type:Boolean},square:{type:Boolean},loading:{type:Boolean},disabled:{type:Boolean},iconPrefix:{},iconSuffix:{},tag:{}},setup(t){const n=t,r=e.useAttrs(),o=(e=>{switch(e){case"sm":return"xs";case"md":default:return"sm";case"lg":return"md"}})(n.size),i=e.computed(()=>xS({...n,...r},"icon","tooltip"));return(n,r)=>t.tooltip?(e.openBlock(),e.createBlock(e.unref(bV),{key:0},{tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[e.createVNode(e.unref(Cz),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.tooltip),1)]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(gN),e.mergeProps(i.value,{square:""}),{default:e.withCtx(()=>[e.createVNode(e.unref(hc),{icon:t.icon,size:e.unref(o)},null,8,["icon","size"])]),_:1},16)]),_:1})):(e.openBlock(),e.createBlock(e.unref(gN),e.mergeProps({key:1},i.value,{square:""}),{default:e.withCtx(()=>[e.createVNode(e.unref(hc),{icon:t.icon,size:e.unref(o)},null,8,["icon","size"])]),_:1},16))}}),gA=e.defineComponent({__name:"DeltaChip",props:{oldValue:{},newValue:{},color:{default:"dark"},content:{},dark:{type:Boolean},removable:{type:Boolean},size:{},textClass:{},tag:{},hasChipBefore:{type:Boolean},hasChipAfter:{type:Boolean}},setup(t){const n=e.createPropsRestProxy(t,["oldValue","newValue","color"]),r=e.computed(()=>{const e=t.newValue-t.oldValue;return`${e>=0?"+":""}${e}`});return(o,i)=>(e.openBlock(),e.createBlock(e.unref(mc),e.mergeProps(n,{color:t.color,class:"pointer-events-none select-none"}),{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value),1)]),_:1},16,["color"]))}}),vA={class:"flex items-center gap-1.5 text-gray-800"},yA=e.defineComponent({__name:"StepInput",props:e.mergeModels({step:{default:1},min:{default:0},max:{},initialValue:{default:1},unitName:{},showDelta:{type:Boolean,default:!1},size:{default:"md"},name:{},required:{type:Boolean},label:{},error:{},disabled:{type:Boolean,default:!1}},{modelValue:{required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(t){const n=t,r=e.useModel(t,"modelValue"),o=e.ref(null),i=e.computed(()=>{if(n.unitName)return n.unitName[1===r.value?"singular":"plural"]}),a=()=>{n.max&&r.value+n.step>n.max||(r.value+=n.step)},l=()=>{r.value-n.step<n.min||(r.value-=n.step)};function s(e){var t;const n=null==(t=o.value)?void 0:t.el;if(!n)return;const i=parseInt(`${e}`);r.value=i,n.innerText=`${i}`,n.focus();const a=document.createRange();a.selectNodeContents(n),a.collapse(!1);const l=window.getSelection();null==l||l.removeAllRanges(),null==l||l.addRange(a)}const c=e=>{const t=e.target;t instanceof HTMLElement&&s(t.innerText)},d=e.computed(()=>!n.disabled&&(!n.max||r.value+n.step<n.max)),u=e.computed(()=>!n.disabled&&r.value-n.step>=n.min);function p(){var e;const t=null==(e=o.value)?void 0:e.el;if(!t)return;t.focus();const n=document.createRange();n.selectNodeContents(t);const r=window.getSelection();null==r||r.removeAllRanges(),null==r||r.addRange(n)}return e.onMounted(()=>{var e;const t=null==(e=o.value)?void 0:e.el;t&&(t.innerText=`${r.value}`)}),e.watch(()=>r.value,e=>{s(e)}),(s,h)=>(e.openBlock(),e.createBlock(AV,{modelValue:r.value,"onUpdate:modelValue":h[0]||(h[0]=e=>r.value=e),type:"number",class:"[appearance:textfield] [&::-webkit-outer-spin-button]:appearance-none [&::-webkit-inner-spin-button]:appearance-none text-transparent","prefix-class":{"!px-0 w-5":"sm"===t.size,"!px-0 w-6":"md"===t.size,"!px-0 w-7":"lg"===t.size},"suffix-class":{"!px-0 w-5":"sm"===t.size,"!px-0 w-6":"md"===t.size,"!px-0 w-7":"lg"===t.size},size:t.size,label:t.label,disabled:t.disabled,name:t.name,required:t.required},e.createSlots({prefix:e.withCtx(()=>[e.createElementVNode("div",{class:"absolute inset-0 flex items-center justify-center",onMousedown:p},[e.createElementVNode("div",vA,[e.createVNode(gc,{ref_key:"contentEditableRef",ref:o,tag:"span",variant:"sm"===t.size?"body":"body-lg",contenteditable:!t.disabled,class:e.normalizeClass(["outline-none",{"pointer-events-none select-none":t.disabled}]),weight:"semibold",onInput:c},null,8,["variant","contenteditable","class"]),i.value?(e.openBlock(),e.createBlock(gc,{key:0,tag:"span",shade:"lighter",class:"pointer-events-none select-none"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(" ")+e.toDisplayString(i.value),1)]),_:1})):e.createCommentVNode("",!0),t.showDelta?(e.openBlock(),e.createBlock(gA,{key:1,"old-value":n.initialValue,"new-value":r.value,class:"ml-0.5 pointer-events-none select-none"},null,8,["old-value","new-value"])):e.createCommentVNode("",!0)])],32),e.createVNode(fA,{disabled:!u.value,type:"button",color:"gray",variant:"ghost",size:"sm",class:e.normalizeClass(["select-none rounded-tr-none rounded-br-none !h-full",{"!w-7":"lg"===t.size,"!w-5":"sm"===t.size,"!w-6":"md"===t.size}]),icon:"remove",onMousedown:l},null,8,["disabled","class"])]),suffix:e.withCtx(()=>[e.createVNode(fA,{disabled:!d.value,type:"button",color:"gray",variant:"ghost",size:"sm",class:e.normalizeClass(["select-none rounded-tl-none rounded-bl-none !h-full",{"!w-7":"lg"===t.size,"!w-5":"sm"===t.size,"!w-6":"md"===t.size}]),icon:"add",onMousedown:a},null,8,["disabled","class"])]),_:2},[s.$slots.helper?{name:"helper",fn:e.withCtx(()=>[e.renderSlot(s.$slots,"helper")]),key:"0"}:void 0]),1032,["modelValue","prefix-class","suffix-class","size","label","disabled","name","required"]))}}),bA=["disabled"],wA=["aria-label"],kA=["id","disabled","value","aria-checked","aria-describedby"],xA=["tabindex","data-testid","for","aria-label","onKeydown"],_A={class:"text-xs"},CA={key:1,class:"mt-2 text-sm text-gray-500"},EA=e.defineComponent({__name:"RadioGroupExtended",props:{options:{},direction:{default:"row"},showRadio:{type:Boolean,default:!0},disabled:{type:Boolean},label:{},modelValue:{type:[String,Boolean]},name:{},required:{type:Boolean},rootClass:{},error:{},variant:{}},emits:["update:modelValue"],setup(t,{emit:n}){const r=t,o=ST(r,"modelValue",n),i=TS(r.name?`radio_${r.name}_`:"radio_");return(n,a)=>(e.openBlock(),e.createElementBlock("fieldset",{class:e.normalizeClass(t.rootClass),disabled:t.disabled},[t.label?(e.openBlock(),e.createBlock(e.unref(_V),{key:0,tag:"legend",required:t.required},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.label),1)]),_:1},8,["required"])):e.createCommentVNode("",!0),e.createElementVNode("div",{role:"group","aria-label":t.label,class:e.normalizeClass([["column"===t.direction?"flex-col":"flex-row"],"rounded flex gap-1"])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,l=>(e.openBlock(),e.createElementBlock("div",{key:l.value.toString(),class:"flex-1"},[e.withDirectives(e.createElementVNode("input",e.mergeProps({ref_for:!0},n.$attrs,{id:`${e.unref(i)}${l.value}`,"onUpdate:modelValue":a[0]||(a[0]=t=>e.isRef(o)?o.value=t:null),disabled:t.disabled,value:l.value,type:"radio","aria-checked":e.unref(o)===l.value,"aria-describedby":l.warning?`${e.unref(i)}${l.value}-warning`:void 0,tabindex:"-1",class:"sr-only"}),null,16,kA),[[e.vModelRadio,e.unref(o)]]),e.createElementVNode("label",{tabindex:t.disabled?void 0:0,"data-testid":`radio-group-item-${l.value}`,for:`${e.unref(i)}${l.value}`,"aria-label":l.label+(l.description?`: ${l.description}`:""),class:e.normalizeClass(["relative label px-4 py-3 h-full flex gap-3 border bg-gray-50/50 border-gray-100 rounded outline-none hover:bg-primary-50/50 focus-visible:bg-primary-50 focus-visible:border-primary-600 focus-visible:ring-1 focus-visible:ring-primary-600 focus:bg-primary-50",{"cursor-pointer":!t.disabled,"cursor-not-allowed":t.disabled,"bg-white border border-primary-600 ring-1 ring-primary-600":e.unref(o)===l.value&&!t.disabled,"opacity-60":t.disabled}]),onKeydown:e=>{return t=e,n=l.value,void(r.disabled||"Enter"!==t.key&&" "!==t.key||(t.preventDefault(),t.stopPropagation(),o.value=n));var t,n}},[t.showRadio?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["material-symbols-outlined leading-4 h-4 w-4 min-w-4 inline-block mt-px rounded-full",{"border-4 border-primary-800":e.unref(o)===l.value,"border border-gray-300":e.unref(o)!==l.value}])},null,2)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["flex flex-col",{"opacity-50":t.disabled}])},[e.createVNode(e.unref(gc),{tag:"div",weight:"semibold","no-spacing":"",variant:"body-sm",class:"flex justify-between align-center"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(l.label),1)]),_:2},1024),l.description?(e.openBlock(),e.createBlock(e.unref(gc),{key:0,tag:"div",variant:"body-xs","no-spacing":"",shade:"lighter"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(l.description),1)]),_:2},1024)):e.createCommentVNode("",!0),l.description?e.createCommentVNode("",!0):e.renderSlot(n.$slots,"description",{key:1,optionValue:l.value})],2)],42,xA),l.warning?(e.openBlock(),e.createBlock(e.unref(JB),{key:0,id:`${e.unref(i)}${l.value}-warning`,class:"mt-1",type:e.unref(o)===l.value?"danger":"dark",role:"alert"},{default:e.withCtx(()=>[e.createElementVNode("span",_A,e.toDisplayString(l.warning),1)]),_:2},1032,["id","type"])):e.createCommentVNode("",!0)]))),128))],10,wA),t.error||n.$slots.helper?(e.openBlock(),e.createElementBlock("div",CA,[t.error?(e.openBlock(),e.createBlock(e.unref(CV),{key:0,message:t.error},null,8,["message"])):n.$slots.helper?e.renderSlot(n.$slots,"helper",{key:1}):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],10,bA))}}),SA={class:"flex items-center pt-1"},BA={class:"px-1.5 text-gray-500 text-xs font-semibold"};const NA=fB({},[["render",function(t,n){return e.openBlock(),e.createElementBlock("div",SA,[n[0]||(n[0]=e.createElementVNode("div",{class:"border-t w-2"},null,-1)),e.createElementVNode("span",BA,[e.renderSlot(t.$slots,"default")]),n[1]||(n[1]=e.createElementVNode("div",{class:"border-t grow"},null,-1))])}]]),MA=["aria-selected","aria-disabled","data-testid"],TA=["id","value","checked","disabled"],VA=["for"],AA={class:"flex items-center gap-1"},zA={class:"flex flex-grow flex-col"},OA={class:"flex flex-grow gap-2"},IA={class:"flex flex-grow flex-col"},DA={class:"flex flex-grow items-start justify-between gap-2"},PA={class:"flex items-center gap-2"},$A=e.defineComponent({__name:"SelectExtendedOption",props:{multiple:{type:Boolean},inputValue:{},condensed:{type:Boolean},label:{},checked:{type:Boolean},disabled:{type:Boolean},subLabel:{},labelPrefixComponent:{},labelSuffixComponent:{},labelInlineComponent:{},value:{},labelSrOnly:{type:Boolean}},emits:["value-changed"],setup(t,{emit:n}){const r=n,o=t,i=e=>{const t=e.target;r("value-changed",{value:t.value,checked:t.checked})},a=()=>{o.multiple||o.disabled||r("value-changed",{value:o.value})},l=e.computed(()=>(e=>`checkbox-item-${e}`)(o.value)),s=e.computed(()=>tB(o.inputValue??""));return(n,r)=>(e.openBlock(),e.createElementBlock("li",{role:"option","aria-selected":t.checked,"aria-disabled":t.disabled,class:e.normalizeClass([{"hover:bg-gray-50":!t.disabled},"flex relative"]),"data-testid":l.value,tabindex:"0",onClick:a,onKeydown:e.withKeys(a,["enter"])},[t.multiple?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("input",e.mergeProps(n.$attrs,{id:l.value,ref:"inputRef",value:t.value,checked:t.checked,disabled:t.disabled,type:"checkbox",class:["absolute top-[50%] -translate-y-2 left-3.5 w-4 h-4 bg-gray-100 border-gray-300 rounded focus:ring-primary-500 focus:ring-2",t.disabled?"text-gray-400 placeholder-gray-500":"text-primary-600"],tabindex:"-1",onChange:i}),null,16,TA),e.createElementVNode("label",{for:l.value,class:e.normalizeClass([t.disabled?"text-gray-400":"text-gray-900 rounded","w-full px-4 py-3 pl-10 text-sm font-medium"])},[e.createElementVNode("div",AA,[t.labelPrefixComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelPrefixComponent.component),{key:0})):e.createCommentVNode("",!0),e.createElementVNode("div",zA,[e.createElementVNode("div",OA,[e.createVNode(e.unref(Qz),{text:t.label,search:s.value,class:e.normalizeClass(["font-semibold",{"sr-only":t.labelSrOnly}])},null,8,["text","search","class"]),t.labelInlineComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelInlineComponent.component),e.normalizeProps(e.mergeProps({key:0},t.labelInlineComponent.props)),null,16)):e.createCommentVNode("",!0),t.subLabel&&t.condensed?(e.openBlock(),e.createBlock(e.unref(Qz),{key:1,class:"text-xs text-slate-500",text:t.subLabel,search:s.value},null,8,["text","search"])):e.createCommentVNode("",!0)]),t.subLabel&&!t.condensed?(e.openBlock(),e.createBlock(e.unref(Qz),{key:0,class:"text-xs text-slate-500",text:t.subLabel,search:s.value},null,8,["text","search"])):e.createCommentVNode("",!0)]),t.labelSuffixComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelSuffixComponent.component),e.normalizeProps(e.mergeProps({key:1},t.labelSuffixComponent.props)),null,16)):e.createCommentVNode("",!0)])],10,VA)],64)):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["w-full px-4 text-sm font-medium flex items-start gap-3",[t.condensed?"p-2":"py-3",t.disabled??"cursor-not-allowed",!t.disabled&&"cursor-pointer"]])},[t.labelPrefixComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelPrefixComponent.component),e.normalizeProps(e.mergeProps({key:0},t.labelPrefixComponent.props)),null,16)):e.createCommentVNode("",!0),e.createElementVNode("div",IA,[e.createElementVNode("div",DA,[e.createVNode(e.unref(Qz),{text:t.label,search:s.value,class:e.normalizeClass(["font-semibold",{"text-gray-400":t.disabled}])},null,8,["text","search","class"]),e.createElementVNode("div",PA,[t.labelInlineComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelInlineComponent.component),e.normalizeProps(e.mergeProps({key:0},t.labelInlineComponent.props)),null,16)):e.createCommentVNode("",!0),t.labelSuffixComponent?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.labelSuffixComponent.component),e.normalizeProps(e.mergeProps({key:1},t.labelSuffixComponent.props)),null,16)):e.createCommentVNode("",!0)])]),t.subLabel&&t.condensed?(e.openBlock(),e.createBlock(e.unref(Qz),{key:0,class:"text-xs text-slate-500",text:t.subLabel,search:s.value},null,8,["text","search"])):e.createCommentVNode("",!0),t.subLabel&&!t.condensed?(e.openBlock(),e.createBlock(e.unref(Qz),{key:1,class:"text-xs text-slate-500",text:t.subLabel,search:s.value},null,8,["text","search"])):e.createCommentVNode("",!0)])],2))],42,MA))}}),LA={class:"flex flex-col rounded-bl rounded-br"},RA={key:0},HA={key:2,class:"border-t border-gray-200"},FA=e.defineComponent({__name:"SelectExtendedOptions",props:{model:{},multiple:{type:Boolean},condensed:{type:Boolean},hasLargeDropdown:{type:Boolean},inputValue:{},addOnly:{type:Boolean},options:{}},emits:["value-changed"],setup(t,{emit:n}){const r=t,o=n,i=e=>o("value-changed",e),a=e.computed(()=>NS(r.options,"group").reduce((e,t)=>""===t.value?e:{...e,[t.value]:t.group},{})),l=e.computed(()=>0===r.options.length);return(n,r)=>(e.openBlock(),e.createElementBlock("div",LA,[l.value?(e.openBlock(),e.createBlock(e.unref(gc),{key:0,tag:"div","no-spacing":"",variant:"body-sm",shade:"lighter",class:"px-5 py-5"},{default:e.withCtx(()=>[...r[0]||(r[0]=[e.createTextVNode("No results",-1)])]),_:1})):(e.openBlock(),e.createElementBlock("ul",{key:1,class:e.normalizeClass(["list-none overflow-y-auto text-gray-700",[t.hasLargeDropdown?"max-h-76":"max-h-48"]])},[t.addOnly?(e.openBlock(),e.createElementBlock("div",RA,[e.createVNode(e.unref(gc),{tag:"p","no-spacing":"",variant:"body-sm",shade:"lighter",class:"px-3 py-2 mt-1"},{default:e.withCtx(()=>[...r[1]||(r[1]=[e.createTextVNode(e.toDisplayString("You can only select currently unselected options."),-1)])]),_:1})])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,({label:n,subLabel:r,value:o,checked:l,disabled:s,labelInlineComponent:c,labelSuffixComponent:d,labelSrOnly:u,labelPrefixComponent:p,hidden:h})=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:o},[a.value[o]?(e.openBlock(),e.createBlock(NA,{key:0},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.value[o]),1)]),_:2},1024)):e.createCommentVNode("",!0),h?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock($A,{key:1,label:n,"sub-label":r,value:o,checked:l,disabled:s,multiple:t.multiple,condensed:t.condensed,"label-suffix-component":d,"label-prefix-component":p,"label-inline-component":c,"label-sr-only":u,"input-value":t.inputValue,onValueChanged:i},null,8,["label","sub-label","value","checked","disabled","multiple","condensed","label-suffix-component","label-prefix-component","label-inline-component","label-sr-only","input-value"]))],64))),128))],2)),n.$slots["list-footer-content"]?(e.openBlock(),e.createElementBlock("div",HA,[e.renderSlot(n.$slots,"list-footer-content")])):e.createCommentVNode("",!0)]))}}),jA=["aria-expanded","aria-controls"],UA={class:"flex gap-2 items-center"},GA={key:1},qA={class:"flex items-center gap-2"},ZA={key:0,class:"flex flex-wrap gap-2 mt-2"},WA=["innerHTML"],KA=["id"],JA=e.defineComponent({__name:"SelectExtended",props:{addOnly:{type:Boolean,default:!1},disabled:{type:Boolean},label:{},labelScreenReaderOnly:{type:Boolean},inputModel:{},singleModelValue:{},multiModelValue:{},options:{default:()=>[]},optionsOrder:{default:()=>["asc","asc"]},optionsOrderProperties:{default:()=>["group","label"]},required:{type:Boolean,default:!1},rootClass:{},size:{default:"md"},withChips:{type:Boolean,default:!1},chipColor:{},error:{},hasReset:{type:Boolean},name:{},hasLargeDropdown:{type:Boolean,default:!1},showSuffixInClosedInput:{type:Boolean},showSuffixLabelInInput:{type:Boolean},showSubLabelInInput:{type:Boolean,default:!1},condensed:{type:Boolean},form:{},isInputReadOnly:{type:Boolean,default:!0},textContent:{default:()=>({placeholderSingleOpen:"Search",placeholderSingleEmpty:"Select an option",placeholderMultipleOpen:"Search",placeholderMultipleEmpty:"Select one or more options",buttonAddLabel:"Add",buttonClearLabel:"Reset",buttonDoneLabel:"Done"})}},emits:["update:inputModel","update:singleModelValue","update:multiModelValue","blur","change","focus","add-option"],setup(t,{emit:n}){var r;const o=t,i=n,a=null==(r=e.getCurrentInstance())?void 0:r.vnode.props,l=ST(o,"inputModel",i),s=ST(o,"singleModelValue",i),c=ST(o,"multiModelValue",i),d=e.computed(()=>p.value?c.value??[]:s.value?[s.value]:[]),u=e.ref(o.multiModelValue??[]),p=e.computed(()=>Array.isArray(o.multiModelValue)),h=e.computed({get:()=>p.value?u.value??[]:"string"==typeof s.value?[s.value]:[],set(e){p.value?u.value=e:s.value=(null==e?void 0:e[0])??""}}),m=e.ref(!1),f=gB(),g=e.ref(),v=e.ref(),y=e.inject(QV),b=e.computed(()=>{return e=h.value,o.options.filter(t=>e.some(e=>t.value===e));var e}),w=e.computed(()=>b.value[0]),k=e.computed(()=>R.value[0]),x=e.computed(()=>{var e;return!m.value&&!p.value&&(null==(e=w.value)?void 0:e.labelPrefixComponent)}),_=!!(null==a?void 0:a.onAddOption),C=()=>{i("add-option"),S()},E=e.computed(()=>{var e,t,n,r;if(!p.value){if(w.value)return null==(e=w.value)?void 0:e.label;if(0===b.value.length)return o.textContent.placeholderSingleEmpty}if(p.value){if(1===b.value.length)return null==(t=w.value)?void 0:t.label;if(b.value.length>=2)return`${null==(n=w.value)?void 0:n.label} +${b.value.length-1}`;if(0===b.value.length)return o.textContent.placeholderMultipleEmpty}return null==(r=k.value)?void 0:r.label}),S=()=>{p.value,m.value=!1},B=({value:e,checked:t})=>{let n;p.value?n=t?[...h.value,e]:h.value.filter(t=>t!==e):(n=[e],m.value=!1),h.value=n,i("change")},N=e.computed(()=>!(!o.addOnly||vS(u.value,o.multiModelValue))||!o.addOnly&&h.value.length>0&&!o.disabled&&(1!==h.value.length||""!==h.value[0])),M=()=>{if(o.addOnly)return u.value=d.value,l.value="",void S();h.value=[],u.value=[],l.value&&(l.value=""),S()},T=()=>g.value?Array.from(g.value.querySelectorAll('li[tabindex="0"], button:not([disabled])')):[],V=()=>{var e;let t=document.activeElement;for(;null==(e=null==t?void 0:t.shadowRoot)?void 0:e.activeElement;)t=t.shadowRoot.activeElement;return t},A=()=>{if(!v.value)return null;let e=v.value.querySelector("input");if(e)return e;const t=v.value.querySelectorAll("*");for(const n of t)if(n.shadowRoot&&(e=n.shadowRoot.querySelector("input"),e))return e;return null},z=e=>{var t,n;if(!m.value)return;const r=T(),o=A();if(V()===o)switch(e.key){case"ArrowDown":r.length>0&&(e.preventDefault(),null==(t=r[0])||t.focus());break;case"Tab":!e.shiftKey&&r.length>0&&(e.preventDefault(),null==(n=r[0])||n.focus());break;case"Escape":e.preventDefault(),S()}},O=t=>{var n,r,o,i;const a=T(),l=V(),s=a.indexOf(l),c=A();switch(t.key){case"ArrowDown":s<a.length-1&&(t.preventDefault(),null==(n=a[s+1])||n.focus());break;case"ArrowUp":t.preventDefault(),s<=0?null==c||c.focus():null==(r=a[s-1])||r.focus();break;case"Tab":t.shiftKey?s<=0?(t.preventDefault(),null==c||c.focus()):(t.preventDefault(),null==(o=a[s-1])||o.focus()):s>=a.length-1?(t.preventDefault(),S(),null==c||c.focus()):(t.preventDefault(),null==(i=a[s+1])||i.focus());break;case"Escape":t.preventDefault(),S(),e.nextTick(()=>{null==c||c.focus()})}};eT("mousedown",e=>{const t=e.composedPath();g.value&&t.includes(g.value)||v.value&&t.includes(v.value)||m.value&&S()});const{floatingStyles:I}=eV(v,g,{whileElementsMounted:Bm,placement:"bottom",middleware:[Nm(4),Mm({mainAxis:!0})]}),D=TS("search-select-options-"),{width:P}=wT(v),$=()=>{const e=A();e&&e.focus()},L=e.computed(()=>o.options.map(e=>({...e,checked:b.value.some(t=>t.value===e.value),disabled:o.disabled||!o.disabled&&o.addOnly&&!!d.value.includes(e.value)}))),R=e.computed(()=>L.value.filter(e=>{var t;return null==(t=h.value)?void 0:t.includes(e.value)}));return(n,r)=>{var o;return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",{ref_key:"wrapperRef",ref:v,class:e.normalizeClass(["relative flex items-end",{rootClass:t.rootClass,"z-30":m.value,"cursor-text":!t.disabled}]),role:"combobox","aria-expanded":m.value,"aria-haspopup":!0,"aria-controls":e.unref(D),onKeydown:z,onClick:$},[e.createVNode(e.unref(AV),{modelValue:e.unref(l),"onUpdate:modelValue":r[0]||(r[0]=t=>e.isRef(l)?l.value=t:null),readonly:t.isInputReadOnly,required:t.required,label:t.label,name:t.name,form:t.form,"label-screen-reader-only":t.labelScreenReaderOnly,placeholder:E.value,class:e.normalizeClass(["grow !outline-none",{"placeholder:text-gray-900":!m.value&&(!p.value&&e.unref(s)||p.value&&!e.unref(gS)(t.multiModelValue)),"cursor-default":t.isInputReadOnly}]),"wrapper-class":{"border-transparent border-b-gray-200 focus-within:border-b relative z-10":m.value},"suffix-class":"border-l-0 pl-0",disabled:t.disabled,size:t.size,error:t.error,"prefix-has-border":!1,"aria-autocomplete":"list",onFocus:r[1]||(r[1]=()=>m.value=!0),onBlur:r[2]||(r[2]=e=>n.$emit("blur"))},e.createSlots({"label-suffix":e.withCtx(()=>[e.renderSlot(n.$slots,"label-suffix")]),suffix:e.withCtx(()=>{var n,r;return[e.createElementVNode("div",qA,[m.value||p.value||!(null==(n=w.value)?void 0:n.labelInlineComponent)||t.showSuffixInClosedInput&&!t.showSuffixLabelInInput?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(w.value.labelInlineComponent.component),e.normalizeProps(e.mergeProps({key:0},w.value.labelInlineComponent.props)),null,16)),!m.value&&!p.value&&(null==(r=w.value)?void 0:r.labelSuffixComponent)&&t.showSuffixInClosedInput?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(w.value.labelSuffixComponent.component),e.normalizeProps(e.mergeProps({key:1},w.value.labelSuffixComponent.props)),null,16)):e.createCommentVNode("",!0),e.unref(l)||N.value&&t.hasReset?(e.openBlock(),e.createBlock(e.unref(fA),{key:2,icon:"close",size:"xs",variant:"ghost",color:"gray",type:"button",onClick:M})):e.createCommentVNode("",!0),e.createVNode(e.unref(hc),{icon:"keyboard_arrow_down",size:"xs",class:e.normalizeClass(["transition-transform",{"rotate-180":m.value}])},null,8,["class"])])]}),_:2},[t.showSubLabelInInput&&(null==(o=w.value)?void 0:o.subLabel)?{name:"input",fn:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(["pointer-events-none absolute inset-0 bg-white",{"px-4 py-3":"xl"===t.size}])},[e.createVNode(e.unref(gc),{tag:"span",class:"block",variant:"body-sm",weight:"semibold"},{default:e.withCtx(()=>{var t;return[e.createTextVNode(e.toDisplayString(null==(t=w.value)?void 0:t.label),1)]}),_:1}),e.createVNode(e.unref(gc),{tag:"span",class:"block",variant:"body-xs",shade:"lighter"},{default:e.withCtx(()=>{var t;return[e.createTextVNode(e.toDisplayString(null==(t=w.value)?void 0:t.subLabel),1)]}),_:1})],2)]),key:"0"}:void 0,n.$slots.tooltip?{name:"tooltip",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"tooltip")]),key:"1"}:void 0,x.value||n.$slots.prefix?{name:"prefix",fn:e.withCtx(()=>{var t;return[e.createElementVNode("div",UA,[n.$slots.prefix?e.renderSlot(n.$slots,"prefix",{key:0}):x.value&&(null==(t=w.value)?void 0:t.labelPrefixComponent)?(e.openBlock(),e.createElementBlock("div",GA,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(w.value.labelPrefixComponent.component),e.normalizeProps(e.guardReactiveProps(w.value.labelPrefixComponent.props)),null,16))])):e.createCommentVNode("",!0)])]}),key:"2"}:void 0,n.$slots.helper?{name:"helper",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"helper")]),key:"3"}:void 0]),1032,["modelValue","readonly","required","label","name","form","label-screen-reader-only","placeholder","wrapper-class","class","disabled","size","error"])],42,jA),t.withChips?(e.openBlock(),e.createElementBlock("div",ZA,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(R.value,({value:n,label:r,disabled:o})=>(e.openBlock(),e.createBlock(e.unref(mc),{key:n,removable:!o,color:o?"dark":t.chipColor,onRemoved:e=>B({value:n,checked:!1})},{default:e.withCtx(()=>[e.createElementVNode("span",{innerHTML:r},null,8,WA)]),_:2},1032,["removable","color","onRemoved"]))),128))])):e.createCommentVNode("",!0),e.unref(f)&&e.unref(y)?(e.openBlock(),e.createBlock(e.Teleport,{key:1,to:e.unref(y)},[m.value&&!t.disabled?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(D),ref_key:"optionsRef",ref:g,role:"listbox",style:e.normalizeStyle(e.unref(I)),class:"drop-shadow-md bg-white rounded z-70",onMouseenter:r[3]||(r[3]=e=>m.value=!0),onKeydown:O},[e.createElementVNode("div",{class:"rounded pt-0",style:e.normalizeStyle({width:`${e.unref(P)}px`})},[e.createVNode(FA,{options:L.value,multiple:p.value,model:h.value,"add-only":t.addOnly,"allows-multiple-values":!!p.value,condensed:t.condensed,"has-large-dropdown":t.hasLargeDropdown,"input-value":e.unref(l),onValueChanged:B},{"list-footer-content":e.withCtx(()=>[_?(e.openBlock(),e.createBlock(e.unref(gN),{key:0,variant:"ghost",class:"w-full",type:"button","icon-prefix":"add",onClick:C},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.textContent.buttonAddLabel),1)]),_:1})):e.createCommentVNode("",!0),p.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["flex justify-between items-center",{"py-2":!n.$slots["list-footer-content"]}])},[N.value?(e.openBlock(),e.createBlock(e.unref(gN),{key:0,type:"button",color:"gray",variant:"ghost",size:"sm",class:"ml-2",onClick:M},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.textContent.buttonClearLabel),1)]),_:1})):e.createCommentVNode("",!0),e.createElementVNode("div",null,[e.renderSlot(n.$slots,"list-footer-content")]),e.createVNode(e.unref(gN),{type:"button",size:"sm",class:"mr-2","data-testid":e.unref("select-search-done-button"),onClick:S},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.textContent.buttonDoneLabel),1)]),_:1},8,["data-testid"])],2)):e.renderSlot(n.$slots,"list-footer-content",{key:2})]),_:3},8,["options","multiple","model","add-only","allows-multiple-values","condensed","has-large-dropdown","input-value"])],4)],44,KA)):e.createCommentVNode("",!0)],8,["to"])):e.createCommentVNode("",!0)],64)}}}),YA={sm:"range-sm",md:"range-md",lg:"range-lg",xl:"range-xl"};const XA=e.defineComponent({__name:"CustomStyles",props:{css:{},marker:{}},setup(t){const n=t,r=e.ref();function o(e){if(!e||!r.value)return;const t=r.value.getRootNode();if(!(t instanceof ShadowRoot))return;if(t.querySelector(`style[${n.marker}]`))return;const o=document.createElement("style");o.setAttribute(n.marker,"true"),o.textContent=e,t.appendChild(o)}return e.onMounted(()=>{n.css&&o(n.css)}),e.watch(()=>n.css,e=>{if(!e||!r.value)return;const t=r.value.getRootNode();if(!(t instanceof ShadowRoot))return;const i=t.querySelector(`style[${n.marker}]`);i?i.textContent=e:o(e)}),(t,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:r},[e.renderSlot(t.$slots,"default")],512))}}),QA=["data-testid"],ez=["step","min","max","name","disabled"],tz={key:0,class:"mt-2 text-sm text-gray-500"},nz=e.defineComponent({__name:"RangeInput",props:e.mergeModels({disabled:{type:Boolean,default:!1},label:{default:void 0},labelAfter:{type:Boolean,default:!1},max:{default:100},min:{default:0},name:{},required:{type:Boolean,default:!1},rootClass:{default:""},size:{default:"md"},steps:{default:1},variant:{default:"default"},error:{},inputWrapperClass:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(t){const n=t,r=e.useModel(t,"modelValue"),o=e.useTemplateRef("inputRef");function i(){const e=o.value;if(!e)return;const t=r.value??n.min,i=(Number(t)-n.min)/(n.max-n.min)*100;e.style.setProperty("--range-percentage",`${i}%`)}const{rangeClasses:a}=function(t){return{rangeClasses:e.computed(()=>`w-full appearance-none cursor-pointer ${YA[t.size.value]}`)}}(e.toRefs(n)),l=e.computed(()=>{switch(n.size){case"xl":return"lg";case"lg":return"md";case"md":return"sm";default:return n.size}}),s=n.name??TS("range-input-"),c=e.computed(()=>null!=r.value&&r.value>n.min?()=>{r.value=(r.value??0)-n.steps}:void 0),d=e.computed(()=>null!=r.value&&r.value<n.max?()=>{r.value=(r.value??0)+n.steps}:void 0),u=e.computed(()=>["stepped","stepped-contained","stepped-ghost"].includes(n.variant)),p=e.computed(()=>"stepped-contained"===n.variant),h=e.computed(()=>p.value||"stepped-ghost"===n.variant?"ghost":"outline");return e.watch([r,o],()=>e.nextTick(i),{immediate:!0}),(n,m)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",e.mergeProps(n.$attrs,{class:["flex flex-col gap-2",{rootClass:t.rootClass,"flex-col-reverse":t.labelAfter}],"data-testid":e.unref(hV)(e.unref(s))}),[t.label?(e.openBlock(),e.createBlock(_V,{key:0,for:e.unref(s),required:t.required},e.createSlots({suffix:e.withCtx(()=>[e.renderSlot(n.$slots,"label-suffix")]),default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.label)+" ",1)]),_:2},[n.$slots.tooltip?{name:"tooltip",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"tooltip")]),key:"0"}:void 0]),1032,["for","required"])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass({flex:u.value,"border rounded bg-white":p.value})},[u.value?(e.openBlock(),e.createBlock(e.unref(fA),{key:0,size:l.value,variant:h.value,icon:"remove",square:"",color:"gray",disabled:!c.value||t.disabled,onMousedown:m[0]||(m[0]=e=>{var t;return null==(t=c.value)?void 0:t.call(c)})},null,8,["size","variant","disabled"])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass([{"flex grow px-3 items-center":u.value,"border-x":p.value},t.inputWrapperClass])},[e.withDirectives(e.createElementVNode("input",{ref_key:"inputRef",ref:o,"onUpdate:modelValue":m[1]||(m[1]=e=>r.value=e),step:t.steps,min:t.min,max:t.max,name:e.unref(s),disabled:t.disabled,type:"range",class:e.normalizeClass(e.unref(a)),onInput:i},null,42,ez),[[e.vModelText,r.value]])],2),u.value?(e.openBlock(),e.createBlock(e.unref(fA),{key:1,size:l.value,variant:h.value,icon:"add",square:"",color:"gray",disabled:!d.value||t.disabled,onMousedown:m[2]||(m[2]=e=>{var t;return null==(t=d.value)?void 0:t.call(d)})},null,8,["size","variant","disabled"])):e.createCommentVNode("",!0)],2)],16,QA),e.createVNode(XA,{marker:"range-input-styles",css:e.unref("/* Base - transparent background so track styles show through */\ninput[type='range'] {\n -webkit-appearance: none;\n -moz-appearance: none;\n appearance: none;\n width: 100%;\n background: transparent;\n margin: 0.5rem 0;\n}\n\n/* Thumb - white with explicit border (required for Firefox) */\ninput[type='range']::-webkit-slider-thumb {\n -webkit-appearance: none;\n appearance: none;\n width: 1rem;\n height: 1rem;\n border: 2px solid rgb(229 231 235);\n border-radius: 50%;\n background: #ffffff;\n box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.3);\n cursor: pointer;\n transition: all 0.1s ease-in-out;\n}\n\ninput[type='range']:disabled::-webkit-slider-thumb {\n cursor: not-allowed;\n}\n\ninput[type='range']::-moz-range-thumb {\n -moz-appearance: none;\n appearance: none;\n width: 1rem;\n height: 1rem;\n border: 2px solid rgb(229 231 235);\n border-radius: 50%;\n background: #ffffff;\n box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.3);\n cursor: pointer;\n transition: all 0.1s ease-in-out;\n}\n\ninput[type='range']:disabled::-moz-range-thumb {\n cursor: not-allowed;\n}\n\ninput[type='range']:not(:disabled):hover::-webkit-slider-thumb {\n box-shadow: 0 0 0 6px color-mix(in srgb, var(--color-primary-200) 50%, transparent);\n}\n\ninput[type='range']:not(:disabled):hover::-moz-range-thumb {\n box-shadow: 0 0 0 6px color-mix(in srgb, var(--color-primary-200) 50%, transparent);\n}\n\ninput[type='range']:not(:disabled):active::-webkit-slider-thumb {\n box-shadow: 0 0 0 8px color-mix(in srgb, var(--color-primary-200) 50%, transparent);\n}\n\ninput[type='range']:not(:disabled):active::-moz-range-thumb {\n box-shadow: 0 0 0 8px color-mix(in srgb, var(--color-primary-200) 50%, transparent);\n}\n\n/* Track - WebKit */\ninput[type='range']::-webkit-slider-runnable-track {\n width: 100%;\n height: 0.5rem;\n cursor: pointer;\n background: linear-gradient(\n to right,\n var(--color-primary-600) var(--range-percentage, 0%),\n #e0e5eb var(--range-percentage, 0%)\n );\n border-radius: 0.25rem;\n}\n\ninput[type='range']:disabled::-webkit-slider-runnable-track {\n background: #e0e5eb;\n cursor: not-allowed;\n}\n\n/* Track - Mozilla */\ninput[type='range']::-moz-range-track {\n width: 100%;\n height: 0.5rem;\n cursor: pointer;\n background: linear-gradient(\n to right,\n var(--color-primary-600) var(--range-percentage, 0%),\n #e0e5eb var(--range-percentage, 0%)\n );\n border-radius: 0.25rem;\n}\n\ninput[type='range']:disabled::-moz-range-track {\n background: #e0e5eb;\n cursor: not-allowed;\n}\n\n/* Size: sm */\ninput[type='range'].range-sm::-webkit-slider-thumb {\n width: 0.8rem;\n height: 0.8rem;\n margin-top: -0.2rem;\n}\n\ninput[type='range'].range-sm::-moz-range-thumb {\n width: 0.8rem;\n height: 0.8rem;\n}\n\ninput[type='range'].range-sm::-webkit-slider-runnable-track {\n height: 0.4rem;\n border-radius: 0.2rem;\n}\n\ninput[type='range'].range-sm::-moz-range-track {\n height: 0.4rem;\n border-radius: 0.2rem;\n}\n\n/* Size: md */\ninput[type='range'].range-md::-webkit-slider-thumb {\n width: 1rem;\n height: 1rem;\n margin-top: -0.25rem;\n}\n\ninput[type='range'].range-md::-moz-range-thumb {\n width: 1rem;\n height: 1rem;\n}\n\ninput[type='range'].range-md::-webkit-slider-runnable-track {\n height: 0.5rem;\n border-radius: 0.25rem;\n}\n\ninput[type='range'].range-md::-moz-range-track {\n height: 0.5rem;\n border-radius: 0.25rem;\n}\n\n/* Size: lg */\ninput[type='range'].range-lg::-webkit-slider-thumb {\n width: 1.4rem;\n height: 1.4rem;\n margin-top: -0.35rem;\n}\n\ninput[type='range'].range-lg::-moz-range-thumb {\n width: 1.4rem;\n height: 1.4rem;\n}\n\ninput[type='range'].range-lg::-webkit-slider-runnable-track {\n height: 0.7rem;\n border-radius: 0.35rem;\n}\n\ninput[type='range'].range-lg::-moz-range-track {\n height: 0.7rem;\n border-radius: 0.35rem;\n}\n\n/* Size: xl */\ninput[type='range'].range-xl::-webkit-slider-thumb {\n width: 1.8rem;\n height: 1.8rem;\n margin-top: -0.5rem;\n}\n\ninput[type='range'].range-xl::-moz-range-thumb {\n width: 1.8rem;\n height: 1.8rem;\n}\n\ninput[type='range'].range-xl::-webkit-slider-runnable-track {\n height: 0.9rem;\n border-radius: 0.45rem;\n}\n\ninput[type='range'].range-xl::-moz-range-track {\n height: 0.9rem;\n border-radius: 0.45rem;\n}\n")},null,8,["css"]),!e.unref(gS)(t.error)||n.$slots.helper?(e.openBlock(),e.createElementBlock("div",tz,[e.unref(gS)(t.error)?n.$slots.helper?e.renderSlot(n.$slots,"helper",{key:1}):e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(CV,{key:0,message:t.error},null,8,["message"]))])):e.createCommentVNode("",!0)],64))}}),rz=e.defineComponent({__name:"RangeInputExtended",props:e.mergeModels({options:{default:()=>[]},label:{},name:{},required:{type:Boolean,default:!1},rootClass:{},size:{default:"md"},variant:{},error:{},disabled:{type:Boolean},labelAfter:{type:Boolean},inputWrapperClass:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(t){const n=t,r=e.useModel(t,"modelValue"),o=e.computed({get:()=>{const e=r.value?n.options.findIndex(e=>e===r.value):0;return e>=0?e:0},set:e=>(r.value=n.options[e],n.options.findIndex(e=>e===r.value))}),i=e.computed(()=>n.options.length??1);return(n,r)=>(e.openBlock(),e.createBlock(nz,e.mergeProps({modelValue:o.value,"onUpdate:modelValue":r[0]||(r[0]=e=>o.value=e)},n.$attrs,{variant:t.variant,"label-after":t.labelAfter,min:0,max:i.value-1,steps:1,label:t.label,name:t.name,required:t.required,"root-class":t.rootClass,size:t.size,"input-wrapper-class":t.inputWrapperClass}),{"label-suffix":e.withCtx(()=>[e.renderSlot(n.$slots,"label-suffix")]),_:3},16,["modelValue","variant","label-after","max","label","name","required","root-class","size","input-wrapper-class"]))}}),oz=e.defineComponent({__name:"PricingGroupRangeInput",props:e.mergeModels({modelValue:{},options:{},name:{},variant:{default:"stepped-contained"},size:{}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(t){const n=t,r=e.useModel(t,"modelValue"),o=e.computed(()=>{var e;return null==(e=n.options.find(e=>e.value===r.value))?void 0:e.label}),i=e.computed(()=>n.options.map(e=>e.value)),a=e.computed(()=>{var e;return null==(e=n.options.find(e=>e.value===r.value))?void 0:e.description});return(n,l)=>(e.openBlock(),e.createBlock(e.unref(rz),e.mergeProps({modelValue:r.value,"onUpdate:modelValue":l[0]||(l[0]=e=>r.value=e)},n.$attrs,{label:o.value,"label-after":"",variant:t.variant,name:t.name,options:i.value,size:t.size,"input-wrapper-class":"border-l border-r",required:""}),{"label-suffix":e.withCtx(()=>[e.createVNode(e.unref(gc),{tag:"span",variant:"body-xs",shade:"lighter"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.value),1)]),_:1})]),_:1},16,["modelValue","label","variant","name","options","size"]))}}),iz={key:1,class:"flex flex-col items-end gap-1"},az=e.defineComponent({__name:"DownloadButton",props:{downloadService:{type:Function},mobileIconOnly:{type:Boolean,default:!1},type:{},variant:{default:"outline"},color:{default:"gray"},size:{default:"md"},pill:{type:Boolean},square:{type:Boolean},loading:{type:Boolean},disabled:{type:Boolean},iconPrefix:{},iconSuffix:{},tag:{}},setup(t){const{$t:n}=HB(),r=e.createPropsRestProxy(t,["downloadService","size","color","mobileIconOnly","variant"]),o=e.ref(!1),i=e.ref(!1),a=uT(iT).smaller("md"),l=e.computed(()=>t.mobileIconOnly&&a.value),s=async()=>{i.value=!0,o.value=!1;try{await t.downloadService()}catch{o.value=!0}finally{i.value=!1}};return(a,c)=>o.value?(e.openBlock(),e.createElementBlock("div",iz,[o.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(gN),e.mergeProps({key:0},{...r,size:t.size,color:t.color},{disabled:i.value,loading:i.value,type:"button","icon-prefix":"download",onClick:s}),e.createSlots({_:2},[a.$slots.default&&!l.value?{name:"default",fn:e.withCtx(()=>[a.$slots.default?e.renderSlot(a.$slots,"default",{key:0}):e.createCommentVNode("",!0)]),key:"0"}:void 0]),1040,["disabled","loading"])),o.value?(e.openBlock(),e.createBlock(e.unref(CV),{key:1},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n)({id:"download_button.download_failed_message",defaultMessage:"Download failed, please try again later",description:"Error message when a download fails"})),1)]),_:1})):e.createCommentVNode("",!0)])):(e.openBlock(),e.createBlock(e.unref(gN),e.mergeProps({key:0},{...r,size:t.size,color:t.color},{disabled:i.value,loading:i.value,variant:t.variant,type:"button","icon-prefix":"download",onClick:s}),e.createSlots({_:2},[a.$slots.default&&!l.value?{name:"default",fn:e.withCtx(()=>[a.$slots.default?e.renderSlot(a.$slots,"default",{key:0}):e.createCommentVNode("",!0)]),key:"0"}:void 0]),1040,["disabled","loading","variant"]))}}),lz={class:"flex items-start gap-2"},sz=e.defineComponent({__name:"InfoBlock",props:{variant:{default:"default"},hasIcon:{type:Boolean}},setup(t){const n={default:"info",warning:"error",danger:"error"};return(r,o)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["px-4 py-3 rounded border text-sm flex justify-between items-center gap-2",{"bg-blue-50 border-blue-100 text-blue-700":"default"===t.variant,"bg-red-50 border-red-100 text-red-700":"danger"===t.variant,"bg-yellow-50 border-yellow-100 text-yellow-700":"warning"===t.variant}])},[e.createElementVNode("div",lz,[t.hasIcon?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,icon:n[t.variant],size:"xs",class:"shrink-0"},null,8,["icon"])):e.createCommentVNode("",!0),e.createElementVNode("div",null,[e.renderSlot(r.$slots,"default")])]),e.createElementVNode("div",null,[e.renderSlot(r.$slots,"cta")])],2))}}),cz=e.defineComponent({__name:"Link",props:e.mergeDefaults({external:{type:Boolean},showOnHover:{type:Boolean},button:{type:Boolean},to:{},target:{},custom:{type:Boolean},activeClass:{},exactActiveClass:{},ariaCurrentValue:{},viewTransition:{type:Boolean},replace:{type:Boolean},type:{},variant:{},color:{},size:{},pill:{type:Boolean},square:{type:Boolean},loading:{type:Boolean},disabled:{type:Boolean},iconPrefix:{},iconSuffix:{},tag:{}},{external:!1,showOnHover:!1,button:!1,...QB}),setup(t){const n=t,r=e.useAttrs(),o=e.ref(!!r.href),i=e.computed(()=>null===n.target?"_self":"_blank"),a=e.computed(()=>{const e=o.value?{rel:"noopener noreferrer",target:i.value}:{to:n.to,target:n.target||null};return{tag:o.value?"a":"RouterLink",props:{...r,...e}}}),{wrapperClasses:l,spanClasses:s}=cN(e.toRefs(n)),c=e.computed(()=>n.button?`inline-flex text-center hover:no-underline ${l.value} text-sm`:"group hover:text-blue-600 hover:underline "+(n.showOnHover?"hover:text-blue-600":"text-blue-600"));return(r,o)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(a.value.tag),e.mergeProps(a.value.props,{class:c.value}),{default:e.withCtx(()=>[e.createElementVNode("span",{class:e.normalizeClass({[`${e.unref(s)} flex items-center grow`]:n.button})},[e.renderSlot(r.$slots,"default"),t.external&&!t.button?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,icon:"arrow_outward",size:"xs",class:e.normalizeClass(["ml-0.5",{"invisible group-hover:visible":n.showOnHover}])},null,8,["class"])):e.createCommentVNode("",!0)],2)]),_:3},16,["class"]))}}),dz=e.defineComponent({__name:"PageGridAsideCard",props:{title:{},contentSpacing:{}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("div",null,[e.createVNode(e.unref(PM),{spacing:"none",title:t.title},{right:e.withCtx(()=>[e.renderSlot(n.$slots,"settings")]),default:e.withCtx(()=>[e.createVNode(e.unref(FM),{spacing:t.contentSpacing},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},8,["spacing"])]),_:3},8,["title"])]))}),uz={class:"relative"},pz={class:"w-full text-sm text-left text-gray-500"},hz=e.defineComponent({__name:"Table",props:{striped:{type:Boolean},stripeClass:{},hoverable:{type:Boolean},sorting:{},rounded:{type:Boolean},noBorder:{type:Boolean}},emits:["sort"],setup(t,{emit:n}){const r=t,o=n;return e.provide("striped",r.striped),e.provide("stripeClass",r.stripeClass),e.provide("hoverable",r.hoverable),e.provide("sorting",r.sorting),e.provide("emit",o),e.provide("rounded",r.rounded??!1),e.provide("noBorder",r.noBorder??!1),(t,n)=>(e.openBlock(),e.createElementBlock("div",uz,[e.createElementVNode("table",pz,[e.renderSlot(t.$slots,"default")])]))}}),mz={class:"bg-white"};const fz=fB({},[["render",function(t,n){return e.openBlock(),e.createElementBlock("thead",mz,[e.renderSlot(t.$slots,"default")])}]]),gz={class:"bg-white"};const vz=fB({},[["render",function(t,n){return e.openBlock(),e.createElementBlock("tr",gz,[e.renderSlot(t.$slots,"default")])}]]);const yz=fB({},[["render",function(t,n){return e.openBlock(),e.createElementBlock("tbody",null,[e.renderSlot(t.$slots,"default")])}]]),bz={key:0,class:"transition-opacity transition-duration-700 shadow-left absolute z-10 pointer-events-none w-3.5 h-full shadow-none top-0 bg-transparent right-0 translate-x-3.5 bg-gradient-to-r from-black/[.06] to-transparent [.scroll-shadow-left_&]:opacity-100 opacity-0"},wz={key:1,class:"transition-opacity transition-duration-700 shadow-right absolute z-10 pointer-events-none w-3.5 h-full shadow-none top-0 bg-transparent left-0 -translate-x-3.5 bg-gradient-to-l from-black/[.06] to-transparent [.scroll-shadow-right_&]:opacity-100 opacity-0"},kz=e.defineComponent({__name:"TableCellScrollShadow",props:{elRef:{}},setup(t){const n=t,r=e.ref(!1),o=e.ref(!1);return e.onMounted(()=>{var e;if((null==(e=n.elRef)?void 0:e.value)&&n.elRef.value.parentElement){const e=Array.from(n.elRef.value.parentElement.children);r.value=e[0]===n.elRef.value,o.value=e[e.length-1]===n.elRef.value}}),(t,n)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[r.value?(e.openBlock(),e.createElementBlock("div",bz)):e.createCommentVNode("",!0),o.value?(e.openBlock(),e.createElementBlock("div",wz)):e.createCommentVNode("",!0)],64))}}),xz={class:"px-3"};const _z=fB({},[["render",function(t,n){return e.openBlock(),e.createElementBlock("div",xz,[e.renderSlot(t.$slots,"default")])}]]),Cz=e.defineComponent({__name:"TooltipParagraph",setup(t){const n=e.inject(vV);return(t,r)=>(e.openBlock(),e.createBlock(e.unref(gc),{tag:"p",variant:"body-xs",shade:"lighter",class:e.normalizeClass({"!text-gray-200":e.unref(n)})},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default")]),_:3},8,["class"]))}}),Ez=["colspan","tabindex"],Sz=e.defineComponent({__name:"TableHeadCell",props:{colspan:{},columnName:{},sortable:{type:Boolean},hasPadding:{type:Boolean,default:!1},tooltip:{},fixedWidth:{}},emits:["sort"],setup(t,{emit:n}){const r=n,o=e.inject("sorting"),i=t,a=e.ref(),l=e.computed(()=>!(!i.sortable||!o)&&(o.columnName===i.columnName&&(null==o?void 0:o.direction))),s=()=>{i.sortable&&o&&i.columnName&&r("sort",i.columnName)};return(n,r)=>(e.openBlock(),e.createElementBlock("th",{ref_key:"el",ref:a,style:e.normalizeStyle(t.fixedWidth?{"--col-w":`${t.fixedWidth}px`}:void 0),class:e.normalizeClass([[{"cursor-pointer":t.sortable,"first:pl-0":!t.hasPadding},t.fixedWidth?["min-w-[var(--col-w)]"]:null],"relative px-4 py-2 font-medium text-xs whitespace-nowrap select-none"]),colspan:t.colspan,tabindex:t.sortable?0:-1,scope:"col",onClick:s},[a.value?(e.openBlock(),e.createBlock(kz,{key:0,"el-ref":e.toRef(a.value)},null,8,["el-ref"])):e.createCommentVNode("",!0),e.createElementVNode("span",{class:e.normalizeClass({"text-blue-700":l.value})},[e.renderSlot(n.$slots,"default")],2),t.sortable?(e.openBlock(),e.createBlock(hc,{key:1,icon:l.value&&"desc"===l.value?"north":"south",class:e.normalizeClass([{"text-blue-700":l.value},"text-sm"]),size:"2xs"},null,8,["icon","class"])):e.createCommentVNode("",!0),t.tooltip?(e.openBlock(),e.createBlock(bV,{key:2,variant:"outline"},{default:e.withCtx(()=>[e.createVNode(hc,{icon:"help",size:"xs",class:"rounded drop-shadow-sm hover:bg-gray-50 hover:cursor-default -mt-0.5 ml-0.5"})]),tooltip:e.withCtx(()=>[e.createVNode(_z,null,{default:e.withCtx(()=>[e.createVNode(Cz,null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.tooltip),1)]),_:1})]),_:1})]),_:1})):e.createCommentVNode("",!0)],14,Ez))}}),Bz=e.defineComponent({__name:"TableRow",props:{backgroundClass:{}},setup(t){const n=e.useSlots();e.provide("tdLinkSlot",n.link);const r=e.inject("noBorder");return(n,o)=>(e.openBlock(),e.createElementBlock("tr",{class:e.normalizeClass(["group rounded-md",{"bg-white":!t.backgroundClass,"border-y border-gray-200":!e.unref(r)}])},[e.renderSlot(n.$slots,"default")],2))}}),Nz=e.defineComponent({__name:"TableCell",props:{hasPadding:{type:Boolean,default:!1}},setup(t){const n=e.inject("stripeClass")??"group-odd:bg-gray-50",r=e.inject("rounded")??!1,o=e.inject("hoverable"),i=e.inject("striped"),a=e.inject("tdLinkSlot"),l=t,s=e.ref(),c=e.computed(()=>{let e="relative transition ease-in-out px-4 py-3 text-gray-800 first:whitespace-nowrap leading-none";return i&&(e+=` group-even:bg-white ${n}`),r&&(e+=" first-of-type:rounded-l last-of-type:rounded-r overflow-clip"),l.hasPadding||(e+=" first:pl-0"),o&&(e+=" group-hover:bg-gray-50 cursor-pointer"),e});return(t,n)=>(e.openBlock(),e.createElementBlock("td",{ref_key:"el",ref:s,class:e.normalizeClass(c.value)},[s.value?(e.openBlock(),e.createBlock(kz,{key:0,"el-ref":e.toRef(s.value)},null,8,["el-ref"])):e.createCommentVNode("",!0),e.unref(a)?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(a)),{key:1})):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default")],2))}}),Mz={border:e=>e.substring(0,e.lastIndexOf("-"))};function Tz(...e){return e.reduce((e,t)=>{const n=Array.isArray(t)?Array.from(t).map(e=>e.split(" ")).flat():t.split(" "),r=n.map(e=>((e,t=Mz)=>{const n=Object.keys(t).find(t=>e.includes(t));return n?t[n](e):e.substring(0,e.indexOf("-"))})(e)),o=r.filter(t=>!e.types.includes(t)),i=[...r.filter(t=>e.types.includes(t)),...o],a=[...new Set([...e.types,...i])],l=a.map(t=>{if(i.includes(t)){const e=r.indexOf(t);if(e>=0)return n[e]||""}const o=e.types.indexOf(t);return o>=0&&e.classes[o]||""}).filter(e=>!!e);return{types:a,classes:l}},{types:[],classes:[]}).classes.join(" ")}const Vz={danger:"text-red-500 bg-red-100 dark:bg-red-800 dark:text-red-200",empty:"",success:"text-green-500 bg-green-100 dark:bg-green-800 dark:text-green-200",warning:"text-orange-500 bg-orange-100 dark:bg-orange-700 dark:text-orange-200"},Az={center:"items-center",end:"items-end",start:"items-start"},zz="flex w-full max-w-xs p-4 text-gray-500 bg-white rounded-lg shadow dark:text-gray-400 dark:bg-gray-800",Oz="text-sm font-normal";const Iz={blue:{background:"bg-blue-700",disabled:"",hover:"hover:bg-blue-800",text:"text-blue-600",border:"border-blue-600",focus:"focus:ring-blue-300"},green:{background:"bg-green-700",disabled:"",hover:"hover:bg-green-800",text:"text-green-600",border:"border-green-600",focus:"focus:ring-green-300"},pink:{background:"bg-pink-700",disabled:"",hover:"hover:bg-pink-800",text:"text-pink-600",border:"border-pink-600",focus:"focus:ring-pink-300"},purple:{background:"bg-purple-700",disabled:"",hover:"hover:bg-purple-800",text:"text-purple-600",border:"border-purple-600",focus:"focus:ring-purple-300"},red:{background:"bg-red-700",disabled:"",hover:"hover:bg-red-800",text:"text-red-600",border:"border-red-600",focus:"focus:ring-red-300"}};function Dz(t){var n;const{textClasses:r,borderClasses:o,backgroundClasses:i,hoverClasses:a,disabledClasses:l,focusClasses:s,isActive:c}=function(t){const n=e.inject("flowbite-themable-injection-key",e.ref(null)),r=e.computed(()=>!!(null==n?void 0:n.value)),o=e.computed(()=>(null==n?void 0:n.value)||void 0),i=e.computed(()=>t||n.value);return{backgroundClasses:e.computed(()=>i.value?Iz[i.value].background:""),disabledClasses:e.computed(()=>i.value?Iz[i.value].disabled:""),hoverClasses:e.computed(()=>i.value?Iz[i.value].hover:""),textClasses:e.computed(()=>i.value?Iz[i.value].text:""),borderClasses:e.computed(()=>i.value?Iz[i.value].border:""),focusClasses:e.computed(()=>i.value?Iz[i.value].focus:""),isActive:r,color:o}}(null==(n=t.theme)?void 0:n.value);return{classes:e.computed(()=>{if(!c.value)return"";const e=[];return t.apply.value.includes("text")&&e.push(r.value),t.apply.value.includes("border")&&e.push(o.value),t.apply.value.includes("background")&&e.push(i.value),t.apply.value.includes("hover")&&e.push(a.value),t.apply.value.includes("disabled")&&e.push(l.value),t.apply.value.includes("focus")&&e.push(s.value),e.join(" ")})}}const Pz=e.defineComponent({__name:"FlowbiteThemableChild",props:{apply:{},tag:{default:"div"},theme:{}},setup(t){const n=t,r=e.useAttrs(),{classes:o}=Dz(e.toRefs(n)),i=e.computed(()=>r.class||"");return(n,r)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.tag),{class:e.normalizeClass(e.unref(Tz)(i.value,e.unref(o)))},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},8,["class"]))}}),$z={key:1,"aria-hidden":"true",class:"w-5 h-5",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},Lz={key:2,"aria-hidden":"true",class:"w-5 h-5",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},Rz={key:3,"aria-hidden":"true",class:"w-5 h-5",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},Hz=e.defineComponent({__name:"Toast",props:{alignment:{default:"center"},closable:{type:Boolean,default:!1},divide:{type:Boolean,default:!1},type:{default:"empty"}},emits:["close"],setup(t,{emit:n}){const r=t,o=n,i=e.ref(!0),{typeClasses:a,wrapperClasses:l,contentClasses:s}=function(t){return{typeClasses:e.computed(()=>Vz[t.type.value]),wrapperClasses:e.computed(()=>{const e=Az[t.alignment.value];return t.divide.value?Tz(zz,"dark:divide-gray-700 divide-x divide-gray-200",e):Tz(zz,e)}),contentClasses:e.computed(()=>"empty"!==t.type.value&&t.divide.value?Tz(Oz,"pl-3"):Oz)}}(e.toRefs(r)),c=()=>{o("close"),i.value=!1};return(n,r)=>i.value?(e.openBlock(),e.createElementBlock("div",{key:0,id:"toast-default",class:e.normalizeClass(e.unref(l)),role:"alert"},["empty"!==t.type||n.$slots.icon?(e.openBlock(),e.createBlock(e.unref(Pz),{key:0,class:e.normalizeClass(["inline-flex flex-shrink-0 justify-center items-center w-8 h-8 rounded",e.unref(a)]),apply:["background","text"]},{default:e.withCtx(()=>[n.$slots.icon?e.renderSlot(n.$slots,"icon",{key:0,class:e.normalizeClass({"ml-3":"empty"!==t.type})}):"success"===t.type?(e.openBlock(),e.createElementBlock("svg",$z,[...r[0]||(r[0]=[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z","clip-rule":"evenodd"},null,-1)])])):"danger"===t.type?(e.openBlock(),e.createElementBlock("svg",Lz,[...r[1]||(r[1]=[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z","clip-rule":"evenodd"},null,-1)])])):"warning"===t.type?(e.openBlock(),e.createElementBlock("svg",Rz,[...r[2]||(r[2]=[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M8.257 3.099c.765-1.36 2.722-1.36 3.486 0l5.58 9.92c.75 1.334-.213 2.98-1.742 2.98H4.42c-1.53 0-2.493-1.646-1.743-2.98l5.58-9.92zM11 13a1 1 0 11-2 0 1 1 0 012 0zm-1-8a1 1 0 00-1 1v3a1 1 0 002 0V6a1 1 0 00-1-1z","clip-rule":"evenodd"},null,-1)])])):e.createCommentVNode("",!0)]),_:3},8,["class"])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass([e.unref(s),{"ml-3":n.$slots.icon||"empty"!==t.type}])},[e.renderSlot(n.$slots,"default")],2),t.closable?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"border-none ml-auto -mx-1.5 -my-1.5 bg-white text-gray-400 hover:text-gray-900 rounded focus:ring-2 focus:ring-gray-300 p-1.5 hover:bg-gray-100 inline-flex h-8 w-8 dark:text-gray-500 dark:hover:text-white dark:bg-gray-800 dark:hover:bg-gray-700","aria-label":"Close",onClick:c},[...r[3]||(r[3]=[e.createElementVNode("span",{class:"sr-only"},"Close",-1),e.createElementVNode("svg",{class:"w-5 h-5",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z","clip-rule":"evenodd"})],-1)])])):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0)}});e.defineComponent({components:{Toast:Hz},props:{transition:{type:String,default:"slide-left"}},setup(){const t=e.ref([]),n=(t,n)=>{!function(t,n,r={}){const{immediate:o=!0}=r,i=e.ref(!1);let a=null;function l(){a&&(clearTimeout(a),a=null)}function s(){i.value=!1,l()}function c(...e){l(),i.value=!0,a=setTimeout(()=>{i.value=!1,a=null,t(...e)},JM(n))}o&&(i.value=!0,ZM&&c()),YM(s),e.readonly(i)}(()=>r(t),n)},r=e=>{const n=t.value.findIndex(t=>t.id===e);return n>=0&&t.value.splice(n,1),n>=0};return e.provide("flowbite-toast-injection-key",{add:e=>{const r=parseInt(((new Date).getTime()*Math.random()).toString()).toString();return t.value.push({id:r,...e}),e.time>0&&n(r,e.time),r},pop:()=>{if(0===t.value.length)return"";const e=t.value[t.value.length-1].id;return t.value.pop(),e},remove:r}),{toasts:t,removeToast:r}},render(){const{$props:t,$slots:n,toasts:r,removeToast:o}=this;return e.h("div",{},[n.default?n.default():null,e.h(e.TransitionGroup,{name:t.transition,tag:"div",class:"xl:w-1/6 md:w-1/4 sm:w-1/4 fixed top-3 right-3 flex flex-col gap-2 z-50"},{default:()=>r.map(t=>t.component?e.h(t.component,{key:t.id,onClose:()=>o(t.id),...t.componentProps?t.componentProps:{}},()=>t.text):e.h(Hz,{closable:!0,type:t.type,key:t.id,onClose:()=>o(t.id)},()=>t.text))})])}});const Fz=e.defineComponent({__name:"TooltipTeleportProvider",setup(t){const n=e.ref(null);return e.provide(gV,n),(t,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.renderSlot(t.$slots,"default"),e.createElementVNode("div",{ref_key:"tooltipTarget",ref:n,"data-tooltip-teleport-target":""},null,512)],64))}}),jz={class:"flex gap-4 items-center"},Uz={key:1},Gz=e.defineComponent({__name:"SectionTitle",setup:t=>(t,n)=>(e.openBlock(),e.createElementBlock("div",jz,[t.$slots.default?(e.openBlock(),e.createBlock(e.unref(gc),{key:0,tag:"h2",variant:"heading-3",class:"grow"},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default")]),_:3})):e.createCommentVNode("",!0),t.$slots.right?(e.openBlock(),e.createElementBlock("div",Uz,[e.renderSlot(t.$slots,"right")])):e.createCommentVNode("",!0)]))}),qz=e.defineComponent({__name:"Section",props:{contentClasses:{},contentBackground:{default:"gray"},title:{},noSpacing:{type:Boolean},hasError:{type:Boolean},noBorder:{type:Boolean,default:!1}},setup:t=>(n,r)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.title?"section":"div"),null,{default:e.withCtx(()=>[e.createVNode(Gz,null,e.createSlots({_:2},[t.title?{name:"default",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.title),1)]),key:"0"}:void 0,n.$slots.right?{name:"right",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"right")]),key:"1"}:void 0]),1024),e.createElementVNode("div",{class:e.normalizeClass({"rounded border":!t.noBorder,"p-3 py-2":!t.noSpacing,"bg-gray-50/50":"gray"===t.contentBackground,"mt-1 md:mt-2":!!t.title,[t.contentClasses??""]:!!t.contentClasses,"border-red-600":t.hasError,"border-gray-100":!t.hasError})},[e.renderSlot(n.$slots,"default")],2)]),_:3}))}),Zz={key:0,class:"flex flex-col gap-4"},Wz={class:"flex flex-col items-start"},Kz={class:"flex flex-col gap-2"},Jz={class:"flex flex-col items-start"},Yz=e.defineComponent({__name:"WalletBalances",props:{items:{},title:{default:void 0},variant:{default:"section"}},setup(t){const{$t:n,formatDate:r,formatNumber:o}=HB(),i=e=>{var t,r,i,a,l,s;if(null==e?void 0:e.amount)return Bx(e.amount);if(null==e?void 0:e.credits){const c=Number(e.credits.quantity),d=1===c?null==(r=null==(t=e.credits.creditType)?void 0:t.unit_name)?void 0:r.singular:(null==(a=null==(i=e.credits.creditType)?void 0:i.unit_name)?void 0:a.plural)??(null==(s=null==(l=e.credits.creditType)?void 0:l.unit_name)?void 0:s.singular);return n({defaultMessage:"{quantity} {unit}",description:"Formatted wallet credits balance",id:"wallet_balance.formatted_credit_unit"},{quantity:o(c),unit:d??n({defaultMessage:"credits",description:"Wallet balances credits default message",id:"wB/wXs"})})}return n({defaultMessage:"N/A",description:"Fallback wallet balance label when no balance is available",id:"PW+sL4"})},a=e=>e?n({defaultMessage:"Updated at {date}",description:"Wallet balance timestamp label",id:"spcNSp"},{date:r({date:e,format:"dateTime",offsetType:"local"})}):null;return(r,o)=>"page-grid-aside"===t.variant?(e.openBlock(),e.createElementBlock("div",Zz,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,t=>(e.openBlock(),e.createBlock(e.unref(dz),{key:t.walletId,title:e.unref(n)({defaultMessage:"Wallet",description:"Title of a wallet balance card",id:"3yk8fB"})},{default:e.withCtx(()=>[e.createElementVNode("section",Wz,[e.createVNode(gc,{variant:"label","no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.title),1)]),_:2},1024),e.createVNode(gc,{variant:"body-lg",weight:"semibold","no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(i(t.balance)),1)]),_:2},1024),t.balanceAt?(e.openBlock(),e.createBlock(gc,{key:0,variant:"body-xs",shade:"lighter","no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a(t.balanceAt)),1)]),_:2},1024)):e.createCommentVNode("",!0)])]),_:2},1032,["title"]))),128))])):(e.openBlock(),e.createBlock(qz,{key:1,"no-spacing":"","no-border":"",title:t.title},{default:e.withCtx(()=>[e.createElementVNode("div",Kz,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,t=>(e.openBlock(),e.createBlock(qz,{key:t.walletId},{default:e.withCtx(()=>[e.createElementVNode("div",Jz,[e.createVNode(gc,{variant:"label","no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.title),1)]),_:2},1024),e.createVNode(gc,{variant:"body-lg",weight:"semibold","no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(i(t.balance)),1)]),_:2},1024),t.balanceAt?(e.openBlock(),e.createBlock(gc,{key:0,variant:"body-xs",shade:"lighter","no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a(t.balanceAt)),1)]),_:2},1024)):e.createCommentVNode("",!0)])]),_:2},1024))),128))])]),_:1},8,["title"]))}}),Xz=["innerHTML"],Qz=e.defineComponent({__name:"TextWithHighlights",props:{text:{},search:{default:""},highlighClasses:{default:"text-primary-600 font-bold underline"}},setup(t){const n=t,r=e.computed(()=>{const e=tB(n.text),t=[{type:"text",value:e}];if(""===n.search)return t;const r=new RegExp((o=EC(o=n.search))&&cS.test(o)?o.replace(sS,"\\$&"):o,"gi");var o;const i=[...e.matchAll(r)];if(gS(i))return t;const a=[];return i.forEach((t,r)=>{void 0!==t.index&&(0===r&&(a.push({type:"text",value:e.substring(0,t.index)}),a.push({type:"highlight",value:e.substring(t.index,t.index+n.search.length)})),r>0&&r<i.length-1&&i[r-1].index&&(a.push({type:"text",value:e.substring(i[r-1].index??0+n.search.length,t.index)}),a.push({type:"highlight",value:e.substring(t.index,t.index+n.search.length)})),r===i.length-1&&t.index+n.search.length<e.length&&a.push({type:"text",value:e.substring(t.index+n.search.length,e.length)}))}),a});return(n,o)=>(e.openBlock(),e.createElementBlock("span",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,({type:n,value:r},o)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:o},["text"===n?(e.openBlock(),e.createElementBlock("span",{key:0,innerHTML:r},null,8,Xz)):e.createCommentVNode("",!0),"highlight"===n?(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass(t.highlighClasses)},e.toDisplayString(r),3)):e.createCommentVNode("",!0)],64))),128))]))}}),eO=e.defineComponent({__name:"ErrorNotification",props:{title:{},description:{}},setup(t){const{formatMessage:n}=HB(),r=t,o=e.computed(()=>r.title??n({defaultMessage:"Something went wrong",id:"error_notification.default_error_message",description:"The default message to display"}));return(t,n)=>(e.openBlock(),e.createBlock(JB,e.mergeProps({type:"danger",title:o.value},t.$attrs),null,16,["title"]))}}),tO=e.defineComponent({__name:"TrialChip",props:{trialPeriod:{},size:{default:"sm"}},setup(t){const n=t,{formatTimePeriod:r}=$B(),o=e.computed(()=>"string"==typeof n.trialPeriod?n.trialPeriod:`${r(n.trialPeriod,{short:!0,singular:!0})} trial`);return(n,r)=>(e.openBlock(),e.createBlock(e.unref(mc),{color:"primary",size:t.size},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(o.value),1)]),_:1},8,["size"]))}}),nO=e.defineComponent({__name:"Skeleton",props:{widthClass:{default:"w-10"},heightClass:{default:"h-3"},shade:{default:"default"}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["rounded",[t.widthClass,t.heightClass,{"bg-gray-50/50":"default"===t.shade,"bg-gray-100/50":"dark"===t.shade,"bg-gray-200/50":"darker"===t.shade,"bg-gray-400/50":"darkest"===t.shade}]])},null,2))}),rO=e.defineComponent({__name:"CombinedVolumeChip",props:{i18n:{},placement:{}},setup:t=>(n,r)=>(e.openBlock(),e.createBlock(e.unref(bV),{offset:4,placement:t.placement},{default:e.withCtx(()=>[e.createVNode(e.unref(mc),{color:"dark"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.i18n.combinedVolume),1)]),_:1})]),tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[e.createVNode(e.unref(Cz),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.i18n.description),1)]),_:1})]),_:1})]),_:1},8,["placement"]))}),oO=["innerHTML"],iO=e.defineComponent({__name:"Comparator",props:{propertyName:{},comparator:{},value:{},values:{},hasFormatting:{type:Boolean,default:!0},i18n:{}},setup(t){const n=t,r=e.computed(()=>({propertyName:n.propertyName,comparator:n.comparator,value:n.value??"",values:n.values??[""]}));return(n,o)=>(e.openBlock(),e.createElementBlock("span",{class:"py-0.25 px-0.5",innerHTML:e.unref($S)(t.i18n)(r.value,{hasFormatting:t.hasFormatting})},null,8,oO))}}),aO=e.defineComponent({__name:"Comparators",props:{comparators:{},expressionComparators:{},i18n:{},display:{default:"block"},rootClass:{}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.comparators?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(t.comparators,({meter_property:n,comparator:r,value:o,values:i},a)=>{var l,s;return e.openBlock(),e.createElementBlock("span",{key:null==n?void 0:n.id,class:e.normalizeClass({block:"block"===t.display,inline:"inline"===t.display})},[e.createVNode(iO,{"property-name":(null==n?void 0:n.name)??(null==(l=t.i18n)?void 0:l.unknown)??"Unknown",comparator:r,value:o,values:i},null,8,["property-name","comparator","value","values"]),a<t.comparators.length-1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(" ")+e.toDisplayString((null==(s=t.i18n)?void 0:s.and)??"and")+e.toDisplayString(" "),1)],64)):e.createCommentVNode("",!0)],2)}),128)):e.createCommentVNode("",!0),t.expressionComparators?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(t.expressionComparators.operands,(n,r)=>{var o,i;return e.openBlock(),e.createElementBlock("span",{key:r,class:e.normalizeClass(["bg-blue-400/25 rounded-sm px-2 mr-1",t.rootClass])},[n.meter_property?(e.openBlock(),e.createBlock(iO,{key:0,"property-name":(null==(o=n.meter_property.meter_property)?void 0:o.name)??(null==(i=t.i18n)?void 0:i.unknown)??"Unknown",comparator:n.meter_property.comparator,value:n.meter_property.value,values:n.meter_property.values},null,8,["property-name","comparator","value","values"])):e.createCommentVNode("",!0),n.expression?(e.openBlock(),e.createBlock(e.unref(aO),{key:1,"expression-comparators":n.expression,display:t.display,i18n:t.i18n,"root-class":t.rootClass},null,8,["expression-comparators","display","i18n","root-class"])):e.createCommentVNode("",!0),r<t.expressionComparators.operands.length-1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(e.toDisplayString(" ")+e.toDisplayString(e.unref(Nx)(t.expressionComparators.operator).toLocaleLowerCase())+e.toDisplayString(" "),1)],64)):e.createCommentVNode("",!0)],2)}),128)):e.createCommentVNode("",!0)],64))}),lO={class:"flex flex-col gap-1"},sO={class:"text-base text-gray-900"},cO=e.defineComponent({__name:"PricingItemHeader",props:{item:{},creditTypesById:{}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("div",lO,[e.createElementVNode("h4",sO,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.item.product_items,t=>(e.openBlock(),e.createBlock(gc,{key:t.id,tag:"span",class:"flex flex-wrap items-center gap-3",weight:"semibold"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.name),1)]),_:2},1024))),128))])]))}),dO=e.defineComponent({__name:"TopUpDescription",props:{i18n:{},pricingItemConfig:{}},setup(t){const n=t,r=e.computed(()=>{var e;return!!(null==(e=n.pricingItemConfig.top_up)?void 0:e.rollover)}),o=e.computed(()=>{var e;return null==(e=n.pricingItemConfig.bands)?void 0:e.some(e=>!!e.block_size)}),i=e.computed(()=>HS(n.pricingItemConfig)&&o.value?r.value?n.i18n.tiered.blockSize.rolloverDescription:n.i18n.tiered.blockSize.nonRolloverDescription:HS(n.pricingItemConfig)&&!o.value?r.value?n.i18n.tiered.nonBlockSize.rolloverDescription:n.i18n.tiered.nonBlockSize.nonRolloverDescription:r.value?n.i18n.rolloverDescription:n.i18n.nonRolloverDescription);return(t,n)=>(e.openBlock(),e.createBlock(e.unref(gc),{variant:"body-xs",class:"italic text-gray-600"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(i.value),1)]),_:1}))}}),uO={tiered:{nonBlockSize:{rolloverDescription:"Includes prior volume to determine the tier, including volume from prior schedule's billing cycles",nonRolloverDescription:"Prior volume is included to determine the tier"},blockSize:{rolloverDescription:"Includes prior volume to determine the tier and unused volume will move over, including volume from adjacent schedule's billing cycles",nonRolloverDescription:"Includes prior volume to determine the tier and unused volume will move over to the following billing cycles"}},nonRolloverDescription:"Unused volume will be moved over to the next billing cycle",rolloverDescription:"Unused volume will be moved over to the next billing cycle, including the next schedule's billing cycle"},pO={class:"inline-flex items-center"},hO=e.defineComponent({__name:"TopUpChip",props:{i18n:{},placement:{},hasTooltip:{type:Boolean},pricingItemConfig:{}},setup(t){const n=t,r=e.computed(()=>{var e,t;return!!(null==(t=null==(e=n.pricingItemConfig)?void 0:e.top_up)?void 0:t.rollover)}),o=e.computed(()=>({color:"dark",hasChipAfter:r.value})),i={color:"dark",dark:!0,hasChipBefore:!0},a=e.computed(()=>{var e,t;return null==(t=null==(e=n.pricingItemConfig)?void 0:e.bands)?void 0:t.some(e=>e.block_size)}),l=e.computed(()=>HS(n.pricingItemConfig)&&a.value?n.i18n.tieredTooltip.blockSize:HS(n.pricingItemConfig)&&!a.value?n.i18n.tieredTooltip.nonBlockSize:n.i18n.defaultTooltip);return(n,a)=>(e.openBlock(),e.createElementBlock("span",pO,[t.hasTooltip?(e.openBlock(),e.createBlock(e.unref(bV),{key:0,offset:4,placement:t.placement},{default:e.withCtx(()=>[e.createVNode(e.unref(mc),e.normalizeProps(e.guardReactiveProps(o.value)),{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.i18n.topUp),1)]),_:1},16)]),tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[e.createVNode(e.unref(Cz),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(l.value),1)]),_:1})]),_:1})]),_:1},8,["placement"])):(e.openBlock(),e.createBlock(e.unref(mc),e.normalizeProps(e.mergeProps({key:1},o.value)),{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.i18n.topUp),1)]),_:1},16)),r.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[t.hasTooltip?(e.openBlock(),e.createBlock(e.unref(bV),{key:0,offset:4,placement:t.placement},{default:e.withCtx(()=>[e.createVNode(e.unref(mc),e.normalizeProps(e.guardReactiveProps(i)),{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.i18n.rollover.title),1)]),_:1},16)]),tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[e.createVNode(e.unref(Cz),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.i18n.rollover.tooltip),1)]),_:1})]),_:1})]),_:1},8,["placement"])):(e.openBlock(),e.createBlock(e.unref(mc),e.normalizeProps(e.mergeProps({key:1},i)),{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.i18n.rollover.title),1)]),_:1},16))],64)):e.createCommentVNode("",!0)]))}}),mO={defaultPricing:"Pricing",combinedVolume:{combinedVolume:"Combined volume",description:"Total volume sets the tier, applied proportionally to the selected rules."},topUpChip:{topUp:"Top up",defaultTooltip:"Top up allows moving unused volume over to the next billing cycle",tieredTooltip:{blockSize:"Includes prior volume to determine the tier and unused volume will move over",nonBlockSize:"Includes prior volume to determine the tier"},rollover:{title:"Rollover",tooltip:"Top up is applied to the next following schedule's billing cycles"}},splitBy:"Split by"},fO={...mO,formatBillingPeriod:Mx,formatAmount:Bx,formatNumber:e=>new Intl.NumberFormat("en-US").format(e),billed:"Billed",from:"From",upTo:"Up to",feeFloor:"Fee floor",feeCap:"Fee cap",price:"Price",pricePerStep:()=>"Price / Step",pricePerUnit:()=>"Price / Unit",percentage:"Percentage",per:"Per",infinite:"infinite",topUpDescription:uO},gO={class:"flex justify-between items-start"},vO={key:0,class:"flex gap-2"},yO={key:1,class:"flex justify-center gap-2"},bO={class:"rounded border overflow-clip mt-3"},wO={class:"table-auto w-full text-gray-600"},kO={colspan:"5",class:"bg-gray-50 text-left px-2"},xO={class:"border-t"},_O={class:"px-2 py-1 text-left"},CO={class:"px-2 py-1 text-left"},EO={class:"px-2 py-1 text-left"},SO={class:"px-2 py-1 text-left"},BO={key:1,class:"text-right pr-2"},NO={class:"px-2 py-1"},MO={class:"px-2 py-1"},TO={class:"px-2 py-1"},VO={class:"px-2 py-1"},AO={key:1,class:"px-2 py-1 text-right"},zO={key:1,class:"mt-2"},OO=e.defineComponent({__name:"TieredSteppedPricingRule",props:{config:{},itemIndex:{},configIndex:{},item:{},i18n:{},isCombinedPricing:{type:Boolean},showConfigHeader:{type:Boolean,default:!0},creditTypesById:{}},setup(t){const n=t;e.useSlots();const r=e.computed(()=>n.i18n??fO),o=e.computed(()=>{var e,t,r,o,i,a;return(null==(r=null==(t=null==(e=n.config.bands)?void 0:e.find(e=>{var t;return null==(t=e.credits)?void 0:t.credit_type_id}))?void 0:t.credits)?void 0:r.credit_type_id)??(null==(a=null==(i=null==(o=n.item.product_items)?void 0:o[0])?void 0:i.credits)?void 0:a.credit_type_id)}),i=e.computed(()=>{var e,t,r,i,a;if(o.value){const r=null==(e=n.creditTypesById)?void 0:e[o.value];if(r)return(null==(t=r.unit_name)?void 0:t.singular)||"unit"}return(null==(a=null==(i=null==(r=n.item.product_items)?void 0:r[0])?void 0:i.unit_name)?void 0:a.singular)||"unit"}),a=e.computed(()=>{if(["TIERED","TOP_TIERED"].includes(n.config.type)&&n.config.bands)for(const e of n.config.bands)if(e.minimum_amount||e.maximum_amount)return!0;return!1}),l=e.computed(()=>HS(n.config)?"TIERED":FS(n.config)?"STAIR_STEP":n.config.type),s=e.computed(()=>RS(n.config)),c=e.computed(()=>{var e;return null==(e=n.config.bands)?void 0:e.some(e=>e.block_size)}),d=e.computed(()=>{var e,t,r,o;return null==(o=null==(r=null==(t=null==(e=n.config.split_pricing)?void 0:e.meter_properties)?void 0:t.map(e=>{var t;return null==(t=e.meter_property)?void 0:t.name}))?void 0:r.filter(e=>!!e))?void 0:o.join(", ")}),u=e.computed(()=>n.showConfigHeader||n.config.split_pricing),p=e.computed(()=>!!n.config.use_fallback_currency&&!!n.config.fallback_currency),h=e.computed(()=>`Based on fallback currency – ${n.config.fallback_currency}`);return(n,o)=>(e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",gO,[u.value?(e.openBlock(),e.createElementBlock("div",vO,[e.createVNode(e.unref(tD),{config:t.config,i18n:r.value},{"override-tooltip":e.withCtx(()=>[e.renderSlot(n.$slots,"override-tooltip")]),_:3},8,["config","i18n"]),p.value?(e.openBlock(),e.createBlock(e.unref(bV),{key:0,variant:"outline",placement:"top"},{tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[e.createVNode(e.unref(Cz),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(h.value),1)]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(hc),{icon:"change_circle",class:"text-gray-500"})]),_:1})):e.createCommentVNode("",!0),t.config.split_pricing?(e.openBlock(),e.createElementBlock("div",yO,[e.createVNode(e.unref(gc),{variant:"label",tag:"span"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.splitBy),1)]),_:1}),e.createVNode(e.unref(gc),{tag:"span",variant:"body-sm"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(d.value),1)]),_:1})])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),s.value?(e.openBlock(),e.createBlock(e.unref(dO),{key:0,class:"mt-1 mb-3",i18n:r.value.topUpDescription,"pricing-item-config":t.config},null,8,["i18n","pricing-item-config"])):e.createCommentVNode("",!0),e.createElementVNode("div",bO,[e.createElementVNode("table",wO,[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("th",kO,[e.createVNode(e.unref(gc),{variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(Nx)(l.value)),1)]),_:1})])]),e.createElementVNode("tr",xO,[e.createElementVNode("th",_O,[e.createVNode(e.unref(gc),{variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.from),1)]),_:1})]),e.createElementVNode("th",CO,[e.createVNode(e.unref(gc),{variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.upTo),1)]),_:1})]),e.createElementVNode("th",{class:e.normalizeClass(["px-2 py-1",[a.value?"text-left":"text-right"]])},["STAIR_STEP"===l.value?(e.openBlock(),e.createBlock(e.unref(gc),{key:0,variant:"caps-heading"},{default:e.withCtx(()=>{var n,o,i;return[e.createTextVNode(e.toDisplayString(r.value.pricePerStep(null==(i=null==(o=null==(n=t.item.product_items)?void 0:n[0])?void 0:o.unit_name)?void 0:i.plural)),1)]}),_:1})):c.value?(e.openBlock(),e.createBlock(e.unref(gc),{key:1,variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.price),1)]),_:1})):t.config.bands&&t.config.bands[0].amount||t.config.bands&&t.config.bands[0].fixed_amount?(e.openBlock(),e.createBlock(e.unref(gc),{key:2,variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.pricePerUnit(i.value)),1)]),_:1})):(e.openBlock(),e.createBlock(e.unref(gc),{key:3,variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.percentage),1)]),_:1}))],2),a.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("th",EO,[e.createVNode(e.unref(gc),{variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.feeFloor),1)]),_:1})]),e.createElementVNode("th",SO,[e.createVNode(e.unref(gc),{variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.feeCap),1)]),_:1})])],64)):e.createCommentVNode("",!0),c.value?(e.openBlock(),e.createElementBlock("th",BO,[e.createVNode(e.unref(gc),{variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.per),1)]),_:1})])):e.createCommentVNode("",!0)])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.config.bands,(n,o)=>(e.openBlock(),e.createElementBlock("tr",{key:o,class:"border-t"},[e.createElementVNode("td",NO,[t.config.bands?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(e.unref(JS)(r.value)(t.config.bands[o-1])),1)],64)):e.createCommentVNode("",!0)]),e.createElementVNode("td",MO,[t.config.bands?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(e.unref(YS)(r.value)(n,t.config.bands,o)),1)],64)):e.createCommentVNode("",!0)]),e.createElementVNode("td",{class:e.normalizeClass(["px-2 py-1",{"text-right":!a.value}])},[n.amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:n.amount,highlighted:""},null,8,["value"])):e.createCommentVNode("",!0),n.fixed_amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:n.fixed_amount,highlighted:""},null,8,["value"])):n.percentage?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(e.toDisplayString(n.percentage)+"% ",1)],64)):e.createCommentVNode("",!0)],2),a.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("td",TO,[n.minimum_amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:n.minimum_amount},null,8,["value"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(" ")],64))]),e.createElementVNode("td",VO,[n.maximum_amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:n.maximum_amount},null,8,["value"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(" ")],64))])],64)):e.createCommentVNode("",!0),c.value?(e.openBlock(),e.createElementBlock("td",AO,[e.unref(ZS)(n.block_size)?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:n.block_size.amount},null,8,["value"])):e.unref(GS)(n.block_size)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(r.value.formatNumber(+n.block_size.number)),1)],64)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]))),128))])])]),n.$slots.included?(e.openBlock(),e.createElementBlock("div",zO,[e.renderSlot(n.$slots,"included")])):e.createCommentVNode("",!0)]))}}),IO={...mO,topUpDescription:uO,notBilled:"Not billed",passThrough:"Pass through",perNumberOfUnits:(e,t)=>"per "+(Number(e)>1?`${e} ${(null==t?void 0:t.plural)??"units"}`:`${(null==t?void 0:t.singular)??"unit"}`),ofAmount:()=>"of amount",with:"with",aMinimumOf:"a minimum of",and:"and",aMaximumOf:"a maximum of",perSeat:"per seat",billedInAdvance:"billed in advance",oneOff:"one-off",formatBillingPeriod:Mx},DO={class:"flex justify-between items-start"},PO={key:0,class:"flex items-center gap-2"},$O={class:"flex flex-col gap-1"},LO={class:"flex items-center gap-2"},RO={key:0,class:"flex justify-center gap-2"},HO={key:0,class:"text-gray-600 ml-auto"},FO={key:1,class:"text-gray-600 ml-auto"},jO={key:0,class:"ml-4 text-gray-600 flex flex-col empty:hidden shrink-0"},UO={class:"flex justify-end items-center"},GO={"data-testid":"flat-fixed-none-amount"},qO={"data-testid":"flat-fixed-none-per-units",class:"pl-1"},ZO={key:0,class:"pl-1"},WO={"data-testid":"flat-fixed-none-credits-label",class:"text-primary-600 font-semibold"},KO={"data-testid":"flat-fixed-none-per-units",class:"pl-1"},JO={key:0,class:"pl-1"},YO={class:"text-primary-600 font-semibold"},XO={class:"pl-1"},QO={key:0,class:"pl-1"},eI={key:1,class:"mr-1"},tI={key:3,class:"mr-1"},nI={key:3,class:"ml-2 flex items-center"},rI={key:0,class:"text-gray-600 flex flex-col shrink-0"},oI={class:"flex items-center"},iI={key:2,class:"pl-1"},aI={key:3,class:"pl-1"},lI={key:4,class:"italic pl-1 shrink-9"},sI={key:5,class:"ml-2 flex items-center"},cI={key:1,class:"text-gray-600 flex flex-col shrink-0"},dI={class:"flex items-center"},uI={class:"pl-1"},pI={key:0,class:"italic"},hI={key:2,class:"ml-2 flex items-center"},mI={key:2,class:"text-gray-600 flex flex-col shrink-0"},fI={class:"flex items-center"},gI={class:"pl-1"},vI={key:1,class:"pl-1"},yI={key:2,class:"italic pl-1"},bI={key:3,class:"ml-2 flex items-center"},wI=e.defineComponent({__name:"FlatFixedNonePricingRule",props:{config:{},item:{},areNonBillableItemsVisible:{type:Boolean},i18n:{},isCombinedPricing:{type:Boolean},showConfigHeader:{type:Boolean,default:!0},showDefaultValues:{type:Boolean,default:!0},creditTypesById:{}},setup(t){const n=t,{formatMessage:r}=HB(),o=e.computed(()=>n.i18n??IO),i=e.computed(()=>RS(n.config)),a=r({defaultMessage:"unit",id:"lWOCGz",description:"Fallback singular unit label for pricing rule display"}),l=r({defaultMessage:"units",id:"Vl9vDx",description:"Fallback plural unit label for pricing rule display"}),s=e.computed(()=>n.item.product_items&&n.item.product_items[0]),c=e.computed(()=>{var e,t,r,o,i,c,d,u;if("CREDITS"===(null==(e=s.value)?void 0:e.model_type)){const e=null==(t=s.value.credits)?void 0:t.credit_type_id,i=e?null==(o=null==(r=n.creditTypesById)?void 0:r[e])?void 0:o.unit_name:void 0;return{singular:(null==i?void 0:i.singular)||a,plural:(null==i?void 0:i.plural)||l}}return{singular:(null==(c=null==(i=s.value)?void 0:i.unit_name)?void 0:c.singular)||a,plural:(null==(u=null==(d=s.value)?void 0:d.unit_name)?void 0:u.plural)||l}}),d=e.computed(()=>{var e,t,n,r;return{singular:(null==(t=null==(e=s.value)?void 0:e.unit_name)?void 0:t.singular)||a,plural:(null==(r=null==(n=s.value)?void 0:n.unit_name)?void 0:r.plural)||l}}),u=e.computed(()=>{var e,t,r,o;return null==(o=null==(r=null==(t=null==(e=n.config.split_pricing)?void 0:e.meter_properties)?void 0:t.map(e=>{var t;return null==(t=e.meter_property)?void 0:t.name}))?void 0:r.filter(e=>!!e))?void 0:o.join(",")}),p=e.computed(()=>n.showConfigHeader||n.config.split_pricing),h=e.computed(()=>!!n.config.use_fallback_currency&&!!n.config.fallback_currency),m=e.computed(()=>`Based on fallback currency – ${n.config.fallback_currency}`),f=e.computed(()=>{var e,t;return null==(t=null==(e=n.config.bands)?void 0:e[0])?void 0:t.credits}),g=e.computed(()=>{var e,t,r,o,i,a;const l=null==(e=f.value)?void 0:e.credit_type_id,s=null==(t=f.value)?void 0:t.quantity;if(!s)return"";const c=l?null==(r=n.creditTypesById)?void 0:r[l]:void 0;if(!c)return s;const d=1===Number(s)?(null==(o=c.unit_name)?void 0:o.singular)??c.name:(null==(i=c.unit_name)?void 0:i.plural)??(null==(a=c.unit_name)?void 0:a.singular)??c.name;return d?`${s} ${d}`:s});return(n,r)=>{var a,l,f,v,y,b,w;return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",DO,[p.value?(e.openBlock(),e.createElementBlock("div",PO,[e.createElementVNode("div",$O,[e.createElementVNode("div",LO,[t.showConfigHeader?(e.openBlock(),e.createBlock(e.unref(tD),{key:0,config:t.config,i18n:o.value},{"override-tooltip":e.withCtx(()=>[e.renderSlot(n.$slots,"override-tooltip")]),_:3},8,["config","i18n"])):e.createCommentVNode("",!0),h.value?(e.openBlock(),e.createBlock(e.unref(bV),{key:1,variant:"outline",placement:"top"},{tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[e.createVNode(e.unref(Cz),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(m.value),1)]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(hc),{icon:"change_circle",class:"text-gray-500"})]),_:1})):e.createCommentVNode("",!0)]),t.config.split_pricing?(e.openBlock(),e.createElementBlock("div",RO,[e.createVNode(gc,{variant:"label",tag:"span"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(o.value.splitBy),1)]),_:1}),e.createVNode(gc,{tag:"span",variant:"body-sm"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(u.value),1)]),_:1})])):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),["NONE","PASS_THROUGH"].includes(t.config.type)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},["NONE"===t.config.type?(e.openBlock(),e.createElementBlock("div",HO,e.toDisplayString(o.value.notBilled),1)):e.createCommentVNode("",!0),"PASS_THROUGH"===t.config.type?(e.openBlock(),e.createElementBlock("div",FO,e.toDisplayString(o.value.passThrough),1)):e.createCommentVNode("",!0)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[s.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},["USAGE_BASED"===s.value.model_type||"CREDITS"===s.value.model_type?(e.openBlock(),e.createElementBlock("div",jO,[e.createElementVNode("div",null,[e.createElementVNode("div",UO,[t.config.bands&&t.config.bands[0].amount?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("span",GO,[e.createVNode(e.unref(YB),{value:t.config.bands[0].amount,highlighted:""},null,8,["value"])]),e.createElementVNode("span",qO,e.toDisplayString(o.value.perNumberOfUnits((null==(a=t.config.bands[0])?void 0:a.block_size)&&e.unref(GS)(t.config.bands[0].block_size)?t.config.bands[0].block_size.number:"1",c.value)),1),t.config.billing_period?(e.openBlock(),e.createElementBlock("span",ZO,e.toDisplayString(o.value.formatBillingPeriod(t.config.billing_period)),1)):e.createCommentVNode("",!0)],64)):t.config.bands&&(null==(l=t.config.bands[0].credits)?void 0:l.quantity)&&(null==(f=t.config.bands[0].credits)?void 0:f.credit_type_id)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("span",WO,e.toDisplayString(g.value),1),e.createElementVNode("span",KO,e.toDisplayString(o.value.perNumberOfUnits((null==(v=t.config.bands[0])?void 0:v.block_size)&&e.unref(GS)(t.config.bands[0].block_size)?t.config.bands[0].block_size.number:"1",d.value)),1),t.config.billing_period?(e.openBlock(),e.createElementBlock("span",JO,e.toDisplayString(o.value.formatBillingPeriod(t.config.billing_period)),1)):e.createCommentVNode("",!0)],64)):t.config.bands&&"string"==typeof t.config.bands[0].percentage?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createElementVNode("span",YO,e.toDisplayString(t.config.bands[0].percentage)+"% ",1),e.createElementVNode("span",XO,e.toDisplayString(o.value.ofAmount(null==(y=s.value.unit_name)?void 0:y.singular)),1),t.config.billing_period?(e.openBlock(),e.createElementBlock("span",QO,e.toDisplayString(o.value.formatBillingPeriod(t.config.billing_period)),1)):e.createCommentVNode("",!0),t.config.bands[0].minimum_amount||t.config.bands[0].maximum_amount?(e.openBlock(),e.createElementBlock("span",eI," , "+e.toDisplayString(o.value.with),1)):e.createCommentVNode("",!0),t.config.bands[0].minimum_amount?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(e.toDisplayString(o.value.aMinimumOf)+" ",1),e.createVNode(e.unref(YB),{value:t.config.bands[0].minimum_amount,highlighted:"",class:"mx-1"},null,8,["value"])],64)):e.createCommentVNode("",!0),t.config.bands[0].minimum_amount&&t.config.bands[0].maximum_amount?(e.openBlock(),e.createElementBlock("span",tI,e.toDisplayString(o.value.and),1)):e.createCommentVNode("",!0),t.config.bands[0].maximum_amount?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[e.createTextVNode(e.toDisplayString(o.value.aMaximumOf)+" ",1),e.createVNode(e.unref(YB),{value:t.config.bands[0].maximum_amount,highlighted:"",class:"ml-1"},null,8,["value"])],64)):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),n.$slots["price-line-additions"]?(e.openBlock(),e.createElementBlock("span",nI,[e.renderSlot(n.$slots,"price-line-additions")])):e.createCommentVNode("",!0)])]),e.createElementVNode("div",null,[e.renderSlot(n.$slots,"included")])])):e.createCommentVNode("",!0),t.isCombinedPricing?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},["RECURRING"===s.value.model_type?(e.openBlock(),e.createElementBlock("div",rI,[e.createElementVNode("div",null,[e.createElementVNode("div",oI,[t.config.bands&&t.config.bands[0].amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.config.bands[0].amount,highlighted:""},null,8,["value"])):t.config.bands&&t.config.bands[0].fixed_amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:t.config.bands[0].fixed_amount,highlighted:""},null,8,["value"])):e.createCommentVNode("",!0),(null==(b=t.config.billing_period)?void 0:b.type)?(e.openBlock(),e.createElementBlock("div",iI,e.toDisplayString(o.value.formatBillingPeriod(t.config.billing_period)),1)):(e.openBlock(),e.createElementBlock("div",aI,"per billing period")),t.config.billing_in_advance?(e.openBlock(),e.createElementBlock("span",lI," ("+e.toDisplayString(o.value.billedInAdvance)+") ",1)):e.createCommentVNode("",!0),n.$slots["price-line-additions"]?(e.openBlock(),e.createElementBlock("span",sI,[e.renderSlot(n.$slots,"price-line-additions")])):e.createCommentVNode("",!0)])]),e.renderSlot(n.$slots,"included")])):e.createCommentVNode("",!0),"ONE_OFF"===s.value.model_type?(e.openBlock(),e.createElementBlock("div",cI,[e.createElementVNode("div",null,[e.createElementVNode("div",dI,[t.config.bands&&t.config.bands[0].amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.config.bands[0].amount,highlighted:""},null,8,["value"])):t.config.bands&&t.config.bands[0].fixed_amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:t.config.bands[0].fixed_amount,highlighted:""},null,8,["value"])):e.createCommentVNode("",!0),e.createElementVNode("div",uI,[e.createTextVNode(e.toDisplayString(o.value.oneOff)+" ",1),t.config.billing_in_advance?(e.openBlock(),e.createElementBlock("span",pI," ("+e.toDisplayString(o.value.billedInAdvance)+") ",1)):e.createCommentVNode("",!0)]),n.$slots["price-line-additions"]?(e.openBlock(),e.createElementBlock("span",hI,[e.renderSlot(n.$slots,"price-line-additions")])):e.createCommentVNode("",!0)])]),e.renderSlot(n.$slots,"included")])):e.createCommentVNode("",!0),"PER_SEAT"===s.value.model_type?(e.openBlock(),e.createElementBlock("div",mI,[e.createElementVNode("div",null,[e.createElementVNode("div",fI,[t.config.bands&&t.config.bands[0].amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.config.bands[0].amount,highlighted:""},null,8,["value"])):e.createCommentVNode("",!0),e.createElementVNode("span",gI,e.toDisplayString(o.value.perSeat),1),(null==(w=t.config.billing_period)?void 0:w.type)?(e.openBlock(),e.createElementBlock("div",vI,e.toDisplayString(o.value.formatBillingPeriod(t.config.billing_period)),1)):e.createCommentVNode("",!0),t.config.billing_in_advance?(e.openBlock(),e.createElementBlock("span",yI," ("+e.toDisplayString(o.value.billedInAdvance)+") ",1)):e.createCommentVNode("",!0),n.$slots["price-line-additions"]?(e.openBlock(),e.createElementBlock("span",bI,[e.renderSlot(n.$slots,"price-line-additions")])):e.createCommentVNode("",!0)])]),e.renderSlot(n.$slots,"included")])):e.createCommentVNode("",!0)],64))],64)):e.createCommentVNode("",!0)],64))]),i.value?(e.openBlock(),e.createBlock(e.unref(dO),{key:0,i18n:o.value.topUpDescription,class:"mt-1","pricing-item-config":t.config},null,8,["i18n","pricing-item-config"])):e.createCommentVNode("",!0)])}}}),kI={...IO,...fO,includedVolumeAmountPerSchedule:e=>`with <strong class="text-primary-600">${new Intl.NumberFormat("en-US",{style:"currency",currencyDisplay:"symbol",currency:e.currency,maximumFractionDigits:10}).format(Number(e.quantity))}</strong> free amount per schedule included`,includedVolumeAmountPerBillingPeriod:e=>`with <strong class="text-primary-600">${new Intl.NumberFormat("en-US",{style:"currency",currencyDisplay:"symbol",currency:e.currency,maximumFractionDigits:10}).format(Number(e.quantity))}</strong> free amount per billing period included`,includedVolumeUnitsPerSchedule:e=>`with <strong class="text-primary-600">${e} unit${"1"===e?"":"s"}</strong> per schedule included`,includedVolumeUnitsPerBillingPeriod:e=>`with <strong class="text-primary-600">${e} unit${"1"===e?"":"s"}</strong> per billing period included`,includedSeats:e=>`with default <strong class="text-primary-600">${e}</strong> seat${"1"===e?"":"s"}`},xI={class:"conditions-root"},_I=["innerHTML"],CI=["innerHTML"],EI=["innerHTML"],SI=["innerHTML"],BI=["innerHTML"],NI=["innerHTML"],MI={key:2,class:"mt-3"},TI={key:0,class:"-transform-x-1/2 context-menu-wrapper absolute -top-2 right-0 opacity-0 transition-opacity"},VI={key:0,class:"nested-conditions-border before:background-repeat-y before:content[''] relative mb-4 w-full pl-4 before:absolute before:inset-0 before:right-auto before:w-1 before:content-['']"},AI=fB(e.defineComponent({__name:"PricingItemConfig",props:{areNonBillableItemsVisible:{type:Boolean},rootConfig:{},config:{},configIndex:{},item:{},itemIndex:{},pricing:{},i18n:{},rootClass:{},showConfigHeader:{type:Boolean,default:!0},showDefaultValues:{type:Boolean,default:!0},schedule:{},creditTypesById:{}},setup(t){const n=t,r=e.computed(()=>n.i18n??kI),o=e.useSlots(),i=e=>(e=>LS(e,["FLAT","FLAT_TOP_UP"]))(e)||"FIXED"===e.type||"PASS_THROUGH"===e.type||"NONE"===e.type&&n.areNonBillableItemsVisible,a=e=>LS(e,["TIERED","TIERED_TOP_UP","TOP_TIERED"])||FS(e),l=e=>{var t,n,r,o,i;return"AMOUNT"===(null==(i=null==(o=null==(r=null==(n=null==(t=e.product_items)?void 0:t[0])?void 0:n.usage_based)?void 0:r.meter_value_calculation)?void 0:o.meter_value)?void 0:i.type)},s=e=>{var t,n,r,o,i;return"NUMBER"===(null==(i=null==(o=null==(r=null==(n=null==(t=e.product_items)?void 0:t[0])?void 0:n.usage_based)?void 0:r.meter_value_calculation)?void 0:o.meter_value)?void 0:i.type)},c=(e,t)=>{var n,r;return"PER_SEAT"===(null==(r=null==(n=e.product_items)?void 0:n[0])?void 0:r.model_type)&&"NONE"!==t.type},d=e.computed(()=>({pricing:n.pricing,item:n.item,config:n.config})),u=e.computed(()=>{var e;return null==(e=n.config.conditions)?void 0:e.configs}),p=e.computed(()=>!!o["pricing-item-config-settings"]&&!QS(o["pricing-item-config-settings"](d.value))),h=e.computed(()=>n.rootConfig??n.config),m=e.computed(()=>{var e,t,r;const o=n.config.original_pricing_item_config_id;return n.schedule?(null==(e=(({schedule:e,pricingItemConfigIds:t})=>{var n,r;const o=new Date,i=new Set(t),a=null==(n=e.seats_values)?void 0:n.map((e,t)=>({seatsValue:e,index:t})).filter(({seatsValue:e})=>!!i.has(e.pricing_item_config_id)&&(!!e.set_start_at_to_now||!!e.start_at&&new Date(e.start_at)<=o));return null==(r=null==a?void 0:a.sort((e,t)=>{const n=e.seatsValue.set_start_at_to_now?o.getTime():e.seatsValue.start_at?new Date(e.seatsValue.start_at).getTime():0,r=t.seatsValue.set_start_at_to_now?o.getTime():t.seatsValue.start_at?new Date(t.seatsValue.start_at).getTime():0;return r!==n?r-n:t.index-e.index})[0])?void 0:r.seatsValue})({schedule:n.schedule,pricingItemConfigIds:[n.config.id,...o?[o]:[]]}))?void 0:e.number)??(null==(t=n.config.default_seats_value)?void 0:t.number):null==(r=n.config.default_seats_value)?void 0:r.number});return(o,f)=>{var g,v,y;const b=e.resolveComponent("PricingItemConfig",!0);return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["relative",{[`${t.rootClass}`]:t.rootClass,"mb-4 last:mb-0":i(t.config)&&((null==(g=t.config.conditions)?void 0:g.meter_properties)||0===t.configIndex&&t.item.configs&&t.item.configs.length>0),"mb-6 last:mb-0":a(t.config)}])},[e.createElementVNode("div",xI,[e.createElementVNode("div",{class:e.normalizeClass({"transition-padding conditions-with-context-menu":p.value})},[t.config.bands||t.config.type?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[i(t.config)?(e.openBlock(),e.createBlock(e.unref(wI),{key:0,"is-combined-pricing":t.pricing.products&&t.pricing.products.length>1,"are-non-billable-items-visible":t.areNonBillableItemsVisible,config:t.config,item:t.item,class:e.normalizeClass({"mt-3":!t.rootClass}),i18n:r.value,"show-config-header":t.showConfigHeader,"show-default-values":t.showDefaultValues,"credit-types-by-id":t.creditTypesById},{"override-tooltip":e.withCtx(()=>[e.renderSlot(o.$slots,"override-tooltip",e.normalizeProps(e.guardReactiveProps(n)),void 0,!0)]),"price-line-additions":e.withCtx(()=>[e.renderSlot(o.$slots,"pricing-item-config-price-line-additions",e.normalizeProps(e.guardReactiveProps(d.value)),void 0,!0)]),included:e.withCtx(()=>{var n,o,i,a;return[l(t.item)&&(null==(n=t.config.default_included_volume)?void 0:n.amount)?(e.openBlock(),e.createElementBlock("span",{key:0,class:"mt-1 text-right text-gray-600",innerHTML:"BILLING_PERIOD"===t.config.default_included_volume.reset_type?r.value.includedVolumeAmountPerBillingPeriod(t.config.default_included_volume.amount):r.value.includedVolumeAmountPerSchedule(t.config.default_included_volume.amount)},null,8,_I)):e.createCommentVNode("",!0),s(t.item)&&(null==(o=t.config.default_included_volume)?void 0:o.number)?(e.openBlock(),e.createElementBlock("span",{key:1,class:"mt-1 text-right text-gray-600",innerHTML:"BILLING_PERIOD"===t.config.default_included_volume.reset_type?r.value.includedVolumeUnitsPerBillingPeriod(t.config.default_included_volume.number,null==(i=t.item.product_items)?void 0:i[0].unit_name):r.value.includedVolumeUnitsPerSchedule(t.config.default_included_volume.number,null==(a=t.item.product_items)?void 0:a[0].unit_name)},null,8,CI)):e.createCommentVNode("",!0),t.showDefaultValues&&c(t.item,t.config)&&m.value?(e.openBlock(),e.createElementBlock("span",{key:2,class:"mt-1 text-right text-gray-600",innerHTML:r.value.includedSeats(m.value)},null,8,EI)):e.createCommentVNode("",!0)]}),_:3},8,["is-combined-pricing","are-non-billable-items-visible","config","item","class","i18n","show-config-header","show-default-values","credit-types-by-id"])):a(t.config)?(e.openBlock(),e.createBlock(e.unref(OO),{key:1,"is-combined-pricing":t.pricing.products&&t.pricing.products.length>1,config:t.config,"item-index":t.itemIndex,"config-index":t.configIndex,item:t.item,"credit-types-by-id":t.creditTypesById,class:"mt-3",i18n:r.value,"show-config-header":t.showConfigHeader},{"override-tooltip":e.withCtx(()=>[e.renderSlot(o.$slots,"override-tooltip",e.normalizeProps(e.guardReactiveProps(n)),void 0,!0)]),"price-line-additions":e.withCtx(()=>[e.renderSlot(o.$slots,"pricing-item-config-price-line-additions",e.normalizeProps(e.guardReactiveProps(d.value)),void 0,!0)]),included:e.withCtx(()=>{var n,o,i,a;return[l(t.item)&&(null==(n=t.config.default_included_volume)?void 0:n.amount)?(e.openBlock(),e.createElementBlock("span",{key:0,class:"mt-1 text-right text-gray-600",innerHTML:"BILLING_PERIOD"===t.config.default_included_volume.reset_type?r.value.includedVolumeAmountPerBillingPeriod(t.config.default_included_volume.amount):r.value.includedVolumeAmountPerSchedule(t.config.default_included_volume.amount)},null,8,SI)):e.createCommentVNode("",!0),s(t.item)&&(null==(o=t.config.default_included_volume)?void 0:o.number)?(e.openBlock(),e.createElementBlock("span",{key:1,class:"mt-1 text-right text-gray-600",innerHTML:"BILLING_PERIOD"===t.config.default_included_volume.reset_type?r.value.includedVolumeUnitsPerBillingPeriod(t.config.default_included_volume.number,null==(i=t.item.product_items)?void 0:i[0].unit_name):r.value.includedVolumeUnitsPerSchedule(t.config.default_included_volume.number,null==(a=t.item.product_items)?void 0:a[0].unit_name)},null,8,BI)):e.createCommentVNode("",!0),t.showDefaultValues&&c(t.item,t.config)&&m.value?(e.openBlock(),e.createElementBlock("span",{key:2,class:"mt-1 text-right text-gray-600",innerHTML:r.value.includedSeats(m.value)},null,8,NI)):e.createCommentVNode("",!0)]}),_:3},8,["is-combined-pricing","config","item-index","config-index","item","credit-types-by-id","i18n","show-config-header"])):e.createCommentVNode("",!0),o.$slots["pricing-item-config-additions"]&&!e.unref(QS)(null==(y=(v=o.$slots)["pricing-item-config-additions"])?void 0:y.call(v,d.value))?(e.openBlock(),e.createElementBlock("div",MI,[e.renderSlot(o.$slots,"pricing-item-config-additions",e.normalizeProps(e.guardReactiveProps(d.value)),void 0,!0)])):e.createCommentVNode("",!0)],64)):t.showConfigHeader?(e.openBlock(),e.createBlock(e.unref(tD),{key:1,"is-combined-pricing":t.pricing.products&&t.pricing.products.length>1,config:t.config,i18n:r.value,class:"mt-3"},{"override-tooltip":e.withCtx(()=>[e.renderSlot(o.$slots,"override-tooltip",e.normalizeProps(e.guardReactiveProps(n)),void 0,!0)]),_:3},8,["is-combined-pricing","config","i18n"])):e.createCommentVNode("",!0)],2),p.value?(e.openBlock(),e.createElementBlock("div",TI,[e.renderSlot(o.$slots,"pricing-item-config-settings",e.mergeProps(d.value,{rootConfig:h.value}),void 0,!0)])):e.createCommentVNode("",!0)]),u.value&&!e.unref(gS)(u.value)?(e.openBlock(),e.createElementBlock("ul",VI,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList([...u.value].sort((e,t)=>t.order-e.order),(n,i)=>(e.openBlock(),e.createElementBlock("li",{key:n.id},[e.createVNode(b,{pricing:t.pricing,item:t.item,"item-index":t.itemIndex,config:n,"config-index":i,"are-non-billable-items-visible":t.areNonBillableItemsVisible,i18n:r.value,"root-class":t.rootClass,"root-config":h.value,"credit-types-by-id":t.creditTypesById},{"pricing-item-config-settings":e.withCtx(t=>[e.renderSlot(o.$slots,"pricing-item-config-settings",e.mergeProps({ref_for:!0},t),void 0,!0)]),"override-tooltip":e.withCtx(t=>[e.renderSlot(o.$slots,"pricing-item-config-override-tooltip",e.mergeProps({ref_for:!0},t),void 0,!0)]),"pricing-item-config-additions":e.withCtx(t=>[e.renderSlot(o.$slots,"pricing-item-config-additions",e.mergeProps({ref_for:!0},t),void 0,!0)]),"pricing-item-config-price-line-additions":e.withCtx(t=>[e.renderSlot(o.$slots,"pricing-item-config-price-line-additions",e.mergeProps({ref_for:!0},t),void 0,!0)]),_:3},8,["pricing","item","item-index","config","config-index","are-non-billable-items-visible","i18n","root-class","root-config","credit-types-by-id"])]))),128))])):e.createCommentVNode("",!0)],2)}}}),[["__scopeId","data-v-8d2c7588"]]),zI=["onClick"],OI={class:"ml-1 text-gray-500"},II={key:0,class:"px-4 pb-3"},DI=e.defineComponent({__name:"PricingDetail",props:{itemClass:{},rootClass:{},titleWithIcon:{type:Boolean},pricing:{},groupedPricingItemIds:{},areNonBillableItemsVisible:{type:Boolean},i18n:{},schedule:{},creditTypesById:{}},setup(t){const n=HB(),r=t,o=e.ref({}),i=e=>!o.value[e],a=(e,t)=>{if(!t)return null;const n=new Map;return e.forEach(e=>{var t;if(!e.billing_period)return;const r=(o=e.billing_period)?`${o.type}:${o.value}`:"none";var o;n.has(r)||n.set(r,{billingPeriod:e.billing_period,configs:[]}),null==(t=n.get(r))||t.configs.push(e)}),Array.from(n.entries()).map(([e,t])=>({key:e,...t}))},l=e=>[...e].sort((e,t)=>t.order-e.order),s=e=>{var t,n;return(null==(t=e.configs)?void 0:t.length)?e.configs:(null==(n=e.billing_period_configs)?void 0:n.flatMap(e=>(e.configs??[]).map(t=>({...t,billing_period:e.billing_period}))))??[]},c=e=>{var t,n;return((null==(t=e.billing_period_configs)?void 0:t.length)??0)>0||((null==(n=r.groupedPricingItemIds)?void 0:n.includes(e.id))??!1)},d=e.computed(()=>{var e;return(null==(e=r.pricing.items)?void 0:e.map(e=>({id:e.id,groups:a(s(e),c(e))})))??[]}),u=e=>{const t=s(e),n=t.some(e=>"NONE"!==e.type),o=t.some(e=>"NONE"===e.type);return n||o&&!!r.areNonBillableItemsVisible};return(r,a)=>(e.openBlock(),e.createElementBlock("div",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.pricing.items,(a,c)=>{var p;return e.openBlock(),e.createElementBlock(e.Fragment,{key:c},[u(a)?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["pb-5 last:pb-3",{[`${t.itemClass}`]:t.itemClass}])},[e.createVNode(e.unref(LM),{icon:t.titleWithIcon?"inventory_2":void 0,variant:"neutral",size:"sm"},{default:e.withCtx(()=>[e.renderSlot(r.$slots,"pricing-item-header",{item:a},()=>[e.createVNode(cO,{item:a,"credit-types-by-id":t.creditTypesById},null,8,["item","credit-types-by-id"])])]),_:2},1032,["icon"]),(null==(p=d.value[c])?void 0:p.groups)?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(d.value[c].groups,s=>{var d,u,p;return e.openBlock(),e.createElementBlock("div",{key:s.key,class:"mt-3 rounded border border-gray-100"},[e.createElementVNode("button",{type:"button",class:"flex w-full items-center justify-between px-4 py-2 text-left text-sm font-semibold text-gray-700",onClick:e=>{return t=s.key,void(o.value={...o.value,[t]:!o.value[t]});var t}},[e.createElementVNode("span",null,[e.createTextVNode(e.toDisplayString((null==(d=t.i18n)?void 0:d.formatBillingPeriod)?e.unref(n).$t({defaultMessage:"Billing cycle",id:"pricing_detail.billing_cycle",description:"The billing cycle in the pricing detail card"}):"Billing cycle")+" ",1),e.createElementVNode("span",OI,e.toDisplayString(null==(p=null==(u=t.i18n)?void 0:u.formatBillingPeriod)?void 0:p.call(u,s.billingPeriod)),1)]),e.createVNode(e.unref(hc),{icon:i(s.key)?"unfold_less":"unfold_more",size:"sm"},null,8,["icon"])],8,zI),e.createVNode(e.unref(dV),null,{default:e.withCtx(()=>[i(s.key)?(e.openBlock(),e.createElementBlock("div",II,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l(s.configs),(n,o)=>(e.openBlock(),e.createBlock(AI,{key:n.id,pricing:t.pricing,item:a,"item-index":c,config:n,"config-index":o,"are-non-billable-items-visible":t.areNonBillableItemsVisible,i18n:t.i18n,"root-class":t.rootClass,schedule:t.schedule,"credit-types-by-id":t.creditTypesById},{"pricing-item-config-settings":e.withCtx(t=>[e.renderSlot(r.$slots,"pricing-item-config-settings",e.mergeProps({ref_for:!0},t))]),"override-tooltip":e.withCtx(t=>[e.renderSlot(r.$slots,"pricing-item-config-override-tooltip",e.mergeProps({ref_for:!0},t))]),"pricing-item-config-additions":e.withCtx(t=>[e.renderSlot(r.$slots,"pricing-item-config-additions",e.mergeProps({ref_for:!0},t))]),"pricing-item-config-price-line-additions":e.withCtx(t=>[e.renderSlot(r.$slots,"pricing-item-config-price-line-additions",e.mergeProps({ref_for:!0},t))]),_:3},8,["pricing","item","item-index","config","config-index","are-non-billable-items-visible","i18n","root-class","schedule","credit-types-by-id"]))),128))])):e.createCommentVNode("",!0)]),_:2},1024)])}),128)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(l(s(a)??[]),(n,o)=>(e.openBlock(),e.createBlock(AI,{key:n.id,pricing:t.pricing,item:a,"item-index":c,config:n,"config-index":o,"are-non-billable-items-visible":t.areNonBillableItemsVisible,i18n:t.i18n,"root-class":t.rootClass,schedule:t.schedule,"credit-types-by-id":t.creditTypesById},{"pricing-item-config-settings":e.withCtx(t=>[e.renderSlot(r.$slots,"pricing-item-config-settings",e.mergeProps({ref_for:!0},t))]),"override-tooltip":e.withCtx(t=>[e.renderSlot(r.$slots,"pricing-item-config-override-tooltip",e.mergeProps({ref_for:!0},t))]),"pricing-item-config-additions":e.withCtx(t=>[e.renderSlot(r.$slots,"pricing-item-config-additions",e.mergeProps({ref_for:!0},t))]),"pricing-item-config-price-line-additions":e.withCtx(t=>[e.renderSlot(r.$slots,"pricing-item-config-price-line-additions",e.mergeProps({ref_for:!0},t))]),_:3},8,["pricing","item","item-index","config","config-index","are-non-billable-items-visible","i18n","root-class","schedule","credit-types-by-id"]))),128))],2)):e.createCommentVNode("",!0)],64)}),128))]))}}),PI={...kI};var $I=(e=>(e.ENUM="ENUM",e.SWITCH="SWITCH",e.NUMBER="NUMBER",e.AMOUNT="AMOUNT",e.STRING="STRING",e))($I||{});const LI={...PI,revenueItems:"Revenue items",deductionItems:"Deduction items",features:"Features"},RI={class:"text-gray-500 uppercase text-xs font-semibold"},HI={class:"text-gray-500 uppercase text-xs font-semibold"},FI={key:2,class:"mt-2 group"},jI={class:"text-gray-500 uppercase text-xs font-semibold"},UI={key:0,class:"absolute right-0 top-1/2 -translate-y-1/2 transition opacity-0 group-hover:opacity-100 bg-white z-10"},GI={class:"pl-4"},qI={class:"mt-2"},ZI={class:"font-bold text-gray-700"},WI={key:1,class:"font-bold text-primary-600"},KI={key:2,class:"font-bold text-primary-600"},JI={key:4,class:"font-bold text-primary-600"},YI=e.defineComponent({__name:"PricingInfo",props:{pricing:{},groupedPricingItemIds:{},areNonBillableItemsVisible:{type:Boolean},i18n:{},schedule:{},creditTypesById:{}},setup(t){const n=t;e.provide("pricingId",n.pricing.id);const r=e.computed(()=>n.i18n??LI),o=e.computed(()=>{var e;return null==(e=n.pricing.items)?void 0:e.filter(e=>{return!!(null==(t=e.product_items)?void 0:t.every(OS));var t})}),i=e.computed(()=>{var e;return null==(e=n.pricing.items)?void 0:e.filter(e=>{return!!(t=e.product_items)&&t.length>0&&(null==t?void 0:t.every(IS));var t})});return(n,a)=>(e.openBlock(),e.createElementBlock("div",null,[e.renderSlot(n.$slots,"pricing-item-warning"),e.unref(gS)(o.value)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.unref(gS)(t.pricing.items)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(ZT),{key:0,class:"my-3"},{default:e.withCtx(()=>[e.createElementVNode("h3",RI,e.toDisplayString(r.value.revenueItems),1)]),_:1})),e.createVNode(e.unref(DI),{pricing:{...t.pricing,items:o.value},"grouped-pricing-item-ids":t.groupedPricingItemIds,i18n:r.value,"are-non-billable-items-visible":t.areNonBillableItemsVisible,schedule:t.schedule,"credit-types-by-id":t.creditTypesById},{"pricing-item-header":e.withCtx(({item:t})=>[e.renderSlot(n.$slots,"pricing-item-header",{item:t})]),"pricing-item-config-settings":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-settings",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-override-tooltip":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-override-tooltip",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-additions",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-price-line-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-price-line-additions",e.normalizeProps(e.guardReactiveProps(t)))]),_:3},8,["pricing","grouped-pricing-item-ids","i18n","are-non-billable-items-visible","schedule","credit-types-by-id"])],64)),e.unref(gS)(i.value)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[t.pricing.items&&t.pricing.items.length>0?(e.openBlock(),e.createBlock(e.unref(ZT),{key:0,class:"mt-6 mb-3"},{default:e.withCtx(()=>[e.createElementVNode("h3",HI,e.toDisplayString(r.value.deductionItems),1)]),_:1})):e.createCommentVNode("",!0),e.createVNode(e.unref(DI),{pricing:{...t.pricing,items:i.value},"grouped-pricing-item-ids":t.groupedPricingItemIds,i18n:r.value,"are-non-billable-items-visible":t.areNonBillableItemsVisible,"credit-types-by-id":t.creditTypesById},{"pricing-item-header":e.withCtx(({item:t})=>[e.renderSlot(n.$slots,"pricing-item-header",{item:t})]),"pricing-item-config-settings":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-settings",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-override-tooltip":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-override-tooltip",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-additions",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-price-line-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-price-line-additions",e.normalizeProps(e.guardReactiveProps(t)))]),_:3},8,["pricing","grouped-pricing-item-ids","i18n","are-non-billable-items-visible","credit-types-by-id"])],64)),e.unref(gS)(t.pricing.entitlements)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",FI,[e.createVNode(e.unref(ZT),{class:"relative"},{default:e.withCtx(()=>[e.createElementVNode("h3",jI,e.toDisplayString(r.value.features),1),n.$slots["pricing-entitlements-settings"]?(e.openBlock(),e.createElementBlock("div",UI,[e.createElementVNode("div",GI,[e.renderSlot(n.$slots,"pricing-entitlements-settings",{pricing:t.pricing})])])):e.createCommentVNode("",!0)]),_:3}),e.createElementVNode("ul",qI,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.pricing.entitlements,t=>(e.openBlock(),e.createElementBlock("li",{key:t.feature_id,class:"py-2 flex justify-between items-center"},[e.createElementVNode("span",ZI,e.toDisplayString(t.feature.name),1),t.feature.type===e.unref($I).AMOUNT&&t.amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.amount,highlighted:""},null,8,["value"])):e.createCommentVNode("",!0),t.feature.type===e.unref($I).NUMBER&&t.number?(e.openBlock(),e.createElementBlock("span",WI,e.toDisplayString(t.number),1)):e.createCommentVNode("",!0),t.feature.type===e.unref($I).STRING&&t.string?(e.openBlock(),e.createElementBlock("span",KI,e.toDisplayString(t.string),1)):e.createCommentVNode("",!0),t.feature.type===e.unref($I).SWITCH&&"switch"in t?(e.openBlock(),e.createElementBlock("div",{key:3,class:e.normalizeClass(["text-white rounded-full leading-[0.5] inline-block",t.switch?"bg-primary-600":"bg-red-500"])},[e.createVNode(e.unref(hc),{icon:t.switch?"check":"close",size:"xs"},null,8,["icon"])],2)):e.createCommentVNode("",!0),t.feature.type===e.unref($I).ENUM&&t.enum?(e.openBlock(),e.createElementBlock("span",JI,e.toDisplayString(t.enum),1)):e.createCommentVNode("",!0)]))),128))])]))]))}}),XI={class:"flex items-center gap-2"},QI={class:"flex items-center gap-2"},eD={key:0},tD=e.defineComponent({__name:"PricingItemConfigHeader",props:{config:{},i18n:{},hasTooltip:{type:Boolean,default:!0},isCombinedPricing:{type:Boolean}},setup(t){const n=t,r=e.computed(()=>n.i18n??mO),o=e.computed(()=>{var e,t;return!gS(null==(t=null==(e=n.config)?void 0:e.conditions)?void 0:t.meter_properties)});return(n,i)=>(e.openBlock(),e.createElementBlock("div",XI,[e.createElementVNode("div",QI,[e.createVNode(e.unref(gc),{class:"line-clamp-1","no-spacing":"",shade:"light",variant:"body",weight:"semibold"},{default:e.withCtx(()=>{var n,i,a,l,s,c;return[(null==(n=t.config.conditions)?void 0:n.name)||o.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(null==(i=t.config.conditions)?void 0:i.name)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(null==(a=t.config.conditions)?void 0:a.name),1)],64)):e.createCommentVNode("",!0),o.value&&(null==(s=null==(l=t.config)?void 0:l.conditions)?void 0:s.meter_properties)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[t.hasTooltip&&(null==(c=t.config.conditions)?void 0:c.name)?(e.openBlock(),e.createBlock(e.unref(bV),{key:0,variant:"outline",class:"ml-1"},{default:e.withCtx(()=>[e.createVNode(e.unref(hc),{icon:"help",size:"2xs",class:"rounded drop-shadow-sm hover:bg-gray-50 hover:cursor-default"})]),tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[e.createVNode(e.unref(gc),{variant:"body-sm","no-spacing":"",shade:"light"},{default:e.withCtx(()=>{var n,r;return[e.createVNode(e.unref(aO),{comparators:null==(r=null==(n=t.config)?void 0:n.conditions)?void 0:r.meter_properties},null,8,["comparators"])]}),_:1})]),_:1})]),_:1})):(e.openBlock(),e.createBlock(e.unref(gc),{key:1,weight:"normal",shade:"light",tag:"span"},{default:e.withCtx(()=>{var n,r,o;return[(null==(n=t.config.conditions)?void 0:n.name)?(e.openBlock(),e.createElementBlock("span",eD," - ")):e.createCommentVNode("",!0),e.createVNode(e.unref(aO),{comparators:null==(o=null==(r=t.config)?void 0:r.conditions)?void 0:o.meter_properties,display:"inline"},null,8,["comparators"])]}),_:1}))],64)):e.createCommentVNode("",!0)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(r.value.defaultPricing),1)],64))]}),_:1}),t.config.volume_group_reference?(e.openBlock(),e.createBlock(e.unref(rO),{key:0,i18n:r.value.combinedVolume},null,8,["i18n"])):e.createCommentVNode("",!0),e.unref(RS)(t.config)?(e.openBlock(),e.createBlock(e.unref(hO),{key:1,i18n:r.value.topUpChip,"pricing-item-config":t.config},null,8,["i18n","pricing-item-config"])):e.createCommentVNode("",!0)]),e.renderSlot(n.$slots,"override-tooltip")]))}}),nD=e=>"cancellationDate"in e,rD=e=>"schedule"in e,oD={...LI,volumePooling:"Volume pooling",addon:"Addon",someItemsDeprecatedWarning:"Some of the product items are deprecated. They cannot be used for pricing and needs to be deleted",allItemsDeprecatedWarning:"All product items are deprecated, this pricing needs to be deleted"},iD={addon:oD.addon,singleSelect:"Single select",multiSelect:"Multi select"},aD={...iD,...oD,productsCount:e=>0===e?"no products":1===e?"1 product":`${e} products`},lD={...PS,and:"and"},sD={...lD,or:"or",unsupported:"unsupported",product:"product",revenueItem:"revenue item",commitmentBody:(e,t,n)=>`Commitment on ${e} <strong>${t}</strong> ${n}`,startOfSchedule:"Start of schedule",endOfSchedule:"End of schedule",unknown:"unknown",products:e=>1===e?"product":"products",pluralRevenueItems:e=>1===e?"revenue item":"revenue items",pricingRule:"price rule",invoice:"invoice",units:e=>`${e} units`,commitmentOnInvoice:e=>`Commitment on <strong>Invoice</strong> ${e}`,basedOnMeterValue:"based on meter value"},cD={class:"flex justify-between items-center"},dD={class:"flex items-center gap-2"},uD={key:0,class:"ml-3 flex gap-3 opacity-0 group-hover:opacity-100 focus-within:opacity-100 transition-opacity"},pD=e.defineComponent({__name:"CommitmentDiscountItem",props:{icon:{},iconColor:{},isEditable:{type:Boolean},isRemovable:{type:Boolean},error:{}},emits:["edit","delete"],setup:t=>(n,r)=>(e.openBlock(),e.createBlock(e.unref(PM),{spacing:"none","root-class":"p-2 pr-3 group"},{default:e.withCtx(()=>[e.createElementVNode("div",cD,[e.createElementVNode("div",dD,[e.createVNode(e.unref(hc),{icon:t.icon,size:"sm",variant:"contained",class:e.normalizeClass(["p-1",{"bg-orange-50 text-orange-700":"orange"===t.iconColor,"bg-yellow-50 text-yellow-700":"yellow"===t.iconColor}])},null,8,["icon","class"]),e.createVNode(e.unref(gc),{variant:"body-sm","no-spacing":""},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"body")]),_:3})]),t.isEditable||t.isRemovable?(e.openBlock(),e.createElementBlock("div",uD,[t.isEditable?(e.openBlock(),e.createBlock(e.unref(gN),{key:0,variant:"ghost",color:"gray",square:"","icon-prefix":"edit",onClick:r[0]||(r[0]=e=>n.$emit("edit"))})):e.createCommentVNode("",!0),t.isRemovable?(e.openBlock(),e.createBlock(e.unref(gN),{key:1,variant:"ghost",color:"red",square:"","icon-prefix":"delete",onClick:r[1]||(r[1]=e=>n.$emit("delete"))})):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createVNode(e.unref(dV),null,{default:e.withCtx(()=>[t.error?(e.openBlock(),e.createBlock(e.unref(JB),{key:0,type:"danger",class:"mt-2 -mb-2 -mr-3 -ml-2 rounded-tl-none rounded-tr-none rounded-bl-md rounded-br-md"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(Cx)(t.error)),1)]),_:1})):e.createCommentVNode("",!0)]),_:1})]),_:3}))}),hD={class:"font-semibold"},mD={key:2,class:"text-primary-600 font-semibold"},fD=["innerHTML"],gD=["innerHTML"],vD={key:2},yD=e.defineComponent({__name:"SubscriptionCommitmentItem",props:{commitment:{},pricingPlanVersion:{},isEditable:{type:Boolean},isRemovable:{type:Boolean},error:{},i18n:{},timezone:{}},emits:["edit","delete"],setup(t){const n=t,r=e.computed(()=>n.i18n??sD),{getCommitmentBody:o,getFormattedDuration:i}=((t,n=sD,r)=>{const{formatDate:o}=HB(),i=e.computed(()=>{var e,n;return(null==(n=null==(e=t.value)?void 0:e.pricing_categories)?void 0:n.flatMap(e=>{var t;return[...(null==(t=e.pricing_groups)?void 0:t.flatMap(e=>e.pricings))??[],...e.pricings??[]]}))??[]}),a=e.computed(()=>i.value.map(e=>{var t;return{pricing:e,product:null==(t=e.products)?void 0:t[0],pricingId:e.id}})),l=e.computed(()=>{var e;return(null==(e=i.value)?void 0:e.flatMap(e=>{var t;return(null==(t=e.items)?void 0:t.map(e=>{var t;return{productItem:null==(t=e.product_items)?void 0:t[0],pricingItemId:e.id}}))??[]}))??[]}),s=e=>{var t,r,o,s,d;switch(e.commitmentLevel){case"PRODUCTS":{const n=null==(t=e.ids)?void 0:t.map(e=>a.value.find(t=>t.pricingId===e));return c((null==n?void 0:n.map(e=>{var t;return(null==e?void 0:e.pricing.name)??((null==(t=null==e?void 0:e.product)?void 0:t.name)||"")}))??[])}case"REVENUE_ITEMS":{const t=null==(r=e.ids)?void 0:r.map(e=>{var t;return null==(t=l.value.find(t=>t.pricingItemId===e))?void 0:t.productItem});return c((null==t?void 0:t.map(e=>(null==e?void 0:e.name)||""))??[])}case"PRICING_RULE":{const t=t=>{var n;return t.id===(null==(n=e.ids)?void 0:n[0])},r=e=>{var n,o;return t(e)||!!(null==(o=null==(n=e.conditions)?void 0:n.configs)?void 0:o.some(r))},a=e=>{var t;return null==(t=e.configs)?void 0:t.some(r)},l=e=>{var t;return null==(t=e.items)?void 0:t.some(a)},c=null==(o=i.value)?void 0:o.find(l),u=null==(s=null==c?void 0:c.items)?void 0:s.find(a),p=null==(d=null==u?void 0:u.configs)?void 0:d.flatMap(jS),h=null==p?void 0:p.find(t);return`<strong>${US(n)({pricing:c,item:u,config:h})}</strong>`}}},c=e=>e.reduce((t,n,r)=>{const o=`<strong>${n}</strong>`;return 0===r?o:r===e.length-1?[t,o].join(" and "):[t,o].join(", ")},""),d=e=>{var t,r;switch(e.commitmentLevel){case"PRODUCTS":return n.products((null==(t=e.ids)?void 0:t.length)??0);case"REVENUE_ITEMS":return n.pluralRevenueItems((null==(r=e.ids)?void 0:r.length)??0);case"PRICING_RULE":return n.pricingRule;case"INVOICE":return n.invoice}},u=e=>{if(!e.start_at&&!e.end_at)return"";let t,i;return e.start_at||(t=n.startOfSchedule),e.end_at||(i=n.endOfSchedule),e.start_at&&(t=o(r?{date:e.start_at,format:"date",offsetType:"offsetted",timezone:r}:{date:e.start_at,format:"date",offsetType:"local",showTimezone:!1})),e.end_at&&(i=o(r?{date:e.end_at,format:"date",offsetType:"offsetted",timezone:r}:{date:e.end_at,format:"date",offsetType:"local",showTimezone:!1})),`(${t} - ${i})`};return{getCommitmentBody:e=>n.commitmentBody(d(e),s(e)??"",u(e)),getFormattedDuration:u}})(e.computed(()=>n.pricingPlanVersion),r.value,n.timezone);return(n,a)=>(e.openBlock(),e.createBlock(pD,{icon:"handshake","icon-color":"orange","is-editable":t.isEditable,"is-removable":t.isRemovable,error:t.error,onEdit:a[0]||(a[0]=e=>n.$emit("edit")),onDelete:a[1]||(a[1]=e=>n.$emit("delete"))},{body:e.withCtx(()=>{var n;return[e.createElementVNode("span",hD,[t.commitment.amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.commitment.amount,highlighted:""},null,8,["value"])):"meter_value_calculation"in t.commitment&&(null==(n=t.commitment.meter_value_calculation)?void 0:n.amount)?(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:t.commitment.meter_value_calculation.amount,highlighted:""},null,8,["value"])):"meter_value_calculation"in t.commitment&&t.commitment.meter_value_calculation&&"number"in t.commitment.meter_value_calculation?(e.openBlock(),e.createElementBlock("span",mD,e.toDisplayString(t.commitment.meter_value_calculation.number&&r.value.units(t.commitment.meter_value_calculation.number)),1)):e.createCommentVNode("",!0)]),a[2]||(a[2]=e.createTextVNode(" ",-1)),"INVOICE"===t.commitment.commitmentLevel?(e.openBlock(),e.createElementBlock("span",{key:0,innerHTML:r.value.commitmentOnInvoice(e.unref(i)(t.commitment))},null,8,fD)):(e.openBlock(),e.createElementBlock("span",{key:1,innerHTML:e.unref(o)(t.commitment)},null,8,gD)),"meter_value_calculation"in t.commitment&&t.commitment.meter_value_calculation&&"amount"in t.commitment.meter_value_calculation?(e.openBlock(),e.createElementBlock("span",vD,e.toDisplayString(" ")+"("+e.toDisplayString(r.value.basedOnMeterValue)+")",1)):e.createCommentVNode("",!0)]}),_:1},8,["is-editable","is-removable","error"]))}}),bD={...sD,title:"Commitments",orderOfApplicationExplanation:"Commitments are applied after discounts on invoices",description:"Setup a minimum usage per an agreed-upon time period.",selectPricingPlanHint:"Please select a pricing plan to add commitments",addItemLabel:"Add commitment",notEditableExplanation:"Commitments can't be edited for active schedules"},wD=({isEditable:t,isRemovable:n})=>({isEditableFlag:e.computed(()=>"function"==typeof t||!!t),isItemEditable:e=>"function"==typeof t?t(e):!!t,isItemRemovable:e=>"function"==typeof n?n(e):"boolean"!=typeof n||n}),kD={class:"flex justify-between items-center gap-4"},xD={class:"flex gap-4 items-center"},_D={class:"flex items-center gap-1"},CD={class:"mt-1 text-xs text-gray-500"},ED={class:"flex justify-between items-center gap-4"},SD={class:"flex items-center gap-1"},BD={class:"text-xs uppercase font-bold text-gray-700"},ND={class:"mt-1 flex flex-col gap-2"},MD=e.defineComponent({__name:"CommitmentDiscountsSection",props:{title:{},orderOfApplicationExplanation:{},description:{},selectPricingPlanHint:{},addItemLabel:{},notEditableExplanation:{},hasItems:{type:Boolean},pricingPlanVersionIsSelected:{type:Boolean},isEditable:{type:Boolean},isCreatable:{type:Boolean}},emits:["add"],setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("section",null,[t.hasItems?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("header",ED,[e.createElementVNode("div",SD,[e.createElementVNode("h2",BD,e.toDisplayString(t.title),1),e.createVNode(e.unref(bV),{variant:"outline",placement:"bottom-start"},{default:e.withCtx(()=>[e.createVNode(e.unref(hc),{icon:"help",class:"drop-shadow-sm hover:bg-gray-50 hover:cursor-default",size:"xs"})]),tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[e.createVNode(e.unref(Cz),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.orderOfApplicationExplanation),1)]),_:1})]),_:1})]),_:1})])]),e.createElementVNode("ul",ND,[e.renderSlot(n.$slots,"list-items")])],64)):(e.openBlock(),e.createBlock(e.unref(PM),{key:0},{default:e.withCtx(()=>[e.createElementVNode("div",kD,[e.createElementVNode("div",xD,[e.renderSlot(n.$slots,"icon"),e.createElementVNode("div",null,[e.createElementVNode("div",_D,[e.createVNode(e.unref(gc),{tag:"h2",variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.title),1)]),_:1}),e.createVNode(e.unref(bV),{variant:"outline",placement:"bottom-start"},{default:e.withCtx(()=>[e.createVNode(e.unref(hc),{icon:"help",class:"drop-shadow-sm hover:bg-gray-50 hover:cursor-default",size:"xs"})]),tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[e.createVNode(e.unref(Cz),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.orderOfApplicationExplanation),1)]),_:1})]),_:1})]),_:1})]),e.createElementVNode("p",CD,e.toDisplayString(t.description),1)])]),t.isEditable?(e.openBlock(),e.createBlock(e.unref(bV),{key:0,variant:"outline"},{tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[t.pricingPlanVersionIsSelected?t.isEditable?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(gc),{key:1,variant:"body-sm","no-spacing":"",class:"text-gray-600"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.notEditableExplanation),1)]),_:1})):(e.openBlock(),e.createBlock(e.unref(gc),{key:0,variant:"body-sm","no-spacing":"",class:"text-gray-600"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.selectPricingPlanHint),1)]),_:1}))]),_:1})]),_:1})):e.createCommentVNode("",!0)])]),_:3}))]))}),TD=["src"],VD=e.defineComponent({__name:"SubscriptionCommitments",props:{pricingPlanVersion:{},commitment:{},i18n:{},isCreatable:{type:Boolean},isEditable:{type:[Boolean,Function]},isRemovable:{type:[Boolean,Function]},error:{},timezone:{}},setup(t){const n=t,r=e.computed(()=>n.i18n??bD),{isEditableFlag:o,isItemEditable:i,isItemRemovable:a}=wD({isEditable:n.isEditable,isRemovable:n.isRemovable}),l=e.computed(()=>{if("error"in n)return(e=>{const t=Object.entries(e||{});if(0===t.length)return;const[n,r]=t[0],[o,i,a]=n.split(".");return{commitmentLevel:o,index:parseInt(i,10),fieldName:a,message:r}})(n.error)}),s=e.computed(()=>{var e,t,r,o,i,a,s,c;return[...(null==(t=null==(e=n.commitment)?void 0:e.pricing_item_configs)?void 0:t.map((e,t)=>{var n,r;return{item:{commitmentLevel:"PRICING_RULE",...e},error:t===(null==(n=l.value)?void 0:n.index)&&"pricing_item_configs"===(null==(r=l.value)?void 0:r.commitmentLevel)?l.value.message:void 0}}))||[],...(null==(o=null==(r=n.commitment)?void 0:r.pricing_items)?void 0:o.map((e,t)=>{var n,r;return{item:{commitmentLevel:"REVENUE_ITEMS",...e},error:t===(null==(n=l.value)?void 0:n.index)&&"pricing_items"===(null==(r=l.value)?void 0:r.commitmentLevel)?l.value.message:void 0}}))||[],...(null==(a=null==(i=n.commitment)?void 0:i.pricings)?void 0:a.map((e,t)=>{var n,r;return{item:{commitmentLevel:"PRODUCTS",...e},error:t===(null==(n=l.value)?void 0:n.index)&&"pricings"===(null==(r=l.value)?void 0:r.commitmentLevel)?l.value.message:void 0}}))||[],...(null==(c=null==(s=n.commitment)?void 0:s.totals)?void 0:c.map((e,t)=>{var n,r;return{item:{commitmentLevel:"INVOICE",...e},error:t===(null==(n=l.value)?void 0:n.index)&&"totals"===(null==(r=l.value)?void 0:r.commitmentLevel)?l.value.message:void 0}}))||[]]});return(n,l)=>(e.openBlock(),e.createBlock(MD,{title:r.value.title,"order-of-application-explanation":r.value.orderOfApplicationExplanation,description:r.value.description,"pricing-plan-version-is-selected":!!t.pricingPlanVersion,"select-pricing-plan-hint":r.value.selectPricingPlanHint,"add-item-label":r.value.addItemLabel,"not-editable-explanation":r.value.notEditableExplanation,"is-creatable":!!t.isCreatable,"is-editable":e.unref(o),"has-items":s.value.length>0,onAdd:l[0]||(l[0]=e=>n.$emit("add"))},{icon:e.withCtx(()=>[e.createElementVNode("img",{src:e.unref("data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='44'%20height='44'%20fill='none'%3e%3cmask%20id='a'%20style='mask-type:alpha'%20maskUnits='userSpaceOnUse'%20x='0'%20y='0'%20width='44'%20height='44'%3e%3cpath%20fill='%23D9D9D9'%20d='M0%200h44v44H0z'/%3e%3c/mask%3e%3cg%20mask='url(%23a)'%3e%3cmask%20id='e'%20fill='%23fff'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M2.922%2015.593A6%206%200%200%200%208.03%208.816c-.072-.516.251-1.035.767-1.108l21.957-3.086c.516-.072.97.338%201.043.854a6%206%200%200%200%206.776%205.106c.589-.082%201.19.281%201.273.87L42.06%2027.22c.083.589-.395%201.104-.984%201.186a6%206%200%200%200-5.106%206.777c.074.525-.255%201.055-.78%201.13l-21.925%203.08c-.526.074-.988-.344-1.062-.87a6%206%200%200%200-6.776-5.107c-.452.064-.901-.223-.965-.674L2.182%2016.507c-.064-.451.29-.85.74-.914Z'/%3e%3c/mask%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M2.922%2015.593A6%206%200%200%200%208.03%208.816c-.072-.516.251-1.035.767-1.108l21.957-3.086c.516-.072.97.338%201.043.854a6%206%200%200%200%206.776%205.106c.589-.082%201.19.281%201.273.87L42.06%2027.22c.083.589-.395%201.104-.984%201.186a6%206%200%200%200-5.106%206.777c.074.525-.255%201.055-.78%201.13l-21.925%203.08c-.526.074-.988-.344-1.062-.87a6%206%200%200%200-6.776-5.107c-.452.064-.901-.223-.965-.674L2.182%2016.507c-.064-.451.29-.85.74-.914Z'%20fill='%23D9D9D9'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M2.922%2015.593A6%206%200%200%200%208.03%208.816c-.072-.516.251-1.035.767-1.108l21.957-3.086c.516-.072.97.338%201.043.854a6%206%200%200%200%206.776%205.106c.589-.082%201.19.281%201.273.87L42.06%2027.22c.083.589-.395%201.104-.984%201.186a6%206%200%200%200-5.106%206.777c.074.525-.255%201.055-.78%201.13l-21.925%203.08c-.526.074-.988-.344-1.062-.87a6%206%200%200%200-6.776-5.107c-.452.064-.901-.223-.965-.674L2.182%2016.507c-.064-.451.29-.85.74-.914Z'%20fill='%23BFEAFB'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M2.922%2015.593A6%206%200%200%200%208.03%208.816c-.072-.516.251-1.035.767-1.108l21.957-3.086c.516-.072.97.338%201.043.854a6%206%200%200%200%206.776%205.106c.589-.082%201.19.281%201.273.87L42.06%2027.22c.083.589-.395%201.104-.984%201.186a6%206%200%200%200-5.106%206.777c.074.525-.255%201.055-.78%201.13l-21.925%203.08c-.526.074-.988-.344-1.062-.87a6%206%200%200%200-6.776-5.107c-.452.064-.901-.223-.965-.674L2.182%2016.507c-.064-.451.29-.85.74-.914Z'%20fill='url(%23b)'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M2.922%2015.593A6%206%200%200%200%208.03%208.816c-.072-.516.251-1.035.767-1.108l21.957-3.086c.516-.072.97.338%201.043.854a6%206%200%200%200%206.776%205.106c.589-.082%201.19.281%201.273.87L42.06%2027.22c.083.589-.395%201.104-.984%201.186a6%206%200%200%200-5.106%206.777c.074.525-.255%201.055-.78%201.13l-21.925%203.08c-.526.074-.988-.344-1.062-.87a6%206%200%200%200-6.776-5.107c-.452.064-.901-.223-.965-.674L2.182%2016.507c-.064-.451.29-.85.74-.914Z'%20fill='url(%23c)'/%3e%3cpath%20d='m39.845%2011.452-1.09.153%201.09-.153Zm-9.092-6.83.153%201.09-.153-1.09Zm11.308%2022.599%201.09-.153-1.09.153ZM8.796%207.708%208.643%206.62l.153%201.09ZM6.94%208.97a4.9%204.9%200%200%201-4.17%205.534l.306%202.179a7.1%207.1%200%200%200%206.042-8.019l-2.178.306ZM30.6%203.533%208.643%206.62l.306%202.179%2021.957-3.086-.306-2.179Zm7.819%205.96a4.9%204.9%200%200%201-5.534-4.17l-2.179.306a7.1%207.1%200%200%200%208.02%206.043l-.307-2.179Zm4.731%2017.575-2.216-15.77-2.179.307%202.217%2015.769%202.178-.306Zm-6.09%207.963a4.9%204.9%200%200%201%204.17-5.534l-.306-2.179a7.1%207.1%200%200%200-6.043%208.019l2.179-.306Zm-23.641%205.453%2021.924-3.081-.306-2.179-21.924%203.081.306%202.179ZM5.58%2034.507a4.9%204.9%200%200%201%205.534%204.17l2.178-.306a7.1%207.1%200%200%200-8.018-6.043l.306%202.179ZM1.092%2016.66l2.282%2016.236%202.179-.306L3.27%2016.354l-2.179.306Zm2.179-.306a.333.333%200%200%201-.066.254.202.202%200%200%201-.13.074l-.306-2.179c-.95.134-1.838%201.008-1.677%202.157l2.179-.306Zm9.841%2021.951a.244.244%200%200%201%20.105.009c.031.01.05.023.06.03.014.013.016.02.017.027l-2.179.306c.142%201.008%201.064%201.981%202.304%201.807l-.306-2.179Zm21.77-2.968c-.002-.006-.002-.014.009-.03a.168.168%200%200%201%20.048-.046.244.244%200%200%201%20.098-.037l.306%202.179c1.24-.175%201.859-1.365%201.717-2.372l-2.179.306Zm3.843-23.665a.117.117%200%200%201%20.069.012c.003.002-.005-.002-.015-.017a.153.153%200%200%201-.024-.062l2.179-.306c-.185-1.317-1.46-1.954-2.515-1.806l.306%202.179ZM5.275%2032.328a.202.202%200%200%201%20.144.036.332.332%200%200%201%20.134.226l-2.179.306c.162%201.15%201.255%201.745%202.207%201.61l-.306-2.178ZM30.906%205.712a.258.258%200%200%201-.11-.01.186.186%200%200%201-.065-.033c-.019-.016-.023-.028-.025-.04l2.179-.306c-.14-1-1.057-1.963-2.285-1.79l.306%202.179Zm10.066%2021.662a.153.153%200%200%201%20.005-.066c.006-.018.012-.024.01-.02a.115.115%200%200%201-.062.03l.305%202.179c1.056-.149%202.105-1.112%201.92-2.43l-2.178.307ZM9.118%208.663c.002.012.001.025-.012.045a.186.186%200%200%201-.053.05.258.258%200%200%201-.104.04l-.306-2.179c-1.229.173-1.844%201.35-1.703%202.35l2.178-.306Z'%20fill='url(%23d)'%20fill-opacity='.1'%20mask='url(%23e)'/%3e%3cg%20opacity='.5'%3e%3cmask%20id='f'%20style='mask-type:alpha'%20maskUnits='userSpaceOnUse'%20x='10'%20y='10'%20width='24'%20height='24'%3e%3cpath%20transform='rotate(-8%2010.706%2013.489)'%20fill='%23D9D9D9'%20d='M10.706%2013.489h20v20h-20z'/%3e%3c/mask%3e%3cg%20mask='url(%23f)'%3e%3cpath%20d='M22.825%2028.616a.486.486%200%200%200%20.271-.164l5.816-7.718a1.54%201.54%200%200%200%20.283-.608%201.804%201.804%200%200%200-.176-1.248%201.375%201.375%200%200%200-.435-.475l-4-3.014a1.376%201.376%200%200%200-.577-.288%201.775%201.775%200%200%200-1.248.176%201.54%201.54%200%200%200-.506.44l-.195.258%201.744%201.333c.233.163.416.362.547.596.13.234.215.489.254.764.081.577-.047%201.09-.383%201.537-.337.447-.795.711-1.372.792a2.245%202.245%200%200%201-.815-.033%201.895%201.895%200%200%201-.731-.339l-1.762-1.309-3.103%204.118a.393.393%200%200%200-.083.306c.015.11.07.204.166.282a.386.386%200%200%200%20.307.094.484.484%200%200%200%20.271-.164l2.412-3.201%201.318.993-2.391%203.197a.394.394%200%200%200-.083.306.4.4%200%200%200%20.164.272.4.4%200%200%200%20.306.083.486.486%200%200%200%20.271-.164l2.415-3.18%201.318.993-2.39%203.197a.25.25%200%200%200-.076.137.472.472%200%200%200-.008.17.4.4%200%200%200%20.164.27.4.4%200%200%200%20.578-.08l2.414-3.18%201.318.993-2.412%203.2a.394.394%200%200%200-.083.306c.016.11.074.2.175.27.101.07.207.098.317.082Zm.21%201.654a2.033%202.033%200%200%201-1.422-.316%201.99%201.99%200%200%201-.869-1.172%202.054%202.054%200%200%201-1.257-.412%202.054%202.054%200%200%201-.743-1.095%201.979%201.979%200%200%201-1.248-.424%202.12%202.12%200%200%201-.731-1.086%201.982%201.982%200%200%201-1.375-.5%202.046%202.046%200%200%201-.687-1.293%202.119%202.119%200%200%201%20.043-.816c.068-.269.184-.513.35-.733l4.116-5.438%203.083%202.323a.25.25%200%200%200%20.137.075.47.47%200%200%200%20.169.008.445.445%200%200%200%20.294-.157.39.39%200%200%200%20.081-.317.473.473%200%200%200-.054-.16.25.25%200%200%200-.11-.111l-3.365-2.536a1.377%201.377%200%200%200-.577-.287%201.778%201.778%200%200%200-1.248.176%201.538%201.538%200%200%200-.506.44l-2.497%203.337c-.107.142-.19.3-.249.477-.06.177-.091.35-.095.518a1.57%201.57%200%200%200%20.304.968l-1.029%201.364a3.313%203.313%200%200%201-.662-.969%203.273%203.273%200%200%201-.154-2.293c.114-.387.295-.746.543-1.075l2.5-3.318c.286-.363.62-.655%201.003-.877a3.316%203.316%200%200%201%203.68.219l.26.195.195-.259c.285-.363.62-.655%201.002-.877a3.316%203.316%200%200%201%203.68.219l3.977%202.996a3.393%203.393%200%200%201%201.3%202.216c.06.426.036.854-.072%201.283a3.282%203.282%200%200%201-.57%201.185l-5.818%207.697c-.166.22-.368.402-.607.548a2.002%202.002%200%200%201-.771.277Z'%20fill='%23222B35'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3clinearGradient%20id='b'%20x1='1.097'%20y1='10.89'%20x2='36.001'%20y2='44.744'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23FF6200'/%3e%3cstop%20offset='1'%20stop-color='%23FF6200'%20stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient%20id='c'%20x1='40.312'%20y1='5.379'%20x2='16.092'%20y2='47.542'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23fff'/%3e%3cstop%20offset='1'%20stop-color='%23fff'%20stop-opacity='.4'/%3e%3c/linearGradient%3e%3clinearGradient%20id='d'%20x1='24.991'%20y1='38.635'%20x2='20.304'%20y2='5.283'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%230C0E41'/%3e%3cstop%20offset='1'%20stop-color='%230C0E41'%20stop-opacity='.5'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e"),alt:""},null,8,TD)]),"list-items":e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,({item:o,error:l})=>(e.openBlock(),e.createElementBlock("li",{key:JSON.stringify(o)},[e.createVNode(yD,{timezone:t.timezone,commitment:o,error:l,"is-editable":e.unref(i)(o),"is-removable":e.unref(a)(o),"pricing-plan-version":t.pricingPlanVersion,i18n:r.value,onEdit:e=>n.$emit("edit",o),onDelete:e=>n.$emit("delete",o)},null,8,["timezone","commitment","error","is-editable","is-removable","pricing-plan-version","i18n","onEdit","onDelete"])]))),128))]),_:1},8,["title","order-of-application-explanation","description","pricing-plan-version-is-selected","select-pricing-plan-hint","add-item-label","not-editable-explanation","is-creatable","is-editable","has-items"]))}}),AD=(t,n,r)=>{const{formatDate:o}=HB(),i=e.computed(()=>{var e,n;return null==(n=null==(e=t.value)?void 0:e.pricing_categories)?void 0:n.flatMap(e=>{var t;return[...(null==(t=e.pricing_groups)?void 0:t.flatMap(e=>e.pricings))??[],...e.pricings??[]]})}),a=e=>{if(!e.start_at&&!e.end_at)return"";let t,i;return e.start_at||(t=n.startOfSchedule),e.end_at||(i=n.endOfSchedule),e.start_at&&(t=o(r?{date:e.start_at,format:"date",offsetType:"offsetted",timezone:r}:{date:e.start_at,format:"date",offsetType:"local",showTimezone:!1})),e.end_at&&(i=o(r?{date:e.end_at,format:"date",offsetType:"offsetted",timezone:r}:{date:e.end_at,format:"date",offsetType:"local",showTimezone:!1})),`(${t} - ${i})`};return{getDiscountBody:e=>{let t;switch(e.discountLevel){case"PRODUCT":t=n.product;break;case"REVENUE_ITEM":t=n.revenueItem;break;case"PRICING_RULE":t=n.pricingRule}return n.discountBody(t??"",(e=>{var t,r,o,a,l,s,c,d,u,p;let h,m;switch(e.discountLevel){case"PRODUCT":h=null==(t=i.value)?void 0:t.find(t=>{var n;return t.id===(null==(n=e.ids)?void 0:n[0])});break;case"REVENUE_ITEM":{const t=t=>{var n;return t.id===(null==(n=e.ids)?void 0:n[0])};h=null==(r=i.value)?void 0:r.find(e=>{var n;return null==(n=e.items)?void 0:n.some(t)}),m=null==(o=null==h?void 0:h.items)?void 0:o.find(t);break}case"PRICING_RULE":{const t=t=>{var n;return t.id===(null==(n=e.ids)?void 0:n[0])},r=e=>{var n,o;return t(e)||!!(null==(o=null==(n=e.conditions)?void 0:n.configs)?void 0:o.some(r))},o=e=>{var t;return null==(t=e.configs)?void 0:t.some(r)},c=e=>{var t;return null==(t=e.items)?void 0:t.some(o)},d=null==(a=i.value)?void 0:a.find(c),u=null==(l=null==d?void 0:d.items)?void 0:l.find(o),p=null==(s=null==u?void 0:u.configs)?void 0:s.flatMap(jS),h=null==p?void 0:p.find(t);return`<strong>${US(n)({pricing:d,item:u,config:h})}</strong>`}}return[(null==h?void 0:h.name)??(null==(d=null==(c=null==h?void 0:h.products)?void 0:c[0])?void 0:d.name),null==(p=null==(u=null==m?void 0:m.product_items)?void 0:u[0])?void 0:p.name].filter(Boolean).join(" - ")})(e)??"",a(e))},getFormattedDuration:a}},zD={...lD,product:"product",revenueItem:"revenue item",pricingRule:"price rule",discountBody:(e,t,n)=>`Discount on ${e} <strong>${t}</strong> ${n}`,startOfSchedule:"Start of schedule",endOfSchedule:"End of schedule",discountOnInvoice:e=>`Discount on <strong>Invoice</strong> ${e}`,or:"or",unsupported:"unsupported",unknown:"unknown"},OD={class:"font-semibold"},ID={key:1,class:"text-primary-600"},DD=["innerHTML"],PD=["innerHTML"],$D=e.defineComponent({__name:"SubscriptionDiscountItem",props:{discount:{},pricingPlanVersion:{},isEditable:{type:Boolean},isRemovable:{type:Boolean},i18n:{},error:{},timezone:{}},emits:["edit","delete"],setup(t,{emit:n}){const r=t,o=n,i=e.computed(()=>r.i18n??zD),{getDiscountBody:a,getFormattedDuration:l}=AD(e.toRef(()=>r.pricingPlanVersion),i.value,r.timezone);return(n,r)=>(e.openBlock(),e.createBlock(pD,{icon:"south_east","icon-color":"yellow","is-editable":t.isEditable,"is-removable":t.isRemovable,error:t.error,onEdit:r[0]||(r[0]=e=>o("edit")),onDelete:r[1]||(r[1]=e=>o("delete"))},{body:e.withCtx(()=>{var n,o,s;return[e.createElementVNode("span",OD,[(null==(n=t.discount.amount)?void 0:n.quantity)?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.discount.amount,highlighted:""},null,8,["value"])):t.discount.percentage?(e.openBlock(),e.createElementBlock("span",ID,e.toDisplayString(t.discount.percentage)+"%",1)):e.createCommentVNode("",!0)]),r[2]||(r[2]=e.createTextVNode(" ",-1)),"INVOICE"===t.discount.discountLevel?(e.openBlock(),e.createElementBlock("span",{key:0,innerHTML:null==(s=(o=i.value).discountOnInvoice)?void 0:s.call(o,e.unref(l)(t.discount))},null,8,DD)):(e.openBlock(),e.createElementBlock("span",{key:1,innerHTML:e.unref(a)(t.discount)},null,8,PD))]}),_:1},8,["is-editable","is-removable","error"]))}}),LD={...zD,title:"Discounts",orderOfApplicationExplanation:"Discounts are applied before commitments on invoices",description:"Add price reductions for a defined period or specific terms.",selectPricingPlanHint:"Please select a pricing plan to add discounts",addItemLabel:"Add",notEditableExplanation:"Discounts can't be edited for active schedules"},RD=["src"],HD=e.defineComponent({__name:"SubscriptionDiscounts",props:{i18n:{},discount:{},pricingPlanVersion:{},isEditable:{type:[Boolean,Function]},isCreatable:{type:Boolean},isRemovable:{type:[Boolean,Function]},scheduleStart:{},billingPeriod:{},billingTime:{},isDraftSubscription:{type:Boolean,default:!1},error:{},timezone:{}},emits:["add","edit","delete"],setup(t){const n=t,r=e.computed(()=>n.i18n??LD),o=e.computed(()=>{if("error"in n)return(e=>{const t=Object.entries(e||{});if(0===t.length)return;const[n,r]=t[0],[o,i,a]=n.split(".");return{discountLevel:o,index:parseInt(i,10),fieldName:a,message:r}})(n.error)}),{isEditableFlag:i,isItemEditable:a,isItemRemovable:l}=wD({isEditable:n.isEditable,isRemovable:n.isRemovable}),s=e.computed(()=>{var e,t,r,i,a,l,s,c;return[...(null==(t=null==(e=n.discount)?void 0:e.pricing_item_configs)?void 0:t.map((e,t)=>{var n,r;return{item:{...e,discountLevel:"PRICING_RULE"},error:t===(null==(n=o.value)?void 0:n.index)&&"pricing_item_configs"===(null==(r=o.value)?void 0:r.discountLevel)?o.value.message:void 0}}))||[],...(null==(i=null==(r=n.discount)?void 0:r.pricing_items)?void 0:i.map((e,t)=>{var n,r;return{item:{...e,discountLevel:"REVENUE_ITEM"},error:t===(null==(n=o.value)?void 0:n.index)&&"pricing_items"===(null==(r=o.value)?void 0:r.discountLevel)?o.value.message:void 0}}))||[],...(null==(l=null==(a=n.discount)?void 0:a.pricings)?void 0:l.map((e,t)=>{var n,r;return{item:{...e,discountLevel:"PRODUCT"},error:t===(null==(n=o.value)?void 0:n.index)&&"pricings"===(null==(r=o.value)?void 0:r.discountLevel)?o.value.message:void 0}}))||[],...(null==(c=null==(s=n.discount)?void 0:s.totals)?void 0:c.map((e,t)=>{var n,r;return{item:{...e,discountLevel:"INVOICE"},error:t===(null==(n=o.value)?void 0:n.index)&&"totals"===(null==(r=o.value)?void 0:r.discountLevel)?o.value.message:void 0}}))||[]]});return(n,o)=>(e.openBlock(),e.createBlock(MD,e.mergeProps(n.$attrs,{title:r.value.title,"order-of-application-explanation":r.value.orderOfApplicationExplanation,description:r.value.description,"pricing-plan-version-is-selected":!!t.pricingPlanVersion,"select-pricing-plan-hint":r.value.selectPricingPlanHint,"add-item-label":r.value.addItemLabel,"is-editable":e.unref(i),"is-creatable":!!t.isCreatable,"not-editable-explanation":r.value.notEditableExplanation,"has-items":s.value.length>0,onAdd:o[0]||(o[0]=e=>n.$emit("add"))}),{icon:e.withCtx(()=>[e.createElementVNode("img",{src:e.unref("data:image/svg+xml,%3csvg%20width='44'%20height='44'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cmask%20id='a'%20style='mask-type:alpha'%20maskUnits='userSpaceOnUse'%20x='0'%20y='0'%20width='44'%20height='44'%3e%3cpath%20fill='%23D9D9D9'%20d='M0%200h44v44H0z'/%3e%3c/mask%3e%3cg%20mask='url(%23a)'%3e%3cmask%20id='e'%20fill='%23fff'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='m18.55%2039.32%203.45%203.4%203.46-3.41%204.48%201.85%201.86-4.5h4.87v-4.84l4.47-1.9-1.82-4.47%203.4-3.45-3.41-3.46%201.85-4.48-4.5-1.86V7.33h-4.84l-1.9-4.47-4.47%201.82L22%201.28%2018.54%204.7l-4.48-1.85-1.86%204.5H7.33v4.84l-4.47%201.9%201.82%204.47L1.28%2022l3.41%203.46-1.85%204.48%204.5%201.86v4.87h4.84l1.9%204.47%204.47-1.82Z'/%3e%3c/mask%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='m18.55%2039.32%203.45%203.4%203.46-3.41%204.48%201.85%201.86-4.5h4.87v-4.84l4.47-1.9-1.82-4.47%203.4-3.45-3.41-3.46%201.85-4.48-4.5-1.86V7.33h-4.84l-1.9-4.47-4.47%201.82L22%201.28%2018.54%204.7l-4.48-1.85-1.86%204.5H7.33v4.84l-4.47%201.9%201.82%204.47L1.28%2022l3.41%203.46-1.85%204.48%204.5%201.86v4.87h4.84l1.9%204.47%204.47-1.82Z'%20fill='%23BFEAFB'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='m18.55%2039.32%203.45%203.4%203.46-3.41%204.48%201.85%201.86-4.5h4.87v-4.84l4.47-1.9-1.82-4.47%203.4-3.45-3.41-3.46%201.85-4.48-4.5-1.86V7.33h-4.84l-1.9-4.47-4.47%201.82L22%201.28%2018.54%204.7l-4.48-1.85-1.86%204.5H7.33v4.84l-4.47%201.9%201.82%204.47L1.28%2022l3.41%203.46-1.85%204.48%204.5%201.86v4.87h4.84l1.9%204.47%204.47-1.82Z'%20fill='url(%23b)'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='m18.55%2039.32%203.45%203.4%203.46-3.41%204.48%201.85%201.86-4.5h4.87v-4.84l4.47-1.9-1.82-4.47%203.4-3.45-3.41-3.46%201.85-4.48-4.5-1.86V7.33h-4.84l-1.9-4.47-4.47%201.82L22%201.28%2018.54%204.7l-4.48-1.85-1.86%204.5H7.33v4.84l-4.47%201.9%201.82%204.47L1.28%2022l3.41%203.46-1.85%204.48%204.5%201.86v4.87h4.84l1.9%204.47%204.47-1.82Z'%20fill='url(%23c)'/%3e%3cpath%20d='m22%2042.72-.7.7.7.7.7-.7-.7-.7Zm-3.45-3.4.7-.71-.46-.46-.61.25.37.92Zm6.91-.01.38-.93-.6-.25-.48.47.7.7Zm4.48%201.85-.38.93.92.38.38-.92-.92-.39Zm1.86-4.5v-1h-.67l-.25.62.92.39Zm4.87%200v1h1v-1h-1Zm0-4.84-.4-.92-.6.26v.66h1Zm4.47-1.9.39.93.9-.39-.36-.9-.93.37Zm-1.82-4.47-.7-.7-.47.46.25.61.92-.37Zm3.4-3.45.7.7.7-.7-.7-.7-.7.7Zm-3.41-3.46-.93-.38-.25.61.47.47.7-.7Zm1.85-4.48.93.39.38-.93-.92-.38-.39.92Zm-4.5-1.86h-1v.67l.62.25.39-.92Zm0-4.87h1v-1h-1v1Zm-4.84%200-.92.4.26.6h.66v-1Zm-1.9-4.47.93-.39-.38-.9-.92.36.38.93Zm-4.47%201.82-.7.71.46.46.61-.25-.37-.92ZM22%201.28l.7-.7-.7-.7-.7.7.7.7ZM18.54%204.7l-.38.93.61.25.47-.47-.7-.7Zm-4.48-1.85.39-.93-.93-.38-.38.92.92.39Zm-1.86%204.5v1h.67l.25-.62-.92-.39Zm-4.87%200v-1h-1v1h1Zm0%204.84.4.92.6-.26v-.66h-1Zm-4.47%201.9-.39-.93-.9.38.36.92.93-.38Zm1.82%204.47.71.7.46-.46-.25-.61-.92.37ZM1.28%2022l-.7-.7-.7.7.7.7.7-.7Zm3.41%203.46.93.38.25-.61-.47-.47-.7.7Zm-1.85%204.48-.93-.39-.38.93.92.38.39-.92Zm4.5%201.86h1v-.67l-.62-.25-.39.92Zm0%204.87h-1v1h1v-1Zm4.84%200%20.92-.4-.26-.6h-.66v1Zm1.9%204.47-.93.39.39.9.9-.36-.37-.93Zm8.62.86-3.44-3.39-1.4%201.42%203.44%203.4L22.7%2042Zm2.06-3.4L21.3%2042l1.4%201.43%203.46-3.41-1.4-1.42Zm5.56%201.64-4.48-1.86-.76%201.85%204.48%201.86.76-1.85Zm.56-3.96L29%2040.78l1.85.77%201.86-4.5-1.84-.77Zm5.79-.61H31.8v2h4.87v-2Zm-1-3.85v4.85h2v-4.85h-2Zm5.08-2.81-4.47%201.89.78%201.84%204.47-1.9-.78-1.83Zm-2.35-3.19%201.81%204.48%201.86-.75-1.82-4.48-1.85.75ZM42%2021.3l-3.39%203.44%201.43%201.4%203.39-3.44L42%2021.3Zm-3.4-2.06L42%2022.7l1.43-1.4-3.4-3.46-1.43%201.4Zm1.64-5.56-1.86%204.48%201.85.76%201.86-4.47-1.85-.77Zm-3.96-.56%204.5%201.87.77-1.85-4.5-1.86-.77%201.84Zm-.61-5.79v4.87h2V7.33h-2Zm-3.85%201h4.85v-2h-4.85v2Zm-2.81-5.08%201.89%204.47%201.84-.78-1.9-4.47-1.83.78ZM25.82%205.6%2030.3%203.8l-.75-1.86-4.48%201.82.75%201.85ZM21.3%202l3.44%203.39%201.4-1.42L22.7.57%2021.3%202Zm-2.06%203.4L22.7%202%2021.3.57l-3.46%203.4%201.4%201.43Zm-5.56-1.64%204.48%201.86.76-1.85-4.47-1.86-.77%201.85Zm-.56%203.96L15%203.22l-1.85-.77-1.86%204.5%201.84.77Zm-5.79.61h4.87v-2H7.33v2Zm1%203.85V7.33h-2v4.85h2Zm-5.08%202.81%204.47-1.89-.78-1.84-4.47%201.9.78%201.83Zm2.35%203.19L3.8%2013.7l-1.86.75%201.82%204.48%201.85-.75ZM2%2022.7l3.39-3.44-1.42-1.4-3.4%203.44L2%2022.7Zm3.4%202.06L2%2021.3.57%2022.7l3.41%203.46%201.42-1.4Zm-1.64%205.56%201.86-4.48-1.85-.76-1.86%204.47%201.85.77Zm3.96.56L3.22%2029l-.77%201.85%204.5%201.86.77-1.84Zm.61%205.79V31.8h-2v4.87h2Zm3.85-1H7.33v2h4.85v-2Zm2.81%205.08-1.89-4.47-1.84.78%201.9%204.47%201.83-.78Zm3.19-2.35L13.7%2040.2l.75%201.86%204.48-1.82-.75-1.85Z'%20fill='url(%23d)'%20fill-opacity='.1'%20mask='url(%23e)'/%3e%3cg%20opacity='.5'%3e%3cmask%20id='f'%20style='mask-type:alpha'%20maskUnits='userSpaceOnUse'%20x='12'%20y='12'%20width='20'%20height='20'%3e%3cpath%20fill='%23D9D9D9'%20d='M12%2012h20v20H12z'/%3e%3c/mask%3e%3cg%20mask='url(%23f)'%3e%3cpath%20d='M19.5%2027.83v-1.66H25l-9.67-9.67%201.17-1.17L26.17%2025v-5.5h1.66v8.33H19.5Z'%20fill='%23222B35'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3clinearGradient%20id='b'%20x1='1.28'%20y1='1.28'%20x2='42.72'%20y2='42.72'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23F6D449'/%3e%3cstop%20offset='1'%20stop-color='%23F6D449'%20stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient%20id='c'%20x1='42.72'%20y1='1.28'%20x2='1.28'%20y2='42.72'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23fff'/%3e%3cstop%20offset='1'%20stop-color='%23fff'%20stop-opacity='.4'/%3e%3c/linearGradient%3e%3clinearGradient%20id='d'%20x1='22'%20y1='42.72'%20x2='22'%20y2='-2.59'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%230C0E41'/%3e%3cstop%20offset='1'%20stop-color='%230C0E41'%20stop-opacity='.5'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e"),alt:""},null,8,RD)]),"list-items":e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,({item:o,error:i})=>(e.openBlock(),e.createElementBlock("li",{key:JSON.stringify(o)},[e.createVNode($D,{discount:o,error:i,"is-editable":e.unref(a)(o),"is-removable":e.unref(l)(o),"pricing-plan-version":t.pricingPlanVersion,i18n:r.value,timezone:t.timezone,onEdit:e=>n.$emit("edit",o),onDelete:e=>n.$emit("delete",o)},null,8,["discount","error","is-editable","is-removable","pricing-plan-version","i18n","timezone","onEdit","onDelete"])]))),128))]),_:1},16,["title","order-of-application-explanation","description","pricing-plan-version-is-selected","select-pricing-plan-hint","add-item-label","is-editable","is-creatable","not-editable-explanation","has-items"]))}}),FD={...sD,...lD,markupBody:(e,t,n)=>`Markup on ${e} <strong>${t}</strong> ${n}`},jD={class:"font-semibold text-primary-600"},UD=["innerHTML"],GD=e.defineComponent({__name:"SubscriptionMarkupItem",props:{markup:{},pricingPlanVersion:{},isEditable:{type:Boolean},isRemovable:{type:Boolean},i18n:{},error:{},timezone:{}},emits:["edit","delete"],setup(t,{emit:n}){const r=t,o=n,i=e.computed(()=>r.i18n??FD),{getMarkupBody:a}=((t,n=FD,r)=>{const{formatDate:o}=HB(),i=e.computed(()=>{var e,n;return(null==(n=null==(e=t.value)?void 0:e.pricing_categories)?void 0:n.flatMap(e=>{var t;return[...(null==(t=e.pricing_groups)?void 0:t.flatMap(e=>e.pricings))??[],...e.pricings??[]]}))??[]}),a=e=>{var t,r;const o=t=>{var n;return t.id===(null==(n=e.ids)?void 0:n[0])},a=e=>{var t,n;return o(e)||!!(null==(n=null==(t=e.conditions)?void 0:t.configs)?void 0:n.some(o))},l=e=>{var t;return null==(t=e.configs)?void 0:t.some(a)},s=null==(t=i.value)?void 0:t.find(e=>{var t;return null==(t=e.items)?void 0:t.some(l)}),c=null==(r=null==s?void 0:s.items)?void 0:r.find(l),d=(null==c?void 0:c.configs)&&(null==c?void 0:c.configs.flatMap(jS)),u=null==d?void 0:d.find(o);return`<strong>${US(n)({pricing:s,item:c,config:u})}</strong>`},l=e=>{if(!e.start_at&&!e.end_at)return"";let t,i;return e.start_at||(t=n.startOfSchedule),e.end_at||(i=n.endOfSchedule),e.start_at&&(t=o(r?{date:e.start_at,format:"date",offsetType:"offsetted",timezone:r}:{date:e.start_at,format:"date",offsetType:"local",showTimezone:!1})),e.end_at&&(i=o(r?{date:e.end_at,format:"date",offsetType:"offsetted",timezone:r}:{date:e.end_at,format:"date",offsetType:"local",showTimezone:!1})),`(${t} - ${i})`};return{getMarkupBody:e=>n.markupBody(n.pricingRule,a(e)??"",l(e)),getFormattedDuration:l}})(e.toRef(()=>r.pricingPlanVersion),i.value,r.timezone);return(n,r)=>(e.openBlock(),e.createBlock(pD,{icon:"north_east","icon-color":"teal","is-editable":t.isEditable,"is-removable":t.isRemovable,error:t.error,onEdit:r[0]||(r[0]=e=>o("edit")),onDelete:r[1]||(r[1]=e=>o("delete"))},{body:e.withCtx(()=>[e.createElementVNode("span",jD,e.toDisplayString(t.markup.percentage)+"%"+e.toDisplayString(" "),1),e.createElementVNode("span",{innerHTML:e.unref(a)(t.markup)},null,8,UD)]),_:1},8,["is-editable","is-removable","error"]))}}),qD={...FD,title:"Markups",orderOfApplicationExplanation:"Markups are applied before commitments on invoices",description:"Add price markups for a defined period or specific terms.",selectPricingPlanHint:"Please select a pricing plan to add markups",addItemLabel:"Add",notEditableExplanation:"Markups can't be edited for active schedules"},ZD=["src"],WD=e.defineComponent({__name:"SubscriptionMarkups",props:{i18n:{},markup:{},pricingPlanVersion:{},isCreatable:{type:Boolean},isEditable:{type:[Boolean,Function]},isRemovable:{type:[Boolean,Function]},error:{},timezone:{}},emits:["add","edit","delete"],setup(t){const n=t,r=e.computed(()=>n.i18n??qD),{isEditableFlag:o,isItemEditable:i,isItemRemovable:a}=wD({isEditable:n.isEditable,isRemovable:n.isRemovable}),l=e.computed(()=>{if("error"in n)return(e=>{const t=Object.entries(e||{});if(0===t.length)return;const[n,r]=t[0],[o,i,a]=n.split(".");return{markupLevel:o,index:parseInt(i,10),fieldName:a,message:r}})(n.error)}),s=e.computed(()=>{var e,t;return(null==(t=null==(e=n.markup)?void 0:e.pricing_item_configs)?void 0:t.map((e,t)=>{var n,r;return{item:e,error:t===(null==(n=l.value)?void 0:n.index)&&"pricing_item_configs"===(null==(r=l.value)?void 0:r.markupLevel)?l.value.message:void 0}}))??[]});return(n,l)=>(e.openBlock(),e.createBlock(MD,e.mergeProps(n.$attrs,{title:r.value.title,"order-of-application-explanation":r.value.orderOfApplicationExplanation,description:r.value.description,"pricing-plan-version-is-selected":!!t.pricingPlanVersion,"select-pricing-plan-hint":r.value.selectPricingPlanHint,"add-item-label":r.value.addItemLabel,"is-editable":e.unref(o),"is-creatable":!!t.isCreatable,"not-editable-explanation":r.value.notEditableExplanation,"has-items":s.value.length>0,onAdd:l[0]||(l[0]=e=>n.$emit("add"))}),{icon:e.withCtx(()=>[e.createElementVNode("img",{src:e.unref("data:image/svg+xml,%3csvg%20width='44'%20height='44'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cmask%20id='a'%20style='mask-type:alpha'%20maskUnits='userSpaceOnUse'%20x='0'%20y='0'%20width='44'%20height='44'%3e%3cpath%20fill='%23D9D9D9'%20d='M0%200h44v44H0z'/%3e%3c/mask%3e%3cg%20mask='url(%23a)'%3e%3cmask%20id='e'%20fill='%23fff'%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M16.76%2040.05a2.94%202.94%200%200%201%203.17.63%202.96%202.96%200%200%200%204.15%200%202.93%202.93%200%200%201%203.17-.63c1.48.61%203.19-.1%203.8-1.58a2.92%202.92%200%200%201%202.7-1.8c1.61%200%202.92-1.3%202.92-2.92%200-1.17.7-2.23%201.78-2.69a2.96%202.96%200%200%200%201.6-3.82%202.94%202.94%200%200%201%20.63-3.17%202.96%202.96%200%200%200%200-4.15%202.93%202.93%200%200%201-.63-3.16c.61-1.5-.1-3.2-1.58-3.81a2.92%202.92%200%200%201-1.8-2.7c0-1.61-1.3-2.92-2.92-2.92a2.93%202.93%200%200%201-2.69-1.78%202.96%202.96%200%200%200-3.82-1.6c-1.09.44-2.34.2-3.17-.63a2.96%202.96%200%200%200-4.15%200%202.93%202.93%200%200%201-3.16.63c-1.5-.61-3.2.1-3.81%201.58a2.92%202.92%200%200%201-2.7%201.8%202.92%202.92%200%200%200-2.92%202.92c0%201.17-.7%202.23-1.78%202.69a2.96%202.96%200%200%200-1.6%203.82c.44%201.09.2%202.34-.63%203.17a2.96%202.96%200%200%200%20.01%204.15c.82.83%201.07%202.08.62%203.16-.61%201.5.1%203.2%201.58%203.81a2.92%202.92%200%200%201%201.8%202.7c0%201.61%201.3%202.92%202.92%202.92%201.17%200%202.23.7%202.69%201.78a2.96%202.96%200%200%200%203.82%201.6Z'/%3e%3c/mask%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M16.76%2040.05a2.94%202.94%200%200%201%203.17.63%202.96%202.96%200%200%200%204.15%200%202.93%202.93%200%200%201%203.17-.63c1.48.61%203.19-.1%203.8-1.58a2.92%202.92%200%200%201%202.7-1.8c1.61%200%202.92-1.3%202.92-2.92%200-1.17.7-2.23%201.78-2.69a2.96%202.96%200%200%200%201.6-3.82%202.94%202.94%200%200%201%20.63-3.17%202.96%202.96%200%200%200%200-4.15%202.93%202.93%200%200%201-.63-3.16c.61-1.5-.1-3.2-1.58-3.81a2.92%202.92%200%200%201-1.8-2.7c0-1.61-1.3-2.92-2.92-2.92a2.93%202.93%200%200%201-2.69-1.78%202.96%202.96%200%200%200-3.82-1.6c-1.09.44-2.34.2-3.17-.63a2.96%202.96%200%200%200-4.15%200%202.93%202.93%200%200%201-3.16.63c-1.5-.61-3.2.1-3.81%201.58a2.92%202.92%200%200%201-2.7%201.8%202.92%202.92%200%200%200-2.92%202.92c0%201.17-.7%202.23-1.78%202.69a2.96%202.96%200%200%200-1.6%203.82c.44%201.09.2%202.34-.63%203.17a2.96%202.96%200%200%200%20.01%204.15c.82.83%201.07%202.08.62%203.16-.61%201.5.1%203.2%201.58%203.81a2.92%202.92%200%200%201%201.8%202.7c0%201.61%201.3%202.92%202.92%202.92%201.17%200%202.23.7%202.69%201.78a2.96%202.96%200%200%200%203.82%201.6Z'%20fill='%23BFEAFB'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M16.76%2040.05a2.94%202.94%200%200%201%203.17.63%202.96%202.96%200%200%200%204.15%200%202.93%202.93%200%200%201%203.17-.63c1.48.61%203.19-.1%203.8-1.58a2.92%202.92%200%200%201%202.7-1.8c1.61%200%202.92-1.3%202.92-2.92%200-1.17.7-2.23%201.78-2.69a2.96%202.96%200%200%200%201.6-3.82%202.94%202.94%200%200%201%20.63-3.17%202.96%202.96%200%200%200%200-4.15%202.93%202.93%200%200%201-.63-3.16c.61-1.5-.1-3.2-1.58-3.81a2.92%202.92%200%200%201-1.8-2.7c0-1.61-1.3-2.92-2.92-2.92a2.93%202.93%200%200%201-2.69-1.78%202.96%202.96%200%200%200-3.82-1.6c-1.09.44-2.34.2-3.17-.63a2.96%202.96%200%200%200-4.15%200%202.93%202.93%200%200%201-3.16.63c-1.5-.61-3.2.1-3.81%201.58a2.92%202.92%200%200%201-2.7%201.8%202.92%202.92%200%200%200-2.92%202.92c0%201.17-.7%202.23-1.78%202.69a2.96%202.96%200%200%200-1.6%203.82c.44%201.09.2%202.34-.63%203.17a2.96%202.96%200%200%200%20.01%204.15c.82.83%201.07%202.08.62%203.16-.61%201.5.1%203.2%201.58%203.81a2.92%202.92%200%200%201%201.8%202.7c0%201.61%201.3%202.92%202.92%202.92%201.17%200%202.23.7%202.69%201.78a2.96%202.96%200%200%200%203.82%201.6Z'%20fill='url(%23b)'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M16.76%2040.05a2.94%202.94%200%200%201%203.17.63%202.96%202.96%200%200%200%204.15%200%202.93%202.93%200%200%201%203.17-.63c1.48.61%203.19-.1%203.8-1.58a2.92%202.92%200%200%201%202.7-1.8c1.61%200%202.92-1.3%202.92-2.92%200-1.17.7-2.23%201.78-2.69a2.96%202.96%200%200%200%201.6-3.82%202.94%202.94%200%200%201%20.63-3.17%202.96%202.96%200%200%200%200-4.15%202.93%202.93%200%200%201-.63-3.16c.61-1.5-.1-3.2-1.58-3.81a2.92%202.92%200%200%201-1.8-2.7c0-1.61-1.3-2.92-2.92-2.92a2.93%202.93%200%200%201-2.69-1.78%202.96%202.96%200%200%200-3.82-1.6c-1.09.44-2.34.2-3.17-.63a2.96%202.96%200%200%200-4.15%200%202.93%202.93%200%200%201-3.16.63c-1.5-.61-3.2.1-3.81%201.58a2.92%202.92%200%200%201-2.7%201.8%202.92%202.92%200%200%200-2.92%202.92c0%201.17-.7%202.23-1.78%202.69a2.96%202.96%200%200%200-1.6%203.82c.44%201.09.2%202.34-.63%203.17a2.96%202.96%200%200%200%20.01%204.15c.82.83%201.07%202.08.62%203.16-.61%201.5.1%203.2%201.58%203.81a2.92%202.92%200%200%201%201.8%202.7c0%201.61%201.3%202.92%202.92%202.92%201.17%200%202.23.7%202.69%201.78a2.96%202.96%200%200%200%203.82%201.6Z'%20fill='url(%23c)'/%3e%3cpath%20d='M12.02%2038.84a3.96%203.96%200%200%200%205.12%202.14l-.75-1.86c-.98.4-2.12-.07-2.53-1.05l-1.84.77Zm-1.77-1.17c.76%200%201.46.46%201.77%201.17l1.84-.78a3.93%203.93%200%200%200-3.61-2.4v2Zm-3.92-3.92a3.92%203.92%200%200%200%203.92%203.92v-2a1.92%201.92%200%200%201-1.92-1.92h-2Zm-1.18-1.77c.72.3%201.18%201%201.18%201.77h2c0-1.58-.95-3.01-2.42-3.62l-.76%201.85Zm-2.12-5.12c-.83%202%20.12%204.29%202.12%205.12l.76-1.85a1.92%201.92%200%200%201-1.03-2.5l-1.85-.77Zm-.41-2.08c.54.55.7%201.37.4%202.08l1.86.77c.6-1.46.26-3.14-.84-4.25l-1.42%201.4Zm-.01-5.55a3.96%203.96%200%200%200%200%205.55l1.43-1.4a1.96%201.96%200%200%201%200-2.75l-1.43-1.4Zm.41-2.1c.3.73.13%201.55-.41%202.1l1.42%201.4a3.94%203.94%200%200%200%20.85-4.25l-1.86.76Zm2.14-5.11a3.96%203.96%200%200%200-2.14%205.12l1.86-.76c-.4-.97.07-2.1%201.06-2.52l-.78-1.84Zm1.17-1.77c0%20.76-.46%201.46-1.17%201.77l.78%201.84a3.93%203.93%200%200%200%202.4-3.61h-2Zm3.92-3.92a3.92%203.92%200%200%200-3.92%203.92h2c0-1.06.86-1.92%201.92-1.92v-2Zm1.77-1.18c-.3.72-1%201.18-1.77%201.18v2c1.58%200%203.01-.95%203.62-2.42l-1.85-.76Zm5.12-2.12c-2-.83-4.29.12-5.12%202.12l1.85.76a1.92%201.92%200%200%201%202.5-1.03l.77-1.85Zm2.08-.41c-.55.54-1.37.7-2.08.4l-.77%201.86c1.46.6%203.14.26%204.26-.84l-1.4-1.42Zm5.55-.01a3.96%203.96%200%200%200-5.55%200l1.4%201.43a1.96%201.96%200%200%201%202.75%200l1.4-1.43Zm2.1.41c-.72.3-1.55.13-2.1-.41l-1.4%201.42a3.94%203.94%200%200%200%204.25.85l-.76-1.86Zm5.12%202.14a3.96%203.96%200%200%200-5.13-2.14l.76%201.86c.97-.4%202.1.07%202.52%201.05L32%205.16Zm1.76%201.17c-.76%200-1.46-.46-1.76-1.17l-1.85.77a3.93%203.93%200%200%200%203.61%202.4v-2Zm3.92%203.92a3.92%203.92%200%200%200-3.92-3.92v2c1.06%200%201.92.86%201.92%201.92h2Zm1.18%201.77c-.71-.3-1.18-1-1.18-1.77h-2c0%201.58.95%203.01%202.42%203.62l.76-1.85Zm2.12%205.12c.83-2-.12-4.29-2.12-5.12l-.76%201.85c.97.4%201.44%201.53%201.03%202.5l1.85.77Zm.41%202.08a1.93%201.93%200%200%201-.4-2.08l-1.86-.77a3.93%203.93%200%200%200%20.84%204.25l1.42-1.4Zm.01%205.55a3.96%203.96%200%200%200%200-5.55l-1.43%201.4c.75.77.75%202%200%202.74l1.43%201.4Zm-.41%202.1c-.3-.73-.13-1.55.41-2.1l-1.42-1.4a3.94%203.94%200%200%200-.85%204.25l1.86-.76Zm-2.14%205.11a3.96%203.96%200%200%200%202.14-5.12l-1.86.76c.4.97-.07%202.1-1.05%202.52l.77%201.84Zm-1.17%201.77c0-.76.46-1.46%201.17-1.77l-.77-1.84a3.93%203.93%200%200%200-2.4%203.61h2Zm-3.92%203.92a3.92%203.92%200%200%200%203.92-3.92h-2c0%201.06-.86%201.92-1.92%201.92v2Zm-1.77%201.18c.3-.72%201-1.18%201.77-1.18v-2c-1.58%200-3.01.95-3.62%202.42l1.85.76Zm-5.12%202.12c2%20.83%204.3-.12%205.12-2.12l-1.85-.76a1.92%201.92%200%200%201-2.5%201.03l-.77%201.85Zm-2.08.41c.55-.54%201.38-.7%202.08-.4l.77-1.86a3.93%203.93%200%200%200-4.25.84l1.4%201.42Zm-4.14-1.41a3.94%203.94%200%200%200-4.25-.85l.75%201.86c.72-.3%201.54-.13%202.1.41l1.4-1.42Zm-1.4%201.42a3.96%203.96%200%200%200%205.54%200l-1.4-1.43c-.77.75-2%20.75-2.74%200l-1.4%201.43Z'%20fill='url(%23d)'%20fill-opacity='.1'%20mask='url(%23e)'/%3e%3cg%20opacity='.5'%3e%3cmask%20id='f'%20style='mask-type:alpha'%20maskUnits='userSpaceOnUse'%20x='12'%20y='12'%20width='20'%20height='20'%3e%3cpath%20fill='%23D9D9D9'%20d='M12%2012h20v20H12z'/%3e%3c/mask%3e%3cg%20mask='url(%23f)'%3e%3cpath%20d='m16.5%2028.67-1.17-1.17L25%2017.83h-5.5v-1.66h8.33v8.33h-1.66V19l-9.67%209.67Z'%20fill='%23222B35'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3clinearGradient%20id='b'%20x1='1.28'%20y1='1.28'%20x2='42.72'%20y2='42.72'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23395E6D'/%3e%3cstop%20offset='1'%20stop-color='%23395E6D'%20stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient%20id='c'%20x1='42.72'%20y1='1.28'%20x2='1.28'%20y2='42.72'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23fff'/%3e%3cstop%20offset='1'%20stop-color='%23fff'%20stop-opacity='.4'/%3e%3c/linearGradient%3e%3clinearGradient%20id='d'%20x1='22'%20y1='42.72'%20x2='22'%20y2='-2.59'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%230C0E41'/%3e%3cstop%20offset='1'%20stop-color='%230C0E41'%20stop-opacity='.5'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e"),alt:""},null,8,ZD)]),"list-items":e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,({item:o,error:l})=>(e.openBlock(),e.createElementBlock("li",{key:JSON.stringify(o)},[e.createVNode(GD,{markup:o,error:l,"is-editable":e.unref(i)(o),"is-removable":e.unref(a)(o),"pricing-plan-version":t.pricingPlanVersion,i18n:r.value,timezone:t.timezone,onEdit:e=>n.$emit("edit",o),onDelete:e=>n.$emit("delete",o)},null,8,["markup","error","is-editable","is-removable","pricing-plan-version","i18n","timezone","onEdit","onDelete"])]))),128))]),_:1},16,["title","order-of-application-explanation","description","pricing-plan-version-is-selected","select-pricing-plan-hint","add-item-label","is-editable","is-creatable","not-editable-explanation","has-items"]))}}),KD={startOfSchedule:bD.startOfSchedule,endOfSchedule:bD.endOfSchedule,markupPercentage:e=>`${e}% markup`},JD={class:"flex gap-2 items-center"},YD=e.defineComponent({__name:"SubscriptionScheduleConfigMarkup",props:{markup:{},i18n:{}},setup(t){const n=t,r=e.computed(()=>n.i18n??KD),{formatDate:o}=HB();return(n,i)=>(e.openBlock(),e.createBlock(e.unref(mc),{color:"teal-light"},{default:e.withCtx(()=>[e.createElementVNode("div",JD,[e.createVNode(e.unref(hc),{icon:"north_east",size:"xs"}),e.createElementVNode("span",null,[t.markup.percentage?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(r.value.markupPercentage(t.markup.percentage)),1)],64)):e.createCommentVNode("",!0),t.markup.start_at||t.markup.end_at?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(" ")+"("+e.toDisplayString(t.markup.start_at?e.unref(o)({date:t.markup.start_at,format:"date",offsetType:"local",showTimezone:!1}):r.value.startOfSchedule)+" - "+e.toDisplayString(t.markup.end_at?e.unref(o)({date:t.markup.end_at,format:"date",offsetType:"local",showTimezone:!1}):r.value.endOfSchedule)+") ",1)],64)):e.createCommentVNode("",!0)])])]),_:1}))}}),XD={...LD,...bD,...qD,...aD,...KD,commitmentsTitle:bD.title,discountsTitle:LD.title,markupsTitle:qD.title,commitmentsOrderOfApplicationExplanation:bD.orderOfApplicationExplanation,discountsOrderOfApplicationExplanation:LD.orderOfApplicationExplanation,markupsOrderOfApplicationExplanation:qD.orderOfApplicationExplanation,scheduleNumber:e=>`Schedule ${e}`,versionNumber:e=>`Version ${e}`,subscriptionCancelled:e=>`Subscription cancelled from ${e}`},QD={class:"flex items-center gap-2"},eP={key:0,class:"flex items-center gap-2 mb-8"},tP={class:"text-base font-semibold"},nP={key:1,class:"transition-opacity-300"},rP=e.defineComponent({__name:"PricingPlanSchedules",props:{schedules:{},isEditable:{type:Boolean},openScheduleId:{},i18n:{},displayDisabledAddonPricings:{type:Boolean,default:!1},isExpandedByDefault:{type:Boolean},timezone:{},cancellationDate:{},enablePricingGroupSelection:{type:Boolean,default:!1}},emits:["add-schedule","toggle-schedule"],setup(t,{emit:n}){var r;const o=t,i=n,a=e.computed(()=>o.i18n??XD),{formatDate:l}=HB(),{getIsOpen:s,toggle:c}=vB({closeOthers:!0,initialToggledItems:[null==(r=o.schedules[0])?void 0:r.schedule.id]}),d=e.computed(()=>o.schedules.map((e,t)=>({...e,inferredPricingPlanVersion:e.selectedPricingPlanVersion&&zS(e.selectedPricingPlanVersion,e.schedule,{displayDisabledAddonPricings:o.displayDisabledAddonPricings}),scheduleNumber:t+1,cancelled:!1}))),u=e.computed(()=>{let e=[...d.value.map((e,t)=>({...e,inferredPricingPlanVersion:e.selectedPricingPlanVersion&&zS(e.selectedPricingPlanVersion,e.schedule,{displayDisabledAddonPricings:o.displayDisabledAddonPricings}),scheduleNumber:t+1}))];if(o.cancellationDate){let t=0;const n={cancellationDate:o.cancellationDate},r=e.findLastIndex(e=>rD(e)&&(e.schedule.start_at??"")<(o.cancellationDate??""));if(-1===r)e=[n,...e];else{const i=e[r];t=rD(i)&&(i.schedule.end_at??"")>=(o.cancellationDate??"")?r:r+1,t===o.schedules.length+1?e=[...e,n]:e.splice(t,0,n)}return e.map((e,n)=>rD(e)?{...e,cancelled:n>t}:e)}return e}),p=e.computed(()=>void 0===o.openScheduleId);return(n,r)=>(e.openBlock(),e.createBlock(e.unref(TT),e.mergeProps(n.$attrs,{"has-add-button":t.isEditable,onAdd:r[0]||(r[0]=e=>n.$emit("add-schedule"))}),{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,(r,u)=>{return e.openBlock(),e.createElementBlock(e.Fragment,{key:u},[e.unref(nD)(r)?(e.openBlock(),e.createBlock(e.unref(RT),{key:0,"hide-collapse-icon":""},{icon:e.withCtx(()=>[e.createVNode(hc,{icon:"cancel",class:"text-red-600"})]),left:e.withCtx(()=>[e.createVNode(e.unref(gc),{variant:"body-sm",weight:"semibold"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.value.subscriptionCancelled(t.timezone?e.unref(l)({date:r.cancellationDate,format:"date",offsetType:"offsetted",timezone:t.timezone}):e.unref(l)({date:r.cancellationDate,format:"dateTime",offsetType:"local"}))),1)]),_:2},1024)]),_:2},1024)):e.createCommentVNode("",!0),e.unref(rD)(r)?(e.openBlock(),e.createBlock(e.unref(RT),{key:1,"item-number":r.scheduleNumber,"is-open":(h=r.schedule,p.value?s(h.id):o.openScheduleId===h.id),"has-continued-preline":!!t.isEditable||r.scheduleNumber-1!=d.value.length-1,class:e.normalizeClass({"opacity-60":r.cancelled}),onToggle:e=>(e=>{p.value?c(e.id):i("toggle-schedule",e.id)})(r.schedule)},{left:e.withCtx(()=>[e.createElementVNode("div",QD,[e.createVNode(e.unref(gc),{tag:"h3",weight:"semibold"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.value.scheduleNumber(r.scheduleNumber)),1)]),_:2},1024),"TRIAL"===r.schedule.type&&r.schedule.start_at&&r.schedule.end_at?(e.openBlock(),e.createBlock(e.unref(tO),{key:0,"trial-period":e.unref(lB)(new Date(r.schedule.start_at),new Date(r.schedule.end_at))},null,8,["trial-period"])):e.createCommentVNode("",!0),e.renderSlot(n.$slots,"id",{id:r.schedule.id})])]),right:e.withCtx(()=>[e.renderSlot(n.$slots,"schedule-right",{item:r,itemIndex:r.scheduleNumber-1},()=>[t.timezone?(e.openBlock(),e.createBlock(e.unref(gc),{key:0,variant:"body-xs"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.schedule.start_at?e.unref(l)({date:r.schedule.start_at,format:"dateTime",offsetType:"offsetted",timezone:t.timezone}):a.value.startOfSchedule)+" - "+e.toDisplayString(r.schedule.end_at?e.unref(l)({date:r.schedule.end_at,format:"dateTime",offsetType:"offsetted",timezone:t.timezone}):a.value.endOfSchedule),1)]),_:2},1024)):(e.openBlock(),e.createBlock(e.unref(gc),{key:1,variant:"body-xs"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.schedule.start_at?e.unref(l)({date:r.schedule.start_at,format:"dateTime",offsetType:"local"}):a.value.startOfSchedule)+" - "+e.toDisplayString(r.schedule.end_at?e.unref(l)({date:r.schedule.end_at,format:"dateTime",offsetType:"local"}):a.value.endOfSchedule),1)]),_:2},1024))])]),default:e.withCtx(()=>[e.renderSlot(n.$slots,"schedule",{item:r,previousItem:d.value.find(e=>e.scheduleNumber===r.scheduleNumber-1),nextItem:d.value.find(e=>e.scheduleNumber===r.scheduleNumber+1),timezone:t.timezone},()=>[r.selectedPricingPlan?(e.openBlock(),e.createElementBlock("div",eP,[e.createVNode(e.unref(XB),{initials:r.selectedPricingPlan.name[0],"color-hash":r.selectedPricingPlan.id,size:"lg"},null,8,["initials","color-hash"]),e.createElementVNode("h2",tP,e.toDisplayString(r.selectedPricingPlan.name),1),e.createVNode(e.unref(mc),{color:"teal"},{default:e.withCtx(()=>{var t;return[e.createTextVNode(e.toDisplayString(a.value.versionNumber((null==(t=r.inferredPricingPlanVersion)?void 0:t.version)??1)),1)]}),_:2},1024)])):e.createCommentVNode("",!0),r.inferredPricingPlanVersion?(e.openBlock(),e.createElementBlock("div",nP,[e.createVNode(e.unref(mP),{"pricing-plan-version":r.inferredPricingPlanVersion,"enabled-pricings":e.unref(VS)(r.schedule),"default-expanded":t.isExpandedByDefault,i18n:a.value,"enable-pricing-group-selection":t.enablePricingGroupSelection,"show-non-billable":""},{"pricing-item-config-additions":e.withCtx(({config:t})=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList([e.unref(XS)(r.schedule,t)],(t,n)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t?(e.openBlock(),e.createBlock(e.unref(YD),{key:n,markup:t,i18n:a.value},null,8,["markup","i18n"])):e.createCommentVNode("",!0)],64))),256)),e.renderSlot(n.$slots,"pricing-item-config-additions",{config:t,item:r,pricingPlanVersion:r.inferredPricingPlanVersion})]),_:2},1032,["pricing-plan-version","enabled-pricings","default-expanded","i18n","enable-pricing-group-selection"])])):e.createCommentVNode("",!0),r.schedule.discount?(e.openBlock(),e.createBlock(e.unref(HD),{key:2,discount:r.schedule.discount,"read-only":"","pricing-plan-version":r.inferredPricingPlanVersion,timezone:t.timezone,i18n:{...a.value,title:a.value.discountsTitle,orderOfApplicationExplanation:a.value.discountsOrderOfApplicationExplanation}},null,8,["discount","pricing-plan-version","timezone","i18n"])):e.createCommentVNode("",!0),r.schedule.markup?(e.openBlock(),e.createBlock(e.unref(WD),{key:3,markup:r.schedule.markup,"pricing-plan-version":r.inferredPricingPlanVersion,timezone:t.timezone,i18n:{...a.value,title:a.value.markupsTitle,orderOfApplicationExplanation:a.value.markupsOrderOfApplicationExplanation}},null,8,["markup","pricing-plan-version","timezone","i18n"])):e.createCommentVNode("",!0),r.schedule&&r.schedule.commitment?(e.openBlock(),e.createBlock(e.unref(VD),{key:4,class:"mt-2",commitment:r.schedule.commitment,"read-only":"","pricing-plan-version":r.inferredPricingPlanVersion,timezone:t.timezone,i18n:{...a.value,title:a.value.commitmentsTitle,orderOfApplicationExplanation:a.value.commitmentsOrderOfApplicationExplanation}},null,8,["commitment","pricing-plan-version","timezone","i18n"])):e.createCommentVNode("",!0)])]),_:2},1032,["item-number","is-open","has-continued-preline","class","onToggle"])):e.createCommentVNode("",!0)],64);var h}),128))]),_:3},16,["has-add-button"]))}}),oP={class:"inline-block ml-2"},iP={key:0,class:"mb-2"},aP=e.defineComponent({__name:"PricingCard",props:{pricing:{},groupedPricingItemIds:{},pricingPlanId:{},pricingPlanVersionId:{},isCustomizedPlan:{type:Boolean},subscriptionId:{},showNonBillable:{type:Boolean},defaultExpanded:{type:Boolean},i18n:{},showAddonChip:{type:Boolean,default:!0},isEnabled:{type:Boolean,default:!0},schedule:{},creditTypesById:{}},setup(t){const n=t,r=e.computed(()=>n.i18n??oD);e.provide("pricingId",n.pricing.id);const o=e=>"DEPRECATED"===e.status,i=e.computed(()=>(n.pricing.items||[]).flatMap(e=>e.product_items||[]).some(o)),a=e.computed(()=>(n.pricing.items||[]).flatMap(e=>e.product_items||[]).every(o));return(n,o)=>(e.openBlock(),e.createBlock(e.unref(NT),{class:"flex flex-col justify-between","capped-width":"","is-open":t.defaultExpanded,"data-testid":`pricing-${t.pricing.id}`,spacing:"sm",onToggled:o[0]||(o[0]=e=>n.$emit("pricing-toggled",e)),onToggle:o[1]||(o[1]=e=>n.$emit("pricing-toggle",t.pricing.id))},{"pre-header":e.withCtx(()=>[e.renderSlot(n.$slots,"pre-header")]),"title-prefix":e.withCtx(()=>[e.renderSlot(n.$slots,"title-prefix")]),title:e.withCtx(()=>[e.createVNode(e.unref(gc),{weight:"semibold",tag:"span",variant:"body-sm"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(Vx)(t.pricing,!(t.pricing.products&&t.pricing.products.length>1))),1)]),_:1})]),"title-suffix":e.withCtx(()=>[t.pricing.products&&t.pricing.products.length>1?(e.openBlock(),e.createBlock(e.unref(mc),{key:0,color:"green",class:"ml-2 align-middle"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.volumePooling),1)]),_:1})):e.createCommentVNode("",!0),t.showAddonChip&&t.pricing.product_type&&"ADDON"===t.pricing.product_type?(e.openBlock(),e.createBlock(e.unref(mc),{key:1,color:"indigo",class:"ml-2 align-middle"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.addon),1)]),_:1})):e.createCommentVNode("",!0),e.createElementVNode("span",oP,[e.renderSlot(n.$slots,"id")])]),right:e.withCtx(()=>[e.renderSlot(n.$slots,"right")]),default:e.withCtx(()=>[e.createVNode(e.unref(FM),{spacing:"none"},{default:e.withCtx(()=>[n.$slots["pricing-note"]?(e.openBlock(),e.createElementBlock("div",iP,[e.renderSlot(n.$slots,"pricing-note")])):e.createCommentVNode("",!0),e.createVNode(YI,{pricing:t.pricing,"grouped-pricing-item-ids":t.groupedPricingItemIds,i18n:r.value,"are-non-billable-items-visible":t.showNonBillable,schedule:t.schedule,"credit-types-by-id":t.creditTypesById},{"pricing-item-header":e.withCtx(({item:t})=>[e.renderSlot(n.$slots,"pricing-item-header",{item:t})]),"pricing-item-warning":e.withCtx(()=>[a.value?(e.openBlock(),e.createBlock(e.unref(JB),{key:0,type:"warning"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.allItemsDeprecatedWarning),1)]),_:1})):i.value?(e.openBlock(),e.createBlock(e.unref(JB),{key:1,type:"warning"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.someItemsDeprecatedWarning),1)]),_:1})):e.createCommentVNode("",!0)]),"pricing-item-config-settings":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-settings",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-entitlements-settings":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-entitlements-settings",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-override-tooltip":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-override-tooltip",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-additions",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-price-line-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-price-line-additions",e.normalizeProps(e.guardReactiveProps(t)))]),_:3},8,["pricing","grouped-pricing-item-ids","i18n","are-non-billable-items-visible","schedule","credit-types-by-id"])]),_:3})]),_:3},8,["is-open","data-testid"]))}}),lP={class:"inline-block"},sP=e.defineComponent({__name:"PricingGroupCard",props:{pricingGroup:{},i18n:{default:()=>iD},isEnabled:{type:Boolean}},setup:t=>(n,r)=>(e.openBlock(),e.createBlock(e.unref(PM),{spacing:t.isEnabled?"sm":"none","border-style":t.isEnabled?"solid":"dashed"},{default:e.withCtx(()=>[e.createVNode(e.unref(HM),{spacing:"none",title:t.pricingGroup.name},{"title-suffix":e.withCtx(()=>[t.pricingGroup.product_type&&"ADDON"===t.pricingGroup.product_type?(e.openBlock(),e.createBlock(e.unref(mc),{key:0,color:"indigo",class:"align-middle ml-2"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.i18n.addon),1)]),_:1})):e.createCommentVNode("",!0),e.createVNode(e.unref(mc),{color:"dark",class:"align-middle mx-2"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(DS)(t.pricingGroup)?t.i18n.singleSelect:t.i18n.multiSelect),1)]),_:1}),e.createElementVNode("span",lP,[e.renderSlot(n.$slots,"id")])]),right:e.withCtx(()=>[e.renderSlot(n.$slots,"settings")]),_:3},8,["title"]),e.createVNode(e.unref(FM),{spacing:"none",class:"mt-2"},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"pricings")]),_:3})]),_:3},8,["spacing","border-style"]))}),cP=e.defineComponent({__name:"PricingGroupSingleSelectCard",props:{pricingGroup:{},pricingPlanVersion:{},schedule:{},showNonBillable:{type:Boolean},isEnabled:{type:Boolean},isControlled:{type:Boolean}},emits:["update-enabled-pricing"],setup(t,{emit:n}){var r,o,i;const a=t,l=n,s=e.ref(null==(i=null==(o=null==(r=a.schedule)?void 0:r.enabled_pricings)?void 0:o.find(e=>a.pricingGroup.pricings.some(t=>t.id===e.pricing_id)))?void 0:i.pricing_id),c=e.computed(()=>a.pricingGroup.pricings.map(e=>({value:e.id}))),d=e.computed({get:()=>s.value||a.pricingGroup.pricings[0].id,set:e=>{s.value=e}}),u=e.computed(()=>a.pricingGroup.pricings.find(e=>e.id===d.value)),{renderPricingForPricingItem:p}=LB(),h=e.computed(()=>{var e,t,n,r;return(null==(t=null==(e=u.value)?void 0:e.items)?void 0:t[0])?p({pricingItem:null==(r=null==(n=u.value)?void 0:n.items)?void 0:r[0]}):""}),m=e.computed(()=>Object.fromEntries((a.pricingPlanVersion.credit_types??[]).map(e=>[e.id,e])));return e.watch(d,(e,t)=>{l("update-enabled-pricing",t,e)},{immediate:!0}),e.watch(()=>a.schedule,e=>{var t,n;s.value=null==(n=null==(t=null==e?void 0:e.enabled_pricings)?void 0:t.find(e=>a.pricingGroup.pricings.some(t=>t.id===e.pricing_id)))?void 0:n.pricing_id},{immediate:!0}),(n,r)=>(e.openBlock(),e.createBlock(e.unref(sP),{"pricing-group":t.pricingGroup,"is-enabled":t.isEnabled},{id:e.withCtx(()=>[e.renderSlot(n.$slots,"id",{id:t.pricingGroup.id})]),settings:e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-group-settings",{pricingGroup:t.pricingGroup})]),pricings:e.withCtx(()=>[u.value?(e.openBlock(),e.createBlock(e.unref(aP),{key:0,"default-expanded":!0,pricing:u.value,"pricing-plan-version-id":t.pricingPlanVersion.id,"pricing-plan-id":t.pricingPlanVersion.pricing_plan_id,"show-non-billable":t.showNonBillable,"is-customized-plan":!!t.pricingPlanVersion.copied_from_pricing_plan_version_id,class:"flex flex-col","is-controlled":t.isControlled,"show-addon-chip":!1,"is-enabled":t.isEnabled,schedule:t.schedule,"credit-types-by-id":m.value},{"pre-header":e.withCtx(()=>[e.createVNode(oz,{modelValue:d.value,"onUpdate:modelValue":r[0]||(r[0]=e=>d.value=e),options:c.value,name:"pricing-group-single-select",variant:"stepped-ghost",size:"lg",class:"border-b"},null,8,["modelValue","options"])]),"pricing-note":e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-note",e.normalizeProps(e.guardReactiveProps({pricing:u.value})))]),"title-prefix":e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-group-pricing-title-prefix",{pricingGroup:t.pricingGroup,pricing:u.value})]),id:e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-title-suffix",{id:u.value.id})]),right:e.withCtx(()=>[h.value?(e.openBlock(),e.createBlock(e.unref(gc),{key:0,variant:"body-xs",shade:"lighter",class:"mr-4"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(h.value),1)]),_:1})):e.createCommentVNode("",!0),e.renderSlot(n.$slots,"pricing-group-pricing-settings",{pricing:u.value,pricingGroup:t.pricingGroup})]),"pricing-item-header":e.withCtx(({item:t})=>[e.renderSlot(n.$slots,"pricing-item-header",{item:t})]),"pricing-entitlements-settings":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-entitlements-settings",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-settings":e.withCtx(r=>[e.renderSlot(n.$slots,"pricing-item-config-settings",e.mergeProps(r,{pricingGroup:t.pricingGroup}))]),"pricing-item-config-override-tooltip":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-override-tooltip",e.normalizeProps(e.guardReactiveProps(t)))]),"pricing-item-config-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-additions",e.normalizeProps(e.guardReactiveProps(t)))]),_:3},8,["pricing","pricing-plan-version-id","pricing-plan-id","show-non-billable","is-customized-plan","is-controlled","is-enabled","schedule","credit-types-by-id"])):e.createCommentVNode("",!0)]),_:3},8,["pricing-group","is-enabled"]))}}),dP={key:0,class:"mb-2 flex items-center gap-2 text-sm"},uP={class:"font-bold"},pP={class:"flex flex-col gap-2"},hP={class:"flex flex-col"},mP=e.defineComponent({__name:"PricingPlanVersionContent",props:{pricingPlanVersion:{},groupedPricingItemIdsByPricing:{},defaultExpanded:{type:Boolean},showNonBillable:{type:Boolean},expandedPricings:{},enabledPricings:{},isControlled:{type:Boolean},i18n:{},schedule:{},enablePricingGroupSelection:{type:Boolean,default:!1}},emits:["pricing-toggle","pricing-toggled","delete-pricing","update-enabled-pricing"],setup(t){const n=t,r=e.computed(()=>n.i18n??aD),o=e.computed(()=>n.enabledPricings??[]),i=e.computed(()=>{var e;return Object.fromEntries(((null==(e=n.pricingPlanVersion)?void 0:e.credit_types)??[]).map(e=>[e.id,e]))}),a=e=>"DEFAULT"===e.product_type||e.pricings.some(e=>o.value.includes(e.id)),l=e=>"DEFAULT"===e.product_type||o.value.includes(e.id);return(n,o)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.renderSlot(n.$slots,"header"),!t.pricingPlanVersion||t.pricingPlanVersion.pricing_categories&&0!==t.pricingPlanVersion.pricing_categories.length?t.pricingPlanVersion?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(t.pricingPlanVersion.pricing_categories??[],(s,c)=>{var d,u;return e.openBlock(),e.createElementBlock("div",{key:s.product_category_id,class:e.normalizeClass({"mt-6":c>0})},[(null==(d=s.product_category)?void 0:d.name)?(e.openBlock(),e.createElementBlock("h2",dP,[e.createElementVNode("span",uP,e.toDisplayString(null==(u=s.product_category)?void 0:u.name),1),e.createElementVNode("div",null,[e.createVNode(e.unref(mc),{size:"sm",color:"dark",class:"rounded-2xl font-semibold uppercase text-gray-600"},{default:e.withCtx(()=>{var t,n;return[e.createTextVNode(e.toDisplayString(r.value.productsCount(((null==(t=s.pricing_groups)?void 0:t.length)??0)+((null==(n=s.pricings)?void 0:n.length)??0))),1)]}),_:2},1024)])])):e.createCommentVNode("",!0),e.createElementVNode("div",pP,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.pricing_groups,s=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:s.id},[t.enablePricingGroupSelection&&"EXACTLY_ONE"===s.selection_constraint&&s.pricings.length>=7?(e.openBlock(),e.createBlock(cP,{key:0,"pricing-group":s,"pricing-plan-version":t.pricingPlanVersion,"is-enabled":a(s),i18n:r.value,schedule:t.schedule,"show-non-billable":t.showNonBillable,"is-controlled":t.isControlled,onUpdateEnabledPricing:o[0]||(o[0]=(e,t)=>n.$emit("update-enabled-pricing",e,t))},{id:e.withCtx(()=>[e.renderSlot(n.$slots,"id",{id:s.id})]),"pricing-group-settings":e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-group-settings",{pricingGroup:s})]),_:2},1032,["pricing-group","pricing-plan-version","is-enabled","i18n","schedule","show-non-billable","is-controlled"])):(e.openBlock(),e.createBlock(e.unref(sP),{key:1,"pricing-group":s,"is-enabled":a(s),i18n:r.value},{id:e.withCtx(()=>[e.renderSlot(n.$slots,"id",{id:s.id})]),settings:e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-group-settings",{pricingGroup:s})]),pricings:e.withCtx(()=>[e.createElementVNode("div",hP,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.pricings,a=>{var c,d;return e.openBlock(),e.createBlock(e.unref(aP),{key:a.id,"default-expanded":!0===t.defaultExpanded||(null==(c=t.expandedPricings)?void 0:c.includes(a.id)),pricing:a,"pricing-plan-version-id":t.pricingPlanVersion.id,"pricing-plan-id":t.pricingPlanVersion.pricing_plan_id,"show-non-billable":t.showNonBillable,"is-customized-plan":!!t.pricingPlanVersion.copied_from_pricing_plan_version_id,"grouped-pricing-item-ids":null==(d=t.groupedPricingItemIdsByPricing)?void 0:d[a.id],class:"flex flex-col","is-controlled":t.isControlled,i18n:r.value,"show-addon-chip":!1,"is-enabled":l(a),"credit-types-by-id":i.value,onPricingToggled:e=>n.$emit("pricing-toggled",a.id,e),onPricingToggle:o[1]||(o[1]=e=>n.$emit("pricing-toggle",e))},{"pricing-note":e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-note",e.mergeProps({ref_for:!0},{pricing:a}))]),"title-prefix":e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-group-pricing-title-prefix",{pricingGroup:s,pricing:a})]),id:e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-title-suffix",{id:a.id})]),right:e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-group-pricing-settings",{pricing:a,pricingGroup:s})]),"pricing-item-header":e.withCtx(({item:t})=>[e.renderSlot(n.$slots,"pricing-item-header",{item:t})]),"pricing-entitlements-settings":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-entitlements-settings",e.mergeProps({ref_for:!0},t))]),"pricing-item-config-settings":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-settings",e.mergeProps({ref_for:!0},t,{pricingGroup:s}))]),"pricing-item-config-override-tooltip":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-override-tooltip",e.mergeProps({ref_for:!0},t))]),"pricing-item-config-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-additions",e.mergeProps({ref_for:!0},t))]),"pricing-item-config-price-line-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-price-line-additions",e.mergeProps({ref_for:!0},t))]),_:2},1032,["default-expanded","pricing","pricing-plan-version-id","pricing-plan-id","show-non-billable","is-customized-plan","grouped-pricing-item-ids","is-controlled","i18n","is-enabled","credit-types-by-id","onPricingToggled"])}),128))])]),_:2},1032,["pricing-group","is-enabled","i18n"]))],64))),128)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.pricings,a=>{var s,c;return e.openBlock(),e.createBlock(e.unref(aP),{key:a.id,"default-expanded":!0===t.defaultExpanded||(null==(s=t.expandedPricings)?void 0:s.includes(a.id)),pricing:a,"pricing-plan-version-id":t.pricingPlanVersion.id,"pricing-plan-id":t.pricingPlanVersion.pricing_plan_id,"grouped-pricing-item-ids":null==(c=t.groupedPricingItemIdsByPricing)?void 0:c[a.id],"show-non-billable":t.showNonBillable,"is-customized-plan":!!t.pricingPlanVersion.copied_from_pricing_plan_version_id,class:"flex flex-col","is-controlled":t.isControlled,i18n:r.value,"is-enabled":l(a),"credit-types-by-id":i.value,schedule:t.schedule,onPricingToggled:e=>n.$emit("pricing-toggled",a.id,e),onPricingToggle:o[2]||(o[2]=e=>n.$emit("pricing-toggle",e))},{id:e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-title-suffix",{id:a.id})]),right:e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-settings",{pricing:a})]),"pricing-note":e.withCtx(()=>[e.renderSlot(n.$slots,"pricing-note",e.mergeProps({ref_for:!0},{pricing:a}))]),"pricing-item-header":e.withCtx(({item:t})=>[e.renderSlot(n.$slots,"pricing-item-header",{item:t})]),"pricing-entitlements-settings":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-entitlements-settings",e.mergeProps({ref_for:!0},t))]),"pricing-item-config-settings":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-settings",e.mergeProps({ref_for:!0},t,{pricingGroup:void 0}))]),"pricing-item-config-override-tooltip":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-override-tooltip",e.mergeProps({ref_for:!0},t))]),"pricing-item-config-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-additions",e.mergeProps({ref_for:!0},t))]),"pricing-item-config-price-line-additions":e.withCtx(t=>[e.renderSlot(n.$slots,"pricing-item-config-price-line-additions",e.mergeProps({ref_for:!0},t))]),_:2},1032,["default-expanded","pricing","pricing-plan-version-id","pricing-plan-id","grouped-pricing-item-ids","show-non-billable","is-customized-plan","is-controlled","i18n","is-enabled","credit-types-by-id","schedule","onPricingToggled"])}),128))])],2)}),128)):e.createCommentVNode("",!0):e.renderSlot(n.$slots,"empty-state",{key:0})],64))}}),fP={key:0,class:"flex flex-col gap-2"},gP={key:0},vP={key:1},yP={key:2},bP={key:3},wP={key:1},kP=e.defineComponent({__name:"CustomerBillingInformation",props:{customer:{},title:{},fallbackToReference:{type:Boolean,default:!0}},setup(t){const{$t:n}=HB(),r=t,o=e.computed(()=>{if(!r.customer)return;const e=sB(r.customer);return r.fallbackToReference&&""===e?r.customer.reference:r.fallbackToReference||""!==e?e:void 0}),i=e.computed(()=>r.title||n({defaultMessage:"Billing information",description:"Title for the billing information",id:"customer_billing_information.title"})),a=e.computed(()=>{if(r.customer)return"individual"in r.customer?r.customer.individual.residential_address:"organization"in r.customer?r.customer.organization.registered_address:void 0});return(r,l)=>(e.openBlock(),e.createBlock(e.unref(qz),{title:i.value},{right:e.withCtx(()=>[e.renderSlot(r.$slots,"settings")]),default:e.withCtx(()=>{var r;return[t.customer?(e.openBlock(),e.createElementBlock("div",fP,[o.value?(e.openBlock(),e.createElementBlock("div",gP,[e.createVNode(e.unref(gc),{variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n)({defaultMessage:"Name",description:"The label for the customer name in the billing information",id:"customer_billing_information.name_label"})),1)]),_:1}),e.createVNode(e.unref(gc),{variant:"body-xs"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(o.value),1)]),_:1})])):e.createCommentVNode("",!0),(null==(r=a.value)?void 0:r.line1)?(e.openBlock(),e.createElementBlock("div",vP,[e.createVNode(e.unref(gc),{variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n)({defaultMessage:"Billing address",description:"The label for the customer billing address in the billing information",id:"customer_billing_information.billing_address_label"})),1)]),_:1}),e.createVNode(e.unref(gc),{variant:"body-xs"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(iB)(a.value)),1)]),_:1})])):e.createCommentVNode("",!0),t.customer.email?(e.openBlock(),e.createElementBlock("div",yP,[e.createVNode(e.unref(gc),{variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n)({defaultMessage:"Email address",description:"The label for the customer email address in the billing information",id:"customer_billing_information.email_address_label"})),1)]),_:1}),e.createVNode(e.unref(gc),{variant:"body-xs"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.customer.email),1)]),_:1})])):e.createCommentVNode("",!0),e.unref(WS)(t.customer)?(e.openBlock(),e.createElementBlock("div",bP,[e.createVNode(e.unref(gc),{variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n)({defaultMessage:"VAT number",description:"The label for the customer Vat number in the billing information",id:"customer_billing_information.vat_number_label"})),1)]),_:1}),e.createVNode(e.unref(gc),{variant:"body-xs"},{default:e.withCtx(()=>{var n,r;return[e.createTextVNode(e.toDisplayString(null==(r=null==(n=t.customer.organization.tax_ids)?void 0:n[0])?void 0:r.id),1)]}),_:1})])):e.createCommentVNode("",!0)])):(e.openBlock(),e.createElementBlock("div",wP,[e.createVNode(e.unref(gc),{variant:"body-xs",shade:"lighter"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n)({defaultMessage:"No billing information to display.",description:"Text that is being displayed when there is no active subscription in the subscriptions block",id:"customer_overview.billing_information.no_billing_information_available"})),1)]),_:1})]))]}),_:3},8,["title"]))}}),xP={class:"flex items-center justify-between md:py-2"},_P=e.defineComponent({__name:"InvoiceHeader",props:{invoice:{},paymentAttempts:{},downloadService:{},showDownloadButton:{type:Boolean},variant:{default:"internal"}},setup(t){const n=t,{$t:r,formatDate:o}=HB(),i=e.computed(()=>n.paymentAttempts.findLast(e=>"AUTHORIZED"===e.result)),a=e.computed(()=>r({defaultMessage:"Due on {date}",description:"Label for due date, where {date} gets replaced with the due date",id:"invoice.due_on_label"},{date:o({date:n.invoice.due_date,format:"date",offsetType:"offsetted",timezone:n.invoice.customer.timezone})})),l=e.computed(()=>o({date:n.invoice.invoice_date,format:"date",offsetType:"offsetted",timezone:n.invoice.customer.timezone})),s=e.computed(()=>"external"===n.variant?l.value:n.invoice.invoice_number||"N/A"),c=e.computed(()=>{if(n.invoice.paid&&i.value)return r({defaultMessage:"Paid on {date}",description:"Label for payment date, where {date} gets replaced with the date",id:"invoice.paid_on_label"},{date:o({date:i.value.created_at,format:"date",offsetType:"offsetted",timezone:n.invoice.customer.timezone})})}),d=e.computed(()=>"external"===n.variant?[n.invoice.invoice_number,c.value||a.value].join(" - "):c.value||a.value);return(n,o)=>(e.openBlock(),e.createElementBlock("div",xP,[e.createVNode(e.unref(LM),{title:s.value},{suffix:e.withCtx(()=>[t.invoice.paid?(e.openBlock(),e.createBlock(e.unref(mc),{key:0,color:"green",class:"ml-2"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({defaultMessage:"Paid",description:"The paid chip label text for a paid invoice",id:"invoice.paid_chip"})),1)]),_:1})):e.createCommentVNode("",!0)]),subTitle:e.withCtx(()=>[e.createVNode(e.unref(gc),{variant:"body-xs",class:"flex gap-1"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(d.value),1)]),_:1})]),_:1},8,["title"]),t.showDownloadButton?(e.openBlock(),e.createBlock(e.unref(az),{key:0,size:"lg",variant:"outline","download-service":t.downloadService,"mobile-icon-only":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({defaultMessage:"Download PDF",description:"Title for button download pdf invoice",id:"invoice.download_pdf_button"})),1)]),_:1},8,["download-service"])):e.createCommentVNode("",!0)]))}}),CP={class:"w-full"};const EP=fB({},[["render",function(t,n){return e.openBlock(),e.createElementBlock("table",CP,[e.renderSlot(t.$slots,"default")])}]]),SP=e.defineComponent({__name:"InvoiceTableData",props:{number:{type:Boolean,default:!1},hasPadding:{type:Boolean,default:!0}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("td",{class:e.normalizeClass({"text-right tabular-nums":t.number,"py-2":t.hasPadding})},[e.renderSlot(n.$slots,"default")],2))}),BP=e.defineComponent({__name:"InvoiceTableHeader",props:{left:{type:Boolean,default:!1},right:{type:Boolean,default:!1}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("th",{class:e.normalizeClass(["py-1.5 font-bold border-b text-gray-400 text-xs uppercase",{"text-left":t.left,"text-right":t.right}])},[e.renderSlot(n.$slots,"default")],2))}),NP={class:"flex items-center"},MP={key:0,class:"text-xs text-gray-400"},TP={class:"flex items-center"},VP={key:0},AP=e.defineComponent({__name:"InvoiceSubLineRow",props:{subLines:{},isOpen:{type:Boolean},lineOrder:{},periodOrder:{},groupOrder:{},processingOnlyCustomers:{}},setup(t){const{formatMessage:n}=HB(),r=t,o=e=>{var t;const o=null==(t=r.processingOnlyCustomers)?void 0:t.find(t=>t.id===e);return o?sB(o):n({id:"generic.not_available",defaultMessage:"N/A",description:"Used in scenarios where no data is available to be displayed"})},i=e=>{var t;return(null==(t=e.usage_based_conversion)?void 0:t.conditions)??e.conditions};return(n,r)=>t.subLines&&t.isOpen?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[t.processingOnlyCustomers?e.createCommentVNode("",!0):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(t.subLines,(o,a)=>(e.openBlock(),e.createElementBlock("tr",{key:a,class:e.normalizeClass(a>0?"border-t":"")},[e.createVNode(e.unref(SP),{class:"w-1/3"},{default:e.withCtx(()=>{var r,a,l,s,c,d;return[e.createElementVNode("div",NP,[e.renderSlot(n.$slots,"invoice-line-prefix",{lineOrder:t.lineOrder,periodOrder:t.periodOrder,groupOrder:t.groupOrder}),e.createElementVNode("div",null,[e.createElementVNode("div",null,[o.description?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(o.description),1)],64)):o.details.description?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(o.details.description),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(" N/A ")],64))]),(null==(r=i(o))?void 0:r.name)||(null==(a=i(o))?void 0:a.meter_properties)?(e.openBlock(),e.createElementBlock("div",MP,[(null==(l=i(o))?void 0:l.name)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(null==(s=i(o))?void 0:s.name),1)],64)):(null==(c=i(o))?void 0:c.meter_properties)?(e.openBlock(),e.createBlock(e.unref(aO),{key:1,comparators:null==(d=i(o))?void 0:d.meter_properties},null,8,["comparators"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])])]}),_:2},1024),e.createVNode(e.unref(SP),{number:"",class:"w-1/7 text-right tabular-nums"},{default:e.withCtx(()=>{var t,n;return[e.createTextVNode(e.toDisplayString((null==(n=null==(t=o.details.conversion)?void 0:t.credits)?void 0:n.quantity)??"N/A"),1)]}),_:2},1024),e.createVNode(e.unref(SP),{class:"w-1/7 text-right tabular-nums"},{default:e.withCtx(()=>{var t,n;return[(null==(t=o.details.band)?void 0:t.amount)?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:o.details.band.amount},null,8,["value"])):(null==(n=o.details.band)?void 0:n.percentage)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(o.details.band.percentage)+"% ",1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(" N/A ")],64))]}),_:2},1024),e.createVNode(e.unref(SP),null,{default:e.withCtx(()=>[...r[0]||(r[0]=[e.createTextVNode(" ",-1)])]),_:1}),o.details.amount?(e.openBlock(),e.createBlock(e.unref(SP),{key:0,class:"w-1/7 text-right tabular-nums"},{default:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:o.details.amount},null,8,["value"])]),_:2},1024)):e.createCommentVNode("",!0)],2))),128)),t.processingOnlyCustomers?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(t.subLines,(t,r)=>(e.openBlock(),e.createElementBlock("tr",{key:r,tabindex:void 0,class:e.normalizeClass(["group",{"border-t":0!==r}])},[e.createVNode(e.unref(SP),{class:"pl-4"},{default:e.withCtx(()=>[e.createElementVNode("div",TP,[t.processing_only_customer_resource_id?(e.openBlock(),e.createElementBlock("div",VP,e.toDisplayString(o(t.processing_only_customer_resource_id)),1)):e.createCommentVNode("",!0)])]),_:2},1024),e.renderSlot(n.$slots,"subline-content",{details:t.details,hideTaxDetails:!0})],2))),128)):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)}}),zP=["tabindex","onClick"],OP={class:"flex items-center"},IP=e.defineComponent({__name:"InvoiceDiscountMarkup",props:{lines:{},type:{},handleToggleItems:{type:Function},formatIndex:{type:Function},expandedItems:{},isExpandable:{type:Boolean},invoicePeriodOrder:{},groupOrder:{}},setup(t){const n=HB(),{getIsOpen:r,toggle:o}=vB(),i=(e,t)=>`${e}-line-${t}`;return(a,l)=>(e.openBlock(),e.createBlock(e.unref(EP),null,{default:e.withCtx(()=>[e.createElementVNode("tr",null,[e.createVNode(e.unref(BP),{left:"",class:"w-3/5"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.table_header.quantity",defaultMessage:"Quantity",description:"Table header for quantity column"})),1)]),_:1}),e.createVNode(e.unref(BP),{colspan:"2"},{default:e.withCtx(()=>[...l[0]||(l[0]=[e.createTextVNode(" ",-1)])]),_:1}),e.createVNode(e.unref(BP),{left:"",class:"w-1/5"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString("DISCOUNT"===t.type?e.unref(n).$t({id:"invoice.table_header.discount",defaultMessage:"Discount",description:"Table header for discount column"}):e.unref(n).$t({id:"invoice.table_header.markup",defaultMessage:"Markup",description:"Table header for markup column"})),1)]),_:1}),e.createVNode(e.unref(BP),{left:"",class:"w-1/5"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString("DISCOUNT"===t.type?e.unref(n).$t({id:"invoice.table_header.total",defaultMessage:"Total",description:"Table header for total column"}):" "),1)]),_:1}),e.createVNode(e.unref(BP),{right:"",class:"w-1/5"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.table_header.sub_total",defaultMessage:"Subtotal",description:"Table header for the column containing the subtotal for invoices"})),1)]),_:1})]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.lines,(n,s)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:s},[e.createElementVNode("tr",{class:e.normalizeClass(["border-t",{"cursor-pointer":t.isExpandable}]),tabindex:t.isExpandable?0:void 0,onClick:e=>{return r=t.groupOrder,a=n.line_order,void o(i(r,a));var r,a}},[e.createVNode(e.unref(SP),{class:"w-3/5"},{default:e.withCtx(()=>{var o,l;return[n.sub_lines?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,icon:"keyboard_arrow_down",size:"md",class:e.normalizeClass(["-translate-x-7 absolute text-slate-400",{"-rotate-90":!e.unref(r)(i(t.groupOrder,n.line_order))}])},null,8,["class"])):e.createCommentVNode("",!0),e.createElementVNode("div",OP,[e.renderSlot(a.$slots,"invoice-line-prefix",{lineOrder:n.line_order,periodOrder:t.invoicePeriodOrder,groupOrder:t.groupOrder}),n.description?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(n.description),1)],64)):(null==(o=n.details)?void 0:o.description)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(null==(l=n.details)?void 0:l.description),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode("N/A")],64))])]}),_:2},1024),e.createVNode(e.unref(SP),{colspan:"2"},{default:e.withCtx(()=>[...l[1]||(l[1]=[e.createTextVNode(" ",-1)])]),_:1}),e.createVNode(e.unref(SP),{class:"tabular-nums w-1/5"},{default:e.withCtx(()=>{var t,r,o;return[e.createTextVNode(e.toDisplayString((null==(r=null==(t=n.details)?void 0:t.band)?void 0:r.percentage)?`${null==(o=n.details)?void 0:o.band.percentage}%`:" "),1)]}),_:2},1024),e.createVNode(e.unref(SP),{class:"w-1/5"},{default:e.withCtx(()=>[...l[2]||(l[2]=[e.createTextVNode(" ",-1)])]),_:1}),e.createVNode(e.unref(SP),{number:"",class:"w-1/5"},{default:e.withCtx(()=>{var t;return[(null==(t=n.details)?void 0:t.amount)?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:n.details.amount},null,8,["value"])):e.createCommentVNode("",!0)]}),_:2},1024)],10,zP),e.createVNode(AP,{ref_for:!0,ref:i(t.groupOrder,n.line_order),"sub-lines":n.sub_lines??[],"line-order":n.line_order,"is-open":e.unref(r)(i(t.groupOrder,n.line_order)),"period-order":t.invoicePeriodOrder,"group-order":t.groupOrder},null,8,["sub-lines","line-order","is-open","period-order","group-order"])],64))),128))]),_:3}))}}),DP={key:0,colspan:"4",class:"p-0"},PP=e.defineComponent({__name:"InvoiceTaxes",props:{taxCategories:{}},setup(t){const n=HB();return(r,o)=>(e.openBlock(),e.createBlock(e.unref(EP),{class:"table-fixed"},{default:e.withCtx(()=>[e.createElementVNode("tr",null,[e.createVNode(e.unref(BP),{left:""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.table_header.tax type",defaultMessage:"Tax type",description:"Table header for the column containing the tax type"})),1)]),_:1}),e.createVNode(e.unref(BP),{right:""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.table_header.base amount",defaultMessage:"Base amount",description:"Table header for the column containing the base amount"})),1)]),_:1}),e.createVNode(e.unref(BP),{right:""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.table_header.tax_percentage",defaultMessage:"Percentage",description:"Table header for the column containing the tax percentage"})),1)]),_:1}),e.createVNode(e.unref(BP),{right:""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.table_header.tax amount",defaultMessage:"Tax amount",description:"Table header for the column containing the tax amount"})),1)]),_:1})]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.taxCategories,(t,n)=>(e.openBlock(),e.createElementBlock("tr",{key:n},[t.rates?(e.openBlock(),e.createElementBlock("td",DP,[e.createVNode(e.unref(EP),{class:"table-fixed"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.rates,(n,r)=>(e.openBlock(),e.createElementBlock("tr",{key:r},[e.createVNode(e.unref(SP),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(n.name)+" ("+e.toDisplayString(t.category)+") ",1)]),_:2},1024),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:t.base_amount},null,8,["value"])]),_:2},1024),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(n.percentage)+"%",1)]),_:2},1024),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:n.tax_amount},null,8,["value"])]),_:2},1024)]))),128))]),_:2},1024)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(e.unref(SP),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.name)+" ("+e.toDisplayString(t.category)+") ",1)]),_:2},1024),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:t.base_amount},null,8,["value"])]),_:2},1024),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.percentage)+"%",1)]),_:2},1024),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:t.tax_amount},null,8,["value"])]),_:2},1024)],64))]))),128))]),_:1}))}}),$P=["tabindex","onClick"],LP={class:"flex items-center"},RP=e.defineComponent({__name:"InvoiceCommitment",props:{commitments:{},groupOrder:{},invoicePeriodOrder:{}},setup(t){const n=HB(),{getIsOpen:r,toggle:o}=vB(),i=(e,t)=>`${e}-line-${t}`;return(a,l)=>(e.openBlock(),e.createBlock(e.unref(EP),null,{default:e.withCtx(()=>[e.createElementVNode("tr",null,[e.createVNode(e.unref(BP),{left:"",colspan:"5"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.table_header.unit",defaultMessage:"Unit",description:"Table header for the column containing the number of units of invoice groups"})),1)]),_:1}),e.createVNode(e.unref(BP),{right:"",class:"w-60"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.table_header.sub_total",defaultMessage:"Subtotal",description:"Table header for the column containing the subtotal for invoices"})),1)]),_:1})]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.commitments,(s,c)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:c},[e.createElementVNode("tr",{class:e.normalizeClass(["border-t",{"cursor-pointer":s.sub_lines}]),tabindex:s.sub_lines?0:void 0,onClick:e=>{return n=t.groupOrder,r=s.line_order,void o(i(n,r));var n,r}},[e.createVNode(e.unref(SP),{colspan:"2"},{default:e.withCtx(()=>{var o,l;return[s.sub_lines?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,icon:"keyboard_arrow_down",size:"md",class:e.normalizeClass(["-translate-x-7 absolute text-slate-400",{"-rotate-90":!e.unref(r)(i(t.groupOrder,s.line_order))}])},null,8,["class"])):e.createCommentVNode("",!0),e.createElementVNode("div",LP,[e.renderSlot(a.$slots,"invoice-line-prefix",{lineOrder:s.line_order,periodOrder:t.invoicePeriodOrder,groupOrder:t.groupOrder}),s.description?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(s.description),1)],64)):(null==(o=s.details)?void 0:o.description)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(null==(l=s.details)?void 0:l.description),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"generic.not_available",defaultMessage:"N/A",description:"Used in scenarios where no data is available to be displayed"})),1)],64))])]}),_:2},1024),e.createVNode(e.unref(SP),{colspan:"3"},{default:e.withCtx(()=>[...l[0]||(l[0]=[e.createTextVNode(" ",-1)])]),_:1}),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>{var t,n;return[(null==(t=s.details)?void 0:t.amount)?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:null==(n=s.details)?void 0:n.amount},null,8,["value"])):e.createCommentVNode("",!0)]}),_:2},1024)],10,$P),e.createVNode(AP,{ref_for:!0,ref:i(t.groupOrder,s.line_order),"sub-lines":s.sub_lines??[],"line-order":s.line_order,"period-order":t.invoicePeriodOrder,"group-order":t.groupOrder,"is-open":e.unref(r)(i(t.groupOrder,s.line_order))},null,8,["sub-lines","line-order","period-order","group-order","is-open"])],64))),128))]),_:3}))}}),HP=["tabindex"],FP={key:0},jP={colspan:"2",class:"p-0"},UP={class:"px-9 py-3 -mx-9 bg-gray-50 text-xs"},GP=e.defineComponent({__name:"InvoiceGroupDiscountMarkup",props:{heading:{},group:{},expandedItems:{},handleToggleItems:{type:Function},formatIndex:{type:Function},invoicePeriodOrder:{},groupOrder:{},isExpandable:{type:Boolean},amountType:{},processingOnlyCustomers:{}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("tr",{class:e.normalizeClass(["border-t",{"cursor-pointer":t.isExpandable}]),tabindex:t.isExpandable?0:void 0,onClick:r[0]||(r[0]=e=>t.handleToggleItems(t.formatIndex(t.invoicePeriodOrder,t.groupOrder))),onKeyup:[r[1]||(r[1]=e.withKeys(e=>t.handleToggleItems(t.formatIndex(t.invoicePeriodOrder,t.groupOrder)),["enter"])),r[2]||(r[2]=e.withKeys(e=>t.handleToggleItems(t.formatIndex(t.invoicePeriodOrder,t.groupOrder)),["space"]))]},[e.createVNode(e.unref(SP),{class:"p-0"},{default:e.withCtx(()=>[t.isExpandable?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,icon:"keyboard_arrow_down",size:"md",class:e.normalizeClass(["-translate-x-7 absolute text-slate-400",{"-rotate-90":!t.expandedItems.includes(t.formatIndex(t.invoicePeriodOrder,t.groupOrder))}])},null,8,["class"])):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(t.heading),1)]),_:1}),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>["INCLUDING_TAX"===t.amountType?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.group.amount_including_tax},null,8,["value"])):(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:t.group.amount_excluding_tax},null,8,["value"]))]),_:1})],42,HP),t.expandedItems.includes(t.formatIndex(t.invoicePeriodOrder,t.groupOrder))&&t.group.lines?(e.openBlock(),e.createElementBlock("tr",FP,[e.createElementVNode("td",jP,[e.createElementVNode("div",UP,[e.createVNode(e.unref(IP),{type:t.group.type,lines:t.group.lines,"format-index":t.formatIndex,"handle-toggle-items":t.handleToggleItems,"expanded-items":t.expandedItems,"is-expandable":t.isExpandable,"invoice-period-order":t.invoicePeriodOrder,"group-order":t.groupOrder},{"invoice-line-prefix":e.withCtx(t=>[e.renderSlot(n.$slots,"invoice-line-prefix",e.normalizeProps(e.guardReactiveProps(t)))]),_:3},8,["type","lines","format-index","handle-toggle-items","expanded-items","is-expandable","invoice-period-order","group-order"])])])])):e.createCommentVNode("",!0)],64))}),qP=["tabindex"],ZP={key:2,class:"inline-flex justify-center items-center w-3.5 h-3.5 rounded-full bg-blue-100 text-blue-600 text-2xs ml-1 font-bold"},WP={key:0},KP={colspan:"2",class:"p-0"},JP={class:"px-9 py-3 -mx-9 bg-gray-50 text-xs"},YP=e.defineComponent({__name:"InvoiceGroupRevenue",props:{group:{},expandedItems:{},handleToggleItems:{type:Function},formatIndex:{type:Function},invoicePeriodOrder:{},groupOrder:{},isExpandable:{type:Boolean},amountType:{},processingOnlyCustomers:{}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("tr",{class:e.normalizeClass(["border-t",{"cursor-pointer":t.isExpandable}]),tabindex:t.isExpandable?0:void 0,onClick:r[0]||(r[0]=e=>t.handleToggleItems(t.formatIndex(t.invoicePeriodOrder,t.groupOrder))),onKeyup:[r[1]||(r[1]=e.withKeys(e=>t.handleToggleItems(t.formatIndex(t.invoicePeriodOrder,t.groupOrder)),["enter"])),r[2]||(r[2]=e.withKeys(e=>t.handleToggleItems(t.formatIndex(t.invoicePeriodOrder,t.groupOrder)),["space"]))]},[e.createVNode(e.unref(SP),{class:"p-0"},{default:e.withCtx(()=>{var n,r,o,i;return[t.isExpandable?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,icon:"keyboard_arrow_down",size:"md",class:e.normalizeClass(["-translate-x-7 absolute text-slate-400",{"-rotate-90":!t.expandedItems.includes(t.formatIndex(t.invoicePeriodOrder,t.groupOrder))}])},null,8,["class"])):e.createCommentVNode("",!0),(null==(n=t.group.pricing)?void 0:n.name)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(t.group.pricing.name)+" ",1),(null==(r=t.group.products)?void 0:r.length)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(" - ")],64)):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(e.unref(Tx)((null==(o=t.group.products)?void 0:o.map(e=>e.name))??[]))+" ",1),t.isExpandable?(e.openBlock(),e.createElementBlock("span",ZP,e.toDisplayString(null==(i=t.group.lines)?void 0:i.length),1)):e.createCommentVNode("",!0)]}),_:1}),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>["INCLUDING_TAX"===t.amountType?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.group.amount_including_tax},null,8,["value"])):(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:t.group.amount_excluding_tax},null,8,["value"]))]),_:1})],42,qP),t.expandedItems.includes(t.formatIndex(t.invoicePeriodOrder,t.groupOrder))?(e.openBlock(),e.createElementBlock("tr",WP,[e.createElementVNode("td",KP,[e.createElementVNode("div",JP,[e.createVNode(e.unref(C$),{"invoice-period-order":t.invoicePeriodOrder,"start-date":t.group.start_at,"end-date":t.group.end_at,total:t.group.amount_excluding_tax,group:t.group,"amount-type":t.amountType,"processing-only-customers":t.processingOnlyCustomers},{"invoice-line-prefix":e.withCtx(t=>[e.renderSlot(n.$slots,"invoice-line-prefix",e.normalizeProps(e.guardReactiveProps(t)))]),"one-off-line-context-menu":e.withCtx(r=>[e.renderSlot(n.$slots,"one-off-line-context-menu",e.mergeProps(r,{groupOrder:t.groupOrder}))]),_:3},8,["invoice-period-order","start-date","end-date","total","group","amount-type","processing-only-customers"])])])])):e.createCommentVNode("",!0)],64))}),XP=["tabindex"],QP={key:0},e$={colspan:"2",class:"p-0"},t$={class:"px-9 py-3 -mx-9 bg-gray-50 text-xs"},n$=e.defineComponent({__name:"InvoiceGroupCommitment",props:{group:{},expandedItems:{},handleToggleItems:{type:Function},formatIndex:{type:Function},invoicePeriodOrder:{},groupOrder:{},isExpandable:{type:Boolean},amountType:{},processingOnlyCustomers:{}},setup(t){const n=HB();return(r,o)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("tr",{class:e.normalizeClass(["border-t",{"cursor-pointer":t.isExpandable}]),tabindex:t.isExpandable?0:void 0,onClick:o[0]||(o[0]=e=>t.handleToggleItems(t.formatIndex(t.invoicePeriodOrder,t.groupOrder))),onKeyup:[o[1]||(o[1]=e.withKeys(e=>t.handleToggleItems(t.formatIndex(t.invoicePeriodOrder,t.groupOrder)),["enter"])),o[2]||(o[2]=e.withKeys(e=>t.handleToggleItems(t.formatIndex(t.invoicePeriodOrder,t.groupOrder)),["space"]))]},[e.createVNode(e.unref(SP),{class:"p-0"},{default:e.withCtx(()=>[t.isExpandable?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,icon:"keyboard_arrow_down",size:"md",class:e.normalizeClass(["-translate-x-7 absolute text-slate-400",{"-rotate-90":!t.expandedItems.includes(t.formatIndex(t.invoicePeriodOrder,t.groupOrder))}])},null,8,["class"])):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(e.unref(n).$t({id:"invoice.commitment_heading",defaultMessage:"Commitment",description:"Heading used for commitment in invoice tables"})),1)]),_:1}),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>["INCLUDING_TAX"===t.amountType?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.group.amount_including_tax},null,8,["value"])):(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:t.group.amount_excluding_tax},null,8,["value"]))]),_:1})],42,XP),t.expandedItems.includes(t.formatIndex(t.invoicePeriodOrder,t.groupOrder))&&t.group.lines?(e.openBlock(),e.createElementBlock("tr",QP,[e.createElementVNode("td",e$,[e.createElementVNode("div",t$,[e.createVNode(e.unref(RP),{commitments:t.group.lines,"format-index":t.formatIndex,"handle-toggle-items":t.handleToggleItems,"expanded-items":t.expandedItems,"is-expandable":t.isExpandable,"invoice-period-order":t.invoicePeriodOrder,"group-order":t.groupOrder},{"invoice-line-prefix":e.withCtx(t=>[e.renderSlot(r.$slots,"invoice-line-prefix",e.normalizeProps(e.guardReactiveProps(t)))]),_:3},8,["commitments","format-index","handle-toggle-items","expanded-items","is-expandable","invoice-period-order","group-order"])])])])):e.createCommentVNode("",!0)],64))}}),r$={class:"flex gap-4"},o$={class:"flex gap-2 items-center"},i$=e.defineComponent({__name:"PricingClauseChip",props:{iconName:{},chipColor:{}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("div",r$,[e.createVNode(e.unref(mc),{color:t.chipColor},{default:e.withCtx(()=>[e.createElementVNode("div",o$,[e.createVNode(e.unref(hc),{icon:t.iconName,size:"xs"},null,8,["icon"]),e.createElementVNode("span",null,[e.renderSlot(n.$slots,"chip-content")])])]),_:3},8,["color"]),e.renderSlot(n.$slots,"chip-postfix")]))}),a$={class:"flex flex-col gap-2"},l$=e.defineComponent({__name:"InvoicePricingClauseChip",props:{clauseType:{},priceDetailsBand:{},invoiceLineDescription:{}},setup(t){const n=HB();return(r,o)=>(e.openBlock(),e.createElementBlock("div",a$,[e.createElementVNode("span",null,e.toDisplayString(t.invoiceLineDescription),1),"DISCOUNT"===t.clauseType&&t.priceDetailsBand?(e.openBlock(),e.createBlock(e.unref(i$),{key:0,"icon-name":"south_east","chip-color":"yellow"},e.createSlots({_:2},[t.priceDetailsBand.amount?{name:"chip-content",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.amount_discount",defaultMessage:"{amount} discount",description:"Represents a certain amount of discount, where {amount} is replaced with the amount"},{amount:e.unref(Bx)(t.priceDetailsBand.amount)}).toUpperCase()),1)]),key:"0"}:t.priceDetailsBand.percentage?{name:"chip-content",fn:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.percentage_discount",defaultMessage:"{percentage}% discount",description:"Represents a certain percentage of discount, where {percentage} is replaced with the percentage (number only)"},{percentage:t.priceDetailsBand.percentage??"0"}).toUpperCase()),1)]),key:"1"}:void 0]),1024)):"ADJUSTMENT"===t.clauseType?(e.openBlock(),e.createBlock(e.unref(i$),{key:1,"icon-name":"info","chip-color":"yellow"},{"chip-content":e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.adjustment_chip_body",defaultMessage:"Adjustment",description:"Used on invoice lines to mark as adjusted"}).toUpperCase()),1)]),_:1})):"MARKUP"===t.clauseType?(e.openBlock(),e.createBlock(e.unref(i$),{key:2,"icon-name":"north_east","chip-color":"teal-light"},{"chip-content":e.withCtx(()=>{var r;return[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.markup_percentage",defaultMessage:"{percentage}% markup",description:"Markup percentage, where {percentage} is replaced with the percentage (number only)"},{percentage:(null==(r=t.priceDetailsBand)?void 0:r.percentage)??"0"}).toUpperCase()),1)]}),_:1})):"COMMITMENT"===t.clauseType?(e.openBlock(),e.createBlock(e.unref(i$),{key:3,"icon-name":"sell","chip-color":"orange"},{"chip-content":e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.commitment",defaultMessage:"commitment",description:"Used on invoice lines to mark as commitment"}).toUpperCase()),1)]),_:1})):e.createCommentVNode("",!0)]))}}),s$={class:"items-left flex flex-col gap-1 leading-none"},c$={class:"flex items-center"},d$={key:0,class:"ml-1 text-xs text-gray-400"},u$={key:0},p$={key:1,class:"text-xs text-gray-400"},h$={key:2,class:"text-xs text-gray-400"},m$={class:"text-[9pt] text-slate-600"},f$=e.defineComponent({__name:"InvoiceLineRow",props:{data:{},isLast:{type:Boolean},periodOrder:{},groupOrder:{},groupType:{},isExpanded:{type:Boolean}},setup(t){const{$t:n}=HB(),r=t,o=e=>{var t,n;if(!e)return"";let r="0",o=" +";if(e.tier_lower_bound&&"number"in e.tier_lower_bound)r=(null==(t=e.tier_lower_bound)?void 0:t.number)??"0";else if(e.tier_lower_bound&&"amount"in e.tier_lower_bound){const{quantity:t,currency:n}=e.tier_lower_bound.amount;r=`${n} ${t??0}`}if(e.tier_top_bound&&"number"in e.tier_top_bound)o=` - ${null==(n=e.tier_top_bound)?void 0:n.number}`;else if(e.tier_top_bound&&"amount"in e.tier_top_bound){const{quantity:t,currency:n}=e.tier_top_bound.amount;o=` - ${n} ${t}`}return r+o},i=e.computed(()=>{var e;return null==(e=r.data.details)?void 0:e.included_volume_details}),a=e.computed(()=>{var e,t;return(null==(e=r.data)?void 0:e.product_items)?Tx(r.data.product_items.map(e=>e.name)):(null==(t=r.data)?void 0:t.description)??"N/A"});return(r,l)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(e.unref(SP),{class:"align-top"},{default:e.withCtx(()=>{var l,s,c,d,u,p,h,m,f,g,v,y,b,w,k,x,_,C;return[e.createElementVNode("div",s$,[e.createElementVNode("div",null,[t.data.sub_lines?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,icon:"keyboard_arrow_down",size:"md",class:e.normalizeClass(["absolute -translate-x-7 -translate-y-2 text-slate-400",{"-rotate-90":!t.isExpanded}])},null,8,["class"])):e.createCommentVNode("",!0),e.createElementVNode("div",c$,[e.renderSlot(r.$slots,"invoice-line-prefix",{lineOrder:t.data.line_order,periodOrder:t.periodOrder,groupOrder:t.groupOrder}),["PRICING","REVENUE","ONE_OFF"].includes(t.data.type)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(a.value)+" ",1),"ONE_OFF"===t.data.type&&"ONE_OFF"!==t.groupType?(e.openBlock(),e.createElementBlock("div",d$,e.toDisplayString(e.unref(Nx)(t.data.type)),1)):e.createCommentVNode("",!0)],64)):(e.openBlock(),e.createBlock(l$,{key:1,"invoice-line-description":a.value,"clause-type":t.data.type,"price-details-band":null==(l=t.data.details)?void 0:l.band},null,8,["invoice-line-description","clause-type","price-details-band"]))])]),["TIERED","STAIR_STEP","TOP_TIERED"].includes(t.data.pricing_type)&&!i.value&&(null==(s=t.data.details)?void 0:s.band)?(e.openBlock(),e.createElementBlock("div",u$,e.toDisplayString(o(null==(c=t.data.details)?void 0:c.band)),1)):e.createCommentVNode("",!0),(null==(u=null==(d=t.data.details)?void 0:d.split_pricing)?void 0:u.meter_properties)?(e.openBlock(),e.createElementBlock("span",p$,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(null==(h=null==(p=t.data.details)?void 0:p.split_pricing)?void 0:h.meter_properties,(n,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createTextVNode(e.toDisplayString(n.meter_property.name)+": "+e.toDisplayString(n.value),1),r<t.data.details.split_pricing.meter_properties.length-1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(", "))],64)):e.createCommentVNode("",!0)],64))),256))])):e.createCommentVNode("",!0),(null==(m=t.data.conditions)?void 0:m.name)||(null==(f=t.data.conditions)?void 0:f.meter_properties)?(e.openBlock(),e.createElementBlock("div",h$,[t.data.conditions.name?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(t.data.conditions.name),1)],64)):t.data.conditions.meter_properties?(e.openBlock(),e.createBlock(e.unref(aO),{key:1,comparators:t.data.conditions.meter_properties},null,8,["comparators"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createElementVNode("span",m$,["BELOW_MINIMUM_AMOUNT"===(null==(g=t.data.details)?void 0:g.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(e.unref(n)({id:"invoice.line.band_minimum_amount",defaultMessage:"Band minimum amount",description:"Minimum amount specified in a band"}))+" ",1),(null==(v=t.data.details.band)?void 0:v.minimum_amount)?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.data.details.band.minimum_amount},null,8,["value"])):e.createCommentVNode("",!0)],64)):"NOT_HIT"===(null==(y=t.data.details)?void 0:y.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(e.unref(n)({id:"invoice.line.price_bound_within_bounds",defaultMessage:"Within bounds",description:"Label used when min and max bounds are specified but reached"})),1)],64)):"ABOVE_MAXIMUM_AMOUNT"===(null==(b=t.data.details)?void 0:b.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(e.toDisplayString(e.unref(n)({id:"invoice.line.price_bound_maximum_amount",defaultMessage:"Maximum amount",description:"Minimum amount specified in a band"}))+" ",1),(null==(w=t.data.details.band)?void 0:w.maximum_amount)?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.data.details.band.maximum_amount},null,8,["value"])):e.createCommentVNode("",!0)],64)):"BELOW_MINIMUM_NUMBER"===(null==(k=t.data.details)?void 0:k.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[e.createTextVNode(e.toDisplayString(e.unref(n)({id:"invoice.line.band_minimum_number",defaultMessage:"Minimum number",description:"Minimum number of units specified in a band"}))+" "+e.toDisplayString(null==(x=t.data.details.band)?void 0:x.minimum_number),1)],64)):"ABOVE_MAXIMUM_NUMBER"===(null==(_=t.data.details)?void 0:_.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[e.createTextVNode(e.toDisplayString(e.unref(n)({id:"invoice.line.band_maximum_number",defaultMessage:"Maximum number",description:"Maximum number of units specified in a band"}))+" "+e.toDisplayString(null==(C=t.data.details.band)?void 0:C.maximum_number),1)],64)):e.createCommentVNode("",!0)])]}),_:3}),e.renderSlot(r.$slots,"line-content",{details:t.data.details})],64))}}),g$={key:4,class:"text-xs text-gray-400"},v$={key:1,class:"tabular-nums"},y$={class:"text-2xs text-gray-500"},b$={key:0,class:"flex justify-end"},w$={class:"flex gap-1 items-center justify-end"},k$={key:0,class:"text-2xs text-gray-500 tabular-nums"},x$=e.defineComponent({__name:"InvoiceRowContent",props:{pricingType:{},details:{},taxCategories:{},amountType:{},hideTaxDetails:{type:Boolean}},setup(t){const n=HB(),r=t,o=e.computed(()=>{var e;return null==(e=r.details)?void 0:e.included_volume_details}),i=e.computed(()=>{var e;return null==(e=o.value)?void 0:e.available_included_volume});return(r,o)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(e.unref(SP),{number:"",class:"align-top"},{default:e.withCtx(()=>{var r,o,a,l,s,c,d,u,p,h,m,f,g,v,y,b,w,k,x,_,C,E,S,B,N;return["PASS_THROUGH"!==t.pricingType?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(null==(r=t.details)?void 0:r.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},["BELOW_MINIMUM_AMOUNT"===(null==(o=t.details)?void 0:o.price_bound)||"ABOVE_MAXIMUM_AMOUNT"===(null==(a=t.details)?void 0:a.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(null==(l=t.details)?void 0:l.meter_value.count),1)],64)):"NOT_HIT"===(null==(s=t.details)?void 0:s.price_bound)&&"amount"in t.details.meter_value&&(null==(d=null==(c=t.details)?void 0:c.meter_value)?void 0:d.amount)?(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:null==(p=null==(u=t.details)?void 0:u.meter_value)?void 0:p.amount},null,8,["value"])):"NOT_HIT"===(null==(h=t.details)?void 0:h.price_bound)&&"number"in t.details.meter_value&&(null==(f=null==(m=t.details)?void 0:m.meter_value)?void 0:f.number)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createTextVNode(e.toDisplayString(null==(v=null==(g=t.details)?void 0:g.meter_value)?void 0:v.number),1)],64)):"RATIO"===(null==(y=t.details)?void 0:y.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[e.createTextVNode(e.toDisplayString(null==(b=t.details)?void 0:b.meter_value.number),1)],64)):"BELOW_MINIMUM_NUMBER"===(null==(w=t.details)?void 0:w.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[e.createTextVNode(e.toDisplayString(null==(x=null==(k=t.details)?void 0:k.band)?void 0:x.minimum_number),1)],64)):"ABOVE_MAXIMUM_NUMBER"===(null==(_=t.details)?void 0:_.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[e.createTextVNode(e.toDisplayString(null==(E=null==(C=t.details)?void 0:C.band)?void 0:E.maximum_number),1)],64)):e.createCommentVNode("",!0)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[(null==(S=t.details)?void 0:S.meter_value)&&"number"in t.details.meter_value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(t.details.meter_value.number),1)],64)):(null==(B=t.details)?void 0:B.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(t.details.total_count),1)],64)):(null==(N=t.details)?void 0:N.meter_value)&&"amount"in t.details.meter_value?(e.openBlock(),e.createBlock(e.unref(YB),{key:2,value:t.details.meter_value.amount},null,8,["value"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[e.createTextVNode("1")],64)),i.value?(e.openBlock(),e.createElementBlock("div",g$,["AMOUNT"===i.value.type?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(e.unref(YB),{value:i.value.amount},null,8,["value"]),e.createTextVNode(" "+e.toDisplayString(e.unref(n).$t({id:"invoice.line.included",defaultMessage:"included",description:"Used to specify an included amount. Should be lowercase."})),1)],64)):"NUMBER"===i.value.type?(e.openBlock(),e.createElementBlock("span",v$,e.toDisplayString(i.value.number)+" "+e.toDisplayString(e.unref(n).$t({id:"invoice.line.units_included",defaultMessage:"units included",description:"Used to specify an included units. Should be lowercase."})),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],64))],64)):e.createCommentVNode("",!0)]}),_:1}),"PASS_THROUGH"===t.pricingType?(e.openBlock(),e.createBlock(e.unref(SP),{key:0,class:"align-top text-right"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.line.pass_through",defaultMessage:"Pass through",description:"Name of the pass through pricing type"})),1)]),_:1})):(e.openBlock(),e.createBlock(e.unref(SP),{key:1,number:"",class:"align-top"},{default:e.withCtx(()=>{var n,r,o,i,a,l,s,c,d,u,p,h;return[(null==(n=t.details)?void 0:n.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},["BELOW_MINIMUM_AMOUNT"===(null==(r=t.details)?void 0:r.price_bound)&&(null==(i=null==(o=t.details)?void 0:o.band)?void 0:i.minimum_amount)?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.details.band.minimum_amount},null,8,["value"])):"ABOVE_MAXIMUM_AMOUNT"===(null==(a=t.details)?void 0:a.price_bound)&&(null==(s=null==(l=t.details)?void 0:l.band)?void 0:s.maximum_amount)?(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:t.details.band.maximum_amount},null,8,["value"])):["NOT_HIT","RATIO","BELOW_MINIMUM_NUMBER","ABOVE_MAXIMUM_NUMBER"].includes(null==(c=t.details)?void 0:c.price_bound)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[(null==(d=t.details)?void 0:d.band)&&t.details.band.amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.details.band.amount},null,8,["value"])):e.createCommentVNode("",!0),(null==(u=t.details)?void 0:u.band)&&"percentage"in t.details.band?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(t.details.band.percentage)+"% ",1)],64)):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[(null==(p=t.details)?void 0:p.band)&&t.details.band.amount?(e.openBlock(),e.createBlock(e.unref(YB),{key:0,value:t.details.band.amount},null,8,["value"])):e.createCommentVNode("",!0),(null==(h=t.details)?void 0:h.band)&&"percentage"in t.details.band?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(t.details.band.percentage)+"% ",1)],64)):e.createCommentVNode("",!0)],64))]}),_:1})),e.createVNode(e.unref(SP),{number:"",class:"align-top"},{default:e.withCtx(()=>[t.hideTaxDetails?e.createCommentVNode("",!0):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(t.taxCategories,(t,n)=>(e.openBlock(),e.createElementBlock("div",{key:n,class:"tabular-nums"},[e.createElementVNode("div",null,e.toDisplayString(t.percentage)+"%",1),e.createElementVNode("div",y$,[e.createVNode(e.unref(YB),{value:t.tax_amount},null,8,["value"])])]))),128))]),_:1}),e.createVNode(e.unref(SP),{number:"",class:"align-top"},{default:e.withCtx(()=>{var o,i,a,l;return[(null==(i=null==(o=t.details)?void 0:o.amount)?void 0:i.currency)&&(null==(l=null==(a=t.details)?void 0:a.amount)?void 0:l.quantity)?(e.openBlock(),e.createElementBlock("div",b$,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.taxCategories,(r,o)=>{var i;return e.openBlock(),e.createElementBlock("div",{key:o,class:"inline-block"},[e.createElementVNode("div",w$,[e.createVNode(e.unref(YB),{value:t.details.amount},null,8,["value"]),(null==(i=t.details)?void 0:i.pricing_amount.quantity)!==t.details.amount.quantity?(e.openBlock(),e.createBlock(e.unref(bV),{key:0,placement:"top-end"},{tooltip:e.withCtx(()=>[e.createVNode(e.unref(_z),null,{default:e.withCtx(()=>[e.createVNode(e.unref(Cz),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.line.original_currency",defaultMessage:"Original currency",description:"Original currency"}))+" ",1),e.createVNode(e.unref(YB),{value:t.details.pricing_amount,class:"font-semibold"},null,8,["value"])]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(e.unref(hc),{icon:"info",size:"2xs"})]),_:1})):e.createCommentVNode("",!0)]),t.hideTaxDetails?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",k$,["INCLUDING_TAX"===t.amountType?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.line.excl.tax",defaultMessage:"Excl. tax",description:"Value excludes tax"}))+" ",1),e.createVNode(e.unref(YB),{value:r.base_amount},null,8,["value"])],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.line.incl.tax",defaultMessage:"Incl. tax",description:"Value includes tax"}))+" ",1),e.createVNode(e.unref(YB),{value:r.total_amount},null,8,["value"])],64))]))])}),128)),e.renderSlot(r.$slots,"one-off-line-context-menu")])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode("-")],64))]}),_:3})],64))}}),_$=["tabindex","onClick"],C$=e.defineComponent({__name:"InvoiceLineGroup",props:{group:{},startDate:{},endDate:{},total:{},amountType:{},invoicePeriodOrder:{},processingOnlyCustomers:{}},setup(t){const n=t,r=e.computed(()=>{var e;return null==(e=[...n.group.lines??[]])?void 0:e.sort((e,t)=>e.line_order-t.line_order)}),o=HB(),{getIsOpen:i,toggle:a}=vB(),l=(e,t)=>`${e}-line-${t}`;return(n,s)=>(e.openBlock(),e.createElementBlock("div",null,[e.createVNode(e.unref(EP),null,{default:e.withCtx(()=>[e.createElementVNode("tr",null,[e.createVNode(e.unref(BP),{left:"",class:"text-gray-400 w-1/5"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(o).$t({id:"invoice.table_header.unit",defaultMessage:"Unit",description:"Table header for the column containing the number of units of invoice groups"})),1)]),_:1}),e.createVNode(e.unref(BP),{right:"",class:"text-gray-400 w-1/5"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(o).$t({id:"invoice.table_header.quantity",defaultMessage:"Quantity",description:"Table header for quantity column"})),1)]),_:1}),e.createVNode(e.unref(BP),{right:"",class:"text-gray-400 w-1/5"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(o).$t({id:"invoice.table_header.price",defaultMessage:"Price",description:"Table header for the column containing the number of units of invoice groups"})),1)]),_:1}),e.createVNode(e.unref(BP),{right:"",class:"text-gray-400 w-1/5"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(o).$t({id:"invoice.table_header.tax_rate",defaultMessage:"Tax rate",description:"Table header for the column containing the tax percentage of invoice groups"})),1)]),_:1}),e.createVNode(e.unref(BP),{right:"",class:"text-gray-400 w-1/5"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(o).$t({id:"invoice.table_header.sub_total",defaultMessage:"Subtotal",description:"Table header for the column containing the subtotal for invoices"})),1)]),_:1})]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(o,s)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:s},[e.createElementVNode("tr",{tabindex:o.sub_lines?0:void 0,class:e.normalizeClass(["group",{"cursor-pointer":o.sub_lines,"border-t":0!==s}]),onClick:e=>{return n=t.group.group_order,r=o.line_order,void a(l(n,r));var n,r}},[(e.openBlock(),e.createBlock(f$,{key:s,data:o,"is-first-in-group":0===s,"period-order":t.invoicePeriodOrder,"group-order":t.group.group_order,"is-last":s===r.value.length-1,"group-type":t.group.type,"is-expanded":e.unref(i)(l(t.group.group_order,o.line_order))},{"invoice-line-prefix":e.withCtx(t=>[e.renderSlot(n.$slots,"invoice-line-prefix",e.mergeProps({ref_for:!0},t))]),"line-content":e.withCtx(r=>[e.createVNode(x$,{details:r.details,"pricing-type":o.pricing_type,"tax-categories":o.tax_categories,"amount-type":t.amountType},e.createSlots({_:2},["ONE_OFF"===o.type?{name:"one-off-line-context-menu",fn:e.withCtx(t=>[e.renderSlot(n.$slots,"one-off-line-context-menu",e.mergeProps({ref_for:!0},t,{lineOrder:o.line_order}))]),key:"0"}:void 0]),1032,["details","pricing-type","tax-categories","amount-type"])]),_:2},1032,["data","is-first-in-group","period-order","group-order","is-last","group-type","is-expanded"]))],10,_$),e.createVNode(AP,{ref_for:!0,ref:l(t.group.group_order,o.line_order),"sub-lines":o.sub_lines??[],"processing-only-customers":t.processingOnlyCustomers,"line-order":o.line_order,"is-open":e.unref(i)(l(t.group.group_order,o.line_order)),"period-order":t.invoicePeriodOrder,"group-order":t.group.group_order},{"invoice-line-prefix":e.withCtx(t=>[e.renderSlot(n.$slots,"invoice-line-prefix",e.mergeProps({ref_for:!0},t))]),"subline-content":e.withCtx(n=>[e.createVNode(x$,{details:n.details,"hide-tax-details":n.hideTaxDetails,"pricing-type":o.pricing_type,"tax-categories":o.tax_categories,"amount-type":t.amountType},null,8,["details","hide-tax-details","pricing-type","tax-categories","amount-type"])]),_:2},1032,["sub-lines","processing-only-customers","line-order","is-open","period-order","group-order"])],64))),128))]),_:3})]))}});function E$(t){return"function"==typeof t?t():e.unref(t)}"undefined"!=typeof WorkerGlobalScope&&(globalThis,WorkerGlobalScope);const S$={key:0,totals:"",class:"border-t"},B$=e.defineComponent({__name:"InvoiceSummaryTotalExcludingTax",props:{baseAmount:{}},setup(t){const n=HB();return(r,o)=>t.baseAmount?(e.openBlock(),e.createElementBlock("tr",S$,[e.createVNode(e.unref(SP),null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.table_header.total_excluding_taxes",defaultMessage:"Total excluding taxes",description:"Table row header for the total excluding taxes column in the invoice table"})),1)]),_:1}),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:t.baseAmount},null,8,["value"])]),_:1})])):e.createCommentVNode("",!0)}}),N$={key:0,class:"font-bold border-t"},M$=e.defineComponent({__name:"InvoiceSummaryTotalIncludingTax",props:{totalAmount:{},isCustomerFacing:{type:Boolean}},setup(t){const n=HB();return(r,o)=>t.totalAmount?(e.openBlock(),e.createElementBlock("tr",N$,[e.createVNode(e.unref(SP),{class:"font-bold"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.isCustomerFacing?e.unref(n).$t({id:"invoice.table_header.total_including_taxes_customer_facing",defaultMessage:"Total due today",description:"Table row header for the total including taxes column in the invoice table for a customer facing component"}):e.unref(n).$t({id:"invoice.table_header.total_including_taxes",defaultMessage:"Total including taxes",description:"Table row header for the total including taxes column in the invoice table"})),1)]),_:1}),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:t.totalAmount},null,8,["value"])]),_:1})])):e.createCommentVNode("",!0)}}),T$={class:"flex justify-between items-start"},V$={key:0,class:"max-h-9"},A$={class:"flex flex-col gap-2"},z$={key:0},O$=["tabindex"],I$={key:1,class:"inline-flex justify-center items-center w-3.5 h-3.5 rounded-full bg-blue-100 text-blue-600 text-2xs ml-1 font-bold"},D$={key:3},P$={colspan:"2",class:"p-0"},$$={class:"px-9 py-3 -mx-9 bg-gray-50 text-xs"},L$=["tabindex","onClick","onKeyup"],R$={key:1,class:"inline-flex justify-center items-center w-3.5 h-3.5 rounded-full bg-blue-100 text-blue-600 text-2xs ml-1 font-bold"},H$={key:0},F$={colspan:"2",class:"p-0"},j$={class:"px-9 py-3 -mx-9 bg-gray-50 text-xs"},U$={key:0,class:"font-bold border-t"},G$=e.defineComponent({__name:"InvoiceSummary",props:{invoice:{},isExpandable:{type:Boolean,default:!1},isInvoiceLineCreatable:{type:Boolean,default:!1},showRenderedServicesHeader:{type:Boolean,default:!0},isCustomerFacing:{type:Boolean}},setup(t){const n=HB(),r=t,[o,i]=yB(),[a,l]=yB(),[s,c]=function(t=!1,n={}){const{truthyValue:r=!0,falsyValue:o=!1}=n,i=e.isRef(t),a=e.ref(t);function l(e){if(arguments.length)return a.value=e,a.value;{const e=E$(r);return a.value=a.value===e?E$(o):e,a.value}}return i?l:[a,l]}(),d=(...e)=>{r.isExpandable&&i(...e)},u=e=>{r.isExpandable&&l(e)},p=()=>{r.invoice.tax_categories&&r.isExpandable&&c()},h=(e,t)=>+`${e}${t}`,m=e=>n.$t({id:"invoice.service_period_heading",defaultMessage:"Service period - {start_at} - {end_at}",description:"Heading for rendered services where {start_at} is replaced for the start date and {end_at} for the end date in invoice summary"},{start_at:n.formatDate({date:e.start_at,format:"date",timezone:Pt(r.invoice.customer.timezone),offsetType:"offsetted"}),end_at:n.formatDate({date:e.end_at,format:"date",timezone:Pt(r.invoice.customer.timezone),offsetType:"offsetted"})}),f=e=>{switch(e){case"PRICING":case"REVENUE":return n.$t({id:"invoice.table_heading.products",defaultMessage:"Products",description:"Table heading for the column containing the products of the invoice"});case"COMMITMENT":return n.$t({id:"invoice.table_heading.commitments",defaultMessage:"Commitments",description:"Table heading for the column containing the commitments of the invoice"});case"DISCOUNT":return n.$t({id:"invoice.table_heading.discounts",defaultMessage:"Discounts",description:"Table heading for the column containing the discounts of the invoice"});case"MARKUP":return n.$t({id:"invoice.table_heading.markups",defaultMessage:"Markups",description:"Table heading for the column containing the markups of the invoice"});case"ONE_OFF":return n.$t({id:"invoice.table_heading.one_offs",defaultMessage:"One-off's",description:"Table heading for the column containing the one-offs of the invoice"})}},g=e=>e.groups.reduce((e,t)=>t.type in e?{...e,[t.type]:[...e[t.type],t]}:{...e,[t.type]:[t]},{});return(r,i)=>(e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",T$,[r.$slots.logo?(e.openBlock(),e.createElementBlock("div",V$,[e.renderSlot(r.$slots,"logo")])):(e.openBlock(),e.createBlock(e.unref(LM),{key:1,title:e.unref(n).$t({id:"invoice.title",defaultMessage:"Details",description:"Title for the invoice summary"}),variant:"neutral",icon:"draft"},null,8,["title"])),r.$slots.intro?e.renderSlot(r.$slots,"intro",{key:2}):e.createCommentVNode("",!0),e.createElementVNode("div",A$,[["ONE_OFF","STANDARD","ONE_OFF_CREDIT"].includes(t.invoice.type)&&["DRAFT","OPEN"].includes(t.invoice.status)&&t.isInvoiceLineCreatable?(e.openBlock(),e.createBlock(e.unref(cz),{key:0,to:{name:"invoice-add-line",params:{id:t.invoice.id}},class:"text-sm font-semibold"},{default:e.withCtx(()=>[e.createVNode(e.unref(hc),{icon:"add",size:"md",class:"mr-1"}),e.createElementVNode("span",null,e.toDisplayString(e.unref(n).$t({id:"invoice.add_invoice_line",defaultMessage:"Add invoice line",description:"Label for adding lines to an invoice"})),1)]),_:1},8,["to"])):e.createCommentVNode("",!0),e.renderSlot(r.$slots,"child-customers-selector")])]),r.$slots.total?e.renderSlot(r.$slots,"total",{key:0}):e.createCommentVNode("",!0),e.renderSlot(r.$slots,"notes"),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.invoice.periods,(a,l)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:l},[t.showRenderedServicesHeader?(e.openBlock(),e.createBlock(e.unref(ZT),{key:0,class:"mt-6"},{default:e.withCtx(()=>[e.createVNode(e.unref(gc),{tag:"h2",variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(m(a)),1)]),_:2},1024)]),_:2},1024)):e.createCommentVNode("",!0),a.groups?(e.openBlock(),e.createBlock(e.unref(EP),{key:1,class:e.normalizeClass({"mt-3":t.showRenderedServicesHeader})},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Object.entries(g(a)),([l,s],c)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:l},[c>0?(e.openBlock(),e.createElementBlock("tr",z$,[...i[0]||(i[0]=[e.createElementVNode("td",null,[e.createElementVNode("div",{class:"h-4"})],-1)])])):e.createCommentVNode("",!0),e.createElementVNode("tr",null,[e.createVNode(e.unref(BP),{left:"",class:"text-gray-600"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(f(l)),1)]),_:2},1024),e.createVNode(e.unref(BP),{right:"",class:"text-gray-600"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.amount_table_heading",defaultMessage:"Amount",description:"Table heading for the amount column in the invoice table"})),1)]),_:1})]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s,(i,s)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:s},["REVENUE"===l||"PRICING"===l||"ONE_OFF"===l?(e.openBlock(),e.createBlock(e.unref(YP),{key:0,group:i,"expanded-items":e.unref(o),"handle-toggle-items":d,"is-expandable":t.isExpandable,"format-index":h,"invoice-period-order":a.period_order,"group-order":i.group_order,"amount-type":t.invoice.pricing_amount_type,"processing-only-customers":t.invoice.processing_only_customers},{"invoice-line-prefix":e.withCtx(t=>[e.renderSlot(r.$slots,"invoice-line-prefix",e.mergeProps({ref_for:!0},t))]),"one-off-line-context-menu":e.withCtx(t=>[e.renderSlot(r.$slots,"one-off-line-context-menu",e.mergeProps({ref_for:!0},t,{periodOrder:a.period_order}))]),_:2},1032,["group","expanded-items","is-expandable","invoice-period-order","group-order","amount-type","processing-only-customers"])):"DISCOUNT"===l||"MARKUP"===l?(e.openBlock(),e.createBlock(e.unref(GP),{key:1,group:i,"expanded-items":e.unref(o),"handle-toggle-items":d,"is-expandable":t.isExpandable,"format-index":h,"invoice-period-order":a.period_order,"group-order":i.group_order,"amount-type":t.invoice.pricing_amount_type,heading:"DISCOUNT"===l?e.unref(n).$t({id:"invoice.discounts_table_heading",defaultMessage:"Discounts",description:"Heading for discounts in the invoice table"}):e.unref(n).$t({id:"invoice.markups_table_heading",defaultMessage:"Markups",description:"Heading for markups in the invoice table"})},{"invoice-line-prefix":e.withCtx(t=>[e.renderSlot(r.$slots,"invoice-line-prefix",e.mergeProps({ref_for:!0},t))]),_:3},8,["group","expanded-items","is-expandable","invoice-period-order","group-order","amount-type","heading"])):"COMMITMENT"===l?(e.openBlock(),e.createBlock(e.unref(n$),{key:2,group:i,"expanded-items":e.unref(o),"handle-toggle-items":d,"is-expandable":t.isExpandable,"format-index":h,"invoice-period-order":a.period_order,"group-order":i.group_order,"amount-type":t.invoice.pricing_amount_type},{"invoice-line-prefix":e.withCtx(t=>[e.renderSlot(r.$slots,"invoice-line-prefix",e.mergeProps({ref_for:!0},t))]),_:3},8,["group","expanded-items","is-expandable","invoice-period-order","group-order","amount-type"])):e.createCommentVNode("",!0)],64))),128))],64))),128))]),_:2},1032,["class"])):e.createCommentVNode("",!0)],64))),128)),t.invoice.tax_summary?(e.openBlock(),e.createBlock(e.unref(EP),{key:1,class:"mt-6"},{default:e.withCtx(()=>[e.createElementVNode("tr",null,[e.createVNode(e.unref(BP),{left:"",class:"text-gray-600"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.totals_table_heading",defaultMessage:"Totals",description:"Table heading for the totals column in the invoice table"})),1)]),_:1}),e.createVNode(e.unref(BP),{right:"",class:"text-gray-600"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.amount_table_heading",defaultMessage:"Amount",description:"Table heading for the amount column in the invoice table"})),1)]),_:1})]),"INCLUDING_TAX"===t.invoice.pricing_amount_type?(e.openBlock(),e.createBlock(M$,{key:0,"total-amount":t.invoice.tax_summary.total_amount,"is-customer-facing":t.isCustomerFacing},null,8,["total-amount","is-customer-facing"])):(e.openBlock(),e.createBlock(B$,{key:1,"base-amount":t.invoice.tax_summary.base_amount},null,8,["base-amount"])),t.invoice.tax_summary.tax_amount?(e.openBlock(),e.createElementBlock("tr",{key:2,class:e.normalizeClass([{"cursor-pointer":t.invoice.tax_categories&&t.isExpandable},"border-t"]),tabindex:t.isExpandable?0:void 0,onClick:p,onKeyup:[e.withKeys(p,["enter"]),e.withKeys(p,["space"])]},[e.createVNode(e.unref(SP),null,{default:e.withCtx(()=>[t.isExpandable&&t.invoice.tax_categories&&t.invoice.tax_categories.length?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,icon:"keyboard_arrow_down",size:"md",class:e.normalizeClass(["-translate-x-7 absolute text-slate-400",{"-rotate-90":!e.unref(s)}])},null,8,["class"])):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(e.unref(n).$t({id:"invoice.taxes_table_heading",defaultMessage:"Taxes",description:"Table heading for the taxes column in the invoice table"}))+" ",1),t.isExpandable&&t.invoice.tax_categories?(e.openBlock(),e.createElementBlock("span",I$,e.toDisplayString(t.invoice.tax_categories.length),1)):e.createCommentVNode("",!0)]),_:1}),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:t.invoice.tax_summary.tax_amount},null,8,["value"])]),_:1})],42,O$)):e.createCommentVNode("",!0),e.unref(s)&&t.invoice.tax_categories?(e.openBlock(),e.createElementBlock("tr",D$,[e.createElementVNode("td",P$,[e.createElementVNode("div",$$,[e.createVNode(e.unref(PP),{"tax-categories":t.invoice.tax_categories},null,8,["tax-categories"])])])])):e.createCommentVNode("",!0),"INCLUDING_TAX"===t.invoice.pricing_amount_type?(e.openBlock(),e.createBlock(B$,{key:4,"base-amount":t.invoice.tax_summary.base_amount},null,8,["base-amount"])):(e.openBlock(),e.createBlock(M$,{key:5,"total-amount":t.invoice.tax_summary.total_amount},null,8,["total-amount"]))]),_:1})):e.createCommentVNode("",!0),e.unref(gS)(t.invoice.closed_periods)?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(e.unref(EP),{key:2,class:"mt-6"},{default:e.withCtx(()=>[e.createElementVNode("tr",null,[e.createVNode(e.unref(BP),{left:"",class:"text-gray-600"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.already_deducted_table_heading",defaultMessage:"Already deducted",description:"Table heading for the already deducted rows in the invoice table"})),1)]),_:1})]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.invoice.closed_periods,(n,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:r},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.groups,(n,o)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:o},[e.createElementVNode("tr",{class:e.normalizeClass(["border-t",{"pt-6":0===r,"cursor-pointer":t.isExpandable}]),tabindex:t.isExpandable?0:void 0,onClick:e=>u(h(r,o)),onKeyup:[e.withKeys(e=>u(h(r,o)),["enter"]),e.withKeys(e=>u(h(r,o)),["space"])]},[e.createVNode(e.unref(SP),{class:"p-0"},{default:e.withCtx(()=>{var i,l;return[t.isExpandable?(e.openBlock(),e.createBlock(e.unref(hc),{key:0,icon:"keyboard_arrow_down",size:"md",class:e.normalizeClass(["-translate-x-7 absolute text-slate-400",{"-rotate-90":!e.unref(a).includes(h(r,o))}])},null,8,["class"])):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(e.unref(Tx)((null==(i=n.products)?void 0:i.map(e=>e.name))??[]))+" ",1),t.isExpandable?(e.openBlock(),e.createElementBlock("span",R$,e.toDisplayString(null==(l=n.lines)?void 0:l.length),1)):e.createCommentVNode("",!0)]}),_:2},1024),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:n.amount_excluding_tax},null,8,["value"])]),_:2},1024)],42,L$),e.unref(a).includes(h(r,o))?(e.openBlock(),e.createElementBlock("tr",H$,[e.createElementVNode("td",F$,[e.createElementVNode("div",j$,[e.createVNode(e.unref(C$),{"start-date":n.start_at,"end-date":n.end_at,total:n.amount_excluding_tax,group:n,"amount-type":t.invoice.pricing_amount_type},null,8,["start-date","end-date","total","group","amount-type"])])])])):e.createCommentVNode("",!0)],64))),128))],64))),128)),t.invoice.open_invoice_amount&&!t.invoice.paid?(e.openBlock(),e.createElementBlock("tr",U$,[e.createVNode(e.unref(SP),{class:"font-bold"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({id:"invoice.amount_due_table_heading",defaultMessage:"Amount due",description:"Table heading for the amount due row in the invoice table"})),1)]),_:1}),e.createVNode(e.unref(SP),{number:""},{default:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:t.invoice.open_invoice_amount},null,8,["value"])]),_:1})])):e.createCommentVNode("",!0)]),_:1}))]))}}),q$=e.defineComponent({__name:"invoicePreviewRow",props:{weight:{default:"normal"},variant:{default:"body-xs"},noSpacing:{type:Boolean,default:!1}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["flex flex-row gap-2",{"py-1.5":!t.noSpacing}])},[e.createVNode(gc,{tag:"span",variant:t.variant,class:"grow",weight:t.weight},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"label")]),_:3},8,["variant","weight"]),e.createVNode(gc,{tag:"span",variant:t.variant,weight:t.weight},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"value")]),_:3},8,["variant","weight"])],2))}),Z$=e.defineComponent({__name:"InvoicePreviewNoTaxesSkeleton",props:{widthClass:{default:"w-12"},heightClass:{default:"h-5"}},setup(t){const{$t:n}=HB();return(r,o)=>(e.openBlock(),e.createBlock(bV,{"is-dark-mode":""},{tooltip:e.withCtx(()=>[e.createVNode(_z,null,{default:e.withCtx(()=>[e.createVNode(Cz,null,{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n)({defaultMessage:"Will be determined by billing information",description:"Tooltip content for the invoice preview when taxes are not determined by billing information",id:"invoice_preview.taxes_not_determined_by_billing_information_tooltip"})),1)]),_:1})]),_:1})]),default:e.withCtx(()=>[e.createVNode(nO,{"width-class":t.widthClass,"height-class":t.heightClass,shade:"darker"},null,8,["width-class","height-class"])]),_:1}))}}),W$=e.defineComponent({__name:"InvoicePreviewGroups",props:{invoice:{},wrapperComponent:{}},setup(t){const n=e=>e.groups.reduce((e,t)=>t.type in e?{...e,[t.type]:[...e[t.type],t]}:{...e,[t.type]:[t]},{}),r=e=>{var t,n,r;return(null==(t=e.pricing)?void 0:t.name)&&!gS(null==(n=e.pricing)?void 0:n.name)?e.pricing.name:Tx((null==(r=e.products)?void 0:r.map(e=>e.name))??[])};return(o,i)=>(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.invoice.periods,(o,i)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:i},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Object.entries(n(o)),([n,o])=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:n},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o,(n,o)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.wrapperComponent??"div"),{key:o},{default:e.withCtx(()=>[e.createVNode(q$,{"no-spacing":void 0!==t.wrapperComponent},{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r(n)),1)]),value:e.withCtx(()=>[e.createVNode(YB,{value:n.amount_excluding_tax},null,8,["value"])]),_:2},1032,["no-spacing"])]),_:2},1024))),128))],64))),128))],64))),128))}}),K$={class:"flex flex-col"},J$={key:0},Y$=e.defineComponent({__name:"InvoicePreview",props:{invoice:{},trialInvoice:{},isCustomerFacing:{type:Boolean,default:!1},variant:{default:"default"},isPaid:{type:Boolean,default:!1},collapsible:{default:void 0},isPreviewWithoutTaxes:{type:Boolean}},setup(t){const n=t,{$t:r}=HB(),o=e.ref(void 0!==n.collapsible&&"expanded"!==n.collapsible),i=e.computed(()=>void 0!==n.collapsible),a=e.computed(()=>!!n.trialInvoice),l=e.computed(()=>n.trialInvoice?n.trialInvoice.tax_summary.total_amount:n.invoice.tax_summary.total_amount),s=()=>{i.value&&(o.value=!o.value)};return(n,c)=>(e.openBlock(),e.createElementBlock("div",K$,[e.createVNode(e.unref(dV),null,{default:e.withCtx(()=>[o.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",J$,[a.value?(e.openBlock(),e.createBlock(e.unref(gc),{key:0,variant:"caps-heading"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({id:"invoice_preview.after_trial_heading",defaultMessage:"After trial",description:"After trial heading for the invoice preview"})),1)]),_:1})):e.createCommentVNode("",!0),"without-products"!==t.variant?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(W$,{invoice:t.invoice},null,8,["invoice"]),e.createVNode(e.unref(WT),{spacing:"xxs"})],64)):e.createCommentVNode("",!0),e.createVNode(q$,null,{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({id:"invoice_preview.total_excluding_taxes_heading",defaultMessage:"Total excluding taxes",description:"Total excluding taxes heading for the invoice preview"})),1)]),value:e.withCtx(()=>[e.createVNode(e.unref(YB),{value:t.invoice.tax_summary.base_amount},null,8,["value"])]),_:1}),e.createVNode(q$,null,{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({id:"invoice_preview.taxes_heading",defaultMessage:"Taxes",description:"Taxes heading for the invoice preview"})),1)]),value:e.withCtx(()=>[t.isPreviewWithoutTaxes?(e.openBlock(),e.createBlock(Z$,{key:0,"width-class":"w-10","height-class":"h-4"})):(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:t.invoice.tax_summary.tax_amount},null,8,["value"]))]),_:1}),a.value?(e.openBlock(),e.createBlock(q$,{key:2},{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(r)({id:"invoice_preview.total_including_taxes_heading",defaultMessage:"Total including taxes",description:"Total including taxes heading for the invoice preview"})),1)]),value:e.withCtx(()=>[t.isPreviewWithoutTaxes?(e.openBlock(),e.createBlock(Z$,{key:0,"width-class":"w-10","height-class":"h-4"})):(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:t.invoice.tax_summary.total_amount},null,8,["value"]))]),_:1})):e.createCommentVNode("",!0),e.createVNode(e.unref(WT),{spacing:"xxs"})]))]),_:1}),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(i.value?"button":"div"),{class:e.normalizeClass({"hover:cursor-pointer text-left":i.value}),onClick:s},{default:e.withCtx(()=>[e.createVNode(q$,{weight:"semibold",variant:"body-sm"},{label:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.isPaid?e.unref(r)({id:"invoice_preview.total_paid_heading",defaultMessage:"Total paid",description:"Total paid heading for the invoice preview"}):e.unref(r)({id:"invoice_preview.total_due_today_heading",defaultMessage:"Total due today",description:"Total due today heading for the invoice preview"}))+" ",1),i.value?(e.openBlock(),e.createBlock(hc,{key:0,size:"xs",icon:"keyboard_arrow_down",class:e.normalizeClass(["transition ease-in-out text-gray-400",{"rotate-0":o.value,"rotate-180":!o.value}])},null,8,["class"])):e.createCommentVNode("",!0)]),value:e.withCtx(()=>[t.isPreviewWithoutTaxes&&(!a.value||a.value&&"0.00"!==l.value.quantity)?(e.openBlock(),e.createBlock(Z$,{key:0})):(e.openBlock(),e.createBlock(e.unref(YB),{key:1,value:l.value},null,8,["value"]))]),_:1})]),_:1},8,["class"]))]))}}),X$="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cpath%20fill='%23f5f7f8'%20d='M0%200h40v40H0z'/%3e%3cmask%20id='a'%20width='28'%20height='28'%20x='6'%20y='6'%20maskUnits='userSpaceOnUse'%20style='mask-type:alpha'%3e%3cpath%20fill='%23d9d9d9'%20d='M6%206h28v28H6z'/%3e%3c/mask%3e%3cg%20mask='url(%23a)'%3e%3cpath%20fill='%23333'%20d='M11.842%2027.955a1.85%201.85%200%200%201-1.36-.557%201.85%201.85%200%200%201-.558-1.36V13.962q0-.805.557-1.36a1.85%201.85%200%200%201%201.36-.557H28.16q.803%200%201.36.556.557.557.557%201.36v12.075q0%20.805-.557%201.36a1.85%201.85%200%200%201-1.36.558zm-.327-8.383h16.97v-3.386h-16.97z'/%3e%3c/g%3e%3c/svg%3e",Q$={class:"shrink-0"},eL={class:"flex items-center justify-center overflow-clip rounded"},tL=["src","alt","width","height"],nL={class:"grow"},rL={key:0},oL={key:0,class:"pt-3"},iL=e.defineComponent({__name:"PaymentMethodBase",props:{imageSrc:{},imageAlt:{},variant:{default:"default"},isInactive:{type:Boolean},options:{},error:{}},setup(t){const n=t,r=e.computed(()=>n.imageSrc||X$);return(n,o)=>(e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",{class:e.normalizeClass(["flex gap-3",{"opacity-50":t.isInactive}])},[e.createElementVNode("div",Q$,[e.createElementVNode("div",eL,[r.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:r.value,alt:t.imageAlt,width:"condensed"===t.variant?20:36,height:"condensed"===t.variant?20:36,class:e.normalizeClass({"w-9 h-9":"default"===t.variant,"w-5 h-5":"condensed"===t.variant})},null,10,tL)):e.createCommentVNode("",!0)])]),e.createElementVNode("div",nL,[e.renderSlot(n.$slots,"default")]),t.options&&t.options.length>0?(e.openBlock(),e.createElementBlock("div",rL,[e.createVNode(pV,{width:"wide",square:"",items:t.options},null,8,["items"])])):e.createCommentVNode("",!0)],2),t.error?(e.openBlock(),e.createElementBlock("div",oL,[e.createVNode(CV,{message:t.error,variant:"error"},null,8,["message"])])):e.createCommentVNode("",!0)]))}}),aL=e.defineComponent({__name:"PaymentMethodDefaultChip",props:{isDefault:{type:Boolean}},setup(t){const n=HB();return(r,o)=>t.isDefault?(e.openBlock(),e.createBlock(mc,{key:0,class:"mt-1 self-start"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({defaultMessage:"Default",description:"The textual label for the default payment method chip",id:"payment_methods.default_chip.label"})),1)]),_:1})):e.createCommentVNode("",!0)}}),lL=e.defineComponent({__name:"PaymentMethodInactiveChip",props:{isInactive:{type:Boolean}},setup(t){const n=HB();return(r,o)=>t.isInactive?(e.openBlock(),e.createBlock(mc,{key:0,class:"mt-1 self-start"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(n).$t({defaultMessage:"Inactive",description:"The textual label for the inactive payment method chip",id:"payment_methods.inactive_chip.label"})),1)]),_:1})):e.createCommentVNode("",!0)}}),sL={KLARNA:{name:"Klarna",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20d='M1%207.65h38v24.7H1z'/%3e%3cmask%20id='b'%20width='36'%20height='20'%20x='2'%20y='10'%20maskUnits='userSpaceOnUse'%20style='mask-type:luminance'%3e%3cpath%20fill='%23fff'%20d='M2.9%2010.5h34.2v19H2.9z'/%3e%3c/mask%3e%3cg%20mask='url(%23b)'%3e%3cpath%20fill='%23ffb3c7'%20d='M33.816%2010.5H6.184A3.284%203.284%200%200%200%202.9%2013.784v12.432A3.284%203.284%200%200%200%206.184%2029.5h27.632a3.284%203.284%200%200%200%203.284-3.284V13.784a3.284%203.284%200%200%200-3.284-3.284'/%3e%3cpath%20fill='%230a0b09'%20d='M33.904%2021.631a.814.814%200%200%200-.81.818c0%20.451.362.817.81.817.447%200%20.81-.366.81-.817a.815.815%200%200%200-.81-.818M31.238%2021c0-.618-.524-1.12-1.17-1.12s-1.17.502-1.17%201.12.524%201.12%201.17%201.12%201.17-.502%201.17-1.12m.004-2.175h1.291v4.35h-1.29v-.278a2.25%202.25%200%200%201-2.154.221A2.29%202.29%200%200%201%2027.688%2021a2.285%202.285%200%200%201%202.275-2.295c.474%200%20.915.147%201.28.398zm-10.33.566v-.566h-1.321v4.35h1.324v-2.03c0-.686.736-1.055%201.247-1.055l.015.001v-1.266c-.524%200-1.006.227-1.265.567M17.62%2021c0-.619-.523-1.12-1.17-1.12-.645%200-1.169.501-1.169%201.12%200%20.617.524%201.118%201.17%201.118s1.17-.5%201.17-1.119m.005-2.176h1.29v4.35h-1.29v-.278a2.25%202.25%200%200%201-2.154.221%202.29%202.29%200%200%201-1.401-2.118%202.285%202.285%200%200%201%202.275-2.295c.475%200%20.915.147%201.28.398zm7.77-.117c-.516%200-1.005.161-1.33.607v-.49H22.78v4.35h1.301v-2.286c0-.661.44-.985.97-.985.566%200%20.892.342.892.976v2.295h1.29v-2.766c0-1.013-.797-1.701-1.837-1.701M12.19%2023.174h1.351v-6.289H12.19zm-5.935.002h1.43v-6.292h-1.43zm5.004-6.292c0%201.362-.526%202.63-1.464%203.571l1.978%202.721h-1.767l-2.15-2.957.555-.42a3.62%203.62%200%200%200%201.449-2.914z'/%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},ZIP:{name:"Zip",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%207h40v26H0z'/%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%231a0826'%20d='m2.81%2022.894.315%202.567h11.001l-.36-2.94h-5.13l-.044-.365%204.724-3.31-.315-2.572H2l.36%202.94h5.138l.045.367z'/%3e%3cpath%20fill='%23aa8fff'%20d='m14.28%2016.274%201.125%209.187h11.01l-1.125-9.187z'/%3e%3cpath%20fill='%231a0826'%20d='M37.96%2019.581c-.254-2.065-1.872-3.316-4.07-3.307h-7.324l1.125%209.186h3.294l-.226-1.837h3.487c2.745%200%204-1.715%203.714-4.042m-4.07%201.467-3.444.004-.27-2.205%203.464.003c.815.01%201.232.47%201.299%201.099.041.404-.144%201.098-1.048%201.098z'/%3e%3cpath%20fill='%23000'%20d='M17.914%2015.05c.58-.623.478-1.662-.226-2.32s-1.744-.684-2.323-.06c-.58.623-.479%201.662.225%202.32s1.745.684%202.324.06'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"}},cL={class:"flex h-full grow flex-col justify-center"},dL=e.defineComponent({__name:"PaymentMethodBuyNowPayLater",props:{paymentMethod:{},isDefault:{type:Boolean},options:{},variant:{default:"default"}},setup(t){const n=t,r=e.computed(()=>{var e;return(null==(e=n.paymentMethod.buy_now_pay_later)?void 0:e.variant)?sL[n.paymentMethod.buy_now_pay_later.variant]:void 0});return(n,o)=>{var i,a,l;return e.openBlock(),e.createBlock(iL,{"image-src":(null==(i=r.value)?void 0:i.logo)??e.unref(X$),"image-alt":null==(l=null==(a=r.value)?void 0:a.name)?void 0:l.toLowerCase(),variant:t.variant,options:t.options,"is-inactive":"INACTIVE"===t.paymentMethod.status},{default:e.withCtx(()=>[e.createElementVNode("div",cL,[e.createVNode(gc,{tag:"span",weight:"semibold","no-spacing":"",variant:"condensed"===t.variant?"body-xs":"body-sm",shade:"condensed"===t.variant?"light":void 0},{default:e.withCtx(()=>{var t;return[e.createTextVNode(e.toDisplayString(null==(t=r.value)?void 0:t.name),1)]}),_:1},8,["variant","shade"]),e.createVNode(aL,{"is-default":t.isDefault},null,8,["is-default"]),e.createVNode(lL,{"is-inactive":"INACTIVE"===t.paymentMethod.status},null,8,["is-inactive"])])]),_:1},8,["image-src","image-alt","variant","options","is-inactive"])}}}),uL={ACCEL:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23f26b21'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20fill-rule='evenodd'%20d='M9.035%2016.597c.715%200%201.215.285%201.572.642.322.357.536.929.464%201.5l-1%206.536c-.035.25-.143.5-.286.75s-.357.465-.571.643a3%203%200%200%201-.821.464%202.9%202.9%200%200%201-.858.143H6.071a2.14%202.14%200%200%201-1.57-.643c-.358-.393-.537-.857-.466-1.5l.286-2.214c.072-.572.144-1%20.537-1.465.357-.357.856-.606%201.535-.606h2.821l.357-2.215a.56.56%200%200%200-.178-.535c-.107-.108-.215-.179-.5-.179H7.464c-.286%200-.429.107-.571.214-.179.143-.25.321-.322.5%200%200-.143.571-.536.571h-.571c-.393%200-.464-.32-.429-.464.036-.285.144-.571.286-.821.143-.25.358-.536.608-.715q.321-.266.75-.428c.285-.107.678-.178.964-.178zM6.43%2022.132c-.25%200-.358.071-.465.178-.107.143-.143.322-.179.608L5.5%2025.203c-.036.322.143.715.643.715H7.57c.286%200%20.5-.108.643-.215.286-.25.321-.5.321-.5L9%2022.132z'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23fff'%20d='M16.035%2016.632c.607%200%201.144.18%201.573.643.356.358.535.858.463%201.5%200%20.357-.285.428-.463.428h-.573c-.535%200-.427-.571-.427-.571a.68.68%200%200%200-.144-.535c-.107-.108-.25-.179-.5-.179h-1.429a.9.9%200%200%200-.606.214c-.214.178-.321.357-.322.5l-1%206.607a.49.49%200%200%200%20.143.5.73.73%200%200%200%20.5.214h1.429a.95.95%200%200%200%20.606-.214c.143-.143.287-.286.322-.5.002-.009.11-.57.536-.571h.571c.393%200%20.465.285.465.464-.036.357-.179.643-.321.893s-.358.464-.573.643c-.214.178-.5.322-.785.429a2.5%202.5%200%200%201-.929.178h-1.428c-.679%200-1.215-.214-1.572-.607a1.8%201.8%200%200%201-.5-1.5l.964-6.393c.036-.285.18-.608.286-.822.143-.25.358-.5.572-.678a3.5%203.5%200%200%201%20.786-.464c.25-.108.607-.18.928-.18h1.428Z'/%3e%3cpath%20fill='%23fff'%20fill-rule='evenodd'%20d='M30.25%2016.597c.714%200%201.214.285%201.571.642.322.393.535.857.464%201.464l-.214%201.786c-.071.572-.143%201-.536%201.464-.357.357-.856.608-1.535.608h-2.857l-.393%202.642a.56.56%200%200%200%20.179.536c.107.107.214.179.5.179h1.429c.285%200%20.428-.072.57-.179.18-.143.25-.321.322-.5.002-.006.145-.57.535-.571h.573c.392%200%20.463.32.427.464a2.3%202.3%200%200%201-.285.821c-.143.25-.357.536-.607.715a2.6%202.6%200%200%201-.75.429%203%203%200%200%201-.964.178h-1.394a2.14%202.14%200%200%201-1.571-.643%201.95%201.95%200%200%201-.464-1.5l.393-2.607h-.25c-.286%200-.465.143-.572.214-.385.246-.392.698-.392.714%200%20.25-.072.358-.5.358h-.5c-.464%200-.5-.357-.465-.464.036-.25.108-.5.286-.822.179-.25.393-.5.608-.678.25-.215.57-.358.785-.429.285-.072.572-.143.786-.143h.429l.392-2.678c.036-.25.142-.5.285-.75s.358-.465.573-.644c.214-.178.535-.357.82-.464a2.8%202.8%200%200%201%20.857-.142zm-.107%201.356h-1.429c-.286%200-.5.108-.643.215-.285.25-.32.5-.32.5l-.393%202.643h2.535c.25%200%20.357-.072.465-.18.106-.142.142-.32.177-.606l.215-1.893c.071-.322-.143-.715-.607-.679'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23fff'%20d='M35.535%2012.06c.215%200%20.5.108.465.465l-2.142%2014.286c-.072.392-.357.464-.5.464h-.573c-.392%200-.464-.286-.464-.464l2.143-14.286c.036-.178.143-.464.5-.465zm-12.356%204.537c.607%200%201.143.178%201.571.642.357.393.535.893.464%201.5-.072.393-.357.465-.5.429h-.571c-.529%200-.432-.557-.429-.571.036-.25-.035-.43-.143-.537s-.25-.178-.5-.178h-1.428c-.25%200-.43.108-.608.215a.9.9%200%200%200-.321.5l-1%206.606a.49.49%200%200%200%20.144.5c.142.179.357.215.5.215h1.427a.95.95%200%200%200%20.608-.215.87.87%200%200%200%20.321-.5c.003-.016.114-.571.536-.571h.571c.429%200%20.5.322.464.465-.035.357-.178.642-.321.892s-.357.464-.571.643a2.8%202.8%200%200%201-.785.428%202.7%202.7%200%200%201-.93.18H20.25c-.678%200-1.214-.215-1.571-.608a1.8%201.8%200%200%201-.5-1.5l1-6.393c.036-.285.142-.607.285-.821.143-.25.357-.5.571-.679.215-.178.5-.357.786-.464.25-.107.608-.178.93-.178z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",AMERICAN_EXPRESS:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23006fcf'%20d='m32.864%209.816%201.28-3.48H40V0H0v40h40v-6.32h-5.52l-2.04-2.384-2.12%202.384H14.64V20.976H9.464l6.472-14.64h6.296l1.52%203.32v-3.32h7.816l1.304%203.48zm-4.408%202.304-.016-1.4.536%201.4%202.6%206.944h2.584l2.616-6.944.504-1.384v8.336H40V8.408h-4.52l-2.056%205.416-.544%201.464-.56-1.464-2.064-5.416h-4.52v10.664h2.72zM22.6%2019.064h3.136L21.04%208.4H17.4l-4.72%2010.664h3.096l.824-2.056h5.176zm-3.944-7.048.536-1.336.536%201.336%201.104%202.696h-3.28zm-1.832%208.968v10.624h8.904v-2.304h-6.184v-1.856h6.064v-2.296h-6.064v-1.864h6.184v-2.304zM35.64%2031.616h3.536l-4.984-5.336%204.984-5.296h-3.48L32.48%2024.44l-3.2-3.456h-3.544l4.976%205.336-4.976%205.296h3.44l3.24-3.464zm1.344-5.352L40%2029.328v-6.096l-3.016%203.024z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",BANCONTACT:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%231e3764'%20d='M3.604%2030.284v-4.816h1.463c1.063%200%201.747.406%201.747%201.245%200%20.475-.217.805-.521.998.44.206.697.606.697%201.149%200%20.97-.697%201.424-1.78%201.424zm.942-2.814h.697c.427%200%20.61-.213.61-.605%200-.42-.332-.558-.78-.558h-.527zm0%201.975h.582c.569%200%20.9-.145.9-.599%200-.447-.284-.633-.819-.633h-.663zm4.27.922c-.928%200-1.395-.461-1.395-1.08%200-.682.548-1.08%201.36-1.087q.305.005.603.055v-.166c0-.42-.237-.619-.69-.619a2.3%202.3%200%200%200-.894.165l-.17-.743c.292-.124.759-.206%201.172-.206.995%200%201.49.537%201.49%201.465v1.913c-.278.145-.8.303-1.477.303Zm.568-.778v-.736a2.2%202.2%200%200%200-.48-.055c-.312%200-.556.124-.556.447%200%20.29.203.44.562.44.163.006.326-.027.474-.096m1.566.695V26.99a4.1%204.1%200%200%201%201.53-.303c.988%200%201.557.495%201.557%201.41v2.188h-.934v-2.119c0-.475-.217-.695-.63-.695a1.4%201.4%200%200%200-.596.124v2.69h-.928Zm6.353-3.392-.176.75a2%202%200%200%200-.765-.172c-.549%200-.847.392-.847%201.04%200%20.708.312%201.072.894%201.072.26-.007.516-.068.752-.178l.149.763a2.25%202.25%200%200%201-.976.2c-1.123%200-1.774-.709-1.774-1.83%200-1.115.644-1.851%201.72-1.851.351-.002.7.068%201.023.206m2.018%203.475c-1.042%200-1.692-.736-1.692-1.844%200-1.101.65-1.837%201.692-1.837%201.05%200%201.687.736%201.687%201.837%200%201.108-.637%201.844-1.686%201.844Zm0-.785c.481%200%20.732-.405.732-1.06%200-.646-.25-1.052-.732-1.052-.474%200-.738.406-.738%201.053%200%20.654.265%201.06.739%201.06Zm2.227.702V26.99a4.1%204.1%200%200%201%201.53-.303c.99%200%201.558.495%201.558%201.41v2.188h-.934v-2.119c0-.475-.217-.695-.63-.695a1.4%201.4%200%200%200-.596.124v2.69zm5.196.083c-.806%200-1.22-.447-1.22-1.356v-1.486h-.46v-.757h.46v-.763l.935-.049v.812h.752v.757h-.752v1.473c0%20.399.163.584.467.584q.182%200%20.36-.04l.047.763a2.5%202.5%200%200%201-.59.062Zm2.358%200c-.928%200-1.395-.461-1.395-1.08%200-.682.549-1.08%201.361-1.087q.304.005.603.055v-.166c0-.42-.237-.619-.69-.619a2.3%202.3%200%200%200-.895.165l-.169-.743c.291-.124.758-.206%201.172-.206.995%200%201.49.537%201.49%201.465v1.913c-.278.145-.8.303-1.477.303m.569-.778v-.736a2.2%202.2%200%200%200-.48-.055c-.312%200-.556.124-.556.447%200%20.29.203.44.562.44.163.006.325-.027.474-.096m4.104-2.697-.176.75a2%202%200%200%200-.765-.172c-.548%200-.846.392-.846%201.04%200%20.708.311%201.072.894%201.072.26-.007.515-.068.751-.178l.15.763a2.25%202.25%200%200%201-.976.2c-1.124%200-1.774-.709-1.774-1.83%200-1.115.643-1.851%201.72-1.851.35-.002.699.068%201.022.206m2.055%203.475c-.806%200-1.219-.447-1.219-1.356v-1.486h-.46v-.757h.46v-.763l.934-.049v.812h.752v.757h-.752v1.473c0%20.399.163.584.468.584q.18%200%20.359-.04l.047.763a2.5%202.5%200%200%201-.59.062Z'/%3e%3cpath%20fill='url(%23a)'%20d='M10.123%2023.06c4.944%200%207.416-3.35%209.889-6.699H3.604v6.699z'/%3e%3cpath%20fill='url(%23b)'%20d='M29.901%209.662c-4.945%200-7.417%203.35-9.89%206.7H36.42v-6.7h-6.518Z'/%3e%3cdefs%3e%3clinearGradient%20id='a'%20x1='6.923'%20x2='18.972'%20y1='20.02'%20y2='15.616'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23005ab9'/%3e%3cstop%20offset='1'%20stop-color='%231e3764'/%3e%3c/linearGradient%3e%3clinearGradient%20id='b'%20x1='21.005'%20x2='33.791'%20y1='16.942'%20y2='12.649'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23fba900'/%3e%3cstop%20offset='1'%20stop-color='%23ffd800'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e",CARNET:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23ee3338'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fffcfc'%20d='M15.27%2013.453c-1.235.362-2.379.854-3.404%201.599-.807.586-1.478%201.296-1.865%202.306-.297-.782-.206-1.488.082-2.176.355-.843.964-1.476%201.68-2.006%201.467-1.08%203.136-1.666%204.895-2.001%203.272-.622%206.501-.47%209.658.666%201.172.423%202.262%201.008%203.169%201.893.842.82%201.387%201.78%201.261%203.02-.018.174-.064.346-.104.55-.06-.053-.098-.07-.11-.1-.43-1.043-1.208-1.773-2.12-2.37-1.505-.988-3.181-1.518-4.932-1.807-2.752-.454-5.484-.35-8.21.426'/%3e%3cpath%20fill='%23fffdfd'%20d='M11.865%2017.027c1.52-1.071%203.204-1.648%204.978-1.964%203.09-.549%206.145-.427%209.14.583%201.366.461%202.639%201.106%203.659%202.174.756.791%201.22%201.71%201.104%202.852-.018.176-.063.35-.096.526-.053-.016-.089-.017-.096-.032-.818-1.817-2.382-2.721-4.101-3.396-2.314-.907-4.727-1.187-7.195-1.052-2.086.115-4.102.517-5.999%201.435q-.555.273-1.075.61c-.948.618-1.739%201.386-2.183%202.522-.297-.783-.207-1.496.093-2.195.37-.867%201.008-1.504%201.771-2.063'/%3e%3cpath%20fill='%23fffbfb'%20d='m19.744%2026.845.597.849c-.385%200-.695.015-1-.01-.094-.007-.194-.108-.264-.194q-.396-.492-.768-1.009c-.29-.407-.657-.535-1.125-.439v1.62h-.929v-4.05c.965.04%201.924.047%202.878.129.484.04.805.494.829.991.024.508-.215.87-.707%201.063-.11.043-.226.079-.198-.009zm-1.725-1.49c.19-.01.382-.007.57-.035.23-.035.403-.16.413-.459.008-.278-.138-.452-.357-.465-.485-.028-.971-.008-1.45-.008v.968h.824Z'/%3e%3cpath%20fill='%23fffafb'%20d='M24.427%2024.913V23.64h.951v3.964c-.686.195-.99.105-1.422-.438l-1.672-2.106v2.578h-.99v-4.02c.308%200%20.611-.018.908.011.1.01.207.128.281.219.624.78%201.242%201.567%201.944%202.335z'/%3e%3cpath%20fill='%23fffdfd'%20d='M28.994%2024.296h-1.157v.9h2.679v.706h-2.688v1.107h2.997v.69h-4.084v-4.086h3.994v.683z'/%3e%3cpath%20fill='%23fffbfc'%20d='M15.302%2027.654c-.103.01-.174%200-.24.013-.638.113-1.065-.077-1.26-.684-.033-.102-.252-.21-.39-.217a22%2022%200%200%200-1.643-.002c-.123.003-.332.081-.35.157-.203.82-.832.833-1.564.71.055-.119.106-.245.171-.364.597-1.106%201.207-2.206%201.788-3.32.128-.246.29-.285.558-.32.623-.077.942.14%201.199.67.498%201.023%201.094%202.005%201.644%203.006a.8.8%200%200%201%20.087.351m-2.492-2.6-.241-.436-.724%201.43h1.473c-.174-.338-.329-.64-.508-.995Z'/%3e%3cpath%20fill='snow'%20d='M6.804%2027.001c.72-.023%201.212-.264%201.428-.834l1.215.227c-.184.52-.568.87-1.146%201.062-1.002.333-2.017.328-2.995-.055-.995-.39-1.427-1.12-1.277-2.07.13-.827.92-1.47%202.036-1.645.753-.117%201.502-.107%202.224.128.538.175.942.456%201.137.952-.343.058-.663.13-.99.156a.5.5%200%200%201-.348-.151c-.426-.475-1.022-.517-1.655-.42-.585.09-.982.379-1.042.865-.042.338-.047.696.048%201.022.158.532.704.71%201.367.763'/%3e%3cpath%20fill='%23fffcfc'%20d='M33.43%2027.087v-2.795h-1.514v-.68H36v.66h-1.501v3.426H33.43v-.61Z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",CARTES_BANCAIRES:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='url(%23b)'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20d='M32.825%2016.982c0-.35-.063-.698-.2-1.037a2.5%202.5%200%200%200-.572-.856%202.24%202.24%200%200%200-.92-.57q-.491-.16-1.363-.16h-7.697v5.266h7.697q.855%200%201.364-.159c.338-.106.634-.296.92-.57.253-.255.443-.53.57-.857.138-.36.201-.709.201-1.058Zm0%206.428c0-.35-.063-.698-.2-1.036a2.5%202.5%200%200%200-.572-.857%202.24%202.24%200%200%200-.92-.57q-.491-.16-1.363-.16h-7.697v5.245h7.697q.855%200%201.364-.159c.338-.105.634-.296.92-.57.253-.254.443-.53.57-.857.138-.338.201-.687.201-1.036m-11.831-3.806C20.74%2016.189%2018.308%2014%2014.513%2014%2010.516%2014%208%2016.442%208%2020.185c0%203.87%202.611%206.196%206.513%206.196%203.817%200%206.238-2.2%206.481-5.604h-6.566v-1.163h6.566zm14.178%2010.425a.6.6%200%200%201-.444.19.58.58%200%200%201-.444-.19.6.6%200%200%201-.18-.445c0-.169.064-.317.18-.444a.6.6%200%200%201%20.444-.18c.18%200%20.328.064.444.18.127.127.18.275.18.444a.53.53%200%200%201-.18.445m-.824-.825a.52.52%200%200%200-.159.38.56.56%200%200%200%20.159.392.52.52%200%200%200%20.38.158.52.52%200%200%200%20.38-.158.53.53%200%200%200%20.16-.392.52.52%200%200%200-.16-.38.52.52%200%200%200-.38-.159.52.52%200%200%200-.38.159m.37.031c.084%200%20.148.011.19.022.074.031.106.084.106.18%200%20.063-.021.105-.064.137-.02.01-.053.032-.095.032.053.01.095.031.117.063a.2.2%200%200%201%20.042.106v.105c0%20.022%200%20.032.01.032v.01h-.116v-.083q0-.126-.063-.158a.4.4%200%200%200-.138-.022h-.095v.275h-.127v-.687h.233v-.01Zm.137.117c-.032-.021-.084-.021-.148-.021h-.106v.253h.106c.053%200%20.095%200%20.116-.01.053-.021.075-.053.075-.106%200-.074-.022-.106-.043-.116'/%3e%3c/g%3e%3cdefs%3e%3clinearGradient%20id='b'%20x1='0'%20x2='40'%20y1='13'%20y2='30'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%232b307a'/%3e%3cstop%20offset='.22'%20stop-color='%232e3b83'/%3e%3cstop%20offset='.42'%20stop-color='%234187c3'/%3e%3cstop%20offset='.5'%20stop-color='%23d7d3df'/%3e%3cstop%20offset='.58'%20stop-color='%23cc7b7b'/%3e%3cstop%20offset='.78'%20stop-color='%23cd2426'/%3e%3cstop%20offset='1'%20stop-color='%23cd191b'/%3e%3c/linearGradient%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",DANKORT:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23ed1c24'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23ed1c24'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23ed1c24'%20d='M12.302%208.788c-6.04%200-10.952%204.982-10.952%2011.105C1.35%2026.018%206.263%2031%2012.302%2031H27.05C33.088%2031%2038%2026.018%2038%2019.893c0-6.123-4.913-11.105-10.95-11.105z'/%3e%3cpath%20fill='%23fff'%20d='m30.226%2018.82%204.179%205.517a9.2%209.2%200%200%200%201.374-4.884%209.2%209.2%200%200%200-1.522-5.112zm-14.382-4.858c3.557%200%206.238.86%206.514%203.71l3.744-3.71h7.455c-1.622-1.806-4.032-2.953-6.718-2.953H12.512c-2.687%200-5.098%201.147-6.72%202.952zM9.33%2017.673l-1.316%203.332h5.304c1.568%200%202.042-.599%202.393-1.75.347-1.14-.525-1.582-1.596-1.582zm17.524%207.547-4.062-5.326c-.75%203.632-3.209%205.327-7.817%205.327H5.792c1.661%202.166%204.224%203.558%207.093%203.558h14.692c2.869%200%205.43-1.39%207.09-3.558z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",DINERS:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20d='M2.65%2019.829c0-8.299%206.728-15.023%2015.023-15.023S32.695%2011.53%2032.695%2019.83c0%208.298-6.724%2015.022-15.022%2015.022S2.651%2028.124%202.651%2019.829Z'/%3e%3cpath%20fill='%230d4e96'%20d='M17.695%2035.117C9.085%2035.16%202%2028.184%202%2019.695%202%2010.415%209.086%204%2017.695%204h4.035C30.235%204%2038%2010.413%2038%2019.695c0%208.486-7.765%2015.422-16.27%2015.422zm.035-29.831c-7.867%200-14.24%206.378-14.24%2014.244%200%207.867%206.374%2014.241%2014.241%2014.241s14.241-6.374%2014.245-14.24c0-7.867-6.378-14.242-14.245-14.245Zm-3.235%2022.67V11.105a9.05%209.05%200%200%200-5.793%208.425%209.04%209.04%200%200%200%205.793%208.422M26.76%2019.53a9.03%209.03%200%200%200-5.8-8.425v16.854a9.04%209.04%200%200%200%205.8-8.426'/%3e%3c/svg%3e",DISCOVER:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20d='M.44%201.317v37.366a.88.88%200%200%200%20.877.878H18.47c10.802%200%2019.563-8.756%2019.563-19.563C38.033%209.195%2029.276.435%2018.47.435H1.317a.88.88%200%200%200-.878.878z'/%3e%3cpath%20fill='%23231f20'%20d='M3.408%2017.223H1.853v5.436h1.55c.821%200%201.419-.193%201.941-.628a2.73%202.73%200%200%200%20.988-2.086c0-1.603-1.199-2.723-2.92-2.723zm1.238%204.083c-.334.299-.764.43-1.45.43h-.285V18.14h.286c.685%200%201.102.123%201.449.44.369.324.588.834.588%201.352s-.22%201.045-.588%201.37zm3.227-4.083H6.815v5.436h1.058zm2.596%202.09c-.637-.237-.821-.391-.821-.685%200-.343.333-.602.79-.602.316%200%20.58.132.856.44l.554-.725a2.38%202.38%200%200%200-1.599-.602c-.962%200-1.695.668-1.695%201.559%200%20.75.343%201.133%201.34%201.489.412.144.627.245.733.307a.65.65%200%200%201%20.316.562c0%20.44-.351.769-.826.769-.505%200-.913-.255-1.159-.725l-.685.659c.488.715%201.076%201.036%201.884%201.036%201.102%200%201.875-.733%201.875-1.783%200-.865-.356-1.256-1.563-1.695zm1.897.632c0%201.599%201.256%202.837%202.867%202.837.457%200%20.848-.088%201.33-.316v-1.247c-.425.425-.798.597-1.281.597-1.068%200-1.827-.773-1.827-1.875%200-1.045.781-1.867%201.778-1.867.505%200%20.887.18%201.33.61v-1.246c-.465-.237-.847-.334-1.303-.334-1.608%200-2.894%201.265-2.894%202.846zm12.607.931-1.45-3.654h-1.158L24.67%2022.8h.57l2.35-5.576h-1.15zm3.096%201.783h3.008v-.918h-1.95v-1.466h1.875v-.923h-1.875v-1.207h1.95v-.922h-3.008zm7.206-3.829c0-1.019-.703-1.603-1.923-1.603H31.78v5.436h1.058v-2.182h.14l1.467%202.182h1.304l-1.712-2.292c.799-.162%201.238-.707%201.238-1.541m-2.125.896h-.312v-1.647h.325c.659%200%201.019.276%201.019.808%200%20.531-.36.838-1.037.838zm2.968-2.218c0-.097-.066-.15-.18-.15h-.154v.48h.114v-.185l.137.184h.14l-.158-.197c.066-.018.105-.066.105-.132zm-.202.066h-.017v-.128h.021q.087.001.088.062c.001.061-.03.066-.088.066z'/%3e%3cpath%20fill='%23231f20'%20d='M35.96%2017.183a.417.417%200%201%200%200%20.834.416.416%200%200%200%20.413-.417.416.416%200%200%200-.413-.417m0%20.76a.34.34%200%200%201-.334-.343c0-.189.15-.342.334-.342s.33.158.33.342a.34.34%200%200%201-.33.343'/%3e%3cpath%20fill='url(%23b)'%20d='M22.668%2019.936a2.88%202.88%200%200%201-2.881%202.881%202.877%202.877%200%200%201-2.88-2.88%202.877%202.877%200%200%201%202.88-2.881%202.877%202.877%200%200%201%202.88%202.88Z'/%3e%3cpath%20fill='url(%23c)'%20d='M22.668%2019.936a2.88%202.88%200%200%201-2.881%202.881%202.877%202.877%200%200%201-2.88-2.88%202.877%202.877%200%200%201%202.88-2.881%202.877%202.877%200%200%201%202.88%202.88Z'%20opacity='.65'%20style='mix-blend-mode:multiply'/%3e%3cg%20opacity='.5'%20style='mix-blend-mode:multiply'%3e%3cmask%20id='d'%20width='7'%20height='6'%20x='16'%20y='17'%20maskUnits='userSpaceOnUse'%20style='mask-type:luminance'%3e%3cpath%20fill='%23fff'%20d='M22.668%2019.936a2.88%202.88%200%200%201-2.881%202.881%202.88%202.88%200%200%201-2.88-2.88%202.877%202.877%200%200%201%202.88-2.881%202.877%202.877%200%200%201%202.88%202.88Z'/%3e%3c/mask%3e%3cg%20mask='url(%23d)'%3e%3cpath%20fill='%23020000'%20d='M19.8%2017.016a2.937%202.937%200%200%201%202.938%202.934%202.938%202.938%200%201%201-2.938-2.938z'/%3e%3cpath%20fill='%23030100'%20d='M19.805%2017.02a2.933%202.933%200%200%201%202.937%202.93%202.937%202.937%200%201%201-5.875.009%202.94%202.94%200%200%201%202.938-2.939'/%3e%3cpath%20fill='%23050100'%20d='M19.805%2017.025a2.937%202.937%200%200%201%202.942%202.929%202.945%202.945%200%200%201-2.942%202.942%202.927%202.927%200%200%201-2.934-2.933%202.933%202.933%200%200%201%202.934-2.934z'/%3e%3cpath%20fill='%23070200'%20d='M19.809%2017.03a2.933%202.933%200%200%201%202.942%202.924%202.95%202.95%200%200%201-2.942%202.942%202.93%202.93%200%200%201-2.934-2.933%202.933%202.933%200%200%201%202.934-2.934Z'/%3e%3cpath%20fill='%23080200'%20d='M19.813%2017.034c1.62%200%202.942%201.3%202.942%202.92a2.95%202.95%200%200%201-2.942%202.946%202.93%202.93%200%200%201-2.933-2.933%202.933%202.933%200%200%201%202.933-2.933'/%3e%3cpath%20fill='%230a0300'%20d='M19.813%2017.038c1.62%200%202.942%201.3%202.942%202.92a2.95%202.95%200%200%201-2.942%202.947%202.93%202.93%200%200%201-2.933-2.934%202.933%202.933%200%200%201%202.933-2.933'/%3e%3cpath%20fill='%230c0300'%20d='M19.818%2017.043c1.62%200%202.946%201.295%202.946%202.915a2.96%202.96%200%200%201-2.946%202.951%202.93%202.93%200%200%201-2.934-2.933%202.933%202.933%200%200%201%202.934-2.933'/%3e%3cpath%20fill='%230e0400'%20d='M19.822%2017.047c1.62%200%202.947%201.295%202.947%202.911a2.96%202.96%200%200%201-2.947%202.951%202.93%202.93%200%200%201-2.933-2.933%202.933%202.933%200%200%201%202.933-2.933z'/%3e%3cpath%20fill='%230f0400'%20d='M19.826%2017.056c1.62.004%202.947%201.29%202.947%202.911s-1.33%202.955-2.947%202.955a2.933%202.933%200%201%201%200-5.866'/%3e%3cpath%20fill='%23110500'%20d='M19.826%2017.06c1.62.004%202.947%201.287%202.947%202.907s-1.33%202.955-2.947%202.955a2.933%202.933%200%201%201%200-5.866z'/%3e%3cpath%20fill='%23130500'%20d='M19.83%2017.064c1.621.005%202.952%201.287%202.952%202.903s-1.33%202.96-2.951%202.96a2.923%202.923%200%200%201-2.93-2.93c.005-1.62%201.318-2.937%202.93-2.928z'/%3e%3cpath%20fill='%23140600'%20d='M19.835%2017.069c1.616.004%202.951%201.282%202.951%202.902s-1.335%202.96-2.95%202.96c-1.617%200-2.938-1.313-2.93-2.929.005-1.62%201.318-2.938%202.93-2.929v-.004Z'/%3e%3cpath%20fill='%23160600'%20d='M19.835%2017.073c1.616.005%202.951%201.278%202.951%202.898s-1.335%202.96-2.95%202.96c-1.617%200-2.938-1.313-2.93-2.929.005-1.62%201.322-2.938%202.93-2.929Z'/%3e%3cpath%20fill='%23180600'%20d='M19.84%2017.078c1.616.008%202.955%201.277%202.955%202.893s-1.335%202.965-2.955%202.965a2.925%202.925%200%200%201-2.93-2.93c.005-1.62%201.323-2.937%202.93-2.928'/%3e%3cpath%20fill='%23190700'%20d='M19.844%2017.082c1.616.009%202.955%201.273%202.955%202.894%200%201.62-1.339%202.964-2.955%202.964a2.93%202.93%200%200%201-2.929-2.929c.009-1.62%201.322-2.938%202.93-2.929Z'/%3e%3cpath%20fill='%231b0700'%20d='M19.849%2017.086c1.616.01%202.955%201.274%202.955%202.89s-1.34%202.968-2.955%202.968a2.93%202.93%200%200%201-2.93-2.929c.01-1.62%201.322-2.937%202.93-2.929'/%3e%3cpath%20fill='%231d0800'%20d='M19.849%2017.09c1.616.01%202.955%201.27%202.955%202.886s-1.34%202.968-2.955%202.968a2.925%202.925%200%200%201-2.93-2.929c.01-1.62%201.322-2.937%202.93-2.929v.005Z'/%3e%3cpath%20fill='%231f0800'%20d='M19.853%2017.095c1.616.009%202.96%201.265%202.96%202.885s-1.344%202.973-2.96%202.973a2.925%202.925%200%200%201-2.929-2.929c.009-1.625%201.322-2.938%202.929-2.929'/%3e%3cpath%20fill='%23200900'%20d='M19.857%2017.104c1.616.009%202.96%201.265%202.96%202.88%200%201.617-1.344%202.973-2.96%202.973a2.92%202.92%200%200%201-2.924-2.924c.008-1.625%201.321-2.938%202.924-2.925z'/%3e%3cpath%20fill='%23220900'%20d='M19.857%2017.108c1.616.01%202.96%201.26%202.96%202.877s-1.344%202.977-2.96%202.977a2.92%202.92%200%200%201-2.924-2.925c.008-1.624%201.321-2.937%202.924-2.924z'/%3e%3cpath%20fill='%23240a00'%20d='M19.862%2017.113c1.616.009%202.96%201.26%202.96%202.872s-1.349%202.977-2.96%202.977c-1.612%200-2.934-1.309-2.925-2.925.009-1.624%201.322-2.937%202.925-2.924'/%3e%3cpath%20fill='%23250a00'%20d='M19.866%2017.117c1.616.013%202.964%201.256%202.964%202.872s-1.348%202.977-2.964%202.977a2.92%202.92%200%200%201-2.925-2.924c.01-1.625%201.322-2.938%202.925-2.925'/%3e%3cpath%20fill='%23270b00'%20d='M19.87%2017.122c1.616.013%202.964%201.251%202.964%202.867s-1.348%202.982-2.964%202.982a2.92%202.92%200%200%201-2.924-2.925c.009-1.625%201.326-2.938%202.924-2.924'/%3e%3cpath%20fill='%23290b00'%20d='M19.87%2017.126c1.616.013%202.964%201.251%202.964%202.863s-1.352%202.982-2.964%202.982-2.933-1.309-2.924-2.925c.009-1.625%201.326-2.933%202.924-2.924z'/%3e%3cpath%20fill='%232a0c00'%20d='M19.875%2017.13c1.616.014%202.968%201.247%202.968%202.863s-1.352%202.987-2.968%202.987a2.92%202.92%200%200%201-2.925-2.925c.013-1.625%201.326-2.933%202.925-2.925'/%3e%3cpath%20fill='%232c0c00'%20d='M19.88%2017.135c1.615.013%202.968%201.242%202.968%202.858s-1.353%202.987-2.969%202.987a2.92%202.92%200%200%201-2.924-2.925c.013-1.625%201.326-2.933%202.924-2.925v.005Z'/%3e%3cpath%20fill='%232e0d00'%20d='M19.88%2017.14c1.61.012%202.968%201.242%202.968%202.853s-1.357%202.99-2.969%202.99-2.933-1.308-2.924-2.92c.013-1.624%201.326-2.933%202.924-2.924Z'/%3e%3cpath%20fill='%23300d00'%20d='M19.884%2017.143c1.611.014%202.968%201.239%202.968%202.855s-1.357%202.99-2.968%202.99c-1.612%200-2.934-1.308-2.92-2.92.013-1.625%201.326-2.933%202.92-2.92z'/%3e%3cpath%20fill='%23310d00'%20d='M19.888%2017.152c1.611.013%202.973%201.239%202.973%202.85%200%201.612-1.357%202.995-2.973%202.995s-2.933-1.309-2.92-2.92c.013-1.625%201.326-2.934%202.92-2.92z'/%3e%3cpath%20fill='%23330e00'%20d='M19.892%2017.157c1.612.013%202.973%201.234%202.973%202.845s-1.361%202.995-2.973%202.995-2.933-1.309-2.92-2.92c.013-1.625%201.326-2.934%202.92-2.92'/%3e%3cpath%20fill='%23350e00'%20d='M19.892%2017.161c1.612.018%202.973%201.23%202.973%202.846S21.504%2023%2019.892%2023s-2.933-1.308-2.92-2.92c.013-1.625%201.326-2.933%202.92-2.92Z'/%3e%3cpath%20fill='%23360f00'%20d='M19.897%2017.165c1.611.018%202.977%201.23%202.977%202.842%200%201.611-1.361%202.999-2.977%202.999s-2.934-1.309-2.92-2.92c.013-1.625%201.326-2.934%202.92-2.92Z'/%3e%3cpath%20fill='%23380f00'%20d='M19.901%2017.17c1.612.017%202.977%201.225%202.977%202.837%200%201.611-1.365%202.999-2.977%202.999s-2.933-1.309-2.92-2.92c.013-1.625%201.326-2.934%202.92-2.92z'/%3e%3cpath%20fill='%233a1000'%20d='M19.901%2017.174c1.612.018%202.977%201.225%202.977%202.837s-1.365%203.004-2.977%203.004-2.933-1.309-2.92-2.92c.013-1.625%201.33-2.934%202.92-2.92Z'/%3e%3cpath%20fill='%233b1000'%20d='M19.905%2017.179c1.612.017%202.978%201.22%202.978%202.832s-1.366%203.004-2.977%203.004c-1.612%200-2.934-1.309-2.92-2.92.017-1.625%201.33-2.934%202.92-2.92v.004Z'/%3e%3cpath%20fill='%233d1100'%20d='M19.91%2017.183c1.611.018%202.982%201.216%202.982%202.828s-1.37%203.008-2.982%203.008-2.933-1.309-2.916-2.916c.018-1.625%201.33-2.933%202.916-2.916z'/%3e%3cpath%20fill='%233f1100'%20d='M19.914%2017.187c1.612.018%202.982%201.217%202.982%202.828%200%201.612-1.37%203.008-2.982%203.008-1.611%200-2.933-1.304-2.915-2.915.017-1.625%201.33-2.934%202.915-2.916z'/%3e%3cpath%20fill='%23411200'%20d='M19.914%2017.196c1.612.018%202.982%201.212%202.982%202.824s-1.37%203.008-2.982%203.008c-1.611%200-2.933-1.304-2.915-2.916.017-1.625%201.33-2.933%202.915-2.916'/%3e%3cpath%20fill='%23421200'%20d='M19.919%2017.2c1.611.018%202.981%201.208%202.981%202.82s-1.374%203.012-2.981%203.012-2.934-1.304-2.916-2.916c.017-1.624%201.33-2.933%202.916-2.915Z'/%3e%3cpath%20fill='%23441300'%20d='M19.923%2017.205c1.612.022%202.986%201.208%202.986%202.82%200%201.61-1.374%203.012-2.986%203.012-1.611%200-2.933-1.305-2.916-2.916.018-1.625%201.33-2.934%202.916-2.916'/%3e%3cpath%20fill='%23461300'%20d='M19.923%2017.21c1.612.021%202.986%201.203%202.986%202.814%200%201.612-1.374%203.017-2.986%203.017-1.611%200-2.933-1.304-2.916-2.916.018-1.625%201.33-2.933%202.916-2.916Z'/%3e%3cpath%20fill='%23471300'%20d='M19.928%2017.214c1.607.022%202.986%201.203%202.986%202.81s-1.38%203.017-2.986%203.017c-1.608%200-2.934-1.304-2.916-2.916.017-1.625%201.33-2.933%202.916-2.916z'/%3e%3cpath%20fill='%23491400'%20d='M19.932%2017.218c1.607.022%202.99%201.199%202.99%202.81%200%201.612-1.378%203.022-2.99%203.022s-2.933-1.305-2.916-2.916c.018-1.625%201.33-2.933%202.916-2.916'/%3e%3cpath%20fill='%234b1400'%20d='M19.936%2017.223c1.608.021%202.99%201.194%202.99%202.806%200%201.611-1.378%203.02-2.99%203.02-1.611%200-2.933-1.303-2.915-2.91.021-1.625%201.33-2.934%202.915-2.912z'/%3e%3cpath%20fill='%234c1500'%20d='M19.936%2017.227c1.608.022%202.99%201.194%202.99%202.802%200%201.607-1.382%203.025-2.99%203.025-1.607%200-2.933-1.304-2.911-2.911.022-1.625%201.335-2.934%202.911-2.912z'/%3e%3cpath%20fill='%234e1500'%20d='M19.94%2017.231c1.608.022%202.991%201.19%202.991%202.797s-1.383%203.026-2.99%203.026-2.934-1.304-2.912-2.911c.022-1.625%201.335-2.934%202.912-2.912Z'/%3e%3cpath%20fill='%23501600'%20d='M19.945%2017.236c1.607.022%202.995%201.19%202.995%202.797s-1.383%203.025-2.995%203.025c-1.611%200-2.933-1.304-2.911-2.91.022-1.626%201.335-2.934%202.911-2.912'/%3e%3cpath%20fill='%23521600'%20d='M19.945%2017.244c1.607.022%202.995%201.186%202.995%202.793s-1.388%203.03-2.995%203.03-2.933-1.304-2.911-2.911c.022-1.625%201.335-2.933%202.911-2.912'/%3e%3cpath%20fill='%23531700'%20d='M19.95%2017.249c1.607.026%202.994%201.181%202.994%202.788%200%201.608-1.387%203.03-2.994%203.03s-2.934-1.304-2.912-2.911c.022-1.625%201.335-2.933%202.912-2.912z'/%3e%3cpath%20fill='%23551700'%20d='M19.954%2017.253c1.607.027%202.995%201.181%202.995%202.789%200%201.607-1.388%203.034-2.995%203.034s-2.934-1.304-2.912-2.911c.022-1.625%201.335-2.934%202.912-2.912'/%3e%3cpath%20fill='%23571800'%20d='M19.958%2017.258c1.608.026%203%201.177%203%202.784s-1.392%203.034-3%203.034c-1.607%200-2.933-1.304-2.911-2.911.022-1.625%201.335-2.934%202.911-2.912z'/%3e%3cpath%20fill='%23581800'%20d='M19.958%2017.262c1.608.026%203%201.172%203%202.78s-1.392%203.038-3%203.038c-1.607%200-2.933-1.304-2.911-2.91.022-1.626%201.335-2.934%202.911-2.912z'/%3e%3cpath%20fill='%235a1900'%20d='M19.963%2017.266c1.607.027%202.999%201.173%202.999%202.78s-1.392%203.039-3%203.039c-1.607%200-2.933-1.304-2.906-2.907.021-1.625%201.334-2.934%202.907-2.907z'/%3e%3cpath%20fill='%235c1900'%20d='M19.967%2017.27c1.607.027%203.004%201.169%203.004%202.776s-1.397%203.043-3.004%203.043-2.933-1.304-2.907-2.907c.026-1.624%201.335-2.933%202.907-2.907z'/%3e%3cpath%20fill='%235e1a00'%20d='M19.967%2017.275c1.607.027%203.004%201.168%203.004%202.771s-1.397%203.043-3.004%203.043-2.933-1.304-2.907-2.907c.026-1.624%201.34-2.933%202.907-2.907'/%3e%3cpath%20fill='%235f1a00'%20d='M19.971%2017.28c1.608.026%203.004%201.163%203.004%202.77%200%201.608-1.396%203.044-3.004%203.044-1.607%200-2.933-1.3-2.907-2.907.027-1.625%201.34-2.934%202.907-2.907'/%3e%3cpath%20fill='%23611a00'%20d='M19.976%2017.284c1.603.026%203.003%201.16%203.003%202.767s-1.4%203.047-3.003%203.047-2.934-1.3-2.907-2.907c.026-1.625%201.34-2.933%202.907-2.907'/%3e%3cpath%20fill='%23631b00'%20d='M19.98%2017.293c1.603.03%203.008%201.16%203.008%202.762s-1.4%203.047-3.008%203.047c-1.607%200-2.933-1.3-2.907-2.907.026-1.624%201.34-2.933%202.907-2.907z'/%3e%3cpath%20fill='%23641b00'%20d='M19.98%2017.297c1.603.03%203.008%201.155%203.008%202.762s-1.405%203.052-3.008%203.052-2.933-1.3-2.907-2.907c.026-1.625%201.34-2.933%202.907-2.907'/%3e%3cpath%20fill='%23661c00'%20d='M19.985%2017.302c1.602.03%203.008%201.154%203.008%202.757s-1.406%203.052-3.008%203.052-2.934-1.3-2.907-2.907c.026-1.625%201.339-2.933%202.907-2.907z'/%3e%3cpath%20fill='%23681c00'%20d='M19.989%2017.306c1.603.03%203.008%201.15%203.008%202.753s-1.405%203.057-3.008%203.057-2.933-1.3-2.903-2.903c.027-1.625%201.34-2.933%202.903-2.903z'/%3e%3cpath%20fill='%23691d00'%20d='M19.989%2017.31c1.603.031%203.012%201.146%203.012%202.754%200%201.607-1.41%203.056-3.012%203.056s-2.933-1.3-2.903-2.903c.027-1.624%201.34-2.933%202.903-2.902z'/%3e%3cpath%20fill='%236b1d00'%20d='M19.993%2017.315c1.603.03%203.013%201.146%203.013%202.749%200%201.602-1.41%203.06-3.013%203.06s-2.933-1.3-2.902-2.902c.026-1.625%201.34-2.934%202.902-2.903z'/%3e%3cpath%20fill='%236d1e00'%20d='M19.998%2017.32c1.603.03%203.012%201.14%203.012%202.744%200%201.602-1.41%203.06-3.012%203.06s-2.934-1.3-2.903-2.902c.03-1.625%201.34-2.934%202.903-2.903Z'/%3e%3cpath%20fill='%236f1e00'%20d='M19.998%2017.323c1.603.031%203.017%201.138%203.017%202.745s-1.414%203.06-3.017%203.06-2.934-1.299-2.903-2.902c.03-1.625%201.34-2.933%202.903-2.902Z'/%3e%3cpath%20fill='%23701f00'%20d='M20.002%2017.328c1.603.035%203.017%201.137%203.017%202.74s-1.414%203.065-3.017%203.065-2.933-1.3-2.902-2.902c.03-1.625%201.343-2.934%202.902-2.903'/%3e%3cpath%20fill='%23721f00'%20d='M20.006%2017.337c1.603.035%203.017%201.133%203.017%202.736%200%201.602-1.414%203.065-3.017%203.065s-2.928-1.3-2.902-2.903c.03-1.625%201.344-2.933%202.902-2.903z'/%3e%3cpath%20fill='%23742000'%20d='M20.01%2017.341c1.604.035%203.018%201.133%203.018%202.736s-1.419%203.07-3.017%203.07-2.93-1.3-2.903-2.903c.031-1.625%201.344-2.934%202.903-2.903Z'/%3e%3cpath%20fill='%23752000'%20d='M20.01%2017.346c1.604.035%203.022%201.128%203.022%202.73%200%201.604-1.418%203.07-3.021%203.07s-2.93-1.3-2.903-2.902c.031-1.625%201.344-2.934%202.903-2.898Z'/%3e%3cpath%20fill='%23772000'%20d='M20.015%2017.35c1.603.035%203.021%201.124%203.021%202.727s-1.418%203.074-3.02%203.074-2.93-1.3-2.899-2.898c.03-1.625%201.344-2.934%202.898-2.899z'/%3e%3cpath%20fill='%23792100'%20d='M20.02%2017.354c1.602.035%203.02%201.124%203.02%202.723s-1.422%203.074-3.02%203.074-2.93-1.3-2.898-2.898c.03-1.625%201.343-2.934%202.898-2.899'/%3e%3cpath%20fill='%237a2100'%20d='M20.02%2017.359c1.598.035%203.025%201.12%203.025%202.722%200%201.603-1.423%203.074-3.025%203.074-1.603%200-2.93-1.3-2.898-2.898.03-1.625%201.343-2.934%202.898-2.898'/%3e%3cpath%20fill='%237c2200'%20d='M20.024%2017.363c1.598.035%203.026%201.12%203.026%202.718%200%201.599-1.423%203.079-3.026%203.079s-2.929-1.3-2.898-2.899c.035-1.624%201.344-2.933%202.898-2.898'/%3e%3cpath%20fill='%237e2200'%20d='M20.029%2017.367c1.598.036%203.025%201.116%203.025%202.714%200%201.599-1.427%203.079-3.025%203.079-1.599%200-2.93-1.3-2.899-2.899.035-1.624%201.344-2.933%202.899-2.898z'/%3e%3cpath%20fill='%23802300'%20d='M20.033%2017.372c1.598.04%203.025%201.11%203.025%202.714%200%201.602-1.427%203.082-3.025%203.082-1.599%200-2.93-1.295-2.898-2.898.035-1.625%201.343-2.933%202.898-2.898'/%3e%3cpath%20fill='%23812300'%20d='M20.033%2017.376c1.598.04%203.03%201.111%203.03%202.71s-1.427%203.082-3.03%203.082-2.93-1.295-2.898-2.898c.035-1.625%201.343-2.933%202.898-2.898z'/%3e%3cpath%20fill='%23832400'%20d='M20.037%2017.385c1.599.04%203.03%201.107%203.03%202.705s-1.431%203.087-3.03%203.087-2.929-1.295-2.898-2.898c.035-1.625%201.348-2.933%202.898-2.898z'/%3e%3cpath%20fill='%23852400'%20d='M20.042%2017.39c1.598.039%203.03%201.106%203.03%202.704s-1.432%203.087-3.03%203.087c-1.599%200-2.93-1.295-2.894-2.893.035-1.625%201.348-2.934%202.894-2.894v-.005Z'/%3e%3cpath%20fill='%23862500'%20d='M20.042%2017.394c1.598.04%203.03%201.102%203.03%202.7s-1.432%203.092-3.03%203.092c-1.599%200-2.93-1.296-2.894-2.894.035-1.625%201.348-2.933%202.894-2.894z'/%3e%3cpath%20fill='%23882500'%20d='M20.046%2017.398c1.599.04%203.035%201.098%203.035%202.696s-1.436%203.092-3.035%203.092c-1.598%200-2.929-1.296-2.894-2.894.035-1.625%201.348-2.933%202.894-2.894'/%3e%3cpath%20fill='%238a2600'%20d='M20.05%2017.403c1.599.04%203.035%201.097%203.035%202.696%200%201.598-1.436%203.091-3.035%203.091-1.598%200-2.928-1.295-2.893-2.894.035-1.624%201.348-2.933%202.893-2.893'/%3e%3cpath%20fill='%238b2600'%20d='M20.055%2017.407c1.598.04%203.034%201.093%203.034%202.692%200%201.598-1.436%203.096-3.034%203.096-1.599%200-2.929-1.296-2.894-2.894.035-1.625%201.348-2.934%202.894-2.894'/%3e%3cpath%20fill='%238d2600'%20d='M20.055%2017.411c1.598.04%203.039%201.09%203.039%202.688s-1.44%203.096-3.04%203.096c-1.598%200-2.928-1.296-2.893-2.894.04-1.625%201.348-2.934%202.894-2.894z'/%3e%3cpath%20fill='%238f2700'%20d='M20.06%2017.416c1.598.044%203.038%201.089%203.038%202.687%200%201.599-1.44%203.1-3.039%203.1-1.598%200-2.929-1.295-2.893-2.893.039-1.625%201.348-2.934%202.893-2.894Z'/%3e%3cpath%20fill='%23912700'%20d='M20.064%2017.42c1.598.044%203.038%201.085%203.038%202.683%200%201.599-1.44%203.1-3.038%203.1-1.599%200-2.93-1.295-2.894-2.893.04-1.625%201.348-2.934%202.894-2.894z'/%3e%3cpath%20fill='%23922800'%20d='M20.064%2017.424c1.594.044%203.038%201.085%203.038%202.68%200%201.593-1.444%203.104-3.038%203.104s-2.93-1.296-2.89-2.89c.04-1.624%201.348-2.933%202.89-2.89z'/%3e%3cpath%20fill='%23942800'%20d='M20.068%2017.433c1.594.044%203.043%201.08%203.043%202.679s-1.445%203.105-3.043%203.105-2.929-1.296-2.89-2.89c.04-1.625%201.353-2.933%202.89-2.89z'/%3e%3cpath%20fill='%23962900'%20d='M20.072%2017.438c1.595.044%203.044%201.076%203.044%202.674s-1.445%203.109-3.044%203.109-2.928-1.295-2.889-2.89c.04-1.624%201.352-2.933%202.89-2.889v-.004Z'/%3e%3cpath%20fill='%23972900'%20d='M20.077%2017.442c1.594.044%203.043%201.076%203.043%202.67s-1.45%203.109-3.043%203.109-2.93-1.295-2.89-2.89c.04-1.624%201.353-2.933%202.89-2.889'/%3e%3cpath%20fill='%23992a00'%20d='M20.077%2017.447c1.594.043%203.043%201.071%203.043%202.67s-1.45%203.108-3.043%203.108-2.93-1.295-2.89-2.89c.04-1.624%201.353-2.932%202.89-2.889Z'/%3e%3cpath%20fill='%239b2a00'%20d='M20.081%2017.45c1.594.045%203.048%201.072%203.048%202.666s-1.45%203.114-3.048%203.114-2.929-1.296-2.89-2.89c.04-1.624%201.353-2.933%202.89-2.89'/%3e%3cpath%20fill='%239c2b00'%20d='M20.086%2017.455c1.594.044%203.047%201.067%203.047%202.661s-1.453%203.114-3.047%203.114-2.93-1.296-2.89-2.89c.04-1.624%201.353-2.933%202.89-2.89z'/%3e%3cpath%20fill='%239e2b00'%20d='M20.086%2017.46c1.594.048%203.047%201.062%203.047%202.66%200%201.6-1.453%203.119-3.047%203.119s-2.93-1.296-2.89-2.89c.044-1.625%201.353-2.933%202.89-2.89Z'/%3e%3cpath%20fill='%23a02c00'%20d='M20.09%2017.464c1.594.048%203.052%201.063%203.052%202.657s-1.454%203.118-3.052%203.118-2.929-1.296-2.89-2.89c.044-1.625%201.353-2.933%202.89-2.89z'/%3e%3cpath%20fill='%23a22c00'%20d='M20.094%2017.468c1.594.049%203.052%201.059%203.052%202.653s-1.458%203.122-3.052%203.122-2.929-1.291-2.885-2.885c.044-1.625%201.353-2.934%202.885-2.885z'/%3e%3cpath%20fill='%23a32d00'%20d='M20.099%2017.477c1.594.049%203.052%201.054%203.052%202.648s-1.458%203.122-3.052%203.122-2.93-1.29-2.885-2.885c.044-1.624%201.352-2.933%202.885-2.885'/%3e%3cpath%20fill='%23a52d00'%20d='M20.099%2017.482c1.594.048%203.052%201.053%203.052%202.648%200%201.594-1.458%203.126-3.052%203.126s-2.93-1.29-2.885-2.885c.044-1.625%201.352-2.933%202.885-2.885z'/%3e%3cpath%20fill='%23a72d00'%20d='M20.103%2017.486c1.594.048%203.056%201.05%203.056%202.643%200%201.595-1.462%203.127-3.056%203.127s-2.929-1.29-2.885-2.885c.044-1.625%201.357-2.933%202.885-2.885'/%3e%3cpath%20fill='%23a82e00'%20d='M20.108%2017.49c1.594.049%203.056%201.05%203.056%202.64s-1.462%203.126-3.056%203.126-2.93-1.29-2.886-2.885c.044-1.625%201.357-2.933%202.886-2.885z'/%3e%3cpath%20fill='%23aa2e00'%20d='M20.108%2017.495c1.594.048%203.056%201.045%203.056%202.639s-1.462%203.13-3.056%203.13-2.93-1.29-2.886-2.884c.044-1.625%201.357-2.933%202.886-2.885'/%3e%3cpath%20fill='%23ac2f00'%20d='M20.112%2017.5c1.59.047%203.056%201.04%203.056%202.634s-1.466%203.13-3.056%203.13-2.929-1.29-2.885-2.884c.044-1.625%201.357-2.933%202.885-2.885v.004Z'/%3e%3cpath%20fill='%23ad2f00'%20d='M20.116%2017.504c1.59.052%203.061%201.04%203.061%202.63s-1.467%203.135-3.06%203.135c-1.595%200-2.93-1.29-2.886-2.885.044-1.625%201.357-2.933%202.885-2.885z'/%3e%3cpath%20fill='%23af3000'%20d='M20.12%2017.508c1.59.053%203.061%201.036%203.061%202.63s-1.466%203.136-3.06%203.136-2.93-1.291-2.881-2.881c.048-1.625%201.357-2.933%202.88-2.88z'/%3e%3cpath%20fill='%23b13000'%20d='M20.12%2017.512c1.59.053%203.061%201.037%203.061%202.626%200%201.59-1.47%203.14-3.06%203.14s-2.93-1.291-2.881-2.88c.048-1.625%201.357-2.934%202.88-2.881z'/%3e%3cpath%20fill='%23b33100'%20d='M20.125%2017.517c1.59.052%203.065%201.032%203.065%202.621%200%201.59-1.47%203.14-3.065%203.14s-2.929-1.291-2.88-2.88c.048-1.625%201.356-2.934%202.88-2.881'/%3e%3cpath%20fill='%23b43100'%20d='M20.13%2017.526c1.59.052%203.065%201.027%203.065%202.621s-1.471%203.14-3.066%203.14-2.928-1.291-2.88-2.88c.048-1.626%201.357-2.934%202.88-2.881Z'/%3e%3cpath%20fill='%23b63200'%20d='M20.13%2017.53c1.59.053%203.065%201.027%203.065%202.617s-1.476%203.144-3.066%203.144-2.928-1.29-2.88-2.88c.048-1.625%201.357-2.934%202.88-2.881Z'/%3e%3cpath%20fill='%23b83200'%20d='M20.134%2017.534c1.59.053%203.065%201.024%203.065%202.613%200%201.59-1.476%203.144-3.065%203.144-1.59%200-2.93-1.29-2.88-2.88.047-1.625%201.356-2.934%202.88-2.881z'/%3e%3cpath%20fill='%23b93300'%20d='M20.138%2017.539c1.59.052%203.07%201.018%203.07%202.612s-1.48%203.149-3.07%203.149-2.929-1.291-2.88-2.88c.048-1.63%201.36-2.934%202.88-2.881'/%3e%3cpath%20fill='%23b30'%20d='M23.212%2020.151c0%201.59-1.48%203.149-3.07%203.149s-2.928-1.291-2.88-2.88c.048-1.63%201.361-2.934%202.88-2.881%201.59.057%203.07%201.018%203.07%202.608v.005Z'/%3e%3cpath%20fill='%23bc3502'%20d='M20.143%2017.547c1.59.053%203.07%201.02%203.07%202.613%200%201.594-1.476%203.149-3.07%203.149s-2.93-1.291-2.881-2.88c.048-1.626%201.361-2.93%202.88-2.881Z'%20opacity='.99'/%3e%3cpath%20fill='%23bc3705'%20d='M20.147%2017.552c1.59.053%203.065%201.023%203.065%202.613s-1.475%203.144-3.065%203.144-2.924-1.291-2.88-2.88c.048-1.626%201.356-2.93%202.88-2.881z'%20opacity='.98'/%3e%3cpath%20fill='%23bd3907'%20d='M20.147%2017.552c1.59.053%203.065%201.027%203.065%202.617s-1.475%203.144-3.065%203.144-2.924-1.29-2.88-2.88c.048-1.625%201.356-2.93%202.88-2.881'%20opacity='.97'/%3e%3cpath%20fill='%23bd3a09'%20d='M20.151%2017.556c1.59.053%203.061%201.028%203.061%202.617%200%201.59-1.47%203.14-3.06%203.14s-2.925-1.29-2.881-2.88c.048-1.625%201.357-2.93%202.88-2.881z'%20opacity='.96'/%3e%3cpath%20fill='%23be3c0c'%20d='M20.151%2017.56c1.59.053%203.061%201.033%203.061%202.622%200%201.59-1.47%203.136-3.06%203.136s-2.925-1.291-2.881-2.881c.048-1.625%201.357-2.929%202.88-2.88v.004Z'%20opacity='.95'/%3e%3cpath%20fill='%23bf3e0e'%20d='M20.156%2017.565c1.59.053%203.06%201.032%203.06%202.622s-1.466%203.135-3.06%203.135-2.925-1.291-2.88-2.88c.047-1.625%201.356-2.93%202.88-2.881z'%20opacity='.95'/%3e%3cpath%20fill='%23bf4010'%20d='M20.16%2017.57c1.59.052%203.057%201.036%203.057%202.625%200%201.59-1.467%203.131-3.057%203.131s-2.924-1.29-2.88-2.88c.048-1.625%201.357-2.93%202.88-2.881z'%20opacity='.94'/%3e%3cpath%20fill='%23c04213'%20d='M20.16%2017.574c1.59.052%203.057%201.036%203.057%202.626s-1.467%203.13-3.057%203.13-2.924-1.29-2.88-2.88c.043-1.625%201.352-2.929%202.88-2.88z'%20opacity='.93'/%3e%3cpath%20fill='%23c14415'%20d='M20.165%2017.578c1.59.049%203.052%201.041%203.052%202.63%200%201.59-1.463%203.127-3.052%203.127-1.59%200-2.925-1.29-2.881-2.88.044-1.625%201.353-2.93%202.88-2.881v.004Z'%20opacity='.92'/%3e%3cpath%20fill='%23c14617'%20d='M20.165%2017.578c1.59.049%203.052%201.041%203.052%202.635s-1.463%203.127-3.052%203.127c-1.59%200-2.925-1.291-2.881-2.881.044-1.625%201.353-2.925%202.88-2.88Z'%20opacity='.91'/%3e%3cpath%20fill='%23c24719'%20d='M20.17%2017.583c1.589.048%203.051%201.045%203.051%202.634%200%201.59-1.462%203.123-3.052%203.123s-2.925-1.291-2.88-2.881c.043-1.625%201.352-2.925%202.88-2.88z'%20opacity='.9'/%3e%3cpath%20fill='%23c2491c'%20d='M20.169%2017.587c1.59.048%203.047%201.05%203.047%202.64%200%201.589-1.457%203.121-3.047%203.121s-2.92-1.29-2.88-2.88c.043-1.625%201.352-2.925%202.88-2.881'%20opacity='.89'/%3e%3cpath%20fill='%23c34b1e'%20d='M20.173%2017.591c1.59.049%203.048%201.05%203.048%202.64s-1.458%203.117-3.048%203.117-2.92-1.29-2.88-2.88c.044-1.625%201.352-2.925%202.88-2.881z'%20opacity='.88'/%3e%3cpath%20fill='%23c44d20'%20d='M20.173%2017.596c1.59.048%203.044%201.054%203.044%202.643%200%201.59-1.454%203.114-3.044%203.114s-2.92-1.291-2.88-2.88c.044-1.621%201.352-2.925%202.88-2.882z'%20opacity='.87'/%3e%3cpath%20fill='%23c44f23'%20d='M20.178%2017.6c1.59.048%203.043%201.054%203.043%202.644s-1.454%203.113-3.043%203.113-2.92-1.29-2.88-2.88c.043-1.62%201.347-2.925%202.88-2.881z'%20opacity='.86'/%3e%3cpath%20fill='%23c55125'%20d='M20.182%2017.6c1.59.048%203.043%201.058%203.043%202.648s-1.453%203.11-3.043%203.11-2.92-1.292-2.88-2.881c.043-1.62%201.348-2.925%202.88-2.881z'%20opacity='.85'/%3e%3cpath%20fill='%23c65327'%20d='M20.182%2017.605c1.59.048%203.039%201.058%203.039%202.648s-1.45%203.108-3.039%203.108-2.92-1.29-2.88-2.88c.043-1.62%201.348-2.925%202.88-2.88z'%20opacity='.85'/%3e%3cpath%20fill='%23c6542a'%20d='M20.187%2017.609c1.59.044%203.038%201.063%203.038%202.652s-1.449%203.105-3.038%203.105c-1.59%200-2.92-1.291-2.881-2.88.04-1.621%201.348-2.925%202.88-2.881v.004Z'%20opacity='.84'/%3e%3cpath%20fill='%23c7562c'%20d='M20.187%2017.613c1.59.044%203.034%201.063%203.034%202.657s-1.445%203.105-3.034%203.105c-1.59%200-2.92-1.291-2.881-2.881.04-1.62%201.348-2.92%202.88-2.88Z'%20opacity='.83'/%3e%3cpath%20fill='%23c7582e'%20d='M20.191%2017.618c1.59.044%203.034%201.067%203.034%202.657s-1.444%203.1-3.034%203.1-2.92-1.291-2.88-2.881c.039-1.62%201.347-2.92%202.88-2.88z'%20opacity='.82'/%3e%3cpath%20fill='%23c85a31'%20d='M20.191%2017.622c1.59.044%203.034%201.072%203.034%202.661%200%201.59-1.444%203.096-3.034%203.096s-2.92-1.291-2.88-2.88c.039-1.621%201.347-2.92%202.88-2.881z'%20opacity='.81'/%3e%3cpath%20fill='%23c95c33'%20d='M20.195%2017.622c1.59.044%203.03%201.072%203.03%202.661%200%201.59-1.44%203.096-3.03%203.096s-2.915-1.291-2.88-2.88c.04-1.621%201.343-2.92%202.88-2.881z'%20opacity='.8'/%3e%3cpath%20fill='%23c95e35'%20d='M20.195%2017.627c1.59.043%203.03%201.075%203.03%202.665s-1.44%203.091-3.03%203.091-2.915-1.29-2.88-2.88c.04-1.62%201.343-2.92%202.88-2.88z'%20opacity='.79'/%3e%3cpath%20fill='%23ca6038'%20d='M20.2%2017.63c1.59.045%203.025%201.077%203.025%202.666%200%201.59-1.436%203.092-3.025%203.092-1.59%200-2.916-1.291-2.88-2.88.039-1.621%201.343-2.921%202.88-2.881v.004Z'%20opacity='.78'/%3e%3cpath%20fill='%23ca613a'%20d='M20.204%2017.635c1.59.044%203.026%201.08%203.026%202.67s-1.436%203.087-3.026%203.087-2.916-1.29-2.88-2.88c.04-1.62%201.343-2.92%202.88-2.881z'%20opacity='.77'/%3e%3cpath%20fill='%23cb633c'%20d='M20.204%2017.64c1.59.044%203.026%201.08%203.026%202.674s-1.436%203.087-3.026%203.087-2.916-1.291-2.88-2.88c.04-1.621%201.343-2.92%202.88-2.881'%20opacity='.76'/%3e%3cpath%20fill='%23cc653f'%20d='M20.209%2017.644c1.59.04%203.02%201.085%203.02%202.674%200%201.59-1.43%203.083-3.02%203.083s-2.916-1.291-2.881-2.88c.04-1.617%201.344-2.92%202.88-2.881v.004Z'%20opacity='.75'/%3e%3cpath%20fill='%23cc6741'%20d='M20.209%2017.644c1.59.04%203.02%201.09%203.02%202.679%200%201.59-1.43%203.082-3.02%203.082s-2.916-1.29-2.881-2.88c.035-1.616%201.344-2.92%202.88-2.88Z'%20opacity='.75'/%3e%3cpath%20fill='%23cd6943'%20d='M20.213%2017.648c1.59.04%203.021%201.09%203.021%202.68%200%201.589-1.427%203.077-3.021%203.077s-2.916-1.29-2.88-2.88c.035-1.616%201.339-2.916%202.88-2.88z'%20opacity='.74'/%3e%3cpath%20fill='%23ce6b46'%20d='M20.213%2017.653c1.59.04%203.017%201.093%203.017%202.683s-1.427%203.074-3.017%203.074-2.916-1.291-2.88-2.88c.035-1.617%201.339-2.917%202.88-2.882z'%20opacity='.73'/%3e%3cpath%20fill='%23ce6c48'%20d='M20.217%2017.657c1.59.04%203.017%201.094%203.017%202.683%200%201.59-1.427%203.074-3.017%203.074s-2.915-1.29-2.88-2.88c.035-1.616%201.34-2.916%202.88-2.881z'%20opacity='.72'/%3e%3cpath%20fill='%23cf6e4a'%20d='M20.222%2017.662c1.59.04%203.012%201.098%203.012%202.687%200%201.59-1.423%203.07-3.012%203.07-1.59%200-2.912-1.291-2.881-2.881.035-1.616%201.34-2.916%202.88-2.88v.004Z'%20opacity='.71'/%3e%3cpath%20fill='%23cf704c'%20d='M20.222%2017.666c1.59.04%203.012%201.098%203.012%202.688s-1.423%203.069-3.012%203.069c-1.59%200-2.912-1.291-2.881-2.88.035-1.617%201.34-2.916%202.88-2.881v.004Z'%20opacity='.7'/%3e%3cpath%20fill='%23d0724f'%20d='M20.226%2017.67c1.59.04%203.012%201.103%203.012%202.692s-1.418%203.065-3.012%203.065-2.911-1.29-2.88-2.88c.035-1.616%201.339-2.916%202.88-2.881z'%20opacity='.69'/%3e%3cpath%20fill='%23d17451'%20d='M20.226%2017.67c1.59.04%203.008%201.103%203.008%202.697s-1.418%203.065-3.008%203.065-2.911-1.291-2.88-2.88c.035-1.617%201.339-2.917%202.88-2.882'%20opacity='.68'/%3e%3cpath%20fill='%23d17653'%20d='M20.23%2017.675c1.59.035%203.008%201.106%203.008%202.696s-1.418%203.06-3.008%203.06-2.911-1.29-2.88-2.88c.035-1.616%201.335-2.916%202.88-2.88z'%20opacity='.67'/%3e%3cpath%20fill='%23d27856'%20d='M20.23%2017.68c1.59.034%203.004%201.11%203.004%202.7s-1.414%203.06-3.004%203.06-2.911-1.29-2.88-2.88c.035-1.616%201.335-2.916%202.88-2.88'%20opacity='.66'/%3e%3cpath%20fill='%23d27958'%20d='M20.235%2017.684c1.59.035%203.003%201.11%203.003%202.7s-1.413%203.057-3.003%203.057-2.912-1.291-2.88-2.881c.03-1.616%201.334-2.912%202.88-2.88z'%20opacity='.65'/%3e%3cpath%20fill='%23d37b5a'%20d='M20.235%2017.688c1.59.035%203.003%201.115%203.003%202.705s-1.41%203.052-3.003%203.052-2.912-1.291-2.88-2.88c.03-1.617%201.334-2.912%202.88-2.881z'%20opacity='.65'/%3e%3cpath%20fill='%23d47d5d'%20d='M20.24%2017.692c1.589.035%202.998%201.116%202.998%202.705%200%201.59-1.41%203.052-2.999%203.052s-2.911-1.29-2.88-2.88c.03-1.612%201.334-2.912%202.88-2.881z'%20opacity='.64'/%3e%3cpath%20fill='%23d47f5f'%20d='M20.244%2017.692c1.59.035%202.999%201.12%202.999%202.71s-1.41%203.047-3%203.047c-1.589%200-2.91-1.29-2.88-2.88.03-1.612%201.335-2.912%202.88-2.881v.004Z'%20opacity='.63'/%3e%3cpath%20fill='%23d58161'%20d='M20.244%2017.697c1.59.035%202.995%201.12%202.995%202.71s-1.406%203.047-2.995%203.047-2.907-1.291-2.88-2.88c.03-1.613%201.33-2.912%202.88-2.882z'%20opacity='.62'/%3e%3cpath%20fill='%23d68364'%20d='M20.248%2017.701c1.59.035%202.995%201.124%202.995%202.714s-1.405%203.043-2.995%203.043-2.907-1.29-2.88-2.88c.03-1.612%201.33-2.912%202.88-2.881z'%20opacity='.61'/%3e%3cpath%20fill='%23d68566'%20d='M20.248%2017.706c1.59.035%202.995%201.128%202.995%202.718s-1.405%203.043-2.995%203.043-2.907-1.291-2.88-2.88c.03-1.612%201.33-2.912%202.88-2.881'%20opacity='.6'/%3e%3cpath%20fill='%23d78668'%20d='M20.252%2017.71c1.59.03%202.99%201.128%202.99%202.718s-1.4%203.039-2.99%203.039-2.907-1.291-2.88-2.88c.03-1.612%201.33-2.912%202.88-2.881z'%20opacity='.59'/%3e%3cpath%20fill='%23d7886b'%20d='M20.252%2017.714c1.59.031%202.99%201.133%202.99%202.723s-1.4%203.034-2.99%203.034-2.907-1.29-2.88-2.88c.03-1.612%201.33-2.912%202.88-2.881z'%20opacity='.58'/%3e%3cpath%20fill='%23d88a6d'%20d='M20.257%2017.714c1.59.031%202.986%201.133%202.986%202.723s-1.397%203.034-2.986%203.034-2.907-1.29-2.88-2.88c.026-1.612%201.33-2.907%202.88-2.881z'%20opacity='.57'/%3e%3cpath%20fill='%23d98c6f'%20d='M20.257%2017.719c1.59.03%202.986%201.137%202.986%202.727s-1.397%203.03-2.986%203.03-2.907-1.291-2.88-2.881c.026-1.612%201.33-2.907%202.88-2.88z'%20opacity='.56'/%3e%3cpath%20fill='%23d98e72'%20d='M20.261%2017.723c1.59.03%202.986%201.137%202.986%202.727s-1.396%203.03-2.986%203.03-2.907-1.291-2.88-2.88c.026-1.612%201.326-2.908%202.88-2.881z'%20opacity='.55'/%3e%3cpath%20fill='%23da9074'%20d='M20.266%2017.727c1.59.031%202.981%201.142%202.981%202.732s-1.392%203.026-2.981%203.026c-1.59%200-2.907-1.292-2.881-2.881.026-1.612%201.326-2.907%202.88-2.88v.003Z'%20opacity='.55'/%3e%3cpath%20fill='%23db9276'%20d='M20.266%2017.732c1.59.03%202.981%201.142%202.981%202.736s-1.392%203.025-2.981%203.025c-1.59%200-2.907-1.29-2.881-2.88.026-1.612%201.326-2.907%202.88-2.881Z'%20opacity='.54'/%3e%3cpath%20fill='%23db9379'%20d='M20.27%2017.736c1.59.031%202.977%201.146%202.977%202.736s-1.387%203.021-2.977%203.021-2.903-1.29-2.88-2.88c.026-1.612%201.325-2.907%202.88-2.881z'%20opacity='.53'/%3e%3cpath%20fill='%23dc957b'%20d='M20.27%2017.736c1.59.027%202.977%201.15%202.977%202.74s-1.387%203.022-2.977%203.022-2.903-1.291-2.88-2.881c.026-1.607%201.325-2.907%202.88-2.88Z'%20opacity='.52'/%3e%3cpath%20fill='%23dc977d'%20d='M20.274%2017.74c1.59.027%202.978%201.151%202.978%202.74s-1.388%203.018-2.978%203.018-2.902-1.291-2.88-2.881c.026-1.607%201.326-2.907%202.88-2.88v.004Z'%20opacity='.51'/%3e%3cpath%20fill='%23dd9980'%20d='M20.274%2017.745c1.59.026%202.973%201.155%202.973%202.745s-1.383%203.012-2.973%203.012-2.902-1.291-2.88-2.88c.026-1.608%201.326-2.908%202.88-2.881z'%20opacity='.5'/%3e%3cpath%20fill='%23de9b82'%20d='M20.279%2017.75c1.59.026%202.973%201.154%202.973%202.744s-1.384%203.012-2.973%203.012c-1.59%200-2.903-1.29-2.88-2.88.025-1.607%201.32-2.903%202.88-2.88z'%20opacity='.49'/%3e%3cpath%20fill='%23de9d84'%20d='M20.279%2017.754c1.59.026%202.968%201.16%202.968%202.749s-1.379%203.008-2.968%203.008c-1.59%200-2.903-1.291-2.88-2.88.021-1.608%201.32-2.904%202.88-2.881z'%20opacity='.48'/%3e%3cpath%20fill='%23df9f86'%20d='M20.283%2017.758c1.59.027%202.969%201.16%202.969%202.75%200%201.589-1.38%203.007-2.969%203.007-1.59%200-2.902-1.29-2.88-2.88.021-1.608%201.321-2.903%202.88-2.881z'%20opacity='.47'/%3e%3cpath%20fill='%23dfa089'%20d='M20.288%2017.758c1.59.027%202.968%201.164%202.968%202.754s-1.379%203.003-2.968%203.003c-1.59%200-2.903-1.29-2.881-2.88.022-1.608%201.322-2.903%202.88-2.881v.004Z'%20opacity='.46'/%3e%3cpath%20fill='%23e0a28b'%20d='M20.288%2017.763c1.59.026%202.964%201.163%202.964%202.757s-1.375%203.004-2.964%203.004c-1.59%200-2.903-1.291-2.881-2.88.022-1.608%201.322-2.903%202.88-2.881Z'%20opacity='.45'/%3e%3cpath%20fill='%23e1a48d'%20d='M20.292%2017.767c1.59.026%202.964%201.168%202.964%202.758s-1.374%202.999-2.964%202.999-2.903-1.291-2.88-2.88c.021-1.608%201.321-2.903%202.88-2.881z'%20opacity='.45'/%3e%3cpath%20fill='%23e1a690'%20d='M20.292%2017.771c1.59.022%202.964%201.173%202.964%202.762%200%201.59-1.37%203-2.964%203s-2.898-1.291-2.88-2.88c.021-1.608%201.321-2.903%202.88-2.882'%20opacity='.44'/%3e%3cpath%20fill='%23e2a892'%20d='M20.296%2017.776c1.59.022%202.96%201.172%202.96%202.762s-1.37%202.995-2.96%202.995-2.898-1.291-2.88-2.88c.022-1.608%201.317-2.903%202.88-2.882z'%20opacity='.43'/%3e%3cpath%20fill='%23e3aa94'%20d='M20.296%2017.78c1.59.022%202.96%201.177%202.96%202.767s-1.37%202.99-2.96%202.99-2.898-1.29-2.88-2.88c.022-1.608%201.317-2.903%202.88-2.881z'%20opacity='.42'/%3e%3cpath%20fill='%23e3ac97'%20d='M20.3%2017.785c1.59.022%202.956%201.177%202.956%202.766%200%201.59-1.366%202.99-2.955%202.99-1.59%200-2.898-1.29-2.88-2.88.021-1.607%201.317-2.898%202.88-2.88v.004Z'%20opacity='.41'/%3e%3cpath%20fill='%23e4ad99'%20d='M20.305%2017.785c1.59.022%202.956%201.18%202.956%202.77s-1.366%202.987-2.956%202.987-2.898-1.292-2.88-2.881c.021-1.603%201.317-2.898%202.88-2.88z'%20opacity='.4'/%3e%3cpath%20fill='%23e4af9b'%20d='M20.305%2017.789c1.59.022%202.956%201.181%202.956%202.77%200%201.59-1.362%202.987-2.956%202.987s-2.898-1.291-2.88-2.88c.017-1.604%201.317-2.899%202.88-2.881z'%20opacity='.39'/%3e%3cpath%20fill='%23e5b19e'%20d='M20.31%2017.793c1.59.022%202.95%201.186%202.95%202.776s-1.36%202.981-2.95%202.981-2.899-1.29-2.881-2.88c.018-1.603%201.317-2.899%202.88-2.881v.004Z'%20opacity='.38'/%3e%3cpath%20fill='%23e6b3a0'%20d='M20.31%2017.798c1.59.022%202.95%201.19%202.95%202.78s-1.36%202.981-2.95%202.981-2.899-1.29-2.881-2.88c.018-1.603%201.317-2.899%202.88-2.881Z'%20opacity='.37'/%3e%3cpath%20fill='%23e6b5a2'%20d='M20.314%2017.802c1.59.022%202.947%201.19%202.947%202.78s-1.357%202.977-2.947%202.977-2.898-1.29-2.88-2.88c.017-1.603%201.312-2.899%202.88-2.881z'%20opacity='.36'/%3e%3cpath%20fill='%23e7b7a5'%20d='M20.314%2017.807c1.59.017%202.947%201.194%202.947%202.784s-1.357%202.973-2.947%202.973-2.898-1.291-2.88-2.881c.017-1.603%201.312-2.898%202.88-2.88z'%20opacity='.35'/%3e%3cpath%20fill='%23e8b9a7'%20d='M20.318%2017.807c1.59.017%202.947%201.194%202.947%202.784s-1.353%202.973-2.947%202.973-2.894-1.291-2.88-2.881c.017-1.603%201.313-2.898%202.88-2.88z'%20opacity='.35'/%3e%3cpath%20fill='%23e8baa9'%20d='M20.318%2017.811c1.59.017%202.942%201.199%202.942%202.788%200%201.59-1.352%202.969-2.942%202.969s-2.894-1.291-2.88-2.88c.017-1.604%201.313-2.899%202.88-2.881z'%20opacity='.34'/%3e%3cpath%20fill='%23e9bcac'%20d='M20.323%2017.815c1.59.018%202.942%201.2%202.942%202.789s-1.353%202.968-2.942%202.968-2.894-1.29-2.88-2.88c.017-1.603%201.312-2.899%202.88-2.881z'%20opacity='.33'/%3e%3cpath%20fill='%23e9beae'%20d='M20.327%2017.82c1.59.017%202.938%201.203%202.938%202.793s-1.348%202.964-2.938%202.964-2.894-1.291-2.88-2.881c.017-1.603%201.312-2.894%202.88-2.88z'%20opacity='.32'/%3e%3cpath%20fill='%23eac0b0'%20d='M20.327%2017.824c1.59.018%202.938%201.203%202.938%202.797s-1.348%202.965-2.938%202.965-2.894-1.292-2.88-2.881c.013-1.603%201.312-2.894%202.88-2.88Z'%20opacity='.31'/%3e%3cpath%20fill='%23ebc2b3'%20d='M20.331%2017.828c1.59.018%202.938%201.208%202.938%202.798s-1.343%202.96-2.938%202.96c-1.594%200-2.893-1.292-2.88-2.881.013-1.603%201.308-2.894%202.88-2.88z'%20opacity='.3'/%3e%3cpath%20fill='%23ebc4b5'%20d='M20.331%2017.828c1.59.018%202.934%201.213%202.934%202.802%200%201.59-1.344%202.96-2.934%202.96s-2.893-1.291-2.88-2.88c.013-1.604%201.308-2.895%202.88-2.882'%20opacity='.29'/%3e%3cpath%20fill='%23ecc6b7'%20d='M20.336%2017.833c1.59.018%202.933%201.212%202.933%202.802s-1.343%202.955-2.933%202.955-2.894-1.291-2.88-2.88c.012-1.6%201.308-2.895%202.88-2.882z'%20opacity='.28'/%3e%3cpath%20fill='%23ecc7b9'%20d='M20.336%2017.837c1.59.014%202.929%201.217%202.929%202.806%200%201.59-1.34%202.951-2.93%202.951-1.589%200-2.893-1.29-2.88-2.88.013-1.599%201.309-2.894%202.88-2.881v.004Z'%20opacity='.27'/%3e%3cpath%20fill='%23edc9bc'%20d='M20.34%2017.842c1.59.013%202.93%201.216%202.93%202.806s-1.34%202.95-2.93%202.95-2.894-1.29-2.88-2.88c.013-1.598%201.308-2.894%202.88-2.88z'%20opacity='.26'/%3e%3cpath%20fill='%23eecbbe'%20d='M20.34%2017.846c1.59.013%202.93%201.22%202.93%202.81s-1.34%202.947-2.93%202.947-2.89-1.291-2.88-2.88c.013-1.6%201.308-2.895%202.88-2.881z'%20opacity='.25'/%3e%3cpath%20fill='%23eecdc0'%20d='M20.345%2017.85c1.59.014%202.924%201.221%202.924%202.81%200%201.59-1.335%202.947-2.924%202.947-1.59%200-2.89-1.29-2.881-2.88.013-1.599%201.304-2.894%202.88-2.88v.003Z'%20opacity='.25'/%3e%3cpath%20fill='%23efcfc3'%20d='M20.35%2017.85c1.589.014%202.924%201.226%202.924%202.815%200%201.59-1.335%202.942-2.925%202.942s-2.89-1.29-2.88-2.88c.013-1.599%201.304-2.89%202.88-2.88v.003Z'%20opacity='.24'/%3e%3cpath%20fill='%23f0d1c5'%20d='M20.35%2017.855c1.589.013%202.92%201.23%202.92%202.82s-1.331%202.941-2.92%202.941c-1.59%200-2.89-1.29-2.882-2.88.014-1.599%201.305-2.89%202.881-2.881Z'%20opacity='.23'/%3e%3cpath%20fill='%23f0d2c7'%20d='M20.354%2017.86c1.59.012%202.92%201.229%202.92%202.819s-1.33%202.937-2.92%202.937-2.89-1.29-2.881-2.88c.009-1.599%201.304-2.89%202.88-2.881v.004Z'%20opacity='.22'/%3e%3cpath%20fill='%23f1d4ca'%20d='M20.354%2017.864c1.59.013%202.92%201.234%202.92%202.823%200%201.59-1.33%202.938-2.92%202.938s-2.89-1.291-2.881-2.88c.009-1.6%201.304-2.89%202.88-2.881Z'%20opacity='.21'/%3e%3cpath%20fill='%23f1d6cc'%20d='M20.358%2017.868c1.59.013%202.916%201.234%202.916%202.824s-1.326%202.933-2.916%202.933-2.89-1.291-2.88-2.88c.008-1.6%201.303-2.89%202.88-2.881z'%20opacity='.2'/%3e%3cpath%20fill='%23f2d8ce'%20d='M20.358%2017.872c1.59.01%202.916%201.239%202.916%202.828%200%201.59-1.326%202.93-2.916%202.93s-2.89-1.292-2.88-2.881c.008-1.599%201.303-2.89%202.88-2.881z'%20opacity='.19'/%3e%3cpath%20fill='%23f3dad1'%20d='M20.362%2017.872c1.59.01%202.912%201.239%202.912%202.828%200%201.59-1.322%202.93-2.912%202.93s-2.89-1.292-2.88-2.881c.008-1.599%201.3-2.89%202.88-2.881z'%20opacity='.18'/%3e%3cpath%20fill='%23f3dcd3'%20d='M20.367%2017.877c1.59.009%202.911%201.243%202.911%202.832%200%201.59-1.322%202.925-2.911%202.925-1.59%200-2.89-1.291-2.881-2.88.009-1.6%201.3-2.89%202.88-2.882v.005Z'%20opacity='.17'/%3e%3cpath%20fill='%23f4ded5'%20d='M20.367%2017.881c1.59.009%202.911%201.243%202.911%202.837s-1.322%202.925-2.911%202.925a2.88%202.88%200%200%201-2.881-2.881c.009-1.594%201.3-2.89%202.88-2.88Z'%20opacity='.16'/%3e%3cpath%20fill='%23f4dfd8'%20d='M20.371%2017.886c1.59.008%202.907%201.247%202.907%202.836%200%201.59-1.317%202.92-2.907%202.92a2.88%202.88%200%200%201-2.88-2.88c.008-1.594%201.3-2.885%202.88-2.88z'%20opacity='.15'/%3e%3cpath%20fill='%23f5e1da'%20d='M20.371%2017.89c1.59.009%202.907%201.252%202.907%202.841s-1.317%202.92-2.907%202.92a2.88%202.88%200%200%201-2.88-2.88c.008-1.594%201.3-2.885%202.88-2.881'%20opacity='.15'/%3e%3cpath%20fill='%23f6e3dc'%20d='M20.375%2017.894c1.59.01%202.907%201.252%202.907%202.841s-1.313%202.916-2.907%202.916a2.877%202.877%200%200%201-2.88-2.88c.008-1.594%201.3-2.885%202.88-2.881z'%20opacity='.14'/%3e%3cpath%20fill='%23f6e5df'%20d='M20.375%2017.899c1.59.009%202.903%201.256%202.903%202.845s-1.313%202.912-2.903%202.912a2.88%202.88%200%200%201-2.88-2.88%202.885%202.885%200%200%201%202.88-2.882z'%20opacity='.13'/%3e%3cpath%20fill='%23f7e7e1'%20d='M20.38%2017.899c1.59.004%202.902%201.256%202.902%202.845s-1.313%202.912-2.902%202.912a2.88%202.88%200%200%201-2.88-2.88%202.88%202.88%200%200%201%202.88-2.882z'%20opacity='.12'/%3e%3cpath%20fill='%23f8e9e3'%20d='M20.38%2017.903c1.59.005%202.898%201.26%202.898%202.85S21.97%2023.66%2020.38%2023.66a2.88%202.88%200%200%201-2.88-2.88%202.88%202.88%200%200%201%202.88-2.881z'%20opacity='.11'/%3e%3cpath%20fill='%23f8ebe6'%20d='M20.384%2017.908c1.59.004%202.898%201.26%202.898%202.85s-1.308%202.907-2.898%202.907a2.88%202.88%200%200%201-2.88-2.881%202.88%202.88%200%200%201%202.88-2.88z'%20opacity='.1'/%3e%3cpath%20fill='%23f9ece8'%20d='M20.389%2017.912c1.59.004%202.898%201.265%202.898%202.854a2.913%202.913%200%200%201-2.898%202.903%202.877%202.877%200%200%201-2.881-2.88%202.88%202.88%200%200%201%202.88-2.881v.004Z'%20opacity='.09'/%3e%3cpath%20fill='%23f9eeea'%20d='M20.389%2017.916c1.59.005%202.893%201.265%202.893%202.86a2.91%202.91%200%200%201-2.893%202.902%202.88%202.88%200%201%201%200-5.761Z'%20opacity='.08'/%3e%3cpath%20fill='%23faf0ec'%20d='M20.393%2017.92c1.59%200%202.894%201.27%202.894%202.86a2.91%202.91%200%200%201-2.894%202.898%202.88%202.88%200%200%201-2.88-2.881%202.88%202.88%200%200%201%202.88-2.88v.004Z'%20opacity='.07'/%3e%3cpath%20fill='%23fbf2ef'%20d='M20.393%2017.92c1.59%200%202.89%201.274%202.89%202.864s-1.3%202.898-2.89%202.898a2.88%202.88%200%200%201-2.88-2.88%202.88%202.88%200%200%201%202.88-2.881Z'%20opacity='.06'/%3e%3cpath%20fill='%23fbf4f1'%20d='M20.397%2017.925c1.59%200%202.89%201.274%202.89%202.863%200%201.59-1.3%202.894-2.89%202.894a2.88%202.88%200%201%201%200-5.761z'%20opacity='.05'/%3e%3cpath%20fill='%23fcf6f3'%20d='M20.397%2017.93c1.59%200%202.89%201.277%202.89%202.867s-1.296%202.89-2.89%202.89a2.88%202.88%200%201%201%200-5.762z'%20opacity='.05'/%3e%3cpath%20fill='%23fdf8f6'%20d='M20.402%2017.934a2.875%202.875%200%200%201%202.885%202.867c0%201.59-1.296%202.89-2.885%202.89a2.88%202.88%200%200%201-2.88-2.88c0-1.59%201.29-2.881%202.88-2.881z'%20opacity='.04'/%3e%3cpath%20fill='%23fdf9f8'%20d='M20.402%2017.938a2.88%202.88%200%200%201%202.885%202.872%202.882%202.882%200%201%201-5.766.004c0-1.59%201.291-2.88%202.88-2.88v.004Z'%20opacity='.03'/%3e%3cpath%20fill='%23fefbfa'%20d='M20.406%2017.943c1.59%200%202.88%201.282%202.88%202.872a2.886%202.886%200%200%201-2.88%202.885%202.88%202.88%200%200%201-2.88-2.881%202.88%202.88%200%200%201%202.88-2.88z'%20opacity='.02'/%3e%3c/g%3e%3c/g%3e%3cmask%20id='e'%20width='40'%20height='40'%20x='0'%20y='0'%20maskUnits='userSpaceOnUse'%20style='mask-type:luminance'%3e%3cpath%20fill='%23fff'%20d='M40%200H0v40h40zM1.317%2039.56a.88.88%200%200%201-.878-.877V1.317A.88.88%200%200%201%201.317.44H18.47c10.802%200%2019.563%208.756%2019.563%2019.563%200%2010.803-8.757%2019.563-19.563%2019.563H1.317v-.004Z'/%3e%3c/mask%3e%3cg%20mask='url(%23e)'%3e%3cmask%20id='f'%20width='75'%20height='76'%20x='-29'%20y='-18'%20maskUnits='userSpaceOnUse'%20style='mask-type:luminance'%3e%3cpath%20fill='%23fff'%20d='M8.752%2057.1c20.49%200%2037.101-16.611%2037.101-37.102S29.243-17.104%208.752-17.104-28.35-.493-28.35%2019.998-11.74%2057.1%208.752%2057.1'/%3e%3c/mask%3e%3cg%20mask='url(%23f)'%3e%3cpath%20fill='%23e04e15'%20d='M22.334-30.688-41.932%206.416l37.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23e04f15'%20d='M23.109-29.352-41.157%207.752l37.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23e15015'%20d='M23.881-28.012-40.385%209.092-3.28%2073.358l64.266-37.104-37.104-64.266Z'/%3e%3cpath%20fill='%23e15115'%20d='m24.65-26.67-64.266%2037.104L-2.512%2074.7l64.266-37.104z'/%3e%3cpath%20fill='%23e25215'%20d='m25.42-25.338-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23e25316'%20d='m26.193-23.998-64.266%2037.104L-.969%2077.372l64.266-37.104z'/%3e%3cpath%20fill='%23e35416'%20d='m26.97-22.658-64.266%2037.104L-.192%2078.712l64.266-37.104z'/%3e%3cpath%20fill='%23e35516'%20d='m27.74-21.322-64.266%2037.104L.578%2080.048l64.266-37.104z'/%3e%3cpath%20fill='%23e35616'%20d='m28.513-19.982-64.266%2037.104L1.35%2081.388l64.266-37.104z'/%3e%3cpath%20fill='%23e45716'%20d='M29.285-18.646-34.98%2018.458%202.123%2082.724%2066.39%2045.62z'/%3e%3cpath%20fill='%23e45716'%20d='m30.06-17.31-64.266%2037.104L2.898%2084.06l64.266-37.104z'/%3e%3cpath%20fill='%23e55816'%20d='m30.832-15.97-64.266%2037.104L3.67%2085.4l64.266-37.104z'/%3e%3cpath%20fill='%23e55916'%20d='m31.605-14.63-64.266%2037.104L4.443%2086.74l64.266-37.104z'/%3e%3cpath%20fill='%23e55a16'%20d='m32.371-13.296-64.266%2037.104L5.21%2088.073%2069.475%2050.97z'/%3e%3cpath%20fill='%23e65b16'%20d='m33.148-11.956-64.266%2037.104L5.986%2089.412%2070.252%2052.31z'/%3e%3cpath%20fill='%23e65c17'%20d='m33.92-10.617-64.265%2037.104L6.759%2090.753%2071.025%2053.65z'/%3e%3cpath%20fill='%23e75d17'%20d='m34.691-9.28-64.266%2037.104L7.53%2092.09l64.266-37.104z'/%3e%3cpath%20fill='%23e75e17'%20d='M35.464-7.945-28.802%2029.16%208.302%2093.425l64.266-37.104z'/%3e%3cpath%20fill='%23e85f17'%20d='M36.236-6.605-28.03%2030.5%209.074%2094.765%2073.34%2057.661z'/%3e%3cpath%20fill='%23e86017'%20d='m37.01-5.269-64.265%2037.104L9.849%2096.101l64.266-37.104z'/%3e%3cpath%20fill='%23e86117'%20d='m37.309-4.75-64.266%2037.104L10.147%2096.62l64.266-37.104z'/%3e%3cpath%20fill='%23e96217'%20d='m37.607-4.23-64.266%2037.103L10.445%2097.14l64.266-37.104z'/%3e%3cpath%20fill='%23e96317'%20d='M37.905-3.716-26.36%2033.388l37.104%2064.266L75.01%2060.55z'/%3e%3cpath%20fill='%23e96418'%20d='m38.208-3.197-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23e96518'%20d='m38.504-2.682-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ea6618'%20d='m38.802-2.163-64.266%2037.104L11.64%2099.207l64.266-37.104z'/%3e%3cpath%20fill='%23ea6718'%20d='m39.1-1.648-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ea6818'%20d='m39.398-1.13-64.266%2037.105%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ea6918'%20d='M39.698-.614-24.568%2036.49l37.105%2064.266%2064.265-37.104z'/%3e%3cpath%20fill='%23eb6a18'%20d='m39.996-.095-64.265%2037.104%2037.103%2064.266L77.1%2064.171z'/%3e%3cpath%20fill='%23eb6b19'%20d='m40.295.424-64.266%2037.104%2037.104%2064.266L77.399%2064.69z'/%3e%3cpath%20fill='%23eb6c19'%20d='m40.593.939-64.266%2037.103%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23eb6d19'%20d='M40.895%201.458-23.37%2038.562l37.104%2064.265L78%2065.724%2040.895%201.457Z'/%3e%3cpath%20fill='%23ec6e19'%20d='m41.191%201.973-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ec6f19'%20d='m41.49%202.492-64.267%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ec7019'%20d='M41.788%203.006-22.479%2040.11l37.104%2064.266L78.89%2067.272z'/%3e%3cpath%20fill='%23ec7119'%20d='M42.086%203.525-22.18%2040.63l37.104%2064.266L79.19%2067.791z'/%3e%3cpath%20fill='%23ed7219'%20d='M42.386%204.04-21.88%2041.146l37.104%2064.266L79.49%2068.306z'/%3e%3cpath%20fill='%23ed731a'%20d='m42.684%204.56-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ed741a'%20d='m42.982%205.079-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ed751a'%20d='m43.28%205.593-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ee761a'%20d='m43.583%206.112-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ee771a'%20d='m43.879%206.627-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ee781a'%20d='M44.177%207.146-20.09%2044.25l37.104%2064.266L81.28%2071.412z'/%3e%3cpath%20fill='%23ef791a'%20d='m44.475%207.661-64.266%2037.104%2037.104%2064.266L81.58%2071.927z'/%3e%3cpath%20fill='%23ef7a1b'%20d='m44.773%208.18-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23ef7b1b'%20d='M45.073%208.695-19.193%2045.8l37.105%2064.266%2064.265-37.104z'/%3e%3cpath%20fill='%23ef7c1b'%20d='m45.371%209.214-64.265%2037.104%2037.103%2064.266L82.476%2073.48z'/%3e%3cpath%20fill='%23f07d1b'%20d='m45.67%209.733-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f07e1b'%20d='m45.968%2010.248-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f07f1b'%20d='M46.27%2010.767-17.996%2047.87l37.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f0801b'%20d='M46.566%2011.282-17.7%2048.386l37.104%2064.266L83.67%2075.548z'/%3e%3cpath%20fill='%23f1801c'%20d='m46.864%2011.801-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f1811c'%20d='m47.162%2012.32-64.266%2037.104L20%20113.69l64.266-37.104z'/%3e%3cpath%20fill='%23f1821c'%20d='m47.46%2012.835-64.265%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f1831c'%20d='m47.76%2013.35-64.265%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f2841c'%20d='m48.059%2013.869-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f2851c'%20d='m48.357%2014.388-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f2861c'%20d='M48.655%2014.903-15.61%2052.007l37.104%2064.266L85.76%2079.168z'/%3e%3cpath%20fill='%23f2871d'%20d='m48.958%2015.422-64.266%2037.104%2037.104%2064.266%2064.266-37.105z'/%3e%3cpath%20fill='%23f3881d'%20d='M49.254%2015.937-15.012%2053.04l37.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f3891d'%20d='M49.552%2016.456-14.714%2053.56l37.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f38a1d'%20d='m49.85%2016.975-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f48b1d'%20d='m50.148%2017.49-64.266%2037.103%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f48c1d'%20d='m50.448%2018.005-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f48d1d'%20d='m50.746%2018.524-64.265%2037.104%2037.104%2064.266L87.85%2082.79%2050.745%2018.524Z'/%3e%3cpath%20fill='%23f48e1e'%20d='m51.045%2019.043-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f58f1e'%20d='m51.343%2019.557-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f5901e'%20d='M51.645%2020.076-12.62%2057.18l37.104%2064.266L88.75%2084.342z'/%3e%3cpath%20fill='%23f5911e'%20d='m51.941%2020.591-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f5921e'%20d='m52.24%2021.11-64.267%2037.105%2037.104%2064.265%2064.266-37.104z'/%3e%3cpath%20fill='%23f6931e'%20d='m52.537%2021.63-64.266%2037.103L25.375%20123l64.266-37.104z'/%3e%3cpath%20fill='%23f6941e'%20d='M52.836%2022.144-11.43%2059.248l37.103%2064.266L89.94%2086.41z'/%3e%3cpath%20fill='%23f6951e'%20d='m53.138%2022.663-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f6961f'%20d='m53.434%2023.178-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f7971f'%20d='m53.732%2023.697-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f7981f'%20d='m54.03%2024.212-64.266%2037.104%2037.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f7991f'%20d='M54.328%2024.731-9.938%2061.835%2027.166%20126.1l64.266-37.104z'/%3e%3cpath%20fill='%23f79a1f'%20d='M54.629%2025.246-9.637%2062.35l37.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f89b1f'%20d='M54.927%2025.765-9.34%2062.87l37.104%2064.266L92.03%2090.031z'/%3e%3cpath%20fill='%23f89c1f'%20d='M55.225%2026.284-9.041%2063.388l37.104%2064.266L92.329%2090.55z'/%3e%3cpath%20fill='%23f89d20'%20d='M55.523%2026.799-8.743%2063.903l37.104%2064.266%2064.266-37.104z'/%3e%3cpath%20fill='%23f89e20'%20d='M55.825%2027.318-8.44%2064.422l37.103%2064.266L92.93%2091.584z'/%3e%3cpath%20fill='%23f99f20'%20d='M56.121%2027.833-8.144%2064.937l37.103%2064.266%2064.266-37.104-37.103-64.266Z'/%3e%3cpath%20fill='%23f9a020'%20d='M56.42%2028.352-7.846%2065.456l37.104%2064.266%2064.266-37.104z'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3clinearGradient%20id='b'%20x1='21.262'%20x2='19.269'%20y1='22.242'%20y2='19.124'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23ff9200'/%3e%3cstop%20offset='.21'%20stop-color='%23ff8d00'/%3e%3cstop%20offset='.45'%20stop-color='%23ff7f00'/%3e%3cstop%20offset='.62'%20stop-color='%23ff7100'/%3e%3cstop%20offset='.82'%20stop-color='%23ff5e00'/%3e%3cstop%20offset='1'%20stop-color='%23ff5200'/%3e%3c/linearGradient%3e%3clinearGradient%20id='c'%20x1='20.946'%20x2='18.035'%20y1='22.202'%20y2='16.507'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23ff7100'%20stop-opacity='0'/%3e%3cstop%20offset='.03'%20stop-color='%23ff6d00'%20stop-opacity='.03'/%3e%3cstop%20offset='.21'%20stop-color='%23ff5900'%20stop-opacity='.25'/%3e%3cstop%20offset='.39'%20stop-color='%23ff4800'%20stop-opacity='.42'/%3e%3cstop%20offset='.56'%20stop-color='%23ff3b00'%20stop-opacity='.56'/%3e%3cstop%20offset='.72'%20stop-color='%23ff3200'%20stop-opacity='.66'/%3e%3cstop%20offset='.86'%20stop-color='%23ff2c00'%20stop-opacity='.72'/%3e%3cstop%20offset='.98'%20stop-color='%23ff2b00'%20stop-opacity='.74'/%3e%3c/linearGradient%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",EFTPOS:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cmask%20id='b'%20width='31'%20height='33'%20x='5'%20y='3'%20maskUnits='userSpaceOnUse'%20style='mask-type:luminance'%3e%3cpath%20fill='%23fff'%20d='M5.055%203.905h30.83v32H5.055z'/%3e%3c/mask%3e%3cg%20mask='url(%23b)'%3e%3cpath%20fill='%231f0038'%20d='M11.667%2030.811h-1.062V29.75h1.062v-.605c.04-.457.12-.914.564-1.17.189-.107.404-.188.619-.215.363-.04.739-.04%201.115-.067v1.022c-.242.013-.47.027-.712.053-.229.027-.376.202-.39.43%200%20.081-.027.175-.04.256v.228c.47%200%20.94-.013%201.397%200%20.43.014.565-.215.578-.59%200-.202.04-.418.054-.633H15.9v1.25h1.627v1.062H15.9v.9c.014.35.027.686.081%201.022s.323.43.592.443c.309.014.631.04.954.054v1.089c-.632%200-1.277.08-1.895-.121-.47-.148-.753-.51-.834-.995a7%207%200%200%201-.08-.699v-1.666h-1.895v3.48H11.64v-3.493zm7.688%202.944v2.163h-1.25v-6.155h1.075l.094.753c.457-.645%201.075-.9%201.828-.914.537%200%201.048.067%201.505.376.497.336.766.82.847%201.411.04.256.08.511.067.766-.027.645-.188%201.237-.672%201.694-.31.282-.672.457-1.075.537-.619.121-1.25.108-1.828-.174-.215-.108-.403-.296-.605-.444zm1.384-3.132c-.08%200-.229.014-.363.054-.39.094-.712.282-.9.659a1.6%201.6%200%200%200-.121%201.061c.08.444.335.753.752.9.363.122.726.149%201.102.068.403-.08.753-.242.914-.659a1.72%201.72%200%200%200%20.054-1.129%201.5%201.5%200%200%200-.255-.524c-.283-.35-.7-.416-1.183-.43m-10.241%202.285c-.229.632-.632%201.048-1.223%201.29-.377.148-.766.202-1.17.242-.55.054-1.075%200-1.599-.161-.793-.242-1.277-.766-1.398-1.6-.107-.752-.067-1.491.417-2.137a2.26%202.26%200%200%201%201.398-.873c.309-.067.631-.121.94-.108.592.014%201.183.108%201.694.444a2%202%200%200%201%20.914%201.37c.067.35.08.727.107%201.103h-4.3c.08.416.309.712.685.833.538.175%201.089.215%201.626%200%20.175-.067.323-.215.47-.336.041-.027.081-.08.122-.08h1.303zm-4.193-1.384h2.943a.99.99%200%200%200-.699-.86%202.33%202.33%200%200%200-1.357-.014c-.457.135-.78.403-.9.887zm28.532-.377h-1.33c-.189-.47-.592-.591-1.049-.604q-.483%200-.967.08c-.121.027-.242.148-.323.269-.094.148-.013.363.161.403.27.067.538.121.82.148.632.08%201.277.08%201.895.255.968.27%201.035%201.33.632%201.936-.282.416-.712.618-1.17.699-.39.08-.792.12-1.182.107-.565-.013-1.142-.08-1.653-.336-.511-.255-.9-.847-.928-1.357h1.33c.041%200%20.095.04.108.08.095.336.363.484.659.551.484.094.968.108%201.451-.027.27-.067.39-.255.377-.483-.014-.162-.188-.283-.457-.31-.484-.053-.968-.067-1.452-.12-.443-.054-.887-.108-1.276-.336-.336-.202-.524-.484-.551-.874-.027-.376.053-.726.309-.995a2.5%202.5%200%200%201%20.658-.457c.31-.147.659-.174%201.008-.201a4.2%204.2%200%200%201%201.64.161c.699.202%201.129.659%201.303%201.398zm-10.886.928c0-.511.107-.995.39-1.412.35-.524.86-.846%201.465-.98.309-.068.645-.122.954-.108.631.027%201.25.12%201.787.51.47.337.74.793.86%201.345a3%203%200%200%201-.04%201.424c-.148.551-.47.968-.968%201.237-.416.228-.873.309-1.344.362-.618.054-1.21%200-1.774-.201-.739-.269-1.169-.847-1.276-1.653a7%207%200%200%201-.054-.524m1.303%200c-.026.55.175.994.726%201.196.39.148.807.175%201.223.08.282-.067.538-.16.726-.403.296-.43.31-.887.202-1.37a1.16%201.16%200%200%200-.672-.82c-.336-.148-.686-.162-1.035-.121-.282.04-.551.12-.766.322-.323.296-.417.672-.404%201.116m10.631-1.976c0%20.323-.188.524-.497.524-.255%200-.55-.161-.538-.51.014-.404.229-.538.511-.552.269%200%20.538.135.51.538zm-.752-.31c-.175.162-.202.431-.04.592.147.148.403.135.55%200a.406.406%200%200%200%200-.578c-.12-.134-.336-.134-.524%200l.014-.013Z'/%3e%3cpath%20fill='%231f0038'%20d='M35.173%2029.83h.188c.256%200%20.269.027.215.269-.013.08.027.175.054.255h-.094l-.148-.201-.148.242-.067-.027z'/%3e%3cpath%20fill='url(%23c)'%20d='M21.21%207.426c-3.038%201.384-5.094%204.046-5.094%207.096%200%203.858%203.548%206.976%207.93%206.976%202.002%200%203.426-.47%205.066-1.452.175-.107.376-.188.497-.013.08.094.04.215-.013.309-1.801%203.306-5.47%205.604-9.596%205.604-6.088%200-11.02-4.932-11.02-11.02%200-3.481%201.612-6.572%204.125-8.588%201.895-1.52%206.626-1.72%208.104%201.088Z'/%3e%3cpath%20fill='%23e40056'%20d='M29.461%2011.687c0%203.655-3.494%206.625-7.808%206.625-.632%200-2.325-.08-3.548-.658-.35-.161-.31-.363-.068-.457.551-.229%204.892-1.062%204.892-5.51%200-4.449-4.596-7.701-9.824-5.363A10.95%2010.95%200%200%201%2020%203.905c5.12%200%209.461%203.48%209.461%207.782'/%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3clinearGradient%20id='c'%20x1='19.14'%20x2='23.481'%20y1='17.775'%20y2='-2.439'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23e40056'/%3e%3cstop%20offset='.66'%20stop-color='%231f0038'/%3e%3c/linearGradient%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",ELO:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23000'%20d='M40%200H0v40h40z'/%3e%3cpath%20fill='%23fff'%20d='M25.275%2019.986c-.371-1.486-1.56-2.525-2.97-2.822-1.484-.223-2.969.371-3.785%201.634s-.817%202.896%200%204.082l3.71-1.632%201.56-.669zm-5.716%201.113v-.223c0-.89.519-1.707%201.41-2.004a2.2%202.2%200%200%201%202.375.593L19.56%2021.1Zm4.676%202.45c-1.261%201.262-3.192%201.41-4.676.445l.89-1.336a2.24%202.24%200%200%200%202.673-.224zm1.56-.965V15.53h1.336v6.83c0%20.074%200%20.148.074.148l1.188.445-.52%201.412-1.337-.595c-.593-.148-.741-.519-.741-1.188Z'/%3e%3cpath%20fill='%23289ad3'%20d='M7.162%2017.416c-.743.668-1.189%201.633-1.189%202.598s.446%201.93%201.19%202.598l-1.635%201.782c-1.261-1.114-2.004-2.747-1.93-4.454%200-1.707.743-3.267%202.005-4.38-.075%200%201.56%201.856%201.56%201.856Z'/%3e%3cpath%20fill='%23ec442d'%20d='M15.145%2021.122c-.297%201.706-1.336%203.118-2.822%204.009-1.484.89-3.266.965-4.898.37l.815-2.3c.965.37%202.005.296%202.896-.224a3.53%203.53%200%200%200%201.707-2.375z'/%3e%3cpath%20fill='%23fdda2e'%20d='m15.18%2018.798-2.376.52c-.224-.966-.817-1.857-1.707-2.376-.892-.52-1.93-.52-2.896-.224l-.742-2.3a6.1%206.1%200%200%201%204.826.445c1.483.817%202.522%202.301%202.894%203.935Z'/%3e%3cpath%20fill='%23fff'%20d='M30.619%2019.169c-.445.37-.742.965-.742%201.633%200%20.594.298%201.188.742%201.633L29.58%2023.55c-.741-.669-1.188-1.707-1.188-2.747a3.41%203.41%200%200%201%201.262-2.672c0-.075.966%201.039.966%201.039m4.973%202.301c-.223%201.04-.816%201.93-1.781%202.45-.891.52-2.005.594-3.044.297l.52-1.411a2.13%202.13%200%200%200%201.781-.148c.52-.297.891-.817%201.04-1.485zm0-1.411-1.485.372a2.6%202.6%200%200%200-1.039-1.485%202.13%202.13%200%200%200-1.782-.15l-.445-1.41c.965-.37%202.079-.222%202.97.224.89.445%201.558%201.41%201.78%202.449Z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",GIROCARD:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M40%200H0v40h40z'/%3e%3cpath%20fill='%23004090'%20d='M14.104%2027.649c.25%200%20.332.083.58.083v-.828c-.082%200-.33-.082-.495-.082-.331%200-.828.082-1.159.497a.9.9%200%200%200-.248.413l-.082-.828h-.827c0%20.58.083%201.076.083%201.654v3.226h.91v-2.398c0-.497.082-1.075.495-1.49.249-.247.577-.247.743-.247m-3.222-.745h-.827v4.963h.827zM8.07%2029.386c0%20.083%200%20.578-.248%201.074-.33.496-.743.662-1.156.662-.331%200-.663-.166-.91-.33-.332-.332-.414-.91-.414-1.406%200-.745.248-1.158.578-1.49a1.04%201.04%200%200%201%20.745-.33%201.2%201.2%200%200%201%20.827.33c.578.497.578%201.406.578%201.49m.415%203.803c.33-.496.413-.992.413-1.985v-4.3H8.07v.745c0-.082-.165-.33-.413-.497s-.663-.413-1.157-.413c-.497%200-.91.165-1.076.331-.33.249-.495.414-.578.579-.413.578-.497%201.157-.497%201.737%200%20.165%200%20.578.165%201.074%200%20.084.167.662.663%201.076.247.248.661.413%201.323.413.33%200%20.826-.165%201.157-.413l.331-.332v.663c0%20.247%200%20.413-.083.661-.083.165-.083.248-.248.413-.248.248-.578.413-1.157.413s-1.076-.165-1.241-.248q-.372-.122-.496-.248l-.082.828c.165.081.248.081.413.165a4.3%204.3%200%200%200%201.406.248c.662%200%201.074-.165%201.405-.331.332-.247.496-.414.578-.579m1.406-7.442h.91v-.993h-.91zm8.682%203.555c0%20.578-.165%201.324-.828%201.737-.165.083-.33.165-.66.165-.083%200-.33%200-.579-.165-.083%200-.083-.083-.248-.165-.166-.083-.331-.33-.496-.662s-.165-.662-.165-.991c0-.663.33-1.16.578-1.406.165-.166.496-.331.992-.331.745%200%201.075.496%201.241.909.082.165.165.496.165.91Zm.248%201.986c.578-.579.745-1.324.745-1.986%200-1.24-.663-1.902-1.241-2.232-.248-.083-.578-.248-1.075-.248-1.075%200-1.818.578-2.15%201.157-.248.414-.33.91-.33%201.407%200%20.992.33%201.57.743%201.985.084.081.165.165.332.246.247.167.661.332%201.322.332.497%200%20.826-.084%201.075-.165.083-.165.332-.332.58-.496Zm3.636.578c.58%200%20.91-.165%201.16-.247l-.084-.828c-.165.083-.578.248-.993.248-.081%200-.33%200-.66-.165-.745-.33-.91-1.157-.91-1.653%200-.828.413-1.324.826-1.572.414-.249.744-.165.828-.165.33%200%20.662.165.744.248l.082-.828c-.165%200-.495-.165-.91-.165-.992%200-1.57.413-1.983.91-.415.578-.497%201.24-.497%201.818%200%201.324.745%201.985%201.406%202.317.165%200%20.495.082.991.082m4.633-2.316c0%20.332%200%20.497-.083.663%200%20.082-.082.247-.248.413-.247.413-.662.496-.992.496-.414%200-.909-.248-.909-.827%200-.578.495-.826.91-.91.165%200%20.33-.083.66-.083h.662zm.083%202.234h.743V28.64c0-.496-.082-.91-.247-1.074-.248-.415-.827-.745-1.572-.745-.909%200-1.405.33-1.57.413v.745c.165-.083.744-.496%201.405-.496.579%200%20.993.331%201.075.662.083.165.083.412.083.66h-.744c-.497%200-1.075%200-1.571.248-.413.167-.91.497-.91%201.324%200%20.578.249.91.497%201.156.247.25.661.332.991.332.578%200%20.91-.165%201.159-.33.248-.165.33-.332.495-.497v.745zm3.969-4.135c.248%200%20.331.083.578.083v-.828c-.082%200-.33-.082-.495-.082-.331%200-.827.082-1.159.497a.9.9%200%200%200-.247.413l-.084-.828h-.826c0%20.58.083%201.076.083%201.654v3.226h.91v-2.398c0-.497.083-1.075.496-1.49.248-.247.578-.247.744-.247m4.3%201.737c0%20.083%200%20.413-.083.662-.248.66-.745%201.075-1.322%201.075-.497%200-.91-.249-1.158-.828-.166-.331-.166-.663-.166-.993%200-.081%200-.413.166-.744.33-.91%201.074-.991%201.322-.991.579%200%201.076.413%201.323%201.074-.165.165-.082.413-.082.745m.91%201.405v-6.119h-.91v2.977c-.165-.165-.165-.249-.248-.33-.248-.248-.663-.415-1.24-.415-.166%200-.91%200-1.571.663-.745.826-.663%201.819-.663%201.983%200%20.332.085.745.166%201.076.248.578.827%201.323%201.984%201.323.166%200%20.828%200%201.324-.497l.33-.33v.744h.828V30.79Zm-11.827-20.26h-1.239v.332h.993l2.481%2010.17H13.941l2.481-10.17h.991v-.332h-1.24l-2.728%2010.915h13.891z'/%3e%3cpath%20fill='%2362c6e9'%20d='M22.79%205.901h-4.88a.536.536%200%200%200-.497.497v4.796h.332V6.397c0-.083.081-.164.165-.164h.91v3.472h-.994l1.406%201.489h2.233l1.406-1.489h-.992V6.233h.909c.083%200%20.165.081.165.165v4.796h.331V6.397a.536.536%200%200%200-.495-.496Z'/%3e%3cpath%20fill='%23004090'%20d='M19.315%2017.148h2.15q.249-.002.248-.248l-.083-1.406c0-.166-.165-.248-.248-.248H19.48q-.248%200-.248.248L19.15%2016.9c-.084.165%200%20.246.165.246m-.992-1.9H16.42c-.165%200-.248.082-.331.248l-.247%201.406q0%20.246.247.246h2.15q.248%200%20.248-.246l.083-1.406q0-.25-.248-.248Zm1.074-.496h1.985c.083%200%20.165-.084.165-.248l-.082-1.158c0-.083-.083-.248-.248-.248h-1.819c-.084%200-.249.082-.249.248l-.082%201.156c.082.166.165.25.33.25m-.826-1.49h-1.819c-.083%200-.248.084-.248.166l-.248%201.157c0%20.083.082.167.165.167h1.985c.082%200%20.248-.084.248-.248l.082-1.158c.083%200%200-.083-.165-.083Zm5.706%201.49a.18.18%200%200%200%20.165-.167l-.248-1.156c0-.084-.165-.166-.249-.166h-1.818c-.083%200-.165.083-.165.248l.082%201.157c0%20.084.083.249.248.249h1.985zm-4.797-1.902h1.82a.18.18%200%200%200%20.166-.167l-.083-.909a.18.18%200%200%200-.165-.165h-1.653a.18.18%200%200%200-.167.165l-.082.91c0%20.082%200%20.166.165.166Zm4.384%200a.18.18%200%200%200%20.165-.167l-.165-.909c0-.082-.084-.165-.248-.165h-1.654a.18.18%200%200%200-.167.165l.083.91c0%20.082.084.166.166.166zm-5.128-1.241h-1.654c-.082%200-.165.083-.248.165l-.165.91c0%20.082.083.166.165.166h1.819a.18.18%200%200%200%20.166-.167l.083-.909a.18.18%200%200%200-.166-.165m5.954%205.54q.248%200%20.248-.247l-.248-1.406c0-.166-.165-.248-.332-.248h-1.901q-.247%200-.247.248l.082%201.406c0%20.165.165.246.248.246zm-3.308.497h-2.067a.35.35%200%200%200-.331.33l-.082%201.819c0%20.166.082.331.33.331h2.398a.353.353%200%200%200%20.332-.331l-.248-1.819a.35.35%200%200%200-.332-.331m-3.307.001h-2.15c-.165%200-.33.165-.414.33l-.33%201.819c0%20.166.082.331.247.331h2.398a.353.353%200%200%200%20.332-.331l.165-1.819c.083-.165-.083-.331-.248-.331m7.028.331c0-.165-.165-.331-.413-.331h-2.15c-.165%200-.33.166-.248.331l.166%201.819c0%20.166.165.331.33.331h2.398c.165%200%20.248-.165.248-.331z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",HIPERCARD:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23b32024'%20d='M40%200H0v40h40z'/%3e%3cpath%20fill='%23fefefe'%20d='M9.504%2013c-1.615.06-2.692.778-2.991%201.855-.12.359-.18.658-.3%201.196v.12c-.06.359-.119.479-.119.658-.24%201.137-.479%202.274-.778%203.71l-.478%202.572c-.3%201.496-.479%202.513-.718%203.47L4%2027h25.906c1.615%200%203.35-.24%203.77-2.034.119-.479.238-.957.418-1.915l.12-.538c.06-.18.778-3.71.957-4.727L36.128%2013zm24.47%207.479c-.239%201.136-.359%201.675-.359%201.974h-.06l-.12.479a34%2034%200%200%201-.418%201.854c-.24.958-.838%201.556-3.17%201.556H4.716c.18-.898.36-1.795.6-3.111l.538-2.513c.299-1.436.538-2.633.777-3.71.06-.179.06-.358.12-.717v-.12l.24-1.197c.239-.897%201.136-1.376%202.452-1.436H35.29z'/%3e%3cpath%20fill='%23fefefe'%20d='M32.419%2018.684c-1.735-.539-2.752.718-2.752%202.273%200%20.3.06.598.239.838.3.359%201.256.479%201.735.12.12-.06.18-.18.24-.24s.119-.18.119-.18c0%20.18-.06.3-.06.48h.658c.12-1.736.479-3.231.778-4.847h-.718c-.06.539-.179%201.077-.239%201.556m-1.317%202.931c-.48%200-.718-.299-.718-.777%200-.838.358-1.795%201.076-1.855.36-.06.599.06.838.12-.24.957-.119%202.512-1.196%202.512m-6.042-2.991c-.06.18-.06.359-.12.538.419-.12%201.675-.418%201.795.12.06.18%200%20.359-.06.538-1.137-.12-2.094.06-2.333.898-.18.538%200%201.077.359%201.256.658.3%201.496-.06%201.795-.478%200%20.18-.06.299-.06.538h.598c0-.598.12-1.017.18-1.555.06-.42.239-.898.18-1.257-.06-.957-1.496-.658-2.334-.598m1.137%202.692c-.36.36-1.376.479-1.257-.418.06-.718.838-.838%201.675-.718-.06.418-.12.897-.418%201.136m-10.889-2.692c-.599-.24-1.316.06-1.616.3%200-.12.06-.18.06-.3h-.598c-.24%201.675-.539%203.29-.838%204.906h.658c.12-.598.18-1.256.3-1.855.179.599%201.196.479%201.615.24.957-.539%201.675-2.872.419-3.291m-.539%202.752c-.359.419-1.316.419-1.376-.299-.06-.3.06-.598.12-.897s.12-.599.12-.838c.359-.479%201.435-.479%201.555.24.12.657-.12%201.435-.419%201.794m-4.188-4.128c-.12.658-.24%201.256-.299%201.914-.718%200-1.436.06-2.154%200%20.12-.598.24-1.256.36-1.914H7.65c-.3%201.555-.539%203.17-.838%204.726h.778c.12-.777.24-1.615.419-2.333.658%200%201.495-.06%202.153%200-.12.778-.299%201.556-.418%202.333h.777c.24-1.615.539-3.17.838-4.726zm1.975.718c.12-.12.299-.539.12-.718-.06-.06-.18-.06-.3-.06s-.24.06-.299.12c-.06.12-.18.478-.06.598.12.18.419.12.539.06m-.718.658q-.24%201.685-.599%203.35h.718c.18-1.136.36-2.273.598-3.35zm10.35%202.573c-.06-.18-.06-.42-.06-.659.06-.478.18-1.017.479-1.316.359-.359%201.077-.299%201.675-.12%200-.179.06-.358.06-.538-.957-.18-1.855-.06-2.333.419-.48.478-.778%201.615-.539%202.333.24.838%201.376.838%202.274.539.06-.18.06-.36.12-.539-.48.3-1.437.48-1.676-.119m-.358-2.573c-.6-.24-1.078.18-1.317.538.06-.179.06-.359.12-.538h-.599q-.24%201.685-.598%203.35h.718c.12-.658.12-1.555.359-2.153.18-.48.598-.958%201.256-.718%200-.18.001-.3.061-.479'/%3e%3cpath%20fill='%23fefefe'%20d='M17.94%2018.564c-.479.06-.957.18-1.256.479-.36.419-.658%201.256-.599%202.034.12%201.137%201.496%201.077%202.633.838%200-.18.06-.36.12-.539-.48.18-1.257.419-1.736.12-.358-.24-.358-.778-.239-1.316h2.274c.06-.36.18-.718.06-1.077-.06-.479-.659-.599-1.257-.539m.718%201.197h-1.615c.06-.36.419-.778.897-.838.479.06.838.24.718.838m11.368-1.137c-.599-.3-1.137.18-1.317.538.06-.18.06-.359.12-.538h-.598c-.18%201.137-.36%202.274-.599%203.35h.718c0-.418.12-.777.18-1.196.12-.958.359-1.975%201.436-1.675%200-.12%200-.3.06-.479'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",JCB:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20d='M39.867%2028.887c0%203.4-2.77%206.17-6.17%206.17H.134V10.623a6.18%206.18%200%200%201%206.17-6.17h33.564v24.433Z'/%3e%3cpath%20fill='url(%23a)'%20d='M28.938%2022.621h2.55c.073%200%20.243-.024.316-.024.485-.097.898-.534.898-1.141a1.18%201.18%200%200%200-.898-1.142c-.073-.024-.22-.024-.316-.024h-2.55z'/%3e%3cpath%20fill='url(%23b)'%20d='M31.196%206.52a4.42%204.42%200%200%200-4.42%204.42v4.59h6.242c.145%200%20.316%200%20.437.024%201.409.073%202.453.801%202.453%202.064%200%20.996-.705%201.846-2.016%202.016v.049c1.433.097%202.526.898%202.526%202.137%200%201.336-1.215%202.21-2.817%202.21h-6.85v8.986h6.485a4.42%204.42%200%200%200%204.42-4.42V6.519h-6.46Z'/%3e%3cpath%20fill='url(%23c)'%20d='M32.386%2017.91c0-.583-.413-.972-.898-1.045-.049%200-.17-.024-.243-.024h-2.307v2.137h2.307c.073%200%20.218%200%20.243-.024.486-.073.898-.461.898-1.044'/%3e%3cpath%20fill='url(%23d)'%20d='M6.764%206.52a4.42%204.42%200%200%200-4.42%204.42v10.904c1.238.607%202.525.996%203.813.996%201.53%200%202.355-.923%202.355-2.186v-5.149h3.79v5.125c0%201.991-1.24%203.619-5.441%203.619-2.55%200-4.542-.559-4.542-.559v9.302h6.485a4.42%204.42%200%200%200%204.42-4.42V6.519h-6.46Z'/%3e%3cpath%20fill='url(%23e)'%20d='M18.98%206.52a4.42%204.42%200%200%200-4.42%204.42v5.78c1.117-.948%203.06-1.555%206.193-1.409%201.676.073%203.473.534%203.473.534v1.87c-.899-.461-1.967-.874-3.352-.971-2.38-.17-3.813.996-3.813%203.036%200%202.064%201.433%203.23%203.813%203.036%201.385-.098%202.453-.535%203.352-.972v1.87s-1.773.462-3.473.535c-3.133.145-5.076-.462-6.193-1.41V33.04h6.484a4.42%204.42%200%200%200%204.42-4.42V6.52z'/%3e%3cdefs%3e%3clinearGradient%20id='a'%20x1='26.772'%20x2='37.686'%20y1='21.459'%20y2='21.459'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23007940'/%3e%3cstop%20offset='.229'%20stop-color='%2300873f'/%3e%3cstop%20offset='.743'%20stop-color='%2340a737'/%3e%3cstop%20offset='1'%20stop-color='%235cb531'/%3e%3c/linearGradient%3e%3clinearGradient%20id='b'%20x1='26.772'%20x2='37.686'%20y1='19.757'%20y2='19.757'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23007940'/%3e%3cstop%20offset='.229'%20stop-color='%2300873f'/%3e%3cstop%20offset='.743'%20stop-color='%2340a737'/%3e%3cstop%20offset='1'%20stop-color='%235cb531'/%3e%3c/linearGradient%3e%3clinearGradient%20id='c'%20x1='26.772'%20x2='37.686'%20y1='17.907'%20y2='17.907'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23007940'/%3e%3cstop%20offset='.229'%20stop-color='%2300873f'/%3e%3cstop%20offset='.743'%20stop-color='%2340a737'/%3e%3cstop%20offset='1'%20stop-color='%235cb531'/%3e%3c/linearGradient%3e%3clinearGradient%20id='d'%20x1='2.338'%20x2='13.421'%20y1='19.757'%20y2='19.757'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%231f286f'/%3e%3cstop%20offset='.475'%20stop-color='%23004e94'/%3e%3cstop%20offset='.826'%20stop-color='%230066b1'/%3e%3cstop%20offset='1'%20stop-color='%23006fbc'/%3e%3c/linearGradient%3e%3clinearGradient%20id='e'%20x1='14.497'%20x2='25.261'%20y1='19.757'%20y2='19.757'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%236c2c2f'/%3e%3cstop%20offset='.173'%20stop-color='%23882730'/%3e%3cstop%20offset='.573'%20stop-color='%23be1833'/%3e%3cstop%20offset='.859'%20stop-color='%23dc0436'/%3e%3cstop%20offset='1'%20stop-color='%23e60039'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e",MAESTRO:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23000'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23ff000f'%20fill-rule='evenodd'%20d='M15.097%2027.5c4.045%200%207.403-3.358%207.403-7.403%200-4.239-3.358-7.597-7.403-7.597-4.239%200-7.597%203.358-7.597%207.597%200%204.045%203.358%207.403%207.597%207.403'%20clip-rule='evenodd'/%3e%3cpath%20fill='%2300a2e1'%20fill-rule='evenodd'%20d='M25.097%2027.5c4.045%200%207.403-3.358%207.403-7.403%200-4.239-3.358-7.597-7.403-7.597-4.239%200-7.597%203.358-7.597%207.597%200%204.045%203.358%207.403%207.597%207.403'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23e7001a'%20fill-rule='evenodd'%20d='M20.015%2014.42c-1.55%201.383-2.515%203.403-2.515%205.677%200%202.17.966%204.14%202.515%205.503%201.52-1.362%202.485-3.334%202.485-5.503a7.65%207.65%200%200%200-2.485-5.678Z'%20clip-rule='evenodd'%20opacity='.3'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",MASTERCARD:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23000'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23e7001a'%20fill-rule='evenodd'%20d='M15.097%2027.5c4.045%200%207.403-3.358%207.403-7.403%200-4.239-3.358-7.597-7.403-7.597-4.239%200-7.597%203.358-7.597%207.597%200%204.045%203.358%207.403%207.597%207.403'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23f49b1c'%20fill-rule='evenodd'%20d='M25.097%2027.5c4.045%200%207.403-3.358%207.403-7.403%200-4.239-3.358-7.597-7.403-7.597-4.239%200-7.597%203.358-7.597%207.597%200%204.045%203.358%207.403%207.597%207.403'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23e7001a'%20fill-rule='evenodd'%20d='M20.015%2014.42c-1.55%201.383-2.515%203.403-2.515%205.677%200%202.17.966%204.14%202.515%205.503%201.52-1.362%202.485-3.334%202.485-5.503a7.65%207.65%200%200%200-2.485-5.678Z'%20clip-rule='evenodd'%20opacity='.3'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",NYCE:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cg%20clip-path='url(%23b)'%3e%3cpath%20fill='%23ed1a2b'%20d='M34.373%2027.463%2038%2013H5.627L2%2027.463z'/%3e%3cpath%20fill='%23fff'%20d='m12.39%2013-1.101%204.346L9.71%2013H7.406l-1.98%207.898H7.85l1.05-4.323%201.475%204.323h2.356L14.78%2013zm10.474%200h-2.78l-1.85%202.676L17.492%2013h-2.644l1.698%204.995-.708%202.903h2.538l.733-2.92zm11.632%204.847.434-1.729h-3.17l.29-1.152h3.677L36.22%2013h-6.05l-1.98%207.898h6l.425-1.695h-3.627l.34-1.356zm1.92-4.008c0-.292.22-.51.502-.51.278%200%20.496.218.496.51a.495.495%200%200%201-.496.513.497.497%200%200%201-.502-.513m.502.614c.335%200%20.62-.259.62-.614a.61.61%200%200%200-.62-.612.613.613%200%201%200%200%201.226m-.13-.566h.123l.187.307h.12l-.2-.311c.103-.013.183-.068.183-.196%200-.14-.083-.201-.25-.201h-.27v.708h.107zm0-.09v-.22h.147c.074%200%20.154.016.154.104%200%20.11-.082.116-.172.116z'/%3e%3cpath%20fill='%23fff'%20d='M21.152%2017.067c-.627%202.343%201.05%204.244%202.72%204.244%203.29%200%204.112-1.408%204.677-3.294h-2.211c-.326.807-.828%201.37-1.908%201.37-.84%200-1.244-1.039-.901-2.32s1.08-2.319%202.142-2.319c.766%200%201.113.564%201.108%201.37h2.208c.148-1.495-.396-2.689-1.686-3.118h-2.773c-2.158.517-2.86%202.141-3.376%204.067'/%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3cclipPath%20id='b'%3e%3cpath%20fill='%23fff'%20d='M2%2013h36v14.463H2z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",PULSE:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cmask%20id='b'%20width='35'%20height='13'%20x='3'%20y='14'%20maskUnits='userSpaceOnUse'%20style='mask-type:luminance'%3e%3cpath%20fill='%23fff'%20d='M3%2014h34.25v12.454H3z'/%3e%3c/mask%3e%3cg%20mask='url(%23b)'%3e%3cmask%20id='c'%20width='36'%20height='18'%20x='2'%20y='13'%20maskUnits='userSpaceOnUse'%20style='mask-type:luminance'%3e%3cpath%20fill='%23fff'%20d='M2.929%2013.919H37.32V30.12H2.93z'/%3e%3c/mask%3e%3cg%20mask='url(%23c)'%3e%3cpath%20fill='%23231f20'%20fill-rule='evenodd'%20d='m20.897%2023.93%201.284-8.598c.087-.517.04-1.277-.83-1.332h-1.3l-1.486%209.93zm-3.127%200%20.967-6.494h-2.312l-.637%204.29H14.24c-.313%200-.579-.203-.517-.589l.354-2.357c.073-.48.115-1.34-.68-1.344h-1.465l-.643%204.295c-.195%201.437.558%202.199%201.51%202.199zM5.945%2021.72h1.836c.45%200%20.87-.371.93-.82l.081-.547c.102-.547-.256-.881-.706-.881H6.282zm-.33%202.21-.377%202.524c-.025-.009-2.238%200-2.238%200l1.346-9.018H8.68c1.475%200%202.513%201.19%202.318%202.666l-.17%201.13c-.195%201.476-1.573%202.698-3.049%202.698z'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23231f20'%20d='m34.447%2019.748.035-.257a.33.33%200%200%200-.333-.386h-1.792a.46.46%200%200%200-.44.386l-.036.257zm-3.758%204.182c-.884%200-1.564-.718-1.444-1.603l.484-3.245c.12-.884.96-1.646%201.844-1.646h3.672c.896%200%201.523.762%201.403%201.646l-.328%202.194h-4.664l-.096.644h3.793c.587-.005.782.532.707%201.102l-.136.908z'/%3e%3cpath%20fill='%23ee7623'%20d='m6.08%2026.454.236-1.658h29.482l-.139.967c-.074.47-.315.69-.694.69z'/%3e%3cpath%20fill='%23231f20'%20d='M24.085%2017.436c-.83%200-1.509.732-1.64%201.614l-.122.808c-.112.854.348%201.571%201.139%201.614q.037.003.076.003h2.848l-.072.448h-3.21c-.576.002-1.138.058-1.21.639l-.21%201.368h5.164c.85%200%201.644-.565%201.76-1.446l.167-1.11c.116-.88-.49-1.616-1.341-1.616H24.47l.055-.418h3.383c.853%200%201.118-.105%201.234-.739l.174-1.165z'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",STAR:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23ba0c2f'%20d='M35.957%2028.373c-.021-.062-.064-.104-.106-.146-.043-.042-.086-.084-.15-.104-.064-.021-.106-.042-.17-.042s-.128%200-.171.042c-.064.02-.107.062-.15.104a.4.4%200%200%200-.106.146c-.021.063-.043.105-.043.167s0%20.126.043.167a.36.36%200%200%200%20.107.146.4.4%200%200%200%20.149.105c.064.02.107.042.17.042.065%200%20.107%200%20.171-.042a.4.4%200%200%200%20.15-.105c.042-.041.064-.083.106-.146.022-.062.043-.104.043-.167%200-.062%200-.125-.043-.167m-.042.334c0%20.042-.043.084-.086.125a.4.4%200%200%201-.128.084c-.042%200-.106.02-.149.02s-.107%200-.15-.02c-.042%200-.085-.042-.127-.084-.043-.041-.064-.083-.086-.125%200-.041-.021-.104-.021-.146s0-.104.021-.146c0-.042.043-.084.086-.125a.4.4%200%200%201%20.128-.084c.042%200%20.106-.02.149-.02a.4.4%200%200%201%20.15.02c.042%200%20.085.042.127.084.043.041.064.083.086.125%200%20.042.021.104.021.146s0%20.105-.021.146m-17.558-7.954c-.17-.773%200-1.504%200-1.504h-8.32s-2.154-.396-3.328-.104c-.853.209-2.176.689-2.517%202.276-.277%201.315.384%202.213.853%202.651.47.418%202.624%201.316%202.774%201.357.234.084%201.173.543.938%201.504-.192.73-1.173.918-1.408.918s-1.813.126-2.24-1.482h-.597S4.491%2027.12%204%2028.31c0%200%20.832.71%202.987.689.128%200%202.602%200%203.669-1.775%201.173-1.984-.533-3.362-.533-3.362-.704-.605-2.795-1.44-2.795-1.44-1.664-.647-1.003-2.109-.15-2.234.79-.105%201.494-.084%202.817.543%200%200%202.218-.272%202.816-.188v8.31s.981-.21%202.709%200v-8.29c.49-.104%202.816.21%202.816.21zm17.43%207.683c0-.042%200-.084-.064-.105-.043-.02-.086-.041-.171-.041h-.192v.5h.085v-.229h.107l.107.23h.106l-.106-.23c.042%200%20.064-.02.085-.042a.16.16%200%200%200%20.043-.083m-.128.063h-.192v-.168h.085c.043%200%20.085%200%20.107.021.021%200%20.042.042.042.063s0%20.042-.021.063l-.021.02ZM17.632%2014.405c4.736-.73%207.36-.605%207.36-.605v-.439s-5.93.126-10.39.794C5.494%2015.49%204%2018.143%204%2018.143h6.57s1.153-2.819%207.062-3.738m16.085%207.162c0-2.568-3.498-2.318-3.498-2.318h-4.054v9.02l-4.288-9.145s-.832.104-1.365%200c0%200-4.608%209.688-4.63%209.688.833-.146%201.857%200%201.857%200l1.13-2.777h3.392l1.11%202.818s1.344-.25%202.858%200c.896-.208%202.688-.02%202.688-.02v-4.05l2.731%204.07c1.579-.23%203.264%200%203.264%200l-3.456-4.655s2.304-.439%202.304-2.59zm-14.293%203.278%201.173-2.568%201.152%202.568zm11.307-1.984c-.47.835-1.878.752-1.878.752v-3.32s1.43-.167%201.835.501c.555.919.043%202.067.043%202.067M30.112%2010l-1.13%203.382h-3.649l2.966%202.026-1.174%203.361%202.987-2.109%202.987%202.088-1.174-3.34%202.966-2.026h-3.67z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",UNION_PAY:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23e21836'%20d='M9.037%208.75h8.969c1.252%200%202.03%201.02%201.738%202.277L15.57%2028.954c-.295%201.252-1.548%202.273-2.801%202.273H3.8c-1.25%200-2.03-1.02-1.739-2.273L6.24%2011.027C6.53%209.77%207.784%208.75%209.037%208.75'/%3e%3cpath%20fill='%2300447c'%20d='M17.26%208.75h10.314c1.252%200%20.687%201.02.393%202.277l-4.175%2017.927c-.293%201.252-.202%202.273-1.456%202.273H12.022c-1.255%200-2.031-1.02-1.736-2.273l4.175-17.927c.296-1.256%201.546-2.277%202.799-2.277'/%3e%3cpath%20fill='%23007b84'%20d='M27.165%208.75h8.968c1.254%200%202.033%201.02%201.738%202.277l-4.175%2017.927c-.294%201.252-1.549%202.273-2.802%202.273h-8.965c-1.254%200-2.032-1.02-1.738-2.273l4.175-17.927c.292-1.256%201.544-2.277%202.799-2.277'/%3e%3cpath%20fill='%23fefefe'%20d='M11.38%2014.495c-.923.01-1.195%200-1.282-.02-.034.159-.656%203.03-.658%203.032-.134.581-.231.995-.562%201.262a1%201%200%200%201-.662.23c-.41%200-.648-.202-.688-.587l-.007-.133.124-.782s.653-2.616.77-2.962l.01-.04c-1.272.012-1.497%200-1.513-.02-.008.028-.04.19-.04.19l-.667%202.95-.057.25-.11.817c0%20.243.047.44.142.608.304.531%201.17.61%201.66.61.633%200%201.225-.133%201.626-.378.695-.411.877-1.053%201.04-1.624l.074-.293s.673-2.717.787-3.07c.005-.02.007-.03.012-.04Zm2.289%202.193a1.8%201.8%200%200%200-.725.17c-.097.049-.188.106-.284.163l.087-.314-.048-.053c-.565.115-.691.13-1.213.203l-.043.03c-.06.502-.115.88-.34%201.866q-.128.548-.262%201.094l.024.046c.534-.028.696-.028%201.16-.02l.038-.041c.06-.303.067-.373.198-.986.061-.29.19-.928.253-1.155.116-.054.23-.107.34-.107.26%200%20.228.227.218.318-.011.152-.106.648-.203%201.074l-.065.275c-.045.203-.095.4-.14.602l.02.04c.526-.028.687-.028%201.137-.02l.053-.041c.081-.473.105-.599.25-1.286l.072-.316c.14-.619.212-.932.105-1.187-.113-.286-.383-.355-.632-.355m2.558.647c-.28.053-.46.09-.637.113-.176.028-.347.053-.618.09l-.021.02-.02.016c-.028.201-.048.376-.085.58-.032.212-.08.453-.16.799a3%203%200%200%201-.128.45c-.034.093-.072.184-.141.444l.016.024.014.022c.253-.012.418-.02.588-.022.17-.006.346%200%20.618.002l.024-.02.026-.021c.04-.235.045-.298.07-.413.023-.123.064-.293.165-.747l.15-.644.156-.644-.007-.025zm.005-.873c-.254-.15-.7-.102-1.001.105-.3.203-.334.492-.08.644.25.146.698.103.996-.107.299-.207.336-.493.085-.642m1.54%203.478c.514%200%201.042-.142%201.44-.563.305-.341.445-.85.493-1.058.158-.694.035-1.018-.12-1.215-.234-.3-.649-.397-1.08-.397-.258%200-.875.026-1.356.47-.346.32-.506.755-.602%201.171-.098.425-.21%201.19.493%201.474.217.093.53.118.731.118Zm-.04-1.56c.118-.525.258-.966.616-.966.28%200%20.3.328.176.855-.023.117-.125.552-.263.737-.097.136-.211.22-.338.22-.037%200-.261%200-.264-.333a2.3%202.3%200%200%201%20.072-.513Zm3.26%201.493.04-.041c.058-.303.067-.374.193-.986.063-.29.194-.928.256-1.155.116-.054.229-.107.341-.107.259%200%20.227.227.217.318-.01.152-.104.648-.203%201.074l-.061.275c-.047.203-.099.4-.144.602l.02.04a12%2012%200%200%201%201.135-.02l.055-.041c.08-.473.1-.599.25-1.286l.07-.316c.142-.619.214-.932.109-1.187-.116-.286-.389-.355-.634-.355-.162%200-.46.039-.725.17-.095.049-.19.106-.283.163l.082-.314-.044-.053c-.564.115-.693.13-1.214.203l-.04.03c-.063.502-.115.879-.34%201.866a121%20121%200%200%201-.262%201.094l.024.046c.535-.028.695-.028%201.158-.02m3.884.02c.033-.162.23-1.123.232-1.123%200%200%20.168-.706.179-.732%200%200%20.053-.073.106-.102h.077c.735%200%201.564%200%202.214-.478.442-.328.744-.812.88-1.4.034-.145.06-.317.06-.488%200-.226-.045-.449-.176-.623-.331-.464-.991-.472-1.753-.476l-.376.004c-.975.012-1.366.008-1.527-.011l-.039.197-.35%201.622-.874%203.604c.851-.01%201.2-.01%201.347.006m.647-2.876.37-1.61.012-.082.005-.064.149.016.784.067c.302.117.427.419.34.812a1.18%201.18%200%200%201-.613.808c-.247.124-.549.134-.86.134h-.202zm2.313%201.393c-.098.418-.211%201.183.488%201.455.223.095.423.123.626.113.215-.012.413-.12.597-.274l-.05.19.032.042c.503-.021.66-.021%201.204-.017l.05-.038c.08-.468.154-.922.361-1.817q.15-.642.305-1.28l-.016-.047c-.563.104-.713.127-1.255.203l-.04.034-.017.127a.77.77%200%200%200-.395-.325c-.24-.094-.806.028-1.292.47-.341.316-.505.749-.598%201.164m1.182.026c.12-.516.258-.953.617-.953.227%200%20.346.21.322.566l-.065.29q-.055.228-.113.457a1.1%201.1%200%200%201-.132.267c-.092.13-.312.212-.438.212-.036%200-.257%200-.265-.326a2.2%202.2%200%200%201%20.074-.514Zm6.171-1.703-.043-.05c-.557.113-.658.13-1.17.2l-.037.038-.006.024-.002-.009c-.38.879-.37.69-.68%201.38l-.003-.084-.078-1.5-.048-.049c-.584.113-.597.13-1.136.2l-.042.038c-.006.017-.006.037-.01.059l.004.007c.067.344.051.268.119.81.031.267.073.535.105.798.053.44.083.658.148%201.33-.364.6-.45.827-.8%201.354l.002.005-.247.39c-.028.041-.053.07-.09.082a.4.4%200%200%201-.16.023h-.137l-.204.675.697.012c.41-.002.666-.193.805-.45l.438-.75h-.007l.046-.053c.294-.635%202.536-4.48%202.536-4.48m-7.353%208.871h-.296l1.094-3.618h.363l.115-.373.011.415c-.013.256.188.483.718.446h.612l.211-.697h-.23q-.198.002-.187-.105l-.01-.422h-1.135v.002c-.366.008-1.461.036-1.683.095-.268.069-.55.272-.55.272l.11-.373h-1.06l-.221.74-1.109%203.674h-.215l-.211.691h2.113l-.071.231h1.04l.07-.23h.292zm-.867-2.883c-.17.047-.486.19-.486.19l.281-.925h.843l-.203.674s-.26.015-.435.061m.016%201.322s-.264.033-.439.072a4%204%200%200%200-.493.216l.29-.962h.847zm-.472%201.57h-.845l.245-.812h.843zm2.036-2.244h1.218l-.175.567h-1.234l-.186.62h1.08l-.817%201.152a.34.34%200%200%201-.166.138.5.5%200%200%201-.22.063h-.3l-.205.68h.784c.407%200%20.648-.186.826-.43l.56-.767.12.78c.026.145.131.23.203.264.078.04.159.107.274.117q.182.009.27.01h.385l.232-.76h-.152c-.087%200-.238-.015-.263-.043-.026-.033-.026-.084-.04-.162l-.122-.781h-.5l.22-.261h1.232l.19-.62H30.62l.178-.567h1.137l.211-.7h-3.39zM18.257%2025.77l.284-.946h1.17l.213-.704h-1.17l.179-.582h1.143l.212-.682h-2.86l-.208.682h.65l-.174.582h-.652l-.216.716h.65l-.379%201.252c-.051.165.024.228.072.305a.31.31%200%200%200%20.21.153c.114.026.192.041.299.041h1.318l.234-.78-.584.08c-.113%200-.425-.013-.39-.117Zm.134-4.53-.296.536a.6.6%200%200%201-.172.223q-.069.041-.265.04h-.154l-.207.685h.514c.246%200%20.436-.09.526-.136.098-.052.123-.022.198-.095l.174-.15h1.603l.212-.713h-1.173l.205-.39zm2.367%204.544c-.028-.04-.008-.11.034-.253l.438-1.45h1.558c.227-.004.391-.006.498-.014q.172-.017.375-.126a.7.7%200%200%200%20.272-.252c.068-.092.176-.296.27-.61l.55-1.834-1.617.01s-.498.073-.717.154c-.222.09-.538.343-.538.343l.146-.503h-.999l-1.398%204.639q-.077.27-.091.389c-.003.085.107.168.177.232.084.063.208.052.327.063.125.01.302.015.547.015h.768l.235-.796-.687.065a.18.18%200%200%201-.148-.072m.754-2.683h1.637l-.104.326c-.014.008-.05-.016-.216.004h-1.417zm.328-1.094h1.651l-.119.393s-.778-.008-.902.015c-.549.095-.869.388-.869.388l.24-.796Zm1.242%202.513a.18.18%200%200%201-.065.1q-.048.031-.167.03h-.234l.014-.398h-.97l-.04%201.942c0%20.14.013.221.115.286.103.081.419.092.844.092h.608l.22-.727-.53.029-.176.01a.2.2%200%200%201-.073-.045c-.022-.022-.06-.009-.053-.149l.004-.497.555-.023c.3%200%20.428-.098.537-.19.104-.09.138-.192.178-.33l.093-.441h-.763z'/%3e%3c/svg%3e",VISA:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%231b16e6'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20fill-rule='evenodd'%20d='M19.912%2018.197c-.018%201.393%201.253%202.17%202.21%202.632.983.475%201.313.779%201.31%201.203-.008.649-.785.935-1.512.946-1.269.02-2.006-.339-2.593-.61l-.457%202.119c.588.268%201.678.503%202.808.513%202.652%200%204.386-1.297%204.396-3.309.01-2.552-3.563-2.693-3.539-3.834.009-.346.342-.715%201.072-.81.361-.047%201.359-.083%202.49.433l.443-2.05a6.8%206.8%200%200%200-2.362-.43c-2.496%200-4.252%201.315-4.266%203.197m10.893-3.02c-.484%200-.892.28-1.074.71l-3.788%208.963h2.65l.527-1.445h3.239l.305%201.444H35l-2.038-9.672zm.372%202.613.765%203.632h-2.094zM16.7%2015.177l-2.09%209.672h2.526l2.088-9.672zm-3.736%200-2.628%206.583-1.064-5.598c-.124-.625-.617-.985-1.164-.985H3.81l-.06.28c.882.19%201.884.496%202.491.823.372.2.478.375.6.85l2.013%207.72h2.67l4.091-9.673h-2.652Z'%20clip-rule='evenodd'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e",V_PAY:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%231c3378'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%231c3378'%20d='M38.753%200H2v39.754h36.753z'/%3e%3cpath%20fill='%23fff'%20d='M36.957%2025.94H2.043V1.04h34.914z'/%3e%3cpath%20fill='%231c3378'%20d='m28.331%205.56-6.85%2016.327h-4.476L13.634%208.855c-.203-.8-.383-1.095-1.003-1.436-1.021-.547-2.7-1.065-4.176-1.388l.099-.47h7.197c.918%200%201.744.608%201.952%201.66l1.784%209.448%204.4-11.108h4.444Z'/%3e%3cpath%20fill='%23fff'%20d='M11.773%2032.32c.163.045.38.058.65.058.994%200%201.601-.51%201.601-1.398%200-.844-.561-1.295-1.484-1.295a3.5%203.5%200%200%200-.767.07zm-1.318-3.535c.476-.09%201.136-.157%202.034-.157.974%200%201.685.213%202.15.619.433.371.714.966.714%201.68%200%20.717-.217%201.313-.628%201.72-.53.55-1.361.81-2.302.81-.246%200-.476-.014-.65-.046v2.862h-1.318zm9.903%204.29-.572-1.869c-.142-.461-.26-.98-.369-1.42h-.021c-.107.44-.217.972-.345%201.42l-.562%201.87h1.87Zm-2.085%201.046-.628%202.152h-1.372l2.334-7.59h1.698l2.369%207.59h-1.428l-.66-2.152zm7.2%202.152v-3.166l-2.302-4.423h1.51l.878%201.946c.248.566.43.99.628%201.51h.019c.184-.485.393-.958.639-1.51l.877-1.946h1.502l-2.422%204.391v3.198z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},pL={class:"flex h-full grow flex-col justify-center"},hL=e.defineComponent({__name:"PaymentMethodCard",props:{paymentMethod:{},isDefault:{type:Boolean},i18n:{},options:{},variant:{default:"default"}},setup(t){const n=t,r=e.computed(()=>{var e,t,r;return(null==(e=n.i18n)?void 0:e.expiryDate)&&n.paymentMethod.card.expiry_date?n.i18n.expiryDate(n.paymentMethod.card.expiry_date.expiry_month,n.paymentMethod.card.expiry_date.expiry_year):n.paymentMethod.card.expiry_date?`Expiry date: ${null==(t=n.paymentMethod.card.expiry_date)?void 0:t.expiry_month}/${null==(r=n.paymentMethod.card.expiry_date)?void 0:r.expiry_year}`:void 0}),o=e.computed(()=>n.paymentMethod.card.brand?uL[n.paymentMethod.card.brand]:X$);return(n,i)=>{var a;return e.openBlock(),e.createBlock(iL,{"image-src":o.value,"image-alt":null==(a=t.paymentMethod.card.brand)?void 0:a.toLowerCase(),variant:t.variant,options:t.options,"is-inactive":"INACTIVE"===t.paymentMethod.status},{default:e.withCtx(()=>[e.createElementVNode("div",pL,[e.createVNode(gc,{tag:"span",variant:"condensed"===t.variant?"body-xs":"body-sm",shade:"condensed"===t.variant?"light":void 0,weight:"semibold","no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(" **** **** **** "+e.toDisplayString(t.paymentMethod.card.last_four_digits??"****"),1)]),_:1},8,["variant","shade"]),"default"===t.variant&&r.value?(e.openBlock(),e.createBlock(gc,{key:0,tag:"span",variant:"body-xs",shade:"lighter","no-spacing":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value),1)]),_:1})):e.createCommentVNode("",!0),e.createVNode(aL,{"is-default":t.isDefault},null,8,["is-default"]),e.createVNode(lL,{"is-inactive":"INACTIVE"===t.paymentMethod.status},null,8,["is-inactive"])])]),_:1},8,["image-src","image-alt","variant","options","is-inactive"])}}}),mL={AMAZON_PAY:{name:"Amazon Pay",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20fill-rule='evenodd'%20clip-path='url(%23a)'%20clip-rule='evenodd'%3e%3cpath%20fill='%23f3f6f9'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23232f3e'%20d='M5.923%2021.696a.13.13%200%200%201-.154.016c-.218-.18-.257-.265-.376-.437-.36.367-.614.476-1.08.476-.551%200-.98-.34-.98-1.02%200-.532.29-.894.696-1.071.356-.155.852-.184%201.231-.227v-.084c0-.156.013-.34-.08-.476-.08-.12-.231-.17-.367-.17-.25%200-.472.128-.526.394a.14.14%200%200%201-.116.12l-.631-.069a.116.116%200%200%201-.097-.137c.146-.77.842-1.002%201.465-1.002.319%200%20.735.084.985.326.318.298.29.695.29%201.127v1.02c0%20.307.128.441.248.607.042.058.051.13%200%20.173-.134.113-.372.319-.502.435zm-.66-1.596c0%20.255.006.467-.122.695-.104.185-.27.298-.454.298-.251%200-.398-.191-.398-.475%200-.558.5-.66.974-.66zm2.454%201.57h-.654a.12.12%200%200%201-.116-.11v-3.362a.124.124%200%200%201%20.125-.12h.61a.12.12%200%200%201%20.116.115v.44h.013c.158-.426.458-.623.862-.623s.666.197.849.623a.967.967%200%200%201%201.666-.258c.208.282.165.695.165%201.053v2.121a.13.13%200%200%201-.038.087.12.12%200%200%201-.088.035h-.655a.12.12%200%200%201-.116-.12v-1.784c0-.141.013-.494-.018-.629-.05-.227-.196-.29-.385-.29a.43.43%200%200%200-.392.275c-.066.171-.061.454-.061.644v1.782a.123.123%200%200%201-.126.121h-.656a.123.123%200%200%201-.116-.12v-1.783c0-.374.058-.927-.406-.927-.463%200-.452.537-.452.927v1.782a.124.124%200%200%201-.127.122m7.296-.583c-.12-.166-.246-.3-.246-.607v-1.02c0-.433.03-.83-.29-1.128-.252-.24-.668-.325-.986-.325-.623%200-1.319.231-1.465%201.002a.116.116%200%200%200%20.098.137l.635.069a.14.14%200%200%200%20.116-.121c.055-.265.276-.393.526-.393.135%200%20.29.05.368.17.092.135.08.319.08.475v.083c-.38.042-.877.071-1.232.226-.41.178-.698.539-.698%201.072%200%20.68.429%201.02.98%201.02.464%200%20.72-.11%201.08-.476.119.174.158.256.375.436a.13.13%200%200%200%20.155-.015%2028%2028%200%200%201%20.502-.435c.056-.04.046-.11.002-.17m-1.286-.294c-.103.183-.269.297-.453.297-.25%200-.397-.191-.397-.475%200-.558.5-.66.973-.66v.142c0%20.256.005.468-.123.696m1.841-2.126v-.48a.116.116%200%200%201%20.123-.122h2.152a.12.12%200%200%201%20.124.121v.412c0%20.07-.058.16-.162.302l-1.115%201.592c.413-.01.851.053%201.228.264.07.037.113.109.115.187v.515c0%20.07-.076.153-.158.11a2.48%202.48%200%200%200-2.274.004c-.075.04-.154-.04-.154-.111v-.49a.6.6%200%200%201%20.08-.33l1.293-1.855h-1.127a.12.12%200%200%201-.125-.121m4.257.026c-.482%200-.513.658-.513%201.068s-.006%201.286.507%201.286.532-.706.532-1.138c0-.282-.012-.622-.098-.891-.073-.231-.22-.325-.428-.325m-.006-.686c.972%200%201.498.834%201.498%201.895%200%201.026-.58%201.84-1.498%201.84-.953%200-1.473-.835-1.473-1.875s.525-1.86%201.473-1.86m2.766%203.659h-.654a.123.123%200%200%201-.116-.12V18.18a.123.123%200%200%201%20.127-.11h.607c.055.002.103.04.116.094v.514h.013c.182-.46.44-.678.892-.678.293%200%20.58.107.765.396.17.269.17.722.17%201.047v2.115a.13.13%200%200%201-.125.106h-.659a.12.12%200%200%201-.116-.106v-1.825c0-.367.043-.905-.41-.905a.43.43%200%200%200-.379.269c-.091.205-.103.41-.103.638v1.809a.126.126%200%200%201-.128.12m5.328-3.083a1.53%201.53%200%200%200-.92.316v1.914q.44.33.906.329.947%200%20.947-1.275t-.933-1.284m-.968-.089c.164-.145.353-.26.556-.343.192-.076.397-.116.604-.116.206-.004.41.038.598.12.177.082.332.204.452.358.132.17.228.364.286.57q.104.37.1.754c.002.26-.034.52-.107.768-.061.212-.163.41-.299.584a1.4%201.4%200%200%201-.467.375%201.4%201.4%200%200%201-.61.128%201.53%201.53%200%200%201-1.065-.406v1.61a.122.122%200%200%201-.137.137h-.405a.12.12%200%200%201-.133-.082.1.1%200%200%201-.005-.056v-4.62a.12.12%200%200%201%20.082-.132.1.1%200%200%201%20.056-.006h.302a.145.145%200%200%201%20.158.138zm4.308%202.7q.244-.002.474-.088.255-.094.473-.261v-.701a3.3%203.3%200%200%200-.727-.09q-.777%200-.777.599%200%20.26.145.401.144.14.412.14m-.804-2.459-.052.018a.2.2%200%200%201-.058.01q-.087%200-.089-.124v-.184a.23.23%200%200%201%20.027-.133.3.3%200%200%201%20.11-.073%202.5%202.5%200%200%201%20.542-.152q.32-.057.646-.057.652%200%20.96.267.31.267.31.83v2.346a.123.123%200%200%201-.137.138h-.296a.14.14%200%200%201-.103-.033.14.14%200%200%201-.048-.098l-.034-.227q-.245.212-.546.33a1.6%201.6%200%200%201-.594.116q-.494%200-.783-.278-.287-.28-.29-.746%200-.5.357-.8.358-.298.962-.298.439.006.864.116v-.451q0-.372-.164-.522-.165-.15-.577-.151a3.6%203.6%200%200%200-1.007.156m4.631%203.494q-.186.474-.43.68-.243.206-.637.206a1.5%201.5%200%200%201-.392-.048.2.2%200%200%201-.11-.066.23.23%200%200%201-.034-.14v-.179q0-.13.103-.13.053.003.103.013.092.015.186.014a.6.6%200%200%200%20.405-.124q.145-.123.261-.453l.13-.348-1.322-3.27a.5.5%200%200%201-.048-.165q0-.082.096-.082h.412a.24.24%200%200%201%20.151.034q.059.067.082.151l.962%202.664.927-2.664a.4.4%200%200%201%20.082-.151.25.25%200%200%201%20.151-.034h.385q.096%200%20.096.082a.5.5%200%200%201-.048.165z'/%3e%3cpath%20fill='%23f90'%20d='M16.456%2022.989c-1.23.907-3.014%201.391-4.547%201.391a8.23%208.23%200%200%201-5.554-2.119c-.116-.103-.013-.246.126-.165%201.582.92%203.536%201.475%205.557%201.475a11.1%2011.1%200%200%200%204.24-.87c.207-.088.382.137.178.29m.511-.584c.158.201-.173%201.031-.322%201.402-.046.112.051.157.153.072.659-.552.83-1.708.695-1.874-.133-.167-1.286-.309-1.99.186-.109.076-.09.18.03.166.396-.048%201.278-.154%201.436.048'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},APPLE_PAY:{name:"Apple Pay",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23000'%20d='M31.367%2011H8.35l-.24.004a3.4%203.4%200%200%200-.52.047%201.66%201.66%200%200%200-1.223.905%201.8%201.8%200%200%200-.163.502%204%204%200%200%200-.046.529q-.003.12-.003.243v13.54l.003.242c.005.177.015.354.046.529q.045.264.163.503a1.68%201.68%200%200%200%201.223.904c.172.032.347.042.52.047q.263.007.524.004h23.017l.239-.004c.173-.005.349-.015.52-.046a1.66%201.66%200%200%200%201.223-.906c.081-.16.132-.325.163-.502.032-.175.042-.352.046-.529q.004-.12.004-.242V13.23q0-.122-.004-.243a4%204%200%200%200-.046-.529%201.7%201.7%200%200%200-.89-1.242%201.7%201.7%200%200%200-.495-.165%203.4%203.4%200%200%200-.521-.047l-.24-.003z'/%3e%3cpath%20fill='%23fff'%20d='M31.368%2011.6h.28q.112%200%20.227.004c.132.003.287.01.432.037a1.07%201.07%200%200%201%20.801.587%201.2%201.2%200%200%201%20.108.337c.026.145.033.302.036.438l.004.23v13.534q0%20.115-.004.23a3%203%200%200%201-.037.44q-.03.176-.107.335a1.08%201.08%200%200%201-.8.586%203%203%200%200%201-.43.038l-.231.003H8.354q-.115%200-.226-.003a3%203%200%200%201-.432-.037%201.2%201.2%200%200%201-.333-.11%201.06%201.06%200%200%201-.468-.477%201.2%201.2%200%200%201-.108-.337%203%203%200%200%201-.037-.438l-.004-.23V13.233q0-.116.004-.23a3%203%200%200%201%20.037-.44c.022-.127.056-.233.108-.336a1.08%201.08%200%200%201%20.8-.586c.145-.026.3-.034.433-.037l.227-.004z'/%3e%3cpath%20fill='%23000'%20d='M13.714%2016.963c.237-.297.398-.695.356-1.102-.347.018-.77.23-1.016.526-.22.254-.415.67-.364%201.059.39.034.779-.195%201.024-.483m.352.559c-.566-.034-1.047.32-1.318.32-.27%200-.684-.303-1.131-.295a1.67%201.67%200%200%200-1.419.862c-.608%201.048-.16%202.602.431%203.456.287.422.633.887%201.09.87.43-.017.599-.279%201.122-.279s.676.279%201.132.27c.473-.008.768-.422%201.055-.844.33-.482.465-.947.473-.972-.008-.009-.912-.355-.92-1.394-.009-.87.71-1.284.743-1.31-.405-.6-1.039-.667-1.258-.684m4.926-1.178c1.23%200%202.086.848%202.086%202.082%200%201.238-.874%202.09-2.117%202.09h-1.362v2.166h-.984v-6.338zm-1.393%203.347h1.129c.856%200%201.344-.461%201.344-1.26%200-.8-.488-1.257-1.34-1.257H17.6zm3.735%201.679c0-.809.62-1.305%201.718-1.367l1.264-.074v-.356c0-.514-.347-.821-.926-.821-.55%200-.892.263-.976.676h-.896c.053-.835.765-1.45%201.907-1.45%201.12%200%201.836.594%201.836%201.52v3.185h-.91v-.76h-.021c-.268.514-.852.839-1.459.839-.904%200-1.537-.562-1.537-1.392m2.982-.418v-.364l-1.137.07c-.567.04-.887.29-.887.685%200%20.404.333.668.843.668.663%200%201.181-.457%201.181-1.059m1.803%203.429v-.768c.07.017.228.017.307.017.44%200%20.677-.184.822-.659%200-.008.083-.28.083-.285l-1.669-4.626h1.028l1.168%203.76h.018l1.168-3.76h1.002l-1.731%204.863c-.395%201.12-.852%201.48-1.81%201.48-.079%200-.316-.009-.386-.022'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},CASH_APP:{name:"Cash App",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%2300ce32'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20d='M20.647%2015.6a5.27%205.27%200%200%201%203.409%201.261c.204.187.517.18.714-.014l.982-.993a.51.51%200%200%200-.027-.743%207.8%207.8%200%200%200-2.624-1.481l.294-1.46a.52.52%200%200%200-.282-.57.5.5%200%200%200-.221-.05h-1.89a.515.515%200%200%200-.502.406l-.264%201.306c-2.516.125-4.65%201.38-4.65%203.955%200%202.225%201.764%203.182%203.627%203.85%201.763.662%202.698.907%202.698%201.838%200%20.93-.932%201.516-2.304%201.516a5.05%205.05%200%200%201-3.582-1.413.51.51%200%200%200-.717%200l-1.053%201.037a.515.515%200%200%200%200%20.738%206.95%206.95%200%200%200%203.042%201.68l-.294%201.353a.53.53%200%200%200%20.5.634h1.895a.515.515%200%200%200%20.506-.409l.273-1.282c3.015-.187%204.858-1.822%204.858-4.216%200-2.204-1.837-3.134-4.068-3.892-1.275-.483-2.377-.8-2.377-1.754s1.029-1.297%202.057-1.297'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},DANA:{name:"DANA",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23108ee9'%20fill-rule='evenodd'%20d='M4.1%2015.7c0-2.48%201.974-4.49%204.411-4.49s4.411%202.01%204.411%204.49c0%202.479-1.976%204.49-4.411%204.49S4.1%2018.18%204.1%2015.7m3.227-1.007c.404-.062.778-.219%201.155-.36.308-.116.616-.236.931-.325.54-.153%201.064-.112%201.543.216.088.061.135.14.135.247v2.496c0%20.1-.036.12-.123.07a1.83%201.83%200%200%200-1.188-.267q-.435.05-.847.197c-.314.108-.628.219-.944.323a3.3%203.3%200%200%201-.874.174%201.8%201.8%200%200%201-1.071-.282.24.24%200%200%201-.112-.216l.002-1.354v-.632q-.002-.255%200-.511c0-.03.013-.07.033-.085.016-.011.058.004.083.02a1.67%201.67%200%200%200%20.979.312q.15-.002.3-.023m12.758.658c.024-1.056.87-1.905%201.913-1.905s1.89.848%201.913%201.905l.001%202.631h-.956v-.971H21.04v.971h-.956v-2.631zm.955.038v.647h1.916v-.646a.967.967%200%200%200-.958-.969.966.966%200%200%200-.958.97m10.033-.038c.023-1.056.87-1.905%201.913-1.905s1.888.848%201.913%201.905l.001%202.631h-.958v-.971H32.03v.971h-.958v-2.633zm.955.038v.647h1.914v-.648a.966.966%200%200%200-.956-.969.967.967%200%200%200-.958.97m-6.445-.038c.023-1.056.869-1.905%201.91-1.905%201.042%200%201.89.848%201.914%201.905h.003v2.632h-.958V15.39a.966.966%200%200%200-.958-.969.964.964%200%200%200-.956.97h-.001v2.593h-.956v-2.633zm-9.408-1.904.018-.001h.089l-.012.004c1.194.042%202.15%201.038%202.15%202.264%200%201.229-.96%202.226-2.156%202.265l.018.004h-1.69v-4.538h1.583m-.628.973v.182h.003v2.224h-.003v.18h.728a1.285%201.285%200%200%200%201.189-1.291c0-.686-.528-1.249-1.195-1.29z'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23d8d8d8'%20d='M34.9%2022.08H4.1v.22h30.8z'/%3e%3cpath%20fill='%233e3a3a'%20fill-rule='evenodd'%20d='M12.313%2026.557c0-.064.013-.128.064-.178.08-.08.238-.141.6-.226v.545c-.18.097-.281.136-.4.136-.162%200-.264-.107-.264-.277m-1.984-1.11c.251%200%20.451.2.451.626%200%20.544-.293.787-.621.787a.7.7%200%200%201-.23-.034v-1.235a.66.66%200%200%201%20.4-.144m5.715-.473.004-.005h-.633l-.4%201.387h-.022l-.46-1.386h-.753l.907%202.29-.379.697v.017h.592zm-7.91%202.277h.672v-2.28h-.672zm4.923%200h.673l-.08-.57v-.954c0-.519-.308-.804-.848-.804-.344%200-.583.06-1.017.192l.119.523c.396-.178.57-.255.753-.255.221%200%20.32.157.32.4v.017c-.77.144-1.01.225-1.158.374-.111.111-.157.268-.157.45%200%20.439.34.673.66.673.238%200%20.43-.09.69-.285zm-2.735.03c.6%200%201.14-.443%201.14-1.23%200-.706-.391-1.128-.876-1.128-.247%200-.438.094-.656.273v-.226h-.672v3.005h.672v-.745c.128.033.247.051.392.051m-5.477-1.108.4-1.383h.017l.378%201.383zm-.932%201.077h.622l.17-.588h1.068l.162.588h.795l-.906-3h-.902zm3.089%200h.672v-3.107h-.672z'%20clip-rule='evenodd'/%3e%3cpath%20fill='%231677ff'%20fill-rule='evenodd'%20d='M8.083%2024.42c0%20.222.162.37.388.37.225%200%20.387-.148.387-.37%200-.216-.162-.37-.387-.37-.226%200-.388.154-.388.37m10.662-.276c.202%200%20.367.165.367.368v1.16h1.16c.202%200%20.367.163.367.367v.393h-1.527a.75.75%200%200%201-.397-.112l-.021-.013a.7.7%200%200%201-.168-.152l-.016-.018-.009-.012a.8.8%200%200%201-.11-.21l-.014-.045a.8.8%200%200%201-.026-.198v-1.528z'%20clip-rule='evenodd'/%3e%3cpath%20fill='%2300b6ff'%20fill-rule='evenodd'%20d='M17.98%2026.432h-.789a.37.37%200%200%201-.367-.367v-.394h1.156zm.37%201.158v-.785h.762v1.153h-.394a.37.37%200%200%201-.367-.367'%20clip-rule='evenodd'/%3e%3cpath%20fill='%233e3a3a'%20fill-rule='evenodd'%20d='M22.688%2025.48v.617h.4a.35.35%200%200%200%20.236-.078q.09-.078.09-.232t-.09-.231a.36.36%200%200%200-.237-.076zm.412-.149q.104%200%20.192.033.09.033.153.092.065.06.099.143.036.09.035.189%200%20.105-.035.189a.4.4%200%200%201-.1.144.5.5%200%200%201-.345.126h-.412v.639h-.166V25.33zm1.406%201.059h.578l-.288-.823zm.93.494h-.177l-.125-.35h-.678l-.125.35h-.176l.571-1.553h.14zm.984-1.404v.57h.414a.35.35%200%200%200%20.223-.07q.087-.069.086-.213%200-.144-.086-.215a.34.34%200%200%200-.223-.07h-.415zm.43-.149q.1%200%20.185.03t.147.085q.06.055.094.136a.5.5%200%200%201%20.034.18.4.4%200%200%201-.093.279.43.43%200%200%201-.244.138l.368.704h-.194l-.354-.688h-.373v.688h-.166v-1.552zm2.256.149h-.45v1.404h-.167V25.48h-.448v-.149h1.064zm2.004%201.405h-.157l-.824-1.246v1.245h-.167v-1.553h.158l.824%201.241v-1.24h.166zm1.98-1.405h-.798v.546h.68v.149h-.68v.561h.798v.148h-.964v-1.553h.964zm1.078%200v.57h.414a.35.35%200%200%200%20.224-.07q.085-.069.085-.213t-.085-.215a.34.34%200%200%200-.224-.07h-.414zm.43-.149a.6.6%200%200%201%20.186.03q.086.03.146.085t.095.136a.5.5%200%200%201%20.034.18.4.4%200%200%201-.338.417l.368.704h-.193l-.353-.688h-.373v.688h-.166v-1.552z'%20clip-rule='evenodd'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},GCASH:{name:"GCash",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23007dfe'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23002ac4'%20d='M11%2019.555c.046-.068.046-.16.046-.228.091-1.027.342-1.986.821-2.899q1.78-3.39%205.479-4.245a7.4%207.4%200%200%201%202.465-.137c1.529.137%202.876.707%204.085%201.62a.906.906%200%200%201%20.092%201.415.9.9%200%200%201-1.164.069%205%205%200%200%200-.571-.388%206.4%206.4%200%200%200-2.716-.89%206.12%206.12%200%200%200-6.505%204.747%206.153%206.153%200%200%200%204.633%207.396c1.849.41%203.56.046%205.113-1.096.297-.205.594-.296.936-.16.32.115.548.366.593.708.046.343-.068.662-.342.867a8.1%208.1%200%200%201-3.538%201.553c-.61.11-1.231.14-1.849.091-1.849-.114-3.47-.776-4.839-2.009-1.37-1.164-2.191-2.625-2.556-4.382a6%206%200%200%201-.137-.89c0-.092%200-.16-.046-.229z'/%3e%3cpath%20fill='%23fff'%20d='M22.093%2020.948h-2.122a.89.89%200%200%201-.868-.617c-.205-.593.228-1.232.867-1.232h3.219c.525%200%20.936.41.936.936a4.9%204.9%200%200%201-.434%202.054c-.753%201.598-1.986%202.58-3.698%202.922-2.716.502-5.34-1.256-5.912-3.926-.456-2.146.48-4.36%202.443-5.479a5%205%200%200%201%202.191-.639%204.9%204.9%200%200%201%202.876.685c.046.023.114.069.16.091.41.274.525.822.274%201.233a.923.923%200%200%201-1.233.342c-.16-.091-.297-.182-.456-.25-1.872-.822-4.086.319-4.451%202.328a3.22%203.22%200%200%200%202.556%203.766c1.552.296%203.127-.617%203.63-2.1.022-.046.045-.069.022-.114'/%3e%3cpath%20fill='%2375c2fb'%20d='M29.991%2019.92c0%201.598-.274%203.013-.867%204.383-.092.251-.206.48-.343.708-.182.342-.502.525-.958.479-.343-.046-.64-.342-.73-.708a.85.85%200%200%201%20.09-.616c.229-.434.411-.867.548-1.324.18-.556.303-1.13.366-1.712.045-.365.068-.753.068-1.118-.023-1.324-.274-2.602-.844-3.812-.046-.114-.115-.228-.16-.343-.274-.616.182-1.323.844-1.278.343.023.617.183.776.502.32.64.594%201.301.776%202.01.16.547.252%201.095.32%201.643.114.41.137.843.114%201.186m-2.967.115a7.7%207.7%200%200%201-.708%203.264c-.114.274-.32.479-.593.547-.343.092-.662.023-.913-.25-.252-.274-.32-.594-.183-.937.091-.228.183-.433.251-.661.16-.457.251-.936.297-1.416.091-1.095-.069-2.122-.525-3.127-.228-.502%200-1.05.502-1.232.434-.183.936.023%201.141.456.274.594.48%201.21.594%201.85.091.501.16%201.003.137%201.506'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},GOOGLE_PAY:{name:"Google Pay",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23111211'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20d='M18.923%2016.468v2.527h1.559c.345.01.68-.125.92-.374a1.268%201.268%200%200%200-.92-2.153zm0%203.417v2.93h-.93V15.58h2.468a2.23%202.23%200%200%201%201.599.626%202.09%202.09%200%200%201%200%203.063%202.23%202.23%200%200%201-1.599.616zm4.746%201.415a.74.74%200%200%200%20.309.606c.206.162.461.247.723.242.393%200%20.77-.156%201.047-.434.293-.258.46-.63.46-1.02a1.9%201.9%200%200%200-1.214-.344%201.58%201.58%200%200%200-.946.273.81.81%200%200%200-.38.676m1.204-3.599a2.3%202.3%200%200%201%201.63.551c.408.393.626.945.596%201.511v3.053h-.89v-.688h-.04a1.78%201.78%200%200%201-1.539.85%202%202%200%200%201-1.37-.486c-.358-.3-.56-.746-.552-1.213a1.47%201.47%200%200%201%20.582-1.223%202.45%202.45%200%200%201%201.553-.455%202.75%202.75%200%200%201%201.365.304v-.213a1.06%201.06%200%200%200-.384-.824%201.32%201.32%200%200%200-.9-.338%201.43%201.43%200%200%200-1.235.657l-.82-.516a2.29%202.29%200%200%201%202.004-.97m7.336.163L29.102%2025h-.96l1.152-2.497-2.044-4.639h1.012l1.477%203.557h.02l1.438-3.557z'/%3e%3cpath%20fill='%23547dbe'%20d='M15.162%2019.254q0-.426-.072-.846h-3.926v1.602h2.249a1.93%201.93%200%200%201-.832%201.264v1.04h1.342a4.07%204.07%200%200%200%201.239-3.06'/%3e%3cpath%20fill='%2334a751'%20d='M11.163%2023.318c1.014.028%202-.33%202.76-1.004l-1.343-1.04a2.526%202.526%200%200%201-3.754-1.319H7.443v1.072a4.16%204.16%200%200%200%203.72%202.29'/%3e%3cpath%20fill='%23f7ba16'%20d='M8.826%2019.954a2.5%202.5%200%200%201%200-1.592v-1.071H7.443a4.15%204.15%200%200%200%200%203.735z'/%3e%3cpath%20fill='%23e84334'%20d='M11.163%2016.646a2.26%202.26%200%200%201%201.597.624l1.188-1.186A4%204%200%200%200%2011.163%2015a4.16%204.16%200%200%200-3.72%202.292l1.383%201.071a2.49%202.49%200%200%201%202.337-1.717'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},GO_PAY:{name:"GoPay",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%234c3494'%20d='M0%207h40v26H0z'/%3e%3cpath%20fill='%2300aed6'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%2300aed6'%20d='M5.93%2016.22c2.17%200%203.928%201.787%203.928%203.99S8.1%2024.2%205.93%2024.2%202%2022.414%202%2020.21c0-2.203%201.76-3.99%203.93-3.99'/%3e%3cpath%20fill='%23fff'%20fill-rule='evenodd'%20d='M8.218%2020.086a.92.92%200%200%200-.953-.873H4.783a.165.165%200%200%201-.163-.166c0-.091.073-.166.163-.166h2.515a.79.79%200%200%200-.573-.733%206.3%206.3%200%200%200-2.215%200%201.055%201.055%200%200%200-.786.887%208%208%200%200%200%200%202.363c.088.455.445.808.896.887.91.115%201.829.115%202.739%200a.97.97%200%200%200%20.76-.838q.12-.675.099-1.361m-.815.559v.147a.165.165%200%200%201-.227.154.17.17%200%200%201-.101-.154v-.147a.25.25%200%200%201%20.164-.435.25.25%200%200%201%20.164.435'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23000'%20d='M5.93%2016.22c2.17%200%203.928%201.787%203.928%203.99S8.1%2024.2%205.93%2024.2%202%2022.414%202%2020.21c0-2.203%201.76-3.99%203.93-3.99'/%3e%3cpath%20fill='%2300aed6'%20fill-rule='evenodd'%20d='M8.218%2020.086a.92.92%200%200%200-.953-.873H4.783a.165.165%200%200%201-.163-.166c0-.091.073-.166.163-.166h2.515a.79.79%200%200%200-.573-.733%206.3%206.3%200%200%200-2.215%200%201.055%201.055%200%200%200-.786.887%208%208%200%200%200%200%202.363c.088.455.445.808.896.887.91.115%201.829.115%202.739%200a.97.97%200%200%200%20.76-.838q.12-.675.099-1.361m-.815.559v.147a.165.165%200%200%201-.227.154.17.17%200%200%201-.101-.154v-.147a.25.25%200%200%201%20.164-.435.25.25%200%200%201%20.164.435'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23fff'%20d='M12.964%2022.197a1.68%201.68%200%200%200%201.469.728c.684%200%201.187-.444%201.187-1.047v-.318h-.016a1.85%201.85%200%200%201-1.41.536c-1.262.036-2.314-.972-2.35-2.253s.957-2.35%202.219-2.386q.045-.002.089-.001a1.95%201.95%200%200%201%201.452.52h.016v-.437h1.172v4.322c0%201.256-.982%202.127-2.36%202.127a2.8%202.8%200%200%201-2.342-1.055zm2.607-2.69c0-.502-.56-.962-1.187-.962-.793%200-1.32.486-1.32%201.214a1.168%201.168%200%200%200%201.27%201.248c.685%200%201.237-.436%201.237-.98zm4.289-2.093c1.428%200%202.467%201.03%202.467%202.345s-1.039%202.345-2.466%202.345c-1.276.085-2.378-.896-2.461-2.192-.084-1.295.883-2.413%202.158-2.498q.15-.01.302%200m.001%201.088a1.25%201.25%200%200%200-1.228%201.265%201.245%201.245%200%200%200%201.246%201.248%201.247%201.247%200%200%200%201.229-1.256%201.195%201.195%200%200%200-1.247-1.257m3.127-.962h1.171v.393h.017c.383-.357.89-.544%201.41-.52%201.276.024%202.291%201.093%202.268%202.389-.022%201.258-1.02%202.275-2.26%202.302a2.1%202.1%200%200%201-1.369-.469h-.016v2.228h-1.221zm2.409.971c-.645%200-1.189.46-1.189.963v.561c0%20.536.528.98%201.196.98a1.24%201.24%200%200%200%201.23-1.256%201.24%201.24%200%200%200-1.237-1.248m4.758.821c.8-.11%201.04-.227%201.04-.452%200-.294-.305-.47-.775-.47a1.034%201.034%200%200%200-1.09.796l-1.154-.242c.164-.905%201.08-1.55%202.21-1.55%201.279%200%202.071.662%202.071%201.742v2.823H31.36v-.486h-.017a1.79%201.79%200%200%201-1.477.611c-.965%200-1.632-.536-1.632-1.323%200-.83.544-1.255%201.921-1.449m1.139.468h-.017c-.107.16-.338.251-.932.36-.718.134-.973.276-.973.536%200%20.268.214.385.676.385.701%200%201.246-.326%201.246-.754zm3.374%201.936-2.021-4.197h1.345l1.327%202.898h.017l1.312-2.898H38l-3.027%206.324H33.63z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},KAKAOPAY:{name:"KakaoPay",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23ffcd01'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23000'%20d='M9.488%2024.5c-.238-.402%200-.702.068-1.003s.153-.617.243-.951c-.164-.125-.334-.238-.504-.363a2.832%202.832%200%200%201-.034-4.735%204.815%204.815%200%200%201%206.152.345%202.76%202.76%200%200%201%200%204.033%204.53%204.53%200%200%201-3.32%201.264%201.43%201.43%200%200%200-.895.271c-.413.3-.85.595-1.274.873-.125.09-.255.158-.436.266m9.482-7.132h.861c.057.091.136.204.193.284q.47-.24.974-.403a1.626%201.626%200%200%201%201.95.997%203.5%203.5%200%200%201%20.055%202.606%202.09%202.09%200%200%201-2.22%201.433l-.527-.034v1.7h-1.274c-.012-2.193-.012-4.362-.012-6.583m1.275%201.133v2.72a1.13%201.13%200%200%200%201.535-.816%203%203%200%200%200%200-1.49.71.71%200%200%200-.567-.567%201.16%201.16%200%200%200-.968.153m11.425-1.342c.448.124.84.232%201.275.368-.227.629-.425%201.212-.652%201.79-.39%201.053-.77%202.13-1.195%203.16a3.26%203.26%200%200%201-1.41%201.7c-.25-.22-.505-.459-.754-.691.363-.436.697-.867%201.031-1.28-.566-1.564-1.133-3.087-1.7-4.668l1.281-.368c.346%201.195.685%202.35%201.02%203.5h.113c.317-1.138.64-2.293.991-3.511m-3.92%205.007h-.883l-.153-.34-.125.034a5.4%205.4%200%200%201-1.133.402c-1.042.102-1.7-.566-1.58-1.654.068-.844.63-1.314%201.603-1.388h.986c.12-.566-.09-.9-.607-.878q-.712.064-1.41.227c-.09-.215-.215-.481-.346-.793a2.95%202.95%200%200%201%202.266-.515%201.524%201.524%200%200%201%201.371%201.506c.057%201.133.011%202.219.011%203.399m-1.268-1.206v-.866h-.77c-.618.068-.817.459-.539%201.048a1.3%201.3%200%200%200%201.31-.21z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},MOMO:{name:"Momo",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23ad2070'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20fill-rule='evenodd'%20d='M13.207%2027.325a.43.43%200%200%200-.336.157.3.3%200%200%200-.096-.098.4.4%200%200%200-.226-.059.44.44%200%200%200-.295.11v-.084H12v1.197h.274v-.62q0-.143.027-.217a.2.2%200%200%201%20.08-.102.23.23%200%200%201%20.126-.035q.084%200%20.116.045.04.053.038.164v.765h.274v-.689q0-.154.065-.22a.22.22%200%200%201%20.165-.065q.052%200%20.09.024.035.022.05.059c.007.02.015.06.015.148v.743h.273v-.806q0-.208-.101-.312a.38.38%200%200%200-.285-.105m1.275.242q.12%200%20.202.091.083.095.083.285%200%20.203-.083.298a.25.25%200%200%201-.202.092.26.26%200%200%201-.202-.091q-.083-.095-.083-.293%200-.196.083-.291a.26.26%200%200%201%20.202-.091m0-.242a.56.56%200%200%200-.377.134q-.187.162-.187.49%200%20.3.156.461a.54.54%200%200%200%20.408.163.6.6%200%200%200%20.29-.073q.134-.075.204-.209a.8.8%200%200%200%20.07-.357.62.62%200%200%200-.158-.445.54.54%200%200%200-.406-.164m1.747.624q0%20.195-.08.292a.23.23%200%200%201-.182.092q-.127%200-.204-.125a.54.54%200%200%201-.049-.267q0-.187.08-.283a.22.22%200%200%201%20.358-.004q.075.092.077.295m.142-.451a.44.44%200%200%200-.167-.128.5.5%200%200%200-.212-.045q-.15%200-.262.089v-.488h-.274v1.621h.26v-.07a.4.4%200%200%200%20.267.096.5.5%200%200%200%20.371-.17q.152-.17.152-.471a.8.8%200%200%200-.035-.24.6.6%200%200%200-.1-.194m.524-.268h.274v-.303h-.274zm0%201.318h.274v-1.197h-.274zm.875%200h.275v-1.62h-.274zm.995-.748a.3.3%200%200%201%20.08-.16.26.26%200%200%201%20.189-.075q.125%200%20.2.094a.3.3%200%200%201%20.056.141zm.532.333a.3.3%200%200%201-.102.154.25.25%200%200%201-.152.046.27.27%200%200%201-.202-.084.36.36%200%200%201-.088-.209h.825l.001-.041.001-.052q0-.293-.153-.456a.52.52%200%200%200-.395-.166.53.53%200%200%200-.407.169q-.155.166-.156.465%200%20.288.155.451a.55.55%200%200%200%20.418.163.56.56%200%200%200%20.344-.102.52.52%200%200%200%20.187-.288l.012-.048-.277-.034zm2.879-.808a.43.43%200%200%200-.336.157.3.3%200%200%200-.097-.098.4.4%200%200%200-.226-.059.44.44%200%200%200-.294.11v-.084h-.254v1.197h.273v-.62q0-.143.028-.217a.2.2%200%200%201%20.08-.102.23.23%200%200%201%20.125-.035q.084%200%20.117.045.038.053.038.164v.765h.274v-.689q0-.154.065-.22a.22.22%200%200%201%20.165-.065q.053%200%20.09.024.035.022.05.059c.006.02.015.06.015.148v.743h.273v-.806q0-.208-.101-.312a.38.38%200%200%200-.285-.105m1.36.242q.12%200%20.201.091.083.095.083.285%200%20.203-.082.298a.25.25%200%200%201-.202.092.26.26%200%200%201-.203-.091q-.083-.095-.083-.293%200-.196.083-.291a.26.26%200%200%201%20.203-.091m0-.242a.56.56%200%200%200-.378.134q-.186.162-.187.49%200%20.3.156.461a.54.54%200%200%200%20.409.163.6.6%200%200%200%20.29-.073.5.5%200%200%200%20.204-.209.8.8%200%200%200%20.07-.357.62.62%200%200%200-.158-.445.54.54%200%200%200-.406-.164m1.895.149a.33.33%200%200%200-.144-.11.5.5%200%200%200-.201-.039.45.45%200%200%200-.312.112v-.087h-.255v1.198h.274v-.65q0-.194.073-.258a.26.26%200%200%201%20.18-.066.2.2%200%200%201%20.11.028q.044.025.06.07a.5.5%200%200%201%20.019.157v.72h.274v-.727a1%201%200%200%200-.012-.192.4.4%200%200%200-.066-.156m.707.326a.3.3%200%200%201%20.08-.16.26.26%200%200%201%20.189-.075q.124%200%20.201.094.04.05.056.141zm.532.333a.3.3%200%200%201-.102.154.25.25%200%200%201-.152.046.27.27%200%200%201-.202-.084.36.36%200%200%201-.087-.209h.824l.001-.041.001-.052q0-.293-.152-.456a.52.52%200%200%200-.396-.166.53.53%200%200%200-.406.169q-.156.166-.156.465%200%20.288.154.451a.55.55%200%200%200%20.418.163.56.56%200%200%200%20.345-.102.52.52%200%200%200%20.186-.288l.012-.048-.277-.034zm1.316-.783-.248.677-.039.113-.04-.117-.241-.672h-.295l.438%201.157-.011.032a1%201%200%200%201-.053.132.13.13%200%200%201-.047.044c-.033.018-.092.023-.177%200l-.06-.016.03.266.026.009a.4.4%200%200%200%20.136.025.3.3%200%200%200%20.178-.05.4.4%200%200%200%20.13-.152q.063-.125.108-.258l.444-1.19zm-3.247-14.23a1.41%201.41%200%200%200-1.408%201.407%201.408%201.408%200%200%200%202.815%200c0-.777-.631-1.408-1.408-1.408m0%204.933a3.53%203.53%200%200%201-3.527-3.526A3.53%203.53%200%200%201%2024.738%2011a3.53%203.53%200%200%201%203.527%203.527%203.53%203.53%200%200%201-3.527%203.526m.001%203.288a1.41%201.41%200%200%200-1.408%201.408%201.41%201.41%200%200%200%201.407%201.407%201.41%201.41%200%200%200%201.408-1.407c0-.776-.63-1.408-1.407-1.408m-.001%204.934a3.53%203.53%200%200%201-3.527-3.526%203.53%203.53%200%200%201%203.526-3.527%203.53%203.53%200%200%201%203.527%203.527%203.53%203.53%200%200%201-3.527%203.526M17.91%2011c-.608%200-1.168.203-1.617.545A2.66%202.66%200%200%200%2014.677%2011%202.68%202.68%200%200%200%2012%2013.676v4.377h2.119v-4.377a.558.558%200%200%201%201.114%200v4.377h2.119v-4.377a.557.557%200%200%201%201.113%200v4.377h2.12v-4.377A2.68%202.68%200%200%200%2017.908%2011m.002%208.222c-.608%200-1.168.203-1.617.545a2.66%202.66%200%200%200-1.617-.545A2.68%202.68%200%200%200%2012%2021.898v4.377h2.12v-4.377a.557.557%200%200%201%201.113%200v4.377h2.12v-4.377a.557.557%200%200%201%201.113%200v4.377h2.119v-4.377a2.68%202.68%200%200%200-2.675-2.676'%20clip-rule='evenodd'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},PAYPAL:{name:"PayPal",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23253b80'%20d='m16.912%2027.988.282-1.822-.627-.015H13.57l2.082-13.443a.17.17%200%200%201%20.169-.146h5.05c1.678%200%202.835.355%203.439%201.056.283.33.463.673.55%201.052.092.397.094.87.005%201.45l-.007.042v.37l.283.164q.357.192.574.445c.242.281.399.639.465%201.063.068.436.046.955-.066%201.542-.13.676-.338%201.264-.62%201.745a3.6%203.6%200%200%201-.983%201.097c-.375.271-.82.477-1.324.608a6.5%206.5%200%200%201-1.654.195h-.393a1.18%201.18%200%200%200-.768.288%201.22%201.22%200%200%200-.401.728l-.03.164-.497%203.211-.023.118c-.006.037-.016.056-.031.069a.1.1%200%200%201-.052.019z'/%3e%3cpath%20fill='%23179bd7'%20d='M25.41%2016.205a9%209%200%200%201-.051.301c-.666%203.483-2.945%204.686-5.856%204.686h-1.481a.724.724%200%200%200-.712.62l-.758%204.901-.215%201.39a.383.383%200%200%200%20.374.446h2.628c.312%200%20.576-.23.625-.543l.026-.136.495-3.198.031-.176a.635.635%200%200%201%20.625-.544h.393c2.546%200%204.54-1.053%205.122-4.1.244-1.272.118-2.335-.526-3.083a2.5%202.5%200%200%200-.72-.564'/%3e%3cpath%20fill='%23222d65'%20d='M24.714%2015.921a5%205%200%200%200-.648-.146%208%208%200%200%200-1.306-.097H18.8a.64.64%200%200%200-.623.544l-.842%205.432-.025.159a.72.72%200%200%201%20.712-.621h1.482c2.91%200%205.19-1.204%205.855-4.686q.03-.154.051-.302a3.5%203.5%200%200%200-.696-.283'/%3e%3cpath%20fill='%23253b80'%20d='M18.177%2016.222a.64.64%200%200%201%20.624-.543h3.959q.705-.002%201.306.097.171.028.333.064.236.055.464.13.296.099.548.234c.198-1.287-.002-2.163-.685-2.956-.753-.874-2.113-1.248-3.853-1.248h-5.05a.726.726%200%200%200-.714.621l-2.104%2013.581a.44.44%200%200%200%20.428.511h3.119l.783-5.059z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},TWINT:{name:"Twint",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23000'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20d='M13.78%2022.301a.44.44%200%200%201-.206.35l-3.977%202.302a.48.48%200%200%201-.413%200l-3.978-2.301a.45.45%200%200%201-.206-.35v-4.603c0-.132.094-.288.206-.35l3.978-2.302a.48.48%200%200%201%20.413%200l3.977%202.301a.45.45%200%200%201%20.207.35zm22.083-4.271h-3.558v.85h1.275v3.64h1.007v-3.64h1.276zm-16.179%200H16.12v.85h1.276v3.64h1.007v-3.64h1.276zm10.307-.138c-1.12%200-1.745.72-1.745%201.752v2.883h1v-2.902c0-.45.263-.8.757-.8s.75.412.75.8v2.902h.995v-2.883c.012-1.039-.632-1.752-1.757-1.752m-3.759.138v4.49h.994v-4.49zm-3.383%201.782.03.2.939%202.515h.406l1.276-4.49h-.982l-.606%202.357-.038.256-.05-.256-.813-2.358h-.325l-.813%202.358-.05.256-.031-.256-.607-2.358h-.988l1.276%204.49h.406l.938-2.514z'/%3e%3cpath%20fill='url(%23b)'%20d='m11.467%2020.013-1.038%201.526-.532-.813.613-.92c.113-.162.356-.613.075-1.225a1.27%201.27%200%200%200-1.157-.739c-.438%200-.907.226-1.157.739a1.18%201.18%200%200%200%20.069%201.207s.344.5.625.919l.463.669.694%201.063c.006.006.113.175.307.175.181%200%20.3-.169.312-.181l1.626-2.408h-.9zm-2.045.037s-.27-.413-.45-.7a.513.513%200%200%201%20.45-.77c.425%200%20.638.463.45.77-.175.287-.45.7-.45.7'/%3e%3cpath%20fill='url(%23c)'%20d='m8.427%2021.489-1.02-1.433s-.269-.412-.45-.7a.513.513%200%200%201%20.45-.77c.057%200%20.1.007.15.02l.357-.657a1.3%201.3%200%200%200-.507-.107%201.28%201.28%200%200%200-1.157.739%201.18%201.18%200%200%200%20.07%201.207l1.782%202.645c.018.019.13.188.319.188.187%200%20.3-.163.312-.182l.538-.82-.463-.675z'/%3e%3c/g%3e%3cdefs%3e%3cradialGradient%20id='b'%20cx='0'%20cy='0'%20r='1'%20gradientTransform='matrix(4.79253%200%200%205.4098%209.085%2018.261)'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%23fc0'/%3e%3cstop%20offset='.092'%20stop-color='%23ffc800'/%3e%3cstop%20offset='.174'%20stop-color='%23ffbd00'/%3e%3cstop%20offset='.253'%20stop-color='%23ffab00'/%3e%3cstop%20offset='.33'%20stop-color='%23ff9100'/%3e%3cstop%20offset='.405'%20stop-color='%23ff7000'/%3e%3cstop%20offset='.479'%20stop-color='%23ff4700'/%3e%3cstop%20offset='.55'%20stop-color='%23ff1800'/%3e%3cstop%20offset='.582'%20stop-color='red'/%3e%3cstop%20offset='1'%20stop-color='red'/%3e%3c/radialGradient%3e%3cradialGradient%20id='c'%20cx='0'%20cy='0'%20r='1'%20gradientTransform='matrix(4.39419%200%200%206.6533%206.196%2018.538)'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%2300b4e6'/%3e%3cstop%20offset='.201'%20stop-color='%2300b0e3'/%3e%3cstop%20offset='.39'%20stop-color='%2301a5db'/%3e%3cstop%20offset='.574'%20stop-color='%230292cd'/%3e%3cstop%20offset='.755'%20stop-color='%230377ba'/%3e%3cstop%20offset='.932'%20stop-color='%230455a1'/%3e%3cstop%20offset='1'%20stop-color='%23054696'/%3e%3c/radialGradient%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"}},fL={class:"flex h-full grow flex-col justify-center"},gL=e.defineComponent({__name:"PaymentMethodDigitalWallet",props:{paymentMethod:{},isDefault:{type:Boolean},options:{},variant:{default:"default"}},setup(t){const n=t,r=e.computed(()=>{var e;return(null==(e=n.paymentMethod.digital_wallet)?void 0:e.variant)?mL[n.paymentMethod.digital_wallet.variant]:void 0});return(n,o)=>{var i,a,l;return e.openBlock(),e.createBlock(iL,{"image-src":(null==(i=r.value)?void 0:i.logo)??e.unref(X$),"image-alt":null==(l=null==(a=r.value)?void 0:a.name)?void 0:l.toLowerCase(),variant:t.variant,options:t.options,"is-inactive":"INACTIVE"===t.paymentMethod.status},{default:e.withCtx(()=>[e.createElementVNode("div",fL,[e.createVNode(gc,{tag:"span",weight:"semibold","no-spacing":"",variant:"condensed"===t.variant?"body-xs":"body-sm",shade:"condensed"===t.variant?"light":void 0},{default:e.withCtx(()=>{var t;return[e.createTextVNode(e.toDisplayString(null==(t=r.value)?void 0:t.name),1)]}),_:1},8,["variant","shade"]),e.createVNode(aL,{"is-default":t.isDefault},null,8,["is-default"]),e.createVNode(lL,{"is-inactive":"INACTIVE"===t.paymentMethod.status},null,8,["is-inactive"])])]),_:1},8,["image-src","image-alt","variant","options","is-inactive"])}}}),vL={ACH:{name:"ACH",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cmask%20id='b'%20width='34'%20height='13'%20x='3'%20y='14'%20maskUnits='userSpaceOnUse'%20style='mask-type:luminance'%3e%3cpath%20fill='%23fff'%20d='M3%2014h34v12.653H3z'/%3e%3c/mask%3e%3cg%20mask='url(%23b)'%3e%3cpath%20fill='%230ac500'%20d='M12.597%2018.94a1.389%201.389%200%200%200-1.156%202.156%201.387%201.387%200%201%200%201.156-2.156m-3.409-2.03c-.623%200-1.13.505-1.132%201.128%200%20.623.505%201.13%201.128%201.131a1.13%201.13%200%200%200%20.004-2.258zm0%204.574a1.128%201.128%200%201%200%200%202.255%201.128%201.128%200%200%200%200-2.255m-2.912-4.376a.923.923%200%201%200%20.06-1.845.923.923%200%200%200-.06%201.845M3.76%2014a.76.76%200%200%200-.004%201.516.76.76%200%200%200%20.76-.756.76.76%200%200%200-.756-.76m2.516%2011.388a.923.923%200%201%200%20.06-1.845.923.923%200%200%200-.06%201.845m-2.516-.251a.758.758%200%201%200%20.756.76v-.004a.757.757%200%200%200-.756-.756'/%3e%3cpath%20fill='%23006eff'%20d='M5.934%2018.94a1.387%201.387%200%201%200%20.004%200zm6.321-1.832a.923.923%200%201%200%200-1.845.923.923%200%200%200%200%201.845m2.51-1.585a.759.759%200%200%200%200-1.516.757.757%200%201%200-.002%201.514h.002zm-2.51%209.865a.923.923%200%201%200%200-1.845.923.923%200%200%200%200%201.845m2.51-.251a.759.759%200%201%200%20.756.76v-.004a.757.757%200%200%200-.756-.756'/%3e%3cpath%20fill='%23000'%20d='M22.613%2019.873h-.638l-.271-.619H20.27l-.266.62h-.634l1.606-3.485h.02zm-2.137-1.109h1.039l-.523-1.187zm5.104-1.867-.37.42a1.15%201.15%200%200%200-.87-.392c-.675%200-1.137.517-1.137%201.238s.464%201.243%201.139%201.243c.342.005.667-.146.885-.41l.37.428c-.318.35-.777.538-1.248.516-1.002%200-1.723-.758-1.723-1.77%200-1.01.721-1.774%201.723-1.774a1.6%201.6%200%200%201%201.231.501m3.05%202.976h-.582v-1.479h-1.56v1.48h-.582v-3.427h.582v1.407h1.56v-1.406h.583zm-6.808%203.021v-2.12h.582v3.485h-.018l-2.087-2.186v2.125h-.583v-3.483h.019zm3.232.108v.184H23.39c.024.37.251.573.643.573.23.01.45-.088.597-.264l.37.292a1.18%201.18%200%200%201-.978.448%201.15%201.15%200%200%201-1.202-1.099v-.116c0-.708.472-1.226%201.15-1.226.725.015%201.084.55%201.084%201.207m-1.664-.206h1.109a.514.514%200%200%200-.471-.553h-.061a.554.554%200%200%200-.572.538v.017h-.005zm2.776-.945h.709v.475h-.709v1.044a.336.336%200%200%200%20.355.368.7.7%200%200%200%20.331-.08l.148.452a.96.96%200%200%201-.521.135c-.534%200-.875-.307-.875-.875v-1.046h-.443v-.475h.443v-.78h.555l.007.78zm3.204%202.394h-.018l-.647-1.294-.653%201.294h-.018l-1.08-2.403h.6l.531%201.294.61-1.295h.019l.605%201.295.536-1.295h.597zm3.513-1.214a1.22%201.22%200%201%201-1.22-1.221%201.18%201.18%200%200%201%201.22%201.14zm-1.873%200c0%20.419.27.72.647.72a.664.664%200%200%200%20.671-.721c0-.425-.273-.74-.656-.74s-.656.315-.656.74zm3.47-.666h-.05a.72.72%200%200%200-.61.353v1.479h-.554V21.85h.502l.034.312a.79.79%200%200%201%20.678-.353zm.849.554.954-1.072h.637l-.785.904.865%201.444h-.638l-.614-1.017-.42.444v.577h-.554v-3.54h.555z'/%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},DIRECT_DEBIT_GB:{name:"Direct Debit GB",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23e71c44'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23e71c44'%20d='M10.72%2023.985c1.688-.077%203.085-1.304%203.34-2.932L15.055%2016H7.58L6%2023.985z'/%3e%3cpath%20fill='%23fff'%20d='m17.35%2016.044-.727%203.459h.023a2.34%202.34%200%200%201%201.933-1.09c1.206%200%201.66.969%201.66%201.916%200%201.63-1.216%203.657-3.423%203.657-.966%200-1.694-.385-1.694-1.376q.012-.417.09-.827l1.195-5.739zm-1.193%205.761q-.085.331-.069.672c0%20.506.296.794.888.794%201.421%200%202.285-1.642%202.285-2.821%200-.66-.295-1.278-1.046-1.278-.819%200-1.66.816-1.933%202.072zm7.983%202.06q.027-.691.125-1.376h-.022a2.41%202.41%200%200%201-2.138%201.497%201.64%201.64%200%200%201-1.19-.54%201.56%201.56%200%200%201-.392-1.222%203.7%203.7%200%200%201%201.087-2.684%203.88%203.88%200%200%201%202.724-1.128c.5%200%20.999.07%201.478.21l-.557%202.776a11.8%2011.8%200%200%200-.239%202.467zm.615-4.648a2.6%202.6%200%200%200-.66-.077c-1.422%200-2.582%201.442-2.593%202.919%200%20.595.216%201.179.944%201.179.785%200%201.717-.992%201.99-2.413zm4.911%204.439c-.5.222-1.043.335-1.592.33a2%202%200%200%201-1.544-.562%201.9%201.9%200%200%201-.571-1.508%203.34%203.34%200%200%201%20.94-2.428%203.5%203.5%200%200%201%202.426-1.065%202.9%202.9%200%200%201%201.15.232l-.274.727a2.2%202.2%200%200%200-.933-.199c-1.377.115-2.41%201.277-2.331%202.622-.05.374.073.75.337%201.025s.641.42%201.027.396a3%203%200%200%200%201.275-.297zM7.417%2021.432q-.452%200-.897-.076l1.023-5.172c2.011.047%203.622%201.203%203.622%202.623%200%201.45-1.679%202.625-3.748%202.625m1.888.27c1.832-.374%203.164-1.505%203.164-2.843%200-1.356-1.367-2.5-3.239-2.858h-.455c1.882.29%203.29%201.462%203.29%202.865%200%201.468-1.542%202.685-3.555%202.901q.076%200%20.153-.005.323-.016.642-.06m.989-5.701c1.965.408%203.394%201.546%203.471%202.956.102%201.866-2.208%203.501-5.158%203.653a8%208%200%200%201-2.294-.206L6%2023.985h4.72c1.687-.076%203.085-1.303%203.34-2.932l.995-5.052zm3.058%202.606C13.28%2017.294%2011.769%2016.26%209.759%2016h-.223c1.968.36%203.406%201.503%203.406%202.858-.13%201.153-.948%202.122-2.083%202.469%201.537-.562%202.554-1.594%202.493-2.721M30.52%2022.94c.36.204.767.318%201.183.33a.96.96%200%200%200%20.715-.215.92.92%200%200%200%20.331-.655c0-.418-.193-.672-.762-.98a1.6%201.6%200%200%201-.988-1.355c.028-.481.256-.93.632-1.241a1.85%201.85%200%200%201%201.357-.412c.4-.01.796.08%201.149.265l-.261.693a2%202%200%200%200-.956-.242.9.9%200%200%200-.666.198.85.85%200%200%200-.311.606c0%20.386.261.628.75.893.583.245.98.782%201.034%201.398a1.8%201.8%200%200%201-.653%201.335%201.9%201.9%200%200%201-1.45.428%202.56%202.56%200%200%201-1.365-.374z'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},SEPA_DIRECT_DEBIT:{name:"SEPA Direct Debit",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%20viewBox='0%200%2040%2040'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%239a1b27'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%239a1b27'%20d='M3.077%209h33.846v22H3.077z'/%3e%3cpath%20fill='%23fefefe'%20d='M11.461%2019.505a6%206%200%200%200-1.527-.325%203.3%203.3%200%200%201-.88-.182.32.32%200%200%201-.202-.3.37.37%200%200%201%20.16-.3.83.83%200%200%201%20.508-.125c.207-.006.412.05.586.162a.67.67%200%200%201%20.253.381l1.951-.193a2.4%202.4%200%200%200-.508-.837%201.85%201.85%200%200%200-.763-.457%205%205%200%200%200-1.418-.148c-.49-.016-.98.048-1.451.19a1.84%201.84%200%200%200-.85.576%201.44%201.44%200%200%200-.308.919c-.004.312.097.618.286.867.177.244.421.431.703.54q.729.237%201.488.348.455.059.885.212a.38.38%200%200%201%20.185.532.4.4%200%200%201-.129.143%201.02%201.02%200%200%201-.642.177%201.05%201.05%200%200%201-.607-.157%201%201%200%200%201-.354-.523l-2.042.193c.098.49.386.92.801%201.198.646.333%201.371.48%202.096.422.56.022%201.12-.067%201.645-.262a1.9%201.9%200%200%200%20.885-.702c.18-.27.277-.585.28-.908a1.46%201.46%200%200%200-.265-.847%201.7%201.7%200%200%200-.766-.594'/%3e%3cpath%20fill='%23fefefe'%20fill-rule='evenodd'%20d='M23.049%2017.42c.307-.16.649-.243.996-.239.66-.028%201.29.285%201.665.828a3.44%203.44%200%200%201%20.59%202.046%202.96%202.96%200%200%201-.643%202.054%202.1%202.1%200%200%201-1.622.708%202.3%202.3%200%200%201-.867-.162%202.1%202.1%200%200%201-.7-.482v2.855h-2.079v-7.725h1.927v.797c.197-.272.446-.503.733-.68m.348%203.854a.75.75%200%200%200%20.602-.297c.19-.3.275-.655.243-1.008.027-.34-.062-.68-.253-.962a.77.77%200%200%200-.617-.307.83.83%200%200%200-.657.31c-.201.294-.294.65-.263%201.005-.027.338.068.675.268.95a.86.86%200%200%200%20.677.309m9.561.274q-.008.3.047.597.075.285.21.55h-1.93a2%202%200%200%201-.153-.317%202.4%202.4%200%200%201-.07-.342%202.7%202.7%200%200%201-.804.558%203.3%203.3%200%200%201-1.27.223%202.12%202.12%200%200%201-1.458-.446%201.42%201.42%200%200%201-.498-1.102c-.014-.37.115-.732.36-1.01a2.4%202.4%200%200%201%201.324-.59%2030%2030%200%200%200%201.501-.327q.37-.104.728-.246a.73.73%200%200%200-.156-.533.78.78%200%200%200-.552-.153%201.4%201.4%200%200%200-.758.163.9.9%200%200%200-.318.477l-1.967-.208c.052-.29.161-.568.321-.815.16-.215.367-.391.604-.515.245-.123.508-.206.779-.244q.532-.091%201.072-.086.747-.015%201.486.104c.346.056.67.206.935.434.192.176.334.4.415.647.097.256.148.526.152.8zm-2.136-.454c.09-.197.132-.412.123-.627v-.33q-.435.155-.884.269a2%202%200%200%200-.794.33.53.53%200%200%200-.003.779.7.7%200%200%200%20.498.155%201.3%201.3%200%200%200%20.64-.168c.177-.092.323-.233.42-.408'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23fefefe'%20d='M12.793%2015.182v9.636l7.063%201.25V13.932z'/%3e%3cpath%20fill='%23fefefe'%20fill-rule='evenodd'%20d='M23.9%2024.877v.11h.134v-1.192h-.145v.427a.29.29%200%200%200-.237-.118.34.34%200%200%200-.32.217.6.6%200%200%200-.043.235.55.55%200%200%200%20.047.234c.03.064.075.12.133.159a.34.34%200%200%200%20.19.057.27.27%200%200%200%20.24-.129m-.392-.074a.38.38%200%200%201-.07-.247.4.4%200%200%201%20.065-.251.207.207%200%200%201%20.33.003.4.4%200%200%201%20.068.26.36.36%200%200%201-.067.239.206.206%200%200%201-.326-.004m1.095-.84h-.174v-.168h.174zm0%201.023h-.174v-.863h.174z'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23fefefe'%20d='M24.96%2024.986v-.863h.131v.131a.4.4%200%200%201%20.093-.12.16.16%200%200%201%20.093-.03.3.3%200%200%201%20.15.047l-.05.136a.2.2%200%200%200-.107-.032.14.14%200%200%200-.086.029.16.16%200%200%200-.054.08.6.6%200%200%200-.024.17v.452z'/%3e%3cpath%20fill='%23fefefe'%20fill-rule='evenodd'%20d='m26.418%2024.727-.15-.019a.3.3%200%200%201-.09.135.22.22%200%200%201-.137.043.24.24%200%200%201-.18-.076.33.33%200%200%201-.08-.218h.64l.002-.039a.47.47%200%200%200-.11-.331.37.37%200%200%200-.28-.118.38.38%200%200%200-.29.12.48.48%200%200%200-.112.338.46.46%200%200%200%20.11.327c.15.138.375.155.545.044a.37.37%200%200%200%20.132-.206m-.629-.255h.48a.3.3%200%200%200-.055-.163.22.22%200%200%200-.18-.085.23.23%200%200%200-.17.068.27.27%200%200%200-.075.18'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23fefefe'%20d='m27.327%2024.67.143.019a.35.35%200%200%201-.357.317.37.37%200%200%201-.284-.116.47.47%200%200%201-.107-.332.6.6%200%200%201%20.046-.244.32.32%200%200%201%20.14-.158.4.4%200%200%201%20.205-.052.36.36%200%200%201%20.23.071.33.33%200%200%201%20.113.202l-.141.022a.24.24%200%200%200-.072-.131.18.18%200%200%200-.124-.044.23.23%200%200%200-.179.08.38.38%200%200%200-.069.25.4.4%200%200%200%20.067.253c.042.051.106.08.173.078a.2.2%200%200%200%20.143-.052.26.26%200%200%200%20.073-.163m.751.185.021.13a.5.5%200%200%201-.11.012.25.25%200%200%201-.123-.025.14.14%200%200%201-.061-.066.5.5%200%200%201-.018-.173v-.496h-.107v-.114h.107v-.213l.145-.088v.301h.146v.114h-.146v.505a.3.3%200%200%200%20.007.08.06.06%200%200%200%20.025.029.1.1%200%200%200%20.05.01z'/%3e%3cpath%20fill='%23fefefe'%20fill-rule='evenodd'%20d='M29.487%2024.877v.11h.135v-1.192h-.145v.427a.29.29%200%200%200-.237-.118.34.34%200%200%200-.32.217.6.6%200%200%200-.043.235.55.55%200%200%200%20.047.234c.029.064.075.12.134.159a.34.34%200%200%200%20.188.057.27.27%200%200%200%20.24-.129m-.392-.074a.38.38%200%200%201-.07-.247.4.4%200%200%201%20.065-.251.21.21%200%200%201%20.33.003.4.4%200%200%201%20.068.26.36.36%200%200%201-.067.239.205.205%200%200%201-.326-.004m1.66-.076-.15-.019a.3.3%200%200%201-.09.135.22.22%200%200%201-.137.043.24.24%200%200%201-.18-.076.33.33%200%200%201-.08-.218h.64l.002-.039a.47.47%200%200%200-.11-.331.37.37%200%200%200-.281-.118.38.38%200%200%200-.29.12.48.48%200%200%200-.111.338.46.46%200%200%200%20.11.327c.15.138.375.155.545.044a.37.37%200%200%200%20.132-.206m-.63-.255h.48a.3.3%200%200%200-.054-.163.22.22%200%200%200-.18-.085.23.23%200%200%200-.17.068.27.27%200%200%200-.075.18m.977.514h.135v-.108c.052.082.143.13.24.128a.34.34%200%200%200%20.26-.121.5.5%200%200%200%20.11-.343.6.6%200%200%200-.025-.176.4.4%200%200%200-.072-.14.3.3%200%200%200-.117-.09.4.4%200%200%200-.15-.032.29.29%200%200%200-.235.116v-.425h-.146zm.176-.213a.45.45%200%200%201-.042-.225.37.37%200%200%201%20.07-.24.204.204%200%200%201%20.326-.003c.05.073.074.16.067.25a.38.38%200%200%201-.07.247.206.206%200%200%201-.282.048.2.2%200%200%201-.07-.078m1.088-.809h-.174v-.168h.174zm0%201.023h-.174v-.863h.174z'%20clip-rule='evenodd'/%3e%3cpath%20fill='%23fefefe'%20d='m33.042%2024.855.02.13a.5.5%200%200%201-.11.012.25.25%200%200%201-.122-.025.14.14%200%200%201-.062-.066.5.5%200%200%201-.017-.173v-.496h-.107v-.114h.107v-.213l.144-.088v.301h.147v.114h-.147v.505q0%20.04.008.08a.06.06%200%200%200%20.025.029.1.1%200%200%200%20.05.01z'/%3e%3cpath%20fill='%239a1b27'%20fill-rule='evenodd'%20d='M15.308%2020.512h4.126v-.233a3.7%203.7%200%200%200-.35-1.732%202.36%202.36%200%200%200-1.015-1.015%203.95%203.95%200%200%200-1.82-.35%203.07%203.07%200%200%200-2.227.781%202.72%202.72%200%200%200-.807%202.047%202.9%202.9%200%200%200%20.402%201.546c.239.41.59.744%201.014.96.53.224%201.103.328%201.678.302a4.06%204.06%200%200%200%201.886-.353%202.9%202.9%200%200%200%201.122-1.166l-2.027-.187q-.15.203-.359.34c-.175.1-.374.152-.576.152a.97.97%200%200%201-.779-.35%201.34%201.34%200%200%201-.268-.742m1.712-1.848c.2.242.314.544.32.858h-2.027c.013-.259.095-.51.238-.726a1.007%201.007%200%200%201%201.469-.132'%20clip-rule='evenodd'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"}},yL={class:"flex h-full grow flex-col justify-center"},bL=e.defineComponent({__name:"PaymentMethodDirectDebit",props:{paymentMethod:{},isDefault:{type:Boolean},options:{},variant:{default:"default"}},setup(t){const n=t,r=e.computed(()=>{var e;return(null==(e=n.paymentMethod.direct_debit)?void 0:e.variant)?vL[n.paymentMethod.direct_debit.variant]:void 0});return(n,o)=>{var i,a,l;return e.openBlock(),e.createBlock(iL,{"image-src":(null==(i=r.value)?void 0:i.logo)??e.unref(X$),"image-alt":null==(l=null==(a=r.value)?void 0:a.name)?void 0:l.toLowerCase(),variant:t.variant,options:t.options,"is-inactive":"INACTIVE"===t.paymentMethod.status},{default:e.withCtx(()=>[e.createElementVNode("div",yL,[e.createVNode(gc,{tag:"span",weight:"semibold","no-spacing":"",variant:"condensed"===t.variant?"body-xs":"body-sm",shade:"condensed"===t.variant?"light":void 0},{default:e.withCtx(()=>{var t;return[e.createTextVNode(e.toDisplayString(null==(t=r.value)?void 0:t.name),1)]}),_:1},8,["variant","shade"]),e.createVNode(aL,{"is-default":t.isDefault},null,8,["is-default"]),e.createVNode(lL,{"is-inactive":"INACTIVE"===t.paymentMethod.status},null,8,["is-inactive"])])]),_:1},8,["image-src","image-alt","variant","options","is-inactive"])}}}),wL={EPS:{name:"Electronic Payment Services",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cg%20clip-path='url(%23a)'%3e%3cpath%20fill='%23de378c'%20d='M40%200H0v40h40z'/%3e%3cpath%20fill='%23fff'%20fill-rule='evenodd'%20d='M17.214%2022.014c.483-.99%201.455-1.76%202.572-1.76s2.088.77%202.571%201.76zM19.784%207.5c2.605%200%204.716%202.185%204.716%204.881v1.367c0%20.176-.146.35-.315.35H22.45c-.17%200-.307-.174-.307-.35v-1.367c0-1.346-1.057-2.441-2.357-2.441s-2.357%201.095-2.357%202.441v1.367c0%20.176-.149.35-.318.35h-1.735c-.17%200-.304-.174-.304-.35v-1.5C15.14%209.614%2017.223%207.5%2019.784%207.5m-5.286%2017.406c.606%202.547%202.848%204.497%205.514%204.497h7.455a2.21%202.21%200%200%201-2.168%201.847H14.701c-1.21%200-2.201-1.047-2.201-2.289V18.085a2.21%202.21%200%200%201%202.201-2.228h10.598c1.21%200%202.201%201.016%202.201%202.259l-.01%208.332h-7.478c-1.146%200-2.14-.555-2.63-1.54H25.7v-1.413c0-3.213-2.569-5.824-5.7-5.824-2.662%200-4.901%201.892-5.512%204.433%200%200-.166.85-.166%201.405s.176%201.397.176%201.397'%20clip-rule='evenodd'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},IDEAL:{name:"iDEAL",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cpath%20fill='%23e664a5'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%23fff'%20d='M7.5%2010.417V29.18c0%20.914.753%201.613%201.613%201.613H20.35c8.494%200%2012.15-4.731%2012.15-11.022%200-6.29-3.656-11.021-12.15-11.021H9.166c-.914.054-1.667.807-1.667%201.667Z'/%3e%3cpath%20fill='%23c06'%20d='M15.027%2013.428v13.871h6.021c5.484%200%207.85-3.118%207.85-7.473%200-4.194-2.366-7.42-7.85-7.42h-5c-.537-.053-1.021.43-1.021%201.022'/%3e%3cpath%20fill='%23000'%20d='M20.35%2029.342h-9.732a1.56%201.56%200%200%201-1.559-1.56V11.868a1.56%201.56%200%200%201%201.56-1.559h9.731c9.247%200%2010.645%205.968%2010.645%209.516%200%206.13-3.764%209.517-10.645%209.517m-9.732-18.495a1.02%201.02%200%200%200-1.021%201.021v15.914a1.02%201.02%200%200%200%201.021%201.022h9.732c6.505%200%2010.107-3.226%2010.107-9.033%200-7.795-6.344-8.978-10.107-8.978l-9.731.054Z'/%3e%3cpath%20fill='%23fff'%20d='M17.178%2017.943c.215%200%20.43.054.591.108q.242.08.484.322l.322.484c.054.215.108.43.108.699s-.054.484-.108.645c-.053.215-.16.377-.268.538s-.27.269-.484.376c-.162.108-.43.108-.645.108h-1.452v-3.334zm-.054%202.688c.107%200%20.215%200%20.322-.053.108-.054.162-.108.27-.162.053-.107.16-.161.16-.322.054-.108.054-.27.054-.484%200-.162%200-.323-.054-.43-.053-.108-.107-.269-.16-.323-.055-.107-.162-.161-.27-.215-.107-.054-.268-.054-.43-.054h-.537v2.097zm4.516-2.688v.591h-1.774v.753h1.613v.538h-1.613v.806h1.774v.592h-2.527v-3.334zm2.473%200%201.237%203.333h-.753l-.27-.753h-1.236l-.269.753h-.752l1.237-3.333zm.054%202.043-.43-1.237-.43%201.237zm2.365-2.043v2.688h1.613v.592H25.78v-3.334c.053.054.752.054.752.054'/%3e%3cpath%20fill='%23000'%20d='M12.285%2021.115a1.506%201.506%200%201%200%200-3.011%201.506%201.506%200%200%200%200%203.011m1.183%206.184a2.294%202.294%200%200%201-2.312-2.312V23.16c0-.645.538-1.182%201.183-1.182s1.183.537%201.183%201.182l-.054%204.14Z'/%3e%3c/svg%3e"},PAY_BY_BANK:{name:"Open Banking / Pay by bank",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cg%20fill='%23101289'%20fill-rule='evenodd'%20clip-path='url(%23a)'%20clip-rule='evenodd'%3e%3cpath%20d='M18.235%2013.537c0-.08.068-.144.143-.144h.19l3.015%203.056h.007v-2.825c0-.08.06-.15.144-.15h.907c.076%200%20.144.07.144.15v5.355c0%20.08-.068.143-.144.143h-.12a.2.2%200%200%201-.1-.04l-2.985-3.158h-.007v2.967c0%20.08-.06.151-.144.151h-.9c-.075%200-.143-.071-.143-.151zM5.713%2017.849c.832%200%201.512-.716%201.512-1.583%200-.875-.68-1.6-1.512-1.6-.823%200-1.504.724-1.504%201.6%200%20.867.68%201.583%201.504%201.583m0-4.455c1.512%200%202.721%201.28%202.721%202.872%200%201.59-1.209%202.856-2.72%202.856C4.201%2019.122%203%2017.857%203%2016.266s1.202-2.872%202.713-2.872m5.511%202.466c.325%200%20.597-.27.597-.628a.59.59%200%200%200-.597-.59h-.718v1.218zm-1.897-2.236c0-.08.06-.15.144-.15h1.821c.93%200%201.693.795%201.693%201.758%200%20.986-.763%201.79-1.685%201.79h-.794v1.87c0%20.079-.068.15-.143.15H9.47a.147.147%200%200%201-.144-.15zm4.486%200c0-.08.06-.15.143-.15h3.13c.082%200%20.143.07.143.15v.868c0%20.08-.06.15-.144.15h-2.093v.987h1.723c.075%200%20.143.072.143.151v.868a.147.147%200%200%201-.143.15h-1.723v1.075h2.093c.083%200%20.144.071.144.15v.868c0%20.08-.06.151-.144.151h-3.129c-.083%200-.143-.071-.143-.151z'/%3e%3c/g%3e%3cg%20fill='%23101289'%20fill-rule='evenodd'%20clip-path='url(%23b)'%20clip-rule='evenodd'%3e%3cpath%20d='M4.918%2025.194c.295%200%20.545-.254.545-.58%200-.319-.325-.557-.62-.557H4.23v1.137zm-.098-2.171c.287%200%20.53-.255.53-.573a.526.526%200%200%200-.53-.541h-.59v1.114zm-1.768-2.109c0-.08.06-.151.143-.151h1.761c.892%200%201.625.644%201.625%201.48%200%20.613-.521%201.058-.876%201.257.4.175%201.012.565%201.012%201.297%200%20.89-.748%201.535-1.647%201.535H3.195c-.083%200-.143-.071-.143-.15zm7.22%203.509-.575-1.313H9.69l-.567%201.313zm-3.107%201.702%202.366-5.354c.023-.048.076-.088.128-.088h.076c.053%200%20.106.04.129.088l2.365%205.354c.046.104-.015.207-.128.207h-.84c-.135%200-.196-.047-.264-.199l-.272-.628H8.67l-.272.636a.28.28%200%200%201-.272.191h-.831c-.114%200-.174-.103-.129-.207Zm5.789-5.298c0-.08.068-.144.143-.144h.19l3.015%203.055h.007v-2.824c0-.08.06-.151.144-.151h.907c.076%200%20.144.072.144.151v5.354c0%20.08-.068.144-.144.144h-.12a.2.2%200%200%201-.1-.04l-2.985-3.159h-.007v2.968c0%20.08-.06.151-.144.151h-.9c-.075%200-.143-.071-.143-.151zm5.716.127c0-.103.076-.191.182-.191h.884c.098%200%20.181.088.181.191v2.092l1.678-2.203c.03-.04.099-.08.144-.08h.952c.144%200%20.22.175.136.294l-1.768%202.331%201.927%202.642c.083.12%200%20.294-.144.294H21.8c-.053%200-.12-.032-.136-.056l-1.746-2.498v2.371c0%20.104-.083.191-.181.191h-.884c-.106%200-.182-.087-.182-.19v-5.188Zm5.188-.04c0-.08.068-.151.143-.151h.908c.075%200%20.143.072.143.151v5.267c0%20.08-.068.151-.143.151H24c-.075%200-.143-.071-.143-.151v-5.267Zm2.375-.087c0-.08.068-.144.143-.144h.19l3.015%203.055h.008v-2.824c0-.08.06-.151.144-.151h.906c.076%200%20.144.072.144.151v5.354c0%20.08-.068.144-.144.144h-.12a.2.2%200%200%201-.099-.04l-2.985-3.159h-.008v2.968c0%20.08-.06.151-.144.151h-.899c-.076%200-.143-.071-.143-.151zm8.13-.136c.635%200%201.33.279%201.844.748a.144.144%200%200%201%20.016.215l-.598.668a.153.153%200%200%201-.203.008c-.288-.278-.62-.382-.99-.382-.825%200-1.49.732-1.49%201.607%200%20.868.673%201.584%201.497%201.584.219%200%20.446-.032.673-.128v-.46h-.477a.14.14%200%200%201-.143-.144v-.788c0-.087.06-.151.143-.151h1.52c.075%200%20.136.072.136.151l.007%202.14a.2.2%200%200%201-.06.128s-.779.517-1.875.517c-1.504%200-2.713-1.257-2.713-2.849%200-1.59%201.21-2.864%202.713-2.864'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M3%2013.394h20.73v5.923H3z'/%3e%3c/clipPath%3e%3cclipPath%20id='b'%3e%3cpath%20fill='%23fff'%20d='M3%2020.683h33.563v5.923H3z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"},TRUSTLY:{name:"Trustly",logo:"data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='40'%20height='40'%20fill='none'%3e%3cg%20clip-path='url(%23a)'%3e%3cmask%20id='b'%20width='40'%20height='40'%20x='0'%20y='0'%20maskUnits='userSpaceOnUse'%20style='mask-type:luminance'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/mask%3e%3cg%20mask='url(%23b)'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%2310303f'%20d='M0%200h40v40H0z'/%3e%3cpath%20fill='%2368de7a'%20d='M7.5%2018.75h8.75v-6.875l6.875%206.875-6.875%206.875v3.75H25V18.75h7.5v-8.125h-25z'/%3e%3c/g%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='a'%3e%3cpath%20fill='%23fff'%20d='M0%200h40v40H0z'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e"}},kL={class:"flex h-full grow flex-col justify-center"},xL=e.defineComponent({__name:"PaymentMethodOnlineBanking",props:{paymentMethod:{},i18n:{},isDefault:{type:Boolean},variant:{default:"default"}},setup(t){const n=t,r=e.computed(()=>{var e;return(null==(e=n.paymentMethod.online_banking)?void 0:e.variant)?wL[n.paymentMethod.online_banking.variant]:void 0});return(n,o)=>{var i,a,l;return e.openBlock(),e.createBlock(iL,{"image-alt":(null==(i=r.value)?void 0:i.name)??(null==(a=t.i18n)?void 0:a.imageAlt)??"Bank transfer","image-src":(null==(l=r.value)?void 0:l.logo)??e.unref("data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='32'%20height='32'%20fill='none'%3e%3cpath%20fill='%23e1e2ff'%20d='M0%200h32v32H0z'/%3e%3cmask%20id='a'%20width='24'%20height='24'%20x='4'%20y='4'%20maskUnits='userSpaceOnUse'%20style='mask-type:alpha'%3e%3cpath%20fill='%23d9d9d9'%20d='M4%204h24v24H4z'/%3e%3c/mask%3e%3cg%20mask='url(%23a)'%3e%3cpath%20fill='%231f216a'%20d='M6.5%2022.5v-13h19v3.144H24l-4.606%204.606H10.25v1.5h7.644l-3.75%203.75zm3.75-7.75h5.5v-1.5h-5.5zm6.904%209.712v-1.27l6.38-6.38%201.27%201.269-6.381%206.38h-1.27Zm8.23-6.981-1.269-1.27.841-.84a.36.36%200%200%201%20.258-.117q.14%200%20.255.115l.758.758a.36.36%200%200%201%20.115.256.36.36%200%200%201-.116.257z'/%3e%3c/g%3e%3c/svg%3e"),variant:t.variant,"is-inactive":"INACTIVE"===t.paymentMethod.status},{default:e.withCtx(()=>[e.createElementVNode("div",kL,[e.createVNode(gc,{tag:"span",weight:"semibold","no-spacing":"",variant:"condensed"===t.variant?"body-xs":"body-sm",shade:"condensed"===t.variant?"light":void 0},{default:e.withCtx(()=>{var n;return[e.createTextVNode(e.toDisplayString(null==(n=r.value)?void 0:n.name)+" ",1),"SETUP"===t.paymentMethod.status?(e.openBlock(),e.createBlock(e.unref(mc),{key:0,size:"sm",class:"font-normal ml-1"},{default:e.withCtx(()=>{var n;return[e.createTextVNode(e.toDisplayString((null==(n=t.i18n)?void 0:n.pendingLabel)??"Pending"),1)]}),_:1})):e.createCommentVNode("",!0)]}),_:1},8,["variant","shade"]),"default"===t.variant?(e.openBlock(),e.createBlock(gc,{key:0,tag:"span",variant:"body-xs",shade:"lighter","no-spacing":""},{default:e.withCtx(()=>{var n,r;return[e.createTextVNode(e.toDisplayString((null==(n=t.paymentMethod.online_banking)?void 0:n.iban)??(null==(r=t.i18n)?void 0:r.onlineBankingLabel)??"Online banking"),1)]}),_:1})):e.createCommentVNode("",!0),e.createVNode(aL,{"is-default":t.isDefault},null,8,["is-default"]),e.createVNode(lL,{"is-inactive":"INACTIVE"===t.paymentMethod.status},null,8,["is-inactive"])])]),_:1},8,["image-alt","image-src","variant","is-inactive"])}}}),_L=e.defineComponent({__name:"PaymentMethod",props:{paymentMethod:{},variant:{},i18n:{}},setup:t=>(n,r)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,["CARD"===t.paymentMethod.type?(e.openBlock(),e.createBlock(hL,e.mergeProps({key:0},n.$attrs,{"payment-method":t.paymentMethod,variant:t.variant,"is-default":t.paymentMethod.is_default}),null,16,["payment-method","variant","is-default"])):e.createCommentVNode("",!0),"ONLINE_BANKING"===t.paymentMethod.type?(e.openBlock(),e.createBlock(xL,e.mergeProps({key:1},n.$attrs,{"payment-method":t.paymentMethod,variant:t.variant,"is-default":t.paymentMethod.is_default}),null,16,["payment-method","variant","is-default"])):e.createCommentVNode("",!0),"BUY_NOW_PAY_LATER"===t.paymentMethod.type?(e.openBlock(),e.createBlock(dL,e.mergeProps({key:2},n.$attrs,{"payment-method":t.paymentMethod,variant:t.variant,"is-default":t.paymentMethod.is_default}),null,16,["payment-method","variant","is-default"])):e.createCommentVNode("",!0),"DIRECT_DEBIT"===t.paymentMethod.type?(e.openBlock(),e.createBlock(bL,e.mergeProps({key:3},n.$attrs,{"payment-method":t.paymentMethod,variant:t.variant,"is-default":t.paymentMethod.is_default}),null,16,["payment-method","variant","is-default"])):e.createCommentVNode("",!0),"DIGITAL_WALLET"===t.paymentMethod.type?(e.openBlock(),e.createBlock(gL,e.mergeProps({key:4},n.$attrs,{"payment-method":t.paymentMethod,variant:t.variant,"is-default":t.paymentMethod.is_default}),null,16,["payment-method","variant","is-default"])):e.createCommentVNode("",!0)],64))});const CL="Authorization",EL="Content-Type",SL="X-Request-Id",BL=(...e)=>{};class NL extends Error{}function ML(e){let t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return function(e){return decodeURIComponent(atob(e).replace(/(.)/g,(e,t)=>{let n=t.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n}))}(t)}catch(n){return atob(t)}}NL.prototype.name="InvalidTokenError";const TL=e=>{try{return function(e,t){if("string"!=typeof e)throw new NL("Invalid token specified: must be a string");t||(t={});const n=!0===t.header?0:1,r=e.split(".")[n];if("string"!=typeof r)throw new NL(`Invalid token specified: missing part #${n+1}`);let o;try{o=ML(r)}catch(hR){throw new NL(`Invalid token specified: invalid base64 for part #${n+1} (${hR.message})`)}try{return JSON.parse(o)}catch(hR){throw new NL(`Invalid token specified: invalid json for part #${n+1} (${hR.message})`)}}(e)}catch{return}},VL={apiUrls:{identity:"https://api.beta-solvimon.com/v1",config:"https://api.beta-solvimon.com/v1",transaction:"https://api.beta-solvimon.com/v1",event:"https://api.beta-solvimon.com/v1"}},AL={apiUrls:{identity:"https://dev.solvimon.com:10016/v1",config:"https://dev.solvimon.com:10010/v1",transaction:"https://dev.solvimon.com:10014/v1",event:"https://dev.solvimon.com:10012/v1"}},zL={apiUrls:{identity:"https://identity.solvimon.com/v1",config:"https://api.solvimon.com/v1",transaction:"https://api.solvimon.com/v1",event:"https://api.solvimon.com/v1"}},OL={apiUrls:{identity:"https://identity.solvimon.com/v1",config:"https://test.api.solvimon.com/v1",transaction:"https://test.api.solvimon.com/v1",event:"https://test.api.solvimon.com/v1"}},IL="localhost",DL={apiUrls:{identity:`https://${IL}:5173/identity`,config:`https://${IL}:5173/config`,transaction:`https://${IL}:5173/transaction`,event:`https://${IL}:5173/event`}},PL=Symbol("config"),$L=()=>{const t=e.inject(PL);if(!t)throw new Error("ConfigProvider is not provided");return t};const LL=Symbol("auth"),RL=t=>{const n=e.ref(),r=e.ref(),{getAccessToken:o,refreshAccessToken:i}=function(){const e=$L(),t=UL({enableAccessCheck:!1});return{getAccessToken:n=>t({url:`${e.apiUrls.identity}/oauth/token`,options:{method:"POST"},data:{token_alias:n}}),refreshAccessToken:()=>t({url:`${e.apiUrls.identity}/oauth/refresh-token`,options:{method:"POST"}})}}(),a=async()=>{const{tokenUserName:e}=function(e){try{const t=atob(e),n=t.lastIndexOf(".");if(-1===n)throw new Error("Invalid token");const[r,o]=[t.substring(0,n),t.substring(n+1)];return{tokenUserName:r,portalUrlResourceId:o}}catch(t){throw new Error("Invalid token")}}(t);try{n.value=(await o(e)).access_token}catch(r){}},l=()=>{i()};e.onMounted(()=>{a(),r.value=setInterval(()=>s(),3e4)}),e.onBeforeUnmount(()=>{clearInterval(r.value),r.value=void 0});const s=()=>{const e=n.value&&TL(n.value);if(!e)return void l();e.exp-(new Date).getTime()/1e3<60&&l()};return{accessToken:n}},HL=e.defineComponent({__name:"AuthProvider",props:{token:{type:String}},setup(t){const n=RL(t.token);return e.provide(LL,n),(t,r)=>e.unref(n).accessToken.value?e.renderSlot(t.$slots,"default",{key:0}):e.createCommentVNode("",!0)}}),FL=()=>{const t=e.inject(LL);if(!t)throw new Error("AuthProvider is not provided");return t},jL={method:"GET"};function UL({enableAccessCheck:e}={enableAccessCheck:!0}){const{onError:t}=Dt(),n=e?{[CL]:`Bearer ${FL().accessToken.value}`}:{},r=({headers:e={}})=>{const t={[EL]:"application/json",...n};return e&&Object.entries(e).forEach(([e,n])=>{null===n?delete t[e]:t[e]=n}),t};return async function({url:e,data:n,options:o,query:i}){const a={...jL,...o},l=new URL(e);Object.entries(i??{}).forEach(([e,t])=>{l.searchParams.append(e,`${t}`)});try{const e=await fetch(l.toString(),{method:a.method,headers:r({headers:a.headers}),credentials:"omit",body:n?JSON.stringify(n):void 0});if("application/pdf"===e.headers.get("Content-Type"))return e.blob();if("application/json"!==e.headers.get("Content-Type"))return e.text();try{const t=await e.json();if(!e.ok)throw{hasError:!0,statusCode:e.status,message:null==t?void 0:t.message,requestId:e.headers.get(SL),field:null==t?void 0:t.field};return t}catch(s){throw null==t||t(new Error("Failed to parse JSON response",{cause:s})),{hasError:!0,statusCode:e.status,requestId:e.headers.get(SL)}}}catch(s){return null==t||t(new Error("Request failed",{cause:s})),Promise.reject(s)}}}const GL=Symbol("experimentalFeature"),qL=["express-checkout"],ZL=Symbol("sdkLogger");function WL(e){if(e)return e instanceof Error?{name:e.name,message:e.message,stack:e.stack,cause:e.cause}:"object"==typeof e?{name:"name"in e&&"string"==typeof e.name?e.name:void 0,message:"message"in e&&"string"==typeof e.message?e.message:String(e),stack:"stack"in e&&"string"==typeof e.stack?e.stack:void 0,cause:"cause"in e?e.cause:void 0}:{message:String(e)}}function KL(e={},t,n){return{componentName:t,environment:n,url:window.location.href,...e}}const JL=Symbol("hostElement"),YL=()=>{const t=e.inject(JL);if(!t)throw new Error("HostElementProvider is not provided");return t},XL=Symbol("requestActionDispatch");const QL=Symbol("portalObject"),eR={"download_button.download_failed_message":"Download mislukt, probeer later nog een keer","customer_billing_information.billing_address_label":"Factuuradres","customer_billing_information.email_address_label":"E-mailadres","customer_billing_information.name_label":"Naam","customer_billing_information.title":"Facturatiegegevens","customer_billing_information.vat_number_label":"Btw-nummer","customer_overview.billing_information.no_billing_information_available":"Geen facturatiegegevens beschikbaar.","generic.not_available":"N/B","invoice.add_invoice_line":"Factuurregel toevoegen","invoice.adjustment_chip_body":"Aanpassing","invoice.already_deducted_table_heading":"Reeds afgetrokken","invoice.amount_discount":"{amount} korting","invoice.amount_due_table_heading":"Te betalen bedrag","invoice.amount_table_heading":"Bedrag","invoice.commitment_heading":"Verplichting","invoice.commitment":"verplichting","invoice.discounts_table_heading":"Kortingen","invoice.download_pdf_button":"PDF downloaden","invoice.due_on_label":"Vervaldatum {date}","invoice.header.customer_title":"Klant","invoice.header.due_date_title":"Vervaldatum","invoice.header.e_invoice_error":"E-factuur fout","invoice.header.e_invoice_status_title":"E-factuur status","invoice.header.invoice_date_title":"Factuurdatum","invoice.header.invoice_number_title":"Factuurnummer","invoice.header.invoice_type_title":"Factuurtype","invoice.header.multiple_subscriptions_chip_body":"Meerdere abonnementen","invoice.header.original_invoice_title":"Originele factuur","invoice.header.po_number_title":"Inkoopordernummer","invoice.header.subscription_title":"Abonnement","invoice.header.supplier_title":"Leverancier","invoice.line.band_maximum_number":"Maximum aantal","invoice.line.band_minimum_amount":"Minimaal bedrag","invoice.line.band_minimum_number":"Minimum aantal","invoice.line.excl.tax":"Excl. belasting","invoice.line.incl.tax":"Incl. belasting","invoice.line.original_currency":"Oorspronkelijke valuta","invoice.line.included":"inbegrepen","invoice.line.pass_through":"Doorbelast","invoice.line.price_bound_maximum_amount":"Maximum bedrag","invoice.line.price_bound_within_bounds":"Binnen grenzen","invoice.line.units_included":"inbegrepen eenheden","invoice.markup_percentage":"{percentage}% opslag","invoice.markups_table_heading":"Opslagen","invoice.paid_chip":"Betaald","invoice.percentage_discount":"{percentage}% korting","invoice.service_period_heading":"Diensten over periode - {start_at} - {end_at}","invoice.table_header.base amount":"Basisbedrag","invoice.table_header.discount":"Korting","invoice.table_header.markup":"Opslag","invoice.table_header.price_amount":"Prijsbedrag","invoice.table_header.price":"Prijs","invoice.table_header.quantity":"Aantal","invoice.table_header.sub_total":"Subtotaal","invoice.table_header.tax amount":"Belastingbedrag","invoice.table_header.tax type":"Belastingtype","invoice.table_header.tax_percentage":"Percentage","invoice.table_header.tax_rate":"Belastingtarief","invoice.table_header.total_excluding_taxes":"Totaal exclusief belastingen","invoice.table_header.total_including_taxes":"Totaal inclusief belastingen","invoice.table_header.total":"Totaal","invoice.table_header.unit":"Eenheid","invoice.table_heading.commitments":"Verplichtingen","invoice.table_heading.discounts":"Kortingen","invoice.table_heading.markups":"Opslagen","invoice.table_heading.one_offs":"Eenmalige posten","invoice.table_heading.products":"Producten","invoice.tax_notes.local_vat_applied_for_missing_tax_id":"Lokale btw toegepast in plaats van verleggingsregeling omdat het btw-nummer van de klant ontbreekt en dit een intracommunautaire levering is","invoice.tax_notes.reverse_charge_outside_eu":"Geen BTW – Dienst geleverd buiten de EU (art. 44 EU-btw-richtlijn)","invoice.tax_notes.no_charge_provided_outside_eu":"Geen BTW in rekening gebracht – diensten geleverd buiten de EU","invoice.tax_notes.reverse_charge":"Verleggingsregeling - Art. 196 van de btw-richtlijn 2006/112/EG","invoice.tax_notes.reverse_charge_tax_registration":"[1] - Verleggingsregeling","invoice.tax_notes.reverse_charge_tax_registration_outside_eu":"Buiten het toepassingsgebied van de EU-btw-heffing","invoice.tax_notes.not_applicable_article":"Btw niet van toepassing – Artikel 294, lid 1 van het CGI","invoice.taxes_table_heading":"Belastingen","invoice.title":"Details","invoice.totals_table_heading":"Totalen","pricing_detail.billing_cycle":"Billing cycle"},tR={"47FYwb":"Cancel",N2IrpM:"Confirm",Vl9vDx:"units","customer_billing_information.billing_address_label":"Billing address","customer_billing_information.email_address_label":"Email address","customer_billing_information.name_label":"Name","customer_billing_information.title":"Billing information","customer_billing_information.vat_number_label":"VAT number","customer_overview.billing_information.no_billing_information_available":"No billing information to display.","download_button.download_failed_message":"Download failed, please try again later","editor.placeholder":"Enter text or type ‘/’ for commands","editorComponent.entityDetailsFallbackTitles.customerTitle":"Customer details","editorComponent.entityDetailsFallbackTitles.supplierTitle":"Supplier details","editorComponent.slashCommands.addCustomerDetailsDescription":"Insert customer details block","editorComponent.slashCommands.addCustomerDetailsTitle":"Add Customer Details","editorComponent.slashCommands.addPartyDetailsDescription":"Insert customer and supplier details in one row","editorComponent.slashCommands.addPartyDetailsTitle":"Add Party Details","editorComponent.slashCommands.addSupplierDetailsDescription":"Insert supplier details block","editorComponent.slashCommands.addSupplierDetailsTitle":"Add Supplier Details","editorComponent.slashCommands.customerFallbackTitle":"Customer details","editorComponent.slashCommands.dividerDescription":"Insert a horizontal rule","editorComponent.slashCommands.dividerTitle":"Divider","editorComponent.slashCommands.headingDescription":"Start writing with heading.","editorComponent.slashCommands.headingTitle":"Heading","editorComponent.slashCommands.supplierFallbackTitle":"Supplier details","editorComponent.slashCommands.textDescription":"Start writing with plain text","editorComponent.slashCommands.textTitle":"Text","error_notification.default_error_message":"Something went wrong","form_validation.tax_id.invalid_format":"Invalid tax ID format. Example: {example}","generic.not_available":"N/A","invoice.add_invoice_line":"Add invoice line","invoice.adjustment_chip_body":"Adjustment","invoice.already_deducted_table_heading":"Already deducted","invoice.amount_discount":"{amount} discount","invoice.amount_due_table_heading":"Amount due","invoice.amount_table_heading":"Amount","invoice.commitment":"commitment","invoice.commitment_heading":"Commitment","invoice.discounts_table_heading":"Discounts","invoice.download_pdf_button":"Download PDF","invoice.due_on_label":"Due on {date}","invoice.line.band_maximum_number":"Maximum number","invoice.line.band_minimum_amount":"Band minimum amount","invoice.line.band_minimum_number":"Minimum number","invoice.line.excl.tax":"Excl. tax","invoice.line.incl.tax":"Incl. tax","invoice.line.included":"included","invoice.line.original_currency":"Original currency","invoice.line.pass_through":"Pass through","invoice.line.price_bound_maximum_amount":"Maximum amount","invoice.line.price_bound_within_bounds":"Within bounds","invoice.line.units_included":"units included","invoice.markup_percentage":"{percentage}% markup","invoice.markups_table_heading":"Markups","invoice.paid_chip":"Paid","invoice.paid_on_label":"Paid on {date}","invoice.percentage_discount":"{percentage}% discount","invoice.service_period_heading":"Service period - {start_at} - {end_at}","invoice.table_header.base amount":"Base amount","invoice.table_header.discount":"Discount","invoice.table_header.markup":"Markup","invoice.table_header.price":"Price","invoice.table_header.quantity":"Quantity","invoice.table_header.sub_total":"Subtotal","invoice.table_header.tax amount":"Tax amount","invoice.table_header.tax type":"Tax type","invoice.table_header.tax_percentage":"Percentage","invoice.table_header.tax_rate":"Tax rate","invoice.table_header.total":"Total","invoice.table_header.total_excluding_taxes":"Total excluding taxes","invoice.table_header.total_including_taxes":"Total including taxes","invoice.table_header.total_including_taxes_customer_facing":"Total due today","invoice.table_header.unit":"Unit","invoice.table_heading.commitments":"Commitments","invoice.table_heading.discounts":"Discounts","invoice.table_heading.markups":"Markups","invoice.table_heading.one_offs":"One-off's","invoice.table_heading.products":"Products","invoice.tax_notes.local_vat_applied_for_missing_tax_id":"Local VAT applied instead of reverse charge mechanism because customer VAT number is missing and this is an intra-EU sale","invoice.tax_notes.no_charge_provided_outside_eu":"No VAT charged – services provided outside the EU","invoice.tax_notes.not_applicable_article":"TVA non applicable – Article 294, 1 du CGI","invoice.tax_notes.reverse_charge":"Reverse charge - Art 196 of the VAT Directive 2006/ 112/EC","invoice.tax_notes.reverse_charge_outside_eu":"No VAT – Service supplied outside the EU (Art. 44 EU VAT Directive)","invoice.tax_notes.reverse_charge_tax_registration":"[1] - Reverse charge","invoice.tax_notes.reverse_charge_tax_registration_outside_eu":"Out of scope for EU VAT","invoice.taxes_table_heading":"Taxes","invoice.title":"Details","invoice.totals_table_heading":"Totals","invoice_preview.after_trial_heading":"After trial","invoice_preview.taxes_heading":"Taxes","invoice_preview.taxes_not_determined_by_billing_information_tooltip":"Will be determined by billing information","invoice_preview.total_due_today_heading":"Total due today","invoice_preview.total_excluding_taxes_heading":"Total excluding taxes","invoice_preview.total_including_taxes_heading":"Total including taxes","invoice_preview.total_paid_heading":"Total paid",lWOCGz:"unit","payment_methods.default_chip.label":"Default","payment_methods.inactive_chip.label":"Inactive","pricing_detail.billing_cycle":"Billing cycle",pricing_item_pricing:"{pricing} per {billing_period}","pricing_item_pricing.flat_top_up":"Flat top up pricing","pricing_item_pricing.none":"Not billed","pricing_item_pricing.pass_through":"Pass through pricing","pricing_item_pricing.per_seat":"Per seat","pricing_item_pricing.stair_step":"Stair step pricing","pricing_item_pricing.tiered":"Tiered pricing","pricing_item_pricing.tiered_top_up":"Tiered top up pricing","pricing_item_pricing.top_tiered":"Top tiered pricing","pricing_item_pricing.unsupported_pricing_error":"Unsupported pricing","promotion.code.expiry":"Never expires","slashCommandList.emptyState":"No matching commands","taxId.invalid":"Invalid tax ID","time_period.day.full":"daily","time_period.day.plural":"days","time_period.day.singular":"day","time_period.month.full":"monthly","time_period.month.plural":"months","time_period.month.singular":"month","time_period.week.full":"weekly","time_period.week.plural":"weeks","time_period.week.singular":"week","time_period.year.full":"yearly","time_period.year.plural":"years","time_period.year.singular":"year","timezone_select.option.inherit_from_platform":"Inherit from platform","ui.CalloutRow.moreActions":"More actions"},nR=e.defineComponent({__name:"ActionDispatchProvider",setup(t){const n=function(){const{hostRef:e}=YL();return(t,n)=>{const r=e.value;if(!r)return!0;const o=new CustomEvent("action-request",{detail:t,bubbles:!0,composed:!0,cancelable:!0}),i=r.dispatchEvent(o);return!i&&n&&n.preventDefault(),i}}();return e.provide(XL,n),(t,n)=>e.renderSlot(t.$slots,"default")}}),rR=e.defineComponent({__name:"LoggerProvider",props:{logLevel:{type:String},onLog:{type:Function,default:()=>{}}},setup(t){const n=t,{customElementName:r,hostRef:o}=YL(),{environment:i}=$L(),a=function(e,t){const n={debug:10,info:20,warn:30,error:40},r=(null==t?void 0:t.minLevel)??"info",o=(t,o,i,a,l)=>{if(n[t]<n[r])return;const s={schemaVersion:1,level:t,code:o,message:i,timestamp:(new Date).toISOString(),context:a,error:l,errorSerialized:WL(l)};e(s)};return{debug:(e,n,r)=>{o("debug",e,n,KL(r,null==t?void 0:t.customElementName,null==t?void 0:t.environment))},info:(e,n,r)=>{o("info",e,n,KL(r,null==t?void 0:t.customElementName,null==t?void 0:t.environment))},warn:(e,n,r,i)=>{o("warn",e,n,KL(r,null==t?void 0:t.customElementName,null==t?void 0:t.environment),i)},error:(e,n,r,i)=>{o("error",e,n,KL(r,null==t?void 0:t.customElementName,null==t?void 0:t.environment),i)},capture:(e,t)=>{const n=(null==t?void 0:t.code)??"UNHANDLED_ERROR",r=(null==t?void 0:t.message)??"Unhandled error",{code:i,message:a,...l}=t??{};o("error",n,r,l,e)}}}(function(e,t){return n=>{e(n),t.value&&t.value.dispatchEvent(new CustomEvent("log",{detail:n,bubbles:!0,cancelable:!0,composed:!0}))}}(n.onLog,o),{minLevel:n.logLevel,customElementName:r,environment:i});return e.provide(ZL,a),(t,n)=>e.renderSlot(t.$slots,"default")}}),oR=e.defineComponent({__name:"ExperimentalFeatureProvider",props:{experimentalFeatures:{type:Array}},setup(t){const n=((t=[])=>e.computed(()=>Object.assign({},...qL.map(e=>({[e]:t.includes(e)})))))(t.experimentalFeatures);return e.provide(GL,n),(t,n)=>e.renderSlot(t.$slots,"default")}}),iR=e.defineComponent({__name:"TeleportProvider",setup:t=>(t,n)=>(e.openBlock(),e.createBlock(e.unref(Fz),null,{default:e.withCtx(()=>[e.createVNode(e.unref(sA),null,{default:e.withCtx(()=>[e.renderSlot(t.$slots,"default")]),_:3})]),_:3}))}),aR={"sdk.invoice.paid_on_label":"Betaald op {date}","sdk.invoice_details.customer_billing_information.title":"Jouw factuur gegevens","sdk.invoice_details.invoice.download_pdf":"Download de PDF voor een volledig overzicht","sdk.invoice_details.invoice.title":"Factuur","sdk.invoice_details.invoice_details_block.due_date":"Vervaldatum","sdk.invoice_details.invoice_details_block.invoice_date":"Factuurdatum","sdk.invoice_details.invoice_details_block.title":"Factuurgegevens","sdk.invoice_details.payment_history.payment_attempt":"Betaalpoging","sdk.invoice_details.payment_history.title":"Betaalgeschiedenis","checkout.order_summary_block.billing_period.label":"Gefactureerd per {period}","checkout.order_summary_block.billing_period.sub_label":"{amount} per {period}","checkout.order_summary_block.billing_period.quarterly":"Gefactureerd per kwartaal"},lR={123456:"Select one product","checkout.address.city.placeholder":"City...","checkout.address.line1.placeholder":"Address line 1...","checkout.address.line2.placeholder":"Address line 2...","checkout.address.portal_code.placeholder":"Postal code...","checkout.address.state.placeholder":"State...","checkout.address.title":"Billing address","checkout.agreement.subscription":"{subscription_amount}/{billing_period} until canceled, starting {start_date, date, long}.","checkout.agreement.trial":"{discounted_amount} for {trial_period}, then {subscription_amount}/{billing_period} until canceled, starting {start_date, date, ::MMMMd}.","checkout.agreement.trial.free":"Free","checkout.billing_details.add_billing_details_button.label":"More billing details","checkout.billing_details.remove_billing_details_button.label":"Remove billing details","checkout.company_purchase_toggle.sub_title":"I am purchasing on behalf of a company","checkout.company_purchase_toggle.title":"Company purchase","checkout.contact_information_block.title":"Customer information","checkout.country.label":"Billing country","checkout.customize_plan_block.title":"Customize plan","checkout.email_address.label":"Email address","checkout.email_address.placeholder":"Email address...","checkout.express_payment_methods.divider_text":"Or","checkout.express_payment_methods.title":"Subscribe instantly with","checkout.invoice_preview.no_country_selected_message":"Please select a country first","checkout.invoice_preview.usage_based_message":"+ Usage","checkout.kpi.encrypted_payments.label":"Secure and encrypted payments","checkout.legal_name.label":"Legal entity name","checkout.legal_name.placeholder":"Legal entity name...","checkout.not_available.contact_support_message":"this page to try again, or contact customer support.","checkout.not_available.description":"The checkout is currently not available.","checkout.not_available.reload_button":"Reload","checkout.not_available.title":"Checkout not available","checkout.optional_suffix.label":"(optional)","checkout.order_summary_block.title":"Order summary","checkout.page_title":"Pay and subscribe","checkout.pay_and_subscribe_button.label":"Pay and subscribe","checkout.pay_and_subscribe_button_trial.label":"Start trial","checkout.payment_method_block.no_country_selected_message":"Payment methods will be shown after you select the billing country.","checkout.payment_method_block.no_country_selected_title":"Select your billing country","checkout.payment_method_block.no_payment_methods_available_message":"There are no available payment methods. Please contact support for more information.","checkout.payment_method_block.no_payment_methods_available_title":"No payment methods available","checkout.payment_method_block.title":"Payment method","checkout.payment_methods.no_country_selected_message":"Select a country to see the available payment methods","checkout.promotion_code.add_label":"Add promotion code","checkout.promotion_code.applied_label":"Promotion applied","checkout.promotion_code.applied_status":"Promotion code applied","checkout.promotion_code.apply_aria_label":"Apply promotion code","checkout.promotion_code.apply_button":"Apply","checkout.promotion_code.input_aria_label":"Promotion code","checkout.promotion_code.placeholder":"Promotion code","checkout.promotion_code.remove_aria_label":"Remove promotion code","checkout.promotion_code.removed_status":"Promotion code removed","checkout.subscription_description":"You will be billed <strong>{price}</strong> per {period_name}, starting today.","checkout.trial.label":"Trial","checkout.trial_period_description":"You will be billed <strong>{price}</strong> per {period_name}, starting {startDate, date, long}.","checkout.vat_number.label":"VAT number","checkout.vat_number.placeholder":"VAT number...","customer.invoice_table.pay_invoice_button.label":"Pay","customer.subscriptions_block.cancel_button_label":"Cancel subscription","customer.subscriptions_block.next_billing_date":"Next billing date","customer.subscriptions_block.renew_button_label":"Renew subscription","customer.subscriptions_block.show_details_button_label":"Subscription details","customer_invoices.load_failed.subtitle":"Please refresh or contact support.","customer_invoices.load_failed.title":"We can’t load your invoices","customer_overview.billing_information_block.load_failed.subtitle":"Please refresh or contact support.","customer_overview.billing_information_block.load_failed.title":"We can’t load your billing information","customer_overview.billing_information_block.title":"Billing information","customer_overview.billing_information_block.view_all_payment_methods_link_label":"Edit","customer_overview.invoices_block.no_active_subscription_content":"You haven’t received an invoice yet. It’ll appear here once it’s generated.","customer_overview.invoices_block.no_invoices_title":"No invoices to display","customer_overview.invoices_block.title":"Invoices","customer_overview.invoices_block.view_all_invoices_link_label":"View all","customer_overview.payment_methods.title":"Payment methods","customer_overview.payment_methods_block.add_payment_method_button_label":"Add payment method","customer_overview.payment_methods_block.add_payment_method_helper_text":"Add a payment method for recurring invoice payments.","customer_overview.payment_methods_block.load_failed.subtitle":"Please refresh or contact support.","customer_overview.payment_methods_block.load_failed.title":"We can’t load your payment methods","customer_overview.payment_methods_block.view_all_payment_methods_link_label":"View all","customer_overview.subscriptions_block.fallback_subscription_name":"Subscription","customer_overview.subscriptions_block.load_failed.subtitle":"Please refresh or contact support.","customer_overview.subscriptions_block.load_failed.title":"We can’t load your subscriptions","customer_overview.subscriptions_block.no_active_subscription_content":"There’s no active subscription to display.","customer_overview.subscriptions_block.no_active_subscription_title":"No subscriptions","customer_overview.subscriptions_block.title":"My subscriptions","customer_overview.subscriptions_block.view_all_button_label":"View all","empty_state.retry.button":"Refresh","invoice_preview.taxes_not_determined_by_billing_information_tooltip":"Will be determined by billing information","invoice_table.chip.paid":"Paid","invoice_table.header.amount":"Amount","invoice_table.header.date":"Date","invoice_table.header.invoice_number":"Invoice","invoice_table.header.status":"Status","payment_completed_card.redirect_message":"You are being redirected...","payment_completed_card.title.authorize":"Payment successful","payment_completed_card.title.tokenize":"Your payment method is added","payment_integration_form.select_payment_method_error":"Select a payment method","payments.retry_button.label":"Try again",pricing_item_pricing:"{pricing} per {billing_period}","pricing_item_pricing.flat_top_up":"Flat top up pricing","pricing_item_pricing.none":"Not billed","pricing_item_pricing.pass_through":"Pass through pricing","pricing_item_pricing.per_seat":"Per seat","pricing_item_pricing.stair_step":"Stair step pricing","pricing_item_pricing.tiered":"Tiered pricing","pricing_item_pricing.tiered_top_up":"Tiered top up pricing","pricing_item_pricing.top_tiered":"Top tiered pricing","pricing_item_pricing.unsupported_pricing_error":"Unsupported pricing","sdk.invoice_details.customer_billing_information.title":"Your billing information","sdk.invoice_details.invoice.download_pdf":"Download the PDF for a full breakdown","sdk.invoice_details.invoice.title":"Invoice","sdk.invoice_details.invoice_details_block.due_date":"Due date","sdk.invoice_details.invoice_details_block.invoice_date":"Invoice date","sdk.invoice_details.invoice_details_block.title":"Invoice details","sdk.invoice_details.payment_history.payment_attempt":"Payment attempt","sdk.invoice_details.payment_history.title":"Payment history","seats.label":"Seats","seats.price_per_seat_period":"{amount} per seat/{period}","seats.tiered_price_per_seat_period":"{amount} per seat/{period}","seats.tiered_pricing_label":"Tiered pricing","seats.tiered_range_label":"{lower_bound} - {upper_bound} seats","seats.tiered_unbounded_range_label":"> {lower_bound} seats","subscription_payment_completed_card.continue":"Continue to merchant","subscription_payment_completed_card.thank_you_for_subscribing":"Thank you for subscribing.","subscription_payment_completed_card.title":"Payment successful"},sR=e.defineComponent({__name:"ConfigProvider",props:{environment:{type:String}},setup(t){const n={environment:r=t.environment,...{CI:DL,LIVE:zL,TEST:OL,BETA:VL,DEV:AL}[r]};var r;return e.provide(PL,n),(t,n)=>e.renderSlot(t.$slots,"default")}}),cR=e.defineComponent({__name:"HostElementProvider",props:{customElementName:{type:String}},setup(t){const n=e.ref(null);return e.onMounted(()=>{var t,r;const o=null==(r=null==(t=e.getCurrentInstance())?void 0:t.vnode)?void 0:r.el;if(o&&"object"==typeof o&&o instanceof Node){const e=o.getRootNode();n.value=e instanceof ShadowRoot?function(e){return e.host instanceof HTMLElement?e.host:null}(e):o.parentElement??null}else n.value=null}),e.onUnmounted(()=>{n.value=null}),e.provide(JL,{hostRef:n,customElementName:t.customElementName}),(t,n)=>e.renderSlot(t.$slots,"default")}}),dR=e.defineComponent({__name:"PortalProvider",props:{portalObject:{type:Object},allowedPortalTypes:{type:Array}},setup(t){const n=t;return e.provide(QL,e.toRef(n.portalObject)),(n,r)=>t.portalObject?e.renderSlot(n.$slots,"default",{key:0}):e.createCommentVNode("",!0)}}),uR=e.defineComponent({__name:"Provider",props:{environment:{type:String},locale:{type:String},dateLocale:{type:String},messages:{type:Object},showTimezones:{type:Boolean},primaryColor:{type:String},secondaryColor:{type:String},isShadowRoot:{type:Boolean},experimentalFeatures:{type:Array},logLevel:{type:String},onLog:{type:Function},allowedPortalTypes:{type:Array},portalObject:{type:Object},customElementName:{type:String}},emits:["error"],setup(t){const n=t;if(!n.environment)throw new Error("environment is required");if(!n.portalObject)throw new Error("portalObject is required");if(!n.customElementName)throw new Error("customElementName is required");const r={"nl-NL":{...eR,...aR},"en-US":{...tR,...lR}},o=e.computed(()=>{if(!n.locale||!(n.locale in r))return r["en-US"];return r[n.locale]}),i=e.computed(()=>({...o.value,...n.messages}));return(r,o)=>(e.openBlock(),e.createBlock(cR,{"custom-element-name":n.customElementName},{default:e.withCtx(()=>[e.createVNode(nR,null,{default:e.withCtx(()=>[e.createVNode(e.unref(FB),{onError:e.unref(BL)},{default:e.withCtx(()=>[e.createVNode(iR,null,{default:e.withCtx(()=>[e.createVNode(e.unref(xx),{"primary-color":t.primaryColor,"secondary-color":t.secondaryColor,"is-shadow-root":""},null,8,["primary-color","secondary-color"]),t.environment?(e.openBlock(),e.createBlock(sR,{key:0,environment:t.environment},{default:e.withCtx(()=>[e.createVNode(rR,{"log-level":n.logLevel,"on-log":n.onLog},{default:e.withCtx(()=>[e.createVNode(HL,{token:t.portalObject.token},{default:e.withCtx(()=>[e.createVNode(oR,{"experimental-features":t.experimentalFeatures},{default:e.withCtx(()=>[e.createVNode(dR,{"allowed-portal-types":t.allowedPortalTypes,"portal-object":t.portalObject},{default:e.withCtx(()=>[e.createVNode(e.unref(mB),null,{default:e.withCtx(()=>[e.createVNode(e.unref(RB),{locale:t.locale,"date-locale":t.dateLocale,messages:i.value,"show-timezones":!1},{default:e.withCtx(()=>[e.renderSlot(r.$slots,"default")]),_:3},8,["locale","date-locale","messages"])]),_:3})]),_:3},8,["allowed-portal-types","portal-object"])]),_:3},8,["experimental-features"])]),_:3},8,["token"])]),_:3},8,["log-level","on-log"])]),_:3},8,["environment"])):e.createCommentVNode("",!0)]),_:3})]),_:3},8,["onError"])]),_:3})]),_:3},8,["custom-element-name"]))}});exports.ACTION_DISPATCHER_PROVIDER_INJECTION_KEY=XL,exports.EXPERIMENTAL_FEATURE_INJECTION_KEY=GL,exports.I18N_INJECTION_KEY=mx,exports.InvoiceTable=EP,exports.LOGGER_PROVIDER_INJECTION_KEY=ZL,exports.PORTAL_INJECTION_KEY=QL,exports.TableBody=yz,exports.TableHead=fz,exports.TableHeadRow=vz,exports.TooltipContent=_z,exports._sfc_main=_L,exports._sfc_main$1=uR,exports._sfc_main$1$=mA,exports._sfc_main$14=nO,exports._sfc_main$15=tO,exports._sfc_main$16=eO,exports._sfc_main$1J=sz,exports._sfc_main$1L=oz,exports._sfc_main$1T=JA,exports._sfc_main$1X=EA,exports._sfc_main$1Y=yA,exports._sfc_main$1f=Yz,exports._sfc_main$1g=qz,exports._sfc_main$1p=Nz,exports._sfc_main$1q=Bz,exports._sfc_main$1r=Sz,exports._sfc_main$1s=Cz,exports._sfc_main$1y=hz,exports._sfc_main$2=gc,exports._sfc_main$20=hA,exports._sfc_main$2H=gN,exports._sfc_main$2K=XB,exports._sfc_main$2L=YB,exports._sfc_main$2a=AV,exports._sfc_main$2b=CV,exports._sfc_main$2e=bV,exports._sfc_main$2j=dV,exports._sfc_main$2p=WT,exports._sfc_main$2q=ZT,exports._sfc_main$3=mc,exports._sfc_main$4=hc,exports._sfc_main$9=Y$,exports._sfc_main$E=rP,exports._sfc_main$a=W$,exports._sfc_main$e=G$,exports._sfc_main$t=BP,exports._sfc_main$u=SP,exports._sfc_main$w=_P,exports._sfc_main$z=kP,exports.convertDateRangeToTimePeriod=lB,exports.createRequestService=UL,exports.defineCustomElement=function(t,n={}){return e.defineCustomElement(t,{shadowRoot:!0,styles:[':root{--color-primary-50: #eff6ff;--color-primary-100: #dbeafe;--color-primary-200: #bfdbfe;--color-primary-300: #93c5fd;--color-primary-400: #60a5fa;--color-primary-500: #3b82f6;--color-primary-600: #2563eb;--color-primary-700: #1d4ed8;--color-primary-800: #1e40af;--color-primary-900: #1e3a8a;--color-secondary-50: #f0f0ff;--color-secondary-100: #e0e2ff;--color-secondary-200: #c5c8ff;--color-secondary-300: #adb2ff;--color-secondary-400: #9198f8;--color-secondary-500: #6b71d6;--color-secondary-600: #4a51b4;--color-secondary-700: #303692;--color-secondary-800: #1b2070;--color-secondary-900: #0c104e}.icon{font-family:md2-icons;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-webkit-font-feature-settings:"liga";-webkit-font-smoothing:antialiased}.font-regular{font-family:regular}.bg-\\[url\\(https\\:\\/\\/www\\.gstatic\\.com\\/instantbuy\\/svg\\/dark_gpay\\.svg\\)\\]{background-image:url(https://www.gstatic.com/instantbuy/svg/dark_gpay.svg)}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}html{--tw-text-opacity: 1;color:rgb(17 25 40 / var(--tw-text-opacity, 1));font-family:inter,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-size:1rem;line-height:1.5rem;-webkit-font-smoothing:auto;-moz-osx-font-smoothing:auto;--tw-bg-opacity: 1;background-color:rgb(245 245 245 / var(--tw-bg-opacity, 1))}.container{width:100%}@media(min-width:640px){.container{max-width:640px}}@media(min-width:768px){.container{max-width:768px}}@media(min-width:1024px){.container{max-width:1024px}}@media(min-width:1280px){.container{max-width:1280px}}@media(min-width:1536px){.container{max-width:1536px}}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.not-sr-only{position:static;width:auto;height:auto;padding:0;margin:0;overflow:visible;clip:auto;white-space:normal}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.\\!visible{visibility:visible!important}.visible{visibility:visible}.invisible{visibility:hidden}.collapse{visibility:collapse}.static{position:static}.fixed{position:fixed}.\\!absolute{position:absolute!important}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.-left-0{left:-0px}.-left-8{left:-2rem}.-top-2{top:-.5rem}.bottom-0{bottom:0}.left-0{left:0}.left-1\\/2{left:50%}.left-3\\.5{left:.875rem}.right-0{right:0}.right-2{right:.5rem}.right-3{right:.75rem}.top-0{top:0}.top-1\\/2{top:50%}.top-2{top:.5rem}.top-3{top:.75rem}.top-\\[50\\%\\]{top:50%}.isolate{isolation:isolate}.isolation-auto{isolation:auto}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-50{z-index:50}.z-\\[1000\\]{z-index:1000}.z-\\[999\\]{z-index:999}.order-1{order:1}.order-2{order:2}.\\!col-span-2{grid-column:span 2 / span 2!important}.\\!col-span-3{grid-column:span 3 / span 3!important}.\\!col-span-6{grid-column:span 6 / span 6!important}.col-span-1{grid-column:span 1 / span 1}.col-span-2{grid-column:span 2 / span 2}.col-span-3{grid-column:span 3 / span 3}.col-span-6{grid-column:span 6 / span 6}.-m-2{margin:-.5rem}.m-\\[unset\\]{margin:unset}.-mx-1\\.5{margin-left:-.375rem;margin-right:-.375rem}.-mx-6{margin-left:-1.5rem;margin-right:-1.5rem}.-mx-9{margin-left:-2.25rem;margin-right:-2.25rem}.-my-1\\.5{margin-top:-.375rem;margin-bottom:-.375rem}.-my-2{margin-top:-.5rem;margin-bottom:-.5rem}.mx-1{margin-left:.25rem;margin-right:.25rem}.mx-1\\.5{margin-left:.375rem;margin-right:.375rem}.mx-2{margin-left:.5rem;margin-right:.5rem}.mx-auto{margin-left:auto;margin-right:auto}.my-1{margin-top:.25rem;margin-bottom:.25rem}.my-10{margin-top:2.5rem;margin-bottom:2.5rem}.my-2{margin-top:.5rem;margin-bottom:.5rem}.my-3{margin-top:.75rem;margin-bottom:.75rem}.my-4{margin-top:1rem;margin-bottom:1rem}.my-6{margin-top:1.5rem;margin-bottom:1.5rem}.my-8{margin-top:2rem;margin-bottom:2rem}.-mb-2{margin-bottom:-.5rem}.-ml-2{margin-left:-.5rem}.-ml-4{margin-left:-1rem}.-mr-3{margin-right:-.75rem}.-mt-0\\.5{margin-top:-.125rem}.-mt-2{margin-top:-.5rem}.mb-0{margin-bottom:0}.mb-1{margin-bottom:.25rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-4{margin-bottom:1rem}.mb-6{margin-bottom:1.5rem}.mb-8{margin-bottom:2rem}.ml-0{margin-left:0}.ml-0\\.5{margin-left:.125rem}.ml-1{margin-left:.25rem}.ml-2{margin-left:.5rem}.ml-3{margin-left:.75rem}.ml-4{margin-left:1rem}.ml-auto{margin-left:auto}.mr-1{margin-right:.25rem}.mr-1\\.5{margin-right:.375rem}.mr-2{margin-right:.5rem}.mr-4{margin-right:1rem}.mt-0\\.5{margin-top:.125rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-6{margin-top:1.5rem}.mt-8{margin-top:2rem}.mt-px{margin-top:1px}.line-clamp-1{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1}.\\!block{display:block!important}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.\\!flex{display:flex!important}.flex{display:flex}.inline-flex{display:inline-flex}.table{display:table}.inline-table{display:inline-table}.table-caption{display:table-caption}.table-cell{display:table-cell}.table-column{display:table-column}.table-column-group{display:table-column-group}.table-footer-group{display:table-footer-group}.table-header-group{display:table-header-group}.table-row-group{display:table-row-group}.table-row{display:table-row}.flow-root{display:flow-root}.grid{display:grid}.inline-grid{display:inline-grid}.contents{display:contents}.list-item{display:list-item}.\\!hidden{display:none!important}.hidden{display:none}.aspect-square{aspect-ratio:1 / 1}.size-2{width:.5rem;height:.5rem}.size-4{width:1rem;height:1rem}.\\!h-full{height:100%!important}.h-0{height:0px}.h-0\\.5{height:.125rem}.h-1{height:.25rem}.h-1\\.5{height:.375rem}.h-10{height:2.5rem}.h-11{height:2.75rem}.h-12{height:3rem}.h-14{height:3.5rem}.h-16{height:4rem}.h-2{height:.5rem}.h-2\\.5{height:.625rem}.h-3{height:.75rem}.h-3\\.5{height:.875rem}.h-4{height:1rem}.h-40{height:10rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-7{height:1.75rem}.h-72{height:18rem}.h-8{height:2rem}.h-9{height:2.25rem}.h-\\[14px\\]{height:14px}.h-\\[16px\\]{height:16px}.h-\\[1px\\]{height:1px}.h-\\[20px\\]{height:20px}.h-\\[22px\\]{height:22px}.h-\\[24px\\]{height:24px}.h-\\[32px\\]{height:32px}.h-\\[44px\\]{height:44px}.h-\\[48px\\]{height:48px}.h-\\[52px\\]{height:52px}.h-\\[88px\\]{height:88px}.h-full{height:100%}.h-px{height:1px}.max-h-48{max-height:12rem}.max-h-60{max-height:15rem}.max-h-64{max-height:16rem}.max-h-9{max-height:2.25rem}.max-h-\\[min\\(95vh\\,920px\\)\\]{max-height:min(95vh,920px)}.min-h-4{min-height:1rem}.min-h-48{min-height:12rem}.min-h-96{min-height:24rem}.min-h-\\[100px\\]{min-height:100px}.min-h-\\[130px\\]{min-height:130px}.min-h-\\[140px\\]{min-height:140px}.min-h-\\[180px\\]{min-height:180px}.min-h-\\[220px\\]{min-height:220px}.min-h-\\[44px\\]{min-height:44px}.min-h-\\[52px\\]{min-height:52px}.\\!w-5{width:1.25rem!important}.\\!w-6{width:1.5rem!important}.\\!w-7{width:1.75rem!important}.w-0{width:0px}.w-0\\.5{width:.125rem}.w-1{width:.25rem}.w-1\\.5{width:.375rem}.w-1\\/3{width:33.333333%}.w-1\\/5{width:20%}.w-10{width:2.5rem}.w-11{width:2.75rem}.w-12{width:3rem}.w-14{width:3.5rem}.w-16{width:4rem}.w-2{width:.5rem}.w-2\\.5{width:.625rem}.w-2\\/5{width:40%}.w-24{width:6rem}.w-3{width:.75rem}.w-3\\.5{width:.875rem}.w-3\\/5{width:60%}.w-36{width:9rem}.w-4{width:1rem}.w-4\\/5{width:80%}.w-40{width:10rem}.w-48{width:12rem}.w-5{width:1.25rem}.w-6{width:1.5rem}.w-60{width:15rem}.w-64{width:16rem}.w-7{width:1.75rem}.w-8{width:2rem}.w-9{width:2.25rem}.w-96{width:24rem}.w-\\[14px\\]{width:14px}.w-\\[16px\\]{width:16px}.w-\\[1px\\]{width:1px}.w-\\[20\\%\\]{width:20%}.w-\\[20px\\]{width:20px}.w-\\[22px\\]{width:22px}.w-\\[24px\\]{width:24px}.w-\\[32px\\]{width:32px}.w-\\[48px\\]{width:48px}.w-\\[50px\\]{width:50px}.w-\\[80\\%\\]{width:80%}.w-auto{width:auto}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.w-px{width:1px}.min-w-0{min-width:0px}.min-w-4{min-width:1rem}.min-w-\\[var\\(--col-w\\)\\]{min-width:var(--col-w)}.min-w-full{min-width:100%}.max-w-2xl{max-width:42rem}.max-w-3xl{max-width:48rem}.max-w-4xl{max-width:56rem}.max-w-5xl{max-width:64rem}.max-w-6xl{max-width:72rem}.max-w-7xl{max-width:80rem}.max-w-80{max-width:20rem}.max-w-\\[920px\\]{max-width:920px}.max-w-full{max-width:100%}.max-w-lg{max-width:32rem}.max-w-md{max-width:28rem}.max-w-none{max-width:none}.max-w-screen-3xl{max-width:1800px}.max-w-sm{max-width:24rem}.max-w-xl{max-width:36rem}.max-w-xs{max-width:20rem}.flex-1{flex:1 1 0%}.flex-shrink{flex-shrink:1}.flex-shrink-0{flex-shrink:0}.shrink{flex-shrink:1}.shrink-0{flex-shrink:0}.flex-grow,.grow{flex-grow:1}.table-auto{table-layout:auto}.table-fixed{table-layout:fixed}.border-collapse{border-collapse:collapse}.-translate-x-1{--tw-translate-x: -.25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-x-1\\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-x-3\\.5{--tw-translate-x: -.875rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-x-7{--tw-translate-x: -1.75rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-0\\.5{--tw-translate-y: -.125rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1{--tw-translate-y: -.25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1\\/2{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-2{--tw-translate-y: -.5rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-6{--tw-translate-y: -1.5rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-x-3\\.5{--tw-translate-x: .875rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-1\\/2{--tw-translate-y: 50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-rotate-90{--tw-rotate: -90deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-0{--tw-rotate: 0deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-180{--tw-rotate: 180deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.\\!transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform-gpu{transform:translate3d(var(--tw-translate-x),var(--tw-translate-y),0) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-default{cursor:default}.cursor-grab{cursor:grab}.cursor-grabbing{cursor:grabbing}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.cursor-text{cursor:text}.touch-pinch-zoom{--tw-pinch-zoom: pinch-zoom;touch-action:var(--tw-pan-x) var(--tw-pan-y) var(--tw-pinch-zoom)}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize{resize:both}.list-none{list-style-type:none}.appearance-none{-webkit-appearance:none;-moz-appearance:none;appearance:none}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}.grid-cols-6{grid-template-columns:repeat(6,minmax(0,1fr))}.flex-row{flex-direction:row}.flex-row-reverse{flex-direction:row-reverse}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.flex-wrap{flex-wrap:wrap}.flex-nowrap{flex-wrap:nowrap}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.items-stretch{align-items:stretch}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-0{gap:0px}.gap-0\\.5{gap:.125rem}.gap-1{gap:.25rem}.gap-1\\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-6{gap:1.5rem}.gap-8{gap:2rem}.-space-x-px>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(-1px * var(--tw-space-x-reverse));margin-left:calc(-1px * calc(1 - var(--tw-space-x-reverse)))}.space-y-reverse>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 1}.space-x-reverse>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 1}.divide-x>:not([hidden])~:not([hidden]){--tw-divide-x-reverse: 0;border-right-width:calc(1px * var(--tw-divide-x-reverse));border-left-width:calc(1px * calc(1 - var(--tw-divide-x-reverse)))}.divide-y>:not([hidden])~:not([hidden]){--tw-divide-y-reverse: 0;border-top-width:calc(1px * calc(1 - var(--tw-divide-y-reverse)));border-bottom-width:calc(1px * var(--tw-divide-y-reverse))}.divide-y-reverse>:not([hidden])~:not([hidden]){--tw-divide-y-reverse: 1}.divide-x-reverse>:not([hidden])~:not([hidden]){--tw-divide-x-reverse: 1}.divide-gray-100>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(238 239 242 / var(--tw-divide-opacity, 1))}.divide-gray-200>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(229 231 235 / var(--tw-divide-opacity, 1))}.self-start{align-self:flex-start}.self-center{align-self:center}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-clip{overflow:clip}.overflow-visible{overflow:visible}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-x-scroll{overflow-x:scroll}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.text-ellipsis{text-overflow:ellipsis}.text-clip{text-overflow:clip}.whitespace-nowrap{white-space:nowrap}.text-wrap{text-wrap:wrap}.\\!rounded-full{border-radius:9999px!important}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-sm{border-radius:.125rem}.rounded-b{border-bottom-right-radius:.25rem;border-bottom-left-radius:.25rem}.rounded-b-none{border-bottom-right-radius:0;border-bottom-left-radius:0}.rounded-e{border-start-end-radius:.25rem;border-end-end-radius:.25rem}.rounded-l{border-top-left-radius:.25rem;border-bottom-left-radius:.25rem}.rounded-l-lg{border-top-left-radius:.5rem;border-bottom-left-radius:.5rem}.rounded-l-none{border-top-left-radius:0;border-bottom-left-radius:0}.rounded-r{border-top-right-radius:.25rem;border-bottom-right-radius:.25rem}.rounded-r-lg{border-top-right-radius:.5rem;border-bottom-right-radius:.5rem}.rounded-r-none{border-top-right-radius:0;border-bottom-right-radius:0}.rounded-s{border-start-start-radius:.25rem;border-end-start-radius:.25rem}.rounded-t{border-top-left-radius:.25rem;border-top-right-radius:.25rem}.rounded-t-none{border-top-left-radius:0;border-top-right-radius:0}.rounded-bl{border-bottom-left-radius:.25rem}.rounded-bl-md{border-bottom-left-radius:.375rem}.rounded-bl-none{border-bottom-left-radius:0}.rounded-br{border-bottom-right-radius:.25rem}.rounded-br-md{border-bottom-right-radius:.375rem}.rounded-br-none{border-bottom-right-radius:0}.rounded-ee{border-end-end-radius:.25rem}.rounded-es{border-end-start-radius:.25rem}.rounded-se{border-start-end-radius:.25rem}.rounded-ss{border-start-start-radius:.25rem}.rounded-tl{border-top-left-radius:.25rem}.rounded-tl-none{border-top-left-radius:0}.rounded-tr{border-top-right-radius:.25rem}.rounded-tr-none{border-top-right-radius:0}.border{border-width:1px}.border-0{border-width:0px}.border-2{border-width:2px}.border-4{border-width:4px}.border-x{border-left-width:1px;border-right-width:1px}.border-y{border-top-width:1px;border-bottom-width:1px}.border-b{border-bottom-width:1px}.border-b-0{border-bottom-width:0px}.border-e{border-inline-end-width:1px}.border-l{border-left-width:1px}.border-l-0{border-left-width:0px}.border-l-2{border-left-width:2px}.border-l-4{border-left-width:4px}.border-l-\\[2px\\]{border-left-width:2px}.border-r{border-right-width:1px}.border-r-0{border-right-width:0px}.border-s{border-inline-start-width:1px}.border-t{border-top-width:1px}.border-t-4{border-top-width:4px}.border-dashed{border-style:dashed}.border-none{border-style:none}.border-black{--tw-border-opacity: 1;border-color:rgb(0 0 0 / var(--tw-border-opacity, 1))}.border-blue-100{--tw-border-opacity: 1;border-color:rgb(219 234 254 / var(--tw-border-opacity, 1))}.border-blue-200{--tw-border-opacity: 1;border-color:rgb(191 219 254 / var(--tw-border-opacity, 1))}.border-blue-400{--tw-border-opacity: 1;border-color:rgb(96 165 250 / var(--tw-border-opacity, 1))}.border-blue-500{--tw-border-opacity: 1;border-color:rgb(59 130 246 / var(--tw-border-opacity, 1))}.border-blue-600{--tw-border-opacity: 1;border-color:rgb(37 99 235 / var(--tw-border-opacity, 1))}.border-gray-100{--tw-border-opacity: 1;border-color:rgb(238 239 242 / var(--tw-border-opacity, 1))}.border-gray-200{--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity, 1))}.border-gray-300{--tw-border-opacity: 1;border-color:rgb(209 213 219 / var(--tw-border-opacity, 1))}.border-gray-50{--tw-border-opacity: 1;border-color:rgb(243 244 246 / var(--tw-border-opacity, 1))}.border-gray-500{--tw-border-opacity: 1;border-color:rgb(107 114 128 / var(--tw-border-opacity, 1))}.border-gray-600{--tw-border-opacity: 1;border-color:rgb(75 85 99 / var(--tw-border-opacity, 1))}.border-gray-700{--tw-border-opacity: 1;border-color:rgb(55 65 81 / var(--tw-border-opacity, 1))}.border-green-500{--tw-border-opacity: 1;border-color:rgb(34 197 94 / var(--tw-border-opacity, 1))}.border-green-600{--tw-border-opacity: 1;border-color:rgb(22 163 74 / var(--tw-border-opacity, 1))}.border-pink-600{--tw-border-opacity: 1;border-color:rgb(219 39 119 / var(--tw-border-opacity, 1))}.border-primary-400{border-color:var(--color-primary-400)}.border-primary-500{border-color:var(--color-primary-500)}.border-primary-600{border-color:var(--color-primary-600)}.border-primary-800{border-color:var(--color-primary-800)}.border-primary-900{border-color:var(--color-primary-900)}.border-purple-600{--tw-border-opacity: 1;border-color:rgb(147 51 234 / var(--tw-border-opacity, 1))}.border-red-100{--tw-border-opacity: 1;border-color:rgb(254 226 226 / var(--tw-border-opacity, 1))}.border-red-500{--tw-border-opacity: 1;border-color:rgb(239 68 68 / var(--tw-border-opacity, 1))}.border-red-600{--tw-border-opacity: 1;border-color:rgb(220 38 38 / var(--tw-border-opacity, 1))}.border-transparent{border-color:transparent}.border-yellow-100{--tw-border-opacity: 1;border-color:rgb(254 249 195 / var(--tw-border-opacity, 1))}.border-yellow-400{--tw-border-opacity: 1;border-color:rgb(250 204 21 / var(--tw-border-opacity, 1))}.border-yellow-500{--tw-border-opacity: 1;border-color:rgb(234 179 8 / var(--tw-border-opacity, 1))}.border-b-gray-200{--tw-border-opacity: 1;border-bottom-color:rgb(229 231 235 / var(--tw-border-opacity, 1))}.border-opacity-5{--tw-border-opacity: .05}.border-opacity-50{--tw-border-opacity: .5}.\\!bg-\\[\\#ffc439\\]{--tw-bg-opacity: 1 !important;background-color:rgb(255 196 57 / var(--tw-bg-opacity, 1))!important}.\\!bg-black{--tw-bg-opacity: 1 !important;background-color:rgb(0 0 0 / var(--tw-bg-opacity, 1))!important}.\\!bg-primary-600{background-color:var(--color-primary-600)!important}.\\!bg-white{--tw-bg-opacity: 1 !important;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))!important}.bg-black{--tw-bg-opacity: 1;background-color:rgb(0 0 0 / var(--tw-bg-opacity, 1))}.bg-blue-100{--tw-bg-opacity: 1;background-color:rgb(219 234 254 / var(--tw-bg-opacity, 1))}.bg-blue-200{--tw-bg-opacity: 1;background-color:rgb(191 219 254 / var(--tw-bg-opacity, 1))}.bg-blue-300\\/80{background-color:#93c5fdcc}.bg-blue-400\\/25{background-color:#60a5fa40}.bg-blue-50{--tw-bg-opacity: 1;background-color:rgb(239 246 255 / var(--tw-bg-opacity, 1))}.bg-blue-50\\/40{background-color:#eff6ff66}.bg-blue-50\\/50{background-color:#eff6ff80}.bg-blue-50\\/70{background-color:#eff6ffb3}.bg-blue-600{--tw-bg-opacity: 1;background-color:rgb(37 99 235 / var(--tw-bg-opacity, 1))}.bg-blue-700{--tw-bg-opacity: 1;background-color:rgb(29 78 216 / var(--tw-bg-opacity, 1))}.bg-gray-100{--tw-bg-opacity: 1;background-color:rgb(238 239 242 / var(--tw-bg-opacity, 1))}.bg-gray-100\\/50{background-color:#eeeff280}.bg-gray-200{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity, 1))}.bg-gray-200\\/50{background-color:#e5e7eb80}.bg-gray-200\\/80{background-color:#e5e7ebcc}.bg-gray-200\\/90{background-color:#e5e7ebe6}.bg-gray-300{--tw-bg-opacity: 1;background-color:rgb(209 213 219 / var(--tw-bg-opacity, 1))}.bg-gray-400\\/50{background-color:#9ca3af80}.bg-gray-50{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity, 1))}.bg-gray-50\\/50{background-color:#f3f4f680}.bg-gray-500{--tw-bg-opacity: 1;background-color:rgb(107 114 128 / var(--tw-bg-opacity, 1))}.bg-gray-600{--tw-bg-opacity: 1;background-color:rgb(75 85 99 / var(--tw-bg-opacity, 1))}.bg-gray-700{--tw-bg-opacity: 1;background-color:rgb(55 65 81 / var(--tw-bg-opacity, 1))}.bg-gray-800{--tw-bg-opacity: 1;background-color:rgb(31 41 55 / var(--tw-bg-opacity, 1))}.bg-gray-900{--tw-bg-opacity: 1;background-color:rgb(17 25 40 / var(--tw-bg-opacity, 1))}.bg-green-100{--tw-bg-opacity: 1;background-color:rgb(220 252 231 / var(--tw-bg-opacity, 1))}.bg-green-200{--tw-bg-opacity: 1;background-color:rgb(187 247 208 / var(--tw-bg-opacity, 1))}.bg-green-700{--tw-bg-opacity: 1;background-color:rgb(21 128 61 / var(--tw-bg-opacity, 1))}.bg-indigo-100{--tw-bg-opacity: 1;background-color:rgb(224 231 255 / var(--tw-bg-opacity, 1))}.bg-indigo-200{--tw-bg-opacity: 1;background-color:rgb(199 210 254 / var(--tw-bg-opacity, 1))}.bg-inherit{background-color:inherit}.bg-neutral-100{--tw-bg-opacity: 1;background-color:rgb(245 245 245 / var(--tw-bg-opacity, 1))}.bg-orange-100{--tw-bg-opacity: 1;background-color:rgb(255 237 213 / var(--tw-bg-opacity, 1))}.bg-orange-200{--tw-bg-opacity: 1;background-color:rgb(254 215 170 / var(--tw-bg-opacity, 1))}.bg-orange-50{--tw-bg-opacity: 1;background-color:rgb(255 247 237 / var(--tw-bg-opacity, 1))}.bg-pink-100{--tw-bg-opacity: 1;background-color:rgb(252 231 243 / var(--tw-bg-opacity, 1))}.bg-pink-200{--tw-bg-opacity: 1;background-color:rgb(251 207 232 / var(--tw-bg-opacity, 1))}.bg-pink-700{--tw-bg-opacity: 1;background-color:rgb(190 24 93 / var(--tw-bg-opacity, 1))}.bg-primary-100{background-color:var(--color-primary-100)}.bg-primary-200{background-color:var(--color-primary-200)}.bg-primary-50{background-color:var(--color-primary-50)}.bg-primary-600{background-color:var(--color-primary-600)}.bg-purple-100{--tw-bg-opacity: 1;background-color:rgb(243 232 255 / var(--tw-bg-opacity, 1))}.bg-purple-200{--tw-bg-opacity: 1;background-color:rgb(233 213 255 / var(--tw-bg-opacity, 1))}.bg-purple-700{--tw-bg-opacity: 1;background-color:rgb(126 34 206 / var(--tw-bg-opacity, 1))}.bg-red-100{--tw-bg-opacity: 1;background-color:rgb(254 226 226 / var(--tw-bg-opacity, 1))}.bg-red-200{--tw-bg-opacity: 1;background-color:rgb(254 202 202 / var(--tw-bg-opacity, 1))}.bg-red-50{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity, 1))}.bg-red-500{--tw-bg-opacity: 1;background-color:rgb(239 68 68 / var(--tw-bg-opacity, 1))}.bg-red-700{--tw-bg-opacity: 1;background-color:rgb(185 28 28 / var(--tw-bg-opacity, 1))}.bg-secondary-100{background-color:var(--color-secondary-100)}.bg-secondary-200{background-color:var(--color-secondary-200)}.bg-teal-100{--tw-bg-opacity: 1;background-color:rgb(204 251 241 / var(--tw-bg-opacity, 1))}.bg-teal-200{--tw-bg-opacity: 1;background-color:rgb(153 246 228 / var(--tw-bg-opacity, 1))}.bg-teal-50{--tw-bg-opacity: 1;background-color:rgb(240 253 250 / var(--tw-bg-opacity, 1))}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.bg-white\\/80{background-color:#fffc}.bg-white\\/90{background-color:#ffffffe6}.bg-white\\/95{background-color:#fffffff2}.bg-yellow-100{--tw-bg-opacity: 1;background-color:rgb(254 249 195 / var(--tw-bg-opacity, 1))}.bg-yellow-200{--tw-bg-opacity: 1;background-color:rgb(254 240 138 / var(--tw-bg-opacity, 1))}.bg-yellow-50{--tw-bg-opacity: 1;background-color:rgb(254 252 232 / var(--tw-bg-opacity, 1))}.bg-yellow-800{--tw-bg-opacity: 1;background-color:rgb(133 77 14 / var(--tw-bg-opacity, 1))}.bg-\\[url\\(https\\:\\/\\/www\\.gstatic\\.com\\/instantbuy\\/svg\\/dark_gpay\\.svg\\)\\]{background-image:url(https://www.gstatic.com/instantbuy/svg/dark_gpay.svg)}.bg-gradient-to-b{background-image:linear-gradient(to bottom,var(--tw-gradient-stops))}.bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))}.bg-gradient-to-l{background-image:linear-gradient(to left,var(--tw-gradient-stops))}.bg-gradient-to-r{background-image:linear-gradient(to right,var(--tw-gradient-stops))}.bg-gradient-to-t{background-image:linear-gradient(to top,var(--tw-gradient-stops))}.bg-none{background-image:none}.from-black\\/\\[\\.06\\]{--tw-gradient-from: rgb(0 0 0 / .06) var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-gray-100{--tw-gradient-from: #EEEFF2 var(--tw-gradient-from-position);--tw-gradient-to: rgb(238 239 242 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-orange-600\\/20{--tw-gradient-from: rgb(234 88 12 / .2) var(--tw-gradient-from-position);--tw-gradient-to: rgb(234 88 12 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-peach-100\\/20{--tw-gradient-from: rgb(255 98 0 / .2) var(--tw-gradient-from-position);--tw-gradient-to: rgb(255 98 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.to-mint-100\\/20{--tw-gradient-to: rgb(0 254 249 / .2) var(--tw-gradient-to-position)}.to-transparent{--tw-gradient-to: transparent var(--tw-gradient-to-position)}.to-yellow-200\\/20{--tw-gradient-to: rgb(254 240 138 / .2) var(--tw-gradient-to-position)}.bg-\\[length\\:auto_42\\.5\\%\\]{background-size:auto 42.5%}.bg-cover{background-size:cover}.bg-center{background-position:center}.bg-repeat{background-repeat:repeat}.bg-no-repeat{background-repeat:no-repeat}.fill-blue-600{fill:#2563eb}.fill-gray-600{fill:#4b5563}.fill-green-500{fill:#22c55e}.fill-pink-600{fill:#db2777}.fill-primary-600{fill:var(--color-primary-600)}.fill-purple-600{fill:#9333ea}.fill-red-600{fill:#dc2626}.fill-white{fill:#fff}.fill-yellow-400{fill:#facc15}.object-contain{-o-object-fit:contain;object-fit:contain}.p-0{padding:0}.p-0\\.5{padding:.125rem}.p-1{padding:.25rem}.p-1\\.5{padding:.375rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-6{padding:1.5rem}.p-8{padding:2rem}.p-\\[1px\\]{padding:1px}.\\!px-0{padding-left:0!important;padding-right:0!important}.\\!py-0{padding-top:0!important;padding-bottom:0!important}.px-0{padding-left:0;padding-right:0}.px-0\\.5{padding-left:.125rem;padding-right:.125rem}.px-1{padding-left:.25rem;padding-right:.25rem}.px-1\\.5{padding-left:.375rem;padding-right:.375rem}.px-16{padding-left:4rem;padding-right:4rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\\.5{padding-left:.625rem;padding-right:.625rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-8{padding-left:2rem;padding-right:2rem}.px-9{padding-left:2.25rem;padding-right:2.25rem}.py-0{padding-top:0;padding-bottom:0}.py-0\\.5{padding-top:.125rem;padding-bottom:.125rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}.py-10{padding-top:2.5rem;padding-bottom:2.5rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-4{padding-top:1rem;padding-bottom:1rem}.py-5{padding-top:1.25rem;padding-bottom:1.25rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.pb-0{padding-bottom:0}.pb-2{padding-bottom:.5rem}.pb-3{padding-bottom:.75rem}.pb-4{padding-bottom:1rem}.pb-5{padding-bottom:1.25rem}.pb-6{padding-bottom:1.5rem}.pl-0{padding-left:0}.pl-1{padding-left:.25rem}.pl-10{padding-left:2.5rem}.pl-2{padding-left:.5rem}.pl-3{padding-left:.75rem}.pl-4{padding-left:1rem}.pr-2{padding-right:.5rem}.pr-3{padding-right:.75rem}.pr-4{padding-right:1rem}.pt-0{padding-top:0}.pt-1{padding-top:.25rem}.pt-1\\.5{padding-top:.375rem}.pt-2{padding-top:.5rem}.pt-3{padding-top:.75rem}.pt-4{padding-top:1rem}.pt-5{padding-top:1.25rem}.pt-6{padding-top:1.5rem}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.align-top{vertical-align:top}.align-middle{vertical-align:middle}.font-inter{font-family:inter,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji"}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-2xl{font-size:1.5rem;line-height:2rem}.text-2xs{font-size:.65rem;line-height:.9rem}.text-3xl{font-size:1.875rem;line-height:2.25rem}.text-4xl{font-size:2.25rem;line-height:2.5rem}.text-6xl{font-size:3.75rem;line-height:1}.text-\\[11px\\]{font-size:11px}.text-\\[9pt\\]{font-size:9pt}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-normal{font-weight:400}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.lowercase{text-transform:lowercase}.capitalize{text-transform:capitalize}.normal-case{text-transform:none}.italic{font-style:italic}.not-italic{font-style:normal}.normal-nums{font-variant-numeric:normal}.ordinal{--tw-ordinal: ordinal;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.slashed-zero{--tw-slashed-zero: slashed-zero;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.lining-nums{--tw-numeric-figure: lining-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.oldstyle-nums{--tw-numeric-figure: oldstyle-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.proportional-nums{--tw-numeric-spacing: proportional-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.tabular-nums{--tw-numeric-spacing: tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.diagonal-fractions{--tw-numeric-fraction: diagonal-fractions;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.stacked-fractions{--tw-numeric-fraction: stacked-fractions;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.leading-4{line-height:1rem}.leading-6{line-height:1.5rem}.leading-\\[0\\.5\\]{line-height:.5}.leading-none{line-height:1}.leading-normal{line-height:1.5}.leading-tight{line-height:1.25}.\\!text-gray-100{--tw-text-opacity: 1 !important;color:rgb(238 239 242 / var(--tw-text-opacity, 1))!important}.\\!text-gray-200{--tw-text-opacity: 1 !important;color:rgb(229 231 235 / var(--tw-text-opacity, 1))!important}.\\!text-inherit{color:inherit!important}.text-black\\/10{color:#0000001a}.text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity, 1))}.text-blue-600{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity, 1))}.text-blue-700{--tw-text-opacity: 1;color:rgb(29 78 216 / var(--tw-text-opacity, 1))}.text-blue-800{--tw-text-opacity: 1;color:rgb(30 64 175 / var(--tw-text-opacity, 1))}.text-blue-900{--tw-text-opacity: 1;color:rgb(30 58 138 / var(--tw-text-opacity, 1))}.text-gray-200{--tw-text-opacity: 1;color:rgb(229 231 235 / var(--tw-text-opacity, 1))}.text-gray-300{--tw-text-opacity: 1;color:rgb(209 213 219 / var(--tw-text-opacity, 1))}.text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity, 1))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity, 1))}.text-gray-600{--tw-text-opacity: 1;color:rgb(75 85 99 / var(--tw-text-opacity, 1))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity, 1))}.text-gray-800{--tw-text-opacity: 1;color:rgb(31 41 55 / var(--tw-text-opacity, 1))}.text-gray-900{--tw-text-opacity: 1;color:rgb(17 25 40 / var(--tw-text-opacity, 1))}.text-green-400{--tw-text-opacity: 1;color:rgb(74 222 128 / var(--tw-text-opacity, 1))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity, 1))}.text-green-600{--tw-text-opacity: 1;color:rgb(22 163 74 / var(--tw-text-opacity, 1))}.text-green-700{--tw-text-opacity: 1;color:rgb(21 128 61 / var(--tw-text-opacity, 1))}.text-green-800{--tw-text-opacity: 1;color:rgb(22 101 52 / var(--tw-text-opacity, 1))}.text-indigo-800{--tw-text-opacity: 1;color:rgb(55 48 163 / var(--tw-text-opacity, 1))}.text-inherit{color:inherit}.text-orange-500{--tw-text-opacity: 1;color:rgb(249 115 22 / var(--tw-text-opacity, 1))}.text-orange-700{--tw-text-opacity: 1;color:rgb(194 65 12 / var(--tw-text-opacity, 1))}.text-orange-800{--tw-text-opacity: 1;color:rgb(154 52 18 / var(--tw-text-opacity, 1))}.text-pink-600{--tw-text-opacity: 1;color:rgb(219 39 119 / var(--tw-text-opacity, 1))}.text-pink-800{--tw-text-opacity: 1;color:rgb(157 23 77 / var(--tw-text-opacity, 1))}.text-primary-600{color:var(--color-primary-600)}.text-primary-700{color:var(--color-primary-700)}.text-primary-800{color:var(--color-primary-800)}.text-primary-900{color:var(--color-primary-900)}.text-purple-600{--tw-text-opacity: 1;color:rgb(147 51 234 / var(--tw-text-opacity, 1))}.text-purple-800{--tw-text-opacity: 1;color:rgb(107 33 168 / var(--tw-text-opacity, 1))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.text-red-600{--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}.text-red-700{--tw-text-opacity: 1;color:rgb(185 28 28 / var(--tw-text-opacity, 1))}.text-red-800{--tw-text-opacity: 1;color:rgb(153 27 27 / var(--tw-text-opacity, 1))}.text-secondary-800{color:var(--color-secondary-800)}.text-slate-400{--tw-text-opacity: 1;color:rgb(148 163 184 / var(--tw-text-opacity, 1))}.text-slate-500{--tw-text-opacity: 1;color:rgb(100 116 139 / var(--tw-text-opacity, 1))}.text-slate-600{--tw-text-opacity: 1;color:rgb(71 85 105 / var(--tw-text-opacity, 1))}.text-teal-800{--tw-text-opacity: 1;color:rgb(17 94 89 / var(--tw-text-opacity, 1))}.text-transparent{color:transparent}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.text-white\\/70{color:#ffffffb3}.text-yellow-500{--tw-text-opacity: 1;color:rgb(234 179 8 / var(--tw-text-opacity, 1))}.text-yellow-600{--tw-text-opacity: 1;color:rgb(202 138 4 / var(--tw-text-opacity, 1))}.text-yellow-700{--tw-text-opacity: 1;color:rgb(161 98 7 / var(--tw-text-opacity, 1))}.text-yellow-800{--tw-text-opacity: 1;color:rgb(133 77 14 / var(--tw-text-opacity, 1))}.underline{text-decoration-line:underline}.overline{text-decoration-line:overline}.line-through{text-decoration-line:line-through}.\\!no-underline{text-decoration-line:none!important}.no-underline{text-decoration-line:none}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.subpixel-antialiased{-webkit-font-smoothing:auto;-moz-osx-font-smoothing:auto}.placeholder-gray-500::-moz-placeholder{--tw-placeholder-opacity: 1;color:rgb(107 114 128 / var(--tw-placeholder-opacity, 1))}.placeholder-gray-500::placeholder{--tw-placeholder-opacity: 1;color:rgb(107 114 128 / var(--tw-placeholder-opacity, 1))}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-\\[0\\.0001\\]{opacity:.0001}.shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-\\[inset_0_0_0_1px_var\\(--sm-color-primary\\)\\]{--tw-shadow: inset 0 0 0 1px var(--sm-color-primary);--tw-shadow-colored: inset 0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.\\!outline-none{outline:2px solid transparent!important;outline-offset:2px!important}.outline-none{outline:2px solid transparent;outline-offset:2px}.outline{outline-style:solid}.ring{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-1{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-2{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-inset{--tw-ring-inset: inset}.ring-blue-200{--tw-ring-opacity: 1;--tw-ring-color: rgb(191 219 254 / var(--tw-ring-opacity, 1))}.ring-primary-300{--tw-ring-color: var(--color-primary-300)}.ring-primary-600{--tw-ring-color: var(--color-primary-600)}.blur{--tw-blur: blur(8px);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.drop-shadow{--tw-drop-shadow: drop-shadow(0 1px 2px rgb(0 0 0 / .1)) drop-shadow(0 1px 1px rgb(0 0 0 / .06));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.drop-shadow-md{--tw-drop-shadow: drop-shadow(0 4px 3px rgb(0 0 0 / .07)) drop-shadow(0 2px 2px rgb(0 0 0 / .06));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.drop-shadow-sm{--tw-drop-shadow: drop-shadow(0 1px 1px rgb(0 0 0 / .05));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.grayscale{--tw-grayscale: grayscale(100%);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.invert{--tw-invert: invert(100%);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.sepia{--tw-sepia: sepia(100%);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.\\!filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)!important}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur{--tw-backdrop-blur: blur(8px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-blur-sm{--tw-backdrop-blur: blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-grayscale{--tw-backdrop-grayscale: grayscale(100%);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-invert{--tw-backdrop-invert: invert(100%);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-sepia{--tw-backdrop-sepia: sepia(100%);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-filter{-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-100{transition-duration:.1s}.duration-200{transition-duration:.2s}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.\\[appearance\\:textfield\\]{-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield}.first-letter\\:capitalize:first-letter{text-transform:capitalize}.selection\\:drop-shadow-sm *::-moz-selection{--tw-drop-shadow: drop-shadow(0 1px 1px rgb(0 0 0 / .05));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.selection\\:drop-shadow-sm *::selection{--tw-drop-shadow: drop-shadow(0 1px 1px rgb(0 0 0 / .05));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.selection\\:drop-shadow-sm::-moz-selection{--tw-drop-shadow: drop-shadow(0 1px 1px rgb(0 0 0 / .05));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.selection\\:drop-shadow-sm::selection{--tw-drop-shadow: drop-shadow(0 1px 1px rgb(0 0 0 / .05));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.placeholder\\:text-gray-900::-moz-placeholder{--tw-text-opacity: 1;color:rgb(17 25 40 / var(--tw-text-opacity, 1))}.placeholder\\:text-gray-900::placeholder{--tw-text-opacity: 1;color:rgb(17 25 40 / var(--tw-text-opacity, 1))}.before\\:absolute:before{content:var(--tw-content);position:absolute}.before\\:inset-0:before{content:var(--tw-content);top:0;right:0;bottom:0;left:0}.before\\:right-auto:before{content:var(--tw-content);right:auto}.before\\:w-1:before{content:var(--tw-content);width:.25rem}.before\\:content-\\[\\\'\\\'\\]:before{--tw-content: "";content:var(--tw-content)}.after\\:absolute:after{content:var(--tw-content);position:absolute}.after\\:inset-0:after{content:var(--tw-content);top:0;right:0;bottom:0;left:0}.after\\:left-0\\.5:after{content:var(--tw-content);left:.125rem}.after\\:top-0\\.5:after{content:var(--tw-content);top:.125rem}.after\\:h-3:after{content:var(--tw-content);height:.75rem}.after\\:h-4:after{content:var(--tw-content);height:1rem}.after\\:h-5:after{content:var(--tw-content);height:1.25rem}.after\\:h-6:after{content:var(--tw-content);height:1.5rem}.after\\:h-7:after{content:var(--tw-content);height:1.75rem}.after\\:w-3:after{content:var(--tw-content);width:.75rem}.after\\:w-4:after{content:var(--tw-content);width:1rem}.after\\:w-5:after{content:var(--tw-content);width:1.25rem}.after\\:w-6:after{content:var(--tw-content);width:1.5rem}.after\\:w-7:after{content:var(--tw-content);width:1.75rem}.after\\:rounded-full:after{content:var(--tw-content);border-radius:9999px}.after\\:border:after{content:var(--tw-content);border-width:1px}.after\\:border-gray-300:after{content:var(--tw-content);--tw-border-opacity: 1;border-color:rgb(209 213 219 / var(--tw-border-opacity, 1))}.after\\:bg-gray-200:after{content:var(--tw-content);--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity, 1))}.after\\:bg-white:after{content:var(--tw-content);--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.after\\:transition-all:after{content:var(--tw-content);transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.after\\:content-\\[\\"\\"\\]:after{--tw-content: "";content:var(--tw-content)}.first\\:whitespace-nowrap:first-child{white-space:nowrap}.first\\:pl-0:first-child{padding-left:0}.last\\:mb-0:last-child{margin-bottom:0}.last\\:border-b-0:last-child{border-bottom-width:0px}.last\\:border-r-0:last-child{border-right-width:0px}.last\\:pb-3:last-child{padding-bottom:.75rem}.first-of-type\\:rounded-l:first-of-type{border-top-left-radius:.25rem;border-bottom-left-radius:.25rem}.last-of-type\\:rounded-r:last-of-type{border-top-right-radius:.25rem;border-bottom-right-radius:.25rem}.checked\\:border-gray-300:checked{--tw-border-opacity: 1;border-color:rgb(209 213 219 / var(--tw-border-opacity, 1))}.checked\\:bg-gray-400:checked{--tw-bg-opacity: 1;background-color:rgb(156 163 175 / var(--tw-bg-opacity, 1))}.checked\\:bg-primary-600:checked{background-color:var(--color-primary-600)}.empty\\:hidden:empty{display:none}.focus-within\\:border-b:focus-within{border-bottom-width:1px}.focus-within\\:border-primary-500:focus-within{border-color:var(--color-primary-500)}.focus-within\\:bg-gray-50:focus-within{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity, 1))}.focus-within\\:bg-red-50:focus-within{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity, 1))}.focus-within\\:text-gray-900:focus-within{--tw-text-opacity: 1;color:rgb(17 25 40 / var(--tw-text-opacity, 1))}.focus-within\\:text-red-700:focus-within{--tw-text-opacity: 1;color:rgb(185 28 28 / var(--tw-text-opacity, 1))}.focus-within\\:opacity-100:focus-within{opacity:1}.focus-within\\:shadow-sm:focus-within{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.focus-within\\:outline:focus-within{outline-style:solid}.focus-within\\:outline-1:focus-within{outline-width:1px}.focus-within\\:outline-primary-500:focus-within{outline-color:var(--color-primary-500)}.focus-within\\:ring-primary-500:focus-within{--tw-ring-color: var(--color-primary-500)}.hover\\:cursor-default:hover{cursor:default}.hover\\:cursor-pointer:hover{cursor:pointer}.hover\\:border-gray-400:hover{--tw-border-opacity: 1;border-color:rgb(156 163 175 / var(--tw-border-opacity, 1))}.hover\\:bg-blue-100:hover{--tw-bg-opacity: 1;background-color:rgb(219 234 254 / var(--tw-bg-opacity, 1))}.hover\\:bg-blue-200:hover{--tw-bg-opacity: 1;background-color:rgb(191 219 254 / var(--tw-bg-opacity, 1))}.hover\\:bg-blue-700:hover{--tw-bg-opacity: 1;background-color:rgb(29 78 216 / var(--tw-bg-opacity, 1))}.hover\\:bg-blue-800:hover{--tw-bg-opacity: 1;background-color:rgb(30 64 175 / var(--tw-bg-opacity, 1))}.hover\\:bg-gray-100:hover{--tw-bg-opacity: 1;background-color:rgb(238 239 242 / var(--tw-bg-opacity, 1))}.hover\\:bg-gray-200:hover{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity, 1))}.hover\\:bg-gray-50:hover{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity, 1))}.hover\\:bg-green-200:hover{--tw-bg-opacity: 1;background-color:rgb(187 247 208 / var(--tw-bg-opacity, 1))}.hover\\:bg-green-800:hover{--tw-bg-opacity: 1;background-color:rgb(22 101 52 / var(--tw-bg-opacity, 1))}.hover\\:bg-pink-800:hover{--tw-bg-opacity: 1;background-color:rgb(157 23 77 / var(--tw-bg-opacity, 1))}.hover\\:bg-primary-700:hover{background-color:var(--color-primary-700)}.hover\\:bg-purple-800:hover{--tw-bg-opacity: 1;background-color:rgb(107 33 168 / var(--tw-bg-opacity, 1))}.hover\\:bg-red-200:hover{--tw-bg-opacity: 1;background-color:rgb(254 202 202 / var(--tw-bg-opacity, 1))}.hover\\:bg-red-50:hover{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity, 1))}.hover\\:bg-red-800:hover{--tw-bg-opacity: 1;background-color:rgb(153 27 27 / var(--tw-bg-opacity, 1))}.hover\\:bg-yellow-200:hover{--tw-bg-opacity: 1;background-color:rgb(254 240 138 / var(--tw-bg-opacity, 1))}.hover\\:bg-yellow-700:hover{--tw-bg-opacity: 1;background-color:rgb(161 98 7 / var(--tw-bg-opacity, 1))}.hover\\:font-semibold:hover{font-weight:600}.hover\\:text-blue-600:hover{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity, 1))}.hover\\:text-gray-700:hover{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity, 1))}.hover\\:text-gray-900:hover{--tw-text-opacity: 1;color:rgb(17 25 40 / var(--tw-text-opacity, 1))}.hover\\:text-white:hover{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.hover\\:underline:hover{text-decoration-line:underline}.hover\\:no-underline:hover{text-decoration-line:none}.hover\\:opacity-60:hover{opacity:.6}.hover\\:shadow-md:hover{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.checked\\:hover\\:bg-gray-500:hover:checked{--tw-bg-opacity: 1;background-color:rgb(107 114 128 / var(--tw-bg-opacity, 1))}.checked\\:hover\\:bg-primary-700:hover:checked{background-color:var(--color-primary-700)}.focus\\:border-transparent:focus{border-color:transparent}.focus\\:bg-blue-100:focus{--tw-bg-opacity: 1;background-color:rgb(219 234 254 / var(--tw-bg-opacity, 1))}.focus\\:bg-primary-50:focus{background-color:var(--color-primary-50)}.focus\\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\\:outline-0:focus{outline-width:0px}.focus\\:ring-0:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\\:ring-2:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\\:ring-4:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(4px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\\:ring-blue-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(147 197 253 / var(--tw-ring-opacity, 1))}.focus\\:ring-blue-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(96 165 250 / var(--tw-ring-opacity, 1))}.focus\\:ring-blue-500:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(59 130 246 / var(--tw-ring-opacity, 1))}.focus\\:ring-gray-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(209 213 219 / var(--tw-ring-opacity, 1))}.focus\\:ring-gray-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(156 163 175 / var(--tw-ring-opacity, 1))}.focus\\:ring-gray-50:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(243 244 246 / var(--tw-ring-opacity, 1))}.focus\\:ring-green-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(134 239 172 / var(--tw-ring-opacity, 1))}.focus\\:ring-green-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(74 222 128 / var(--tw-ring-opacity, 1))}.focus\\:ring-pink-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(249 168 212 / var(--tw-ring-opacity, 1))}.focus\\:ring-primary-300:focus{--tw-ring-color: var(--color-primary-300)}.focus\\:ring-primary-500:focus{--tw-ring-color: var(--color-primary-500)}.focus\\:ring-purple-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(216 180 254 / var(--tw-ring-opacity, 1))}.focus\\:ring-red-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(252 165 165 / var(--tw-ring-opacity, 1))}.focus\\:ring-red-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(248 113 113 / var(--tw-ring-opacity, 1))}.focus\\:ring-yellow-300:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(253 224 71 / var(--tw-ring-opacity, 1))}.focus\\:ring-yellow-400:focus{--tw-ring-opacity: 1;--tw-ring-color: rgb(250 204 21 / var(--tw-ring-opacity, 1))}.focus-visible\\:border-primary-600:focus-visible{border-color:var(--color-primary-600)}.focus-visible\\:bg-primary-50:focus-visible{background-color:var(--color-primary-50)}.focus-visible\\:ring-0:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus-visible\\:ring-1:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus-visible\\:ring-2:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus-visible\\:ring-blue-400:focus-visible{--tw-ring-opacity: 1;--tw-ring-color: rgb(96 165 250 / var(--tw-ring-opacity, 1))}.focus-visible\\:ring-primary-600:focus-visible{--tw-ring-color: var(--color-primary-600)}.active\\:scale-90:active{--tw-scale-x: .9;--tw-scale-y: .9;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.active\\:cursor-grabbing:active{cursor:grabbing}.active\\:shadow-sm:active{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.active\\:outline-none:active{outline:2px solid transparent;outline-offset:2px}.group:nth-child(odd) .group-odd\\:bg-gray-50{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity, 1))}.group:nth-child(odd) .group-odd\\:bg-gray-50\\/50{background-color:#f3f4f680}.group:nth-child(2n) .group-even\\:bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.group:focus-within .group-focus-within\\:visible{visibility:visible}.group:focus-within .group-focus-within\\:opacity-100{opacity:1}.group:hover .group-hover\\:visible{visibility:visible}.group:hover .group-hover\\:bg-gray-50{--tw-bg-opacity: 1;background-color:rgb(243 244 246 / var(--tw-bg-opacity, 1))}.group:hover .group-hover\\:opacity-100{opacity:1}.peer:checked~.peer-checked\\:bg-green-600{--tw-bg-opacity: 1;background-color:rgb(22 163 74 / var(--tw-bg-opacity, 1))}.peer:checked~.peer-checked\\:bg-orange-500{--tw-bg-opacity: 1;background-color:rgb(249 115 22 / var(--tw-bg-opacity, 1))}.peer:checked~.peer-checked\\:bg-primary-200{background-color:var(--color-primary-200)}.peer:checked~.peer-checked\\:bg-primary-600{background-color:var(--color-primary-600)}.peer:checked~.peer-checked\\:bg-purple-600{--tw-bg-opacity: 1;background-color:rgb(147 51 234 / var(--tw-bg-opacity, 1))}.peer:checked~.peer-checked\\:bg-red-600{--tw-bg-opacity: 1;background-color:rgb(220 38 38 / var(--tw-bg-opacity, 1))}.peer:checked~.peer-checked\\:bg-teal-600{--tw-bg-opacity: 1;background-color:rgb(13 148 136 / var(--tw-bg-opacity, 1))}.peer:checked~.peer-checked\\:bg-yellow-400{--tw-bg-opacity: 1;background-color:rgb(250 204 21 / var(--tw-bg-opacity, 1))}.peer:checked~.peer-checked\\:after\\:translate-x-full:after{content:var(--tw-content);--tw-translate-x: 100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.peer:checked~.peer-checked\\:after\\:border-white:after{content:var(--tw-content);--tw-border-opacity: 1;border-color:rgb(255 255 255 / var(--tw-border-opacity, 1))}.peer:focus~.peer-focus\\:outline-none{outline:2px solid transparent;outline-offset:2px}.peer:focus~.peer-focus\\:ring-4{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(4px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.peer:focus~.peer-focus\\:ring-green-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(134 239 172 / var(--tw-ring-opacity, 1))}.peer:focus~.peer-focus\\:ring-orange-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(253 186 116 / var(--tw-ring-opacity, 1))}.peer:focus~.peer-focus\\:ring-primary-300{--tw-ring-color: var(--color-primary-300)}.peer:focus~.peer-focus\\:ring-purple-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(216 180 254 / var(--tw-ring-opacity, 1))}.peer:focus~.peer-focus\\:ring-red-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(252 165 165 / var(--tw-ring-opacity, 1))}.peer:focus~.peer-focus\\:ring-teal-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(94 234 212 / var(--tw-ring-opacity, 1))}.peer:focus~.peer-focus\\:ring-yellow-300{--tw-ring-opacity: 1;--tw-ring-color: rgb(253 224 71 / var(--tw-ring-opacity, 1))}@media(min-width:640px){.sm\\:w-1\\/4{width:25%}.sm\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(min-width:768px){.md\\:inset-0{top:0;right:0;bottom:0;left:0}.md\\:\\!col-span-2{grid-column:span 2 / span 2!important}.md\\:\\!col-span-3{grid-column:span 3 / span 3!important}.md\\:col-span-2{grid-column:span 2 / span 2}.md\\:col-span-6{grid-column:span 6 / span 6}.md\\:mt-2{margin-top:.5rem}.md\\:block{display:block}.md\\:table-cell{display:table-cell}.md\\:list-item{display:list-item}.md\\:hidden{display:none}.md\\:h-auto{height:auto}.md\\:h-full{height:100%}.md\\:w-1\\/4{width:25%}.md\\:w-32{width:8rem}.md\\:w-80{width:20rem}.md\\:w-auto{width:auto}.md\\:shrink-0{flex-shrink:0}.md\\:flex-row{flex-direction:row}.md\\:gap-2{gap:.5rem}.md\\:py-2{padding-top:.5rem;padding-bottom:.5rem}}@media(min-width:1024px){.lg\\:mt-0{margin-top:0}.lg\\:w-72{width:18rem}.lg\\:flex-row{flex-direction:row}.lg\\:items-center{align-items:center}.lg\\:gap-2{gap:.5rem}.lg\\:gap-6{gap:1.5rem}}@media(min-width:1280px){.xl\\:order-1{order:1}.xl\\:order-2{order:2}.xl\\:col-span-1{grid-column:span 1 / span 1}.xl\\:col-span-3{grid-column:span 3 / span 3}.xl\\:w-1\\/6{width:16.666667%}.xl\\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.xl\\:gap-8{gap:2rem}}@media(prefers-color-scheme:dark){.dark\\:divide-gray-700>:not([hidden])~:not([hidden]){--tw-divide-opacity: 1;border-color:rgb(55 65 81 / var(--tw-divide-opacity, 1))}.dark\\:bg-gray-800{--tw-bg-opacity: 1;background-color:rgb(31 41 55 / var(--tw-bg-opacity, 1))}.dark\\:bg-green-800{--tw-bg-opacity: 1;background-color:rgb(22 101 52 / var(--tw-bg-opacity, 1))}.dark\\:bg-orange-700{--tw-bg-opacity: 1;background-color:rgb(194 65 12 / var(--tw-bg-opacity, 1))}.dark\\:bg-red-800{--tw-bg-opacity: 1;background-color:rgb(153 27 27 / var(--tw-bg-opacity, 1))}.dark\\:text-gray-400{--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity, 1))}.dark\\:text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity, 1))}.dark\\:text-green-200{--tw-text-opacity: 1;color:rgb(187 247 208 / var(--tw-text-opacity, 1))}.dark\\:text-orange-200{--tw-text-opacity: 1;color:rgb(254 215 170 / var(--tw-text-opacity, 1))}.dark\\:text-red-200{--tw-text-opacity: 1;color:rgb(254 202 202 / var(--tw-text-opacity, 1))}.dark\\:hover\\:bg-gray-700:hover{--tw-bg-opacity: 1;background-color:rgb(55 65 81 / var(--tw-bg-opacity, 1))}.dark\\:hover\\:text-white:hover{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}}.\\[\\&\\:\\:-webkit-inner-spin-button\\]\\:appearance-none::-webkit-inner-spin-button{-webkit-appearance:none;-moz-appearance:none;appearance:none}.\\[\\&\\:\\:-webkit-outer-spin-button\\]\\:appearance-none::-webkit-outer-spin-button{-webkit-appearance:none;-moz-appearance:none;appearance:none}.scroll-shadow-left .\\[\\.scroll-shadow-left_\\&\\]\\:opacity-100,.scroll-shadow-right .\\[\\.scroll-shadow-right_\\&\\]\\:opacity-100{opacity:1}',...t.styles??[],...n.styles??[]],...n})},exports.downloadFile=(e,t)=>{const n=window.URL.createObjectURL(e);Ex(n,t)},exports.formatAmount=Bx,exports.formatBillingPeriod=Mx,exports.formatEnum=Nx,exports.getApiError=function(e){return"field"in e?{[e.field]:e.message}:"message"in e?{_generic:e.message}:void 0},exports.getComponentName=function(e){return`solvimon-${e}`},exports.getCountryNameByCode=rB,exports.getCustomerCountry=e=>{var t,n;return KS(e)?null==(t=e.individual.residential_address)?void 0:t.country:WS(e)?null==(n=e.organization.registered_address)?void 0:n.country:void 0},exports.getPaginatedFullList=async e=>{let t=!0,n=1,r=[],o={data:[],links:{current:"",next:void 0},page:n,limit:50};for(;t;)o=await e(n),r=[...r,...o.data],t=!!o.links.next,n+=1;return{...o,data:r}},exports.isApiSuccessCollectionResponse=function(e){return"data"in e&&"links"in e},exports.isIndividual=KS,exports.isOrganization=WS,exports.isValidCountryCode=function(e){return!!_x.find(t=>t.key===e)},exports.objectDiff=({from:e,to:t,mode:n="shallow",nullifyEmptyValues:r=!1})=>"deep"===n?(({from:e,to:t,nullifyEmptyValues:n=!1})=>{const r={},o=(e,t,n)=>{const o=MC(t,n);return yS(e)?qx(o)?r[n]=[]:Jx(o)&&(r[n]={}):qx(o)?e[n]=[]:Jx(o)&&(e[n]={}),[yS(e)?r:e,n]},i=(e,t,r)=>{for(const n of oC(e)){const i=o(r,e,n);pS(t,n)||(i[0][i[1]]={from:MC(e,n)})}for(const[a,l]of lS(t)){const t=pS(e,a),s=o(r,e,a);if(t){const t=MC(e,a);vS(t,l)?delete s[0][s[1]]:jx(l)&&jx(t)?i(t,l,s[0][s[1]]):s[0][s[1]]=n&&!mS(l)?eB(l):l}else s[0][s[1]]=n?eB(l):l}};return i(e,t),r})({from:e,to:t,nullifyEmptyValues:r}):nB({from:e,to:t,nullifyEmptyValues:r}),exports.serializeQueryParams=function(e){const t=function(e){const t=new URLSearchParams;for(const n in e){const r=e[n];null!==r&&(Array.isArray(r)?r.forEach(e=>t.append(`${n}[]`,e)):""!==r&&t.append(n,r))}return t.toString()}(e);return""===t?"":`?${t}`},exports.trackSentryException=BL,exports.useConfig=$L,exports.useIntl=HB,exports.usePricingItem=LB,exports.useTimePeriod=$B,exports.useToggleList=vB,exports.useValidation=function(e,t,n){return e&&t?PB(e,t,{$autoDirty:!0,...n}):PB({$autoDirty:!0,...e})},exports.withExpand=function({initialParams:e={},expandParams:t,expand:n=!0}){return n?{...e,expand:t}:e},exports.withPagination=function(e,{page:t=1,pageSize:n,orderBy:r,orderDirection:o}){const i={...e??{},page:t.toString()};return n&&Object.assign(i,{limit:n}),r&&Object.assign(i,{order_by:r}),o&&Object.assign(i,{order_direction:o}),i};
|