@bbn/bbn 2.0.65 → 2.0.66
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 +1 -1
- package/dist/bbn.js.map +1 -1
- package/dist/dt/classes/date.d.ts +1 -3
- package/dist/dt/classes/date.js +13 -26
- package/dist/dt/classes/dateTime.d.ts +1 -3
- package/dist/dt/classes/dateTime.js +10 -26
- package/dist/dt/classes/dt.d.ts +72 -0
- package/dist/dt/classes/dt.js +470 -0
- package/dist/dt/classes/duration.d.ts +39 -0
- package/dist/dt/classes/duration.js +185 -0
- package/dist/dt/classes/monthDay.d.ts +1 -3
- package/dist/dt/classes/monthDay.js +10 -26
- package/dist/dt/classes/time.d.ts +1 -2
- package/dist/dt/classes/time.js +13 -26
- package/dist/dt/classes/yearMonth.d.ts +1 -3
- package/dist/dt/classes/yearMonth.js +12 -25
- package/dist/dt/classes/zoned.d.ts +1 -3
- package/dist/dt/classes/zoned.js +10 -26
- package/dist/dt/functions/getWeekday.d.ts +3 -0
- package/dist/dt/functions/getWeekday.js +58 -0
- package/dist/dt/vars/types.d.ts +0 -1
- package/dist/dt/vars/units.d.ts +11 -0
- package/dist/dt/vars/units.js +109 -0
- package/dist/dt.d.ts +2 -1
- package/package.json +1 -1
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(Do(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 u(e){return{[Symbol.toStringTag]:{value:e,configurable:1}}}function c(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 D(e,t){return[Math.floor(e/t),I(e,t)]}function I(e,t){return(e%t+t)%t}function k(e,t){return[S(e,t),T(e,t)]}function S(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,[u,c]=k(t,s);r+=c*a,o+=u}const[i,a]=k(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]]=S(e,t),e=T(e,t)}return r}function j(e){if(void 0!==e)return R(e)}function C(e){return F(R(e))}function R(e){return A($i(e))}function N(e,t){if(null==t)throw new RangeError(Do(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 F(e,t="number"){if(e<=0)throw new RangeError(po(t,e));return e}function L(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 F(Z(e,t),t)}function q(e,t){let[n,r]=k(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]=k(e,n);return[r,o*t]}function ee(e,t=1,n){const[r,o]=e,[i,a]=k(o,t);return r*(bi/t)+(i+(n?a/t:0))}function te(e,t,n=D){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]=D(e,bi);return[O(n,5,ta),t]}function ue(e){return te(e,mi)}function ce(e){return he(e.isoYear,e.isoMonth,e.isoDay,e.isoHour,e.isoMinute,e.isoSecond,e.isoMillisecond)}function le(e){const t=ce(e);if(void 0!==t){const[n,r]=k(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,u=new Date;return u.setUTCHours(r,o,i,a),u.setUTCFullYear(e,t-1,n+s),[u,s]}function pe(e,t){let[n,r]=V(e,t);r<0&&(r+=bi,n-=1);const[o,i]=D(r,hi),[a,s]=D(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 c(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 De(e)?29:28;case 4:case 6:case 9:case 11:return 30}return 31}function Me(e){return De(e)?366:365}function De(e){return e%4==0&&(e%100!=0||e%400==0)}function Ie(e){const[t,n]=me(e.isoYear,e.isoMonth,e.isoDay);return I(t.getUTCDay()-n,7)||7}function ke(e){return this.id===Fi?(({isoYear:e})=>e<1?["gregory-inverse",1-e]:["gregory",e])(e):this.id===Li?Ea(e):[]}function Se(e){const t=ce(e);if(t<va){const{isoYear:t}=e;return t<1?["japanese-inverse",1-t]:["japanese",t]}const n=be(Cs(Li),t),{era:r,eraYear:o}=jr(n,Li);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 c(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=Fa(t,r,o),s=He(t),u=qa(t,i);const c=Aa(t,r,o,1);return null==a?a=Math.max(n,c):Ve(a,c),s=Be(s,c,1),e&&(u=(e=>e<4?(e+2)%4:e)(u)),[a,c,s,u]}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 Fe(Ze(e),t)}function Fe(e,t=4){const n=Ue(e);return[qa(e,4),...Le(Aa(e,t),n)]}function Le(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[Ia];return void 0===t?1:Z(t,Ia)}function Be(e,t,r,o){const i=o?bi:wi[t+1];if(i){const r=wi[t];if(i%((e=n(Ia,e,1,i/r-(o?0:1),1))*r))throw new RangeError(Mo(Ia,e))}else e=n(Ia,e,1,r?10**9:1,1);return e}function Ue(e){let t=e[ka];if(void 0!==t){if("number"!=typeof t){if("auto"===L(t))return;throw new RangeError(Mo(ka,t))}t=n(ka,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=L(a),"auto"===a)return i?o:null;let s=ui[a];if(void 0===s&&(s=Ki[a]),void 0===s)throw new RangeError(To(e,a,ui));return n(e,s,o,r,1,ci),s}function ze(e,t,n,r=0){const o=n[e];if(void 0===o)return r;const i=L(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],u={...t,[s]:t[s]+r},c=a(e,o,t),l=a(e,o,u);return[i(c),i(l)]}function st(e,t,n){const r=ee(J(t,n));if(!r)throw new RangeError(Fo);return ee(J(t,e))/r}function ut(e,t,n,r){return ct(e,dt(t,n),r)}function ct(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 ua(6,e)}function pt(e,t,n){const r=Math.min(In(e),6);return En(wt(vn(e,r),t,n),r)}function gt(e,t,n,r,o,i,a,s,u,c){if(0===r&&1===o)return e;const l=hn(r,s)?dn(s)&&r<6&&n>=6?Mt:Et:Dt;let[f,d,h]=l(e,t,n,r,o,i,a,s,u,c);return h&&7!==r&&(f=((e,t,n,r,o,i,a,s)=>{const u=bn(e);for(let c=r+1;c<=n;c++){if(7===c&&7!==n)continue;const r=ea(c,e);r[qi[c]]+=u;const l=ee(J(a(s(o,i,r)),t));if(l&&Math.sign(l)!==u)break;e=r}return e})(f,d,n,Math.max(6,r),a,s,u,c)),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]=D(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),u=bt(s,r,o,i),c=J(s,u),l=Math.sign(u[0]-s[0])===a,f=En(u,Math.min(n,6));return[{...e,...f},z(t,c),l]}function Mt(e,t,n,r,o,i,a,s,u,c){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,u,c),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 Dt(e,t,n,r,o,i,a,s,u,c){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=S(e[f],o)*o;d[f]=h;const[m,p]=at(a,d,r,o*l,s,u,c),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 It(e,t,n,r){const[o,i,a,s]=(e=>{const t=Fe(e=Ze(e));return[e.timeZone,...t]})(r),u=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?Lt(ft(a)):"Z")})(u,t(u?e(o):ns),n.epochNanoseconds,i,a,s)}function kt(e,t,n){const[r,o,i,a,s,u]=(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,...Le(i,n)]})(n);return((e,t,n,r,o,i,a,s,u,c)=>{r=wt(r,u,s,1);const l=e(n).R(r);return Nt(pe(r,l),c)+Lt(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,u)}function St(e,t){const[n,r,o,i]=(e=>(e=Ze(e),[Za(e),...Fe(e)]))(t);return a=e.calendar,s=n,u=i,Nt(ct(e,o,r),u)+Ht(a,s);var a,s,u}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,Ft(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,k);yn(a);const u=Ut(s,t),c=t>=0||!n||u;return(n<0?"-":"")+"P"+Rt({Y:Wt(r.years),M:Wt(r.months),W:Wt(r.weeks),D:Wt(r.days)})+(o||i||a||c?"T"+Rt({H:Wt(o),M:Wt(i),S:Wt(a,c)+u}):"")})(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"+Ft(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 Ft(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 Lt(e,t=0){if(1===t)return"";const[n,r]=D(Math.abs(e),gi),[o,i]=D(r,pi),[a,s]=D(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(Dn(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 u=a.P(s,r,o);return Qe(on(a,u),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(Dn(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(ce(e)+t*li)}:e}function un(e,t,n){const r=e(n.calendar);return dn(n)?[n,r,t(n.timeZone)]:[{...n,...sa},r]}function cn(e){return e?ot:le}function ln(e){return e?b(tn,e):nn}function fn(e){return e?b(sr,e):ur}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),u=Math.max(In(o),In(i));if(hn(u,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,u,r)));if(!s)throw new RangeError(Ko);r&&(i=gn(i));const[c,l,f]=un(t,n,s),d=ln(f),h=fn(f),m=d(l,c,o);return nt(h(l,c,d(l,m,i),u))}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],-us,us,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 Dn(e){return Boolean(bn(e,Ji))}function In(e){let t=9;for(;t>0&&!e[qi[t]];t--);return t}function kn(e,t){return[e,t]}function Sn(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=cs(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:Fn(e),isoMonth:parseInt(e[4]),isoDay:parseInt(e[5]),...Ln(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:Fn(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=Is.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 Fn(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 Ln(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(ks,(e,o,i)=>{const a=Boolean(o),[s,u]=i.split("=").reverse();if(u){if("u-ca"===u)r.push(s),t||(t=a);else if(a||/[A-Z]/.test(u))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?Lt(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(ce(e),ce(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,u,c,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,u,c,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=cr(f,n,r,o,h,s,i),m=gt(m,d,s,u,c,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,u,c]=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,u,c);else{const t=e(i);h=lr(t,n,r,d,a,o),h=gt(h,f,a,s,u,c,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),u=on(s,n),c=on(s,r);return u.isoYear===c.isoYear&&u.isoMonth===c.isoMonth&&u.isoDay===c.isoDay?nt(Xi):ir(t,()=>s,re(u),re(c),...a,8)}function ir(e,t,n,r,o,i,a,s,u=6){const c=le(n),l=le(r);if(void 0===c||void 0===l)throw new RangeError(Vo);let f;if(G(l,c))if(6===o)f=fr(c,l,o,i,a,s);else{const e=t();f=e.N(n,r,o),i===u&&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),u=yt(pr(t,n),dt(i,a),s),c={...Xi,...Mn(u,o)};return nt(e?gn(c):c)}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):cr(t,e,n,r,a,o,i):Xi}function ur(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 cr(e,t,n,r,o,i,a){const[s,u,c]=((e,t,n,r)=>{function o(){return f={...sn(s,c++*-r),...a},d=zt(e,f),G(u,d)===-r}const i=ss(t,e),a=h(ta,i),s=ss(n,e),u=n.epochNanoseconds;let c=0;const l=pr(i,s);let f,d;if(Math.sign(l)===-r&&c++,o()&&(-1===r||o()))throw new RangeError(Fo);const m=ee(J(d,u));return[i,f,m]})(t,n,r,o);var l,f;return{...6===i?(l=s,f=u,{...Xi,days:hr(l,f)}):e.N(s,u,i,a),...Mn(c)}}function lr(e,t,n,r,o,i){const[a,s,u]=((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(u)}}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(ce(e),ce(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),ce(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 Dr(e,t){return e-(t&&e>=t?1:0)}function Ir(e,t){return(t+e)*(Math.sign(t)||1)||0}function kr(e){return Hi[Tr(e)]}function Sr(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=ce(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(Fo)}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=Ir(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[Dr(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=Sr(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 Fr(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 Lr(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!==Fi){const t=Cs(e).resolvedOptions().calendar;if(Wr(e)!==Wr(t))throw new RangeError(Lo(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===Fi||n===Li?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,[],Ii);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(ko(r));if("constructor"===r||"__proto__"===r)throw new RangeError(Io(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(Do(r));o[r]=Yi[r]}i=r}if(r&&!a)throw new TypeError(So(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=kr(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=Ir(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=Sr(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=Eu,...s)=>{const u=t(o&&o(...s),i,a,r,n),c=u.resolvedOptions();return[u,...uo(e,c,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 uo(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 co(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 Ou||(Ou=(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}`,Do=e=>`Missing ${e}`,Io=e=>`Invalid field ${e}`,ko=e=>`Duplicate field ${e}`,So=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",Fo="Invalid protocol results",Lo=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),ui={nanosecond:0,microsecond:1,millisecond:2,second:3,minute:4,hour:5,day:6,week:7,month:8,year:9},ci=Object.keys(ui),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=ci.slice(0,6),vi=y(yi),Ei=["offset"],Mi=["timeZone"],Di=yi.concat(Ei),Ii=Di.concat(Mi),ki=["era","eraYear"],Si=ki.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",Fi="gregory",Li="japanese",Hi={[Fi]:{"gregory-inverse":-1,gregory:0},[Li]:{"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={[Fi]:{bce:"gregory-inverse",ce:"gregory"},[Li]:{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=ci.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),ua=b(g,ra),ca=1e8,la=ca*li,fa=[ca,0],da=[-ca,0],ha=275760,ma=-271821,pa=Intl.DateTimeFormat,ga="en-GB",ba=1970,wa=1972,ya=12,va=he(1868,9,8),Ea=o(Se,WeakMap),Ma="smallestUnit",Da="unit",Ia="roundingIncrement",ka="fractionalSecondDigits",Sa="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),Fa=b(qe,"largestUnit"),La=b(qe,Da),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),us=2**32-1,cs=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,u]=Sn(t),c=r(o),l=r(u);return c===l?c:n(i(o,u),c,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(kn);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[u,c]=Sn(o);const l=rs*t,f=t<0?()=>c>a||(a=o,0):()=>u<s||(s=o,0);for(;f();){const o=r(u),a=r(c);if(o!==a){const r=i(u,c);n(r,o,a);const s=r[0];if((E(s,e)||1)===t)return s}u+=l,c+=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=>ue(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]=ue(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),Ds=Un("T?"+ps+"(?:"+gs+")?"+ys),Is=Un(gs),ks=new RegExp(ws,"g"),Ss=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:u,days:c}=t;if(c+=vn(t,5)[0],a||s)i=((e,t,r,o,i)=>{let[a,s,u]=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)),u=n("day",u,1,e.U(a,s),i),e.p(a,s,u)})(this,e,a,s,o);else{if(!u&&!c)return e;i=ce(e)}if(void 0===i)throw new RangeError(Vo);return i+=(7*u+c)*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]=k(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,u=i-n,c=a-r;if(s||u){const l=Math.sign(s||u);let f=e.U(o,i),d=0;if(Math.sign(c)===-l){const r=f;[o,i]=e.un(o,i,-l),s=o-t,u=i-n,f=e.U(o,i),d=l<0?-r:f}if(c=a-Math.min(r,f)+d,s){const[r,a]=e.q(t,n),[c,f]=e.q(o,i);if(u=c-r||Number(f)-Number(a),Math.sign(u)===-l){const n=l<0&&-e.B(o);s=(o-=l)-t,u=i-Mr(r,a,e.L(o))+(n||e.B(o))}}}return[s,u,c]})(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=Dr(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!==Fi&&this.id!==Li)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 u=this.G(o,i,r);if(!u)throw new RangeError("Cannot guess year");const[c,l]=u;return et(re(this.V(c,l,r)),this.id||Ai)},fields(e){return kr(this)&&e.includes("year")?[...e,...ki]:e},k(e,t){const n=Object.assign(Object.create(null),e);return eo(n,t,xi),kr(this)&&(eo(n,t,Si),this.id===Li&&eo(n,t,Ni,ki)),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:Ie,daysInWeek:()=>7},Ns={v:we,hn:ke,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(I(u+n*r,7));return l=(n+(o-c)*r)/7}const r=this.id?1:4,o=Ie(e),i=this.dayOfYear(e),a=I(o-1,7),s=i-1,u=I(a-s,7),c=t(u);let l,f=Math.floor((s-c)/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:ke,q:ye,G(e,t){if(!t)return[wa,e]},sn:De,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+=S(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}),Fs={v:Rr,hn:Hr,q:Pr},Ls={dayOfYear:yr,v:Rr,p:Nr,weekOfYear:br,yearOfWeek:wr,m:()=>[]},Hs=Object.assign({},Rs,Ls,{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),u=i===s;1===(E(e,Dr(i,s))||E(Number(t),Number(u))||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<=Fr.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:Lr,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+=Lr.call(this,e+o);return i},U:Fr,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+=Lr.call(this,--e);else{let n;for(;t>(n=Lr.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,Fs),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"}),eu=Object.keys(Js),tu=Object.keys(Vs),nu=Object.keys(Gs),ru=Object.keys(Ks),ou=["dateStyle"],iu=eu.concat(ou),au=tu.concat(ou),su=nu.concat(ou,["weekday"]),uu=ru.concat(["dayPeriod","timeStyle","fractionalSecondDigits"]),cu=su.concat(uu),lu=zs.concat(uu),fu=zs.concat(su),du=zs.concat(["day","weekday"],uu),hu=zs.concat(["year","weekday"],uu),mu=io(cu,Xs),pu=io(cu,Qs),gu=io(cu,Xs,zs),bu=io(su,Gs,lu),wu=io(uu,Ks,fu),yu=io(iu,Js,du),vu=io(au,Vs,hu),Eu={},Mu=new pa(void 0,{calendar:Ai}).resolvedOptions().calendar===Ai,Du=[mu,rt],Iu=[pu,rt,0,(e,t)=>{const n=e.timeZone;if(t&&t.timeZone!==n)throw new RangeError(Uo);return n}],ku=[gu,ce],Su=[bu,ce],Tu=[wu,e=>ae(e)/hi],_u=[yu,ce,Mu],xu=[vu,ce,Mu];let Ou;function ju(e,t,n,r,o){function c(...e){if(!(this instanceof c))throw new TypeError(_o);rc(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=nc(t);if(!n||n.branding!==e)throw new TypeError(_o);return n}return Object.defineProperties(c.prototype,{...s(l(f,n)),...a(l(f,r)),...u("Temporal."+e)}),Object.defineProperties(c,{...a(o),...i(e)}),[c,e=>{const t=Object.create(c.prototype);return rc(t,e),t},d]}function Cu(e){if(nc(e)||void 0!==e.calendar||void 0!==e.timeZone)throw new TypeError("Invalid bag");return e}function Ru(e){return Nu(e)||Ai}function Nu(e){const{calendar:t}=e;if(void 0!==t)return Pu(t)}function Pu(e){if(r(e)){const{calendar:t}=nc(e)||{};if(!t)throw new TypeError(Lo(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 Yu(e){const t={};for(const n in e)t[n]=e=>{const{calendar:t}=e;return Us(t)[n](e)};return t}function Au(){throw new TypeError("Cannot use valueOf")}function Fu(e){if(r(e)){const{timeZone:t}=nc(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 Lu(e){if(r(e)){const t=nc(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=Ss.exec(e);return t?(e=>{function t(e,t,i){let a=0,s=0;if(i&&([a,o]=D(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={...c(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(So(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 Hu(e){if(void 0!==e){if(r(e)){const t=nc(e)||{};switch(t.branding){case Xa:case Ja:return t;case Ga:return Xe(t)}const n=Ru(e);return{...qr(Fu,cs,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 Bu(e,t){if(r(e)){const n=nc(e)||{};switch(n.branding){case Ka:return Ce(t),n;case Ga:return Ce(t),tt(n);case Xa:return Ce(t),oo(cs,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=Ds.exec(e);return t?(Hn(t[10]),Ln(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 Uu(e){return void 0===e?void 0:Bu(e)}function Zu(e,t){if(r(e)){const n=nc(e)||{};switch(n.branding){case Ga:return Ce(t),n;case Ja:return Ce(t),Ke({...n,...sa});case Xa:return Ce(t),no(cs,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(Ru(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 Wu(e,t){if(r(e)){const n=nc(e);if(n&&n.branding===Va)return Ce(t),n;const r=Nu(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,u]=i.v(r),[c,l]=i.q(a,s),[f,d]=i.G(c,l,u);return et(re(i.V(f,d,u)),o)}(Us,e);return Ce(t),n}function $u(e,t){if(r(e)){const n=nc(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(Ru(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 qu(e,t){if(r(e)){const n=nc(e)||{};switch(n.branding){case Ja:return Ce(t),n;case Ga:return Ce(t),Xe(n);case Xa:return Ce(t),ro(cs,n)}return function(e,t,n,r=[]){const o=zr(e,t,Ri,r);return e.F(o,n)}(Us(Ru(e)),e,t)}const n=_n(e);return Ce(t),n}function zu(e,t){if(r(e)){const n=nc(e);if(n&&n.branding===Xa)return Re(t),n;const r=Ru(e);return function(e,t,n,r,o,i){const a=zr(n,o,Ri,Mi,Ii),s=e(a.timeZone),[u,c,l]=Re(i),f=n.F(a,$e(u)),d=Jr(a,u);return Ge(qt(t(s),{...f,...d},void 0!==a.offset?Tn(a.offset):void 0,c,l),s,r)}(Fu,cs,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 Vu(e){return l(e=>t=>e(Ju(t)),e)}function Ju(e){return ss(e,cs)}function Gu(e){if(r(e)){const t=nc(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 Ku(){function e(e,n){return new t(e,n)}function t(e,t=Object.create(null)){Uc.set(this,((e,t)=>{const n=new pa(e,t),r=n.resolvedOptions(),i=r.locale,a=h(Object.keys(t),r),s=o(ec),u=(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=>nc(e)||Number(e));let o,u=0;for(const e of r){const t="object"==typeof e?e.branding:void 0;if(u++&&t!==o)throw new TypeError(ri);o=t}return o?s(o)(i,a,...r):[n,...r]};return u.X=n,u})(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")&&Xu(t);"function"==typeof n.value?n.value="constructor"===t?e:o||Qu(t):o&&(n.get=function(){if(!Uc.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 Xu(e){return Object.defineProperties(function(...t){const n=Uc.get(this),[r,...o]=n(e.includes("Range"),...t);return r[e](...o)},i(e))}function Qu(e){return Object.defineProperties(function(...t){return Uc.get(this).X[e](...t)},i(e))}function ec(e){const t=bc[e];if(!t)throw new TypeError((e=>`Cannot format ${e}`)(e));return ao(t,o(so),1)}const tc=new WeakMap,nc=tc.get.bind(tc),rc=tc.set.bind(tc),oc={era:function(e){if(void 0!==e)return Zi(e)},eraYear:j,year:R,month:C,daysInMonth:C,daysInYear:C,inLeapYear:Wi,monthsInYear:C},ic={monthCode:Zi},ac={day:C},sc={dayOfWeek:C,dayOfYear:C,weekOfYear:function(e){if(void 0!==e)return C(e)},yearOfWeek:j,daysInWeek:C},uc=Yu(Object.assign({},oc,ic,ac,sc)),cc=Yu({...oc,...ic}),lc=Yu({...ic,...ac}),fc={calendarId:e=>e.calendar},dc=f(e=>t=>t[e],qi.concat("sign")),hc=f((e,t)=>e=>e[ta[t]],yi),mc={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)}},[pc,gc]=ju(es,function(e=0,t=0,n=0,r=0,o=0,i=0,a=0,s=0,u=0,f=0){return nt(wn(l(W,c(qi,[e,t,n,r,o,i,a,s,u,f]))))},{...dc,blank:function(e){return!e.sign}},{with:(e,t)=>gc(function(e,t){return nt((n=e,r=t,wn({...n,...Vr(r,zi)})));var n,r}(e,t)),negated:e=>gc(pn(e)),abs:e=>gc(function(e){return-1===e.sign?pn(e):e}(e)),add:(e,t,n)=>gc(mn(Hu,Us,cs,0,e,Lu(t),n)),subtract:(e,t,n)=>gc(mn(Hu,Us,cs,1,e,Lu(t),n)),round:(e,t)=>gc(function(e,t,n,r,o){const i=In(r),[a,s,u,c,l]=((e,t,n)=>{e=We(e,Ma);let r=Fa(e);const o=n(e[Sa]);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,u,c)));if(!dn(l)&&!r.sign)return r;if(!l)throw new RangeError(Ko);const[d,h,m]=un(t,n,l),p=cn(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(Fo);return y=gt(y,p(w),a,s,u,c,h,d,p,g),nt(y)}(Hu,Us,cs,e,t)),total:(e,t)=>function(e,t,n,r,o){const i=In(r),[a,s]=((e,t)=>{const n=t((e=We(e,Da))[Sa]);let r=La(e);return r=N(Da,r),[r,n]})(o,e),u=Math.max(a,i);if(!s&&hn(u,s))return it(r,a);if(!s)throw new RangeError(Ko);if(!r.sign)return 0;const[c,l,f]=un(t,n,s),d=cn(f),h=ln(f),m=fn(f),p=h(l,c,r);dn(s)||(oe(c),oe(p));const g=m(l,c,p,a);return hn(a,s)?it(g,a):((e,t,n,r,o,i,a)=>{const s=bn(e),[u,c]=at(r,ea(n,e),n,s,o,i,a),l=st(t,u,c);return e[qi[n]]+l*s})(g,d(p),a,l,c,d,h)}(Hu,Us,cs,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:Au},{from:e=>gc(Lu(e)),compare:(e,t,n)=>function(e,t,n,r,o,i){const a=e(Ze(i).relativeTo),s=Math.max(In(r),In(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[u,c,l]=un(t,n,a),f=cn(l),d=ln(l);return G(f(d(c,u,r)),f(d(c,u,o)))}(Hu,Us,cs,Lu(e),Lu(t),n)}),bc={Instant:Du,PlainDateTime:ku,PlainDate:Su,PlainTime:Tu,PlainYearMonth:_u,PlainMonthDay:xu},wc=ao(Du),yc=ao(Iu),vc=ao(ku),Ec=ao(Su),Mc=ao(Tu),Dc=ao(_u),Ic=ao(xu),[kc,Sc]=ju(Ka,function(e=0,t=0,n=0,r=0,o=0,i=0){return tt(je(l(Z,c(ta,[e,t,n,r,o,i])),1))},hc,{with(e,t,n){return Sc(function(e,t,n){return tt(((e,t,n)=>Jr({...h(vi,e),...Vr(t,vi)},Ce(n)))(e,t,n))}(this,Cu(t),n))},add:(e,t)=>Sc(en(0,e,Lu(t))),subtract:(e,t)=>Sc(en(1,e,Lu(t))),until:(e,t,n)=>gc(ar(0,e,Bu(t),n)),since:(e,t,n)=>gc(ar(1,e,Bu(t),n)),round:(e,t)=>Sc(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,Bu(t)),toLocaleString(e,t,n){const[r,o]=Mc(t,n,e);return r.format(o)},toString:Ot,toJSON:e=>Ot(e),valueOf:Au},{from:(e,t)=>Sc(Bu(e,t)),compare:(e,t)=>Xn(Bu(e),Bu(t))}),[Tc,_c]=ju(Ga,b(function(e,t,n,r,o=0,i=0,a=0,s=0,u=0,f=0,d=Ai){return Ke(oe(Te(l(Z,c(ra,[t,n,r,o,i,a,s,u,f])))),e(d))},Ur),{...fc,...uc,...hc},{with:(e,t,n)=>_c(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 u=Vr(n,i),c=Ce(r),l=o.k(a,u),f={...a,...u};return Ke(oe({...o.F(l,$e(c)),...je(Ws(f),c)}))}(Us,e,Cu(t),n)),withCalendar:(e,t)=>_c(co(e,Pu(t))),withPlainTime:(e,t)=>_c(function(e,t=sa){return Ke(oe({...e,...t}))}(e,Uu(t))),add:(e,t,n)=>_c(Kt(Us,0,e,Lu(t),n)),subtract:(e,t,n)=>_c(Kt(Us,1,e,Lu(t),n)),until:(e,t,n)=>gc(nr(Us,0,e,Zu(t),n)),since:(e,t,n)=>gc(nr(Us,1,e,Zu(t),n)),round:(e,t)=>_c(function(e,t){return Ke(ut(e,...Pe(t)),e.calendar)}(e,t)),equals:(e,t)=>function(e,t){return!Gn(e,t)&&e.calendar===t.calendar}(e,Zu(t)),toZonedDateTime:(e,t,n)=>Yc(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)}(cs,e,Fu(t),n)),toPlainDate:e=>Nc(Xe(e)),toPlainTime:e=>Sc(tt(e)),toLocaleString(e,t,n){const[r,o]=vc(t,n,e);return r.format(o)},toString:St,toJSON:e=>St(e),valueOf:Au},{from:(e,t)=>_c(Zu(e,t)),compare:(e,t)=>Gn(Zu(e),Zu(t))}),[xc,Oc]=ju(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),{...fc,...lc},{with:(e,t,n)=>Oc(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),u=o.k(a,s);return o._(u,r)}(Us,e,Cu(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,Wu(t)),toPlainDate(e,t){return Nc(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]=Ic(t,n,e);return r.format(o)},toString:xt,toJSON:e=>xt(e),valueOf:Au},{from:(e,t)=>Oc(Wu(e,t))}),[jc,Cc]=ju(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),{...fc,...cc},{with:(e,t,n)=>Cc(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),u=o.k(a,s);return o.K(u,r)}(Us,e,Cu(t),n)),add:(e,t,n)=>Cc(Qt(Us,0,e,Lu(t),n)),subtract:(e,t,n)=>Cc(Qt(Us,1,e,Lu(t),n)),until:(e,t,n)=>gc(or(Us,0,e,$u(t),n)),since:(e,t,n)=>gc(or(Us,1,e,$u(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,$u(t)),toPlainDate(e,t){return Nc(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]=Dc(t,n,e);return r.format(o)},toString:_t,toJSON:e=>_t(e),valueOf:Au},{from:(e,t)=>Cc($u(e,t)),compare:(e,t)=>Kn($u(e),$u(t))}),[Rc,Nc]=ju(Ja,b(function(e,t,n,r,o=Ai){return Xe(re(_e(l(Z,{isoYear:t,isoMonth:n,isoDay:r}))),e(o))},Ur),{...fc,...uc},{with:(e,t,n)=>Nc(function(e,t,n,r){const o=e(t.calendar),i=o.fields(Ri).sort(),a=to(t),s=Vr(n,i),u=o.k(a,s);return o.F(u,r)}(Us,e,Cu(t),n)),withCalendar:(e,t)=>Nc(co(e,Pu(t))),add:(e,t,n)=>Nc(Xt(Us,0,e,Lu(t),n)),subtract:(e,t,n)=>Nc(Xt(Us,1,e,Lu(t),n)),until:(e,t,n)=>gc(rr(Us,0,e,qu(t),n)),since:(e,t,n)=>gc(rr(Us,1,e,qu(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,qu(t)),toZonedDateTime(e,t){const n=r(t)?t:{timeZone:t};return Yc(function(e,t,n,r,o){const i=e(o.timeZone),a=o.plainTime,s=void 0!==a?t(a):void 0,u=n(i);let c;return c=s?zt(u,{...r,...s}):Vt(u,{...r,...sa}),Ge(c,i,r.calendar)}(Fu,Bu,cs,e,n))},toPlainDateTime:(e,t)=>_c(function(e,t=sa){return Ke(oe({...e,...t}))}(e,Uu(t))),toPlainYearMonth(e){return Cc(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 Oc(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]=Ec(t,n,e);return r.format(o)},toString:Tt,toJSON:e=>Tt(e),valueOf:Au},{from:(e,t)=>Nc(qu(e,t)),compare:(e,t)=>Kn(qu(e),qu(t))}),[Pc,Yc]=ju(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))}),{...mc,...fc,...Vu(uc),...Vu(hc),offset:e=>Lt(Ju(e).offsetNanoseconds),offsetNanoseconds:e=>Ju(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(Fo);return a}(cs,e)},{with:(e,t,n)=>Yc(function(e,t,n,r,o){const{calendar:i,timeZone:a}=n,s=e(i),u=t(a),c=[...s.fields(Ri),...Di].sort(),l=(e=>{const t=ss(e,cs),n=Lt(t.offsetNanoseconds),r=Bs(e.calendar),[o,i,a]=r.v(t),[s,u]=r.q(o,i),c=Er(s,u);return{...$s(t),year:o,monthCode:c,day:a,offset:n}})(n),f=Vr(r,c),d=s.k(l,f),h={...l,...f},[m,p,g]=Re(o,2);return Ge(qt(u,{...s.F(d,$e(m)),...je(Ws(h),m)},Tn(h.offset),p,g),a,i)}(Us,cs,e,Cu(t),n)),withCalendar:(e,t)=>Yc(co(e,Pu(t))),withTimeZone:(e,t)=>Yc(function(e,t){return{...e,timeZone:t}}(e,Fu(t))),withPlainTime:(e,t)=>Yc(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)}(cs,e,Uu(t))),add:(e,t,n)=>Yc(Gt(Us,cs,0,e,Lu(t),n)),subtract:(e,t,n)=>Yc(Gt(Us,cs,1,e,Lu(t),n)),until:(e,t,n)=>gc(nt(tr(Us,cs,0,e,zu(t),n))),since:(e,t,n)=>gc(nt(tr(Us,cs,1,e,zu(t),n))),round:(e,t)=>Yc(function(e,t,n){let{epochNanoseconds:r,timeZone:o,calendar:i}=t;const[a,s,u]=Pe(n);if(0===a&&1===s)return t;const c=e(o);if(6===a)r=((e,t,n,r)=>{const o=ss(n,t),[i,a]=e(o),s=n.epochNanoseconds,u=Vt(t,i),c=Vt(t,a);if(K(s,u,c))throw new RangeError(Fo);return vt(st(s,u,c),r)?c:u})(ht,c,t,u);else{const e=c.R(r);r=qt(c,ut(pe(r,e),a,s,u),e,2,0,1)}return Ge(r,o,i)}(cs,e,t)),startOfDay:e=>Yc(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)}(cs,e)),equals:(e,t)=>function(e,t){return!Jn(e,t)&&!!Qn(e.timeZone,t.timeZone)&&e.calendar===t.calendar}(e,zu(t)),toInstant:e=>Fc(function(e){return Je(e.epochNanoseconds)}(e)),toPlainDateTime:e=>_c(no(cs,e)),toPlainDate:e=>Nc(ro(cs,e)),toPlainTime:e=>Sc(oo(cs,e)),toLocaleString(e,t,n={}){const[r,o]=yc(t,n,e);return r.format(o)},toString:(e,t)=>kt(cs,e,t),toJSON:e=>kt(cs,e),valueOf:Au,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=cs(n).O(r,o);return i?Yc({...e,epochNanoseconds:i}):null}},{from:(e,t)=>Yc(zu(e,t)),compare:(e,t)=>Jn(zu(e),zu(t))}),[Ac,Fc]=ju(Qa,function(e){return Je(ie(X(B(e))))},mc,{add:(e,t)=>Fc(Jt(0,e,Lu(t))),subtract:(e,t)=>Fc(Jt(1,e,Lu(t))),until:(e,t,n)=>gc(er(0,e,Gu(t),n)),since:(e,t,n)=>gc(er(1,e,Gu(t),n)),round:(e,t)=>Fc(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,Gu(t)),toZonedDateTimeISO:(e,t)=>Yc(function(e,t,n=Ai){return Ge(e.epochNanoseconds,t,n)}(e,Fu(t))),toLocaleString(e,t,n){const[r,o]=wc(t,n,e);return r.format(o)},toString:(e,t)=>It(Fu,cs,e,t),toJSON:e=>It(Fu,cs,e),valueOf:Au},{from:e=>Fc(Gu(e)),fromEpochMilliseconds:e=>Fc(function(e){return Je(ie(Q(W(e),hi)))}(e)),fromEpochNanoseconds:e=>Fc(function(e){return Je(ie(X(B(e))))}(e)),compare:(e,t)=>Vn(Gu(e),Gu(t))}),Lc=Object.defineProperties({},{...u("Temporal.Now"),...a({timeZoneId:()=>ho(),instant:()=>Fc(Je(fo())),zonedDateTimeISO:(e=ho())=>Yc(Ge(fo(),Fu(e),Ai)),plainDateTimeISO:(e=ho())=>_c(Ke(lo(cs(Fu(e))),Ai)),plainDateISO:(e=ho())=>Nc(Xe(lo(cs(Fu(e))),Ai)),plainTimeISO:(e=ho())=>Sc(tt(lo(cs(Fu(e)))))})}),Hc=Object.defineProperties({},{...u("Temporal"),...a({PlainYearMonth:jc,PlainMonthDay:xc,PlainDate:Rc,PlainTime:kc,PlainDateTime:Tc,ZonedDateTime:Pc,Instant:Ac,Duration:pc,Now:Lc})}),Bc=Ku(),Uc=new WeakMap;function Zc(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:Bc});var Wc={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}},$c={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},qc=function(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}u((r=r.apply(e,t||[])).next())})};class zc extends Error{constructor(e){super(e||"Request canceled"),this.name="Cancel",this.__BBN_CANCEL__=!0}}const Vc=["POST","PUT","PATCH","DELETE"],Jc=(e,t,n={},r)=>{const o=new XMLHttpRequest,i=Vc.includes(e.toUpperCase()),a=new Promise((r,a)=>{o.open(e,t,!0);const{body:s,headers:u}=((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);u.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 u={data:s,status:t,statusText:i,headers:e,config:n,request:o};if(t>=200&&t<300)r(u);else{const e=new Error("Request failed with status code "+t);e.response=u,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 zc("Request canceled"))},i?o.send(s):o.send()});return a.cancel=()=>o.abort(),a};var Gc={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&&Vc.includes(e.toUpperCase())?Jc(e,t,n):((e,t,n={},r)=>{const o={method:e,headers:new Headers(n.headers||{}),signal:null==r?void 0:r.signal},i=Vc.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=>qc(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 zc("Request canceled");throw e});return a.cancel=()=>r.abort(),a})(e,t,n,r)}};function Kc(...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 Xc(...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 Qc(...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(!Qc(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(!(Kc(e)&&e>0)){if(Xc(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 ul(...e){if(!e.length)return!1;for(let t of e)if(!Array.isArray(t))return!1;return!0}function cl(...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?ul(e)?(o[n]=ul(o[n])?o[n]:[],al(e,(e,t)=>{if(e&&"object"==typeof e){let r=o[n][t];ul(e)?ul(r)||(r=[]):sl(r)||(r={}),o[n][t]=cl(!0,r,e)}else o[n][t]=e})):sl(e)?o[n]=cl(!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[u,c]=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=cl({},a?{[f]:r[e][f]}:r[e],t);if(!n[f])throw new Error(Zc("No primary key in the data"));const i=c.put(n);o(i,s),i.onsuccess=()=>{d++}}u.oncomplete=()=>{s(d)}})}),this.delete=(e,t)=>new Promise(r=>{const[a,s]=i(e,"w"),u=n[e],c=u.keys.PRIMARY.columns.length>1?u.keys.PRIMARY.columns:u.keys.PRIMARY.columns[0];if(!t[c])throw new Error(Zc("No "));const l=s.delete(t[c]);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,u=null)=>new Promise(a=>{const[c,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||ul(r)?null:d,m=[];if(h===d)if(bbn.fn.isArray(null==r?void 0:r[d])){const e=Math.min(r[d].length,u||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===u&&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,u=0,c=null)=>new Promise(l=>{if(t.objectStoreNames.contains(r)||hl.add(e,r,n[o]),!t.objectStoreNames.contains(r))throw l(0),new Error(Zc("The target table %s does not exist",r));this.selectAll(o,i,a,s,u,c).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(Zc("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(Zc("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(!Qc(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&&Qc(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||(ul(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 Dl(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 Il(e){return Ml(e).padStart(8,"0")+Dl(e).padStart(8,"0")}function kl(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof HTMLElement))return!1;return!0}function Sl(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)||kl(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=kl(e)?Tl(e)?"__BBN_CP__"+e.$cid:e.bbnId?"__BBN_DOM__"+e.tagName+"/"+e.bbnId+e.bbnHash:"__BBN_DOM__"+Sl(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 Il(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 u(e,t,n,r,i,a,s){return o(n^(t|~r),e,t,i,a,s)}var c,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(c=0;c<m.length;c+=16)l=p,f=g,d=b,h=w,p=i(p,g,b,w,m[c+0],7,-680876936),w=i(w,p,g,b,m[c+1],12,-389564586),b=i(b,w,p,g,m[c+2],17,606105819),g=i(g,b,w,p,m[c+3],22,-1044525330),p=i(p,g,b,w,m[c+4],7,-176418897),w=i(w,p,g,b,m[c+5],12,1200080426),b=i(b,w,p,g,m[c+6],17,-1473231341),g=i(g,b,w,p,m[c+7],22,-45705983),p=i(p,g,b,w,m[c+8],7,1770035416),w=i(w,p,g,b,m[c+9],12,-1958414417),b=i(b,w,p,g,m[c+10],17,-42063),g=i(g,b,w,p,m[c+11],22,-1990404162),p=i(p,g,b,w,m[c+12],7,1804603682),w=i(w,p,g,b,m[c+13],12,-40341101),b=i(b,w,p,g,m[c+14],17,-1502002290),p=a(p,g=i(g,b,w,p,m[c+15],22,1236535329),b,w,m[c+1],5,-165796510),w=a(w,p,g,b,m[c+6],9,-1069501632),b=a(b,w,p,g,m[c+11],14,643717713),g=a(g,b,w,p,m[c+0],20,-373897302),p=a(p,g,b,w,m[c+5],5,-701558691),w=a(w,p,g,b,m[c+10],9,38016083),b=a(b,w,p,g,m[c+15],14,-660478335),g=a(g,b,w,p,m[c+4],20,-405537848),p=a(p,g,b,w,m[c+9],5,568446438),w=a(w,p,g,b,m[c+14],9,-1019803690),b=a(b,w,p,g,m[c+3],14,-187363961),g=a(g,b,w,p,m[c+8],20,1163531501),p=a(p,g,b,w,m[c+13],5,-1444681467),w=a(w,p,g,b,m[c+2],9,-51403784),b=a(b,w,p,g,m[c+7],14,1735328473),p=s(p,g=a(g,b,w,p,m[c+12],20,-1926607734),b,w,m[c+5],4,-378558),w=s(w,p,g,b,m[c+8],11,-2022574463),b=s(b,w,p,g,m[c+11],16,1839030562),g=s(g,b,w,p,m[c+14],23,-35309556),p=s(p,g,b,w,m[c+1],4,-1530992060),w=s(w,p,g,b,m[c+4],11,1272893353),b=s(b,w,p,g,m[c+7],16,-155497632),g=s(g,b,w,p,m[c+10],23,-1094730640),p=s(p,g,b,w,m[c+13],4,681279174),w=s(w,p,g,b,m[c+0],11,-358537222),b=s(b,w,p,g,m[c+3],16,-722521979),g=s(g,b,w,p,m[c+6],23,76029189),p=s(p,g,b,w,m[c+9],4,-640364487),w=s(w,p,g,b,m[c+12],11,-421815835),b=s(b,w,p,g,m[c+15],16,530742520),p=u(p,g=s(g,b,w,p,m[c+2],23,-995338651),b,w,m[c+0],6,-198630844),w=u(w,p,g,b,m[c+7],10,1126891415),b=u(b,w,p,g,m[c+14],15,-1416354905),g=u(g,b,w,p,m[c+5],21,-57434055),p=u(p,g,b,w,m[c+12],6,1700485571),w=u(w,p,g,b,m[c+3],10,-1894986606),b=u(b,w,p,g,m[c+10],15,-1051523),g=u(g,b,w,p,m[c+1],21,-2054922799),p=u(p,g,b,w,m[c+8],6,1873313359),w=u(w,p,g,b,m[c+15],10,-30611744),b=u(b,w,p,g,m[c+6],15,-1560198380),g=u(g,b,w,p,m[c+13],21,1309151649),p=u(p,g,b,w,m[c+4],6,-145523070),w=u(w,p,g,b,m[c+11],10,-1120210379),b=u(b,w,p,g,m[c+2],15,718787259),g=u(g,b,w,p,m[c+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="",u=0,c=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(u++,""!==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])u===c+1&&(p?(f.default=r.trim(),p=!1):r&&(f.name=r.trim()),(f.name||f.default)&&(l.push(f),f={}),r=""),c++;else if(w&&"}"!==t[e])r+=t[e];else{if(u&&u===c&&":"===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]||u!==c||c||o)){f.name=t.slice(0,e).trim(),l.push(f),f={},o=!0,n=bbn.fn.substr(t,e+2).trim();break}if(u===c&&"="===t[e]&&">"===t[e+1]){""!==r.trim()&&(f.name=r.trim(),l.push(f),f={},r=""),o=!0,e++;continue}if("="===t[e]&&u>c&&!p)f.name=r.trim(),r="",p=!0;else if(","===t[e])if(w)r+=t[e];else{if(!(u>c))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(u===c){n=t.substring(e).trim();break}u>c?"{"!==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),u>c?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||!ul(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&&ul(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||!ul(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(!Xc(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,u=!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)u=!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 ul(t)&&(a={conditions:t,logic:"AND"});else u=!0,s=e=>Nl({value:e},Pl({logic:"AND",conditions:[{field:"value",operator:r||"=",value:n}]}));if(u||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 Fl(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 Ll(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(!ul(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 u;u="function"==typeof t?t:(e,t)=>Nl(e,i);for(let t=0;t<e.length&&(bbn.env._enumerated.push(!0),!(u(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=Ll(a);if(null==s?void 0:s.loader)return s.loader;bbn.env.token&&cl(n||{},{_bbn_token:bbn.env.token});const u=new AbortController;let c={responseType:t,signal:u.signal};"text"===t?c.headers={accept:"text/javascript","Content-Type":"text/javascript"}:"json"===t?c.headers={accept:"application/json","Content-Type":"application/json"}:"html"===t&&(c.headers={accept:"text/html","Content-Type":"text/html"});let l="get";sl(n)&&yl(n)>0&&(c.data=n,l="post");let f=Gc.run(l,e,c).then(t=>{if(Fl(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=Gc.isCancel(t);if(Fl(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,u);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&&Qc(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 uf=[{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]})}],cf=[["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(cf,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(cf,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(cf,t=>t[1]===e);if(!t)throw new Error("Unit name not found: "+e);return t},nf=function(e,t){const n=cf.findIndex(([,t])=>t===e);if(-1===n)throw new Error("Unit not found: "+e);const r=cf[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]=cf[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||cl(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),u=[],c=[];for(let e=0;e<7;e++){const t=new Date(s.getTime()+864e5*e);u.push(r.format(t)),c.push(o.format(t))}return{monthsLong:i,monthsShort:a,weekdaysLong:u,weekdaysShort:c}})());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},u={year:1970,month:1,day:1,hour:0,minute:0,second:0,ms:0},c=e=>e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),l=[{token:"YYYY",regex:"\\d{4}",apply:e=>{u.year=parseInt(e,10)}},{token:"YY",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);u.year=t>=70?1900+t:2e3+t}},{token:"Y",regex:"[+-]?\\d{1,6}",apply:e=>{u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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+=c(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(u.year,u.month-1,u.day,u.hour,u.minute,u.second,u.ms);if(g.getFullYear()!==u.year||g.getMonth()!==u.month-1||g.getDate()!==u.day||g.getHours()!==u.hour||g.getMinutes()!==u.minute||g.getSeconds()!==u.second||g.getMilliseconds()!==u.ms)throw new Error("Invalid date produced from components");return void 0!==u.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(cf,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||Kc(e)&&""!==e)&&(e<5e3&&Kc(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 uf){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(cf,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?Zc("%d %s before",r,t):r<0?Zc("%d %s after",-r,t):Zc("The same %s",t)}guessUnit(e){const t=Math.abs(e);for(const[e,n,r]of cf)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(cf,e=>e[0]===i);if(!a)throw new Error("Invalid unit for diff: "+t);const[s,u,c]=a;return Math.round(o/c)}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]),ul(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;ul(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(Qc(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(ul(e))return e.slice().map(e=>"object"==typeof e?Mf(e):e);if(sl(e)){return cl(!0,Object.create(Object.getPrototypeOf(e)),e)}return e}rf=new WeakMap,of=new WeakMap;const Df=(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 If(e,t,n=null,r="="){if(!ul(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 kf=[];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;kf.push(t)}function Sf(...e){const t=Object.create(null);return e.length&&cl(t,...e),t}function Tf(e){let t=typeof e;if(void 0===e)return new Date;if("number"===t||Kc(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(Qc(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&&Qc(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(Qc(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 Ff=function(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}u((r=r.apply(e,t||[])).next())})};function Lf(){return Ff(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{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}u((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 Qc(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&&cl(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(Ll(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?(cl(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")||Kc(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 ud(...e){if(!e.length)return!1;for(let t of e)if(!Qc(t)||!bbn.var.regexp.ip.test(t))return!1;return!0}function cd(...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||ul(n)&&!n.includes(t))&&(e instanceof File?r.append(t,e):ul(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&&Qc(n)||(n="..."),e.length>t&&(e=rl(e,0,t)+n)),e}var bd,wd={_addLoader:ml,_compareValues:wl,_deleteLoader:Fl,abort:function(e){let t=Ll(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&&Xc(e[0])&&(e=e[0]),Zl("height",e)},adjustSize:Zl,adjustWidth:function(){let e=arguments;return 1===e.length&&Xc(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]={}),cl(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&&Qc(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=kl(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||Df(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||Df(e,r.type.toString()),n(!0)})}):(navigator.clipboard.writeText(e),t||Df(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||Df(e),n(!0)}n(!1)})},correctCase:vf,count:function(e,t,n=null,r="="){return If(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^kf[255&(t^r)]}return(-1^t)>>>0},createObject:Sf,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=!ul(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]&&(ul(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(ul(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=Sf();if(!tl(t)&&!tl(n)){if(jf(t)||jf(n)){let e=(s=t)===(u=n)||bl(s)&&bl(u)&&s.getTime()===u.getTime()?i:void 0===s?"created":void 0===u?"deleted":"updated";if(r||e!==i){let r=Sf();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(kl(t)||kl(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,u;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 Qc(e)?e.replace(/"/g,'\\"'):e},escapeRegExp:Wl,escapeSquotes:function(e){return Qc(e)?e.replace(/'/g,"\\'"):e},escapeTicks:function(e){return Qc(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&&Qc(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 Lf();let r=t(e[n],n);if(r instanceof Promise&&(r=yield r),!1===r)return!1}return!0})},extend:cl,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&&Qc(t)?t:""},fdatetime:function(e,t=!1){let n=gf(e);return n.isValid?n.fdate(!1,!0):t&&Qc(t)?t:""},fieldValue:Bf,fileExt:Pf,filter:If,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=>{ul(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(ul(e)){let o=e.length-1;Kc(n)&&0<n&&n<=o||(n=o),(!Kc(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(ul(e)){let o=e.length-1;Kc(n)&&0<n&&n<=o||(n=o),(!Kc(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 Kc(e)?e+"px":Qc(e)?e:!t&&"auto"},formdata:Uf,fphone:function(e){var t;if(Kc(e)&&(e=e.toString()),Qc(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&&Qc(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 u=i.kind,c=i.type;if("file"===u){let u=t.files[s];if(!c&&u.name){let e=u.name.split(".");c=e[e.length-1]}let l=u?u.name:bbn._("untitled"),f=u?u.size:null,d=u?u.lastModified:null,h=i.getAsFile();h?(a=!0,n--,r.files.push({type:c,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:c,data:t}),"text/plain"===c&&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 u;return n&&["object","function"].includes(typeof n)&&6 in arguments&&(s=a),t?(u=Al(e,n,r,o,i,a,void 0),void 0===u?s:u[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:Ll,getPath:Sl,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])),u=Array(t.length).fill(-1);for(let e=t.length-2;e>=0;e--)u[e]=u[e+1],s.has(t[e+1])&&(u[e]=e+1);const c=e.slice(),l=new Map(c.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=u[e],i=-1!==o?l.get(t[o]):c.length;if(void 0===i)throw new Error("Inconsistent state");const a=r<i?i-1:i;if(r!==a){const[e]=c.splice(r,1);c.splice(a,0,e),f.push({from:r,to:a,value:n}),l.clear();for(let e=0;e<c.length;e++)l.set(c[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&&cl(!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,cl({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:ul,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(!Qc(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:kl,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(!Qc(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(!Qc(t))return!1;if(!ud(t)&&!bbn.var.regexp.hostname.test(t))return!1}return!0},isInside:function(e,t){let n=Wf(e);if(n.length){if(Qc(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:ud,isIterable:Xc,isMobile:id,isMobileDevice:rd,isNotObject:jf,isNull:El,isNumber:Kc,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:Qc,isSymbol:cd,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(!Qc(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:Sf(),writable:!0,configurable:!0,enumerable:!1});return new Proxy(t,{get(s,u){const c=Reflect.get(s,u),l=s.__bbnRoot||s;if(cd(u))return Reflect.get(l,u);const f=o?o+"."+u:u,d=a+(Kc(u)?u.toString():u);if(["fill","pop","push","reverse","shift","sort","splice","unshift"].includes(u)&&ul(s))return function(...e){let t=l[u](...e);return ld("DOING ARRAY STUFF"),nl(s.__bbnParent),n(s,"length",r),t};if(tl(c))return c;if("__bbnRoot"===u){let e=t;for(;e&&(null==e?void 0:e.__bbnTarget);)e=e.__bbnTarget;return e}return"__bbnIsProxy"===u||("__bbnTarget"===u?s:"__bbnParent"===u?r:"__bbnWatchers"===u?s.__bbnWatchers:0===u.indexOf("__bbn_")?Reflect.get(s,u):"length"===u&&ul(s.__bbnRoot||s)?l.length:u in s&&c&&"object"==typeof c&&[void 0,Object,Array].includes(c.constructor)?(c.__bbnIsProxy&&c.__bbnParent===r||(d in l||Reflect.defineProperty(l,d,{value:e(c,n,r,f),writable:!0,configurable:!0,enumerable:!1}),l[d].__bbnIsProxy&&!l.__bbnWatchers[i]&&(l.__bbnWatchers[i]=f)),l[d]):c)},set(t,s,u){if(cd(s))return Reflect.get(t,s,u);const c=t.__bbnRoot||t,l=o?o+"."+s:s;if(cd(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,u]),!Cl(c[s],u)){if(0===s.indexOf("__bbn_"))Reflect.defineProperty(c,s,{value:e(u,n,r,l),writable:!0,configurable:!0,enumerable:!1});else if(u&&"object"==typeof u&&[void 0,Object,Array].includes(u.constructor)){const t=a+(Kc(s)?s.toString():s);Reflect.defineProperty(c,t,{value:e(u,n,r,l),writable:!0,configurable:!0,enumerable:!1}),c[t].__bbnIsProxy&&!c.__bbnWatchers[i]&&(c.__bbnWatchers[i]=l)}r&&r.$options&&"bbn-loadbar"===r.$options.name&&nl(["Setting proxy prop in "+r.$options.name+" "+(Kc(s)?s.toString():s),u,t]),Reflect.set(c,s,u),n(t,s,r)}return!0},defineProperty(t,i,s){const u=t,c=o?o+"."+i:i;if("__bbnWatchers"===i||cd(i)||0===i.indexOf("__bbn_"))Reflect.defineProperty(u,i,s);else{const t=a+(Kc(i)?i.toString():i);Reflect.defineProperty(u,t,{value:e(s.value,n,r,c),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+(Kc(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]&&ul(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),Kc(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),u=0,c=1e4;return s&&(c=s.indexOf("."),c<=0?c=1e4:u=s.length-c),s.replace(/./g,function(e,t,n){return"."===e?o:t&&(n.length-t-u)%3==0&&t<c?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(!ul(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=Sf(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("'","'",e)),t&&0!==t.toLowerCase().indexOf("d")||(e=$l('"',""",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(ul(e))for(let n=0;n<e.length;n++){let r=!1;e[n]&&(ul(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)=>{Qc(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:Il,simpleHash1:Ml,simpleHash2:Dl,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=Ll(a);if(null==s?void 0:s.loader)return s.loader;n||(n={}),bbn.env.token&&(n._bbn_token=bbn.env.token);const u=new AbortController;let c="";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:u.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:u}){if(s)return Fl(a,n),c&&l(c),void(i&&i());if(o)if(c+=Jl(u).trim(),bbn.fn.log(["STREAM RESULT",c.length,c]),c)try{l(c),c=""}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(Fl(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,u),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(If(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=ul(e)?e.length:Object.values(e).length,u=0;al(e,e=>{o+="string"==typeof e?r+$l(r,"\\"+r,e)+r:0===e?"0":e&&e.toString?e.toString():r+r,u++,u<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(ul(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=()=>Gc.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:Lf},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 extends bbnDt{constructor(e,t,n,r,o,i,a){if(super(),bd.set(this,void 0),this.kind="datetime",e)if(void 0===t)if(e instanceof Hc.PlainDateTime)yd(this,bd,e,"f");else if(e instanceof Date)yd(this,bd,new Hc.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 Hc.PlainDateTime(t.getFullYear(),t.getMonth()+1,t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()),"f")}}else yd(this,bd,new Hc.PlainDateTime(e,t,n||1,r||0,o||0,i||0,a||0),"f");else yd(this,bd,Hc.PlainDateTime.from(Hc.Now.plainDateISO()),"f")}get value(){return vd(this,bd,"f")}fdate(e=!1,t=!1,n=!1){if(!this.value)return"";const r=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),this.second()),o=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],o).format(r)}ftime(e=!1){if(!this.value)return"";const t=new Date(2e3,1,1,this.hour(),this.minute(),this.second()),n={hour:"2-digit",minute:"2-digit"};e&&(n.second="2-digit");return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],n).format(t)}}function Md(e,t,n){let r="";const o=e.some(e=>"dayPeriod"===e.type),i=o||"h12"===t||"h11"===t,a=!!n.weekday,s="short"===n.month||"long"===n.month,u="numeric"===n.year&&"numeric"===n.month&&"numeric"===n.day&&!a&&!s;for(const t of e)switch(t.type){case"year":"2-digit"===n.year?r+="YY":r+="YYYY";break;case"month":if("short"===n.month){r+="MMM";break}if("long"===n.month){r+="MMMM";break}if(u){r+="M";break}/^\d+$/.test(t.value)?r+=2===t.value.length?"MM":"M":r+=t.value.length>3?"MMMM":"MMM";break;case"day":if(u){r+="D";break}r+=2===t.value.length?"DD":"D";break;case"weekday":"short"===n.weekday||"narrow"===n.weekday?r+="ddd":"long"===n.weekday?r+="dddd":r+=t.value.length>3?"dddd":"ddd";break;case"hour":r+=i?2===t.value.length?"hh":"h":2===t.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(!t.value)break;if(/[A-Za-zÀ-ÖØ-öø-ÿ]/.test(t.value)){r+=`[${t.value.replace(/]/g,"\\]")}]`}else r+=t.value;break;default:r+=t.value}return r}bd=new WeakMap;const Dd=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,u=[{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"}],c=[];for(const r of u){const o=new Intl.DateTimeFormat(e,r),a=Md(o.formatToParts(t),o.resolvedOptions().hourCycle,r);i.has(a)||(i.add(a),n.push({pattern:a,sample:o.format(t),options:r})),r.year&&r.month&&r.day&&c.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=Md(o.formatToParts(t),o.resolvedOptions().hourCycle,n);a.has(i)||(a.add(i),r.push({pattern:i,sample:o.format(t),options:n}))}for(const n of c)for(const r of l){const i=Object.assign(Object.assign({},n),r),a=new Intl.DateTimeFormat(e,i),u=Md(a.formatToParts(t),a.resolvedOptions().hourCycle,i);s.has(u)||(s.add(u),o.push({pattern:u,sample:a.format(t),options:i}))}return{date:n,time:r,datetime:o}},Id=()=>{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),u=[],c=[];for(let e=0;e<7;e++){const t=new Date(s.getTime()+864e5*e);u.push(r.format(t)),c.push(o.format(t))}const{date:l,time:f,datetime:d}=Dd(e);cl(bbn.dt.locales,{monthsLong:i,monthsShort:a,weekdaysLong:u,weekdaysShort:c,date:l,time:f,datetime:d})};function kd(e,t=!1,n=Hc.Now.timeZoneId()){const r=Hc.Instant.fromEpochMilliseconds(e.getTime()).toZonedDateTimeISO(n);return t?r:r.toPlainDateTime()}var Sd,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 extends bbnDt{constructor(e,t,n,r,o,i,a,s){if(super(),Sd.set(this,void 0),this.kind="zoned",e)if(void 0===t)if(e instanceof Hc.ZonedDateTime)Td(this,Sd,e,"f");else if(e instanceof Date)Td(this,Sd,kd(e,!0),"f");else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtZoned");{const t=new Date(e);Td(this,Sd,kd(t,!0),"f")}}else{const u=new Hc.PlainDateTime(t,n,r||1,o||0,i||0,a||0,s||0);Td(this,Sd,u.toZonedDateTime(e||Hc.Now.timeZoneId()),"f")}else{const e=new Date;Td(this,Sd,new Hc.ZonedDateTime(BigInt(1e6*e.getTime()),Intl.DateTimeFormat().resolvedOptions().timeZone),"f")}}get value(){return _d(this,Sd,"f")}fdate(e=!1,t=!1,n=!1){if(!this.value)return"";const r=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),this.second()),o=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],o).format(r)}ftime(e=!1){if(!this.value)return"";const t=new Date(2e3,1,1,this.hour(),this.minute(),this.second()),n={hour:"2-digit",minute:"2-digit"};e&&(n.second="2-digit");return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],n).format(t)}}Sd=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 extends bbnDt{constructor(e,t,n){if(super(),Od.set(this,void 0),this.kind="date",e){if(void 0===t)if(e instanceof Hc.PlainDate)jd(this,Od,e,"f");else if(e instanceof Date)jd(this,Od,new Hc.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 Hc.PlainDate(t.getFullYear(),t.getMonth()+1,t.getDate()),"f")}}}else jd(this,Od,Hc.PlainDate.from(Hc.Now.plainDateISO()),"f")}compareSameKind(e){const t=Hc.PlainDate.compare(Cd(this,Od,"f"),e.value);return t<0?-1:t>0?1:0}get value(){return Cd(this,Od,"f")}fdate(e=!1,t=!1){const n=new Date(this.year(),this.month()-1,this.day()),r=Object.assign({year:"numeric",month:e?"long":"numeric",day:"numeric"},t?{weekday:e?"long":"short"}:{});return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],r).format(n)}}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 extends bbnDt{constructor(e,t,n,r){if(super(),Nd.set(this,void 0),this.kind="time",e){if(void 0===e)if(e instanceof Hc.PlainTime)Pd(this,Nd,e,"f");else if(e instanceof Date)Pd(this,Nd,new Hc.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 Hc.PlainTime(e,t,n||0,r||0),"f");else{const t=new Date(e);Pd(this,Nd,new Hc.PlainTime(t.getHours(),t.getMinutes(),t.getSeconds(),1e6*t.getMilliseconds()),"f")}}}else{const e=new Date;Pd(this,Nd,new Hc.PlainTime(e.getHours(),e.getMinutes(),e.getSeconds(),1e6*e.getMilliseconds()),"f")}}get value(){return Yd(this,Nd,"f")}ftime(e=!1){if(!this.value)return"";const t=new Date(2e3,1,1,this.hour(),this.minute(),this.second()),n={hour:"2-digit",minute:"2-digit"};e&&(n.second="2-digit");return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],n).format(t)}}Nd=new WeakMap;var Fd,Ld=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 extends bbnDt{constructor(e,t){if(super(),Fd.set(this,void 0),this.kind="year-month",e){if(void 0===t)if(e instanceof Hc.PlainYearMonth)Ld(this,Fd,e,"f");else if(e instanceof Date)Ld(this,Fd,new Hc.PlainYearMonth(e.getFullYear(),e.getMonth()+1),"f");else{if("number"!=typeof t)throw new Error("Invalid value for bbnDtDateTime");{const e=new Date(t);Ld(this,Fd,new Hc.PlainYearMonth(e.getFullYear(),e.getMonth()+1),"f")}}}else{const e=new Date;Ld(this,Fd,new Hc.PlainYearMonth(e.getFullYear(),e.getMonth()+1),"f")}}get value(){return Hd(this,Fd,"f")}fdate(e=!1,t=!1,n=!1){if(!this.value)return"";const r=new Date(this.year(),this.month()-1),o={year:"numeric",month:e?"long":"numeric"};return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],o).format(r)}}Fd=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 extends bbnDt{constructor(e,t){if(super(),Ud.set(this,void 0),this.kind="month-day",e)if(void 0===t)if(e instanceof Hc.PlainMonthDay)Zd(this,Ud,e,"f");else if(e instanceof Date)Zd(this,Ud,new Hc.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 Hc.PlainMonthDay(t.getMonth()+1,t.getDate()),"f")}}else Zd(this,Ud,new Hc.PlainMonthDay(e,t),"f");else{const e=new Date;Zd(this,Ud,new Hc.PlainMonthDay(e.getMonth()+1,e.getDate()),"f")}}get value(){return Wd(this,Ud,"f")}fdate(e=!1,t=!1,n=!1){if(!this.value)return"";const r=new Date(2e3,this.month()-1,this.day()),o={month:e?"long":"numeric",day:"numeric"};return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],o).format(r)}}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,u,c,l;Id();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!==(u=null==r?void 0:r.weekdaysShort)&&void 0!==u?u:bbn.dt.locales.weekdaysShort},m=(null==bbn?void 0:bbn.env)&&(null===(c=bbn.env)||void 0===c?void 0:c.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(),u="date"===n.toLowerCase(),c="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,D=o.hasYear&&o.hasMonth&&o.hasDay,I=o.hasYear&&o.hasMonth&&!o.hasDay,k=!o.hasYear&&o.hasMonth&&o.hasDay,S=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&&S){if(!D)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(u||l||f||i&&M&&!S){if(u||D&&i){const e=new d.PlainDate(o.year,o.month,o.day);return new Rd(e)}if(l||I&&i){const e=new d.PlainYearMonth(o.year,o.month);return new Bd(e)}if(f||k&&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(c||i&&!M&&S){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"];function Jd(e,t,n){const r=e.trim();if(!r)return null;Id();const o=e=>{for(const t of e)try{return zd(r,t),t}catch(e){}return null};if(t){return o(Array.isArray(t)?t:[t])}const i=Dd(n),a=new Set,s=Vd.filter(e=>!a.has(e)&&(a.add(e),!0)),u=[...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)),c=o([...s,...u]);return c||null}const Gd=(e,t=null,n="auto")=>{if(!e)return new Ed;if("string"==typeof e){if(t)return zd(e,t,n);{const t=Jd(e);if(t)return zd(e,t,n);throw new Error(Zc("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(Zc("Invalid date value: %s",e))};Gd.locales=Object.create(null),Gd.parse=zd,Gd.guessFormat=Jd,Gd.time=()=>{},Gd.date=()=>{},Gd.dateTime=()=>{},Gd.duration=()=>{},Gd.zoned=()=>{},Gd.monthDay=()=>{},Gd.yearMonth=()=>{};const Kd={version:"1.0.1",opt:{_cat:{}},app:{},_:Zc,$: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:Wc,date:gf,dt:Gd,com:Gc,env:$c,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=Kd,window.Temporal||(window.Temporal=Hc)),e.Temporal=Hc,e.bbn=Kd,e.default=Kd,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(So(t));return n})(e,t),r,o,i)}function n(e,t,n,r,o,i){const s=M(t,n,r);if(o&&t!==s)throw new RangeError(Eo(e,t,n,r,i));return s}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 s({name:e},1)}function s(e,t){return l(e=>({value:e,configurable:1,writable:!t}),e)}function a(e){return l(e=>({get:e,configurable:1}),e)}function u(e){return{[Symbol.toStringTag]:{value:e,configurable:1}}}function c(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 g(e,t,n){for(const r of e)if(t[r]!==n[r])return 0;return 1}function p(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 S(e,t){return[Math.floor(e/t),k(e,t)]}function k(e,t){return(e%t+t)%t}function D(e,t){return[I(e,t),T(e,t)]}function I(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]],s=wi[i],a=bi/s,[u,c]=D(t,a);r+=c*s,o+=u}const[i,s]=D(r,bi);return[o+i,s]}function O(e,t,n){const r={};for(let o=t;o>=0;o--){const t=wi[o];r[n[o]]=I(e,t),e=T(e,t)}return r}function j(e){if(void 0!==e)return C(e)}function Y(e){return F(C(e))}function C(e){return A($i(e))}function N(e,t){if(null==t)throw new RangeError(So(e));return t}function R(e){if(!r(e))throw new TypeError(vo);return e}function P(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 F(e,t="number"){if(e<=0)throw new RangeError(go(t,e));return e}function L(e){if("symbol"==typeof e)throw new TypeError(yo);return String(e)}function H(e,t){return r(e)?String(e):Wi(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(po(t,e));return e}function W(e,t){return Math.trunc(U(e,t))||0}function Z(e,t){return A(U(e,t),t)}function $(e,t){return F(W(e,t),t)}function q(e,t){let[n,r]=D(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]=D(e,n);return[r,o*t]}function ee(e,t=1,n){const[r,o]=e,[i,s]=D(o,t);return r*(bi/t)+(i+(n?s/t:0))}function te(e,t,n=S){const[r,o]=e,[i,s]=n(o,t);return[r*(bi/t)+i,s]}function ne(e){return t(e,"isoYear",ms,hs,1),e.isoYear===ms?t(e,"isoMonth",4,12,1):e.isoYear===hs&&t(e,"isoMonth",1,9,1),e}function re(e){return oe({...e,...as,isoHour:12}),e}function oe(e){const n=t(e,"isoYear",ms,hs,1),r=n===ms?1:n===hs?-1:0;return r&&ie(le({...e,isoDay:e.isoDay+r,isoNanosecond:e.isoNanosecond-r})),e}function ie(e){if(!e||K(e,ds,fs))throw new RangeError(Vo);return e}function se(e){return x(e,5,ts)[1]}function ae(e){const[t,n]=S(e,bi);return[O(n,5,ts),t]}function ue(e){return te(e,mi)}function ce(e){return he(e.isoYear,e.isoMonth,e.isoDay,e.isoHour,e.isoMinute,e.isoSecond,e.isoMillisecond)}function le(e){const t=ce(e);if(void 0!==t){const[n,r]=D(t,li);return[n,r*hi+(e.isoMicrosecond||0)*di+(e.isoNanosecond||0)]}}function fe(e,t){const[n,r]=ae(se(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,s=0){const a=e===ms?1:e===hs?-1:0,u=new Date;return u.setUTCHours(r,o,i,s),u.setUTCFullYear(e,t-1,n+a),[u,a]}function ge(e,t){let[n,r]=V(e,t);r<0&&(r+=bi,n-=1);const[o,i]=S(r,hi),[s,a]=S(i,di);return pe(n*li+o,s,a)}function pe(e,t=0,n=0){const r=Math.ceil(Math.max(0,Math.abs(e)-ls)/li)*Math.sign(e),o=new Date(e-r*li);return c(rs,[o.getUTCFullYear(),o.getUTCMonth()+1,o.getUTCDate()+r,o.getUTCHours(),o.getUTCMinutes(),o.getUTCSeconds(),o.getUTCMilliseconds(),t,n])}function be(e,t){if(t<-ls)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 ys}function Ee(e,t){switch(t){case 2:return Se(e)?29:28;case 4:case 6:case 9:case 11:return 30}return 31}function Me(e){return Se(e)?366:365}function Se(e){return e%4==0&&(e%100!=0||e%400==0)}function ke(e){const[t,n]=me(e.isoYear,e.isoMonth,e.isoDay);return k(t.getUTCDay()-n,7)||7}function De(e){return this.id===Fi?(({isoYear:e})=>e<1?["gregory-inverse",1-e]:["gregory",e])(e):this.id===Li?Es(e):[]}function Ie(e){const t=ce(e);if(t<vs){const{isoYear:t}=e;return t<1?["japanese-inverse",1-t]:["japanese",t]}const n=be(Ya(Li),t),{era:r,eraYear:o}=jr(n,Li);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 g(ns,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 c(ts,[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 Ye(e){return void 0===e?0:Hs(R(e))}function Ce(e,t=0){e=We(e);const n=Bs(e),r=Us(e,t);return[Hs(e),r,n]}function Ne(e,t,n,r=9,o=0,i=4){t=We(t);let s=Fs(t,r,o),a=He(t),u=qs(t,i);const c=As(t,r,o,1);return null==s?s=Math.max(n,c):Ve(s,c),a=Be(a,c,1),e&&(u=(e=>e<4?(e+2)%4:e)(u)),[s,c,a,u]}function Re(e,t=6,n){let r=He(e=Ze(e,Ms));const o=qs(e,7);let i=As(e,t);return i=N(Ms,i),r=Be(r,i,void 0,n),[i,r,o]}function Pe(e){return Ws(We(e))}function Ae(e,t){return Fe(We(e),t)}function Fe(e,t=4){const n=Ue(e);return[qs(e,4),...Le(As(e,t),n)]}function Le(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[ks];return void 0===t?1:W(t,ks)}function Be(e,t,r,o){const i=o?bi:wi[t+1];if(i){const r=wi[t];if(i%((e=n(ks,e,1,i/r-(o?0:1),1))*r))throw new RangeError(Mo(ks,e))}else e=n(ks,e,1,r?10**9:1,1);return e}function Ue(e){let t=e[Ds];if(void 0!==t){if("number"!=typeof t){if("auto"===L(t))return;throw new RangeError(Mo(Ds,t))}t=n(Ds,Math.floor(t),0,9,1)}return t}function We(e){return void 0===e?{}:R(e)}function Ze(e,t){return"string"==typeof e?{[t]:e}:R(e)}function $e(e){return{overflow:xs[e]}}function qe(e,t,r=9,o=0,i){let s=t[e];if(void 0===s)return i?o:void 0;if(s=L(s),"auto"===s)return i?o:null;let a=ui[s];if(void 0===a&&(a=Ki[s]),void 0===a)throw new RangeError(To(e,s,ui));return n(e,a,o,r,1,ci),a}function ze(e,t,n,r=0){const o=n[e];if(void 0===o)return r;const i=L(o),s=t[i];if(void 0===s)throw new RangeError(To(e,i,t));return s}function Ve(e,t){if(t>e)throw new RangeError(ei)}function Je(e){return{branding:Qs,epochNanoseconds:e}}function Ge(e,t,n){return{branding:Xs,calendar:n,timeZone:t,epochNanoseconds:e}}function Ke(e,t=e.calendar){return{branding:Gs,calendar:t,...h(ss,e)}}function Xe(e,t=e.calendar){return{branding:Js,calendar:t,...h(os,e)}}function Qe(e,t=e.calendar){return{branding:zs,calendar:t,...h(os,e)}}function et(e,t=e.calendar){return{branding:Vs,calendar:t,...h(os,e)}}function tt(e){return{branding:Ks,...h(is,e)}}function nt(e){return{branding:ea,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 st(e,t,n,r,o,i,s){const a=qi[n],u={...t,[a]:t[a]+r},c=s(e,o,t),l=s(e,o,u);return[i(c),i(l)]}function at(e,t,n){const r=ee(J(t,n));if(!r)throw new RangeError(Fo);return ee(J(t,e))/r}function ut(e,t,n,r){return ct(e,dt(t,n),r)}function ct(e,t,n){const[r,o]=lt(e,t,n);return oe({...an(e,o),...r})}function lt(e,t,n){return ae(yt(se(e),t,n))}function ft(e){return yt(e,gi,7)}function dt(e,t){return wi[e]*t}function ht(e){const t=mt(e);return[t,an(t,1)]}function mt(e){return us(6,e)}function gt(e,t,n){const r=Math.min(kn(e),6);return En(wt(vn(e,r),t,n),r)}function pt(e,t,n,r,o,i,s,a,u,c){if(0===r&&1===o)return e;const l=hn(r,a)?dn(a)&&r<6&&n>=6?Mt:Et:St;let[f,d,h]=l(e,t,n,r,o,i,s,a,u,c);return h&&7!==r&&(f=((e,t,n,r,o,i,s,a)=>{const u=bn(e);for(let c=r+1;c<=n;c++){if(7===c&&7!==n)continue;const r=es(c,e);r[qi[c]]+=u;const l=ee(J(s(a(o,i,r)),t));if(l&&Math.sign(l)!==u)break;e=r}return e})(f,d,n,Math.max(6,r),s,a,u,c)),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[s,a]=S(yt(i,t,n),bi);return q(o+s,a)}function yt(e,t,n){return vt(e/t,n)*t}function vt(e,t){return ta[t](e)}function Et(e,t,n,r,o,i){const s=bn(e),a=vn(e),u=bt(a,r,o,i),c=J(a,u),l=Math.sign(u[0]-a[0])===s,f=En(u,Math.min(n,6));return[{...e,...f},z(t,c),l]}function Mt(e,t,n,r,o,i,s,a,u,c){const l=bn(e)||1,f=ee(vn(e,5)),d=dt(r,o);let h=yt(f,d,i);const[m,g]=st(s,{...e,...Qi},6,l,a,u,c),p=h-ee(J(m,g));let b=0;p&&Math.sign(p)!==l?t=V(m,h):(b+=l,h=yt(p,d,i),t=V(g,h));const w=Mn(h);return[{...e,...w,days:e.days+b},t,Boolean(b)]}function St(e,t,n,r,o,i,s,a,u,c){const l=bn(e),f=qi[r],d=es(r,e);7===r&&(e={...e,weeks:e.weeks+Math.trunc(e.days/7)});const h=I(e[f],o)*o;d[f]=h;const[m,g]=st(s,d,r,o*l,a,u,c),p=h+at(t,m,g)*l*o,b=yt(p,o,i),w=Math.sign(b-p)===l;return d[f]=b,[d,w?g:m,w]}function kt(e,t,n,r){const[o,i,s,a]=(e=>{const t=Fe(e=We(e));return[e.timeZone,...t]})(r),u=void 0!==o;return((e,t,n,r,o,i)=>{n=wt(n,o,r,1);const s=t.R(n);return Nt(ge(n,s),i)+(e?Lt(ft(s)):"Z")})(u,t(u?e(o):na),n.epochNanoseconds,i,s,a)}function Dt(e,t,n){const[r,o,i,s,a,u]=(e=>{e=We(e);const t=Ws(e),n=Ue(e),r=$s(e),o=qs(e,4),i=As(e,4);return[t,Zs(e),r,o,...Le(i,n)]})(n);return((e,t,n,r,o,i,s,a,u,c)=>{r=wt(r,u,a,1);const l=e(n).R(r);return Nt(ge(r,l),c)+Lt(ft(l),s)+((e,t)=>1!==t?"["+(2===t?"!":"")+e+"]":"")(n,i)+Ht(t,o)})(e,t.calendar,t.timeZone,t.epochNanoseconds,r,o,i,s,a,u)}function It(e,t){const[n,r,o,i]=(e=>(e=We(e),[Ws(e),...Fe(e)]))(t);return s=e.calendar,a=n,u=i,Nt(ct(e,o,r),u)+Ht(s,a);var s,a,u}function Tt(e,t){return n=e.calendar,r=e,o=Pe(t),Rt(r)+Ht(n,o);var n,r,o}function _t(e,t){return Yt(e.calendar,Pt,e,Pe(t))}function xt(e,t){return Yt(e.calendar,At,e,Pe(t))}function Ot(e,t){const[n,r,o]=Ae(t);return i=o,Ft(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,...gt(e,r,n)}),((e,t)=>{const{sign:n}=e,r=-1===n?pn(e):e,{hours:o,minutes:i}=r,[s,a]=te(vn(r,3),mi,D);yn(s);const u=Ut(a,t),c=t>=0||!n||u;return(n<0?"-":"")+"P"+Ct({Y:Zt(r.years),M:Zt(r.months),W:Zt(r.weeks),D:Zt(r.days)})+(o||i||s||c?"T"+Ct({H:Zt(o),M:Zt(i),S:Zt(s,c)+u}):"")})(e,o)}function Yt(e,t,n,r){const o=r>1||0===r&&e!==Ai;return 1===r?e===Ai?t(n):Rt(n):o?Rt(n)+Bt(e,2===r):t(n)}function Ct(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 Rt(e)+"T"+Ft(e,t)}function Rt(e){return Pt(e)+"-"+ai(e.isoDay)}function Pt(e){const{isoYear:t}=e;return(t<0||t>9999?Wt(t)+v(6,Math.abs(t)):v(4,t))+"-"+ai(e.isoMonth)}function At(e){return ai(e.isoMonth)+"-"+ai(e.isoDay)}function Ft(e,t){const n=[ai(e.isoHour),ai(e.isoMinute)];return-1!==t&&n.push(ai(e.isoSecond)+((e,t,n,r)=>Ut(e*hi+t*di+n,r))(e.isoMillisecond,e.isoMicrosecond,e.isoNanosecond,t)),n.join(":")}function Lt(e,t=0){if(1===t)return"";const[n,r]=S(Math.abs(e),pi),[o,i]=S(r,gi),[s,a]=S(i,mi);return Wt(e)+ai(n)+":"+ai(o)+(s||a?":"+ai(s)+Ut(a):"")}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(sa,""):n.slice(0,t),n?"."+n:""}function Wt(e){return e<0?"-":"+"}function Zt(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=ge(n,r);return{calendar:e.calendar,...o,offsetNanoseconds:r}}function qt(e,t,n,r=0,o=0,i,s){if(void 0!==n&&1===r&&(1===r||s))return fe(t,n);const a=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}})(a,t,n,i);if(void 0!==e)return e;if(0===r)throw new RangeError(qo)}return s?le(t):zt(e,t,o,a)}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),s=i*(2===n?-1:1);return(r=e.I(ge(o,s)))[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(Sn(e))throw new RangeError(Xo);return vn(e,5)})(e?pn(n):n))))}function Gt(e,t,n,r,o,i=Object.create(null)){const s=t(r.timeZone),a=e(r.calendar);return{...r,...tn(s,a,r,n?pn(o):o,i)}}function Kt(e,t,n,r,o=Object.create(null)){const{calendar:i}=n;return Ke(nn(e(i),n,t?pn(r):r,o),i)}function Xt(e,t,n,r,o){const{calendar:i}=n;return Xe(rn(e(i),n,t?pn(r):r,o),i)}function Qt(e,t,n,r,o){const i=n.calendar,s=e(i);let a=re(on(s,n));t&&(r=gn(r)),r.sign<0&&(a=s.P(a,{...Xi,months:1}),a=an(a,-1));const u=s.P(a,r,o);return Qe(on(s,u),i)}function en(e,t,n){return tt(sn(t,e?pn(n):n)[0])}function tn(e,t,n,r,o){const i=vn(r,5);let s=n.epochNanoseconds;if(Sn(r)){const a=aa(n,e);s=z(zt(e,{...rn(t,a,{...r,...Qi},o),...h(ts,a)}),i)}else s=z(s,i),Ye(o);return{epochNanoseconds:ie(s)}}function nn(e,t,n,r){const[o,i]=sn(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);Ye(r);const o=n.days+vn(n,5)[0];return o?re(an(t,o)):t}function on(e,t,n=1){return an(t,n-e.day(t))}function sn(e,t){const[n,r]=vn(t,5),[o,i]=ae(se(e)+r);return[o,n+i]}function an(e,t){return t?{...e,...pe(ce(e)+t*li)}:e}function un(e,t,n){const r=e(n.calendar);return dn(n)?[n,r,t(n.timeZone)]:[{...n,...as},r]}function cn(e){return e?ot:le}function ln(e){return e?b(tn,e):nn}function fn(e){return e?b(ar,e):ur}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,s){const a=e(We(s).relativeTo),u=Math.max(kn(o),kn(i));if(hn(u,a))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,u,r)));if(!a)throw new RangeError(Ko);r&&(i=pn(i));const[c,l,f]=un(t,n,a),d=ln(f),h=fn(f),m=d(l,c,o);return nt(h(l,c,d(l,m,i),u))}function gn(e){return nt(pn(e))}function pn(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],-ua,ua,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 Sn(e){return Boolean(bn(e,Ji))}function kn(e){let t=9;for(;t>0&&!e[qi[t]];t--);return t}function Dn(e,t){return[e,t]}function In(e){const t=Math.floor(e/ra)*ra;return[t,t+ra]}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(Wi(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,...as}:{...r,isoDay:1,...as}):n&&r.calendar===Ai&&(r={...r,isoYear:ws}),Xe(r.C?jn(r):Yn(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=ca(o);let s;return Te(e),s=e.C?qt(i,e,t,n,r,!i.$,e.j):Vt(i,e),Ge(s,o,Wr(e.calendar))}function jn(e){return Cn(oe(Te(e)))}function Yn(e){return Cn(re(_e(e)))}function Cn(e){return{...e,calendar:Wr(e.calendar)}}function Nn(e){const t=Ma.exec(e);return t?(e=>{const t=e[10],n="Z"===(t||"").toUpperCase();return{isoYear:Fn(e),isoMonth:parseInt(e[4]),isoDay:parseInt(e[5]),...Ln(e.slice(5)),...Hn(e[16]),C:Boolean(e[6]),j:n,offset:n?void 0:t}})(t):void 0}function Rn(e){const t=va.exec(e);return t?(e=>({isoYear:Fn(e),isoMonth:parseInt(e[4]),isoDay:1,...Hn(e[5])}))(t):void 0}function Pn(e){const t=Ea.exec(e);return t?(e=>({isoYear:ws,isoMonth:parseInt(e[1]),isoDay:parseInt(e[2]),...Hn(e[3])}))(t):void 0}function An(e,t){const n=ka.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(Zo);return e})((Zn(e[2])*pi+Zn(e[3])*gi+Zn(e[4])*mi+Bn(e[5]||""))*Wn(e[1]))})(n,t):void 0}function Fn(e){const t=Wn(e[1]),n=parseInt(e[2]||e[3]);if(t<0&&!n)throw new RangeError(ni(-0));return t*n}function Ln(e){const t=Zn(e[3]);return{...ae(Bn(e[4]||""))[0],isoHour:Zn(e[1]),isoMinute:Zn(e[2]),isoSecond:60===t?59:t}}function Hn(e){let t,n;const r=[];if(e.replace(Da,(e,o,i)=>{const s=Boolean(o),[a,u]=i.split("=").reverse();if(u){if("u-ca"===u)r.push(a),t||(t=s);else if(s||/[A-Z]/.test(u))throw new RangeError(ni(e))}else{if(n)throw new RangeError(ni(e));n=a}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 Wn(e){return e&&"+"!==e?-1:1}function Zn(e){return void 0===e?0:parseInt(e)}function $n(e){const t=zn(e);return"number"==typeof t?Lt(t):t?(e=>{if(xa.test(e))throw new RangeError(Bo(e));if(_a.test(e))throw new RangeError(Wo);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):na}function qn(e){const t=zn(e);return"number"==typeof t?t:t?t.resolvedOptions().timeZone:na}function zn(e){const t=An(e=e.toUpperCase(),1);return void 0!==t?t:e!==na?Ta(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(ce(e),ce(t))}function Xn(e,t){return E(se(e),se(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?pn(i):i)}function tr(e,t,n,r,o,i){const s=pr(r.calendar,o.calendar),[a,u,c,l]=Ne(n,i,5),f=r.epochNanoseconds,d=o.epochNanoseconds,h=G(d,f);let m;if(h)if(a<6)m=fr(f,d,a,u,c,l);else{const n=t(((e,t)=>{if(!Qn(e,t))throw new RangeError(Uo);return e})(r.timeZone,o.timeZone)),f=e(s);m=cr(f,n,r,o,h,a,i),m=pt(m,d,a,u,c,l,f,r,ot,b(tn,n))}else m=Xi;return nt(n?pn(m):m)}function nr(e,t,n,r,o){const i=pr(n.calendar,r.calendar),[s,a,u,c]=Ne(t,o,6),l=le(n),f=le(r),d=G(f,l);let h;if(d)if(s<=6)h=fr(l,f,s,a,u,c);else{const t=e(i);h=lr(t,n,r,d,s,o),h=pt(h,f,s,a,u,c,t,n,le,nn)}else h=Xi;return nt(t?pn(h):h)}function rr(e,t,n,r,o){const i=pr(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=pr(n.calendar,r.calendar),s=Ne(t,o,9,9,8),a=e(i),u=on(a,n),c=on(a,r);return u.isoYear===c.isoYear&&u.isoMonth===c.isoMonth&&u.isoDay===c.isoDay?nt(Xi):ir(t,()=>a,re(u),re(c),...s,8)}function ir(e,t,n,r,o,i,s,a,u=6){const c=le(n),l=le(r);if(void 0===c||void 0===l)throw new RangeError(Vo);let f;if(G(l,c))if(6===o)f=fr(c,l,o,i,s,a);else{const e=t();f=e.N(n,r,o),i===u&&1===s||(f=pt(f,l,o,i,s,a,e,n,le,rn))}else f=Xi;return nt(e?pn(f):f)}function sr(e,t,n,r){const[o,i,s,a]=Ne(e,r,5,5),u=yt(gr(t,n),dt(i,s),a),c={...Xi,...Mn(u,o)};return nt(e?pn(c):c)}function ar(e,t,n,r,o,i){const s=G(r.epochNanoseconds,n.epochNanoseconds);return s?o<6?dr(n.epochNanoseconds,r.epochNanoseconds,o):cr(t,e,n,r,s,o,i):Xi}function ur(e,t,n,r,o){const i=le(t),s=le(n),a=G(s,i);return a?r<=6?dr(i,s,r):lr(e,t,n,a,r,o):Xi}function cr(e,t,n,r,o,i,s){const[a,u,c]=((e,t,n,r)=>{function o(){return f={...an(a,c++*-r),...s},d=zt(e,f),G(u,d)===-r}const i=aa(t,e),s=h(ts,i),a=aa(n,e),u=n.epochNanoseconds;let c=0;const l=gr(i,a);let f,d;if(Math.sign(l)===-r&&c++,o()&&(-1===r||o()))throw new RangeError(Fo);const m=ee(J(d,u));return[i,f,m]})(t,n,r,o);var l,f;return{...6===i?(l=a,f=u,{...Xi,days:hr(l,f)}):e.N(a,u,i,s),...Mn(c)}}function lr(e,t,n,r,o,i){const[s,a,u]=((e,t,n)=>{let r=t,o=gr(e,t);return Math.sign(o)===-n&&(r=an(t,-n),o+=bi*n),[e,r,o]})(t,n,r);return{...e.N(s,a,o,i),...Mn(u)}}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(ce(e),ce(t))}function mr(e,t){return Math.trunc((t-e)/li)}function gr(e,t){return se(t)-se(e)}function pr(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),ce(e))+1}function vr(e){const t=Oa.exec(e);if(!t)throw new RangeError(No(e));return[parseInt(t[1]),Boolean(t[2])]}function Er(e,t){return"M"+ai(e)+(t?"L":"")}function Mr(e,t,n){return e+(t||n&&e>=n?1:0)}function Sr(e,t){return e-(t&&e>=t?1:0)}function kr(e,t){return(t+e)*(Math.sign(t)||1)||0}function Dr(e){return Hi[Tr(e)]}function Ir(e){return Ui[Tr(e)]}function Tr(e){return Zr(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=Ya(e),r=Zr(e);return{id:e,h:xr(t),l:Or(t)}}function xr(e){return o(t=>{const n=ce(t);return e(n)},WeakMap)}function Or(e){const t=e(0).year-bs;return o(n=>{let r,o=he(n-t),i=0;const s=[],a=[];do{o+=400*li}while((r=e(o)).year<=n);do{if(o+=(1-r.day)*li,r.year===n&&(s.push(o),a.push(r.o)),o-=li,++i>100||o<-ls)throw new RangeError(Fo)}while((r=e(o)).year>=n);return{i:s.reverse(),u:ii(a.reverse())}})}function jr(e,t){let n,r,o=Yr(e);if(e.era){const i=Hi[t],s=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=s[n]||n,r=o,o=kr(r,i[n]||0))}return{era:n,eraYear:r,year:o}}function Yr(e){return parseInt(e.relatedYear||e.year)}function Cr(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 Rr(e,t){const n=Pr.call(this,e);return[Sr(t,n),n===t]}function Pr(e){const t=Br(this,e),n=Br(this,e-1),r=t.length;if(r>n.length){const e=Ir(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 Fr(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 Lr(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 Wr(Wi(e))}function Wr(e){if((e=e.toLowerCase())!==Ai&&e!==Fi){const t=Ya(e).resolvedOptions().calendar;if(Zr(e)!==Zr(t))throw new RangeError(Lo(e));return t}return e}function Zr(e){return"islamicc"===e&&(e="islamic"),e.split("-")[0]}function $r(e,t){return n=>n===Ai?e:n===Fi||n===Li?Object.assign(Object.create(e),{id:n}):Object.assign(Object.create(t),ja(n))}function qr(e,t,n,r){const o=zr(n,r,Ci,[],ki);if(void 0!==o.timeZone){const r=n.F(o),i=Jr(o),s=e(o.timeZone);return{epochNanoseconds:qt(t(s),{...r,...i},void 0!==o.offset?Tn(o.offset):void 0),timeZone:s}}return{...n.F(o),...as}}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,s=0;for(const r of t){if(r===i)throw new RangeError(Do(r));if("constructor"===r||"__proto__"===r)throw new RangeError(ko(r));let t=e[r];if(void 0!==t)s=1,Wa[r]&&(t=Wa[r](t,r)),o[r]=t;else if(n){if(n.includes(r))throw new TypeError(So(r));o[r]=Pi[r]}i=r}if(r&&!s)throw new TypeError(Io(t));return o}function Jr(e,t){return je(Za({...Pi,...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=Dr(e),r=Bi[e.id||""]||{};let{era:o,eraYear:i,year:s}=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(Yo(o));const t=kr(i,e);if(void 0!==s&&s!==t)throw new RangeError(jo);s=t}else if(void 0===s)throw new TypeError(Co(n));return s}function Xr(e,t,r,o){let{month:i,monthCode:s}=t;if(void 0!==s){const t=((e,t,n,r)=>{const o=e.L(n),[i,s]=vr(t);let a=Mr(i,s,o);if(s){const t=Ir(e);if(void 0===t)throw new RangeError(Ao);if(t>0){if(a>t)throw new RangeError(Ao);if(void 0===o){if(1===r)throw new RangeError(Ao);a--}}else{if(a!==-t)throw new RangeError(Ao);if(void 0===o&&1===r)throw new RangeError(Ao)}}return a})(e,s,r,o);if(void 0!==i&&i!==t)throw new RangeError(Ro);i=t,o=1}else if(void 0===i)throw new TypeError(Po);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=Ba(e.calendar),[n,r,o]=t.v(e),[i,s]=t.q(n,r);return{year:n,monthCode:Er(i,s),day:o}}function no(e,t){return Ke(aa(t,e))}function ro(e,t){return Xe(aa(t,e))}function oo(e,t){return tt(aa(t,e))}function io(e,t,n){const r=new Set(n);return(o,i)=>{const s=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&&s)throw new TypeError("Invalid formatting options");o={...t,...o}}return n&&(o.timeZone=na,["full","long"].includes(o.J)&&(o.J="medium")),o}}function so(e,t=ao,n=0){const[r,,,o]=e;return(i,s=Eu,...a)=>{const u=t(o&&o(...a),i,s,r,n),c=u.resolvedOptions();return[u,...uo(e,c,a)]}}function ao(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 gs(t,n)}function uo(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 co(e,t){return{...e,calendar:t}}function lo(e){const t=fo();return ge(t,e.R(t))}function fo(){return Q(Date.now(),hi)}function ho(){return Ou||(Ou=(new gs).resolvedOptions().timeZone)}const mo=(e,t)=>`Non-integer ${e}: ${t}`,go=(e,t)=>`Non-positive ${e}: ${t}`,po=(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}`,So=e=>`Missing ${e}`,ko=e=>`Invalid field ${e}`,Do=e=>`Duplicate field ${e}`,Io=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",Yo=e=>`Invalid era: ${e}`,Co=e=>"Missing year"+(e?"/era/eraYear":""),No=e=>`Invalid monthCode: ${e}`,Ro="Mismatching month/monthCode",Po="Missing month/monthCode",Ao="Invalid leap month",Fo="Invalid protocol results",Lo=e=>Mo("Calendar",e),Ho="Mismatching Calendars",Bo=e=>Mo("TimeZone",e),Uo="Mismatching TimeZones",Wo="Forbidden ICU TimeZone",Zo="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),si=b(f,(e,t,n)=>n),ai=b(v,2),ui={nanosecond:0,microsecond:1,millisecond:2,second:3,minute:4,hour:5,day:6,week:7,month:8,year:9},ci=Object.keys(ui),li=864e5,fi=1e3,di=1e3,hi=1e6,mi=1e9,gi=6e10,pi=36e11,bi=864e11,wi=[1,di,hi,mi,gi,pi,bi],yi=ci.slice(0,6),vi=y(yi),Ei=["offset"],Mi=["timeZone"],Si=yi.concat(Ei),ki=Si.concat(Mi),Di=["era","eraYear"],Ii=Di.concat(["year"]),Ti=["year"],_i=["monthCode"],xi=["month"].concat(_i),Oi=["day"],ji=xi.concat(Ti),Yi=_i.concat(Ti),Ci=Oi.concat(ji),Ni=Oi.concat(xi),Ri=Oi.concat(_i),Pi=si(yi,0),Ai="iso8601",Fi="gregory",Li="japanese",Hi={[Fi]:{"gregory-inverse":-1,gregory:0},[Li]:{"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={[Fi]:{bce:"gregory-inverse",ce:"gregory"},[Li]:{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},Wi=b(P,"string"),Zi=b(P,"boolean"),$i=b(P,"number"),qi=ci.map(e=>e+"s"),zi=y(qi),Vi=qi.slice(0,6),Ji=qi.slice(6),Gi=Ji.slice(1),Ki=ii(qi),Xi=si(qi,0),Qi=si(Vi,0),es=b(p,qi),ts=["isoNanosecond","isoMicrosecond","isoMillisecond","isoSecond","isoMinute","isoHour"],ns=["isoDay","isoMonth","isoYear"],rs=ts.concat(ns),os=y(ns),is=y(ts),ss=y(rs),as=si(is,0),us=b(p,rs),cs=1e8,ls=cs*li,fs=[cs,0],ds=[-cs,0],hs=275760,ms=-271821,gs=Intl.DateTimeFormat,ps="en-GB",bs=1970,ws=1972,ys=12,vs=he(1868,9,8),Es=o(Ie,WeakMap),Ms="smallestUnit",Ss="unit",ks="roundingIncrement",Ds="fractionalSecondDigits",Is="relativeTo",Ts="direction",_s={constrain:0,reject:1},xs=Object.keys(_s),Os={compatible:0,reject:1,earlier:2,later:3},js={reject:0,use:1,prefer:2,ignore:3},Ys={auto:0,never:1,critical:2,always:3},Cs={auto:0,never:1,critical:2},Ns={auto:0,never:1},Rs={floor:0,halfFloor:1,ceil:2,halfCeil:3,trunc:4,halfTrunc:5,expand:6,halfExpand:7,halfEven:8},Ps={previous:-1,next:1},As=b(qe,Ms),Fs=b(qe,"largestUnit"),Ls=b(qe,Ss),Hs=b(ze,"overflow",_s),Bs=b(ze,"disambiguation",Os),Us=b(ze,"offset",js),Ws=b(ze,"calendarName",Ys),Zs=b(ze,"timeZoneName",Cs),$s=b(ze,"offset",Ns),qs=b(ze,"roundingMode",Rs),zs="PlainYearMonth",Vs="PlainMonthDay",Js="PlainDate",Gs="PlainDateTime",Ks="PlainTime",Xs="ZonedDateTime",Qs="Instant",ea="Duration",ta=[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)],na="UTC",ra=5184e3,oa=de(1847),ia=de((new Date).getUTCFullYear()+10),sa=/0+$/,aa=o($t,WeakMap),ua=2**32-1,ca=o(e=>{const t=zn(e);return"object"==typeof t?new fa(t):new la(t||0)});class la{constructor(e){this.$=e}R(){return this.$}I(e){return(e=>{const t=le({...e,...as});if(!t||Math.abs(t[0])>1e8)throw new RangeError(Vo)})(e),[fe(e,this.$)]}O(){}}class fa{constructor(e){this.nn=(e=>{function t(e){const t=M(e,s,a),[o,u]=In(t),c=r(o),l=r(u);return c===l?c:n(i(o,u),c,l,e)}function n(t,n,r,o){let i,s;for(;(void 0===o||void 0===(i=o<t[0]?n:o>=t[1]?r:void 0))&&(s=t[1]-t[0]);){const n=t[0]+Math.floor(s/2);e(n)===r?t[1]=n:t[0]=n+1}return i}const r=o(e),i=o(Dn);let s=oa,a=ia;return{tn(e){const n=t(e-86400),r=t(e+86400),o=e-n,i=e-r;if(n===r)return[o];const s=t(o);return s===t(i)?[e-s]:n>r?[o,i]:[]},rn:t,O(e,t){const o=M(e,s,a);let[u,c]=In(o);const l=ra*t,f=t<0?()=>c>s||(s=o,0):()=>u<a||(a=o,0);for(;f();){const o=r(u),s=r(c);if(o!==s){const r=i(u,c);n(r,o,s);const a=r[0];if((E(a,e)||1)===t)return a}u+=l,c+=l}}}})((e=>t=>{const n=be(e,t*fi);return de(Yr(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=>ue(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]=ue(e),o=this.nn.O(n+(t>0||r?1:0),t);if(void 0!==o)return Q(o,mi)}}const da="([+-])",ha="(?:[.,](\\d{1,9}))?",ma=`(?:(?:${da}(\\d{6}))|(\\d{4}))-?(\\d{2})`,ga="(\\d{2})(?::?(\\d{2})(?::?(\\d{2})"+ha+")?)?",pa=da+ga,ba=ma+"-?(\\d{2})(?:[T ]"+ga+"(Z|"+pa+")?)?",wa="\\[(!?)([^\\]]*)\\]",ya=`((?:${wa}){0,9})`,va=Un(ma+ya),Ea=Un("(?:--)?(\\d{2})-?(\\d{2})"+ya),Ma=Un(ba+ya),Sa=Un("T?"+ga+"(?:"+pa+")?"+ya),ka=Un(pa),Da=new RegExp(wa,"g"),Ia=Un(`${da}?P(\\d+Y)?(\\d+M)?(\\d+W)?(\\d+D)?(?:T(?:(\\d+)${ha}H)?(?:(\\d+)${ha}M)?(?:(\\d+)${ha}S)?)?`),Ta=o(e=>new gs(ps,{timeZone:e,era:"short",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"})),_a=/^(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$/,xa=/[^\w\/:+-]+/,Oa=/^M(\d{2})(L?)$/,ja=o(_r),Ya=o(e=>new gs(ps,{calendar:e,timeZone:na,era:"short",year:"numeric",month:"short",day:"numeric"})),Ca={P(e,t,r){const o=Ye(r);let i,{years:s,months:a,weeks:u,days:c}=t;if(c+=vn(t,5)[0],s||a)i=((e,t,r,o,i)=>{let[s,a,u]=e.v(t);if(r){const[t,o]=e.q(s,a);s+=r,a=Mr(t,o,e.L(s)),a=n("month",a,1,e.B(s),i)}return o&&([s,a]=e.un(s,a,o)),u=n("day",u,1,e.U(s,a),i),e.p(s,a,u)})(this,e,s,a,o);else{if(!u&&!c)return e;i=ce(e)}if(void 0===i)throw new RangeError(Vo);return i+=(7*u+c)*li,re(pe(i))},N(e,t,n){if(n<=7){let r=0,o=hr({...e,...as},{...t,...as});return 7===n&&([r,o]=D(o,7)),{...Xi,weeks:r,days:o}}const r=this.v(e),o=this.v(t);let[i,s,a]=((e,t,n,r,o,i,s)=>{let a=o-t,u=i-n,c=s-r;if(a||u){const l=Math.sign(a||u);let f=e.U(o,i),d=0;if(Math.sign(c)===-l){const r=f;[o,i]=e.un(o,i,-l),a=o-t,u=i-n,f=e.U(o,i),d=l<0?-r:f}if(c=s-Math.min(r,f)+d,a){const[r,s]=e.q(t,n),[c,f]=e.q(o,i);if(u=c-r||Number(f)-Number(s),Math.sign(u)===-l){const n=l<0&&-e.B(o);a=(o-=l)-t,u=i-Mr(r,s,e.L(o))+(n||e.B(o))}}}return[a,u,c]})(this,...r,...o);return 8===n&&(s+=this.cn(i,r[0]),i=0),{...Xi,years:i,months:s,days:a}},F(e,t){const n=Ye(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=Ye(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=Ye(t);let r,o,i,s=void 0!==e.eraYear||void 0!==e.year?Kr(this,e):void 0;const a=!this.id;if(void 0===s&&a&&(s=ws),void 0!==s){const t=Xr(this,e,s,n);r=Qr(this,e,t,s,n);const a=this.L(s);o=Sr(t,a),i=t===a}else{if(void 0===e.monthCode)throw new TypeError(Po);if([o,i]=vr(e.monthCode),this.id&&this.id!==Fi&&this.id!==Li)if(this.id&&"coptic"===Zr(this.id)&&0===n){const t=i||13!==o?30:6;r=e.day,r=M(r,1,t)}else if(this.id&&"chinese"===Zr(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,ws,n),ws,n)}const u=this.G(o,i,r);if(!u)throw new RangeError("Cannot guess year");const[c,l]=u;return et(re(this.V(c,l,r)),this.id||Ai)},fields(e){return Dr(this)&&e.includes("year")?[...e,...Di]:e},k(e,t){const n=Object.assign(Object.create(null),e);return eo(n,t,xi),Dr(this)&&(eo(n,t,Ii),this.id===Li&&eo(n,t,Ni,Di)),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:ke,daysInWeek:()=>7},Na={v:we,hn:De,q:ye},Ra={dayOfYear:yr,v:we,p:he},Pa=Object.assign({},Ra,{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(k(u+n*r,7));return l=(n+(o-c)*r)/7}const r=this.id?1:4,o=ke(e),i=this.dayOfYear(e),s=k(o-1,7),a=i-1,u=k(s-a,7),c=t(u);let l,f=Math.floor((a-c)/7)+1,d=e.isoYear;return f?f>n(0)&&(f=1,d++):(f=n(-1),d--),[f,d,l]}}),Aa=Object.assign({},Ca,Pa,{v:we,hn:De,q:ye,G(e,t){if(!t)return[ws,e]},sn:Se,L(){},B:ve,cn:e=>e*ys,U:Ee,fn:Me,V:(e,t,n)=>({isoYear:e,isoMonth:t,isoDay:n}),p:he,un:(e,t,n)=>(e+=I(n,ys),(t+=T(n,ys))<1?(e--,t+=ys):t>ys&&(e++,t-=ys),[e,t]),year:e=>e.isoYear,month:e=>e.isoMonth,day:e=>e.isoDay}),Fa={v:Cr,hn:Hr,q:Rr},La={dayOfYear:yr,v:Cr,p:Nr,weekOfYear:br,yearOfWeek:wr,m:()=>[]},Ha=Object.assign({},Ca,La,{v:Cr,hn:Hr,q:Rr,G(e,t,n){const r=this.id&&"chinese"===Zr(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):ws;let[o,i,s]=Cr.call(this,{isoYear:r,isoMonth:ys,isoDay:31});const a=Pr.call(this,o),u=i===a;1===(E(e,Sr(i,a))||E(Number(t),Number(u))||E(n,s))&&o--;for(let r=0;r<100;r++){const i=o-r,s=Pr.call(this,i),a=Mr(e,t,s);if(t===(a===s)&&n<=Fr.call(this,i,a))return[i,a]}},sn(e){const t=Ar.call(this,e);return t>Ar.call(this,e-1)&&t>Ar.call(this,e+1)},L:Pr,B:Lr,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+=Lr.call(this,e+o);return i},U:Fr,fn:Ar,V(e,t,n){return pe(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+=Lr.call(this,--e);else{let n;for(;t>(n=Lr.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}}),Ba=$r(Na,Fa),Ua=$r(Aa,Ha),Wa={...{era:H,eraYear:W,year:W,month:$,monthCode(e){const t=H(e);return vr(t),t},day:$},...si(yi,W),...si(qi,Z),offset(e){const t=H(e);return Tn(t),t}},Za=b(d,yi,ts),$a=b(d,ts,yi),qa="numeric",za=["timeZoneName"],Va={month:qa,day:qa},Ja={year:qa,month:qa},Ga=Object.assign({},Ja,{day:qa}),Ka={hour:qa,minute:qa,second:qa},Xa=Object.assign({},Ga,Ka),Qa=Object.assign({},Xa,{timeZoneName:"short"}),eu=Object.keys(Ja),tu=Object.keys(Va),nu=Object.keys(Ga),ru=Object.keys(Ka),ou=["dateStyle"],iu=eu.concat(ou),su=tu.concat(ou),au=nu.concat(ou,["weekday"]),uu=ru.concat(["dayPeriod","timeStyle","fractionalSecondDigits"]),cu=au.concat(uu),lu=za.concat(uu),fu=za.concat(au),du=za.concat(["day","weekday"],uu),hu=za.concat(["year","weekday"],uu),mu=io(cu,Xa),gu=io(cu,Qa),pu=io(cu,Xa,za),bu=io(au,Ga,lu),wu=io(uu,Ka,fu),yu=io(iu,Ja,du),vu=io(su,Va,hu),Eu={},Mu=new gs(void 0,{calendar:Ai}).resolvedOptions().calendar===Ai,Su=[mu,rt],ku=[gu,rt,0,(e,t)=>{const n=e.timeZone;if(t&&t.timeZone!==n)throw new RangeError(Uo);return n}],Du=[pu,ce],Iu=[bu,ce],Tu=[wu,e=>se(e)/hi],_u=[yu,ce,Mu],xu=[vu,ce,Mu];let Ou;function ju(e,t,n,r,o){function c(...e){if(!(this instanceof c))throw new TypeError(_o);rc(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=nc(t);if(!n||n.branding!==e)throw new TypeError(_o);return n}return Object.defineProperties(c.prototype,{...a(l(f,n)),...s(l(f,r)),...u("Temporal."+e)}),Object.defineProperties(c,{...s(o),...i(e)}),[c,e=>{const t=Object.create(c.prototype);return rc(t,e),t},d]}function Yu(e){if(nc(e)||void 0!==e.calendar||void 0!==e.timeZone)throw new TypeError("Invalid bag");return e}function Cu(e){return Nu(e)||Ai}function Nu(e){const{calendar:t}=e;if(void 0!==t)return Ru(t)}function Ru(e){if(r(e)){const{calendar:t}=nc(e)||{};if(!t)throw new TypeError(Lo(e));return t}return(e=>Wr(function(e){const t=Nn(e)||Rn(e)||Pn(e);return t?t.calendar:e}(Wi(e))))(e)}function Pu(e){const t={};for(const n in e)t[n]=e=>{const{calendar:t}=e;return Ua(t)[n](e)};return t}function Au(){throw new TypeError("Cannot use valueOf")}function Fu(e){if(r(e)){const{timeZone:t}=nc(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&&na||t.offset)||e}(Wi(e))))(e)}function Lu(e){if(r(e)){const t=nc(e);return t&&t.branding===ea?t:function(e){const t=Vr(e,zi);return nt(wn({...Xi,...t}))}(e)}return function(e){const t=(e=>{const t=Ia.exec(e);return t?(e=>{function t(e,t,i){let s=0,a=0;if(i&&([s,o]=S(o,wi[i])),void 0!==e){if(r)throw new RangeError(ni(e));a=(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 s+a}let n=0,r=0,o=0,i={...c(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(Io(qi));return Wn(e[1])<0&&(i=pn(i)),i})(t):void 0})(Wi(e));if(!t)throw new RangeError(ti(e));return nt(wn(t))}(e)}function Hu(e){if(void 0!==e){if(r(e)){const t=nc(e)||{};switch(t.branding){case Xs:case Js:return t;case Gs:return Xe(t)}const n=Cu(e);return{...qr(Fu,ca,Ua(n),e),calendar:n}}return function(e){const t=Nn(Wi(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 Yn(t)}(e)}}function Bu(e,t){if(r(e)){const n=nc(e)||{};switch(n.branding){case Ks:return Ye(t),n;case Gs:return Ye(t),tt(n);case Xs:return Ye(t),oo(ca,n)}return function(e,t){return tt(Jr(Vr(e,vi,[],1),Ye(t)))}(e,t)}const n=function(e){let t,n=(e=>{const t=Sa.exec(e);return t?(Hn(t[10]),Ln(t)):void 0})(Wi(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=Rn(e))&&xe(t))throw new RangeError(ti(e));if((t=Pn(e))&&xe(t))throw new RangeError(ti(e));return tt(je(n,1))}(e);return Ye(t),n}function Uu(e){return void 0===e?void 0:Bu(e)}function Wu(e,t){if(r(e)){const n=nc(e)||{};switch(n.branding){case Gs:return Ye(t),n;case Js:return Ye(t),Ke({...n,...as});case Xs:return Ye(t),no(ca,n)}return function(e,t,n){const r=zr(e,t,Ci,[],yi),o=Ye(n);return Ke(oe({...e.F(r,$e(o)),...Jr(r,o)}))}(Ua(Cu(e)),e,t)}const n=function(e){const t=Nn(Wi(e));if(!t||t.j)throw new RangeError(ti(e));return Ke(jn(t))}(e);return Ye(t),n}function Zu(e,t){if(r(e)){const n=nc(e);if(n&&n.branding===Vs)return Ye(t),n;const r=Nu(e);return function(e,t,n,r){const o=zr(e,n,Ci,Oi);return t&&void 0!==o.month&&void 0===o.monthCode&&void 0===o.year&&(o.year=ws),e._(o,r)}(Ua(r||Ai),!r,e,t)}const n=function(e,t){const n=Pn(Wi(t));if(n)return xn(n),et(_e(n));const r=_n(t,0,1),{calendar:o}=r,i=e(o),[s,a,u]=i.v(r),[c,l]=i.q(s,a),[f,d]=i.G(c,l,u);return et(re(i.V(f,d,u)),o)}(Ua,e);return Ye(t),n}function $u(e,t){if(r(e)){const n=nc(e);return n&&n.branding===zs?(Ye(t),n):function(e,t,n,r){const o=zr(e,t,ji,r);return e.K(o,n)}(Ua(Cu(e)),e,t)}const n=function(e,t){const n=Rn(Wi(t));if(n)return xn(n),Qe(ne(_e(n)));const r=_n(t,1);return Qe(on(e(r.calendar),r))}(Ua,e);return Ye(t),n}function qu(e,t){if(r(e)){const n=nc(e)||{};switch(n.branding){case Js:return Ye(t),n;case Gs:return Ye(t),Xe(n);case Xs:return Ye(t),ro(ca,n)}return function(e,t,n,r=[]){const o=zr(e,t,Ci,r);return e.F(o,n)}(Ua(Cu(e)),e,t)}const n=_n(e);return Ye(t),n}function zu(e,t){if(r(e)){const n=nc(e);if(n&&n.branding===Xs)return Ce(t),n;const r=Cu(e);return function(e,t,n,r,o,i){const s=zr(n,o,Ci,Mi,ki),a=e(s.timeZone),[u,c,l]=Ce(i),f=n.F(s,$e(u)),d=Jr(s,u);return Ge(qt(t(a),{...f,...d},void 0!==s.offset?Tn(s.offset):void 0,c,l),a,r)}(Fu,ca,Ua(r),r,e,t)}return function(e,t){const n=Nn(Wi(e));if(!n||!n.timeZone)throw new RangeError(ti(e));const{offset:r}=n,o=r?Tn(r):void 0,[,i,s]=Ce(t);return On(n,o,i,s)}(e,t)}function Vu(e){return l(e=>t=>e(Ju(t)),e)}function Ju(e){return aa(e,ca)}function Gu(e){if(r(e)){const t=nc(e);if(t)switch(t.branding){case Qs:return t;case Xs: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 Ku(){function e(e,n){return new t(e,n)}function t(e,t=Object.create(null)){Uc.set(this,((e,t)=>{const n=new gs(e,t),r=n.resolvedOptions(),i=r.locale,s=h(Object.keys(t),r),a=o(ec),u=(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=>nc(e)||Number(e));let o,u=0;for(const e of r){const t="object"==typeof e?e.branding:void 0;if(u++&&t!==o)throw new TypeError(ri);o=t}return o?a(o)(i,s,...r):[n,...r]};return u.X=n,u})(e,t))}const n=gs.prototype,r=Object.getOwnPropertyDescriptors(n),s=Object.getOwnPropertyDescriptors(gs);for(const t in r){const n=r[t],o=t.startsWith("format")&&Xu(t);"function"==typeof n.value?n.value="constructor"===t?e:o||Qu(t):o&&(n.get=function(){if(!Uc.has(this))throw new TypeError(_o);return(...e)=>o.apply(this,e)},Object.defineProperties(n.get,i(`get ${t}`)))}return s.prototype.value=t.prototype=Object.create({},r),Object.defineProperties(e,s),e}function Xu(e){return Object.defineProperties(function(...t){const n=Uc.get(this),[r,...o]=n(e.includes("Range"),...t);return r[e](...o)},i(e))}function Qu(e){return Object.defineProperties(function(...t){return Uc.get(this).X[e](...t)},i(e))}function ec(e){const t=bc[e];if(!t)throw new TypeError((e=>`Cannot format ${e}`)(e));return so(t,o(ao),1)}const tc=new WeakMap,nc=tc.get.bind(tc),rc=tc.set.bind(tc),oc={era:function(e){if(void 0!==e)return Wi(e)},eraYear:j,year:C,month:Y,daysInMonth:Y,daysInYear:Y,inLeapYear:Zi,monthsInYear:Y},ic={monthCode:Wi},sc={day:Y},ac={dayOfWeek:Y,dayOfYear:Y,weekOfYear:function(e){if(void 0!==e)return Y(e)},yearOfWeek:j,daysInWeek:Y},uc=Pu(Object.assign({},oc,ic,sc,ac)),cc=Pu({...oc,...ic}),lc=Pu({...ic,...sc}),fc={calendarId:e=>e.calendar},dc=f(e=>t=>t[e],qi.concat("sign")),hc=f((e,t)=>e=>e[ts[t]],yi),mc={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)}},[gc,pc]=ju(ea,function(e=0,t=0,n=0,r=0,o=0,i=0,s=0,a=0,u=0,f=0){return nt(wn(l(Z,c(qi,[e,t,n,r,o,i,s,a,u,f]))))},{...dc,blank:function(e){return!e.sign}},{with:(e,t)=>pc(function(e,t){return nt((n=e,r=t,wn({...n,...Vr(r,zi)})));var n,r}(e,t)),negated:e=>pc(gn(e)),abs:e=>pc(function(e){return-1===e.sign?gn(e):e}(e)),add:(e,t,n)=>pc(mn(Hu,Ua,ca,0,e,Lu(t),n)),subtract:(e,t,n)=>pc(mn(Hu,Ua,ca,1,e,Lu(t),n)),round:(e,t)=>pc(function(e,t,n,r,o){const i=kn(r),[s,a,u,c,l]=((e,t,n)=>{e=Ze(e,Ms);let r=Fs(e);const o=n(e[Is]);let i=He(e);const s=qs(e,7);let a=As(e);if(void 0===r&&void 0===a)throw new RangeError(Qo);if(null==a&&(a=0),null==r&&(r=Math.max(a,t)),Ve(r,a),i=Be(i,a,1),i>1&&a>5&&r!==a)throw new RangeError("For calendar units with roundingIncrement > 1, use largestUnit = smallestUnit");return[r,a,i,s,o]})(o,i,e),f=Math.max(i,s);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,s,a,u,c)));if(!dn(l)&&!r.sign)return r;if(!l)throw new RangeError(Ko);const[d,h,m]=un(t,n,l),g=cn(m),p=ln(m),b=fn(m),w=p(h,d,r);dn(l)||(oe(d),oe(w));let y=b(h,d,w,s);const v=r.sign,E=bn(y);if(v&&E&&v!==E)throw new RangeError(Fo);return y=pt(y,g(w),s,a,u,c,h,d,g,p),nt(y)}(Hu,Ua,ca,e,t)),total:(e,t)=>function(e,t,n,r,o){const i=kn(r),[s,a]=((e,t)=>{const n=t((e=Ze(e,Ss))[Is]);let r=Ls(e);return r=N(Ss,r),[r,n]})(o,e),u=Math.max(s,i);if(!a&&hn(u,a))return it(r,s);if(!a)throw new RangeError(Ko);if(!r.sign)return 0;const[c,l,f]=un(t,n,a),d=cn(f),h=ln(f),m=fn(f),g=h(l,c,r);dn(a)||(oe(c),oe(g));const p=m(l,c,g,s);return hn(s,a)?it(p,s):((e,t,n,r,o,i,s)=>{const a=bn(e),[u,c]=st(r,es(n,e),n,a,o,i,s),l=at(t,u,c);return e[qi[n]]+l*a})(p,d(g),s,l,c,d,h)}(Hu,Ua,ca,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:Au},{from:e=>pc(Lu(e)),compare:(e,t,n)=>function(e,t,n,r,o,i){const s=e(We(i).relativeTo),a=Math.max(kn(r),kn(o));if(g(qi,r,o))return 0;if(hn(a,s))return G(vn(r),vn(o));if(!s)throw new RangeError(Ko);const[u,c,l]=un(t,n,s),f=cn(l),d=ln(l);return G(f(d(c,u,r)),f(d(c,u,o)))}(Hu,Ua,ca,Lu(e),Lu(t),n)}),bc={Instant:Su,PlainDateTime:Du,PlainDate:Iu,PlainTime:Tu,PlainYearMonth:_u,PlainMonthDay:xu},wc=so(Su),yc=so(ku),vc=so(Du),Ec=so(Iu),Mc=so(Tu),Sc=so(_u),kc=so(xu),[Dc,Ic]=ju(Ks,function(e=0,t=0,n=0,r=0,o=0,i=0){return tt(je(l(W,c(ts,[e,t,n,r,o,i])),1))},hc,{with(e,t,n){return Ic(function(e,t,n){return tt(((e,t,n)=>Jr({...h(vi,e),...Vr(t,vi)},Ye(n)))(e,t,n))}(this,Yu(t),n))},add:(e,t)=>Ic(en(0,e,Lu(t))),subtract:(e,t)=>Ic(en(1,e,Lu(t))),until:(e,t,n)=>pc(sr(0,e,Bu(t),n)),since:(e,t,n)=>pc(sr(1,e,Bu(t),n)),round:(e,t)=>Ic(function(e,t){const[n,r,o]=Re(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,Bu(t)),toLocaleString(e,t,n){const[r,o]=Mc(t,n,e);return r.format(o)},toString:Ot,toJSON:e=>Ot(e),valueOf:Au},{from:(e,t)=>Ic(Bu(e,t)),compare:(e,t)=>Xn(Bu(e),Bu(t))}),[Tc,_c]=ju(Gs,b(function(e,t,n,r,o=0,i=0,s=0,a=0,u=0,f=0,d=Ai){return Ke(oe(Te(l(W,c(rs,[t,n,r,o,i,s,a,u,f])))),e(d))},Ur),{...fc,...uc,...hc},{with:(e,t,n)=>_c(function(e,t,n,r){const o=e(t.calendar),i=[...o.fields(Ci),...yi].sort(),s={...to(a=t),hour:a.isoHour,minute:a.isoMinute,second:a.isoSecond,millisecond:a.isoMillisecond,microsecond:a.isoMicrosecond,nanosecond:a.isoNanosecond};var a;const u=Vr(n,i),c=Ye(r),l=o.k(s,u),f={...s,...u};return Ke(oe({...o.F(l,$e(c)),...je(Za(f),c)}))}(Ua,e,Yu(t),n)),withCalendar:(e,t)=>_c(co(e,Ru(t))),withPlainTime:(e,t)=>_c(function(e,t=as){return Ke(oe({...e,...t}))}(e,Uu(t))),add:(e,t,n)=>_c(Kt(Ua,0,e,Lu(t),n)),subtract:(e,t,n)=>_c(Kt(Ua,1,e,Lu(t),n)),until:(e,t,n)=>pc(nr(Ua,0,e,Wu(t),n)),since:(e,t,n)=>pc(nr(Ua,1,e,Wu(t),n)),round:(e,t)=>_c(function(e,t){return Ke(ut(e,...Re(t)),e.calendar)}(e,t)),equals:(e,t)=>function(e,t){return!Gn(e,t)&&e.calendar===t.calendar}(e,Wu(t)),toZonedDateTime:(e,t,n)=>Pc(function(e,t,n,r){const o=((e,t,n,r)=>{const o=(e=>Bs(We(e)))(r);return zt(e(t),n,o)})(e,n,t,r);return Ge(ie(o),n,t.calendar)}(ca,e,Fu(t),n)),toPlainDate:e=>Nc(Xe(e)),toPlainTime:e=>Ic(tt(e)),toLocaleString(e,t,n){const[r,o]=vc(t,n,e);return r.format(o)},toString:It,toJSON:e=>It(e),valueOf:Au},{from:(e,t)=>_c(Wu(e,t)),compare:(e,t)=>Gn(Wu(e),Wu(t))}),[xc,Oc]=ju(Vs,b(function(e,t,n,r=Ai,o=ws){const i=W(t),s=W(n),a=e(r);return et(re(_e({isoYear:W(o),isoMonth:i,isoDay:s})),a)},Ur),{...fc,...lc},{with:(e,t,n)=>Oc(function(e,t,n,r){const o=e(t.calendar),i=o.fields(Ci).sort(),s=(e=>{const t=Ba(e.calendar),[n,r,o]=t.v(e),[i,s]=t.q(n,r);return{monthCode:Er(i,s),day:o}})(t),a=Vr(n,i),u=o.k(s,a);return o._(u,r)}(Ua,e,Yu(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,Zu(t)),toPlainDate(e,t){return Nc(function(e,t,n,r){return((e,t,n)=>Gr(e,t,Ri,R(n),Ti))(e(t.calendar),n,r)}(Ua,e,this,t))},toLocaleString(e,t,n){const[r,o]=kc(t,n,e);return r.format(o)},toString:xt,toJSON:e=>xt(e),valueOf:Au},{from:(e,t)=>Oc(Zu(e,t))}),[jc,Yc]=ju(zs,b(function(e,t,n,r=Ai,o=1){const i=W(t),s=W(n),a=e(r);return Qe(ne(_e({isoYear:i,isoMonth:s,isoDay:W(o)})),a)},Ur),{...fc,...cc},{with:(e,t,n)=>Yc(function(e,t,n,r){const o=e(t.calendar),i=o.fields(ji).sort(),s=(e=>{const t=Ba(e.calendar),[n,r]=t.v(e),[o,i]=t.q(n,r);return{year:n,monthCode:Er(o,i)}})(t),a=Vr(n,i),u=o.k(s,a);return o.K(u,r)}(Ua,e,Yu(t),n)),add:(e,t,n)=>Yc(Qt(Ua,0,e,Lu(t),n)),subtract:(e,t,n)=>Yc(Qt(Ua,1,e,Lu(t),n)),until:(e,t,n)=>pc(or(Ua,0,e,$u(t),n)),since:(e,t,n)=>pc(or(Ua,1,e,$u(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,$u(t)),toPlainDate(e,t){return Nc(function(e,t,n,r){return((e,t,n)=>Gr(e,t,Yi,R(n),Oi))(e(t.calendar),n,r)}(Ua,e,this,t))},toLocaleString(e,t,n){const[r,o]=Sc(t,n,e);return r.format(o)},toString:_t,toJSON:e=>_t(e),valueOf:Au},{from:(e,t)=>Yc($u(e,t)),compare:(e,t)=>Kn($u(e),$u(t))}),[Cc,Nc]=ju(Js,b(function(e,t,n,r,o=Ai){return Xe(re(_e(l(W,{isoYear:t,isoMonth:n,isoDay:r}))),e(o))},Ur),{...fc,...uc},{with:(e,t,n)=>Nc(function(e,t,n,r){const o=e(t.calendar),i=o.fields(Ci).sort(),s=to(t),a=Vr(n,i),u=o.k(s,a);return o.F(u,r)}(Ua,e,Yu(t),n)),withCalendar:(e,t)=>Nc(co(e,Ru(t))),add:(e,t,n)=>Nc(Xt(Ua,0,e,Lu(t),n)),subtract:(e,t,n)=>Nc(Xt(Ua,1,e,Lu(t),n)),until:(e,t,n)=>pc(rr(Ua,0,e,qu(t),n)),since:(e,t,n)=>pc(rr(Ua,1,e,qu(t),n)),equals:(e,t)=>function(e,t){return!Kn(e,t)&&e.calendar===t.calendar}(e,qu(t)),toZonedDateTime(e,t){const n=r(t)?t:{timeZone:t};return Pc(function(e,t,n,r,o){const i=e(o.timeZone),s=o.plainTime,a=void 0!==s?t(s):void 0,u=n(i);let c;return c=a?zt(u,{...r,...a}):Vt(u,{...r,...as}),Ge(c,i,r.calendar)}(Fu,Bu,ca,e,n))},toPlainDateTime:(e,t)=>_c(function(e,t=as){return Ke(oe({...e,...t}))}(e,Uu(t))),toPlainYearMonth(e){return Yc(function(e,t,n){return((e,t)=>{const n=zr(e,t,Yi);return e.K(n,void 0)})(e(t.calendar),n)}(Ua,e,this))},toPlainMonthDay(e){return Oc(function(e,t,n){return((e,t)=>{const n=zr(e,t,Ri);return e._(n)})(e(t.calendar),n)}(Ua,e,this))},toLocaleString(e,t,n){const[r,o]=Ec(t,n,e);return r.format(o)},toString:Tt,toJSON:e=>Tt(e),valueOf:Au},{from:(e,t)=>Nc(qu(e,t)),compare:(e,t)=>Kn(qu(e),qu(t))}),[Rc,Pc]=ju(Xs,b(function(e,t,n,r,o=Ai){return Ge(ie(X(B(n))),t(r),e(o))},Ur,function(e){return $n(Wi(e))}),{...mc,...fc,...Vu(uc),...Vu(hc),offset:e=>Lt(Ju(e).offsetNanoseconds),offsetNanoseconds:e=>Ju(e).offsetNanoseconds,timeZoneId:e=>e.timeZone,hoursInDay:e=>function(e,t){const n=e(t.timeZone),r=aa(t,n),[o,i]=ht(r),s=ee(J(Vt(n,o),Vt(n,i)),pi,1);if(s<=0)throw new RangeError(Fo);return s}(ca,e)},{with:(e,t,n)=>Pc(function(e,t,n,r,o){const{calendar:i,timeZone:s}=n,a=e(i),u=t(s),c=[...a.fields(Ci),...Si].sort(),l=(e=>{const t=aa(e,ca),n=Lt(t.offsetNanoseconds),r=Ba(e.calendar),[o,i,s]=r.v(t),[a,u]=r.q(o,i),c=Er(a,u);return{...$a(t),year:o,monthCode:c,day:s,offset:n}})(n),f=Vr(r,c),d=a.k(l,f),h={...l,...f},[m,g,p]=Ce(o,2);return Ge(qt(u,{...a.F(d,$e(m)),...je(Za(h),m)},Tn(h.offset),g,p),s,i)}(Ua,ca,e,Yu(t),n)),withCalendar:(e,t)=>Pc(co(e,Ru(t))),withTimeZone:(e,t)=>Pc(function(e,t){return{...e,timeZone:t}}(e,Fu(t))),withPlainTime:(e,t)=>Pc(function(e,t,n){const r=t.timeZone,o=e(r),i={...aa(t,o),...n||as};let s;return s=n?qt(o,i,i.offsetNanoseconds,2):Vt(o,i),Ge(s,r,t.calendar)}(ca,e,Uu(t))),add:(e,t,n)=>Pc(Gt(Ua,ca,0,e,Lu(t),n)),subtract:(e,t,n)=>Pc(Gt(Ua,ca,1,e,Lu(t),n)),until:(e,t,n)=>pc(nt(tr(Ua,ca,0,e,zu(t),n))),since:(e,t,n)=>pc(nt(tr(Ua,ca,1,e,zu(t),n))),round:(e,t)=>Pc(function(e,t,n){let{epochNanoseconds:r,timeZone:o,calendar:i}=t;const[s,a,u]=Re(n);if(0===s&&1===a)return t;const c=e(o);if(6===s)r=((e,t,n,r)=>{const o=aa(n,t),[i,s]=e(o),a=n.epochNanoseconds,u=Vt(t,i),c=Vt(t,s);if(K(a,u,c))throw new RangeError(Fo);return vt(at(a,u,c),r)?c:u})(ht,c,t,u);else{const e=c.R(r);r=qt(c,ut(ge(r,e),s,a,u),e,2,0,1)}return Ge(r,o,i)}(ca,e,t)),startOfDay:e=>Pc(function(e,t){const{timeZone:n,calendar:r}=t,o=((e,t,n)=>Vt(t,e(aa(n,t))))(mt,e(n),t);return Ge(o,n,r)}(ca,e)),equals:(e,t)=>function(e,t){return!Jn(e,t)&&!!Qn(e.timeZone,t.timeZone)&&e.calendar===t.calendar}(e,zu(t)),toInstant:e=>Fc(function(e){return Je(e.epochNanoseconds)}(e)),toPlainDateTime:e=>_c(no(ca,e)),toPlainDate:e=>Nc(ro(ca,e)),toPlainTime:e=>Ic(oo(ca,e)),toLocaleString(e,t,n={}){const[r,o]=yc(t,n,e);return r.format(o)},toString:(e,t)=>Dt(ca,e,t),toJSON:e=>Dt(ca,e),valueOf:Au,getTimeZoneTransition(e,t){const{timeZone:n,epochNanoseconds:r}=e,o=function(e){const t=Ze(e,Ts),n=ze(Ts,Ps,t,0);if(!n)throw new RangeError(Mo(Ts,n));return n}(t),i=ca(n).O(r,o);return i?Pc({...e,epochNanoseconds:i}):null}},{from:(e,t)=>Pc(zu(e,t)),compare:(e,t)=>Jn(zu(e),zu(t))}),[Ac,Fc]=ju(Qs,function(e){return Je(ie(X(B(e))))},mc,{add:(e,t)=>Fc(Jt(0,e,Lu(t))),subtract:(e,t)=>Fc(Jt(1,e,Lu(t))),until:(e,t,n)=>pc(er(0,e,Gu(t),n)),since:(e,t,n)=>pc(er(1,e,Gu(t),n)),round:(e,t)=>Fc(function(e,t){const[n,r,o]=Re(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,Gu(t)),toZonedDateTimeISO:(e,t)=>Pc(function(e,t,n=Ai){return Ge(e.epochNanoseconds,t,n)}(e,Fu(t))),toLocaleString(e,t,n){const[r,o]=wc(t,n,e);return r.format(o)},toString:(e,t)=>kt(Fu,ca,e,t),toJSON:e=>kt(Fu,ca,e),valueOf:Au},{from:e=>Fc(Gu(e)),fromEpochMilliseconds:e=>Fc(function(e){return Je(ie(Q(Z(e),hi)))}(e)),fromEpochNanoseconds:e=>Fc(function(e){return Je(ie(X(B(e))))}(e)),compare:(e,t)=>Vn(Gu(e),Gu(t))}),Lc=Object.defineProperties({},{...u("Temporal.Now"),...s({timeZoneId:()=>ho(),instant:()=>Fc(Je(fo())),zonedDateTimeISO:(e=ho())=>Pc(Ge(fo(),Fu(e),Ai)),plainDateTimeISO:(e=ho())=>_c(Ke(lo(ca(Fu(e))),Ai)),plainDateISO:(e=ho())=>Nc(Xe(lo(ca(Fu(e))),Ai)),plainTimeISO:(e=ho())=>Ic(tt(lo(ca(Fu(e)))))})}),Hc=Object.defineProperties({},{...u("Temporal"),...s({PlainYearMonth:jc,PlainMonthDay:xc,PlainDate:Cc,PlainTime:Dc,PlainDateTime:Tc,ZonedDateTime:Rc,Instant:Ac,Duration:gc,Now:Lc})}),Bc=Ku(),Uc=new WeakMap;function Wc(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),s({DateTimeFormat:Bc});var Zc={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}},$c={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},qc=function(e,t,n,r){return new(n||(n=Promise))(function(o,i){function s(e){try{u(r.next(e))}catch(e){i(e)}}function a(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(s,a)}u((r=r.apply(e,t||[])).next())})};class zc extends Error{constructor(e){super(e||"Request canceled"),this.name="Cancel",this.__BBN_CANCEL__=!0}}const Vc=["POST","PUT","PATCH","DELETE"],Jc=(e,t,n={},r)=>{const o=new XMLHttpRequest,i=Vc.includes(e.toUpperCase()),s=new Promise((r,s)=>{o.open(e,t,!0);const{body:a,headers:u}=((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);u.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 a=o.responseText;if((e["content-type"]||"").includes("application/json"))try{a=JSON.parse(o.responseText)}catch(e){}const u={data:a,status:t,statusText:i,headers:e,config:n,request:o};if(t>=200&&t<300)r(u);else{const e=new Error("Request failed with status code "+t);e.response=u,e.config=n,e.request=o,s(e)}},o.onerror=()=>{const e=new Error("Network Error");e.config=n,e.request=o,s(e)},o.onabort=()=>{s(new zc("Request canceled"))},i?o.send(a):o.send()});return s.cancel=()=>o.abort(),s};var Gc={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&&Vc.includes(e.toUpperCase())?Jc(e,t,n):((e,t,n={},r)=>{const o={method:e,headers:new Headers(n.headers||{}),signal:null==r?void 0:r.signal},i=Vc.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 s=fetch(t,o).then(e=>qc(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 zc("Request canceled");throw e});return s.cancel=()=>r.abort(),s})(e,t,n,r)}};function Kc(...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 Xc(...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 Qc(...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 s=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),s.apply(window.console,o),n++}}}return this}function rl(e,t,n){if(!Qc(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 sl(e,t){if(!(Kc(e)&&e>0)){if(Xc(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 al(...e){if(!e.length)return!1;for(let t of e)if("[object Object]"!=={}.toString.apply(t))return!1;return!0}function ul(...e){if(!e.length)return!1;for(let t of e)if(!Array.isArray(t))return!1;return!0}function cl(...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?ul(e)?(o[n]=ul(o[n])?o[n]:[],sl(e,(e,t)=>{if(e&&"object"==typeof e){let r=o[n][t];ul(e)?ul(r)||(r=[]):al(r)||(r={}),o[n][t]=cl(!0,r,e)}else o[n][t]=e})):al(e)?o[n]=cl(!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 s=t.length;sl(t,e=>{const t=o.put(e);t.onerror=()=>{nl(t.error),s--}}),r.oncomplete=()=>{n(s)}})),this.update=(e,t,r,s)=>new Promise(a=>{this.selectAll(e,[],r).then(r=>{if(!r.length)return void a(0);const[u,c]=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=cl({},s?{[f]:r[e][f]}:r[e],t);if(!n[f])throw new Error(Wc("No primary key in the data"));const i=c.put(n);o(i,a),i.onsuccess=()=>{d++}}u.oncomplete=()=>{a(d)}})}),this.delete=(e,t)=>new Promise(r=>{const[s,a]=i(e,"w"),u=n[e],c=u.keys.PRIMARY.columns.length>1?u.keys.PRIMARY.columns:u.keys.PRIMARY.columns[0];if(!t[c])throw new Error(Wc("No "));const l=a.delete(t[c]);o(l,r),s.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,s=null,a=0,u=null)=>new Promise(s=>{const[c,l]=i(e,"r"),f=n[e],d=f.keys.PRIMARY.columns.length>1?f.keys.PRIMARY.columns:f.keys.PRIMARY.columns[0],h=al(r)?Object.keys(r)[0]:!r||ul(r)?null:d,m=[];if(h===d)if(bbn.fn.isArray(null==r?void 0:r[d])){const e=Math.min(r[d].length,u||9999999);for(let n=a||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&&s(m)},o(i,s)}}else{let e=l.get((null==r?void 0:r[d])||r);e.onsuccess=()=>{let n=e.result;m.push(fl(n,t)),s(m)},o(e,s)}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>=a&&(m.push(fl(o.value,t)),m.length===u&&s(m)),n++),o.continue()):s(m)},o(e,s)}}),this.getColumnValues=(e,n,r,o,i,s)=>new Promise(n=>{t.transaction([e],"read").objectStore(e)}),this.copyTable=(r,o,i=[],s=null,a=null,u=0,c=null)=>new Promise(l=>{if(t.objectStoreNames.contains(r)||hl.add(e,r,n[o]),!t.objectStoreNames.contains(r))throw l(0),new Error(Wc("The target table %s does not exist",r));this.selectAll(o,i,s,a,u,c).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(Wc("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(Wc("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 gl(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 pl(e){if(!Qc(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=gl(e,n),i=gl(t,n),s=(typeof o).toLowerCase(),a=(typeof i).toLowerCase();if("asc"!==r&&Qc(r)&&"desc"===r.toLowerCase()&&(r="desc"),s!==a)o=s,i=a;else switch(s){case"string":o=pl(o).toLowerCase(),i=pl(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||(ul(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 Sl(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 kl(e){return Ml(e).padStart(8,"0")+Sl(e).padStart(8,"0")}function Dl(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof HTMLElement))return!1;return!0}function Il(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,s=Array.from(i.children).filter(t=>t.tagName===e.tagName);if(!o&&s.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)||Dl(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 s=0;s<e.length;s++)i+="__BBN_ITEM"+s.toString()+"__"+o(e[s],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 s in e){let a=s;"string"!=typeof a&&(a=o(a,o,1,1)),i+="__BBN_PROP_"+a+"__"+o(e[s],t,n+1,r,o)}e="__BBN_OBJECT__"+i}}else e=Dl(e)?Tl(e)?"__BBN_CP__"+e.$cid:e.bbnId?"__BBN_DOM__"+e.tagName+"/"+e.bbnId+e.bbnHash:"__BBN_DOM__"+Il(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 kl(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,s){return r(function(e,t){return e<<t|e>>>32-t}(r(r(t,e),r(o,s)),i),n)}function i(e,t,n,r,i,s,a){return o(t&n|~t&r,e,t,i,s,a)}function s(e,t,n,r,i,s,a){return o(t&r|n&~r,e,t,i,s,a)}function a(e,t,n,r,i,s,a){return o(t^n^r,e,t,i,s,a)}function u(e,t,n,r,i,s,a){return o(n^(t|~r),e,t,i,s,a)}var c,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),g=1732584193,p=-271733879,b=-1732584194,w=271733878;for(c=0;c<m.length;c+=16)l=g,f=p,d=b,h=w,g=i(g,p,b,w,m[c+0],7,-680876936),w=i(w,g,p,b,m[c+1],12,-389564586),b=i(b,w,g,p,m[c+2],17,606105819),p=i(p,b,w,g,m[c+3],22,-1044525330),g=i(g,p,b,w,m[c+4],7,-176418897),w=i(w,g,p,b,m[c+5],12,1200080426),b=i(b,w,g,p,m[c+6],17,-1473231341),p=i(p,b,w,g,m[c+7],22,-45705983),g=i(g,p,b,w,m[c+8],7,1770035416),w=i(w,g,p,b,m[c+9],12,-1958414417),b=i(b,w,g,p,m[c+10],17,-42063),p=i(p,b,w,g,m[c+11],22,-1990404162),g=i(g,p,b,w,m[c+12],7,1804603682),w=i(w,g,p,b,m[c+13],12,-40341101),b=i(b,w,g,p,m[c+14],17,-1502002290),g=s(g,p=i(p,b,w,g,m[c+15],22,1236535329),b,w,m[c+1],5,-165796510),w=s(w,g,p,b,m[c+6],9,-1069501632),b=s(b,w,g,p,m[c+11],14,643717713),p=s(p,b,w,g,m[c+0],20,-373897302),g=s(g,p,b,w,m[c+5],5,-701558691),w=s(w,g,p,b,m[c+10],9,38016083),b=s(b,w,g,p,m[c+15],14,-660478335),p=s(p,b,w,g,m[c+4],20,-405537848),g=s(g,p,b,w,m[c+9],5,568446438),w=s(w,g,p,b,m[c+14],9,-1019803690),b=s(b,w,g,p,m[c+3],14,-187363961),p=s(p,b,w,g,m[c+8],20,1163531501),g=s(g,p,b,w,m[c+13],5,-1444681467),w=s(w,g,p,b,m[c+2],9,-51403784),b=s(b,w,g,p,m[c+7],14,1735328473),g=a(g,p=s(p,b,w,g,m[c+12],20,-1926607734),b,w,m[c+5],4,-378558),w=a(w,g,p,b,m[c+8],11,-2022574463),b=a(b,w,g,p,m[c+11],16,1839030562),p=a(p,b,w,g,m[c+14],23,-35309556),g=a(g,p,b,w,m[c+1],4,-1530992060),w=a(w,g,p,b,m[c+4],11,1272893353),b=a(b,w,g,p,m[c+7],16,-155497632),p=a(p,b,w,g,m[c+10],23,-1094730640),g=a(g,p,b,w,m[c+13],4,681279174),w=a(w,g,p,b,m[c+0],11,-358537222),b=a(b,w,g,p,m[c+3],16,-722521979),p=a(p,b,w,g,m[c+6],23,76029189),g=a(g,p,b,w,m[c+9],4,-640364487),w=a(w,g,p,b,m[c+12],11,-421815835),b=a(b,w,g,p,m[c+15],16,530742520),g=u(g,p=a(p,b,w,g,m[c+2],23,-995338651),b,w,m[c+0],6,-198630844),w=u(w,g,p,b,m[c+7],10,1126891415),b=u(b,w,g,p,m[c+14],15,-1416354905),p=u(p,b,w,g,m[c+5],21,-57434055),g=u(g,p,b,w,m[c+12],6,1700485571),w=u(w,g,p,b,m[c+3],10,-1894986606),b=u(b,w,g,p,m[c+10],15,-1051523),p=u(p,b,w,g,m[c+1],21,-2054922799),g=u(g,p,b,w,m[c+8],6,1873313359),w=u(w,g,p,b,m[c+15],10,-30611744),b=u(b,w,g,p,m[c+6],15,-1560198380),p=u(p,b,w,g,m[c+13],21,1309151649),g=u(g,p,b,w,m[c+4],6,-145523070),w=u(w,g,p,b,m[c+11],10,-1120210379),b=u(b,w,g,p,m[c+2],15,718787259),p=u(p,b,w,g,m[c+9],21,-343485551),g=r(g,l),p=r(p,f),b=r(b,d),w=r(w,h);return n(g)+n(p)+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,s=!1,a="",u=0,c=0,l=[],f={},d="",h=['"',"'","`"],m=!1,g=!1,p=!1,b=!1,w=!1,y=!1,v="";for(let e=0;e<t.length;e++)if(p||"/"!==t[e]||"*"!==t[e+1])if("/"===t[e]&&"*"===t[e-1])p=!1;else if(b||"/"!==t[e]||"/"!==t[e+1])if("\n"===t[e])b=!1;else{if(p||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(u++,""!==r.trim()){if("function"===r.trim())s=!0;else if("async"!==r.trim()){a=r.trim();let e=a.match(/^([a-zA-Z0-9_]+)<[a-zA-Z0-9_]+>$/);e&&(a=e[1])}r=""}}else if(")"===t[e])u===c+1&&(g?(f.default=r.trim(),g=!1):r&&(f.name=r.trim()),(f.name||f.default)&&(l.push(f),f={}),r=""),c++;else if(w&&"}"!==t[e])r+=t[e];else{if(u&&u===c&&":"===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]||u!==c||c||o)){f.name=t.slice(0,e).trim(),l.push(f),f={},o=!0,n=bbn.fn.substr(t,e+2).trim();break}if(u===c&&"="===t[e]&&">"===t[e+1]){""!==r.trim()&&(f.name=r.trim(),l.push(f),f={},r=""),o=!0,e++;continue}if("="===t[e]&&u>c&&!g)f.name=r.trim(),r="",g=!0;else if(","===t[e])if(w)r+=t[e];else{if(!(u>c))throw Error("Unexpected ',' while parsing function");g?(f.default=r.trim(),g=!1):r&&(f.name=r.trim()),(f.name||f.default)&&(l.push(f),f={}),r=""}else if("{"===t[e]||"}"===t[e]){if(u===c){n=t.substring(e).trim();break}u>c?"{"!==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),u>c?r+=t[e]:r=""):r+=t[e]}}}else b=!0,r="";else p=!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:s,name:a,isAsync:i,isBinary:y,hash:Ol(n+(a?"-"+a:"")+(E?"-"+E:"")),returnType:v}}function Yl(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 sl(r,n=>{if(!Yl(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 Cl(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!==pl(e).toLowerCase().indexOf(pl(t).toLowerCase());case"doesnotcontain":case"donotcontain":return!(!El(e)&&!El(t))||-1===pl(e.toLowerCase()).indexOf(pl(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===pl(e).toLowerCase().indexOf(pl(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)&&pl(e).toLowerCase()===pl(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(al(e,t))return Yl(e,t);default:return e==t}}function Nl(e,t){if(!t.conditions||!t.logic||!ul(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 sl(t.conditions,r=>{let o;if(r.conditions&&ul(r.conditions))o=Nl(e,r);else if(o=Cl(gl(e,r.field),r.value,r.operator),o){let t=r.field.split("."),n=t.pop();t.length&&sl(t,t=>e=e[t]),void 0===gl(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 Rl(e,t="="){if(!al(e))throw new Error("Error in filterToCondition: filter must be an object");if(!e.conditions||!ul(e.conditions)){let n=[];il(e,(e,r)=>{al(e)&&"object"==typeof e.conditions?n.push(Rl(e)):n.push({field:r,operator:t,value:e})}),e={conditions:n}}return e.logic||(e.logic="AND"),e}function Pl(e,t,n=null,r="=",o=0,i=!1){if(!Xc(e))throw new Error(bbn._("The first argument for a search should be iterable")+" "+typeof e+" "+bbn._("given"));if(!e.length)return-1;let s,a,u=!1;if(t)if("string"==typeof t)s={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)u=!0,a=t;else if(al(t))if("field"in t&&"value"in t)s={conditions:[t],logic:"AND"};else if("conditions"in t)s=t;else{const e=[];for(let n in t)e.push({field:n,value:t[n],operator:"="});s={conditions:e,logic:"AND"}}else ul(t)&&(s={conditions:t,logic:"AND"});else u=!0,a=e=>Nl({value:e},Rl({logic:"AND",conditions:[{field:"value",operator:r||"=",value:n}]}));if(u||s){if("number"!=typeof o&&(o=i?e.length-1:0),!a){const e=Rl(s);a=t=>Nl(t,e)}if(i)for(let t=o;t>=0;t--){if(bbn.env._enumerated.push(!0),a(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),a(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,s=!1){let a=Pl(e,t,n,r,o,i);return a>-1?e[a]:t&&["object","function"].includes(typeof t)&&5 in arguments?i:s}function Fl(e,t=null,n=!1){let r=Pl(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):al(t)&&(i.success=!0)),!0}return!1}function Ll(e){let t=Pl(bbn.env.loaders,{key:e});return t>-1?bbn.env.loaders[t]:null}function Hl(e,t,n=null,r="=",o=0){if(!ul(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 s=[],a="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(!a)throw new Error("Search function error: The prop argument should be a string or an object");let u;u="function"==typeof t?t:(e,t)=>Nl(e,i);for(let t=0;t<e.length&&(bbn.env._enumerated.push(!0),!(u(e[t],t)&&(bbn.env._enumerated.pop(),s.push(e[t]),bbn.env._enumerated.push(!0),o&&s.length>=o)));t++)bbn.env._enumerated.pop();return s}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 Wl(e,t){let n=0;sl(t,t=>{t.style[e]="auto"}),sl(t,(t,r)=>{let o=t.getBoundingClientRect(),i=o[e]%1?o[e]-o[e]%1+1:o[e];i>n&&(n=i)}),sl(t,(t,r)=>{n&&(t.style[e]=n+"px")})}function Zl(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}function $l(e,t,n,r=""){return n.toString().replace(al(e)?e:new RegExp(Zl(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 s=ql(e,n,t),a=Ll(s);if(null==a?void 0:a.loader)return a.loader;bbn.env.token&&cl(n||{},{_bbn_token:bbn.env.token});const u=new AbortController;let c={responseType:t,signal:u.signal};"text"===t?c.headers={accept:"text/javascript","Content-Type":"text/javascript"}:"json"===t?c.headers={accept:"application/json","Content-Type":"application/json"}:"html"===t&&(c.headers={accept:"text/html","Content-Type":"text/html"});let l="get";al(n)&&yl(n)>0&&(c.data=n,l="post");let f=Gc.run(l,e,c).then(t=>{if(Fl(s,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=Gc.isCancel(t);if(Fl(s,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(s,f,u);return bbn.fn.defaultStartLoadingFunction(e,d,n,s),f}}const Vl=new TextDecoder;function Jl(e){return Vl.decode(e)}function Gl(e,t){if(e&&Qc(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,sf=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},af=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 uf=[{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]})}],cf=[["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);sf(this,ef,r,"f");const o=Al(cf,e=>e[0]===r);if(!o)throw new Error("Invalid unit for duration: "+r);const i=o[2];sf(this,Ql,n?e:e*i,"f")}years(e=!1){return af(this,Xl,"m",nf).call(this,"year",e)}months(e=!1){return af(this,Xl,"m",nf).call(this,"month",e)}weeks(e=!1){return af(this,Xl,"m",nf).call(this,"week",e)}days(e=!1){return af(this,Xl,"m",nf).call(this,"day",e)}hours(e=!1){return af(this,Xl,"m",nf).call(this,"hour",e)}minutes(e=!1){return af(this,Xl,"m",nf).call(this,"minute",e)}seconds(e=!1){return af(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]=af(this,Xl,"m",tf).call(this,"year");return af(this,Ql,"f")/e}asMonths(){const[,,e]=af(this,Xl,"m",tf).call(this,"month");return af(this,Ql,"f")/e}asWeeks(){const[,,e]=af(this,Xl,"m",tf).call(this,"week");return af(this,Ql,"f")/e}asDays(){const[,,e]=af(this,Xl,"m",tf).call(this,"day");return af(this,Ql,"f")/e}asHours(){const[,,e]=af(this,Xl,"m",tf).call(this,"hour");return af(this,Ql,"f")/e}asMinutes(){const[,,e]=af(this,Xl,"m",tf).call(this,"minute");return af(this,Ql,"f")/e}asSeconds(){const[,,e]=af(this,Xl,"m",tf).call(this,"second");return af(this,Ql,"f")/e}add(e,t){const n=t?df[t]||t:af(this,ef,"f"),r=Al(cf,e=>e[0]===n);if(!r)throw new Error("Invalid unit for duration: "+(null!=t?t:n));return new mf(af(this,Ql,"f")+e*r[2],af(this,ef,"f"),!0)}subtract(e,t){return this.add(-e,t)}toMilliseconds(){return af(this,Ql,"f")}}Ql=new WeakMap,ef=new WeakMap,Xl=new WeakSet,tf=function(e){const t=Al(cf,t=>t[1]===e);if(!t)throw new Error("Unit name not found: "+e);return t},nf=function(e,t){const n=cf.findIndex(([,t])=>t===e);if(-1===n)throw new Error("Unit not found: "+e);const r=cf[n][2];if(!t)return Math.floor(af(this,Ql,"f")/r);let o=af(this,Ql,"f");for(let e=0;e<n;e++){const[,,t]=cf[e];o-=Math.floor(o/t)*t}return Math.floor(o/r)};class gf{static parse(e,t,n){var r,o,i,s;"monthsLong"in hf||cl(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=[],s=[];for(let e=0;e<12;e++){const r=new Date(2020,e,1);i.push(t.format(r)),s.push(n.format(r))}const a=new Date(2020,1,2),u=[],c=[];for(let e=0;e<7;e++){const t=new Date(a.getTime()+864e5*e);u.push(r.format(t)),c.push(o.format(t))}return{monthsLong:i,monthsShort:s,weekdaysLong:u,weekdaysShort:c}})());const a={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!==(s=null==n?void 0:n.weekdaysShort)&&void 0!==s?s:hf.weekdaysShort},u={year:1970,month:1,day:1,hour:0,minute:0,second:0,ms:0},c=e=>e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),l=[{token:"YYYY",regex:"\\d{4}",apply:e=>{u.year=parseInt(e,10)}},{token:"YY",regex:"\\d{2}",apply:e=>{const t=parseInt(e,10);u.year=t>=70?1900+t:2e3+t}},{token:"Y",regex:"[+-]?\\d{1,6}",apply:e=>{u.year=parseInt(e,10)}},{token:"MMMM",regex:"[^\\d\\s]+",apply:e=>{const t=a.monthsLong.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid month name: "+e);u.month=t+1}},{token:"MMM",regex:"[^\\d\\s]+",apply:e=>{const t=a.monthsShort.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid short month name: "+e);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.day=t}},{token:"dddd",regex:"[^\\d\\s]+",apply:e=>{const t=a.weekdaysLong.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid weekday name: "+e);u.weekday=t}},{token:"ddd",regex:"[^\\d\\s]+",apply:e=>{const t=a.weekdaysShort.findIndex(t=>t.toLowerCase()===e.toLowerCase());if(-1===t)throw new Error("Invalid short weekday name: "+e);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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);u.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+=c(t[m]),m+=1)}const g=new RegExp("^"+d+"$").exec(e);if(!g)throw new Error(`Date string "${e}" does not match format "${t}"`);for(let e=1;e<g.length;e++){const t=g[e],n=h[e-1];null!=t&&n&&n(t)}const p=new Date(u.year,u.month-1,u.day,u.hour,u.minute,u.second,u.ms);if(p.getFullYear()!==u.year||p.getMonth()!==u.month-1||p.getDate()!==u.day||p.getHours()!==u.hour||p.getMinutes()!==u.minute||p.getSeconds()!==u.second||p.getMilliseconds()!==u.ms)throw new Error("Invalid date produced from components");return void 0!==u.weekday&&p.getDay(),p}static compare(e,t,n=""){var r;const o=e instanceof gf?e:new gf(e),i=t instanceof gf?t:new gf(t),s=df[n]||null;if(!s)return o.mtst<i.mtst?-1:o.mtst>i.mtst?1:0;const a=["y","m","d","h","i","s"];for(const e of a){const t=null===(r=Al(cf,t=>t[0]===e))||void 0===r?void 0:r[1],n=i[t](),a=o[t]();if(n<a)return-1;if(n>a)return 1;if(e===s)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)&&sf(this,rf,gf.parse(e,t),"f");else if(("number"===n||Kc(e)&&""!==e)&&(e<5e3&&Kc(t)?e=Array.from(arguments):e<1e10&&(e*=1e3),Array.isArray(e)||sf(this,rf,new Date(e),"f")),"string"===n){for(const t of uf){const n=e.match(t.re);if(n){const{year:e,month:r,day:o,hour:i,minute:s,second:a}=t.map(n);sf(this,rf,new Date(e,r-1,o,i,s,a,0),"f")}}if(!af(this,rf,"f"))throw new Error("Invalid date string format: "+e)}else bl(e)?sf(this,rf,e,"f"):Array.isArray(e)&&sf(this,rf,new Date(...e),"f");else sf(this,rf,new Date,"f")}parse(e,t){const n=gf.parse(e,t);return new gf(n)}matchFormat(e,t){try{return gf.parse(e,t),!0}catch(e){return!1}}toString(){return af(this,rf,"f")?this.format():""}year(e){if(af(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setFullYear(e),new gf(t)}return af(this,rf,"f").getFullYear()}}month(e){if(af(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setMonth(e-1),new gf(t)}return af(this,rf,"f").getMonth()+1}}day(e){if(af(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setDate(e),new gf(t)}return af(this,rf,"f").getDate()}}hour(e){if(af(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setHours(e),new gf(t)}return af(this,rf,"f").getHours()}}minute(e){if(af(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setMinutes(e),new gf(t)}return af(this,rf,"f").getMinutes()}}second(e){if(af(this,rf,"f")){if(0 in arguments&&void 0!==e&&!(e instanceof Event)){const t=this.copy();return t.setSeconds(e),new gf(t)}return af(this,rf,"f").getSeconds()}}weekday(e,t=!1){if(af(this,rf,"f"))return!(0 in arguments)||void 0===e||e instanceof Event?af(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(af(this,rf,"f").getTime()/1e3)}get mtst(){return af(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(af(this,rf,"f"))}get MMM(){return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],{month:"short"}).format(af(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(af(this,rf,"f"))}get ddd(){return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],{weekday:"short"}).format(af(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=(af(this,rf,"f").getTime()-t.getTime())/864e5;return String(Math.ceil((n+t.getDay()+1)/7)).padStart(2,"0")}get isValid(){return void 0!==af(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(!af(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(af(this,rf,"f"))}ftime(e=!1){if(!af(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(af(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;sl(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 gf(t)}return af(this,rf,"f")?e?af(this,rf,"f").getTime():Math.floor(af(this,rf,"f").getTime()/1e3):0}sql(e=!1){return af(this,rf,"f")?e?this.format("YYYY-MM-DD"):this.format("YYYY-MM-DD HH:II:SS"):""}inLeapYear(){if(this.isValid){const e=af(this,rf,"f").getFullYear();return e%4==0&&e%100!=0||e%400==0}return!1}daysInMonth(){if(this.isValid)switch(af(this,rf,"f").getMonth()){case 1:return af(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 gf.compare(this,e,t)}add(e,t="d"){const n=af(this,rf,"f")?new Date(af(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 gf(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(cf,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?Wc("%d %s before",r,t):r<0?Wc("%d %s after",-r,t):Wc("The same %s",t)}guessUnit(e){const t=Math.abs(e);for(const[e,n,r]of cf)if(t>=r||"second"===n)return e}diff(e,t="",n=!1){const r=e instanceof gf?e.mtst:new Date(e).getTime();let o=this.mtst-r;if(n&&(o=Math.abs(o)),!t)return o;const i=df[t],s=Al(cf,e=>e[0]===i);if(!s)throw new Error("Invalid unit for diff: "+t);const[a,u,c]=s;return Math.round(o/c)}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 s=this.copy();return s.setDate(s.getDate()+i),new gf(s)}copy(){return new Date(af(this,rf,"f").getTime())}clone(){return new gf(af(this,rf,"f")?new Date(af(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 gf(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 gf(n)}duration(e,t="s"){return new mf(e,t)}}function pf(e,t=null){return e instanceof gf?e:new gf(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 s,a="object"===(typeof t).toLowerCase();if(a&&t.prescript)try{new Function(t.prescript)()}catch(e){bf(e.message||"")}if(a&&void 0===t.url&&(t.url=e),i=n&&tl(n)?n(t,o):bbn.fn.defaultLinkFunction(t,o),o&&a&&void 0!==t.content&&("value"in o?o.value=t.content:o.innerHTML=t.content),i&&a&&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):a&&bbn.fn.defaultPostLinkFunction&&bbn.fn.defaultPostLinkFunction(t,o),i&&a&&t.postscript){new Function(t.postscript)(t.postscript)}a&&t.error&&(s=t.errorTitle||bbn.lng.server_response,bbn.fn.defaultErrorFunction(t.error,s))}else bbn.fn.defaultErrorFunction(bbn.lng.errorText,bbn.lng.error);return i}function yf(e){return e.replace(/([A-Z])/g,function(e){return"-"+e.toLowerCase()}).replace("/^./",function(e){return e.toLowerCase()})}function vf(e,t,n=!1){let r={error:!1,result:!0};if("string"==typeof t&&(t=[t]),ul(t)||(r.error=bbn._("checkProps must receive a string or an array as props argument")),al(e)||(r.error=bbn._("checkProps must receive an object as obj argument")),!r.error){let o;sl(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 Ef(e){return e.replace(/[A-z]{1}/,e=>e.toUpperCase())}function Mf(e,t,n,...r){let o=!1;ul(t)||(t=[t]);const i=[];if(sl(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(Qc(t)&&tl(bbn.fn["is"+Ef(t)])){if(bbn.fn["is"+Ef(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 Sf(e){if(ul(e))return e.slice().map(e=>"object"==typeof e?Sf(e):e);if(al(e)){return cl(!0,Object.create(Object.getPrototypeOf(e)),e)}return e}rf=new WeakMap,of=new WeakMap;const kf=(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(!ul(e))throw bbn.fn.log("NOT ARRAY",e),new Error("Error in filter: The first argument must be an array");let o={};const i=[],s="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(!s)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=Rl(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 If=[];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;If.push(t)}function Tf(...e){const t=Object.create(null);return e.length&&cl(t,...e),t}function _f(e){let t=typeof e;if(void 0===e)return new Date;if("number"===t||Kc(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 xf(e,t=""){nl(e)}function Of(e,t=null,n=null){nl(t,n)}function jf(e,t,n=null,r=null){return!0}function Yf(...e){if(!e.length)return!1;for(let t of e)if("object"==typeof t&&!El(t))return!1;return!0}let Cf=[];function Nf(e){if(Qc(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 Rf(...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&&Qc(e)){let t=e.split(".");if(t[0]&&t.length>1)return t[t.length-1].toLowerCase()}return""}function Af(...e){if(!e.length)return!1;for(let t of e)if(!(t instanceof HTMLCanvasElement))return!1;return!0}function Ff(e,t,n=null){if(Af(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=al(t)&&t.type?t.type:"octet/stream";let r=window.document.createElement("a");r.className="bbn-no";let o=null;if(Qc(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 s(e){try{u(r.next(e))}catch(e){i(e)}}function a(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(s,a)}u((r=r.apply(e,t||[])).next())})};function Hf(){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 Bf=function(e,t,n,r){return new(n||(n=Promise))(function(o,i){function s(e){try{u(r.next(e))}catch(e){i(e)}}function a(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(s,a)}u((r=r.apply(e,t||[])).next())})};function Uf(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 Wf(e){let t,n,r=e.querySelectorAll("input[name],select[name],textarea[name],button[name]"),o={};return sl(r,(e,r)=>{if(n=Uf(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 $f(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 qf(e){0!==e.indexOf("--")&&(e="--"+e);let t=getComputedStyle(document.documentElement).getPropertyValue(e);return"string"==typeof t&&(t=t.trim()),t}function zf(){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 Vf(){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 Jf(e){return Qc(e)?e.replace(/<!--[\s\S]*?-->/g,""):e}function Gf(e){let t=document.createElement("div");return t.innerHTML=e,e=t.innerText}function Kf(e){let t=document.createElement("canvas");return t.width=e.width,t.height=e.height,t.getContext("2d").drawImage(e,0,0),t}function Xf(e){let t,n,r={};if(al(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 Qf(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&&cl(i.data,e.data),e.title&&!t&&(t=e.title),r=!0),t=t?Gf(t):bbn.env.siteTitle,r?(i.reload=!0,o.replaceState(i,t,bbn.env.url)):o.pushState(i,t,bbn.env.url)}}function ed(...e){let t=Xf(e),n=1;if(!0===t)return!0;if(!t)return ed(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(Ll(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?(cl(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")),al(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)&&Qf(t.url,(n.title?n.title+" - ":"")+bbn.env.siteTitle)},t.errorFn||null)}}return!0}function td(...e){let t=Xf(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 nd(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=Wf(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),td(...t)}}function rd(){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(qf("mobile-limit"))||650,r="bbn-screen-"+(bbn.env.width<n?"small":"regular"),o=(document.body.className||"").split(" "),i=!1;sl(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 od(){return"mobile"===zf()}function id(){return"tablet"===zf()}function sd(){return od()||id()}function ad(e=!1){let t=(new Date).getTime();return e?Math.round(t/1e3):t}function ud(e){if("string"==typeof e&&e.length>0&&(0===e.indexOf("calc")||Kc(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(!Qc(t)||!bbn.var.regexp.ip.test(t))return!1;return!0}function ld(...e){if(!e.length)return!1;for(let t of e)if("[object Symbol]"!=={}.toString.apply(t))return!1;return!0}function fd(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 dd(e,t="",n=null){let r=new FormData,o=(e,t="")=>{(!n||ul(n)&&!n.includes(t))&&(e instanceof File?r.append(t,e):ul(e)?sl(e,(e,n)=>{o(e,t+"["+n+"]")}):al(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 hd(e){return"string"==typeof e?document.querySelector(e):e}function md(e,t,n,r){if("object"==typeof e&&"string"==typeof t){let o=e;const i=t.split(".");sl(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 gd(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 bd(e,t,n){return"string"==typeof e.toLowerCase()&&(t||(t=bbn.var.shortenLen),void 0!==n&&Qc(n)||(n="..."),e.length>t&&(e=rl(e,0,t)+n)),e}var wd={_addLoader:ml,_compareValues:wl,_deleteLoader:Fl,abort:function(e){let t=Ll(e);(null==t?void 0:t.aborter)&&t.aborter.abort("Operation canceled by the user.")},abortURL:function(e){sl(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){al(t)&&il(t,(t,n)=>{e.style[n]=t})},adjustHeight:function(){let e=arguments;return 1===e.length&&Xc(e[0])&&(e=e[0]),Wl("height",e)},adjustSize:Wl,adjustWidth:function(){let e=arguments;return 1===e.length&&Xc(e[0])&&(e=e[0]),Wl("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 sl(e,(e,r)=>{n.push(gl(e,t))}),n},autoExtend:function(e,t){bbn[e]||(bbn[e]={}),cl(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=pf(e);return n.isValid?n.fdate():t&&Qc(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:yf,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 vf(e,t,n).result},checkPropsDetails:vf,checkPropsOrDie:function(e,t,n=!1){let r=vf(e,t,n);if(r.error)throw new Error(r.error);return!0},checkType:Mf,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=Dl(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:Sf,colorToHex:function(e){let t=document.createElement("canvas").getContext("2d");return t.fillStyle=e,t.fillStyle},compare:Cl,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||kf(e,e.type.toString())):al(e)&&tl(e.toBlob)?e.toBlob(r=>{const o=new ClipboardItem({[r.type.toString()]:r});navigator.clipboard.write([o]).then(()=>{t||kf(e,r.type.toString()),n(!0)})}):(navigator.clipboard.writeText(e),t||kf(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||kf(e),n(!0)}n(!1)})},correctCase:Ef,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^If[255&(t^r)]}return(-1^t)>>>0},createObject:Tf,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)"+Zl(e)+"(\\{|\\s)","g").test(n[t].selectorText))return!0}return!1},data2Html:function e(t,n=""){const r=!ul(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]&&(ul(t[i])||al(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:_f,dateSQL:function(e,t){let n=pf(e);if(n)return n.format("YYYY-MM-DD"+(t?"":" HH:mm:ss"))},deepPath:function e(t,n,r,o=[]){let i;return(i=Pl(t,n,0))>-1?(o.push(i),o):(sl(t,(t,i)=>{if(ul(t[r])){let s=o.slice();s.push(i);let a=e(t[r],n,r,s);if(!1!==a)return a}}),!1)},defaultAjaxAbortFunction:xf,defaultAjaxErrorFunction:Of,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:jf,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){Mf(e,"object",bbn._("The obj must be an object in setProp")),Mf(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 s=Tf();if(!tl(t)&&!tl(n)){if(Yf(t)||Yf(n)){let e=(a=t)===(u=n)||bl(a)&&bl(u)&&a.getTime()===u.getTime()?i:void 0===a?"created":void 0===u?"deleted":"updated";if(r||e!==i){let r=Tf();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(Dl(t)||Dl(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 a=e(t[o],i,r,!0);a&&(s[o]=a)}for(let o in n){if(tl(n[o])||void 0!==t[o])continue;let i=e(void 0,n[o],r,!0);i&&(s[o]=i)}}var a,u;return!(o&&!r&&!yl(s))&&s},dirName:Nf,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(Rf(n)){let e=Pf(t),r=["php","html"];if("string"==typeof t&&("type"in n&&"text/html"!==n.type||r.includes(e)))return void Ff(t,n)}},e=>{bbn.fn.defaultAjaxErrorFunction(e)})},downloadContent:Ff,each:sl,eraseCookie:function(e){document.cookie=e+"=; Max-Age=-99999999;"},error:bf,escapeDquotes:function(e){return Qc(e)?e.replace(/"/g,'\\"'):e},escapeRegExp:Zl,escapeSquotes:function(e){return Qc(e)?e.replace(/'/g,"\\'"):e},escapeTicks:function(e){return Qc(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)),sl(Nf(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&&Qc(t)?(t.match("^(\\&|\\?)")&&(t=t.substring(1)),t=o+t):t="",n+encodeURIComponent(r)+i+t},executeSlowly:function(e,t){return Bf(this,void 0,void 0,function*(){for(let n=0;n<e.length;n++){yield Hf();let r=t(e[n],n);if(r instanceof Promise&&(r=yield r),!1===r)return!1}return!0})},extend:cl,extendOut:function e(...t){let n=null;for(let r of t){if(!al(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)al(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=pf(e),r=!1;return!0===t&&(r=!0),n.isValid?n.fdate(!1,r):t&&Qc(t)?t:""},fdatetime:function(e,t=!1){let n=pf(e);return n.isValid?n.fdate(!1,!0):t&&Qc(t)?t:""},fieldValue:Uf,fileExt:Pf,filter:Df,filterToConditions:Rl,findAll:function e(t,n,r,o=[]){let i,s=0;for(;(i=Pl(t,n,s))>-1;)o.push(t[i]),s=i+1;return sl(t,t=>{ul(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(ul(e)){let o=e.length-1;Kc(n)&&0<n&&n<=o||(n=o),(!Kc(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(ul(e)){let o=e.length-1;Kc(n)&&0<n&&n<=o||(n=o),(!Kc(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 Mf(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=pf(e);return n.isValid?n.format(t):""},formatSize:function(e,t){return Kc(e)?e+"px":Qc(e)?e:!t&&"auto"},formdata:Wf,fphone:function(e){var t;if(Kc(e)&&(e=e.toString()),Qc(e)){const n=(null===(t=bbn.var)||void 0===t?void 0:t.phoneCodes)||[];let r="",o="",i="";if(n.length&&sl(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=pf(e);return n.isValid?n.ftime():t&&Qc(t)?t:""},getAllTags:function(){return Zf(Array.prototype.map.apply(document.all,[e=>e.tagName.toLowerCase()]))},getAncestors:$f,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:qf,getDay:function(e){let t=_f(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:zf,getEventData:function(e){let t=e.dataTransfer||e.clipboardData,n=t.getData("Text"),r={raw:n,files:[],str:[]};return new Promise((o,i)=>{let s=!(t instanceof DataTransfer);if(!n&&"copy"===e.type){let e=window.getSelection();r.raw=e.toString();let t=Vf();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>"}),s=!0,o(r)}if(!s){let e=[],n=t.items.length;sl(t.items,(i,a)=>{let u=i.kind,c=i.type;if("file"===u){let u=t.files[a];if(!c&&u.name){let e=u.name.split(".");c=e[e.length-1]}let l=u?u.name:bbn._("untitled"),f=u?u.size:null,d=u?u.lastModified:null,h=i.getAsFile();h?(s=!0,n--,r.files.push({type:c,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 s=!0,i.getAsString(t=>{n--,r.str.push({type:c,data:t}),"text/plain"===c&&e.push(name),n||(r.raw||(r.raw=e.join(", ")),o(r))})})}s||setTimeout(()=>{o(r)})})},getField:function(e,t,n="",r=null,o="=",i=0,s=!1,a=void 0){let u;return n&&["object","function"].includes(typeof n)&&6 in arguments&&(a=s),t?(u=Al(e,n,r,o,i,s,void 0),void 0===u?a:u[t]):a},getFieldValues:function(e,t,n,r,o){Mf(t,"string"),n&&(e=Hl(e,n,r,o));let i=[];return sl(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=Jf(n)),n.trim()},getHTMLOfSelection:Vf,getLoader:Ll,getPath:Il,getProp:function(e,t){return Mf(e,"object",bbn._("The obj must be an object in setProp")),Mf(t,"string",bbn._("The prop must be a string in setProp")),e[t]},getProperty:gl,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)),s=(e=>{const t=e.length,n=[],r=Array(t).fill(-1);for(let o=0;o<t;o++){let t=e[o],i=0,s=n.length;for(;i<s;){const r=i+s>>1;e[n[r]]<t?i=r+1:s=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),a=new Set(s.map(t=>e[t])),u=Array(t.length).fill(-1);for(let e=t.length-2;e>=0;e--)u[e]=u[e+1],a.has(t[e+1])&&(u[e]=e+1);const c=e.slice(),l=new Map(c.map((e,t)=>[e,t])),f=[];for(let e=0;e<t.length;e++){const n=t[e];if(a.has(n))continue;const r=l.get(n);if(void 0===r)throw new Error("Inconsistent state");const o=u[e],i=-1!==o?l.get(t[o]):c.length;if(void 0===i)throw new Error("Inconsistent state");const s=r<i?i-1:i;if(r!==s){const[e]=c.splice(r,1);c.splice(s,0,e),f.push({from:r,to:s,value:n}),l.clear();for(let e=0;e<c.length;e++)l.set(c[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:Gf,imageToCanvas:Kf,imgToBase64:function(e,t="image/png"){return Kf(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&&cl(!0,bbn,e),bbn.env.path=rl(bbn.env.url,bbn.env.root.length),n=bbn.env.path.split("/"),sl(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(),ed(t.getAttribute("href")),!1):void 0}),sl(document.querySelectorAll("form:not(.bbn-no), form:not(.bbn-form)"),e=>{e.addEventListener("submit",t=>{nd(e,t)})}),window.addEventListener("hashchange",()=>{bbn.env.hashChanged=(new Date).getTime()},!1),window.addEventListener("resize",()=>{rd()}),window.addEventListener("orientationchange",()=>{rd()}),rd(),sd()&&(document.body.classList.add("bbn-mobile"),id()&&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?ed(e.url,cl({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:ul,isBlob:Rf,isBoolean:function(...e){if(!e.length)return!1;for(let t of e)if(![!0,!1].includes(t))return!1;return!0},isCanvas:Af,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(!Qc(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"===zf()},isDimension:function(...e){if(!e.length)return!1;for(let t of e){if("number"!=typeof t||t<0)return!1;if(!ud(t))return!1}return!0},isDom:Dl,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(!Qc(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(!Qc(t))return!1;if(!cd(t)&&!bbn.var.regexp.hostname.test(t))return!1}return!0},isInside:function(e,t){let n=$f(e);if(n.length){if(Qc(t)){let e=!1;return sl(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:Xc,isMobile:sd,isMobileDevice:od,isNotObject:Yf,isNull:El,isNumber:Kc,isObject:al,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 sl(["width","height","gap","margin","padding","top","left","right","bottom"],n=>{if(-1!==e.indexOf(n))return t=!0,!1}),t},isSame:Yl,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:Qc,isSymbol:ld,isTabletDevice:id,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:ud,isValidName:function(...e){if(!e.length)return!1;for(let t of e)if(!Qc(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,s=(255&r)+t;return o>255?o=255:o<0&&(o=0),i>255?i=255:i<0&&(i=0),s>255?s=255:s<0&&(s=0),(n?"#":"")+(s|i<<8|o<<16).toString(16)}},link:ed,log:nl,makeReactive:function e(t,n,r,o){const i=(null==r?void 0:r.$cid)||"",s="__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:Tf(),writable:!0,configurable:!0,enumerable:!1});return new Proxy(t,{get(a,u){const c=Reflect.get(a,u),l=a.__bbnRoot||a;if(ld(u))return Reflect.get(l,u);const f=o?o+"."+u:u,d=s+(Kc(u)?u.toString():u);if(["fill","pop","push","reverse","shift","sort","splice","unshift"].includes(u)&&ul(a))return function(...e){let t=l[u](...e);return fd("DOING ARRAY STUFF"),nl(a.__bbnParent),n(a,"length",r),t};if(tl(c))return c;if("__bbnRoot"===u){let e=t;for(;e&&(null==e?void 0:e.__bbnTarget);)e=e.__bbnTarget;return e}return"__bbnIsProxy"===u||("__bbnTarget"===u?a:"__bbnParent"===u?r:"__bbnWatchers"===u?a.__bbnWatchers:0===u.indexOf("__bbn_")?Reflect.get(a,u):"length"===u&&ul(a.__bbnRoot||a)?l.length:u in a&&c&&"object"==typeof c&&[void 0,Object,Array].includes(c.constructor)?(c.__bbnIsProxy&&c.__bbnParent===r||(d in l||Reflect.defineProperty(l,d,{value:e(c,n,r,f),writable:!0,configurable:!0,enumerable:!1}),l[d].__bbnIsProxy&&!l.__bbnWatchers[i]&&(l.__bbnWatchers[i]=f)),l[d]):c)},set(t,a,u){if(ld(a))return Reflect.get(t,a,u);const c=t.__bbnRoot||t,l=o?o+"."+a:a;if(ld(a))return Reflect.get(t,a);if(r&&r.$options&&"bbn-loadbar"===r.$options.name&&nl(["Setting proxy prop in "+r.$options.name,t,a,u]),!Yl(c[a],u)){if(0===a.indexOf("__bbn_"))Reflect.defineProperty(c,a,{value:e(u,n,r,l),writable:!0,configurable:!0,enumerable:!1});else if(u&&"object"==typeof u&&[void 0,Object,Array].includes(u.constructor)){const t=s+(Kc(a)?a.toString():a);Reflect.defineProperty(c,t,{value:e(u,n,r,l),writable:!0,configurable:!0,enumerable:!1}),c[t].__bbnIsProxy&&!c.__bbnWatchers[i]&&(c.__bbnWatchers[i]=l)}r&&r.$options&&"bbn-loadbar"===r.$options.name&&nl(["Setting proxy prop in "+r.$options.name+" "+(Kc(a)?a.toString():a),u,t]),Reflect.set(c,a,u),n(t,a,r)}return!0},defineProperty(t,i,a){const u=t,c=o?o+"."+i:i;if("__bbnWatchers"===i||ld(i)||0===i.indexOf("__bbn_"))Reflect.defineProperty(u,i,a);else{const t=s+(Kc(i)?i.toString():i);Reflect.defineProperty(u,t,{value:e(a.value,n,r,c),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=s+(Kc(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]&&ul(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,s){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:" "),s||(s=void 0===s&&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),Kc(s)||(s=t?3:0),0===e&&"number"==typeof s&&s>0){let r=e.toFixed(s).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 a=e.toFixed(s),u=0,c=1e4;return a&&(c=a.indexOf("."),c<=0?c=1e4:u=a.length-c),a.replace(/./g,function(e,t,n){return"."===e?o:t&&(n.length-t-u)%3==0&&t<c?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(!ul(e,t))throw new TypeError("mutateArray can only be called with arrays");n?Mf(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||!Yl(e[t],o[t])){const n=Pl(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(!al(e,t))throw new TypeError("mutateObject can only be called with arrays");n?Mf(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=>{Yl(e[n],t[n])||(e[n]=t[n])}),e},nl2br:function(e,t){return $l("\n","<br>"+(t?"\n":""),e)},numProperties:yl,objectToFormData:dd,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=hd(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=hd(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:td,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"),md(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=Tf(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("'","'",e)),t&&0!==t.toLowerCase().indexOf("d")||(e=$l('"',""",e)),e},randomInt:gd,randomString:function(e,t,n){let r,o,i={n:"0123456789",l:"abcdefghijklmnopqrstuvwxyz",u:"ABCDEFGHIJKLMNOPQRSTUVWXYZ"};n||(n="nlu"),e||(r=gd(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=gd(e,t):e&&(r=e);let s="";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)],s+=i[o][Math.floor(Math.random()*i[o].length)];return s},range:function(e,t,n){return Array.from({length:(t-e)/n+1},(t,r)=>e+r*n)},removeAccents:pl,removeEmpty:function(e){var t=[];if(ul(e))for(let n=0;n<e.length;n++){let r=!1;e[n]&&(ul(e[n])?e[n].length&&(r=!0):al(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:Jf,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,s=o.lastChild;r.insertNode(o),n.removeAllRanges(),t?(i&&(r.setStartBefore(i),r.setEndAfter(s)),n.addRange(r)):(r.setStartAfter(s),n.addRange(r))}},resize:rd,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(pl(e).replace(/[^a-z0-9]/gi,t).replace(o,t),t)},search:Pl,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:hd,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:Qf,setProp:function(e,t,n,r=!0,o=!0){Object.defineProperty(e,t,{value:n,writable:r,configurable:o})},setProperty:md,shorten:bd,shortenObj:function e(t,n=100){let r=Sf(t);return sl(r,(t,o)=>{Qc(t)&&t.length>n?r[o]=bd(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:kl,simpleHash1:Ml,simpleHash2:Sl,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 s=ql(e,n,"json"),a=Ll(s);if(null==a?void 0:a.loader)return a.loader;n||(n={}),bbn.env.token&&(n._bbn_token=bbn.env.token);const u=new AbortController;let c="";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:u.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:a,value:u}){if(a)return Fl(s,n),c&&l(c),void(i&&i());if(o)if(c+=Jl(u).trim(),bbn.fn.log(["STREAM RESULT",c.length,c]),c)try{l(c),c=""}catch(e){}else t();else bbn.fn.log(["STREAM SUCCESS IS FN? "+o]);return r.read().then(e)})}}).catch(t=>{let i=!(!(a=t)||!0!==a.__BBN_CANCEL__);var a;if(Fl(s,n,i),i){let n=1;tl(o)&&(n=o(t.message,e)),n&&xf(t.message,e)}else{let e=1;tl(r)&&(e=r(t.request,t)),e&&Of(t.request,t.response?t.response.data:"",t.response?t.response.status:t)}});return ml(s,d,u),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:nd,substr:rl,sum:function(e,t,n,r,o){let i=0;return sl(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 sl(e,(e,s)=>{let a=ul(e)?e.length:Object.values(e).length,u=0;sl(e,e=>{o+="string"==typeof e?r+$l(r,"\\"+r,e)+r:0===e?"0":e&&e.toString?e.toString():r+r,u++,u<a&&(o+=t)}),s<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(){rd()},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:Xf,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(ul(e[n]))t+=JSON.stringify(e[n]);else{let r={};sl(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=()=>Gc.run("post",e||bbn.env.path,{data:dd({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:fd,yieldToBrowser:Hf};const yd=(e,t="long",n)=>{if(!t){const t=yd(e,"narrow"),n=yd(e,"short"),r=yd(e,"long");return{letter:t,abbr:n,full:r,long:r,short:n,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([bbn.env.lang,...navigator.languages],{weekday:r})},vd=[["y","year",31536e6],["m","month",2592e6],["w","week",6048e5],["d","day",864e5],["h","hour",36e5],["i","minute",6e4],["s","second",1e3]],Ed={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"},Md={y:"YYYY",m:"MM",d:"DD",e:"EE",w:"WW",h:"HH",i:"II",s:"SS"};var Sd,kd,Dd,Id,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)};const xd=Hc.ZonedDateTime.from("1970-01-01T00:00Z[UTC]");class Od{static fromUnit(e,t){const n=Ed[t]||"ms",r=["y"===n?e:0,"m"===n?e:0,"d"===n?e:0,"h"===n?e:0,"i"===n?e:0,"s"===n?e:0,["y","m","d","h","i","s"].includes(n)?0:e],o=new Hc.Duration(...r);return new Od(o,0,0,0,0,0,0,n)}constructor(e,t,n,r,o,i,s,a){Sd.add(this),kd.set(this,void 0),Dd.set(this,void 0),e instanceof Hc.Duration?Td(this,kd,e,"f"):Td(this,kd,"object"==typeof e?new Hc.Duration(e.years||0,e.months||0,e.weeks||0,e.days||0,e.hours||0,e.minutes||0,e.seconds||0,e.milliseconds||0,0,0):new Hc.Duration(e||0,t||0,n||0,r||0,o||0,i||0,s||0,0,0),"f");const u=Ed[a||""]||a;Td(this,Dd,u||"ms","f");const c=Al(vd,e=>e[0]===u);if(!c)throw new Error("Invalid unit for duration: "+u)}get value(){return _d(this,kd,"f")}years(e=!1){return _d(this,Sd,"m",Id).call(this,"year",e)}months(e=!1){return _d(this,Sd,"m",Id).call(this,"month",e)}weeks(e=!1){return _d(this,Sd,"m",Id).call(this,"week",e)}days(e=!1){return _d(this,Sd,"m",Id).call(this,"day",e)}hours(e=!1){return _d(this,Sd,"m",Id).call(this,"hour",e)}minutes(e=!1){return _d(this,Sd,"m",Id).call(this,"minute",e)}seconds(e=!1){return _d(this,Sd,"m",Id).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(){return _d(this,kd,"f").total({unit:"year",relativeTo:xd})}asMonths(){return _d(this,kd,"f").total({unit:"month",relativeTo:xd})}asWeeks(){return _d(this,kd,"f").total({unit:"week",relativeTo:xd})}asDays(){return _d(this,kd,"f").total({unit:"day",relativeTo:xd})}asHours(){return _d(this,kd,"f").total({unit:"hour",relativeTo:xd})}asMinutes(){return _d(this,kd,"f").total({unit:"minute",relativeTo:xd})}asSeconds(){return _d(this,kd,"f").total({unit:"second",relativeTo:xd})}add(e,t){const n=t?Ed[t]||t:_d(this,Dd,"f"),r=n+"s";if(!["years","months","weeks","days","hours","minutes","seconds","milliseconds"].includes(r))throw new Error("Invalid unit for duration: "+(null!=t?t:n));const o={[r]:e},i=_d(this,kd,"f").add(o);return new Od(i,void 0,void 0,void 0,void 0,void 0,void 0,_d(this,Dd,"f"))}subtract(e,t){return this.add(-e,t)}toMilliseconds(){const e=_d(this,kd,"f");return e.years||e.months||e.weeks||e.days?e.total({unit:"millisecond",relativeTo:xd}):e.total({unit:"millisecond"})}}kd=new WeakMap,Dd=new WeakMap,Sd=new WeakSet,Id=function(e,t){const n=_d(this,kd,"f");if(t)switch(e){case"year":return n.years;case"month":return n.months;case"week":return n.weeks;case"day":return n.days;case"hour":return n.hours;case"minute":return n.minutes;case"second":return n.seconds}const r=n.total({unit:e,relativeTo:xd});return Math.floor(r)};var jd,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},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 Nd{constructor(e){jd.set(this,void 0),Yd(this,jd,e,"f")}get value(){return Cd(this,jd,"f")}static compare(e,t,n){if(!e||!t)throw new TypeError("Both arguments must be Temporal values");if(e.constructor!==t.constructor)throw new TypeError("Cannot compare different Temporal types");const r=e.constructor;if(void 0===n){if("function"!=typeof r.compare)throw new TypeError("This Temporal type has no static compare");return r.compare(e,t)}if("function"!=typeof e.until)throw new TypeError("This Temporal type does not support until/since");return e.until(t,{largestUnit:n}).sign}static parse(e,t,n="auto",r){return parse(e,t,n,r)}parse(e,t){return Nd.parse(e,t,yf(this.kind))}compare(e,t){return e instanceof Nd||(e=bbn.dt(e,this.kind)),Nd.compare(this.value,e.value,t)}add(e,t){if(this.value){if(this.value instanceof Hc.PlainMonthDay||"function"!=typeof this.value.add)throw new TypeError("This Temporal type does not support add/subtract");if(e instanceof Od){const t=this.value.add(e.value);return new this.constructor(t)}if("object"==typeof e){const t=new Od(e),n=this.value.add(t.value);return new this.constructor(n)}{if(!t)throw new Error("Unit must be specified when adding a number");const n=Od.fromUnit(e,t),r=this.value.add(n.value);return new this.constructor(r)}}}subtract(e,t){if(this.value){if(this.value instanceof Hc.PlainMonthDay||"function"!=typeof this.value.subtract)throw new TypeError("This Temporal type does not support add/subtract");if(e instanceof Od){const t=this.value.subtract(e.value);return new this.constructor(t)}if("object"==typeof e){const t=new Od(e),n=this.value.subtract(t.value);return new this.constructor(n)}{if(!t)throw new Error("Unit must be specified when adding a number");const n=Od.fromUnit(e,t),r=this.value.subtract(n.value);return new this.constructor(r)}}}isBefore(e){return this.compare(e)<0}isAfter(e){return this.compare(e)>0}isSame(e){return 0===this.compare(e)}equals(e){return this.isSame(e)}toJSON(){return{kind:this.kind,value:String(this.value)}}toString(){return String(this.value)}year(e){if(this.value){if(!("year"in this.value))throw new Error("year() is not supported for this type");if(void 0!==e&&!(e instanceof Event)){const t=this.value.with({year:e});return new this.constructor(t)}return this.value.year}}month(e){if(this.value){if(!("month"in this.value))throw new Error("month() is not supported for this type");if(void 0!==e&&!(e instanceof Event)){const t=this.value.with({month:e});return new this.constructor(t)}return this.value.month}}day(e){if(this.value){if(!("day"in this.value))throw new Error("day() is not supported for this type");if(void 0!==e&&!(e instanceof Event)){const t=this.value.with({day:e});return new this.constructor(t)}return this.value.day}}hour(e){if(this.value){if(!("hour"in this.value))throw new Error("hour() is not supported for this type");if(void 0!==e&&!(e instanceof Event)){const t=this.value.with({hour:e});return new this.constructor(t)}return this.value.hour}}minute(e){if(this.value){if(!("minute"in this.value))throw new Error("minute() is not supported for this type");if(void 0!==e&&!(e instanceof Event)){const t=this.value.with({minute:e});return new this.constructor(t)}return this.value.minute}}second(e){if(this.value){if(!("second"in this.value))throw new Error("second() is not supported for this type");if(void 0!==e&&!(e instanceof Event)){const t=this.value.with({second:e});return new this.constructor(t)}return this.value.second}}weekday(e,t){if(this.value){if(!("dayOfWeek"in this.value))throw new Error("weekday() is not supported for this type");return void 0===e||e instanceof Event?this.value.dayOfWeek:this.setWeekday(e,t)}}date(e){if(this.value){if(!("year"in this.value)||!("month"in this.value)||!("day"in this.value))throw new Error("date() is not supported for this type");return 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")}week(){if(this.value){if(!("weekOfYear"in this.value))throw new Error("week() is not supported for this type");return this.value.weekOfYear}}get YYYY(){if("year"in this.value)return this.year().toString()}get YY(){if("year"in this.value)return rl(this.year().toString(),2,2)}get MMMM(){if("month"in this.value)return this.format("MMMM")}get MMM(){if("month"in this.value)return this.format("MMM")}get MM(){if("month"in this.value){const e=parseInt(this.month().toString());return e<10?"0"+e.toString():e.toString()}}get M(){if("month"in this.value)return this.month().toString()}get EE(){if("dayOfWeek"in this.value)return this.value.dayOfWeek.toString()}get DD(){if("day"in this.value){const e=parseInt(this.day().toString());return e<10?"0"+e.toString():e.toString()}}get d(){if("day"in this.value)return this.day().toString()}get dddd(){if("dayOfWeek"in this.value)return yd(0,"long")}get ddd(){if("day"in this.value)return yd(0,"short")}get D(){if("day"in this.value)return this.day().toString()}get HH(){if("hour"in this.value){const e=parseInt(this.hour().toString());return e<10?"0"+e.toString():e.toString()}}get H(){if("hour"in this.value)return this.hour().toString()}get II(){if("minute"in this.value){const e=parseInt(this.minute().toString());return e<10?"0"+e.toString():e.toString()}}get mm(){if("minute"in this.value){const e=parseInt(this.minute().toString());return e<10?"0"+e.toString():e.toString()}}get I(){if("minute"in this.value)return this.minute().toString()}get SS(){if("second"in this.value){const e=parseInt(this.second().toString());return e<10?"0"+e.toString():e.toString()}}get S(){if("second"in this.value)return this.second().toString()}get WW(){if("weekOfYear"in this.value)return this.value.weekOfYear.toString().padStart(2,"0")}get W(){if("weekOfYear"in this.value)return this.value.weekOfYear.toString()}format(e="YYYY-MM-DD HH:II:SS"){let t="";if(e){const n=new RegExp("([|]|"+Object.keys(Ed).join("|")+")","g");let r=0;sl(e.split(n),e=>{if("["!==e)if("]"!==e)if(r>0)t+=e;else if(e in Ed)if(e in this&&Kl(this[e]))t+=this[e];else{t+=this[Md[Ed[e]]]}else t+=e;else r--;else r++})}return t}setWeekday(e,t=!1,n){let r;if("string"==typeof e&&(e=((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}'`)})(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;return t?(i=(o-r+7)%7,0===i&&(i=7),i=-i):(i=(r-o+7)%7,0===i&&(i=7)),this.add(i,"d")}}jd=new WeakMap;class Rd extends Nd{constructor(e,t,n,r,o,i,s){let a;if(e)if(void 0===t)if(e instanceof Hc.PlainDateTime)a=e;else if(e instanceof Date)a=new Hc.PlainDateTime(e.getFullYear(),e.getMonth()+1,e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds());else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");{const t=new Date(e);a=new Hc.PlainDateTime(t.getFullYear(),t.getMonth()+1,t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds())}}else a=new Hc.PlainDateTime(e,t,n||1,r||0,o||0,i||0,s||0);else a=Hc.PlainDateTime.from(Hc.Now.plainDateISO());super(a),this.kind="datetime"}fdate(e=!1,t=!1,n=!1){if(!this.value)return"";const r=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),this.second()),o=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],o).format(r)}ftime(e=!1){if(!this.value)return"";const t=new Date(2e3,1,1,this.hour(),this.minute(),this.second()),n={hour:"2-digit",minute:"2-digit"};e&&(n.second="2-digit");return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],n).format(t)}}function Pd(e,t,n){let r="";const o=e.some(e=>"dayPeriod"===e.type),i=o||"h12"===t||"h11"===t,s=!!n.weekday,a="short"===n.month||"long"===n.month,u="numeric"===n.year&&"numeric"===n.month&&"numeric"===n.day&&!s&&!a;for(const t of e)switch(t.type){case"year":"2-digit"===n.year?r+="YY":r+="YYYY";break;case"month":if("short"===n.month){r+="MMM";break}if("long"===n.month){r+="MMMM";break}if(u){r+="M";break}/^\d+$/.test(t.value)?r+=2===t.value.length?"MM":"M":r+=t.value.length>3?"MMMM":"MMM";break;case"day":if(u){r+="D";break}r+=2===t.value.length?"DD":"D";break;case"weekday":"short"===n.weekday||"narrow"===n.weekday?r+="ddd":"long"===n.weekday?r+="dddd":r+=t.value.length>3?"dddd":"ddd";break;case"hour":r+=i?2===t.value.length?"hh":"h":2===t.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(!t.value)break;if(/[A-Za-zÀ-ÖØ-öø-ÿ]/.test(t.value)){r+=`[${t.value.replace(/]/g,"\\]")}]`}else r+=t.value;break;default:r+=t.value}return r}const Ad=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,s=new Set,a=new Set,u=[{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"}],c=[];for(const r of u){const o=new Intl.DateTimeFormat(e,r),s=Pd(o.formatToParts(t),o.resolvedOptions().hourCycle,r);i.has(s)||(i.add(s),n.push({pattern:s,sample:o.format(t),options:r})),r.year&&r.month&&r.day&&c.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=Pd(o.formatToParts(t),o.resolvedOptions().hourCycle,n);s.has(i)||(s.add(i),r.push({pattern:i,sample:o.format(t),options:n}))}for(const n of c)for(const r of l){const i=Object.assign(Object.assign({},n),r),s=new Intl.DateTimeFormat(e,i),u=Pd(s.formatToParts(t),s.resolvedOptions().hourCycle,i);a.has(u)||(a.add(u),o.push({pattern:u,sample:s.format(t),options:i}))}return{date:n,time:r,datetime:o}},Fd=()=>{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=[],s=[];for(let e=0;e<12;e++){const r=new Date(2020,e,1);i.push(t.format(r)),s.push(n.format(r))}const a=new Date(2020,1,2),u=[],c=[];for(let e=0;e<7;e++){const t=new Date(a.getTime()+864e5*e);u.push(r.format(t)),c.push(o.format(t))}const{date:l,time:f,datetime:d}=Ad(e);cl(bbn.dt.locales,{monthsLong:i,monthsShort:s,weekdaysLong:u,weekdaysShort:c,date:l,time:f,datetime:d})};function Ld(e,t=!1,n=Hc.Now.timeZoneId()){const r=Hc.Instant.fromEpochMilliseconds(e.getTime()).toZonedDateTimeISO(n);return t?r:r.toPlainDateTime()}class Hd extends Nd{constructor(e,t,n,r,o,i,s,a){let u;if(e)if(void 0===t)if(e instanceof Hc.ZonedDateTime)u=e;else if(e instanceof Date)u=Ld(e,!0);else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtZoned");u=Ld(new Date(e),!0)}else{u=new Hc.PlainDateTime(t,n,r||1,o||0,i||0,s||0,a||0).toZonedDateTime(e||Hc.Now.timeZoneId())}else{const e=new Date;u=new Hc.ZonedDateTime(BigInt(1e6*e.getTime()),Intl.DateTimeFormat().resolvedOptions().timeZone)}super(u),this.kind="zoned"}fdate(e=!1,t=!1,n=!1){if(!this.value)return"";const r=new Date(this.year(),this.month()-1,this.day(),this.hour(),this.minute(),this.second()),o=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],o).format(r)}ftime(e=!1){if(!this.value)return"";const t=new Date(2e3,1,1,this.hour(),this.minute(),this.second()),n={hour:"2-digit",minute:"2-digit"};e&&(n.second="2-digit");return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],n).format(t)}}class Bd extends Nd{constructor(e,t,n){let r;if(e)if(void 0===t)if(e instanceof Hc.PlainDate)r=e;else if(e instanceof Date)r=new Hc.PlainDate(e.getFullYear(),e.getMonth()+1,e.getDate());else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");{const t=new Date(e);r=new Hc.PlainDate(t.getFullYear(),t.getMonth()+1,t.getDate())}}else r=new Hc.PlainDate(e,t,n||1);else r=Hc.PlainDate.from(Hc.Now.plainDateISO());super(r),this.kind="date"}compareSameKind(e){const t=Hc.PlainDate.compare(this.value,e.value);return t<0?-1:t>0?1:0}fdate(e=!1,t=!1){const n=new Date(this.year(),this.month()-1,this.day()),r=Object.assign({year:"numeric",month:e?"long":"numeric",day:"numeric"},t?{weekday:e?"long":"short"}:{});return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],r).format(n)}}class Ud extends Nd{constructor(e,t,n,r){let o;if(e)if(void 0===e)if(e instanceof Hc.PlainTime)o=e;else if(e instanceof Date)o=new Hc.PlainTime(e.getHours(),e.getMinutes(),e.getSeconds(),1e6*e.getMilliseconds());else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");if(void 0!==t)o=new Hc.PlainTime(e,t,n||0,r||0);else{const t=new Date(e);o=new Hc.PlainTime(t.getHours(),t.getMinutes(),t.getSeconds(),1e6*t.getMilliseconds())}}else o=new Hc.PlainTime(e,t||0,n||0,r||0);else{const e=new Date;o=new Hc.PlainTime(e.getHours(),e.getMinutes(),e.getSeconds(),1e6*e.getMilliseconds())}super(o),this.kind="time"}ftime(e=!1){if(!this.value)return"";const t=new Date(2e3,1,1,this.hour(),this.minute(),this.second()),n={hour:"2-digit",minute:"2-digit"};e&&(n.second="2-digit");return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],n).format(t)}}class Wd extends Nd{constructor(e,t){let n;if(e)if(void 0===t)if(e instanceof Hc.PlainYearMonth)n=e;else if(e instanceof Date)n=new Hc.PlainYearMonth(e.getFullYear(),e.getMonth()+1);else{if("number"!=typeof t)throw new Error("Invalid value for bbnDtDateTime");{const e=new Date(t);n=new Hc.PlainYearMonth(e.getFullYear(),e.getMonth()+1)}}else n=new Hc.PlainYearMonth(e,t);else{const e=new Date;n=new Hc.PlainYearMonth(e.getFullYear(),e.getMonth()+1)}super(n),this.kind="year-month"}fdate(e=!1,t=!1,n=!1){if(!this.value)return"";const r=new Date(this.year(),this.month()-1),o={year:"numeric",month:e?"long":"numeric"};return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],o).format(r)}}class Zd extends Nd{constructor(e,t){let n;if(e)if(void 0===t)if(e instanceof Hc.PlainMonthDay)n=e;else if(e instanceof Date)n=new Hc.PlainMonthDay(e.getMonth()+1,e.getDate());else{if("number"!=typeof e)throw new Error("Invalid value for bbnDtDateTime");{const t=new Date(e);n=new Hc.PlainMonthDay(t.getMonth()+1,t.getDate())}}else n=new Hc.PlainMonthDay(e,t);else{const e=new Date;n=new Hc.PlainMonthDay(e.getMonth()+1,e.getDate())}super(n),this.kind="month-day"}fdate(e=!1,t=!1,n=!1){if(!this.value)return"";const r=new Date(2e3,this.month()-1,this.day()),o={month:e?"long":"numeric",day:"numeric"};return new Intl.DateTimeFormat([bbn.env.lang,...navigator.languages],o).format(r)}}const $d=function(e,t){try{return t?e.toLocaleLowerCase(t):e.toLowerCase()}catch(t){return e.toLowerCase()}};function qd(e,t,n="auto",r){var o,i,s,a,u,c,l;Fd();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!==(s=null==r?void 0:r.monthsShort)&&void 0!==s?s:bbn.dt.locales.monthsShort,weekdaysLong:null!==(a=null==r?void 0:r.weekdaysLong)&&void 0!==a?a:bbn.dt.locales.weekdaysLong,weekdaysShort:null!==(u=null==r?void 0:r.weekdaysShort)&&void 0!==u?u:bbn.dt.locales.weekdaysShort},m=(null==bbn?void 0:bbn.env)&&(null===(c=bbn.env)||void 0===c?void 0:c.lang)||(null==bbn?void 0:bbn.dt)&&(null===(l=bbn.dt)||void 0===l?void 0:l.locale)||Intl.DateTimeFormat().resolvedOptions().locale,g=e=>e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");function p(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,s="zoned"===n.toLowerCase(),a="datetime"===n.toLowerCase(),u="date"===n.toLowerCase(),c="time"===n.toLowerCase(),l="yearmonth"===n.toLowerCase(),f="monthday"===n.toLowerCase(),p=[{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=$d(e,m),r=h.monthsLong.findIndex(e=>$d(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=$d(e,m),r=h.monthsShort.findIndex(e=>$d(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=$d(e,m),r=h.weekdaysLong.findIndex(e=>$d(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=$d(e,m),r=h.weekdaysShort.findIndex(e=>$d(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=[...p].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+=g(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+=g(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,S=o.hasYear&&o.hasMonth&&o.hasDay,k=o.hasYear&&o.hasMonth&&!o.hasDay,D=!o.hasYear&&o.hasMonth&&o.hasDay,I=o.hasHour||o.hasMinute||o.hasSecond||o.hasMs,T=null!=o.timeZone||null!=o.offsetMinutes;if(s||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 Hd(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 Hd(d.Instant.fromEpochMilliseconds(t).toZonedDateTimeISO(d.Now.timeZoneId()))}if(a||i&&M&&I){if(!S)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 Rd(e)}if(u||l||f||i&&M&&!I){if(u||S&&i){const e=new d.PlainDate(o.year,o.month,o.day);return new Bd(e)}if(l||k&&i){const e=new d.PlainYearMonth(o.year,o.month);return new Wd(e)}if(f||D&&i){const e=new d.PlainMonthDay(o.month,o.day,1972);return new Zd(e)}throw new Error("Not enough date components for a known Temporal type")}if(c||i&&!M&&I){const e=new d.PlainTime(o.hour,o.minute,o.second,1e6*o.ms);return new Ud(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 p(r,n)}catch(t){e=t}throw null!=e?e:new Error("No format matched")}return p(t,n)}const zd=["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"];function Vd(e,t,n){const r=e.trim();if(!r)return null;Fd();const o=e=>{for(const t of e)try{return qd(r,t),t}catch(e){}return null};if(t){return o(Array.isArray(t)?t:[t])}const i=Ad(n),s=new Set,a=zd.filter(e=>!s.has(e)&&(s.add(e),!0)),u=[...i.datetime.map(e=>e.pattern),...i.date.map(e=>e.pattern),...i.time.map(e=>e.pattern)].filter(e=>!s.has(e)&&(s.add(e),!0)),c=o([...a,...u]);return c||null}const Jd=(e,t=null,n="auto")=>{if(!e)return new Rd;if("string"==typeof e){if(t)return qd(e,t,n);{const t=Vd(e);if(t)return qd(e,t,n);throw new Error(Wc("Could not guess the date format for value: %s",e))}}if("number"==typeof e)return new Rd(e);if(e instanceof Date){const t=e;return new Rd(t.getFullYear(),t.getMonth()+1,t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds())}throw new Error(Wc("Invalid date value: %s",e))};Jd.locales=Object.create(null),Jd.parse=qd,Jd.guessFormat=Vd,Jd.time=()=>{},Jd.date=()=>{},Jd.dateTime=()=>{},Jd.duration=()=>{},Jd.zoned=()=>{},Jd.monthDay=()=>{},Jd.yearMonth=()=>{};const Gd={version:"1.0.1",opt:{_cat:{}},app:{},_:Wc,$: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:Zc,date:pf,dt:Jd,com:Gc,env:$c,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=Gd,window.Temporal||(window.Temporal=Hc)),e.Temporal=Hc,e.bbn=Gd,e.default=Gd,Object.defineProperty(e,"__esModule",{value:!0}),e}({});
|
|
2
2
|
//# sourceMappingURL=bbn.js.map
|