@bbn/bbn 2.0.59 → 2.0.60

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/bbn.js CHANGED
@@ -1,2 +1,2 @@
1
- var bbn=function(e){"use strict";function t(e,t,r,o,i){return n(t,((e,t)=>{const n=e[t];if(void 0===n)throw new TypeError(Io(t));return n})(e,t),r,o,i)}function n(e,t,n,r,o,i){const a=M(t,n,r);if(o&&t!==a)throw new RangeError(Eo(e,t,n,r,i));return a}function r(e){return null!==e&&/object|function/.test(typeof e)}function o(e,t=Map){const n=new t;return(t,...r)=>{if(n.has(t))return n.get(t);const o=e(t,...r);return n.set(t,o),o}}function i(e){return a({name:e},1)}function a(e,t){return l(e=>({value:e,configurable:1,writable:!t}),e)}function s(e){return l(e=>({get:e,configurable:1}),e)}function c(e){return{[Symbol.toStringTag]:{value:e,configurable:1}}}function u(e,t){const n={};let r=e.length;for(const o of t)n[e[--r]]=o;return n}function l(e,t,n){const r={};for(const o in t)r[o]=e(t[o],o,n);return r}function f(e,t,n){const r={};for(let o=0;o<t.length;o++){const i=t[o];r[i]=e(i,o,n)}return r}function d(e,t,n){const r={};for(let o=0;o<e.length;o++)r[t[o]]=n[e[o]];return r}function h(e,t){const n=Object.create(null);for(const r of e)n[r]=t[r];return n}function m(e,t){for(const n of t)if(n in e)return 1;return 0}function p(e,t,n){for(const r of e)if(t[r]!==n[r])return 0;return 1}function g(e,t,n){const r={...n};for(let n=0;n<t;n++)r[e[n]]=0;return r}function b(e,...t){return(...n)=>e(...t,...n)}function w(e){return e[0].toUpperCase()+e.substring(1)}function y(e){return e.slice().sort()}function v(e,t){return String(t).padStart(e,"0")}function E(e,t){return Math.sign(e-t)}function M(e,t,n){return Math.min(Math.max(e,t),n)}function I(e,t){return[Math.floor(e/t),D(e,t)]}function D(e,t){return(e%t+t)%t}function S(e,t){return[k(e,t),T(e,t)]}function k(e,t){return Math.trunc(e/t)||0}function T(e,t){return e%t||0}function _(e){return.5===Math.abs(e%1)}function x(e,t,n){let r=0,o=0;for(let i=0;i<=t;i++){const t=e[n[i]],a=wi[i],s=bi/a,[c,u]=S(t,s);r+=u*a,o+=c}const[i,a]=S(r,bi);return[o+i,a]}function O(e,t,n){const r={};for(let o=t;o>=0;o--){const t=wi[o];r[n[o]]=k(e,t),e=T(e,t)}return r}function j(e){if(void 0!==e)return R(e)}function C(e){return L(R(e))}function R(e){return A($i(e))}function N(e,t){if(null==t)throw new RangeError(Io(e));return t}function P(e){if(!r(e))throw new TypeError(vo);return e}function Y(e,t,n=e){if(typeof t!==e)throw new TypeError(Mo(n,t));return t}function A(e,t="number"){if(!Number.isInteger(e))throw new RangeError(mo(t,e));return e||0}function L(e,t="number"){if(e<=0)throw new RangeError(po(t,e));return e}function F(e){if("symbol"==typeof e)throw new TypeError(yo);return String(e)}function H(e,t){return r(e)?String(e):Zi(e,t)}function B(e){if("string"==typeof e)return BigInt(e);if("bigint"!=typeof e)throw new TypeError(wo(e));return e}function U(e,t="number"){if("bigint"==typeof e)throw new TypeError(bo(t));if(e=Number(e),!Number.isFinite(e))throw new RangeError(go(t,e));return e}function Z(e,t){return Math.trunc(U(e,t))||0}function W(e,t){return A(U(e,t),t)}function $(e,t){return L(Z(e,t),t)}function q(e,t){let[n,r]=S(t,bi),o=e+n;const i=Math.sign(o);return i&&i===-Math.sign(r)&&(o-=i,r+=i*bi),[o,r]}function z(e,t,n=1){return q(e[0]+t[0]*n,e[1]+t[1]*n)}function V(e,t){return q(e[0],e[1]+t)}function J(e,t){return z(t,e,-1)}function G(e,t){return E(e[0],t[0])||E(e[1],t[1])}function K(e,t,n){return-1===G(e,t)||1===G(e,n)}function X(e,t=1){const n=BigInt(bi/t);return[Number(e/n),Number(e%n)*t]}function Q(e,t=1){const n=bi/t,[r,o]=S(e,n);return[r,o*t]}function ee(e,t=1,n){const[r,o]=e,[i,a]=S(o,t);return r*(bi/t)+(i+(n?a/t:0))}function te(e,t,n=I){const[r,o]=e,[i,a]=n(o,t);return[r*(bi/t)+i,a]}function ne(e){return t(e,"isoYear",ma,ha,1),e.isoYear===ma?t(e,"isoMonth",4,12,1):e.isoYear===ha&&t(e,"isoMonth",1,9,1),e}function re(e){return oe({...e,...sa,isoHour:12}),e}function oe(e){const n=t(e,"isoYear",ma,ha,1),r=n===ma?1:n===ha?-1:0;return r&&ie(le({...e,isoDay:e.isoDay+r,isoNanosecond:e.isoNanosecond-r})),e}function ie(e){if(!e||K(e,da,fa))throw new RangeError(Vo);return e}function ae(e){return x(e,5,ta)[1]}function se(e){const[t,n]=I(e,bi);return[O(n,5,ta),t]}function ce(e){return te(e,mi)}function ue(e){return he(e.isoYear,e.isoMonth,e.isoDay,e.isoHour,e.isoMinute,e.isoSecond,e.isoMillisecond)}function le(e){const t=ue(e);if(void 0!==t){const[n,r]=S(t,li);return[n,r*hi+(e.isoMicrosecond||0)*di+(e.isoNanosecond||0)]}}function fe(e,t){const[n,r]=se(ae(e)-t);return ie(le({...e,isoDay:e.isoDay+r,...n}))}function de(...e){return he(...e)/fi}function he(...e){const[t,n]=me(...e),r=t.valueOf();if(!isNaN(r))return r-n*li}function me(e,t=1,n=1,r=0,o=0,i=0,a=0){const s=e===ma?1:e===ha?-1:0,c=new Date;return c.setUTCHours(r,o,i,a),c.setUTCFullYear(e,t-1,n+s),[c,s]}function pe(e,t){let[n,r]=V(e,t);r<0&&(r+=bi,n-=1);const[o,i]=I(r,hi),[a,s]=I(i,di);return ge(n*li+o,a,s)}function ge(e,t=0,n=0){const r=Math.ceil(Math.max(0,Math.abs(e)-la)/li)*Math.sign(e),o=new Date(e-r*li);return u(ra,[o.getUTCFullYear(),o.getUTCMonth()+1,o.getUTCDate()+r,o.getUTCHours(),o.getUTCMinutes(),o.getUTCSeconds(),o.getUTCMilliseconds(),t,n])}function be(e,t){if(t<-la)throw new RangeError(Vo);const n=e.formatToParts(t),r={};for(const e of n)r[e.type]=e.value;return r}function we(e){return[e.isoYear,e.isoMonth,e.isoDay]}function ye(e,t){return[t,0]}function ve(){return ya}function Ee(e,t){switch(t){case 2:return Ie(e)?29:28;case 4:case 6:case 9:case 11:return 30}return 31}function Me(e){return Ie(e)?366:365}function Ie(e){return e%4==0&&(e%100!=0||e%400==0)}function De(e){const[t,n]=me(e.isoYear,e.isoMonth,e.isoDay);return D(t.getUTCDay()-n,7)||7}function Se(e){return this.id===Li?(({isoYear:e})=>e<1?["gregory-inverse",1-e]:["gregory",e])(e):this.id===Fi?Ea(e):[]}function ke(e){const t=ue(e);if(t<va){const{isoYear:t}=e;return t<1?["japanese-inverse",1-t]:["japanese",t]}const n=be(Cs(Fi),t),{era:r,eraYear:o}=jr(n,Fi);return[r,o]}function Te(e){return _e(e),je(e,1),e}function _e(e){return Oe(e,1),e}function xe(e){return p(na,e,Oe(e))}function Oe(e,n){const{isoYear:r}=e,o=t(e,"isoMonth",1,ve(),n);return{isoYear:r,isoMonth:o,isoDay:t(e,"isoDay",1,Ee(r,o),n)}}function je(e,n){return u(ta,[t(e,"isoHour",0,23,n),t(e,"isoMinute",0,59,n),t(e,"isoSecond",0,59,n),t(e,"isoMillisecond",0,999,n),t(e,"isoMicrosecond",0,999,n),t(e,"isoNanosecond",0,999,n)])}function Ce(e){return void 0===e?0:Ha(P(e))}function Re(e,t=0){e=Ze(e);const n=Ba(e),r=Ua(e,t);return[Ha(e),r,n]}function Ne(e,t,n,r=9,o=0,i=4){t=Ze(t);let a=La(t,r,o),s=He(t),c=qa(t,i);const u=Aa(t,r,o,1);return null==a?a=Math.max(n,u):Ve(a,u),s=Be(s,u,1),e&&(c=(e=>e<4?(e+2)%4:e)(c)),[a,u,s,c]}function Pe(e,t=6,n){let r=He(e=We(e,Ma));const o=qa(e,7);let i=Aa(e,t);return i=N(Ma,i),r=Be(r,i,void 0,n),[i,r,o]}function Ye(e){return Za(Ze(e))}function Ae(e,t){return Le(Ze(e),t)}function Le(e,t=4){const n=Ue(e);return[qa(e,4),...Fe(Aa(e,t),n)]}function Fe(e,t){return null!=e?[wi[e],e<4?9-3*e:-1]:[void 0===t?1:10**(9-t),t]}function He(e){const t=e[Da];return void 0===t?1:Z(t,Da)}function Be(e,t,r,o){const i=o?bi:wi[t+1];if(i){const r=wi[t];if(i%((e=n(Da,e,1,i/r-(o?0:1),1))*r))throw new RangeError(Mo(Da,e))}else e=n(Da,e,1,r?10**9:1,1);return e}function Ue(e){let t=e[Sa];if(void 0!==t){if("number"!=typeof t){if("auto"===F(t))return;throw new RangeError(Mo(Sa,t))}t=n(Sa,Math.floor(t),0,9,1)}return t}function Ze(e){return void 0===e?{}:P(e)}function We(e,t){return"string"==typeof e?{[t]:e}:P(e)}function $e(e){return{overflow:xa[e]}}function qe(e,t,r=9,o=0,i){let a=t[e];if(void 0===a)return i?o:void 0;if(a=F(a),"auto"===a)return i?o:null;let s=ci[a];if(void 0===s&&(s=Ki[a]),void 0===s)throw new RangeError(To(e,a,ci));return n(e,s,o,r,1,ui),s}function ze(e,t,n,r=0){const o=n[e];if(void 0===o)return r;const i=F(o),a=t[i];if(void 0===a)throw new RangeError(To(e,i,t));return a}function Ve(e,t){if(t>e)throw new RangeError(ei)}function Je(e){return{branding:Qa,epochNanoseconds:e}}function Ge(e,t,n){return{branding:Xa,calendar:n,timeZone:t,epochNanoseconds:e}}function Ke(e,t=e.calendar){return{branding:Ga,calendar:t,...h(aa,e)}}function Xe(e,t=e.calendar){return{branding:Ja,calendar:t,...h(oa,e)}}function Qe(e,t=e.calendar){return{branding:za,calendar:t,...h(oa,e)}}function et(e,t=e.calendar){return{branding:Va,calendar:t,...h(oa,e)}}function tt(e){return{branding:Ka,...h(ia,e)}}function nt(e){return{branding:es,sign:bn(e),...h(zi,e)}}function rt(e){return te(e.epochNanoseconds,hi)[0]}function ot(e){return e.epochNanoseconds}function it(e,t){return ee(vn(e),wi[t],1)}function at(e,t,n,r,o,i,a){const s=qi[n],c={...t,[s]:t[s]+r},u=a(e,o,t),l=a(e,o,c);return[i(u),i(l)]}function st(e,t,n){const r=ee(J(t,n));if(!r)throw new RangeError(Lo);return ee(J(t,e))/r}function ct(e,t,n,r){return ut(e,dt(t,n),r)}function ut(e,t,n){const[r,o]=lt(e,t,n);return oe({...sn(e,o),...r})}function lt(e,t,n){return se(yt(ae(e),t,n))}function ft(e){return yt(e,pi,7)}function dt(e,t){return wi[e]*t}function ht(e){const t=mt(e);return[t,sn(t,1)]}function mt(e){return ca(6,e)}function pt(e,t,n){const r=Math.min(Dn(e),6);return En(wt(vn(e,r),t,n),r)}function gt(e,t,n,r,o,i,a,s,c,u){if(0===r&&1===o)return e;const l=hn(r,s)?dn(s)&&r<6&&n>=6?Mt:Et:It;let[f,d,h]=l(e,t,n,r,o,i,a,s,c,u);return h&&7!==r&&(f=((e,t,n,r,o,i,a,s)=>{const c=bn(e);for(let u=r+1;u<=n;u++){if(7===u&&7!==n)continue;const r=ea(u,e);r[qi[u]]+=c;const l=ee(J(a(s(o,i,r)),t));if(l&&Math.sign(l)!==c)break;e=r}return e})(f,d,n,Math.max(6,r),a,s,c,u)),f}function bt(e,t,n,r,o){if(6===t){const t=(e=>e[0]+e[1]/bi)(e);return[yt(t,n,r),0]}return wt(e,dt(t,n),r,o)}function wt(e,t,n,r){let[o,i]=e;r&&i<0&&(i+=bi,o-=1);const[a,s]=I(yt(i,t,n),bi);return q(o+a,s)}function yt(e,t,n){return vt(e/t,n)*t}function vt(e,t){return ts[t](e)}function Et(e,t,n,r,o,i){const a=bn(e),s=vn(e),c=bt(s,r,o,i),u=J(s,c),l=Math.sign(c[0]-s[0])===a,f=En(c,Math.min(n,6));return[{...e,...f},z(t,u),l]}function Mt(e,t,n,r,o,i,a,s,c,u){const l=bn(e)||1,f=ee(vn(e,5)),d=dt(r,o);let h=yt(f,d,i);const[m,p]=at(a,{...e,...Qi},6,l,s,c,u),g=h-ee(J(m,p));let b=0;g&&Math.sign(g)!==l?t=V(m,h):(b+=l,h=yt(g,d,i),t=V(p,h));const w=Mn(h);return[{...e,...w,days:e.days+b},t,Boolean(b)]}function It(e,t,n,r,o,i,a,s,c,u){const l=bn(e),f=qi[r],d=ea(r,e);7===r&&(e={...e,weeks:e.weeks+Math.trunc(e.days/7)});const h=k(e[f],o)*o;d[f]=h;const[m,p]=at(a,d,r,o*l,s,c,u),g=h+st(t,m,p)*l*o,b=yt(g,o,i),w=Math.sign(b-g)===l;return d[f]=b,[d,w?p:m,w]}function Dt(e,t,n,r){const[o,i,a,s]=(e=>{const t=Le(e=Ze(e));return[e.timeZone,...t]})(r),c=void 0!==o;return((e,t,n,r,o,i)=>{n=wt(n,o,r,1);const a=t.R(n);return Nt(pe(n,a),i)+(e?Ft(ft(a)):"Z")})(c,t(c?e(o):ns),n.epochNanoseconds,i,a,s)}function St(e,t,n){const[r,o,i,a,s,c]=(e=>{e=Ze(e);const t=Za(e),n=Ue(e),r=$a(e),o=qa(e,4),i=Aa(e,4);return[t,Wa(e),r,o,...Fe(i,n)]})(n);return((e,t,n,r,o,i,a,s,c,u)=>{r=wt(r,c,s,1);const l=e(n).R(r);return Nt(pe(r,l),u)+Ft(ft(l),a)+((e,t)=>1!==t?"["+(2===t?"!":"")+e+"]":"")(n,i)+Ht(t,o)})(e,t.calendar,t.timeZone,t.epochNanoseconds,r,o,i,a,s,c)}function kt(e,t){const[n,r,o,i]=(e=>(e=Ze(e),[Za(e),...Le(e)]))(t);return a=e.calendar,s=n,c=i,Nt(ut(e,o,r),c)+Ht(a,s);var a,s,c}function Tt(e,t){return n=e.calendar,r=e,o=Ye(t),Pt(r)+Ht(n,o);var n,r,o}function _t(e,t){return Ct(e.calendar,Yt,e,Ye(t))}function xt(e,t){return Ct(e.calendar,At,e,Ye(t))}function Ot(e,t){const[n,r,o]=Ae(t);return i=o,Lt(lt(e,r,n)[0],i);var i}function jt(e,t){const[n,r,o]=Ae(t,3);return r>1&&wn(e={...e,...pt(e,r,n)}),((e,t)=>{const{sign:n}=e,r=-1===n?gn(e):e,{hours:o,minutes:i}=r,[a,s]=te(vn(r,3),mi,S);yn(a);const c=Ut(s,t),u=t>=0||!n||c;return(n<0?"-":"")+"P"+Rt({Y:Wt(r.years),M:Wt(r.months),W:Wt(r.weeks),D:Wt(r.days)})+(o||i||a||u?"T"+Rt({H:Wt(o),M:Wt(i),S:Wt(a,u)+c}):"")})(e,o)}function Ct(e,t,n,r){const o=r>1||0===r&&e!==Ai;return 1===r?e===Ai?t(n):Pt(n):o?Pt(n)+Bt(e,2===r):t(n)}function Rt(e){const t=[];for(const n in e){const r=e[n];r&&t.push(r,n)}return t.join("")}function Nt(e,t){return Pt(e)+"T"+Lt(e,t)}function Pt(e){return Yt(e)+"-"+si(e.isoDay)}function Yt(e){const{isoYear:t}=e;return(t<0||t>9999?Zt(t)+v(6,Math.abs(t)):v(4,t))+"-"+si(e.isoMonth)}function At(e){return si(e.isoMonth)+"-"+si(e.isoDay)}function Lt(e,t){const n=[si(e.isoHour),si(e.isoMinute)];return-1!==t&&n.push(si(e.isoSecond)+((e,t,n,r)=>Ut(e*hi+t*di+n,r))(e.isoMillisecond,e.isoMicrosecond,e.isoNanosecond,t)),n.join(":")}function Ft(e,t=0){if(1===t)return"";const[n,r]=I(Math.abs(e),gi),[o,i]=I(r,pi),[a,s]=I(i,mi);return Zt(e)+si(n)+":"+si(o)+(a||s?":"+si(a)+Ut(s):"")}function Ht(e,t){return 1!==t&&(t>1||0===t&&e!==Ai)?Bt(e,2===t):""}function Bt(e,t){return"["+(t?"!":"")+"u-ca="+e+"]"}function Ut(e,t){let n=v(9,e);return n=void 0===t?n.replace(as,""):n.slice(0,t),n?"."+n:""}function Zt(e){return e<0?"-":"+"}function Wt(e,t){return e||t?e.toLocaleString("fullwide",{useGrouping:0}):""}function $t(e,t){const{epochNanoseconds:n}=e,r=(t.R?t:t(e.timeZone)).R(n),o=pe(n,r);return{calendar:e.calendar,...o,offsetNanoseconds:r}}function qt(e,t,n,r=0,o=0,i,a){if(void 0!==n&&1===r&&(1===r||a))return fe(t,n);const s=e.I(t);if(void 0!==n&&3!==r){const e=((e,t,n,r)=>{const o=le(t);r&&(n=ft(n));for(const t of e){let e=ee(J(t,o));if(r&&(e=ft(e)),e===n)return t}})(s,t,n,i);if(void 0!==e)return e;if(0===r)throw new RangeError(qo)}return a?le(t):zt(e,t,o,s)}function zt(e,t,n=0,r=e.I(t)){if(1===r.length)return r[0];if(1===n)throw new RangeError(zo);if(r.length)return r[3===n?1:0];const o=le(t),i=((e,t)=>{const n=e.R(V(t,-bi));return(e=>{if(e>bi)throw new RangeError($o);return e})(e.R(V(t,bi))-n)})(e,o),a=i*(2===n?-1:1);return(r=e.I(pe(o,a)))[2===n?0:r.length-1]}function Vt(e,t){const n=e.I(t);if(n.length)return n[0];const r=V(le(t),-bi);return e.O(r,1)}function Jt(e,t,n){return Je(ie(z(t.epochNanoseconds,(e=>{if(In(e))throw new RangeError(Xo);return vn(e,5)})(e?gn(n):n))))}function Gt(e,t,n,r,o,i=Object.create(null)){const a=t(r.timeZone),s=e(r.calendar);return{...r,...tn(a,s,r,n?gn(o):o,i)}}function Kt(e,t,n,r,o=Object.create(null)){const{calendar:i}=n;return Ke(nn(e(i),n,t?gn(r):r,o),i)}function Xt(e,t,n,r,o){const{calendar:i}=n;return Xe(rn(e(i),n,t?gn(r):r,o),i)}function Qt(e,t,n,r,o){const i=n.calendar,a=e(i);let s=re(on(a,n));t&&(r=pn(r)),r.sign<0&&(s=a.P(s,{...Xi,months:1}),s=sn(s,-1));const c=a.P(s,r,o);return Qe(on(a,c),i)}function en(e,t,n){return tt(an(t,e?gn(n):n)[0])}function tn(e,t,n,r,o){const i=vn(r,5);let a=n.epochNanoseconds;if(In(r)){const s=ss(n,e);a=z(zt(e,{...rn(t,s,{...r,...Qi},o),...h(ta,s)}),i)}else a=z(a,i),Ce(o);return{epochNanoseconds:ie(a)}}function nn(e,t,n,r){const[o,i]=an(t,n);return oe({...rn(e,t,{...n,...Qi,days:n.days+i},r),...o})}function rn(e,t,n,r){if(n.years||n.months||n.weeks)return e.P(t,n,r);Ce(r);const o=n.days+vn(n,5)[0];return o?re(sn(t,o)):t}function on(e,t,n=1){return sn(t,n-e.day(t))}function an(e,t){const[n,r]=vn(t,5),[o,i]=se(ae(e)+r);return[o,n+i]}function sn(e,t){return t?{...e,...ge(ue(e)+t*li)}:e}function cn(e,t,n){const r=e(n.calendar);return dn(n)?[n,r,t(n.timeZone)]:[{...n,...sa},r]}function un(e){return e?ot:le}function ln(e){return e?b(tn,e):nn}function fn(e){return e?b(sr,e):cr}function dn(e){return e&&e.epochNanoseconds}function hn(e,t){return e<=6-(dn(t)?1:0)}function mn(e,t,n,r,o,i,a){const s=e(Ze(a).relativeTo),c=Math.max(Dn(o),Dn(i));if(hn(c,s))return nt(wn(((e,t,n,r)=>{const o=z(vn(e),vn(t),r?-1:1);if(!Number.isFinite(o[0]))throw new RangeError(Vo);return{...Xi,...En(o,n)}})(o,i,c,r)));if(!s)throw new RangeError(Ko);r&&(i=gn(i));const[u,l,f]=cn(t,n,s),d=ln(f),h=fn(f),m=d(l,u,o);return nt(h(l,u,d(l,m,i),c))}function pn(e){return nt(gn(e))}function gn(e){const t={};for(const n of qi)t[n]=-1*e[n]||0;return t}function bn(e,t=qi){let n=0;for(const r of t){const t=Math.sign(e[r]);if(t){if(n&&n!==t)throw new RangeError(Go);n=t}}return n}function wn(e){for(const t of Gi)n(t,e[t],-cs,cs,1);return yn(ee(vn(e),mi)),e}function yn(e){if(!Number.isSafeInteger(e))throw new RangeError(Jo)}function vn(e,t=6){return x(e,t,qi)}function En(e,t=6){const[n,r]=e,o=O(r,t,qi);if(o[qi[t]]+=n*(bi/wi[t]),!Number.isFinite(o[qi[t]]))throw new RangeError(Vo);return o}function Mn(e,t=5){return O(e,t,qi)}function In(e){return Boolean(bn(e,Ji))}function Dn(e){let t=9;for(;t>0&&!e[qi[t]];t--);return t}function Sn(e,t){return[e,t]}function kn(e){const t=Math.floor(e/rs)*rs;return[t,t+rs]}function Tn(e){const t=An(e);if(void 0===t)throw new RangeError(ti(e));return t}function _n(e,t,n){let r=Nn(Zi(e));if(!r||r.j)throw new RangeError(ti(e));return t?r.calendar===Ai&&(r=-271821===r.isoYear&&4===r.isoMonth?{...r,isoDay:20,...sa}:{...r,isoDay:1,...sa}):n&&r.calendar===Ai&&(r={...r,isoYear:wa}),Xe(r.C?jn(r):Cn(r))}function xn(e){if(e.calendar!==Ai)throw new RangeError(ni(e.calendar))}function On(e,t,n=0,r=0){const o=$n(e.timeZone),i=us(o);let a;return Te(e),a=e.C?qt(i,e,t,n,r,!i.$,e.j):Vt(i,e),Ge(a,o,Zr(e.calendar))}function jn(e){return Rn(oe(Te(e)))}function Cn(e){return Rn(re(_e(e)))}function Rn(e){return{...e,calendar:Zr(e.calendar)}}function Nn(e){const t=Ms.exec(e);return t?(e=>{const t=e[10],n="Z"===(t||"").toUpperCase();return{isoYear:Ln(e),isoMonth:parseInt(e[4]),isoDay:parseInt(e[5]),...Fn(e.slice(5)),...Hn(e[16]),C:Boolean(e[6]),j:n,offset:n?void 0:t}})(t):void 0}function Pn(e){const t=vs.exec(e);return t?(e=>({isoYear:Ln(e),isoMonth:parseInt(e[4]),isoDay:1,...Hn(e[5])}))(t):void 0}function Yn(e){const t=Es.exec(e);return t?(e=>({isoYear:wa,isoMonth:parseInt(e[1]),isoDay:parseInt(e[2]),...Hn(e[3])}))(t):void 0}function An(e,t){const n=Ds.exec(e);return n?((e,t)=>{const n=e[4]||e[5];if(t&&n)throw new RangeError(ni(n));return(e=>{if(Math.abs(e)>=bi)throw new RangeError(Wo);return e})((Wn(e[2])*gi+Wn(e[3])*pi+Wn(e[4])*mi+Bn(e[5]||""))*Zn(e[1]))})(n,t):void 0}function Ln(e){const t=Zn(e[1]),n=parseInt(e[2]||e[3]);if(t<0&&!n)throw new RangeError(ni(-0));return t*n}function Fn(e){const t=Wn(e[3]);return{...se(Bn(e[4]||""))[0],isoHour:Wn(e[1]),isoMinute:Wn(e[2]),isoSecond:60===t?59:t}}function Hn(e){let t,n;const r=[];if(e.replace(Ss,(e,o,i)=>{const a=Boolean(o),[s,c]=i.split("=").reverse();if(c){if("u-ca"===c)r.push(s),t||(t=a);else if(a||/[A-Z]/.test(c))throw new RangeError(ni(e))}else{if(n)throw new RangeError(ni(e));n=s}return""}),r.length>1&&t)throw new RangeError(ni(e));return{timeZone:n,calendar:r[0]||Ai}}function Bn(e){return parseInt(e.padEnd(9,"0"))}function Un(e){return new RegExp(`^${e}$`,"i")}function Zn(e){return e&&"+"!==e?-1:1}function Wn(e){return void 0===e?0:parseInt(e)}function $n(e){const t=zn(e);return"number"==typeof t?Ft(t):t?(e=>{if(xs.test(e))throw new RangeError(Bo(e));if(_s.test(e))throw new RangeError(Zo);return e.toLowerCase().split("/").map((e,t)=>(e.length<=3||/\d/.test(e))&&!/etc|yap/.test(e)?e.toUpperCase():e.replace(/baja|dumont|[a-z]+/g,(e,n)=>e.length<=2&&!t||"in"===e||"chat"===e?e.toUpperCase():e.length>2||!n?w(e).replace(/island|noronha|murdo|rivadavia|urville/,w):e)).join("/")})(e):ns}function qn(e){const t=zn(e);return"number"==typeof t?t:t?t.resolvedOptions().timeZone:ns}function zn(e){const t=An(e=e.toUpperCase(),1);return void 0!==t?t:e!==ns?Ts(e):void 0}function Vn(e,t){return G(e.epochNanoseconds,t.epochNanoseconds)}function Jn(e,t){return G(e.epochNanoseconds,t.epochNanoseconds)}function Gn(e,t){return Kn(e,t)||Xn(e,t)}function Kn(e,t){return E(ue(e),ue(t))}function Xn(e,t){return E(ae(e),ae(t))}function Qn(e,t){if(e===t)return 1;try{return qn(e)===qn(t)}catch(e){}}function er(e,t,n,r){const o=Ne(e,r,3,5),i=fr(t.epochNanoseconds,n.epochNanoseconds,...o);return nt(e?gn(i):i)}function tr(e,t,n,r,o,i){const a=gr(r.calendar,o.calendar),[s,c,u,l]=Ne(n,i,5),f=r.epochNanoseconds,d=o.epochNanoseconds,h=G(d,f);let m;if(h)if(s<6)m=fr(f,d,s,c,u,l);else{const n=t(((e,t)=>{if(!Qn(e,t))throw new RangeError(Uo);return e})(r.timeZone,o.timeZone)),f=e(a);m=ur(f,n,r,o,h,s,i),m=gt(m,d,s,c,u,l,f,r,ot,b(tn,n))}else m=Xi;return nt(n?gn(m):m)}function nr(e,t,n,r,o){const i=gr(n.calendar,r.calendar),[a,s,c,u]=Ne(t,o,6),l=le(n),f=le(r),d=G(f,l);let h;if(d)if(a<=6)h=fr(l,f,a,s,c,u);else{const t=e(i);h=lr(t,n,r,d,a,o),h=gt(h,f,a,s,c,u,t,n,le,nn)}else h=Xi;return nt(t?gn(h):h)}function rr(e,t,n,r,o){const i=gr(n.calendar,r.calendar);return ir(t,()=>e(i),n,r,...Ne(t,o,6,9,6))}function or(e,t,n,r,o){const i=gr(n.calendar,r.calendar),a=Ne(t,o,9,9,8),s=e(i),c=on(s,n),u=on(s,r);return c.isoYear===u.isoYear&&c.isoMonth===u.isoMonth&&c.isoDay===u.isoDay?nt(Xi):ir(t,()=>s,re(c),re(u),...a,8)}function ir(e,t,n,r,o,i,a,s,c=6){const u=le(n),l=le(r);if(void 0===u||void 0===l)throw new RangeError(Vo);let f;if(G(l,u))if(6===o)f=fr(u,l,o,i,a,s);else{const e=t();f=e.N(n,r,o),i===c&&1===a||(f=gt(f,l,o,i,a,s,e,n,le,rn))}else f=Xi;return nt(e?gn(f):f)}function ar(e,t,n,r){const[o,i,a,s]=Ne(e,r,5,5),c=yt(pr(t,n),dt(i,a),s),u={...Xi,...Mn(c,o)};return nt(e?gn(u):u)}function sr(e,t,n,r,o,i){const a=G(r.epochNanoseconds,n.epochNanoseconds);return a?o<6?dr(n.epochNanoseconds,r.epochNanoseconds,o):ur(t,e,n,r,a,o,i):Xi}function cr(e,t,n,r,o){const i=le(t),a=le(n),s=G(a,i);return s?r<=6?dr(i,a,r):lr(e,t,n,s,r,o):Xi}function ur(e,t,n,r,o,i,a){const[s,c,u]=((e,t,n,r)=>{function o(){return f={...sn(s,u++*-r),...a},d=zt(e,f),G(c,d)===-r}const i=ss(t,e),a=h(ta,i),s=ss(n,e),c=n.epochNanoseconds;let u=0;const l=pr(i,s);let f,d;if(Math.sign(l)===-r&&u++,o()&&(-1===r||o()))throw new RangeError(Lo);const m=ee(J(d,c));return[i,f,m]})(t,n,r,o);var l,f;return{...6===i?(l=s,f=c,{...Xi,days:hr(l,f)}):e.N(s,c,i,a),...Mn(u)}}function lr(e,t,n,r,o,i){const[a,s,c]=((e,t,n)=>{let r=t,o=pr(e,t);return Math.sign(o)===-n&&(r=sn(t,-n),o+=bi*n),[e,r,o]})(t,n,r);return{...e.N(a,s,o,i),...Mn(c)}}function fr(e,t,n,r,o,i){return{...Xi,...En(bt(J(e,t),r,o,i),n)}}function dr(e,t,n){return{...Xi,...En(J(e,t),n)}}function hr(e,t){return mr(ue(e),ue(t))}function mr(e,t){return Math.trunc((t-e)/li)}function pr(e,t){return ae(t)-ae(e)}function gr(e,t){if(e!==t)throw new RangeError(Ho);return e}function br(e){return this.m(e)[0]}function wr(e){return this.m(e)[1]}function yr(e){const[t]=this.v(e);return mr(this.p(t),ue(e))+1}function vr(e){const t=Os.exec(e);if(!t)throw new RangeError(No(e));return[parseInt(t[1]),Boolean(t[2])]}function Er(e,t){return"M"+si(e)+(t?"L":"")}function Mr(e,t,n){return e+(t||n&&e>=n?1:0)}function Ir(e,t){return e-(t&&e>=t?1:0)}function Dr(e,t){return(t+e)*(Math.sign(t)||1)||0}function Sr(e){return Hi[Tr(e)]}function kr(e){return Ui[Tr(e)]}function Tr(e){return Wr(e.id||Ai)}function _r(e){function t(e){return((e,t)=>({...jr(e,t),o:e.month,day:parseInt(e.day)}))(be(n,e),r)}const n=Cs(e),r=Wr(e);return{id:e,h:xr(t),l:Or(t)}}function xr(e){return o(t=>{const n=ue(t);return e(n)},WeakMap)}function Or(e){const t=e(0).year-ba;return o(n=>{let r,o=he(n-t),i=0;const a=[],s=[];do{o+=400*li}while((r=e(o)).year<=n);do{if(o+=(1-r.day)*li,r.year===n&&(a.push(o),s.push(r.o)),o-=li,++i>100||o<-la)throw new RangeError(Lo)}while((r=e(o)).year>=n);return{i:a.reverse(),u:ii(s.reverse())}})}function jr(e,t){let n,r,o=Cr(e);if(e.era){const i=Hi[t],a=Bi[t]||{};void 0!==i&&(n="islamic"===t?"ah":e.era.normalize("NFD").toLowerCase().replace(/[^a-z0-9]/g,""),"bc"===n||"b"===n?n="bce":"ad"===n||"a"===n?n="ce":"beforeroc"===n&&(n="broc"),n=a[n]||n,r=o,o=Dr(r,i[n]||0))}return{era:n,eraYear:r,year:o}}function Cr(e){return parseInt(e.relatedYear||e.year)}function Rr(e){const{year:t,o:n,day:r}=this.h(e),{u:o}=this.l(t);return[t,o[n]+1,r]}function Nr(e,t=1,n=1){return this.l(e).i[t-1]+(n-1)*li}function Pr(e,t){const n=Yr.call(this,e);return[Ir(t,n),n===t]}function Yr(e){const t=Br(this,e),n=Br(this,e-1),r=t.length;if(r>n.length){const e=kr(this);if(e<0)return-e;for(let e=0;e<r;e++)if(t[e]!==n[e])return e+1}}function Ar(e){return mr(Nr.call(this,e),Nr.call(this,e+1))}function Lr(e,t){const{i:n}=this.l(e);let r=t+1,o=n;return r>n.length&&(r=1,o=this.l(e+1).i),mr(n[t-1],o[r-1])}function Fr(e){return this.l(e).i.length}function Hr(e){const t=this.h(e);return[t.era,t.eraYear]}function Br(e,t){return Object.keys(e.l(t).u)}function Ur(e){return Zr(Zi(e))}function Zr(e){if((e=e.toLowerCase())!==Ai&&e!==Li){const t=Cs(e).resolvedOptions().calendar;if(Wr(e)!==Wr(t))throw new RangeError(Fo(e));return t}return e}function Wr(e){return"islamicc"===e&&(e="islamic"),e.split("-")[0]}function $r(e,t){return n=>n===Ai?e:n===Li||n===Fi?Object.assign(Object.create(e),{id:n}):Object.assign(Object.create(t),js(n))}function qr(e,t,n,r){const o=zr(n,r,Ri,[],Di);if(void 0!==o.timeZone){const r=n.F(o),i=Jr(o),a=e(o.timeZone);return{epochNanoseconds:qt(t(a),{...r,...i},void 0!==o.offset?Tn(o.offset):void 0),timeZone:a}}return{...n.F(o),...sa}}function zr(e,t,n,r=[],o=[]){return Vr(t,[...e.fields(n),...o].sort(),r)}function Vr(e,t,n,r=!n){const o={};let i,a=0;for(const r of t){if(r===i)throw new RangeError(So(r));if("constructor"===r||"__proto__"===r)throw new RangeError(Do(r));let t=e[r];if(void 0!==t)a=1,Zs[r]&&(t=Zs[r](t,r)),o[r]=t;else if(n){if(n.includes(r))throw new TypeError(Io(r));o[r]=Yi[r]}i=r}if(r&&!a)throw new TypeError(ko(t));return o}function Jr(e,t){return je(Ws({...Yi,...e}),t)}function Gr(e,t,n,r,o){t=h(n=e.fields(n),t),r=Vr(r,o=e.fields(o),[]);let i=e.k(t,r);return i=Vr(i,[...n,...o].sort(),[]),e.F(i)}function Kr(e,t){const n=Sr(e),r=Bi[e.id||""]||{};let{era:o,eraYear:i,year:a}=t;if(void 0!==o||void 0!==i){if(void 0===o||void 0===i)throw new TypeError(Oo);if(!n)throw new RangeError(xo);const e=n[r[o]||o];if(void 0===e)throw new RangeError(Co(o));const t=Dr(i,e);if(void 0!==a&&a!==t)throw new RangeError(jo);a=t}else if(void 0===a)throw new TypeError(Ro(n));return a}function Xr(e,t,r,o){let{month:i,monthCode:a}=t;if(void 0!==a){const t=((e,t,n,r)=>{const o=e.L(n),[i,a]=vr(t);let s=Mr(i,a,o);if(a){const t=kr(e);if(void 0===t)throw new RangeError(Ao);if(t>0){if(s>t)throw new RangeError(Ao);if(void 0===o){if(1===r)throw new RangeError(Ao);s--}}else{if(s!==-t)throw new RangeError(Ao);if(void 0===o&&1===r)throw new RangeError(Ao)}}return s})(e,a,r,o);if(void 0!==i&&i!==t)throw new RangeError(Po);i=t,o=1}else if(void 0===i)throw new TypeError(Yo);return n("month",i,1,e.B(r),o)}function Qr(e,n,r,o,i){return t(n,"day",1,e.U(o,r),i)}function eo(e,t,n,r){let o=0;const i=[];for(const e of n)void 0!==t[e]?o=1:i.push(e);if(Object.assign(e,t),o)for(const t of r||i)delete e[t]}function to(e){const t=Bs(e.calendar),[n,r,o]=t.v(e),[i,a]=t.q(n,r);return{year:n,monthCode:Er(i,a),day:o}}function no(e,t){return Ke(ss(t,e))}function ro(e,t){return Xe(ss(t,e))}function oo(e,t){return tt(ss(t,e))}function io(e,t,n){const r=new Set(n);return(o,i)=>{const a=n&&m(o,n);if(!m(o=((e,t)=>{const n={};for(const r in t)e.has(r)||(n[r]=t[r]);return n})(r,o),e)){if(i&&a)throw new TypeError("Invalid formatting options");o={...t,...o}}return n&&(o.timeZone=ns,["full","long"].includes(o.J)&&(o.J="medium")),o}}function ao(e,t=so,n=0){const[r,,,o]=e;return(i,a=Ec,...s)=>{const c=t(o&&o(...s),i,a,r,n),u=c.resolvedOptions();return[c,...co(e,u,s)]}}function so(e,t,n,r,o){if(n=r(n,o),e){if(void 0!==n.timeZone)throw new TypeError(oi);n.timeZone=e}return new pa(t,n)}function co(e,t,n){const[,r,o]=e;return n.map(e=>(e.calendar&&((e,t,n)=>{if((n||e!==Ai)&&e!==t)throw new RangeError(Ho)})(e.calendar,t.calendar,o),r(e,t)))}function uo(e,t){return{...e,calendar:t}}function lo(e){const t=fo();return pe(t,e.R(t))}function fo(){return Q(Date.now(),hi)}function ho(){return Oc||(Oc=(new pa).resolvedOptions().timeZone)}const mo=(e,t)=>`Non-integer ${e}: ${t}`,po=(e,t)=>`Non-positive ${e}: ${t}`,go=(e,t)=>`Non-finite ${e}: ${t}`,bo=e=>`Cannot convert bigint to ${e}`,wo=e=>`Invalid bigint: ${e}`,yo="Cannot convert Symbol to string",vo="Invalid object",Eo=(e,t,n,r,o)=>o?Eo(e,o[t],o[n],o[r]):Mo(e,t)+`; must be between ${n}-${r}`,Mo=(e,t)=>`Invalid ${e}: ${t}`,Io=e=>`Missing ${e}`,Do=e=>`Invalid field ${e}`,So=e=>`Duplicate field ${e}`,ko=e=>"No valid fields: "+e.join(),To=(e,t,n)=>Mo(e,t)+"; must be "+Object.keys(n).join(),_o="Invalid calling context",xo="Forbidden era/eraYear",Oo="Mismatching era/eraYear",jo="Mismatching year/eraYear",Co=e=>`Invalid era: ${e}`,Ro=e=>"Missing year"+(e?"/era/eraYear":""),No=e=>`Invalid monthCode: ${e}`,Po="Mismatching month/monthCode",Yo="Missing month/monthCode",Ao="Invalid leap month",Lo="Invalid protocol results",Fo=e=>Mo("Calendar",e),Ho="Mismatching Calendars",Bo=e=>Mo("TimeZone",e),Uo="Mismatching TimeZones",Zo="Forbidden ICU TimeZone",Wo="Out-of-bounds offset",$o="Out-of-bounds TimeZone gap",qo="Invalid TimeZone offset",zo="Ambiguous offset",Vo="Out-of-bounds date",Jo="Out-of-bounds duration",Go="Cannot mix duration signs",Ko="Missing relativeTo",Xo="Cannot use large units",Qo="Required smallestUnit or largestUnit",ei="smallestUnit > largestUnit",ti=e=>`Cannot parse: ${e}`,ni=e=>`Invalid substring: ${e}`,ri="Mismatching types for formatting",oi="Cannot specify TimeZone",ii=b(f,(e,t)=>t),ai=b(f,(e,t,n)=>n),si=b(v,2),ci={nanosecond:0,microsecond:1,millisecond:2,second:3,minute:4,hour:5,day:6,week:7,month:8,year:9},ui=Object.keys(ci),li=864e5,fi=1e3,di=1e3,hi=1e6,mi=1e9,pi=6e10,gi=36e11,bi=864e11,wi=[1,di,hi,mi,pi,gi,bi],yi=ui.slice(0,6),vi=y(yi),Ei=["offset"],Mi=["timeZone"],Ii=yi.concat(Ei),Di=Ii.concat(Mi),Si=["era","eraYear"],ki=Si.concat(["year"]),Ti=["year"],_i=["monthCode"],xi=["month"].concat(_i),Oi=["day"],ji=xi.concat(Ti),Ci=_i.concat(Ti),Ri=Oi.concat(ji),Ni=Oi.concat(xi),Pi=Oi.concat(_i),Yi=ai(yi,0),Ai="iso8601",Li="gregory",Fi="japanese",Hi={[Li]:{"gregory-inverse":-1,gregory:0},[Fi]:{"japanese-inverse":-1,japanese:0,meiji:1867,taisho:1911,showa:1925,heisei:1988,reiwa:2018},ethiopic:{ethioaa:0,ethiopic:5500},coptic:{"coptic-inverse":-1,coptic:0},roc:{"roc-inverse":-1,roc:0},buddhist:{be:0},islamic:{ah:0},indian:{saka:0},persian:{ap:0}},Bi={[Li]:{bce:"gregory-inverse",ce:"gregory"},[Fi]:{bce:"japanese-inverse",ce:"japanese"},ethiopic:{era0:"ethioaa",era1:"ethiopic"},coptic:{era0:"coptic-inverse",era1:"coptic"},roc:{broc:"roc-inverse",minguo:"roc"}},Ui={chinese:13,dangi:13,hebrew:-6},Zi=b(Y,"string"),Wi=b(Y,"boolean"),$i=b(Y,"number"),qi=ui.map(e=>e+"s"),zi=y(qi),Vi=qi.slice(0,6),Ji=qi.slice(6),Gi=Ji.slice(1),Ki=ii(qi),Xi=ai(qi,0),Qi=ai(Vi,0),ea=b(g,qi),ta=["isoNanosecond","isoMicrosecond","isoMillisecond","isoSecond","isoMinute","isoHour"],na=["isoDay","isoMonth","isoYear"],ra=ta.concat(na),oa=y(na),ia=y(ta),aa=y(ra),sa=ai(ia,0),ca=b(g,ra),ua=1e8,la=ua*li,fa=[ua,0],da=[-ua,0],ha=275760,ma=-271821,pa=Intl.DateTimeFormat,ga="en-GB",ba=1970,wa=1972,ya=12,va=he(1868,9,8),Ea=o(ke,WeakMap),Ma="smallestUnit",Ia="unit",Da="roundingIncrement",Sa="fractionalSecondDigits",ka="relativeTo",Ta="direction",_a={constrain:0,reject:1},xa=Object.keys(_a),Oa={compatible:0,reject:1,earlier:2,later:3},ja={reject:0,use:1,prefer:2,ignore:3},Ca={auto:0,never:1,critical:2,always:3},Ra={auto:0,never:1,critical:2},Na={auto:0,never:1},Pa={floor:0,halfFloor:1,ceil:2,halfCeil:3,trunc:4,halfTrunc:5,expand:6,halfExpand:7,halfEven:8},Ya={previous:-1,next:1},Aa=b(qe,Ma),La=b(qe,"largestUnit"),Fa=b(qe,Ia),Ha=b(ze,"overflow",_a),Ba=b(ze,"disambiguation",Oa),Ua=b(ze,"offset",ja),Za=b(ze,"calendarName",Ca),Wa=b(ze,"timeZoneName",Ra),$a=b(ze,"offset",Na),qa=b(ze,"roundingMode",Pa),za="PlainYearMonth",Va="PlainMonthDay",Ja="PlainDate",Ga="PlainDateTime",Ka="PlainTime",Xa="ZonedDateTime",Qa="Instant",es="Duration",ts=[Math.floor,e=>_(e)?Math.floor(e):Math.round(e),Math.ceil,e=>_(e)?Math.ceil(e):Math.round(e),Math.trunc,e=>_(e)?Math.trunc(e)||0:Math.round(e),e=>e<0?Math.floor(e):Math.ceil(e),e=>Math.sign(e)*Math.round(Math.abs(e))||0,e=>_(e)?(e=Math.trunc(e)||0)+e%2:Math.round(e)],ns="UTC",rs=5184e3,os=de(1847),is=de((new Date).getUTCFullYear()+10),as=/0+$/,ss=o($t,WeakMap),cs=2**32-1,us=o(e=>{const t=zn(e);return"object"==typeof t?new fs(t):new ls(t||0)});class ls{constructor(e){this.$=e}R(){return this.$}I(e){return(e=>{const t=le({...e,...sa});if(!t||Math.abs(t[0])>1e8)throw new RangeError(Vo)})(e),[fe(e,this.$)]}O(){}}class fs{constructor(e){this.nn=(e=>{function t(e){const t=M(e,a,s),[o,c]=kn(t),u=r(o),l=r(c);return u===l?u:n(i(o,c),u,l,e)}function n(t,n,r,o){let i,a;for(;(void 0===o||void 0===(i=o<t[0]?n:o>=t[1]?r:void 0))&&(a=t[1]-t[0]);){const n=t[0]+Math.floor(a/2);e(n)===r?t[1]=n:t[0]=n+1}return i}const r=o(e),i=o(Sn);let a=os,s=is;return{tn(e){const n=t(e-86400),r=t(e+86400),o=e-n,i=e-r;if(n===r)return[o];const a=t(o);return a===t(i)?[e-a]:n>r?[o,i]:[]},rn:t,O(e,t){const o=M(e,a,s);let[c,u]=kn(o);const l=rs*t,f=t<0?()=>u>a||(a=o,0):()=>c<s||(s=o,0);for(;f();){const o=r(c),a=r(u);if(o!==a){const r=i(c,u);n(r,o,a);const s=r[0];if((E(s,e)||1)===t)return s}c+=l,u+=l}}}})((e=>t=>{const n=be(e,t*fi);return de(Cr(n),parseInt(n.month),parseInt(n.day),parseInt(n.hour),parseInt(n.minute),parseInt(n.second))-t})(e))}R(e){return this.nn.rn((e=>ce(e)[0])(e))*mi}I(e){const[t,n]=[de((r=e).isoYear,r.isoMonth,r.isoDay,r.isoHour,r.isoMinute,r.isoSecond),r.isoMillisecond*hi+r.isoMicrosecond*di+r.isoNanosecond];var r;return this.nn.tn(t).map(e=>ie(V(Q(e,mi),n)))}O(e,t){const[n,r]=ce(e),o=this.nn.O(n+(t>0||r?1:0),t);if(void 0!==o)return Q(o,mi)}}const ds="([+-])",hs="(?:[.,](\\d{1,9}))?",ms=`(?:(?:${ds}(\\d{6}))|(\\d{4}))-?(\\d{2})`,ps="(\\d{2})(?::?(\\d{2})(?::?(\\d{2})"+hs+")?)?",gs=ds+ps,bs=ms+"-?(\\d{2})(?:[T ]"+ps+"(Z|"+gs+")?)?",ws="\\[(!?)([^\\]]*)\\]",ys=`((?:${ws}){0,9})`,vs=Un(ms+ys),Es=Un("(?:--)?(\\d{2})-?(\\d{2})"+ys),Ms=Un(bs+ys),Is=Un("T?"+ps+"(?:"+gs+")?"+ys),Ds=Un(gs),Ss=new RegExp(ws,"g"),ks=Un(`${ds}?P(\\d+Y)?(\\d+M)?(\\d+W)?(\\d+D)?(?:T(?:(\\d+)${hs}H)?(?:(\\d+)${hs}M)?(?:(\\d+)${hs}S)?)?`),Ts=o(e=>new pa(ga,{timeZone:e,era:"short",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"})),_s=/^(AC|AE|AG|AR|AS|BE|BS|CA|CN|CS|CT|EA|EC|IE|IS|JS|MI|NE|NS|PL|PN|PR|PS|SS|VS)T$/,xs=/[^\w\/:+-]+/,Os=/^M(\d{2})(L?)$/,js=o(_r),Cs=o(e=>new pa(ga,{calendar:e,timeZone:ns,era:"short",year:"numeric",month:"short",day:"numeric"})),Rs={P(e,t,r){const o=Ce(r);let i,{years:a,months:s,weeks:c,days:u}=t;if(u+=vn(t,5)[0],a||s)i=((e,t,r,o,i)=>{let[a,s,c]=e.v(t);if(r){const[t,o]=e.q(a,s);a+=r,s=Mr(t,o,e.L(a)),s=n("month",s,1,e.B(a),i)}return o&&([a,s]=e.un(a,s,o)),c=n("day",c,1,e.U(a,s),i),e.p(a,s,c)})(this,e,a,s,o);else{if(!c&&!u)return e;i=ue(e)}if(void 0===i)throw new RangeError(Vo);return i+=(7*c+u)*li,re(ge(i))},N(e,t,n){if(n<=7){let r=0,o=hr({...e,...sa},{...t,...sa});return 7===n&&([r,o]=S(o,7)),{...Xi,weeks:r,days:o}}const r=this.v(e),o=this.v(t);let[i,a,s]=((e,t,n,r,o,i,a)=>{let s=o-t,c=i-n,u=a-r;if(s||c){const l=Math.sign(s||c);let f=e.U(o,i),d=0;if(Math.sign(u)===-l){const r=f;[o,i]=e.un(o,i,-l),s=o-t,c=i-n,f=e.U(o,i),d=l<0?-r:f}if(u=a-Math.min(r,f)+d,s){const[r,a]=e.q(t,n),[u,f]=e.q(o,i);if(c=u-r||Number(f)-Number(a),Math.sign(c)===-l){const n=l<0&&-e.B(o);s=(o-=l)-t,c=i-Mr(r,a,e.L(o))+(n||e.B(o))}}}return[s,c,u]})(this,...r,...o);return 8===n&&(a+=this.cn(i,r[0]),i=0),{...Xi,years:i,months:a,days:s}},F(e,t){const n=Ce(t),r=Kr(this,e),o=Xr(this,e,r,n),i=Qr(this,e,o,r,n);return Xe(re(this.V(r,o,i)),this.id||Ai)},K(e,t){const n=Ce(t),r=Kr(this,e),o=Xr(this,e,r,n);return Qe(ne(this.V(r,o,1)),this.id||Ai)},_(e,t){const n=Ce(t);let r,o,i,a=void 0!==e.eraYear||void 0!==e.year?Kr(this,e):void 0;const s=!this.id;if(void 0===a&&s&&(a=wa),void 0!==a){const t=Xr(this,e,a,n);r=Qr(this,e,t,a,n);const s=this.L(a);o=Ir(t,s),i=t===s}else{if(void 0===e.monthCode)throw new TypeError(Yo);if([o,i]=vr(e.monthCode),this.id&&this.id!==Li&&this.id!==Fi)if(this.id&&"coptic"===Wr(this.id)&&0===n){const t=i||13!==o?30:6;r=e.day,r=M(r,1,t)}else if(this.id&&"chinese"===Wr(this.id)&&0===n){const t=!i||1!==o&&9!==o&&10!==o&&11!==o&&12!==o?30:29;r=e.day,r=M(r,1,t)}else r=e.day;else r=Qr(this,e,Xr(this,e,wa,n),wa,n)}const c=this.G(o,i,r);if(!c)throw new RangeError("Cannot guess year");const[u,l]=c;return et(re(this.V(u,l,r)),this.id||Ai)},fields(e){return Sr(this)&&e.includes("year")?[...e,...Si]:e},k(e,t){const n=Object.assign(Object.create(null),e);return eo(n,t,xi),Sr(this)&&(eo(n,t,ki),this.id===Fi&&eo(n,t,Ni,Si)),n},inLeapYear(e){const[t]=this.v(e);return this.sn(t)},monthsInYear(e){const[t]=this.v(e);return this.B(t)},daysInMonth(e){const[t,n]=this.v(e);return this.U(t,n)},daysInYear(e){const[t]=this.v(e);return this.fn(t)},dayOfYear:yr,era(e){return this.hn(e)[0]},eraYear(e){return this.hn(e)[1]},monthCode(e){const[t,n]=this.v(e),[r,o]=this.q(t,n);return Er(r,o)},dayOfWeek:De,daysInWeek:()=>7},Ns={v:we,hn:Se,q:ye},Ps={dayOfYear:yr,v:we,p:he},Ys=Object.assign({},Ps,{weekOfYear:br,yearOfWeek:wr,m(e){function t(e){return(7-e<r?7:0)-e}function n(e){const n=Me(d+e),r=e||1,o=t(D(c+n*r,7));return l=(n+(o-u)*r)/7}const r=this.id?1:4,o=De(e),i=this.dayOfYear(e),a=D(o-1,7),s=i-1,c=D(a-s,7),u=t(c);let l,f=Math.floor((s-u)/7)+1,d=e.isoYear;return f?f>n(0)&&(f=1,d++):(f=n(-1),d--),[f,d,l]}}),As=Object.assign({},Rs,Ys,{v:we,hn:Se,q:ye,G(e,t){if(!t)return[wa,e]},sn:Ie,L(){},B:ve,cn:e=>e*ya,U:Ee,fn:Me,V:(e,t,n)=>({isoYear:e,isoMonth:t,isoDay:n}),p:he,un:(e,t,n)=>(e+=k(n,ya),(t+=T(n,ya))<1?(e--,t+=ya):t>ya&&(e++,t-=ya),[e,t]),year:e=>e.isoYear,month:e=>e.isoMonth,day:e=>e.isoDay}),Ls={v:Rr,hn:Hr,q:Pr},Fs={dayOfYear:yr,v:Rr,p:Nr,weekOfYear:br,yearOfWeek:wr,m:()=>[]},Hs=Object.assign({},Rs,Fs,{v:Rr,hn:Hr,q:Pr,G(e,t,n){const r=this.id&&"chinese"===Wr(this.id)?((e,t,n)=>{if(t)switch(e){case 1:return 1651;case 2:return n<30?1947:1765;case 3:return n<30?1966:1955;case 4:return n<30?1963:1944;case 5:return n<30?1971:1952;case 6:return n<30?1960:1941;case 7:return n<30?1968:1938;case 8:return n<30?1957:1718;case 9:return 1832;case 10:return 1870;case 11:return 1814;case 12:return 1890}return 1972})(e,t,n):wa;let[o,i,a]=Rr.call(this,{isoYear:r,isoMonth:ya,isoDay:31});const s=Yr.call(this,o),c=i===s;1===(E(e,Ir(i,s))||E(Number(t),Number(c))||E(n,a))&&o--;for(let r=0;r<100;r++){const i=o-r,a=Yr.call(this,i),s=Mr(e,t,a);if(t===(s===a)&&n<=Lr.call(this,i,s))return[i,s]}},sn(e){const t=Ar.call(this,e);return t>Ar.call(this,e-1)&&t>Ar.call(this,e+1)},L:Yr,B:Fr,cn(e,t){const n=t+e,r=Math.sign(e),o=r<0?-1:0;let i=0;for(let e=t;e!==n;e+=r)i+=Fr.call(this,e+o);return i},U:Lr,fn:Ar,V(e,t,n){return ge(Nr.call(this,e,t,n))},p:Nr,un(e,t,n){if(n){if(t+=n,!Number.isSafeInteger(t))throw new RangeError(Vo);if(n<0)for(;t<1;)t+=Fr.call(this,--e);else{let n;for(;t>(n=Fr.call(this,e));)t-=n,e++}}return[e,t]},year(e){return this.h(e).year},month(e){const{year:t,o:n}=this.h(e),{u:r}=this.l(t);return r[n]+1},day(e){return this.h(e).day}}),Bs=$r(Ns,Ls),Us=$r(As,Hs),Zs={...{era:H,eraYear:Z,year:Z,month:$,monthCode(e){const t=H(e);return vr(t),t},day:$},...ai(yi,Z),...ai(qi,W),offset(e){const t=H(e);return Tn(t),t}},Ws=b(d,yi,ta),$s=b(d,ta,yi),qs="numeric",zs=["timeZoneName"],Vs={month:qs,day:qs},Js={year:qs,month:qs},Gs=Object.assign({},Js,{day:qs}),Ks={hour:qs,minute:qs,second:qs},Xs=Object.assign({},Gs,Ks),Qs=Object.assign({},Xs,{timeZoneName:"short"}),ec=Object.keys(Js),tc=Object.keys(Vs),nc=Object.keys(Gs),rc=Object.keys(Ks),oc=["dateStyle"],ic=ec.concat(oc),ac=tc.concat(oc),sc=nc.concat(oc,["weekday"]),cc=rc.concat(["dayPeriod","timeStyle","fractionalSecondDigits"]),uc=sc.concat(cc),lc=zs.concat(cc),fc=zs.concat(sc),dc=zs.concat(["day","weekday"],cc),hc=zs.concat(["year","weekday"],cc),mc=io(uc,Xs),pc=io(uc,Qs),gc=io(uc,Xs,zs),bc=io(sc,Gs,lc),wc=io(cc,Ks,fc),yc=io(ic,Js,dc),vc=io(ac,Vs,hc),Ec={},Mc=new pa(void 0,{calendar:Ai}).resolvedOptions().calendar===Ai,Ic=[mc,rt],Dc=[pc,rt,0,(e,t)=>{const n=e.timeZone;if(t&&t.timeZone!==n)throw new RangeError(Uo);return n}],Sc=[gc,ue],kc=[bc,ue],Tc=[wc,e=>ae(e)/hi],_c=[yc,ue,Mc],xc=[vc,ue,Mc];let Oc;function jc(e,t,n,r,o){function u(...e){if(!(this instanceof u))throw new TypeError(_o);ru(this,t(...e))}function f(e,t){return Object.defineProperties(function(...t){return e.call(this,d(this),...t)},i(t))}function d(t){const n=nu(t);if(!n||n.branding!==e)throw new TypeError(_o);return n}return Object.defineProperties(u.prototype,{...s(l(f,n)),...a(l(f,r)),...c("Temporal."+e)}),Object.defineProperties(u,{...a(o),...i(e)}),[u,e=>{const t=Object.create(u.prototype);return ru(t,e),t},d]}function Cc(e){if(nu(e)||void 0!==e.calendar||void 0!==e.timeZone)throw new TypeError("Invalid bag");return e}function Rc(e){return Nc(e)||Ai}function Nc(e){const{calendar:t}=e;if(void 0!==t)return Pc(t)}function Pc(e){if(r(e)){const{calendar:t}=nu(e)||{};if(!t)throw new TypeError(Fo(e));return t}return(e=>Zr(function(e){const t=Nn(e)||Pn(e)||Yn(e);return t?t.calendar:e}(Zi(e))))(e)}function Yc(e){const t={};for(const n in e)t[n]=e=>{const{calendar:t}=e;return Us(t)[n](e)};return t}function Ac(){throw new TypeError("Cannot use valueOf")}function Lc(e){if(r(e)){const{timeZone:t}=nu(e)||{};if(!t)throw new TypeError(Bo(e));return t}return(e=>$n(function(e){const t=Nn(e);return t&&(t.timeZone||t.j&&ns||t.offset)||e}(Zi(e))))(e)}function Fc(e){if(r(e)){const t=nu(e);return t&&t.branding===es?t:function(e){const t=Vr(e,zi);return nt(wn({...Xi,...t}))}(e)}return function(e){const t=(e=>{const t=ks.exec(e);return t?(e=>{function t(e,t,i){let a=0,s=0;if(i&&([a,o]=I(o,wi[i])),void 0!==e){if(r)throw new RangeError(ni(e));s=(e=>{const t=parseInt(e);if(!Number.isFinite(t))throw new RangeError(ni(e));return t})(e),n=1,t&&(o=Bn(t)*(wi[i]/mi),r=1)}return a+s}let n=0,r=0,o=0,i={...u(qi,[t(e[2]),t(e[3]),t(e[4]),t(e[5]),t(e[6],e[7],5),t(e[8],e[9],4),t(e[10],e[11],3)]),...O(o,2,qi)};if(!n)throw new RangeError(ko(qi));return Zn(e[1])<0&&(i=gn(i)),i})(t):void 0})(Zi(e));if(!t)throw new RangeError(ti(e));return nt(wn(t))}(e)}function Hc(e){if(void 0!==e){if(r(e)){const t=nu(e)||{};switch(t.branding){case Xa:case Ja:return t;case Ga:return Xe(t)}const n=Rc(e);return{...qr(Lc,us,Us(n),e),calendar:n}}return function(e){const t=Nn(Zi(e));if(!t)throw new RangeError(ti(e));if(t.timeZone)return On(t,t.offset?Tn(t.offset):void 0);if(t.j)throw new RangeError(ti(e));return Cn(t)}(e)}}function Bc(e,t){if(r(e)){const n=nu(e)||{};switch(n.branding){case Ka:return Ce(t),n;case Ga:return Ce(t),tt(n);case Xa:return Ce(t),oo(us,n)}return function(e,t){return tt(Jr(Vr(e,vi,[],1),Ce(t)))}(e,t)}const n=function(e){let t,n=(e=>{const t=Is.exec(e);return t?(Hn(t[10]),Fn(t)):void 0})(Zi(e));if(!n){if(n=Nn(e),!n)throw new RangeError(ti(e));if(!n.C)throw new RangeError(ti(e));if(n.j)throw new RangeError(ni("Z"));xn(n)}if((t=Pn(e))&&xe(t))throw new RangeError(ti(e));if((t=Yn(e))&&xe(t))throw new RangeError(ti(e));return tt(je(n,1))}(e);return Ce(t),n}function Uc(e){return void 0===e?void 0:Bc(e)}function Zc(e,t){if(r(e)){const n=nu(e)||{};switch(n.branding){case Ga:return Ce(t),n;case Ja:return Ce(t),Ke({...n,...sa});case Xa:return Ce(t),no(us,n)}return function(e,t,n){const r=zr(e,t,Ri,[],yi),o=Ce(n);return Ke(oe({...e.F(r,$e(o)),...Jr(r,o)}))}(Us(Rc(e)),e,t)}const n=function(e){const t=Nn(Zi(e));if(!t||t.j)throw new RangeError(ti(e));return Ke(jn(t))}(e);return Ce(t),n}function Wc(e,t){if(r(e)){const n=nu(e);if(n&&n.branding===Va)return Ce(t),n;const r=Nc(e);return function(e,t,n,r){const o=zr(e,n,Ri,Oi);return t&&void 0!==o.month&&void 0===o.monthCode&&void 0===o.year&&(o.year=wa),e._(o,r)}(Us(r||Ai),!r,e,t)}const n=function(e,t){const n=Yn(Zi(t));if(n)return xn(n),et(_e(n));const r=_n(t,0,1),{calendar:o}=r,i=e(o),[a,s,c]=i.v(r),[u,l]=i.q(a,s),[f,d]=i.G(u,l,c);return et(re(i.V(f,d,c)),o)}(Us,e);return Ce(t),n}function $c(e,t){if(r(e)){const n=nu(e);return n&&n.branding===za?(Ce(t),n):function(e,t,n,r){const o=zr(e,t,ji,r);return e.K(o,n)}(Us(Rc(e)),e,t)}const n=function(e,t){const n=Pn(Zi(t));if(n)return xn(n),Qe(ne(_e(n)));const r=_n(t,1);return Qe(on(e(r.calendar),r))}(Us,e);return Ce(t),n}function qc(e,t){if(r(e)){const n=nu(e)||{};switch(n.branding){case Ja:return Ce(t),n;case Ga:return Ce(t),Xe(n);case Xa:return Ce(t),ro(us,n)}return function(e,t,n,r=[]){const o=zr(e,t,Ri,r);return e.F(o,n)}(Us(Rc(e)),e,t)}const n=_n(e);return Ce(t),n}function zc(e,t){if(r(e)){const n=nu(e);if(n&&n.branding===Xa)return Re(t),n;const r=Rc(e);return function(e,t,n,r,o,i){const a=zr(n,o,Ri,Mi,Di),s=e(a.timeZone),[c,u,l]=Re(i),f=n.F(a,$e(c)),d=Jr(a,c);return Ge(qt(t(s),{...f,...d},void 0!==a.offset?Tn(a.offset):void 0,u,l),s,r)}(Lc,us,Us(r),r,e,t)}return function(e,t){const n=Nn(Zi(e));if(!n||!n.timeZone)throw new RangeError(ti(e));const{offset:r}=n,o=r?Tn(r):void 0,[,i,a]=Re(t);return On(n,o,i,a)}(e,t)}function Vc(e){return l(e=>t=>e(Jc(t)),e)}function Jc(e){return ss(e,us)}function Gc(e){if(r(e)){const t=nu(e);if(t)switch(t.branding){case Qa:return t;case Xa:return Je(t.epochNanoseconds)}}return function(e){const t=Nn(e=H(e));if(!t)throw new RangeError(ti(e));let n;if(t.j)n=0;else{if(!t.offset)throw new RangeError(ti(e));n=Tn(t.offset)}return t.timeZone&&An(t.timeZone,1),Je(fe(Te(t),n))}(e)}function Kc(){function e(e,n){return new t(e,n)}function t(e,t=Object.create(null)){Uu.set(this,((e,t)=>{const n=new pa(e,t),r=n.resolvedOptions(),i=r.locale,a=h(Object.keys(t),r),s=o(eu),c=(e,...t)=>{if(e){if(2!==t.length)throw new TypeError(ri);for(const e of t)if(void 0===e)throw new TypeError(ri)}e||void 0!==t[0]||(t=[]);const r=t.map(e=>nu(e)||Number(e));let o,c=0;for(const e of r){const t="object"==typeof e?e.branding:void 0;if(c++&&t!==o)throw new TypeError(ri);o=t}return o?s(o)(i,a,...r):[n,...r]};return c.X=n,c})(e,t))}const n=pa.prototype,r=Object.getOwnPropertyDescriptors(n),a=Object.getOwnPropertyDescriptors(pa);for(const t in r){const n=r[t],o=t.startsWith("format")&&Xc(t);"function"==typeof n.value?n.value="constructor"===t?e:o||Qc(t):o&&(n.get=function(){if(!Uu.has(this))throw new TypeError(_o);return(...e)=>o.apply(this,e)},Object.defineProperties(n.get,i(`get ${t}`)))}return a.prototype.value=t.prototype=Object.create({},r),Object.defineProperties(e,a),e}function Xc(e){return Object.defineProperties(function(...t){const n=Uu.get(this),[r,...o]=n(e.includes("Range"),...t);return r[e](...o)},i(e))}function Qc(e){return Object.defineProperties(function(...t){return Uu.get(this).X[e](...t)},i(e))}function eu(e){const t=bu[e];if(!t)throw new TypeError((e=>`Cannot format ${e}`)(e));return ao(t,o(so),1)}const tu=new WeakMap,nu=tu.get.bind(tu),ru=tu.set.bind(tu),ou={era:function(e){if(void 0!==e)return Zi(e)},eraYear:j,year:R,month:C,daysInMonth:C,daysInYear:C,inLeapYear:Wi,monthsInYear:C},iu={monthCode:Zi},au={day:C},su={dayOfWeek:C,dayOfYear:C,weekOfYear:function(e){if(void 0!==e)return C(e)},yearOfWeek:j,daysInWeek:C},cu=Yc(Object.assign({},ou,iu,au,su)),uu=Yc({...ou,...iu}),lu=Yc({...iu,...au}),fu={calendarId:e=>e.calendar},du=f(e=>t=>t[e],qi.concat("sign")),hu=f((e,t)=>e=>e[ta[t]],yi),mu={epochMilliseconds:rt,epochNanoseconds:function(e){return((e,t=1)=>{const[n,r]=e,o=Math.floor(r/t),i=bi/t;return BigInt(n)*BigInt(i)+BigInt(o)})(e.epochNanoseconds)}},[pu,gu]=jc(es,function(e=0,t=0,n=0,r=0,o=0,i=0,a=0,s=0,c=0,f=0){return nt(wn(l(W,u(qi,[e,t,n,r,o,i,a,s,c,f]))))},{...du,blank:function(e){return!e.sign}},{with:(e,t)=>gu(function(e,t){return nt((n=e,r=t,wn({...n,...Vr(r,zi)})));var n,r}(e,t)),negated:e=>gu(pn(e)),abs:e=>gu(function(e){return-1===e.sign?pn(e):e}(e)),add:(e,t,n)=>gu(mn(Hc,Us,us,0,e,Fc(t),n)),subtract:(e,t,n)=>gu(mn(Hc,Us,us,1,e,Fc(t),n)),round:(e,t)=>gu(function(e,t,n,r,o){const i=Dn(r),[a,s,c,u,l]=((e,t,n)=>{e=We(e,Ma);let r=La(e);const o=n(e[ka]);let i=He(e);const a=qa(e,7);let s=Aa(e);if(void 0===r&&void 0===s)throw new RangeError(Qo);if(null==s&&(s=0),null==r&&(r=Math.max(s,t)),Ve(r,s),i=Be(i,s,1),i>1&&s>5&&r!==s)throw new RangeError("For calendar units with roundingIncrement > 1, use largestUnit = smallestUnit");return[r,s,i,a,o]})(o,i,e),f=Math.max(i,a);if(!l&&f<=6)return nt(wn(((e,t,n,r,o)=>{const i=bt(vn(e),n,r,o);return{...Xi,...En(i,t)}})(r,a,s,c,u)));if(!dn(l)&&!r.sign)return r;if(!l)throw new RangeError(Ko);const[d,h,m]=cn(t,n,l),p=un(m),g=ln(m),b=fn(m),w=g(h,d,r);dn(l)||(oe(d),oe(w));let y=b(h,d,w,a);const v=r.sign,E=bn(y);if(v&&E&&v!==E)throw new RangeError(Lo);return y=gt(y,p(w),a,s,c,u,h,d,p,g),nt(y)}(Hc,Us,us,e,t)),total:(e,t)=>function(e,t,n,r,o){const i=Dn(r),[a,s]=((e,t)=>{const n=t((e=We(e,Ia))[ka]);let r=Fa(e);return r=N(Ia,r),[r,n]})(o,e),c=Math.max(a,i);if(!s&&hn(c,s))return it(r,a);if(!s)throw new RangeError(Ko);if(!r.sign)return 0;const[u,l,f]=cn(t,n,s),d=un(f),h=ln(f),m=fn(f),p=h(l,u,r);dn(s)||(oe(u),oe(p));const g=m(l,u,p,a);return hn(a,s)?it(g,a):((e,t,n,r,o,i,a)=>{const s=bn(e),[c,u]=at(r,ea(n,e),n,s,o,i,a),l=st(t,c,u);return e[qi[n]]+l*s})(g,d(p),a,l,u,d,h)}(Hc,Us,us,e,t),toLocaleString(e,t,n){return Intl.DurationFormat?new Intl.DurationFormat(t,n).format(this):jt(e)},toString:jt,toJSON:e=>jt(e),valueOf:Ac},{from:e=>gu(Fc(e)),compare:(e,t,n)=>function(e,t,n,r,o,i){const a=e(Ze(i).relativeTo),s=Math.max(Dn(r),Dn(o));if(p(qi,r,o))return 0;if(hn(s,a))return G(vn(r),vn(o));if(!a)throw new RangeError(Ko);const[c,u,l]=cn(t,n,a),f=un(l),d=ln(l);return G(f(d(u,c,r)),f(d(u,c,o)))}(Hc,Us,us,Fc(e),Fc(t),n)}),bu={Instant:Ic,PlainDateTime:Sc,PlainDate:kc,PlainTime:Tc,PlainYearMonth:_c,PlainMonthDay:xc},wu=ao(Ic),yu=ao(Dc),vu=ao(Sc),Eu=ao(kc),Mu=ao(Tc),Iu=ao(_c),Du=ao(xc),[Su,ku]=jc(Ka,function(e=0,t=0,n=0,r=0,o=0,i=0){return tt(je(l(Z,u(ta,[e,t,n,r,o,i])),1))},hu,{with(e,t,n){return ku(function(e,t,n){return tt(((e,t,n)=>Jr({...h(vi,e),...Vr(t,vi)},Ce(n)))(e,t,n))}(this,Cc(t),n))},add:(e,t)=>ku(en(0,e,Fc(t))),subtract:(e,t)=>ku(en(1,e,Fc(t))),until:(e,t,n)=>gu(ar(0,e,Bc(t),n)),since:(e,t,n)=>gu(ar(1,e,Bc(t),n)),round:(e,t)=>ku(function(e,t){const[n,r,o]=Pe(t,5);var i;return tt((i=o,lt(e,dt(n,r),i)[0]))}(e,t)),equals:(e,t)=>function(e,t){return!Xn(e,t)}(e,Bc(t)),toLocaleString(e,t,n){const[r,o]=Mu(t,n,e);return r.format(o)},toString:Ot,toJSON:e=>Ot(e),valueOf:Ac},{from:(e,t)=>ku(Bc(e,t)),compare:(e,t)=>Xn(Bc(e),Bc(t))}),[Tu,_u]=jc(Ga,b(function(e,t,n,r,o=0,i=0,a=0,s=0,c=0,f=0,d=Ai){return Ke(oe(Te(l(Z,u(ra,[t,n,r,o,i,a,s,c,f])))),e(d))},Ur),{...fu,...cu,...hu},{with:(e,t,n)=>_u(function(e,t,n,r){const o=e(t.calendar),i=[...o.fields(Ri),...yi].sort(),a={...to(s=t),hour:s.isoHour,minute:s.isoMinute,second:s.isoSecond,millisecond:s.isoMillisecond,microsecond:s.isoMicrosecond,nanosecond:s.isoNanosecond};var s;const c=Vr(n,i),u=Ce(r),l=o.k(a,c),f={...a,...c};return Ke(oe({...o.F(l,$e(u)),...je(Ws(f),u)}))}(Us,e,Cc(t),n)),withCalendar:(e,t)=>_u(uo(e,Pc(t))),withPlainTime:(e,t)=>_u(function(e,t=sa){return Ke(oe({...e,...t}))}(e,Uc(t))),add:(e,t,n)=>_u(Kt(Us,0,e,Fc(t),n)),subtract:(e,t,n)=>_u(Kt(Us,1,e,Fc(t),n)),until:(e,t,n)=>gu(nr(Us,0,e,Zc(t),n)),since:(e,t,n)=>gu(nr(Us,1,e,Zc(t),n)),round:(e,t)=>_u(function(e,t){return Ke(ct(e,...Pe(t)),e.calendar)}(e,t)),equals:(e,t)=>function(e,t){return!Gn(e,t)&&e.calendar===t.calendar}(e,Zc(t)),toZonedDateTime:(e,t,n)=>Yu(function(e,t,n,r){const o=((e,t,n,r)=>{const o=(e=>Ba(Ze(e)))(r);return zt(e(t),n,o)})(e,n,t,r);return Ge(ie(o),n,t.calendar)}(us,e,Lc(t),n)),toPlainDate:e=>Nu(Xe(e)),toPlainTime:e=>ku(tt(e)),toLocaleString(e,t,n){const[r,o]=vu(t,n,e);return r.format(o)},toString:kt,toJSON:e=>kt(e),valueOf:Ac},{from:(e,t)=>_u(Zc(e,t)),compare:(e,t)=>Gn(Zc(e),Zc(t))}),[xu,Ou]=jc(Va,b(function(e,t,n,r=Ai,o=wa){const i=Z(t),a=Z(n),s=e(r);return et(re(_e({isoYear:Z(o),isoMonth:i,isoDay:a})),s)},Ur),{...fu,...lu},{with:(e,t,n)=>Ou(function(e,t,n,r){const o=e(t.calendar),i=o.fields(Ri).sort(),a=(e=>{const t=Bs(e.calendar),[n,r,o]=t.v(e),[i,a]=t.q(n,r);return{monthCode:Er(i,a),day:o}})(t),s=Vr(n,i),c=o.k(a,s);return o._(c,r)}(Us,e,Cc(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,Wc(t)),toPlainDate(e,t){return Nu(function(e,t,n,r){return((e,t,n)=>Gr(e,t,Pi,P(n),Ti))(e(t.calendar),n,r)}(Us,e,this,t))},toLocaleString(e,t,n){const[r,o]=Du(t,n,e);return r.format(o)},toString:xt,toJSON:e=>xt(e),valueOf:Ac},{from:(e,t)=>Ou(Wc(e,t))}),[ju,Cu]=jc(za,b(function(e,t,n,r=Ai,o=1){const i=Z(t),a=Z(n),s=e(r);return Qe(ne(_e({isoYear:i,isoMonth:a,isoDay:Z(o)})),s)},Ur),{...fu,...uu},{with:(e,t,n)=>Cu(function(e,t,n,r){const o=e(t.calendar),i=o.fields(ji).sort(),a=(e=>{const t=Bs(e.calendar),[n,r]=t.v(e),[o,i]=t.q(n,r);return{year:n,monthCode:Er(o,i)}})(t),s=Vr(n,i),c=o.k(a,s);return o.K(c,r)}(Us,e,Cc(t),n)),add:(e,t,n)=>Cu(Qt(Us,0,e,Fc(t),n)),subtract:(e,t,n)=>Cu(Qt(Us,1,e,Fc(t),n)),until:(e,t,n)=>gu(or(Us,0,e,$c(t),n)),since:(e,t,n)=>gu(or(Us,1,e,$c(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,$c(t)),toPlainDate(e,t){return Nu(function(e,t,n,r){return((e,t,n)=>Gr(e,t,Ci,P(n),Oi))(e(t.calendar),n,r)}(Us,e,this,t))},toLocaleString(e,t,n){const[r,o]=Iu(t,n,e);return r.format(o)},toString:_t,toJSON:e=>_t(e),valueOf:Ac},{from:(e,t)=>Cu($c(e,t)),compare:(e,t)=>Kn($c(e),$c(t))}),[Ru,Nu]=jc(Ja,b(function(e,t,n,r,o=Ai){return Xe(re(_e(l(Z,{isoYear:t,isoMonth:n,isoDay:r}))),e(o))},Ur),{...fu,...cu},{with:(e,t,n)=>Nu(function(e,t,n,r){const o=e(t.calendar),i=o.fields(Ri).sort(),a=to(t),s=Vr(n,i),c=o.k(a,s);return o.F(c,r)}(Us,e,Cc(t),n)),withCalendar:(e,t)=>Nu(uo(e,Pc(t))),add:(e,t,n)=>Nu(Xt(Us,0,e,Fc(t),n)),subtract:(e,t,n)=>Nu(Xt(Us,1,e,Fc(t),n)),until:(e,t,n)=>gu(rr(Us,0,e,qc(t),n)),since:(e,t,n)=>gu(rr(Us,1,e,qc(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,qc(t)),toZonedDateTime(e,t){const n=r(t)?t:{timeZone:t};return Yu(function(e,t,n,r,o){const i=e(o.timeZone),a=o.plainTime,s=void 0!==a?t(a):void 0,c=n(i);let u;return u=s?zt(c,{...r,...s}):Vt(c,{...r,...sa}),Ge(u,i,r.calendar)}(Lc,Bc,us,e,n))},toPlainDateTime:(e,t)=>_u(function(e,t=sa){return Ke(oe({...e,...t}))}(e,Uc(t))),toPlainYearMonth(e){return Cu(function(e,t,n){return((e,t)=>{const n=zr(e,t,Ci);return e.K(n,void 0)})(e(t.calendar),n)}(Us,e,this))},toPlainMonthDay(e){return Ou(function(e,t,n){return((e,t)=>{const n=zr(e,t,Pi);return e._(n)})(e(t.calendar),n)}(Us,e,this))},toLocaleString(e,t,n){const[r,o]=Eu(t,n,e);return r.format(o)},toString:Tt,toJSON:e=>Tt(e),valueOf:Ac},{from:(e,t)=>Nu(qc(e,t)),compare:(e,t)=>Kn(qc(e),qc(t))}),[Pu,Yu]=jc(Xa,b(function(e,t,n,r,o=Ai){return Ge(ie(X(B(n))),t(r),e(o))},Ur,function(e){return $n(Zi(e))}),{...mu,...fu,...Vc(cu),...Vc(hu),offset:e=>Ft(Jc(e).offsetNanoseconds),offsetNanoseconds:e=>Jc(e).offsetNanoseconds,timeZoneId:e=>e.timeZone,hoursInDay:e=>function(e,t){const n=e(t.timeZone),r=ss(t,n),[o,i]=ht(r),a=ee(J(Vt(n,o),Vt(n,i)),gi,1);if(a<=0)throw new RangeError(Lo);return a}(us,e)},{with:(e,t,n)=>Yu(function(e,t,n,r,o){const{calendar:i,timeZone:a}=n,s=e(i),c=t(a),u=[...s.fields(Ri),...Ii].sort(),l=(e=>{const t=ss(e,us),n=Ft(t.offsetNanoseconds),r=Bs(e.calendar),[o,i,a]=r.v(t),[s,c]=r.q(o,i),u=Er(s,c);return{...$s(t),year:o,monthCode:u,day:a,offset:n}})(n),f=Vr(r,u),d=s.k(l,f),h={...l,...f},[m,p,g]=Re(o,2);return Ge(qt(c,{...s.F(d,$e(m)),...je(Ws(h),m)},Tn(h.offset),p,g),a,i)}(Us,us,e,Cc(t),n)),withCalendar:(e,t)=>Yu(uo(e,Pc(t))),withTimeZone:(e,t)=>Yu(function(e,t){return{...e,timeZone:t}}(e,Lc(t))),withPlainTime:(e,t)=>Yu(function(e,t,n){const r=t.timeZone,o=e(r),i={...ss(t,o),...n||sa};let a;return a=n?qt(o,i,i.offsetNanoseconds,2):Vt(o,i),Ge(a,r,t.calendar)}(us,e,Uc(t))),add:(e,t,n)=>Yu(Gt(Us,us,0,e,Fc(t),n)),subtract:(e,t,n)=>Yu(Gt(Us,us,1,e,Fc(t),n)),until:(e,t,n)=>gu(nt(tr(Us,us,0,e,zc(t),n))),since:(e,t,n)=>gu(nt(tr(Us,us,1,e,zc(t),n))),round:(e,t)=>Yu(function(e,t,n){let{epochNanoseconds:r,timeZone:o,calendar:i}=t;const[a,s,c]=Pe(n);if(0===a&&1===s)return t;const u=e(o);if(6===a)r=((e,t,n,r)=>{const o=ss(n,t),[i,a]=e(o),s=n.epochNanoseconds,c=Vt(t,i),u=Vt(t,a);if(K(s,c,u))throw new RangeError(Lo);return vt(st(s,c,u),r)?u:c})(ht,u,t,c);else{const e=u.R(r);r=qt(u,ct(pe(r,e),a,s,c),e,2,0,1)}return Ge(r,o,i)}(us,e,t)),startOfDay:e=>Yu(function(e,t){const{timeZone:n,calendar:r}=t,o=((e,t,n)=>Vt(t,e(ss(n,t))))(mt,e(n),t);return Ge(o,n,r)}(us,e)),equals:(e,t)=>function(e,t){return!Jn(e,t)&&!!Qn(e.timeZone,t.timeZone)&&e.calendar===t.calendar}(e,zc(t)),toInstant:e=>Lu(function(e){return Je(e.epochNanoseconds)}(e)),toPlainDateTime:e=>_u(no(us,e)),toPlainDate:e=>Nu(ro(us,e)),toPlainTime:e=>ku(oo(us,e)),toLocaleString(e,t,n={}){const[r,o]=yu(t,n,e);return r.format(o)},toString:(e,t)=>St(us,e,t),toJSON:e=>St(us,e),valueOf:Ac,getTimeZoneTransition(e,t){const{timeZone:n,epochNanoseconds:r}=e,o=function(e){const t=We(e,Ta),n=ze(Ta,Ya,t,0);if(!n)throw new RangeError(Mo(Ta,n));return n}(t),i=us(n).O(r,o);return i?Yu({...e,epochNanoseconds:i}):null}},{from:(e,t)=>Yu(zc(e,t)),compare:(e,t)=>Jn(zc(e),zc(t))}),[Au,Lu]=jc(Qa,function(e){return Je(ie(X(B(e))))},mu,{add:(e,t)=>Lu(Jt(0,e,Fc(t))),subtract:(e,t)=>Lu(Jt(1,e,Fc(t))),until:(e,t,n)=>gu(er(0,e,Gc(t),n)),since:(e,t,n)=>gu(er(1,e,Gc(t),n)),round:(e,t)=>Lu(function(e,t){const[n,r,o]=Pe(t,5,1);return Je(bt(e.epochNanoseconds,n,r,o,1))}(e,t)),equals:(e,t)=>function(e,t){return!Vn(e,t)}(e,Gc(t)),toZonedDateTimeISO:(e,t)=>Yu(function(e,t,n=Ai){return Ge(e.epochNanoseconds,t,n)}(e,Lc(t))),toLocaleString(e,t,n){const[r,o]=wu(t,n,e);return r.format(o)},toString:(e,t)=>Dt(Lc,us,e,t),toJSON:e=>Dt(Lc,us,e),valueOf:Ac},{from:e=>Lu(Gc(e)),fromEpochMilliseconds:e=>Lu(function(e){return Je(ie(Q(W(e),hi)))}(e)),fromEpochNanoseconds:e=>Lu(function(e){return Je(ie(X(B(e))))}(e)),compare:(e,t)=>Vn(Gc(e),Gc(t))}),Fu=Object.defineProperties({},{...c("Temporal.Now"),...a({timeZoneId:()=>ho(),instant:()=>Lu(Je(fo())),zonedDateTimeISO:(e=ho())=>Yu(Ge(fo(),Lc(e),Ai)),plainDateTimeISO:(e=ho())=>_u(Ke(lo(us(Lc(e))),Ai)),plainDateISO:(e=ho())=>Nu(Xe(lo(us(Lc(e))),Ai)),plainTimeISO:(e=ho())=>ku(tt(lo(us(Lc(e)))))})}),Hu=Object.defineProperties({},{...c("Temporal"),...a({PlainYearMonth:ju,PlainMonthDay:xu,PlainDate:Ru,PlainTime:Su,PlainDateTime:Tu,ZonedDateTime:Pu,Instant:Au,Duration:pu,Now:Fu})}),Bu=Kc(),Uu=new WeakMap;function Zu(e,...t){let n=bbn.lng[e]||e;if(t.length){let e=0;return n.replace(/\%([d|s])/g,(n,r)=>{let o=t[e++];o||(o="d"===r?0:"");const i=typeof o;return"d"===r&&"number"!==i?(o=parseFloat(o),isNaN(o)&&(o=0)):"s"===r&&"string"!==i&&(o=""+o),o})}return n}Object.create(Intl),a({DateTimeFormat:Bu});var Wu={loggers:{_num:0},datatypes:["xml","html","script","json","jsonp","text","blob"],shortenLen:30,keys:{upDown:[33,34,35,36,38,40],leftRight:[36,35,37,39],dels:[8,46,45],confirm:[13,9],alt:[20,16,17,18,144],numbers:[48,49,50,51,52,53,54,55,56,57,96,97,98,99,100,101,102,103,104,105],numsigns:[109,110,189,190]},comparators:[">=","<=",">","<","="],operators:["+","-","/","*"],tags:["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","label","legend","li","link","main","map","mark","menu","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","slot","small","source","span","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr"],colors:{darkgrey:"#5a6a62",black:"#000000",anthracite:"#454545",grey:"#d3d3d3",white:"#ffffff",beige:"#fdfdfd",lightgrey:"#dcdcdc",pastelblue:"#ddebf6",cyan:"#00c8f8",blue:"#6e9ecf",indigo:"#3f51b5",navy:"#354458",webblue:"#2196f3",teal:"#009688",turquoise:"#1fda9a",pastelgreen:"#e2efda",palegreen:"#ccffcc",green:"#00a03e",olive:"#92b06a",pastelorange:"#fff2cc",yellow:"#fdf200",orange:"#ff9900",pink:"#eb65a0",purple:"#a333c8",red:"#db3340",brown:"#8c6954"},reserved:["abstract","boolean","break","byte","case","catch","char","class","continue","const","debugger","default","delete","do","double","else","enum","export","extends","false","final","finally","float","for","function","goto","if","implements","import","in","instanceof","int","interface","long","new","null","package","return","super","switch","synchronized","this","throw","throws","transient","true","try","typeof","var","void","while","with"],mockText:"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.",regexp:{url:new RegExp("^(https?:\\/\\/)?((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.?)+[a-z]{2,}|((\\d{1,3}\\.){3}\\d{1,3}))(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*(\\?[;&a-z\\d%_.~+=-]*)?(\\#[-a-z\\d_]*)?$","i"),ip:/^((\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])\.){3}(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])$/,hostname:/^[a-z\d]([a-z\d-]{0,61}[a-z\d])?(\.[a-z\d]([a-z\d-]{0,61}[a-z\d])?)*$/i}},$u={siteTitle:window.document.title,logging:!1,cdn:"",lang:"en",host:window.location.protocol+"//"+window.location.hostname,url:window.location.href,old_path:null,loading:!1,_enumerated:[],get isEnumerating(){return this._enumerated.length>0},width:0,height:0,focused:!1,last_focus:(new Date).getTime(),sleep:!1,theme:"dark",loaders:[],loadersHistory:[],maxLoadersHistory:50,resizeTimer:!1,hashChanged:0,params:[],isInit:!1,isFocused:!1,timeoff:Math.round((new Date).getTime()/1e3),loggingLevel:5,ignoreUnload:!1,historyDisabled:!1,nav:"ajax",online:window.navigator.onLine},qu=function(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function s(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}c((r=r.apply(e,t||[])).next())})};class zu extends Error{constructor(e){super(e||"Request canceled"),this.name="Cancel",this.__BBN_CANCEL__=!0}}const Vu=["POST","PUT","PATCH","DELETE"],Ju=(e,t,n={},r)=>{const o=new XMLHttpRequest,i=Vu.includes(e.toUpperCase()),a=new Promise((r,a)=>{o.open(e,t,!0);const{body:s,headers:c}=((e,t)=>{const n=new Headers(t||{});let r=e;return null==e||e instanceof FormData||"object"!=typeof e||(n.set("Content-Type","application/json"),r=JSON.stringify(e)),{body:r,headers:n}})(n.data,n.headers);c.forEach((e,t)=>{o.setRequestHeader(t,e)}),"function"==typeof n.onUploadProgress&&o.upload&&o.upload.addEventListener("progress",e=>{const t=e.lengthComputable?e.total:void 0;n.onUploadProgress({loaded:e.loaded,total:t,progress:t?e.loaded/t:void 0})}),o.onreadystatechange=()=>{if(4!==o.readyState)return;const e=(e=>{const t={};return e?(e.trim().split(/[\r\n]+/).forEach(e=>{const n=e.split(": "),r=n.shift(),o=n.join(": ");r&&(t[r.toLowerCase()]=o)}),t):t})(o.getAllResponseHeaders()),t=1223===o.status?204:o.status,i=o.statusText||"";let s=o.responseText;if((e["content-type"]||"").includes("application/json"))try{s=JSON.parse(o.responseText)}catch(e){}const c={data:s,status:t,statusText:i,headers:e,config:n,request:o};if(t>=200&&t<300)r(c);else{const e=new Error("Request failed with status code "+t);e.response=c,e.config=n,e.request=o,a(e)}},o.onerror=()=>{const e=new Error("Network Error");e.config=n,e.request=o,a(e)},o.onabort=()=>{a(new zu("Request canceled"))},i?o.send(s):o.send()});return a.cancel=()=>o.abort(),a};var Gu={isCancel:e=>!(!e||!0!==e.__BBN_CANCEL__),run:(e,t,n={},r)=>{n.baseURL&&!/^https?:\/\//i.test(t)&&(t=n.baseURL.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,"")),t=((e,t)=>{if(!t)return e;const n=new URLSearchParams(t).toString();return n?e+(e.includes("?")?"&":"?")+n:e})(t,n.params);return"function"==typeof n.onUploadProgress&&Vu.includes(e.toUpperCase())?Ju(e,t,n):((e,t,n={},r)=>{const o={method:e,headers:new Headers(n.headers||{}),signal:null==r?void 0:r.signal},i=Vu.includes(e.toUpperCase());if(null!=n.data&&i&&(bbn.fn.log("DATA",n.data),"object"!=typeof n.data||n.data instanceof FormData?o.body=n.data:(o.headers.set("Content-Type","application/json"),o.body=JSON.stringify(n.data))),n.params){const e=new URLSearchParams(n.params).toString();t+=(t.includes("?")?"&":"?")+e}const a=fetch(t,o).then(e=>qu(void 0,void 0,void 0,function*(){let t;t=(e.headers.get("content-type")||"").includes("application/json")?yield e.json():yield e.text();const r={data:t,status:e.status,statusText:e.statusText,headers:Object.fromEntries(e.headers.entries()),config:n,request:e};if(!e.ok){const t=new Error("Request failed with status code "+e.status);throw t.response=r,t.config=n,t.request=e,t}return r})).catch(e=>{if("AbortError"===e.name)throw new zu("Request canceled");throw e});return a.cancel=()=>r.abort(),a})(e,t,n,r)}};function Ku(...e){if(!e.length)return!1;for(let t of e)if(["boolean","object","symbol"].includes(typeof t)||""===t||isNaN(t))return!1;return!0}function Xu(...e){if(!e.length)return!1;for(let t of e)if(!t||"object"!=typeof t||!(Symbol.iterator in Object(t)))return!1;return!0}function Qu(...e){if(!e.length)return!1;for(let t of e)if("[object String]"!=={}.toString.apply(t))return!1;return!0}function el(...e){if(!e.length)return!1;for(let t of e)if(!Number.isInteger(t))return!1;return!0}function tl(...e){if(!e.length)return!1;for(let t of e)if(!(t&&t.constructor&&t.call&&t.apply))return!1;return!0}function nl(...e){var t,n,r;if((null===(t=bbn.env)||void 0===t?void 0:t.isDev)&&void 0!==(null===window||void 0===window?void 0:window.console)){let t,o=5,i="log";e[0]&&"object"==typeof e[0]&&e[0]._bbn_console_style&&(e[0]._bbn_console_mode&&tl(console[e[0]._bbn_console_mode])?i=e[0]._bbn_console_mode:(t=e[0]._bbn_console_style,o=e[0]._bbn_console_level),e.shift());const a=window.console[i];if((null===(r=null===(n=window.bbn)||void 0===n?void 0:n.env)||void 0===r?void 0:r.loggingLevel)>=o){let n=0;for(;n<e.length;){let r=typeof e[n],o=[e[n]];"string"!==r&&"number"!==r||o.unshift("%c %s ",t),a.apply(window.console,o),n++}}}return this}function rl(e,t,n){if(!Qu(e)||!el(t))throw nl(arguments),new Error(bbn._("The substr function should be applied to a string and at least a `from` argument should be given"));return t<0&&(t=e.length+t),el(n)?e.substring(t,(n<0?e.length:t)+n):e.substring(t)}function ol(e,t=!1){let n=null;if("object"==typeof e)for(var r in n={},e)rl(r,0,1).match(/^[A-z0-9]$/)&&r in e&&(t&&"object"==typeof e[r]?n[r]=ol(e[r],!0):n[r]=e[r]);return n||!1}function il(e,t,n=!1,r=!1){if(null!==e&&"object"==typeof e){let o=Object.keys(n?ol(e):e);r&&o.reverse();for(let n of o)if(!1===t(e[n],n))break}return e}function al(e,t){if(!(Ku(e)&&e>0)){if(Xu(e)){for(let n=0;n<e.length;n++)if(!1===t(e[n],n))return;return e}return il(e,t)}for(let n=0;n<e;n++)if(!1===t(n,n))return}function sl(...e){if(!e.length)return!1;for(let t of e)if("[object Object]"!=={}.toString.apply(t))return!1;return!0}function cl(...e){if(!e.length)return!1;for(let t of e)if(!Array.isArray(t))return!1;return!0}function ul(...e){let t=!1,n=[];for(let r=0;r<e.length;r++)if(!0===e[r])t=!0;else{if(!e[r])continue;if("object"!=typeof e[r])throw new Error(bbn._("Error in extend: all arguments should be object, you have given ")+typeof e[r]);n.push(e[r])}if(!n.length)throw new Error("No argument given");let r,o=n[0];for(let e=1;e<n.length;e++)il(n[e],(e,n)=>{t?cl(e)?(o[n]=cl(o[n])?o[n]:[],al(e,(e,t)=>{if(e&&"object"==typeof e){let r=o[n][t];cl(e)?cl(r)||(r=[]):sl(r)||(r={}),o[n][t]=ul(!0,r,e)}else o[n][t]=e})):sl(e)?o[n]=ul(!0,o[n]&&"object"==typeof o[n]?o[n]:Object.create(Object.getPrototypeOf(e)),e):o[n]=e:(o[n]!==e||void 0===e&&!Object.prototype.hasOwnProperty.apply(o,[n]))&&(o[n]=e)}),r||(r=!!n[e].__bbnNoData);return r&&"bbnData"in window&&(o.__bbnData&&o.__bbnData.unset(),Object.defineProperty(o,"__bbnNoData",{value:!0,enumerable:!1,configurable:!1,writable:!1})),o}const ll=window.indexedDB||window.webkitIndexedDB||window.mozIndexedDB||window.OIndexedDB||window.msIndexedDB,fl=(e,t)=>{if(null==t?void 0:t.length){let n={};return il(e,(e,r)=>{t.indexOf(r)>-1&&(n[r]=e)}),n}return e},dl=function(e){const t=hl._connections[e],n=hl._structures[e];let r=null;const o=(e,t)=>{e.onerror=()=>{r=e.error,nl(e.error),t(e.error)}},i=(e,n)=>{const o=t.transaction([e],0===n.toLowerCase().indexOf("r")?"readonly":"readwrite");return o.onabort=()=>{throw r=o.error,new Error(o.error)},[o,o.objectStore(e)]};this.lastError=()=>r,this.insert=(e,t)=>(Array.isArray(t)||(t=[t]),new Promise(n=>{const[r,o]=i(e,"w");let a=t.length;al(t,e=>{const t=o.put(e);t.onerror=()=>{nl(t.error),a--}}),r.oncomplete=()=>{n(a)}})),this.update=(e,t,r,a)=>new Promise(s=>{this.selectAll(e,[],r).then(r=>{if(!r.length)return void s(0);const[c,u]=i(e,"w"),l=n[e],f=l.keys.PRIMARY.columns.length>1?l.keys.PRIMARY.columns:l.keys.PRIMARY.columns[0];let d=0;for(let e=0;e<r.length;e++){const n=ul({},a?{[f]:r[e][f]}:r[e],t);if(!n[f])throw new Error(Zu("No primary key in the data"));const i=u.put(n);o(i,s),i.onsuccess=()=>{d++}}c.oncomplete=()=>{s(d)}})}),this.delete=(e,t)=>new Promise(r=>{const[a,s]=i(e,"w"),c=n[e],u=c.keys.PRIMARY.columns.length>1?c.keys.PRIMARY.columns:c.keys.PRIMARY.columns[0];if(!t[u])throw new Error(Zu("No "));const l=s.delete(t[u]);o(l,r),a.oncomplete=()=>{r(1)}}),this.selectOne=(e,t,n,r,o,i)=>new Promise(i=>{this.selectAll(e,[t],n,r,o,1).then(e=>{var n,r;i(null!==(r=null===(n=null==e?void 0:e[0])||void 0===n?void 0:n[t])&&void 0!==r?r:void 0)})}),this.select=(e,t,n,r,o)=>new Promise(i=>{this.selectAll(e,t,n,r,o,1).then(e=>{i(e.length?e[0]:null)})}),this.selectAll=(e,t=[],r=null,a=null,s=0,c=null)=>new Promise(a=>{const[u,l]=i(e,"r"),f=n[e],d=f.keys.PRIMARY.columns.length>1?f.keys.PRIMARY.columns:f.keys.PRIMARY.columns[0],h=sl(r)?Object.keys(r)[0]:!r||cl(r)?null:d,m=[];if(h===d)if(bbn.fn.isArray(null==r?void 0:r[d])){const e=Math.min(r[d].length,c||9999999);for(let n=s||0;n<e;n++){let i=l.get(r[d][n]);i.onsuccess=()=>{let n=i.result;m.push(fl(n,t)),m.length===e&&a(m)},o(i,a)}}else{let e=l.get((null==r?void 0:r[d])||r);e.onsuccess=()=>{let n=e.result;m.push(fl(n,t)),a(m)},o(e,a)}else{const e=l.openCursor();let n=0;e.onsuccess=e=>{const o=e.target.result;o?(r&&bbn.fn.search([o.value],r)||(n>=s&&(m.push(fl(o.value,t)),m.length===c&&a(m)),n++),o.continue()):a(m)},o(e,a)}}),this.getColumnValues=(e,n,r,o,i,a)=>new Promise(n=>{t.transaction([e],"read").objectStore(e)}),this.copyTable=(r,o,i=[],a=null,s=null,c=0,u=null)=>new Promise(l=>{if(t.objectStoreNames.contains(r)||hl.add(e,r,n[o]),!t.objectStoreNames.contains(r))throw l(0),new Error(Zu("The target table %s does not exist",r));this.selectAll(o,i,a,s,c,u).then(e=>{e.length?this.insert(r,e).then(e=>{l(e)}):l(0)})}),this.deleteTable=e=>new Promise(n=>{t.deleteObjectStore(e),n(!0)})},hl={_structures:{},_connections:{},_stores:{},ok:void 0!==ll,updateStructure(e,t,n){const r=t.keys.PRIMARY.columns.length>1?t.keys.PRIMARY.columns:t.keys.PRIMARY.columns[0];if(!n.objectStoreNames.contains(e)){const o=n.createObjectStore(e,{keyPath:r});il(t.keys,(e,t)=>{"PRIMARY"!==t&&o.createIndex(t,e.columns.length>1?e.columns:e.columns[0],{unique:!!e.unique})})}},open(e){return new Promise(t=>{if(hl._connections[e])t(new dl(e));else{if(!hl._structures[e])throw new Error(Zu("Impossible to find a structure for the database %s",e));let n=Math.max.apply(this,[1].concat(Object.keys(hl._structures[e]).map(t=>hl._structures[e][t].num||1)));const r=ll.open(e,n);r.onupgradeneeded=()=>{const t=r.result;il(hl._structures[e],(e,n)=>{this.updateStructure(n,e,t)})},r.onsuccess=()=>{hl._connections[e]=r.result;let n=new dl(e);t(n)}}})},add(e,t,n){var r;if(!(null===(r=null==n?void 0:n.keys)||void 0===r?void 0:r.PRIMARY)||!(null==n?void 0:n.fields))throw new Error(Zu("The database structure for %s is not valid (are there keys and field? Is there a primary?",t));hl._structures[e]||(hl._structures[e]={}),hl._structures[e][t]=n,hl._connections[e]&&this.updateStructure(t,n,hl._connections[e])}};function ml(e,t,n){let r=(new Date).getTime(),o={key:e,url:rl(e,0,e.length-33),loader:t,aborter:n,loading:!0,error:!1,abort:!1,errorMessage:!1,success:!1,start:r};bbn.env.loaders.push(o),bbn.env.loadersHistory.unshift(o);let i=bbn.env.loadersHistory.length;for(;i&&bbn.env.loadersHistory.length>bbn.env.maxLoadersHistory;)i--,bbn.env.loading||bbn.env.loadersHistory.splice(i,1);return r}function pl(e,...t){if("object"==typeof e){const n=[];return 1===t.length&&"string"==typeof t[0]?n.push(...t[0].split(".")):n.push(...t),n.reduce((e,t)=>{if(e)return e[e instanceof Array?parseInt(t):t]},e)}}function gl(e){if(!Qu(e)){if(!e.toString)throw nl(e),new Error(bbn._("removeAccent expects a string"));e=e.toString()}return e.normalize("NFD").replace(/[\u0300-\u036f]/g,"")}function bl(...e){if(!e.length)return!1;for(let t of e)if("[object Date]"!=={}.toString.apply(t))return!1;return!0}function wl(e,t,n,r="asc"){let o=pl(e,n),i=pl(t,n),a=(typeof o).toLowerCase(),s=(typeof i).toLowerCase();if("asc"!==r&&Qu(r)&&"desc"===r.toLowerCase()&&(r="desc"),a!==s)o=a,i=s;else switch(a){case"string":o=gl(o).toLowerCase(),i=gl(i).toLowerCase();break;case"boolean":o=o?1:0,i=i?1:0;break;case"object":bl(o)&&(o=o.getTime(),i=bl(i)?i.getTime():0)}return o<i?"desc"===r?1:-1:o>i?"desc"===r?-1:1:0}function yl(e){return e&&"object"==typeof e?Object.keys(e).length:0}function vl(e){return!e||(cl(e)?!e.length:"object"==typeof e&&!yl(e))}function El(...e){if(!e.length)return!1;for(let t of e)if("[object Null]"!=={}.toString.apply(t))return!1;return!0}function Ml(e){let t=0;for(let n=0;n<e.length;n++){t=(t<<5)-t+e.charCodeAt(n),t|=0}return Math.abs(t).toString(16)}function Il(e){let t=0;for(let n=0;n<e.length;n++){t=e.charCodeAt(n)+(t<<6)+(t<<16)-t,t|=0}return Math.abs(t).toString(16)}function Dl(e){return Ml(e).padStart(8,"0")+Il(e).padStart(8,"0")}function Sl(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof HTMLElement))return!1;return!0}function kl(e){let t="",n=e;if(e.id)return"#"+e.id;for(;n&&n!==document.body;){let e=n,r=e.localName,o=0;if(!r)break;if(e===document.body)break;e.id&&(t="#"+e.id+">"+t,o=1);let i=n.parentNode,a=Array.from(i.children).filter(t=>t.tagName===e.tagName);if(!o&&a.length>1){let t=Array.from(i.children).indexOf(e)+1;t>1&&(r+=":nth-child("+t+")")}t=r+(t?">"+t:""),n=i}return t}function Tl(...e){var t;if(!e.length)return!1;if(!("cp"in bbn)||!("isComponent"in bbn.cp)||"function"!=typeof bbn.cp.isComponent)return!1;for(let n of e){if(!bbn.cp.isComponent(n)||Sl(n)||!(null===(t=n.$el)||void 0===t?void 0:t.bbnCid))return!1}return!0}function _l(e,t=null,n=0,r=null,o=null){if(n||r||(r=new WeakSet),void 0===e)e="__BBN_UNDEFINED__";else if(null===e)e="__BBN_NULL__";else if(null===e)e="__BBN_NULL__";else if("function"==typeof e)e="__BBN_FUNCTION__"+e.toString();else if("symbol"==typeof e)e="__BBN_SYMBOL__"+e.toString();else if("string"==typeof e)e="__BBN_STRING__"+e;else if("number"==typeof e)e="__BBN_NUMBER__"+e.toString();else if("boolean"==typeof e)e="__BBN_BOOLEAN__"+e.toString();else if([void 0,Object,Array,null].includes(null==e?void 0:e.constructor)){if(bbn.fn.isArray(e))if(r.has(e)||t&&t<n)e="__BBN_ARRAY__"+e.constructor.toString();else{r.add(e);let i="";for(let a=0;a<e.length;a++)i+="__BBN_ITEM"+a.toString()+"__"+o(e[a],t,n+1,r,o);e="__BBN_ARRAY__"+i}else if("object"==typeof e)if(r.has(e)||t&&t<n)e="__BBN_OBJECT__"+(e.constructor?e.constructor.toString():"");else{r.add(e);let i="";for(let a in e){let s=a;"string"!=typeof s&&(s=o(s,o,1,1)),i+="__BBN_PROP_"+s+"__"+o(e[a],t,n+1,r,o)}e="__BBN_OBJECT__"+i}}else e=Sl(e)?Tl(e)?"__BBN_CP__"+e.$cid:e.bbnId?"__BBN_DOM__"+e.tagName+"/"+e.bbnId+e.bbnHash:"__BBN_DOM__"+kl(e):"__BBN_UNKNOWN_OBJECT__"+e.constructor.toString();return e}function xl(...e){let t="",n=null;2===e.length&&"number"==typeof e[1]&&(n=e[1],e=[e[0]]);for(let r in e)t+=_l(e[r],n,0,null,_l);return Dl(t)}function Ol(e){var t="0123456789abcdef";function n(e){var n,r="";for(n=0;n<=3;n++)r+=t.charAt(e>>8*n+4&15)+t.charAt(e>>8*n&15);return r}function r(e,t){var n=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(n>>16)<<16|65535&n}function o(e,t,n,o,i,a){return r(function(e,t){return e<<t|e>>>32-t}(r(r(t,e),r(o,a)),i),n)}function i(e,t,n,r,i,a,s){return o(t&n|~t&r,e,t,i,a,s)}function a(e,t,n,r,i,a,s){return o(t&r|n&~r,e,t,i,a,s)}function s(e,t,n,r,i,a,s){return o(t^n^r,e,t,i,a,s)}function c(e,t,n,r,i,a,s){return o(n^(t|~r),e,t,i,a,s)}var u,l,f,d,h,m=function(e){var t,n=1+(e.length+8>>6),r=new Array(16*n);for(t=0;t<16*n;t++)r[t]=0;for(t=0;t<e.length;t++)r[t>>2]|=e.charCodeAt(t)<<t%4*8;return r[t>>2]|=128<<t%4*8,r[16*n-2]=8*e.length,r}(e),p=1732584193,g=-271733879,b=-1732584194,w=271733878;for(u=0;u<m.length;u+=16)l=p,f=g,d=b,h=w,p=i(p,g,b,w,m[u+0],7,-680876936),w=i(w,p,g,b,m[u+1],12,-389564586),b=i(b,w,p,g,m[u+2],17,606105819),g=i(g,b,w,p,m[u+3],22,-1044525330),p=i(p,g,b,w,m[u+4],7,-176418897),w=i(w,p,g,b,m[u+5],12,1200080426),b=i(b,w,p,g,m[u+6],17,-1473231341),g=i(g,b,w,p,m[u+7],22,-45705983),p=i(p,g,b,w,m[u+8],7,1770035416),w=i(w,p,g,b,m[u+9],12,-1958414417),b=i(b,w,p,g,m[u+10],17,-42063),g=i(g,b,w,p,m[u+11],22,-1990404162),p=i(p,g,b,w,m[u+12],7,1804603682),w=i(w,p,g,b,m[u+13],12,-40341101),b=i(b,w,p,g,m[u+14],17,-1502002290),p=a(p,g=i(g,b,w,p,m[u+15],22,1236535329),b,w,m[u+1],5,-165796510),w=a(w,p,g,b,m[u+6],9,-1069501632),b=a(b,w,p,g,m[u+11],14,643717713),g=a(g,b,w,p,m[u+0],20,-373897302),p=a(p,g,b,w,m[u+5],5,-701558691),w=a(w,p,g,b,m[u+10],9,38016083),b=a(b,w,p,g,m[u+15],14,-660478335),g=a(g,b,w,p,m[u+4],20,-405537848),p=a(p,g,b,w,m[u+9],5,568446438),w=a(w,p,g,b,m[u+14],9,-1019803690),b=a(b,w,p,g,m[u+3],14,-187363961),g=a(g,b,w,p,m[u+8],20,1163531501),p=a(p,g,b,w,m[u+13],5,-1444681467),w=a(w,p,g,b,m[u+2],9,-51403784),b=a(b,w,p,g,m[u+7],14,1735328473),p=s(p,g=a(g,b,w,p,m[u+12],20,-1926607734),b,w,m[u+5],4,-378558),w=s(w,p,g,b,m[u+8],11,-2022574463),b=s(b,w,p,g,m[u+11],16,1839030562),g=s(g,b,w,p,m[u+14],23,-35309556),p=s(p,g,b,w,m[u+1],4,-1530992060),w=s(w,p,g,b,m[u+4],11,1272893353),b=s(b,w,p,g,m[u+7],16,-155497632),g=s(g,b,w,p,m[u+10],23,-1094730640),p=s(p,g,b,w,m[u+13],4,681279174),w=s(w,p,g,b,m[u+0],11,-358537222),b=s(b,w,p,g,m[u+3],16,-722521979),g=s(g,b,w,p,m[u+6],23,76029189),p=s(p,g,b,w,m[u+9],4,-640364487),w=s(w,p,g,b,m[u+12],11,-421815835),b=s(b,w,p,g,m[u+15],16,530742520),p=c(p,g=s(g,b,w,p,m[u+2],23,-995338651),b,w,m[u+0],6,-198630844),w=c(w,p,g,b,m[u+7],10,1126891415),b=c(b,w,p,g,m[u+14],15,-1416354905),g=c(g,b,w,p,m[u+5],21,-57434055),p=c(p,g,b,w,m[u+12],6,1700485571),w=c(w,p,g,b,m[u+3],10,-1894986606),b=c(b,w,p,g,m[u+10],15,-1051523),g=c(g,b,w,p,m[u+1],21,-2054922799),p=c(p,g,b,w,m[u+8],6,1873313359),w=c(w,p,g,b,m[u+15],10,-30611744),b=c(b,w,p,g,m[u+6],15,-1560198380),g=c(g,b,w,p,m[u+13],21,1309151649),p=c(p,g,b,w,m[u+4],6,-145523070),w=c(w,p,g,b,m[u+11],10,-1120210379),b=c(b,w,p,g,m[u+2],15,718787259),g=c(g,b,w,p,m[u+9],21,-343485551),p=r(p,l),g=r(g,f),b=r(b,d),w=r(w,h);return n(p)+n(g)+n(b)+n(w)}function jl(e){const t="function"==typeof e?e.toString():e;if("string"!=typeof t)throw Error("Unexpected type "+typeof e+" while parsing function");let n,r="",o=!1,i=!1,a=!1,s="",c=0,u=0,l=[],f={},d="",h=['"',"'","`"],m=!1,p=!1,g=!1,b=!1,w=!1,y=!1,v="";for(let e=0;e<t.length;e++)if(g||"/"!==t[e]||"*"!==t[e+1])if("/"===t[e]&&"*"===t[e-1])g=!1;else if(b||"/"!==t[e]||"/"!==t[e+1])if("\n"===t[e])b=!1;else{if(g||b)continue;if(t[e]===d&&!m&&d)d="",r+=t[e];else if(d)m="\\"===t[e]&&!m,r+=t[e];else if(h.includes(t[e])&&!m)d=t[e],r+=t[e];else if("("===t[e]){if(c++,""!==r.trim()){if("function"===r.trim())a=!0;else if("async"!==r.trim()){s=r.trim();let e=s.match(/^([a-zA-Z0-9_]+)<[a-zA-Z0-9_]+>$/);e&&(s=e[1])}r=""}}else if(")"===t[e])c===u+1&&(p?(f.default=r.trim(),p=!1):r&&(f.name=r.trim()),(f.name||f.default)&&(l.push(f),f={}),r=""),u++;else if(w&&"}"!==t[e])r+=t[e];else{if(c&&c===u&&":"===t[e]){const r=t.substring(e+1).trim().match(/^\s*([a-zA-Z0-9_]+)\s*\{/);if(!r)throw Error("Unexpected ':' while parsing function");v=r[1],n=t.substring(e+r[0].length).trim();break}if(!(r||"="!==t[e]||">"!==t[e+1]||c!==u||u||o)){f.name=t.slice(0,e).trim(),l.push(f),f={},o=!0,n=bbn.fn.substr(t,e+2).trim();break}if(c===u&&"="===t[e]&&">"===t[e+1]){""!==r.trim()&&(f.name=r.trim(),l.push(f),f={},r=""),o=!0,e++;continue}if("="===t[e]&&c>u&&!p)f.name=r.trim(),r="",p=!0;else if(","===t[e])if(w)r+=t[e];else{if(!(c>u))throw Error("Unexpected ',' while parsing function");p?(f.default=r.trim(),p=!1):r&&(f.name=r.trim()),(f.name||f.default)&&(l.push(f),f={}),r=""}else if("{"===t[e]||"}"===t[e]){if(c===u){n=t.substring(e).trim();break}c>u?"{"!==t[e]||w?"}"===t[e]&&w&&(w=!1,r+=t[e]):(w=!0,r=t[e]):r=""}else{if(o){n=t.substring(t.indexOf("=>")+2).trim();break}" "===t[e]?""!==r.trim()&&("async"===r.trim()&&(i=!0),c>u?r+=t[e]:r=""):r+=t[e]}}}else b=!0,r="";else g=!0,r="";if(!n){if(!o)throw Error("Unexpected end of function while parsing function");n=r}n.substr(0,25).indexOf("[native code]")>-1&&(y=!0);const E=l.map(e=>e.name+(e.default?" = "+e.default:"")).join(", ");return{body:n,args:l,argString:E,isArrow:o,hasFunction:a,name:s,isAsync:i,isBinary:y,hash:Ol(n+(s?"-"+s:"")+(E?"-"+E:"")),returnType:v}}function Cl(e,t,n){if(n||(n=[]),e===t)return!0;if(e&&t&&"object"==typeof e&&"object"==typeof t){if(![void 0,Object,Array,null].includes(null==e?void 0:e.constructor)||![void 0,Object,Array,null].includes(null==t?void 0:t.constructor))return!1;let r=Object.keys(e).sort(),o=Object.keys(t).sort();if(xl(r)!==xl(o))return!1;let i=!0;if(e&&"object"==typeof e){if(n.includes(e))return i;n.push(e)}return al(r,n=>{if(!Cl(e[n],t[n]))return i=!1,!1}),i}if(e&&t&&"function"==typeof e&&"function"==typeof t){let n=jl(e),r=jl(t),o=n.hash===r.hash;return o&&n.isBinary&&(o=!1),o}return!1}function Rl(e,t,n){switch(n){case"===":case"=":case"equal":case"eq":case"is":return e===t;case"!==":case"notequal":case"neq":case"isnot":return e!==t;case"!=":case"different":return e!=t;case"contains":case"contain":case"icontains":case"icontain":return!vl(e)&&!vl(t)&&-1!==gl(e).toLowerCase().indexOf(gl(t).toLowerCase());case"doesnotcontain":case"donotcontain":return!(!El(e)&&!El(t))||-1===gl(e.toLowerCase()).indexOf(gl(t.toLowerCase()));case"starts":case"start":return!El(e)&&!El(t)&&("string"!=typeof e&&(e=e.toString()||""),"string"!=typeof t&&(t=t.toString()||""),0===e.indexOf(t));case"startswith":case"startsi":case"starti":case"istarts":case"istart":return!El(e)&&!El(t)&&0===gl(e).toLowerCase().indexOf(gl(t).toLowerCase());case"endswith":case"endsi":case"endi":case"iends":case"iend":return!El(e)&&!El(t)&&e.lastIndexOf(t)===e.length-t.length;case"like":return!El(e)&&!El(t)&&gl(e).toLowerCase()===gl(t).toLowerCase();case"gt":case">":return e>t;case"gte":case">=":return e>=t;case"lt":case"<":return e<t;case"lte":case"<=":return e<=t;case"isnull":return null===e;case"isnotnull":return null!==e;case"isempty":return""===e;case"isnotempty":return""!==e;case"==":if(sl(e,t))return Cl(e,t);default:return e==t}}function Nl(e,t){if(!t.conditions||!t.logic||!cl(t.conditions))throw new Error("Error in compareConditions: the filter should an abject with conditions and logic properties and conditions should be an array of objects");let n="AND"===t.logic;return al(t.conditions,r=>{let o;if(r.conditions&&cl(r.conditions))o=Nl(e,r);else if(o=Rl(pl(e,r.field),r.value,r.operator),o){let t=r.field.split("."),n=t.pop();t.length&&al(t,t=>e=e[t]),void 0===pl(e,n)&&void 0!==r.value&&(o=!1)}if(o){if("OR"===t.logic)return n=!0,!1}else if("AND"===t.logic)return n=!1,!1}),n}function Pl(e,t="="){if(!sl(e))throw new Error("Error in filterToCondition: filter must be an object");if(!e.conditions||!cl(e.conditions)){let n=[];il(e,(e,r)=>{sl(e)&&"object"==typeof e.conditions?n.push(Pl(e)):n.push({field:r,operator:t,value:e})}),e={conditions:n}}return e.logic||(e.logic="AND"),e}function Yl(e,t,n=null,r="=",o=0,i=!1){if(!Xu(e))throw new Error(bbn._("The first argument for a search should be iterable")+" "+typeof e+" "+bbn._("given"));if(!e.length)return-1;let a,s,c=!1;if(t)if("string"==typeof t)a={conditions:[{field:t,value:n,operator:r||"="}]};else if(i=!0===r,o="number"==typeof n?n:i?e.length-1:0,"function"==typeof t)c=!0,s=t;else if(sl(t))if("field"in t&&"value"in t)a={conditions:[t],logic:"AND"};else if("conditions"in t)a=t;else{const e=[];for(let n in t)e.push({field:n,value:t[n],operator:"="});a={conditions:e,logic:"AND"}}else cl(t)&&(a={conditions:t,logic:"AND"});else c=!0,s=e=>Nl({value:e},Pl({logic:"AND",conditions:[{field:"value",operator:r||"=",value:n}]}));if(c||a){if("number"!=typeof o&&(o=i?e.length-1:0),!s){const e=Pl(a);s=t=>Nl(t,e)}if(i)for(let t=o;t>=0;t--){if(bbn.env._enumerated.push(!0),s(e[t]))return bbn.env._enumerated.pop(),e[t],t;bbn.env._enumerated.pop()}else for(let t=o;t<e.length;t++){if(bbn.env._enumerated.push(!0),s(e[t]))return bbn.env._enumerated.pop(),e[t],t;bbn.env._enumerated.pop()}}return-1}function Al(e,t,n=null,r="=",o=0,i=!1,a=!1){let s=Yl(e,t,n,r,o,i);return s>-1?e[s]:t&&["object","function"].includes(typeof t)&&5 in arguments?i:a}function Ll(e,t=null,n=!1){let r=Yl(bbn.env.loaders,{key:e});if(r>-1){let o=bbn.env.loaders.splice(r,1)[0],i=Al(bbn.env.loadersHistory,{key:e,start:o.start});return i&&(i.loading=!1,i.duration=(new Date).getTime()-o.start,"string"==typeof t?(i.errorMessage=t,i.error=!n,i.abort=n):sl(t)&&(i.success=!0)),!0}return!1}function Fl(e){let t=Yl(bbn.env.loaders,{key:e});return t>-1?bbn.env.loaders[t]:null}function Hl(e,t,n=null,r="=",o=0){if(!cl(e))try{e=Array.from(e)}catch(t){throw bbn.fn.log("NOT ARRAY",e),new Error("Error in filter: The first argument must be an array")}let i={};const a=[],s="function"==typeof t;if(!t||!e.length)return e;if("object"==typeof t)i=t;else if("string"==typeof t)i[t]=n;else if(!s)throw new Error("Search function error: The prop argument should be a string or an object");let c;c="function"==typeof t?t:(e,t)=>Nl(e,i);for(let t=0;t<e.length&&(bbn.env._enumerated.push(!0),!(c(e[t],t)&&(bbn.env._enumerated.pop(),a.push(e[t]),bbn.env._enumerated.push(!0),o&&a.length>=o)));t++)bbn.env._enumerated.pop();return a}function Bl(e){if(yl(e)){bbn.var.colors||(bbn.var.colors={});let t=document.createElement("style");document.head.appendChild(t);let n=t.sheet,r=0;il(e,(e,t)=>{bbn.var.colors[t]=e,n.insertRule(".bbn-"+t+", .bbn-color-text-"+t+" {color: "+e+" !important;}",r),n.insertRule("svg.bbn-"+t+", .bbn-"+t+" svg, svg.bbn-color-text-"+t+", .bbn-color-text-"+t+" svg {fill: "+e+";}",r),n.insertRule(".bbn-bg-"+t+", .bbn-color-bg-"+t+", .bbn-color-background-"+t+" {background-color: "+e+" !important;}",r),n.insertRule(".bbn-border-"+t+", .bbn-color-border-"+t+" {border-color: "+e+" !important;}",r),n.insertRule(".bbn-color-"+t+" {border-color: "+e+"; background-color: "+e+"; color: "+e+";}",r)})}}function Ul(e,t=null,n=""){if(e&&"FORM"===e.tagName){let r=(t,n)=>{let r=document.createElement("input");r.setAttribute("type","hidden"),r.setAttribute("name",t),r.setAttribute("value",n),e.appendChild(r)};t=JSON.parse(JSON.stringify(t||{})),n=n||"",t&&il(t,(t,o)=>{let i=n?`${n}[${o}]`:o;t instanceof Date?r(i,t.toISOString()):t instanceof Array?t.forEach((t,n)=>{const o=`${i}[${n}]`;"object"==typeof t?Ul(e,t,o):r(o,t.toString())}):"object"!=typeof t||t instanceof File?r(i,t.toString()):Ul(e,t,i)})}}function Zl(e,t){let n=0;al(t,t=>{t.style[e]="auto"}),al(t,(t,r)=>{let o=t.getBoundingClientRect(),i=o[e]%1?o[e]-o[e]%1+1:o[e];i>n&&(n=i)}),al(t,(t,r)=>{n&&(t.style[e]=n+"px")})}function Wl(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}function $l(e,t,n,r=""){return n.toString().replace(sl(e)?e:new RegExp(Wl(e),"g"+r),t)}function ql(e,t,n){let r={};return t&&il(t,(e,t)=>{-1===t.indexOf("_bbn")&&(r[t]=e)}),e+":"+Ol((n||"json")+JSON.stringify(r))}function zl(e,t=null,n=null,r=null,o=null,i=null){if(null===t&&e&&"object"==typeof e&&e.url&&(e.abort&&(i=e.abort),e.failure&&(o=e.failure),e.success&&(r=e.success),e.data&&(n=e.data),e.datatype&&(t=e.datatype),e=e.url),e&&e&&"string"==typeof e){-1===e.indexOf("://")&&(e=$l("//","/",e)),t||(t="json");let a=ql(e,n,t),s=Fl(a);if(null==s?void 0:s.loader)return s.loader;bbn.env.token&&ul(n||{},{_bbn_token:bbn.env.token});const c=new AbortController;let u={responseType:t,signal:c.signal};"text"===t?u.headers={accept:"text/javascript","Content-Type":"text/javascript"}:"json"===t?u.headers={accept:"application/json","Content-Type":"application/json"}:"html"===t&&(u.headers={accept:"text/html","Content-Type":"text/html"});let l="get";sl(n)&&yl(n)>0&&(u.data=n,l="post");let f=Gu.run(l,e,u).then(t=>{if(Ll(a,t),bbn.fn.defaultEndLoadingFunction(e,d,n,t),200===t.status)tl(r)&&r(t.data,t.headers);else{let e=1;tl(o)&&(e=o(f,t.message,t)),e&&bbn.fn.defaultAjaxErrorFunction(f,t.message,t)}return t}).catch(t=>{let r=Gu.isCancel(t);if(Ll(a,t.message||t.response.data,r),bbn.fn.defaultEndLoadingFunction(e,d,n,t),r){let n=1;tl(i)&&(n=i(t.message,e)),n&&bbn.fn.defaultAjaxAbortFunction(t.message,e)}else{let e=1;tl(o)&&(e=o(f,t.message,t)),e&&bbn.fn.defaultAjaxErrorFunction(f,t.message,t.response)}return t.response}),d=ml(a,f,c);return bbn.fn.defaultStartLoadingFunction(e,d,n,a),f}}const Vl=new TextDecoder;function Jl(e){return Vl.decode(e)}function Gl(e,t){if(e&&Qu(e)){let n=e.split("/").pop();if(!t)return n;let r=t.length;if(n&&rl(n,-r)===t)return rl(n,0,n.length-r)}return""}function Kl(...e){if(!e.length)return!1;for(let t of e)if(null!==t&&("object"==typeof t||"function"==typeof t))return!1;return!0}var Xl,Ql,ef,tf,nf,rf,of,af=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},sf=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};const cf=[{name:"mariadb-datetime",re:/^(\d{4})-(\d{2})-(\d{2})[ T](\d{2}):(\d{2}):(\d{2})$/,map:e=>({year:+e[1],month:+e[2],day:+e[3],hour:+e[4],minute:+e[5],second:+e[6]})},{name:"mariadb-datetime-no-sec",re:/^(\d{4})-(\d{2})-(\d{2})[ T](\d{2}):(\d{2})$/,map:e=>({year:+e[1],month:+e[2],day:+e[3],hour:+e[4],minute:+e[5],second:0})},{name:"mariadb-date",re:/^(\d{4})-(\d{2})-(\d{2})$/,map:e=>({year:+e[1],month:+e[2],day:+e[3],hour:0,minute:0,second:0})},{name:"iso-datetime",re:/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2})(?::(\d{2}))?(?:\.\d+)?(?:Z|[+\-]\d{2}:?\d{2})?$/,map:e=>({year:+e[1],month:+e[2],day:+e[3],hour:+e[4],minute:+e[5],second:void 0!==e[6]?+e[6]:0})},{name:"slash-date",re:/^(\d{2})\/(\d{2})\/(\d{4})$/,map:e=>({year:+e[3],month:+e[2],day:+e[1],hour:0,minute:0,second:0})},{name:"slash-datetime",re:/^(\d{2})\/(\d{2})\/(\d{4})[ T](\d{2}):(\d{2}):(\d{2})$/,map:e=>({year:+e[3],month:+e[2],day:+e[1],hour:+e[4],minute:+e[5],second:+e[6]})}],uf=[["y","year",31536e6],["m","month",2592e6],["w","week",6048e5],["d","day",864e5],["h","hour",36e5],["i","minute",6e4],["s","second",1e3]],lf={y:"Year",m:"Month",d:"Date",w:"Week",h:"Hours",i:"Minutes",s:"Seconds"},ff={y:"YYYY",m:"MM",d:"DD",e:"EE",w:"WW",h:"HH",i:"II",s:"SS"},df={years:"y",year:"y",YEARS:"y",YEAR:"y",Years:"y",Year:"y",YYYY:"y",YY:"y",yyyy:"y",yy:"y",months:"m",month:"m",Months:"m",Month:"m",MONTHS:"m",MONTH:"m",MMMM:"m",MMM:"m",MM:"m",weekday:"e",WEEKDAY:"e",ee:"e",EE:"e",ddd:"e",days:"d",day:"d",Days:"d",Day:"d",DAYS:"d",DAY:"d",DD:"d",dd:"d",hours:"h",hour:"h",Hours:"h",Hour:"h",HOURS:"h",HOUR:"h",HH:"h",hr:"h",hh:"h",minutes:"i",minute:"i",Minutes:"i",Minute:"i",MINUTES:"i",MINUTE:"i",II:"i",ii:"i",mn:"i",mm:"i",min:"i",SS:"s",ss:"s",seconds:"s",second:"s",Seconds:"s",Second:"s",SECONDS:"s",SECOND:"s",sec:"s",WW:"w",Y:"y",y:"y",M:"m",m:"m",e:"e",E:"e",D:"d",d:"d",H:"h",h:"h",n:"i",i:"i",s:"s",S:"s",W:"w",w:"w"},hf={};class mf{constructor(e,t,n=!1){Xl.add(this),Ql.set(this,0),ef.set(this,"");const r=df[t]||t;if(!r)throw new Error("Invalid unit for duration: "+t);af(this,ef,r,"f");const o=Al(uf,e=>e[0]===r);if(!o)throw new Error("Invalid unit for duration: "+r);const i=o[2];af(this,Ql,n?e:e*i,"f")}years(e=!1){return sf(this,Xl,"m",nf).call(this,"year",e)}months(e=!1){return sf(this,Xl,"m",nf).call(this,"month",e)}weeks(e=!1){return sf(this,Xl,"m",nf).call(this,"week",e)}days(e=!1){return sf(this,Xl,"m",nf).call(this,"day",e)}hours(e=!1){return sf(this,Xl,"m",nf).call(this,"hour",e)}minutes(e=!1){return sf(this,Xl,"m",nf).call(this,"minute",e)}seconds(e=!1){return sf(this,Xl,"m",nf).call(this,"second",e)}toJSON(){return{years:this.years(!0),months:this.months(!0),days:this.days(!0),hours:this.hours(!0),minutes:this.minutes(!0),seconds:this.seconds(!0),milliseconds:this.toMilliseconds()}}asYears(){const[,,e]=sf(this,Xl,"m",tf).call(this,"year");return sf(this,Ql,"f")/e}asMonths(){const[,,e]=sf(this,Xl,"m",tf).call(this,"month");return sf(this,Ql,"f")/e}asWeeks(){const[,,e]=sf(this,Xl,"m",tf).call(this,"week");return sf(this,Ql,"f")/e}asDays(){const[,,e]=sf(this,Xl,"m",tf).call(this,"day");return sf(this,Ql,"f")/e}asHours(){const[,,e]=sf(this,Xl,"m",tf).call(this,"hour");return sf(this,Ql,"f")/e}asMinutes(){const[,,e]=sf(this,Xl,"m",tf).call(this,"minute");return sf(this,Ql,"f")/e}asSeconds(){const[,,e]=sf(this,Xl,"m",tf).call(this,"second");return sf(this,Ql,"f")/e}add(e,t){const n=t?df[t]||t:sf(this,ef,"f"),r=Al(uf,e=>e[0]===n);if(!r)throw new Error("Invalid unit for duration: "+(null!=t?t:n));return new mf(sf(this,Ql,"f")+e*r[2],sf(this,ef,"f"),!0)}subtract(e,t){return this.add(-e,t)}toMilliseconds(){return sf(this,Ql,"f")}}Ql=new WeakMap,ef=new WeakMap,Xl=new WeakSet,tf=function(e){const t=Al(uf,t=>t[1]===e);if(!t)throw new Error("Unit name not found: "+e);return t},nf=function(e,t){const n=uf.findIndex(([,t])=>t===e);if(-1===n)throw new Error("Unit not found: "+e);const r=uf[n][2];if(!t)return Math.floor(sf(this,Ql,"f")/r);let o=sf(this,Ql,"f");for(let e=0;e<n;e++){const[,,t]=uf[e];o-=Math.floor(o/t)*t}return Math.floor(o/r)};class pf{static parse(e,t,n){var r,o,i,a;"monthsLong"in hf||ul(hf,(()=>{const e=[bbn.env.lang,...navigator.languages],t=new Intl.DateTimeFormat(e,{month:"long"}),n=new Intl.DateTimeFormat(e,{month:"short"}),r=new Intl.DateTimeFormat(e,{weekday:"long"}),o=new Intl.DateTimeFormat(e,{weekday:"short"}),i=[],a=[];for(let e=0;e<12;e++){const r=new Date(2020,e,1);i.push(t.format(r)),a.push(n.format(r))}const s=new Date(2020,1,2),c=[],u=[];for(let e=0;e<7;e++){const t=new Date(s.getTime()+864e5*e);c.push(r.format(t)),u.push(o.format(t))}return{monthsLong:i,monthsShort:a,weekdaysLong:c,weekdaysShort:u}})());const s={monthsLong:null!==(r=null==n?void 0:n.monthsLong)&&void 0!==r?r:hf.monthsLong,monthsShort:null!==(o=null==n?void 0:n.monthsShort)&&void 0!==o?o:hf.monthsShort,weekdaysLong:null!==(i=null==n?void 0:n.weekdaysLong)&&void 0!==i?i:hf.weekdaysLong,weekdaysShort:null!==(a=null==n?void 0:n.weekdaysShort)&&void 0!==a?a:hf.weekdaysShort},c={year:1970,month:1,day:1,hour:0,minute:0,second:0,ms:0},u=e=>e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),l=[{token:"YYYY",regex:"\\d{4}",apply:e=>{c.year=parseInt(e,10)}},{token:"YY",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);c.year=t>=70?1900+t:2e3+t}},{token:"Y",regex:"[+-]?\\d{1,6}",apply:e=>{c.year=parseInt(e,10)}},{token:"MMMM",regex:"[^\\d\\s]+",apply:e=>{const t=s.monthsLong.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid month name: "+e);c.month=t+1}},{token:"MMM",regex:"[^\\d\\s]+",apply:e=>{const t=s.monthsShort.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid short month name: "+e);c.month=t+1}},{token:"MM",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>12)throw new Error("Invalid month: "+t);c.month=t}},{token:"mm",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid minute: "+t);c.month=t}},{token:"M",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>12)throw new Error("Invalid month: "+t);c.month=t}},{token:"m",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>12)throw new Error("Invalid month: "+t);c.month=t}},{token:"DD",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>31)throw new Error("Invalid day of month: "+t);c.day=t}},{token:"D",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>31)throw new Error("Invalid day of month: "+t);c.day=t}},{token:"d",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>31)throw new Error("Invalid day of month: "+t);c.day=t}},{token:"dddd",regex:"[^\\d\\s]+",apply:e=>{const t=s.weekdaysLong.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid weekday name: "+e);c.weekday=t}},{token:"ddd",regex:"[^\\d\\s]+",apply:e=>{const t=s.weekdaysShort.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid short weekday name: "+e);c.weekday=t}},{token:"EE",regex:"\\d{1}",apply:e=>{const t=parseInt(e,10);if(t<0||t>7)throw new Error("Invalid weekday number: "+t);c.weekday=t}},{token:"HH",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>23)throw new Error("Invalid hour: "+t);c.hour=t}},{token:"H",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>23)throw new Error("Invalid hour: "+t);c.hour=t}},{token:"h",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>23)throw new Error("Invalid hour: "+t);c.hour=t}},{token:"II",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid minute: "+t);c.minute=t}},{token:"I",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid minute: "+t);c.minute=t}},{token:"i",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid minute: "+t);c.minute=t}},{token:"SS",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid second: "+t);c.second=t}},{token:"S",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid second: "+t);c.second=t}},{token:"s",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid second: "+t);c.second=t}},{token:"ms",regex:"\\d{1,3}",apply:e=>{const t=parseInt(e,10);if(t<0||t>999)throw new Error("Invalid millisecond: "+t);c.ms=t}},{token:"WWWW",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>53)throw new Error("Invalid week number: "+t);c.week=t}},{token:"WWW",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>53)throw new Error("Invalid week number: "+t);c.week=t}},{token:"WW",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>53)throw new Error("Invalid week number: "+t);c.week=t}},{token:"W",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>53)throw new Error("Invalid week number: "+t);c.week=t}}],f=[...l].sort((e,t)=>t.token.length-e.token.length);let d="";const h=[];let m=0;for(;m<t.length;){let e=null;for(const n of f)if(t.startsWith(n.token,m)){e=n;break}e?(d+=`(${e.regex})`,e.apply?h.push(e.apply):h.push(()=>{}),m+=e.token.length):(d+=u(t[m]),m+=1)}const p=new RegExp("^"+d+"$").exec(e);if(!p)throw new Error(`Date string "${e}" does not match format "${t}"`);for(let e=1;e<p.length;e++){const t=p[e],n=h[e-1];null!=t&&n&&n(t)}const g=new Date(c.year,c.month-1,c.day,c.hour,c.minute,c.second,c.ms);if(g.getFullYear()!==c.year||g.getMonth()!==c.month-1||g.getDate()!==c.day||g.getHours()!==c.hour||g.getMinutes()!==c.minute||g.getSeconds()!==c.second||g.getMilliseconds()!==c.ms)throw new Error("Invalid date produced from components");return void 0!==c.weekday&&g.getDay(),g}static compare(e,t,n=""){var r;const o=e instanceof pf?e:new pf(e),i=t instanceof pf?t:new pf(t),a=df[n]||null;if(!a)return o.mtst<i.mtst?-1:o.mtst>i.mtst?1:0;const s=["y","m","d","h","i","s"];for(const e of s){const t=null===(r=Al(uf,t=>t[0]===e))||void 0===r?void 0:r[1],n=i[t](),s=o[t]();if(n<s)return-1;if(n>s)return 1;if(e===a)break}return 0}constructor(e,t=null){rf.set(this,void 0),of.set(this,!1);let n=typeof e;if(e)if(t)this.matchFormat(e,t)&&af(this,rf,pf.parse(e,t),"f");else if(("number"===n||Ku(e)&&""!==e)&&(e<5e3&&Ku(t)?e=Array.from(arguments):e<1e10&&(e*=1e3),Array.isArray(e)||af(this,rf,new Date(e),"f")),"string"===n){for(const t of cf){const n=e.match(t.re);if(n){const{year:e,month:r,day:o,hour:i,minute:a,second:s}=t.map(n);af(this,rf,new Date(e,r-1,o,i,a,s,0),"f")}}if(!sf(this,rf,"f"))throw new Error("Invalid date string format: "+e)}else bl(e)?af(this,rf,e,"f"):Array.isArray(e)&&af(this,rf,new Date(...e),"f");else af(this,rf,new Date,"f")}parse(e,t){const n=pf.parse(e,t);return new pf(n)}matchFormat(e,t){try{return pf.parse(e,t),!0}catch(e){return!1}}toString(){return sf(this,rf,"f")?this.format():""}year(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setFullYear(e),new pf(t)}return sf(this,rf,"f").getFullYear()}}month(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setMonth(e-1),new pf(t)}return sf(this,rf,"f").getMonth()+1}}day(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setDate(e),new pf(t)}return sf(this,rf,"f").getDate()}}hour(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setHours(e),new pf(t)}return sf(this,rf,"f").getHours()}}minute(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setMinutes(e),new pf(t)}return sf(this,rf,"f").getMinutes()}}second(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setSeconds(e),new pf(t)}return sf(this,rf,"f").getSeconds()}}weekday(e,t=!1){if(sf(this,rf,"f"))return!(0 in arguments)||void 0===e||e instanceof Event?sf(this,rf,"f").getDay():this.setWeekday(e,t)}week(){const e=new Date(Date.UTC(this.year(),this.month()-1,this.day())),t=e.getUTCDay()||7;e.setUTCDate(e.getUTCDate()+(4-t));const n=new Date(Date.UTC(e.getUTCFullYear(),0,1));return Math.ceil(((e.getTime()-n.getTime())/864e5+1)/7)}get tst(){return Math.ceil(sf(this,rf,"f").getTime()/1e3)}get mtst(){return sf(this,rf,"f").getTime()}get YYYY(){return this.year().toString()}get YY(){return rl(this.year().toString(),2,2)}get MMMM(){return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],{month:"long"}).format(sf(this,rf,"f"))}get MMM(){return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],{month:"short"}).format(sf(this,rf,"f"))}get MM(){const e=parseInt(this.month().toString());return e<10?"0"+e.toString():e.toString()}get M(){return this.month().toString()}get EE(){return this.weekday().toString()}get DD(){const e=parseInt(this.day().toString());return e<10?"0"+e.toString():e.toString()}get d(){return this.day().toString()}get dddd(){return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],{weekday:"long"}).format(sf(this,rf,"f"))}get ddd(){return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],{weekday:"short"}).format(sf(this,rf,"f"))}get D(){return this.day().toString()}get HH(){const e=parseInt(this.hour().toString());return e<10?"0"+e.toString():e.toString()}get H(){return this.hour().toString()}get II(){const e=parseInt(this.minute().toString());return e<10?"0"+e.toString():e.toString()}get mm(){const e=parseInt(this.minute().toString());return e<10?"0"+e.toString():e.toString()}get I(){return this.minute().toString()}get SS(){const e=parseInt(this.second().toString());return e<10?"0"+e.toString():e.toString()}get S(){return this.second().toString()}get WW(){const e=parseInt(this.year().toString()),t=new Date(e,0,1),n=(sf(this,rf,"f").getTime()-t.getTime())/864e5;return String(Math.ceil((n+t.getDay()+1)/7)).padStart(2,"0")}get isValid(){return void 0!==sf(this,rf,"f")}dateFromFormat(e,t){return new Date}date(e){return!(0 in arguments)||void 0===e||e instanceof Event?this.format("Y-m-d"):this.parse(e,"Y-m-d")}datetime(e){return!(0 in arguments)||void 0===e||e instanceof Event?this.format("Y-m-d H:i:s"):this.parse(e,"Y-m-d H:i:s")}time(e){return!(0 in arguments)||void 0===e||e instanceof Event?this.format("H:i:s"):this.parse(e,"H:i:s")}fdate(e=!1,t=!1,n=!1){if(!sf(this,rf,"f"))return"";const r=Object.assign(Object.assign({year:"numeric",month:e?"long":"numeric",day:"numeric"},n?{weekday:e?"long":"short"}:{}),t?{hour:e?"2-digit":"numeric",minute:"2-digit"}:{});return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],r).format(sf(this,rf,"f"))}ftime(e=!1){if(!sf(this,rf,"f"))return"";const t={hour:"2-digit",minute:"2-digit"};e&&(t.second="2-digit");return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],t).format(sf(this,rf,"f"))}format(e="YYYY-MM-DD HH:II:SS"){let t="";if(e){const n=new RegExp("([|]|"+Object.keys(df).join("|")+")","g");let r=0;al(e.split(n),e=>{if("["!==e)if("]"!==e)if(r>0)t+=e;else if(e in df)if(e in this&&Kl(this[e]))t+=this[e];else{t+=this[ff[df[e]]]}else t+=e;else r--;else r++})}return t}unix(e=!1){if("number"==typeof e){const t=this.copy();return t.setTime(1e3*e),new pf(t)}return sf(this,rf,"f")?e?sf(this,rf,"f").getTime():Math.floor(sf(this,rf,"f").getTime()/1e3):0}sql(e=!1){return sf(this,rf,"f")?e?this.format("YYYY-MM-DD"):this.format("YYYY-MM-DD HH:II:SS"):""}inLeapYear(){if(this.isValid){const e=sf(this,rf,"f").getFullYear();return e%4==0&&e%100!=0||e%400==0}return!1}daysInMonth(){if(this.isValid)switch(sf(this,rf,"f").getMonth()){case 1:return sf(this,rf,"f").getFullYear()%4==0?29:28;case 0:case 3:case 5:case 8:case 10:return 30;default:return 31}}valueOf(){return this.mtst}compare(e,t=""){return pf.compare(this,e,t)}add(e,t="d"){const n=sf(this,rf,"f")?new Date(sf(this,rf,"f").getTime()):new Date;if(df[t]){const r=df[t],o="y"===r?"FullYear":lf[r],i="get"+o;return n["set"+o](n[i]()+e),new pf(n)}return null}subtract(e,t){return this.add(-e,t)}isBefore(e,t=""){return-1===this.compare(e,t)}isAfter(e,t="day"){return 1===this.compare(e,t)}isSame(e,t="day"){return 0===this.compare(e,t)}isAfterOrSame(e,t=""){return[0,1].includes(this.compare(e,t))}isBeforeOrSame(e,t=""){return[-1,0].includes(this.compare(e,t))}fromNow(e=""){const t=new Date,n=df[e]||this.guessUnit(this.diff(t)),r=this.diff(t,n),o=new Intl.RelativeTimeFormat([bbn.env.lang,...navigator.languages],{numeric:"auto"}),i=Al(uf,e=>e[0]===n);if(!i)throw new Error("Invalid unit for fromDate: "+e);return o.format(r,i[1])}fromDate(e,t=""){const n=df[t]||this.guessUnit(this.diff(e)),r=this.diff(e,n);return r>0?Zu("%d %s before",r,t):r<0?Zu("%d %s after",-r,t):Zu("The same %s",t)}guessUnit(e){const t=Math.abs(e);for(const[e,n,r]of uf)if(t>=r||"second"===n)return e}diff(e,t="",n=!1){const r=e instanceof pf?e.mtst:new Date(e).getTime();let o=this.mtst-r;if(n&&(o=Math.abs(o)),!t)return o;const i=df[t],a=Al(uf,e=>e[0]===i);if(!a)throw new Error("Invalid unit for diff: "+t);const[s,c,u]=a;return Math.round(o/u)}calendar(e){return""}getWeekday(e,t="long",n){if(!t){const t=this.getWeekday(e,"narrow",n),r=this.getWeekday(e,"short",n),o=this.getWeekday(e,"long",n);return{letter:t,abbr:r,full:o,long:o,short:r,narrow:t}}let r;if("letter"===t)r="narrow";else if("abbr"===t)r="short";else if("full"===t)r="long";else{if(!["long","short","narrow"].includes(t))throw new Error("Invalid mode for getWeekDay: "+t+'. Allowed values are "long", "short", "narrow", "letter", "abbr", "full".');r=t}return new Date(2023,0,1+e).toLocaleDateString([n||bbn.env.lang,...navigator.languages],{weekday:r})}getWeekdayIndex(e,t){const n=t||bbn.env.lang,r=e.trim().toLowerCase(),o=[n,...navigator.languages];for(let e=0;e<o.length;e++){if(!o[e])continue;const t=new Intl.DateTimeFormat(o[e],{weekday:"long"});for(let e=0;e<7;e++){const n=new Date(2023,0,1+e);if(t.format(n).toLowerCase()===r)return e}}throw new Error(`Unknown weekday name '${e}' for locale '${n}'`)}setWeekday(e,t=!1,n){let r;if("string"==typeof e&&(e=this.getWeekdayIndex(e,n)),"number"!=typeof e)throw new TypeError("weekday must be a number (0–6) or a string");if(e<0||e>6)throw new RangeError("weekday number must be between 0 and 6");r=e;const o=this.weekday();let i;t?(i=(o-r+7)%7,0===i&&(i=7),i=-i):(i=(r-o+7)%7,0===i&&(i=7));const a=this.copy();return a.setDate(a.getDate()+i),new pf(a)}copy(){return new Date(sf(this,rf,"f").getTime())}clone(){return new pf(sf(this,rf,"f")?new Date(sf(this,rf,"f").getTime()):void 0)}startOf(e="d"){const t=df[e];if(!t)throw new Error("Invalid unit for startOf: "+e);let n;switch(t){case"y":n=new Date(this.year(),0,1,0,0,0,0);break;case"m":n=new Date(this.year(),this.month()-1,1,0,0,0,0);break;case"w":{const e=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),this.second(),0),t=(e.getDay()+6)%7;n=new Date(e.getFullYear(),e.getMonth(),e.getDate()-t,0,0,0,0);break}case"d":n=new Date(this.year(),this.month()-1,this.day(),0,0,0,0);break;case"h":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),0,0,0);break;case"i":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),0,0);break;case"s":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),this.second(),0);break;default:throw new Error("Invalid unit for startOf: "+e)}return new pf(n)}endOf(e="d"){const t=df[e];if(!t)throw new Error("Invalid unit for endOf: "+e);let n;switch(t){case"y":n=new Date(this.year(),11,31,23,59,59,999);break;case"m":n=new Date(this.year(),this.month(),0,23,59,59,999);break;case"w":{const e=this.startOf("w"),t=new Date(e.year(),e.month()-1,e.day(),23,59,59,999);t.setDate(t.getDate()+6),n=t;break}case"day":n=new Date(this.year(),this.month()-1,this.day(),23,59,59,999);break;case"hour":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),59,59,999);break;case"minute":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),59,999);break;case"second":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),this.second(),999);break;default:n=new Date(this.mtst)}return new pf(n)}duration(e,t="s"){return new mf(e,t)}}function gf(e,t=null){return e instanceof pf?e:new pf(e,t)}function bf(e){if(arguments.length>1){const e=[];for(let t=1;t<arguments.length;t++)e.push(arguments[t]);e.unshift({_bbn_console_mode:"error",_bbn_console_level:1,_bbn_console_style:"color: #E64141; background: #F7E195; font-size: 14px"}),nl.apply(this,e)}throw new Error(e)}function wf(e,t=null,n=null,r=null,o=null){let i=!1;if(t){i=!0;let a,s="object"===(typeof t).toLowerCase();if(s&&t.prescript)try{new Function(t.prescript)()}catch(e){bf(e.message||"")}if(s&&void 0===t.url&&(t.url=e),i=n&&tl(n)?n(t,o):bbn.fn.defaultLinkFunction(t,o),o&&s&&void 0!==t.content&&("value"in o?o.value=t.content:o.innerHTML=t.content),i&&s&&t.script&&(i="function"==typeof t.script?t.script(t.data?t.data:{},o||null):((e,n)=>{let r=null;try{r=new Function(t.script)(),tl(r)&&(r=r(e,n))}catch(e){nl(e,t),bf(tl(e.getMessage)?e.getMessage():null)}return r})(t.data?t.data:{},o||!1)),i&&r&&tl(r)?r(t):s&&bbn.fn.defaultPostLinkFunction&&bbn.fn.defaultPostLinkFunction(t,o),i&&s&&t.postscript){new Function(t.postscript)(t.postscript)}s&&t.error&&(a=t.errorTitle||bbn.lng.server_response,bbn.fn.defaultErrorFunction(t.error,a))}else bbn.fn.defaultErrorFunction(bbn.lng.errorText,bbn.lng.error);return i}function yf(e,t,n=!1){let r={error:!1,result:!0};if("string"==typeof t&&(t=[t]),cl(t)||(r.error=bbn._("checkProps must receive a string or an array as props argument")),sl(e)||(r.error=bbn._("checkProps must receive an object as obj argument")),!r.error){let o;al(t,t=>{let i=(t=t.trim().split(":"))[1]||!1;if(t=t[0],void 0===e[t]?r.error=t+" "+bbn._("is not defined"):i?(o="is"+rl(i,0,1).toUpperCase()+rl(i,1).toLowerCase(),void 0===bbn.fn[o]?r.error=i+" "+bbn._("is not a valid type"):bbn.fn[o](e[t])||(r.error=t+" "+bbn._("is not a")+" "+i)):n&&!e[t]&&(r.error=t+" "+bbn._("is empty")),r.error)return!1})}return r.error&&(r.result=!1),r}function vf(e){return e.replace(/[A-z]{1}/,e=>e.toUpperCase())}function Ef(e,t,n,...r){let o=!1;cl(t)||(t=[t]);const i=[];if(al(t,t=>{var n;if(t===String?t="string":t===Number?t="number":t===Array?t="array":t===Boolean?t="boolean":t===Object?t="object":t===Function&&(t="function"),tl(t)){if(i.push(t.name||(null===(n=t.constructor)||void 0===n?void 0:n.name)||t.toString()),e instanceof t)return o=!0,!1}else if(Qu(t)&&tl(bbn.fn["is"+vf(t)])){if(bbn.fn["is"+vf(t)](e))return o=!0,!1;i.push(t)}else bf(`The type ${t} is not recognized`)}),!o)throw nl(["Value given",e,"type",typeof e,"expected",i.join(" or ")]),r.length&&nl(r),new Error((n?n+" - ":"")+bbn._("The value should be a %s",i.join(" "+bbn._("or a")+" ")))}function Mf(e){if(cl(e))return e.slice().map(e=>"object"==typeof e?Mf(e):e);if(sl(e)){return ul(!0,Object.create(Object.getPrototypeOf(e)),e)}return e}rf=new WeakMap,of=new WeakMap;const If=(e,t="text/plain")=>{const n=new DataTransfer;n.setData(t,e);const r=new ClipboardEvent("copy",{bubbles:!0,cancelable:!0,clipboardData:n});document.dispatchEvent(r)};function Df(e,t,n=null,r="="){if(!cl(e))throw bbn.fn.log("NOT ARRAY",e),new Error("Error in filter: The first argument must be an array");let o={};const i=[],a="function"==typeof t;if(!t||!e.length)return e;if("object"==typeof t)r=n,o=t;else if("string"==typeof t)o[t]=n;else if(!a)throw new Error("Search function error: The prop argument should be a string or an object");if("function"==typeof t)for(let n=0;n<e.length;n++)t(e[n],n)&&i.push(e[n]);else if(o=Pl(o,r),o.conditions&&o.logic)for(let t=0;t<e.length;t++)Nl(e[t],o)&&i.push(e[t]);return i}const Sf=[];for(let e=0;e<256;e++){let t=e;for(let e=0;e<8;e++)t=1&t?3988292384^t>>>1:t>>>1;Sf.push(t)}function kf(...e){const t=Object.create(null);return e.length&&ul(t,...e),t}function Tf(e){let t=typeof e;if(void 0===e)return new Date;if("number"===t||Ku(e)&&""!==e)return e<1e10&&(e*=1e3),new Date(e);if("string"===t){if(10===e.length)return new Date(parseInt(rl(e,0,4)),parseInt(rl(e,5,2))-1,parseInt(rl(e,8,2)),12);if(19===e.length)return new Date(parseInt(rl(e,0,4)),parseInt(rl(e,5,2))-1,parseInt(rl(e,8,2)),parseInt(rl(e,11,2)),parseInt(rl(e,14,2)),parseInt(rl(e,17,2)))}else if(bl(e))return e;return!1}function _f(e,t=""){nl(e)}function xf(e,t=null,n=null){nl(t,n)}function Of(e,t,n=null,r=null){return!0}function jf(...e){if(!e.length)return!1;for(let t of e)if("object"==typeof t&&!El(t))return!1;return!0}let Cf=[];function Rf(e){if(Qu(e)&&e){for(;"/"===rl(e,e.length-1);)e=rl(e,0,e.length-1);let t=e.lastIndexOf("/");if(t>0)return rl(e,0,t);if(0===t)return"/"}return""}function Nf(...e){if(!e.length)return!1;for(let t of e)if("[object Blob]"!=={}.toString.apply(t))return!1;return!0}function Pf(e){if(e&&Qu(e)){let t=e.split(".");if(t[0]&&t.length>1)return t[t.length-1].toLowerCase()}return""}function Yf(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof HTMLCanvasElement))return!1;return!0}function Af(e,t,n=null){if(Yf(t))return void t.toBlob(t=>{let n=document.createElement("a");n.download=e,n.href=window.URL.createObjectURL(t),n.className="bbn-no",n.click(),window.URL.revokeObjectURL(n.href)},n||"image/png");n?-1===n.indexOf("/")&&(n="text/"+n):n=sl(t)&&t.type?t.type:"octet/stream";let r=window.document.createElement("a");r.className="bbn-no";let o=null;if(Qu(t))o=new Blob([t],{type:n});else try{o=t}catch(e){nl(e)}r.href=window.URL.createObjectURL(o),r.download=e,document.body.appendChild(r),r.click(),window.URL.revokeObjectURL(r.href),document.body.removeChild(r)}var Lf=function(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function s(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}c((r=r.apply(e,t||[])).next())})};function Ff(){return Lf(this,void 0,void 0,function*(){var e;(null===(e=window.scheduler)||void 0===e?void 0:e.yield)?yield window.scheduler.yield():yield new Promise(requestAnimationFrame)})}var Hf=function(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function s(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}c((r=r.apply(e,t||[])).next())})};function Bf(e){let t;return"checkbox"===e.type?e.checked?(t=e.value,t||(t=1)):t=0:"radio"===e.type?e.checked&&(t=e.value):t=e.value,t}function Uf(e){let t,n,r=e.querySelectorAll("input[name],select[name],textarea[name],button[name]"),o={};return al(r,(e,r)=>{if(n=Bf(e),void 0!==n&&!e.disabled){let r=e.name;if(-1===r.indexOf("[]")&&r.indexOf("[")>-1&&r.indexOf("]")>-1&&r.lastIndexOf("]")===r.length-1&&(r=$l("][",".",r),r=$l("[",".",r),r=$l("]","",r)),r.length>2&&r.indexOf("[]")===r.length-2)t=rl(r,0,r.length-2),void 0===o[t]&&(o[t]=[]),o[t].push(n);else if(r.indexOf(".")>-1){let e,t=r.split(".");e=o;for(let r=0;r<t.length;r++)void 0===o[t[r]]&&(r<t.length-1?e[t[r]]={}:e[t[r]]=n),e=e[t[r]]}else o[r]=n}}),o}function Zf(e){return e.filter((e,t,n)=>t===n.indexOf(e))}function Wf(e,t=null){let n=[];if("string"==typeof e&&(e=document.querySelector(e)),e instanceof HTMLElement&&e.parentElement)if("string"==typeof t)for(;e=e.parentElement.closest(t);)n.push(e);else for(!0===t&&n.push(e);e=e.parentElement;)n.push(e);return n}function $f(e){0!==e.indexOf("--")&&(e="--"+e);let t=getComputedStyle(document.documentElement).getPropertyValue(e);return"string"==typeof t&&(t=t.trim()),t}function qf(){const e=navigator.userAgent.toLowerCase();return/iPhone|Android/i.test(navigator.userAgent)?"mobile":/(ipad|tablet|(android(?!.*mobile))|(windows(?!.*phone)(.*touch))|kindle|playbook|silk|(puffin(?!.*(IP|AP|WP))))/.test(e)?"tablet":"desktop"}function zf(){let e,t=window.getSelection();if(t.rangeCount>0){e=t.getRangeAt(0),nl("RANGE",e);let n=e.cloneContents();nl("clonedSelection",n);let r=document.createElement("div");return r.appendChild(n),r.innerHTML}return""}function Vf(e){return Qu(e)?e.replace(/<!--[\s\S]*?-->/g,""):e}function Jf(e){let t=document.createElement("div");return t.innerHTML=e,e=t.innerText}function Gf(e){let t=document.createElement("canvas");return t.width=e.width,t.height=e.height,t.getContext("2d").drawImage(e,0,0),t}function Kf(e){let t,n,r={};if(sl(e[0])&&1===e.length)return e[0];for(n=0;n<e.length;n++)t=typeof e[n],t=t.toLowerCase(),tl(e[n])?(r.errorFn&&!r.abortFn&&(r.abortFn=e[n]),r.successFn&&!r.errorFn?r.errorFn=e[n]:r.successFn||(r.successFn=e[n])):1===e[n]||!0===e[n]?r.force=!0:"string"===t?r.url?r.datatype=e[n]:0===e[n].indexOf("#")||0===e[n].indexOf(bbn.env.root+"#")?r.url=rl(e[n],bbn.env.root.length):(r.url=e[n],0===r.url.indexOf(bbn.env.root)&&(r.url=rl(r.url,bbn.env.root.length))):e[n]&&"object"===t&&(e[n]instanceof Event?r.e=e[n]:r.ele||1!==e[n].nodeType?"object"===t.toLowerCase()&&(r.obj=e[n]):r.ele=e[n]);return!r.url&&yl(r)&&(r.url=bbn.env.path),void 0===r.obj&&(r.obj={_bbn:"public"}),r.datatype||(r.datatype="json"),r}function Xf(e,t,n=null,r=!1){bbn.env.old_path=bbn.env.path,bbn.env.url=["https:/","http://"].includes(rl(e,0,7))?e:bbn.env.root+e,bbn.env.path=rl(bbn.env.url,bbn.env.root.length),bbn.env.params=bbn.env.path.split("/").filter(e=>""!==e);let o=window.history;if(o){let e=o.state,i={url:bbn.env.path,old_path:bbn.env.old_path||null,data:n||{},reload:!1};e&&e.url===bbn.env.path&&(e.data&&ul(i.data,e.data),e.title&&!t&&(t=e.title),r=!0),t=t?Jf(t):bbn.env.siteTitle,r?(i.reload=!0,o.replaceState(i,t,bbn.env.url)):o.pushState(i,t,bbn.env.url)}}function Qf(...e){let t=Kf(e),n=1;if(!0===t)return!0;if(!t)return Qf(window.location.href);if(0===t.url.indexOf("javascript:"))return!0;if(0===t.url.indexOf("data:"))return!0;if(0===t.url.indexOf("#"))return location.href=bbn.env.url+t.url,!0;if(0===t.url.indexOf("mailto:"))return bbn.env.ignoreUnload=!0,window.location.href=t.url,setTimeout(()=>{bbn.env.ignoreUnload=!1},0),!1;if(Fl(t.url))return!1;if((0===t.url.indexOf("http://")||0===t.url.indexOf("https://"))&&0!==t.url.indexOf(bbn.env.host))return t.e&&t.e.preventDefault(),window.open(t.url),!1;if(t.url!==bbn.env.params.join("/")||1===t.force){if(t.successFn)n=t.successFn(t.url);else if(bbn.fn.defaultPreLinkFunction){let e=bbn.fn.defaultPreLinkFunction(t.url,t.force,t.ele);void 0!==e.data?(ul(t.obj,e.data),n=1):n=e}if(n){1!==n&&"string"==typeof n&&(t.url=n);let e=bbn._("The Ajax call to")+" "+t.url+" ";return zl(t.url,t.datatype,t.obj,n=>{n||nl(e+bbn._("returned no answer")),sl(n)&&(0===Object.keys(n).length&&nl(e+bbn._("returned an empty object")),n.new_url?(n.old_path=t.url,t.url=n.new_url):n.url&&t.url!==n.url&&(n.old_path=t.url)),wf(t.url,n,t.successFn,null,t.ele)&&void 0===n.noNav&&0!==bbn.env.path.indexOf(t.url)&&Xf(t.url,(n.title?n.title+" - ":"")+bbn.env.siteTitle)},t.errorFn||null)}}return!0}function ed(...e){let t=Kf(e);if(t.url)return zl(t.url,t.datatype,t.obj,e=>{wf(t.url,e,t.successFn,t.errorFn,t.ele)},t.errorFn,t.abortFn)}function td(e,t,n){let r,o=e.getAttribute("action")||bbn.env.path;if(""===o&&(o="."),"string"==typeof o&&(0!==o.indexOf("http")||-1!==o.indexOf(window.document.location.hostname))&&!e.getAttribute("target")&&(t&&t.preventDefault(),r=Uf(e),r)){e.setAttribute("action",null);const t=[o,r];!n&&e.getAttribute("data-script")&&(n=(n=new Function(e.getAttribute("data-script")))()),n&&t.push(n),ed(...t)}}function nd(){let e=bbn.env.width!==window.innerWidth,t=bbn.env.height!==window.innerHeight;if(e||t){e&&(bbn.env.width=window.innerWidth||window.document.documentElement.clientWidth||window.document.body.clientWidth,document.documentElement.style.setProperty("--vw",.01*bbn.env.width+"px")),t&&(bbn.env.height=window.innerHeight||window.document.documentElement.clientHeight||window.document.body.clientHeight,document.documentElement.style.setProperty("--vh",.01*bbn.env.height+"px"));let n=parseInt($f("mobile-limit"))||650,r="bbn-screen-"+(bbn.env.width<n?"small":"regular"),o=(document.body.className||"").split(" "),i=!1;al(o,(e,t)=>{if(3===e.split("-").length&&0===e.indexOf("bbn-screen-"))return i=!0,e!==r&&o.splice(t,1,r),!1}),i||o.push(r),bbn.fn.defaultResizeFunction(),document.body.className=o.join(" ")}}function rd(){return"mobile"===qf()}function od(){return"tablet"===qf()}function id(){return rd()||od()}function ad(e=!1){let t=(new Date).getTime();return e?Math.round(t/1e3):t}function sd(e){if("string"==typeof e&&e.length>0&&(0===e.indexOf("calc")||Ku(rl(e,0,1)))){let t=document.createElement("div");t.style.width=e;let n=!!t.style.width.length;return t.remove(),n}return!1}function cd(...e){if(!e.length)return!1;for(let t of e)if(!Qu(t)||!bbn.var.regexp.ip.test(t))return!1;return!0}function ud(...e){if(!e.length)return!1;for(let t of e)if("[object Symbol]"!=={}.toString.apply(t))return!1;return!0}function ld(e){const t=["BBN: "+e];t.unshift({_bbn_console_mode:"warn",_bbn_console_level:2,_bbn_console_style:"color: #E64141; background: #F7E195; font-size: 14px"}),nl.apply(this,t)}function fd(e,t="",n=null){let r=new FormData,o=(e,t="")=>{(!n||cl(n)&&!n.includes(t))&&(e instanceof File?r.append(t,e):cl(e)?al(e,(e,n)=>{o(e,t+"["+n+"]")}):sl(e)&&Object.keys(e).length?il(e,(n,r)=>{r in e&&o(n,t?t+"["+r+"]":r)}):El(e)||void 0===e||r.append(t,e))};return o(e,t),r}function dd(e){return"string"==typeof e?document.querySelector(e):e}function hd(e,t,n,r){if("object"==typeof e&&"string"==typeof t){let o=e;const i=t.split(".");al(i,(e,t)=>{if(!o){if(!r)throw new Error(bbn._("The object is invalid"));o={}}i.length-1===t?o[e]=n:o=o[e]})}}function md(e,t){return Math.floor(Math.random()*(t-e+1)+e)}function pd(e,t=" "){if(" "===t)return e.trim();if(!t)return e;if(t===e)return"";for(;0===e.indexOf(t);)e=rl(e,t.length);for(;e.lastIndexOf(t)===e.length-t.length;)e=rl(e,0,e.length-t.length);return e}function gd(e,t,n){return"string"==typeof e.toLowerCase()&&(t||(t=bbn.var.shortenLen),void 0!==n&&Qu(n)||(n="..."),e.length>t&&(e=rl(e,0,t)+n)),e}var bd,wd={_addLoader:ml,_compareValues:wl,_deleteLoader:Ll,abort:function(e){let t=Fl(e);(null==t?void 0:t.aborter)&&t.aborter.abort("Operation canceled by the user.")},abortURL:function(e){al(Hl(bbn.env.loaders,{url:e}),t=>{if(!t||!t.source)throw new Error("Impossible to find the loader with URL "+e);t.source.cancel("Operation canceled by the user.")})},addColors:Bl,addInputs:Ul,addStyle:function(e,t){sl(t)&&il(t,(t,n)=>{e.style[n]=t})},adjustHeight:function(){let e=arguments;return 1===e.length&&Xu(e[0])&&(e=e[0]),Zl("height",e)},adjustSize:Zl,adjustWidth:function(){let e=arguments;return 1===e.length&&Xu(e[0])&&(e=e[0]),Zl("width",e)},ajax:zl,analyzeFunction:jl,animateCss:function(e,t,n){e.classList.add("animated"),e.classList.add(t),e.addEventListener("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend",function e(r){r.target.removeEventListener(r.type,e),"function"==typeof n&&n.call(this),r.target.classList.remove(t)})},arrayBuffer2String:Jl,arrayFromProp:function(e,t){let n=[];return al(e,(e,r)=>{n.push(pl(e,t))}),n},autoExtend:function(e,t){bbn[e]||(bbn[e]={}),ul(bbn[e],t)},baseName:Gl,br2nl:function(e){return $l("<br />","\n",$l("<br/>","\n",$l("<br>","\n",e)))},calendar:function(e,t=!1){let n=gf(e);return n.isValid?n.fdate():t&&Qu(t)?t:""},callback:wf,camelize:function(e){return e.replace(/^([A-Z])|[\s-](\w)/g,function(e,t,n,r){return n?n.toUpperCase():t.toLowerCase()})},camelToCss:function(e){return e.replace(/([A-Z])/g,function(e){return"-"+e.toLowerCase()}).replace("/^./",function(e){return e.toLowerCase()})},canvasToImage:function(e){let t=new Image;return t.src=e.toDataURL("image/png"),t},cast:function(e){var t;return e?"object"==typeof e?bbn.fn.isArray(e)?"Array ("+e.length+")":(null===(t=e.constructor)||void 0===t?void 0:t.name)||"{}":e.toString?e.toString():"string"==typeof e?e:"":""},center:function(e){let t=e.parentNode,n=t.clientWidth,r=t.clientHeight;for(;t&&(!n||!r);)t=e.parentNode,n=t.clientWidth,r=t.clientHeight;return e.style.position="absolute",e.style.top=Math.max(0,(r-e.offsetHeight)/2+t.scrollTop)+"px",e.style.left=Math.max(0,(r-e.offsetWidth)/2+t.scrollLeft)+"px",e},checkProps:function(e,t,n=!1){return yf(e,t,n).result},checkPropsDetails:yf,checkPropsOrDie:function(e,t,n=!1){let r=yf(e,t,n);if(r.error)throw new Error(r.error);return!0},checkType:Ef,circularReplacer:function(){const e=new WeakSet;return(t,n)=>{if("object"==typeof n&&null!==n){if(e.has(n))return;e.add(n),[void 0,Object,Array,null].includes(n.constructor)||(n=Sl(n)?n.bbnId?"__BBN_DOM__"+n.tagName+"/"+n.bbnId+n.bbnHash:"__BBN_DOM__"+n.tagName+"/"+n.className:Tl(n)?"__BBN_CP__"+n.$options.name+"/"+n.$cid:n.constructor.toString())}return n}},clone:Mf,colorToHex:function(e){let t=document.createElement("canvas").getContext("2d");return t.fillStyle=e,t.fillStyle},compare:Rl,compareConditions:Nl,copy:function(e,t){return new Promise(n=>{if(e){if(navigator&&navigator.clipboard)return void(e instanceof Blob?(navigator.clipboard.write([new ClipboardItem({[e.type.toString()]:e})]).then(()=>{n(!0)}),t||If(e,e.type.toString())):sl(e)&&tl(e.toBlob)?e.toBlob(r=>{const o=new ClipboardItem({[r.type.toString()]:r});navigator.clipboard.write([o]).then(()=>{t||If(e,r.type.toString()),n(!0)})}):(navigator.clipboard.writeText(e),t||If(e),n(!0)));let r=document.createElement("textarea");r.style.opacity="0",r.value=e,document.body.appendChild(r),r.select(),document.execCommand("copy"),document.body.removeChild(r),t||If(e),n(!0)}n(!1)})},correctCase:vf,count:function(e,t,n=null,r="="){return Df(e,t,n,r).length||0},crc32:function(e){let t=~0;for(let n=0;n<e.length;n++){const r=e.charCodeAt(n);t=t>>>8^Sf[255&(t^r)]}return(-1^t)>>>0},createObject:kf,cssExists:function(e){let t,n,r=document.styleSheets;for(let o=0;o<r.length;o++){t=1;try{n=r[o].rules||r[o].cssRules}catch(e){if(t=!1,"SecurityError"!==e.name)throw e}if(t)for(let t=0;t<n.length;t++)if(new RegExp("(^|\\s)"+Wl(e)+"(\\{|\\s)","g").test(n[t].selectorText))return!0}return!1},data2Html:function e(t,n=""){const r=!cl(t);let o='<ul class="bbn-bottom-xspadding '+(n||"bbn-ul")+'">';for(let i in t)o+="<li>",r&&(o+="<em>"+i+"</em>: "),t[i]&&(cl(t[i])||sl(t[i]))?o+=e(t[i],n):o+=null===t[i]?"<em>null</em>":t[i].toString?t[i].toString():t[i],o+="</li>";return o+='</ul><div class="bbn-bottom-xspadding '+(n||"bbn-div")+'"></div>',o},date:Tf,dateSQL:function(e,t){let n=gf(e);if(n)return n.format("YYYY-MM-DD"+(t?"":" HH:mm:ss"))},deepPath:function e(t,n,r,o=[]){let i;return(i=Yl(t,n,0))>-1?(o.push(i),o):(al(t,(t,i)=>{if(cl(t[r])){let a=o.slice();a.push(i);let s=e(t[r],n,r,a);if(!1!==s)return s}}),!1)},defaultAjaxAbortFunction:_f,defaultAjaxErrorFunction:xf,defaultAlertFunction:function(e,t=null){alert(e)},defaultConfirmFunction:function(e,t,n=null){let r=0;confirm(e)&&tl(t)&&(t(),r=1),!r&&tl(n)&&n()},defaultEndLoadingFunction:Of,defaultErrorFunction:function(e){nl(e)},defaultHistoryFunction:function(e){return!0},defaultLinkFunction:function(e,t){return!0},defaultPostLinkFunction:function(e,t=null){return!0},defaultPreLinkFunction:function(e,t=!1,n=null){return nl("defaultPreLinkFunction",e,t,n),!0},defaultResizeFunction:function(){return!0},defaultStartLoadingFunction:function(e,t,n,r){return!0},deleteProp:function(e,t){Ef(e,"object",bbn._("The obj must be an object in setProp")),Ef(t,"string",bbn._("The prop must be a string in setProp")),delete e[t]},diffObj:function e(t,n,r=!1,o=!1){o||(Cf=[]);let i="unchanged";void 0===o&&(o=!1);let a=kf();if(!tl(t)&&!tl(n)){if(jf(t)||jf(n)){let e=(s=t)===(c=n)||bl(s)&&bl(c)&&s.getTime()===c.getTime()?i:void 0===s?"created":void 0===c?"deleted":"updated";if(r||e!==i){let r=kf();return Object.defineProperty(r,"type",{value:e,enumerable:!1}),Object.defineProperty(r,"data",{value:void 0===t?n:t,enumerable:!1}),Object.defineProperty(r,"_bbnDiffObjProof",{value:!0,enumerable:!1}),void 0!==t&&Object.defineProperty(r,"newData",{value:n,enumerable:!1}),r}return!1}if(Sl(t)||Sl(n))return!1;if(Cf.includes(t)||Cf.includes(n))return!1;Cf.push(t,n);for(let o in t){if(tl(t[o]))continue;let i;void 0!==n[o]&&(i=n[o]);let s=e(t[o],i,r,!0);s&&(a[o]=s)}for(let o in n){if(tl(n[o])||void 0!==t[o])continue;let i=e(void 0,n[o],r,!0);i&&(a[o]=i)}}var s,c;return!(o&&!r&&!yl(a))&&a},dirName:Rf,download:function(e,t="",n=null){return t&&"object"==typeof t&&(n=t,t=""),zl(e,"blob",n||{_bbn_download:1},(n,r)=>{if(!t){let n="content-disposition",o="attachment; filename=";t=(null==r?void 0:r[n])&&0===r[n].indexOf(o)?rl(r[n],o.length+1,r[n].length-o.length-2):Gl(e)}if(Nf(n)){let e=Pf(t),r=["php","html"];if("string"==typeof t&&("type"in n&&"text/html"!==n.type||r.includes(e)))return void Af(t,n)}},e=>{bbn.fn.defaultAjaxErrorFunction(e)})},downloadContent:Af,each:al,eraseCookie:function(e){document.cookie=e+"=; Max-Age=-99999999;"},error:bf,escapeDquotes:function(e){return Qu(e)?e.replace(/"/g,'\\"'):e},escapeRegExp:Wl,escapeSquotes:function(e){return Qu(e)?e.replace(/'/g,"\\'"):e},escapeTicks:function(e){return Qu(e)?e.replace(/`/g,"\\`"):e},escapeUrl:function(e,t){let n="";e.match("^(http|https)://")&&(n+="http","s"===(e=e.substring(4)).substr(0,1)&&(n+="s",e=e.substring(1)),n+="://",e=e.substring(3)),al(Rf(e).split("/"),e=>{n+=encodeURIComponent(e)+"/"});let r=Gl(e),o="?",i="";if(r.indexOf(o)){let e=r.split("?");o="&",i="?"+e[1],r=e[0]}return t&&Qu(t)?(t.match("^(\\&|\\?)")&&(t=t.substring(1)),t=o+t):t="",n+encodeURIComponent(r)+i+t},executeSlowly:function(e,t){return Hf(this,void 0,void 0,function*(){for(let n=0;n<e.length;n++){yield Ff();let r=t(e[n],n);if(r instanceof Promise&&(r=yield r),!1===r)return!1}return!0})},extend:ul,extendOut:function e(...t){let n=null;for(let r of t){if(!sl(r))throw new Error("Each argument for extendOut must be an object, "+typeof r+" given");if(null===n)n=r;else for(let t in r)sl(n[t],r[t])?e(n[t],r[t]):void 0===n[t]&&(n[t]=r[t])}return n},fdate:function(e,t=!1){let n=gf(e),r=!1;return!0===t&&(r=!0),n.isValid?n.fdate(!1,r):t&&Qu(t)?t:""},fdatetime:function(e,t=!1){let n=gf(e);return n.isValid?n.fdate(!1,!0):t&&Qu(t)?t:""},fieldValue:Bf,fileExt:Pf,filter:Df,filterToConditions:Pl,findAll:function e(t,n,r,o=[]){let i,a=0;for(;(i=Yl(t,n,a))>-1;)o.push(t[i]),a=i+1;return al(t,t=>{cl(t[r])&&e(t[r],n,r,o)}),o},firstVarElement:function(e){const t=e.indexOf("["),n=e.indexOf(".");return-1===t&&-1===n?e:-1===t?e.substring(0,n):-1===n?e.substring(0,t):e.substring(0,Math.min(t,n))},fori:function(e,t,n=e.length-1,r=0){if(cl(e)){let o=e.length-1;Ku(n)&&0<n&&n<=o||(n=o),(!Ku(r)||!(0<=r&&r<o)||r>n)&&(r=0);for(let o=r;o<=n;o++)if(!1===t(e[o],o))return}},forir:function(e,t,n=e.length-1,r=0){if(cl(e)){let o=e.length-1;Ku(n)&&0<n&&n<=o||(n=o),(!Ku(r)||!(0<=r&&r<o)||r>n)&&(r=0);for(let o=n;o>=r;o--)if(!1===t(e[o],o))return}},format:function(e){let t=Array.prototype.slice.call(arguments,1);if(t.length){let n=0;return e.replace(/\%([d|s])/g,(e,r)=>{let o=t[n++];return Ef(o,"d"===r?"number":"string",bbn._("The value doesn't correspond to the format")),o})}return e},formatBytes:function(e,t=2){if(!e)return"0 B";const n=Math.floor(Math.log(e)/Math.log(1024));return parseFloat((e/Math.pow(1024,n)).toFixed(t<0?0:t))+" "+["B","KB","MB","GB","TB","PB","EB","ZB","YB"][n]},formatDate:function(e,t){const n=gf(e);return n.isValid?n.format(t):""},formatSize:function(e,t){return Ku(e)?e+"px":Qu(e)?e:!t&&"auto"},formdata:Uf,fphone:function(e){var t;if(Ku(e)&&(e=e.toString()),Qu(e)){const n=(null===(t=bbn.var)||void 0===t?void 0:t.phoneCodes)||[];let r="",o="",i="";if(n.length&&al(n,t=>{e.startsWith(t.prefix)&&t.prefix.length>o.length&&(o=t.prefix,i=t.mask||"")}),!i.length&&e.startsWith("+")){o.length||(o=e.substr(0,3));const t=e.slice(o.length);for(let e=0;e<t.length;e++)e+1<=t.length&&e%2==0&&(i+="0"+(t[e+1]?"0":"")+" ");i=i.trim()}if(i.length){o.length&&(r=o+" ",e=e.slice(o.length));let t=0;return r+=i.replace(/[0-9]/g,()=>e[t++]||""),r}}return e},fromXml:function(e,t){let n=null;if(window.DOMParser)n=(new DOMParser).parseFromString(e,"text/xml");else{if(!window.ActiveXObject)throw new Error("cannot parse xml string!");if(n=new window.ActiveXObject("Microsoft.XMLDOM"),n.async=!1,!n.loadXML(e))throw n.parseError.reason+" "+n.parseError.srcText}function r(e,n){if("#text"==e.nodeName){let t=e.nodeValue;return void(t.trim()&&(n["#text"]=t))}let o={},i=n[e.nodeName];if(i?Array.isArray(i)?n[e.nodeName].push(o):n[e.nodeName]=[i,o]:t&&-1!=t.indexOf(e.nodeName)?n[e.nodeName]=[o]:n[e.nodeName]=o,e.attributes)for(let t of e.attributes)o[t.nodeName]=t.nodeValue;for(let t of e.childNodes)r(t,o)}let o={};for(let e of n.childNodes)r(e,o);return o},ftime:function(e,t){let n=gf(e);return n.isValid?n.ftime():t&&Qu(t)?t:""},getAllTags:function(){return Zf(Array.prototype.map.apply(document.all,[e=>e.tagName.toLowerCase()]))},getAncestors:Wf,getAttributes:function(e){e.getAttributeNames||bf("The element is not a proper HTML Element");let t=Object.create(null);return e.getAttributeNames().forEach(n=>{t[n]=e.getAttribute(n)}),t},getBrowserName:function(){const e=navigator.userAgent.toLowerCase();switch(!0){case e.includes("edge"):case e.includes("edg/"):return"Edge";case e.includes("opr")&&!!window.opr:return"Opera";case e.includes("chrome")&&!!window.chrome:return"Chrome";case e.includes("trident"):return"Internet Explorer";case e.includes("firefox"):return"Firefox";case e.includes("safari"):return"Safari";default:return"Other"}},getBrowserVersion:function(){const e=navigator.userAgent.toLowerCase();switch(!0){case e.includes("edge/"):return e.split("edge/")[1].split(" ")[0];case e.includes("edg/"):return e.split("edg/")[1].split(" ")[0];case e.includes("opr/")&&!!window.opr:return e.split("opr/")[1].split(" ")[0];case e.includes("chrome/")&&!!window.chrome:return e.split("chrome/")[1].split(" ")[0];case e.includes("trident/"):return e.split("trident/")[1].split(" ")[0];case e.includes("firefox/"):return e.split("firefox/")[1].split(" ")[0];case e.includes("safari/"):return e.split("version/")[1].split(" ")[0];default:return""}},getChrono:function(e="default"){return bbn.fn.microtimestamp()-this.constructor.chronos[e]},getCookie:function(e){let t=e+"=",n=document.cookie.split(";");for(let e=0;e<n.length;e++){let r=n[e];for(;" "==r.charAt(0);)r=r.substring(1,r.length);if(0==r.indexOf(t)){let e=r.substring(t.length,r.length);if(e)return JSON.parse(unescape(e)).value}}return null},getCssVar:$f,getDay:function(e){let t=Tf(e);if(t){let e=t.getTime(),r=t.getYear(),o=365*(r-1970);t.getMonth()<2&&r--;for(var n=1972;n<=r;n+=4)o++;return o+Math.floor(e/864e5)}return!1},getDeviceType:qf,getEventData:function(e){let t=e.dataTransfer||e.clipboardData,n=t.getData("Text"),r={raw:n,files:[],str:[]};return new Promise((o,i)=>{let a=!(t instanceof DataTransfer);if(!n&&"copy"===e.type){let e=window.getSelection();r.raw=e.toString();let t=zf();r.str.push({type:"text/plain",data:r.raw}),t!==r.raw?r.str.push({type:"text/html",data:t}):0===r.raw.trim().indexOf("<")&&r.str.push({type:"text/html",data:"<meta charset='utf-8'><code style=\"white-space: pre; font-family: 'Courier New', sans-serif\">\n"+r.raw+"\n</code>"}),a=!0,o(r)}if(!a){let e=[],n=t.items.length;al(t.items,(i,s)=>{let c=i.kind,u=i.type;if("file"===c){let c=t.files[s];if(!u&&c.name){let e=c.name.split(".");u=e[e.length-1]}let l=c?c.name:bbn._("untitled"),f=c?c.size:null,d=c?c.lastModified:null,h=i.getAsFile();h?(a=!0,n--,r.files.push({type:u,data:h,name:l,size:f,mdate:d}),e.push(l),n||(r.raw||(r.raw=e.join(", ")),o(r))):bbn.fn.defaultErrorFunction(bbn._("Impossible to read the file")+" "+l)}else a=!0,i.getAsString(t=>{n--,r.str.push({type:u,data:t}),"text/plain"===u&&e.push(name),n||(r.raw||(r.raw=e.join(", ")),o(r))})})}a||setTimeout(()=>{o(r)})})},getField:function(e,t,n="",r=null,o="=",i=0,a=!1,s=void 0){let c;return n&&["object","function"].includes(typeof n)&&6 in arguments&&(s=a),t?(c=Al(e,n,r,o,i,a,void 0),void 0===c?s:c[t]):s},getFieldValues:function(e,t,n,r,o){Ef(t,"string"),n&&(e=Hl(e,n,r,o));let i=[];return al(e,e=>-1===i.indexOf(e[t])?i.push(e[t]):null),i},getIndex:function(e,t=""){return e.parentElement?(t||Array.from(e.parentElement.children).indexOf(e),Array.from(e.parentElement.children).filter(e=>e.matches(t)).indexOf(e)):-1},getHtml:function(e,t=!1){let n=e.innerHTML();return t&&(n=Vf(n)),n.trim()},getHTMLOfSelection:zf,getLoader:Fl,getPath:kl,getProp:function(e,t){return Ef(e,"object",bbn._("The obj must be an object in setProp")),Ef(t,"string",bbn._("The prop must be a string in setProp")),e[t]},getProperty:pl,getRequestId:ql,getRow:Al,getScrollBarSize:function(){if(void 0===bbn.env.scrollBarSize){let e=document.createElement("div");e.style.visibility="hidden",e.style.width="100px","msOverflowStyle"in e.style&&(e.style.msOverflowStyle="scrollbar"),document.body.appendChild(e);let t=e.offsetWidth;e.style.overflow="scroll";let n=document.createElement("div");n.style.width="100%",e.appendChild(n);let r=n.offsetWidth;e.parentNode.removeChild(e);let o=t-r;bbn.env.scrollBarSize=o?o+1:0}return bbn.env.scrollBarSize},getSortingMoves:function(e,t){if(e.length!==t.length)throw new Error("Lengths must match.");const n=new Set(t);if(n.size!==t.length)throw new Error("dst has duplicates.");const r=new Set(e);if(r.size!==e.length)throw new Error("src has duplicates.");if(e.length!==n.size||Array.from(r).some(e=>!n.has(e)))throw new Error("Arrays must contain the same unique values.");const o=new Map(t.map((e,t)=>[e,t])),i=e.map(e=>o.get(e)),a=(e=>{const t=e.length,n=[],r=Array(t).fill(-1);for(let o=0;o<t;o++){let t=e[o],i=0,a=n.length;for(;i<a;){const r=i+a>>1;e[n[r]]<t?i=r+1:a=r}i>0&&(r[o]=n[i-1]),n[i]=o}const o=[];for(let e=n.length?n[n.length-1]:-1;-1!==e;e=r[e])o.push(e);return o.reverse()})(i),s=new Set(a.map(t=>e[t])),c=Array(t.length).fill(-1);for(let e=t.length-2;e>=0;e--)c[e]=c[e+1],s.has(t[e+1])&&(c[e]=e+1);const u=e.slice(),l=new Map(u.map((e,t)=>[e,t])),f=[];for(let e=0;e<t.length;e++){const n=t[e];if(s.has(n))continue;const r=l.get(n);if(void 0===r)throw new Error("Inconsistent state");const o=c[e],i=-1!==o?l.get(t[o]):u.length;if(void 0===i)throw new Error("Inconsistent state");const a=r<i?i-1:i;if(r!==a){const[e]=u.splice(r,1);u.splice(a,0,e),f.push({from:r,to:a,value:n}),l.clear();for(let e=0;e<u.length;e++)l.set(u[e],e)}}return f},getText:function(e){return e.innerText().trim()},getTimeoff:function(){return bbn.env.isFocused?0:Math.round((new Date).getTime()/1e3-bbn.env.timeoff)},happy:function(...e){return e.unshift({_bbn_console_level:3,_bbn_console_style:"color: white; background: green; font-size: 18px;"}),nl.apply(this,e),this},hash:xl,hex2rgb:function(e){"#"!==e.charAt(0)&&(e="#"+e),4===e.length&&(e="#"+e[1]+e[1]+e[2]+e[2]+e[3]+e[3]);const t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?{r:parseInt(t[1],16),g:parseInt(t[2],16),b:parseInt(t[3],16)}:null},history:function(){return window.history||!1},html2text:Jf,imageToCanvas:Gf,imgToBase64:function(e,t="image/png"){return Gf(e).toDataURL(t)},info:function(...e){return e.unshift({_bbn_console_level:4,_bbn_console_style:"color: #EEE; background: blue; font-size: 12px;"}),nl.apply(this,e),this},init:function(e,t){let n;bbn.env.isInit||(bbn.env.root=document.baseURI.length>0?document.baseURI:bbn.env.host,bbn.env.root.length&&"/"!==rl(bbn.env.root,-1)&&(bbn.env.root+="/"),"object"==typeof e&&ul(!0,bbn,e),bbn.env.path=rl(bbn.env.url,bbn.env.root.length),n=bbn.env.path.split("/"),al(n,(e,t)=>{""!==(e=decodeURI(e.trim()))&&bbn.env.params.push(e)}),bbn.var.colors&&Bl(bbn.var.colors),document.addEventListener("visibilitychange",()=>{document.hidden&&bbn.env.isFocused?bbn.env.isFocused=!1:document.hidden||bbn.env.isFocused||(bbn.env.isFocused=!0)}),document.addEventListener("focusin",e=>{e.target instanceof HTMLElement&&!e.target.classList.contains("bbn-no")&&(bbn.env.focused=e.target),bbn.env.last_focus=ad()}),document.addEventListener("click",e=>{if(bbn.env.last_focus=ad(),"ajax"!==bbn.env.nav)return;let t=e.target;if(t instanceof HTMLElement&&"A"!==t.tagName){let e=t;for(;e&&"A"!==e.tagName&&"BODY"!==e.tagName;)e=e.parentElement;t=e&&"A"===e.tagName?e:null}return t instanceof HTMLElement&&t.hasAttribute("href")&&!t.hasAttribute("target")&&!t.classList.contains("bbn-no")?(e.preventDefault(),e.stopPropagation(),Qf(t.getAttribute("href")),!1):void 0}),al(document.querySelectorAll("form:not(.bbn-no), form:not(.bbn-form)"),e=>{e.addEventListener("submit",t=>{td(e,t)})}),window.addEventListener("hashchange",()=>{bbn.env.hashChanged=(new Date).getTime()},!1),window.addEventListener("resize",()=>{nd()}),window.addEventListener("orientationchange",()=>{nd()}),nd(),id()&&(document.body.classList.add("bbn-mobile"),od()&&document.body.classList.add("bbn-tablet")),window.history&&(window.onpopstate=function(e){let t=window.history;if(!bbn.env.historyDisabled&&t&&bbn.fn.defaultHistoryFunction(t.state)){let e=t.state;e?Qf(e.url,ul({title:e.title||bbn.env.siteTitle},e.data||{})):e&&e.data&&tl(e.data.script)&&e.data.script()}}),window.addEventListener("online",()=>{bbn.env.online=!0}),window.addEventListener("offline",()=>{bbn.env.online=!1}),bbn.env.isInit=!0,document.dispatchEvent(new Event("bbninit")),bbn.env.logging&&nl("Logging in bbn is enabled"))},isActiveInterface:function(e=600){return!!bbn.env.last_focus&&(new Date).getTime()-bbn.env.last_focus<1e3*e},isArray:cl,isBlob:Nf,isBoolean:function(...e){if(!e.length)return!1;for(let t of e)if(![!0,!1].includes(t))return!1;return!0},isCanvas:Yf,isColor:function(...e){if(!e.length)return!1;var t=new RegExp("^(#[a-f0-9]{6}|#[a-f0-9]{3}|rgb *( *[0-9]{1,3}%? *, *[0-9]{1,3}%? *, *[0-9]{1,3}%? *)|rgba *( *[0-9]{1,3}%? *, *[0-9]{1,3}%? *, *[0-9]{1,3}%? *, *[0-9]{1,3}%? *)|black|green|silver|gray|olive|white|yellow|maroon|navy|red|blue|purple|teal|fuchsia|aqua)$","i");for(let n of e){if(!Qu(n))return!1;if(!t.test(n))return!1}return!0},isComment:function(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof Comment))return!1;return!0},isCp:Tl,isDataURL:function(...e){if(!e.length)return!1;for(let t of e)if(!/^data:([a-z]+\/[a-z0-9\-\+\.]+(;[a-z\-]+\=[a-z0-9\-\.]+)?)?(;base64)?,/i.test(t))return!1;return!0},isDate:bl,isDesktopDevice:function(){return"desktop"===qf()},isDimension:function(...e){if(!e.length)return!1;for(let t of e){if("number"!=typeof t||t<0)return!1;if(!sd(t))return!1}return!0},isDom:Sl,isEmail:function(...e){if(!e.length)return!1;let t=/^([a-zA-Z0-9_.+-])+\@(([a-zA-Z0-9-])+\.)+([a-zA-Z0-9]{2,4})+$/;for(let n of e){if(!Qu(n))return!1;if(!t.test(n))return!1}return!0},isEmpty:vl,isEvent:function(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof Event))return!1;return!0},isFocused:function(e,t=!1){return e===document.activeElement||t&&e.contains&&e.contains(document.activeElement)},isFunction:tl,isHex:function(e){return Boolean(e.match(/^(0x)?[0-9a-f]+$/i))},isHostname:function(...e){if(!e.length)return!1;for(let t of e){if(!Qu(t))return!1;if(!cd(t)&&!bbn.var.regexp.hostname.test(t))return!1}return!0},isInside:function(e,t){let n=Wf(e);if(n.length){if(Qu(t)){let e=!1;return al(n,n=>{if(n.matches&&n.matches(t))return e=!0,!1}),e}if(t instanceof HTMLElement)return n.indexOf(t)>-1}return!1},isInt:el,isInViewport:function(e,t=!1){const n=e.getBoundingClientRect();if(t)return n.top>=0&&n.left>=0&&n.right<=(window.innerWidth||document.documentElement.clientWidth)&&n.bottom<=(window.innerHeight||document.documentElement.clientHeight);const r=e.offsetHeight,o=e.offsetWidth;return n.top>=-r&&n.left>=-o&&n.right<=(window.innerWidth||document.documentElement.clientWidth)+o&&n.bottom<=(window.innerHeight||document.documentElement.clientHeight)+r},isIP:cd,isIterable:Xu,isMobile:id,isMobileDevice:rd,isNotObject:jf,isNull:El,isNumber:Ku,isObject:sl,isPercent:function(...e){if(!e.length)return!1;for(let t of e)if("string"!=typeof t||!t.match(/^\d+(?:\.\d+)?%$/))return!1;return!0},isPrimitive:Kl,isPromise:function(...e){if(!e.length)return!1;for(let t of e)if("[object Promise]"!=={}.toString.apply(t))return!1;return!0},isPropSize:function(e){let t=!1;return al(["width","height","gap","margin","padding","top","left","right","bottom"],n=>{if(-1!==e.indexOf(n))return t=!0,!1}),t},isSame:Cl,isSQLDate:function(...e){if(!e.length)return!1;for(let t of e)if("string"!=typeof t||!t.match(/^([1-2]\d{3})-((0\d)|(1[12]))-(([0-2]\d)|(3[01]))(?:( [0-2]\d):([0-5]\d):([0-5]\d))?$/))return!1;return!0},isString:Qu,isSymbol:ud,isTabletDevice:od,isURL:function(...e){if(!e.length)return!1;for(let t of e)if(!bbn.var.regexp.url.test(t))return!1;return!0},isUid:function(...e){if(!e.length)return!1;for(let t of e)if("string"!=typeof t||!t.match(/^[0-9a-f]{32}$/i))return!1;return!0},isValidDimension:sd,isValidName:function(...e){if(!e.length)return!1;for(let t of e)if(!Qu(t)||!/^[$A-Z_][0-9A-Z_$]*$/i.test(t))return!1;return!0},isVue:function(...e){if(!e.length)return!1;if("vue"in bbn&&window.Vue)if("app"in bbn.vue){for(let t of e)if(!t||"function"!=typeof t.render)return!1}else for(let t of e)if(!(t instanceof window.Vue))return!1;return!("cp"in bbn)||!("isComponent"in bbn.cp)||"function"!=typeof bbn.cp.isComponent||bbn.cp.isComponent(...e)},isWritable:function(e,t){let n;for(;e&&(n=Object.getOwnPropertyDescriptor(e,t),!n);)e=Object.getPrototypeOf(e);return!n||Boolean(n.writable||n.set)},iterate:il,lightenDarkenHex:function(e,t){if(e&&t){let n="#"===e[0];e=n?e.slice(1):e;let r=parseInt(e,16),o=(r>>16)+t,i=(r>>8&255)+t,a=(255&r)+t;return o>255?o=255:o<0&&(o=0),i>255?i=255:i<0&&(i=0),a>255?a=255:a<0&&(a=0),(n?"#":"")+(a|i<<8|o<<16).toString(16)}},link:Qf,log:nl,makeReactive:function e(t,n,r,o){const i=(null==r?void 0:r.$cid)||"",a="__bbn_"+(i?i+"_":"");if(t&&"object"==typeof t&&[void 0,Object,Array].includes(t.constructor)){if(t.__bbnIsProxy&&t.__bbnParent===r)return t;r&&r.$options&&"bbn-loadbar"===r.$options.name&&nl(["MAKING bbn-loadbar",t]),t.__bbnWatchers||Reflect.defineProperty(t,"__bbnWatchers",{value:kf(),writable:!0,configurable:!0,enumerable:!1});return new Proxy(t,{get(s,c){const u=Reflect.get(s,c),l=s.__bbnRoot||s;if(ud(c))return Reflect.get(l,c);const f=o?o+"."+c:c,d=a+(Ku(c)?c.toString():c);if(["fill","pop","push","reverse","shift","sort","splice","unshift"].includes(c)&&cl(s))return function(...e){let t=l[c](...e);return ld("DOING ARRAY STUFF"),nl(s.__bbnParent),n(s,"length",r),t};if(tl(u))return u;if("__bbnRoot"===c){let e=t;for(;e&&(null==e?void 0:e.__bbnTarget);)e=e.__bbnTarget;return e}return"__bbnIsProxy"===c||("__bbnTarget"===c?s:"__bbnParent"===c?r:"__bbnWatchers"===c?s.__bbnWatchers:0===c.indexOf("__bbn_")?Reflect.get(s,c):"length"===c&&cl(s.__bbnRoot||s)?l.length:c in s&&u&&"object"==typeof u&&[void 0,Object,Array].includes(u.constructor)?(u.__bbnIsProxy&&u.__bbnParent===r||(d in l||Reflect.defineProperty(l,d,{value:e(u,n,r,f),writable:!0,configurable:!0,enumerable:!1}),l[d].__bbnIsProxy&&!l.__bbnWatchers[i]&&(l.__bbnWatchers[i]=f)),l[d]):u)},set(t,s,c){if(ud(s))return Reflect.get(t,s,c);const u=t.__bbnRoot||t,l=o?o+"."+s:s;if(ud(s))return Reflect.get(t,s);if(r&&r.$options&&"bbn-loadbar"===r.$options.name&&nl(["Setting proxy prop in "+r.$options.name,t,s,c]),!Cl(u[s],c)){if(0===s.indexOf("__bbn_"))Reflect.defineProperty(u,s,{value:e(c,n,r,l),writable:!0,configurable:!0,enumerable:!1});else if(c&&"object"==typeof c&&[void 0,Object,Array].includes(c.constructor)){const t=a+(Ku(s)?s.toString():s);Reflect.defineProperty(u,t,{value:e(c,n,r,l),writable:!0,configurable:!0,enumerable:!1}),u[t].__bbnIsProxy&&!u.__bbnWatchers[i]&&(u.__bbnWatchers[i]=l)}r&&r.$options&&"bbn-loadbar"===r.$options.name&&nl(["Setting proxy prop in "+r.$options.name+" "+(Ku(s)?s.toString():s),c,t]),Reflect.set(u,s,c),n(t,s,r)}return!0},defineProperty(t,i,s){const c=t,u=o?o+"."+i:i;if("__bbnWatchers"===i||ud(i)||0===i.indexOf("__bbn_"))Reflect.defineProperty(c,i,s);else{const t=a+(Ku(i)?i.toString():i);Reflect.defineProperty(c,t,{value:e(s.value,n,r,u),writable:!0,configurable:!0,enumerable:!1})}return n(t,i,r),!0},deleteProperty(e,t){const n=e;if(0===t.indexOf("__bbn_"))Reflect.deleteProperty(n,t);else{const r=a+(Ku(t)?t.toString():t);Reflect.deleteProperty(n,r),Reflect.deleteProperty(e,t)}return!0}})}return t},map:function e(t,n,r,o=0){return t.map((t,i)=>(t=n(t,i,o),r&&t[r]&&cl(t[r])&&(t[r]=e(t[r],n,r,o+1)),t))},md5:Ol,microtimestamp:function(){return window.performance.now()+performance.timeOrigin},money:function(e,t,n,r,o,i,a){if(o||(o=void 0===o&&bbn.env.money&&void 0!==bbn.env.money.decimal?bbn.env.money.decimal:"."),n||(n=void 0===n&&bbn.env.money&&void 0!==bbn.env.money.currency?bbn.env.money.currency:""),i||(i=void 0===i&&bbn.env.money&&void 0!==bbn.env.money.thousands?bbn.env.money.thousands:" "),a||(a=void 0===a&&bbn.env.money&&void 0!==bbn.env.money.precision?bbn.env.money.precision:0),t||(t=!(void 0!==t||!bbn.env.money||void 0===bbn.env.money.kilo)&&bbn.env.money.kilo),r||(r=!(void 0!==r||!bbn.env.money||void 0===bbn.env.money.novalue)&&bbn.env.money.novalue),Ku(a)||(a=t?3:0),0===e&&"number"==typeof a&&a>0){let r=e.toFixed(a).replace(".",o);return n&&(r+=" "+(t?"K"+n:n)),r}if((isNaN(e)||!e)&&r)return r;if(isNaN(e)||!e)return 0+(n?" "+n:"");if("string"==typeof e&&(e=Number(e)),"number"!=typeof e)throw new Error("The value must be a number");t&&e&&(e/=1e3,n&&(n="K"+n));let s=e.toFixed(a),c=0,u=1e4;return s&&(u=s.indexOf("."),u<=0?u=1e4:c=s.length-u),s.replace(/./g,function(e,t,n){return"."===e?o:t&&(n.length-t-c)%3==0&&t<u?i+e:e})+(n?" "+n:"")},move:function(e,t,n){if(n>=e.length){let t=n-e.length;for(;1+t--;)e.push(void 0)}return e.splice(n,0,e.splice(t,1)[0]),e},multiorder:function(e,t){if(!t)return e;let n;if(Array.isArray(t)||"object"!=typeof t)n=t;else for(var r in n=[],t)n.push({field:r,dir:t[r]});if(!Array.isArray(n))throw new Error("The orders argument must be an array");return e.slice().sort((e,t)=>{let r;for(let o of n)if(r=wl(e,t,o.field,o.dir),0!==r)return r;return 0})},mutateArray:function(e,t,n=null){if(!cl(e,t))throw new TypeError("mutateArray can only be called with arrays");n?Ef(n,"function","The hash function must be a function"):n=xl;const r=new Map(t.map(e=>[n(e),e]));let o=[];t.forEach(e=>{o.push(e)});let i=e.length;for(;i--;)r.has(n(e[i]))||e.splice(i,1);for(let t=0;t<o.length;t++)if(t>=e.length||!Cl(e[t],o[t])){const n=Yl(e,o[t]);if(-1!==n){const[r]=e.splice(n,1);e.splice(t,0,r)}else e.splice(t,0,o[t])}return e.length>o.length&&e.splice(o.length,e.length-o.length),e},mutateObject:function(e,t,n){if(!sl(e,t))throw new TypeError("mutateObject can only be called with arrays");n?Ef(n,"function","The hash function must be a function"):n=xl;const r=Object.keys(t);for(let t in e)r.includes(t)||delete e[t];return r.forEach(n=>{Cl(e[n],t[n])||(e[n]=t[n])}),e},nl2br:function(e,t){return $l("\n","<br>"+(t?"\n":""),e)},numProperties:yl,objectToFormData:fd,order:function(e,t,n="asc"){return e?e.sort(function(e,r){return wl(e,r,t,n)}):e},outerHeight:function(e){if((e=dd(e))&&"offsetHeight"in e){let t=window.getComputedStyle(e),n=parseFloat(t.marginTop)+parseFloat(t.marginBottom);return Math.ceil(e.offsetHeight+n)}},outerWidth:function(e){e=dd(e);let t=window.getComputedStyle(e),n=parseFloat(t.marginLeft)+parseFloat(t.marginRight);return Math.ceil(e.offsetWidth+n)},percent:function(e,t){return t/100*e},pickValue:function(e){if(Array.isArray(e)&&e.length)return e[Math.floor(Math.random()*e.length)]},post:ed,postOut:function(e,t,n=null,r=""){let o=document.body.querySelector("form#bbn-form_out");o||(o=document.createElement("form"),o.classList.add("bbn-no"),o.setAttribute("id","bbn-form_out"),o.setAttribute("method","post"),o.setAttribute("enctype","multipart/form-data-encoded"),hd(o,"style.display","none"),document.body.appendChild(o)),o instanceof HTMLFormElement&&(o.innerHTML="",o.setAttribute("action",e),o.setAttribute("target",r||"_blank"),t||(t={}),(t=kf(t)).bbn||(t.bbn="public"),Ul(o,t),o.submit(),n&&n())},printf:function(e){var t=Array.prototype.slice.call(arguments,1);return e.replace(/{(\d+)}/g,function(e,n){return void 0!==t[n]?t[n]:e})},quotes2html:function(e,t){return t&&0!==t.toLowerCase().indexOf("s")||(e=$l("'","&#39;",e)),t&&0!==t.toLowerCase().indexOf("d")||(e=$l('"',"&quot;",e)),e},randomInt:md,randomString:function(e,t,n){let r,o,i={n:"0123456789",l:"abcdefghijklmnopqrstuvwxyz",u:"ABCDEFGHIJKLMNOPQRSTUVWXYZ"};n||(n="nlu"),e||(r=md(8,14)),"string"==typeof t?(n="n",delete i.l,delete i.u,i.n=t,r||(r=e)):"number"==typeof t&&e<t?r=md(e,t):e&&(r=e);let a="";for(let e=0;e<r;e++)0===e?"n"!==n&&(o=-1===n.indexOf("u")?"l":"u"):o=n[Math.floor(Math.random()*n.length)],a+=i[o][Math.floor(Math.random()*i[o].length)];return a},range:function(e,t,n){return Array.from({length:(t-e)/n+1},(t,r)=>e+r*n)},removeAccents:gl,removeEmpty:function(e){var t=[];if(cl(e))for(let n=0;n<e.length;n++){let r=!1;e[n]&&(cl(e[n])?e[n].length&&(r=!0):sl(e[n])?yl(e[n])&&(r=!0):r=!0),r&&t.push(e[n])}return t},removeExtraSpaces:function(e){return e.replace(/\s+/g," ").trim()},removeHtmlComments:Vf,removePrivateProp:ol,removeTrailingChars:function(e,t){if(t||(t=" "),t.length){for(;rl(e,-t.length)===t;)e=rl(e,0,e.length-t.length);for(;rl(e,0,t.length)===t;)e=rl(e,t.length)}return e},repeat:function(e,t){return e.repeat(t)},replaceAll:$l,replaceSelection:function(e,t){let n,r,o;if(n=window.getSelection(),n.getRangeAt&&n.rangeCount){if(r=window.getSelection().getRangeAt(0),r.deleteContents(),r.createContextualFragment)o=r.createContextualFragment(e);else{const t=document.createElement("div");let n;for(t.innerHTML=e,o=document.createDocumentFragment();n=t.firstChild;)o.appendChild(n)}const i=o.firstChild,a=o.lastChild;r.insertNode(o),n.removeAllRanges(),t?(i&&(r.setStartBefore(i),r.setEndAfter(a)),n.addRange(r)):(r.setStartAfter(a),n.addRange(r))}},resize:nd,rgb2hex:function(e){return(e=e.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?/i))&&4===e.length?"#"+("0"+parseInt(e[1],10).toString(16)).slice(-2)+("0"+parseInt(e[2],10).toString(16)).slice(-2)+("0"+parseInt(e[3],10).toString(16)).slice(-2):""},riterate:function(e,t,n=!1){return il(e,t,n,!0)},roundDecimal:function(e,t){return Number(Math.round(parseFloat(e+"e"+t+"e-"+t)))},sanitize:function(e,t="_"){let n=["[","]","{","}","(",")","-","+","*","/"],r="[";for(let e=0;e<t.length;e++)n.includes(t[e])&&(r+="\\"),r+=t[e];r+="]+";let o=new RegExp(r,"g");return pd(gl(e).replace(/[^a-z0-9]/gi,t).replace(o,t),t)},search:Yl,selectElementText:function(e,t=null){if(t=t||window,e instanceof HTMLInputElement)return void e.select();let n,r,o=t.document;t.getSelection&&o.createRange?(n=t.getSelection(),r=o.createRange(),r.selectNodeContents(e),n.removeAllRanges(),n.addRange(r)):"createTextRange"in o.body&&"function"==typeof o.body.createTextRange&&(r=o.body.createTextRange(),r.moveToElementText(e),r.select())},selector:dd,setCookie:function(e,t,n){let r="";if(n){let e=new Date;e.setTime(e.getTime()+24*n*60*60*1e3),r="; expires="+e.toUTCString()}let o=escape(JSON.stringify({value:t}));document.cookie=e+"="+o+r+"; path=/"},setCssVar:function(e,t){0!==e.indexOf("--")&&(e="--"+e),document.documentElement.style.setProperty(e,t)},setNavigationVars:Xf,setProp:function(e,t,n,r=!0,o=!0){Object.defineProperty(e,t,{value:n,writable:r,configurable:o})},setProperty:hd,shorten:gd,shortenObj:function e(t,n=100){let r=Mf(t);return al(r,(t,o)=>{Qu(t)&&t.length>n?r[o]=gd(t,n):t&&"object"==typeof t&&(r[o]=e(t))}),r},shuffle:function(e){let t,n=e.length;for(;0!=n;)t=Math.floor(Math.random()*n),n--,[e[n],e[t]]=[e[t],e[n]];return e},simpleHash:Dl,simpleHash1:Ml,simpleHash2:Il,startChrono:function(e){let t=bbn.fn.microtimestamp();return this.constructor.chronos||Object.defineProperty(this.constructor,"chronos",{value:Object.create(null),writable:!1,configurable:!1}),this.constructor.chronos[e||"default"]=t,e},stopChrono:function(e,t){if(this.constructor.chronos[e||"default"]){let n=bbn.fn.microtimestamp()-this.constructor.chronos[e||"default"];return delete this.constructor.chronos[e||"default"],t&&(n=Math.round(n)/1e3),n}throw Error("No chrono with name "+(e||"default"))},stream:function(e,t,n,r,o,i){const a=ql(e,n,"json"),s=Fl(a);if(null==s?void 0:s.loader)return s.loader;n||(n={}),bbn.env.token&&(n._bbn_token=bbn.env.token);const c=new AbortController;let u="";const l=e=>{if(e.length){e=e.indexOf("\n")>-1?bbn.fn.removeEmpty(e.split("\n")):[e];for(let n in e)try{t(JSON.parse(e[n]))}catch(e){throw e}}},f=bbn.fn.startChrono(),d=fetch(e,{method:"POST",mode:"cors",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json"},redirect:"follow",referrerPolicy:"no-referrer",signal:c.signal,body:JSON.stringify(n||{})}).then(e=>{if(bbn.fn.log("RESPONSE IN "+bbn.fn.stopChrono(f,!0)+" SECS"),e.body){const r=e.body.getReader(),o=tl(t);r.read().then(function e({done:s,value:c}){if(s)return Ll(a,n),u&&l(u),void(i&&i());if(o)if(u+=Jl(c).trim(),bbn.fn.log(["STREAM RESULT",u.length,u]),u)try{l(u),u=""}catch(e){}else t();else bbn.fn.log(["STREAM SUCCESS IS FN? "+o]);return r.read().then(e)})}}).catch(t=>{let i=!(!(s=t)||!0!==s.__BBN_CANCEL__);var s;if(Ll(a,n,i),i){let n=1;tl(o)&&(n=o(t.message,e)),n&&_f(t.message,e)}else{let e=1;tl(r)&&(e=r(t.request,t)),e&&xf(t.request,t.response?t.response.data:"",t.response?t.response.status:t)}});return ml(a,d,c),d},string2ArrayBuffer:function(e){for(var t=new ArrayBuffer(2*e.length),n=new Uint16Array(t),r=0,o=e.length;r<o;r++)n[r]=e.charCodeAt(r);return t},submit:td,substr:rl,sum:function(e,t,n,r,o){let i=0;return al(Df(e,n,r,o),e=>{let n="function"==typeof t?t(e):e[t];n&&(i+=parseFloat(n)||0)}),i},timestamp:ad,toCSV:function(e,t=",",n="",r='"'){t||(t=","),r||(r='"');let o="",i=e.length;return al(e,(e,a)=>{let s=cl(e)?e.length:Object.values(e).length,c=0;al(e,e=>{o+="string"==typeof e?r+$l(r,"\\"+r,e)+r:0===e?"0":e&&e.toString?e.toString():r+r,c++,c<s&&(o+=t)}),a<i-1&&(o+=n+"\n")}),o},toggleFullScreen:function(){"mozRequestFullScreen"in window.document.documentElement?window.document.mozFullScreen?window.document.mozCancelFullScreen():"function"==typeof window.document.documentElement.mozRequestFullScreen&&window.document.documentElement.mozRequestFullScreen():"webkitRequestFullScreen"in window.document.documentElement?window.document.webkitIsFullScreen?window.document.webkitCancelFullScreen():"function"==typeof window.document.documentElement.webkitRequestFullScreen&&window.document.documentElement.webkitRequestFullScreen():"msRequestFullScreen"in window.document.documentElement?window.document.msFullscreenEnabled?window.document.msExitFullscreen():"function"==typeof window.document.documentElement.msRequestFullScreen&&window.document.documentElement.msRequestFullScreen():"requestFullscreen"in window.document&&(window.document.fullscreenEnabled?window.document.exitFullscreen():window.document.documentElement.requestFullscreen()),setTimeout(function(){nd()},0)},translate:function(e,t){let n=t?bbn.lng[0===t.indexOf("_")?t:"_"+t]:bbn.lng;il(e,(e,t)=>{n[t]=e})},treatAjaxArguments:Kf,treatForHash:_l,trim:pd,uniqString:function(...e){for(var t="",n=0;n<e.length;n++)if(e[n])if("object"==typeof e[n])if(cl(e[n]))t+=JSON.stringify(e[n]);else{let r={};al(Object.keys(e[n]).sort(),t=>{r[t]=e[n][t]}),t+=JSON.stringify(r)}else"string"!=typeof e[n]?t+=e[n].toString():t+=e[n];else t+="__bbn_empty__";return Ol(t)},unique:Zf,upload:function(e,t,n=null,r=null,o=null){const i=()=>Gu.run("post",e||bbn.env.path,{data:fd({file:t}),headers:{"Content-Type":"multipart/form-data"},onUploadProgress(e){if(o){let t=Math.round(100*e.loaded/e.total);o(t,e.loaded,e.total)}}});return n||r?i().then(e=>{n&&(nl("SUCCESS",e),n(e))}).catch(e=>{r&&(nl("ERROR",e),r(e))}):i()},warning:ld,yieldToBrowser:Ff},yd=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},vd=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class Ed{constructor(e,t,n,r,o,i,a){if(bd.set(this,void 0),e)if(void 0===t)if(e instanceof Hu.PlainDateTime)yd(this,bd,e,"f");else if(e instanceof Date)yd(this,bd,new Hu.PlainDateTime(e.getFullYear(),e.getMonth()+1,e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");{const t=new Date(e);yd(this,bd,new Hu.PlainDateTime(t.getFullYear(),t.getMonth()+1,t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()),"f")}}else yd(this,bd,new Hu.PlainDateTime(e,t,n||1,r||0,o||0,i||0,a||0),"f");else yd(this,bd,Hu.PlainDateTime.from(Hu.Now.plainDateISO()),"f")}get value(){return vd(this,bd,"f")}}bd=new WeakMap;const Md=(e,t,n)=>{let r="";const o=t.hourCycle,i=e.some(e=>"dayPeriod"===e.type),a=i||"h12"===o||"h11"===o,s=!!n.year,c=!!n.month,u=!!n.day,l=!!n.weekday,f="short"===n.month||"long"===n.month,d=s&&c&&u&&!l&&!f;for(const o of e)switch(o.type){case"year":"2-digit"===t.year?r+="YY":r+="YYYY";break;case"month":if("short"===n.month||"long"===n.month){r+="long"===n.month?"MMMM":"MMM";break}if(d){r+="M";break}/^\d+$/.test(o.value)?r+=2===o.value.length?"MM":"M":r+=o.value.length>3?"MMMM":"MMM";break;case"day":if(d){r+="D";break}r+=2===o.value.length?"DD":"D";break;case"weekday":"short"===n.weekday||"narrow"===n.weekday?r+="ddd":"long"===n.weekday?r+="dddd":r+=o.value.length>3?"dddd":"ddd";break;case"hour":r+=a?2===o.value.length?"hh":"h":2===o.value.length?"HH":"H";break;case"minute":r+="II";break;case"second":r+="SS";break;case"dayPeriod":r+="A";break;case"timeZoneName":r+="z";break;case"literal":if(!o.value)break;if(/[A-Za-zÀ-ÖØ-öø-ÿ]/.test(o.value)){r+=`[${o.value.replace(/]/g,"\\]")}]`}else r+=o.value;break;default:r+=o.value}return r},Id=e=>{e||(e=[bbn.env.lang,...navigator.languages]);const t=new Date(Date.UTC(2e3,0,2,13,45,30)),n=[],r=[],o=[],i=new Set,a=new Set,s=new Set,c=[{year:"numeric",month:"2-digit",day:"2-digit"},{year:"numeric",month:"numeric",day:"numeric"},{year:"numeric",month:"short",day:"numeric"},{year:"numeric",month:"long",day:"numeric"},{weekday:"short",year:"numeric",month:"short",day:"numeric"},{weekday:"long",year:"numeric",month:"long",day:"numeric"},{year:"numeric",month:"numeric"},{year:"numeric",month:"2-digit"},{year:"numeric",month:"short"},{year:"numeric",month:"long"},{month:"numeric",day:"numeric"},{month:"2-digit",day:"2-digit"},{month:"short",day:"numeric"},{month:"long",day:"numeric"}],u=[];for(const r of c){const o=new Intl.DateTimeFormat(e,r),a=o.formatToParts(t),s=o.resolvedOptions(),c=Md(a,s,r);i.has(c)||(i.add(c),n.push({pattern:c,sample:o.format(t),options:r})),r.year&&r.month&&r.day&&u.push(r)}const l=[{hour:"numeric"},{hour:"2-digit",minute:"2-digit"},{hour:"2-digit",minute:"2-digit",second:"2-digit"},{hour:"2-digit",minute:"2-digit",timeZoneName:"short"},{hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:"short"},{hour:"2-digit",minute:"2-digit",timeZoneName:"long"}];for(const n of l){const o=new Intl.DateTimeFormat(e,n),i=o.formatToParts(t),s=o.resolvedOptions(),c=Md(i,s,n);a.has(c)||(a.add(c),r.push({pattern:c,sample:o.format(t),options:n}))}for(const n of u)for(const r of l){const i=Object.assign(Object.assign({},n),r),a=new Intl.DateTimeFormat(e,i),c=a.formatToParts(t),u=a.resolvedOptions(),l=Md(c,u,i);s.has(l)||(s.add(l),o.push({pattern:l,sample:a.format(t),options:i}))}return{date:n,time:r,datetime:o}},Dd=()=>{if(Object.keys(bbn.dt.locales).length)return;const e=[bbn.env.lang,...navigator.languages],t=new Intl.DateTimeFormat(e,{month:"long"}),n=new Intl.DateTimeFormat(e,{month:"short"}),r=new Intl.DateTimeFormat(e,{weekday:"long"}),o=new Intl.DateTimeFormat(e,{weekday:"short"}),i=[],a=[];for(let e=0;e<12;e++){const r=new Date(2020,e,1);i.push(t.format(r)),a.push(n.format(r))}const s=new Date(2020,1,2),c=[],u=[];for(let e=0;e<7;e++){const t=new Date(s.getTime()+864e5*e);c.push(r.format(t)),u.push(o.format(t))}const{date:l,time:f,datetime:d}=Id(e);ul(bbn.dt.locales,{monthsLong:i,monthsShort:a,weekdaysLong:c,weekdaysShort:u,date:l,time:f,datetime:d})};function Sd(e,t=!1,n=Hu.Now.timeZoneId()){const r=Hu.Instant.fromEpochMilliseconds(e.getTime()).toZonedDateTimeISO(n);return t?r:r.toPlainDateTime()}var kd,Td=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},_d=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class xd{constructor(e,t,n,r,o,i,a,s){if(kd.set(this,void 0),e)if(void 0===t)if(e instanceof Hu.ZonedDateTime)Td(this,kd,e,"f");else if(e instanceof Date)Td(this,kd,Sd(e,!0),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtZoned");{const t=new Date(e);Td(this,kd,Sd(t,!0),"f")}}else{const c=new Hu.PlainDateTime(t,n,r||1,o||0,i||0,a||0,s||0);Td(this,kd,c.toZonedDateTime(e||Hu.Now.timeZoneId()),"f")}else{const e=new Date;Td(this,kd,new Hu.ZonedDateTime(BigInt(1e6*e.getTime()),Intl.DateTimeFormat().resolvedOptions().timeZone),"f")}}get value(){return _d(this,kd,"f")}}kd=new WeakMap;var Od,jd=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},Cd=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class Rd{constructor(e,t,n){if(Od.set(this,void 0),e){if(void 0===t)if(e instanceof Hu.PlainDate)jd(this,Od,e,"f");else if(e instanceof Date)jd(this,Od,new Hu.PlainDate(e.getFullYear(),e.getMonth()+1,e.getDate()),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");{const t=new Date(e);jd(this,Od,new Hu.PlainDate(t.getFullYear(),t.getMonth()+1,t.getDate()),"f")}}}else jd(this,Od,Hu.PlainDate.from(Hu.Now.plainDateISO()),"f")}get value(){return Cd(this,Od,"f")}}Od=new WeakMap;var Nd,Pd=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},Yd=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class Ad{constructor(e,t,n,r){if(Nd.set(this,void 0),e){if(void 0===e)if(e instanceof Hu.PlainTime)Pd(this,Nd,e,"f");else if(e instanceof Date)Pd(this,Nd,new Hu.PlainTime(e.getHours(),e.getMinutes(),e.getSeconds(),1e6*e.getMilliseconds()),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");if(void 0!==t)Pd(this,Nd,new Hu.PlainTime(e,t,n||0,r||0),"f");else{const t=new Date(e);Pd(this,Nd,new Hu.PlainTime(t.getHours(),t.getMinutes(),t.getSeconds(),1e6*t.getMilliseconds()),"f")}}}else{const e=new Date;Pd(this,Nd,new Hu.PlainTime(e.getHours(),e.getMinutes(),e.getSeconds(),1e6*e.getMilliseconds()),"f")}}get value(){return Yd(this,Nd,"f")}}Nd=new WeakMap;var Ld,Fd=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},Hd=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class Bd{constructor(e,t){if(Ld.set(this,void 0),e){if(void 0===t)if(e instanceof Hu.PlainYearMonth)Fd(this,Ld,e,"f");else if(e instanceof Date)Fd(this,Ld,new Hu.PlainYearMonth(e.getFullYear(),e.getMonth()+1),"f");else{if("number"!=typeof t)throw new Error("Invalid value for bbnDtDateTime");{const e=new Date(t);Fd(this,Ld,new Hu.PlainYearMonth(e.getFullYear(),e.getMonth()+1),"f")}}}else{const e=new Date;Fd(this,Ld,new Hu.PlainYearMonth(e.getFullYear(),e.getMonth()+1),"f")}}get value(){return Hd(this,Ld,"f")}}Ld=new WeakMap;var Ud,Zd=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},Wd=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class $d{constructor(e,t){if(Ud.set(this,void 0),e)if(void 0===t)if(e instanceof Hu.PlainMonthDay)Zd(this,Ud,e,"f");else if(e instanceof Date)Zd(this,Ud,new Hu.PlainMonthDay(e.getMonth()+1,e.getDate()),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");{const t=new Date(e);Zd(this,Ud,new Hu.PlainMonthDay(t.getMonth()+1,t.getDate()),"f")}}else Zd(this,Ud,new Hu.PlainMonthDay(e,t),"f");else{const e=new Date;Zd(this,Ud,new Hu.PlainMonthDay(e.getMonth()+1,e.getDate()),"f")}}get value(){return Wd(this,Ud,"f")}}Ud=new WeakMap;const qd=function(e,t){try{return t?e.toLocaleLowerCase(t):e.toLowerCase()}catch(t){return e.toLowerCase()}};function zd(e,t,n="auto",r){var o,i,a,s,c,u,l;bbn.fn.log([e,t,n]),Dd();const f=globalThis.Temporal;if(!f)throw new Error("Temporal API is required (load @js-temporal/polyfill)");const d=f;r||(r=(null===(o=null==bbn?void 0:bbn.dt)||void 0===o?void 0:o.locales)||{});const h={monthsLong:null!==(i=null==r?void 0:r.monthsLong)&&void 0!==i?i:bbn.dt.locales.monthsLong,monthsShort:null!==(a=null==r?void 0:r.monthsShort)&&void 0!==a?a:bbn.dt.locales.monthsShort,weekdaysLong:null!==(s=null==r?void 0:r.weekdaysLong)&&void 0!==s?s:bbn.dt.locales.weekdaysLong,weekdaysShort:null!==(c=null==r?void 0:r.weekdaysShort)&&void 0!==c?c:bbn.dt.locales.weekdaysShort},m=(null==bbn?void 0:bbn.env)&&(null===(u=bbn.env)||void 0===u?void 0:u.lang)||(null==bbn?void 0:bbn.dt)&&(null===(l=bbn.dt)||void 0===l?void 0:l.locale)||Intl.DateTimeFormat().resolvedOptions().locale,p=e=>e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");function g(t,n="auto"){var r;const o={year:1970,month:1,day:1,hour:0,minute:0,second:0,ms:0,hasYear:!1,hasMonth:!1,hasDay:!1,hasHour:!1,hasMinute:!1,hasSecond:!1,hasMs:!1},i="auto"===n,a="zoned"===n.toLowerCase(),s="datetime"===n.toLowerCase(),c="date"===n.toLowerCase(),u="time"===n.toLowerCase(),l="yearmonth"===n.toLowerCase(),f="monthday"===n.toLowerCase(),g=[{token:"YYYY",regex:"\\d{4}",apply:(e,t)=>{t.year=parseInt(e,10),t.hasYear=!0}},{token:"YY",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);t.year=n>=70?1900+n:2e3+n,t.hasYear=!0}},{token:"Y",regex:"[+-]?\\d{1,6}",apply:(e,t)=>{t.year=parseInt(e,10),t.hasYear=!0}},{token:"MMMM",regex:"[^\\d\\s]+",apply:(e,t)=>{const n=qd(e,m),r=h.monthsLong.findIndex(e=>qd(e,m)===n);if(-1===r)throw new Error("Invalid month name: "+e);t.month=r+1,t.hasMonth=!0}},{token:"MMM",regex:"[^\\d\\s]+",apply:(e,t)=>{const n=qd(e,m),r=h.monthsShort.findIndex(e=>qd(e,m)===n);if(-1===r)throw new Error("Invalid short month name: "+e);t.month=r+1,t.hasMonth=!0}},{token:"MM",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>12)throw new Error("Invalid month: "+n);t.month=n,t.hasMonth=!0}},{token:"mm",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid minute: "+n);t.month=n,t.hasMonth=!0}},{token:"M",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>12)throw new Error("Invalid month: "+n);t.month=n,t.hasMonth=!0}},{token:"m",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>12)throw new Error("Invalid month: "+n);t.month=n,t.hasMonth=!0}},{token:"DD",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>31)throw new Error("Invalid day of month: "+n);t.day=n,t.hasDay=!0}},{token:"D",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>31)throw new Error("Invalid day of month: "+n);t.day=n,t.hasDay=!0}},{token:"d",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>31)throw new Error("Invalid day of month: "+n);t.day=n,t.hasDay=!0}},{token:"dddd",regex:"[^\\d\\s]+",apply:(e,t)=>{const n=qd(e,m),r=h.weekdaysLong.findIndex(e=>qd(e,m)===n);if(-1===r)throw new Error("Invalid weekday name: "+e);t.weekday=r}},{token:"ddd",regex:"[^\\d\\s]+",apply:(e,t)=>{const n=qd(e,m),r=h.weekdaysShort.findIndex(e=>qd(e,m)===n);if(-1===r)throw new Error("Invalid short weekday name: "+e);t.weekday=r}},{token:"EE",regex:"\\d{1}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>7)throw new Error("Invalid weekday number: "+n);t.weekday=n}},{token:"hh",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>12)throw new Error("Invalid 12-hour clock hour: "+n);t.hour=n,t.hasHour=!0,t.uses12Hour=!0}},{token:"HH",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>23)throw new Error("Invalid hour: "+n);t.hour=n,t.hasHour=!0}},{token:"H",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>23)throw new Error("Invalid hour: "+n);t.hour=n,t.hasHour=!0}},{token:"h",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>23)throw new Error("Invalid hour: "+n);t.hour=n,t.hasHour=!0}},{token:"II",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid minute: "+n);t.minute=n,t.hasMinute=!0}},{token:"I",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid minute: "+n);t.minute=n,t.hasMinute=!0}},{token:"i",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid minute: "+n);t.minute=n,t.hasMinute=!0}},{token:"SS",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid second: "+n);t.second=n,t.hasSecond=!0}},{token:"S",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid second: "+n);t.second=n,t.hasSecond=!0}},{token:"s",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid second: "+n);t.second=n,t.hasSecond=!0}},{token:"ms",regex:"\\d{1,3}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>999)throw new Error("Invalid millisecond: "+n);t.ms=n,t.hasMs=!0}},{token:"WWWW",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>53)throw new Error("Invalid week number: "+n);t.week=n}},{token:"WWW",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>53)throw new Error("Invalid week number: "+n);t.week=n}},{token:"WW",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>53)throw new Error("Invalid week number: "+n);t.week=n}},{token:"W",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>53)throw new Error("Invalid week number: "+n);t.week=n}},{token:"Z",regex:"(?:Z|[+-]\\d{2}:?\\d{2})",apply:(e,t)=>{if("Z"===e||"z"===e)return void(t.offsetMinutes=0);const n="-"===e[0]?-1:1,r=e.slice(1);let o,i;if(r.includes(":")){const[e,t]=r.split(":");o=parseInt(e,10),i=parseInt(t,10)}else o=parseInt(r.slice(0,2),10),i=parseInt(r.slice(2,4),10);if(o<0||o>23||i<0||i>59)throw new Error("Invalid timezone offset: "+e);t.offsetMinutes=n*(60*o+i)}},{token:"z",regex:"[A-Za-z_\\/]+",apply:(e,t)=>{t.timeZone=e}},{token:"A",regex:"(?:AM|PM|am|pm)",apply:(e,t)=>{t.isPM=/pm/i.test(e),t.hasAmPm=!0}},{token:"a",regex:"(?:AM|PM|am|pm)",apply:(e,t)=>{t.isPM=/pm/i.test(e),t.hasAmPm=!0}}],b=[...g].sort((e,t)=>t.token.length-e.token.length);let w="";const y=[];let v=0;for(;v<t.length;){if("["===t[v]){let e=v+1,n="";for(;e<t.length&&"]"!==t[e];)n+=t[e],e++;if(e<t.length&&"]"===t[e]){const t=n.replace(/\\]/g,"]");w+=p(t),v=e+1;continue}}let e=null;for(const n of b)if(t.startsWith(n.token,v)){e=n;break}e?(w+=`(${e.regex})`,e.apply?y.push(t=>e.apply(t,o)):y.push(()=>{}),v+=e.token.length):(w+=p(t[v]),v+=1)}const E=new RegExp("^"+w+"$").exec(e);if(!E)throw new Error(`Date string "${e}" does not match format "${t}"`);for(let e=1;e<E.length;e++){const t=E[e],n=y[e-1];null!=t&&n&&n(t)}if(o.uses12Hour){if(!o.hasAmPm)throw new Error("AM/PM marker (A or a) is required with 12-hour format (hh)");let e=o.hour;o.isPM?e<12&&(e+=12):12===e&&(e=0),o.hour=e}const M=o.hasYear||o.hasMonth||o.hasDay,I=o.hasYear&&o.hasMonth&&o.hasDay,D=o.hasYear&&o.hasMonth&&!o.hasDay,S=!o.hasYear&&o.hasMonth&&o.hasDay,k=o.hasHour||o.hasMinute||o.hasSecond||o.hasMs,T=null!=o.timeZone||null!=o.offsetMinutes;if(a||T&&i){let e;try{e=new d.PlainDateTime(o.year,o.month,o.day,o.hour,o.minute,o.second,1e6*o.ms)}catch(e){throw new Error("Invalid date/time components")}if(o.timeZone){const t=d.TimeZone.from(o.timeZone),n=e.toZonedDateTime(t);return new xd(n)}const t=Date.UTC(o.year,o.month-1,o.day,o.hour,o.minute,o.second,o.ms)-6e4*(null!==(r=o.offsetMinutes)&&void 0!==r?r:0);return new xd(d.Instant.fromEpochMilliseconds(t).toZonedDateTimeISO(d.Now.timeZoneId()))}if(s||i&&M&&k){if(!I)throw new Error("PlainDateTime requires year, month and day");const e=new d.PlainDateTime(o.year,o.month,o.day,o.hour,o.minute,o.second,1e6*o.ms);return new Ed(e)}if(c||l||f||i&&M&&!k){if(c||I&&i){const e=new d.PlainDate(o.year,o.month,o.day);return new Rd(e)}if(l||D&&i){const e=new d.PlainYearMonth(o.year,o.month);return new Bd(e)}if(f||S&&i){const e=new d.PlainMonthDay(o.month,o.day,1972);return new $d(e)}throw new Error("Not enough date components for a known Temporal type")}if(u||i&&!M&&k){const e=new d.PlainTime(o.hour,o.minute,o.second,1e6*o.ms);return new Ad(e)}throw new Error("No date or time information found in input")}if(Array.isArray(t)){let e=null;for(const r of t)try{return g(r,n)}catch(t){e=t}throw null!=e?e:new Error("No format matched")}return g(t,n)}const Vd=["YYYY-MM-DD","YYYY-MM-DD HH:II:SS.ms","YYYY-MM-DD HH:II:SS","YYYY-MM-DD HH:II","HH:II:SS","HH:II","YYYY-MM-DDTHH:II:SS.msZ","YYYY-MM-DDTHH:II:SSZ","YYYY-MM-DDTHH:II:SS","YYYY-MM-DDTHH:II","ddd[, ]DD MMM YYYY HH:II:SS[ GMT]","ddd MMM DD YYYY HH:II:SS[ GMT]Z","ddd MMM DD YYYY HH:II:SS"],Jd=e=>!/[HhI SAz]/.test(e)&&!!(/[Y]/.test(e)&&/[M]/.test(e)&&/[D]/.test(e)),Gd=e=>e.replace(/DD/g,"D").replace(/MM/g,"M"),Kd=(e,t)=>{if(/[HhI SAzM]{2,}|[A-Za-z]/.test(e.replace(/[DMY]/g,"")))return e;if(!e.includes("D")||!e.includes("M")||!e.includes("Y"))return e;const n=t.split(/\D+/).filter(Boolean);if(n.length<3)return e;const[r,o]=n;if(2===r.length&&2===o.length){let t=e;return t=t.replace(/D+/,"DD"),t=t.replace(/M+/,"MM"),t}return e};function Xd(e,t,n){const r=e.trim();if(!r)return null;Dd();const o=e=>{for(const t of e){try{return zd(r,t),Kd(t,r)}catch(e){}if(Jd(t)){const e=Gd(t);if(e!==t)try{return zd(r,e),e}catch(e){}}}return null};if(t){return o(Array.isArray(t)?t:[t])}const i=Id(n),a=new Set,s=Vd.filter(e=>!a.has(e)&&(a.add(e),!0)),c=[...i.datetime.map(e=>e.pattern),...i.date.map(e=>e.pattern),...i.time.map(e=>e.pattern)].filter(e=>!a.has(e)&&(a.add(e),!0)),u=o([...s,...c]);return u||null}const Qd=(e,t=null,n="auto")=>{if(!e)return new Ed;if("string"==typeof e){if(t)return zd(e,t,n);{const t=Xd(e);if(t)return zd(e,t,n);throw new Error(Zu("Could not guess the date format for value: %s",e))}}if("number"==typeof e)return new Ed(e);if(e instanceof Date){const t=e;return new Ed(t.getFullYear(),t.getMonth()+1,t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds())}throw new Error(Zu("Invalid date value: %s",e))};Qd.locales=Object.create(null),Qd.parse=zd,Qd.guessFormat=Xd,Qd.time=()=>{},Qd.date=()=>{},Qd.dateTime=()=>{},Qd.duration=()=>{},Qd.zoned=()=>{},Qd.monthDay=()=>{},Qd.yearMonth=()=>{};const eh={version:"1.0.1",opt:{_cat:{}},app:{},_:Zu,$:function(e,t){if(null==t?void 0:t.querySelectorAll)return t.querySelectorAll(e);if(t)throw new Error("Invalid context");return document.body.querySelectorAll(e)},lng:{select_unselect_all:"Select/Clear all",select_all:"Select all",search:"Search",loading:"Loading...",choose:"Choose",error:"Error",server_response:"Server response",reload:"Reload",errorText:"Something went wrong",closeAll:"Close all",closeOthers:"Close others",pin:"Pin",arrange:"Arrange",cancel:"Cancel",unpin:"Unpin",yes:"Yes",no:"No",unknown:"Unknown",untitled:"Untitled",confirmation:"Confirmation",Today:"Today",Tomorrow:"Tomorrow",Yesterday:"Yesterday"},var:Wu,date:gf,dt:Qd,com:Gu,env:$u,db:hl,fn:wd,info:[{value:"ajax",label:"Loading and streaming",description:"Functions related to Ajax requests",icon:"nf nf-fa-rocket"},{value:"browser",label:"Browser-only",description:"Functions that can only be run in the browser",icon:"nf nf-fa-desktop"},{value:"convert",label:"Conversion",description:"Functions related to data conversion",icon:"nf nf-fa-exchange"},{value:"datetime",label:"Date and time",description:"Functions related to dates and times",icon:"nf nf-fa-calendar"},{value:"form",label:"Form manipulation",description:"Functions related to form manipulation and validation",icon:"nf nf-fa-edit"},{value:"html",label:"HTML manipulation",description:"Functions related to HTML manipulation and DOM interaction",icon:"nf nf-fa-html5"},{value:"loop",label:"Looping",description:"Functions related to looping through arrays and objects",icon:"nf nf-fa-repeat"},{value:"misc",label:"Miscellaneous",description:"Miscellaneous functions that do not fit into other categories",icon:"nf nf-fa-cubes"},{value:"object",label:"Object manipulation",description:"Functions related to object manipulation and inspection",icon:"nf nf-fa-object_group"},{value:"phone",label:"Phone and contact",description:"Functions related to phone numbers and contact information",icon:"nf nf-fa-phone"},{value:"string",label:"String manipulation",description:"Functions related to string manipulation and formatting",icon:"nf nf-fa-text_height"},{value:"style",label:"Styling and layout",description:"Functions related to styling and layout management",icon:"nf nf-fa-paint_brush"},{value:"type",label:"Type checking",description:"Functions related to type checking and validation",icon:"nf nf-fa-check_square"}]};return"undefined"!=typeof window&&(window.bbn=eh,window.Temporal||(window.Temporal=Hu)),e.Temporal=Hu,e.bbn=eh,e.default=eh,Object.defineProperty(e,"__esModule",{value:!0}),e}({});
1
+ var bbn=function(e){"use strict";function t(e,t,r,o,i){return n(t,((e,t)=>{const n=e[t];if(void 0===n)throw new TypeError(Io(t));return n})(e,t),r,o,i)}function n(e,t,n,r,o,i){const a=M(t,n,r);if(o&&t!==a)throw new RangeError(Eo(e,t,n,r,i));return a}function r(e){return null!==e&&/object|function/.test(typeof e)}function o(e,t=Map){const n=new t;return(t,...r)=>{if(n.has(t))return n.get(t);const o=e(t,...r);return n.set(t,o),o}}function i(e){return a({name:e},1)}function a(e,t){return l(e=>({value:e,configurable:1,writable:!t}),e)}function s(e){return l(e=>({get:e,configurable:1}),e)}function c(e){return{[Symbol.toStringTag]:{value:e,configurable:1}}}function u(e,t){const n={};let r=e.length;for(const o of t)n[e[--r]]=o;return n}function l(e,t,n){const r={};for(const o in t)r[o]=e(t[o],o,n);return r}function f(e,t,n){const r={};for(let o=0;o<t.length;o++){const i=t[o];r[i]=e(i,o,n)}return r}function d(e,t,n){const r={};for(let o=0;o<e.length;o++)r[t[o]]=n[e[o]];return r}function h(e,t){const n=Object.create(null);for(const r of e)n[r]=t[r];return n}function m(e,t){for(const n of t)if(n in e)return 1;return 0}function p(e,t,n){for(const r of e)if(t[r]!==n[r])return 0;return 1}function g(e,t,n){const r={...n};for(let n=0;n<t;n++)r[e[n]]=0;return r}function b(e,...t){return(...n)=>e(...t,...n)}function w(e){return e[0].toUpperCase()+e.substring(1)}function y(e){return e.slice().sort()}function v(e,t){return String(t).padStart(e,"0")}function E(e,t){return Math.sign(e-t)}function M(e,t,n){return Math.min(Math.max(e,t),n)}function I(e,t){return[Math.floor(e/t),D(e,t)]}function D(e,t){return(e%t+t)%t}function S(e,t){return[k(e,t),T(e,t)]}function k(e,t){return Math.trunc(e/t)||0}function T(e,t){return e%t||0}function _(e){return.5===Math.abs(e%1)}function x(e,t,n){let r=0,o=0;for(let i=0;i<=t;i++){const t=e[n[i]],a=wi[i],s=bi/a,[c,u]=S(t,s);r+=u*a,o+=c}const[i,a]=S(r,bi);return[o+i,a]}function O(e,t,n){const r={};for(let o=t;o>=0;o--){const t=wi[o];r[n[o]]=k(e,t),e=T(e,t)}return r}function j(e){if(void 0!==e)return R(e)}function C(e){return L(R(e))}function R(e){return A($i(e))}function N(e,t){if(null==t)throw new RangeError(Io(e));return t}function P(e){if(!r(e))throw new TypeError(vo);return e}function Y(e,t,n=e){if(typeof t!==e)throw new TypeError(Mo(n,t));return t}function A(e,t="number"){if(!Number.isInteger(e))throw new RangeError(mo(t,e));return e||0}function L(e,t="number"){if(e<=0)throw new RangeError(po(t,e));return e}function F(e){if("symbol"==typeof e)throw new TypeError(yo);return String(e)}function H(e,t){return r(e)?String(e):Zi(e,t)}function B(e){if("string"==typeof e)return BigInt(e);if("bigint"!=typeof e)throw new TypeError(wo(e));return e}function U(e,t="number"){if("bigint"==typeof e)throw new TypeError(bo(t));if(e=Number(e),!Number.isFinite(e))throw new RangeError(go(t,e));return e}function Z(e,t){return Math.trunc(U(e,t))||0}function W(e,t){return A(U(e,t),t)}function $(e,t){return L(Z(e,t),t)}function q(e,t){let[n,r]=S(t,bi),o=e+n;const i=Math.sign(o);return i&&i===-Math.sign(r)&&(o-=i,r+=i*bi),[o,r]}function z(e,t,n=1){return q(e[0]+t[0]*n,e[1]+t[1]*n)}function V(e,t){return q(e[0],e[1]+t)}function J(e,t){return z(t,e,-1)}function G(e,t){return E(e[0],t[0])||E(e[1],t[1])}function K(e,t,n){return-1===G(e,t)||1===G(e,n)}function X(e,t=1){const n=BigInt(bi/t);return[Number(e/n),Number(e%n)*t]}function Q(e,t=1){const n=bi/t,[r,o]=S(e,n);return[r,o*t]}function ee(e,t=1,n){const[r,o]=e,[i,a]=S(o,t);return r*(bi/t)+(i+(n?a/t:0))}function te(e,t,n=I){const[r,o]=e,[i,a]=n(o,t);return[r*(bi/t)+i,a]}function ne(e){return t(e,"isoYear",ma,ha,1),e.isoYear===ma?t(e,"isoMonth",4,12,1):e.isoYear===ha&&t(e,"isoMonth",1,9,1),e}function re(e){return oe({...e,...sa,isoHour:12}),e}function oe(e){const n=t(e,"isoYear",ma,ha,1),r=n===ma?1:n===ha?-1:0;return r&&ie(le({...e,isoDay:e.isoDay+r,isoNanosecond:e.isoNanosecond-r})),e}function ie(e){if(!e||K(e,da,fa))throw new RangeError(Vo);return e}function ae(e){return x(e,5,ta)[1]}function se(e){const[t,n]=I(e,bi);return[O(n,5,ta),t]}function ce(e){return te(e,mi)}function ue(e){return he(e.isoYear,e.isoMonth,e.isoDay,e.isoHour,e.isoMinute,e.isoSecond,e.isoMillisecond)}function le(e){const t=ue(e);if(void 0!==t){const[n,r]=S(t,li);return[n,r*hi+(e.isoMicrosecond||0)*di+(e.isoNanosecond||0)]}}function fe(e,t){const[n,r]=se(ae(e)-t);return ie(le({...e,isoDay:e.isoDay+r,...n}))}function de(...e){return he(...e)/fi}function he(...e){const[t,n]=me(...e),r=t.valueOf();if(!isNaN(r))return r-n*li}function me(e,t=1,n=1,r=0,o=0,i=0,a=0){const s=e===ma?1:e===ha?-1:0,c=new Date;return c.setUTCHours(r,o,i,a),c.setUTCFullYear(e,t-1,n+s),[c,s]}function pe(e,t){let[n,r]=V(e,t);r<0&&(r+=bi,n-=1);const[o,i]=I(r,hi),[a,s]=I(i,di);return ge(n*li+o,a,s)}function ge(e,t=0,n=0){const r=Math.ceil(Math.max(0,Math.abs(e)-la)/li)*Math.sign(e),o=new Date(e-r*li);return u(ra,[o.getUTCFullYear(),o.getUTCMonth()+1,o.getUTCDate()+r,o.getUTCHours(),o.getUTCMinutes(),o.getUTCSeconds(),o.getUTCMilliseconds(),t,n])}function be(e,t){if(t<-la)throw new RangeError(Vo);const n=e.formatToParts(t),r={};for(const e of n)r[e.type]=e.value;return r}function we(e){return[e.isoYear,e.isoMonth,e.isoDay]}function ye(e,t){return[t,0]}function ve(){return ya}function Ee(e,t){switch(t){case 2:return Ie(e)?29:28;case 4:case 6:case 9:case 11:return 30}return 31}function Me(e){return Ie(e)?366:365}function Ie(e){return e%4==0&&(e%100!=0||e%400==0)}function De(e){const[t,n]=me(e.isoYear,e.isoMonth,e.isoDay);return D(t.getUTCDay()-n,7)||7}function Se(e){return this.id===Li?(({isoYear:e})=>e<1?["gregory-inverse",1-e]:["gregory",e])(e):this.id===Fi?Ea(e):[]}function ke(e){const t=ue(e);if(t<va){const{isoYear:t}=e;return t<1?["japanese-inverse",1-t]:["japanese",t]}const n=be(Cs(Fi),t),{era:r,eraYear:o}=jr(n,Fi);return[r,o]}function Te(e){return _e(e),je(e,1),e}function _e(e){return Oe(e,1),e}function xe(e){return p(na,e,Oe(e))}function Oe(e,n){const{isoYear:r}=e,o=t(e,"isoMonth",1,ve(),n);return{isoYear:r,isoMonth:o,isoDay:t(e,"isoDay",1,Ee(r,o),n)}}function je(e,n){return u(ta,[t(e,"isoHour",0,23,n),t(e,"isoMinute",0,59,n),t(e,"isoSecond",0,59,n),t(e,"isoMillisecond",0,999,n),t(e,"isoMicrosecond",0,999,n),t(e,"isoNanosecond",0,999,n)])}function Ce(e){return void 0===e?0:Ha(P(e))}function Re(e,t=0){e=Ze(e);const n=Ba(e),r=Ua(e,t);return[Ha(e),r,n]}function Ne(e,t,n,r=9,o=0,i=4){t=Ze(t);let a=La(t,r,o),s=He(t),c=qa(t,i);const u=Aa(t,r,o,1);return null==a?a=Math.max(n,u):Ve(a,u),s=Be(s,u,1),e&&(c=(e=>e<4?(e+2)%4:e)(c)),[a,u,s,c]}function Pe(e,t=6,n){let r=He(e=We(e,Ma));const o=qa(e,7);let i=Aa(e,t);return i=N(Ma,i),r=Be(r,i,void 0,n),[i,r,o]}function Ye(e){return Za(Ze(e))}function Ae(e,t){return Le(Ze(e),t)}function Le(e,t=4){const n=Ue(e);return[qa(e,4),...Fe(Aa(e,t),n)]}function Fe(e,t){return null!=e?[wi[e],e<4?9-3*e:-1]:[void 0===t?1:10**(9-t),t]}function He(e){const t=e[Da];return void 0===t?1:Z(t,Da)}function Be(e,t,r,o){const i=o?bi:wi[t+1];if(i){const r=wi[t];if(i%((e=n(Da,e,1,i/r-(o?0:1),1))*r))throw new RangeError(Mo(Da,e))}else e=n(Da,e,1,r?10**9:1,1);return e}function Ue(e){let t=e[Sa];if(void 0!==t){if("number"!=typeof t){if("auto"===F(t))return;throw new RangeError(Mo(Sa,t))}t=n(Sa,Math.floor(t),0,9,1)}return t}function Ze(e){return void 0===e?{}:P(e)}function We(e,t){return"string"==typeof e?{[t]:e}:P(e)}function $e(e){return{overflow:xa[e]}}function qe(e,t,r=9,o=0,i){let a=t[e];if(void 0===a)return i?o:void 0;if(a=F(a),"auto"===a)return i?o:null;let s=ci[a];if(void 0===s&&(s=Ki[a]),void 0===s)throw new RangeError(To(e,a,ci));return n(e,s,o,r,1,ui),s}function ze(e,t,n,r=0){const o=n[e];if(void 0===o)return r;const i=F(o),a=t[i];if(void 0===a)throw new RangeError(To(e,i,t));return a}function Ve(e,t){if(t>e)throw new RangeError(ei)}function Je(e){return{branding:Qa,epochNanoseconds:e}}function Ge(e,t,n){return{branding:Xa,calendar:n,timeZone:t,epochNanoseconds:e}}function Ke(e,t=e.calendar){return{branding:Ga,calendar:t,...h(aa,e)}}function Xe(e,t=e.calendar){return{branding:Ja,calendar:t,...h(oa,e)}}function Qe(e,t=e.calendar){return{branding:za,calendar:t,...h(oa,e)}}function et(e,t=e.calendar){return{branding:Va,calendar:t,...h(oa,e)}}function tt(e){return{branding:Ka,...h(ia,e)}}function nt(e){return{branding:es,sign:bn(e),...h(zi,e)}}function rt(e){return te(e.epochNanoseconds,hi)[0]}function ot(e){return e.epochNanoseconds}function it(e,t){return ee(vn(e),wi[t],1)}function at(e,t,n,r,o,i,a){const s=qi[n],c={...t,[s]:t[s]+r},u=a(e,o,t),l=a(e,o,c);return[i(u),i(l)]}function st(e,t,n){const r=ee(J(t,n));if(!r)throw new RangeError(Lo);return ee(J(t,e))/r}function ct(e,t,n,r){return ut(e,dt(t,n),r)}function ut(e,t,n){const[r,o]=lt(e,t,n);return oe({...sn(e,o),...r})}function lt(e,t,n){return se(yt(ae(e),t,n))}function ft(e){return yt(e,pi,7)}function dt(e,t){return wi[e]*t}function ht(e){const t=mt(e);return[t,sn(t,1)]}function mt(e){return ca(6,e)}function pt(e,t,n){const r=Math.min(Dn(e),6);return En(wt(vn(e,r),t,n),r)}function gt(e,t,n,r,o,i,a,s,c,u){if(0===r&&1===o)return e;const l=hn(r,s)?dn(s)&&r<6&&n>=6?Mt:Et:It;let[f,d,h]=l(e,t,n,r,o,i,a,s,c,u);return h&&7!==r&&(f=((e,t,n,r,o,i,a,s)=>{const c=bn(e);for(let u=r+1;u<=n;u++){if(7===u&&7!==n)continue;const r=ea(u,e);r[qi[u]]+=c;const l=ee(J(a(s(o,i,r)),t));if(l&&Math.sign(l)!==c)break;e=r}return e})(f,d,n,Math.max(6,r),a,s,c,u)),f}function bt(e,t,n,r,o){if(6===t){const t=(e=>e[0]+e[1]/bi)(e);return[yt(t,n,r),0]}return wt(e,dt(t,n),r,o)}function wt(e,t,n,r){let[o,i]=e;r&&i<0&&(i+=bi,o-=1);const[a,s]=I(yt(i,t,n),bi);return q(o+a,s)}function yt(e,t,n){return vt(e/t,n)*t}function vt(e,t){return ts[t](e)}function Et(e,t,n,r,o,i){const a=bn(e),s=vn(e),c=bt(s,r,o,i),u=J(s,c),l=Math.sign(c[0]-s[0])===a,f=En(c,Math.min(n,6));return[{...e,...f},z(t,u),l]}function Mt(e,t,n,r,o,i,a,s,c,u){const l=bn(e)||1,f=ee(vn(e,5)),d=dt(r,o);let h=yt(f,d,i);const[m,p]=at(a,{...e,...Qi},6,l,s,c,u),g=h-ee(J(m,p));let b=0;g&&Math.sign(g)!==l?t=V(m,h):(b+=l,h=yt(g,d,i),t=V(p,h));const w=Mn(h);return[{...e,...w,days:e.days+b},t,Boolean(b)]}function It(e,t,n,r,o,i,a,s,c,u){const l=bn(e),f=qi[r],d=ea(r,e);7===r&&(e={...e,weeks:e.weeks+Math.trunc(e.days/7)});const h=k(e[f],o)*o;d[f]=h;const[m,p]=at(a,d,r,o*l,s,c,u),g=h+st(t,m,p)*l*o,b=yt(g,o,i),w=Math.sign(b-g)===l;return d[f]=b,[d,w?p:m,w]}function Dt(e,t,n,r){const[o,i,a,s]=(e=>{const t=Le(e=Ze(e));return[e.timeZone,...t]})(r),c=void 0!==o;return((e,t,n,r,o,i)=>{n=wt(n,o,r,1);const a=t.R(n);return Nt(pe(n,a),i)+(e?Ft(ft(a)):"Z")})(c,t(c?e(o):ns),n.epochNanoseconds,i,a,s)}function St(e,t,n){const[r,o,i,a,s,c]=(e=>{e=Ze(e);const t=Za(e),n=Ue(e),r=$a(e),o=qa(e,4),i=Aa(e,4);return[t,Wa(e),r,o,...Fe(i,n)]})(n);return((e,t,n,r,o,i,a,s,c,u)=>{r=wt(r,c,s,1);const l=e(n).R(r);return Nt(pe(r,l),u)+Ft(ft(l),a)+((e,t)=>1!==t?"["+(2===t?"!":"")+e+"]":"")(n,i)+Ht(t,o)})(e,t.calendar,t.timeZone,t.epochNanoseconds,r,o,i,a,s,c)}function kt(e,t){const[n,r,o,i]=(e=>(e=Ze(e),[Za(e),...Le(e)]))(t);return a=e.calendar,s=n,c=i,Nt(ut(e,o,r),c)+Ht(a,s);var a,s,c}function Tt(e,t){return n=e.calendar,r=e,o=Ye(t),Pt(r)+Ht(n,o);var n,r,o}function _t(e,t){return Ct(e.calendar,Yt,e,Ye(t))}function xt(e,t){return Ct(e.calendar,At,e,Ye(t))}function Ot(e,t){const[n,r,o]=Ae(t);return i=o,Lt(lt(e,r,n)[0],i);var i}function jt(e,t){const[n,r,o]=Ae(t,3);return r>1&&wn(e={...e,...pt(e,r,n)}),((e,t)=>{const{sign:n}=e,r=-1===n?gn(e):e,{hours:o,minutes:i}=r,[a,s]=te(vn(r,3),mi,S);yn(a);const c=Ut(s,t),u=t>=0||!n||c;return(n<0?"-":"")+"P"+Rt({Y:Wt(r.years),M:Wt(r.months),W:Wt(r.weeks),D:Wt(r.days)})+(o||i||a||u?"T"+Rt({H:Wt(o),M:Wt(i),S:Wt(a,u)+c}):"")})(e,o)}function Ct(e,t,n,r){const o=r>1||0===r&&e!==Ai;return 1===r?e===Ai?t(n):Pt(n):o?Pt(n)+Bt(e,2===r):t(n)}function Rt(e){const t=[];for(const n in e){const r=e[n];r&&t.push(r,n)}return t.join("")}function Nt(e,t){return Pt(e)+"T"+Lt(e,t)}function Pt(e){return Yt(e)+"-"+si(e.isoDay)}function Yt(e){const{isoYear:t}=e;return(t<0||t>9999?Zt(t)+v(6,Math.abs(t)):v(4,t))+"-"+si(e.isoMonth)}function At(e){return si(e.isoMonth)+"-"+si(e.isoDay)}function Lt(e,t){const n=[si(e.isoHour),si(e.isoMinute)];return-1!==t&&n.push(si(e.isoSecond)+((e,t,n,r)=>Ut(e*hi+t*di+n,r))(e.isoMillisecond,e.isoMicrosecond,e.isoNanosecond,t)),n.join(":")}function Ft(e,t=0){if(1===t)return"";const[n,r]=I(Math.abs(e),gi),[o,i]=I(r,pi),[a,s]=I(i,mi);return Zt(e)+si(n)+":"+si(o)+(a||s?":"+si(a)+Ut(s):"")}function Ht(e,t){return 1!==t&&(t>1||0===t&&e!==Ai)?Bt(e,2===t):""}function Bt(e,t){return"["+(t?"!":"")+"u-ca="+e+"]"}function Ut(e,t){let n=v(9,e);return n=void 0===t?n.replace(as,""):n.slice(0,t),n?"."+n:""}function Zt(e){return e<0?"-":"+"}function Wt(e,t){return e||t?e.toLocaleString("fullwide",{useGrouping:0}):""}function $t(e,t){const{epochNanoseconds:n}=e,r=(t.R?t:t(e.timeZone)).R(n),o=pe(n,r);return{calendar:e.calendar,...o,offsetNanoseconds:r}}function qt(e,t,n,r=0,o=0,i,a){if(void 0!==n&&1===r&&(1===r||a))return fe(t,n);const s=e.I(t);if(void 0!==n&&3!==r){const e=((e,t,n,r)=>{const o=le(t);r&&(n=ft(n));for(const t of e){let e=ee(J(t,o));if(r&&(e=ft(e)),e===n)return t}})(s,t,n,i);if(void 0!==e)return e;if(0===r)throw new RangeError(qo)}return a?le(t):zt(e,t,o,s)}function zt(e,t,n=0,r=e.I(t)){if(1===r.length)return r[0];if(1===n)throw new RangeError(zo);if(r.length)return r[3===n?1:0];const o=le(t),i=((e,t)=>{const n=e.R(V(t,-bi));return(e=>{if(e>bi)throw new RangeError($o);return e})(e.R(V(t,bi))-n)})(e,o),a=i*(2===n?-1:1);return(r=e.I(pe(o,a)))[2===n?0:r.length-1]}function Vt(e,t){const n=e.I(t);if(n.length)return n[0];const r=V(le(t),-bi);return e.O(r,1)}function Jt(e,t,n){return Je(ie(z(t.epochNanoseconds,(e=>{if(In(e))throw new RangeError(Xo);return vn(e,5)})(e?gn(n):n))))}function Gt(e,t,n,r,o,i=Object.create(null)){const a=t(r.timeZone),s=e(r.calendar);return{...r,...tn(a,s,r,n?gn(o):o,i)}}function Kt(e,t,n,r,o=Object.create(null)){const{calendar:i}=n;return Ke(nn(e(i),n,t?gn(r):r,o),i)}function Xt(e,t,n,r,o){const{calendar:i}=n;return Xe(rn(e(i),n,t?gn(r):r,o),i)}function Qt(e,t,n,r,o){const i=n.calendar,a=e(i);let s=re(on(a,n));t&&(r=pn(r)),r.sign<0&&(s=a.P(s,{...Xi,months:1}),s=sn(s,-1));const c=a.P(s,r,o);return Qe(on(a,c),i)}function en(e,t,n){return tt(an(t,e?gn(n):n)[0])}function tn(e,t,n,r,o){const i=vn(r,5);let a=n.epochNanoseconds;if(In(r)){const s=ss(n,e);a=z(zt(e,{...rn(t,s,{...r,...Qi},o),...h(ta,s)}),i)}else a=z(a,i),Ce(o);return{epochNanoseconds:ie(a)}}function nn(e,t,n,r){const[o,i]=an(t,n);return oe({...rn(e,t,{...n,...Qi,days:n.days+i},r),...o})}function rn(e,t,n,r){if(n.years||n.months||n.weeks)return e.P(t,n,r);Ce(r);const o=n.days+vn(n,5)[0];return o?re(sn(t,o)):t}function on(e,t,n=1){return sn(t,n-e.day(t))}function an(e,t){const[n,r]=vn(t,5),[o,i]=se(ae(e)+r);return[o,n+i]}function sn(e,t){return t?{...e,...ge(ue(e)+t*li)}:e}function cn(e,t,n){const r=e(n.calendar);return dn(n)?[n,r,t(n.timeZone)]:[{...n,...sa},r]}function un(e){return e?ot:le}function ln(e){return e?b(tn,e):nn}function fn(e){return e?b(sr,e):cr}function dn(e){return e&&e.epochNanoseconds}function hn(e,t){return e<=6-(dn(t)?1:0)}function mn(e,t,n,r,o,i,a){const s=e(Ze(a).relativeTo),c=Math.max(Dn(o),Dn(i));if(hn(c,s))return nt(wn(((e,t,n,r)=>{const o=z(vn(e),vn(t),r?-1:1);if(!Number.isFinite(o[0]))throw new RangeError(Vo);return{...Xi,...En(o,n)}})(o,i,c,r)));if(!s)throw new RangeError(Ko);r&&(i=gn(i));const[u,l,f]=cn(t,n,s),d=ln(f),h=fn(f),m=d(l,u,o);return nt(h(l,u,d(l,m,i),c))}function pn(e){return nt(gn(e))}function gn(e){const t={};for(const n of qi)t[n]=-1*e[n]||0;return t}function bn(e,t=qi){let n=0;for(const r of t){const t=Math.sign(e[r]);if(t){if(n&&n!==t)throw new RangeError(Go);n=t}}return n}function wn(e){for(const t of Gi)n(t,e[t],-cs,cs,1);return yn(ee(vn(e),mi)),e}function yn(e){if(!Number.isSafeInteger(e))throw new RangeError(Jo)}function vn(e,t=6){return x(e,t,qi)}function En(e,t=6){const[n,r]=e,o=O(r,t,qi);if(o[qi[t]]+=n*(bi/wi[t]),!Number.isFinite(o[qi[t]]))throw new RangeError(Vo);return o}function Mn(e,t=5){return O(e,t,qi)}function In(e){return Boolean(bn(e,Ji))}function Dn(e){let t=9;for(;t>0&&!e[qi[t]];t--);return t}function Sn(e,t){return[e,t]}function kn(e){const t=Math.floor(e/rs)*rs;return[t,t+rs]}function Tn(e){const t=An(e);if(void 0===t)throw new RangeError(ti(e));return t}function _n(e,t,n){let r=Nn(Zi(e));if(!r||r.j)throw new RangeError(ti(e));return t?r.calendar===Ai&&(r=-271821===r.isoYear&&4===r.isoMonth?{...r,isoDay:20,...sa}:{...r,isoDay:1,...sa}):n&&r.calendar===Ai&&(r={...r,isoYear:wa}),Xe(r.C?jn(r):Cn(r))}function xn(e){if(e.calendar!==Ai)throw new RangeError(ni(e.calendar))}function On(e,t,n=0,r=0){const o=$n(e.timeZone),i=us(o);let a;return Te(e),a=e.C?qt(i,e,t,n,r,!i.$,e.j):Vt(i,e),Ge(a,o,Zr(e.calendar))}function jn(e){return Rn(oe(Te(e)))}function Cn(e){return Rn(re(_e(e)))}function Rn(e){return{...e,calendar:Zr(e.calendar)}}function Nn(e){const t=Ms.exec(e);return t?(e=>{const t=e[10],n="Z"===(t||"").toUpperCase();return{isoYear:Ln(e),isoMonth:parseInt(e[4]),isoDay:parseInt(e[5]),...Fn(e.slice(5)),...Hn(e[16]),C:Boolean(e[6]),j:n,offset:n?void 0:t}})(t):void 0}function Pn(e){const t=vs.exec(e);return t?(e=>({isoYear:Ln(e),isoMonth:parseInt(e[4]),isoDay:1,...Hn(e[5])}))(t):void 0}function Yn(e){const t=Es.exec(e);return t?(e=>({isoYear:wa,isoMonth:parseInt(e[1]),isoDay:parseInt(e[2]),...Hn(e[3])}))(t):void 0}function An(e,t){const n=Ds.exec(e);return n?((e,t)=>{const n=e[4]||e[5];if(t&&n)throw new RangeError(ni(n));return(e=>{if(Math.abs(e)>=bi)throw new RangeError(Wo);return e})((Wn(e[2])*gi+Wn(e[3])*pi+Wn(e[4])*mi+Bn(e[5]||""))*Zn(e[1]))})(n,t):void 0}function Ln(e){const t=Zn(e[1]),n=parseInt(e[2]||e[3]);if(t<0&&!n)throw new RangeError(ni(-0));return t*n}function Fn(e){const t=Wn(e[3]);return{...se(Bn(e[4]||""))[0],isoHour:Wn(e[1]),isoMinute:Wn(e[2]),isoSecond:60===t?59:t}}function Hn(e){let t,n;const r=[];if(e.replace(Ss,(e,o,i)=>{const a=Boolean(o),[s,c]=i.split("=").reverse();if(c){if("u-ca"===c)r.push(s),t||(t=a);else if(a||/[A-Z]/.test(c))throw new RangeError(ni(e))}else{if(n)throw new RangeError(ni(e));n=s}return""}),r.length>1&&t)throw new RangeError(ni(e));return{timeZone:n,calendar:r[0]||Ai}}function Bn(e){return parseInt(e.padEnd(9,"0"))}function Un(e){return new RegExp(`^${e}$`,"i")}function Zn(e){return e&&"+"!==e?-1:1}function Wn(e){return void 0===e?0:parseInt(e)}function $n(e){const t=zn(e);return"number"==typeof t?Ft(t):t?(e=>{if(xs.test(e))throw new RangeError(Bo(e));if(_s.test(e))throw new RangeError(Zo);return e.toLowerCase().split("/").map((e,t)=>(e.length<=3||/\d/.test(e))&&!/etc|yap/.test(e)?e.toUpperCase():e.replace(/baja|dumont|[a-z]+/g,(e,n)=>e.length<=2&&!t||"in"===e||"chat"===e?e.toUpperCase():e.length>2||!n?w(e).replace(/island|noronha|murdo|rivadavia|urville/,w):e)).join("/")})(e):ns}function qn(e){const t=zn(e);return"number"==typeof t?t:t?t.resolvedOptions().timeZone:ns}function zn(e){const t=An(e=e.toUpperCase(),1);return void 0!==t?t:e!==ns?Ts(e):void 0}function Vn(e,t){return G(e.epochNanoseconds,t.epochNanoseconds)}function Jn(e,t){return G(e.epochNanoseconds,t.epochNanoseconds)}function Gn(e,t){return Kn(e,t)||Xn(e,t)}function Kn(e,t){return E(ue(e),ue(t))}function Xn(e,t){return E(ae(e),ae(t))}function Qn(e,t){if(e===t)return 1;try{return qn(e)===qn(t)}catch(e){}}function er(e,t,n,r){const o=Ne(e,r,3,5),i=fr(t.epochNanoseconds,n.epochNanoseconds,...o);return nt(e?gn(i):i)}function tr(e,t,n,r,o,i){const a=gr(r.calendar,o.calendar),[s,c,u,l]=Ne(n,i,5),f=r.epochNanoseconds,d=o.epochNanoseconds,h=G(d,f);let m;if(h)if(s<6)m=fr(f,d,s,c,u,l);else{const n=t(((e,t)=>{if(!Qn(e,t))throw new RangeError(Uo);return e})(r.timeZone,o.timeZone)),f=e(a);m=ur(f,n,r,o,h,s,i),m=gt(m,d,s,c,u,l,f,r,ot,b(tn,n))}else m=Xi;return nt(n?gn(m):m)}function nr(e,t,n,r,o){const i=gr(n.calendar,r.calendar),[a,s,c,u]=Ne(t,o,6),l=le(n),f=le(r),d=G(f,l);let h;if(d)if(a<=6)h=fr(l,f,a,s,c,u);else{const t=e(i);h=lr(t,n,r,d,a,o),h=gt(h,f,a,s,c,u,t,n,le,nn)}else h=Xi;return nt(t?gn(h):h)}function rr(e,t,n,r,o){const i=gr(n.calendar,r.calendar);return ir(t,()=>e(i),n,r,...Ne(t,o,6,9,6))}function or(e,t,n,r,o){const i=gr(n.calendar,r.calendar),a=Ne(t,o,9,9,8),s=e(i),c=on(s,n),u=on(s,r);return c.isoYear===u.isoYear&&c.isoMonth===u.isoMonth&&c.isoDay===u.isoDay?nt(Xi):ir(t,()=>s,re(c),re(u),...a,8)}function ir(e,t,n,r,o,i,a,s,c=6){const u=le(n),l=le(r);if(void 0===u||void 0===l)throw new RangeError(Vo);let f;if(G(l,u))if(6===o)f=fr(u,l,o,i,a,s);else{const e=t();f=e.N(n,r,o),i===c&&1===a||(f=gt(f,l,o,i,a,s,e,n,le,rn))}else f=Xi;return nt(e?gn(f):f)}function ar(e,t,n,r){const[o,i,a,s]=Ne(e,r,5,5),c=yt(pr(t,n),dt(i,a),s),u={...Xi,...Mn(c,o)};return nt(e?gn(u):u)}function sr(e,t,n,r,o,i){const a=G(r.epochNanoseconds,n.epochNanoseconds);return a?o<6?dr(n.epochNanoseconds,r.epochNanoseconds,o):ur(t,e,n,r,a,o,i):Xi}function cr(e,t,n,r,o){const i=le(t),a=le(n),s=G(a,i);return s?r<=6?dr(i,a,r):lr(e,t,n,s,r,o):Xi}function ur(e,t,n,r,o,i,a){const[s,c,u]=((e,t,n,r)=>{function o(){return f={...sn(s,u++*-r),...a},d=zt(e,f),G(c,d)===-r}const i=ss(t,e),a=h(ta,i),s=ss(n,e),c=n.epochNanoseconds;let u=0;const l=pr(i,s);let f,d;if(Math.sign(l)===-r&&u++,o()&&(-1===r||o()))throw new RangeError(Lo);const m=ee(J(d,c));return[i,f,m]})(t,n,r,o);var l,f;return{...6===i?(l=s,f=c,{...Xi,days:hr(l,f)}):e.N(s,c,i,a),...Mn(u)}}function lr(e,t,n,r,o,i){const[a,s,c]=((e,t,n)=>{let r=t,o=pr(e,t);return Math.sign(o)===-n&&(r=sn(t,-n),o+=bi*n),[e,r,o]})(t,n,r);return{...e.N(a,s,o,i),...Mn(c)}}function fr(e,t,n,r,o,i){return{...Xi,...En(bt(J(e,t),r,o,i),n)}}function dr(e,t,n){return{...Xi,...En(J(e,t),n)}}function hr(e,t){return mr(ue(e),ue(t))}function mr(e,t){return Math.trunc((t-e)/li)}function pr(e,t){return ae(t)-ae(e)}function gr(e,t){if(e!==t)throw new RangeError(Ho);return e}function br(e){return this.m(e)[0]}function wr(e){return this.m(e)[1]}function yr(e){const[t]=this.v(e);return mr(this.p(t),ue(e))+1}function vr(e){const t=Os.exec(e);if(!t)throw new RangeError(No(e));return[parseInt(t[1]),Boolean(t[2])]}function Er(e,t){return"M"+si(e)+(t?"L":"")}function Mr(e,t,n){return e+(t||n&&e>=n?1:0)}function Ir(e,t){return e-(t&&e>=t?1:0)}function Dr(e,t){return(t+e)*(Math.sign(t)||1)||0}function Sr(e){return Hi[Tr(e)]}function kr(e){return Ui[Tr(e)]}function Tr(e){return Wr(e.id||Ai)}function _r(e){function t(e){return((e,t)=>({...jr(e,t),o:e.month,day:parseInt(e.day)}))(be(n,e),r)}const n=Cs(e),r=Wr(e);return{id:e,h:xr(t),l:Or(t)}}function xr(e){return o(t=>{const n=ue(t);return e(n)},WeakMap)}function Or(e){const t=e(0).year-ba;return o(n=>{let r,o=he(n-t),i=0;const a=[],s=[];do{o+=400*li}while((r=e(o)).year<=n);do{if(o+=(1-r.day)*li,r.year===n&&(a.push(o),s.push(r.o)),o-=li,++i>100||o<-la)throw new RangeError(Lo)}while((r=e(o)).year>=n);return{i:a.reverse(),u:ii(s.reverse())}})}function jr(e,t){let n,r,o=Cr(e);if(e.era){const i=Hi[t],a=Bi[t]||{};void 0!==i&&(n="islamic"===t?"ah":e.era.normalize("NFD").toLowerCase().replace(/[^a-z0-9]/g,""),"bc"===n||"b"===n?n="bce":"ad"===n||"a"===n?n="ce":"beforeroc"===n&&(n="broc"),n=a[n]||n,r=o,o=Dr(r,i[n]||0))}return{era:n,eraYear:r,year:o}}function Cr(e){return parseInt(e.relatedYear||e.year)}function Rr(e){const{year:t,o:n,day:r}=this.h(e),{u:o}=this.l(t);return[t,o[n]+1,r]}function Nr(e,t=1,n=1){return this.l(e).i[t-1]+(n-1)*li}function Pr(e,t){const n=Yr.call(this,e);return[Ir(t,n),n===t]}function Yr(e){const t=Br(this,e),n=Br(this,e-1),r=t.length;if(r>n.length){const e=kr(this);if(e<0)return-e;for(let e=0;e<r;e++)if(t[e]!==n[e])return e+1}}function Ar(e){return mr(Nr.call(this,e),Nr.call(this,e+1))}function Lr(e,t){const{i:n}=this.l(e);let r=t+1,o=n;return r>n.length&&(r=1,o=this.l(e+1).i),mr(n[t-1],o[r-1])}function Fr(e){return this.l(e).i.length}function Hr(e){const t=this.h(e);return[t.era,t.eraYear]}function Br(e,t){return Object.keys(e.l(t).u)}function Ur(e){return Zr(Zi(e))}function Zr(e){if((e=e.toLowerCase())!==Ai&&e!==Li){const t=Cs(e).resolvedOptions().calendar;if(Wr(e)!==Wr(t))throw new RangeError(Fo(e));return t}return e}function Wr(e){return"islamicc"===e&&(e="islamic"),e.split("-")[0]}function $r(e,t){return n=>n===Ai?e:n===Li||n===Fi?Object.assign(Object.create(e),{id:n}):Object.assign(Object.create(t),js(n))}function qr(e,t,n,r){const o=zr(n,r,Ri,[],Di);if(void 0!==o.timeZone){const r=n.F(o),i=Jr(o),a=e(o.timeZone);return{epochNanoseconds:qt(t(a),{...r,...i},void 0!==o.offset?Tn(o.offset):void 0),timeZone:a}}return{...n.F(o),...sa}}function zr(e,t,n,r=[],o=[]){return Vr(t,[...e.fields(n),...o].sort(),r)}function Vr(e,t,n,r=!n){const o={};let i,a=0;for(const r of t){if(r===i)throw new RangeError(So(r));if("constructor"===r||"__proto__"===r)throw new RangeError(Do(r));let t=e[r];if(void 0!==t)a=1,Zs[r]&&(t=Zs[r](t,r)),o[r]=t;else if(n){if(n.includes(r))throw new TypeError(Io(r));o[r]=Yi[r]}i=r}if(r&&!a)throw new TypeError(ko(t));return o}function Jr(e,t){return je(Ws({...Yi,...e}),t)}function Gr(e,t,n,r,o){t=h(n=e.fields(n),t),r=Vr(r,o=e.fields(o),[]);let i=e.k(t,r);return i=Vr(i,[...n,...o].sort(),[]),e.F(i)}function Kr(e,t){const n=Sr(e),r=Bi[e.id||""]||{};let{era:o,eraYear:i,year:a}=t;if(void 0!==o||void 0!==i){if(void 0===o||void 0===i)throw new TypeError(Oo);if(!n)throw new RangeError(xo);const e=n[r[o]||o];if(void 0===e)throw new RangeError(Co(o));const t=Dr(i,e);if(void 0!==a&&a!==t)throw new RangeError(jo);a=t}else if(void 0===a)throw new TypeError(Ro(n));return a}function Xr(e,t,r,o){let{month:i,monthCode:a}=t;if(void 0!==a){const t=((e,t,n,r)=>{const o=e.L(n),[i,a]=vr(t);let s=Mr(i,a,o);if(a){const t=kr(e);if(void 0===t)throw new RangeError(Ao);if(t>0){if(s>t)throw new RangeError(Ao);if(void 0===o){if(1===r)throw new RangeError(Ao);s--}}else{if(s!==-t)throw new RangeError(Ao);if(void 0===o&&1===r)throw new RangeError(Ao)}}return s})(e,a,r,o);if(void 0!==i&&i!==t)throw new RangeError(Po);i=t,o=1}else if(void 0===i)throw new TypeError(Yo);return n("month",i,1,e.B(r),o)}function Qr(e,n,r,o,i){return t(n,"day",1,e.U(o,r),i)}function eo(e,t,n,r){let o=0;const i=[];for(const e of n)void 0!==t[e]?o=1:i.push(e);if(Object.assign(e,t),o)for(const t of r||i)delete e[t]}function to(e){const t=Bs(e.calendar),[n,r,o]=t.v(e),[i,a]=t.q(n,r);return{year:n,monthCode:Er(i,a),day:o}}function no(e,t){return Ke(ss(t,e))}function ro(e,t){return Xe(ss(t,e))}function oo(e,t){return tt(ss(t,e))}function io(e,t,n){const r=new Set(n);return(o,i)=>{const a=n&&m(o,n);if(!m(o=((e,t)=>{const n={};for(const r in t)e.has(r)||(n[r]=t[r]);return n})(r,o),e)){if(i&&a)throw new TypeError("Invalid formatting options");o={...t,...o}}return n&&(o.timeZone=ns,["full","long"].includes(o.J)&&(o.J="medium")),o}}function ao(e,t=so,n=0){const[r,,,o]=e;return(i,a=Ec,...s)=>{const c=t(o&&o(...s),i,a,r,n),u=c.resolvedOptions();return[c,...co(e,u,s)]}}function so(e,t,n,r,o){if(n=r(n,o),e){if(void 0!==n.timeZone)throw new TypeError(oi);n.timeZone=e}return new pa(t,n)}function co(e,t,n){const[,r,o]=e;return n.map(e=>(e.calendar&&((e,t,n)=>{if((n||e!==Ai)&&e!==t)throw new RangeError(Ho)})(e.calendar,t.calendar,o),r(e,t)))}function uo(e,t){return{...e,calendar:t}}function lo(e){const t=fo();return pe(t,e.R(t))}function fo(){return Q(Date.now(),hi)}function ho(){return Oc||(Oc=(new pa).resolvedOptions().timeZone)}const mo=(e,t)=>`Non-integer ${e}: ${t}`,po=(e,t)=>`Non-positive ${e}: ${t}`,go=(e,t)=>`Non-finite ${e}: ${t}`,bo=e=>`Cannot convert bigint to ${e}`,wo=e=>`Invalid bigint: ${e}`,yo="Cannot convert Symbol to string",vo="Invalid object",Eo=(e,t,n,r,o)=>o?Eo(e,o[t],o[n],o[r]):Mo(e,t)+`; must be between ${n}-${r}`,Mo=(e,t)=>`Invalid ${e}: ${t}`,Io=e=>`Missing ${e}`,Do=e=>`Invalid field ${e}`,So=e=>`Duplicate field ${e}`,ko=e=>"No valid fields: "+e.join(),To=(e,t,n)=>Mo(e,t)+"; must be "+Object.keys(n).join(),_o="Invalid calling context",xo="Forbidden era/eraYear",Oo="Mismatching era/eraYear",jo="Mismatching year/eraYear",Co=e=>`Invalid era: ${e}`,Ro=e=>"Missing year"+(e?"/era/eraYear":""),No=e=>`Invalid monthCode: ${e}`,Po="Mismatching month/monthCode",Yo="Missing month/monthCode",Ao="Invalid leap month",Lo="Invalid protocol results",Fo=e=>Mo("Calendar",e),Ho="Mismatching Calendars",Bo=e=>Mo("TimeZone",e),Uo="Mismatching TimeZones",Zo="Forbidden ICU TimeZone",Wo="Out-of-bounds offset",$o="Out-of-bounds TimeZone gap",qo="Invalid TimeZone offset",zo="Ambiguous offset",Vo="Out-of-bounds date",Jo="Out-of-bounds duration",Go="Cannot mix duration signs",Ko="Missing relativeTo",Xo="Cannot use large units",Qo="Required smallestUnit or largestUnit",ei="smallestUnit > largestUnit",ti=e=>`Cannot parse: ${e}`,ni=e=>`Invalid substring: ${e}`,ri="Mismatching types for formatting",oi="Cannot specify TimeZone",ii=b(f,(e,t)=>t),ai=b(f,(e,t,n)=>n),si=b(v,2),ci={nanosecond:0,microsecond:1,millisecond:2,second:3,minute:4,hour:5,day:6,week:7,month:8,year:9},ui=Object.keys(ci),li=864e5,fi=1e3,di=1e3,hi=1e6,mi=1e9,pi=6e10,gi=36e11,bi=864e11,wi=[1,di,hi,mi,pi,gi,bi],yi=ui.slice(0,6),vi=y(yi),Ei=["offset"],Mi=["timeZone"],Ii=yi.concat(Ei),Di=Ii.concat(Mi),Si=["era","eraYear"],ki=Si.concat(["year"]),Ti=["year"],_i=["monthCode"],xi=["month"].concat(_i),Oi=["day"],ji=xi.concat(Ti),Ci=_i.concat(Ti),Ri=Oi.concat(ji),Ni=Oi.concat(xi),Pi=Oi.concat(_i),Yi=ai(yi,0),Ai="iso8601",Li="gregory",Fi="japanese",Hi={[Li]:{"gregory-inverse":-1,gregory:0},[Fi]:{"japanese-inverse":-1,japanese:0,meiji:1867,taisho:1911,showa:1925,heisei:1988,reiwa:2018},ethiopic:{ethioaa:0,ethiopic:5500},coptic:{"coptic-inverse":-1,coptic:0},roc:{"roc-inverse":-1,roc:0},buddhist:{be:0},islamic:{ah:0},indian:{saka:0},persian:{ap:0}},Bi={[Li]:{bce:"gregory-inverse",ce:"gregory"},[Fi]:{bce:"japanese-inverse",ce:"japanese"},ethiopic:{era0:"ethioaa",era1:"ethiopic"},coptic:{era0:"coptic-inverse",era1:"coptic"},roc:{broc:"roc-inverse",minguo:"roc"}},Ui={chinese:13,dangi:13,hebrew:-6},Zi=b(Y,"string"),Wi=b(Y,"boolean"),$i=b(Y,"number"),qi=ui.map(e=>e+"s"),zi=y(qi),Vi=qi.slice(0,6),Ji=qi.slice(6),Gi=Ji.slice(1),Ki=ii(qi),Xi=ai(qi,0),Qi=ai(Vi,0),ea=b(g,qi),ta=["isoNanosecond","isoMicrosecond","isoMillisecond","isoSecond","isoMinute","isoHour"],na=["isoDay","isoMonth","isoYear"],ra=ta.concat(na),oa=y(na),ia=y(ta),aa=y(ra),sa=ai(ia,0),ca=b(g,ra),ua=1e8,la=ua*li,fa=[ua,0],da=[-ua,0],ha=275760,ma=-271821,pa=Intl.DateTimeFormat,ga="en-GB",ba=1970,wa=1972,ya=12,va=he(1868,9,8),Ea=o(ke,WeakMap),Ma="smallestUnit",Ia="unit",Da="roundingIncrement",Sa="fractionalSecondDigits",ka="relativeTo",Ta="direction",_a={constrain:0,reject:1},xa=Object.keys(_a),Oa={compatible:0,reject:1,earlier:2,later:3},ja={reject:0,use:1,prefer:2,ignore:3},Ca={auto:0,never:1,critical:2,always:3},Ra={auto:0,never:1,critical:2},Na={auto:0,never:1},Pa={floor:0,halfFloor:1,ceil:2,halfCeil:3,trunc:4,halfTrunc:5,expand:6,halfExpand:7,halfEven:8},Ya={previous:-1,next:1},Aa=b(qe,Ma),La=b(qe,"largestUnit"),Fa=b(qe,Ia),Ha=b(ze,"overflow",_a),Ba=b(ze,"disambiguation",Oa),Ua=b(ze,"offset",ja),Za=b(ze,"calendarName",Ca),Wa=b(ze,"timeZoneName",Ra),$a=b(ze,"offset",Na),qa=b(ze,"roundingMode",Pa),za="PlainYearMonth",Va="PlainMonthDay",Ja="PlainDate",Ga="PlainDateTime",Ka="PlainTime",Xa="ZonedDateTime",Qa="Instant",es="Duration",ts=[Math.floor,e=>_(e)?Math.floor(e):Math.round(e),Math.ceil,e=>_(e)?Math.ceil(e):Math.round(e),Math.trunc,e=>_(e)?Math.trunc(e)||0:Math.round(e),e=>e<0?Math.floor(e):Math.ceil(e),e=>Math.sign(e)*Math.round(Math.abs(e))||0,e=>_(e)?(e=Math.trunc(e)||0)+e%2:Math.round(e)],ns="UTC",rs=5184e3,os=de(1847),is=de((new Date).getUTCFullYear()+10),as=/0+$/,ss=o($t,WeakMap),cs=2**32-1,us=o(e=>{const t=zn(e);return"object"==typeof t?new fs(t):new ls(t||0)});class ls{constructor(e){this.$=e}R(){return this.$}I(e){return(e=>{const t=le({...e,...sa});if(!t||Math.abs(t[0])>1e8)throw new RangeError(Vo)})(e),[fe(e,this.$)]}O(){}}class fs{constructor(e){this.nn=(e=>{function t(e){const t=M(e,a,s),[o,c]=kn(t),u=r(o),l=r(c);return u===l?u:n(i(o,c),u,l,e)}function n(t,n,r,o){let i,a;for(;(void 0===o||void 0===(i=o<t[0]?n:o>=t[1]?r:void 0))&&(a=t[1]-t[0]);){const n=t[0]+Math.floor(a/2);e(n)===r?t[1]=n:t[0]=n+1}return i}const r=o(e),i=o(Sn);let a=os,s=is;return{tn(e){const n=t(e-86400),r=t(e+86400),o=e-n,i=e-r;if(n===r)return[o];const a=t(o);return a===t(i)?[e-a]:n>r?[o,i]:[]},rn:t,O(e,t){const o=M(e,a,s);let[c,u]=kn(o);const l=rs*t,f=t<0?()=>u>a||(a=o,0):()=>c<s||(s=o,0);for(;f();){const o=r(c),a=r(u);if(o!==a){const r=i(c,u);n(r,o,a);const s=r[0];if((E(s,e)||1)===t)return s}c+=l,u+=l}}}})((e=>t=>{const n=be(e,t*fi);return de(Cr(n),parseInt(n.month),parseInt(n.day),parseInt(n.hour),parseInt(n.minute),parseInt(n.second))-t})(e))}R(e){return this.nn.rn((e=>ce(e)[0])(e))*mi}I(e){const[t,n]=[de((r=e).isoYear,r.isoMonth,r.isoDay,r.isoHour,r.isoMinute,r.isoSecond),r.isoMillisecond*hi+r.isoMicrosecond*di+r.isoNanosecond];var r;return this.nn.tn(t).map(e=>ie(V(Q(e,mi),n)))}O(e,t){const[n,r]=ce(e),o=this.nn.O(n+(t>0||r?1:0),t);if(void 0!==o)return Q(o,mi)}}const ds="([+-])",hs="(?:[.,](\\d{1,9}))?",ms=`(?:(?:${ds}(\\d{6}))|(\\d{4}))-?(\\d{2})`,ps="(\\d{2})(?::?(\\d{2})(?::?(\\d{2})"+hs+")?)?",gs=ds+ps,bs=ms+"-?(\\d{2})(?:[T ]"+ps+"(Z|"+gs+")?)?",ws="\\[(!?)([^\\]]*)\\]",ys=`((?:${ws}){0,9})`,vs=Un(ms+ys),Es=Un("(?:--)?(\\d{2})-?(\\d{2})"+ys),Ms=Un(bs+ys),Is=Un("T?"+ps+"(?:"+gs+")?"+ys),Ds=Un(gs),Ss=new RegExp(ws,"g"),ks=Un(`${ds}?P(\\d+Y)?(\\d+M)?(\\d+W)?(\\d+D)?(?:T(?:(\\d+)${hs}H)?(?:(\\d+)${hs}M)?(?:(\\d+)${hs}S)?)?`),Ts=o(e=>new pa(ga,{timeZone:e,era:"short",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"})),_s=/^(AC|AE|AG|AR|AS|BE|BS|CA|CN|CS|CT|EA|EC|IE|IS|JS|MI|NE|NS|PL|PN|PR|PS|SS|VS)T$/,xs=/[^\w\/:+-]+/,Os=/^M(\d{2})(L?)$/,js=o(_r),Cs=o(e=>new pa(ga,{calendar:e,timeZone:ns,era:"short",year:"numeric",month:"short",day:"numeric"})),Rs={P(e,t,r){const o=Ce(r);let i,{years:a,months:s,weeks:c,days:u}=t;if(u+=vn(t,5)[0],a||s)i=((e,t,r,o,i)=>{let[a,s,c]=e.v(t);if(r){const[t,o]=e.q(a,s);a+=r,s=Mr(t,o,e.L(a)),s=n("month",s,1,e.B(a),i)}return o&&([a,s]=e.un(a,s,o)),c=n("day",c,1,e.U(a,s),i),e.p(a,s,c)})(this,e,a,s,o);else{if(!c&&!u)return e;i=ue(e)}if(void 0===i)throw new RangeError(Vo);return i+=(7*c+u)*li,re(ge(i))},N(e,t,n){if(n<=7){let r=0,o=hr({...e,...sa},{...t,...sa});return 7===n&&([r,o]=S(o,7)),{...Xi,weeks:r,days:o}}const r=this.v(e),o=this.v(t);let[i,a,s]=((e,t,n,r,o,i,a)=>{let s=o-t,c=i-n,u=a-r;if(s||c){const l=Math.sign(s||c);let f=e.U(o,i),d=0;if(Math.sign(u)===-l){const r=f;[o,i]=e.un(o,i,-l),s=o-t,c=i-n,f=e.U(o,i),d=l<0?-r:f}if(u=a-Math.min(r,f)+d,s){const[r,a]=e.q(t,n),[u,f]=e.q(o,i);if(c=u-r||Number(f)-Number(a),Math.sign(c)===-l){const n=l<0&&-e.B(o);s=(o-=l)-t,c=i-Mr(r,a,e.L(o))+(n||e.B(o))}}}return[s,c,u]})(this,...r,...o);return 8===n&&(a+=this.cn(i,r[0]),i=0),{...Xi,years:i,months:a,days:s}},F(e,t){const n=Ce(t),r=Kr(this,e),o=Xr(this,e,r,n),i=Qr(this,e,o,r,n);return Xe(re(this.V(r,o,i)),this.id||Ai)},K(e,t){const n=Ce(t),r=Kr(this,e),o=Xr(this,e,r,n);return Qe(ne(this.V(r,o,1)),this.id||Ai)},_(e,t){const n=Ce(t);let r,o,i,a=void 0!==e.eraYear||void 0!==e.year?Kr(this,e):void 0;const s=!this.id;if(void 0===a&&s&&(a=wa),void 0!==a){const t=Xr(this,e,a,n);r=Qr(this,e,t,a,n);const s=this.L(a);o=Ir(t,s),i=t===s}else{if(void 0===e.monthCode)throw new TypeError(Yo);if([o,i]=vr(e.monthCode),this.id&&this.id!==Li&&this.id!==Fi)if(this.id&&"coptic"===Wr(this.id)&&0===n){const t=i||13!==o?30:6;r=e.day,r=M(r,1,t)}else if(this.id&&"chinese"===Wr(this.id)&&0===n){const t=!i||1!==o&&9!==o&&10!==o&&11!==o&&12!==o?30:29;r=e.day,r=M(r,1,t)}else r=e.day;else r=Qr(this,e,Xr(this,e,wa,n),wa,n)}const c=this.G(o,i,r);if(!c)throw new RangeError("Cannot guess year");const[u,l]=c;return et(re(this.V(u,l,r)),this.id||Ai)},fields(e){return Sr(this)&&e.includes("year")?[...e,...Si]:e},k(e,t){const n=Object.assign(Object.create(null),e);return eo(n,t,xi),Sr(this)&&(eo(n,t,ki),this.id===Fi&&eo(n,t,Ni,Si)),n},inLeapYear(e){const[t]=this.v(e);return this.sn(t)},monthsInYear(e){const[t]=this.v(e);return this.B(t)},daysInMonth(e){const[t,n]=this.v(e);return this.U(t,n)},daysInYear(e){const[t]=this.v(e);return this.fn(t)},dayOfYear:yr,era(e){return this.hn(e)[0]},eraYear(e){return this.hn(e)[1]},monthCode(e){const[t,n]=this.v(e),[r,o]=this.q(t,n);return Er(r,o)},dayOfWeek:De,daysInWeek:()=>7},Ns={v:we,hn:Se,q:ye},Ps={dayOfYear:yr,v:we,p:he},Ys=Object.assign({},Ps,{weekOfYear:br,yearOfWeek:wr,m(e){function t(e){return(7-e<r?7:0)-e}function n(e){const n=Me(d+e),r=e||1,o=t(D(c+n*r,7));return l=(n+(o-u)*r)/7}const r=this.id?1:4,o=De(e),i=this.dayOfYear(e),a=D(o-1,7),s=i-1,c=D(a-s,7),u=t(c);let l,f=Math.floor((s-u)/7)+1,d=e.isoYear;return f?f>n(0)&&(f=1,d++):(f=n(-1),d--),[f,d,l]}}),As=Object.assign({},Rs,Ys,{v:we,hn:Se,q:ye,G(e,t){if(!t)return[wa,e]},sn:Ie,L(){},B:ve,cn:e=>e*ya,U:Ee,fn:Me,V:(e,t,n)=>({isoYear:e,isoMonth:t,isoDay:n}),p:he,un:(e,t,n)=>(e+=k(n,ya),(t+=T(n,ya))<1?(e--,t+=ya):t>ya&&(e++,t-=ya),[e,t]),year:e=>e.isoYear,month:e=>e.isoMonth,day:e=>e.isoDay}),Ls={v:Rr,hn:Hr,q:Pr},Fs={dayOfYear:yr,v:Rr,p:Nr,weekOfYear:br,yearOfWeek:wr,m:()=>[]},Hs=Object.assign({},Rs,Fs,{v:Rr,hn:Hr,q:Pr,G(e,t,n){const r=this.id&&"chinese"===Wr(this.id)?((e,t,n)=>{if(t)switch(e){case 1:return 1651;case 2:return n<30?1947:1765;case 3:return n<30?1966:1955;case 4:return n<30?1963:1944;case 5:return n<30?1971:1952;case 6:return n<30?1960:1941;case 7:return n<30?1968:1938;case 8:return n<30?1957:1718;case 9:return 1832;case 10:return 1870;case 11:return 1814;case 12:return 1890}return 1972})(e,t,n):wa;let[o,i,a]=Rr.call(this,{isoYear:r,isoMonth:ya,isoDay:31});const s=Yr.call(this,o),c=i===s;1===(E(e,Ir(i,s))||E(Number(t),Number(c))||E(n,a))&&o--;for(let r=0;r<100;r++){const i=o-r,a=Yr.call(this,i),s=Mr(e,t,a);if(t===(s===a)&&n<=Lr.call(this,i,s))return[i,s]}},sn(e){const t=Ar.call(this,e);return t>Ar.call(this,e-1)&&t>Ar.call(this,e+1)},L:Yr,B:Fr,cn(e,t){const n=t+e,r=Math.sign(e),o=r<0?-1:0;let i=0;for(let e=t;e!==n;e+=r)i+=Fr.call(this,e+o);return i},U:Lr,fn:Ar,V(e,t,n){return ge(Nr.call(this,e,t,n))},p:Nr,un(e,t,n){if(n){if(t+=n,!Number.isSafeInteger(t))throw new RangeError(Vo);if(n<0)for(;t<1;)t+=Fr.call(this,--e);else{let n;for(;t>(n=Fr.call(this,e));)t-=n,e++}}return[e,t]},year(e){return this.h(e).year},month(e){const{year:t,o:n}=this.h(e),{u:r}=this.l(t);return r[n]+1},day(e){return this.h(e).day}}),Bs=$r(Ns,Ls),Us=$r(As,Hs),Zs={...{era:H,eraYear:Z,year:Z,month:$,monthCode(e){const t=H(e);return vr(t),t},day:$},...ai(yi,Z),...ai(qi,W),offset(e){const t=H(e);return Tn(t),t}},Ws=b(d,yi,ta),$s=b(d,ta,yi),qs="numeric",zs=["timeZoneName"],Vs={month:qs,day:qs},Js={year:qs,month:qs},Gs=Object.assign({},Js,{day:qs}),Ks={hour:qs,minute:qs,second:qs},Xs=Object.assign({},Gs,Ks),Qs=Object.assign({},Xs,{timeZoneName:"short"}),ec=Object.keys(Js),tc=Object.keys(Vs),nc=Object.keys(Gs),rc=Object.keys(Ks),oc=["dateStyle"],ic=ec.concat(oc),ac=tc.concat(oc),sc=nc.concat(oc,["weekday"]),cc=rc.concat(["dayPeriod","timeStyle","fractionalSecondDigits"]),uc=sc.concat(cc),lc=zs.concat(cc),fc=zs.concat(sc),dc=zs.concat(["day","weekday"],cc),hc=zs.concat(["year","weekday"],cc),mc=io(uc,Xs),pc=io(uc,Qs),gc=io(uc,Xs,zs),bc=io(sc,Gs,lc),wc=io(cc,Ks,fc),yc=io(ic,Js,dc),vc=io(ac,Vs,hc),Ec={},Mc=new pa(void 0,{calendar:Ai}).resolvedOptions().calendar===Ai,Ic=[mc,rt],Dc=[pc,rt,0,(e,t)=>{const n=e.timeZone;if(t&&t.timeZone!==n)throw new RangeError(Uo);return n}],Sc=[gc,ue],kc=[bc,ue],Tc=[wc,e=>ae(e)/hi],_c=[yc,ue,Mc],xc=[vc,ue,Mc];let Oc;function jc(e,t,n,r,o){function u(...e){if(!(this instanceof u))throw new TypeError(_o);ru(this,t(...e))}function f(e,t){return Object.defineProperties(function(...t){return e.call(this,d(this),...t)},i(t))}function d(t){const n=nu(t);if(!n||n.branding!==e)throw new TypeError(_o);return n}return Object.defineProperties(u.prototype,{...s(l(f,n)),...a(l(f,r)),...c("Temporal."+e)}),Object.defineProperties(u,{...a(o),...i(e)}),[u,e=>{const t=Object.create(u.prototype);return ru(t,e),t},d]}function Cc(e){if(nu(e)||void 0!==e.calendar||void 0!==e.timeZone)throw new TypeError("Invalid bag");return e}function Rc(e){return Nc(e)||Ai}function Nc(e){const{calendar:t}=e;if(void 0!==t)return Pc(t)}function Pc(e){if(r(e)){const{calendar:t}=nu(e)||{};if(!t)throw new TypeError(Fo(e));return t}return(e=>Zr(function(e){const t=Nn(e)||Pn(e)||Yn(e);return t?t.calendar:e}(Zi(e))))(e)}function Yc(e){const t={};for(const n in e)t[n]=e=>{const{calendar:t}=e;return Us(t)[n](e)};return t}function Ac(){throw new TypeError("Cannot use valueOf")}function Lc(e){if(r(e)){const{timeZone:t}=nu(e)||{};if(!t)throw new TypeError(Bo(e));return t}return(e=>$n(function(e){const t=Nn(e);return t&&(t.timeZone||t.j&&ns||t.offset)||e}(Zi(e))))(e)}function Fc(e){if(r(e)){const t=nu(e);return t&&t.branding===es?t:function(e){const t=Vr(e,zi);return nt(wn({...Xi,...t}))}(e)}return function(e){const t=(e=>{const t=ks.exec(e);return t?(e=>{function t(e,t,i){let a=0,s=0;if(i&&([a,o]=I(o,wi[i])),void 0!==e){if(r)throw new RangeError(ni(e));s=(e=>{const t=parseInt(e);if(!Number.isFinite(t))throw new RangeError(ni(e));return t})(e),n=1,t&&(o=Bn(t)*(wi[i]/mi),r=1)}return a+s}let n=0,r=0,o=0,i={...u(qi,[t(e[2]),t(e[3]),t(e[4]),t(e[5]),t(e[6],e[7],5),t(e[8],e[9],4),t(e[10],e[11],3)]),...O(o,2,qi)};if(!n)throw new RangeError(ko(qi));return Zn(e[1])<0&&(i=gn(i)),i})(t):void 0})(Zi(e));if(!t)throw new RangeError(ti(e));return nt(wn(t))}(e)}function Hc(e){if(void 0!==e){if(r(e)){const t=nu(e)||{};switch(t.branding){case Xa:case Ja:return t;case Ga:return Xe(t)}const n=Rc(e);return{...qr(Lc,us,Us(n),e),calendar:n}}return function(e){const t=Nn(Zi(e));if(!t)throw new RangeError(ti(e));if(t.timeZone)return On(t,t.offset?Tn(t.offset):void 0);if(t.j)throw new RangeError(ti(e));return Cn(t)}(e)}}function Bc(e,t){if(r(e)){const n=nu(e)||{};switch(n.branding){case Ka:return Ce(t),n;case Ga:return Ce(t),tt(n);case Xa:return Ce(t),oo(us,n)}return function(e,t){return tt(Jr(Vr(e,vi,[],1),Ce(t)))}(e,t)}const n=function(e){let t,n=(e=>{const t=Is.exec(e);return t?(Hn(t[10]),Fn(t)):void 0})(Zi(e));if(!n){if(n=Nn(e),!n)throw new RangeError(ti(e));if(!n.C)throw new RangeError(ti(e));if(n.j)throw new RangeError(ni("Z"));xn(n)}if((t=Pn(e))&&xe(t))throw new RangeError(ti(e));if((t=Yn(e))&&xe(t))throw new RangeError(ti(e));return tt(je(n,1))}(e);return Ce(t),n}function Uc(e){return void 0===e?void 0:Bc(e)}function Zc(e,t){if(r(e)){const n=nu(e)||{};switch(n.branding){case Ga:return Ce(t),n;case Ja:return Ce(t),Ke({...n,...sa});case Xa:return Ce(t),no(us,n)}return function(e,t,n){const r=zr(e,t,Ri,[],yi),o=Ce(n);return Ke(oe({...e.F(r,$e(o)),...Jr(r,o)}))}(Us(Rc(e)),e,t)}const n=function(e){const t=Nn(Zi(e));if(!t||t.j)throw new RangeError(ti(e));return Ke(jn(t))}(e);return Ce(t),n}function Wc(e,t){if(r(e)){const n=nu(e);if(n&&n.branding===Va)return Ce(t),n;const r=Nc(e);return function(e,t,n,r){const o=zr(e,n,Ri,Oi);return t&&void 0!==o.month&&void 0===o.monthCode&&void 0===o.year&&(o.year=wa),e._(o,r)}(Us(r||Ai),!r,e,t)}const n=function(e,t){const n=Yn(Zi(t));if(n)return xn(n),et(_e(n));const r=_n(t,0,1),{calendar:o}=r,i=e(o),[a,s,c]=i.v(r),[u,l]=i.q(a,s),[f,d]=i.G(u,l,c);return et(re(i.V(f,d,c)),o)}(Us,e);return Ce(t),n}function $c(e,t){if(r(e)){const n=nu(e);return n&&n.branding===za?(Ce(t),n):function(e,t,n,r){const o=zr(e,t,ji,r);return e.K(o,n)}(Us(Rc(e)),e,t)}const n=function(e,t){const n=Pn(Zi(t));if(n)return xn(n),Qe(ne(_e(n)));const r=_n(t,1);return Qe(on(e(r.calendar),r))}(Us,e);return Ce(t),n}function qc(e,t){if(r(e)){const n=nu(e)||{};switch(n.branding){case Ja:return Ce(t),n;case Ga:return Ce(t),Xe(n);case Xa:return Ce(t),ro(us,n)}return function(e,t,n,r=[]){const o=zr(e,t,Ri,r);return e.F(o,n)}(Us(Rc(e)),e,t)}const n=_n(e);return Ce(t),n}function zc(e,t){if(r(e)){const n=nu(e);if(n&&n.branding===Xa)return Re(t),n;const r=Rc(e);return function(e,t,n,r,o,i){const a=zr(n,o,Ri,Mi,Di),s=e(a.timeZone),[c,u,l]=Re(i),f=n.F(a,$e(c)),d=Jr(a,c);return Ge(qt(t(s),{...f,...d},void 0!==a.offset?Tn(a.offset):void 0,u,l),s,r)}(Lc,us,Us(r),r,e,t)}return function(e,t){const n=Nn(Zi(e));if(!n||!n.timeZone)throw new RangeError(ti(e));const{offset:r}=n,o=r?Tn(r):void 0,[,i,a]=Re(t);return On(n,o,i,a)}(e,t)}function Vc(e){return l(e=>t=>e(Jc(t)),e)}function Jc(e){return ss(e,us)}function Gc(e){if(r(e)){const t=nu(e);if(t)switch(t.branding){case Qa:return t;case Xa:return Je(t.epochNanoseconds)}}return function(e){const t=Nn(e=H(e));if(!t)throw new RangeError(ti(e));let n;if(t.j)n=0;else{if(!t.offset)throw new RangeError(ti(e));n=Tn(t.offset)}return t.timeZone&&An(t.timeZone,1),Je(fe(Te(t),n))}(e)}function Kc(){function e(e,n){return new t(e,n)}function t(e,t=Object.create(null)){Uu.set(this,((e,t)=>{const n=new pa(e,t),r=n.resolvedOptions(),i=r.locale,a=h(Object.keys(t),r),s=o(eu),c=(e,...t)=>{if(e){if(2!==t.length)throw new TypeError(ri);for(const e of t)if(void 0===e)throw new TypeError(ri)}e||void 0!==t[0]||(t=[]);const r=t.map(e=>nu(e)||Number(e));let o,c=0;for(const e of r){const t="object"==typeof e?e.branding:void 0;if(c++&&t!==o)throw new TypeError(ri);o=t}return o?s(o)(i,a,...r):[n,...r]};return c.X=n,c})(e,t))}const n=pa.prototype,r=Object.getOwnPropertyDescriptors(n),a=Object.getOwnPropertyDescriptors(pa);for(const t in r){const n=r[t],o=t.startsWith("format")&&Xc(t);"function"==typeof n.value?n.value="constructor"===t?e:o||Qc(t):o&&(n.get=function(){if(!Uu.has(this))throw new TypeError(_o);return(...e)=>o.apply(this,e)},Object.defineProperties(n.get,i(`get ${t}`)))}return a.prototype.value=t.prototype=Object.create({},r),Object.defineProperties(e,a),e}function Xc(e){return Object.defineProperties(function(...t){const n=Uu.get(this),[r,...o]=n(e.includes("Range"),...t);return r[e](...o)},i(e))}function Qc(e){return Object.defineProperties(function(...t){return Uu.get(this).X[e](...t)},i(e))}function eu(e){const t=bu[e];if(!t)throw new TypeError((e=>`Cannot format ${e}`)(e));return ao(t,o(so),1)}const tu=new WeakMap,nu=tu.get.bind(tu),ru=tu.set.bind(tu),ou={era:function(e){if(void 0!==e)return Zi(e)},eraYear:j,year:R,month:C,daysInMonth:C,daysInYear:C,inLeapYear:Wi,monthsInYear:C},iu={monthCode:Zi},au={day:C},su={dayOfWeek:C,dayOfYear:C,weekOfYear:function(e){if(void 0!==e)return C(e)},yearOfWeek:j,daysInWeek:C},cu=Yc(Object.assign({},ou,iu,au,su)),uu=Yc({...ou,...iu}),lu=Yc({...iu,...au}),fu={calendarId:e=>e.calendar},du=f(e=>t=>t[e],qi.concat("sign")),hu=f((e,t)=>e=>e[ta[t]],yi),mu={epochMilliseconds:rt,epochNanoseconds:function(e){return((e,t=1)=>{const[n,r]=e,o=Math.floor(r/t),i=bi/t;return BigInt(n)*BigInt(i)+BigInt(o)})(e.epochNanoseconds)}},[pu,gu]=jc(es,function(e=0,t=0,n=0,r=0,o=0,i=0,a=0,s=0,c=0,f=0){return nt(wn(l(W,u(qi,[e,t,n,r,o,i,a,s,c,f]))))},{...du,blank:function(e){return!e.sign}},{with:(e,t)=>gu(function(e,t){return nt((n=e,r=t,wn({...n,...Vr(r,zi)})));var n,r}(e,t)),negated:e=>gu(pn(e)),abs:e=>gu(function(e){return-1===e.sign?pn(e):e}(e)),add:(e,t,n)=>gu(mn(Hc,Us,us,0,e,Fc(t),n)),subtract:(e,t,n)=>gu(mn(Hc,Us,us,1,e,Fc(t),n)),round:(e,t)=>gu(function(e,t,n,r,o){const i=Dn(r),[a,s,c,u,l]=((e,t,n)=>{e=We(e,Ma);let r=La(e);const o=n(e[ka]);let i=He(e);const a=qa(e,7);let s=Aa(e);if(void 0===r&&void 0===s)throw new RangeError(Qo);if(null==s&&(s=0),null==r&&(r=Math.max(s,t)),Ve(r,s),i=Be(i,s,1),i>1&&s>5&&r!==s)throw new RangeError("For calendar units with roundingIncrement > 1, use largestUnit = smallestUnit");return[r,s,i,a,o]})(o,i,e),f=Math.max(i,a);if(!l&&f<=6)return nt(wn(((e,t,n,r,o)=>{const i=bt(vn(e),n,r,o);return{...Xi,...En(i,t)}})(r,a,s,c,u)));if(!dn(l)&&!r.sign)return r;if(!l)throw new RangeError(Ko);const[d,h,m]=cn(t,n,l),p=un(m),g=ln(m),b=fn(m),w=g(h,d,r);dn(l)||(oe(d),oe(w));let y=b(h,d,w,a);const v=r.sign,E=bn(y);if(v&&E&&v!==E)throw new RangeError(Lo);return y=gt(y,p(w),a,s,c,u,h,d,p,g),nt(y)}(Hc,Us,us,e,t)),total:(e,t)=>function(e,t,n,r,o){const i=Dn(r),[a,s]=((e,t)=>{const n=t((e=We(e,Ia))[ka]);let r=Fa(e);return r=N(Ia,r),[r,n]})(o,e),c=Math.max(a,i);if(!s&&hn(c,s))return it(r,a);if(!s)throw new RangeError(Ko);if(!r.sign)return 0;const[u,l,f]=cn(t,n,s),d=un(f),h=ln(f),m=fn(f),p=h(l,u,r);dn(s)||(oe(u),oe(p));const g=m(l,u,p,a);return hn(a,s)?it(g,a):((e,t,n,r,o,i,a)=>{const s=bn(e),[c,u]=at(r,ea(n,e),n,s,o,i,a),l=st(t,c,u);return e[qi[n]]+l*s})(g,d(p),a,l,u,d,h)}(Hc,Us,us,e,t),toLocaleString(e,t,n){return Intl.DurationFormat?new Intl.DurationFormat(t,n).format(this):jt(e)},toString:jt,toJSON:e=>jt(e),valueOf:Ac},{from:e=>gu(Fc(e)),compare:(e,t,n)=>function(e,t,n,r,o,i){const a=e(Ze(i).relativeTo),s=Math.max(Dn(r),Dn(o));if(p(qi,r,o))return 0;if(hn(s,a))return G(vn(r),vn(o));if(!a)throw new RangeError(Ko);const[c,u,l]=cn(t,n,a),f=un(l),d=ln(l);return G(f(d(u,c,r)),f(d(u,c,o)))}(Hc,Us,us,Fc(e),Fc(t),n)}),bu={Instant:Ic,PlainDateTime:Sc,PlainDate:kc,PlainTime:Tc,PlainYearMonth:_c,PlainMonthDay:xc},wu=ao(Ic),yu=ao(Dc),vu=ao(Sc),Eu=ao(kc),Mu=ao(Tc),Iu=ao(_c),Du=ao(xc),[Su,ku]=jc(Ka,function(e=0,t=0,n=0,r=0,o=0,i=0){return tt(je(l(Z,u(ta,[e,t,n,r,o,i])),1))},hu,{with(e,t,n){return ku(function(e,t,n){return tt(((e,t,n)=>Jr({...h(vi,e),...Vr(t,vi)},Ce(n)))(e,t,n))}(this,Cc(t),n))},add:(e,t)=>ku(en(0,e,Fc(t))),subtract:(e,t)=>ku(en(1,e,Fc(t))),until:(e,t,n)=>gu(ar(0,e,Bc(t),n)),since:(e,t,n)=>gu(ar(1,e,Bc(t),n)),round:(e,t)=>ku(function(e,t){const[n,r,o]=Pe(t,5);var i;return tt((i=o,lt(e,dt(n,r),i)[0]))}(e,t)),equals:(e,t)=>function(e,t){return!Xn(e,t)}(e,Bc(t)),toLocaleString(e,t,n){const[r,o]=Mu(t,n,e);return r.format(o)},toString:Ot,toJSON:e=>Ot(e),valueOf:Ac},{from:(e,t)=>ku(Bc(e,t)),compare:(e,t)=>Xn(Bc(e),Bc(t))}),[Tu,_u]=jc(Ga,b(function(e,t,n,r,o=0,i=0,a=0,s=0,c=0,f=0,d=Ai){return Ke(oe(Te(l(Z,u(ra,[t,n,r,o,i,a,s,c,f])))),e(d))},Ur),{...fu,...cu,...hu},{with:(e,t,n)=>_u(function(e,t,n,r){const o=e(t.calendar),i=[...o.fields(Ri),...yi].sort(),a={...to(s=t),hour:s.isoHour,minute:s.isoMinute,second:s.isoSecond,millisecond:s.isoMillisecond,microsecond:s.isoMicrosecond,nanosecond:s.isoNanosecond};var s;const c=Vr(n,i),u=Ce(r),l=o.k(a,c),f={...a,...c};return Ke(oe({...o.F(l,$e(u)),...je(Ws(f),u)}))}(Us,e,Cc(t),n)),withCalendar:(e,t)=>_u(uo(e,Pc(t))),withPlainTime:(e,t)=>_u(function(e,t=sa){return Ke(oe({...e,...t}))}(e,Uc(t))),add:(e,t,n)=>_u(Kt(Us,0,e,Fc(t),n)),subtract:(e,t,n)=>_u(Kt(Us,1,e,Fc(t),n)),until:(e,t,n)=>gu(nr(Us,0,e,Zc(t),n)),since:(e,t,n)=>gu(nr(Us,1,e,Zc(t),n)),round:(e,t)=>_u(function(e,t){return Ke(ct(e,...Pe(t)),e.calendar)}(e,t)),equals:(e,t)=>function(e,t){return!Gn(e,t)&&e.calendar===t.calendar}(e,Zc(t)),toZonedDateTime:(e,t,n)=>Yu(function(e,t,n,r){const o=((e,t,n,r)=>{const o=(e=>Ba(Ze(e)))(r);return zt(e(t),n,o)})(e,n,t,r);return Ge(ie(o),n,t.calendar)}(us,e,Lc(t),n)),toPlainDate:e=>Nu(Xe(e)),toPlainTime:e=>ku(tt(e)),toLocaleString(e,t,n){const[r,o]=vu(t,n,e);return r.format(o)},toString:kt,toJSON:e=>kt(e),valueOf:Ac},{from:(e,t)=>_u(Zc(e,t)),compare:(e,t)=>Gn(Zc(e),Zc(t))}),[xu,Ou]=jc(Va,b(function(e,t,n,r=Ai,o=wa){const i=Z(t),a=Z(n),s=e(r);return et(re(_e({isoYear:Z(o),isoMonth:i,isoDay:a})),s)},Ur),{...fu,...lu},{with:(e,t,n)=>Ou(function(e,t,n,r){const o=e(t.calendar),i=o.fields(Ri).sort(),a=(e=>{const t=Bs(e.calendar),[n,r,o]=t.v(e),[i,a]=t.q(n,r);return{monthCode:Er(i,a),day:o}})(t),s=Vr(n,i),c=o.k(a,s);return o._(c,r)}(Us,e,Cc(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,Wc(t)),toPlainDate(e,t){return Nu(function(e,t,n,r){return((e,t,n)=>Gr(e,t,Pi,P(n),Ti))(e(t.calendar),n,r)}(Us,e,this,t))},toLocaleString(e,t,n){const[r,o]=Du(t,n,e);return r.format(o)},toString:xt,toJSON:e=>xt(e),valueOf:Ac},{from:(e,t)=>Ou(Wc(e,t))}),[ju,Cu]=jc(za,b(function(e,t,n,r=Ai,o=1){const i=Z(t),a=Z(n),s=e(r);return Qe(ne(_e({isoYear:i,isoMonth:a,isoDay:Z(o)})),s)},Ur),{...fu,...uu},{with:(e,t,n)=>Cu(function(e,t,n,r){const o=e(t.calendar),i=o.fields(ji).sort(),a=(e=>{const t=Bs(e.calendar),[n,r]=t.v(e),[o,i]=t.q(n,r);return{year:n,monthCode:Er(o,i)}})(t),s=Vr(n,i),c=o.k(a,s);return o.K(c,r)}(Us,e,Cc(t),n)),add:(e,t,n)=>Cu(Qt(Us,0,e,Fc(t),n)),subtract:(e,t,n)=>Cu(Qt(Us,1,e,Fc(t),n)),until:(e,t,n)=>gu(or(Us,0,e,$c(t),n)),since:(e,t,n)=>gu(or(Us,1,e,$c(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,$c(t)),toPlainDate(e,t){return Nu(function(e,t,n,r){return((e,t,n)=>Gr(e,t,Ci,P(n),Oi))(e(t.calendar),n,r)}(Us,e,this,t))},toLocaleString(e,t,n){const[r,o]=Iu(t,n,e);return r.format(o)},toString:_t,toJSON:e=>_t(e),valueOf:Ac},{from:(e,t)=>Cu($c(e,t)),compare:(e,t)=>Kn($c(e),$c(t))}),[Ru,Nu]=jc(Ja,b(function(e,t,n,r,o=Ai){return Xe(re(_e(l(Z,{isoYear:t,isoMonth:n,isoDay:r}))),e(o))},Ur),{...fu,...cu},{with:(e,t,n)=>Nu(function(e,t,n,r){const o=e(t.calendar),i=o.fields(Ri).sort(),a=to(t),s=Vr(n,i),c=o.k(a,s);return o.F(c,r)}(Us,e,Cc(t),n)),withCalendar:(e,t)=>Nu(uo(e,Pc(t))),add:(e,t,n)=>Nu(Xt(Us,0,e,Fc(t),n)),subtract:(e,t,n)=>Nu(Xt(Us,1,e,Fc(t),n)),until:(e,t,n)=>gu(rr(Us,0,e,qc(t),n)),since:(e,t,n)=>gu(rr(Us,1,e,qc(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,qc(t)),toZonedDateTime(e,t){const n=r(t)?t:{timeZone:t};return Yu(function(e,t,n,r,o){const i=e(o.timeZone),a=o.plainTime,s=void 0!==a?t(a):void 0,c=n(i);let u;return u=s?zt(c,{...r,...s}):Vt(c,{...r,...sa}),Ge(u,i,r.calendar)}(Lc,Bc,us,e,n))},toPlainDateTime:(e,t)=>_u(function(e,t=sa){return Ke(oe({...e,...t}))}(e,Uc(t))),toPlainYearMonth(e){return Cu(function(e,t,n){return((e,t)=>{const n=zr(e,t,Ci);return e.K(n,void 0)})(e(t.calendar),n)}(Us,e,this))},toPlainMonthDay(e){return Ou(function(e,t,n){return((e,t)=>{const n=zr(e,t,Pi);return e._(n)})(e(t.calendar),n)}(Us,e,this))},toLocaleString(e,t,n){const[r,o]=Eu(t,n,e);return r.format(o)},toString:Tt,toJSON:e=>Tt(e),valueOf:Ac},{from:(e,t)=>Nu(qc(e,t)),compare:(e,t)=>Kn(qc(e),qc(t))}),[Pu,Yu]=jc(Xa,b(function(e,t,n,r,o=Ai){return Ge(ie(X(B(n))),t(r),e(o))},Ur,function(e){return $n(Zi(e))}),{...mu,...fu,...Vc(cu),...Vc(hu),offset:e=>Ft(Jc(e).offsetNanoseconds),offsetNanoseconds:e=>Jc(e).offsetNanoseconds,timeZoneId:e=>e.timeZone,hoursInDay:e=>function(e,t){const n=e(t.timeZone),r=ss(t,n),[o,i]=ht(r),a=ee(J(Vt(n,o),Vt(n,i)),gi,1);if(a<=0)throw new RangeError(Lo);return a}(us,e)},{with:(e,t,n)=>Yu(function(e,t,n,r,o){const{calendar:i,timeZone:a}=n,s=e(i),c=t(a),u=[...s.fields(Ri),...Ii].sort(),l=(e=>{const t=ss(e,us),n=Ft(t.offsetNanoseconds),r=Bs(e.calendar),[o,i,a]=r.v(t),[s,c]=r.q(o,i),u=Er(s,c);return{...$s(t),year:o,monthCode:u,day:a,offset:n}})(n),f=Vr(r,u),d=s.k(l,f),h={...l,...f},[m,p,g]=Re(o,2);return Ge(qt(c,{...s.F(d,$e(m)),...je(Ws(h),m)},Tn(h.offset),p,g),a,i)}(Us,us,e,Cc(t),n)),withCalendar:(e,t)=>Yu(uo(e,Pc(t))),withTimeZone:(e,t)=>Yu(function(e,t){return{...e,timeZone:t}}(e,Lc(t))),withPlainTime:(e,t)=>Yu(function(e,t,n){const r=t.timeZone,o=e(r),i={...ss(t,o),...n||sa};let a;return a=n?qt(o,i,i.offsetNanoseconds,2):Vt(o,i),Ge(a,r,t.calendar)}(us,e,Uc(t))),add:(e,t,n)=>Yu(Gt(Us,us,0,e,Fc(t),n)),subtract:(e,t,n)=>Yu(Gt(Us,us,1,e,Fc(t),n)),until:(e,t,n)=>gu(nt(tr(Us,us,0,e,zc(t),n))),since:(e,t,n)=>gu(nt(tr(Us,us,1,e,zc(t),n))),round:(e,t)=>Yu(function(e,t,n){let{epochNanoseconds:r,timeZone:o,calendar:i}=t;const[a,s,c]=Pe(n);if(0===a&&1===s)return t;const u=e(o);if(6===a)r=((e,t,n,r)=>{const o=ss(n,t),[i,a]=e(o),s=n.epochNanoseconds,c=Vt(t,i),u=Vt(t,a);if(K(s,c,u))throw new RangeError(Lo);return vt(st(s,c,u),r)?u:c})(ht,u,t,c);else{const e=u.R(r);r=qt(u,ct(pe(r,e),a,s,c),e,2,0,1)}return Ge(r,o,i)}(us,e,t)),startOfDay:e=>Yu(function(e,t){const{timeZone:n,calendar:r}=t,o=((e,t,n)=>Vt(t,e(ss(n,t))))(mt,e(n),t);return Ge(o,n,r)}(us,e)),equals:(e,t)=>function(e,t){return!Jn(e,t)&&!!Qn(e.timeZone,t.timeZone)&&e.calendar===t.calendar}(e,zc(t)),toInstant:e=>Lu(function(e){return Je(e.epochNanoseconds)}(e)),toPlainDateTime:e=>_u(no(us,e)),toPlainDate:e=>Nu(ro(us,e)),toPlainTime:e=>ku(oo(us,e)),toLocaleString(e,t,n={}){const[r,o]=yu(t,n,e);return r.format(o)},toString:(e,t)=>St(us,e,t),toJSON:e=>St(us,e),valueOf:Ac,getTimeZoneTransition(e,t){const{timeZone:n,epochNanoseconds:r}=e,o=function(e){const t=We(e,Ta),n=ze(Ta,Ya,t,0);if(!n)throw new RangeError(Mo(Ta,n));return n}(t),i=us(n).O(r,o);return i?Yu({...e,epochNanoseconds:i}):null}},{from:(e,t)=>Yu(zc(e,t)),compare:(e,t)=>Jn(zc(e),zc(t))}),[Au,Lu]=jc(Qa,function(e){return Je(ie(X(B(e))))},mu,{add:(e,t)=>Lu(Jt(0,e,Fc(t))),subtract:(e,t)=>Lu(Jt(1,e,Fc(t))),until:(e,t,n)=>gu(er(0,e,Gc(t),n)),since:(e,t,n)=>gu(er(1,e,Gc(t),n)),round:(e,t)=>Lu(function(e,t){const[n,r,o]=Pe(t,5,1);return Je(bt(e.epochNanoseconds,n,r,o,1))}(e,t)),equals:(e,t)=>function(e,t){return!Vn(e,t)}(e,Gc(t)),toZonedDateTimeISO:(e,t)=>Yu(function(e,t,n=Ai){return Ge(e.epochNanoseconds,t,n)}(e,Lc(t))),toLocaleString(e,t,n){const[r,o]=wu(t,n,e);return r.format(o)},toString:(e,t)=>Dt(Lc,us,e,t),toJSON:e=>Dt(Lc,us,e),valueOf:Ac},{from:e=>Lu(Gc(e)),fromEpochMilliseconds:e=>Lu(function(e){return Je(ie(Q(W(e),hi)))}(e)),fromEpochNanoseconds:e=>Lu(function(e){return Je(ie(X(B(e))))}(e)),compare:(e,t)=>Vn(Gc(e),Gc(t))}),Fu=Object.defineProperties({},{...c("Temporal.Now"),...a({timeZoneId:()=>ho(),instant:()=>Lu(Je(fo())),zonedDateTimeISO:(e=ho())=>Yu(Ge(fo(),Lc(e),Ai)),plainDateTimeISO:(e=ho())=>_u(Ke(lo(us(Lc(e))),Ai)),plainDateISO:(e=ho())=>Nu(Xe(lo(us(Lc(e))),Ai)),plainTimeISO:(e=ho())=>ku(tt(lo(us(Lc(e)))))})}),Hu=Object.defineProperties({},{...c("Temporal"),...a({PlainYearMonth:ju,PlainMonthDay:xu,PlainDate:Ru,PlainTime:Su,PlainDateTime:Tu,ZonedDateTime:Pu,Instant:Au,Duration:pu,Now:Fu})}),Bu=Kc(),Uu=new WeakMap;function Zu(e,...t){let n=bbn.lng[e]||e;if(t.length){let e=0;return n.replace(/\%([d|s])/g,(n,r)=>{let o=t[e++];o||(o="d"===r?0:"");const i=typeof o;return"d"===r&&"number"!==i?(o=parseFloat(o),isNaN(o)&&(o=0)):"s"===r&&"string"!==i&&(o=""+o),o})}return n}Object.create(Intl),a({DateTimeFormat:Bu});var Wu={loggers:{_num:0},datatypes:["xml","html","script","json","jsonp","text","blob"],shortenLen:30,keys:{upDown:[33,34,35,36,38,40],leftRight:[36,35,37,39],dels:[8,46,45],confirm:[13,9],alt:[20,16,17,18,144],numbers:[48,49,50,51,52,53,54,55,56,57,96,97,98,99,100,101,102,103,104,105],numsigns:[109,110,189,190]},comparators:[">=","<=",">","<","="],operators:["+","-","/","*"],tags:["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","label","legend","li","link","main","map","mark","menu","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","slot","small","source","span","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr"],colors:{darkgrey:"#5a6a62",black:"#000000",anthracite:"#454545",grey:"#d3d3d3",white:"#ffffff",beige:"#fdfdfd",lightgrey:"#dcdcdc",pastelblue:"#ddebf6",cyan:"#00c8f8",blue:"#6e9ecf",indigo:"#3f51b5",navy:"#354458",webblue:"#2196f3",teal:"#009688",turquoise:"#1fda9a",pastelgreen:"#e2efda",palegreen:"#ccffcc",green:"#00a03e",olive:"#92b06a",pastelorange:"#fff2cc",yellow:"#fdf200",orange:"#ff9900",pink:"#eb65a0",purple:"#a333c8",red:"#db3340",brown:"#8c6954"},reserved:["abstract","boolean","break","byte","case","catch","char","class","continue","const","debugger","default","delete","do","double","else","enum","export","extends","false","final","finally","float","for","function","goto","if","implements","import","in","instanceof","int","interface","long","new","null","package","return","super","switch","synchronized","this","throw","throws","transient","true","try","typeof","var","void","while","with"],mockText:"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.",regexp:{url:new RegExp("^(https?:\\/\\/)?((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.?)+[a-z]{2,}|((\\d{1,3}\\.){3}\\d{1,3}))(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*(\\?[;&a-z\\d%_.~+=-]*)?(\\#[-a-z\\d_]*)?$","i"),ip:/^((\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])\.){3}(\d|[1-9]\d|1\d{2}|2[0-4]\d|25[0-5])$/,hostname:/^[a-z\d]([a-z\d-]{0,61}[a-z\d])?(\.[a-z\d]([a-z\d-]{0,61}[a-z\d])?)*$/i}},$u={siteTitle:window.document.title,logging:!1,cdn:"",lang:"en",host:window.location.protocol+"//"+window.location.hostname,url:window.location.href,old_path:null,loading:!1,_enumerated:[],get isEnumerating(){return this._enumerated.length>0},width:0,height:0,focused:!1,last_focus:(new Date).getTime(),sleep:!1,theme:"dark",loaders:[],loadersHistory:[],maxLoadersHistory:50,resizeTimer:!1,hashChanged:0,params:[],isInit:!1,isFocused:!1,timeoff:Math.round((new Date).getTime()/1e3),loggingLevel:5,ignoreUnload:!1,historyDisabled:!1,nav:"ajax",online:window.navigator.onLine},qu=function(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function s(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}c((r=r.apply(e,t||[])).next())})};class zu extends Error{constructor(e){super(e||"Request canceled"),this.name="Cancel",this.__BBN_CANCEL__=!0}}const Vu=["POST","PUT","PATCH","DELETE"],Ju=(e,t,n={},r)=>{const o=new XMLHttpRequest,i=Vu.includes(e.toUpperCase()),a=new Promise((r,a)=>{o.open(e,t,!0);const{body:s,headers:c}=((e,t)=>{const n=new Headers(t||{});let r=e;return null==e||e instanceof FormData||"object"!=typeof e||(n.set("Content-Type","application/json"),r=JSON.stringify(e)),{body:r,headers:n}})(n.data,n.headers);c.forEach((e,t)=>{o.setRequestHeader(t,e)}),"function"==typeof n.onUploadProgress&&o.upload&&o.upload.addEventListener("progress",e=>{const t=e.lengthComputable?e.total:void 0;n.onUploadProgress({loaded:e.loaded,total:t,progress:t?e.loaded/t:void 0})}),o.onreadystatechange=()=>{if(4!==o.readyState)return;const e=(e=>{const t={};return e?(e.trim().split(/[\r\n]+/).forEach(e=>{const n=e.split(": "),r=n.shift(),o=n.join(": ");r&&(t[r.toLowerCase()]=o)}),t):t})(o.getAllResponseHeaders()),t=1223===o.status?204:o.status,i=o.statusText||"";let s=o.responseText;if((e["content-type"]||"").includes("application/json"))try{s=JSON.parse(o.responseText)}catch(e){}const c={data:s,status:t,statusText:i,headers:e,config:n,request:o};if(t>=200&&t<300)r(c);else{const e=new Error("Request failed with status code "+t);e.response=c,e.config=n,e.request=o,a(e)}},o.onerror=()=>{const e=new Error("Network Error");e.config=n,e.request=o,a(e)},o.onabort=()=>{a(new zu("Request canceled"))},i?o.send(s):o.send()});return a.cancel=()=>o.abort(),a};var Gu={isCancel:e=>!(!e||!0!==e.__BBN_CANCEL__),run:(e,t,n={},r)=>{n.baseURL&&!/^https?:\/\//i.test(t)&&(t=n.baseURL.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,"")),t=((e,t)=>{if(!t)return e;const n=new URLSearchParams(t).toString();return n?e+(e.includes("?")?"&":"?")+n:e})(t,n.params);return"function"==typeof n.onUploadProgress&&Vu.includes(e.toUpperCase())?Ju(e,t,n):((e,t,n={},r)=>{const o={method:e,headers:new Headers(n.headers||{}),signal:null==r?void 0:r.signal},i=Vu.includes(e.toUpperCase());if(null!=n.data&&i&&(bbn.fn.log("DATA",n.data),"object"!=typeof n.data||n.data instanceof FormData?o.body=n.data:(o.headers.set("Content-Type","application/json"),o.body=JSON.stringify(n.data))),n.params){const e=new URLSearchParams(n.params).toString();t+=(t.includes("?")?"&":"?")+e}const a=fetch(t,o).then(e=>qu(void 0,void 0,void 0,function*(){let t;t=(e.headers.get("content-type")||"").includes("application/json")?yield e.json():yield e.text();const r={data:t,status:e.status,statusText:e.statusText,headers:Object.fromEntries(e.headers.entries()),config:n,request:e};if(!e.ok){const t=new Error("Request failed with status code "+e.status);throw t.response=r,t.config=n,t.request=e,t}return r})).catch(e=>{if("AbortError"===e.name)throw new zu("Request canceled");throw e});return a.cancel=()=>r.abort(),a})(e,t,n,r)}};function Ku(...e){if(!e.length)return!1;for(let t of e)if(["boolean","object","symbol"].includes(typeof t)||""===t||isNaN(t))return!1;return!0}function Xu(...e){if(!e.length)return!1;for(let t of e)if(!t||"object"!=typeof t||!(Symbol.iterator in Object(t)))return!1;return!0}function Qu(...e){if(!e.length)return!1;for(let t of e)if("[object String]"!=={}.toString.apply(t))return!1;return!0}function el(...e){if(!e.length)return!1;for(let t of e)if(!Number.isInteger(t))return!1;return!0}function tl(...e){if(!e.length)return!1;for(let t of e)if(!(t&&t.constructor&&t.call&&t.apply))return!1;return!0}function nl(...e){var t,n,r;if((null===(t=bbn.env)||void 0===t?void 0:t.isDev)&&void 0!==(null===window||void 0===window?void 0:window.console)){let t,o=5,i="log";e[0]&&"object"==typeof e[0]&&e[0]._bbn_console_style&&(e[0]._bbn_console_mode&&tl(console[e[0]._bbn_console_mode])?i=e[0]._bbn_console_mode:(t=e[0]._bbn_console_style,o=e[0]._bbn_console_level),e.shift());const a=window.console[i];if((null===(r=null===(n=window.bbn)||void 0===n?void 0:n.env)||void 0===r?void 0:r.loggingLevel)>=o){let n=0;for(;n<e.length;){let r=typeof e[n],o=[e[n]];"string"!==r&&"number"!==r||o.unshift("%c %s ",t),a.apply(window.console,o),n++}}}return this}function rl(e,t,n){if(!Qu(e)||!el(t))throw nl(arguments),new Error(bbn._("The substr function should be applied to a string and at least a `from` argument should be given"));return t<0&&(t=e.length+t),el(n)?e.substring(t,(n<0?e.length:t)+n):e.substring(t)}function ol(e,t=!1){let n=null;if("object"==typeof e)for(var r in n={},e)rl(r,0,1).match(/^[A-z0-9]$/)&&r in e&&(t&&"object"==typeof e[r]?n[r]=ol(e[r],!0):n[r]=e[r]);return n||!1}function il(e,t,n=!1,r=!1){if(null!==e&&"object"==typeof e){let o=Object.keys(n?ol(e):e);r&&o.reverse();for(let n of o)if(!1===t(e[n],n))break}return e}function al(e,t){if(!(Ku(e)&&e>0)){if(Xu(e)){for(let n=0;n<e.length;n++)if(!1===t(e[n],n))return;return e}return il(e,t)}for(let n=0;n<e;n++)if(!1===t(n,n))return}function sl(...e){if(!e.length)return!1;for(let t of e)if("[object Object]"!=={}.toString.apply(t))return!1;return!0}function cl(...e){if(!e.length)return!1;for(let t of e)if(!Array.isArray(t))return!1;return!0}function ul(...e){let t=!1,n=[];for(let r=0;r<e.length;r++)if(!0===e[r])t=!0;else{if(!e[r])continue;if("object"!=typeof e[r])throw new Error(bbn._("Error in extend: all arguments should be object, you have given ")+typeof e[r]);n.push(e[r])}if(!n.length)throw new Error("No argument given");let r,o=n[0];for(let e=1;e<n.length;e++)il(n[e],(e,n)=>{t?cl(e)?(o[n]=cl(o[n])?o[n]:[],al(e,(e,t)=>{if(e&&"object"==typeof e){let r=o[n][t];cl(e)?cl(r)||(r=[]):sl(r)||(r={}),o[n][t]=ul(!0,r,e)}else o[n][t]=e})):sl(e)?o[n]=ul(!0,o[n]&&"object"==typeof o[n]?o[n]:Object.create(Object.getPrototypeOf(e)),e):o[n]=e:(o[n]!==e||void 0===e&&!Object.prototype.hasOwnProperty.apply(o,[n]))&&(o[n]=e)}),r||(r=!!n[e].__bbnNoData);return r&&"bbnData"in window&&(o.__bbnData&&o.__bbnData.unset(),Object.defineProperty(o,"__bbnNoData",{value:!0,enumerable:!1,configurable:!1,writable:!1})),o}const ll=window.indexedDB||window.webkitIndexedDB||window.mozIndexedDB||window.OIndexedDB||window.msIndexedDB,fl=(e,t)=>{if(null==t?void 0:t.length){let n={};return il(e,(e,r)=>{t.indexOf(r)>-1&&(n[r]=e)}),n}return e},dl=function(e){const t=hl._connections[e],n=hl._structures[e];let r=null;const o=(e,t)=>{e.onerror=()=>{r=e.error,nl(e.error),t(e.error)}},i=(e,n)=>{const o=t.transaction([e],0===n.toLowerCase().indexOf("r")?"readonly":"readwrite");return o.onabort=()=>{throw r=o.error,new Error(o.error)},[o,o.objectStore(e)]};this.lastError=()=>r,this.insert=(e,t)=>(Array.isArray(t)||(t=[t]),new Promise(n=>{const[r,o]=i(e,"w");let a=t.length;al(t,e=>{const t=o.put(e);t.onerror=()=>{nl(t.error),a--}}),r.oncomplete=()=>{n(a)}})),this.update=(e,t,r,a)=>new Promise(s=>{this.selectAll(e,[],r).then(r=>{if(!r.length)return void s(0);const[c,u]=i(e,"w"),l=n[e],f=l.keys.PRIMARY.columns.length>1?l.keys.PRIMARY.columns:l.keys.PRIMARY.columns[0];let d=0;for(let e=0;e<r.length;e++){const n=ul({},a?{[f]:r[e][f]}:r[e],t);if(!n[f])throw new Error(Zu("No primary key in the data"));const i=u.put(n);o(i,s),i.onsuccess=()=>{d++}}c.oncomplete=()=>{s(d)}})}),this.delete=(e,t)=>new Promise(r=>{const[a,s]=i(e,"w"),c=n[e],u=c.keys.PRIMARY.columns.length>1?c.keys.PRIMARY.columns:c.keys.PRIMARY.columns[0];if(!t[u])throw new Error(Zu("No "));const l=s.delete(t[u]);o(l,r),a.oncomplete=()=>{r(1)}}),this.selectOne=(e,t,n,r,o,i)=>new Promise(i=>{this.selectAll(e,[t],n,r,o,1).then(e=>{var n,r;i(null!==(r=null===(n=null==e?void 0:e[0])||void 0===n?void 0:n[t])&&void 0!==r?r:void 0)})}),this.select=(e,t,n,r,o)=>new Promise(i=>{this.selectAll(e,t,n,r,o,1).then(e=>{i(e.length?e[0]:null)})}),this.selectAll=(e,t=[],r=null,a=null,s=0,c=null)=>new Promise(a=>{const[u,l]=i(e,"r"),f=n[e],d=f.keys.PRIMARY.columns.length>1?f.keys.PRIMARY.columns:f.keys.PRIMARY.columns[0],h=sl(r)?Object.keys(r)[0]:!r||cl(r)?null:d,m=[];if(h===d)if(bbn.fn.isArray(null==r?void 0:r[d])){const e=Math.min(r[d].length,c||9999999);for(let n=s||0;n<e;n++){let i=l.get(r[d][n]);i.onsuccess=()=>{let n=i.result;m.push(fl(n,t)),m.length===e&&a(m)},o(i,a)}}else{let e=l.get((null==r?void 0:r[d])||r);e.onsuccess=()=>{let n=e.result;m.push(fl(n,t)),a(m)},o(e,a)}else{const e=l.openCursor();let n=0;e.onsuccess=e=>{const o=e.target.result;o?(r&&bbn.fn.search([o.value],r)||(n>=s&&(m.push(fl(o.value,t)),m.length===c&&a(m)),n++),o.continue()):a(m)},o(e,a)}}),this.getColumnValues=(e,n,r,o,i,a)=>new Promise(n=>{t.transaction([e],"read").objectStore(e)}),this.copyTable=(r,o,i=[],a=null,s=null,c=0,u=null)=>new Promise(l=>{if(t.objectStoreNames.contains(r)||hl.add(e,r,n[o]),!t.objectStoreNames.contains(r))throw l(0),new Error(Zu("The target table %s does not exist",r));this.selectAll(o,i,a,s,c,u).then(e=>{e.length?this.insert(r,e).then(e=>{l(e)}):l(0)})}),this.deleteTable=e=>new Promise(n=>{t.deleteObjectStore(e),n(!0)})},hl={_structures:{},_connections:{},_stores:{},ok:void 0!==ll,updateStructure(e,t,n){const r=t.keys.PRIMARY.columns.length>1?t.keys.PRIMARY.columns:t.keys.PRIMARY.columns[0];if(!n.objectStoreNames.contains(e)){const o=n.createObjectStore(e,{keyPath:r});il(t.keys,(e,t)=>{"PRIMARY"!==t&&o.createIndex(t,e.columns.length>1?e.columns:e.columns[0],{unique:!!e.unique})})}},open(e){return new Promise(t=>{if(hl._connections[e])t(new dl(e));else{if(!hl._structures[e])throw new Error(Zu("Impossible to find a structure for the database %s",e));let n=Math.max.apply(this,[1].concat(Object.keys(hl._structures[e]).map(t=>hl._structures[e][t].num||1)));const r=ll.open(e,n);r.onupgradeneeded=()=>{const t=r.result;il(hl._structures[e],(e,n)=>{this.updateStructure(n,e,t)})},r.onsuccess=()=>{hl._connections[e]=r.result;let n=new dl(e);t(n)}}})},add(e,t,n){var r;if(!(null===(r=null==n?void 0:n.keys)||void 0===r?void 0:r.PRIMARY)||!(null==n?void 0:n.fields))throw new Error(Zu("The database structure for %s is not valid (are there keys and field? Is there a primary?",t));hl._structures[e]||(hl._structures[e]={}),hl._structures[e][t]=n,hl._connections[e]&&this.updateStructure(t,n,hl._connections[e])}};function ml(e,t,n){let r=(new Date).getTime(),o={key:e,url:rl(e,0,e.length-33),loader:t,aborter:n,loading:!0,error:!1,abort:!1,errorMessage:!1,success:!1,start:r};bbn.env.loaders.push(o),bbn.env.loadersHistory.unshift(o);let i=bbn.env.loadersHistory.length;for(;i&&bbn.env.loadersHistory.length>bbn.env.maxLoadersHistory;)i--,bbn.env.loading||bbn.env.loadersHistory.splice(i,1);return r}function pl(e,...t){if("object"==typeof e){const n=[];return 1===t.length&&"string"==typeof t[0]?n.push(...t[0].split(".")):n.push(...t),n.reduce((e,t)=>{if(e)return e[e instanceof Array?parseInt(t):t]},e)}}function gl(e){if(!Qu(e)){if(!e.toString)throw nl(e),new Error(bbn._("removeAccent expects a string"));e=e.toString()}return e.normalize("NFD").replace(/[\u0300-\u036f]/g,"")}function bl(...e){if(!e.length)return!1;for(let t of e)if("[object Date]"!=={}.toString.apply(t))return!1;return!0}function wl(e,t,n,r="asc"){let o=pl(e,n),i=pl(t,n),a=(typeof o).toLowerCase(),s=(typeof i).toLowerCase();if("asc"!==r&&Qu(r)&&"desc"===r.toLowerCase()&&(r="desc"),a!==s)o=a,i=s;else switch(a){case"string":o=gl(o).toLowerCase(),i=gl(i).toLowerCase();break;case"boolean":o=o?1:0,i=i?1:0;break;case"object":bl(o)&&(o=o.getTime(),i=bl(i)?i.getTime():0)}return o<i?"desc"===r?1:-1:o>i?"desc"===r?-1:1:0}function yl(e){return e&&"object"==typeof e?Object.keys(e).length:0}function vl(e){return!e||(cl(e)?!e.length:"object"==typeof e&&!yl(e))}function El(...e){if(!e.length)return!1;for(let t of e)if("[object Null]"!=={}.toString.apply(t))return!1;return!0}function Ml(e){let t=0;for(let n=0;n<e.length;n++){t=(t<<5)-t+e.charCodeAt(n),t|=0}return Math.abs(t).toString(16)}function Il(e){let t=0;for(let n=0;n<e.length;n++){t=e.charCodeAt(n)+(t<<6)+(t<<16)-t,t|=0}return Math.abs(t).toString(16)}function Dl(e){return Ml(e).padStart(8,"0")+Il(e).padStart(8,"0")}function Sl(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof HTMLElement))return!1;return!0}function kl(e){let t="",n=e;if(e.id)return"#"+e.id;for(;n&&n!==document.body;){let e=n,r=e.localName,o=0;if(!r)break;if(e===document.body)break;e.id&&(t="#"+e.id+">"+t,o=1);let i=n.parentNode,a=Array.from(i.children).filter(t=>t.tagName===e.tagName);if(!o&&a.length>1){let t=Array.from(i.children).indexOf(e)+1;t>1&&(r+=":nth-child("+t+")")}t=r+(t?">"+t:""),n=i}return t}function Tl(...e){var t;if(!e.length)return!1;if(!("cp"in bbn)||!("isComponent"in bbn.cp)||"function"!=typeof bbn.cp.isComponent)return!1;for(let n of e){if(!bbn.cp.isComponent(n)||Sl(n)||!(null===(t=n.$el)||void 0===t?void 0:t.bbnCid))return!1}return!0}function _l(e,t=null,n=0,r=null,o=null){if(n||r||(r=new WeakSet),void 0===e)e="__BBN_UNDEFINED__";else if(null===e)e="__BBN_NULL__";else if(null===e)e="__BBN_NULL__";else if("function"==typeof e)e="__BBN_FUNCTION__"+e.toString();else if("symbol"==typeof e)e="__BBN_SYMBOL__"+e.toString();else if("string"==typeof e)e="__BBN_STRING__"+e;else if("number"==typeof e)e="__BBN_NUMBER__"+e.toString();else if("boolean"==typeof e)e="__BBN_BOOLEAN__"+e.toString();else if([void 0,Object,Array,null].includes(null==e?void 0:e.constructor)){if(bbn.fn.isArray(e))if(r.has(e)||t&&t<n)e="__BBN_ARRAY__"+e.constructor.toString();else{r.add(e);let i="";for(let a=0;a<e.length;a++)i+="__BBN_ITEM"+a.toString()+"__"+o(e[a],t,n+1,r,o);e="__BBN_ARRAY__"+i}else if("object"==typeof e)if(r.has(e)||t&&t<n)e="__BBN_OBJECT__"+(e.constructor?e.constructor.toString():"");else{r.add(e);let i="";for(let a in e){let s=a;"string"!=typeof s&&(s=o(s,o,1,1)),i+="__BBN_PROP_"+s+"__"+o(e[a],t,n+1,r,o)}e="__BBN_OBJECT__"+i}}else e=Sl(e)?Tl(e)?"__BBN_CP__"+e.$cid:e.bbnId?"__BBN_DOM__"+e.tagName+"/"+e.bbnId+e.bbnHash:"__BBN_DOM__"+kl(e):"__BBN_UNKNOWN_OBJECT__"+e.constructor.toString();return e}function xl(...e){let t="",n=null;2===e.length&&"number"==typeof e[1]&&(n=e[1],e=[e[0]]);for(let r in e)t+=_l(e[r],n,0,null,_l);return Dl(t)}function Ol(e){var t="0123456789abcdef";function n(e){var n,r="";for(n=0;n<=3;n++)r+=t.charAt(e>>8*n+4&15)+t.charAt(e>>8*n&15);return r}function r(e,t){var n=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(n>>16)<<16|65535&n}function o(e,t,n,o,i,a){return r(function(e,t){return e<<t|e>>>32-t}(r(r(t,e),r(o,a)),i),n)}function i(e,t,n,r,i,a,s){return o(t&n|~t&r,e,t,i,a,s)}function a(e,t,n,r,i,a,s){return o(t&r|n&~r,e,t,i,a,s)}function s(e,t,n,r,i,a,s){return o(t^n^r,e,t,i,a,s)}function c(e,t,n,r,i,a,s){return o(n^(t|~r),e,t,i,a,s)}var u,l,f,d,h,m=function(e){var t,n=1+(e.length+8>>6),r=new Array(16*n);for(t=0;t<16*n;t++)r[t]=0;for(t=0;t<e.length;t++)r[t>>2]|=e.charCodeAt(t)<<t%4*8;return r[t>>2]|=128<<t%4*8,r[16*n-2]=8*e.length,r}(e),p=1732584193,g=-271733879,b=-1732584194,w=271733878;for(u=0;u<m.length;u+=16)l=p,f=g,d=b,h=w,p=i(p,g,b,w,m[u+0],7,-680876936),w=i(w,p,g,b,m[u+1],12,-389564586),b=i(b,w,p,g,m[u+2],17,606105819),g=i(g,b,w,p,m[u+3],22,-1044525330),p=i(p,g,b,w,m[u+4],7,-176418897),w=i(w,p,g,b,m[u+5],12,1200080426),b=i(b,w,p,g,m[u+6],17,-1473231341),g=i(g,b,w,p,m[u+7],22,-45705983),p=i(p,g,b,w,m[u+8],7,1770035416),w=i(w,p,g,b,m[u+9],12,-1958414417),b=i(b,w,p,g,m[u+10],17,-42063),g=i(g,b,w,p,m[u+11],22,-1990404162),p=i(p,g,b,w,m[u+12],7,1804603682),w=i(w,p,g,b,m[u+13],12,-40341101),b=i(b,w,p,g,m[u+14],17,-1502002290),p=a(p,g=i(g,b,w,p,m[u+15],22,1236535329),b,w,m[u+1],5,-165796510),w=a(w,p,g,b,m[u+6],9,-1069501632),b=a(b,w,p,g,m[u+11],14,643717713),g=a(g,b,w,p,m[u+0],20,-373897302),p=a(p,g,b,w,m[u+5],5,-701558691),w=a(w,p,g,b,m[u+10],9,38016083),b=a(b,w,p,g,m[u+15],14,-660478335),g=a(g,b,w,p,m[u+4],20,-405537848),p=a(p,g,b,w,m[u+9],5,568446438),w=a(w,p,g,b,m[u+14],9,-1019803690),b=a(b,w,p,g,m[u+3],14,-187363961),g=a(g,b,w,p,m[u+8],20,1163531501),p=a(p,g,b,w,m[u+13],5,-1444681467),w=a(w,p,g,b,m[u+2],9,-51403784),b=a(b,w,p,g,m[u+7],14,1735328473),p=s(p,g=a(g,b,w,p,m[u+12],20,-1926607734),b,w,m[u+5],4,-378558),w=s(w,p,g,b,m[u+8],11,-2022574463),b=s(b,w,p,g,m[u+11],16,1839030562),g=s(g,b,w,p,m[u+14],23,-35309556),p=s(p,g,b,w,m[u+1],4,-1530992060),w=s(w,p,g,b,m[u+4],11,1272893353),b=s(b,w,p,g,m[u+7],16,-155497632),g=s(g,b,w,p,m[u+10],23,-1094730640),p=s(p,g,b,w,m[u+13],4,681279174),w=s(w,p,g,b,m[u+0],11,-358537222),b=s(b,w,p,g,m[u+3],16,-722521979),g=s(g,b,w,p,m[u+6],23,76029189),p=s(p,g,b,w,m[u+9],4,-640364487),w=s(w,p,g,b,m[u+12],11,-421815835),b=s(b,w,p,g,m[u+15],16,530742520),p=c(p,g=s(g,b,w,p,m[u+2],23,-995338651),b,w,m[u+0],6,-198630844),w=c(w,p,g,b,m[u+7],10,1126891415),b=c(b,w,p,g,m[u+14],15,-1416354905),g=c(g,b,w,p,m[u+5],21,-57434055),p=c(p,g,b,w,m[u+12],6,1700485571),w=c(w,p,g,b,m[u+3],10,-1894986606),b=c(b,w,p,g,m[u+10],15,-1051523),g=c(g,b,w,p,m[u+1],21,-2054922799),p=c(p,g,b,w,m[u+8],6,1873313359),w=c(w,p,g,b,m[u+15],10,-30611744),b=c(b,w,p,g,m[u+6],15,-1560198380),g=c(g,b,w,p,m[u+13],21,1309151649),p=c(p,g,b,w,m[u+4],6,-145523070),w=c(w,p,g,b,m[u+11],10,-1120210379),b=c(b,w,p,g,m[u+2],15,718787259),g=c(g,b,w,p,m[u+9],21,-343485551),p=r(p,l),g=r(g,f),b=r(b,d),w=r(w,h);return n(p)+n(g)+n(b)+n(w)}function jl(e){const t="function"==typeof e?e.toString():e;if("string"!=typeof t)throw Error("Unexpected type "+typeof e+" while parsing function");let n,r="",o=!1,i=!1,a=!1,s="",c=0,u=0,l=[],f={},d="",h=['"',"'","`"],m=!1,p=!1,g=!1,b=!1,w=!1,y=!1,v="";for(let e=0;e<t.length;e++)if(g||"/"!==t[e]||"*"!==t[e+1])if("/"===t[e]&&"*"===t[e-1])g=!1;else if(b||"/"!==t[e]||"/"!==t[e+1])if("\n"===t[e])b=!1;else{if(g||b)continue;if(t[e]===d&&!m&&d)d="",r+=t[e];else if(d)m="\\"===t[e]&&!m,r+=t[e];else if(h.includes(t[e])&&!m)d=t[e],r+=t[e];else if("("===t[e]){if(c++,""!==r.trim()){if("function"===r.trim())a=!0;else if("async"!==r.trim()){s=r.trim();let e=s.match(/^([a-zA-Z0-9_]+)<[a-zA-Z0-9_]+>$/);e&&(s=e[1])}r=""}}else if(")"===t[e])c===u+1&&(p?(f.default=r.trim(),p=!1):r&&(f.name=r.trim()),(f.name||f.default)&&(l.push(f),f={}),r=""),u++;else if(w&&"}"!==t[e])r+=t[e];else{if(c&&c===u&&":"===t[e]){const r=t.substring(e+1).trim().match(/^\s*([a-zA-Z0-9_]+)\s*\{/);if(!r)throw Error("Unexpected ':' while parsing function");v=r[1],n=t.substring(e+r[0].length).trim();break}if(!(r||"="!==t[e]||">"!==t[e+1]||c!==u||u||o)){f.name=t.slice(0,e).trim(),l.push(f),f={},o=!0,n=bbn.fn.substr(t,e+2).trim();break}if(c===u&&"="===t[e]&&">"===t[e+1]){""!==r.trim()&&(f.name=r.trim(),l.push(f),f={},r=""),o=!0,e++;continue}if("="===t[e]&&c>u&&!p)f.name=r.trim(),r="",p=!0;else if(","===t[e])if(w)r+=t[e];else{if(!(c>u))throw Error("Unexpected ',' while parsing function");p?(f.default=r.trim(),p=!1):r&&(f.name=r.trim()),(f.name||f.default)&&(l.push(f),f={}),r=""}else if("{"===t[e]||"}"===t[e]){if(c===u){n=t.substring(e).trim();break}c>u?"{"!==t[e]||w?"}"===t[e]&&w&&(w=!1,r+=t[e]):(w=!0,r=t[e]):r=""}else{if(o){n=t.substring(t.indexOf("=>")+2).trim();break}" "===t[e]?""!==r.trim()&&("async"===r.trim()&&(i=!0),c>u?r+=t[e]:r=""):r+=t[e]}}}else b=!0,r="";else g=!0,r="";if(!n){if(!o)throw Error("Unexpected end of function while parsing function");n=r}n.substr(0,25).indexOf("[native code]")>-1&&(y=!0);const E=l.map(e=>e.name+(e.default?" = "+e.default:"")).join(", ");return{body:n,args:l,argString:E,isArrow:o,hasFunction:a,name:s,isAsync:i,isBinary:y,hash:Ol(n+(s?"-"+s:"")+(E?"-"+E:"")),returnType:v}}function Cl(e,t,n){if(n||(n=[]),e===t)return!0;if(e&&t&&"object"==typeof e&&"object"==typeof t){if(![void 0,Object,Array,null].includes(null==e?void 0:e.constructor)||![void 0,Object,Array,null].includes(null==t?void 0:t.constructor))return!1;let r=Object.keys(e).sort(),o=Object.keys(t).sort();if(xl(r)!==xl(o))return!1;let i=!0;if(e&&"object"==typeof e){if(n.includes(e))return i;n.push(e)}return al(r,n=>{if(!Cl(e[n],t[n]))return i=!1,!1}),i}if(e&&t&&"function"==typeof e&&"function"==typeof t){let n=jl(e),r=jl(t),o=n.hash===r.hash;return o&&n.isBinary&&(o=!1),o}return!1}function Rl(e,t,n){switch(n){case"===":case"=":case"equal":case"eq":case"is":return e===t;case"!==":case"notequal":case"neq":case"isnot":return e!==t;case"!=":case"different":return e!=t;case"contains":case"contain":case"icontains":case"icontain":return!vl(e)&&!vl(t)&&-1!==gl(e).toLowerCase().indexOf(gl(t).toLowerCase());case"doesnotcontain":case"donotcontain":return!(!El(e)&&!El(t))||-1===gl(e.toLowerCase()).indexOf(gl(t.toLowerCase()));case"starts":case"start":return!El(e)&&!El(t)&&("string"!=typeof e&&(e=e.toString()||""),"string"!=typeof t&&(t=t.toString()||""),0===e.indexOf(t));case"startswith":case"startsi":case"starti":case"istarts":case"istart":return!El(e)&&!El(t)&&0===gl(e).toLowerCase().indexOf(gl(t).toLowerCase());case"endswith":case"endsi":case"endi":case"iends":case"iend":return!El(e)&&!El(t)&&e.lastIndexOf(t)===e.length-t.length;case"like":return!El(e)&&!El(t)&&gl(e).toLowerCase()===gl(t).toLowerCase();case"gt":case">":return e>t;case"gte":case">=":return e>=t;case"lt":case"<":return e<t;case"lte":case"<=":return e<=t;case"isnull":return null===e;case"isnotnull":return null!==e;case"isempty":return""===e;case"isnotempty":return""!==e;case"==":if(sl(e,t))return Cl(e,t);default:return e==t}}function Nl(e,t){if(!t.conditions||!t.logic||!cl(t.conditions))throw new Error("Error in compareConditions: the filter should an abject with conditions and logic properties and conditions should be an array of objects");let n="AND"===t.logic;return al(t.conditions,r=>{let o;if(r.conditions&&cl(r.conditions))o=Nl(e,r);else if(o=Rl(pl(e,r.field),r.value,r.operator),o){let t=r.field.split("."),n=t.pop();t.length&&al(t,t=>e=e[t]),void 0===pl(e,n)&&void 0!==r.value&&(o=!1)}if(o){if("OR"===t.logic)return n=!0,!1}else if("AND"===t.logic)return n=!1,!1}),n}function Pl(e,t="="){if(!sl(e))throw new Error("Error in filterToCondition: filter must be an object");if(!e.conditions||!cl(e.conditions)){let n=[];il(e,(e,r)=>{sl(e)&&"object"==typeof e.conditions?n.push(Pl(e)):n.push({field:r,operator:t,value:e})}),e={conditions:n}}return e.logic||(e.logic="AND"),e}function Yl(e,t,n=null,r="=",o=0,i=!1){if(!Xu(e))throw new Error(bbn._("The first argument for a search should be iterable")+" "+typeof e+" "+bbn._("given"));if(!e.length)return-1;let a,s,c=!1;if(t)if("string"==typeof t)a={conditions:[{field:t,value:n,operator:r||"="}]};else if(i=!0===r,o="number"==typeof n?n:i?e.length-1:0,"function"==typeof t)c=!0,s=t;else if(sl(t))if("field"in t&&"value"in t)a={conditions:[t],logic:"AND"};else if("conditions"in t)a=t;else{const e=[];for(let n in t)e.push({field:n,value:t[n],operator:"="});a={conditions:e,logic:"AND"}}else cl(t)&&(a={conditions:t,logic:"AND"});else c=!0,s=e=>Nl({value:e},Pl({logic:"AND",conditions:[{field:"value",operator:r||"=",value:n}]}));if(c||a){if("number"!=typeof o&&(o=i?e.length-1:0),!s){const e=Pl(a);s=t=>Nl(t,e)}if(i)for(let t=o;t>=0;t--){if(bbn.env._enumerated.push(!0),s(e[t]))return bbn.env._enumerated.pop(),e[t],t;bbn.env._enumerated.pop()}else for(let t=o;t<e.length;t++){if(bbn.env._enumerated.push(!0),s(e[t]))return bbn.env._enumerated.pop(),e[t],t;bbn.env._enumerated.pop()}}return-1}function Al(e,t,n=null,r="=",o=0,i=!1,a=!1){let s=Yl(e,t,n,r,o,i);return s>-1?e[s]:t&&["object","function"].includes(typeof t)&&5 in arguments?i:a}function Ll(e,t=null,n=!1){let r=Yl(bbn.env.loaders,{key:e});if(r>-1){let o=bbn.env.loaders.splice(r,1)[0],i=Al(bbn.env.loadersHistory,{key:e,start:o.start});return i&&(i.loading=!1,i.duration=(new Date).getTime()-o.start,"string"==typeof t?(i.errorMessage=t,i.error=!n,i.abort=n):sl(t)&&(i.success=!0)),!0}return!1}function Fl(e){let t=Yl(bbn.env.loaders,{key:e});return t>-1?bbn.env.loaders[t]:null}function Hl(e,t,n=null,r="=",o=0){if(!cl(e))try{e=Array.from(e)}catch(t){throw bbn.fn.log("NOT ARRAY",e),new Error("Error in filter: The first argument must be an array")}let i={};const a=[],s="function"==typeof t;if(!t||!e.length)return e;if("object"==typeof t)i=t;else if("string"==typeof t)i[t]=n;else if(!s)throw new Error("Search function error: The prop argument should be a string or an object");let c;c="function"==typeof t?t:(e,t)=>Nl(e,i);for(let t=0;t<e.length&&(bbn.env._enumerated.push(!0),!(c(e[t],t)&&(bbn.env._enumerated.pop(),a.push(e[t]),bbn.env._enumerated.push(!0),o&&a.length>=o)));t++)bbn.env._enumerated.pop();return a}function Bl(e){if(yl(e)){bbn.var.colors||(bbn.var.colors={});let t=document.createElement("style");document.head.appendChild(t);let n=t.sheet,r=0;il(e,(e,t)=>{bbn.var.colors[t]=e,n.insertRule(".bbn-"+t+", .bbn-color-text-"+t+" {color: "+e+" !important;}",r),n.insertRule("svg.bbn-"+t+", .bbn-"+t+" svg, svg.bbn-color-text-"+t+", .bbn-color-text-"+t+" svg {fill: "+e+";}",r),n.insertRule(".bbn-bg-"+t+", .bbn-color-bg-"+t+", .bbn-color-background-"+t+" {background-color: "+e+" !important;}",r),n.insertRule(".bbn-border-"+t+", .bbn-color-border-"+t+" {border-color: "+e+" !important;}",r),n.insertRule(".bbn-color-"+t+" {border-color: "+e+"; background-color: "+e+"; color: "+e+";}",r)})}}function Ul(e,t=null,n=""){if(e&&"FORM"===e.tagName){let r=(t,n)=>{let r=document.createElement("input");r.setAttribute("type","hidden"),r.setAttribute("name",t),r.setAttribute("value",n),e.appendChild(r)};t=JSON.parse(JSON.stringify(t||{})),n=n||"",t&&il(t,(t,o)=>{let i=n?`${n}[${o}]`:o;t instanceof Date?r(i,t.toISOString()):t instanceof Array?t.forEach((t,n)=>{const o=`${i}[${n}]`;"object"==typeof t?Ul(e,t,o):r(o,t.toString())}):"object"!=typeof t||t instanceof File?r(i,t.toString()):Ul(e,t,i)})}}function Zl(e,t){let n=0;al(t,t=>{t.style[e]="auto"}),al(t,(t,r)=>{let o=t.getBoundingClientRect(),i=o[e]%1?o[e]-o[e]%1+1:o[e];i>n&&(n=i)}),al(t,(t,r)=>{n&&(t.style[e]=n+"px")})}function Wl(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}function $l(e,t,n,r=""){return n.toString().replace(sl(e)?e:new RegExp(Wl(e),"g"+r),t)}function ql(e,t,n){let r={};return t&&il(t,(e,t)=>{-1===t.indexOf("_bbn")&&(r[t]=e)}),e+":"+Ol((n||"json")+JSON.stringify(r))}function zl(e,t=null,n=null,r=null,o=null,i=null){if(null===t&&e&&"object"==typeof e&&e.url&&(e.abort&&(i=e.abort),e.failure&&(o=e.failure),e.success&&(r=e.success),e.data&&(n=e.data),e.datatype&&(t=e.datatype),e=e.url),e&&e&&"string"==typeof e){-1===e.indexOf("://")&&(e=$l("//","/",e)),t||(t="json");let a=ql(e,n,t),s=Fl(a);if(null==s?void 0:s.loader)return s.loader;bbn.env.token&&ul(n||{},{_bbn_token:bbn.env.token});const c=new AbortController;let u={responseType:t,signal:c.signal};"text"===t?u.headers={accept:"text/javascript","Content-Type":"text/javascript"}:"json"===t?u.headers={accept:"application/json","Content-Type":"application/json"}:"html"===t&&(u.headers={accept:"text/html","Content-Type":"text/html"});let l="get";sl(n)&&yl(n)>0&&(u.data=n,l="post");let f=Gu.run(l,e,u).then(t=>{if(Ll(a,t),bbn.fn.defaultEndLoadingFunction(e,d,n,t),200===t.status)tl(r)&&r(t.data,t.headers);else{let e=1;tl(o)&&(e=o(f,t.message,t)),e&&bbn.fn.defaultAjaxErrorFunction(f,t.message,t)}return t}).catch(t=>{let r=Gu.isCancel(t);if(Ll(a,t.message||t.response.data,r),bbn.fn.defaultEndLoadingFunction(e,d,n,t),r){let n=1;tl(i)&&(n=i(t.message,e)),n&&bbn.fn.defaultAjaxAbortFunction(t.message,e)}else{let e=1;tl(o)&&(e=o(f,t.message,t)),e&&bbn.fn.defaultAjaxErrorFunction(f,t.message,t.response)}return t.response}),d=ml(a,f,c);return bbn.fn.defaultStartLoadingFunction(e,d,n,a),f}}const Vl=new TextDecoder;function Jl(e){return Vl.decode(e)}function Gl(e,t){if(e&&Qu(e)){let n=e.split("/").pop();if(!t)return n;let r=t.length;if(n&&rl(n,-r)===t)return rl(n,0,n.length-r)}return""}function Kl(...e){if(!e.length)return!1;for(let t of e)if(null!==t&&("object"==typeof t||"function"==typeof t))return!1;return!0}var Xl,Ql,ef,tf,nf,rf,of,af=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},sf=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};const cf=[{name:"mariadb-datetime",re:/^(\d{4})-(\d{2})-(\d{2})[ T](\d{2}):(\d{2}):(\d{2})$/,map:e=>({year:+e[1],month:+e[2],day:+e[3],hour:+e[4],minute:+e[5],second:+e[6]})},{name:"mariadb-datetime-no-sec",re:/^(\d{4})-(\d{2})-(\d{2})[ T](\d{2}):(\d{2})$/,map:e=>({year:+e[1],month:+e[2],day:+e[3],hour:+e[4],minute:+e[5],second:0})},{name:"mariadb-date",re:/^(\d{4})-(\d{2})-(\d{2})$/,map:e=>({year:+e[1],month:+e[2],day:+e[3],hour:0,minute:0,second:0})},{name:"iso-datetime",re:/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2})(?::(\d{2}))?(?:\.\d+)?(?:Z|[+\-]\d{2}:?\d{2})?$/,map:e=>({year:+e[1],month:+e[2],day:+e[3],hour:+e[4],minute:+e[5],second:void 0!==e[6]?+e[6]:0})},{name:"slash-date",re:/^(\d{2})\/(\d{2})\/(\d{4})$/,map:e=>({year:+e[3],month:+e[2],day:+e[1],hour:0,minute:0,second:0})},{name:"slash-datetime",re:/^(\d{2})\/(\d{2})\/(\d{4})[ T](\d{2}):(\d{2}):(\d{2})$/,map:e=>({year:+e[3],month:+e[2],day:+e[1],hour:+e[4],minute:+e[5],second:+e[6]})}],uf=[["y","year",31536e6],["m","month",2592e6],["w","week",6048e5],["d","day",864e5],["h","hour",36e5],["i","minute",6e4],["s","second",1e3]],lf={y:"Year",m:"Month",d:"Date",w:"Week",h:"Hours",i:"Minutes",s:"Seconds"},ff={y:"YYYY",m:"MM",d:"DD",e:"EE",w:"WW",h:"HH",i:"II",s:"SS"},df={years:"y",year:"y",YEARS:"y",YEAR:"y",Years:"y",Year:"y",YYYY:"y",YY:"y",yyyy:"y",yy:"y",months:"m",month:"m",Months:"m",Month:"m",MONTHS:"m",MONTH:"m",MMMM:"m",MMM:"m",MM:"m",weekday:"e",WEEKDAY:"e",ee:"e",EE:"e",ddd:"e",days:"d",day:"d",Days:"d",Day:"d",DAYS:"d",DAY:"d",DD:"d",dd:"d",hours:"h",hour:"h",Hours:"h",Hour:"h",HOURS:"h",HOUR:"h",HH:"h",hr:"h",hh:"h",minutes:"i",minute:"i",Minutes:"i",Minute:"i",MINUTES:"i",MINUTE:"i",II:"i",ii:"i",mn:"i",mm:"i",min:"i",SS:"s",ss:"s",seconds:"s",second:"s",Seconds:"s",Second:"s",SECONDS:"s",SECOND:"s",sec:"s",WW:"w",Y:"y",y:"y",M:"m",m:"m",e:"e",E:"e",D:"d",d:"d",H:"h",h:"h",n:"i",i:"i",s:"s",S:"s",W:"w",w:"w"},hf={};class mf{constructor(e,t,n=!1){Xl.add(this),Ql.set(this,0),ef.set(this,"");const r=df[t]||t;if(!r)throw new Error("Invalid unit for duration: "+t);af(this,ef,r,"f");const o=Al(uf,e=>e[0]===r);if(!o)throw new Error("Invalid unit for duration: "+r);const i=o[2];af(this,Ql,n?e:e*i,"f")}years(e=!1){return sf(this,Xl,"m",nf).call(this,"year",e)}months(e=!1){return sf(this,Xl,"m",nf).call(this,"month",e)}weeks(e=!1){return sf(this,Xl,"m",nf).call(this,"week",e)}days(e=!1){return sf(this,Xl,"m",nf).call(this,"day",e)}hours(e=!1){return sf(this,Xl,"m",nf).call(this,"hour",e)}minutes(e=!1){return sf(this,Xl,"m",nf).call(this,"minute",e)}seconds(e=!1){return sf(this,Xl,"m",nf).call(this,"second",e)}toJSON(){return{years:this.years(!0),months:this.months(!0),days:this.days(!0),hours:this.hours(!0),minutes:this.minutes(!0),seconds:this.seconds(!0),milliseconds:this.toMilliseconds()}}asYears(){const[,,e]=sf(this,Xl,"m",tf).call(this,"year");return sf(this,Ql,"f")/e}asMonths(){const[,,e]=sf(this,Xl,"m",tf).call(this,"month");return sf(this,Ql,"f")/e}asWeeks(){const[,,e]=sf(this,Xl,"m",tf).call(this,"week");return sf(this,Ql,"f")/e}asDays(){const[,,e]=sf(this,Xl,"m",tf).call(this,"day");return sf(this,Ql,"f")/e}asHours(){const[,,e]=sf(this,Xl,"m",tf).call(this,"hour");return sf(this,Ql,"f")/e}asMinutes(){const[,,e]=sf(this,Xl,"m",tf).call(this,"minute");return sf(this,Ql,"f")/e}asSeconds(){const[,,e]=sf(this,Xl,"m",tf).call(this,"second");return sf(this,Ql,"f")/e}add(e,t){const n=t?df[t]||t:sf(this,ef,"f"),r=Al(uf,e=>e[0]===n);if(!r)throw new Error("Invalid unit for duration: "+(null!=t?t:n));return new mf(sf(this,Ql,"f")+e*r[2],sf(this,ef,"f"),!0)}subtract(e,t){return this.add(-e,t)}toMilliseconds(){return sf(this,Ql,"f")}}Ql=new WeakMap,ef=new WeakMap,Xl=new WeakSet,tf=function(e){const t=Al(uf,t=>t[1]===e);if(!t)throw new Error("Unit name not found: "+e);return t},nf=function(e,t){const n=uf.findIndex(([,t])=>t===e);if(-1===n)throw new Error("Unit not found: "+e);const r=uf[n][2];if(!t)return Math.floor(sf(this,Ql,"f")/r);let o=sf(this,Ql,"f");for(let e=0;e<n;e++){const[,,t]=uf[e];o-=Math.floor(o/t)*t}return Math.floor(o/r)};class pf{static parse(e,t,n){var r,o,i,a;"monthsLong"in hf||ul(hf,(()=>{const e=[bbn.env.lang,...navigator.languages],t=new Intl.DateTimeFormat(e,{month:"long"}),n=new Intl.DateTimeFormat(e,{month:"short"}),r=new Intl.DateTimeFormat(e,{weekday:"long"}),o=new Intl.DateTimeFormat(e,{weekday:"short"}),i=[],a=[];for(let e=0;e<12;e++){const r=new Date(2020,e,1);i.push(t.format(r)),a.push(n.format(r))}const s=new Date(2020,1,2),c=[],u=[];for(let e=0;e<7;e++){const t=new Date(s.getTime()+864e5*e);c.push(r.format(t)),u.push(o.format(t))}return{monthsLong:i,monthsShort:a,weekdaysLong:c,weekdaysShort:u}})());const s={monthsLong:null!==(r=null==n?void 0:n.monthsLong)&&void 0!==r?r:hf.monthsLong,monthsShort:null!==(o=null==n?void 0:n.monthsShort)&&void 0!==o?o:hf.monthsShort,weekdaysLong:null!==(i=null==n?void 0:n.weekdaysLong)&&void 0!==i?i:hf.weekdaysLong,weekdaysShort:null!==(a=null==n?void 0:n.weekdaysShort)&&void 0!==a?a:hf.weekdaysShort},c={year:1970,month:1,day:1,hour:0,minute:0,second:0,ms:0},u=e=>e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),l=[{token:"YYYY",regex:"\\d{4}",apply:e=>{c.year=parseInt(e,10)}},{token:"YY",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);c.year=t>=70?1900+t:2e3+t}},{token:"Y",regex:"[+-]?\\d{1,6}",apply:e=>{c.year=parseInt(e,10)}},{token:"MMMM",regex:"[^\\d\\s]+",apply:e=>{const t=s.monthsLong.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid month name: "+e);c.month=t+1}},{token:"MMM",regex:"[^\\d\\s]+",apply:e=>{const t=s.monthsShort.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid short month name: "+e);c.month=t+1}},{token:"MM",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>12)throw new Error("Invalid month: "+t);c.month=t}},{token:"mm",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid minute: "+t);c.month=t}},{token:"M",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>12)throw new Error("Invalid month: "+t);c.month=t}},{token:"m",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>12)throw new Error("Invalid month: "+t);c.month=t}},{token:"DD",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>31)throw new Error("Invalid day of month: "+t);c.day=t}},{token:"D",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>31)throw new Error("Invalid day of month: "+t);c.day=t}},{token:"d",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>31)throw new Error("Invalid day of month: "+t);c.day=t}},{token:"dddd",regex:"[^\\d\\s]+",apply:e=>{const t=s.weekdaysLong.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid weekday name: "+e);c.weekday=t}},{token:"ddd",regex:"[^\\d\\s]+",apply:e=>{const t=s.weekdaysShort.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid short weekday name: "+e);c.weekday=t}},{token:"EE",regex:"\\d{1}",apply:e=>{const t=parseInt(e,10);if(t<0||t>7)throw new Error("Invalid weekday number: "+t);c.weekday=t}},{token:"HH",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>23)throw new Error("Invalid hour: "+t);c.hour=t}},{token:"H",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>23)throw new Error("Invalid hour: "+t);c.hour=t}},{token:"h",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>23)throw new Error("Invalid hour: "+t);c.hour=t}},{token:"II",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid minute: "+t);c.minute=t}},{token:"I",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid minute: "+t);c.minute=t}},{token:"i",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid minute: "+t);c.minute=t}},{token:"SS",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid second: "+t);c.second=t}},{token:"S",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid second: "+t);c.second=t}},{token:"s",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);if(t<0||t>59)throw new Error("Invalid second: "+t);c.second=t}},{token:"ms",regex:"\\d{1,3}",apply:e=>{const t=parseInt(e,10);if(t<0||t>999)throw new Error("Invalid millisecond: "+t);c.ms=t}},{token:"WWWW",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>53)throw new Error("Invalid week number: "+t);c.week=t}},{token:"WWW",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>53)throw new Error("Invalid week number: "+t);c.week=t}},{token:"WW",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>53)throw new Error("Invalid week number: "+t);c.week=t}},{token:"W",regex:"\\d{1,2}",apply:e=>{const t=parseInt(e,10);if(t<1||t>53)throw new Error("Invalid week number: "+t);c.week=t}}],f=[...l].sort((e,t)=>t.token.length-e.token.length);let d="";const h=[];let m=0;for(;m<t.length;){let e=null;for(const n of f)if(t.startsWith(n.token,m)){e=n;break}e?(d+=`(${e.regex})`,e.apply?h.push(e.apply):h.push(()=>{}),m+=e.token.length):(d+=u(t[m]),m+=1)}const p=new RegExp("^"+d+"$").exec(e);if(!p)throw new Error(`Date string "${e}" does not match format "${t}"`);for(let e=1;e<p.length;e++){const t=p[e],n=h[e-1];null!=t&&n&&n(t)}const g=new Date(c.year,c.month-1,c.day,c.hour,c.minute,c.second,c.ms);if(g.getFullYear()!==c.year||g.getMonth()!==c.month-1||g.getDate()!==c.day||g.getHours()!==c.hour||g.getMinutes()!==c.minute||g.getSeconds()!==c.second||g.getMilliseconds()!==c.ms)throw new Error("Invalid date produced from components");return void 0!==c.weekday&&g.getDay(),g}static compare(e,t,n=""){var r;const o=e instanceof pf?e:new pf(e),i=t instanceof pf?t:new pf(t),a=df[n]||null;if(!a)return o.mtst<i.mtst?-1:o.mtst>i.mtst?1:0;const s=["y","m","d","h","i","s"];for(const e of s){const t=null===(r=Al(uf,t=>t[0]===e))||void 0===r?void 0:r[1],n=i[t](),s=o[t]();if(n<s)return-1;if(n>s)return 1;if(e===a)break}return 0}constructor(e,t=null){rf.set(this,void 0),of.set(this,!1);let n=typeof e;if(e)if(t)this.matchFormat(e,t)&&af(this,rf,pf.parse(e,t),"f");else if(("number"===n||Ku(e)&&""!==e)&&(e<5e3&&Ku(t)?e=Array.from(arguments):e<1e10&&(e*=1e3),Array.isArray(e)||af(this,rf,new Date(e),"f")),"string"===n){for(const t of cf){const n=e.match(t.re);if(n){const{year:e,month:r,day:o,hour:i,minute:a,second:s}=t.map(n);af(this,rf,new Date(e,r-1,o,i,a,s,0),"f")}}if(!sf(this,rf,"f"))throw new Error("Invalid date string format: "+e)}else bl(e)?af(this,rf,e,"f"):Array.isArray(e)&&af(this,rf,new Date(...e),"f");else af(this,rf,new Date,"f")}parse(e,t){const n=pf.parse(e,t);return new pf(n)}matchFormat(e,t){try{return pf.parse(e,t),!0}catch(e){return!1}}toString(){return sf(this,rf,"f")?this.format():""}year(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setFullYear(e),new pf(t)}return sf(this,rf,"f").getFullYear()}}month(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setMonth(e-1),new pf(t)}return sf(this,rf,"f").getMonth()+1}}day(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setDate(e),new pf(t)}return sf(this,rf,"f").getDate()}}hour(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setHours(e),new pf(t)}return sf(this,rf,"f").getHours()}}minute(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setMinutes(e),new pf(t)}return sf(this,rf,"f").getMinutes()}}second(e){if(sf(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setSeconds(e),new pf(t)}return sf(this,rf,"f").getSeconds()}}weekday(e,t=!1){if(sf(this,rf,"f"))return!(0 in arguments)||void 0===e||e instanceof Event?sf(this,rf,"f").getDay():this.setWeekday(e,t)}week(){const e=new Date(Date.UTC(this.year(),this.month()-1,this.day())),t=e.getUTCDay()||7;e.setUTCDate(e.getUTCDate()+(4-t));const n=new Date(Date.UTC(e.getUTCFullYear(),0,1));return Math.ceil(((e.getTime()-n.getTime())/864e5+1)/7)}get tst(){return Math.ceil(sf(this,rf,"f").getTime()/1e3)}get mtst(){return sf(this,rf,"f").getTime()}get YYYY(){return this.year().toString()}get YY(){return rl(this.year().toString(),2,2)}get MMMM(){return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],{month:"long"}).format(sf(this,rf,"f"))}get MMM(){return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],{month:"short"}).format(sf(this,rf,"f"))}get MM(){const e=parseInt(this.month().toString());return e<10?"0"+e.toString():e.toString()}get M(){return this.month().toString()}get EE(){return this.weekday().toString()}get DD(){const e=parseInt(this.day().toString());return e<10?"0"+e.toString():e.toString()}get d(){return this.day().toString()}get dddd(){return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],{weekday:"long"}).format(sf(this,rf,"f"))}get ddd(){return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],{weekday:"short"}).format(sf(this,rf,"f"))}get D(){return this.day().toString()}get HH(){const e=parseInt(this.hour().toString());return e<10?"0"+e.toString():e.toString()}get H(){return this.hour().toString()}get II(){const e=parseInt(this.minute().toString());return e<10?"0"+e.toString():e.toString()}get mm(){const e=parseInt(this.minute().toString());return e<10?"0"+e.toString():e.toString()}get I(){return this.minute().toString()}get SS(){const e=parseInt(this.second().toString());return e<10?"0"+e.toString():e.toString()}get S(){return this.second().toString()}get WW(){const e=parseInt(this.year().toString()),t=new Date(e,0,1),n=(sf(this,rf,"f").getTime()-t.getTime())/864e5;return String(Math.ceil((n+t.getDay()+1)/7)).padStart(2,"0")}get isValid(){return void 0!==sf(this,rf,"f")}dateFromFormat(e,t){return new Date}date(e){return!(0 in arguments)||void 0===e||e instanceof Event?this.format("Y-m-d"):this.parse(e,"Y-m-d")}datetime(e){return!(0 in arguments)||void 0===e||e instanceof Event?this.format("Y-m-d H:i:s"):this.parse(e,"Y-m-d H:i:s")}time(e){return!(0 in arguments)||void 0===e||e instanceof Event?this.format("H:i:s"):this.parse(e,"H:i:s")}fdate(e=!1,t=!1,n=!1){if(!sf(this,rf,"f"))return"";const r=Object.assign(Object.assign({year:"numeric",month:e?"long":"numeric",day:"numeric"},n?{weekday:e?"long":"short"}:{}),t?{hour:e?"2-digit":"numeric",minute:"2-digit"}:{});return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],r).format(sf(this,rf,"f"))}ftime(e=!1){if(!sf(this,rf,"f"))return"";const t={hour:"2-digit",minute:"2-digit"};e&&(t.second="2-digit");return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],t).format(sf(this,rf,"f"))}format(e="YYYY-MM-DD HH:II:SS"){let t="";if(e){const n=new RegExp("([|]|"+Object.keys(df).join("|")+")","g");let r=0;al(e.split(n),e=>{if("["!==e)if("]"!==e)if(r>0)t+=e;else if(e in df)if(e in this&&Kl(this[e]))t+=this[e];else{t+=this[ff[df[e]]]}else t+=e;else r--;else r++})}return t}unix(e=!1){if("number"==typeof e){const t=this.copy();return t.setTime(1e3*e),new pf(t)}return sf(this,rf,"f")?e?sf(this,rf,"f").getTime():Math.floor(sf(this,rf,"f").getTime()/1e3):0}sql(e=!1){return sf(this,rf,"f")?e?this.format("YYYY-MM-DD"):this.format("YYYY-MM-DD HH:II:SS"):""}inLeapYear(){if(this.isValid){const e=sf(this,rf,"f").getFullYear();return e%4==0&&e%100!=0||e%400==0}return!1}daysInMonth(){if(this.isValid)switch(sf(this,rf,"f").getMonth()){case 1:return sf(this,rf,"f").getFullYear()%4==0?29:28;case 0:case 3:case 5:case 8:case 10:return 30;default:return 31}}valueOf(){return this.mtst}compare(e,t=""){return pf.compare(this,e,t)}add(e,t="d"){const n=sf(this,rf,"f")?new Date(sf(this,rf,"f").getTime()):new Date;if(df[t]){const r=df[t],o="y"===r?"FullYear":lf[r],i="get"+o;return n["set"+o](n[i]()+e),new pf(n)}return null}subtract(e,t){return this.add(-e,t)}isBefore(e,t=""){return-1===this.compare(e,t)}isAfter(e,t="day"){return 1===this.compare(e,t)}isSame(e,t="day"){return 0===this.compare(e,t)}isAfterOrSame(e,t=""){return[0,1].includes(this.compare(e,t))}isBeforeOrSame(e,t=""){return[-1,0].includes(this.compare(e,t))}fromNow(e=""){const t=new Date,n=df[e]||this.guessUnit(this.diff(t)),r=this.diff(t,n),o=new Intl.RelativeTimeFormat([bbn.env.lang,...navigator.languages],{numeric:"auto"}),i=Al(uf,e=>e[0]===n);if(!i)throw new Error("Invalid unit for fromDate: "+e);return o.format(r,i[1])}fromDate(e,t=""){const n=df[t]||this.guessUnit(this.diff(e)),r=this.diff(e,n);return r>0?Zu("%d %s before",r,t):r<0?Zu("%d %s after",-r,t):Zu("The same %s",t)}guessUnit(e){const t=Math.abs(e);for(const[e,n,r]of uf)if(t>=r||"second"===n)return e}diff(e,t="",n=!1){const r=e instanceof pf?e.mtst:new Date(e).getTime();let o=this.mtst-r;if(n&&(o=Math.abs(o)),!t)return o;const i=df[t],a=Al(uf,e=>e[0]===i);if(!a)throw new Error("Invalid unit for diff: "+t);const[s,c,u]=a;return Math.round(o/u)}calendar(e){return""}getWeekday(e,t="long",n){if(!t){const t=this.getWeekday(e,"narrow",n),r=this.getWeekday(e,"short",n),o=this.getWeekday(e,"long",n);return{letter:t,abbr:r,full:o,long:o,short:r,narrow:t}}let r;if("letter"===t)r="narrow";else if("abbr"===t)r="short";else if("full"===t)r="long";else{if(!["long","short","narrow"].includes(t))throw new Error("Invalid mode for getWeekDay: "+t+'. Allowed values are "long", "short", "narrow", "letter", "abbr", "full".');r=t}return new Date(2023,0,1+e).toLocaleDateString([n||bbn.env.lang,...navigator.languages],{weekday:r})}getWeekdayIndex(e,t){const n=t||bbn.env.lang,r=e.trim().toLowerCase(),o=[n,...navigator.languages];for(let e=0;e<o.length;e++){if(!o[e])continue;const t=new Intl.DateTimeFormat(o[e],{weekday:"long"});for(let e=0;e<7;e++){const n=new Date(2023,0,1+e);if(t.format(n).toLowerCase()===r)return e}}throw new Error(`Unknown weekday name '${e}' for locale '${n}'`)}setWeekday(e,t=!1,n){let r;if("string"==typeof e&&(e=this.getWeekdayIndex(e,n)),"number"!=typeof e)throw new TypeError("weekday must be a number (0–6) or a string");if(e<0||e>6)throw new RangeError("weekday number must be between 0 and 6");r=e;const o=this.weekday();let i;t?(i=(o-r+7)%7,0===i&&(i=7),i=-i):(i=(r-o+7)%7,0===i&&(i=7));const a=this.copy();return a.setDate(a.getDate()+i),new pf(a)}copy(){return new Date(sf(this,rf,"f").getTime())}clone(){return new pf(sf(this,rf,"f")?new Date(sf(this,rf,"f").getTime()):void 0)}startOf(e="d"){const t=df[e];if(!t)throw new Error("Invalid unit for startOf: "+e);let n;switch(t){case"y":n=new Date(this.year(),0,1,0,0,0,0);break;case"m":n=new Date(this.year(),this.month()-1,1,0,0,0,0);break;case"w":{const e=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),this.second(),0),t=(e.getDay()+6)%7;n=new Date(e.getFullYear(),e.getMonth(),e.getDate()-t,0,0,0,0);break}case"d":n=new Date(this.year(),this.month()-1,this.day(),0,0,0,0);break;case"h":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),0,0,0);break;case"i":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),0,0);break;case"s":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),this.second(),0);break;default:throw new Error("Invalid unit for startOf: "+e)}return new pf(n)}endOf(e="d"){const t=df[e];if(!t)throw new Error("Invalid unit for endOf: "+e);let n;switch(t){case"y":n=new Date(this.year(),11,31,23,59,59,999);break;case"m":n=new Date(this.year(),this.month(),0,23,59,59,999);break;case"w":{const e=this.startOf("w"),t=new Date(e.year(),e.month()-1,e.day(),23,59,59,999);t.setDate(t.getDate()+6),n=t;break}case"day":n=new Date(this.year(),this.month()-1,this.day(),23,59,59,999);break;case"hour":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),59,59,999);break;case"minute":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),59,999);break;case"second":n=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),this.second(),999);break;default:n=new Date(this.mtst)}return new pf(n)}duration(e,t="s"){return new mf(e,t)}}function gf(e,t=null){return e instanceof pf?e:new pf(e,t)}function bf(e){if(arguments.length>1){const e=[];for(let t=1;t<arguments.length;t++)e.push(arguments[t]);e.unshift({_bbn_console_mode:"error",_bbn_console_level:1,_bbn_console_style:"color: #E64141; background: #F7E195; font-size: 14px"}),nl.apply(this,e)}throw new Error(e)}function wf(e,t=null,n=null,r=null,o=null){let i=!1;if(t){i=!0;let a,s="object"===(typeof t).toLowerCase();if(s&&t.prescript)try{new Function(t.prescript)()}catch(e){bf(e.message||"")}if(s&&void 0===t.url&&(t.url=e),i=n&&tl(n)?n(t,o):bbn.fn.defaultLinkFunction(t,o),o&&s&&void 0!==t.content&&("value"in o?o.value=t.content:o.innerHTML=t.content),i&&s&&t.script&&(i="function"==typeof t.script?t.script(t.data?t.data:{},o||null):((e,n)=>{let r=null;try{r=new Function(t.script)(),tl(r)&&(r=r(e,n))}catch(e){nl(e,t),bf(tl(e.getMessage)?e.getMessage():null)}return r})(t.data?t.data:{},o||!1)),i&&r&&tl(r)?r(t):s&&bbn.fn.defaultPostLinkFunction&&bbn.fn.defaultPostLinkFunction(t,o),i&&s&&t.postscript){new Function(t.postscript)(t.postscript)}s&&t.error&&(a=t.errorTitle||bbn.lng.server_response,bbn.fn.defaultErrorFunction(t.error,a))}else bbn.fn.defaultErrorFunction(bbn.lng.errorText,bbn.lng.error);return i}function yf(e,t,n=!1){let r={error:!1,result:!0};if("string"==typeof t&&(t=[t]),cl(t)||(r.error=bbn._("checkProps must receive a string or an array as props argument")),sl(e)||(r.error=bbn._("checkProps must receive an object as obj argument")),!r.error){let o;al(t,t=>{let i=(t=t.trim().split(":"))[1]||!1;if(t=t[0],void 0===e[t]?r.error=t+" "+bbn._("is not defined"):i?(o="is"+rl(i,0,1).toUpperCase()+rl(i,1).toLowerCase(),void 0===bbn.fn[o]?r.error=i+" "+bbn._("is not a valid type"):bbn.fn[o](e[t])||(r.error=t+" "+bbn._("is not a")+" "+i)):n&&!e[t]&&(r.error=t+" "+bbn._("is empty")),r.error)return!1})}return r.error&&(r.result=!1),r}function vf(e){return e.replace(/[A-z]{1}/,e=>e.toUpperCase())}function Ef(e,t,n,...r){let o=!1;cl(t)||(t=[t]);const i=[];if(al(t,t=>{var n;if(t===String?t="string":t===Number?t="number":t===Array?t="array":t===Boolean?t="boolean":t===Object?t="object":t===Function&&(t="function"),tl(t)){if(i.push(t.name||(null===(n=t.constructor)||void 0===n?void 0:n.name)||t.toString()),e instanceof t)return o=!0,!1}else if(Qu(t)&&tl(bbn.fn["is"+vf(t)])){if(bbn.fn["is"+vf(t)](e))return o=!0,!1;i.push(t)}else bf(`The type ${t} is not recognized`)}),!o)throw nl(["Value given",e,"type",typeof e,"expected",i.join(" or ")]),r.length&&nl(r),new Error((n?n+" - ":"")+bbn._("The value should be a %s",i.join(" "+bbn._("or a")+" ")))}function Mf(e){if(cl(e))return e.slice().map(e=>"object"==typeof e?Mf(e):e);if(sl(e)){return ul(!0,Object.create(Object.getPrototypeOf(e)),e)}return e}rf=new WeakMap,of=new WeakMap;const If=(e,t="text/plain")=>{const n=new DataTransfer;n.setData(t,e);const r=new ClipboardEvent("copy",{bubbles:!0,cancelable:!0,clipboardData:n});document.dispatchEvent(r)};function Df(e,t,n=null,r="="){if(!cl(e))throw bbn.fn.log("NOT ARRAY",e),new Error("Error in filter: The first argument must be an array");let o={};const i=[],a="function"==typeof t;if(!t||!e.length)return e;if("object"==typeof t)r=n,o=t;else if("string"==typeof t)o[t]=n;else if(!a)throw new Error("Search function error: The prop argument should be a string or an object");if("function"==typeof t)for(let n=0;n<e.length;n++)t(e[n],n)&&i.push(e[n]);else if(o=Pl(o,r),o.conditions&&o.logic)for(let t=0;t<e.length;t++)Nl(e[t],o)&&i.push(e[t]);return i}const Sf=[];for(let e=0;e<256;e++){let t=e;for(let e=0;e<8;e++)t=1&t?3988292384^t>>>1:t>>>1;Sf.push(t)}function kf(...e){const t=Object.create(null);return e.length&&ul(t,...e),t}function Tf(e){let t=typeof e;if(void 0===e)return new Date;if("number"===t||Ku(e)&&""!==e)return e<1e10&&(e*=1e3),new Date(e);if("string"===t){if(10===e.length)return new Date(parseInt(rl(e,0,4)),parseInt(rl(e,5,2))-1,parseInt(rl(e,8,2)),12);if(19===e.length)return new Date(parseInt(rl(e,0,4)),parseInt(rl(e,5,2))-1,parseInt(rl(e,8,2)),parseInt(rl(e,11,2)),parseInt(rl(e,14,2)),parseInt(rl(e,17,2)))}else if(bl(e))return e;return!1}function _f(e,t=""){nl(e)}function xf(e,t=null,n=null){nl(t,n)}function Of(e,t,n=null,r=null){return!0}function jf(...e){if(!e.length)return!1;for(let t of e)if("object"==typeof t&&!El(t))return!1;return!0}let Cf=[];function Rf(e){if(Qu(e)&&e){for(;"/"===rl(e,e.length-1);)e=rl(e,0,e.length-1);let t=e.lastIndexOf("/");if(t>0)return rl(e,0,t);if(0===t)return"/"}return""}function Nf(...e){if(!e.length)return!1;for(let t of e)if("[object Blob]"!=={}.toString.apply(t))return!1;return!0}function Pf(e){if(e&&Qu(e)){let t=e.split(".");if(t[0]&&t.length>1)return t[t.length-1].toLowerCase()}return""}function Yf(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof HTMLCanvasElement))return!1;return!0}function Af(e,t,n=null){if(Yf(t))return void t.toBlob(t=>{let n=document.createElement("a");n.download=e,n.href=window.URL.createObjectURL(t),n.className="bbn-no",n.click(),window.URL.revokeObjectURL(n.href)},n||"image/png");n?-1===n.indexOf("/")&&(n="text/"+n):n=sl(t)&&t.type?t.type:"octet/stream";let r=window.document.createElement("a");r.className="bbn-no";let o=null;if(Qu(t))o=new Blob([t],{type:n});else try{o=t}catch(e){nl(e)}r.href=window.URL.createObjectURL(o),r.download=e,document.body.appendChild(r),r.click(),window.URL.revokeObjectURL(r.href),document.body.removeChild(r)}var Lf=function(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function s(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}c((r=r.apply(e,t||[])).next())})};function Ff(){return Lf(this,void 0,void 0,function*(){var e;(null===(e=window.scheduler)||void 0===e?void 0:e.yield)?yield window.scheduler.yield():yield new Promise(requestAnimationFrame)})}var Hf=function(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{c(r.next(e))}catch(e){i(e)}}function s(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}c((r=r.apply(e,t||[])).next())})};function Bf(e){let t;return"checkbox"===e.type?e.checked?(t=e.value,t||(t=1)):t=0:"radio"===e.type?e.checked&&(t=e.value):t=e.value,t}function Uf(e){let t,n,r=e.querySelectorAll("input[name],select[name],textarea[name],button[name]"),o={};return al(r,(e,r)=>{if(n=Bf(e),void 0!==n&&!e.disabled){let r=e.name;if(-1===r.indexOf("[]")&&r.indexOf("[")>-1&&r.indexOf("]")>-1&&r.lastIndexOf("]")===r.length-1&&(r=$l("][",".",r),r=$l("[",".",r),r=$l("]","",r)),r.length>2&&r.indexOf("[]")===r.length-2)t=rl(r,0,r.length-2),void 0===o[t]&&(o[t]=[]),o[t].push(n);else if(r.indexOf(".")>-1){let e,t=r.split(".");e=o;for(let r=0;r<t.length;r++)void 0===o[t[r]]&&(r<t.length-1?e[t[r]]={}:e[t[r]]=n),e=e[t[r]]}else o[r]=n}}),o}function Zf(e){return e.filter((e,t,n)=>t===n.indexOf(e))}function Wf(e,t=null){let n=[];if("string"==typeof e&&(e=document.querySelector(e)),e instanceof HTMLElement&&e.parentElement)if("string"==typeof t)for(;e=e.parentElement.closest(t);)n.push(e);else for(!0===t&&n.push(e);e=e.parentElement;)n.push(e);return n}function $f(e){0!==e.indexOf("--")&&(e="--"+e);let t=getComputedStyle(document.documentElement).getPropertyValue(e);return"string"==typeof t&&(t=t.trim()),t}function qf(){const e=navigator.userAgent.toLowerCase();return/iPhone|Android/i.test(navigator.userAgent)?"mobile":/(ipad|tablet|(android(?!.*mobile))|(windows(?!.*phone)(.*touch))|kindle|playbook|silk|(puffin(?!.*(IP|AP|WP))))/.test(e)?"tablet":"desktop"}function zf(){let e,t=window.getSelection();if(t.rangeCount>0){e=t.getRangeAt(0),nl("RANGE",e);let n=e.cloneContents();nl("clonedSelection",n);let r=document.createElement("div");return r.appendChild(n),r.innerHTML}return""}function Vf(e){return Qu(e)?e.replace(/<!--[\s\S]*?-->/g,""):e}function Jf(e){let t=document.createElement("div");return t.innerHTML=e,e=t.innerText}function Gf(e){let t=document.createElement("canvas");return t.width=e.width,t.height=e.height,t.getContext("2d").drawImage(e,0,0),t}function Kf(e){let t,n,r={};if(sl(e[0])&&1===e.length)return e[0];for(n=0;n<e.length;n++)t=typeof e[n],t=t.toLowerCase(),tl(e[n])?(r.errorFn&&!r.abortFn&&(r.abortFn=e[n]),r.successFn&&!r.errorFn?r.errorFn=e[n]:r.successFn||(r.successFn=e[n])):1===e[n]||!0===e[n]?r.force=!0:"string"===t?r.url?r.datatype=e[n]:0===e[n].indexOf("#")||0===e[n].indexOf(bbn.env.root+"#")?r.url=rl(e[n],bbn.env.root.length):(r.url=e[n],0===r.url.indexOf(bbn.env.root)&&(r.url=rl(r.url,bbn.env.root.length))):e[n]&&"object"===t&&(e[n]instanceof Event?r.e=e[n]:r.ele||1!==e[n].nodeType?"object"===t.toLowerCase()&&(r.obj=e[n]):r.ele=e[n]);return!r.url&&yl(r)&&(r.url=bbn.env.path),void 0===r.obj&&(r.obj={_bbn:"public"}),r.datatype||(r.datatype="json"),r}function Xf(e,t,n=null,r=!1){bbn.env.old_path=bbn.env.path,bbn.env.url=["https:/","http://"].includes(rl(e,0,7))?e:bbn.env.root+e,bbn.env.path=rl(bbn.env.url,bbn.env.root.length),bbn.env.params=bbn.env.path.split("/").filter(e=>""!==e);let o=window.history;if(o){let e=o.state,i={url:bbn.env.path,old_path:bbn.env.old_path||null,data:n||{},reload:!1};e&&e.url===bbn.env.path&&(e.data&&ul(i.data,e.data),e.title&&!t&&(t=e.title),r=!0),t=t?Jf(t):bbn.env.siteTitle,r?(i.reload=!0,o.replaceState(i,t,bbn.env.url)):o.pushState(i,t,bbn.env.url)}}function Qf(...e){let t=Kf(e),n=1;if(!0===t)return!0;if(!t)return Qf(window.location.href);if(0===t.url.indexOf("javascript:"))return!0;if(0===t.url.indexOf("data:"))return!0;if(0===t.url.indexOf("#"))return location.href=bbn.env.url+t.url,!0;if(0===t.url.indexOf("mailto:"))return bbn.env.ignoreUnload=!0,window.location.href=t.url,setTimeout(()=>{bbn.env.ignoreUnload=!1},0),!1;if(Fl(t.url))return!1;if((0===t.url.indexOf("http://")||0===t.url.indexOf("https://"))&&0!==t.url.indexOf(bbn.env.host))return t.e&&t.e.preventDefault(),window.open(t.url),!1;if(t.url!==bbn.env.params.join("/")||1===t.force){if(t.successFn)n=t.successFn(t.url);else if(bbn.fn.defaultPreLinkFunction){let e=bbn.fn.defaultPreLinkFunction(t.url,t.force,t.ele);void 0!==e.data?(ul(t.obj,e.data),n=1):n=e}if(n){1!==n&&"string"==typeof n&&(t.url=n);let e=bbn._("The Ajax call to")+" "+t.url+" ";return zl(t.url,t.datatype,t.obj,n=>{n||nl(e+bbn._("returned no answer")),sl(n)&&(0===Object.keys(n).length&&nl(e+bbn._("returned an empty object")),n.new_url?(n.old_path=t.url,t.url=n.new_url):n.url&&t.url!==n.url&&(n.old_path=t.url)),wf(t.url,n,t.successFn,null,t.ele)&&void 0===n.noNav&&0!==bbn.env.path.indexOf(t.url)&&Xf(t.url,(n.title?n.title+" - ":"")+bbn.env.siteTitle)},t.errorFn||null)}}return!0}function ed(...e){let t=Kf(e);if(t.url)return zl(t.url,t.datatype,t.obj,e=>{wf(t.url,e,t.successFn,t.errorFn,t.ele)},t.errorFn,t.abortFn)}function td(e,t,n){let r,o=e.getAttribute("action")||bbn.env.path;if(""===o&&(o="."),"string"==typeof o&&(0!==o.indexOf("http")||-1!==o.indexOf(window.document.location.hostname))&&!e.getAttribute("target")&&(t&&t.preventDefault(),r=Uf(e),r)){e.setAttribute("action",null);const t=[o,r];!n&&e.getAttribute("data-script")&&(n=(n=new Function(e.getAttribute("data-script")))()),n&&t.push(n),ed(...t)}}function nd(){let e=bbn.env.width!==window.innerWidth,t=bbn.env.height!==window.innerHeight;if(e||t){e&&(bbn.env.width=window.innerWidth||window.document.documentElement.clientWidth||window.document.body.clientWidth,document.documentElement.style.setProperty("--vw",.01*bbn.env.width+"px")),t&&(bbn.env.height=window.innerHeight||window.document.documentElement.clientHeight||window.document.body.clientHeight,document.documentElement.style.setProperty("--vh",.01*bbn.env.height+"px"));let n=parseInt($f("mobile-limit"))||650,r="bbn-screen-"+(bbn.env.width<n?"small":"regular"),o=(document.body.className||"").split(" "),i=!1;al(o,(e,t)=>{if(3===e.split("-").length&&0===e.indexOf("bbn-screen-"))return i=!0,e!==r&&o.splice(t,1,r),!1}),i||o.push(r),bbn.fn.defaultResizeFunction(),document.body.className=o.join(" ")}}function rd(){return"mobile"===qf()}function od(){return"tablet"===qf()}function id(){return rd()||od()}function ad(e=!1){let t=(new Date).getTime();return e?Math.round(t/1e3):t}function sd(e){if("string"==typeof e&&e.length>0&&(0===e.indexOf("calc")||Ku(rl(e,0,1)))){let t=document.createElement("div");t.style.width=e;let n=!!t.style.width.length;return t.remove(),n}return!1}function cd(...e){if(!e.length)return!1;for(let t of e)if(!Qu(t)||!bbn.var.regexp.ip.test(t))return!1;return!0}function ud(...e){if(!e.length)return!1;for(let t of e)if("[object Symbol]"!=={}.toString.apply(t))return!1;return!0}function ld(e){const t=["BBN: "+e];t.unshift({_bbn_console_mode:"warn",_bbn_console_level:2,_bbn_console_style:"color: #E64141; background: #F7E195; font-size: 14px"}),nl.apply(this,t)}function fd(e,t="",n=null){let r=new FormData,o=(e,t="")=>{(!n||cl(n)&&!n.includes(t))&&(e instanceof File?r.append(t,e):cl(e)?al(e,(e,n)=>{o(e,t+"["+n+"]")}):sl(e)&&Object.keys(e).length?il(e,(n,r)=>{r in e&&o(n,t?t+"["+r+"]":r)}):El(e)||void 0===e||r.append(t,e))};return o(e,t),r}function dd(e){return"string"==typeof e?document.querySelector(e):e}function hd(e,t,n,r){if("object"==typeof e&&"string"==typeof t){let o=e;const i=t.split(".");al(i,(e,t)=>{if(!o){if(!r)throw new Error(bbn._("The object is invalid"));o={}}i.length-1===t?o[e]=n:o=o[e]})}}function md(e,t){return Math.floor(Math.random()*(t-e+1)+e)}function pd(e,t=" "){if(" "===t)return e.trim();if(!t)return e;if(t===e)return"";for(;0===e.indexOf(t);)e=rl(e,t.length);for(;e.lastIndexOf(t)===e.length-t.length;)e=rl(e,0,e.length-t.length);return e}function gd(e,t,n){return"string"==typeof e.toLowerCase()&&(t||(t=bbn.var.shortenLen),void 0!==n&&Qu(n)||(n="..."),e.length>t&&(e=rl(e,0,t)+n)),e}var bd,wd={_addLoader:ml,_compareValues:wl,_deleteLoader:Ll,abort:function(e){let t=Fl(e);(null==t?void 0:t.aborter)&&t.aborter.abort("Operation canceled by the user.")},abortURL:function(e){al(Hl(bbn.env.loaders,{url:e}),t=>{if(!t||!t.source)throw new Error("Impossible to find the loader with URL "+e);t.source.cancel("Operation canceled by the user.")})},addColors:Bl,addInputs:Ul,addStyle:function(e,t){sl(t)&&il(t,(t,n)=>{e.style[n]=t})},adjustHeight:function(){let e=arguments;return 1===e.length&&Xu(e[0])&&(e=e[0]),Zl("height",e)},adjustSize:Zl,adjustWidth:function(){let e=arguments;return 1===e.length&&Xu(e[0])&&(e=e[0]),Zl("width",e)},ajax:zl,analyzeFunction:jl,animateCss:function(e,t,n){e.classList.add("animated"),e.classList.add(t),e.addEventListener("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend",function e(r){r.target.removeEventListener(r.type,e),"function"==typeof n&&n.call(this),r.target.classList.remove(t)})},arrayBuffer2String:Jl,arrayFromProp:function(e,t){let n=[];return al(e,(e,r)=>{n.push(pl(e,t))}),n},autoExtend:function(e,t){bbn[e]||(bbn[e]={}),ul(bbn[e],t)},baseName:Gl,br2nl:function(e){return $l("<br />","\n",$l("<br/>","\n",$l("<br>","\n",e)))},calendar:function(e,t=!1){let n=gf(e);return n.isValid?n.fdate():t&&Qu(t)?t:""},callback:wf,camelize:function(e){return e.replace(/^([A-Z])|[\s-](\w)/g,function(e,t,n,r){return n?n.toUpperCase():t.toLowerCase()})},camelToCss:function(e){return e.replace(/([A-Z])/g,function(e){return"-"+e.toLowerCase()}).replace("/^./",function(e){return e.toLowerCase()})},canvasToImage:function(e){let t=new Image;return t.src=e.toDataURL("image/png"),t},cast:function(e){var t;return e?"object"==typeof e?bbn.fn.isArray(e)?"Array ("+e.length+")":(null===(t=e.constructor)||void 0===t?void 0:t.name)||"{}":e.toString?e.toString():"string"==typeof e?e:"":""},center:function(e){let t=e.parentNode,n=t.clientWidth,r=t.clientHeight;for(;t&&(!n||!r);)t=e.parentNode,n=t.clientWidth,r=t.clientHeight;return e.style.position="absolute",e.style.top=Math.max(0,(r-e.offsetHeight)/2+t.scrollTop)+"px",e.style.left=Math.max(0,(r-e.offsetWidth)/2+t.scrollLeft)+"px",e},checkProps:function(e,t,n=!1){return yf(e,t,n).result},checkPropsDetails:yf,checkPropsOrDie:function(e,t,n=!1){let r=yf(e,t,n);if(r.error)throw new Error(r.error);return!0},checkType:Ef,circularReplacer:function(){const e=new WeakSet;return(t,n)=>{if("object"==typeof n&&null!==n){if(e.has(n))return;e.add(n),[void 0,Object,Array,null].includes(n.constructor)||(n=Sl(n)?n.bbnId?"__BBN_DOM__"+n.tagName+"/"+n.bbnId+n.bbnHash:"__BBN_DOM__"+n.tagName+"/"+n.className:Tl(n)?"__BBN_CP__"+n.$options.name+"/"+n.$cid:n.constructor.toString())}return n}},clone:Mf,colorToHex:function(e){let t=document.createElement("canvas").getContext("2d");return t.fillStyle=e,t.fillStyle},compare:Rl,compareConditions:Nl,copy:function(e,t){return new Promise(n=>{if(e){if(navigator&&navigator.clipboard)return void(e instanceof Blob?(navigator.clipboard.write([new ClipboardItem({[e.type.toString()]:e})]).then(()=>{n(!0)}),t||If(e,e.type.toString())):sl(e)&&tl(e.toBlob)?e.toBlob(r=>{const o=new ClipboardItem({[r.type.toString()]:r});navigator.clipboard.write([o]).then(()=>{t||If(e,r.type.toString()),n(!0)})}):(navigator.clipboard.writeText(e),t||If(e),n(!0)));let r=document.createElement("textarea");r.style.opacity="0",r.value=e,document.body.appendChild(r),r.select(),document.execCommand("copy"),document.body.removeChild(r),t||If(e),n(!0)}n(!1)})},correctCase:vf,count:function(e,t,n=null,r="="){return Df(e,t,n,r).length||0},crc32:function(e){let t=~0;for(let n=0;n<e.length;n++){const r=e.charCodeAt(n);t=t>>>8^Sf[255&(t^r)]}return(-1^t)>>>0},createObject:kf,cssExists:function(e){let t,n,r=document.styleSheets;for(let o=0;o<r.length;o++){t=1;try{n=r[o].rules||r[o].cssRules}catch(e){if(t=!1,"SecurityError"!==e.name)throw e}if(t)for(let t=0;t<n.length;t++)if(new RegExp("(^|\\s)"+Wl(e)+"(\\{|\\s)","g").test(n[t].selectorText))return!0}return!1},data2Html:function e(t,n=""){const r=!cl(t);let o='<ul class="bbn-bottom-xspadding '+(n||"bbn-ul")+'">';for(let i in t)o+="<li>",r&&(o+="<em>"+i+"</em>: "),t[i]&&(cl(t[i])||sl(t[i]))?o+=e(t[i],n):o+=null===t[i]?"<em>null</em>":t[i].toString?t[i].toString():t[i],o+="</li>";return o+='</ul><div class="bbn-bottom-xspadding '+(n||"bbn-div")+'"></div>',o},date:Tf,dateSQL:function(e,t){let n=gf(e);if(n)return n.format("YYYY-MM-DD"+(t?"":" HH:mm:ss"))},deepPath:function e(t,n,r,o=[]){let i;return(i=Yl(t,n,0))>-1?(o.push(i),o):(al(t,(t,i)=>{if(cl(t[r])){let a=o.slice();a.push(i);let s=e(t[r],n,r,a);if(!1!==s)return s}}),!1)},defaultAjaxAbortFunction:_f,defaultAjaxErrorFunction:xf,defaultAlertFunction:function(e,t=null){alert(e)},defaultConfirmFunction:function(e,t,n=null){let r=0;confirm(e)&&tl(t)&&(t(),r=1),!r&&tl(n)&&n()},defaultEndLoadingFunction:Of,defaultErrorFunction:function(e){nl(e)},defaultHistoryFunction:function(e){return!0},defaultLinkFunction:function(e,t){return!0},defaultPostLinkFunction:function(e,t=null){return!0},defaultPreLinkFunction:function(e,t=!1,n=null){return nl("defaultPreLinkFunction",e,t,n),!0},defaultResizeFunction:function(){return!0},defaultStartLoadingFunction:function(e,t,n,r){return!0},deleteProp:function(e,t){Ef(e,"object",bbn._("The obj must be an object in setProp")),Ef(t,"string",bbn._("The prop must be a string in setProp")),delete e[t]},diffObj:function e(t,n,r=!1,o=!1){o||(Cf=[]);let i="unchanged";void 0===o&&(o=!1);let a=kf();if(!tl(t)&&!tl(n)){if(jf(t)||jf(n)){let e=(s=t)===(c=n)||bl(s)&&bl(c)&&s.getTime()===c.getTime()?i:void 0===s?"created":void 0===c?"deleted":"updated";if(r||e!==i){let r=kf();return Object.defineProperty(r,"type",{value:e,enumerable:!1}),Object.defineProperty(r,"data",{value:void 0===t?n:t,enumerable:!1}),Object.defineProperty(r,"_bbnDiffObjProof",{value:!0,enumerable:!1}),void 0!==t&&Object.defineProperty(r,"newData",{value:n,enumerable:!1}),r}return!1}if(Sl(t)||Sl(n))return!1;if(Cf.includes(t)||Cf.includes(n))return!1;Cf.push(t,n);for(let o in t){if(tl(t[o]))continue;let i;void 0!==n[o]&&(i=n[o]);let s=e(t[o],i,r,!0);s&&(a[o]=s)}for(let o in n){if(tl(n[o])||void 0!==t[o])continue;let i=e(void 0,n[o],r,!0);i&&(a[o]=i)}}var s,c;return!(o&&!r&&!yl(a))&&a},dirName:Rf,download:function(e,t="",n=null){return t&&"object"==typeof t&&(n=t,t=""),zl(e,"blob",n||{_bbn_download:1},(n,r)=>{if(!t){let n="content-disposition",o="attachment; filename=";t=(null==r?void 0:r[n])&&0===r[n].indexOf(o)?rl(r[n],o.length+1,r[n].length-o.length-2):Gl(e)}if(Nf(n)){let e=Pf(t),r=["php","html"];if("string"==typeof t&&("type"in n&&"text/html"!==n.type||r.includes(e)))return void Af(t,n)}},e=>{bbn.fn.defaultAjaxErrorFunction(e)})},downloadContent:Af,each:al,eraseCookie:function(e){document.cookie=e+"=; Max-Age=-99999999;"},error:bf,escapeDquotes:function(e){return Qu(e)?e.replace(/"/g,'\\"'):e},escapeRegExp:Wl,escapeSquotes:function(e){return Qu(e)?e.replace(/'/g,"\\'"):e},escapeTicks:function(e){return Qu(e)?e.replace(/`/g,"\\`"):e},escapeUrl:function(e,t){let n="";e.match("^(http|https)://")&&(n+="http","s"===(e=e.substring(4)).substr(0,1)&&(n+="s",e=e.substring(1)),n+="://",e=e.substring(3)),al(Rf(e).split("/"),e=>{n+=encodeURIComponent(e)+"/"});let r=Gl(e),o="?",i="";if(r.indexOf(o)){let e=r.split("?");o="&",i="?"+e[1],r=e[0]}return t&&Qu(t)?(t.match("^(\\&|\\?)")&&(t=t.substring(1)),t=o+t):t="",n+encodeURIComponent(r)+i+t},executeSlowly:function(e,t){return Hf(this,void 0,void 0,function*(){for(let n=0;n<e.length;n++){yield Ff();let r=t(e[n],n);if(r instanceof Promise&&(r=yield r),!1===r)return!1}return!0})},extend:ul,extendOut:function e(...t){let n=null;for(let r of t){if(!sl(r))throw new Error("Each argument for extendOut must be an object, "+typeof r+" given");if(null===n)n=r;else for(let t in r)sl(n[t],r[t])?e(n[t],r[t]):void 0===n[t]&&(n[t]=r[t])}return n},fdate:function(e,t=!1){let n=gf(e),r=!1;return!0===t&&(r=!0),n.isValid?n.fdate(!1,r):t&&Qu(t)?t:""},fdatetime:function(e,t=!1){let n=gf(e);return n.isValid?n.fdate(!1,!0):t&&Qu(t)?t:""},fieldValue:Bf,fileExt:Pf,filter:Df,filterToConditions:Pl,findAll:function e(t,n,r,o=[]){let i,a=0;for(;(i=Yl(t,n,a))>-1;)o.push(t[i]),a=i+1;return al(t,t=>{cl(t[r])&&e(t[r],n,r,o)}),o},firstVarElement:function(e){const t=e.indexOf("["),n=e.indexOf(".");return-1===t&&-1===n?e:-1===t?e.substring(0,n):-1===n?e.substring(0,t):e.substring(0,Math.min(t,n))},fori:function(e,t,n=e.length-1,r=0){if(cl(e)){let o=e.length-1;Ku(n)&&0<n&&n<=o||(n=o),(!Ku(r)||!(0<=r&&r<o)||r>n)&&(r=0);for(let o=r;o<=n;o++)if(!1===t(e[o],o))return}},forir:function(e,t,n=e.length-1,r=0){if(cl(e)){let o=e.length-1;Ku(n)&&0<n&&n<=o||(n=o),(!Ku(r)||!(0<=r&&r<o)||r>n)&&(r=0);for(let o=n;o>=r;o--)if(!1===t(e[o],o))return}},format:function(e){let t=Array.prototype.slice.call(arguments,1);if(t.length){let n=0;return e.replace(/\%([d|s])/g,(e,r)=>{let o=t[n++];return Ef(o,"d"===r?"number":"string",bbn._("The value doesn't correspond to the format")),o})}return e},formatBytes:function(e,t=2){if(!e)return"0 B";const n=Math.floor(Math.log(e)/Math.log(1024));return parseFloat((e/Math.pow(1024,n)).toFixed(t<0?0:t))+" "+["B","KB","MB","GB","TB","PB","EB","ZB","YB"][n]},formatDate:function(e,t){const n=gf(e);return n.isValid?n.format(t):""},formatSize:function(e,t){return Ku(e)?e+"px":Qu(e)?e:!t&&"auto"},formdata:Uf,fphone:function(e){var t;if(Ku(e)&&(e=e.toString()),Qu(e)){const n=(null===(t=bbn.var)||void 0===t?void 0:t.phoneCodes)||[];let r="",o="",i="";if(n.length&&al(n,t=>{e.startsWith(t.prefix)&&t.prefix.length>o.length&&(o=t.prefix,i=t.mask||"")}),!i.length&&e.startsWith("+")){o.length||(o=e.substr(0,3));const t=e.slice(o.length);for(let e=0;e<t.length;e++)e+1<=t.length&&e%2==0&&(i+="0"+(t[e+1]?"0":"")+" ");i=i.trim()}if(i.length){o.length&&(r=o+" ",e=e.slice(o.length));let t=0;return r+=i.replace(/[0-9]/g,()=>e[t++]||""),r}}return e},fromXml:function(e,t){let n=null;if(window.DOMParser)n=(new DOMParser).parseFromString(e,"text/xml");else{if(!window.ActiveXObject)throw new Error("cannot parse xml string!");if(n=new window.ActiveXObject("Microsoft.XMLDOM"),n.async=!1,!n.loadXML(e))throw n.parseError.reason+" "+n.parseError.srcText}function r(e,n){if("#text"==e.nodeName){let t=e.nodeValue;return void(t.trim()&&(n["#text"]=t))}let o={},i=n[e.nodeName];if(i?Array.isArray(i)?n[e.nodeName].push(o):n[e.nodeName]=[i,o]:t&&-1!=t.indexOf(e.nodeName)?n[e.nodeName]=[o]:n[e.nodeName]=o,e.attributes)for(let t of e.attributes)o[t.nodeName]=t.nodeValue;for(let t of e.childNodes)r(t,o)}let o={};for(let e of n.childNodes)r(e,o);return o},ftime:function(e,t){let n=gf(e);return n.isValid?n.ftime():t&&Qu(t)?t:""},getAllTags:function(){return Zf(Array.prototype.map.apply(document.all,[e=>e.tagName.toLowerCase()]))},getAncestors:Wf,getAttributes:function(e){e.getAttributeNames||bf("The element is not a proper HTML Element");let t=Object.create(null);return e.getAttributeNames().forEach(n=>{t[n]=e.getAttribute(n)}),t},getBrowserName:function(){const e=navigator.userAgent.toLowerCase();switch(!0){case e.includes("edge"):case e.includes("edg/"):return"Edge";case e.includes("opr")&&!!window.opr:return"Opera";case e.includes("chrome")&&!!window.chrome:return"Chrome";case e.includes("trident"):return"Internet Explorer";case e.includes("firefox"):return"Firefox";case e.includes("safari"):return"Safari";default:return"Other"}},getBrowserVersion:function(){const e=navigator.userAgent.toLowerCase();switch(!0){case e.includes("edge/"):return e.split("edge/")[1].split(" ")[0];case e.includes("edg/"):return e.split("edg/")[1].split(" ")[0];case e.includes("opr/")&&!!window.opr:return e.split("opr/")[1].split(" ")[0];case e.includes("chrome/")&&!!window.chrome:return e.split("chrome/")[1].split(" ")[0];case e.includes("trident/"):return e.split("trident/")[1].split(" ")[0];case e.includes("firefox/"):return e.split("firefox/")[1].split(" ")[0];case e.includes("safari/"):return e.split("version/")[1].split(" ")[0];default:return""}},getChrono:function(e="default"){return bbn.fn.microtimestamp()-this.constructor.chronos[e]},getCookie:function(e){let t=e+"=",n=document.cookie.split(";");for(let e=0;e<n.length;e++){let r=n[e];for(;" "==r.charAt(0);)r=r.substring(1,r.length);if(0==r.indexOf(t)){let e=r.substring(t.length,r.length);if(e)return JSON.parse(unescape(e)).value}}return null},getCssVar:$f,getDay:function(e){let t=Tf(e);if(t){let e=t.getTime(),r=t.getYear(),o=365*(r-1970);t.getMonth()<2&&r--;for(var n=1972;n<=r;n+=4)o++;return o+Math.floor(e/864e5)}return!1},getDeviceType:qf,getEventData:function(e){let t=e.dataTransfer||e.clipboardData,n=t.getData("Text"),r={raw:n,files:[],str:[]};return new Promise((o,i)=>{let a=!(t instanceof DataTransfer);if(!n&&"copy"===e.type){let e=window.getSelection();r.raw=e.toString();let t=zf();r.str.push({type:"text/plain",data:r.raw}),t!==r.raw?r.str.push({type:"text/html",data:t}):0===r.raw.trim().indexOf("<")&&r.str.push({type:"text/html",data:"<meta charset='utf-8'><code style=\"white-space: pre; font-family: 'Courier New', sans-serif\">\n"+r.raw+"\n</code>"}),a=!0,o(r)}if(!a){let e=[],n=t.items.length;al(t.items,(i,s)=>{let c=i.kind,u=i.type;if("file"===c){let c=t.files[s];if(!u&&c.name){let e=c.name.split(".");u=e[e.length-1]}let l=c?c.name:bbn._("untitled"),f=c?c.size:null,d=c?c.lastModified:null,h=i.getAsFile();h?(a=!0,n--,r.files.push({type:u,data:h,name:l,size:f,mdate:d}),e.push(l),n||(r.raw||(r.raw=e.join(", ")),o(r))):bbn.fn.defaultErrorFunction(bbn._("Impossible to read the file")+" "+l)}else a=!0,i.getAsString(t=>{n--,r.str.push({type:u,data:t}),"text/plain"===u&&e.push(name),n||(r.raw||(r.raw=e.join(", ")),o(r))})})}a||setTimeout(()=>{o(r)})})},getField:function(e,t,n="",r=null,o="=",i=0,a=!1,s=void 0){let c;return n&&["object","function"].includes(typeof n)&&6 in arguments&&(s=a),t?(c=Al(e,n,r,o,i,a,void 0),void 0===c?s:c[t]):s},getFieldValues:function(e,t,n,r,o){Ef(t,"string"),n&&(e=Hl(e,n,r,o));let i=[];return al(e,e=>-1===i.indexOf(e[t])?i.push(e[t]):null),i},getIndex:function(e,t=""){return e.parentElement?(t||Array.from(e.parentElement.children).indexOf(e),Array.from(e.parentElement.children).filter(e=>e.matches(t)).indexOf(e)):-1},getHtml:function(e,t=!1){let n=e.innerHTML();return t&&(n=Vf(n)),n.trim()},getHTMLOfSelection:zf,getLoader:Fl,getPath:kl,getProp:function(e,t){return Ef(e,"object",bbn._("The obj must be an object in setProp")),Ef(t,"string",bbn._("The prop must be a string in setProp")),e[t]},getProperty:pl,getRequestId:ql,getRow:Al,getScrollBarSize:function(){if(void 0===bbn.env.scrollBarSize){let e=document.createElement("div");e.style.visibility="hidden",e.style.width="100px","msOverflowStyle"in e.style&&(e.style.msOverflowStyle="scrollbar"),document.body.appendChild(e);let t=e.offsetWidth;e.style.overflow="scroll";let n=document.createElement("div");n.style.width="100%",e.appendChild(n);let r=n.offsetWidth;e.parentNode.removeChild(e);let o=t-r;bbn.env.scrollBarSize=o?o+1:0}return bbn.env.scrollBarSize},getSortingMoves:function(e,t){if(e.length!==t.length)throw new Error("Lengths must match.");const n=new Set(t);if(n.size!==t.length)throw new Error("dst has duplicates.");const r=new Set(e);if(r.size!==e.length)throw new Error("src has duplicates.");if(e.length!==n.size||Array.from(r).some(e=>!n.has(e)))throw new Error("Arrays must contain the same unique values.");const o=new Map(t.map((e,t)=>[e,t])),i=e.map(e=>o.get(e)),a=(e=>{const t=e.length,n=[],r=Array(t).fill(-1);for(let o=0;o<t;o++){let t=e[o],i=0,a=n.length;for(;i<a;){const r=i+a>>1;e[n[r]]<t?i=r+1:a=r}i>0&&(r[o]=n[i-1]),n[i]=o}const o=[];for(let e=n.length?n[n.length-1]:-1;-1!==e;e=r[e])o.push(e);return o.reverse()})(i),s=new Set(a.map(t=>e[t])),c=Array(t.length).fill(-1);for(let e=t.length-2;e>=0;e--)c[e]=c[e+1],s.has(t[e+1])&&(c[e]=e+1);const u=e.slice(),l=new Map(u.map((e,t)=>[e,t])),f=[];for(let e=0;e<t.length;e++){const n=t[e];if(s.has(n))continue;const r=l.get(n);if(void 0===r)throw new Error("Inconsistent state");const o=c[e],i=-1!==o?l.get(t[o]):u.length;if(void 0===i)throw new Error("Inconsistent state");const a=r<i?i-1:i;if(r!==a){const[e]=u.splice(r,1);u.splice(a,0,e),f.push({from:r,to:a,value:n}),l.clear();for(let e=0;e<u.length;e++)l.set(u[e],e)}}return f},getText:function(e){return e.innerText().trim()},getTimeoff:function(){return bbn.env.isFocused?0:Math.round((new Date).getTime()/1e3-bbn.env.timeoff)},happy:function(...e){return e.unshift({_bbn_console_level:3,_bbn_console_style:"color: white; background: green; font-size: 18px;"}),nl.apply(this,e),this},hash:xl,hex2rgb:function(e){"#"!==e.charAt(0)&&(e="#"+e),4===e.length&&(e="#"+e[1]+e[1]+e[2]+e[2]+e[3]+e[3]);const t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?{r:parseInt(t[1],16),g:parseInt(t[2],16),b:parseInt(t[3],16)}:null},history:function(){return window.history||!1},html2text:Jf,imageToCanvas:Gf,imgToBase64:function(e,t="image/png"){return Gf(e).toDataURL(t)},info:function(...e){return e.unshift({_bbn_console_level:4,_bbn_console_style:"color: #EEE; background: blue; font-size: 12px;"}),nl.apply(this,e),this},init:function(e,t){let n;bbn.env.isInit||(bbn.env.root=document.baseURI.length>0?document.baseURI:bbn.env.host,bbn.env.root.length&&"/"!==rl(bbn.env.root,-1)&&(bbn.env.root+="/"),"object"==typeof e&&ul(!0,bbn,e),bbn.env.path=rl(bbn.env.url,bbn.env.root.length),n=bbn.env.path.split("/"),al(n,(e,t)=>{""!==(e=decodeURI(e.trim()))&&bbn.env.params.push(e)}),bbn.var.colors&&Bl(bbn.var.colors),document.addEventListener("visibilitychange",()=>{document.hidden&&bbn.env.isFocused?bbn.env.isFocused=!1:document.hidden||bbn.env.isFocused||(bbn.env.isFocused=!0)}),document.addEventListener("focusin",e=>{e.target instanceof HTMLElement&&!e.target.classList.contains("bbn-no")&&(bbn.env.focused=e.target),bbn.env.last_focus=ad()}),document.addEventListener("click",e=>{if(bbn.env.last_focus=ad(),"ajax"!==bbn.env.nav)return;let t=e.target;if(t instanceof HTMLElement&&"A"!==t.tagName){let e=t;for(;e&&"A"!==e.tagName&&"BODY"!==e.tagName;)e=e.parentElement;t=e&&"A"===e.tagName?e:null}return t instanceof HTMLElement&&t.hasAttribute("href")&&!t.hasAttribute("target")&&!t.classList.contains("bbn-no")?(e.preventDefault(),e.stopPropagation(),Qf(t.getAttribute("href")),!1):void 0}),al(document.querySelectorAll("form:not(.bbn-no), form:not(.bbn-form)"),e=>{e.addEventListener("submit",t=>{td(e,t)})}),window.addEventListener("hashchange",()=>{bbn.env.hashChanged=(new Date).getTime()},!1),window.addEventListener("resize",()=>{nd()}),window.addEventListener("orientationchange",()=>{nd()}),nd(),id()&&(document.body.classList.add("bbn-mobile"),od()&&document.body.classList.add("bbn-tablet")),window.history&&(window.onpopstate=function(e){let t=window.history;if(!bbn.env.historyDisabled&&t&&bbn.fn.defaultHistoryFunction(t.state)){let e=t.state;e?Qf(e.url,ul({title:e.title||bbn.env.siteTitle},e.data||{})):e&&e.data&&tl(e.data.script)&&e.data.script()}}),window.addEventListener("online",()=>{bbn.env.online=!0}),window.addEventListener("offline",()=>{bbn.env.online=!1}),bbn.env.isInit=!0,document.dispatchEvent(new Event("bbninit")),bbn.env.logging&&nl("Logging in bbn is enabled"))},isActiveInterface:function(e=600){return!!bbn.env.last_focus&&(new Date).getTime()-bbn.env.last_focus<1e3*e},isArray:cl,isBlob:Nf,isBoolean:function(...e){if(!e.length)return!1;for(let t of e)if(![!0,!1].includes(t))return!1;return!0},isCanvas:Yf,isColor:function(...e){if(!e.length)return!1;var t=new RegExp("^(#[a-f0-9]{6}|#[a-f0-9]{3}|rgb *( *[0-9]{1,3}%? *, *[0-9]{1,3}%? *, *[0-9]{1,3}%? *)|rgba *( *[0-9]{1,3}%? *, *[0-9]{1,3}%? *, *[0-9]{1,3}%? *, *[0-9]{1,3}%? *)|black|green|silver|gray|olive|white|yellow|maroon|navy|red|blue|purple|teal|fuchsia|aqua)$","i");for(let n of e){if(!Qu(n))return!1;if(!t.test(n))return!1}return!0},isComment:function(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof Comment))return!1;return!0},isCp:Tl,isDataURL:function(...e){if(!e.length)return!1;for(let t of e)if(!/^data:([a-z]+\/[a-z0-9\-\+\.]+(;[a-z\-]+\=[a-z0-9\-\.]+)?)?(;base64)?,/i.test(t))return!1;return!0},isDate:bl,isDesktopDevice:function(){return"desktop"===qf()},isDimension:function(...e){if(!e.length)return!1;for(let t of e){if("number"!=typeof t||t<0)return!1;if(!sd(t))return!1}return!0},isDom:Sl,isEmail:function(...e){if(!e.length)return!1;let t=/^([a-zA-Z0-9_.+-])+\@(([a-zA-Z0-9-])+\.)+([a-zA-Z0-9]{2,4})+$/;for(let n of e){if(!Qu(n))return!1;if(!t.test(n))return!1}return!0},isEmpty:vl,isEvent:function(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof Event))return!1;return!0},isFocused:function(e,t=!1){return e===document.activeElement||t&&e.contains&&e.contains(document.activeElement)},isFunction:tl,isHex:function(e){return Boolean(e.match(/^(0x)?[0-9a-f]+$/i))},isHostname:function(...e){if(!e.length)return!1;for(let t of e){if(!Qu(t))return!1;if(!cd(t)&&!bbn.var.regexp.hostname.test(t))return!1}return!0},isInside:function(e,t){let n=Wf(e);if(n.length){if(Qu(t)){let e=!1;return al(n,n=>{if(n.matches&&n.matches(t))return e=!0,!1}),e}if(t instanceof HTMLElement)return n.indexOf(t)>-1}return!1},isInt:el,isInViewport:function(e,t=!1){const n=e.getBoundingClientRect();if(t)return n.top>=0&&n.left>=0&&n.right<=(window.innerWidth||document.documentElement.clientWidth)&&n.bottom<=(window.innerHeight||document.documentElement.clientHeight);const r=e.offsetHeight,o=e.offsetWidth;return n.top>=-r&&n.left>=-o&&n.right<=(window.innerWidth||document.documentElement.clientWidth)+o&&n.bottom<=(window.innerHeight||document.documentElement.clientHeight)+r},isIP:cd,isIterable:Xu,isMobile:id,isMobileDevice:rd,isNotObject:jf,isNull:El,isNumber:Ku,isObject:sl,isPercent:function(...e){if(!e.length)return!1;for(let t of e)if("string"!=typeof t||!t.match(/^\d+(?:\.\d+)?%$/))return!1;return!0},isPrimitive:Kl,isPromise:function(...e){if(!e.length)return!1;for(let t of e)if("[object Promise]"!=={}.toString.apply(t))return!1;return!0},isPropSize:function(e){let t=!1;return al(["width","height","gap","margin","padding","top","left","right","bottom"],n=>{if(-1!==e.indexOf(n))return t=!0,!1}),t},isSame:Cl,isSQLDate:function(...e){if(!e.length)return!1;for(let t of e)if("string"!=typeof t||!t.match(/^([1-2]\d{3})-((0\d)|(1[12]))-(([0-2]\d)|(3[01]))(?:( [0-2]\d):([0-5]\d):([0-5]\d))?$/))return!1;return!0},isString:Qu,isSymbol:ud,isTabletDevice:od,isURL:function(...e){if(!e.length)return!1;for(let t of e)if(!bbn.var.regexp.url.test(t))return!1;return!0},isUid:function(...e){if(!e.length)return!1;for(let t of e)if("string"!=typeof t||!t.match(/^[0-9a-f]{32}$/i))return!1;return!0},isValidDimension:sd,isValidName:function(...e){if(!e.length)return!1;for(let t of e)if(!Qu(t)||!/^[$A-Z_][0-9A-Z_$]*$/i.test(t))return!1;return!0},isVue:function(...e){if(!e.length)return!1;if("vue"in bbn&&window.Vue)if("app"in bbn.vue){for(let t of e)if(!t||"function"!=typeof t.render)return!1}else for(let t of e)if(!(t instanceof window.Vue))return!1;return!("cp"in bbn)||!("isComponent"in bbn.cp)||"function"!=typeof bbn.cp.isComponent||bbn.cp.isComponent(...e)},isWritable:function(e,t){let n;for(;e&&(n=Object.getOwnPropertyDescriptor(e,t),!n);)e=Object.getPrototypeOf(e);return!n||Boolean(n.writable||n.set)},iterate:il,lightenDarkenHex:function(e,t){if(e&&t){let n="#"===e[0];e=n?e.slice(1):e;let r=parseInt(e,16),o=(r>>16)+t,i=(r>>8&255)+t,a=(255&r)+t;return o>255?o=255:o<0&&(o=0),i>255?i=255:i<0&&(i=0),a>255?a=255:a<0&&(a=0),(n?"#":"")+(a|i<<8|o<<16).toString(16)}},link:Qf,log:nl,makeReactive:function e(t,n,r,o){const i=(null==r?void 0:r.$cid)||"",a="__bbn_"+(i?i+"_":"");if(t&&"object"==typeof t&&[void 0,Object,Array].includes(t.constructor)){if(t.__bbnIsProxy&&t.__bbnParent===r)return t;r&&r.$options&&"bbn-loadbar"===r.$options.name&&nl(["MAKING bbn-loadbar",t]),t.__bbnWatchers||Reflect.defineProperty(t,"__bbnWatchers",{value:kf(),writable:!0,configurable:!0,enumerable:!1});return new Proxy(t,{get(s,c){const u=Reflect.get(s,c),l=s.__bbnRoot||s;if(ud(c))return Reflect.get(l,c);const f=o?o+"."+c:c,d=a+(Ku(c)?c.toString():c);if(["fill","pop","push","reverse","shift","sort","splice","unshift"].includes(c)&&cl(s))return function(...e){let t=l[c](...e);return ld("DOING ARRAY STUFF"),nl(s.__bbnParent),n(s,"length",r),t};if(tl(u))return u;if("__bbnRoot"===c){let e=t;for(;e&&(null==e?void 0:e.__bbnTarget);)e=e.__bbnTarget;return e}return"__bbnIsProxy"===c||("__bbnTarget"===c?s:"__bbnParent"===c?r:"__bbnWatchers"===c?s.__bbnWatchers:0===c.indexOf("__bbn_")?Reflect.get(s,c):"length"===c&&cl(s.__bbnRoot||s)?l.length:c in s&&u&&"object"==typeof u&&[void 0,Object,Array].includes(u.constructor)?(u.__bbnIsProxy&&u.__bbnParent===r||(d in l||Reflect.defineProperty(l,d,{value:e(u,n,r,f),writable:!0,configurable:!0,enumerable:!1}),l[d].__bbnIsProxy&&!l.__bbnWatchers[i]&&(l.__bbnWatchers[i]=f)),l[d]):u)},set(t,s,c){if(ud(s))return Reflect.get(t,s,c);const u=t.__bbnRoot||t,l=o?o+"."+s:s;if(ud(s))return Reflect.get(t,s);if(r&&r.$options&&"bbn-loadbar"===r.$options.name&&nl(["Setting proxy prop in "+r.$options.name,t,s,c]),!Cl(u[s],c)){if(0===s.indexOf("__bbn_"))Reflect.defineProperty(u,s,{value:e(c,n,r,l),writable:!0,configurable:!0,enumerable:!1});else if(c&&"object"==typeof c&&[void 0,Object,Array].includes(c.constructor)){const t=a+(Ku(s)?s.toString():s);Reflect.defineProperty(u,t,{value:e(c,n,r,l),writable:!0,configurable:!0,enumerable:!1}),u[t].__bbnIsProxy&&!u.__bbnWatchers[i]&&(u.__bbnWatchers[i]=l)}r&&r.$options&&"bbn-loadbar"===r.$options.name&&nl(["Setting proxy prop in "+r.$options.name+" "+(Ku(s)?s.toString():s),c,t]),Reflect.set(u,s,c),n(t,s,r)}return!0},defineProperty(t,i,s){const c=t,u=o?o+"."+i:i;if("__bbnWatchers"===i||ud(i)||0===i.indexOf("__bbn_"))Reflect.defineProperty(c,i,s);else{const t=a+(Ku(i)?i.toString():i);Reflect.defineProperty(c,t,{value:e(s.value,n,r,u),writable:!0,configurable:!0,enumerable:!1})}return n(t,i,r),!0},deleteProperty(e,t){const n=e;if(0===t.indexOf("__bbn_"))Reflect.deleteProperty(n,t);else{const r=a+(Ku(t)?t.toString():t);Reflect.deleteProperty(n,r),Reflect.deleteProperty(e,t)}return!0}})}return t},map:function e(t,n,r,o=0){return t.map((t,i)=>(t=n(t,i,o),r&&t[r]&&cl(t[r])&&(t[r]=e(t[r],n,r,o+1)),t))},md5:Ol,microtimestamp:function(){return window.performance.now()+performance.timeOrigin},money:function(e,t,n,r,o,i,a){if(o||(o=void 0===o&&bbn.env.money&&void 0!==bbn.env.money.decimal?bbn.env.money.decimal:"."),n||(n=void 0===n&&bbn.env.money&&void 0!==bbn.env.money.currency?bbn.env.money.currency:""),i||(i=void 0===i&&bbn.env.money&&void 0!==bbn.env.money.thousands?bbn.env.money.thousands:" "),a||(a=void 0===a&&bbn.env.money&&void 0!==bbn.env.money.precision?bbn.env.money.precision:0),t||(t=!(void 0!==t||!bbn.env.money||void 0===bbn.env.money.kilo)&&bbn.env.money.kilo),r||(r=!(void 0!==r||!bbn.env.money||void 0===bbn.env.money.novalue)&&bbn.env.money.novalue),Ku(a)||(a=t?3:0),0===e&&"number"==typeof a&&a>0){let r=e.toFixed(a).replace(".",o);return n&&(r+=" "+(t?"K"+n:n)),r}if((isNaN(e)||!e)&&r)return r;if(isNaN(e)||!e)return 0+(n?" "+n:"");if("string"==typeof e&&(e=Number(e)),"number"!=typeof e)throw new Error("The value must be a number");t&&e&&(e/=1e3,n&&(n="K"+n));let s=e.toFixed(a),c=0,u=1e4;return s&&(u=s.indexOf("."),u<=0?u=1e4:c=s.length-u),s.replace(/./g,function(e,t,n){return"."===e?o:t&&(n.length-t-c)%3==0&&t<u?i+e:e})+(n?" "+n:"")},move:function(e,t,n){if(n>=e.length){let t=n-e.length;for(;1+t--;)e.push(void 0)}return e.splice(n,0,e.splice(t,1)[0]),e},multiorder:function(e,t){if(!t)return e;let n;if(Array.isArray(t)||"object"!=typeof t)n=t;else for(var r in n=[],t)n.push({field:r,dir:t[r]});if(!Array.isArray(n))throw new Error("The orders argument must be an array");return e.slice().sort((e,t)=>{let r;for(let o of n)if(r=wl(e,t,o.field,o.dir),0!==r)return r;return 0})},mutateArray:function(e,t,n=null){if(!cl(e,t))throw new TypeError("mutateArray can only be called with arrays");n?Ef(n,"function","The hash function must be a function"):n=xl;const r=new Map(t.map(e=>[n(e),e]));let o=[];t.forEach(e=>{o.push(e)});let i=e.length;for(;i--;)r.has(n(e[i]))||e.splice(i,1);for(let t=0;t<o.length;t++)if(t>=e.length||!Cl(e[t],o[t])){const n=Yl(e,o[t]);if(-1!==n){const[r]=e.splice(n,1);e.splice(t,0,r)}else e.splice(t,0,o[t])}return e.length>o.length&&e.splice(o.length,e.length-o.length),e},mutateObject:function(e,t,n){if(!sl(e,t))throw new TypeError("mutateObject can only be called with arrays");n?Ef(n,"function","The hash function must be a function"):n=xl;const r=Object.keys(t);for(let t in e)r.includes(t)||delete e[t];return r.forEach(n=>{Cl(e[n],t[n])||(e[n]=t[n])}),e},nl2br:function(e,t){return $l("\n","<br>"+(t?"\n":""),e)},numProperties:yl,objectToFormData:fd,order:function(e,t,n="asc"){return e?e.sort(function(e,r){return wl(e,r,t,n)}):e},outerHeight:function(e){if((e=dd(e))&&"offsetHeight"in e){let t=window.getComputedStyle(e),n=parseFloat(t.marginTop)+parseFloat(t.marginBottom);return Math.ceil(e.offsetHeight+n)}},outerWidth:function(e){e=dd(e);let t=window.getComputedStyle(e),n=parseFloat(t.marginLeft)+parseFloat(t.marginRight);return Math.ceil(e.offsetWidth+n)},percent:function(e,t){return t/100*e},pickValue:function(e){if(Array.isArray(e)&&e.length)return e[Math.floor(Math.random()*e.length)]},post:ed,postOut:function(e,t,n=null,r=""){let o=document.body.querySelector("form#bbn-form_out");o||(o=document.createElement("form"),o.classList.add("bbn-no"),o.setAttribute("id","bbn-form_out"),o.setAttribute("method","post"),o.setAttribute("enctype","multipart/form-data-encoded"),hd(o,"style.display","none"),document.body.appendChild(o)),o instanceof HTMLFormElement&&(o.innerHTML="",o.setAttribute("action",e),o.setAttribute("target",r||"_blank"),t||(t={}),(t=kf(t)).bbn||(t.bbn="public"),Ul(o,t),o.submit(),n&&n())},printf:function(e){var t=Array.prototype.slice.call(arguments,1);return e.replace(/{(\d+)}/g,function(e,n){return void 0!==t[n]?t[n]:e})},quotes2html:function(e,t){return t&&0!==t.toLowerCase().indexOf("s")||(e=$l("'","&#39;",e)),t&&0!==t.toLowerCase().indexOf("d")||(e=$l('"',"&quot;",e)),e},randomInt:md,randomString:function(e,t,n){let r,o,i={n:"0123456789",l:"abcdefghijklmnopqrstuvwxyz",u:"ABCDEFGHIJKLMNOPQRSTUVWXYZ"};n||(n="nlu"),e||(r=md(8,14)),"string"==typeof t?(n="n",delete i.l,delete i.u,i.n=t,r||(r=e)):"number"==typeof t&&e<t?r=md(e,t):e&&(r=e);let a="";for(let e=0;e<r;e++)0===e?"n"!==n&&(o=-1===n.indexOf("u")?"l":"u"):o=n[Math.floor(Math.random()*n.length)],a+=i[o][Math.floor(Math.random()*i[o].length)];return a},range:function(e,t,n){return Array.from({length:(t-e)/n+1},(t,r)=>e+r*n)},removeAccents:gl,removeEmpty:function(e){var t=[];if(cl(e))for(let n=0;n<e.length;n++){let r=!1;e[n]&&(cl(e[n])?e[n].length&&(r=!0):sl(e[n])?yl(e[n])&&(r=!0):r=!0),r&&t.push(e[n])}return t},removeExtraSpaces:function(e){return e.replace(/\s+/g," ").trim()},removeHtmlComments:Vf,removePrivateProp:ol,removeTrailingChars:function(e,t){if(t||(t=" "),t.length){for(;rl(e,-t.length)===t;)e=rl(e,0,e.length-t.length);for(;rl(e,0,t.length)===t;)e=rl(e,t.length)}return e},repeat:function(e,t){return e.repeat(t)},replaceAll:$l,replaceSelection:function(e,t){let n,r,o;if(n=window.getSelection(),n.getRangeAt&&n.rangeCount){if(r=window.getSelection().getRangeAt(0),r.deleteContents(),r.createContextualFragment)o=r.createContextualFragment(e);else{const t=document.createElement("div");let n;for(t.innerHTML=e,o=document.createDocumentFragment();n=t.firstChild;)o.appendChild(n)}const i=o.firstChild,a=o.lastChild;r.insertNode(o),n.removeAllRanges(),t?(i&&(r.setStartBefore(i),r.setEndAfter(a)),n.addRange(r)):(r.setStartAfter(a),n.addRange(r))}},resize:nd,rgb2hex:function(e){return(e=e.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?/i))&&4===e.length?"#"+("0"+parseInt(e[1],10).toString(16)).slice(-2)+("0"+parseInt(e[2],10).toString(16)).slice(-2)+("0"+parseInt(e[3],10).toString(16)).slice(-2):""},riterate:function(e,t,n=!1){return il(e,t,n,!0)},roundDecimal:function(e,t){return Number(Math.round(parseFloat(e+"e"+t+"e-"+t)))},sanitize:function(e,t="_"){let n=["[","]","{","}","(",")","-","+","*","/"],r="[";for(let e=0;e<t.length;e++)n.includes(t[e])&&(r+="\\"),r+=t[e];r+="]+";let o=new RegExp(r,"g");return pd(gl(e).replace(/[^a-z0-9]/gi,t).replace(o,t),t)},search:Yl,selectElementText:function(e,t=null){if(t=t||window,e instanceof HTMLInputElement)return void e.select();let n,r,o=t.document;t.getSelection&&o.createRange?(n=t.getSelection(),r=o.createRange(),r.selectNodeContents(e),n.removeAllRanges(),n.addRange(r)):"createTextRange"in o.body&&"function"==typeof o.body.createTextRange&&(r=o.body.createTextRange(),r.moveToElementText(e),r.select())},selector:dd,setCookie:function(e,t,n){let r="";if(n){let e=new Date;e.setTime(e.getTime()+24*n*60*60*1e3),r="; expires="+e.toUTCString()}let o=escape(JSON.stringify({value:t}));document.cookie=e+"="+o+r+"; path=/"},setCssVar:function(e,t){0!==e.indexOf("--")&&(e="--"+e),document.documentElement.style.setProperty(e,t)},setNavigationVars:Xf,setProp:function(e,t,n,r=!0,o=!0){Object.defineProperty(e,t,{value:n,writable:r,configurable:o})},setProperty:hd,shorten:gd,shortenObj:function e(t,n=100){let r=Mf(t);return al(r,(t,o)=>{Qu(t)&&t.length>n?r[o]=gd(t,n):t&&"object"==typeof t&&(r[o]=e(t))}),r},shuffle:function(e){let t,n=e.length;for(;0!=n;)t=Math.floor(Math.random()*n),n--,[e[n],e[t]]=[e[t],e[n]];return e},simpleHash:Dl,simpleHash1:Ml,simpleHash2:Il,startChrono:function(e){let t=bbn.fn.microtimestamp();return this.constructor.chronos||Object.defineProperty(this.constructor,"chronos",{value:Object.create(null),writable:!1,configurable:!1}),this.constructor.chronos[e||"default"]=t,e},stopChrono:function(e,t){if(this.constructor.chronos[e||"default"]){let n=bbn.fn.microtimestamp()-this.constructor.chronos[e||"default"];return delete this.constructor.chronos[e||"default"],t&&(n=Math.round(n)/1e3),n}throw Error("No chrono with name "+(e||"default"))},stream:function(e,t,n,r,o,i){const a=ql(e,n,"json"),s=Fl(a);if(null==s?void 0:s.loader)return s.loader;n||(n={}),bbn.env.token&&(n._bbn_token=bbn.env.token);const c=new AbortController;let u="";const l=e=>{if(e.length){e=e.indexOf("\n")>-1?bbn.fn.removeEmpty(e.split("\n")):[e];for(let n in e)try{t(JSON.parse(e[n]))}catch(e){throw e}}},f=bbn.fn.startChrono(),d=fetch(e,{method:"POST",mode:"cors",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json"},redirect:"follow",referrerPolicy:"no-referrer",signal:c.signal,body:JSON.stringify(n||{})}).then(e=>{if(bbn.fn.log("RESPONSE IN "+bbn.fn.stopChrono(f,!0)+" SECS"),e.body){const r=e.body.getReader(),o=tl(t);r.read().then(function e({done:s,value:c}){if(s)return Ll(a,n),u&&l(u),void(i&&i());if(o)if(u+=Jl(c).trim(),bbn.fn.log(["STREAM RESULT",u.length,u]),u)try{l(u),u=""}catch(e){}else t();else bbn.fn.log(["STREAM SUCCESS IS FN? "+o]);return r.read().then(e)})}}).catch(t=>{let i=!(!(s=t)||!0!==s.__BBN_CANCEL__);var s;if(Ll(a,n,i),i){let n=1;tl(o)&&(n=o(t.message,e)),n&&_f(t.message,e)}else{let e=1;tl(r)&&(e=r(t.request,t)),e&&xf(t.request,t.response?t.response.data:"",t.response?t.response.status:t)}});return ml(a,d,c),d},string2ArrayBuffer:function(e){for(var t=new ArrayBuffer(2*e.length),n=new Uint16Array(t),r=0,o=e.length;r<o;r++)n[r]=e.charCodeAt(r);return t},submit:td,substr:rl,sum:function(e,t,n,r,o){let i=0;return al(Df(e,n,r,o),e=>{let n="function"==typeof t?t(e):e[t];n&&(i+=parseFloat(n)||0)}),i},timestamp:ad,toCSV:function(e,t=",",n="",r='"'){t||(t=","),r||(r='"');let o="",i=e.length;return al(e,(e,a)=>{let s=cl(e)?e.length:Object.values(e).length,c=0;al(e,e=>{o+="string"==typeof e?r+$l(r,"\\"+r,e)+r:0===e?"0":e&&e.toString?e.toString():r+r,c++,c<s&&(o+=t)}),a<i-1&&(o+=n+"\n")}),o},toggleFullScreen:function(){"mozRequestFullScreen"in window.document.documentElement?window.document.mozFullScreen?window.document.mozCancelFullScreen():"function"==typeof window.document.documentElement.mozRequestFullScreen&&window.document.documentElement.mozRequestFullScreen():"webkitRequestFullScreen"in window.document.documentElement?window.document.webkitIsFullScreen?window.document.webkitCancelFullScreen():"function"==typeof window.document.documentElement.webkitRequestFullScreen&&window.document.documentElement.webkitRequestFullScreen():"msRequestFullScreen"in window.document.documentElement?window.document.msFullscreenEnabled?window.document.msExitFullscreen():"function"==typeof window.document.documentElement.msRequestFullScreen&&window.document.documentElement.msRequestFullScreen():"requestFullscreen"in window.document&&(window.document.fullscreenEnabled?window.document.exitFullscreen():window.document.documentElement.requestFullscreen()),setTimeout(function(){nd()},0)},translate:function(e,t){let n=t?bbn.lng[0===t.indexOf("_")?t:"_"+t]:bbn.lng;il(e,(e,t)=>{n[t]=e})},treatAjaxArguments:Kf,treatForHash:_l,trim:pd,uniqString:function(...e){for(var t="",n=0;n<e.length;n++)if(e[n])if("object"==typeof e[n])if(cl(e[n]))t+=JSON.stringify(e[n]);else{let r={};al(Object.keys(e[n]).sort(),t=>{r[t]=e[n][t]}),t+=JSON.stringify(r)}else"string"!=typeof e[n]?t+=e[n].toString():t+=e[n];else t+="__bbn_empty__";return Ol(t)},unique:Zf,upload:function(e,t,n=null,r=null,o=null){const i=()=>Gu.run("post",e||bbn.env.path,{data:fd({file:t}),headers:{"Content-Type":"multipart/form-data"},onUploadProgress(e){if(o){let t=Math.round(100*e.loaded/e.total);o(t,e.loaded,e.total)}}});return n||r?i().then(e=>{n&&(nl("SUCCESS",e),n(e))}).catch(e=>{r&&(nl("ERROR",e),r(e))}):i()},warning:ld,yieldToBrowser:Ff},yd=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},vd=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class Ed{constructor(e,t,n,r,o,i,a){if(bd.set(this,void 0),e)if(void 0===t)if(e instanceof Hu.PlainDateTime)yd(this,bd,e,"f");else if(e instanceof Date)yd(this,bd,new Hu.PlainDateTime(e.getFullYear(),e.getMonth()+1,e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");{const t=new Date(e);yd(this,bd,new Hu.PlainDateTime(t.getFullYear(),t.getMonth()+1,t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()),"f")}}else yd(this,bd,new Hu.PlainDateTime(e,t,n||1,r||0,o||0,i||0,a||0),"f");else yd(this,bd,Hu.PlainDateTime.from(Hu.Now.plainDateISO()),"f")}get value(){return vd(this,bd,"f")}}bd=new WeakMap;const Md=(e,t,n)=>{let r="";const o=t.hourCycle,i=e.some(e=>"dayPeriod"===e.type),a=i||"h12"===o||"h11"===o,s=!!n.year,c=!!n.month,u=!!n.day,l=!!n.weekday,f="short"===n.month||"long"===n.month,d=s&&c&&u&&!l&&!f;for(const o of e)switch(o.type){case"year":"2-digit"===t.year?r+="YY":r+="YYYY";break;case"month":if("short"===n.month||"long"===n.month){r+="long"===n.month?"MMMM":"MMM";break}if(d){r+="M";break}/^\d+$/.test(o.value)?r+=2===o.value.length?"MM":"M":r+=o.value.length>3?"MMMM":"MMM";break;case"day":if(d){r+="D";break}r+=2===o.value.length?"DD":"D";break;case"weekday":"short"===n.weekday||"narrow"===n.weekday?r+="ddd":"long"===n.weekday?r+="dddd":r+=o.value.length>3?"dddd":"ddd";break;case"hour":r+=a?2===o.value.length?"hh":"h":2===o.value.length?"HH":"H";break;case"minute":r+="II";break;case"second":r+="SS";break;case"dayPeriod":r+="A";break;case"timeZoneName":r+="z";break;case"literal":if(!o.value)break;if(/[A-Za-zÀ-ÖØ-öø-ÿ]/.test(o.value)){r+=`[${o.value.replace(/]/g,"\\]")}]`}else r+=o.value;break;default:r+=o.value}return r},Id=e=>{e||(e=[bbn.env.lang,...navigator.languages]);const t=new Date(Date.UTC(2e3,0,2,13,45,30)),n=[],r=[],o=[],i=new Set,a=new Set,s=new Set,c=[{year:"numeric",month:"2-digit",day:"2-digit"},{year:"numeric",month:"numeric",day:"numeric"},{year:"numeric",month:"short",day:"numeric"},{year:"numeric",month:"long",day:"numeric"},{weekday:"short",year:"numeric",month:"short",day:"numeric"},{weekday:"long",year:"numeric",month:"long",day:"numeric"},{year:"numeric",month:"numeric"},{year:"numeric",month:"2-digit"},{year:"numeric",month:"short"},{year:"numeric",month:"long"},{month:"numeric",day:"numeric"},{month:"2-digit",day:"2-digit"},{month:"short",day:"numeric"},{month:"long",day:"numeric"}],u=[];for(const r of c){const o=new Intl.DateTimeFormat(e,r),a=o.formatToParts(t),s=o.resolvedOptions(),c=Md(a,s,r);i.has(c)||(i.add(c),n.push({pattern:c,sample:o.format(t),options:r})),r.year&&r.month&&r.day&&u.push(r)}const l=[{hour:"numeric"},{hour:"2-digit",minute:"2-digit"},{hour:"2-digit",minute:"2-digit",second:"2-digit"},{hour:"2-digit",minute:"2-digit",timeZoneName:"short"},{hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:"short"},{hour:"2-digit",minute:"2-digit",timeZoneName:"long"}];for(const n of l){const o=new Intl.DateTimeFormat(e,n),i=o.formatToParts(t),s=o.resolvedOptions(),c=Md(i,s,n);a.has(c)||(a.add(c),r.push({pattern:c,sample:o.format(t),options:n}))}for(const n of u)for(const r of l){const i=Object.assign(Object.assign({},n),r),a=new Intl.DateTimeFormat(e,i),c=a.formatToParts(t),u=a.resolvedOptions(),l=Md(c,u,i);s.has(l)||(s.add(l),o.push({pattern:l,sample:a.format(t),options:i}))}return{date:n,time:r,datetime:o}},Dd=()=>{if(Object.keys(bbn.dt.locales).length)return;const e=[bbn.env.lang,...navigator.languages],t=new Intl.DateTimeFormat(e,{month:"long"}),n=new Intl.DateTimeFormat(e,{month:"short"}),r=new Intl.DateTimeFormat(e,{weekday:"long"}),o=new Intl.DateTimeFormat(e,{weekday:"short"}),i=[],a=[];for(let e=0;e<12;e++){const r=new Date(2020,e,1);i.push(t.format(r)),a.push(n.format(r))}const s=new Date(2020,1,2),c=[],u=[];for(let e=0;e<7;e++){const t=new Date(s.getTime()+864e5*e);c.push(r.format(t)),u.push(o.format(t))}const{date:l,time:f,datetime:d}=Id(e);ul(bbn.dt.locales,{monthsLong:i,monthsShort:a,weekdaysLong:c,weekdaysShort:u,date:l,time:f,datetime:d})};function Sd(e,t=!1,n=Hu.Now.timeZoneId()){const r=Hu.Instant.fromEpochMilliseconds(e.getTime()).toZonedDateTimeISO(n);return t?r:r.toPlainDateTime()}var kd,Td=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},_d=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class xd{constructor(e,t,n,r,o,i,a,s){if(kd.set(this,void 0),e)if(void 0===t)if(e instanceof Hu.ZonedDateTime)Td(this,kd,e,"f");else if(e instanceof Date)Td(this,kd,Sd(e,!0),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtZoned");{const t=new Date(e);Td(this,kd,Sd(t,!0),"f")}}else{const c=new Hu.PlainDateTime(t,n,r||1,o||0,i||0,a||0,s||0);Td(this,kd,c.toZonedDateTime(e||Hu.Now.timeZoneId()),"f")}else{const e=new Date;Td(this,kd,new Hu.ZonedDateTime(BigInt(1e6*e.getTime()),Intl.DateTimeFormat().resolvedOptions().timeZone),"f")}}get value(){return _d(this,kd,"f")}}kd=new WeakMap;var Od,jd=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},Cd=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class Rd{constructor(e,t,n){if(Od.set(this,void 0),e){if(void 0===t)if(e instanceof Hu.PlainDate)jd(this,Od,e,"f");else if(e instanceof Date)jd(this,Od,new Hu.PlainDate(e.getFullYear(),e.getMonth()+1,e.getDate()),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");{const t=new Date(e);jd(this,Od,new Hu.PlainDate(t.getFullYear(),t.getMonth()+1,t.getDate()),"f")}}}else jd(this,Od,Hu.PlainDate.from(Hu.Now.plainDateISO()),"f")}get value(){return Cd(this,Od,"f")}}Od=new WeakMap;var Nd,Pd=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},Yd=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class Ad{constructor(e,t,n,r){if(Nd.set(this,void 0),e){if(void 0===e)if(e instanceof Hu.PlainTime)Pd(this,Nd,e,"f");else if(e instanceof Date)Pd(this,Nd,new Hu.PlainTime(e.getHours(),e.getMinutes(),e.getSeconds(),1e6*e.getMilliseconds()),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");if(void 0!==t)Pd(this,Nd,new Hu.PlainTime(e,t,n||0,r||0),"f");else{const t=new Date(e);Pd(this,Nd,new Hu.PlainTime(t.getHours(),t.getMinutes(),t.getSeconds(),1e6*t.getMilliseconds()),"f")}}}else{const e=new Date;Pd(this,Nd,new Hu.PlainTime(e.getHours(),e.getMinutes(),e.getSeconds(),1e6*e.getMilliseconds()),"f")}}get value(){return Yd(this,Nd,"f")}}Nd=new WeakMap;var Ld,Fd=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},Hd=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class Bd{constructor(e,t){if(Ld.set(this,void 0),e){if(void 0===t)if(e instanceof Hu.PlainYearMonth)Fd(this,Ld,e,"f");else if(e instanceof Date)Fd(this,Ld,new Hu.PlainYearMonth(e.getFullYear(),e.getMonth()+1),"f");else{if("number"!=typeof t)throw new Error("Invalid value for bbnDtDateTime");{const e=new Date(t);Fd(this,Ld,new Hu.PlainYearMonth(e.getFullYear(),e.getMonth()+1),"f")}}}else{const e=new Date;Fd(this,Ld,new Hu.PlainYearMonth(e.getFullYear(),e.getMonth()+1),"f")}}get value(){return Hd(this,Ld,"f")}}Ld=new WeakMap;var Ud,Zd=function(e,t,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(e,n):o?o.value=n:t.set(e,n),n},Wd=function(e,t,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(e):r?r.value:t.get(e)};class $d{constructor(e,t){if(Ud.set(this,void 0),e)if(void 0===t)if(e instanceof Hu.PlainMonthDay)Zd(this,Ud,e,"f");else if(e instanceof Date)Zd(this,Ud,new Hu.PlainMonthDay(e.getMonth()+1,e.getDate()),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");{const t=new Date(e);Zd(this,Ud,new Hu.PlainMonthDay(t.getMonth()+1,t.getDate()),"f")}}else Zd(this,Ud,new Hu.PlainMonthDay(e,t),"f");else{const e=new Date;Zd(this,Ud,new Hu.PlainMonthDay(e.getMonth()+1,e.getDate()),"f")}}get value(){return Wd(this,Ud,"f")}}Ud=new WeakMap;const qd=function(e,t){try{return t?e.toLocaleLowerCase(t):e.toLowerCase()}catch(t){return e.toLowerCase()}};function zd(e,t,n="auto",r){var o,i,a,s,c,u,l;Dd();const f=globalThis.Temporal;if(!f)throw new Error("Temporal API is required (load @js-temporal/polyfill)");const d=f;r||(r=(null===(o=null==bbn?void 0:bbn.dt)||void 0===o?void 0:o.locales)||{});const h={monthsLong:null!==(i=null==r?void 0:r.monthsLong)&&void 0!==i?i:bbn.dt.locales.monthsLong,monthsShort:null!==(a=null==r?void 0:r.monthsShort)&&void 0!==a?a:bbn.dt.locales.monthsShort,weekdaysLong:null!==(s=null==r?void 0:r.weekdaysLong)&&void 0!==s?s:bbn.dt.locales.weekdaysLong,weekdaysShort:null!==(c=null==r?void 0:r.weekdaysShort)&&void 0!==c?c:bbn.dt.locales.weekdaysShort},m=(null==bbn?void 0:bbn.env)&&(null===(u=bbn.env)||void 0===u?void 0:u.lang)||(null==bbn?void 0:bbn.dt)&&(null===(l=bbn.dt)||void 0===l?void 0:l.locale)||Intl.DateTimeFormat().resolvedOptions().locale,p=e=>e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");function g(t,n="auto"){var r;const o={year:1970,month:1,day:1,hour:0,minute:0,second:0,ms:0,hasYear:!1,hasMonth:!1,hasDay:!1,hasHour:!1,hasMinute:!1,hasSecond:!1,hasMs:!1},i="auto"===n,a="zoned"===n.toLowerCase(),s="datetime"===n.toLowerCase(),c="date"===n.toLowerCase(),u="time"===n.toLowerCase(),l="yearmonth"===n.toLowerCase(),f="monthday"===n.toLowerCase(),g=[{token:"YYYY",regex:"\\d{4}",apply:(e,t)=>{t.year=parseInt(e,10),t.hasYear=!0}},{token:"YY",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);t.year=n>=70?1900+n:2e3+n,t.hasYear=!0}},{token:"Y",regex:"[+-]?\\d{1,6}",apply:(e,t)=>{t.year=parseInt(e,10),t.hasYear=!0}},{token:"MMMM",regex:"[^\\d\\s]+",apply:(e,t)=>{const n=qd(e,m),r=h.monthsLong.findIndex(e=>qd(e,m)===n);if(-1===r)throw new Error("Invalid month name: "+e);t.month=r+1,t.hasMonth=!0}},{token:"MMM",regex:"[^\\d\\s]+",apply:(e,t)=>{const n=qd(e,m),r=h.monthsShort.findIndex(e=>qd(e,m)===n);if(-1===r)throw new Error("Invalid short month name: "+e);t.month=r+1,t.hasMonth=!0}},{token:"MM",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>12)throw new Error("Invalid month: "+n);t.month=n,t.hasMonth=!0}},{token:"mm",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid minute: "+n);t.month=n,t.hasMonth=!0}},{token:"M",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>12)throw new Error("Invalid month: "+n);t.month=n,t.hasMonth=!0}},{token:"m",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>12)throw new Error("Invalid month: "+n);t.month=n,t.hasMonth=!0}},{token:"DD",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>31)throw new Error("Invalid day of month: "+n);t.day=n,t.hasDay=!0}},{token:"D",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>31)throw new Error("Invalid day of month: "+n);t.day=n,t.hasDay=!0}},{token:"d",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>31)throw new Error("Invalid day of month: "+n);t.day=n,t.hasDay=!0}},{token:"dddd",regex:"[^\\d\\s]+",apply:(e,t)=>{const n=qd(e,m),r=h.weekdaysLong.findIndex(e=>qd(e,m)===n);if(-1===r)throw new Error("Invalid weekday name: "+e);t.weekday=r}},{token:"ddd",regex:"[^\\d\\s]+",apply:(e,t)=>{const n=qd(e,m),r=h.weekdaysShort.findIndex(e=>qd(e,m)===n);if(-1===r)throw new Error("Invalid short weekday name: "+e);t.weekday=r}},{token:"EE",regex:"\\d{1}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>7)throw new Error("Invalid weekday number: "+n);t.weekday=n}},{token:"hh",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>12)throw new Error("Invalid 12-hour clock hour: "+n);t.hour=n,t.hasHour=!0,t.uses12Hour=!0}},{token:"HH",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>23)throw new Error("Invalid hour: "+n);t.hour=n,t.hasHour=!0}},{token:"H",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>23)throw new Error("Invalid hour: "+n);t.hour=n,t.hasHour=!0}},{token:"h",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>23)throw new Error("Invalid hour: "+n);t.hour=n,t.hasHour=!0}},{token:"II",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid minute: "+n);t.minute=n,t.hasMinute=!0}},{token:"I",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid minute: "+n);t.minute=n,t.hasMinute=!0}},{token:"i",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid minute: "+n);t.minute=n,t.hasMinute=!0}},{token:"SS",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid second: "+n);t.second=n,t.hasSecond=!0}},{token:"S",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid second: "+n);t.second=n,t.hasSecond=!0}},{token:"s",regex:"\\d{2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>59)throw new Error("Invalid second: "+n);t.second=n,t.hasSecond=!0}},{token:"ms",regex:"\\d{1,3}",apply:(e,t)=>{const n=parseInt(e,10);if(n<0||n>999)throw new Error("Invalid millisecond: "+n);t.ms=n,t.hasMs=!0}},{token:"WWWW",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>53)throw new Error("Invalid week number: "+n);t.week=n}},{token:"WWW",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>53)throw new Error("Invalid week number: "+n);t.week=n}},{token:"WW",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>53)throw new Error("Invalid week number: "+n);t.week=n}},{token:"W",regex:"\\d{1,2}",apply:(e,t)=>{const n=parseInt(e,10);if(n<1||n>53)throw new Error("Invalid week number: "+n);t.week=n}},{token:"Z",regex:"(?:Z|[+-]\\d{2}:?\\d{2})",apply:(e,t)=>{if("Z"===e||"z"===e)return void(t.offsetMinutes=0);const n="-"===e[0]?-1:1,r=e.slice(1);let o,i;if(r.includes(":")){const[e,t]=r.split(":");o=parseInt(e,10),i=parseInt(t,10)}else o=parseInt(r.slice(0,2),10),i=parseInt(r.slice(2,4),10);if(o<0||o>23||i<0||i>59)throw new Error("Invalid timezone offset: "+e);t.offsetMinutes=n*(60*o+i)}},{token:"z",regex:"[A-Za-z_\\/]+",apply:(e,t)=>{t.timeZone=e}},{token:"A",regex:"(?:AM|PM|am|pm)",apply:(e,t)=>{t.isPM=/pm/i.test(e),t.hasAmPm=!0}},{token:"a",regex:"(?:AM|PM|am|pm)",apply:(e,t)=>{t.isPM=/pm/i.test(e),t.hasAmPm=!0}}],b=[...g].sort((e,t)=>t.token.length-e.token.length);let w="";const y=[];let v=0;for(;v<t.length;){if("["===t[v]){let e=v+1,n="";for(;e<t.length&&"]"!==t[e];)n+=t[e],e++;if(e<t.length&&"]"===t[e]){const t=n.replace(/\\]/g,"]");w+=p(t),v=e+1;continue}}let e=null;for(const n of b)if(t.startsWith(n.token,v)){e=n;break}e?(w+=`(${e.regex})`,e.apply?y.push(t=>e.apply(t,o)):y.push(()=>{}),v+=e.token.length):(w+=p(t[v]),v+=1)}const E=new RegExp("^"+w+"$").exec(e);if(!E)throw new Error(`Date string "${e}" does not match format "${t}"`);for(let e=1;e<E.length;e++){const t=E[e],n=y[e-1];null!=t&&n&&n(t)}if(o.uses12Hour){if(!o.hasAmPm)throw new Error("AM/PM marker (A or a) is required with 12-hour format (hh)");let e=o.hour;o.isPM?e<12&&(e+=12):12===e&&(e=0),o.hour=e}const M=o.hasYear||o.hasMonth||o.hasDay,I=o.hasYear&&o.hasMonth&&o.hasDay,D=o.hasYear&&o.hasMonth&&!o.hasDay,S=!o.hasYear&&o.hasMonth&&o.hasDay,k=o.hasHour||o.hasMinute||o.hasSecond||o.hasMs,T=null!=o.timeZone||null!=o.offsetMinutes;if(a||T&&i){let e;try{e=new d.PlainDateTime(o.year,o.month,o.day,o.hour,o.minute,o.second,1e6*o.ms)}catch(e){throw new Error("Invalid date/time components")}if(o.timeZone){const t=d.TimeZone.from(o.timeZone),n=e.toZonedDateTime(t);return new xd(n)}const t=Date.UTC(o.year,o.month-1,o.day,o.hour,o.minute,o.second,o.ms)-6e4*(null!==(r=o.offsetMinutes)&&void 0!==r?r:0);return new xd(d.Instant.fromEpochMilliseconds(t).toZonedDateTimeISO(d.Now.timeZoneId()))}if(s||i&&M&&k){if(!I)throw new Error("PlainDateTime requires year, month and day");const e=new d.PlainDateTime(o.year,o.month,o.day,o.hour,o.minute,o.second,1e6*o.ms);return new Ed(e)}if(c||l||f||i&&M&&!k){if(c||I&&i){const e=new d.PlainDate(o.year,o.month,o.day);return new Rd(e)}if(l||D&&i){const e=new d.PlainYearMonth(o.year,o.month);return new Bd(e)}if(f||S&&i){const e=new d.PlainMonthDay(o.month,o.day,1972);return new $d(e)}throw new Error("Not enough date components for a known Temporal type")}if(u||i&&!M&&k){const e=new d.PlainTime(o.hour,o.minute,o.second,1e6*o.ms);return new Ad(e)}throw new Error("No date or time information found in input")}if(Array.isArray(t)){let e=null;for(const r of t)try{return g(r,n)}catch(t){e=t}throw null!=e?e:new Error("No format matched")}return g(t,n)}const Vd=["YYYY-MM-DD","YYYY-MM-DD HH:II:SS.ms","YYYY-MM-DD HH:II:SS","YYYY-MM-DD HH:II","HH:II:SS","HH:II","YYYY-MM-DDTHH:II:SS.msZ","YYYY-MM-DDTHH:II:SSZ","YYYY-MM-DDTHH:II:SS","YYYY-MM-DDTHH:II","ddd[, ]DD MMM YYYY HH:II:SS[ GMT]","ddd MMM DD YYYY HH:II:SS[ GMT]Z","ddd MMM DD YYYY HH:II:SS"],Jd=e=>!/[HhI SAz]/.test(e)&&!!(/[Y]/.test(e)&&/[M]/.test(e)&&/[D]/.test(e)),Gd=e=>e.replace(/DD/g,"D").replace(/MM/g,"M"),Kd=(e,t)=>{if(/[HhI SAzM]{2,}|[A-Za-z]/.test(e.replace(/[DMY]/g,"")))return e;if(!e.includes("D")||!e.includes("M")||!e.includes("Y"))return e;const n=t.split(/\D+/).filter(Boolean);if(n.length<3)return e;const[r,o]=n;if(2===r.length&&2===o.length){let t=e;return t=t.replace(/D+/,"DD"),t=t.replace(/M+/,"MM"),t}return e};function Xd(e,t,n){const r=e.trim();if(!r)return null;Dd();const o=e=>{for(const t of e){try{return zd(r,t),Kd(t,r)}catch(e){}if(Jd(t)){const e=Gd(t);if(e!==t)try{return zd(r,e),e}catch(e){}}}return null};if(t){return o(Array.isArray(t)?t:[t])}const i=Id(n),a=new Set,s=Vd.filter(e=>!a.has(e)&&(a.add(e),!0)),c=[...i.datetime.map(e=>e.pattern),...i.date.map(e=>e.pattern),...i.time.map(e=>e.pattern)].filter(e=>!a.has(e)&&(a.add(e),!0)),u=o([...s,...c]);return u||null}const Qd=(e,t=null,n="auto")=>{if(!e)return new Ed;if("string"==typeof e){if(t)return zd(e,t,n);{const t=Xd(e);if(t)return zd(e,t,n);throw new Error(Zu("Could not guess the date format for value: %s",e))}}if("number"==typeof e)return new Ed(e);if(e instanceof Date){const t=e;return new Ed(t.getFullYear(),t.getMonth()+1,t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds())}throw new Error(Zu("Invalid date value: %s",e))};Qd.locales=Object.create(null),Qd.parse=zd,Qd.guessFormat=Xd,Qd.time=()=>{},Qd.date=()=>{},Qd.dateTime=()=>{},Qd.duration=()=>{},Qd.zoned=()=>{},Qd.monthDay=()=>{},Qd.yearMonth=()=>{};const eh={version:"1.0.1",opt:{_cat:{}},app:{},_:Zu,$:function(e,t){if(null==t?void 0:t.querySelectorAll)return t.querySelectorAll(e);if(t)throw new Error("Invalid context");return document.body.querySelectorAll(e)},lng:{select_unselect_all:"Select/Clear all",select_all:"Select all",search:"Search",loading:"Loading...",choose:"Choose",error:"Error",server_response:"Server response",reload:"Reload",errorText:"Something went wrong",closeAll:"Close all",closeOthers:"Close others",pin:"Pin",arrange:"Arrange",cancel:"Cancel",unpin:"Unpin",yes:"Yes",no:"No",unknown:"Unknown",untitled:"Untitled",confirmation:"Confirmation",Today:"Today",Tomorrow:"Tomorrow",Yesterday:"Yesterday"},var:Wu,date:gf,dt:Qd,com:Gu,env:$u,db:hl,fn:wd,info:[{value:"ajax",label:"Loading and streaming",description:"Functions related to Ajax requests",icon:"nf nf-fa-rocket"},{value:"browser",label:"Browser-only",description:"Functions that can only be run in the browser",icon:"nf nf-fa-desktop"},{value:"convert",label:"Conversion",description:"Functions related to data conversion",icon:"nf nf-fa-exchange"},{value:"datetime",label:"Date and time",description:"Functions related to dates and times",icon:"nf nf-fa-calendar"},{value:"form",label:"Form manipulation",description:"Functions related to form manipulation and validation",icon:"nf nf-fa-edit"},{value:"html",label:"HTML manipulation",description:"Functions related to HTML manipulation and DOM interaction",icon:"nf nf-fa-html5"},{value:"loop",label:"Looping",description:"Functions related to looping through arrays and objects",icon:"nf nf-fa-repeat"},{value:"misc",label:"Miscellaneous",description:"Miscellaneous functions that do not fit into other categories",icon:"nf nf-fa-cubes"},{value:"object",label:"Object manipulation",description:"Functions related to object manipulation and inspection",icon:"nf nf-fa-object_group"},{value:"phone",label:"Phone and contact",description:"Functions related to phone numbers and contact information",icon:"nf nf-fa-phone"},{value:"string",label:"String manipulation",description:"Functions related to string manipulation and formatting",icon:"nf nf-fa-text_height"},{value:"style",label:"Styling and layout",description:"Functions related to styling and layout management",icon:"nf nf-fa-paint_brush"},{value:"type",label:"Type checking",description:"Functions related to type checking and validation",icon:"nf nf-fa-check_square"}]};return"undefined"!=typeof window&&(window.bbn=eh,window.Temporal||(window.Temporal=Hu)),e.Temporal=Hu,e.bbn=eh,e.default=eh,Object.defineProperty(e,"__esModule",{value:!0}),e}({});
2
2
  //# sourceMappingURL=bbn.js.map