@qikdev/vue-ui 0.3.15 → 0.3.16
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/lib.es.js +12 -6
- package/dist/lib.es.js.map +1 -1
- package/dist/lib.umd.js +1 -1
- package/dist/lib.umd.js.map +1 -1
- package/dist/vue-ui.css +1 -1
- package/package.json +1 -1
package/dist/lib.umd.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(E,t){typeof exports=="object"&&typeof module<"u"?t(exports,require("vue"),require("@qikdev/sdk")):typeof define=="function"&&define.amd?define(["exports","vue","@qikdev/sdk"],t):(E=typeof globalThis<"u"?globalThis:E||self,t(E["@qikdev/vue-ui"]={},E.Vue,E.sdk))})(this,function(E,t,Dt){"use strict";var ZL=Object.defineProperty;var XL=(E,t,Dt)=>t in E?ZL(E,t,{enumerable:!0,configurable:!0,writable:!0,value:Dt}):E[t]=Dt;var W=(E,t,Dt)=>XL(E,typeof t!="symbol"?t+"":t,Dt);const qh="0.3.15";class Ot extends Error{}class zh extends Ot{constructor(n){super(`Invalid DateTime: ${n.toMessage()}`)}}class Wh extends Ot{constructor(n){super(`Invalid Interval: ${n.toMessage()}`)}}class Hh extends Ot{constructor(n){super(`Invalid Duration: ${n.toMessage()}`)}}class yn extends Ot{}class jl extends Ot{constructor(n){super(`Invalid unit ${n}`)}}class Ie extends Ot{}class dt extends Ot{constructor(){super("Zone is an abstract class")}}const T="numeric",qe="short",De="long",oo={year:T,month:T,day:T},ql={year:T,month:qe,day:T},Gh={year:T,month:qe,day:T,weekday:qe},zl={year:T,month:De,day:T},Wl={year:T,month:De,day:T,weekday:De},Hl={hour:T,minute:T},Gl={hour:T,minute:T,second:T},Yl={hour:T,minute:T,second:T,timeZoneName:qe},Jl={hour:T,minute:T,second:T,timeZoneName:De},Kl={hour:T,minute:T,hourCycle:"h23"},Zl={hour:T,minute:T,second:T,hourCycle:"h23"},Xl={hour:T,minute:T,second:T,hourCycle:"h23",timeZoneName:qe},Ql={hour:T,minute:T,second:T,hourCycle:"h23",timeZoneName:De},vl={year:T,month:T,day:T,hour:T,minute:T},ea={year:T,month:T,day:T,hour:T,minute:T,second:T},ta={year:T,month:qe,day:T,hour:T,minute:T},na={year:T,month:qe,day:T,hour:T,minute:T,second:T},Yh={year:T,month:qe,day:T,weekday:qe,hour:T,minute:T},ra={year:T,month:De,day:T,hour:T,minute:T,timeZoneName:qe},oa={year:T,month:De,day:T,hour:T,minute:T,second:T,timeZoneName:qe},ia={year:T,month:De,day:T,weekday:De,hour:T,minute:T,timeZoneName:De},sa={year:T,month:De,day:T,weekday:De,hour:T,minute:T,second:T,timeZoneName:De};function H(e){return typeof e>"u"}function Mt(e){return typeof e=="number"}function Kn(e){return typeof e=="number"&&e%1===0}function Jh(e){return typeof e=="string"}function Kh(e){return Object.prototype.toString.call(e)==="[object Date]"}function la(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function Zh(e){return Array.isArray(e)?e:[e]}function aa(e,n,r){if(e.length!==0)return e.reduce((i,s)=>{const o=[n(s),s];return i&&r(i[0],o[0])===i[0]?i:o},null)[1]}function Xh(e,n){return n.reduce((r,i)=>(r[i]=e[i],r),{})}function Qt(e,n){return Object.prototype.hasOwnProperty.call(e,n)}function nt(e,n,r){return Kn(e)&&e>=n&&e<=r}function Qh(e,n){return e-n*Math.floor(e/n)}function fe(e,n=2){const r=e<0;let i;return r?i="-"+(""+-e).padStart(n,"0"):i=(""+e).padStart(n,"0"),i}function ut(e){if(!(H(e)||e===null||e===""))return parseInt(e,10)}function Ft(e){if(!(H(e)||e===null||e===""))return parseFloat(e)}function io(e){if(!(H(e)||e===null||e==="")){const n=parseFloat("0."+e)*1e3;return Math.floor(n)}}function so(e,n,r=!1){const i=10**n;return(r?Math.trunc:Math.round)(e*i)/i}function kn(e){return e%4===0&&(e%100!==0||e%400===0)}function _n(e){return kn(e)?366:365}function Zn(e,n){const r=Qh(n-1,12)+1,i=e+(n-r)/12;return r===2?kn(i)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][r-1]}function lo(e){let n=Date.UTC(e.year,e.month-1,e.day,e.hour,e.minute,e.second,e.millisecond);return e.year<100&&e.year>=0&&(n=new Date(n),n.setUTCFullYear(n.getUTCFullYear()-1900)),+n}function Xn(e){const n=(e+Math.floor(e/4)-Math.floor(e/100)+Math.floor(e/400))%7,r=e-1,i=(r+Math.floor(r/4)-Math.floor(r/100)+Math.floor(r/400))%7;return n===4||i===3?53:52}function ao(e){return e>99?e:e>60?1900+e:2e3+e}function ca(e,n,r,i=null){const s=new Date(e),o={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};i&&(o.timeZone=i);const l={timeZoneName:n,...o},a=new Intl.DateTimeFormat(r,l).formatToParts(s).find(c=>c.type.toLowerCase()==="timezonename");return a?a.value:null}function Qn(e,n){let r=parseInt(e,10);Number.isNaN(r)&&(r=0);const i=parseInt(n,10)||0,s=r<0||Object.is(r,-0)?-i:i;return r*60+s}function da(e){const n=Number(e);if(typeof e=="boolean"||e===""||Number.isNaN(n))throw new Ie(`Invalid unit value ${e}`);return n}function vn(e,n){const r={};for(const i in e)if(Qt(e,i)){const s=e[i];if(s==null)continue;r[n(i)]=da(s)}return r}function er(e,n){const r=Math.trunc(Math.abs(e/60)),i=Math.trunc(Math.abs(e%60)),s=e>=0?"+":"-";switch(n){case"short":return`${s}${fe(r,2)}:${fe(i,2)}`;case"narrow":return`${s}${r}${i>0?`:${i}`:""}`;case"techie":return`${s}${fe(r,2)}${fe(i,2)}`;default:throw new RangeError(`Value format ${n} is out of range for property format`)}}function tr(e){return Xh(e,["hour","minute","second","millisecond"])}const vh=/[A-Za-z_+-]{1,256}(:?\/[A-Za-z0-9_+-]{1,256}(\/[A-Za-z0-9_+-]{1,256})?)?/,ep=["January","February","March","April","May","June","July","August","September","October","November","December"],ua=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],tp=["J","F","M","A","M","J","J","A","S","O","N","D"];function ma(e){switch(e){case"narrow":return[...tp];case"short":return[...ua];case"long":return[...ep];case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}const fa=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],ha=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],np=["M","T","W","T","F","S","S"];function pa(e){switch(e){case"narrow":return[...np];case"short":return[...ha];case"long":return[...fa];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const ga=["AM","PM"],rp=["Before Christ","Anno Domini"],op=["BC","AD"],ip=["B","A"];function ya(e){switch(e){case"narrow":return[...ip];case"short":return[...op];case"long":return[...rp];default:return null}}function sp(e){return ga[e.hour<12?0:1]}function lp(e,n){return pa(n)[e.weekday-1]}function ap(e,n){return ma(n)[e.month-1]}function cp(e,n){return ya(n)[e.year<0?0:1]}function dp(e,n,r="always",i=!1){const s={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},o=["hours","minutes","seconds"].indexOf(e)===-1;if(r==="auto"&&o){const m=e==="days";switch(n){case 1:return m?"tomorrow":`next ${s[e][0]}`;case-1:return m?"yesterday":`last ${s[e][0]}`;case 0:return m?"today":`this ${s[e][0]}`}}const l=Object.is(n,-0)||n<0,a=Math.abs(n),c=a===1,d=s[e],u=i?c?d[1]:d[2]||d[1]:c?s[e][0]:e;return l?`${a} ${u} ago`:`in ${a} ${u}`}function ka(e,n){let r="";for(const i of e)i.literal?r+=i.val:r+=n(i.val);return r}const up={D:oo,DD:ql,DDD:zl,DDDD:Wl,t:Hl,tt:Gl,ttt:Yl,tttt:Jl,T:Kl,TT:Zl,TTT:Xl,TTTT:Ql,f:vl,ff:ta,fff:ra,ffff:ia,F:ea,FF:na,FFF:oa,FFFF:sa};class Ne{static create(n,r={}){return new Ne(n,r)}static parseFormat(n){let r=null,i="",s=!1;const o=[];for(let l=0;l<n.length;l++){const a=n.charAt(l);a==="'"?(i.length>0&&o.push({literal:s,val:i}),r=null,i="",s=!s):s||a===r?i+=a:(i.length>0&&o.push({literal:!1,val:i}),i=a,r=a)}return i.length>0&&o.push({literal:s,val:i}),o}static macroTokenToFormatOpts(n){return up[n]}constructor(n,r){this.opts=r,this.loc=n,this.systemLoc=null}formatWithSystemDefault(n,r){return this.systemLoc===null&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(n,{...this.opts,...r}).format()}formatDateTime(n,r={}){return this.loc.dtFormatter(n,{...this.opts,...r}).format()}formatDateTimeParts(n,r={}){return this.loc.dtFormatter(n,{...this.opts,...r}).formatToParts()}resolvedOptions(n,r={}){return this.loc.dtFormatter(n,{...this.opts,...r}).resolvedOptions()}num(n,r=0){if(this.opts.forceSimple)return fe(n,r);const i={...this.opts};return r>0&&(i.padTo=r),this.loc.numberFormatter(i).format(n)}formatDateTimeFromString(n,r){const i=this.loc.listingMode()==="en",s=this.loc.outputCalendar&&this.loc.outputCalendar!=="gregory",o=(h,g)=>this.loc.extract(n,h,g),l=h=>n.isOffsetFixed&&n.offset===0&&h.allowZ?"Z":n.isValid?n.zone.formatOffset(n.ts,h.format):"",a=()=>i?sp(n):o({hour:"numeric",hourCycle:"h12"},"dayperiod"),c=(h,g)=>i?ap(n,h):o(g?{month:h}:{month:h,day:"numeric"},"month"),d=(h,g)=>i?lp(n,h):o(g?{weekday:h}:{weekday:h,month:"long",day:"numeric"},"weekday"),u=h=>{const g=Ne.macroTokenToFormatOpts(h);return g?this.formatWithSystemDefault(n,g):h},m=h=>i?cp(n,h):o({era:h},"era"),f=h=>{switch(h){case"S":return this.num(n.millisecond);case"u":case"SSS":return this.num(n.millisecond,3);case"s":return this.num(n.second);case"ss":return this.num(n.second,2);case"uu":return this.num(Math.floor(n.millisecond/10),2);case"uuu":return this.num(Math.floor(n.millisecond/100));case"m":return this.num(n.minute);case"mm":return this.num(n.minute,2);case"h":return this.num(n.hour%12===0?12:n.hour%12);case"hh":return this.num(n.hour%12===0?12:n.hour%12,2);case"H":return this.num(n.hour);case"HH":return this.num(n.hour,2);case"Z":return l({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return l({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return l({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return n.zone.offsetName(n.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return n.zone.offsetName(n.ts,{format:"long",locale:this.loc.locale});case"z":return n.zoneName;case"a":return a();case"d":return s?o({day:"numeric"},"day"):this.num(n.day);case"dd":return s?o({day:"2-digit"},"day"):this.num(n.day,2);case"c":return this.num(n.weekday);case"ccc":return d("short",!0);case"cccc":return d("long",!0);case"ccccc":return d("narrow",!0);case"E":return this.num(n.weekday);case"EEE":return d("short",!1);case"EEEE":return d("long",!1);case"EEEEE":return d("narrow",!1);case"L":return s?o({month:"numeric",day:"numeric"},"month"):this.num(n.month);case"LL":return s?o({month:"2-digit",day:"numeric"},"month"):this.num(n.month,2);case"LLL":return c("short",!0);case"LLLL":return c("long",!0);case"LLLLL":return c("narrow",!0);case"M":return s?o({month:"numeric"},"month"):this.num(n.month);case"MM":return s?o({month:"2-digit"},"month"):this.num(n.month,2);case"MMM":return c("short",!1);case"MMMM":return c("long",!1);case"MMMMM":return c("narrow",!1);case"y":return s?o({year:"numeric"},"year"):this.num(n.year);case"yy":return s?o({year:"2-digit"},"year"):this.num(n.year.toString().slice(-2),2);case"yyyy":return s?o({year:"numeric"},"year"):this.num(n.year,4);case"yyyyyy":return s?o({year:"numeric"},"year"):this.num(n.year,6);case"G":return m("short");case"GG":return m("long");case"GGGGG":return m("narrow");case"kk":return this.num(n.weekYear.toString().slice(-2),2);case"kkkk":return this.num(n.weekYear,4);case"W":return this.num(n.weekNumber);case"WW":return this.num(n.weekNumber,2);case"o":return this.num(n.ordinal);case"ooo":return this.num(n.ordinal,3);case"q":return this.num(n.quarter);case"qq":return this.num(n.quarter,2);case"X":return this.num(Math.floor(n.ts/1e3));case"x":return this.num(n.ts);default:return u(h)}};return ka(Ne.parseFormat(r),f)}formatDurationFromString(n,r){const i=c=>{switch(c[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year";default:return null}},s=c=>d=>{const u=i(d);return u?this.num(c.get(u),d.length):d},o=Ne.parseFormat(r),l=o.reduce((c,{literal:d,val:u})=>d?c:c.concat(u),[]),a=n.shiftTo(...l.map(i).filter(c=>c));return ka(o,s(a))}}class ze{constructor(n,r){this.reason=n,this.explanation=r}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}class wn{get type(){throw new dt}get name(){throw new dt}get isUniversal(){throw new dt}offsetName(n,r){throw new dt}formatOffset(n,r){throw new dt}offset(n){throw new dt}equals(n){throw new dt}get isValid(){throw new dt}}let co=null;class uo extends wn{static get instance(){return co===null&&(co=new uo),co}get type(){return"system"}get name(){return new Intl.DateTimeFormat().resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(n,{format:r,locale:i}){return ca(n,r,i)}formatOffset(n,r){return er(this.offset(n),r)}offset(n){return-new Date(n).getTimezoneOffset()}equals(n){return n.type==="system"}get isValid(){return!0}}let nr={};function mp(e){return nr[e]||(nr[e]=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"})),nr[e]}const fp={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function hp(e,n){const r=e.format(n).replace(/\u200E/g,""),i=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(r),[,s,o,l,a,c,d,u]=i;return[l,s,o,a,c,d,u]}function pp(e,n){const r=e.formatToParts(n),i=[];for(let s=0;s<r.length;s++){const{type:o,value:l}=r[s],a=fp[o];o==="era"?i[a]=l:H(a)||(i[a]=parseInt(l,10))}return i}let rr={};class rt extends wn{static create(n){return rr[n]||(rr[n]=new rt(n)),rr[n]}static resetCache(){rr={},nr={}}static isValidSpecifier(n){return this.isValidZone(n)}static isValidZone(n){if(!n)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:n}).format(),!0}catch{return!1}}constructor(n){super(),this.zoneName=n,this.valid=rt.isValidZone(n)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(n,{format:r,locale:i}){return ca(n,r,i,this.name)}formatOffset(n,r){return er(this.offset(n),r)}offset(n){const r=new Date(n);if(isNaN(r))return NaN;const i=mp(this.name);let[s,o,l,a,c,d,u]=i.formatToParts?pp(i,r):hp(i,r);a==="BC"&&(s=-Math.abs(s)+1);const f=lo({year:s,month:o,day:l,hour:c===24?0:c,minute:d,second:u,millisecond:0});let h=+r;const g=h%1e3;return h-=g>=0?g:1e3+g,(f-h)/(60*1e3)}equals(n){return n.type==="iana"&&n.name===this.name}get isValid(){return this.valid}}let mo=null;class Ce extends wn{static get utcInstance(){return mo===null&&(mo=new Ce(0)),mo}static instance(n){return n===0?Ce.utcInstance:new Ce(n)}static parseSpecifier(n){if(n){const r=n.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(r)return new Ce(Qn(r[1],r[2]))}return null}constructor(n){super(),this.fixed=n}get type(){return"fixed"}get name(){return this.fixed===0?"UTC":`UTC${er(this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(n,r){return er(this.fixed,r)}get isUniversal(){return!0}offset(){return this.fixed}equals(n){return n.type==="fixed"&&n.fixed===this.fixed}get isValid(){return!0}}class gp extends wn{constructor(n){super(),this.zoneName=n}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}}function mt(e,n){if(H(e)||e===null)return n;if(e instanceof wn)return e;if(Jh(e)){const r=e.toLowerCase();return r==="local"||r==="system"?n:r==="utc"||r==="gmt"?Ce.utcInstance:Ce.parseSpecifier(r)||rt.create(e)}else return Mt(e)?Ce.instance(e):typeof e=="object"&&e.offset&&typeof e.offset=="number"?e:new gp(e)}let _a=()=>Date.now(),wa="system",xa=null,ba=null,Ca=null,Va;class ge{static get now(){return _a}static set now(n){_a=n}static set defaultZone(n){wa=n}static get defaultZone(){return mt(wa,uo.instance)}static get defaultLocale(){return xa}static set defaultLocale(n){xa=n}static get defaultNumberingSystem(){return ba}static set defaultNumberingSystem(n){ba=n}static get defaultOutputCalendar(){return Ca}static set defaultOutputCalendar(n){Ca=n}static get throwOnInvalid(){return Va}static set throwOnInvalid(n){Va=n}static resetCaches(){se.resetCache(),rt.resetCache()}}let Na={};function yp(e,n={}){const r=JSON.stringify([e,n]);let i=Na[r];return i||(i=new Intl.ListFormat(e,n),Na[r]=i),i}let fo={};function ho(e,n={}){const r=JSON.stringify([e,n]);let i=fo[r];return i||(i=new Intl.DateTimeFormat(e,n),fo[r]=i),i}let po={};function kp(e,n={}){const r=JSON.stringify([e,n]);let i=po[r];return i||(i=new Intl.NumberFormat(e,n),po[r]=i),i}let go={};function _p(e,n={}){const{base:r,...i}=n,s=JSON.stringify([e,i]);let o=go[s];return o||(o=new Intl.RelativeTimeFormat(e,n),go[s]=o),o}let xn=null;function wp(){return xn||(xn=new Intl.DateTimeFormat().resolvedOptions().locale,xn)}function xp(e){const n=e.indexOf("-u-");if(n===-1)return[e];{let r;const i=e.substring(0,n);try{r=ho(e).resolvedOptions()}catch{r=ho(i).resolvedOptions()}const{numberingSystem:s,calendar:o}=r;return[i,s,o]}}function bp(e,n,r){return(r||n)&&(e+="-u",r&&(e+=`-ca-${r}`),n&&(e+=`-nu-${n}`)),e}function Cp(e){const n=[];for(let r=1;r<=12;r++){const i=_.utc(2016,r,1);n.push(e(i))}return n}function Vp(e){const n=[];for(let r=1;r<=7;r++){const i=_.utc(2016,11,13+r);n.push(e(i))}return n}function or(e,n,r,i,s){const o=e.listingMode(r);return o==="error"?null:o==="en"?i(n):s(n)}function Np(e){return e.numberingSystem&&e.numberingSystem!=="latn"?!1:e.numberingSystem==="latn"||!e.locale||e.locale.startsWith("en")||new Intl.DateTimeFormat(e.intl).resolvedOptions().numberingSystem==="latn"}class Ep{constructor(n,r,i){this.padTo=i.padTo||0,this.floor=i.floor||!1;const{padTo:s,floor:o,...l}=i;if(!r||Object.keys(l).length>0){const a={useGrouping:!1,...i};i.padTo>0&&(a.minimumIntegerDigits=i.padTo),this.inf=kp(n,a)}}format(n){if(this.inf){const r=this.floor?Math.floor(n):n;return this.inf.format(r)}else{const r=this.floor?Math.floor(n):so(n,3);return fe(r,this.padTo)}}}class Bp{constructor(n,r,i){this.opts=i;let s;if(n.zone.isUniversal){const l=-1*(n.offset/60),a=l>=0?`Etc/GMT+${l}`:`Etc/GMT${l}`;n.offset!==0&&rt.create(a).valid?(s=a,this.dt=n):(s="UTC",i.timeZoneName?this.dt=n:this.dt=n.offset===0?n:_.fromMillis(n.ts+n.offset*60*1e3))}else n.zone.type==="system"?this.dt=n:(this.dt=n,s=n.zone.name);const o={...this.opts};s&&(o.timeZone=s),this.dtf=ho(r,o)}format(){return this.dtf.format(this.dt.toJSDate())}formatToParts(){return this.dtf.formatToParts(this.dt.toJSDate())}resolvedOptions(){return this.dtf.resolvedOptions()}}class Sp{constructor(n,r,i){this.opts={style:"long",...i},!r&&la()&&(this.rtf=_p(n,i))}format(n,r){return this.rtf?this.rtf.format(n,r):dp(r,n,this.opts.numeric,this.opts.style!=="long")}formatToParts(n,r){return this.rtf?this.rtf.formatToParts(n,r):[]}}class se{static fromOpts(n){return se.create(n.locale,n.numberingSystem,n.outputCalendar,n.defaultToEN)}static create(n,r,i,s=!1){const o=n||ge.defaultLocale,l=o||(s?"en-US":wp()),a=r||ge.defaultNumberingSystem,c=i||ge.defaultOutputCalendar;return new se(l,a,c,o)}static resetCache(){xn=null,fo={},po={},go={}}static fromObject({locale:n,numberingSystem:r,outputCalendar:i}={}){return se.create(n,r,i)}constructor(n,r,i,s){const[o,l,a]=xp(n);this.locale=o,this.numberingSystem=r||l||null,this.outputCalendar=i||a||null,this.intl=bp(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=s,this.fastNumbersCached=null}get fastNumbers(){return this.fastNumbersCached==null&&(this.fastNumbersCached=Np(this)),this.fastNumbersCached}listingMode(){const n=this.isEnglish(),r=(this.numberingSystem===null||this.numberingSystem==="latn")&&(this.outputCalendar===null||this.outputCalendar==="gregory");return n&&r?"en":"intl"}clone(n){return!n||Object.getOwnPropertyNames(n).length===0?this:se.create(n.locale||this.specifiedLocale,n.numberingSystem||this.numberingSystem,n.outputCalendar||this.outputCalendar,n.defaultToEN||!1)}redefaultToEN(n={}){return this.clone({...n,defaultToEN:!0})}redefaultToSystem(n={}){return this.clone({...n,defaultToEN:!1})}months(n,r=!1,i=!0){return or(this,n,i,ma,()=>{const s=r?{month:n,day:"numeric"}:{month:n},o=r?"format":"standalone";return this.monthsCache[o][n]||(this.monthsCache[o][n]=Cp(l=>this.extract(l,s,"month"))),this.monthsCache[o][n]})}weekdays(n,r=!1,i=!0){return or(this,n,i,pa,()=>{const s=r?{weekday:n,year:"numeric",month:"long",day:"numeric"}:{weekday:n},o=r?"format":"standalone";return this.weekdaysCache[o][n]||(this.weekdaysCache[o][n]=Vp(l=>this.extract(l,s,"weekday"))),this.weekdaysCache[o][n]})}meridiems(n=!0){return or(this,void 0,n,()=>ga,()=>{if(!this.meridiemCache){const r={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[_.utc(2016,11,13,9),_.utc(2016,11,13,19)].map(i=>this.extract(i,r,"dayperiod"))}return this.meridiemCache})}eras(n,r=!0){return or(this,n,r,ya,()=>{const i={era:n};return this.eraCache[n]||(this.eraCache[n]=[_.utc(-40,1,1),_.utc(2017,1,1)].map(s=>this.extract(s,i,"era"))),this.eraCache[n]})}extract(n,r,i){const s=this.dtFormatter(n,r),o=s.formatToParts(),l=o.find(a=>a.type.toLowerCase()===i);return l?l.value:null}numberFormatter(n={}){return new Ep(this.intl,n.forceSimple||this.fastNumbers,n)}dtFormatter(n,r={}){return new Bp(n,this.intl,r)}relFormatter(n={}){return new Sp(this.intl,this.isEnglish(),n)}listFormatter(n={}){return yp(this.intl,n)}isEnglish(){return this.locale==="en"||this.locale.toLowerCase()==="en-us"||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")}equals(n){return this.locale===n.locale&&this.numberingSystem===n.numberingSystem&&this.outputCalendar===n.outputCalendar}}function vt(...e){const n=e.reduce((r,i)=>r+i.source,"");return RegExp(`^${n}$`)}function It(...e){return n=>e.reduce(([r,i,s],o)=>{const[l,a,c]=o(n,s);return[{...r,...l},i||a,c]},[{},null,1]).slice(0,2)}function en(e,...n){if(e==null)return[null,null];for(const[r,i]of n){const s=r.exec(e);if(s)return i(s)}return[null,null]}function Ea(...e){return(n,r)=>{const i={};let s;for(s=0;s<e.length;s++)i[e[s]]=ut(n[r+s]);return[i,null,r+s]}}const Ba=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,yo=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,Sa=RegExp(`${yo.source}${Ba.source}?`),ko=RegExp(`(?:T${Sa.source})?`),Tp=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Dp=/(\d{4})-?W(\d\d)(?:-?(\d))?/,Op=/(\d{4})-?(\d{3})/,Mp=Ea("weekYear","weekNumber","weekDay"),Fp=Ea("year","ordinal"),Ip=/(\d{4})-(\d\d)-(\d\d)/,Ta=RegExp(`${yo.source} ?(?:${Ba.source}|(${vh.source}))?`),Ap=RegExp(`(?: ${Ta.source})?`);function tn(e,n,r){const i=e[n];return H(i)?r:ut(i)}function Da(e,n){return[{year:tn(e,n),month:tn(e,n+1,1),day:tn(e,n+2,1)},null,n+3]}function At(e,n){return[{hours:tn(e,n,0),minutes:tn(e,n+1,0),seconds:tn(e,n+2,0),milliseconds:io(e[n+3])},null,n+4]}function nn(e,n){const r=!e[n]&&!e[n+1],i=Qn(e[n+1],e[n+2]),s=r?null:Ce.instance(i);return[{},s,n+3]}function Oa(e,n){const r=e[n]?rt.create(e[n]):null;return[{},r,n+1]}const Lp=RegExp(`^T?${yo.source}$`),$p=/^-?P(?:(?:(-?\d{1,9}(?:\.\d{1,9})?)Y)?(?:(-?\d{1,9}(?:\.\d{1,9})?)M)?(?:(-?\d{1,9}(?:\.\d{1,9})?)W)?(?:(-?\d{1,9}(?:\.\d{1,9})?)D)?(?:T(?:(-?\d{1,9}(?:\.\d{1,9})?)H)?(?:(-?\d{1,9}(?:\.\d{1,9})?)M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,9}))?S)?)?)$/;function Pp(e){const[n,r,i,s,o,l,a,c,d]=e,u=n[0]==="-",m=c&&c[0]==="-",f=(h,g=!1)=>h!==void 0&&(g||h&&u)?-h:h;return[{years:f(Ft(r)),months:f(Ft(i)),weeks:f(Ft(s)),days:f(Ft(o)),hours:f(Ft(l)),minutes:f(Ft(a)),seconds:f(Ft(c),c==="-0"),milliseconds:f(io(d),m)}]}const Rp={GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function _o(e,n,r,i,s,o,l){const a={year:n.length===2?ao(ut(n)):ut(n),month:ua.indexOf(r)+1,day:ut(i),hour:ut(s),minute:ut(o)};return l&&(a.second=ut(l)),e&&(a.weekday=e.length>3?fa.indexOf(e)+1:ha.indexOf(e)+1),a}const Up=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;function jp(e){const[,n,r,i,s,o,l,a,c,d,u,m]=e,f=_o(n,s,i,r,o,l,a);let h;return c?h=Rp[c]:d?h=0:h=Qn(u,m),[f,new Ce(h)]}function qp(e){return e.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}const zp=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,Wp=/^(Monday|Tuesday|Wedsday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,Hp=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function Ma(e){const[,n,r,i,s,o,l,a]=e;return[_o(n,s,i,r,o,l,a),Ce.utcInstance]}function Gp(e){const[,n,r,i,s,o,l,a]=e;return[_o(n,a,r,i,s,o,l),Ce.utcInstance]}const Yp=vt(Tp,ko),Jp=vt(Dp,ko),Kp=vt(Op,ko),Zp=vt(Sa),Xp=It(Da,At,nn),Qp=It(Mp,At,nn),vp=It(Fp,At,nn),eg=It(At,nn);function tg(e){return en(e,[Yp,Xp],[Jp,Qp],[Kp,vp],[Zp,eg])}function ng(e){return en(qp(e),[Up,jp])}function rg(e){return en(e,[zp,Ma],[Wp,Ma],[Hp,Gp])}function og(e){return en(e,[$p,Pp])}const ig=It(At);function sg(e){return en(e,[Lp,ig])}const lg=vt(Ip,Ap),ag=vt(Ta),cg=It(Da,At,nn,Oa),dg=It(At,nn,Oa);function ug(e){return en(e,[lg,cg],[ag,dg])}const mg="Invalid Duration",Fa={weeks:{days:7,hours:7*24,minutes:7*24*60,seconds:7*24*60*60,milliseconds:7*24*60*60*1e3},days:{hours:24,minutes:24*60,seconds:24*60*60,milliseconds:24*60*60*1e3},hours:{minutes:60,seconds:60*60,milliseconds:60*60*1e3},minutes:{seconds:60,milliseconds:60*1e3},seconds:{milliseconds:1e3}},fg={years:{quarters:4,months:12,weeks:52,days:365,hours:365*24,minutes:365*24*60,seconds:365*24*60*60,milliseconds:365*24*60*60*1e3},quarters:{months:3,weeks:13,days:91,hours:91*24,minutes:91*24*60,seconds:91*24*60*60,milliseconds:91*24*60*60*1e3},months:{weeks:4,days:30,hours:30*24,minutes:30*24*60,seconds:30*24*60*60,milliseconds:30*24*60*60*1e3},...Fa},Ae=146097/400,rn=146097/4800,hg={years:{quarters:4,months:12,weeks:Ae/7,days:Ae,hours:Ae*24,minutes:Ae*24*60,seconds:Ae*24*60*60,milliseconds:Ae*24*60*60*1e3},quarters:{months:3,weeks:Ae/28,days:Ae/4,hours:Ae*24/4,minutes:Ae*24*60/4,seconds:Ae*24*60*60/4,milliseconds:Ae*24*60*60*1e3/4},months:{weeks:rn/7,days:rn,hours:rn*24,minutes:rn*24*60,seconds:rn*24*60*60,milliseconds:rn*24*60*60*1e3},...Fa},Lt=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],pg=Lt.slice(0).reverse();function $t(e,n,r=!1){const i={values:r?n.values:{...e.values,...n.values||{}},loc:e.loc.clone(n.loc),conversionAccuracy:n.conversionAccuracy||e.conversionAccuracy};return new Y(i)}function gg(e){return e<0?Math.floor(e):Math.ceil(e)}function Ia(e,n,r,i,s){const o=e[s][r],l=n[r]/o,a=Math.sign(l)===Math.sign(i[s]),c=!a&&i[s]!==0&&Math.abs(l)<=1?gg(l):Math.trunc(l);i[s]+=c,n[r]-=c*o}function yg(e,n){pg.reduce((r,i)=>H(n[i])?r:(r&&Ia(e,n,r,n,i),i),null)}class Y{constructor(n){const r=n.conversionAccuracy==="longterm"||!1;this.values=n.values,this.loc=n.loc||se.create(),this.conversionAccuracy=r?"longterm":"casual",this.invalid=n.invalid||null,this.matrix=r?hg:fg,this.isLuxonDuration=!0}static fromMillis(n,r){return Y.fromObject({milliseconds:n},r)}static fromObject(n,r={}){if(n==null||typeof n!="object")throw new Ie(`Duration.fromObject: argument expected to be an object, got ${n===null?"null":typeof n}`);return new Y({values:vn(n,Y.normalizeUnit),loc:se.fromObject(r),conversionAccuracy:r.conversionAccuracy})}static fromDurationLike(n){if(Mt(n))return Y.fromMillis(n);if(Y.isDuration(n))return n;if(typeof n=="object")return Y.fromObject(n);throw new Ie(`Unknown duration argument ${n} of type ${typeof n}`)}static fromISO(n,r){const[i]=og(n);return i?Y.fromObject(i,r):Y.invalid("unparsable",`the input "${n}" can't be parsed as ISO 8601`)}static fromISOTime(n,r){const[i]=sg(n);return i?Y.fromObject(i,r):Y.invalid("unparsable",`the input "${n}" can't be parsed as ISO 8601`)}static invalid(n,r=null){if(!n)throw new Ie("need to specify a reason the Duration is invalid");const i=n instanceof ze?n:new ze(n,r);if(ge.throwOnInvalid)throw new Hh(i);return new Y({invalid:i})}static normalizeUnit(n){const r={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[n&&n.toLowerCase()];if(!r)throw new jl(n);return r}static isDuration(n){return n&&n.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(n,r={}){const i={...r,floor:r.round!==!1&&r.floor!==!1};return this.isValid?Ne.create(this.loc,i).formatDurationFromString(this,n):mg}toHuman(n={}){const r=Lt.map(i=>{const s=this.values[i];return H(s)?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...n,unit:i.slice(0,-1)}).format(s)}).filter(i=>i);return this.loc.listFormatter({type:"conjunction",style:n.listStyle||"narrow",...n}).format(r)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let n="P";return this.years!==0&&(n+=this.years+"Y"),(this.months!==0||this.quarters!==0)&&(n+=this.months+this.quarters*3+"M"),this.weeks!==0&&(n+=this.weeks+"W"),this.days!==0&&(n+=this.days+"D"),(this.hours!==0||this.minutes!==0||this.seconds!==0||this.milliseconds!==0)&&(n+="T"),this.hours!==0&&(n+=this.hours+"H"),this.minutes!==0&&(n+=this.minutes+"M"),(this.seconds!==0||this.milliseconds!==0)&&(n+=so(this.seconds+this.milliseconds/1e3,3)+"S"),n==="P"&&(n+="T0S"),n}toISOTime(n={}){if(!this.isValid)return null;const r=this.toMillis();if(r<0||r>=864e5)return null;n={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...n};const i=this.shiftTo("hours","minutes","seconds","milliseconds");let s=n.format==="basic"?"hhmm":"hh:mm";(!n.suppressSeconds||i.seconds!==0||i.milliseconds!==0)&&(s+=n.format==="basic"?"ss":":ss",(!n.suppressMilliseconds||i.milliseconds!==0)&&(s+=".SSS"));let o=i.toFormat(s);return n.includePrefix&&(o="T"+o),o}toJSON(){return this.toISO()}toString(){return this.toISO()}toMillis(){return this.as("milliseconds")}valueOf(){return this.toMillis()}plus(n){if(!this.isValid)return this;const r=Y.fromDurationLike(n),i={};for(const s of Lt)(Qt(r.values,s)||Qt(this.values,s))&&(i[s]=r.get(s)+this.get(s));return $t(this,{values:i},!0)}minus(n){if(!this.isValid)return this;const r=Y.fromDurationLike(n);return this.plus(r.negate())}mapUnits(n){if(!this.isValid)return this;const r={};for(const i of Object.keys(this.values))r[i]=da(n(this.values[i],i));return $t(this,{values:r},!0)}get(n){return this[Y.normalizeUnit(n)]}set(n){if(!this.isValid)return this;const r={...this.values,...vn(n,Y.normalizeUnit)};return $t(this,{values:r})}reconfigure({locale:n,numberingSystem:r,conversionAccuracy:i}={}){const s=this.loc.clone({locale:n,numberingSystem:r}),o={loc:s};return i&&(o.conversionAccuracy=i),$t(this,o)}as(n){return this.isValid?this.shiftTo(n).get(n):NaN}normalize(){if(!this.isValid)return this;const n=this.toObject();return yg(this.matrix,n),$t(this,{values:n},!0)}shiftTo(...n){if(!this.isValid)return this;if(n.length===0)return this;n=n.map(l=>Y.normalizeUnit(l));const r={},i={},s=this.toObject();let o;for(const l of Lt)if(n.indexOf(l)>=0){o=l;let a=0;for(const d in i)a+=this.matrix[d][l]*i[d],i[d]=0;Mt(s[l])&&(a+=s[l]);const c=Math.trunc(a);r[l]=c,i[l]=(a*1e3-c*1e3)/1e3;for(const d in s)Lt.indexOf(d)>Lt.indexOf(l)&&Ia(this.matrix,s,d,r,l)}else Mt(s[l])&&(i[l]=s[l]);for(const l in i)i[l]!==0&&(r[o]+=l===o?i[l]:i[l]/this.matrix[o][l]);return $t(this,{values:r},!0).normalize()}negate(){if(!this.isValid)return this;const n={};for(const r of Object.keys(this.values))n[r]=this.values[r]===0?0:-this.values[r];return $t(this,{values:n},!0)}get years(){return this.isValid?this.values.years||0:NaN}get quarters(){return this.isValid?this.values.quarters||0:NaN}get months(){return this.isValid?this.values.months||0:NaN}get weeks(){return this.isValid?this.values.weeks||0:NaN}get days(){return this.isValid?this.values.days||0:NaN}get hours(){return this.isValid?this.values.hours||0:NaN}get minutes(){return this.isValid?this.values.minutes||0:NaN}get seconds(){return this.isValid?this.values.seconds||0:NaN}get milliseconds(){return this.isValid?this.values.milliseconds||0:NaN}get isValid(){return this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(n){if(!this.isValid||!n.isValid||!this.loc.equals(n.loc))return!1;function r(i,s){return i===void 0||i===0?s===void 0||s===0:i===s}for(const i of Lt)if(!r(this.values[i],n.values[i]))return!1;return!0}}const bn="Invalid Interval";function kg(e,n){return!e||!e.isValid?ce.invalid("missing or invalid start"):!n||!n.isValid?ce.invalid("missing or invalid end"):n<e?ce.invalid("end before start",`The end of an interval must be after its start, but you had start=${e.toISO()} and end=${n.toISO()}`):null}class ce{constructor(n){this.s=n.start,this.e=n.end,this.invalid=n.invalid||null,this.isLuxonInterval=!0}static invalid(n,r=null){if(!n)throw new Ie("need to specify a reason the Interval is invalid");const i=n instanceof ze?n:new ze(n,r);if(ge.throwOnInvalid)throw new Wh(i);return new ce({invalid:i})}static fromDateTimes(n,r){const i=Nn(n),s=Nn(r),o=kg(i,s);return o??new ce({start:i,end:s})}static after(n,r){const i=Y.fromDurationLike(r),s=Nn(n);return ce.fromDateTimes(s,s.plus(i))}static before(n,r){const i=Y.fromDurationLike(r),s=Nn(n);return ce.fromDateTimes(s.minus(i),s)}static fromISO(n,r){const[i,s]=(n||"").split("/",2);if(i&&s){let o,l;try{o=_.fromISO(i,r),l=o.isValid}catch{l=!1}let a,c;try{a=_.fromISO(s,r),c=a.isValid}catch{c=!1}if(l&&c)return ce.fromDateTimes(o,a);if(l){const d=Y.fromISO(s,r);if(d.isValid)return ce.after(o,d)}else if(c){const d=Y.fromISO(i,r);if(d.isValid)return ce.before(a,d)}}return ce.invalid("unparsable",`the input "${n}" can't be parsed as ISO 8601`)}static isInterval(n){return n&&n.isLuxonInterval||!1}get start(){return this.isValid?this.s:null}get end(){return this.isValid?this.e:null}get isValid(){return this.invalidReason===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}length(n="milliseconds"){return this.isValid?this.toDuration(n).get(n):NaN}count(n="milliseconds"){if(!this.isValid)return NaN;const r=this.start.startOf(n),i=this.end.startOf(n);return Math.floor(i.diff(r,n).get(n))+1}hasSame(n){return this.isValid?this.isEmpty()||this.e.minus(1).hasSame(this.s,n):!1}isEmpty(){return this.s.valueOf()===this.e.valueOf()}isAfter(n){return this.isValid?this.s>n:!1}isBefore(n){return this.isValid?this.e<=n:!1}contains(n){return this.isValid?this.s<=n&&this.e>n:!1}set({start:n,end:r}={}){return this.isValid?ce.fromDateTimes(n||this.s,r||this.e):this}splitAt(...n){if(!this.isValid)return[];const r=n.map(Nn).filter(l=>this.contains(l)).sort(),i=[];let{s}=this,o=0;for(;s<this.e;){const l=r[o]||this.e,a=+l>+this.e?this.e:l;i.push(ce.fromDateTimes(s,a)),s=a,o+=1}return i}splitBy(n){const r=Y.fromDurationLike(n);if(!this.isValid||!r.isValid||r.as("milliseconds")===0)return[];let{s:i}=this,s=1,o;const l=[];for(;i<this.e;){const a=this.start.plus(r.mapUnits(c=>c*s));o=+a>+this.e?this.e:a,l.push(ce.fromDateTimes(i,o)),i=o,s+=1}return l}divideEqually(n){return this.isValid?this.splitBy(this.length()/n).slice(0,n):[]}overlaps(n){return this.e>n.s&&this.s<n.e}abutsStart(n){return this.isValid?+this.e==+n.s:!1}abutsEnd(n){return this.isValid?+n.e==+this.s:!1}engulfs(n){return this.isValid?this.s<=n.s&&this.e>=n.e:!1}equals(n){return!this.isValid||!n.isValid?!1:this.s.equals(n.s)&&this.e.equals(n.e)}intersection(n){if(!this.isValid)return this;const r=this.s>n.s?this.s:n.s,i=this.e<n.e?this.e:n.e;return r>=i?null:ce.fromDateTimes(r,i)}union(n){if(!this.isValid)return this;const r=this.s<n.s?this.s:n.s,i=this.e>n.e?this.e:n.e;return ce.fromDateTimes(r,i)}static merge(n){const[r,i]=n.sort((s,o)=>s.s-o.s).reduce(([s,o],l)=>o?o.overlaps(l)||o.abutsStart(l)?[s,o.union(l)]:[s.concat([o]),l]:[s,l],[[],null]);return i&&r.push(i),r}static xor(n){let r=null,i=0;const s=[],o=n.map(c=>[{time:c.s,type:"s"},{time:c.e,type:"e"}]),l=Array.prototype.concat(...o),a=l.sort((c,d)=>c.time-d.time);for(const c of a)i+=c.type==="s"?1:-1,i===1?r=c.time:(r&&+r!=+c.time&&s.push(ce.fromDateTimes(r,c.time)),r=null);return ce.merge(s)}difference(...n){return ce.xor([this].concat(n)).map(r=>this.intersection(r)).filter(r=>r&&!r.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} – ${this.e.toISO()})`:bn}toISO(n){return this.isValid?`${this.s.toISO(n)}/${this.e.toISO(n)}`:bn}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:bn}toISOTime(n){return this.isValid?`${this.s.toISOTime(n)}/${this.e.toISOTime(n)}`:bn}toFormat(n,{separator:r=" – "}={}){return this.isValid?`${this.s.toFormat(n)}${r}${this.e.toFormat(n)}`:bn}toDuration(n,r){return this.isValid?this.e.diff(this.s,n,r):Y.invalid(this.invalidReason)}mapEndpoints(n){return ce.fromDateTimes(n(this.s),n(this.e))}}let ir=class{static hasDST(n=ge.defaultZone){const r=_.now().setZone(n).set({month:12});return!n.isUniversal&&r.offset!==r.set({month:6}).offset}static isValidIANAZone(n){return rt.isValidZone(n)}static normalizeZone(n){return mt(n,ge.defaultZone)}static months(n="long",{locale:r=null,numberingSystem:i=null,locObj:s=null,outputCalendar:o="gregory"}={}){return(s||se.create(r,i,o)).months(n)}static monthsFormat(n="long",{locale:r=null,numberingSystem:i=null,locObj:s=null,outputCalendar:o="gregory"}={}){return(s||se.create(r,i,o)).months(n,!0)}static weekdays(n="long",{locale:r=null,numberingSystem:i=null,locObj:s=null}={}){return(s||se.create(r,i,null)).weekdays(n)}static weekdaysFormat(n="long",{locale:r=null,numberingSystem:i=null,locObj:s=null}={}){return(s||se.create(r,i,null)).weekdays(n,!0)}static meridiems({locale:n=null}={}){return se.create(n).meridiems()}static eras(n="short",{locale:r=null}={}){return se.create(r,null,"gregory").eras(n)}static features(){return{relative:la()}}};function Aa(e,n){const r=s=>s.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),i=r(n)-r(e);return Math.floor(Y.fromMillis(i).as("days"))}function _g(e,n,r){const i=[["years",(a,c)=>c.year-a.year],["quarters",(a,c)=>c.quarter-a.quarter],["months",(a,c)=>c.month-a.month+(c.year-a.year)*12],["weeks",(a,c)=>{const d=Aa(a,c);return(d-d%7)/7}],["days",Aa]],s={};let o,l;for(const[a,c]of i)if(r.indexOf(a)>=0){o=a;let d=c(e,n);l=e.plus({[a]:d}),l>n?(e=e.plus({[a]:d-1}),d-=1):e=l,s[a]=d}return[e,s,l,o]}function wg(e,n,r,i){let[s,o,l,a]=_g(e,n,r);const c=n-s,d=r.filter(m=>["hours","minutes","seconds","milliseconds"].indexOf(m)>=0);d.length===0&&(l<n&&(l=s.plus({[a]:1})),l!==s&&(o[a]=(o[a]||0)+c/(l-s)));const u=Y.fromObject(o,i);return d.length>0?Y.fromMillis(c,i).shiftTo(...d).plus(u):u}const wo={arab:"[٠-٩]",arabext:"[۰-۹]",bali:"[᭐-᭙]",beng:"[০-৯]",deva:"[०-९]",fullwide:"[0-9]",gujr:"[૦-૯]",hanidec:"[〇|一|二|三|四|五|六|七|八|九]",khmr:"[០-៩]",knda:"[೦-೯]",laoo:"[໐-໙]",limb:"[᥆-᥏]",mlym:"[൦-൯]",mong:"[᠐-᠙]",mymr:"[၀-၉]",orya:"[୦-୯]",tamldec:"[௦-௯]",telu:"[౦-౯]",thai:"[๐-๙]",tibt:"[༠-༩]",latn:"\\d"},La={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},xg=wo.hanidec.replace(/[\[|\]]/g,"").split("");function bg(e){let n=parseInt(e,10);if(isNaN(n)){n="";for(let r=0;r<e.length;r++){const i=e.charCodeAt(r);if(e[r].search(wo.hanidec)!==-1)n+=xg.indexOf(e[r]);else for(const s in La){const[o,l]=La[s];i>=o&&i<=l&&(n+=i-o)}}return parseInt(n,10)}else return n}function We({numberingSystem:e},n=""){return new RegExp(`${wo[e||"latn"]}${n}`)}const Cg="missing Intl.DateTimeFormat.formatToParts support";function Z(e,n=r=>r){return{regex:e,deser:([r])=>n(bg(r))}}const $a="( | )",Pa=new RegExp($a,"g");function Vg(e){return e.replace(/\./g,"\\.?").replace(Pa,$a)}function Ra(e){return e.replace(/\./g,"").replace(Pa," ").toLowerCase()}function He(e,n){return e===null?null:{regex:RegExp(e.map(Vg).join("|")),deser:([r])=>e.findIndex(i=>Ra(r)===Ra(i))+n}}function Ua(e,n){return{regex:e,deser:([,r,i])=>Qn(r,i),groups:n}}function xo(e){return{regex:e,deser:([n])=>n}}function Ng(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function Eg(e,n){const r=We(n),i=We(n,"{2}"),s=We(n,"{3}"),o=We(n,"{4}"),l=We(n,"{6}"),a=We(n,"{1,2}"),c=We(n,"{1,3}"),d=We(n,"{1,6}"),u=We(n,"{1,9}"),m=We(n,"{2,4}"),f=We(n,"{4,6}"),h=y=>({regex:RegExp(Ng(y.val)),deser:([k])=>k,literal:!0}),p=(y=>{if(e.literal)return h(y);switch(y.val){case"G":return He(n.eras("short",!1),0);case"GG":return He(n.eras("long",!1),0);case"y":return Z(d);case"yy":return Z(m,ao);case"yyyy":return Z(o);case"yyyyy":return Z(f);case"yyyyyy":return Z(l);case"M":return Z(a);case"MM":return Z(i);case"MMM":return He(n.months("short",!0,!1),1);case"MMMM":return He(n.months("long",!0,!1),1);case"L":return Z(a);case"LL":return Z(i);case"LLL":return He(n.months("short",!1,!1),1);case"LLLL":return He(n.months("long",!1,!1),1);case"d":return Z(a);case"dd":return Z(i);case"o":return Z(c);case"ooo":return Z(s);case"HH":return Z(i);case"H":return Z(a);case"hh":return Z(i);case"h":return Z(a);case"mm":return Z(i);case"m":return Z(a);case"q":return Z(a);case"qq":return Z(i);case"s":return Z(a);case"ss":return Z(i);case"S":return Z(c);case"SSS":return Z(s);case"u":return xo(u);case"uu":return xo(a);case"uuu":return Z(r);case"a":return He(n.meridiems(),0);case"kkkk":return Z(o);case"kk":return Z(m,ao);case"W":return Z(a);case"WW":return Z(i);case"E":case"c":return Z(r);case"EEE":return He(n.weekdays("short",!1,!1),1);case"EEEE":return He(n.weekdays("long",!1,!1),1);case"ccc":return He(n.weekdays("short",!0,!1),1);case"cccc":return He(n.weekdays("long",!0,!1),1);case"Z":case"ZZ":return Ua(new RegExp(`([+-]${a.source})(?::(${i.source}))?`),2);case"ZZZ":return Ua(new RegExp(`([+-]${a.source})(${i.source})?`),2);case"z":return xo(/[a-z_+-/]{1,256}?/i);default:return h(y)}})(e)||{invalidReason:Cg};return p.token=e,p}const Bg={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour:{numeric:"h","2-digit":"hh"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"}};function Sg(e,n,r){const{type:i,value:s}=e;if(i==="literal")return{literal:!0,val:s};const o=r[i];let l=Bg[i];if(typeof l=="object"&&(l=l[o]),l)return{literal:!1,val:l}}function Tg(e){return[`^${e.map(r=>r.regex).reduce((r,i)=>`${r}(${i.source})`,"")}$`,e]}function Dg(e,n,r){const i=e.match(n);if(i){const s={};let o=1;for(const l in r)if(Qt(r,l)){const a=r[l],c=a.groups?a.groups+1:1;!a.literal&&a.token&&(s[a.token.val[0]]=a.deser(i.slice(o,o+c))),o+=c}return[i,s]}else return[i,{}]}function Og(e){const n=o=>{switch(o){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}};let r=null,i;return H(e.z)||(r=rt.create(e.z)),H(e.Z)||(r||(r=new Ce(e.Z)),i=e.Z),H(e.q)||(e.M=(e.q-1)*3+1),H(e.h)||(e.h<12&&e.a===1?e.h+=12:e.h===12&&e.a===0&&(e.h=0)),e.G===0&&e.y&&(e.y=-e.y),H(e.u)||(e.S=io(e.u)),[Object.keys(e).reduce((o,l)=>{const a=n(l);return a&&(o[a]=e[l]),o},{}),r,i]}let bo=null;function Mg(){return bo||(bo=_.fromMillis(1555555555555)),bo}function Fg(e,n){if(e.literal)return e;const r=Ne.macroTokenToFormatOpts(e.val);if(!r)return e;const o=Ne.create(n,r).formatDateTimeParts(Mg()).map(l=>Sg(l,n,r));return o.includes(void 0)?e:o}function Ig(e,n){return Array.prototype.concat(...e.map(r=>Fg(r,n)))}function ja(e,n,r){const i=Ig(Ne.parseFormat(r),e),s=i.map(l=>Eg(l,e)),o=s.find(l=>l.invalidReason);if(o)return{input:n,tokens:i,invalidReason:o.invalidReason};{const[l,a]=Tg(s),c=RegExp(l,"i"),[d,u]=Dg(n,c,a),[m,f,h]=u?Og(u):[null,null,void 0];if(Qt(u,"a")&&Qt(u,"H"))throw new yn("Can't include meridiem when specifying 24-hour format");return{input:n,tokens:i,regex:c,rawMatches:d,matches:u,result:m,zone:f,specificOffset:h}}}function Ag(e,n,r){const{result:i,zone:s,specificOffset:o,invalidReason:l}=ja(e,n,r);return[i,s,o,l]}const qa=[0,31,59,90,120,151,181,212,243,273,304,334],za=[0,31,60,91,121,152,182,213,244,274,305,335];function Le(e,n){return new ze("unit out of range",`you specified ${n} (of type ${typeof n}) as a ${e}, which is invalid`)}function Wa(e,n,r){const i=new Date(Date.UTC(e,n-1,r));e<100&&e>=0&&i.setUTCFullYear(i.getUTCFullYear()-1900);const s=i.getUTCDay();return s===0?7:s}function Ha(e,n,r){return r+(kn(e)?za:qa)[n-1]}function Ga(e,n){const r=kn(e)?za:qa,i=r.findIndex(o=>o<n),s=n-r[i];return{month:i+1,day:s}}function Co(e){const{year:n,month:r,day:i}=e,s=Ha(n,r,i),o=Wa(n,r,i);let l=Math.floor((s-o+10)/7),a;return l<1?(a=n-1,l=Xn(a)):l>Xn(n)?(a=n+1,l=1):a=n,{weekYear:a,weekNumber:l,weekday:o,...tr(e)}}function Ya(e){const{weekYear:n,weekNumber:r,weekday:i}=e,s=Wa(n,1,4),o=_n(n);let l=r*7+i-s-3,a;l<1?(a=n-1,l+=_n(a)):l>o?(a=n+1,l-=_n(n)):a=n;const{month:c,day:d}=Ga(a,l);return{year:a,month:c,day:d,...tr(e)}}function Vo(e){const{year:n,month:r,day:i}=e,s=Ha(n,r,i);return{year:n,ordinal:s,...tr(e)}}function Ja(e){const{year:n,ordinal:r}=e,{month:i,day:s}=Ga(n,r);return{year:n,month:i,day:s,...tr(e)}}function Lg(e){const n=Kn(e.weekYear),r=nt(e.weekNumber,1,Xn(e.weekYear)),i=nt(e.weekday,1,7);return n?r?i?!1:Le("weekday",e.weekday):Le("week",e.week):Le("weekYear",e.weekYear)}function $g(e){const n=Kn(e.year),r=nt(e.ordinal,1,_n(e.year));return n?r?!1:Le("ordinal",e.ordinal):Le("year",e.year)}function Ka(e){const n=Kn(e.year),r=nt(e.month,1,12),i=nt(e.day,1,Zn(e.year,e.month));return n?r?i?!1:Le("day",e.day):Le("month",e.month):Le("year",e.year)}function Za(e){const{hour:n,minute:r,second:i,millisecond:s}=e,o=nt(n,0,23)||n===24&&r===0&&i===0&&s===0,l=nt(r,0,59),a=nt(i,0,59),c=nt(s,0,999);return o?l?a?c?!1:Le("millisecond",s):Le("second",i):Le("minute",r):Le("hour",n)}const No="Invalid DateTime",Pg=864e13;function sr(e){return new ze("unsupported zone",`the zone "${e.name}" is not supported`)}function Eo(e){return e.weekData===null&&(e.weekData=Co(e.c)),e.weekData}function Cn(e,n){const r={ts:e.ts,zone:e.zone,c:e.c,o:e.o,loc:e.loc,invalid:e.invalid};return new _({...r,...n,old:r})}function Xa(e,n,r){let i=e-n*60*1e3;const s=r.offset(i);if(n===s)return[i,n];i-=(s-n)*60*1e3;const o=r.offset(i);return s===o?[i,s]:[e-Math.min(s,o)*60*1e3,Math.max(s,o)]}function Qa(e,n){e+=n*60*1e3;const r=new Date(e);return{year:r.getUTCFullYear(),month:r.getUTCMonth()+1,day:r.getUTCDate(),hour:r.getUTCHours(),minute:r.getUTCMinutes(),second:r.getUTCSeconds(),millisecond:r.getUTCMilliseconds()}}function lr(e,n,r){return Xa(lo(e),n,r)}function va(e,n){const r=e.o,i=e.c.year+Math.trunc(n.years),s=e.c.month+Math.trunc(n.months)+Math.trunc(n.quarters)*3,o={...e.c,year:i,month:s,day:Math.min(e.c.day,Zn(i,s))+Math.trunc(n.days)+Math.trunc(n.weeks)*7},l=Y.fromObject({years:n.years-Math.trunc(n.years),quarters:n.quarters-Math.trunc(n.quarters),months:n.months-Math.trunc(n.months),weeks:n.weeks-Math.trunc(n.weeks),days:n.days-Math.trunc(n.days),hours:n.hours,minutes:n.minutes,seconds:n.seconds,milliseconds:n.milliseconds}).as("milliseconds"),a=lo(o);let[c,d]=Xa(a,r,e.zone);return l!==0&&(c+=l,d=e.zone.offset(c)),{ts:c,o:d}}function Vn(e,n,r,i,s,o){const{setZone:l,zone:a}=r;if(e&&Object.keys(e).length!==0){const c=n||a,d=_.fromObject(e,{...r,zone:c,specificOffset:o});return l?d:d.setZone(a)}else return _.invalid(new ze("unparsable",`the input "${s}" can't be parsed as ${i}`))}function ar(e,n,r=!0){return e.isValid?Ne.create(se.create("en-US"),{allowZ:r,forceSimple:!0}).formatDateTimeFromString(e,n):null}function Bo(e,n){const r=e.c.year>9999||e.c.year<0;let i="";return r&&e.c.year>=0&&(i+="+"),i+=fe(e.c.year,r?6:4),n?(i+="-",i+=fe(e.c.month),i+="-",i+=fe(e.c.day)):(i+=fe(e.c.month),i+=fe(e.c.day)),i}function ec(e,n,r,i,s){let o=fe(e.c.hour);return n?(o+=":",o+=fe(e.c.minute),(e.c.second!==0||!r)&&(o+=":")):o+=fe(e.c.minute),(e.c.second!==0||!r)&&(o+=fe(e.c.second),(e.c.millisecond!==0||!i)&&(o+=".",o+=fe(e.c.millisecond,3))),s&&(e.isOffsetFixed&&e.offset===0?o+="Z":e.o<0?(o+="-",o+=fe(Math.trunc(-e.o/60)),o+=":",o+=fe(Math.trunc(-e.o%60))):(o+="+",o+=fe(Math.trunc(e.o/60)),o+=":",o+=fe(Math.trunc(e.o%60)))),o}const tc={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},Rg={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},Ug={ordinal:1,hour:0,minute:0,second:0,millisecond:0},nc=["year","month","day","hour","minute","second","millisecond"],jg=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],qg=["year","ordinal","hour","minute","second","millisecond"];function rc(e){const n={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[e.toLowerCase()];if(!n)throw new jl(e);return n}function oc(e,n){const r=mt(n.zone,ge.defaultZone),i=se.fromObject(n),s=ge.now();let o,l;if(H(e.year))o=s;else{for(const d of nc)H(e[d])&&(e[d]=tc[d]);const a=Ka(e)||Za(e);if(a)return _.invalid(a);const c=r.offset(s);[o,l]=lr(e,c,r)}return new _({ts:o,zone:r,loc:i,o:l})}function ic(e,n,r){const i=H(r.round)?!0:r.round,s=(l,a)=>(l=so(l,i||r.calendary?0:2,!0),n.loc.clone(r).relFormatter(r).format(l,a)),o=l=>r.calendary?n.hasSame(e,l)?0:n.startOf(l).diff(e.startOf(l),l).get(l):n.diff(e,l).get(l);if(r.unit)return s(o(r.unit),r.unit);for(const l of r.units){const a=o(l);if(Math.abs(a)>=1)return s(a,l)}return s(e>n?-0:0,r.units[r.units.length-1])}function sc(e){let n={},r;return e.length>0&&typeof e[e.length-1]=="object"?(n=e[e.length-1],r=Array.from(e).slice(0,e.length-1)):r=Array.from(e),[n,r]}class _{constructor(n){const r=n.zone||ge.defaultZone;let i=n.invalid||(Number.isNaN(n.ts)?new ze("invalid input"):null)||(r.isValid?null:sr(r));this.ts=H(n.ts)?ge.now():n.ts;let s=null,o=null;if(!i)if(n.old&&n.old.ts===this.ts&&n.old.zone.equals(r))[s,o]=[n.old.c,n.old.o];else{const a=r.offset(this.ts);s=Qa(this.ts,a),i=Number.isNaN(s.year)?new ze("invalid input"):null,s=i?null:s,o=i?null:a}this._zone=r,this.loc=n.loc||se.create(),this.invalid=i,this.weekData=null,this.c=s,this.o=o,this.isLuxonDateTime=!0}static now(){return new _({})}static local(){const[n,r]=sc(arguments),[i,s,o,l,a,c,d]=r;return oc({year:i,month:s,day:o,hour:l,minute:a,second:c,millisecond:d},n)}static utc(){const[n,r]=sc(arguments),[i,s,o,l,a,c,d]=r;return n.zone=Ce.utcInstance,oc({year:i,month:s,day:o,hour:l,minute:a,second:c,millisecond:d},n)}static fromJSDate(n,r={}){const i=Kh(n)?n.valueOf():NaN;if(Number.isNaN(i))return _.invalid("invalid input");const s=mt(r.zone,ge.defaultZone);return s.isValid?new _({ts:i,zone:s,loc:se.fromObject(r)}):_.invalid(sr(s))}static fromMillis(n,r={}){if(Mt(n))return n<-864e13||n>Pg?_.invalid("Timestamp out of range"):new _({ts:n,zone:mt(r.zone,ge.defaultZone),loc:se.fromObject(r)});throw new Ie(`fromMillis requires a numerical input, but received a ${typeof n} with value ${n}`)}static fromSeconds(n,r={}){if(Mt(n))return new _({ts:n*1e3,zone:mt(r.zone,ge.defaultZone),loc:se.fromObject(r)});throw new Ie("fromSeconds requires a numerical input")}static fromObject(n,r={}){n=n||{};const i=mt(r.zone,ge.defaultZone);if(!i.isValid)return _.invalid(sr(i));const s=ge.now(),o=H(r.specificOffset)?i.offset(s):r.specificOffset,l=vn(n,rc),a=!H(l.ordinal),c=!H(l.year),d=!H(l.month)||!H(l.day),u=c||d,m=l.weekYear||l.weekNumber,f=se.fromObject(r);if((u||a)&&m)throw new yn("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(d&&a)throw new yn("Can't mix ordinal dates with month/day");const h=m||l.weekday&&!u;let g,p,y=Qa(s,o);h?(g=jg,p=Rg,y=Co(y)):a?(g=qg,p=Ug,y=Vo(y)):(g=nc,p=tc);let k=!1;for(const F of g){const O=l[F];H(O)?k?l[F]=p[F]:l[F]=y[F]:k=!0}const x=h?Lg(l):a?$g(l):Ka(l),S=x||Za(l);if(S)return _.invalid(S);const I=h?Ya(l):a?Ja(l):l,[P,q]=lr(I,o,i),b=new _({ts:P,zone:i,o:q,loc:f});return l.weekday&&u&&n.weekday!==b.weekday?_.invalid("mismatched weekday",`you can't specify both a weekday of ${l.weekday} and a date of ${b.toISO()}`):b}static fromISO(n,r={}){const[i,s]=tg(n);return Vn(i,s,r,"ISO 8601",n)}static fromRFC2822(n,r={}){const[i,s]=ng(n);return Vn(i,s,r,"RFC 2822",n)}static fromHTTP(n,r={}){const[i,s]=rg(n);return Vn(i,s,r,"HTTP",r)}static fromFormat(n,r,i={}){if(H(n)||H(r))throw new Ie("fromFormat requires an input string and a format");const{locale:s=null,numberingSystem:o=null}=i,l=se.fromOpts({locale:s,numberingSystem:o,defaultToEN:!0}),[a,c,d,u]=Ag(l,n,r);return u?_.invalid(u):Vn(a,c,i,`format ${r}`,n,d)}static fromString(n,r,i={}){return _.fromFormat(n,r,i)}static fromSQL(n,r={}){const[i,s]=ug(n);return Vn(i,s,r,"SQL",n)}static invalid(n,r=null){if(!n)throw new Ie("need to specify a reason the DateTime is invalid");const i=n instanceof ze?n:new ze(n,r);if(ge.throwOnInvalid)throw new zh(i);return new _({invalid:i})}static isDateTime(n){return n&&n.isLuxonDateTime||!1}get(n){return this[n]}get isValid(){return this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}get outputCalendar(){return this.isValid?this.loc.outputCalendar:null}get zone(){return this._zone}get zoneName(){return this.isValid?this.zone.name:null}get year(){return this.isValid?this.c.year:NaN}get quarter(){return this.isValid?Math.ceil(this.c.month/3):NaN}get month(){return this.isValid?this.c.month:NaN}get day(){return this.isValid?this.c.day:NaN}get hour(){return this.isValid?this.c.hour:NaN}get minute(){return this.isValid?this.c.minute:NaN}get second(){return this.isValid?this.c.second:NaN}get millisecond(){return this.isValid?this.c.millisecond:NaN}get weekYear(){return this.isValid?Eo(this).weekYear:NaN}get weekNumber(){return this.isValid?Eo(this).weekNumber:NaN}get weekday(){return this.isValid?Eo(this).weekday:NaN}get ordinal(){return this.isValid?Vo(this.c).ordinal:NaN}get monthShort(){return this.isValid?ir.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?ir.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?ir.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?ir.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}get offset(){return this.isValid?+this.o:NaN}get offsetNameShort(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}get offsetNameLong(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}get isOffsetFixed(){return this.isValid?this.zone.isUniversal:null}get isInDST(){return this.isOffsetFixed?!1:this.offset>this.set({month:1}).offset||this.offset>this.set({month:5}).offset}get isInLeapYear(){return kn(this.year)}get daysInMonth(){return Zn(this.year,this.month)}get daysInYear(){return this.isValid?_n(this.year):NaN}get weeksInWeekYear(){return this.isValid?Xn(this.weekYear):NaN}resolvedLocaleOptions(n={}){const{locale:r,numberingSystem:i,calendar:s}=Ne.create(this.loc.clone(n),n).resolvedOptions(this);return{locale:r,numberingSystem:i,outputCalendar:s}}toUTC(n=0,r={}){return this.setZone(Ce.instance(n),r)}toLocal(){return this.setZone(ge.defaultZone)}setZone(n,{keepLocalTime:r=!1,keepCalendarTime:i=!1}={}){if(n=mt(n,ge.defaultZone),n.equals(this.zone))return this;if(n.isValid){let s=this.ts;if(r||i){const o=n.offset(this.ts),l=this.toObject();[s]=lr(l,o,n)}return Cn(this,{ts:s,zone:n})}else return _.invalid(sr(n))}reconfigure({locale:n,numberingSystem:r,outputCalendar:i}={}){const s=this.loc.clone({locale:n,numberingSystem:r,outputCalendar:i});return Cn(this,{loc:s})}setLocale(n){return this.reconfigure({locale:n})}set(n){if(!this.isValid)return this;const r=vn(n,rc),i=!H(r.weekYear)||!H(r.weekNumber)||!H(r.weekday),s=!H(r.ordinal),o=!H(r.year),l=!H(r.month)||!H(r.day),a=o||l,c=r.weekYear||r.weekNumber;if((a||s)&&c)throw new yn("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(l&&s)throw new yn("Can't mix ordinal dates with month/day");let d;i?d=Ya({...Co(this.c),...r}):H(r.ordinal)?(d={...this.toObject(),...r},H(r.day)&&(d.day=Math.min(Zn(d.year,d.month),d.day))):d=Ja({...Vo(this.c),...r});const[u,m]=lr(d,this.o,this.zone);return Cn(this,{ts:u,o:m})}plus(n){if(!this.isValid)return this;const r=Y.fromDurationLike(n);return Cn(this,va(this,r))}minus(n){if(!this.isValid)return this;const r=Y.fromDurationLike(n).negate();return Cn(this,va(this,r))}startOf(n){if(!this.isValid)return this;const r={},i=Y.normalizeUnit(n);switch(i){case"years":r.month=1;case"quarters":case"months":r.day=1;case"weeks":case"days":r.hour=0;case"hours":r.minute=0;case"minutes":r.second=0;case"seconds":r.millisecond=0;break}if(i==="weeks"&&(r.weekday=1),i==="quarters"){const s=Math.ceil(this.month/3);r.month=(s-1)*3+1}return this.set(r)}endOf(n){return this.isValid?this.plus({[n]:1}).startOf(n).minus(1):this}toFormat(n,r={}){return this.isValid?Ne.create(this.loc.redefaultToEN(r)).formatDateTimeFromString(this,n):No}toLocaleString(n=oo,r={}){return this.isValid?Ne.create(this.loc.clone(r),n).formatDateTime(this):No}toLocaleParts(n={}){return this.isValid?Ne.create(this.loc.clone(n),n).formatDateTimeParts(this):[]}toISO({format:n="extended",suppressSeconds:r=!1,suppressMilliseconds:i=!1,includeOffset:s=!0}={}){if(!this.isValid)return null;const o=n==="extended";let l=Bo(this,o);return l+="T",l+=ec(this,o,r,i,s),l}toISODate({format:n="extended"}={}){return this.isValid?Bo(this,n==="extended"):null}toISOWeekDate(){return ar(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:n=!1,suppressSeconds:r=!1,includeOffset:i=!0,includePrefix:s=!1,format:o="extended"}={}){return this.isValid?(s?"T":"")+ec(this,o==="extended",r,n,i):null}toRFC2822(){return ar(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return ar(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?Bo(this,!0):null}toSQLTime({includeOffset:n=!0,includeZone:r=!1,includeOffsetSpace:i=!0}={}){let s="HH:mm:ss.SSS";return(r||n)&&(i&&(s+=" "),r?s+="z":n&&(s+="ZZ")),ar(this,s,!0)}toSQL(n={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(n)}`:null}toString(){return this.isValid?this.toISO():No}valueOf(){return this.toMillis()}toMillis(){return this.isValid?this.ts:NaN}toSeconds(){return this.isValid?this.ts/1e3:NaN}toUnixInteger(){return this.isValid?Math.floor(this.ts/1e3):NaN}toJSON(){return this.toISO()}toBSON(){return this.toJSDate()}toObject(n={}){if(!this.isValid)return{};const r={...this.c};return n.includeConfig&&(r.outputCalendar=this.outputCalendar,r.numberingSystem=this.loc.numberingSystem,r.locale=this.loc.locale),r}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(n,r="milliseconds",i={}){if(!this.isValid||!n.isValid)return Y.invalid("created by diffing an invalid DateTime");const s={locale:this.locale,numberingSystem:this.numberingSystem,...i},o=Zh(r).map(Y.normalizeUnit),l=n.valueOf()>this.valueOf(),a=l?this:n,c=l?n:this,d=wg(a,c,o,s);return l?d.negate():d}diffNow(n="milliseconds",r={}){return this.diff(_.now(),n,r)}until(n){return this.isValid?ce.fromDateTimes(this,n):this}hasSame(n,r){if(!this.isValid)return!1;const i=n.valueOf(),s=this.setZone(n.zone,{keepLocalTime:!0});return s.startOf(r)<=i&&i<=s.endOf(r)}equals(n){return this.isValid&&n.isValid&&this.valueOf()===n.valueOf()&&this.zone.equals(n.zone)&&this.loc.equals(n.loc)}toRelative(n={}){if(!this.isValid)return null;const r=n.base||_.fromObject({},{zone:this.zone}),i=n.padding?this<r?-n.padding:n.padding:0;let s=["years","months","days","hours","minutes","seconds"],o=n.unit;return Array.isArray(n.unit)&&(s=n.unit,o=void 0),ic(r,this.plus(i),{...n,numeric:"always",units:s,unit:o})}toRelativeCalendar(n={}){return this.isValid?ic(n.base||_.fromObject({},{zone:this.zone}),this,{...n,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...n){if(!n.every(_.isDateTime))throw new Ie("min requires all arguments be DateTimes");return aa(n,r=>r.valueOf(),Math.min)}static max(...n){if(!n.every(_.isDateTime))throw new Ie("max requires all arguments be DateTimes");return aa(n,r=>r.valueOf(),Math.max)}static fromFormatExplain(n,r,i={}){const{locale:s=null,numberingSystem:o=null}=i,l=se.fromOpts({locale:s,numberingSystem:o,defaultToEN:!0});return ja(l,n,r)}static fromStringExplain(n,r,i={}){return _.fromFormatExplain(n,r,i)}static get DATE_SHORT(){return oo}static get DATE_MED(){return ql}static get DATE_MED_WITH_WEEKDAY(){return Gh}static get DATE_FULL(){return zl}static get DATE_HUGE(){return Wl}static get TIME_SIMPLE(){return Hl}static get TIME_WITH_SECONDS(){return Gl}static get TIME_WITH_SHORT_OFFSET(){return Yl}static get TIME_WITH_LONG_OFFSET(){return Jl}static get TIME_24_SIMPLE(){return Kl}static get TIME_24_WITH_SECONDS(){return Zl}static get TIME_24_WITH_SHORT_OFFSET(){return Xl}static get TIME_24_WITH_LONG_OFFSET(){return Ql}static get DATETIME_SHORT(){return vl}static get DATETIME_SHORT_WITH_SECONDS(){return ea}static get DATETIME_MED(){return ta}static get DATETIME_MED_WITH_SECONDS(){return na}static get DATETIME_MED_WITH_WEEKDAY(){return Yh}static get DATETIME_FULL(){return ra}static get DATETIME_FULL_WITH_SECONDS(){return oa}static get DATETIME_HUGE(){return ia}static get DATETIME_HUGE_WITH_SECONDS(){return sa}}function Nn(e){if(_.isDateTime(e))return e;if(e&&e.valueOf&&Mt(e.valueOf()))return _.fromJSDate(e);if(e&&typeof e=="object")return _.fromObject(e);throw new Ie(`Unknown datetime argument: ${e}, of type ${typeof e}`)}const Q={};Q.format=function(e,n){return e=e?new Date(e):new Date,_.fromJSDate(e).toFormat(n)},Q.readableTime=function(e){if(e=String(e||""),!e||!/^\d{4}$/.test(e))return e;const n=e.substring(0,2),r=e.substring(2,4);return console.log(e,n,r),_.fromObject({hour:parseInt(n,10),minute:parseInt(r,10)}).toFormat("h:mma").toLowerCase().replace(/:00/g,"")},Q.timeago=function(e,n){return _.fromJSDate(new Date(e)).toRelative(n)},Q.getDatesBetween=function(e,n){const r=[];let i=_.fromISO(e);const s=_.fromISO(n);for(;i<=s;)r.push(i.toISODate()),i=i.plus({days:1});return r},Q.getCalendarDateLimits=function(e){const n=e.getFullYear(),r=e.getMonth(),i=new Date(n,r,1),s=new Date(n,r+1,0),o=new Date(i);o.setDate(o.getDate()-o.getDay());const l=new Date(s);l.setDate(l.getDate()+(6-l.getDay()));const a={weekday:"long",day:"numeric",month:"long",year:"numeric"},c=o.toLocaleDateString("en-US",a),d=l.toLocaleDateString("en-US",a);return{start:new Date(c),end:new Date(d)}},Q.getMiddleDate=function(e,n){const r=e.getTime(),i=n.getTime(),s=(r+i)/2;return new Date(s)},Q.shortTime=function(e){return e.toJSDate||(e=_.fromJSDate(new Date(e))),e.toFormat("mm")==="00"?e.toFormat("ha").toLowerCase():e.toFormat("h:mma").toLowerCase()},Q.readableEventDate=function({startDate:e,endDate:n,timezone:r},i){if(!e)return"";e=new Date(e),n=n?new Date(n):void 0;let s,o;try{s=r?_.fromJSDate(e).setZone(r):_.fromJSDate(e),o=n?r?_.fromJSDate(n).setZone(r):_.fromJSDate(n):s}catch{s=_.fromJSDate(e),o=n?_.fromJSDate(n):s}const l=_.now(),a=r&&s.zoneName!==_.local().zoneName?` (${s.zoneName})`:"",d=s.year!==l.year?` ${s.year}`:"";return s.hasSame(o,"day")?Q.shortTime(s)==="12am"?`${s.toFormat("d MMMM")}${d}${a}`:`${Q.shortTime(s)}, ${s.toFormat("cccc d MMMM")}${d}${a}`:s.hasSame(o,"month")?`${s.toFormat("d")}-${o.toFormat("d MMMM")}${d}${a}`:s.hasSame(o,"year")?`${s.toFormat("d MMM")} - ${o.toFormat("d MMM")}${d}${a}`:`${s.toFormat("d MMM yyyy")} - ${o.toFormat("d MMM yyyy")}${a}`},Q.readableDateRange=function(e,n,r){if(!e)return;if(!n)return Q.readableDate(e);e=_.fromJSDate(new Date(e)),n=_.fromJSDate(new Date(n));const i=e.toFormat("yyyy"),s=e.toFormat("LLL yyyy"),o=e.toFormat("WW yyyy"),l=e.toFormat("d LLL yyyy"),a=n.toFormat("yyyy"),c=n.toFormat("LLL yyyy"),d=n.toFormat("WW yyyy"),u=n.toFormat("d LLL yyyy");return l===u?Q.shortTime(e)==="12am"?`${Q.readableDate(n)}`:`${Q.shortTime(e)} - ${Q.readableDate(n)}`:o===d?`${Q.readableDate(e)} - ${Q.readableDate(n)}`:s===c?`${e.toFormat("d")} - ${n.toFormat("d LLL")}`:i===a?`${Q.readableDate(e)} - ${Q.readableDate(n)}`:`${Q.readableDate(e)} - ${Q.readableDate(n)}`},Q.readableDate=function(e){if(!e)return;const n=new Date,r=_.fromJSDate(n),i=r.toFormat("yyyy"),s=r.toFormat("LLL yyyy"),o=r.toFormat("WW yyyy"),l=r.toFormat("d LLL yyyy");e=new Date(e);const a=_.fromJSDate(e),c=a.toFormat("yyyy"),d=a.toFormat("LLL yyyy"),u=a.toFormat("WW yyyy");if(a.toFormat("d LLL yyyy")===l)return`${Q.shortTime(a)} today`;if(u===o)if(e>n){const f=parseInt(r.toFormat("d"));return parseInt(a.toFormat("d"))-f===1?`${Q.shortTime(a)} tomorrow`:`${Q.shortTime(a)} ${a.toFormat("cccc")}`}else return`${a.toRelativeCalendar()}`;return d===s?Q.shortTime(a)==="12am"?`${a.toFormat("d LLL")}`:`${Q.shortTime(a)} ${a.toFormat("d LLL")}`:c===i?a.toFormat("cccc d LLL"):a.toFormat("d LLL yyyy")};function lc(e){var h,g;const n=t.reactive({items:[],hash:{},hex:{},loading:!1,loaded:!1,_fullyLoaded:{}});let r=null;const i={};function s(p,y){if(!(!p||!y))for(const k of Object.keys(y))p[k]=y[k]}function o(p){const y={},k={};return p.forEach(function(x){x.key&&(y[x.key]=x),x.hex&&(k[x.hex]=x)}),{hash:y,hex:k}}async function l(p){if(r)return r;if(!(n.loaded&&!p))return r=a(),r}async function a(p){if(!e.auth.getCurrentUser()){u();return}n.loading=!0;try{const{data:k}=await e.api.get("/glossary/index",{cache:!1}),x=k||[],{hash:S,hex:I}=o(x);n._fullyLoaded={},n.items=x,n.hash=S,n.hex=I,n.loaded=!0}catch(k){console.error("GlossaryService: failed to load glossary index",k)}finally{n.loading=!1,r=null}}async function c(p,y){return n._fullyLoaded[p]&&!y?n.hash[p]:(i[p]||(i[p]=d(p)),i[p])}async function d(p,y){try{const{data:k}=await e.api.get(`/glossary/index/${p}`,{cache:!1});if(!k)return;n.hash[p]?s(n.hash[p],k):n.hash[p]=k;const x=n.items.findIndex(function(S){return S.key===p});return x!==-1&&s(n.items[x],k),n._fullyLoaded[p]=!0,n.hash[p]}catch(k){console.error(`GlossaryService: failed to load definition for '${p}'`,k)}finally{delete i[p]}}n.ensure=async function(p){if(!p)return l(!1);if(await l(!1),typeof p=="string")return c(p,!1);if(Array.isArray(p))return Promise.all(p.map(function(y){return c(y,!1)}))},n.reload=async function(p){if(!p)return l(!0);if(await l(!1),typeof p=="string")return c(p,!0);if(Array.isArray(p))return Promise.all(p.map(function(y){return c(y,!0)}))},n.definitionName=function(p,y){const k=n.hash[p];return k?y?k.plural:k.title:p},n.clear=u;function u(){n.items=[],n.hash={},n.hex={},n.loaded=!1,n.loading=!1,n._fullyLoaded={},r=null;for(const p in i)delete i[p]}let m=null;e.auth.addEventListener("change",function(p){var y,k;if(p){const x=(k=(y=p==null?void 0:p.session)==null?void 0:y.organisation)==null?void 0:k._id;m&&x!==m&&u(),m=x||null,l(!1)}else m=null,u()});const f=e.auth.getCurrentUser();return f&&(m=((g=(h=f==null?void 0:f.session)==null?void 0:h.organisation)==null?void 0:g._id)||null,l(!1)),n}const cr={STRIPE_NOT_LOADED:"Stripe v3 library is not loaded",INSTANCE_NOT_DEFINED:"Instance object is not defined. Make sure you initialized Stripe before creating elements",ELEMENTS_NOT_DEFINED:"Elements object is not defined. You can't create stripe element without it",ELEMENT_TYPE_NOT_DEFINED:"elementType is required. You can't create stripe element without it"},zg=(e,n)=>{try{if(!window.Stripe)throw new Error(cr.STRIPE_NOT_LOADED);return window.Stripe(e,n)}catch(r){return console.error(r),r}},Wg=(e,n)=>{try{if(!e)throw new Error(cr.INSTANCE_NOT_DEFINED);return e.elements(n)}catch(r){return console.error(r),r}},Hg=(e,n,r)=>{try{if(!e)throw new Error(cr.ELEMENTS_NOT_DEFINED);if(!n)throw new Error(cr.ELEMENT_TYPE_NOT_DEFINED);return e.create(n,r)}catch(i){return console.error(i),i}};var ac=(e,n)=>{const r=e.__vccOpts||e;for(const[i,s]of n)r[i]=s;return r};const Gg=t.defineComponent({name:"StripeElement",props:{elements:{type:Object,required:!0},type:{type:String,default:()=>"card"},options:{type:Object,default:()=>({})}},setup(e,{emit:n}){const r=t.ref(document.createElement("div")),i=t.ref(),s=t.ref(),{elements:o,type:l,options:a}=t.toRefs(e);return t.onMounted(()=>{const c=()=>{i.value=Hg(o.value,l.value,a.value),i.value.mount(r.value),s.value.appendChild(r.value)},d=(m,f)=>{n(m,f)},u=()=>{["change","ready","focus","blur","click","escape"].forEach(f=>{i.value.on(f,d.bind(null,f))})};try{c(),u()}catch(m){console.error(m)}}),t.onBeforeUnmount(()=>{var c,d;(c=i.value)==null||c.unmount(),(d=i.value)==null||d.destroy()}),t.watch(a,()=>{var c;(c=i.value)==null||c.update(e.options)}),{stripeElement:i,domElement:r,mountPoint:s}}}),Yg={ref:"mountPoint"};function Jg(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",Yg,null,512)}var So=ac(Gg,[["render",Jg]]);const Kg=t.defineComponent({name:"StripeElements",props:{stripeKey:{type:String,required:!0},instanceOptions:{type:Object,default:()=>({})},elementsOptions:{type:Object,default:()=>({})}},setup(e){const{stripeKey:n,instanceOptions:r,elementsOptions:i}=t.toRefs(e),s=t.ref(),o=t.ref(),l=t.computed(()=>o.value?Object.keys(o.value).length>0:!1);return t.onMounted(()=>{s.value=zg(n.value,r.value),o.value=Wg(s.value,i.value)}),t.watch(i,()=>{var a;(a=o.value)==null||a.update(i.value)}),{elements:o,instance:s,elementsUsable:l}}}),Zg={key:0};function Xg(e,n,r,i,s,o){return e.elementsUsable?(t.openBlock(),t.createElementBlock("div",Zg,[t.renderSlot(e.$slots,"default",{instance:e.instance,elements:e.elements})])):t.createCommentVNode("",!0)}var To=ac(Kg,[["render",Xg]]);const w=(e,n)=>{const r=e.__vccOpts||e;for(const[i,s]of n)r[i]=s;return r},Qg={props:{center:{type:Boolean},shrink:{type:Boolean}}};function vg(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["flex-column",{center:r.center,shrink:r.shrink}])},[t.renderSlot(e.$slots,"default",{},void 0,!0)],2)}const cc=w(Qg,[["render",vg],["__scopeId","data-v-b03628f8"]]),ey={},ty={class:"flex-column-body"};function ny(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",ty,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const dc=w(ey,[["render",ny],["__scopeId","data-v-ab49c425"]]),ry={},oy={class:"flex-column-header"};function iy(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",oy,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const uc=w(ry,[["render",iy],["__scopeId","data-v-968bcded"]]),sy={},ly={class:"flex-column-footer"};function ay(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",ly,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const mc=w(sy,[["render",ay],["__scopeId","data-v-941966e2"]]),cy={props:{flex:{type:Boolean},center:{type:Boolean},vcenter:{type:Boolean},alignBottom:{type:Boolean},shrink:{type:Boolean}}};function dy(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["flex-cell",{flex:r.flex,center:r.center,vcenter:r.vcenter,"align-bottom":r.alignBottom,shrink:r.shrink}])},[t.renderSlot(e.$slots,"default",{},void 0,!0)],2)}const fc=w(cy,[["render",dy],["__scopeId","data-v-efd82fd0"]]),uy={props:{center:{type:Boolean},vcenter:{type:Boolean},gap:{type:Boolean},wrap:{type:Boolean}}};function my(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["flex-row",{gap:r.gap,vcenter:r.vcenter,center:r.center,wrap:r.wrap}])},[t.renderSlot(e.$slots,"default",{},void 0,!0)],2)}const hc=w(uy,[["render",my],["__scopeId","data-v-bd96c129"]]),fy={},hy={class:"flex-spacer"};function py(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",hy)}const pc=w(fy,[["render",py],["__scopeId","data-v-f42ac625"]]),gy={},yy={class:"panel"};function ky(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",yy,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const gc=w(gy,[["render",ky],["__scopeId","data-v-dc6d0d19"]]),_y={},wy={class:"panel-body"};function xy(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",wy,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const yc=w(_y,[["render",xy],["__scopeId","data-v-53a6d4be"]]),by={},Cy={class:"panel-header"};function Vy(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",Cy,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const kc=w(by,[["render",Vy],["__scopeId","data-v-3b352542"]]),Ny={},Ey={class:"panel-footer"};function By(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",Ey,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const _c=w(Ny,[["render",By],["__scopeId","data-v-e87fc082"]]);var dr=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ft(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Do,wc;function En(){if(wc)return Do;wc=1;function e(n){var r=typeof n;return n!=null&&(r=="object"||r=="function")}return Do=e,Do}var Oo,xc;function bc(){if(xc)return Oo;xc=1;var e=typeof dr=="object"&&dr&&dr.Object===Object&&dr;return Oo=e,Oo}var Mo,Cc;function on(){if(Cc)return Mo;Cc=1;var e=bc(),n=typeof self=="object"&&self&&self.Object===Object&&self,r=e||n||Function("return this")();return Mo=r,Mo}var Fo,Vc;function Sy(){if(Vc)return Fo;Vc=1;var e=on(),n=function(){return e.Date.now()};return Fo=n,Fo}var Io,Nc;function Ty(){if(Nc)return Io;Nc=1;var e=/\s/;function n(r){for(var i=r.length;i--&&e.test(r.charAt(i)););return i}return Io=n,Io}var Ao,Ec;function Dy(){if(Ec)return Ao;Ec=1;var e=Ty(),n=/^\s+/;function r(i){return i&&i.slice(0,e(i)+1).replace(n,"")}return Ao=r,Ao}var Lo,Bc;function $o(){if(Bc)return Lo;Bc=1;var e=on(),n=e.Symbol;return Lo=n,Lo}var Po,Sc;function Oy(){if(Sc)return Po;Sc=1;var e=$o(),n=Object.prototype,r=n.hasOwnProperty,i=n.toString,s=e?e.toStringTag:void 0;function o(l){var a=r.call(l,s),c=l[s];try{l[s]=void 0;var d=!0}catch{}var u=i.call(l);return d&&(a?l[s]=c:delete l[s]),u}return Po=o,Po}var Ro,Tc;function My(){if(Tc)return Ro;Tc=1;var e=Object.prototype,n=e.toString;function r(i){return n.call(i)}return Ro=r,Ro}var Uo,Dc;function Bn(){if(Dc)return Uo;Dc=1;var e=$o(),n=Oy(),r=My(),i="[object Null]",s="[object Undefined]",o=e?e.toStringTag:void 0;function l(a){return a==null?a===void 0?s:i:o&&o in Object(a)?n(a):r(a)}return Uo=l,Uo}var jo,Oc;function Sn(){if(Oc)return jo;Oc=1;function e(n){return n!=null&&typeof n=="object"}return jo=e,jo}var qo,Mc;function ur(){if(Mc)return qo;Mc=1;var e=Bn(),n=Sn(),r="[object Symbol]";function i(s){return typeof s=="symbol"||n(s)&&e(s)==r}return qo=i,qo}var zo,Fc;function Ic(){if(Fc)return zo;Fc=1;var e=Dy(),n=En(),r=ur(),i=NaN,s=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,l=/^0o[0-7]+$/i,a=parseInt;function c(d){if(typeof d=="number")return d;if(r(d))return i;if(n(d)){var u=typeof d.valueOf=="function"?d.valueOf():d;d=n(u)?u+"":u}if(typeof d!="string")return d===0?d:+d;d=e(d);var m=o.test(d);return m||l.test(d)?a(d.slice(2),m?2:8):s.test(d)?i:+d}return zo=c,zo}var Wo,Ac;function Fy(){if(Ac)return Wo;Ac=1;var e=En(),n=Sy(),r=Ic(),i="Expected a function",s=Math.max,o=Math.min;function l(a,c,d){var u,m,f,h,g,p,y=0,k=!1,x=!1,S=!0;if(typeof a!="function")throw new TypeError(i);c=r(c)||0,e(d)&&(k=!!d.leading,x="maxWait"in d,f=x?s(r(d.maxWait)||0,c):f,S="trailing"in d?!!d.trailing:S);function I(j){var v=u,ae=m;return u=m=void 0,y=j,h=a.apply(ae,v),h}function P(j){return y=j,g=setTimeout(F,c),k?I(j):h}function q(j){var v=j-p,ae=j-y,me=c-v;return x?o(me,f-ae):me}function b(j){var v=j-p,ae=j-y;return p===void 0||v>=c||v<0||x&&ae>=f}function F(){var j=n();if(b(j))return O(j);g=setTimeout(F,q(j))}function O(j){return g=void 0,S&&u?I(j):(u=m=void 0,h)}function U(){g!==void 0&&clearTimeout(g),y=0,u=p=m=g=void 0}function A(){return g===void 0?h:O(n())}function te(){var j=n(),v=b(j);if(u=arguments,m=this,p=j,v){if(g===void 0)return P(p);if(x)return clearTimeout(g),g=setTimeout(F,c),I(p)}return g===void 0&&(g=setTimeout(F,c)),h}return te.cancel=U,te.flush=A,te}return Wo=l,Wo}var Iy=Fy();const Tn=ft(Iy),Ay=["onClick"],Ly=["onClick"],Lc=w({__name:"tabset",props:{vertical:Boolean,inline:Boolean,pills:Boolean,defaultTab:String},setup(e){const n=e,r=t.useSlots(),i=t.reactive({tabs:[]});t.provide("tabset",i);const s=t.ref();t.provide("activeHeading",s);const o=function(u){s.value=u},l=Tn(function(){const m=r.default().reduce(function(g,p){var y;return((y=p.type)==null?void 0:y.name)==="tab"?g.push(p):p.children&&(g=[...g,...p.children]),g},[]).filter(function(g){var p;return((p=g.type)==null?void 0:p.name)==="tab"&&g.props.enabled!==!1}).map(function(g,p){const y=g.props.heading,k=g.props.tabKey||y;return{heading:y,key:k,index:p}});i.tabs=m;const f=m.reduce(function(g,p){return g[p.key||p.heading]=!0,g},{}),h=s.value;if((!h||!f[h])&&m.length){let g;n.defaultTab&&f[n.defaultTab]?g=n.defaultTab:g=m[0].key||m[0].heading,s.value=g}});t.provide("rebuild",l);const a=t.computed(function(){return i.tabs.map(function(u){if(u)return u.heading}).filter(Boolean)}),c=t.computed(function(){return i.tabs.map(function(u){if(u)return u.key}).filter(Boolean)}),d=t.computed(function(){return a.value.length>1});return l(),(u,m)=>{const f=t.resolveComponent("flex-body"),h=t.resolveComponent("flex-column"),g=t.resolveComponent("ux-button"),p=t.resolveComponent("flex-row"),y=t.resolveComponent("flex-header");return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-tabset",{vertical:e.vertical,horizontal:!e.vertical,inline:e.inline,block:!e.inline&&!e.pills,pills:e.pills}])},[e.vertical?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.unref(d)?(t.openBlock(),t.createBlock(h,{key:0,class:"tabset-menu"},{default:t.withCtx(()=>[t.createVNode(f,null,{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(t.unref(c),(k,x)=>(t.openBlock(),t.createElementBlock("a",{class:t.normalizeClass({active:s.value===k}),key:`tab-link-${k}`,onClick:S=>o(k)},t.toDisplayString(t.unref(a)[x]),11,Ay))),128))]),_:1})]),_:1})):t.createCommentVNode("",!0)],64)):e.pills?(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.unref(d)?(t.openBlock(),t.createBlock(y,{key:0,class:"tabset-menu"},{default:t.withCtx(()=>[t.createVNode(p,null,{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(t.unref(c),(k,x)=>(t.openBlock(),t.createBlock(g,{color:s.value===k?"primary":"",key:`tab-pill-${k}`,onClick:S=>o(k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(a)[x]),1)]),_:2},1032,["color","onClick"]))),128))]),_:1})]),_:1})):t.createCommentVNode("",!0)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:2},[t.unref(d)?(t.openBlock(),t.createBlock(y,{key:0,class:"tabset-menu"},{default:t.withCtx(()=>[t.createVNode(p,null,{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(t.unref(c),(k,x)=>(t.openBlock(),t.createElementBlock("a",{class:t.normalizeClass({active:s.value===k}),key:`tab-link-${k}`,onClick:S=>o(k)},t.toDisplayString(t.unref(a)[x]),11,Ly))),128))]),_:1})]),_:1})):t.createCommentVNode("",!0)],64)),t.createVNode(h,null,{default:t.withCtx(()=>[t.renderSlot(u.$slots,"default",{},void 0,!0)]),_:3})],2)}}},[["__scopeId","data-v-781fc138"]]),$y={emits:["mount","unmount"],name:"tab",props:{heading:{type:String,required:!0},tabKey:{type:String},enabled:{type:Boolean,default:!0},keepAlive:{type:Boolean,default:!1}},created(){this.rebuild()},unmounted(){this.rebuild()},watch:{heading(){this.rebuild()}},inject:["tabset","activeHeading","rebuild"],computed:{active(){var r;return String(this.tabKey||this.heading)===String(((r=this.activeHeading)==null?void 0:r.value)||this.activeHeading)}}};function Py(e,n,r,i,s,o){const l=t.resolveComponent("flex-column");return r.keepAlive?t.withDirectives((t.openBlock(),t.createBlock(l,{key:0},{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default")]),_:3},512)),[[t.vShow,o.active]]):o.active?(t.openBlock(),t.createBlock(l,{key:1},{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default")]),_:3})):t.createCommentVNode("",!0)}const $c=w($y,[["render",Py]]);var Ho,Pc;function Dn(){if(Pc)return Ho;Pc=1;var e=Array.isArray;return Ho=e,Ho}var Go,Rc;function Ry(){if(Rc)return Go;Rc=1;var e=Dn(),n=ur(),r=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,i=/^\w*$/;function s(o,l){if(e(o))return!1;var a=typeof o;return a=="number"||a=="symbol"||a=="boolean"||o==null||n(o)?!0:i.test(o)||!r.test(o)||l!=null&&o in Object(l)}return Go=s,Go}var Yo,Uc;function jc(){if(Uc)return Yo;Uc=1;var e=Bn(),n=En(),r="[object AsyncFunction]",i="[object Function]",s="[object GeneratorFunction]",o="[object Proxy]";function l(a){if(!n(a))return!1;var c=e(a);return c==i||c==s||c==r||c==o}return Yo=l,Yo}var Jo,qc;function Uy(){if(qc)return Jo;qc=1;var e=on(),n=e["__core-js_shared__"];return Jo=n,Jo}var Ko,zc;function jy(){if(zc)return Ko;zc=1;var e=Uy(),n=function(){var i=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return i?"Symbol(src)_1."+i:""}();function r(i){return!!n&&n in i}return Ko=r,Ko}var Zo,Wc;function qy(){if(Wc)return Zo;Wc=1;var e=Function.prototype,n=e.toString;function r(i){if(i!=null){try{return n.call(i)}catch{}try{return i+""}catch{}}return""}return Zo=r,Zo}var Xo,Hc;function zy(){if(Hc)return Xo;Hc=1;var e=jc(),n=jy(),r=En(),i=qy(),s=/[\\^$.*+?()[\]{}|]/g,o=/^\[object .+?Constructor\]$/,l=Function.prototype,a=Object.prototype,c=l.toString,d=a.hasOwnProperty,u=RegExp("^"+c.call(d).replace(s,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function m(f){if(!r(f)||n(f))return!1;var h=e(f)?u:o;return h.test(i(f))}return Xo=m,Xo}var Qo,Gc;function Wy(){if(Gc)return Qo;Gc=1;function e(n,r){return n==null?void 0:n[r]}return Qo=e,Qo}var vo,Yc;function ei(){if(Yc)return vo;Yc=1;var e=zy(),n=Wy();function r(i,s){var o=n(i,s);return e(o)?o:void 0}return vo=r,vo}var ti,Jc;function mr(){if(Jc)return ti;Jc=1;var e=ei(),n=e(Object,"create");return ti=n,ti}var ni,Kc;function Hy(){if(Kc)return ni;Kc=1;var e=mr();function n(){this.__data__=e?e(null):{},this.size=0}return ni=n,ni}var ri,Zc;function Gy(){if(Zc)return ri;Zc=1;function e(n){var r=this.has(n)&&delete this.__data__[n];return this.size-=r?1:0,r}return ri=e,ri}var oi,Xc;function Yy(){if(Xc)return oi;Xc=1;var e=mr(),n="__lodash_hash_undefined__",r=Object.prototype,i=r.hasOwnProperty;function s(o){var l=this.__data__;if(e){var a=l[o];return a===n?void 0:a}return i.call(l,o)?l[o]:void 0}return oi=s,oi}var ii,Qc;function Jy(){if(Qc)return ii;Qc=1;var e=mr(),n=Object.prototype,r=n.hasOwnProperty;function i(s){var o=this.__data__;return e?o[s]!==void 0:r.call(o,s)}return ii=i,ii}var si,vc;function Ky(){if(vc)return si;vc=1;var e=mr(),n="__lodash_hash_undefined__";function r(i,s){var o=this.__data__;return this.size+=this.has(i)?0:1,o[i]=e&&s===void 0?n:s,this}return si=r,si}var li,ed;function Zy(){if(ed)return li;ed=1;var e=Hy(),n=Gy(),r=Yy(),i=Jy(),s=Ky();function o(l){var a=-1,c=l==null?0:l.length;for(this.clear();++a<c;){var d=l[a];this.set(d[0],d[1])}}return o.prototype.clear=e,o.prototype.delete=n,o.prototype.get=r,o.prototype.has=i,o.prototype.set=s,li=o,li}var ai,td;function Xy(){if(td)return ai;td=1;function e(){this.__data__=[],this.size=0}return ai=e,ai}var ci,nd;function rd(){if(nd)return ci;nd=1;function e(n,r){return n===r||n!==n&&r!==r}return ci=e,ci}var di,od;function fr(){if(od)return di;od=1;var e=rd();function n(r,i){for(var s=r.length;s--;)if(e(r[s][0],i))return s;return-1}return di=n,di}var ui,id;function Qy(){if(id)return ui;id=1;var e=fr(),n=Array.prototype,r=n.splice;function i(s){var o=this.__data__,l=e(o,s);if(l<0)return!1;var a=o.length-1;return l==a?o.pop():r.call(o,l,1),--this.size,!0}return ui=i,ui}var mi,sd;function vy(){if(sd)return mi;sd=1;var e=fr();function n(r){var i=this.__data__,s=e(i,r);return s<0?void 0:i[s][1]}return mi=n,mi}var fi,ld;function ek(){if(ld)return fi;ld=1;var e=fr();function n(r){return e(this.__data__,r)>-1}return fi=n,fi}var hi,ad;function tk(){if(ad)return hi;ad=1;var e=fr();function n(r,i){var s=this.__data__,o=e(s,r);return o<0?(++this.size,s.push([r,i])):s[o][1]=i,this}return hi=n,hi}var pi,cd;function nk(){if(cd)return pi;cd=1;var e=Xy(),n=Qy(),r=vy(),i=ek(),s=tk();function o(l){var a=-1,c=l==null?0:l.length;for(this.clear();++a<c;){var d=l[a];this.set(d[0],d[1])}}return o.prototype.clear=e,o.prototype.delete=n,o.prototype.get=r,o.prototype.has=i,o.prototype.set=s,pi=o,pi}var gi,dd;function rk(){if(dd)return gi;dd=1;var e=ei(),n=on(),r=e(n,"Map");return gi=r,gi}var yi,ud;function ok(){if(ud)return yi;ud=1;var e=Zy(),n=nk(),r=rk();function i(){this.size=0,this.__data__={hash:new e,map:new(r||n),string:new e}}return yi=i,yi}var ki,md;function ik(){if(md)return ki;md=1;function e(n){var r=typeof n;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?n!=="__proto__":n===null}return ki=e,ki}var _i,fd;function hr(){if(fd)return _i;fd=1;var e=ik();function n(r,i){var s=r.__data__;return e(i)?s[typeof i=="string"?"string":"hash"]:s.map}return _i=n,_i}var wi,hd;function sk(){if(hd)return wi;hd=1;var e=hr();function n(r){var i=e(this,r).delete(r);return this.size-=i?1:0,i}return wi=n,wi}var xi,pd;function lk(){if(pd)return xi;pd=1;var e=hr();function n(r){return e(this,r).get(r)}return xi=n,xi}var bi,gd;function ak(){if(gd)return bi;gd=1;var e=hr();function n(r){return e(this,r).has(r)}return bi=n,bi}var Ci,yd;function ck(){if(yd)return Ci;yd=1;var e=hr();function n(r,i){var s=e(this,r),o=s.size;return s.set(r,i),this.size+=s.size==o?0:1,this}return Ci=n,Ci}var Vi,kd;function _d(){if(kd)return Vi;kd=1;var e=ok(),n=sk(),r=lk(),i=ak(),s=ck();function o(l){var a=-1,c=l==null?0:l.length;for(this.clear();++a<c;){var d=l[a];this.set(d[0],d[1])}}return o.prototype.clear=e,o.prototype.delete=n,o.prototype.get=r,o.prototype.has=i,o.prototype.set=s,Vi=o,Vi}var Ni,wd;function dk(){if(wd)return Ni;wd=1;var e=_d(),n="Expected a function";function r(i,s){if(typeof i!="function"||s!=null&&typeof s!="function")throw new TypeError(n);var o=function(){var l=arguments,a=s?s.apply(this,l):l[0],c=o.cache;if(c.has(a))return c.get(a);var d=i.apply(this,l);return o.cache=c.set(a,d)||c,d};return o.cache=new(r.Cache||e),o}return r.Cache=e,Ni=r,Ni}var Ei,xd;function uk(){if(xd)return Ei;xd=1;var e=dk(),n=500;function r(i){var s=e(i,function(l){return o.size===n&&o.clear(),l}),o=s.cache;return s}return Ei=r,Ei}var Bi,bd;function mk(){if(bd)return Bi;bd=1;var e=uk(),n=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,r=/\\(\\)?/g,i=e(function(s){var o=[];return s.charCodeAt(0)===46&&o.push(""),s.replace(n,function(l,a,c,d){o.push(c?d.replace(r,"$1"):a||l)}),o});return Bi=i,Bi}var Si,Cd;function Vd(){if(Cd)return Si;Cd=1;function e(n,r){for(var i=-1,s=n==null?0:n.length,o=Array(s);++i<s;)o[i]=r(n[i],i,n);return o}return Si=e,Si}var Ti,Nd;function fk(){if(Nd)return Ti;Nd=1;var e=$o(),n=Vd(),r=Dn(),i=ur(),s=e?e.prototype:void 0,o=s?s.toString:void 0;function l(a){if(typeof a=="string")return a;if(r(a))return n(a,l)+"";if(i(a))return o?o.call(a):"";var c=a+"";return c=="0"&&1/a==-1/0?"-0":c}return Ti=l,Ti}var Di,Ed;function Oi(){if(Ed)return Di;Ed=1;var e=fk();function n(r){return r==null?"":e(r)}return Di=n,Di}var Mi,Bd;function hk(){if(Bd)return Mi;Bd=1;var e=Dn(),n=Ry(),r=mk(),i=Oi();function s(o,l){return e(o)?o:n(o,l)?[o]:r(i(o))}return Mi=s,Mi}var Fi,Sd;function pk(){if(Sd)return Fi;Sd=1;var e=ur();function n(r){if(typeof r=="string"||e(r))return r;var i=r+"";return i=="0"&&1/r==-1/0?"-0":i}return Fi=n,Fi}var Ii,Td;function gk(){if(Td)return Ii;Td=1;var e=hk(),n=pk();function r(i,s){s=e(s,i);for(var o=0,l=s.length;i!=null&&o<l;)i=i[n(s[o++])];return o&&o==l?i:void 0}return Ii=r,Ii}var Ai,Dd;function yk(){if(Dd)return Ai;Dd=1;var e=gk();function n(r,i,s){var o=r==null?void 0:e(r,i);return o===void 0?s:o}return Ai=n,Ai}var kk=yk();const ht=ft(kk),le={props:{column:{type:Object,required:!0},row:{type:Object,required:!0},value:{}}},_k={mixins:[le],data(){return{processing:!1}},methods:{async clicked(){const e=this,n=(e.tags||[]).slice(),r=await e.$sdk.tag({title:"Edit tags",description:e.row.title,model:n.slice()}),i=e.$sdk.utils.ids(n),s=e.$sdk.utils.ids(r);JSON.stringify(i.sort())===JSON.stringify(s.sort())||(e.processing=!0,await e.$sdk.content.patch(this.itemID,{meta:{tags:r}}),e.row.meta.tags=r,e.processing=!1,e.$sdk.notify("Tags were updated"))}},computed:{canEditItem(){return this.$sdk.access.canEditItem(this.user,this.row)},itemID(){return this.row._id},tags(){var r;return((r=this.row.meta)==null?void 0:r.tags)||[]}}},wk={class:"table-quicktag-cell"};function xk(e,n,r,i,s,o){const l=t.resolveComponent("ux-pill"),a=t.resolveComponent("flex-cell"),c=t.resolveComponent("flex-row"),d=t.resolveComponent("ux-icon"),u=t.resolveComponent("ux-button");return t.openBlock(),t.createElementBlock("td",wk,[t.createVNode(c,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(a,null,{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.tags,m=>(t.openBlock(),t.createBlock(l,{icon:"fa-tag",tag:"a",value:m},null,8,["value"]))),256))]),_:1})]),_:1}),o.canEditItem?(t.openBlock(),t.createElementBlock("div",{key:0,class:"clicker",onClick:n[0]||(n[0]=t.withModifiers((...m)=>o.clicked&&o.clicked(...m),["stop","prevent"]))},[t.createVNode(c,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(a),t.createVNode(a,{shrink:""},{default:t.withCtx(()=>[t.createVNode(u,{icon:"",size:"xs"},{default:t.withCtx(()=>[t.createVNode(d,{icon:"fa-pen-to-square"})]),_:1})]),_:1})]),_:1})])):t.createCommentVNode("",!0)])}const bk=w(_k,[["render",xk],["__scopeId","data-v-d98dce09"]]),Ck={mixins:[le],computed:{initials(){var e,n;return`${((e=this.row)==null?void 0:e.firstName)||""} ${((n=this.row)==null?void 0:n.lastName)||""}`.trim()||this.row.title},source(){return this.$sdk.utils.id(this.value)||this.$sdk.utils.id(this.row)}}},Vk={class:"table-avatar-cell"},Nk={class:"avatar-wrapper"};function Ek(e,n,r,i,s,o){const l=t.resolveComponent("avatar",!0);return t.openBlock(),t.createElementBlock("td",Vk,[t.createElementVNode("div",Nk,[t.createVNode(l,{id:o.source,initials:o.initials},null,8,["id","initials"])])])}const Bk=w(Ck,[["render",Ek],["__scopeId","data-v-a4b42e00"]]),Sk={mixins:[le],computed:{formatted(){return this.$sdk.date.readableTime(this.value)}}},Tk={class:"table-time-cell"};function Dk(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("td",Tk,[t.createVNode(l,{icon:"far fa-clock"}),t.createTextVNode(" "+t.toDisplayString(o.formatted),1)])}const Ok=w(Sk,[["render",Dk],["__scopeId","data-v-677f555b"]]),Mk={mixins:[le],computed:{key(){return this.column.key},rawSource(){return ht(this.row,this.key)},source(){return Array.isArray(this.rawSource)?this.rawSource[0]:this.rawSource?this.rawSource:this.row},imageSource(){var r;const e=this.source;if(e)switch((r=e==null?void 0:e.meta)==null?void 0:r.type){case"video":case"image":case"event":case"persona":case"profile":case"audio":case"file":return this.source;default:{const i=this.$sdk.utils.id(this.source);if(!i)return;var n=i.slice(8,10);switch(n){case"69":return{_id:i,meta:{type:"image"}};case"76":return{_id:i,meta:{type:"video"}};case"24":return{_id:i,meta:{type:"persona"}};case"70":return{_id:i,meta:{type:"profile"}};case"71":return{_id:i,meta:{type:"checkin"}}}return i}}},type(){var e,n;return(n=(e=this.imageSource)==null?void 0:e.meta)==null?void 0:n.type}},methods:{clicked(e){this.$sdk.dispatch("item:view",this.imageSource)}}},Fk={class:"table-image-cell"};function Ik(e,n,r,i,s,o){const l=t.resolveComponent("ux-image"),a=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("td",Fk,[o.imageSource?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[o.type=="image"||o.type=="video"?(t.openBlock(),t.createElementBlock("div",{key:0,onClick:n[0]||(n[0]=t.withModifiers(c=>o.clicked(e.value),["stop","prevent"])),class:"image-wrapper"},[t.createVNode(l,{lazy:"",item:o.imageSource,type:o.type,width:100,height:100},null,8,["item","type"])])):o.type==="audio"?(t.openBlock(),t.createBlock(a,{key:1,icon:"fa-music"})):o.type==="file"?(t.openBlock(),t.createBlock(a,{key:2,icon:"fa-file"})):(t.openBlock(),t.createElementBlock("div",{key:3,onClick:n[1]||(n[1]=t.withModifiers(c=>o.clicked(e.value),["stop","prevent"])),class:"image-wrapper"},[t.createVNode(l,{lazy:"",item:o.imageSource,type:o.type,width:100,height:100},null,8,["item","type"])]))],64)):t.createCommentVNode("",!0)])}const Ak=w(Mk,[["render",Ik],["__scopeId","data-v-0d557d14"]]),Lk={mixins:[le],computed:{string(){return isNaN(this.amount)?"0.00":this.amount.toFixed(2)},amount(){return Number(parseInt(this.value)/100)},credit(){return this.amount>0},debit(){return this.amount<0},invalid(){var e;return((e=this.column)==null?void 0:e.key)==="amount"&&this.adjusted},adjusted(){return this.row.effectiveAmount!==this.row.amount},empty(){return parseInt(this.value)===0},currency(){return this.column.currency||this.row.currency}}};function $k(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-currency-cell",{credit:o.credit,empty:o.empty,debit:o.debit,invalid:o.invalid,adjusted:o.adjusted}])},t.toDisplayString(o.string),3)}const Pk=w(Lk,[["render",$k],["__scopeId","data-v-c62e82ec"]]),Rk={data(){return{processing:!1}},mixins:[le],computed:{visible(){return!this.hidden},enabled(){const e=this;switch(typeof e.button.enabled){case"function":return e.button.enabled(e.row,e.column);case"undefined":case"null":return!0;default:return e.button.enabled}},hidden(){const e=this;switch(typeof e.button.hidden){case"function":return!!e.button.hidden(e.row,e.column);case"undefined":case"null":return!1;default:return!!e.button.hidden}},button(){return this.column.button},type(){var e,n;return(n=(e=this.row)==null?void 0:e.meta)==null?void 0:n.type},label(){const e=this.button;return typeof e.text=="function"?e.text(this):e.text}},methods:{async clicked(){this.processing=!0,await this.button.action(this.row,this.column,this),this.processing=!1}}},Uk={class:"table-button-cell"};function jk(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon"),a=t.resolveComponent("ux-button");return t.openBlock(),t.createElementBlock("td",Uk,[o.visible?(t.openBlock(),t.createBlock(a,{key:0,block:o.button.block,color:o.button.color,size:o.button.size,loading:s.processing,disabled:!o.enabled,onClick:t.withModifiers(o.clicked,["stop","prevent"])},{default:t.withCtx(()=>[o.label?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createTextVNode(t.toDisplayString(o.label),1)],64)):t.createCommentVNode("",!0),o.button.icon?(t.openBlock(),t.createBlock(l,{key:1,icon:o.button.icon,right:""},null,8,["icon"])):t.createCommentVNode("",!0)]),_:1},8,["block","color","size","loading","disabled","onClick"])):t.createCommentVNode("",!0)])}const qk=w(Rk,[["render",jk],["__scopeId","data-v-413157fd"]]),zk={mixins:[le],methods:{timeago(e){return _.fromJSDate(e).toRelative()},readable(e){e=_.fromJSDate(e);let n=_.now(),r=n.toFormat("yyyy");return n.toFormat("MMM yyyy"),e.toFormat("yyyy")===r?e.toFormat("h:mma, ccc d MMM").replace(/:00/g,"").replace(/PM,/g,"pm,").replace(/:AM,/g,"am,"):e.toFormat("h:mma, ccc d MMM yyyy").replace(/:00/g,"").replace(/:PM,/g,"pm,").replace(/:AM,/g,"am,")}},computed:{values(){return Array.isArray(this.value)?this.value:[this.value]},mapped(){const e=this;return e.values.map(function(n){if(!n)return;const r=new Date(n);return{readable:e.readable(r),timeago:e.timeago(r)}}).filter(Boolean)}}},Wk={class:"table-date-cell"},Hk={class:"date-pill"},Gk={class:"off"},Yk={class:"on"},Jk={class:"spacer"};function Kk(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",Wk,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.mapped,l=>(t.openBlock(),t.createElementBlock("div",Hk,[t.createElementVNode("span",Gk,t.toDisplayString(l.readable),1),t.createElementVNode("span",Yk,t.toDisplayString(l.timeago),1),t.createElementVNode("span",Jk,t.toDisplayString(l.readable),1)]))),256))])}const Od=w(zk,[["render",Kk],["__scopeId","data-v-7ddc957f"]]),Zk={mixins:[le],methods:{timeago(e){return _.fromJSDate(e).toRelative()},readable(e){e=_.fromJSDate(e);let n=_.now(),r=n.toFormat("yyyy");return n.toFormat("MMM yyyy"),e.toFormat("yyyy")===r?e.toFormat("h:mm a - dd MMM"):e.toFormat("h:mm a - dd MMM yyyy")}},computed:{values(){return Array.isArray(this.value)?this.value:[this.value]},mapped(){const e=this;return e.values.map(function(n){if(!n)return;const r=new Date(n),i=r<new Date;return{readable:e.readable(r),timeago:e.timeago(r),overdue:i}}).filter(Boolean)}}},Xk={class:"table-date-cell"},Qk={class:"off"},vk={class:"on"},e_={class:"spacer"};function t_(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("td",Xk,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.mapped,a=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["date-pill",{overdue:a.overdue}])},[t.createElementVNode("span",Qk,[t.createVNode(l,{icon:"far fa-clock",left:""}),t.createTextVNode(t.toDisplayString(a.readable),1)]),t.createElementVNode("span",vk,[t.createVNode(l,{icon:"far fa-clock",left:""}),t.createTextVNode(t.toDisplayString(a.timeago),1)]),t.createElementVNode("span",e_,[t.createVNode(l,{icon:"far fa-clock",left:""}),t.createTextVNode(t.toDisplayString(a.readable),1)])],2))),256))])}const n_=w(Zk,[["render",t_],["__scopeId","data-v-0e48d460"]]),r_={mixins:[le],computed:{boolean(){return!!this.value}}};function o_(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-boolean-cell",{true:o.boolean,false:!o.boolean}])},[t.createVNode(l,{icon:o.boolean?"fa-check":"fa-times"},null,8,["icon"])],2)}const Md=w(r_,[["render",o_],["__scopeId","data-v-b180904a"]]),i_={mixins:[le],computed:{size(){return this.$sdk.files.filesize(this.value)}}};function s_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-filesize-cell",{true:e.boolean,false:!e.boolean}])},t.toDisplayString(o.size),3)}const l_=w(i_,[["render",s_],["__scopeId","data-v-0419990c"]]);function a_(e){const n=Math.round(e),r=Math.floor(n/3600),i=Math.floor(n%3600/60),s=n%60;return r>0?`${r}:${i.toString().padStart(2,"0")}:${s.toString().padStart(2,"0")}`:`${i}:${s.toString().padStart(2,"0")}`}const c_={mixins:[le],computed:{duration(){return a_(this.value)}}};function d_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-duration-cell",{true:e.boolean,false:!e.boolean}])},t.toDisplayString(o.duration),3)}const u_=w(c_,[["render",d_],["__scopeId","data-v-2910d792"]]),m_={mixins:[le],methods:{async clicked(){const e=this,n=e.$sdk.utils.id(e.row),r=e.public?"secure":"public";e.processing=!0,e.$sdk.content.patch(n,{meta:{security:r}}).catch(function(i){e.$sdk.error(i),e.processing=!1}).then(function(i){e.v=r,e.processing=!1,e.$sdk.notify(`Set security to ${r}`)})}},data(){return{processing:!1,v:this.value}},computed:{canEdit(){var e=this.user;return this.$sdk.access.canEditItem(e,this.row)},public(){return this.security==="public"},security(){return this.v||"secure"}}};function f_(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon"),a=t.resolveComponent("ux-button");return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-security-cell",o.security])},[o.canEdit?(t.openBlock(),t.createBlock(a,{key:0,size:"sm",loading:s.processing,onClick:t.withModifiers(o.clicked,["stop","prevent"])},{default:t.withCtx(()=>[t.createVNode(l,{icon:o.public?"fa-lock-open":"fa-lock"},null,8,["icon"])]),_:1},8,["loading","onClick"])):(t.openBlock(),t.createBlock(l,{key:1,icon:o.public?"fa-lock-open":"fa-lock"},null,8,["icon"]))],2)}const h_=w(m_,[["render",f_],["__scopeId","data-v-45dd2b07"]]),p_={mixins:[le],methods:{open(){window.open(this.href)}},computed:{actualValue(){return String(this.value||"").trim()},href(){let e=this.actualValue;return/^https?:\/\//i.test(e)?e:"https://"+e}}},g_={class:"table-url-cell"},y_=["href"];function k_(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("td",g_,[o.actualValue?(t.openBlock(),t.createElementBlock("a",{key:0,href:o.href,onClick:n[0]||(n[0]=t.withModifiers((...a)=>o.open&&o.open(...a),["stop","prevent"])),target:"_blank"},[t.createTextVNode(t.toDisplayString(o.actualValue)+" ",1),t.createVNode(l,{right:"",icon:"fa-external-link"})],8,y_)):t.createCommentVNode("",!0)])}const Fd=w(p_,[["render",k_],["__scopeId","data-v-aa99a5e7"]]);var Id=function(e,n,r){if(!n.hasOwnProperty(r)){var i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,i)}};const Ad={props:{template:String,parent:Object,templateProps:{type:Object,default:function(){return{}}}},render:function(){if(this.template){var e=this.parent||this.$parent,n=e.$data;n===void 0&&(n={});var r=e.$props;r===void 0&&(r={});var i=e.$options;i===void 0&&(i={});var s=i.components;s===void 0&&(s={});var o=i.computed;o===void 0&&(o={});var l=i.methods;l===void 0&&(l={});var a=this.$data;a===void 0&&(a={});var c=this.$props;c===void 0&&(c={});var d=this.$options;d===void 0&&(d={});var u=d.methods;u===void 0&&(u={});var m=d.computed;m===void 0&&(m={});var f=d.components;f===void 0&&(f={});var h={$data:{},$props:{},$options:{},components:{},computed:{},methods:{}};Object.keys(n).forEach(function(b){a[b]===void 0&&(h.$data[b]=n[b])}),Object.keys(r).forEach(function(b){c[b]===void 0&&(h.$props[b]=r[b])}),Object.keys(l).forEach(function(b){u[b]===void 0&&(h.methods[b]=l[b])}),Object.keys(o).forEach(function(b){m[b]===void 0&&(h.computed[b]=o[b])}),Object.keys(s).forEach(function(b){f[b]===void 0&&(h.components[b]=s[b])});var g=Object.keys(h.methods||{}),p=Object.keys(h.$data||{}),y=Object.keys(h.$props||{}),k=Object.keys(this.templateProps),x=p.concat(y).concat(g).concat(k),S=(P=e,q={},g.forEach(function(b){return Id(P,q,b)}),q),I=function(b){var F={};return b.forEach(function(O){O&&Object.getOwnPropertyNames(O).forEach(function(U){return Id(O,F,U)})}),F}([h.$data,h.$props,S,this.templateProps]);return t.h({template:this.template||"<div></div>",props:x,computed:h.computed,components:h.components,provide:this.$parent.$.provides?this.$parent.$.provides:{}},Object.assign({},I))}var P,q}},__={components:{Compile:Ad},mixins:[le]},w_={class:"table-computed-cell"};function x_(e,n,r,i,s,o){const l=t.resolveComponent("compile");return t.openBlock(),t.createElementBlock("td",w_,[t.createVNode(l,{template:this.column.code},null,8,["template"])])}const b_=w(__,[["render",x_],["__scopeId","data-v-05dd3203"]]),C_={props:{multi:{type:Boolean},last:{type:Boolean},value:{required:!0},type:{type:String},widget:{type:String}},computed:{reference(){return!!(this.value&&this.value._id)},renderValue(){return this.value?this.value.title||this.value.name||this.value:void 0},date(){return _.fromISO(this.value).toFormat("dd MMM yyyy")},actualWidget(){var e;if(this.widget)e=this.widget;else switch(this.type){case"date":e="datetime";break}return e}},methods:{clicked(e){this.$sdk.dispatch("item:view",e)}}};function V_(e,n,r,i,s,o){const l=t.resolveComponent("ux-pill");return o.reference?(t.openBlock(),t.createBlock(l,{key:0,tag:"a",value:r.value,onClick:n[0]||(n[0]=t.withModifiers(a=>o.clicked(r.value),["stop","prevent"]))},null,8,["value"])):r.type=="date"?(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createTextVNode(t.toDisplayString(o.date),1)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:2},[t.createTextVNode(t.toDisplayString(o.renderValue),1),r.multi&&!r.last?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createTextVNode(", ")],64)):t.createCommentVNode("",!0)],64))}const N_=w(C_,[["render",V_],["__scopeId","data-v-27442ac9"]]),E_=".total",B_={mixins:[le],methods:{clicked(e){this.menuOpen=!1,this.$sdk.dispatch("item:view",e)}},data(){return{menuOpen:!1}},computed:{path(){return this.column.key||""},rawPath(){return this.path.slice(0,-E_.length)},itemPath(){return`${this.rawPath}.items`},value(){return ht(this.row,this.column.key)},items(){return ht(this.row,this.itemPath)}}},S_={class:"table-complex-cell"},T_={class:"items"};function D_(e,n,r,i,s,o){const l=t.resolveComponent("ux-button"),a=t.resolveComponent("ux-pill"),c=t.resolveComponent("ux-menu");return t.openBlock(),t.createElementBlock("td",S_,[t.createVNode(c,{modelValue:s.menuOpen,"onUpdate:modelValue":n[1]||(n[1]=d=>s.menuOpen=d)},{activator:t.withCtx(({on:d})=>[t.createVNode(l,t.mergeProps({size:"sm",onClick:n[0]||(n[0]=t.withModifiers(()=>{},["stop","prevent"]))},t.toHandlers(d),{icon:""}),{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.value),1)]),_:2},1040)]),default:t.withCtx(()=>[t.createElementVNode("div",T_,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.items,d=>(t.openBlock(),t.createBlock(a,{tag:"a",value:d,onClick:t.withModifiers(u=>o.clicked(d),["stop","prevent"])},null,8,["value","onClick"]))),256))])]),_:1},8,["modelValue"])])}const O_=w(B_,[["render",D_],["__scopeId","data-v-1cdab26c"]]),M_={mixins:[le],computed:{email(){var e;return this.row.username||((e=this.row.user)==null?void 0:e.email)||this.row.userEmailAddress||this.row.collectionEmailAddress}}},F_={class:"table-persona-email-cell"};function I_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",F_,t.toDisplayString(o.email),1)}const A_=w(M_,[["render",I_],["__scopeId","data-v-9c894a39"]]),L_={mixins:[le],computed:{className(){return this.isConnected?"connected":this.isInvited?"invited":this.isManaged?"managed":"empty"},isConnected(){return!!this.row.user},isInvited(){return!this.isConnected&&this.row.collectionEmailAddress},isManaged(){return!this.isConnected&&!this.isInvited},email(){var e;return this.row.username||((e=this.row.user)==null?void 0:e.email)||this.row.userEmailAddress||this.row.collectionEmailAddress},text(){switch(this.className){case"connected":return"Qik User";case"invited":return"Invite sent";case"managed":return"App user";default:return""}},tooltip(){var r,i,s,o;const e=this,n=(i=(r=e.user)==null?void 0:r.organisation)!=null&&i.title?`'${(o=(s=e.user)==null?void 0:s.organisation)==null?void 0:o.title}'`:void 0;switch(e.className){case"connected":return`This user can sign in to ${n||"your organisation"} on the Qik platform.`;case"invited":return"We've sent an invite to this user to join your organisation on Qik.";case"managed":return"This user can only sign in to your applications.";default:return""}},icon(){switch(this.className){case"connected":return"far fa-user";case"invited":return"far fa-envelope";case"managed":return"far fa-user";default:return}}}},$_={class:"pill"};function P_(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon"),a=t.resolveComponent("tippy");return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-persona-invite-cell",o.className])},[t.createVNode(a,{content:o.tooltip},{default:t.withCtx(()=>[t.createElementVNode("div",$_,[t.createVNode(l,{icon:o.icon,left:""},null,8,["icon"]),t.createTextVNode(" "+t.toDisplayString(o.text),1)])]),_:1},8,["content"])],2)}const R_=w(L_,[["render",P_],["__scopeId","data-v-be3bef4b"]]),U_={mixins:[le],computed:{status(){return String(this.value||"").toLowerCase()}}},j_={key:0,class:"pill"};function q_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-status-cell",o.status])},[o.status?(t.openBlock(),t.createElementBlock("div",j_,t.toDisplayString(o.status),1)):t.createCommentVNode("",!0)],2)}const z_=w(U_,[["render",q_],["__scopeId","data-v-357810c2"]]),W_={mixins:[le],computed:{typeKey(){var e;return(e=this.row.meta)==null?void 0:e.type},subtitle(){var l,a,c,d,u,m,f;const e=this,n=this.row,r=n.subtitle,i=n.description,s=(l=n.meta)==null?void 0:l.description,o=r||i||s;switch(this.typeKey){case"runsheet":return n.event?`${n.event.title} • ${e.$sdk.date.readableEventDate(n.event)}`:"";case"venue":return[(a=n.address)==null?void 0:a.addressLine1,(c=n.address)==null?void 0:c.addressLine2,(d=n.address)==null?void 0:d.suburb,(u=n.address)==null?void 0:u.state,(m=n.address)==null?void 0:m.postalCode,(f=n.address)==null?void 0:f.country].filter(Boolean).join(" ");case"event":if(n.startDate,n.endDate,e.$sdk.date)return o?`${e.$sdk.date.readableEventDate(n)} • ${o}`:`${e.$sdk.date.readableEventDate(n)}`;break}return o}}},H_={class:"title"},G_={key:0,class:"subtitle"};function Y_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-title-cell",e.status])},[t.createElementVNode("div",H_,t.toDisplayString(e.value),1),o.subtitle?(t.openBlock(),t.createElementBlock("div",G_,t.toDisplayString(o.subtitle),1)):t.createCommentVNode("",!0)],2)}const J_=w(W_,[["render",Y_],["__scopeId","data-v-bf723bb2"]]),K_={props:{value:{type:Object}},computed:{style(){var r,i;const e=(r=this.value)==null?void 0:r.color,n=(i=this.value)==null?void 0:i.bgColor;if(e||n)return{backgroundColor:n||e}}}};function Z_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("span",{class:"ux-circle",style:t.normalizeStyle(o.style)},null,4)}const pr=w(K_,[["render",Z_],["__scopeId","data-v-6f2d4cea"]]),X_={mixins:[le],components:{UxCircle:pr},computed:{scopes(){return this.column.key==="_id"?[this.row]:(this.value||[]).filter(function({unit:n}){return!n})}}},Q_={class:"scope-circles-cell"};function v_(e,n,r,i,s,o){const l=t.resolveComponent("ux-circle"),a=t.resolveComponent("tippy");return t.openBlock(),t.createElementBlock("td",Q_,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.scopes,c=>(t.openBlock(),t.createBlock(a,{content:c.title},{default:t.withCtx(()=>[t.createVNode(l,{value:c},null,8,["value"])]),_:2},1032,["content"]))),256))])}const ew=w(X_,[["render",v_],["__scopeId","data-v-f79f00ee"]]),tw={mixins:[le],created(){this.$glossary.ensure()},computed:{glossary(){return this.$glossary.hash},match(){return this.glossary?this.glossary[this.value]:null},title(){var e;return((e=this.match)==null?void 0:e.title)||this.value}}},nw={class:"content-type-cell"};function rw(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",nw,t.toDisplayString(o.title),1)}const ow=w(tw,[["render",rw],["__scopeId","data-v-26ccbfe4"]]),iw={mixins:[le],computed:{count(){return this.rosters.reduce(function(e,n){return n.slots.forEach(function(r){e+=r.assignments.length}),e},0)},rosters(){return Object.entries(this.row.join_roster||{}).map(function([n,r]){return{title:n,slots:r.items}})},rosterEnabled(){return this.$sdk.access.hasFeature(this.user,"rostering")?this.$sdk.access.canKnowOf(this.user,"roster")||this.$sdk.access.canKnowOf(this.user,"assignment"):void 0}}},sw={class:"table-roster-cell"},lw={class:"event-title"},aw={class:"event-date"},cw={class:"event-subtitle"},dw={class:"preview"},uw={class:"grid"},mw={class:"face"};function fw(e,n,r,i,s,o){const l=t.resolveComponent("ux-button"),a=t.resolveComponent("ux-panel-header"),c=t.resolveComponent("ux-avatar"),d=t.resolveComponent("flex-cell"),u=t.resolveComponent("flex-row"),m=t.resolveComponent("ux-panel-body"),f=t.resolveComponent("ux-panel"),h=t.resolveComponent("ux-menu");return t.openBlock(),t.createElementBlock("td",sw,[o.rosterEnabled&&o.count?(t.openBlock(),t.createBlock(h,{key:0,right:"",group:"roster-preview"},{activator:t.withCtx(({on:g})=>[t.createVNode(l,t.mergeProps({size:"sm"},t.toHandlers(g),{icon:"",onClick:n[0]||(n[0]=t.withModifiers(()=>{},["stop"]))}),{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.count),1)]),_:2},1040)]),default:t.withCtx(()=>[t.createVNode(f,null,{default:t.withCtx(()=>[t.createVNode(a,null,{default:t.withCtx(()=>[t.createElementVNode("div",lw,t.toDisplayString(e.row.title),1),t.createElementVNode("div",aw,t.toDisplayString(e.$sdk.date.readableEventDate(e.row)),1),t.createElementVNode("div",cw,t.toDisplayString(e.row.subtitle),1)]),_:1}),t.createVNode(m,null,{default:t.withCtx(()=>[t.createElementVNode("div",dw,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.rosters,g=>(t.openBlock(),t.createElementBlock("div",null,[t.createElementVNode("div",uw,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(g.slots,p=>(t.openBlock(),t.createElementBlock("div",null,[t.createElementVNode("h4",null,t.toDisplayString(p.title),1),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(p.assignments,y=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["assignment",y.state||"unknown"])},[t.createVNode(u,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(d,{shrink:""},{default:t.withCtx(()=>[t.createElementVNode("div",mw,[t.createVNode(c,{initials:`${y.profile.firstName} ${y.profile.lastName}`,id:y.profile},null,8,["initials","id"])])]),_:2},1024),t.createVNode(d,null,{default:t.withCtx(()=>{var k,x;return[t.createTextVNode(t.toDisplayString((k=y.profile)==null?void 0:k.firstName)+" "+t.toDisplayString((x=y.profile)==null?void 0:x.lastName),1)]}),_:2},1024)]),_:2},1024)],2))),256))]))),256))])]))),256))])]),_:1})]),_:1})]),_:1})):t.createCommentVNode("",!0)])}const hw=w(iw,[["render",fw],["__scopeId","data-v-88720bfa"]]),pw={mixins:[le],data(){return{runsheets:[],creating:!1}},created(){var e,n;this.runsheets=((n=(e=this.row.join_runsheet)==null?void 0:e.runsheet)==null?void 0:n.items)||[]},methods:{async addRunsheet(){const e=this;e.creating=!0,e.$sdk.global.create("runsheet",{model:{event:e.row}}).then(function(n){e.runsheets.push(n),e.openRunsheet(n),e.creating=!1},function(n){e.creating=!1})},async openRunsheet(e){const n=this.$sdk.access.canEditItem(this.user,e);return console.log("OPEN",n,e),n?this.editRunsheet(e):this.viewRunsheet(e)},async editRunsheet(e){const n=await this.$sdk.global.edit(e,!0);e.title=n.title},async viewRunsheet(e){const n=await this.$sdk.global.view(e,!0);e.title=n.title}},computed:{count(){var e;return(e=this.runsheets)==null?void 0:e.length}}},gw={class:"table-roster-cell"},yw={class:"wrp"};function kw(e,n,r,i,s,o){const l=t.resolveComponent("ux-button"),a=t.resolveComponent("ux-panel-body"),c=t.resolveComponent("ux-list-item"),d=t.resolveComponent("ux-list"),u=t.resolveComponent("ux-panel"),m=t.resolveComponent("ux-menu"),f=t.resolveComponent("ux-icon"),h=t.resolveDirective("tippy");return t.openBlock(),t.createElementBlock("td",gw,[t.withDirectives((t.openBlock(),t.createElementBlock("div",yw,[o.count?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[o.count>1?(t.openBlock(),t.createBlock(m,{key:0},{activator:t.withCtx(({on:g})=>[t.createVNode(l,t.mergeProps({size:"xs"},t.toHandlers(g),{onClick:n[0]||(n[0]=t.withModifiers(()=>{},["stop"])),icon:""}),{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.count),1)]),_:2},1040)]),default:t.withCtx(()=>[t.createVNode(u,null,{default:t.withCtx(()=>[t.createVNode(a,null,{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.count)+" Run Sheet"+t.toDisplayString(o.count===1?"":"s"),1)]),_:1}),t.createVNode(d,null,{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(s.runsheets,g=>(t.openBlock(),t.createBlock(c,{onClick:p=>o.openRunsheet(g)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(g.title)+" ",1)]),_:2},1032,["onClick"]))),256))]),_:1})]),_:1})]),_:1})):(t.openBlock(),t.createBlock(l,{key:1,size:"xs",icon:"",onClick:n[1]||(n[1]=t.withModifiers(g=>o.openRunsheet(s.runsheets[0]),["stop"]))},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.count),1)]),_:1}))],64)):(t.openBlock(),t.createBlock(l,{key:1,size:"xs",icon:"",loading:s.creating,onClick:t.withModifiers(o.addRunsheet,["stop"])},{default:t.withCtx(()=>[t.createVNode(f,{icon:"fa-plus"})]),_:1},8,["loading","onClick"]))])),[[h,{placement:"bottom",content:`${o.count} Run Sheets`}]])])}const _w=w(pw,[["render",kw],["__scopeId","data-v-b904ed97"]]);function Li(e,n){if(!e||!n)return;const r=n.split("|");n=r[0];const i=r[1];var s=ht(e,n);if(s)return i&&Array.isArray(s)?s.filter(function(d){var m;const u=(m=d==null?void 0:d.meta)==null?void 0:m.definition;if(i==="null")return!u;if(u)return u===i}):s;const o=n.split("."),l=o.shift(),a=o.join("."),c=ht(e,l);return Array.isArray(c)?c.map(function(d){return Li(d,a)}).flat().filter(Boolean):Li(c,a)}const ww={data(){return{component:null}},components:{ValueRenderer:N_},async created(){const e=this;let n,r=e.column.type,i=e.column.renderer,s=e.column.key;if(!i)switch(s){case"fileSize":i="filesize";break;case"duration":i="duration";break;case"title":i="title";break;case"status":case"paymentStatus":case"meta.status":i="status";break;case"meta.tags":i="tag";break;case"meta.definition":i="type";break}switch(e.column.widget){case"button":break;default:i=i||e.column.widget;break}switch(r){case"boolean":i="boolean";break;case"reference":e.column.referenceType==="image"&&(i="thumbnail");break}switch(i){case"filesize":n=l_;break;case"duration":n=u_;break;case"button":n=qk;break;case"security":n=h_;break;case"boolean":n=Md;break;case"roster":n=hw;break;case"runsheet":n=_w;break;case"personainvite":n=R_;break;case"personaemail":n=A_;break;case"time":case"timefield":n=Ok;break;case"date":case"datetime":n=Od;break;case"due":n=n_;break;case"circles":n=ew;break;case"title":n=J_;break;case"type":n=ow;break;case"complex":n=O_;break;case"status":n=z_;break;case"computed":n=b_;break;case"url":n=Fd;break;case"currency":n=Pk;break;case"tag":n=bk;break;case"avatar":n=Bk;break;case"thumbnail":n=Ak;break;default:switch(r){case"date":n=Od;break;case"boolean":n=Md;break;case"url":n=Fd;break}break}e.component=n},props:{column:{type:Object,required:!0},row:{type:Object,required:!0}},computed:{nowrap(){return this.column.wrap===!1},multiValue(){return Array.isArray(this.value)},renderer(){return this.column.renderer},renderValue(){var e=this.value;if(e!=null)return e.title||e.name||e},value(){var e=Li(this.row,this.column.key);return e}}},xw={class:"value"};function bw(e,n,r,i,s,o){const l=t.resolveComponent("value-renderer");return s.component?(t.openBlock(),t.createBlock(t.resolveDynamicComponent(s.component),{key:0,column:r.column,row:r.row,value:o.value},null,8,["column","row","value"])):(t.openBlock(),t.createElementBlock("td",{key:1,class:t.normalizeClass(["table-cell",{nowrap:o.nowrap}])},[o.multiValue?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:0},t.renderList(o.value,(a,c)=>(t.openBlock(),t.createElementBlock("span",xw,[t.createVNode(l,{type:r.column.type,multi:"",last:c===o.value.length-1,value:a},null,8,["type","last","value"])]))),256)):(t.openBlock(),t.createBlock(l,{key:1,type:r.column.type,value:o.value},null,8,["type","value"]))],2))}const Ld=w(ww,[["render",bw],["__scopeId","data-v-43da03cf"]]),Cw={components:{TableCell:Ld},props:{selected:{type:Boolean},index:{type:Number},row:{type:Object,required:!0},columns:{type:Array,required:!0},enableActions:{type:Boolean,default(){return!1}},enableSelection:{type:Boolean,default(){return!0}}},emits:["click:cell","click:row","click:actions","mousedown:select","mouseenter:select"],methods:{clickCell(e){this.$emit("click:cell",{row:this.row,column:e}),this.$emit("click:row",this.row)},clickActions(e){this.$emit("click:actions",e)},mousedownSelect(e){this.$emit("mousedown:select",this.row,this.index,e)},mouseenterSelect(){this.$emit("mouseenter:select",this.row,this.index)}},computed:{classes(){var n,r;var e=[];return this.selected&&e.push("selected"),((r=(n=this.row)==null?void 0:n.meta)==null?void 0:r.status)==="inactive"&&e.push("inactive"),e}}};function Vw(e,n,r,i,s,o){const l=t.resolveComponent("ux-checkbox"),a=t.resolveComponent("table-cell"),c=t.resolveComponent("ux-icon"),d=t.resolveComponent("ux-button");return t.openBlock(),t.createElementBlock("tr",{class:t.normalizeClass([o.classes,"table-row"])},[t.renderSlot(e.$slots,"default",{},()=>[r.enableSelection?(t.openBlock(),t.createElementBlock("th",{key:0,class:"table-cell table-select first shrink",onMousedown:n[0]||(n[0]=t.withModifiers((...u)=>o.mousedownSelect&&o.mousedownSelect(...u),["prevent"])),onMouseenter:n[1]||(n[1]=(...u)=>o.mouseenterSelect&&o.mouseenterSelect(...u)),onClick:n[2]||(n[2]=t.withModifiers(()=>{},["stop","prevent"]))},[t.createVNode(l,{value:r.selected},null,8,["value"])],32)):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.columns,(u,m)=>(t.openBlock(),t.createBlock(a,{key:`${u.path||u.key}-${m}-${u.type}-${u.renderer}`,onClick:t.withModifiers(f=>o.clickCell(u),["stop","prevent"]),column:u,row:r.row},null,8,["onClick","column","row"]))),128)),r.enableActions?(t.openBlock(),t.createElementBlock("th",{key:1,class:"table-cell last shrink",onClick:n[3]||(n[3]=t.withModifiers(u=>o.clickActions(r.row),["stop","prevent"]))},[t.createVNode(d,{size:"xs",icon:""},{default:t.withCtx(()=>[t.createVNode(c,{icon:"fa-ellipsis"})]),_:1})])):t.createCommentVNode("",!0)],!0)],2)}const Nw=w(Cw,[["render",Vw],["__scopeId","data-v-e196f762"]]),$d={data(){return{scrollTop:0}},methods:{updateScroll(e){var n=this.$refs.scroll;n=(n==null?void 0:n.$el)||n,n&&(this.scrollTop=n.scrollTop)}},mounted(){var e=this.$refs.scroll;e=(e==null?void 0:e.$el)||e,e&&e.addEventListener("scroll",this.updateScroll)},beforeUnmount(){var e=this.$refs.scroll;e=(e==null?void 0:e.$el)||e,e&&e.removeEventListener("scroll",this.updateScroll)},activated(){var e=this.$refs.scroll;e=(e==null?void 0:e.$el)||e,e&&(e.scrollTop=this.scrollTop)}},Ew={mixins:[$d],components:{TableRow:Nw,TableCell:Ld},emits:["update:sort","select:multiple","deselect:multiple","select:multiple","click:row","click:cell","click:actions","select:row:toggle"],watch:{rows(){this.$refs.scroll.scroll({top:0,left:0})},sort(e){this.sorting=e},sorting(e){this.$emit("update:sort",e)}},props:{total:{type:Number},columns:{type:Array,default(){return[]}},rows:{type:Array,default(){return[]}},scrollable:{type:Boolean,default(){return!0}},enableActions:{type:Boolean,default(){return!1}},enableSelection:{type:Boolean,default(){return!0}},sort:{type:Object,default(){return{key:"meta.created",type:"date",direction:"desc"}}},selection:{type:Array,default(){return[]}},selectAll:{type:Function},deselectAll:{type:Function},group:{type:Object,default(){return{}}}},data(){return{sorting:this.sort,lastSelectedIndex:null,lastSelectAction:null,dragging:!1,dragMode:null}},beforeUnmount(){window.removeEventListener("mouseup",this.endDrag)},computed:{groupedRows(){const e=this.group.key,n=this.group.type||"string";if(e){const{values:r}=this.renderRows.reduce(function(i,s){let o=ht(s,e);o=String(o);let l=i.keys[o];return l||(l=i.keys[o]={title:o,rows:[]},i.values.push(l)),i},{values:[],keys:{}});return r}return[{rows:this.renderRows}]},currentSortDirection(){var e;return((e=this.sorting)==null?void 0:e.direction)||"asc"},selectionHash(){var e=this;return e.selection.reduce(function(n,r){var i=r._id||r.id;return n[i]=r,n},{})},pageSelected(){var e=this;if(!(!e.rows||!e.rows.length))return!e.rows.some(function(n){return!e.selectionHash[n._id||n.id]})},renderColumns(){return this.columns.map(function(n){var r=Object.assign({},n);return r.class=[],r.shrink&&r.class.push("shrink"),r})},renderRows(){return this.rows},someSelectedOnPage(){return this.rows.some(this.isSelected)}},methods:{togglePage(){var e=this;e.pageSelected?e.deselectPage():e.selectPage()},selectPage(){var e=this;e.$emit("select:multiple",e.rows)},deselectPage(){var e=this;e.$emit("deselect:multiple",e.rows)},isSelected(e){var n=this,r=e._id||e.id;return n.selection.some(function(i){var s=i._id||i.id;return i==e||s==r})},classes(e){let n=[];return this.isSelected(e)&&n.push("selected"),n},selectRange(e,n){const r=Math.min(e,n),i=Math.max(e,n)+1,s=this.renderRows.slice(r,i);this.$emit("select:multiple",s)},deselectRange(e,n){const r=Math.min(e,n),i=Math.max(e,n)+1,s=this.renderRows.slice(r,i);this.$emit("deselect:multiple",s)},toggleSort(e){var o,l;const n=(o=this.sorting)==null?void 0:o.key,r=((l=this.sorting)==null?void 0:l.direction)||"asc";let{key:i,direction:s}=e;i===n&&(s=r==="dsc"?"asc":"dsc"),this.sorting={key:i,direction:s,type:e.type}},clickRow(e){this.$emit("click:row",e)},clickCell({row:e,column:n}){this.$emit("click:cell",{row:e,column:n})},clickActions(e){this.$emit("click:actions",e)},mousedownSelect(e,n,r){const s=this.isSelected(e)?"deselect":"select";if(r.shiftKey&&this.lastSelectedIndex!=null&&this.lastSelectedIndex!==n){this.lastSelectAction==="deselect"?this.deselectRange(this.lastSelectedIndex,n):this.selectRange(this.lastSelectedIndex,n),this.lastSelectedIndex=n;return}s==="select"?this.$emit("select:multiple",[e]):this.$emit("deselect:multiple",[e]),this.lastSelectedIndex=n,this.lastSelectAction=s,this.dragging=!0,this.dragMode=s,window.addEventListener("mouseup",this.endDrag,{once:!0})},mouseenterSelect(e,n){if(!this.dragging)return;const r=this.isSelected(e);this.dragMode==="select"&&!r?this.$emit("select:multiple",[e]):this.dragMode==="deselect"&&r&&this.$emit("deselect:multiple",[e])},endDrag(){this.dragging&&(this.dragging=!1,this.dragMode=null,window.removeEventListener("mouseup",this.endDrag))}}},Bw={class:"table-scroll",ref:"scroll"},Sw={key:0,class:"first table-select shrink"},Tw=["onClick"],Dw={key:1,class:"last shrink"},Ow={key:0};function Mw(e,n,r,i,s,o){const l=t.resolveComponent("ux-checkbox"),a=t.resolveComponent("ux-list-item"),c=t.resolveComponent("ux-list"),d=t.resolveComponent("ux-menu"),u=t.resolveComponent("flex-cell"),m=t.resolveComponent("flex-row"),f=t.resolveComponent("table-row");return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["table-wrapper",{dragging:s.dragging}]),onMouseup:n[4]||(n[4]=(...h)=>o.endDrag&&o.endDrag(...h))},[t.createElementVNode("div",Bw,[t.createElementVNode("table",null,[t.createElementVNode("thead",null,[t.createElementVNode("tr",null,[r.enableSelection?(t.openBlock(),t.createElementBlock("th",Sw,[t.createVNode(d,null,{activator:t.withCtx(({on:h})=>[t.createVNode(l,t.mergeProps(t.toHandlers(h),{value:o.pageSelected}),null,16,["value"])]),default:t.withCtx(()=>[t.createVNode(c,null,{default:t.withCtx(()=>[t.createVNode(a,{onClick:n[0]||(n[0]=h=>o.selectPage())},{default:t.withCtx(()=>[t.createTextVNode(" Select Page ")]),_:1}),o.someSelectedOnPage?(t.openBlock(),t.createBlock(a,{key:0,onClick:n[1]||(n[1]=h=>o.deselectPage())},{default:t.withCtx(()=>[t.createTextVNode(" Deselect Page ")]),_:1})):t.createCommentVNode("",!0),r.selectAll?(t.openBlock(),t.createBlock(a,{key:1,onClick:n[2]||(n[2]=h=>r.selectAll())},{default:t.withCtx(()=>[t.createTextVNode(" Select All ("+t.toDisplayString(r.total)+") ",1)]),_:1})):t.createCommentVNode("",!0),r.deselectAll?(t.openBlock(),t.createBlock(a,{key:2,onClick:n[3]||(n[3]=h=>r.deselectAll())},{default:t.withCtx(()=>[t.createTextVNode(" Deselect All ")]),_:1})):t.createCommentVNode("",!0)]),_:1})]),_:1})])):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.renderColumns,h=>{var g;return t.openBlock(),t.createElementBlock("th",{onClick:p=>o.toggleSort(h),class:t.normalizeClass([{sortable:h.sortable!==!1,active:h.key===((g=s.sorting)==null?void 0:g.key)},h.class])},[t.createVNode(m,{gap:"",vcenter:""},{default:t.withCtx(()=>{var p;return[t.createVNode(u,null,{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(h.title),1)]),_:2},1024),h.key===((p=s.sorting)==null?void 0:p.key)?(t.openBlock(),t.createBlock(u,{key:0,class:"caret",shrink:""},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.currentSortDirection==="asc"?"▲":"▼"),1)]),_:1})):t.createCommentVNode("",!0)]}),_:2},1024)],10,Tw)}),256)),r.enableActions?(t.openBlock(),t.createElementBlock("th",Dw,[t.renderSlot(e.$slots,"corner",{},void 0,!0)])):t.createCommentVNode("",!0)])]),t.createElementVNode("tbody",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.groupedRows,h=>(t.openBlock(),t.createElementBlock(t.Fragment,null,[h.title?(t.openBlock(),t.createElementBlock("tr",Ow,[t.createElementVNode("td",null,t.toDisplayString(h.title),1)])):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(h.rows,(g,p)=>(t.openBlock(),t.createBlock(f,{enableSelection:r.enableSelection,enableActions:r.enableActions,key:g._id,"onClick:cell":o.clickCell,"onClick:row":o.clickRow,"onMousedown:select":o.mousedownSelect,"onMouseenter:select":o.mouseenterSelect,"onClick:actions":o.clickActions,selected:o.isSelected(g),row:g,index:p,columns:r.columns},null,8,["enableSelection","enableActions","onClick:cell","onClick:row","onMousedown:select","onMouseenter:select","onClick:actions","selected","row","index","columns"]))),128))],64))),256))])])],512)],34)}const Pd=w(Ew,[["render",Mw],["__scopeId","data-v-c1fe12b7"]]);var gr={exports:{}},Rd;function Fw(){if(Rd)return gr.exports;Rd=1;var e=Object.prototype.hasOwnProperty;function n(s){return"[Throws: "+(s?s.message:"?")+"]"}function r(s,o){if(e.call(s,o))try{return s[o]}catch(l){return n(l)}return s[o]}function i(s){var o=[];function l(a){if(a===null||typeof a!="object")return a;if(o.indexOf(a)!==-1)return"[Circular]";if(o.push(a),typeof a.toJSON=="function")try{var c=l(a.toJSON());return o.pop(),c}catch(m){return n(m)}if(Array.isArray(a)){var d=a.map(l);return o.pop(),d}var u=Object.keys(a).reduce(function(m,f){return m[f]=l(r(a,f)),m},{});return o.pop(),u}return l(s)}return gr.exports=function(s,o,l){return JSON.stringify(i(s),o,l)},gr.exports.ensureProperties=i,gr.exports}var Iw=Fw();const $i=ft(Iw);function Aw(e,n){return e==null||n=="date"&&e.toString&&e.toString()==="Invalid Date"}function Ud(e){return e!=null}const z={emits:["touched","update:modelValue"],props:{field:{type:Object,default(){return{}}},parentModel:{type:Object}},data(){return{dynamicOptions:[],asyncOptionsAreLoading:this.field.asyncOptions,value:this.modelValue}},watch:{modelValue(e,n){this.model=e}},mounted(){this.checkAutofocus()},async created(){const e=this;e.hasAsyncOptions&&await e.reloadAsyncOptions()},inject:{form:{default(){}},fieldPath:{default(){}}},computed:{asyncOptionsURL(){const e=this;if(e.field.asyncOptions&&String(e.field.asyncOptions||"").trim().length)return e.field.asyncOptions;if(e.field.dynamicOptions){const n=e.$sdk.utils.id(e.field.dynamicOptions);if(n)return e.$sdk.api.generateEndpointURL(`/smartlist/${n}/select`)}},hasAuthenticationToken(){return this.$sdk.auth.getCurrentToken()},hasAsyncOptions(){var e;if(this.asyncOptionsURL)return!0;if(this.field.type==="reference"){if((e=this.field.allowedReferences)!=null&&e.length)return!1;switch(this.field.widget){case"select":if(this.hasAuthenticationToken)return!0;break;default:return!1}if(this.field.lockFilter)return!0}return!1},loadingAsyncOptions(){return this.hasAsyncOptions&&this.asyncOptionsAreLoading},optionLookup(){var e=this;return e.options.reduce(function(n,r){const i=e.getValue(r);return n[i]=r,n},{})},selectableOptions(){return this.options},required(){return this.minimum},model:{get(){var e=this.cleanOutput(this.value);return e},set(e){let n;(this.isGroup||this.widget==="form")&&(e===this.value?n=!1:n=!0);const r=this.cleanInput(e),i=this.cleanInput(this.value);($i(r)!=$i(i)||n)&&(this.value=r,this.checkAutofocus(),this.dispatch())}},options(){var e=this;if(e.field.type==="reference"){const n=(e.field.allowedReferences||[]).filter(Boolean);if(n.length)return n.map(function(r){let{_id:i,title:s}=r;return s=s||[r.firstName,r.lastName].filter(Boolean).join(" "),{title:s,value:i,_id:i}})}return e.hasAsyncOptions?e.dynamicOptions:(e.field.options||[]).reduce(function(n,r){if(!r)return n;const i=e.getValue(r);var o={title:r.title||r.name||r.label||i,value:i,none:r.none,group:r.group,source:r};return e.field.type=="reference"&&(o._id=i),n.push(o),n},[])},prefix(){return this.field.suffix},suffix(){return this.field.suffix},type(){return this.field.type||"string"},key(){return this.field.key},isGroup(){return this.type==="group"},asObject(){return this.isGroup&&!!this.field.asObject},layoutGroup(){return this.isGroup&&!this.field.asObject},canAddValue(){if(!this.singleValue&&!(this.options.length&&this.selectableOptions.length===0))return this.maximum===0||this.numValues<this.maximum},canRemoveValue(){return this.numValues>this.minimum},widget(){return this.field.widget},singleValue(){if(this.asObject){var e=this.minimum===1&&this.maximum===1;return e}else return this.maximum===1},multiValue(){return!this.singleValue},label(){return this.field.title},title(){return this.label},plural(){return this.field.plural},description(){return this.field.description},placeholder(){return this.field.placeholder||this.field.hint},addLabel(){return this.field.addLabel?this.field.addLabel:this.numValues?`Add another ${this.label}`:`Add ${this.label}`},removeLabel(){return"Remove"},size(){return this.field.size},numValues(){return this.singleValue?1:(this.value||[]).length||0},showLabel(){return this.field.title&&!this.field.hideTitle},showDescription(){return this.description},fields(){var e=this.field.fields;if(e&&e.length)return e},minimum(){if(this.layoutGroup)return 1;var e=parseInt(this.field.minimum||0);return isNaN(e)&&(e=0),e=Math.max(e,0),e=this.maximum?Math.min(e,this.maximum):e,parseInt(e)},maximum(){if(this.layoutGroup)return 1;var e=parseInt(this.field.maximum||0);return isNaN(e)&&(e=0),e=Math.max(e,0),parseInt(e)},ask(){var e=parseInt(this.field.ask);return e=Math.max(e,this.minimum),this.maximum&&(e=Math.min(e,this.maximum)),e},minDate(){if(this.field.minDate)return new Date(this.field.minDate)},maxDate(){if(this.field.maxDate)return new Date(this.field.maxDate)}},methods:{async reloadAsyncOptions(){const e=this;if(!e.hasAsyncOptions){e.asyncOptionsAreLoading=!1;return}if(e.asyncOptionsAreLoading=!0,e.asyncOptionsURL){const{data:n}=await e.$sdk.api.get(e.asyncOptionsURL);e.dynamicOptions=(n||[]).map(function(r){let i=r==null?void 0:r.title;i||(i=r==null?void 0:r.name),i||(i=r==null?void 0:r.label),i||(i=[r.firstName,r.lastName].filter(Boolean).join(" ").trim()),i||(i=r.value||String(r));const s=String((r==null?void 0:r.value)||(r==null?void 0:r.title)||(r==null?void 0:r.name)||(r==null?void 0:r.label)||r),o=e.$sdk.utils.id((r==null?void 0:r._id)||r);return{title:i,value:s,_id:o}})}else if(e.hasAuthenticationToken){const n=e.field.referenceType,r={filter:e.field.lockFilter,sort:{key:"title",direction:"asc",type:"string"},page:{size:1e3}},{items:i}=await e.$sdk.content.list(n,r);e.dynamicOptions=i.map(function({_id:s,title:o}){return{value:s,title:o,_id:s}})}e.asyncOptionsAreLoading=!1},cleanTextInput(e,n,r){switch(n){case"url":e=r.$sdk.utils.parseURL(e);break;case"key":e=String(r.$sdk.utils.machineName(e||"")||"").trim();break;case"integer":e=parseInt(String(e).replace(/[^0-9-]/g,"")),isNaN(e)&&(e=void 0);break;case"number":case"decimal":case"float":e=Number(String(e).replace(/[^0-9.-]/g,"")),isNaN(e)&&(e=void 0);break}return e},checkAutofocus(){if(this.field.autofocus){if(this.value)return;this.$nextTick(function(){this.refocus()})}},getValue(e){if(!e)return this.cleanTextInput(e);var n=this.cleanTextInput(e._id||e.value),r=Ud(n);return!r&&e.title&&!this.returnObject&&(n=e.title),n=this.cleanTextInput(n),Ud(n)?n:e},getLabel(e){if(e){var n=e.title;return!n&&n!==0&&n!==!1&&(n=e.name),!n&&n!==0&&n!==!1&&(n=e.label),!n&&n!==0&&n!==!1&&(n=e.value),typeof n=="object"?"(no title)":n}},touch(){this.$emit("touched")},getNewDefaultEntry(){},add(){if(this.canAddValue){var e=this.cleanInputValue(this.getNewDefaultEntry());(!this.value||!Array.isArray(this.value))&&(this.value=[]),this.value.push(e),this.dispatch(),this.$nextTick(function(){this.refocus()}),this.touch()}},remove(e){var n=this.model.indexOf(e);this.model.splice(n,1),this.dispatch(),this.touch()},dispatch(){this.$emit("update:modelValue",this.value)},cleanInputValue(e){return e},cleanOutputValue(e){return e},cleanOutput(e){var n=this;return Aw(e,n.field.type)?n.multiValue?e=[]:e=void 0:n.multiValue?(Array.isArray(e)||(e=[]),e.forEach(function(r,i){e[i]=n.cleanOutputValue(r)})):e=n.cleanOutputValue(e),e},cleanInput(e){var n=this;if(n.multiValue){for(e||(e=[]),Array.isArray(e)||(e=[e]),n.maximum&&e.length>n.maximum&&(e.length=n.maximum);e.length<n.minimum;)e.push(n.cleanInputValue(n.getNewDefaultEntry()));e=e.map(function(r){var i=n.cleanInputValue(r);return i})}else e&&(e=n.cleanInputValue(e));return e},refocus(){var e=this.$refs.input;if(e){var n;Array.isArray(e)?(console.log("ELEMENTS LENGTH?",e),n=e[e.length-1]):n=e,n&&(console.log("INPUT",n),n.focus())}}}};function Lw(e){return e===void 0||typeof e>"u"||e===null||String(e)==="null"||String(e)==="undefined"}const $w={data(){return{candidate:null}},props:{modelValue:{},pills:{type:Boolean,default:!1}},mixins:[z],created(){this.model=this.model},methods:{displayLabelFromValue(e){if(!e)return;const n=e.value||e,r=this.optionLookup[n]||{};return r.title||r.name||e.title||e.value||e},addValue(e){this.canAddValue&&this.model.indexOf(e)===-1&&(this.model=[...this.model,e])},removeValue(e){var n=this.model.slice();e!=-1&&(n.splice(e,1),this.model=n)},cleanOutput(e){var n=this;return Lw(e)?n.multiValue?e=[]:e=void 0:n.multiValue?e=(e||[]).filter(function(r){return r!=null}).map(function(r){return n.getValue(r)}):e=n.getValue(e),e},cleanInput(e){var n=this;if(n.multiValue)e||(e=[]),Array.isArray(e)||(e=[e]),n.maximum&&e.length>n.maximum&&(e.length=n.maximum),e=e.filter(function(i){return i!=null}).map(function(i){var s=n.getValue(i);return n.returnObject?n.optionLookup[s]:s});else{var r=n.getValue(e);switch(e=n.returnObject?n.optionLookup[r]:r,e){case"":switch(n.type){case"decimal":case"float":case"number":case"integer":e=void 0;break}break}}return e}},watch:{candidate(e){e&&(this.addValue(e),this.candidate=null)}},computed:{noneTitle(){return this.field.placeholder||"None"},usePills(){return this.field.pills||this.pills},returnObject(){return this.type=="reference"},classes(){var e=[];return this.multiValue?e.push("multiple"):e.push("single"),this.usePills&&e.push("pills"),e},summary(){if(this.multiValue)return"Select an option";const e=this.selectableOptions.find(function(i){return i.none}),n=(e==null?void 0:e.title)||(e==null?void 0:e.label),r=this.model;return r||r===!1||r===0?this.getLabel(this.optionLookup[this.model]):n||this.noneTitle||this.title||"Click to select"},grouped(){const e=this,{values:n}=e.selectableOptions.reduce(function(r,i){const s=i.group||"";let o=r.hash[s];return o||(o=r.hash[s]={title:s,options:[]},r.values.push(o)),o.options.push(i),r},{hash:{},values:[]});if(!(n.length<=1))return n},modelLookup(){var e=this;return e.multiValue?e.model.reduce(function(n,r){const i=e.getValue(r);return n[i]=r,n},{}):{}},selectableOptions(){var r;const e=this;let n=e.options;return e.multiValue&&(n=n.filter(function(i){return!e.modelLookup[e.getValue(i)]})),(r=e.field)!=null&&r.sorted?n.sort(function(i,s){var o=(i.title||i).toLowerCase(),l=(s.title||s).toLowerCase();return o<l?-1:o>l?1:0}):n},showNoneOption(){return!(!(this.singleValue&&!this.minimum)||this.selectableOptions.find(function(r){return r.none}))}}},Pw=e=>(t.pushScopeId("data-v-9fabb548"),e=e(),t.popScopeId(),e),Rw={key:0,class:"ux-field-title"},Uw={key:0,class:"ux-required-marker"},jw={key:1,class:"ux-field-description"},qw={key:2,class:"select-tags"},zw=["onClick"],Ww={key:3},Hw={key:4,class:"select-input-wrapper"},Gw={class:"ui-select-button"},Yw=Pw(()=>t.createElementVNode("option",{value:""},"Select an option",-1)),Jw=["label"],Kw=["value"],Zw=["value"],Xw={class:"ui-select-button"},Qw=["multiple"],vw={key:0,value:""},e1=["label"],t1=["value"],n1=["value"];function r1(e,n,r,i,s,o){var u,m;const l=t.resolveComponent("flex-cell"),a=t.resolveComponent("ux-icon"),c=t.resolveComponent("flex-row"),d=t.resolveComponent("ux-button");return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["native-select",o.classes])},[e.showLabel?(t.openBlock(),t.createElementBlock("label",Rw,[t.createTextVNode(t.toDisplayString(e.label)+" ",1),e.required?(t.openBlock(),t.createElementBlock("span",Uw,"*")):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),e.showDescription?(t.openBlock(),t.createElementBlock("div",jw,t.toDisplayString(e.description),1)):t.createCommentVNode("",!0),e.multiValue?(t.openBlock(),t.createElementBlock("div",qw,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.model,(f,h)=>(t.openBlock(),t.createElementBlock("div",{class:"select-tag",key:f.value||f},[t.createVNode(c,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(l,null,{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.displayLabelFromValue(f)),1)]),_:2},1024),t.createVNode(l,{shrink:""},{default:t.withCtx(()=>[t.createElementVNode("a",{onClick:g=>o.removeValue(h)},[t.createVNode(a,{icon:"fa-times"})],8,zw)]),_:2},1024)]),_:2},1024)]))),128))])):t.createCommentVNode("",!0),e.loadingAsyncOptions?(t.openBlock(),t.createElementBlock("div",Ww,[t.createVNode(a,{icon:"fa-spinner",spin:"",left:""}),t.createTextVNode(" Loading Options ")])):(t.openBlock(),t.createElementBlock("div",Hw,[e.multiValue?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[e.canAddValue?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createElementVNode("div",Gw,[t.renderSlot(e.$slots,"default",{},()=>[t.createVNode(d,{size:e.size,tag:"div"},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.summary),1)]),_:1},8,["size"])],!0)]),t.withDirectives((t.openBlock(),t.createElementBlock("select",{onFocus:n[0]||(n[0]=(...f)=>e.touch&&e.touch(...f)),"onUpdate:modelValue":n[1]||(n[1]=f=>s.candidate=f),key:(u=e.model)==null?void 0:u.length},[Yw,o.grouped?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:0},t.renderList(o.grouped,f=>(t.openBlock(),t.createElementBlock("optgroup",{label:f.title,key:f.title},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(f.options,h=>(t.openBlock(),t.createElementBlock("option",{value:h.value},t.toDisplayString(h.title),9,Kw))),256))],8,Jw))),128)):(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:1},t.renderList(o.selectableOptions,f=>(t.openBlock(),t.createElementBlock("option",{value:f.value},t.toDisplayString(f.title),9,Zw))),256))],32)),[[t.vModelSelect,s.candidate]])],64)):t.createCommentVNode("",!0)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createElementVNode("div",Xw,[t.renderSlot(e.$slots,"default",{},()=>[t.createVNode(d,{size:e.size,tag:"div"},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.summary),1)]),_:1},8,["size"])],!0)]),t.withDirectives((t.openBlock(),t.createElementBlock("select",{onFocus:n[2]||(n[2]=(...f)=>e.touch&&e.touch(...f)),multiple:e.multiValue,"onUpdate:modelValue":n[3]||(n[3]=f=>e.model=f),key:(m=e.model)==null?void 0:m.length},[o.showNoneOption?(t.openBlock(),t.createElementBlock("option",vw,t.toDisplayString(o.noneTitle),1)):t.createCommentVNode("",!0),o.grouped?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:1},t.renderList(o.grouped,f=>(t.openBlock(),t.createElementBlock("optgroup",{label:f.title,key:f.title},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(f.options,h=>(t.openBlock(),t.createElementBlock("option",{value:h.value},t.toDisplayString(h.title),9,t1))),256))],8,e1))),128)):(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:2},t.renderList(o.selectableOptions,f=>(t.openBlock(),t.createElementBlock("option",{value:f.value},t.toDisplayString(f.title),9,n1))),256))],40,Qw)),[[t.vModelSelect,e.model]])],64))]))],2)}const Ke=w($w,[["render",r1],["__scopeId","data-v-9fabb548"]]),o1={props:{total:{type:Number,default(){return 0}},page:{type:Object,default(){return{size:50,index:1}}},sizeOptions:{type:Array,default(){return[50,100,250,500]}}},components:{NativeSelect:Ke},watch:{totalPages(){this.currentPage=0}},computed:{perPage:{get(){return this.pageModel.size},set(e){e=Math.max(e,1),this.pageModel.size=e,this.dispatch()}},pageField(){return{type:"integer",maximum:1,minimum:1,options:Array(this.totalPages).fill(1).map((e,n)=>e+n)}},totalPages(){return Math.ceil(this.total/this.perPage)},startIndex(){return(this.currentPage-1)*this.pageModel.size},displayStartIndex(){return this.total?this.startIndex+1:0},endIndex(){return Math.min(this.startIndex+this.pageModel.size,this.total)},currentPage:{get(){return this.pageModel.index},set(e){this.totalPages&&(e=Math.min(this.totalPages,e)),e=Math.max(e,1),this.pageModel.index=e,this.dispatch()}}},methods:{dispatch(){return this.$emit("update:page",this.pageModel)},previousPage(){this.currentPage--},nextPage(){this.currentPage++}},data(){return{pageModel:this.page,perPageField:{minimum:1,maximum:1,options:this.sizeOptions.map(function(e){return{title:`${e} per page`,value:e}})}}}};function i1(e,n,r,i,s,o){const l=t.resolveComponent("native-select"),a=t.resolveComponent("flex-cell"),c=t.resolveComponent("ux-icon"),d=t.resolveComponent("ux-button"),u=t.resolveComponent("flex-row");return t.openBlock(),t.createBlock(u,{center:"",gap:""},{default:t.withCtx(()=>[t.createVNode(a,{shrink:"",class:"text"},{default:t.withCtx(()=>[t.createVNode(l,{modelValue:o.perPage,"onUpdate:modelValue":n[0]||(n[0]=m=>o.perPage=m),field:s.perPageField},{default:t.withCtx(()=>[e.$device.breakpoint.xs?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createTextVNode(t.toDisplayString(o.displayStartIndex)+"-"+t.toDisplayString(o.endIndex)+" of "+t.toDisplayString(r.total),1)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createTextVNode("Showing "+t.toDisplayString(o.displayStartIndex)+" to "+t.toDisplayString(o.endIndex)+" of "+t.toDisplayString(r.total)+" total",1)],64))]),_:1},8,["modelValue","field"])]),_:1}),t.createVNode(a),o.totalPages>1?(t.openBlock(),t.createBlock(a,{key:0,shrink:""},{default:t.withCtx(()=>[t.createVNode(u,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(a,{shrink:"",class:"text"},{default:t.withCtx(()=>[t.createVNode(l,{modelValue:o.currentPage,"onUpdate:modelValue":n[1]||(n[1]=m=>o.currentPage=m),field:o.pageField},{default:t.withCtx(()=>[e.$device.breakpoint.xs?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createTextVNode(t.toDisplayString(o.currentPage)+"/"+t.toDisplayString(o.totalPages),1)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createTextVNode("Page "+t.toDisplayString(o.currentPage)+" of "+t.toDisplayString(o.totalPages),1)],64))]),_:1},8,["modelValue","field"])]),_:1}),t.createVNode(a,{shrink:""},{default:t.withCtx(()=>[t.createVNode(d,{size:"sm",icon:"",onClick:n[2]||(n[2]=m=>o.previousPage())},{default:t.withCtx(()=>[t.createVNode(c,{icon:"fa-arrow-left"})]),_:1})]),_:1}),t.createVNode(a,{shrink:""},{default:t.withCtx(()=>[t.createVNode(d,{size:"sm",icon:"",onClick:n[3]||(n[3]=m=>o.nextPage())},{default:t.withCtx(()=>[t.createVNode(c,{icon:"fa-arrow-right"})]),_:1})]),_:1})]),_:1})]),_:1})):t.createCommentVNode("",!0)]),_:1})}const jd=w(o1,[["render",i1],["__scopeId","data-v-93d339c8"]]);function s1(e){return t.getCurrentScope()?(t.onScopeDispose(e),!0):!1}function qd(e){return typeof e=="function"?e():t.unref(e)}const l1=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const a1=e=>e!=null,Pi=()=>{};function Ri(e){var n;const r=qd(e);return(n=r==null?void 0:r.$el)!=null?n:r}const c1=l1?window:void 0;function d1(){const e=t.ref(!1),n=t.getCurrentInstance();return n&&t.onMounted(()=>{e.value=!0},n),e}function u1(e){const n=d1();return t.computed(()=>(n.value,!!e()))}function m1(e,n,r={}){const{root:i,rootMargin:s="0px",threshold:o=.1,window:l=c1,immediate:a=!0}=r,c=u1(()=>l&&"IntersectionObserver"in l),d=t.computed(()=>{const g=qd(e);return(Array.isArray(g)?g:[g]).map(Ri).filter(a1)});let u=Pi;const m=t.ref(a),f=c.value?t.watch(()=>[d.value,Ri(i),m.value],([g,p])=>{if(u(),!m.value||!g.length)return;const y=new IntersectionObserver(n,{root:Ri(p),rootMargin:s,threshold:o});g.forEach(k=>k&&y.observe(k)),u=()=>{y.disconnect(),u=Pi}},{immediate:a,flush:"post"}):Pi,h=()=>{u(),f(),m.value=!1};return s1(h),{isSupported:c,isActive:m,pause(){u(),m.value=!1},resume(){m.value=!0},stop:h}}const f1={setup(){const e=t.ref(!1),n=t.ref(),{stop:r}=m1(n,([{isIntersecting:i}])=>{i&&(e.value=!0,r())},{rootMargin:"600px"});return{targetEl:n,shouldRender:e}}},h1={ref:"targetEl"};function p1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",h1,[i.shouldRender?t.renderSlot(e.$slots,"default",{key:0}):t.createCommentVNode("",!0)],512)}const zd=w(f1,[["render",p1]]),g1={props:{icon:{type:[Object,String],default(){return"fa-exclamation"}},type:{type:String,default:"info"}},computed:{classes(){var e=[];return e.push(`ux-info-${this.type}`),e}}},y1={class:"icon-circle"};function k1(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon"),a=t.resolveComponent("flex-cell"),c=t.resolveComponent("flex-row");return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-info-box",o.classes])},[t.createVNode(c,{style:{gap:"1em"},center:""},{default:t.withCtx(()=>[r.icon?(t.openBlock(),t.createBlock(a,{key:0,shrink:""},{default:t.withCtx(()=>[t.createElementVNode("div",y1,[t.createVNode(l,{icon:r.icon},null,8,["icon"])])]),_:1})):t.createCommentVNode("",!0),t.createVNode(a,null,{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3})]),_:3})],2)}const Wd=w(g1,[["render",k1],["__scopeId","data-v-9669e7c0"]]),_1={props:{id:{type:[Object,String]},initials:{type:[String,Object]},cacheKey:{type:[String,Number]}},data(){return{stringID:this.$sdk.utils.id(this.id)}},watch:{id(e){this.stringID=this.$sdk.utils.id(e)}},computed:{initialString(){var s,o,l;if(typeof this.initials=="string")return this.initials;const e=((s=this.initials)==null?void 0:s.firstName)||"",n=((o=this.initials)==null?void 0:o.lastName)||"",r=`${e} ${n}`.trim(),i=(l=this.initials)==null?void 0:l.title;return r||i},initialLetters(){const e=this.initialString||"";if(!e||!e.length)return"";const n=e.split(/\s+/);let r="";return n[0]&&(r+=String(n[0][0]||"").toUpperCase()),n[1]&&(r+=String(n[1][0]||"").toUpperCase()),r},url(){const e={};return this.cacheKey&&(e.cacheKey=this.cacheKey),this.$sdk.api.generateEndpointURL(`/image/${this.stringID}`,e,{file:!0})},style(){const e={};return e.backgroundImage=`url(${this.url})`,e}}},w1={key:0,class:"initials"};function x1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["avatar-image",{"with-initials":o.initialLetters}])},[o.initialLetters?(t.openBlock(),t.createElementBlock("div",w1,t.toDisplayString(o.initialLetters),1)):t.createCommentVNode("",!0),t.createElementVNode("div",{class:"avatar-img",style:t.normalizeStyle(o.style)},null,4)],2)}const Ui=w(_1,[["render",x1],["__scopeId","data-v-0acb5372"]]),b1={props:{large:{type:Boolean}}},C1=[(e=>(t.pushScopeId("data-v-d9a57955"),e=e(),t.popScopeId(),e))(()=>t.createElementVNode("svg",{width:"24",height:"24",stroke:"#000",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},[t.createElementVNode("g",{class:"spinner_V8m1"},[t.createElementVNode("circle",{cx:"12",cy:"12",r:"9.5",fill:"none","stroke-width":"2"})])],-1))];function V1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-spinner",{large:r.large}])},C1,2)}const Pt=w(b1,[["render",V1],["__scopeId","data-v-d9a57955"]]),N1={components:{Spinner:Pt},props:{to:{type:[Object,String]},icon:{type:Boolean},color:{type:String,default:"default"},bgColor:{type:String},fgColor:{type:String},tag:{type:String},href:{type:String},target:{type:String},loading:{type:Boolean},active:{type:Boolean},disabled:{type:Boolean},block:{type:Boolean},size:{type:String,default:"md"}},computed:{style(){var e={};return this.bgColor&&(e.backgroundColor=this.bgColor),this.fgColor&&(e.color=this.fgColor),e},classes(){var e=[];return e.push(`ux-btn-${this.size}`),this.block&&e.push("ux-btn-block"),this.loading&&e.push("ux-btn-loading"),this.active&&e.push("ux-btn-active"),this.icon&&e.push("ux-btn-icon"),e.push(`ux-btn-color-${this.color}`),this.disabled&&e.push("ux-btn-disabled"),e},element(){switch(this.tag){case"span":return this.tag;case"submit":return"button";default:return this.to||this.href?"ux-link":this.tag||"button"}}}},E1={class:"ux-btn-text"};function B1(e,n,r,i,s,o){const l=t.resolveComponent("spinner");return t.openBlock(),t.createBlock(t.resolveDynamicComponent(o.element),{type:"button",active:r.active,loading:r.loading,to:r.to,href:r.href,target:r.target,style:t.normalizeStyle(o.style),class:t.normalizeClass([o.classes,"ux-btn"]),disabled:r.disabled},{default:t.withCtx(()=>[r.loading?(t.openBlock(),t.createBlock(l,{key:0})):t.createCommentVNode("",!0),t.createElementVNode("span",E1,[t.renderSlot(e.$slots,"default",{},void 0,!0)])]),_:3},8,["active","loading","to","href","target","style","class","disabled"])}const Hd=w(N1,[["render",B1],["__scopeId","data-v-ea56e98b"]]),S1={props:{value:{type:Boolean,default(){return!1}}},computed:{classes(){var e=[];return this.value?e.push("ux-checkbox-true"):e.push("ux-checkbox-false"),e}}};function T1(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("button",{class:t.normalizeClass(["ux-checkbox",o.classes])},[t.createVNode(l,{class:"icon",icon:"fa-check"})],2)}const yr=w(S1,[["render",T1],["__scopeId","data-v-54bb07ba"]]),D1={props:{value:{type:Boolean,default(){return!1}},loading:{type:Boolean,default(){return!1}}},computed:{classes(){var e=[];return this.value?e.push("ux-switch-true"):e.push("ux-switch-false"),this.loading&&e.push("ux-switch-loading"),e}}};function O1(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("a",{class:t.normalizeClass(["ux-switch",o.classes])},[t.createElementVNode("span",null,[t.createVNode(l,{spin:"",icon:"fa-spinner"})])],2)}const ji=w(D1,[["render",O1],["__scopeId","data-v-1a0e83ee"]]),M1={props:{to:{type:[Object,String]},href:{type:String},target:{type:String},disabled:{type:Boolean},active:{type:Boolean}},methods:{clicked(e){var n=this;if(n.to&&(n.buildMode||n.nuxtMode))return e.preventDefault(),e.stopImmediatePropagation(),n.$sdk.app.to(n.to);if(n.href){if(n.buildMode){e.preventDefault(),window.open(n.href);return}if(n.nuxtMode){e.preventDefault(),e.stopImmediatePropagation();return}}}},computed:{actualHref(){if(this.href)return this.href;if(this.nuxtMode)return this.to?this.$sdk.app.createHref(this.to):void 0;if(this.to&&this.$router&&this.$router.resolve){const e=this.$router;this.$route;const n=!1,{location:r,route:i,href:s}=e.resolve(this.to,this.$route,n);return s}},nuxtMode(){return this.to&&this.$sdk.nuxt&&this.$sdk.app&&this.$sdk.app.createHref},buildMode(){return!!this.$sdk&&this.$sdk.app&&this.$sdk.app.builder},class(){var e=[];return this.disabled&&e.push("disabled"),this.active&&e.push("active"),(this.href||this.to)&&e.push("haslink"),e},element(){return this.nuxtMode||this.buildMode?"a":this.to?"router-link":"a"}}};function F1(e,n,r,i,s,o){return t.openBlock(),t.createBlock(t.resolveDynamicComponent(o.element),{onClick:o.clicked,to:r.to,href:o.actualHref,target:r.target,class:t.normalizeClass([o.class,"ux-link"])},{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["onClick","to","href","target","class"])}const Gd=w(M1,[["render",F1],["__scopeId","data-v-7a924ee2"]]),I1={props:{icon:{type:[Object,String]},spin:{type:Boolean},left:{type:Boolean},right:{type:Boolean},fixed:{type:Boolean}},computed:{classes(){var e=[];return e.push(this.icon),this.spin&&e.push("fa-spin"),this.left&&e.push("ux-icon-left"),this.right&&e.push("ux-icon-right"),this.fixed&&e.push("ux-icon-fixed"),e},element(){return"i"}}};function A1(e,n,r,i,s,o){return t.openBlock(),t.createBlock(t.resolveDynamicComponent(o.element),{class:t.normalizeClass(["ux-icon fa",o.classes])},null,8,["class"])}const Yd=w(I1,[["render",A1],["__scopeId","data-v-e7a15ac2"]]),kr={cache:{}},L1={props:{group:{type:String},right:{type:Boolean,default:!1},bottom:{type:Boolean,default:!1},stop:{type:Boolean,default:!1},flex:{type:Boolean,default:!1},closeOnClick:{type:Boolean,default:!0},visible:{type:Boolean,default:!0},modelValue:{type:Boolean,default:!1}},data(){return{outerStyle:{},innerStyle:{},isExpanded:this.modelValue,isVisible:this.visible,triggerEvent:null,refMenu:null,mounted:!1}},watch:{modelValue(e){this.expanded=e},visible(e){this.isVisible=e}},mounted(){this.refMenu=this.$refs.menu,this.mounted=!0},beforeUnmount(){this.removeListeners(),this.refMenu=null,this.mounted=!1,kr.cache[this.group]===this&&(kr.cache[this.group]=null)},methods:{removeListeners(){document.removeEventListener("click",this.globalClick),this.refMenu&&this.refMenu.removeEventListener("click",this.immediateClick)},addEventListeners(){document.addEventListener("click",this.globalClick),this.refMenu&&this.refMenu.addEventListener("click",this.immediateClick)},immediateClick(e){this.expanded&&this.closeOnClick&&(e.stopImmediatePropagation(),this.expanded=!1)},globalClick(e){if(this.triggerEvent!==e){var n=this.$refs.menu,r=e.srcElement;n&&n.contains(r)?this.closeOnClick&&(this.expanded=!1):this.expanded=!1}},position(){const e=this.$el.getBoundingClientRect();let n=e.left+window.scrollX,r=e.bottom+window.scrollY;this.outerStyle.left=`${n}px`,this.outerStyle.top=`${r}px`,this.innerStyle={},this.right&&(this.innerStyle.right=`-${e.width}px`),this.bottom&&(this.innerStyle.bottom=`${e.height}px`);var i=this.getMaxZIndex();this.outerStyle.zIndex=i,this.$nextTick(()=>{this.adjustForViewportBoundaries(e)})},adjustForViewportBoundaries(e){if(!this.refMenu)return;this.refMenu.getBoundingClientRect();const n={width:window.innerWidth,height:window.innerHeight};let r=e.left+window.scrollX,i=e.bottom+window.scrollY,s=!1;const o={...this.innerStyle};this.innerStyle={},this.$nextTick(()=>{const l=this.refMenu.getBoundingClientRect(),a=e.left+l.width>n.width,c=e.left,d=n.width-e.right;a&&c>d?(r=e.right+window.scrollX-l.width,s=!0):this.right&&!a&&(this.innerStyle.right=`-${e.width}px`);const u=e.bottom+l.height>n.height,m=e.top,f=n.height-e.bottom;u&&m>f?(i=e.top+window.scrollY-l.height,s=!0):this.bottom&&!u&&(this.innerStyle.bottom=`${e.height}px`),s?(this.outerStyle.left=`${Math.max(0,r)}px`,this.outerStyle.top=`${Math.max(0,i)}px`):this.innerStyle=o,this.ensureWithinViewport()})},ensureWithinViewport(){if(!this.refMenu)return;const e=this.refMenu.getBoundingClientRect(),n={width:window.innerWidth,height:window.innerHeight};let r=parseInt(this.outerStyle.left)||0,i=parseInt(this.outerStyle.top)||0;e.right>n.width&&(r-=e.right-n.width+10),e.left<0&&(r+=Math.abs(e.left)+10),e.bottom>n.height&&(i-=e.bottom-n.height+10),e.top<0&&(i+=Math.abs(e.top)+10),this.outerStyle.left=`${Math.max(0,r)}px`,this.outerStyle.top=`${Math.max(0,i)}px`},getMaxZIndex(){return Math.max(...Array.from(document.querySelectorAll("body *"),e=>parseFloat(window.getComputedStyle(e).zIndex)).filter(e=>!Number.isNaN(e)),0)},close(){this.expanded=!1}},computed:{expanded:{get(){return this.isExpanded},set(e){var n;this.group&&(n=kr.cache[this.group]),this.isExpanded!=e&&(this.isExpanded=e,e?(this.position(),this.addEventListeners(),kr.cache[this.group]=this,n&&n!=this&&(n.expanded=!1)):this.removeListeners(),this.$emit("update:modelValue",e))}},on(){var e=this;return{click(n){e.stop&&n.stopImmediatePropagation(),e.triggerEvent=n,e.expanded=!e.expanded}}}}};function $1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-menu",{right:r.right}])},[t.createElementVNode("span",null,[t.renderSlot(e.$slots,"activator",{on:o.on},void 0,!0)]),(t.openBlock(),t.createBlock(t.Teleport,{to:"body"},[t.createVNode(t.Transition,{name:"ux-menu-transition",appear:""},{default:t.withCtx(()=>[s.isExpanded?t.withDirectives((t.openBlock(),t.createElementBlock("div",{key:0,class:"ux-menu-outer",style:t.normalizeStyle(s.outerStyle)},[t.createElementVNode("div",{class:t.normalizeClass(["ux-menu-panel",{flex:r.flex}]),ref:"menu",style:t.normalizeStyle(s.innerStyle)},[t.renderSlot(e.$slots,"default",{},void 0,!0)],6)],4)),[[t.vShow,s.isVisible]]):t.createCommentVNode("",!0)]),_:3})]))],2)}const Jd=w(L1,[["render",$1],["__scopeId","data-v-6be4a759"]]),P1={name:"menulist",props:{items:{type:Array,default(){return[]}},depth:{type:Number,default:0},expandOn:{type:String,default:"none"},isolate:{type:Boolean,default:!0},collapseOnRouteChange:{type:Boolean,default:!0},displayCaret:{type:Boolean,default:!0}},mounted(){this.mounted=!0,this.addRouteChangeListeners()},beforeUnmount(){this.mounted=!1,this.removeRouteChangeListeners(),this.removeListeners()},computed:{actualDepth(){const e=this.depth;return isNaN(e)||!parseInt(e)?0:Math.max(e,0)},filteredItems(){const e=this;let n=e.tree.filter(function(r){return!(r.advancedOptions&&e.$sdk.utils.checkContextVisibility&&!e.$sdk.utils.checkContextVisibility(r.contextVisibility)||r.disabled)});return this.actualDepth===1&&(n=n.map(function(r){return{...r,items:[]}})),n}},data(){return{currentExpandedItems:[],tree:JSON.parse(JSON.stringify(this.items))}},methods:{globalClick(e){this.currentExpandedItems=[]},routeChanged(){this.collapseOnRouteChange&&this.collapseAll()},addRouteChangeListeners(){this.$sdk.addEventListener("route:change",this.routeChanged)},removeRouteChangeListeners(){this.$sdk.removeEventListener("route:change",this.routeChanged)},addListeners(){var n;const e=(n=this.$el)==null?void 0:n.ownerDocument;e&&e.body.addEventListener("click",this.globalClick)},removeListeners(){var n;const e=(n=this.$el)==null?void 0:n.ownerDocument;e&&e.body.removeEventListener("click",this.globalClick)},expandItem(e){e.expanded=!0,this.currentExpandedItems.push(e)},collapseItem(e){const n=this.currentExpandedItems.indexOf(e);n!==-1&&(e.expanded=!1,this.currentExpandedItems.splice(n,1))},collapseAll(){this.currentExpandedItems.forEach(function(e){e.expanded=!1}),this.currentExpandedItems=[],this.currentExpandedItems.length?this.addListeners():this.removeListeners()},toggle(e){const n=e.expanded;this.isolate&&(this.currentExpandedItems.forEach(function(i){i.expanded=!1}),this.currentExpandedItems=[]);const r=this.currentExpandedItems.indexOf(e);n||r!==-1?this.collapseItem(e):this.expandItem(e),this.currentExpandedItems.length?this.addListeners():this.removeListeners()}},watch:{items:{handler(e){this.tree=JSON.parse(JSON.stringify(e))},deep:!0}}};function R1(e,n,r,i,s,o){const l=t.resolveComponent("flex-cell"),a=t.resolveComponent("ux-icon"),c=t.resolveComponent("flex-row"),d=t.resolveComponent("ux-link"),u=t.resolveComponent("menulist",!0);return t.openBlock(),t.createElementBlock("ul",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.filteredItems,m=>{var f;return t.openBlock(),t.createElementBlock("li",{class:t.normalizeClass({expanded:m.expanded,collapsed:!m.expanded}),key:m.title},[r.expandOn==="click"&&((f=m.items)!=null&&f.length)?(t.openBlock(),t.createBlock(d,{key:0,onClick:t.withModifiers(h=>o.toggle(m),["stop","prevent"]),class:t.normalizeClass(m.class)},{default:t.withCtx(()=>[t.createVNode(c,{center:""},{default:t.withCtx(()=>[t.createVNode(l,null,{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(m.title),1)]),_:2},1024),r.displayCaret?(t.openBlock(),t.createBlock(l,{key:0,shrink:""},{default:t.withCtx(()=>[t.createVNode(a,{class:"caret",icon:"fa-angle-down"})]),_:1})):t.createCommentVNode("",!0)]),_:2},1024)]),_:2},1032,["onClick","class"])):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[m.type==="url"?(t.openBlock(),t.createBlock(d,{key:0,class:t.normalizeClass(m.class),target:m.target,href:m.href||m.url},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(m.title),1)]),_:2},1032,["class","target","href"])):m.type==="route"?(t.openBlock(),t.createBlock(d,{key:1,class:t.normalizeClass(m.class),to:{name:m.route}},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(m.title),1)]),_:2},1032,["class","to"])):t.createCommentVNode("",!0)],64)),m.items&&m.items.length?(t.openBlock(),t.createBlock(u,{key:2,expandOn:r.expandOn,items:m.items,displayCaret:r.displayCaret,isolate:r.isolate,depth:o.actualDepth-1},null,8,["expandOn","items","displayCaret","isolate","depth"])):t.createCommentVNode("",!0)],2)}),128))])}const Kd=w(P1,[["render",R1],["__scopeId","data-v-cbfd31c1"]]),U1={props:{item:{type:[Object,String]},alt:{type:String},width:{type:[Number,String]},height:{type:[Number,String]},auto:{type:Boolean,default:!0},inline:{type:Boolean},quality:{type:[Number,String]},contain:{type:Boolean,default:!0},preview:{type:Boolean,default:!1},crop:{type:Boolean},cover:{type:Boolean},format:{type:String},upscale:{type:Boolean,default:!0},type:{type:String,default:"image"},svg:{type:Boolean},lazy:{type:Boolean},eager:{type:Boolean}},data(){return{model:this.item,retries:0,cacheBuster:0,retryTimer:null}},watch:{item(e){this.model=e}},beforeMount(){this.$sdk.auth.ensureValidToken()},mounted(){const e=this.$refs.img;e&&e.addEventListener("error",this.imageLoadError)},beforeUnmount(){const e=this.$refs.img;e&&e.removeEventListener("error",this.imageLoadError)},methods:{imageLoadError(e){const n=this;n.retryTimer&&(clearTimeout(n.retryTimer),n.retryTimer=!1),n.retryTimer=setTimeout(function(){n.retries<5&&(n.cacheBuster++,n.retries++)},500)}},computed:{actualFormat(){var r,i;const e=((r=this.item)==null?void 0:r.fileMime)==="image/heic",n=((i=this.item)==null?void 0:i.fileExtension)==="heic";return e||n?"png":this.format},loading(){if(this.lazy)return"lazy";if(this.eager)return"eager"},altText(){var e;return this.alt||((e=this.model)==null?void 0:e.title)},className(){var e=[];return this.portrait&&e.push("img-portrait"),e.join(" ")},isSvg(){var e;if(this.svg)return!0;switch((e=this.item)==null?void 0:e.fileMime){case"image/svg+xml":case"image/svg":return!0}},portrait(){return this.crop?this.dimensionHeight>this.dimensionWidth:this.modelHeight>this.modelWidth},manualWidth(){return parseInt(this.width)},manualHeight(){return parseInt(this.height)},modelWidth(){var e;return parseInt((e=this.model)==null?void 0:e.width)},modelHeight(){var e;return parseInt((e=this.model)==null?void 0:e.height)},id(){return this.$sdk.utils.id(this.model)},params(){var n,r,i,s;var e={};if(e.access_token=this.$sdk.auth.getCurrentToken(),e.cb=this.cacheBuster,this.manualWidth&&(e.w=this.manualWidth?this.manualWidth:void 0),this.manualHeight&&(e.h=this.manualHeight?this.manualHeight:void 0),this.upscale&&(e.u=!0),this.auto&&!e.w&&!e.h){const o=(s=(i=(r=(n=this.$sdk.app)==null?void 0:n.device)==null?void 0:r.image)==null?void 0:i.auto)==null?void 0:s.med;o&&(e.w=o,e.u=!1)}return this.crop?e.c=!0:this.contain||(e.c=!!parseInt(this.manualWidth)&&!!parseInt(this.manualHeight)),this.quality&&(e.q=parseInt(this.quality)),this.actualFormat&&(e.f=this.actualFormat),e},src(){return this.$sdk.api.generateEndpointURL(`/image/${this.id}`,this.params,{file:!0})},previewSrc(){var e=Object.assign({},this.params);return e.w=50,delete e.h,this.$sdk.api.generateEndpointURL(`/image/${this.id}`,e,{file:!0})},imageStyle(){var e={};return this.crop||(e["object-fit"]="contain"),this.cover&&(e["object-fit"]="cover"),this.inline?e.maxWidth="100%":(e.width="100%",e.height="100%",e.top="0",e.left="0",e.position="absolute"),e},dimensionWidth(){if(this.manualHeight&&this.manualWidth)return this.manualWidth;if(this.modelWidth&&this.modelHeight)return this.modelWidth},dimensionHeight(){if(this.manualHeight&&this.manualWidth)return this.manualHeight;if(this.modelWidth&&this.modelHeight)return this.modelHeight},style(){var r,i,s;var e={};this.inline?e.display="inline-block":this.dimensionHeight&&this.dimensionWidth&&(e.height=0,e.overflow="hidden",e.paddingBottom=`${this.dimensionHeight/this.dimensionWidth*100}%`,e.position="relative");var n=(s=(i=(r=this.model)==null?void 0:r.fileMeta)==null?void 0:i.colors)==null?void 0:s.colors;return n&&n.length&&(e.backgroundColor=n[0]),this.isSvg||this.preview&&(e.backgroundImage=`url(${this.previewSrc})`),e}}},j1=["alt","data"],q1=["loading","alt","src"];function z1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-image",o.className]),style:t.normalizeStyle(o.style)},[r.svg?(t.openBlock(),t.createElementBlock("object",{key:0,alt:o.altText,type:"image/svg+xml",data:o.src},null,8,j1)):(t.openBlock(),t.createElementBlock("img",{key:1,ref:"img",loading:o.loading,alt:o.altText,style:t.normalizeStyle(o.imageStyle),src:o.src},null,12,q1))],6)}const Zd=w(U1,[["render",z1],["__scopeId","data-v-ba449734"]]),W1={props:{item:{type:[Object,String]},width:{type:[Number,String]},height:{type:[Number,String]},controls:{type:Boolean,default:!0},controlslist:{type:String},autoplay:{type:Boolean,default:!1},playsinline:{type:Boolean,default:!1},loop:{type:Boolean,default:!1},muted:{type:Boolean,default:!1}},data(){return{model:this.item,isMuted:this.muted||this.autoplay,playsInline:this.playsinline||this.autoplay}},watch:{playsinline(e){this.playsInline=e},muted(e){this.isMuted=e}},beforeMount(){this.$sdk.auth.ensureValidToken()},computed:{padHeight(){return this.actualHeight&&this.actualWidth?`${this.actualHeight/this.actualWidth*100}%`:void 0},youtubeSrc(){return`https://www.youtube.com/embed/${this.mediaID}`},title(){var e;return(e=this.model)==null?void 0:e.title},mediaID(){var e;return(e=this.model)==null?void 0:e.mediaIntegrationID},mediaType(){var e;return((e=this.model)==null?void 0:e.mediaIntegrationType)||"upload"},mimetype(){var e;return((e=this.model)==null?void 0:e.fileMime)||"video/mp4"},actualWidth(){return parseInt(this.width)||this.modelWidth||1920},actualHeight(){return parseInt(this.height)||this.modelHeight||1080},className(){var e=[];return this.portrait&&e.push("video-portrait"),e.push(`video-type-${this.mediaType}`),e.join(" ")},portrait(){return this.actualHeight>this.actualWidth},modelWidth(){var e;return parseInt(((e=this.model)==null?void 0:e.width)||0)},modelHeight(){var e;return parseInt(((e=this.model)==null?void 0:e.height)||0)},id(){return this.$sdk.utils.id(this.model)},params(){var e={};return e.access_token=this.$sdk.auth.getCurrentToken(),e},src(){return this.$sdk.api.generateEndpointURL(`/video/${this.id}`,this.params,{file:!0})},thumbnailSrc(){var e=Object.assign({},this.params);return e.w=this.actualWidth,e.h=this.actualHeight,delete e.h,this.$sdk.api.generateEndpointURL(`/image/${this.id}/poster.png`,e,{file:!0})},embedStyle(){var e={};return this.padHeight&&(e.height=0,e.paddingBottom=this.padHeight,e.overflow="hidden",e.position="relative"),e}}},H1=["poster","playsinline","muted","loop","autoplay","width","height","controls","controlslist"],G1=["src","type"],Y1=["width","height","src","title"];function J1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-video",o.className])},[o.mediaType==="upload"?(t.openBlock(),t.createElementBlock("div",{key:0,class:"ux-video-embed ux-video-embed-upload",style:t.normalizeStyle(o.embedStyle)},[t.createElementVNode("video",{poster:o.thumbnailSrc,playsinline:s.playsInline,muted:s.isMuted,loop:r.loop,autoplay:r.autoplay,width:o.actualWidth,height:o.actualHeight,controls:r.controls,controlslist:r.controlslist},[t.createElementVNode("source",{src:o.src,type:o.mimetype},null,8,G1),t.createTextVNode(" Your browser does not support the video tag. ")],8,H1)],4)):t.createCommentVNode("",!0),o.mediaType==="youtube"?(t.openBlock(),t.createElementBlock("div",{key:1,class:"ux-video-embed ux-video-embed-youtube",style:t.normalizeStyle(o.embedStyle)},[t.createElementVNode("iframe",{width:o.actualWidth,height:o.actualHeight,src:o.youtubeSrc,title:o.title,frameborder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",allowfullscreen:""},null,8,Y1)],4)):t.createCommentVNode("",!0)],2)}const Xd=w(W1,[["render",J1],["__scopeId","data-v-8f908e0a"]]),K1={props:{value:{type:Number},active:{type:Boolean}},computed:{classes(){var e=[];return e.push(this.icon),this.spin&&e.push("fa-spin"),this.left&&e.push("ux-icon-left"),this.right&&e.push("ux-icon-right"),e},percent(){return this.value},barStyle(){return{width:`${this.percent}%`}},element(){return"i"}}},Z1={class:"ux-progress"};function X1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",Z1,[t.createElementVNode("div",{class:t.normalizeClass(["ux-progress-bg",{active:r.active}])},null,2),t.createElementVNode("div",{class:"ux-progress-fg",style:t.normalizeStyle(o.barStyle)},null,4)])}const qi=w(K1,[["render",X1],["__scopeId","data-v-6e492d1a"]]),Q1={props:{value:{},tag:{type:String,default:"span"},clickable:{type:Boolean},deleteable:{type:Boolean},icon:{type:String}},computed:{avatar(){var s;const e=(s=this.value)==null?void 0:s._id;if(!e)return;const n=e.slice(8,10)==="24",r=e.slice(8,10)==="70",i=e.slice(8,10)==="71";if(n||r||i)return e},elementType(){return this.tag||"span"},title(){var e,n,r,i,s,o,l,a;return[(e=this.value)==null?void 0:e.title,(n=this.value)==null?void 0:n.name,(r=this.value)!=null&&r.firstName&&((i=this.value)!=null&&i.lastName)?`${(s=this.value)==null?void 0:s.firstName} ${(o=this.value)==null?void 0:o.lastName}`:(l=this.value)==null?void 0:l.firstName,(a=this.value)==null?void 0:a.firstName,this.value].filter(Boolean)[0]},subtitle(){var e;if((e=this.value)!=null&&e.startDate)return this.$sdk.date?this.$sdk.date.readableEventDate(this.value):void 0},hasLink(){return this.tag==="a"||this.clickable},style(){var r,i;const e=(r=this.value)==null?void 0:r.color,n=(i=this.value)==null?void 0:i.bgColor;if(e||n)return{color:e,backgroundColor:n}}}},v1={key:0,class:"pill-avatar"},ex={class:"font-sm font-muted"};function tx(e,n,r,i,s,o){const l=t.resolveComponent("ux-avatar"),a=t.resolveComponent("ux-icon"),c=t.resolveComponent("flex-cell"),d=t.resolveComponent("flex-row");return t.openBlock(),t.createBlock(t.resolveDynamicComponent(o.elementType),{class:t.normalizeClass(["ux-pill",{"has-link":o.hasLink}]),style:t.normalizeStyle(o.style)},{default:t.withCtx(()=>[t.createVNode(d,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(c,null,{default:t.withCtx(()=>[o.avatar?(t.openBlock(),t.createElementBlock("div",v1,[t.createVNode(l,{id:o.avatar,initials:o.title},null,8,["id","initials"])])):t.createCommentVNode("",!0),o.subtitle?(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[r.icon?(t.openBlock(),t.createBlock(a,{key:0,icon:r.icon,left:""},null,8,["icon"])):t.createCommentVNode("",!0),t.createTextVNode(t.toDisplayString(o.title),1),t.createElementVNode("span",ex," • "+t.toDisplayString(o.subtitle),1)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:2},[r.icon?(t.openBlock(),t.createBlock(a,{key:0,icon:r.icon,left:""},null,8,["icon"])):t.createCommentVNode("",!0),t.createTextVNode(t.toDisplayString(o.title),1)],64))]),_:1}),r.deleteable?(t.openBlock(),t.createBlock(c,{key:0,shrink:""},{default:t.withCtx(()=>[t.createVNode(a,{icon:"fa-times"})]),_:1})):t.createCommentVNode("",!0)]),_:1})]),_:1},8,["class","style"])}const Qd=w(Q1,[["render",tx],["__scopeId","data-v-709f24b0"]]),nx={},rx={class:"ux-list"};function ox(e,n){return t.openBlock(),t.createElementBlock("ul",rx,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const vd=w(nx,[["render",ox],["__scopeId","data-v-670de630"]]),ix={props:{to:{type:[Object,String]},href:{type:String},target:{type:String},disabled:{type:Boolean}},computed:{element(){return this.to||this.href?"ux-link":"div"}}};function sx(e,n,r,i,s,o){return t.openBlock(),t.createBlock(t.resolveDynamicComponent(o.element),{class:"ux-list-item",to:r.to,href:r.href,target:r.target,disabled:r.disabled},{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["to","href","target","disabled"])}const eu=w(ix,[["render",sx],["__scopeId","data-v-a5de8929"]]);var K;(function(e){e[e.AM=0]="AM",e[e.PM=1]="PM"})(K||(K={}));var oe;(function(e){e[e.SUNDAY=0]="SUNDAY",e[e.MONDAY=1]="MONDAY",e[e.TUESDAY=2]="TUESDAY",e[e.WEDNESDAY=3]="WEDNESDAY",e[e.THURSDAY=4]="THURSDAY",e[e.FRIDAY=5]="FRIDAY",e[e.SATURDAY=6]="SATURDAY"})(oe||(oe={}));var $e;(function(e){e[e.JANUARY=1]="JANUARY",e[e.FEBRUARY=2]="FEBRUARY",e[e.MARCH=3]="MARCH",e[e.APRIL=4]="APRIL",e[e.MAY=5]="MAY",e[e.JUNE=6]="JUNE",e[e.JULY=7]="JULY",e[e.AUGUST=8]="AUGUST",e[e.SEPTEMBER=9]="SEPTEMBER",e[e.OCTOBER=10]="OCTOBER",e[e.NOVEMBER=11]="NOVEMBER",e[e.DECEMBER=12]="DECEMBER"})($e||($e={}));function Rt(e,n){e.assign("day",n.getDate()),e.assign("month",n.getMonth()+1),e.assign("year",n.getFullYear())}function tu(e,n){e.assign("hour",n.getHours()),e.assign("minute",n.getMinutes()),e.assign("second",n.getSeconds()),e.assign("millisecond",n.getMilliseconds()),e.assign("meridiem",n.getHours()<12?K.AM:K.PM)}function sn(e,n){e.imply("day",n.getDate()),e.imply("month",n.getMonth()+1),e.imply("year",n.getFullYear())}function zi(e,n){e.imply("hour",n.getHours()),e.imply("minute",n.getMinutes()),e.imply("second",n.getSeconds()),e.imply("millisecond",n.getMilliseconds()),e.imply("meridiem",n.getHours()<12?K.AM:K.PM)}const lx={ACDT:630,ACST:570,ADT:-180,AEDT:660,AEST:600,AFT:270,AKDT:-480,AKST:-540,ALMT:360,AMST:-180,AMT:-240,ANAST:720,ANAT:720,AQTT:300,ART:-180,AST:-240,AWDT:540,AWST:480,AZOST:0,AZOT:-60,AZST:300,AZT:240,BNT:480,BOT:-240,BRST:-120,BRT:-180,BST:60,BTT:360,CAST:480,CAT:120,CCT:390,CDT:-300,CEST:120,CET:{timezoneOffsetDuringDst:2*60,timezoneOffsetNonDst:60,dstStart:e=>nu(e,$e.MARCH,oe.SUNDAY,2),dstEnd:e=>nu(e,$e.OCTOBER,oe.SUNDAY,3)},CHADT:825,CHAST:765,CKT:-600,CLST:-180,CLT:-240,COT:-300,CST:-360,CT:{timezoneOffsetDuringDst:-5*60,timezoneOffsetNonDst:-6*60,dstStart:e=>pt(e,$e.MARCH,oe.SUNDAY,2,2),dstEnd:e=>pt(e,$e.NOVEMBER,oe.SUNDAY,1,2)},CVT:-60,CXT:420,ChST:600,DAVT:420,EASST:-300,EAST:-360,EAT:180,ECT:-300,EDT:-240,EEST:180,EET:120,EGST:0,EGT:-60,EST:-300,ET:{timezoneOffsetDuringDst:-4*60,timezoneOffsetNonDst:-5*60,dstStart:e=>pt(e,$e.MARCH,oe.SUNDAY,2,2),dstEnd:e=>pt(e,$e.NOVEMBER,oe.SUNDAY,1,2)},FJST:780,FJT:720,FKST:-180,FKT:-240,FNT:-120,GALT:-360,GAMT:-540,GET:240,GFT:-180,GILT:720,GMT:0,GST:240,GYT:-240,HAA:-180,HAC:-300,HADT:-540,HAE:-240,HAP:-420,HAR:-360,HAST:-600,HAT:-90,HAY:-480,HKT:480,HLV:-210,HNA:-240,HNC:-360,HNE:-300,HNP:-480,HNR:-420,HNT:-150,HNY:-540,HOVT:420,ICT:420,IDT:180,IOT:360,IRDT:270,IRKST:540,IRKT:540,IRST:210,IST:330,JST:540,KGT:360,KRAST:480,KRAT:480,KST:540,KUYT:240,LHDT:660,LHST:630,LINT:840,MAGST:720,MAGT:720,MART:-510,MAWT:300,MDT:-360,MESZ:120,MEZ:60,MHT:720,MMT:390,MSD:240,MSK:180,MST:-420,MT:{timezoneOffsetDuringDst:-6*60,timezoneOffsetNonDst:-7*60,dstStart:e=>pt(e,$e.MARCH,oe.SUNDAY,2,2),dstEnd:e=>pt(e,$e.NOVEMBER,oe.SUNDAY,1,2)},MUT:240,MVT:300,MYT:480,NCT:660,NDT:-90,NFT:690,NOVST:420,NOVT:360,NPT:345,NST:-150,NUT:-660,NZDT:780,NZST:720,OMSST:420,OMST:420,PDT:-420,PET:-300,PETST:720,PETT:720,PGT:600,PHOT:780,PHT:480,PKT:300,PMDT:-120,PMST:-180,PONT:660,PST:-480,PT:{timezoneOffsetDuringDst:-7*60,timezoneOffsetNonDst:-8*60,dstStart:e=>pt(e,$e.MARCH,oe.SUNDAY,2,2),dstEnd:e=>pt(e,$e.NOVEMBER,oe.SUNDAY,1,2)},PWT:540,PYST:-180,PYT:-240,RET:240,SAMT:240,SAST:120,SBT:660,SCT:240,SGT:480,SRT:-180,SST:-660,TAHT:-600,TFT:300,TJT:300,TKT:780,TLT:540,TMT:300,TVT:720,ULAT:480,UTC:0,UYST:-120,UYT:-180,UZT:300,VET:-210,VLAST:660,VLAT:660,VUT:660,WAST:120,WAT:60,WEST:60,WESZ:60,WET:0,WEZ:0,WFT:720,WGST:-120,WGT:-180,WIB:420,WIT:540,WITA:480,WST:780,WT:0,YAKST:600,YAKT:600,YAPT:600,YEKST:360,YEKT:360};function pt(e,n,r,i,s=0){let o=0,l=0;for(;l<i;)o++,new Date(e,n-1,o).getDay()===r&&l++;return new Date(e,n-1,o,s)}function nu(e,n,r,i=0){const s=r===0?7:r,o=new Date(e,n-1+1,1,12),l=o.getDay()===0?7:o.getDay();let a;return l===s?a=7:l<s?a=7+l-s:a=l-s,o.setDate(o.getDate()-a),new Date(e,n-1,o.getDate(),i)}function ru(e,n,r={}){if(e==null)return null;if(typeof e=="number")return e;const i=r[e]??lx[e];return i==null?null:typeof i=="number"?i:n==null?null:n>i.dstStart(n.getFullYear())&&!(n>i.dstEnd(n.getFullYear()))?i.timezoneOffsetDuringDst:i.timezoneOffsetNonDst}const ax={day:0,second:0,millisecond:0};function Ee(e,n){let r=new Date(e);if(n.y&&(n.year=n.y,delete n.y),n.mo&&(n.month=n.mo,delete n.mo),n.M&&(n.month=n.M,delete n.M),n.w&&(n.week=n.w,delete n.w),n.d&&(n.day=n.d,delete n.d),n.h&&(n.hour=n.h,delete n.h),n.m&&(n.minute=n.m,delete n.m),n.s&&(n.second=n.s,delete n.s),n.ms&&(n.millisecond=n.ms,delete n.ms),"year"in n){const i=Math.floor(n.year);r.setFullYear(r.getFullYear()+i);const s=n.year-i;s>0&&(n.month=(n==null?void 0:n.month)??0,n.month+=s*12)}if("quarter"in n){const i=Math.floor(n.quarter);r.setMonth(r.getMonth()+i*3)}if("month"in n){const i=Math.floor(n.month);r.setMonth(r.getMonth()+i);const s=n.month-i;s>0&&(n.week=(n==null?void 0:n.week)??0,n.week+=s*4)}if("week"in n){const i=Math.floor(n.week);r.setDate(r.getDate()+i*7);const s=n.week-i;s>0&&(n.day=(n==null?void 0:n.day)??0,n.day+=Math.round(s*7))}if("day"in n){const i=Math.floor(n.day);r.setDate(r.getDate()+i);const s=n.day-i;s>0&&(n.hour=(n==null?void 0:n.hour)??0,n.hour+=Math.round(s*24))}if("hour"in n){const i=Math.floor(n.hour);r.setHours(r.getHours()+i);const s=n.hour-i;s>0&&(n.minute=(n==null?void 0:n.minute)??0,n.minute+=Math.round(s*60))}if("minute"in n){const i=Math.floor(n.minute);r.setMinutes(r.getMinutes()+i);const s=n.minute-i;s>0&&(n.second=(n==null?void 0:n.second)??0,n.second+=Math.round(s*60))}if("second"in n){const i=Math.floor(n.second);r.setSeconds(r.getSeconds()+i);const s=n.second-i;s>0&&(n.millisecond=(n==null?void 0:n.millisecond)??0,n.millisecond+=Math.round(s*1e3))}if("millisecond"in n){const i=Math.floor(n.millisecond);r.setMilliseconds(r.getMilliseconds()+i)}return r}function _r(e){const n={};for(const r in e)n[r]=-e[r];return n}class gt{constructor(n,r){W(this,"instant");W(this,"timezoneOffset");this.instant=n??new Date,this.timezoneOffset=r??null}static fromDate(n){return new gt(n)}static fromInput(n,r){if(n instanceof Date)return gt.fromDate(n);const i=(n==null?void 0:n.instant)??new Date,s=ru(n==null?void 0:n.timezone,i,r);return new gt(i,s)}getDateWithAdjustedTimezone(){const n=new Date(this.instant);return this.timezoneOffset!==null&&n.setMinutes(n.getMinutes()-this.getSystemTimezoneAdjustmentMinute(this.instant)),n}getSystemTimezoneAdjustmentMinute(n,r){(!n||n.getTime()<0)&&(n=new Date);const i=-n.getTimezoneOffset(),s=r??this.timezoneOffset??i;return i-s}getTimezoneOffset(){return this.timezoneOffset??-this.instant.getTimezoneOffset()}}class ee{constructor(n,r){W(this,"knownValues");W(this,"impliedValues");W(this,"reference");W(this,"_tags",new Set);if(this.reference=n,this.knownValues={},this.impliedValues={},r)for(const s in r)this.knownValues[s]=r[s];const i=n.getDateWithAdjustedTimezone();this.imply("day",i.getDate()),this.imply("month",i.getMonth()+1),this.imply("year",i.getFullYear()),this.imply("hour",12),this.imply("minute",0),this.imply("second",0),this.imply("millisecond",0)}static createRelativeFromReference(n,r=ax){let i=Ee(n.getDateWithAdjustedTimezone(),r);const s=new ee(n);return s.addTag("result/relativeDate"),"hour"in r||"minute"in r||"second"in r||"millisecond"in r?(s.addTag("result/relativeDateAndTime"),tu(s,i),Rt(s,i),s.assign("timezoneOffset",n.getTimezoneOffset())):(zi(s,i),s.imply("timezoneOffset",n.getTimezoneOffset()),"day"in r?(s.assign("day",i.getDate()),s.assign("month",i.getMonth()+1),s.assign("year",i.getFullYear()),s.assign("weekday",i.getDay())):"week"in r?(s.assign("day",i.getDate()),s.assign("month",i.getMonth()+1),s.assign("year",i.getFullYear()),s.imply("weekday",i.getDay())):(s.imply("day",i.getDate()),"month"in r?(s.assign("month",i.getMonth()+1),s.assign("year",i.getFullYear())):(s.imply("month",i.getMonth()+1),"year"in r?s.assign("year",i.getFullYear()):s.imply("year",i.getFullYear())))),s}get(n){return n in this.knownValues?this.knownValues[n]:n in this.impliedValues?this.impliedValues[n]:null}isCertain(n){return n in this.knownValues}getCertainComponents(){return Object.keys(this.knownValues)}imply(n,r){return n in this.knownValues?this:(this.impliedValues[n]=r,this)}assign(n,r){return this.knownValues[n]=r,delete this.impliedValues[n],this}addDurationAsImplied(n){const r=this.dateWithoutTimezoneAdjustment(),i=Ee(r,n);return("day"in n||"week"in n||"month"in n||"year"in n)&&(this.delete(["day","weekday","month","year"]),this.imply("day",i.getDate()),this.imply("weekday",i.getDay()),this.imply("month",i.getMonth()+1),this.imply("year",i.getFullYear())),("second"in n||"minute"in n||"hour"in n)&&(this.delete(["second","minute","hour"]),this.imply("second",i.getSeconds()),this.imply("minute",i.getMinutes()),this.imply("hour",i.getHours())),this}delete(n){typeof n=="string"&&(n=[n]);for(const r of n)delete this.knownValues[r],delete this.impliedValues[r]}clone(){const n=new ee(this.reference);n.knownValues={},n.impliedValues={};for(const r in this.knownValues)n.knownValues[r]=this.knownValues[r];for(const r in this.impliedValues)n.impliedValues[r]=this.impliedValues[r];return n}isOnlyDate(){return!this.isCertain("hour")&&!this.isCertain("minute")&&!this.isCertain("second")}isOnlyTime(){return!this.isCertain("weekday")&&!this.isCertain("day")&&!this.isCertain("month")&&!this.isCertain("year")}isOnlyWeekdayComponent(){return this.isCertain("weekday")&&!this.isCertain("day")&&!this.isCertain("month")}isDateWithUnknownYear(){return this.isCertain("month")&&!this.isCertain("year")}isValidDate(){const n=this.dateWithoutTimezoneAdjustment();return!(n.getFullYear()!==this.get("year")||n.getMonth()!==this.get("month")-1||n.getDate()!==this.get("day")||this.get("hour")!=null&&n.getHours()!=this.get("hour")||this.get("minute")!=null&&n.getMinutes()!=this.get("minute"))}toString(){return`[ParsingComponents {
|
|
1
|
+
(function(E,t){typeof exports=="object"&&typeof module<"u"?t(exports,require("vue"),require("@qikdev/sdk")):typeof define=="function"&&define.amd?define(["exports","vue","@qikdev/sdk"],t):(E=typeof globalThis<"u"?globalThis:E||self,t(E["@qikdev/vue-ui"]={},E.Vue,E.sdk))})(this,function(E,t,Dt){"use strict";var ZL=Object.defineProperty;var XL=(E,t,Dt)=>t in E?ZL(E,t,{enumerable:!0,configurable:!0,writable:!0,value:Dt}):E[t]=Dt;var W=(E,t,Dt)=>XL(E,typeof t!="symbol"?t+"":t,Dt);const qh="0.3.16";class Ot extends Error{}class zh extends Ot{constructor(n){super(`Invalid DateTime: ${n.toMessage()}`)}}class Wh extends Ot{constructor(n){super(`Invalid Interval: ${n.toMessage()}`)}}class Hh extends Ot{constructor(n){super(`Invalid Duration: ${n.toMessage()}`)}}class yn extends Ot{}class jl extends Ot{constructor(n){super(`Invalid unit ${n}`)}}class Ie extends Ot{}class dt extends Ot{constructor(){super("Zone is an abstract class")}}const T="numeric",qe="short",De="long",oo={year:T,month:T,day:T},ql={year:T,month:qe,day:T},Gh={year:T,month:qe,day:T,weekday:qe},zl={year:T,month:De,day:T},Wl={year:T,month:De,day:T,weekday:De},Hl={hour:T,minute:T},Gl={hour:T,minute:T,second:T},Yl={hour:T,minute:T,second:T,timeZoneName:qe},Jl={hour:T,minute:T,second:T,timeZoneName:De},Kl={hour:T,minute:T,hourCycle:"h23"},Zl={hour:T,minute:T,second:T,hourCycle:"h23"},Xl={hour:T,minute:T,second:T,hourCycle:"h23",timeZoneName:qe},Ql={hour:T,minute:T,second:T,hourCycle:"h23",timeZoneName:De},vl={year:T,month:T,day:T,hour:T,minute:T},ea={year:T,month:T,day:T,hour:T,minute:T,second:T},ta={year:T,month:qe,day:T,hour:T,minute:T},na={year:T,month:qe,day:T,hour:T,minute:T,second:T},Yh={year:T,month:qe,day:T,weekday:qe,hour:T,minute:T},ra={year:T,month:De,day:T,hour:T,minute:T,timeZoneName:qe},oa={year:T,month:De,day:T,hour:T,minute:T,second:T,timeZoneName:qe},ia={year:T,month:De,day:T,weekday:De,hour:T,minute:T,timeZoneName:De},sa={year:T,month:De,day:T,weekday:De,hour:T,minute:T,second:T,timeZoneName:De};function H(e){return typeof e>"u"}function Mt(e){return typeof e=="number"}function Kn(e){return typeof e=="number"&&e%1===0}function Jh(e){return typeof e=="string"}function Kh(e){return Object.prototype.toString.call(e)==="[object Date]"}function la(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function Zh(e){return Array.isArray(e)?e:[e]}function aa(e,n,r){if(e.length!==0)return e.reduce((i,s)=>{const o=[n(s),s];return i&&r(i[0],o[0])===i[0]?i:o},null)[1]}function Xh(e,n){return n.reduce((r,i)=>(r[i]=e[i],r),{})}function Qt(e,n){return Object.prototype.hasOwnProperty.call(e,n)}function nt(e,n,r){return Kn(e)&&e>=n&&e<=r}function Qh(e,n){return e-n*Math.floor(e/n)}function fe(e,n=2){const r=e<0;let i;return r?i="-"+(""+-e).padStart(n,"0"):i=(""+e).padStart(n,"0"),i}function ut(e){if(!(H(e)||e===null||e===""))return parseInt(e,10)}function Ft(e){if(!(H(e)||e===null||e===""))return parseFloat(e)}function io(e){if(!(H(e)||e===null||e==="")){const n=parseFloat("0."+e)*1e3;return Math.floor(n)}}function so(e,n,r=!1){const i=10**n;return(r?Math.trunc:Math.round)(e*i)/i}function kn(e){return e%4===0&&(e%100!==0||e%400===0)}function _n(e){return kn(e)?366:365}function Zn(e,n){const r=Qh(n-1,12)+1,i=e+(n-r)/12;return r===2?kn(i)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][r-1]}function lo(e){let n=Date.UTC(e.year,e.month-1,e.day,e.hour,e.minute,e.second,e.millisecond);return e.year<100&&e.year>=0&&(n=new Date(n),n.setUTCFullYear(n.getUTCFullYear()-1900)),+n}function Xn(e){const n=(e+Math.floor(e/4)-Math.floor(e/100)+Math.floor(e/400))%7,r=e-1,i=(r+Math.floor(r/4)-Math.floor(r/100)+Math.floor(r/400))%7;return n===4||i===3?53:52}function ao(e){return e>99?e:e>60?1900+e:2e3+e}function ca(e,n,r,i=null){const s=new Date(e),o={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};i&&(o.timeZone=i);const l={timeZoneName:n,...o},a=new Intl.DateTimeFormat(r,l).formatToParts(s).find(c=>c.type.toLowerCase()==="timezonename");return a?a.value:null}function Qn(e,n){let r=parseInt(e,10);Number.isNaN(r)&&(r=0);const i=parseInt(n,10)||0,s=r<0||Object.is(r,-0)?-i:i;return r*60+s}function da(e){const n=Number(e);if(typeof e=="boolean"||e===""||Number.isNaN(n))throw new Ie(`Invalid unit value ${e}`);return n}function vn(e,n){const r={};for(const i in e)if(Qt(e,i)){const s=e[i];if(s==null)continue;r[n(i)]=da(s)}return r}function er(e,n){const r=Math.trunc(Math.abs(e/60)),i=Math.trunc(Math.abs(e%60)),s=e>=0?"+":"-";switch(n){case"short":return`${s}${fe(r,2)}:${fe(i,2)}`;case"narrow":return`${s}${r}${i>0?`:${i}`:""}`;case"techie":return`${s}${fe(r,2)}${fe(i,2)}`;default:throw new RangeError(`Value format ${n} is out of range for property format`)}}function tr(e){return Xh(e,["hour","minute","second","millisecond"])}const vh=/[A-Za-z_+-]{1,256}(:?\/[A-Za-z0-9_+-]{1,256}(\/[A-Za-z0-9_+-]{1,256})?)?/,ep=["January","February","March","April","May","June","July","August","September","October","November","December"],ua=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],tp=["J","F","M","A","M","J","J","A","S","O","N","D"];function ma(e){switch(e){case"narrow":return[...tp];case"short":return[...ua];case"long":return[...ep];case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}const fa=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],ha=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],np=["M","T","W","T","F","S","S"];function pa(e){switch(e){case"narrow":return[...np];case"short":return[...ha];case"long":return[...fa];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const ga=["AM","PM"],rp=["Before Christ","Anno Domini"],op=["BC","AD"],ip=["B","A"];function ya(e){switch(e){case"narrow":return[...ip];case"short":return[...op];case"long":return[...rp];default:return null}}function sp(e){return ga[e.hour<12?0:1]}function lp(e,n){return pa(n)[e.weekday-1]}function ap(e,n){return ma(n)[e.month-1]}function cp(e,n){return ya(n)[e.year<0?0:1]}function dp(e,n,r="always",i=!1){const s={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},o=["hours","minutes","seconds"].indexOf(e)===-1;if(r==="auto"&&o){const m=e==="days";switch(n){case 1:return m?"tomorrow":`next ${s[e][0]}`;case-1:return m?"yesterday":`last ${s[e][0]}`;case 0:return m?"today":`this ${s[e][0]}`}}const l=Object.is(n,-0)||n<0,a=Math.abs(n),c=a===1,d=s[e],u=i?c?d[1]:d[2]||d[1]:c?s[e][0]:e;return l?`${a} ${u} ago`:`in ${a} ${u}`}function ka(e,n){let r="";for(const i of e)i.literal?r+=i.val:r+=n(i.val);return r}const up={D:oo,DD:ql,DDD:zl,DDDD:Wl,t:Hl,tt:Gl,ttt:Yl,tttt:Jl,T:Kl,TT:Zl,TTT:Xl,TTTT:Ql,f:vl,ff:ta,fff:ra,ffff:ia,F:ea,FF:na,FFF:oa,FFFF:sa};class Ne{static create(n,r={}){return new Ne(n,r)}static parseFormat(n){let r=null,i="",s=!1;const o=[];for(let l=0;l<n.length;l++){const a=n.charAt(l);a==="'"?(i.length>0&&o.push({literal:s,val:i}),r=null,i="",s=!s):s||a===r?i+=a:(i.length>0&&o.push({literal:!1,val:i}),i=a,r=a)}return i.length>0&&o.push({literal:s,val:i}),o}static macroTokenToFormatOpts(n){return up[n]}constructor(n,r){this.opts=r,this.loc=n,this.systemLoc=null}formatWithSystemDefault(n,r){return this.systemLoc===null&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(n,{...this.opts,...r}).format()}formatDateTime(n,r={}){return this.loc.dtFormatter(n,{...this.opts,...r}).format()}formatDateTimeParts(n,r={}){return this.loc.dtFormatter(n,{...this.opts,...r}).formatToParts()}resolvedOptions(n,r={}){return this.loc.dtFormatter(n,{...this.opts,...r}).resolvedOptions()}num(n,r=0){if(this.opts.forceSimple)return fe(n,r);const i={...this.opts};return r>0&&(i.padTo=r),this.loc.numberFormatter(i).format(n)}formatDateTimeFromString(n,r){const i=this.loc.listingMode()==="en",s=this.loc.outputCalendar&&this.loc.outputCalendar!=="gregory",o=(h,g)=>this.loc.extract(n,h,g),l=h=>n.isOffsetFixed&&n.offset===0&&h.allowZ?"Z":n.isValid?n.zone.formatOffset(n.ts,h.format):"",a=()=>i?sp(n):o({hour:"numeric",hourCycle:"h12"},"dayperiod"),c=(h,g)=>i?ap(n,h):o(g?{month:h}:{month:h,day:"numeric"},"month"),d=(h,g)=>i?lp(n,h):o(g?{weekday:h}:{weekday:h,month:"long",day:"numeric"},"weekday"),u=h=>{const g=Ne.macroTokenToFormatOpts(h);return g?this.formatWithSystemDefault(n,g):h},m=h=>i?cp(n,h):o({era:h},"era"),f=h=>{switch(h){case"S":return this.num(n.millisecond);case"u":case"SSS":return this.num(n.millisecond,3);case"s":return this.num(n.second);case"ss":return this.num(n.second,2);case"uu":return this.num(Math.floor(n.millisecond/10),2);case"uuu":return this.num(Math.floor(n.millisecond/100));case"m":return this.num(n.minute);case"mm":return this.num(n.minute,2);case"h":return this.num(n.hour%12===0?12:n.hour%12);case"hh":return this.num(n.hour%12===0?12:n.hour%12,2);case"H":return this.num(n.hour);case"HH":return this.num(n.hour,2);case"Z":return l({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return l({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return l({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return n.zone.offsetName(n.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return n.zone.offsetName(n.ts,{format:"long",locale:this.loc.locale});case"z":return n.zoneName;case"a":return a();case"d":return s?o({day:"numeric"},"day"):this.num(n.day);case"dd":return s?o({day:"2-digit"},"day"):this.num(n.day,2);case"c":return this.num(n.weekday);case"ccc":return d("short",!0);case"cccc":return d("long",!0);case"ccccc":return d("narrow",!0);case"E":return this.num(n.weekday);case"EEE":return d("short",!1);case"EEEE":return d("long",!1);case"EEEEE":return d("narrow",!1);case"L":return s?o({month:"numeric",day:"numeric"},"month"):this.num(n.month);case"LL":return s?o({month:"2-digit",day:"numeric"},"month"):this.num(n.month,2);case"LLL":return c("short",!0);case"LLLL":return c("long",!0);case"LLLLL":return c("narrow",!0);case"M":return s?o({month:"numeric"},"month"):this.num(n.month);case"MM":return s?o({month:"2-digit"},"month"):this.num(n.month,2);case"MMM":return c("short",!1);case"MMMM":return c("long",!1);case"MMMMM":return c("narrow",!1);case"y":return s?o({year:"numeric"},"year"):this.num(n.year);case"yy":return s?o({year:"2-digit"},"year"):this.num(n.year.toString().slice(-2),2);case"yyyy":return s?o({year:"numeric"},"year"):this.num(n.year,4);case"yyyyyy":return s?o({year:"numeric"},"year"):this.num(n.year,6);case"G":return m("short");case"GG":return m("long");case"GGGGG":return m("narrow");case"kk":return this.num(n.weekYear.toString().slice(-2),2);case"kkkk":return this.num(n.weekYear,4);case"W":return this.num(n.weekNumber);case"WW":return this.num(n.weekNumber,2);case"o":return this.num(n.ordinal);case"ooo":return this.num(n.ordinal,3);case"q":return this.num(n.quarter);case"qq":return this.num(n.quarter,2);case"X":return this.num(Math.floor(n.ts/1e3));case"x":return this.num(n.ts);default:return u(h)}};return ka(Ne.parseFormat(r),f)}formatDurationFromString(n,r){const i=c=>{switch(c[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year";default:return null}},s=c=>d=>{const u=i(d);return u?this.num(c.get(u),d.length):d},o=Ne.parseFormat(r),l=o.reduce((c,{literal:d,val:u})=>d?c:c.concat(u),[]),a=n.shiftTo(...l.map(i).filter(c=>c));return ka(o,s(a))}}class ze{constructor(n,r){this.reason=n,this.explanation=r}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}class wn{get type(){throw new dt}get name(){throw new dt}get isUniversal(){throw new dt}offsetName(n,r){throw new dt}formatOffset(n,r){throw new dt}offset(n){throw new dt}equals(n){throw new dt}get isValid(){throw new dt}}let co=null;class uo extends wn{static get instance(){return co===null&&(co=new uo),co}get type(){return"system"}get name(){return new Intl.DateTimeFormat().resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(n,{format:r,locale:i}){return ca(n,r,i)}formatOffset(n,r){return er(this.offset(n),r)}offset(n){return-new Date(n).getTimezoneOffset()}equals(n){return n.type==="system"}get isValid(){return!0}}let nr={};function mp(e){return nr[e]||(nr[e]=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"})),nr[e]}const fp={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function hp(e,n){const r=e.format(n).replace(/\u200E/g,""),i=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(r),[,s,o,l,a,c,d,u]=i;return[l,s,o,a,c,d,u]}function pp(e,n){const r=e.formatToParts(n),i=[];for(let s=0;s<r.length;s++){const{type:o,value:l}=r[s],a=fp[o];o==="era"?i[a]=l:H(a)||(i[a]=parseInt(l,10))}return i}let rr={};class rt extends wn{static create(n){return rr[n]||(rr[n]=new rt(n)),rr[n]}static resetCache(){rr={},nr={}}static isValidSpecifier(n){return this.isValidZone(n)}static isValidZone(n){if(!n)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:n}).format(),!0}catch{return!1}}constructor(n){super(),this.zoneName=n,this.valid=rt.isValidZone(n)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(n,{format:r,locale:i}){return ca(n,r,i,this.name)}formatOffset(n,r){return er(this.offset(n),r)}offset(n){const r=new Date(n);if(isNaN(r))return NaN;const i=mp(this.name);let[s,o,l,a,c,d,u]=i.formatToParts?pp(i,r):hp(i,r);a==="BC"&&(s=-Math.abs(s)+1);const f=lo({year:s,month:o,day:l,hour:c===24?0:c,minute:d,second:u,millisecond:0});let h=+r;const g=h%1e3;return h-=g>=0?g:1e3+g,(f-h)/(60*1e3)}equals(n){return n.type==="iana"&&n.name===this.name}get isValid(){return this.valid}}let mo=null;class Ce extends wn{static get utcInstance(){return mo===null&&(mo=new Ce(0)),mo}static instance(n){return n===0?Ce.utcInstance:new Ce(n)}static parseSpecifier(n){if(n){const r=n.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(r)return new Ce(Qn(r[1],r[2]))}return null}constructor(n){super(),this.fixed=n}get type(){return"fixed"}get name(){return this.fixed===0?"UTC":`UTC${er(this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(n,r){return er(this.fixed,r)}get isUniversal(){return!0}offset(){return this.fixed}equals(n){return n.type==="fixed"&&n.fixed===this.fixed}get isValid(){return!0}}class gp extends wn{constructor(n){super(),this.zoneName=n}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}}function mt(e,n){if(H(e)||e===null)return n;if(e instanceof wn)return e;if(Jh(e)){const r=e.toLowerCase();return r==="local"||r==="system"?n:r==="utc"||r==="gmt"?Ce.utcInstance:Ce.parseSpecifier(r)||rt.create(e)}else return Mt(e)?Ce.instance(e):typeof e=="object"&&e.offset&&typeof e.offset=="number"?e:new gp(e)}let _a=()=>Date.now(),wa="system",xa=null,ba=null,Ca=null,Va;class ge{static get now(){return _a}static set now(n){_a=n}static set defaultZone(n){wa=n}static get defaultZone(){return mt(wa,uo.instance)}static get defaultLocale(){return xa}static set defaultLocale(n){xa=n}static get defaultNumberingSystem(){return ba}static set defaultNumberingSystem(n){ba=n}static get defaultOutputCalendar(){return Ca}static set defaultOutputCalendar(n){Ca=n}static get throwOnInvalid(){return Va}static set throwOnInvalid(n){Va=n}static resetCaches(){se.resetCache(),rt.resetCache()}}let Na={};function yp(e,n={}){const r=JSON.stringify([e,n]);let i=Na[r];return i||(i=new Intl.ListFormat(e,n),Na[r]=i),i}let fo={};function ho(e,n={}){const r=JSON.stringify([e,n]);let i=fo[r];return i||(i=new Intl.DateTimeFormat(e,n),fo[r]=i),i}let po={};function kp(e,n={}){const r=JSON.stringify([e,n]);let i=po[r];return i||(i=new Intl.NumberFormat(e,n),po[r]=i),i}let go={};function _p(e,n={}){const{base:r,...i}=n,s=JSON.stringify([e,i]);let o=go[s];return o||(o=new Intl.RelativeTimeFormat(e,n),go[s]=o),o}let xn=null;function wp(){return xn||(xn=new Intl.DateTimeFormat().resolvedOptions().locale,xn)}function xp(e){const n=e.indexOf("-u-");if(n===-1)return[e];{let r;const i=e.substring(0,n);try{r=ho(e).resolvedOptions()}catch{r=ho(i).resolvedOptions()}const{numberingSystem:s,calendar:o}=r;return[i,s,o]}}function bp(e,n,r){return(r||n)&&(e+="-u",r&&(e+=`-ca-${r}`),n&&(e+=`-nu-${n}`)),e}function Cp(e){const n=[];for(let r=1;r<=12;r++){const i=_.utc(2016,r,1);n.push(e(i))}return n}function Vp(e){const n=[];for(let r=1;r<=7;r++){const i=_.utc(2016,11,13+r);n.push(e(i))}return n}function or(e,n,r,i,s){const o=e.listingMode(r);return o==="error"?null:o==="en"?i(n):s(n)}function Np(e){return e.numberingSystem&&e.numberingSystem!=="latn"?!1:e.numberingSystem==="latn"||!e.locale||e.locale.startsWith("en")||new Intl.DateTimeFormat(e.intl).resolvedOptions().numberingSystem==="latn"}class Ep{constructor(n,r,i){this.padTo=i.padTo||0,this.floor=i.floor||!1;const{padTo:s,floor:o,...l}=i;if(!r||Object.keys(l).length>0){const a={useGrouping:!1,...i};i.padTo>0&&(a.minimumIntegerDigits=i.padTo),this.inf=kp(n,a)}}format(n){if(this.inf){const r=this.floor?Math.floor(n):n;return this.inf.format(r)}else{const r=this.floor?Math.floor(n):so(n,3);return fe(r,this.padTo)}}}class Bp{constructor(n,r,i){this.opts=i;let s;if(n.zone.isUniversal){const l=-1*(n.offset/60),a=l>=0?`Etc/GMT+${l}`:`Etc/GMT${l}`;n.offset!==0&&rt.create(a).valid?(s=a,this.dt=n):(s="UTC",i.timeZoneName?this.dt=n:this.dt=n.offset===0?n:_.fromMillis(n.ts+n.offset*60*1e3))}else n.zone.type==="system"?this.dt=n:(this.dt=n,s=n.zone.name);const o={...this.opts};s&&(o.timeZone=s),this.dtf=ho(r,o)}format(){return this.dtf.format(this.dt.toJSDate())}formatToParts(){return this.dtf.formatToParts(this.dt.toJSDate())}resolvedOptions(){return this.dtf.resolvedOptions()}}class Sp{constructor(n,r,i){this.opts={style:"long",...i},!r&&la()&&(this.rtf=_p(n,i))}format(n,r){return this.rtf?this.rtf.format(n,r):dp(r,n,this.opts.numeric,this.opts.style!=="long")}formatToParts(n,r){return this.rtf?this.rtf.formatToParts(n,r):[]}}class se{static fromOpts(n){return se.create(n.locale,n.numberingSystem,n.outputCalendar,n.defaultToEN)}static create(n,r,i,s=!1){const o=n||ge.defaultLocale,l=o||(s?"en-US":wp()),a=r||ge.defaultNumberingSystem,c=i||ge.defaultOutputCalendar;return new se(l,a,c,o)}static resetCache(){xn=null,fo={},po={},go={}}static fromObject({locale:n,numberingSystem:r,outputCalendar:i}={}){return se.create(n,r,i)}constructor(n,r,i,s){const[o,l,a]=xp(n);this.locale=o,this.numberingSystem=r||l||null,this.outputCalendar=i||a||null,this.intl=bp(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=s,this.fastNumbersCached=null}get fastNumbers(){return this.fastNumbersCached==null&&(this.fastNumbersCached=Np(this)),this.fastNumbersCached}listingMode(){const n=this.isEnglish(),r=(this.numberingSystem===null||this.numberingSystem==="latn")&&(this.outputCalendar===null||this.outputCalendar==="gregory");return n&&r?"en":"intl"}clone(n){return!n||Object.getOwnPropertyNames(n).length===0?this:se.create(n.locale||this.specifiedLocale,n.numberingSystem||this.numberingSystem,n.outputCalendar||this.outputCalendar,n.defaultToEN||!1)}redefaultToEN(n={}){return this.clone({...n,defaultToEN:!0})}redefaultToSystem(n={}){return this.clone({...n,defaultToEN:!1})}months(n,r=!1,i=!0){return or(this,n,i,ma,()=>{const s=r?{month:n,day:"numeric"}:{month:n},o=r?"format":"standalone";return this.monthsCache[o][n]||(this.monthsCache[o][n]=Cp(l=>this.extract(l,s,"month"))),this.monthsCache[o][n]})}weekdays(n,r=!1,i=!0){return or(this,n,i,pa,()=>{const s=r?{weekday:n,year:"numeric",month:"long",day:"numeric"}:{weekday:n},o=r?"format":"standalone";return this.weekdaysCache[o][n]||(this.weekdaysCache[o][n]=Vp(l=>this.extract(l,s,"weekday"))),this.weekdaysCache[o][n]})}meridiems(n=!0){return or(this,void 0,n,()=>ga,()=>{if(!this.meridiemCache){const r={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[_.utc(2016,11,13,9),_.utc(2016,11,13,19)].map(i=>this.extract(i,r,"dayperiod"))}return this.meridiemCache})}eras(n,r=!0){return or(this,n,r,ya,()=>{const i={era:n};return this.eraCache[n]||(this.eraCache[n]=[_.utc(-40,1,1),_.utc(2017,1,1)].map(s=>this.extract(s,i,"era"))),this.eraCache[n]})}extract(n,r,i){const s=this.dtFormatter(n,r),o=s.formatToParts(),l=o.find(a=>a.type.toLowerCase()===i);return l?l.value:null}numberFormatter(n={}){return new Ep(this.intl,n.forceSimple||this.fastNumbers,n)}dtFormatter(n,r={}){return new Bp(n,this.intl,r)}relFormatter(n={}){return new Sp(this.intl,this.isEnglish(),n)}listFormatter(n={}){return yp(this.intl,n)}isEnglish(){return this.locale==="en"||this.locale.toLowerCase()==="en-us"||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")}equals(n){return this.locale===n.locale&&this.numberingSystem===n.numberingSystem&&this.outputCalendar===n.outputCalendar}}function vt(...e){const n=e.reduce((r,i)=>r+i.source,"");return RegExp(`^${n}$`)}function It(...e){return n=>e.reduce(([r,i,s],o)=>{const[l,a,c]=o(n,s);return[{...r,...l},i||a,c]},[{},null,1]).slice(0,2)}function en(e,...n){if(e==null)return[null,null];for(const[r,i]of n){const s=r.exec(e);if(s)return i(s)}return[null,null]}function Ea(...e){return(n,r)=>{const i={};let s;for(s=0;s<e.length;s++)i[e[s]]=ut(n[r+s]);return[i,null,r+s]}}const Ba=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,yo=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,Sa=RegExp(`${yo.source}${Ba.source}?`),ko=RegExp(`(?:T${Sa.source})?`),Tp=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,Dp=/(\d{4})-?W(\d\d)(?:-?(\d))?/,Op=/(\d{4})-?(\d{3})/,Mp=Ea("weekYear","weekNumber","weekDay"),Fp=Ea("year","ordinal"),Ip=/(\d{4})-(\d\d)-(\d\d)/,Ta=RegExp(`${yo.source} ?(?:${Ba.source}|(${vh.source}))?`),Ap=RegExp(`(?: ${Ta.source})?`);function tn(e,n,r){const i=e[n];return H(i)?r:ut(i)}function Da(e,n){return[{year:tn(e,n),month:tn(e,n+1,1),day:tn(e,n+2,1)},null,n+3]}function At(e,n){return[{hours:tn(e,n,0),minutes:tn(e,n+1,0),seconds:tn(e,n+2,0),milliseconds:io(e[n+3])},null,n+4]}function nn(e,n){const r=!e[n]&&!e[n+1],i=Qn(e[n+1],e[n+2]),s=r?null:Ce.instance(i);return[{},s,n+3]}function Oa(e,n){const r=e[n]?rt.create(e[n]):null;return[{},r,n+1]}const Lp=RegExp(`^T?${yo.source}$`),$p=/^-?P(?:(?:(-?\d{1,9}(?:\.\d{1,9})?)Y)?(?:(-?\d{1,9}(?:\.\d{1,9})?)M)?(?:(-?\d{1,9}(?:\.\d{1,9})?)W)?(?:(-?\d{1,9}(?:\.\d{1,9})?)D)?(?:T(?:(-?\d{1,9}(?:\.\d{1,9})?)H)?(?:(-?\d{1,9}(?:\.\d{1,9})?)M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,9}))?S)?)?)$/;function Pp(e){const[n,r,i,s,o,l,a,c,d]=e,u=n[0]==="-",m=c&&c[0]==="-",f=(h,g=!1)=>h!==void 0&&(g||h&&u)?-h:h;return[{years:f(Ft(r)),months:f(Ft(i)),weeks:f(Ft(s)),days:f(Ft(o)),hours:f(Ft(l)),minutes:f(Ft(a)),seconds:f(Ft(c),c==="-0"),milliseconds:f(io(d),m)}]}const Rp={GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function _o(e,n,r,i,s,o,l){const a={year:n.length===2?ao(ut(n)):ut(n),month:ua.indexOf(r)+1,day:ut(i),hour:ut(s),minute:ut(o)};return l&&(a.second=ut(l)),e&&(a.weekday=e.length>3?fa.indexOf(e)+1:ha.indexOf(e)+1),a}const Up=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;function jp(e){const[,n,r,i,s,o,l,a,c,d,u,m]=e,f=_o(n,s,i,r,o,l,a);let h;return c?h=Rp[c]:d?h=0:h=Qn(u,m),[f,new Ce(h)]}function qp(e){return e.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}const zp=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,Wp=/^(Monday|Tuesday|Wedsday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,Hp=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function Ma(e){const[,n,r,i,s,o,l,a]=e;return[_o(n,s,i,r,o,l,a),Ce.utcInstance]}function Gp(e){const[,n,r,i,s,o,l,a]=e;return[_o(n,a,r,i,s,o,l),Ce.utcInstance]}const Yp=vt(Tp,ko),Jp=vt(Dp,ko),Kp=vt(Op,ko),Zp=vt(Sa),Xp=It(Da,At,nn),Qp=It(Mp,At,nn),vp=It(Fp,At,nn),eg=It(At,nn);function tg(e){return en(e,[Yp,Xp],[Jp,Qp],[Kp,vp],[Zp,eg])}function ng(e){return en(qp(e),[Up,jp])}function rg(e){return en(e,[zp,Ma],[Wp,Ma],[Hp,Gp])}function og(e){return en(e,[$p,Pp])}const ig=It(At);function sg(e){return en(e,[Lp,ig])}const lg=vt(Ip,Ap),ag=vt(Ta),cg=It(Da,At,nn,Oa),dg=It(At,nn,Oa);function ug(e){return en(e,[lg,cg],[ag,dg])}const mg="Invalid Duration",Fa={weeks:{days:7,hours:7*24,minutes:7*24*60,seconds:7*24*60*60,milliseconds:7*24*60*60*1e3},days:{hours:24,minutes:24*60,seconds:24*60*60,milliseconds:24*60*60*1e3},hours:{minutes:60,seconds:60*60,milliseconds:60*60*1e3},minutes:{seconds:60,milliseconds:60*1e3},seconds:{milliseconds:1e3}},fg={years:{quarters:4,months:12,weeks:52,days:365,hours:365*24,minutes:365*24*60,seconds:365*24*60*60,milliseconds:365*24*60*60*1e3},quarters:{months:3,weeks:13,days:91,hours:91*24,minutes:91*24*60,seconds:91*24*60*60,milliseconds:91*24*60*60*1e3},months:{weeks:4,days:30,hours:30*24,minutes:30*24*60,seconds:30*24*60*60,milliseconds:30*24*60*60*1e3},...Fa},Ae=146097/400,rn=146097/4800,hg={years:{quarters:4,months:12,weeks:Ae/7,days:Ae,hours:Ae*24,minutes:Ae*24*60,seconds:Ae*24*60*60,milliseconds:Ae*24*60*60*1e3},quarters:{months:3,weeks:Ae/28,days:Ae/4,hours:Ae*24/4,minutes:Ae*24*60/4,seconds:Ae*24*60*60/4,milliseconds:Ae*24*60*60*1e3/4},months:{weeks:rn/7,days:rn,hours:rn*24,minutes:rn*24*60,seconds:rn*24*60*60,milliseconds:rn*24*60*60*1e3},...Fa},Lt=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],pg=Lt.slice(0).reverse();function $t(e,n,r=!1){const i={values:r?n.values:{...e.values,...n.values||{}},loc:e.loc.clone(n.loc),conversionAccuracy:n.conversionAccuracy||e.conversionAccuracy};return new Y(i)}function gg(e){return e<0?Math.floor(e):Math.ceil(e)}function Ia(e,n,r,i,s){const o=e[s][r],l=n[r]/o,a=Math.sign(l)===Math.sign(i[s]),c=!a&&i[s]!==0&&Math.abs(l)<=1?gg(l):Math.trunc(l);i[s]+=c,n[r]-=c*o}function yg(e,n){pg.reduce((r,i)=>H(n[i])?r:(r&&Ia(e,n,r,n,i),i),null)}class Y{constructor(n){const r=n.conversionAccuracy==="longterm"||!1;this.values=n.values,this.loc=n.loc||se.create(),this.conversionAccuracy=r?"longterm":"casual",this.invalid=n.invalid||null,this.matrix=r?hg:fg,this.isLuxonDuration=!0}static fromMillis(n,r){return Y.fromObject({milliseconds:n},r)}static fromObject(n,r={}){if(n==null||typeof n!="object")throw new Ie(`Duration.fromObject: argument expected to be an object, got ${n===null?"null":typeof n}`);return new Y({values:vn(n,Y.normalizeUnit),loc:se.fromObject(r),conversionAccuracy:r.conversionAccuracy})}static fromDurationLike(n){if(Mt(n))return Y.fromMillis(n);if(Y.isDuration(n))return n;if(typeof n=="object")return Y.fromObject(n);throw new Ie(`Unknown duration argument ${n} of type ${typeof n}`)}static fromISO(n,r){const[i]=og(n);return i?Y.fromObject(i,r):Y.invalid("unparsable",`the input "${n}" can't be parsed as ISO 8601`)}static fromISOTime(n,r){const[i]=sg(n);return i?Y.fromObject(i,r):Y.invalid("unparsable",`the input "${n}" can't be parsed as ISO 8601`)}static invalid(n,r=null){if(!n)throw new Ie("need to specify a reason the Duration is invalid");const i=n instanceof ze?n:new ze(n,r);if(ge.throwOnInvalid)throw new Hh(i);return new Y({invalid:i})}static normalizeUnit(n){const r={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[n&&n.toLowerCase()];if(!r)throw new jl(n);return r}static isDuration(n){return n&&n.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(n,r={}){const i={...r,floor:r.round!==!1&&r.floor!==!1};return this.isValid?Ne.create(this.loc,i).formatDurationFromString(this,n):mg}toHuman(n={}){const r=Lt.map(i=>{const s=this.values[i];return H(s)?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...n,unit:i.slice(0,-1)}).format(s)}).filter(i=>i);return this.loc.listFormatter({type:"conjunction",style:n.listStyle||"narrow",...n}).format(r)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let n="P";return this.years!==0&&(n+=this.years+"Y"),(this.months!==0||this.quarters!==0)&&(n+=this.months+this.quarters*3+"M"),this.weeks!==0&&(n+=this.weeks+"W"),this.days!==0&&(n+=this.days+"D"),(this.hours!==0||this.minutes!==0||this.seconds!==0||this.milliseconds!==0)&&(n+="T"),this.hours!==0&&(n+=this.hours+"H"),this.minutes!==0&&(n+=this.minutes+"M"),(this.seconds!==0||this.milliseconds!==0)&&(n+=so(this.seconds+this.milliseconds/1e3,3)+"S"),n==="P"&&(n+="T0S"),n}toISOTime(n={}){if(!this.isValid)return null;const r=this.toMillis();if(r<0||r>=864e5)return null;n={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...n};const i=this.shiftTo("hours","minutes","seconds","milliseconds");let s=n.format==="basic"?"hhmm":"hh:mm";(!n.suppressSeconds||i.seconds!==0||i.milliseconds!==0)&&(s+=n.format==="basic"?"ss":":ss",(!n.suppressMilliseconds||i.milliseconds!==0)&&(s+=".SSS"));let o=i.toFormat(s);return n.includePrefix&&(o="T"+o),o}toJSON(){return this.toISO()}toString(){return this.toISO()}toMillis(){return this.as("milliseconds")}valueOf(){return this.toMillis()}plus(n){if(!this.isValid)return this;const r=Y.fromDurationLike(n),i={};for(const s of Lt)(Qt(r.values,s)||Qt(this.values,s))&&(i[s]=r.get(s)+this.get(s));return $t(this,{values:i},!0)}minus(n){if(!this.isValid)return this;const r=Y.fromDurationLike(n);return this.plus(r.negate())}mapUnits(n){if(!this.isValid)return this;const r={};for(const i of Object.keys(this.values))r[i]=da(n(this.values[i],i));return $t(this,{values:r},!0)}get(n){return this[Y.normalizeUnit(n)]}set(n){if(!this.isValid)return this;const r={...this.values,...vn(n,Y.normalizeUnit)};return $t(this,{values:r})}reconfigure({locale:n,numberingSystem:r,conversionAccuracy:i}={}){const s=this.loc.clone({locale:n,numberingSystem:r}),o={loc:s};return i&&(o.conversionAccuracy=i),$t(this,o)}as(n){return this.isValid?this.shiftTo(n).get(n):NaN}normalize(){if(!this.isValid)return this;const n=this.toObject();return yg(this.matrix,n),$t(this,{values:n},!0)}shiftTo(...n){if(!this.isValid)return this;if(n.length===0)return this;n=n.map(l=>Y.normalizeUnit(l));const r={},i={},s=this.toObject();let o;for(const l of Lt)if(n.indexOf(l)>=0){o=l;let a=0;for(const d in i)a+=this.matrix[d][l]*i[d],i[d]=0;Mt(s[l])&&(a+=s[l]);const c=Math.trunc(a);r[l]=c,i[l]=(a*1e3-c*1e3)/1e3;for(const d in s)Lt.indexOf(d)>Lt.indexOf(l)&&Ia(this.matrix,s,d,r,l)}else Mt(s[l])&&(i[l]=s[l]);for(const l in i)i[l]!==0&&(r[o]+=l===o?i[l]:i[l]/this.matrix[o][l]);return $t(this,{values:r},!0).normalize()}negate(){if(!this.isValid)return this;const n={};for(const r of Object.keys(this.values))n[r]=this.values[r]===0?0:-this.values[r];return $t(this,{values:n},!0)}get years(){return this.isValid?this.values.years||0:NaN}get quarters(){return this.isValid?this.values.quarters||0:NaN}get months(){return this.isValid?this.values.months||0:NaN}get weeks(){return this.isValid?this.values.weeks||0:NaN}get days(){return this.isValid?this.values.days||0:NaN}get hours(){return this.isValid?this.values.hours||0:NaN}get minutes(){return this.isValid?this.values.minutes||0:NaN}get seconds(){return this.isValid?this.values.seconds||0:NaN}get milliseconds(){return this.isValid?this.values.milliseconds||0:NaN}get isValid(){return this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(n){if(!this.isValid||!n.isValid||!this.loc.equals(n.loc))return!1;function r(i,s){return i===void 0||i===0?s===void 0||s===0:i===s}for(const i of Lt)if(!r(this.values[i],n.values[i]))return!1;return!0}}const bn="Invalid Interval";function kg(e,n){return!e||!e.isValid?ce.invalid("missing or invalid start"):!n||!n.isValid?ce.invalid("missing or invalid end"):n<e?ce.invalid("end before start",`The end of an interval must be after its start, but you had start=${e.toISO()} and end=${n.toISO()}`):null}class ce{constructor(n){this.s=n.start,this.e=n.end,this.invalid=n.invalid||null,this.isLuxonInterval=!0}static invalid(n,r=null){if(!n)throw new Ie("need to specify a reason the Interval is invalid");const i=n instanceof ze?n:new ze(n,r);if(ge.throwOnInvalid)throw new Wh(i);return new ce({invalid:i})}static fromDateTimes(n,r){const i=Nn(n),s=Nn(r),o=kg(i,s);return o??new ce({start:i,end:s})}static after(n,r){const i=Y.fromDurationLike(r),s=Nn(n);return ce.fromDateTimes(s,s.plus(i))}static before(n,r){const i=Y.fromDurationLike(r),s=Nn(n);return ce.fromDateTimes(s.minus(i),s)}static fromISO(n,r){const[i,s]=(n||"").split("/",2);if(i&&s){let o,l;try{o=_.fromISO(i,r),l=o.isValid}catch{l=!1}let a,c;try{a=_.fromISO(s,r),c=a.isValid}catch{c=!1}if(l&&c)return ce.fromDateTimes(o,a);if(l){const d=Y.fromISO(s,r);if(d.isValid)return ce.after(o,d)}else if(c){const d=Y.fromISO(i,r);if(d.isValid)return ce.before(a,d)}}return ce.invalid("unparsable",`the input "${n}" can't be parsed as ISO 8601`)}static isInterval(n){return n&&n.isLuxonInterval||!1}get start(){return this.isValid?this.s:null}get end(){return this.isValid?this.e:null}get isValid(){return this.invalidReason===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}length(n="milliseconds"){return this.isValid?this.toDuration(n).get(n):NaN}count(n="milliseconds"){if(!this.isValid)return NaN;const r=this.start.startOf(n),i=this.end.startOf(n);return Math.floor(i.diff(r,n).get(n))+1}hasSame(n){return this.isValid?this.isEmpty()||this.e.minus(1).hasSame(this.s,n):!1}isEmpty(){return this.s.valueOf()===this.e.valueOf()}isAfter(n){return this.isValid?this.s>n:!1}isBefore(n){return this.isValid?this.e<=n:!1}contains(n){return this.isValid?this.s<=n&&this.e>n:!1}set({start:n,end:r}={}){return this.isValid?ce.fromDateTimes(n||this.s,r||this.e):this}splitAt(...n){if(!this.isValid)return[];const r=n.map(Nn).filter(l=>this.contains(l)).sort(),i=[];let{s}=this,o=0;for(;s<this.e;){const l=r[o]||this.e,a=+l>+this.e?this.e:l;i.push(ce.fromDateTimes(s,a)),s=a,o+=1}return i}splitBy(n){const r=Y.fromDurationLike(n);if(!this.isValid||!r.isValid||r.as("milliseconds")===0)return[];let{s:i}=this,s=1,o;const l=[];for(;i<this.e;){const a=this.start.plus(r.mapUnits(c=>c*s));o=+a>+this.e?this.e:a,l.push(ce.fromDateTimes(i,o)),i=o,s+=1}return l}divideEqually(n){return this.isValid?this.splitBy(this.length()/n).slice(0,n):[]}overlaps(n){return this.e>n.s&&this.s<n.e}abutsStart(n){return this.isValid?+this.e==+n.s:!1}abutsEnd(n){return this.isValid?+n.e==+this.s:!1}engulfs(n){return this.isValid?this.s<=n.s&&this.e>=n.e:!1}equals(n){return!this.isValid||!n.isValid?!1:this.s.equals(n.s)&&this.e.equals(n.e)}intersection(n){if(!this.isValid)return this;const r=this.s>n.s?this.s:n.s,i=this.e<n.e?this.e:n.e;return r>=i?null:ce.fromDateTimes(r,i)}union(n){if(!this.isValid)return this;const r=this.s<n.s?this.s:n.s,i=this.e>n.e?this.e:n.e;return ce.fromDateTimes(r,i)}static merge(n){const[r,i]=n.sort((s,o)=>s.s-o.s).reduce(([s,o],l)=>o?o.overlaps(l)||o.abutsStart(l)?[s,o.union(l)]:[s.concat([o]),l]:[s,l],[[],null]);return i&&r.push(i),r}static xor(n){let r=null,i=0;const s=[],o=n.map(c=>[{time:c.s,type:"s"},{time:c.e,type:"e"}]),l=Array.prototype.concat(...o),a=l.sort((c,d)=>c.time-d.time);for(const c of a)i+=c.type==="s"?1:-1,i===1?r=c.time:(r&&+r!=+c.time&&s.push(ce.fromDateTimes(r,c.time)),r=null);return ce.merge(s)}difference(...n){return ce.xor([this].concat(n)).map(r=>this.intersection(r)).filter(r=>r&&!r.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} – ${this.e.toISO()})`:bn}toISO(n){return this.isValid?`${this.s.toISO(n)}/${this.e.toISO(n)}`:bn}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:bn}toISOTime(n){return this.isValid?`${this.s.toISOTime(n)}/${this.e.toISOTime(n)}`:bn}toFormat(n,{separator:r=" – "}={}){return this.isValid?`${this.s.toFormat(n)}${r}${this.e.toFormat(n)}`:bn}toDuration(n,r){return this.isValid?this.e.diff(this.s,n,r):Y.invalid(this.invalidReason)}mapEndpoints(n){return ce.fromDateTimes(n(this.s),n(this.e))}}let ir=class{static hasDST(n=ge.defaultZone){const r=_.now().setZone(n).set({month:12});return!n.isUniversal&&r.offset!==r.set({month:6}).offset}static isValidIANAZone(n){return rt.isValidZone(n)}static normalizeZone(n){return mt(n,ge.defaultZone)}static months(n="long",{locale:r=null,numberingSystem:i=null,locObj:s=null,outputCalendar:o="gregory"}={}){return(s||se.create(r,i,o)).months(n)}static monthsFormat(n="long",{locale:r=null,numberingSystem:i=null,locObj:s=null,outputCalendar:o="gregory"}={}){return(s||se.create(r,i,o)).months(n,!0)}static weekdays(n="long",{locale:r=null,numberingSystem:i=null,locObj:s=null}={}){return(s||se.create(r,i,null)).weekdays(n)}static weekdaysFormat(n="long",{locale:r=null,numberingSystem:i=null,locObj:s=null}={}){return(s||se.create(r,i,null)).weekdays(n,!0)}static meridiems({locale:n=null}={}){return se.create(n).meridiems()}static eras(n="short",{locale:r=null}={}){return se.create(r,null,"gregory").eras(n)}static features(){return{relative:la()}}};function Aa(e,n){const r=s=>s.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),i=r(n)-r(e);return Math.floor(Y.fromMillis(i).as("days"))}function _g(e,n,r){const i=[["years",(a,c)=>c.year-a.year],["quarters",(a,c)=>c.quarter-a.quarter],["months",(a,c)=>c.month-a.month+(c.year-a.year)*12],["weeks",(a,c)=>{const d=Aa(a,c);return(d-d%7)/7}],["days",Aa]],s={};let o,l;for(const[a,c]of i)if(r.indexOf(a)>=0){o=a;let d=c(e,n);l=e.plus({[a]:d}),l>n?(e=e.plus({[a]:d-1}),d-=1):e=l,s[a]=d}return[e,s,l,o]}function wg(e,n,r,i){let[s,o,l,a]=_g(e,n,r);const c=n-s,d=r.filter(m=>["hours","minutes","seconds","milliseconds"].indexOf(m)>=0);d.length===0&&(l<n&&(l=s.plus({[a]:1})),l!==s&&(o[a]=(o[a]||0)+c/(l-s)));const u=Y.fromObject(o,i);return d.length>0?Y.fromMillis(c,i).shiftTo(...d).plus(u):u}const wo={arab:"[٠-٩]",arabext:"[۰-۹]",bali:"[᭐-᭙]",beng:"[০-৯]",deva:"[०-९]",fullwide:"[0-9]",gujr:"[૦-૯]",hanidec:"[〇|一|二|三|四|五|六|七|八|九]",khmr:"[០-៩]",knda:"[೦-೯]",laoo:"[໐-໙]",limb:"[᥆-᥏]",mlym:"[൦-൯]",mong:"[᠐-᠙]",mymr:"[၀-၉]",orya:"[୦-୯]",tamldec:"[௦-௯]",telu:"[౦-౯]",thai:"[๐-๙]",tibt:"[༠-༩]",latn:"\\d"},La={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},xg=wo.hanidec.replace(/[\[|\]]/g,"").split("");function bg(e){let n=parseInt(e,10);if(isNaN(n)){n="";for(let r=0;r<e.length;r++){const i=e.charCodeAt(r);if(e[r].search(wo.hanidec)!==-1)n+=xg.indexOf(e[r]);else for(const s in La){const[o,l]=La[s];i>=o&&i<=l&&(n+=i-o)}}return parseInt(n,10)}else return n}function We({numberingSystem:e},n=""){return new RegExp(`${wo[e||"latn"]}${n}`)}const Cg="missing Intl.DateTimeFormat.formatToParts support";function Z(e,n=r=>r){return{regex:e,deser:([r])=>n(bg(r))}}const $a="( | )",Pa=new RegExp($a,"g");function Vg(e){return e.replace(/\./g,"\\.?").replace(Pa,$a)}function Ra(e){return e.replace(/\./g,"").replace(Pa," ").toLowerCase()}function He(e,n){return e===null?null:{regex:RegExp(e.map(Vg).join("|")),deser:([r])=>e.findIndex(i=>Ra(r)===Ra(i))+n}}function Ua(e,n){return{regex:e,deser:([,r,i])=>Qn(r,i),groups:n}}function xo(e){return{regex:e,deser:([n])=>n}}function Ng(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function Eg(e,n){const r=We(n),i=We(n,"{2}"),s=We(n,"{3}"),o=We(n,"{4}"),l=We(n,"{6}"),a=We(n,"{1,2}"),c=We(n,"{1,3}"),d=We(n,"{1,6}"),u=We(n,"{1,9}"),m=We(n,"{2,4}"),f=We(n,"{4,6}"),h=y=>({regex:RegExp(Ng(y.val)),deser:([k])=>k,literal:!0}),p=(y=>{if(e.literal)return h(y);switch(y.val){case"G":return He(n.eras("short",!1),0);case"GG":return He(n.eras("long",!1),0);case"y":return Z(d);case"yy":return Z(m,ao);case"yyyy":return Z(o);case"yyyyy":return Z(f);case"yyyyyy":return Z(l);case"M":return Z(a);case"MM":return Z(i);case"MMM":return He(n.months("short",!0,!1),1);case"MMMM":return He(n.months("long",!0,!1),1);case"L":return Z(a);case"LL":return Z(i);case"LLL":return He(n.months("short",!1,!1),1);case"LLLL":return He(n.months("long",!1,!1),1);case"d":return Z(a);case"dd":return Z(i);case"o":return Z(c);case"ooo":return Z(s);case"HH":return Z(i);case"H":return Z(a);case"hh":return Z(i);case"h":return Z(a);case"mm":return Z(i);case"m":return Z(a);case"q":return Z(a);case"qq":return Z(i);case"s":return Z(a);case"ss":return Z(i);case"S":return Z(c);case"SSS":return Z(s);case"u":return xo(u);case"uu":return xo(a);case"uuu":return Z(r);case"a":return He(n.meridiems(),0);case"kkkk":return Z(o);case"kk":return Z(m,ao);case"W":return Z(a);case"WW":return Z(i);case"E":case"c":return Z(r);case"EEE":return He(n.weekdays("short",!1,!1),1);case"EEEE":return He(n.weekdays("long",!1,!1),1);case"ccc":return He(n.weekdays("short",!0,!1),1);case"cccc":return He(n.weekdays("long",!0,!1),1);case"Z":case"ZZ":return Ua(new RegExp(`([+-]${a.source})(?::(${i.source}))?`),2);case"ZZZ":return Ua(new RegExp(`([+-]${a.source})(${i.source})?`),2);case"z":return xo(/[a-z_+-/]{1,256}?/i);default:return h(y)}})(e)||{invalidReason:Cg};return p.token=e,p}const Bg={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour:{numeric:"h","2-digit":"hh"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"}};function Sg(e,n,r){const{type:i,value:s}=e;if(i==="literal")return{literal:!0,val:s};const o=r[i];let l=Bg[i];if(typeof l=="object"&&(l=l[o]),l)return{literal:!1,val:l}}function Tg(e){return[`^${e.map(r=>r.regex).reduce((r,i)=>`${r}(${i.source})`,"")}$`,e]}function Dg(e,n,r){const i=e.match(n);if(i){const s={};let o=1;for(const l in r)if(Qt(r,l)){const a=r[l],c=a.groups?a.groups+1:1;!a.literal&&a.token&&(s[a.token.val[0]]=a.deser(i.slice(o,o+c))),o+=c}return[i,s]}else return[i,{}]}function Og(e){const n=o=>{switch(o){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}};let r=null,i;return H(e.z)||(r=rt.create(e.z)),H(e.Z)||(r||(r=new Ce(e.Z)),i=e.Z),H(e.q)||(e.M=(e.q-1)*3+1),H(e.h)||(e.h<12&&e.a===1?e.h+=12:e.h===12&&e.a===0&&(e.h=0)),e.G===0&&e.y&&(e.y=-e.y),H(e.u)||(e.S=io(e.u)),[Object.keys(e).reduce((o,l)=>{const a=n(l);return a&&(o[a]=e[l]),o},{}),r,i]}let bo=null;function Mg(){return bo||(bo=_.fromMillis(1555555555555)),bo}function Fg(e,n){if(e.literal)return e;const r=Ne.macroTokenToFormatOpts(e.val);if(!r)return e;const o=Ne.create(n,r).formatDateTimeParts(Mg()).map(l=>Sg(l,n,r));return o.includes(void 0)?e:o}function Ig(e,n){return Array.prototype.concat(...e.map(r=>Fg(r,n)))}function ja(e,n,r){const i=Ig(Ne.parseFormat(r),e),s=i.map(l=>Eg(l,e)),o=s.find(l=>l.invalidReason);if(o)return{input:n,tokens:i,invalidReason:o.invalidReason};{const[l,a]=Tg(s),c=RegExp(l,"i"),[d,u]=Dg(n,c,a),[m,f,h]=u?Og(u):[null,null,void 0];if(Qt(u,"a")&&Qt(u,"H"))throw new yn("Can't include meridiem when specifying 24-hour format");return{input:n,tokens:i,regex:c,rawMatches:d,matches:u,result:m,zone:f,specificOffset:h}}}function Ag(e,n,r){const{result:i,zone:s,specificOffset:o,invalidReason:l}=ja(e,n,r);return[i,s,o,l]}const qa=[0,31,59,90,120,151,181,212,243,273,304,334],za=[0,31,60,91,121,152,182,213,244,274,305,335];function Le(e,n){return new ze("unit out of range",`you specified ${n} (of type ${typeof n}) as a ${e}, which is invalid`)}function Wa(e,n,r){const i=new Date(Date.UTC(e,n-1,r));e<100&&e>=0&&i.setUTCFullYear(i.getUTCFullYear()-1900);const s=i.getUTCDay();return s===0?7:s}function Ha(e,n,r){return r+(kn(e)?za:qa)[n-1]}function Ga(e,n){const r=kn(e)?za:qa,i=r.findIndex(o=>o<n),s=n-r[i];return{month:i+1,day:s}}function Co(e){const{year:n,month:r,day:i}=e,s=Ha(n,r,i),o=Wa(n,r,i);let l=Math.floor((s-o+10)/7),a;return l<1?(a=n-1,l=Xn(a)):l>Xn(n)?(a=n+1,l=1):a=n,{weekYear:a,weekNumber:l,weekday:o,...tr(e)}}function Ya(e){const{weekYear:n,weekNumber:r,weekday:i}=e,s=Wa(n,1,4),o=_n(n);let l=r*7+i-s-3,a;l<1?(a=n-1,l+=_n(a)):l>o?(a=n+1,l-=_n(n)):a=n;const{month:c,day:d}=Ga(a,l);return{year:a,month:c,day:d,...tr(e)}}function Vo(e){const{year:n,month:r,day:i}=e,s=Ha(n,r,i);return{year:n,ordinal:s,...tr(e)}}function Ja(e){const{year:n,ordinal:r}=e,{month:i,day:s}=Ga(n,r);return{year:n,month:i,day:s,...tr(e)}}function Lg(e){const n=Kn(e.weekYear),r=nt(e.weekNumber,1,Xn(e.weekYear)),i=nt(e.weekday,1,7);return n?r?i?!1:Le("weekday",e.weekday):Le("week",e.week):Le("weekYear",e.weekYear)}function $g(e){const n=Kn(e.year),r=nt(e.ordinal,1,_n(e.year));return n?r?!1:Le("ordinal",e.ordinal):Le("year",e.year)}function Ka(e){const n=Kn(e.year),r=nt(e.month,1,12),i=nt(e.day,1,Zn(e.year,e.month));return n?r?i?!1:Le("day",e.day):Le("month",e.month):Le("year",e.year)}function Za(e){const{hour:n,minute:r,second:i,millisecond:s}=e,o=nt(n,0,23)||n===24&&r===0&&i===0&&s===0,l=nt(r,0,59),a=nt(i,0,59),c=nt(s,0,999);return o?l?a?c?!1:Le("millisecond",s):Le("second",i):Le("minute",r):Le("hour",n)}const No="Invalid DateTime",Pg=864e13;function sr(e){return new ze("unsupported zone",`the zone "${e.name}" is not supported`)}function Eo(e){return e.weekData===null&&(e.weekData=Co(e.c)),e.weekData}function Cn(e,n){const r={ts:e.ts,zone:e.zone,c:e.c,o:e.o,loc:e.loc,invalid:e.invalid};return new _({...r,...n,old:r})}function Xa(e,n,r){let i=e-n*60*1e3;const s=r.offset(i);if(n===s)return[i,n];i-=(s-n)*60*1e3;const o=r.offset(i);return s===o?[i,s]:[e-Math.min(s,o)*60*1e3,Math.max(s,o)]}function Qa(e,n){e+=n*60*1e3;const r=new Date(e);return{year:r.getUTCFullYear(),month:r.getUTCMonth()+1,day:r.getUTCDate(),hour:r.getUTCHours(),minute:r.getUTCMinutes(),second:r.getUTCSeconds(),millisecond:r.getUTCMilliseconds()}}function lr(e,n,r){return Xa(lo(e),n,r)}function va(e,n){const r=e.o,i=e.c.year+Math.trunc(n.years),s=e.c.month+Math.trunc(n.months)+Math.trunc(n.quarters)*3,o={...e.c,year:i,month:s,day:Math.min(e.c.day,Zn(i,s))+Math.trunc(n.days)+Math.trunc(n.weeks)*7},l=Y.fromObject({years:n.years-Math.trunc(n.years),quarters:n.quarters-Math.trunc(n.quarters),months:n.months-Math.trunc(n.months),weeks:n.weeks-Math.trunc(n.weeks),days:n.days-Math.trunc(n.days),hours:n.hours,minutes:n.minutes,seconds:n.seconds,milliseconds:n.milliseconds}).as("milliseconds"),a=lo(o);let[c,d]=Xa(a,r,e.zone);return l!==0&&(c+=l,d=e.zone.offset(c)),{ts:c,o:d}}function Vn(e,n,r,i,s,o){const{setZone:l,zone:a}=r;if(e&&Object.keys(e).length!==0){const c=n||a,d=_.fromObject(e,{...r,zone:c,specificOffset:o});return l?d:d.setZone(a)}else return _.invalid(new ze("unparsable",`the input "${s}" can't be parsed as ${i}`))}function ar(e,n,r=!0){return e.isValid?Ne.create(se.create("en-US"),{allowZ:r,forceSimple:!0}).formatDateTimeFromString(e,n):null}function Bo(e,n){const r=e.c.year>9999||e.c.year<0;let i="";return r&&e.c.year>=0&&(i+="+"),i+=fe(e.c.year,r?6:4),n?(i+="-",i+=fe(e.c.month),i+="-",i+=fe(e.c.day)):(i+=fe(e.c.month),i+=fe(e.c.day)),i}function ec(e,n,r,i,s){let o=fe(e.c.hour);return n?(o+=":",o+=fe(e.c.minute),(e.c.second!==0||!r)&&(o+=":")):o+=fe(e.c.minute),(e.c.second!==0||!r)&&(o+=fe(e.c.second),(e.c.millisecond!==0||!i)&&(o+=".",o+=fe(e.c.millisecond,3))),s&&(e.isOffsetFixed&&e.offset===0?o+="Z":e.o<0?(o+="-",o+=fe(Math.trunc(-e.o/60)),o+=":",o+=fe(Math.trunc(-e.o%60))):(o+="+",o+=fe(Math.trunc(e.o/60)),o+=":",o+=fe(Math.trunc(e.o%60)))),o}const tc={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},Rg={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},Ug={ordinal:1,hour:0,minute:0,second:0,millisecond:0},nc=["year","month","day","hour","minute","second","millisecond"],jg=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],qg=["year","ordinal","hour","minute","second","millisecond"];function rc(e){const n={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[e.toLowerCase()];if(!n)throw new jl(e);return n}function oc(e,n){const r=mt(n.zone,ge.defaultZone),i=se.fromObject(n),s=ge.now();let o,l;if(H(e.year))o=s;else{for(const d of nc)H(e[d])&&(e[d]=tc[d]);const a=Ka(e)||Za(e);if(a)return _.invalid(a);const c=r.offset(s);[o,l]=lr(e,c,r)}return new _({ts:o,zone:r,loc:i,o:l})}function ic(e,n,r){const i=H(r.round)?!0:r.round,s=(l,a)=>(l=so(l,i||r.calendary?0:2,!0),n.loc.clone(r).relFormatter(r).format(l,a)),o=l=>r.calendary?n.hasSame(e,l)?0:n.startOf(l).diff(e.startOf(l),l).get(l):n.diff(e,l).get(l);if(r.unit)return s(o(r.unit),r.unit);for(const l of r.units){const a=o(l);if(Math.abs(a)>=1)return s(a,l)}return s(e>n?-0:0,r.units[r.units.length-1])}function sc(e){let n={},r;return e.length>0&&typeof e[e.length-1]=="object"?(n=e[e.length-1],r=Array.from(e).slice(0,e.length-1)):r=Array.from(e),[n,r]}class _{constructor(n){const r=n.zone||ge.defaultZone;let i=n.invalid||(Number.isNaN(n.ts)?new ze("invalid input"):null)||(r.isValid?null:sr(r));this.ts=H(n.ts)?ge.now():n.ts;let s=null,o=null;if(!i)if(n.old&&n.old.ts===this.ts&&n.old.zone.equals(r))[s,o]=[n.old.c,n.old.o];else{const a=r.offset(this.ts);s=Qa(this.ts,a),i=Number.isNaN(s.year)?new ze("invalid input"):null,s=i?null:s,o=i?null:a}this._zone=r,this.loc=n.loc||se.create(),this.invalid=i,this.weekData=null,this.c=s,this.o=o,this.isLuxonDateTime=!0}static now(){return new _({})}static local(){const[n,r]=sc(arguments),[i,s,o,l,a,c,d]=r;return oc({year:i,month:s,day:o,hour:l,minute:a,second:c,millisecond:d},n)}static utc(){const[n,r]=sc(arguments),[i,s,o,l,a,c,d]=r;return n.zone=Ce.utcInstance,oc({year:i,month:s,day:o,hour:l,minute:a,second:c,millisecond:d},n)}static fromJSDate(n,r={}){const i=Kh(n)?n.valueOf():NaN;if(Number.isNaN(i))return _.invalid("invalid input");const s=mt(r.zone,ge.defaultZone);return s.isValid?new _({ts:i,zone:s,loc:se.fromObject(r)}):_.invalid(sr(s))}static fromMillis(n,r={}){if(Mt(n))return n<-864e13||n>Pg?_.invalid("Timestamp out of range"):new _({ts:n,zone:mt(r.zone,ge.defaultZone),loc:se.fromObject(r)});throw new Ie(`fromMillis requires a numerical input, but received a ${typeof n} with value ${n}`)}static fromSeconds(n,r={}){if(Mt(n))return new _({ts:n*1e3,zone:mt(r.zone,ge.defaultZone),loc:se.fromObject(r)});throw new Ie("fromSeconds requires a numerical input")}static fromObject(n,r={}){n=n||{};const i=mt(r.zone,ge.defaultZone);if(!i.isValid)return _.invalid(sr(i));const s=ge.now(),o=H(r.specificOffset)?i.offset(s):r.specificOffset,l=vn(n,rc),a=!H(l.ordinal),c=!H(l.year),d=!H(l.month)||!H(l.day),u=c||d,m=l.weekYear||l.weekNumber,f=se.fromObject(r);if((u||a)&&m)throw new yn("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(d&&a)throw new yn("Can't mix ordinal dates with month/day");const h=m||l.weekday&&!u;let g,p,y=Qa(s,o);h?(g=jg,p=Rg,y=Co(y)):a?(g=qg,p=Ug,y=Vo(y)):(g=nc,p=tc);let k=!1;for(const F of g){const O=l[F];H(O)?k?l[F]=p[F]:l[F]=y[F]:k=!0}const x=h?Lg(l):a?$g(l):Ka(l),S=x||Za(l);if(S)return _.invalid(S);const I=h?Ya(l):a?Ja(l):l,[P,q]=lr(I,o,i),b=new _({ts:P,zone:i,o:q,loc:f});return l.weekday&&u&&n.weekday!==b.weekday?_.invalid("mismatched weekday",`you can't specify both a weekday of ${l.weekday} and a date of ${b.toISO()}`):b}static fromISO(n,r={}){const[i,s]=tg(n);return Vn(i,s,r,"ISO 8601",n)}static fromRFC2822(n,r={}){const[i,s]=ng(n);return Vn(i,s,r,"RFC 2822",n)}static fromHTTP(n,r={}){const[i,s]=rg(n);return Vn(i,s,r,"HTTP",r)}static fromFormat(n,r,i={}){if(H(n)||H(r))throw new Ie("fromFormat requires an input string and a format");const{locale:s=null,numberingSystem:o=null}=i,l=se.fromOpts({locale:s,numberingSystem:o,defaultToEN:!0}),[a,c,d,u]=Ag(l,n,r);return u?_.invalid(u):Vn(a,c,i,`format ${r}`,n,d)}static fromString(n,r,i={}){return _.fromFormat(n,r,i)}static fromSQL(n,r={}){const[i,s]=ug(n);return Vn(i,s,r,"SQL",n)}static invalid(n,r=null){if(!n)throw new Ie("need to specify a reason the DateTime is invalid");const i=n instanceof ze?n:new ze(n,r);if(ge.throwOnInvalid)throw new zh(i);return new _({invalid:i})}static isDateTime(n){return n&&n.isLuxonDateTime||!1}get(n){return this[n]}get isValid(){return this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}get outputCalendar(){return this.isValid?this.loc.outputCalendar:null}get zone(){return this._zone}get zoneName(){return this.isValid?this.zone.name:null}get year(){return this.isValid?this.c.year:NaN}get quarter(){return this.isValid?Math.ceil(this.c.month/3):NaN}get month(){return this.isValid?this.c.month:NaN}get day(){return this.isValid?this.c.day:NaN}get hour(){return this.isValid?this.c.hour:NaN}get minute(){return this.isValid?this.c.minute:NaN}get second(){return this.isValid?this.c.second:NaN}get millisecond(){return this.isValid?this.c.millisecond:NaN}get weekYear(){return this.isValid?Eo(this).weekYear:NaN}get weekNumber(){return this.isValid?Eo(this).weekNumber:NaN}get weekday(){return this.isValid?Eo(this).weekday:NaN}get ordinal(){return this.isValid?Vo(this.c).ordinal:NaN}get monthShort(){return this.isValid?ir.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?ir.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?ir.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?ir.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}get offset(){return this.isValid?+this.o:NaN}get offsetNameShort(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}get offsetNameLong(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}get isOffsetFixed(){return this.isValid?this.zone.isUniversal:null}get isInDST(){return this.isOffsetFixed?!1:this.offset>this.set({month:1}).offset||this.offset>this.set({month:5}).offset}get isInLeapYear(){return kn(this.year)}get daysInMonth(){return Zn(this.year,this.month)}get daysInYear(){return this.isValid?_n(this.year):NaN}get weeksInWeekYear(){return this.isValid?Xn(this.weekYear):NaN}resolvedLocaleOptions(n={}){const{locale:r,numberingSystem:i,calendar:s}=Ne.create(this.loc.clone(n),n).resolvedOptions(this);return{locale:r,numberingSystem:i,outputCalendar:s}}toUTC(n=0,r={}){return this.setZone(Ce.instance(n),r)}toLocal(){return this.setZone(ge.defaultZone)}setZone(n,{keepLocalTime:r=!1,keepCalendarTime:i=!1}={}){if(n=mt(n,ge.defaultZone),n.equals(this.zone))return this;if(n.isValid){let s=this.ts;if(r||i){const o=n.offset(this.ts),l=this.toObject();[s]=lr(l,o,n)}return Cn(this,{ts:s,zone:n})}else return _.invalid(sr(n))}reconfigure({locale:n,numberingSystem:r,outputCalendar:i}={}){const s=this.loc.clone({locale:n,numberingSystem:r,outputCalendar:i});return Cn(this,{loc:s})}setLocale(n){return this.reconfigure({locale:n})}set(n){if(!this.isValid)return this;const r=vn(n,rc),i=!H(r.weekYear)||!H(r.weekNumber)||!H(r.weekday),s=!H(r.ordinal),o=!H(r.year),l=!H(r.month)||!H(r.day),a=o||l,c=r.weekYear||r.weekNumber;if((a||s)&&c)throw new yn("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(l&&s)throw new yn("Can't mix ordinal dates with month/day");let d;i?d=Ya({...Co(this.c),...r}):H(r.ordinal)?(d={...this.toObject(),...r},H(r.day)&&(d.day=Math.min(Zn(d.year,d.month),d.day))):d=Ja({...Vo(this.c),...r});const[u,m]=lr(d,this.o,this.zone);return Cn(this,{ts:u,o:m})}plus(n){if(!this.isValid)return this;const r=Y.fromDurationLike(n);return Cn(this,va(this,r))}minus(n){if(!this.isValid)return this;const r=Y.fromDurationLike(n).negate();return Cn(this,va(this,r))}startOf(n){if(!this.isValid)return this;const r={},i=Y.normalizeUnit(n);switch(i){case"years":r.month=1;case"quarters":case"months":r.day=1;case"weeks":case"days":r.hour=0;case"hours":r.minute=0;case"minutes":r.second=0;case"seconds":r.millisecond=0;break}if(i==="weeks"&&(r.weekday=1),i==="quarters"){const s=Math.ceil(this.month/3);r.month=(s-1)*3+1}return this.set(r)}endOf(n){return this.isValid?this.plus({[n]:1}).startOf(n).minus(1):this}toFormat(n,r={}){return this.isValid?Ne.create(this.loc.redefaultToEN(r)).formatDateTimeFromString(this,n):No}toLocaleString(n=oo,r={}){return this.isValid?Ne.create(this.loc.clone(r),n).formatDateTime(this):No}toLocaleParts(n={}){return this.isValid?Ne.create(this.loc.clone(n),n).formatDateTimeParts(this):[]}toISO({format:n="extended",suppressSeconds:r=!1,suppressMilliseconds:i=!1,includeOffset:s=!0}={}){if(!this.isValid)return null;const o=n==="extended";let l=Bo(this,o);return l+="T",l+=ec(this,o,r,i,s),l}toISODate({format:n="extended"}={}){return this.isValid?Bo(this,n==="extended"):null}toISOWeekDate(){return ar(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:n=!1,suppressSeconds:r=!1,includeOffset:i=!0,includePrefix:s=!1,format:o="extended"}={}){return this.isValid?(s?"T":"")+ec(this,o==="extended",r,n,i):null}toRFC2822(){return ar(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return ar(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?Bo(this,!0):null}toSQLTime({includeOffset:n=!0,includeZone:r=!1,includeOffsetSpace:i=!0}={}){let s="HH:mm:ss.SSS";return(r||n)&&(i&&(s+=" "),r?s+="z":n&&(s+="ZZ")),ar(this,s,!0)}toSQL(n={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(n)}`:null}toString(){return this.isValid?this.toISO():No}valueOf(){return this.toMillis()}toMillis(){return this.isValid?this.ts:NaN}toSeconds(){return this.isValid?this.ts/1e3:NaN}toUnixInteger(){return this.isValid?Math.floor(this.ts/1e3):NaN}toJSON(){return this.toISO()}toBSON(){return this.toJSDate()}toObject(n={}){if(!this.isValid)return{};const r={...this.c};return n.includeConfig&&(r.outputCalendar=this.outputCalendar,r.numberingSystem=this.loc.numberingSystem,r.locale=this.loc.locale),r}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(n,r="milliseconds",i={}){if(!this.isValid||!n.isValid)return Y.invalid("created by diffing an invalid DateTime");const s={locale:this.locale,numberingSystem:this.numberingSystem,...i},o=Zh(r).map(Y.normalizeUnit),l=n.valueOf()>this.valueOf(),a=l?this:n,c=l?n:this,d=wg(a,c,o,s);return l?d.negate():d}diffNow(n="milliseconds",r={}){return this.diff(_.now(),n,r)}until(n){return this.isValid?ce.fromDateTimes(this,n):this}hasSame(n,r){if(!this.isValid)return!1;const i=n.valueOf(),s=this.setZone(n.zone,{keepLocalTime:!0});return s.startOf(r)<=i&&i<=s.endOf(r)}equals(n){return this.isValid&&n.isValid&&this.valueOf()===n.valueOf()&&this.zone.equals(n.zone)&&this.loc.equals(n.loc)}toRelative(n={}){if(!this.isValid)return null;const r=n.base||_.fromObject({},{zone:this.zone}),i=n.padding?this<r?-n.padding:n.padding:0;let s=["years","months","days","hours","minutes","seconds"],o=n.unit;return Array.isArray(n.unit)&&(s=n.unit,o=void 0),ic(r,this.plus(i),{...n,numeric:"always",units:s,unit:o})}toRelativeCalendar(n={}){return this.isValid?ic(n.base||_.fromObject({},{zone:this.zone}),this,{...n,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...n){if(!n.every(_.isDateTime))throw new Ie("min requires all arguments be DateTimes");return aa(n,r=>r.valueOf(),Math.min)}static max(...n){if(!n.every(_.isDateTime))throw new Ie("max requires all arguments be DateTimes");return aa(n,r=>r.valueOf(),Math.max)}static fromFormatExplain(n,r,i={}){const{locale:s=null,numberingSystem:o=null}=i,l=se.fromOpts({locale:s,numberingSystem:o,defaultToEN:!0});return ja(l,n,r)}static fromStringExplain(n,r,i={}){return _.fromFormatExplain(n,r,i)}static get DATE_SHORT(){return oo}static get DATE_MED(){return ql}static get DATE_MED_WITH_WEEKDAY(){return Gh}static get DATE_FULL(){return zl}static get DATE_HUGE(){return Wl}static get TIME_SIMPLE(){return Hl}static get TIME_WITH_SECONDS(){return Gl}static get TIME_WITH_SHORT_OFFSET(){return Yl}static get TIME_WITH_LONG_OFFSET(){return Jl}static get TIME_24_SIMPLE(){return Kl}static get TIME_24_WITH_SECONDS(){return Zl}static get TIME_24_WITH_SHORT_OFFSET(){return Xl}static get TIME_24_WITH_LONG_OFFSET(){return Ql}static get DATETIME_SHORT(){return vl}static get DATETIME_SHORT_WITH_SECONDS(){return ea}static get DATETIME_MED(){return ta}static get DATETIME_MED_WITH_SECONDS(){return na}static get DATETIME_MED_WITH_WEEKDAY(){return Yh}static get DATETIME_FULL(){return ra}static get DATETIME_FULL_WITH_SECONDS(){return oa}static get DATETIME_HUGE(){return ia}static get DATETIME_HUGE_WITH_SECONDS(){return sa}}function Nn(e){if(_.isDateTime(e))return e;if(e&&e.valueOf&&Mt(e.valueOf()))return _.fromJSDate(e);if(e&&typeof e=="object")return _.fromObject(e);throw new Ie(`Unknown datetime argument: ${e}, of type ${typeof e}`)}const Q={};Q.format=function(e,n){return e=e?new Date(e):new Date,_.fromJSDate(e).toFormat(n)},Q.readableTime=function(e){if(e=String(e||""),!e||!/^\d{4}$/.test(e))return e;const n=e.substring(0,2),r=e.substring(2,4);return console.log(e,n,r),_.fromObject({hour:parseInt(n,10),minute:parseInt(r,10)}).toFormat("h:mma").toLowerCase().replace(/:00/g,"")},Q.timeago=function(e,n){return _.fromJSDate(new Date(e)).toRelative(n)},Q.getDatesBetween=function(e,n){const r=[];let i=_.fromISO(e);const s=_.fromISO(n);for(;i<=s;)r.push(i.toISODate()),i=i.plus({days:1});return r},Q.getCalendarDateLimits=function(e){const n=e.getFullYear(),r=e.getMonth(),i=new Date(n,r,1),s=new Date(n,r+1,0),o=new Date(i);o.setDate(o.getDate()-o.getDay());const l=new Date(s);l.setDate(l.getDate()+(6-l.getDay()));const a={weekday:"long",day:"numeric",month:"long",year:"numeric"},c=o.toLocaleDateString("en-US",a),d=l.toLocaleDateString("en-US",a);return{start:new Date(c),end:new Date(d)}},Q.getMiddleDate=function(e,n){const r=e.getTime(),i=n.getTime(),s=(r+i)/2;return new Date(s)},Q.shortTime=function(e){return e.toJSDate||(e=_.fromJSDate(new Date(e))),e.toFormat("mm")==="00"?e.toFormat("ha").toLowerCase():e.toFormat("h:mma").toLowerCase()},Q.readableEventDate=function({startDate:e,endDate:n,timezone:r},i){if(!e)return"";e=new Date(e),n=n?new Date(n):void 0;let s,o;try{s=r?_.fromJSDate(e).setZone(r):_.fromJSDate(e),o=n?r?_.fromJSDate(n).setZone(r):_.fromJSDate(n):s}catch{s=_.fromJSDate(e),o=n?_.fromJSDate(n):s}const l=_.now(),a=r&&s.zoneName!==_.local().zoneName?` (${s.zoneName})`:"",d=s.year!==l.year?` ${s.year}`:"";return s.hasSame(o,"day")?Q.shortTime(s)==="12am"?`${s.toFormat("d MMMM")}${d}${a}`:`${Q.shortTime(s)}, ${s.toFormat("cccc d MMMM")}${d}${a}`:s.hasSame(o,"month")?`${s.toFormat("d")}-${o.toFormat("d MMMM")}${d}${a}`:s.hasSame(o,"year")?`${s.toFormat("d MMM")} - ${o.toFormat("d MMM")}${d}${a}`:`${s.toFormat("d MMM yyyy")} - ${o.toFormat("d MMM yyyy")}${a}`},Q.readableDateRange=function(e,n,r){if(!e)return;if(!n)return Q.readableDate(e);e=_.fromJSDate(new Date(e)),n=_.fromJSDate(new Date(n));const i=e.toFormat("yyyy"),s=e.toFormat("LLL yyyy"),o=e.toFormat("WW yyyy"),l=e.toFormat("d LLL yyyy"),a=n.toFormat("yyyy"),c=n.toFormat("LLL yyyy"),d=n.toFormat("WW yyyy"),u=n.toFormat("d LLL yyyy");return l===u?Q.shortTime(e)==="12am"?`${Q.readableDate(n)}`:`${Q.shortTime(e)} - ${Q.readableDate(n)}`:o===d?`${Q.readableDate(e)} - ${Q.readableDate(n)}`:s===c?`${e.toFormat("d")} - ${n.toFormat("d LLL")}`:i===a?`${Q.readableDate(e)} - ${Q.readableDate(n)}`:`${Q.readableDate(e)} - ${Q.readableDate(n)}`},Q.readableDate=function(e){if(!e)return;const n=new Date,r=_.fromJSDate(n),i=r.toFormat("yyyy"),s=r.toFormat("LLL yyyy"),o=r.toFormat("WW yyyy"),l=r.toFormat("d LLL yyyy");e=new Date(e);const a=_.fromJSDate(e),c=a.toFormat("yyyy"),d=a.toFormat("LLL yyyy"),u=a.toFormat("WW yyyy");if(a.toFormat("d LLL yyyy")===l)return`${Q.shortTime(a)} today`;if(u===o)if(e>n){const f=parseInt(r.toFormat("d"));return parseInt(a.toFormat("d"))-f===1?`${Q.shortTime(a)} tomorrow`:`${Q.shortTime(a)} ${a.toFormat("cccc")}`}else return`${a.toRelativeCalendar()}`;return d===s?Q.shortTime(a)==="12am"?`${a.toFormat("d LLL")}`:`${Q.shortTime(a)} ${a.toFormat("d LLL")}`:c===i?a.toFormat("cccc d LLL"):a.toFormat("d LLL yyyy")};function lc(e){var h,g;const n=t.reactive({items:[],hash:{},hex:{},loading:!1,loaded:!1,_fullyLoaded:{}});let r=null;const i={};function s(p,y){if(!(!p||!y))for(const k of Object.keys(y))p[k]=y[k]}function o(p){const y={},k={};return p.forEach(function(x){x.key&&(y[x.key]=x),x.hex&&(k[x.hex]=x)}),{hash:y,hex:k}}async function l(p){if(r)return r;if(!(n.loaded&&!p))return r=a(),r}async function a(p){if(!e.auth.getCurrentUser()){u();return}n.loading=!0;try{const{data:k}=await e.api.get("/glossary/index",{cache:!1}),x=k||[],{hash:S,hex:I}=o(x);n._fullyLoaded={},n.items=x,n.hash=S,n.hex=I,n.loaded=!0}catch(k){console.error("GlossaryService: failed to load glossary index",k)}finally{n.loading=!1,r=null}}async function c(p,y){return n._fullyLoaded[p]&&!y?n.hash[p]:(i[p]||(i[p]=d(p)),i[p])}async function d(p,y){try{const{data:k}=await e.api.get(`/glossary/index/${p}`,{cache:!1});if(!k)return;n.hash[p]?s(n.hash[p],k):n.hash[p]=k;const x=n.items.findIndex(function(S){return S.key===p});return x!==-1&&s(n.items[x],k),n._fullyLoaded[p]=!0,n.hash[p]}catch(k){console.error(`GlossaryService: failed to load definition for '${p}'`,k)}finally{delete i[p]}}n.ensure=async function(p){if(!p)return l(!1);if(await l(!1),typeof p=="string")return c(p,!1);if(Array.isArray(p))return Promise.all(p.map(function(y){return c(y,!1)}))},n.reload=async function(p){if(!p)return l(!0);if(await l(!1),typeof p=="string")return c(p,!0);if(Array.isArray(p))return Promise.all(p.map(function(y){return c(y,!0)}))},n.definitionName=function(p,y){const k=n.hash[p];return k?y?k.plural:k.title:p},n.clear=u;function u(){n.items=[],n.hash={},n.hex={},n.loaded=!1,n.loading=!1,n._fullyLoaded={},r=null;for(const p in i)delete i[p]}let m=null;e.auth.addEventListener("change",function(p){var y,k;if(p){const x=(k=(y=p==null?void 0:p.session)==null?void 0:y.organisation)==null?void 0:k._id;m&&x!==m&&u(),m=x||null,l(!1)}else m=null,u()});const f=e.auth.getCurrentUser();return f&&(m=((g=(h=f==null?void 0:f.session)==null?void 0:h.organisation)==null?void 0:g._id)||null,l(!1)),n}const cr={STRIPE_NOT_LOADED:"Stripe v3 library is not loaded",INSTANCE_NOT_DEFINED:"Instance object is not defined. Make sure you initialized Stripe before creating elements",ELEMENTS_NOT_DEFINED:"Elements object is not defined. You can't create stripe element without it",ELEMENT_TYPE_NOT_DEFINED:"elementType is required. You can't create stripe element without it"},zg=(e,n)=>{try{if(!window.Stripe)throw new Error(cr.STRIPE_NOT_LOADED);return window.Stripe(e,n)}catch(r){return console.error(r),r}},Wg=(e,n)=>{try{if(!e)throw new Error(cr.INSTANCE_NOT_DEFINED);return e.elements(n)}catch(r){return console.error(r),r}},Hg=(e,n,r)=>{try{if(!e)throw new Error(cr.ELEMENTS_NOT_DEFINED);if(!n)throw new Error(cr.ELEMENT_TYPE_NOT_DEFINED);return e.create(n,r)}catch(i){return console.error(i),i}};var ac=(e,n)=>{const r=e.__vccOpts||e;for(const[i,s]of n)r[i]=s;return r};const Gg=t.defineComponent({name:"StripeElement",props:{elements:{type:Object,required:!0},type:{type:String,default:()=>"card"},options:{type:Object,default:()=>({})}},setup(e,{emit:n}){const r=t.ref(document.createElement("div")),i=t.ref(),s=t.ref(),{elements:o,type:l,options:a}=t.toRefs(e);return t.onMounted(()=>{const c=()=>{i.value=Hg(o.value,l.value,a.value),i.value.mount(r.value),s.value.appendChild(r.value)},d=(m,f)=>{n(m,f)},u=()=>{["change","ready","focus","blur","click","escape"].forEach(f=>{i.value.on(f,d.bind(null,f))})};try{c(),u()}catch(m){console.error(m)}}),t.onBeforeUnmount(()=>{var c,d;(c=i.value)==null||c.unmount(),(d=i.value)==null||d.destroy()}),t.watch(a,()=>{var c;(c=i.value)==null||c.update(e.options)}),{stripeElement:i,domElement:r,mountPoint:s}}}),Yg={ref:"mountPoint"};function Jg(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",Yg,null,512)}var So=ac(Gg,[["render",Jg]]);const Kg=t.defineComponent({name:"StripeElements",props:{stripeKey:{type:String,required:!0},instanceOptions:{type:Object,default:()=>({})},elementsOptions:{type:Object,default:()=>({})}},setup(e){const{stripeKey:n,instanceOptions:r,elementsOptions:i}=t.toRefs(e),s=t.ref(),o=t.ref(),l=t.computed(()=>o.value?Object.keys(o.value).length>0:!1);return t.onMounted(()=>{s.value=zg(n.value,r.value),o.value=Wg(s.value,i.value)}),t.watch(i,()=>{var a;(a=o.value)==null||a.update(i.value)}),{elements:o,instance:s,elementsUsable:l}}}),Zg={key:0};function Xg(e,n,r,i,s,o){return e.elementsUsable?(t.openBlock(),t.createElementBlock("div",Zg,[t.renderSlot(e.$slots,"default",{instance:e.instance,elements:e.elements})])):t.createCommentVNode("",!0)}var To=ac(Kg,[["render",Xg]]);const w=(e,n)=>{const r=e.__vccOpts||e;for(const[i,s]of n)r[i]=s;return r},Qg={props:{center:{type:Boolean},shrink:{type:Boolean}}};function vg(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["flex-column",{center:r.center,shrink:r.shrink}])},[t.renderSlot(e.$slots,"default",{},void 0,!0)],2)}const cc=w(Qg,[["render",vg],["__scopeId","data-v-b03628f8"]]),ey={},ty={class:"flex-column-body"};function ny(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",ty,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const dc=w(ey,[["render",ny],["__scopeId","data-v-ab49c425"]]),ry={},oy={class:"flex-column-header"};function iy(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",oy,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const uc=w(ry,[["render",iy],["__scopeId","data-v-968bcded"]]),sy={},ly={class:"flex-column-footer"};function ay(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",ly,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const mc=w(sy,[["render",ay],["__scopeId","data-v-941966e2"]]),cy={props:{flex:{type:Boolean},center:{type:Boolean},vcenter:{type:Boolean},alignBottom:{type:Boolean},shrink:{type:Boolean}}};function dy(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["flex-cell",{flex:r.flex,center:r.center,vcenter:r.vcenter,"align-bottom":r.alignBottom,shrink:r.shrink}])},[t.renderSlot(e.$slots,"default",{},void 0,!0)],2)}const fc=w(cy,[["render",dy],["__scopeId","data-v-efd82fd0"]]),uy={props:{center:{type:Boolean},vcenter:{type:Boolean},gap:{type:Boolean},wrap:{type:Boolean}}};function my(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["flex-row",{gap:r.gap,vcenter:r.vcenter,center:r.center,wrap:r.wrap}])},[t.renderSlot(e.$slots,"default",{},void 0,!0)],2)}const hc=w(uy,[["render",my],["__scopeId","data-v-bd96c129"]]),fy={},hy={class:"flex-spacer"};function py(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",hy)}const pc=w(fy,[["render",py],["__scopeId","data-v-f42ac625"]]),gy={},yy={class:"panel"};function ky(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",yy,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const gc=w(gy,[["render",ky],["__scopeId","data-v-dc6d0d19"]]),_y={},wy={class:"panel-body"};function xy(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",wy,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const yc=w(_y,[["render",xy],["__scopeId","data-v-53a6d4be"]]),by={},Cy={class:"panel-header"};function Vy(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",Cy,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const kc=w(by,[["render",Vy],["__scopeId","data-v-3b352542"]]),Ny={},Ey={class:"panel-footer"};function By(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",Ey,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const _c=w(Ny,[["render",By],["__scopeId","data-v-e87fc082"]]);var dr=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ft(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Do,wc;function En(){if(wc)return Do;wc=1;function e(n){var r=typeof n;return n!=null&&(r=="object"||r=="function")}return Do=e,Do}var Oo,xc;function bc(){if(xc)return Oo;xc=1;var e=typeof dr=="object"&&dr&&dr.Object===Object&&dr;return Oo=e,Oo}var Mo,Cc;function on(){if(Cc)return Mo;Cc=1;var e=bc(),n=typeof self=="object"&&self&&self.Object===Object&&self,r=e||n||Function("return this")();return Mo=r,Mo}var Fo,Vc;function Sy(){if(Vc)return Fo;Vc=1;var e=on(),n=function(){return e.Date.now()};return Fo=n,Fo}var Io,Nc;function Ty(){if(Nc)return Io;Nc=1;var e=/\s/;function n(r){for(var i=r.length;i--&&e.test(r.charAt(i)););return i}return Io=n,Io}var Ao,Ec;function Dy(){if(Ec)return Ao;Ec=1;var e=Ty(),n=/^\s+/;function r(i){return i&&i.slice(0,e(i)+1).replace(n,"")}return Ao=r,Ao}var Lo,Bc;function $o(){if(Bc)return Lo;Bc=1;var e=on(),n=e.Symbol;return Lo=n,Lo}var Po,Sc;function Oy(){if(Sc)return Po;Sc=1;var e=$o(),n=Object.prototype,r=n.hasOwnProperty,i=n.toString,s=e?e.toStringTag:void 0;function o(l){var a=r.call(l,s),c=l[s];try{l[s]=void 0;var d=!0}catch{}var u=i.call(l);return d&&(a?l[s]=c:delete l[s]),u}return Po=o,Po}var Ro,Tc;function My(){if(Tc)return Ro;Tc=1;var e=Object.prototype,n=e.toString;function r(i){return n.call(i)}return Ro=r,Ro}var Uo,Dc;function Bn(){if(Dc)return Uo;Dc=1;var e=$o(),n=Oy(),r=My(),i="[object Null]",s="[object Undefined]",o=e?e.toStringTag:void 0;function l(a){return a==null?a===void 0?s:i:o&&o in Object(a)?n(a):r(a)}return Uo=l,Uo}var jo,Oc;function Sn(){if(Oc)return jo;Oc=1;function e(n){return n!=null&&typeof n=="object"}return jo=e,jo}var qo,Mc;function ur(){if(Mc)return qo;Mc=1;var e=Bn(),n=Sn(),r="[object Symbol]";function i(s){return typeof s=="symbol"||n(s)&&e(s)==r}return qo=i,qo}var zo,Fc;function Ic(){if(Fc)return zo;Fc=1;var e=Dy(),n=En(),r=ur(),i=NaN,s=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,l=/^0o[0-7]+$/i,a=parseInt;function c(d){if(typeof d=="number")return d;if(r(d))return i;if(n(d)){var u=typeof d.valueOf=="function"?d.valueOf():d;d=n(u)?u+"":u}if(typeof d!="string")return d===0?d:+d;d=e(d);var m=o.test(d);return m||l.test(d)?a(d.slice(2),m?2:8):s.test(d)?i:+d}return zo=c,zo}var Wo,Ac;function Fy(){if(Ac)return Wo;Ac=1;var e=En(),n=Sy(),r=Ic(),i="Expected a function",s=Math.max,o=Math.min;function l(a,c,d){var u,m,f,h,g,p,y=0,k=!1,x=!1,S=!0;if(typeof a!="function")throw new TypeError(i);c=r(c)||0,e(d)&&(k=!!d.leading,x="maxWait"in d,f=x?s(r(d.maxWait)||0,c):f,S="trailing"in d?!!d.trailing:S);function I(j){var v=u,ae=m;return u=m=void 0,y=j,h=a.apply(ae,v),h}function P(j){return y=j,g=setTimeout(F,c),k?I(j):h}function q(j){var v=j-p,ae=j-y,me=c-v;return x?o(me,f-ae):me}function b(j){var v=j-p,ae=j-y;return p===void 0||v>=c||v<0||x&&ae>=f}function F(){var j=n();if(b(j))return O(j);g=setTimeout(F,q(j))}function O(j){return g=void 0,S&&u?I(j):(u=m=void 0,h)}function U(){g!==void 0&&clearTimeout(g),y=0,u=p=m=g=void 0}function A(){return g===void 0?h:O(n())}function te(){var j=n(),v=b(j);if(u=arguments,m=this,p=j,v){if(g===void 0)return P(p);if(x)return clearTimeout(g),g=setTimeout(F,c),I(p)}return g===void 0&&(g=setTimeout(F,c)),h}return te.cancel=U,te.flush=A,te}return Wo=l,Wo}var Iy=Fy();const Tn=ft(Iy),Ay=["onClick"],Ly=["onClick"],Lc=w({__name:"tabset",props:{vertical:Boolean,inline:Boolean,pills:Boolean,defaultTab:String},setup(e){const n=e,r=t.useSlots(),i=t.reactive({tabs:[]});t.provide("tabset",i);const s=t.ref();t.provide("activeHeading",s);const o=function(u){s.value=u},l=Tn(function(){const m=r.default().reduce(function(g,p){var y;return((y=p.type)==null?void 0:y.name)==="tab"?g.push(p):p.children&&(g=[...g,...p.children]),g},[]).filter(function(g){var p;return((p=g.type)==null?void 0:p.name)==="tab"&&g.props.enabled!==!1}).map(function(g,p){const y=g.props.heading,k=g.props.tabKey||y;return{heading:y,key:k,index:p}});i.tabs=m;const f=m.reduce(function(g,p){return g[p.key||p.heading]=!0,g},{}),h=s.value;if((!h||!f[h])&&m.length){let g;n.defaultTab&&f[n.defaultTab]?g=n.defaultTab:g=m[0].key||m[0].heading,s.value=g}});t.provide("rebuild",l);const a=t.computed(function(){return i.tabs.map(function(u){if(u)return u.heading}).filter(Boolean)}),c=t.computed(function(){return i.tabs.map(function(u){if(u)return u.key}).filter(Boolean)}),d=t.computed(function(){return a.value.length>1});return l(),(u,m)=>{const f=t.resolveComponent("flex-body"),h=t.resolveComponent("flex-column"),g=t.resolveComponent("ux-button"),p=t.resolveComponent("flex-row"),y=t.resolveComponent("flex-header");return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-tabset",{vertical:e.vertical,horizontal:!e.vertical,inline:e.inline,block:!e.inline&&!e.pills,pills:e.pills}])},[e.vertical?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.unref(d)?(t.openBlock(),t.createBlock(h,{key:0,class:"tabset-menu"},{default:t.withCtx(()=>[t.createVNode(f,null,{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(t.unref(c),(k,x)=>(t.openBlock(),t.createElementBlock("a",{class:t.normalizeClass({active:s.value===k}),key:`tab-link-${k}`,onClick:S=>o(k)},t.toDisplayString(t.unref(a)[x]),11,Ay))),128))]),_:1})]),_:1})):t.createCommentVNode("",!0)],64)):e.pills?(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.unref(d)?(t.openBlock(),t.createBlock(y,{key:0,class:"tabset-menu"},{default:t.withCtx(()=>[t.createVNode(p,null,{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(t.unref(c),(k,x)=>(t.openBlock(),t.createBlock(g,{color:s.value===k?"primary":"",key:`tab-pill-${k}`,onClick:S=>o(k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(a)[x]),1)]),_:2},1032,["color","onClick"]))),128))]),_:1})]),_:1})):t.createCommentVNode("",!0)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:2},[t.unref(d)?(t.openBlock(),t.createBlock(y,{key:0,class:"tabset-menu"},{default:t.withCtx(()=>[t.createVNode(p,null,{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(t.unref(c),(k,x)=>(t.openBlock(),t.createElementBlock("a",{class:t.normalizeClass({active:s.value===k}),key:`tab-link-${k}`,onClick:S=>o(k)},t.toDisplayString(t.unref(a)[x]),11,Ly))),128))]),_:1})]),_:1})):t.createCommentVNode("",!0)],64)),t.createVNode(h,null,{default:t.withCtx(()=>[t.renderSlot(u.$slots,"default",{},void 0,!0)]),_:3})],2)}}},[["__scopeId","data-v-781fc138"]]),$y={emits:["mount","unmount"],name:"tab",props:{heading:{type:String,required:!0},tabKey:{type:String},enabled:{type:Boolean,default:!0},keepAlive:{type:Boolean,default:!1}},created(){this.rebuild()},unmounted(){this.rebuild()},watch:{heading(){this.rebuild()}},inject:["tabset","activeHeading","rebuild"],computed:{active(){var r;return String(this.tabKey||this.heading)===String(((r=this.activeHeading)==null?void 0:r.value)||this.activeHeading)}}};function Py(e,n,r,i,s,o){const l=t.resolveComponent("flex-column");return r.keepAlive?t.withDirectives((t.openBlock(),t.createBlock(l,{key:0},{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default")]),_:3},512)),[[t.vShow,o.active]]):o.active?(t.openBlock(),t.createBlock(l,{key:1},{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default")]),_:3})):t.createCommentVNode("",!0)}const $c=w($y,[["render",Py]]);var Ho,Pc;function Dn(){if(Pc)return Ho;Pc=1;var e=Array.isArray;return Ho=e,Ho}var Go,Rc;function Ry(){if(Rc)return Go;Rc=1;var e=Dn(),n=ur(),r=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,i=/^\w*$/;function s(o,l){if(e(o))return!1;var a=typeof o;return a=="number"||a=="symbol"||a=="boolean"||o==null||n(o)?!0:i.test(o)||!r.test(o)||l!=null&&o in Object(l)}return Go=s,Go}var Yo,Uc;function jc(){if(Uc)return Yo;Uc=1;var e=Bn(),n=En(),r="[object AsyncFunction]",i="[object Function]",s="[object GeneratorFunction]",o="[object Proxy]";function l(a){if(!n(a))return!1;var c=e(a);return c==i||c==s||c==r||c==o}return Yo=l,Yo}var Jo,qc;function Uy(){if(qc)return Jo;qc=1;var e=on(),n=e["__core-js_shared__"];return Jo=n,Jo}var Ko,zc;function jy(){if(zc)return Ko;zc=1;var e=Uy(),n=function(){var i=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return i?"Symbol(src)_1."+i:""}();function r(i){return!!n&&n in i}return Ko=r,Ko}var Zo,Wc;function qy(){if(Wc)return Zo;Wc=1;var e=Function.prototype,n=e.toString;function r(i){if(i!=null){try{return n.call(i)}catch{}try{return i+""}catch{}}return""}return Zo=r,Zo}var Xo,Hc;function zy(){if(Hc)return Xo;Hc=1;var e=jc(),n=jy(),r=En(),i=qy(),s=/[\\^$.*+?()[\]{}|]/g,o=/^\[object .+?Constructor\]$/,l=Function.prototype,a=Object.prototype,c=l.toString,d=a.hasOwnProperty,u=RegExp("^"+c.call(d).replace(s,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function m(f){if(!r(f)||n(f))return!1;var h=e(f)?u:o;return h.test(i(f))}return Xo=m,Xo}var Qo,Gc;function Wy(){if(Gc)return Qo;Gc=1;function e(n,r){return n==null?void 0:n[r]}return Qo=e,Qo}var vo,Yc;function ei(){if(Yc)return vo;Yc=1;var e=zy(),n=Wy();function r(i,s){var o=n(i,s);return e(o)?o:void 0}return vo=r,vo}var ti,Jc;function mr(){if(Jc)return ti;Jc=1;var e=ei(),n=e(Object,"create");return ti=n,ti}var ni,Kc;function Hy(){if(Kc)return ni;Kc=1;var e=mr();function n(){this.__data__=e?e(null):{},this.size=0}return ni=n,ni}var ri,Zc;function Gy(){if(Zc)return ri;Zc=1;function e(n){var r=this.has(n)&&delete this.__data__[n];return this.size-=r?1:0,r}return ri=e,ri}var oi,Xc;function Yy(){if(Xc)return oi;Xc=1;var e=mr(),n="__lodash_hash_undefined__",r=Object.prototype,i=r.hasOwnProperty;function s(o){var l=this.__data__;if(e){var a=l[o];return a===n?void 0:a}return i.call(l,o)?l[o]:void 0}return oi=s,oi}var ii,Qc;function Jy(){if(Qc)return ii;Qc=1;var e=mr(),n=Object.prototype,r=n.hasOwnProperty;function i(s){var o=this.__data__;return e?o[s]!==void 0:r.call(o,s)}return ii=i,ii}var si,vc;function Ky(){if(vc)return si;vc=1;var e=mr(),n="__lodash_hash_undefined__";function r(i,s){var o=this.__data__;return this.size+=this.has(i)?0:1,o[i]=e&&s===void 0?n:s,this}return si=r,si}var li,ed;function Zy(){if(ed)return li;ed=1;var e=Hy(),n=Gy(),r=Yy(),i=Jy(),s=Ky();function o(l){var a=-1,c=l==null?0:l.length;for(this.clear();++a<c;){var d=l[a];this.set(d[0],d[1])}}return o.prototype.clear=e,o.prototype.delete=n,o.prototype.get=r,o.prototype.has=i,o.prototype.set=s,li=o,li}var ai,td;function Xy(){if(td)return ai;td=1;function e(){this.__data__=[],this.size=0}return ai=e,ai}var ci,nd;function rd(){if(nd)return ci;nd=1;function e(n,r){return n===r||n!==n&&r!==r}return ci=e,ci}var di,od;function fr(){if(od)return di;od=1;var e=rd();function n(r,i){for(var s=r.length;s--;)if(e(r[s][0],i))return s;return-1}return di=n,di}var ui,id;function Qy(){if(id)return ui;id=1;var e=fr(),n=Array.prototype,r=n.splice;function i(s){var o=this.__data__,l=e(o,s);if(l<0)return!1;var a=o.length-1;return l==a?o.pop():r.call(o,l,1),--this.size,!0}return ui=i,ui}var mi,sd;function vy(){if(sd)return mi;sd=1;var e=fr();function n(r){var i=this.__data__,s=e(i,r);return s<0?void 0:i[s][1]}return mi=n,mi}var fi,ld;function ek(){if(ld)return fi;ld=1;var e=fr();function n(r){return e(this.__data__,r)>-1}return fi=n,fi}var hi,ad;function tk(){if(ad)return hi;ad=1;var e=fr();function n(r,i){var s=this.__data__,o=e(s,r);return o<0?(++this.size,s.push([r,i])):s[o][1]=i,this}return hi=n,hi}var pi,cd;function nk(){if(cd)return pi;cd=1;var e=Xy(),n=Qy(),r=vy(),i=ek(),s=tk();function o(l){var a=-1,c=l==null?0:l.length;for(this.clear();++a<c;){var d=l[a];this.set(d[0],d[1])}}return o.prototype.clear=e,o.prototype.delete=n,o.prototype.get=r,o.prototype.has=i,o.prototype.set=s,pi=o,pi}var gi,dd;function rk(){if(dd)return gi;dd=1;var e=ei(),n=on(),r=e(n,"Map");return gi=r,gi}var yi,ud;function ok(){if(ud)return yi;ud=1;var e=Zy(),n=nk(),r=rk();function i(){this.size=0,this.__data__={hash:new e,map:new(r||n),string:new e}}return yi=i,yi}var ki,md;function ik(){if(md)return ki;md=1;function e(n){var r=typeof n;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?n!=="__proto__":n===null}return ki=e,ki}var _i,fd;function hr(){if(fd)return _i;fd=1;var e=ik();function n(r,i){var s=r.__data__;return e(i)?s[typeof i=="string"?"string":"hash"]:s.map}return _i=n,_i}var wi,hd;function sk(){if(hd)return wi;hd=1;var e=hr();function n(r){var i=e(this,r).delete(r);return this.size-=i?1:0,i}return wi=n,wi}var xi,pd;function lk(){if(pd)return xi;pd=1;var e=hr();function n(r){return e(this,r).get(r)}return xi=n,xi}var bi,gd;function ak(){if(gd)return bi;gd=1;var e=hr();function n(r){return e(this,r).has(r)}return bi=n,bi}var Ci,yd;function ck(){if(yd)return Ci;yd=1;var e=hr();function n(r,i){var s=e(this,r),o=s.size;return s.set(r,i),this.size+=s.size==o?0:1,this}return Ci=n,Ci}var Vi,kd;function _d(){if(kd)return Vi;kd=1;var e=ok(),n=sk(),r=lk(),i=ak(),s=ck();function o(l){var a=-1,c=l==null?0:l.length;for(this.clear();++a<c;){var d=l[a];this.set(d[0],d[1])}}return o.prototype.clear=e,o.prototype.delete=n,o.prototype.get=r,o.prototype.has=i,o.prototype.set=s,Vi=o,Vi}var Ni,wd;function dk(){if(wd)return Ni;wd=1;var e=_d(),n="Expected a function";function r(i,s){if(typeof i!="function"||s!=null&&typeof s!="function")throw new TypeError(n);var o=function(){var l=arguments,a=s?s.apply(this,l):l[0],c=o.cache;if(c.has(a))return c.get(a);var d=i.apply(this,l);return o.cache=c.set(a,d)||c,d};return o.cache=new(r.Cache||e),o}return r.Cache=e,Ni=r,Ni}var Ei,xd;function uk(){if(xd)return Ei;xd=1;var e=dk(),n=500;function r(i){var s=e(i,function(l){return o.size===n&&o.clear(),l}),o=s.cache;return s}return Ei=r,Ei}var Bi,bd;function mk(){if(bd)return Bi;bd=1;var e=uk(),n=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,r=/\\(\\)?/g,i=e(function(s){var o=[];return s.charCodeAt(0)===46&&o.push(""),s.replace(n,function(l,a,c,d){o.push(c?d.replace(r,"$1"):a||l)}),o});return Bi=i,Bi}var Si,Cd;function Vd(){if(Cd)return Si;Cd=1;function e(n,r){for(var i=-1,s=n==null?0:n.length,o=Array(s);++i<s;)o[i]=r(n[i],i,n);return o}return Si=e,Si}var Ti,Nd;function fk(){if(Nd)return Ti;Nd=1;var e=$o(),n=Vd(),r=Dn(),i=ur(),s=e?e.prototype:void 0,o=s?s.toString:void 0;function l(a){if(typeof a=="string")return a;if(r(a))return n(a,l)+"";if(i(a))return o?o.call(a):"";var c=a+"";return c=="0"&&1/a==-1/0?"-0":c}return Ti=l,Ti}var Di,Ed;function Oi(){if(Ed)return Di;Ed=1;var e=fk();function n(r){return r==null?"":e(r)}return Di=n,Di}var Mi,Bd;function hk(){if(Bd)return Mi;Bd=1;var e=Dn(),n=Ry(),r=mk(),i=Oi();function s(o,l){return e(o)?o:n(o,l)?[o]:r(i(o))}return Mi=s,Mi}var Fi,Sd;function pk(){if(Sd)return Fi;Sd=1;var e=ur();function n(r){if(typeof r=="string"||e(r))return r;var i=r+"";return i=="0"&&1/r==-1/0?"-0":i}return Fi=n,Fi}var Ii,Td;function gk(){if(Td)return Ii;Td=1;var e=hk(),n=pk();function r(i,s){s=e(s,i);for(var o=0,l=s.length;i!=null&&o<l;)i=i[n(s[o++])];return o&&o==l?i:void 0}return Ii=r,Ii}var Ai,Dd;function yk(){if(Dd)return Ai;Dd=1;var e=gk();function n(r,i,s){var o=r==null?void 0:e(r,i);return o===void 0?s:o}return Ai=n,Ai}var kk=yk();const ht=ft(kk),le={props:{column:{type:Object,required:!0},row:{type:Object,required:!0},value:{}}},_k={mixins:[le],data(){return{processing:!1}},methods:{async clicked(){const e=this,n=(e.tags||[]).slice(),r=await e.$sdk.tag({title:"Edit tags",description:e.row.title,model:n.slice()}),i=e.$sdk.utils.ids(n),s=e.$sdk.utils.ids(r);JSON.stringify(i.sort())===JSON.stringify(s.sort())||(e.processing=!0,await e.$sdk.content.patch(this.itemID,{meta:{tags:r}}),e.row.meta.tags=r,e.processing=!1,e.$sdk.notify("Tags were updated"))}},computed:{canEditItem(){return this.$sdk.access.canEditItem(this.user,this.row)},itemID(){return this.row._id},tags(){var r;return((r=this.row.meta)==null?void 0:r.tags)||[]}}},wk={class:"table-quicktag-cell"};function xk(e,n,r,i,s,o){const l=t.resolveComponent("ux-pill"),a=t.resolveComponent("flex-cell"),c=t.resolveComponent("flex-row"),d=t.resolveComponent("ux-icon"),u=t.resolveComponent("ux-button");return t.openBlock(),t.createElementBlock("td",wk,[t.createVNode(c,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(a,null,{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.tags,m=>(t.openBlock(),t.createBlock(l,{icon:"fa-tag",tag:"a",value:m},null,8,["value"]))),256))]),_:1})]),_:1}),o.canEditItem?(t.openBlock(),t.createElementBlock("div",{key:0,class:"clicker",onClick:n[0]||(n[0]=t.withModifiers((...m)=>o.clicked&&o.clicked(...m),["stop","prevent"]))},[t.createVNode(c,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(a),t.createVNode(a,{shrink:""},{default:t.withCtx(()=>[t.createVNode(u,{icon:"",size:"xs"},{default:t.withCtx(()=>[t.createVNode(d,{icon:"fa-pen-to-square"})]),_:1})]),_:1})]),_:1})])):t.createCommentVNode("",!0)])}const bk=w(_k,[["render",xk],["__scopeId","data-v-d98dce09"]]),Ck={mixins:[le],computed:{initials(){var e,n;return`${((e=this.row)==null?void 0:e.firstName)||""} ${((n=this.row)==null?void 0:n.lastName)||""}`.trim()||this.row.title},source(){return this.$sdk.utils.id(this.value)||this.$sdk.utils.id(this.row)}}},Vk={class:"table-avatar-cell"},Nk={class:"avatar-wrapper"};function Ek(e,n,r,i,s,o){const l=t.resolveComponent("avatar",!0);return t.openBlock(),t.createElementBlock("td",Vk,[t.createElementVNode("div",Nk,[t.createVNode(l,{id:o.source,initials:o.initials},null,8,["id","initials"])])])}const Bk=w(Ck,[["render",Ek],["__scopeId","data-v-a4b42e00"]]),Sk={mixins:[le],computed:{formatted(){return this.$sdk.date.readableTime(this.value)}}},Tk={class:"table-time-cell"};function Dk(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("td",Tk,[t.createVNode(l,{icon:"far fa-clock"}),t.createTextVNode(" "+t.toDisplayString(o.formatted),1)])}const Ok=w(Sk,[["render",Dk],["__scopeId","data-v-677f555b"]]),Mk={mixins:[le],computed:{key(){return this.column.key},rawSource(){return ht(this.row,this.key)},source(){return Array.isArray(this.rawSource)?this.rawSource[0]:this.rawSource?this.rawSource:this.row},imageSource(){var r;const e=this.source;if(e)switch((r=e==null?void 0:e.meta)==null?void 0:r.type){case"video":case"image":case"event":case"persona":case"profile":case"audio":case"file":return this.source;default:{const i=this.$sdk.utils.id(this.source);if(!i)return;var n=i.slice(8,10);switch(n){case"69":return{_id:i,meta:{type:"image"}};case"76":return{_id:i,meta:{type:"video"}};case"24":return{_id:i,meta:{type:"persona"}};case"70":return{_id:i,meta:{type:"profile"}};case"71":return{_id:i,meta:{type:"checkin"}}}return i}}},type(){var e,n;return(n=(e=this.imageSource)==null?void 0:e.meta)==null?void 0:n.type}},methods:{clicked(e){this.$sdk.dispatch("item:view",this.imageSource)}}},Fk={class:"table-image-cell"};function Ik(e,n,r,i,s,o){const l=t.resolveComponent("ux-image"),a=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("td",Fk,[o.imageSource?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[o.type=="image"||o.type=="video"?(t.openBlock(),t.createElementBlock("div",{key:0,onClick:n[0]||(n[0]=t.withModifiers(c=>o.clicked(e.value),["stop","prevent"])),class:"image-wrapper"},[t.createVNode(l,{lazy:"",item:o.imageSource,type:o.type,width:100,height:100},null,8,["item","type"])])):o.type==="audio"?(t.openBlock(),t.createBlock(a,{key:1,icon:"fa-music"})):o.type==="file"?(t.openBlock(),t.createBlock(a,{key:2,icon:"fa-file"})):(t.openBlock(),t.createElementBlock("div",{key:3,onClick:n[1]||(n[1]=t.withModifiers(c=>o.clicked(e.value),["stop","prevent"])),class:"image-wrapper"},[t.createVNode(l,{lazy:"",item:o.imageSource,type:o.type,width:100,height:100},null,8,["item","type"])]))],64)):t.createCommentVNode("",!0)])}const Ak=w(Mk,[["render",Ik],["__scopeId","data-v-0d557d14"]]),Lk={mixins:[le],computed:{string(){return isNaN(this.amount)?"0.00":this.amount.toFixed(2)},amount(){return Number(parseInt(this.value)/100)},credit(){return this.amount>0},debit(){return this.amount<0},invalid(){var e;return((e=this.column)==null?void 0:e.key)==="amount"&&this.adjusted},adjusted(){return this.row.effectiveAmount!==this.row.amount},empty(){return parseInt(this.value)===0},currency(){return this.column.currency||this.row.currency}}};function $k(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-currency-cell",{credit:o.credit,empty:o.empty,debit:o.debit,invalid:o.invalid,adjusted:o.adjusted}])},t.toDisplayString(o.string),3)}const Pk=w(Lk,[["render",$k],["__scopeId","data-v-c62e82ec"]]),Rk={data(){return{processing:!1}},mixins:[le],computed:{visible(){return!this.hidden},enabled(){const e=this;switch(typeof e.button.enabled){case"function":return e.button.enabled(e.row,e.column);case"undefined":case"null":return!0;default:return e.button.enabled}},hidden(){const e=this;switch(typeof e.button.hidden){case"function":return!!e.button.hidden(e.row,e.column);case"undefined":case"null":return!1;default:return!!e.button.hidden}},button(){return this.column.button},type(){var e,n;return(n=(e=this.row)==null?void 0:e.meta)==null?void 0:n.type},label(){const e=this.button;return typeof e.text=="function"?e.text(this):e.text}},methods:{async clicked(){this.processing=!0,await this.button.action(this.row,this.column,this),this.processing=!1}}},Uk={class:"table-button-cell"};function jk(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon"),a=t.resolveComponent("ux-button");return t.openBlock(),t.createElementBlock("td",Uk,[o.visible?(t.openBlock(),t.createBlock(a,{key:0,block:o.button.block,color:o.button.color,size:o.button.size,loading:s.processing,disabled:!o.enabled,onClick:t.withModifiers(o.clicked,["stop","prevent"])},{default:t.withCtx(()=>[o.label?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createTextVNode(t.toDisplayString(o.label),1)],64)):t.createCommentVNode("",!0),o.button.icon?(t.openBlock(),t.createBlock(l,{key:1,icon:o.button.icon,right:""},null,8,["icon"])):t.createCommentVNode("",!0)]),_:1},8,["block","color","size","loading","disabled","onClick"])):t.createCommentVNode("",!0)])}const qk=w(Rk,[["render",jk],["__scopeId","data-v-413157fd"]]),zk={mixins:[le],methods:{timeago(e){return _.fromJSDate(e).toRelative()},readable(e){e=_.fromJSDate(e);let n=_.now(),r=n.toFormat("yyyy");return n.toFormat("MMM yyyy"),e.toFormat("yyyy")===r?e.toFormat("h:mma, ccc d MMM").replace(/:00/g,"").replace(/PM,/g,"pm,").replace(/:AM,/g,"am,"):e.toFormat("h:mma, ccc d MMM yyyy").replace(/:00/g,"").replace(/:PM,/g,"pm,").replace(/:AM,/g,"am,")}},computed:{values(){return Array.isArray(this.value)?this.value:[this.value]},mapped(){const e=this;return e.values.map(function(n){if(!n)return;const r=new Date(n);return{readable:e.readable(r),timeago:e.timeago(r)}}).filter(Boolean)}}},Wk={class:"table-date-cell"},Hk={class:"date-pill"},Gk={class:"off"},Yk={class:"on"},Jk={class:"spacer"};function Kk(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",Wk,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.mapped,l=>(t.openBlock(),t.createElementBlock("div",Hk,[t.createElementVNode("span",Gk,t.toDisplayString(l.readable),1),t.createElementVNode("span",Yk,t.toDisplayString(l.timeago),1),t.createElementVNode("span",Jk,t.toDisplayString(l.readable),1)]))),256))])}const Od=w(zk,[["render",Kk],["__scopeId","data-v-7ddc957f"]]),Zk={mixins:[le],methods:{timeago(e){return _.fromJSDate(e).toRelative()},readable(e){e=_.fromJSDate(e);let n=_.now(),r=n.toFormat("yyyy");return n.toFormat("MMM yyyy"),e.toFormat("yyyy")===r?e.toFormat("h:mm a - dd MMM"):e.toFormat("h:mm a - dd MMM yyyy")}},computed:{values(){return Array.isArray(this.value)?this.value:[this.value]},mapped(){const e=this;return e.values.map(function(n){if(!n)return;const r=new Date(n),i=r<new Date;return{readable:e.readable(r),timeago:e.timeago(r),overdue:i}}).filter(Boolean)}}},Xk={class:"table-date-cell"},Qk={class:"off"},vk={class:"on"},e_={class:"spacer"};function t_(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("td",Xk,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.mapped,a=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["date-pill",{overdue:a.overdue}])},[t.createElementVNode("span",Qk,[t.createVNode(l,{icon:"far fa-clock",left:""}),t.createTextVNode(t.toDisplayString(a.readable),1)]),t.createElementVNode("span",vk,[t.createVNode(l,{icon:"far fa-clock",left:""}),t.createTextVNode(t.toDisplayString(a.timeago),1)]),t.createElementVNode("span",e_,[t.createVNode(l,{icon:"far fa-clock",left:""}),t.createTextVNode(t.toDisplayString(a.readable),1)])],2))),256))])}const n_=w(Zk,[["render",t_],["__scopeId","data-v-0e48d460"]]),r_={mixins:[le],computed:{boolean(){return!!this.value}}};function o_(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-boolean-cell",{true:o.boolean,false:!o.boolean}])},[t.createVNode(l,{icon:o.boolean?"fa-check":"fa-times"},null,8,["icon"])],2)}const Md=w(r_,[["render",o_],["__scopeId","data-v-b180904a"]]),i_={mixins:[le],computed:{size(){return this.$sdk.files.filesize(this.value)}}};function s_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-filesize-cell",{true:e.boolean,false:!e.boolean}])},t.toDisplayString(o.size),3)}const l_=w(i_,[["render",s_],["__scopeId","data-v-0419990c"]]);function a_(e){const n=Math.round(e),r=Math.floor(n/3600),i=Math.floor(n%3600/60),s=n%60;return r>0?`${r}:${i.toString().padStart(2,"0")}:${s.toString().padStart(2,"0")}`:`${i}:${s.toString().padStart(2,"0")}`}const c_={mixins:[le],computed:{duration(){return a_(this.value)}}};function d_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-duration-cell",{true:e.boolean,false:!e.boolean}])},t.toDisplayString(o.duration),3)}const u_=w(c_,[["render",d_],["__scopeId","data-v-2910d792"]]),m_={mixins:[le],methods:{async clicked(){const e=this,n=e.$sdk.utils.id(e.row),r=e.public?"secure":"public";e.processing=!0,e.$sdk.content.patch(n,{meta:{security:r}}).catch(function(i){e.$sdk.error(i),e.processing=!1}).then(function(i){e.v=r,e.processing=!1,e.$sdk.notify(`Set security to ${r}`)})}},data(){return{processing:!1,v:this.value}},computed:{canEdit(){var e=this.user;return this.$sdk.access.canEditItem(e,this.row)},public(){return this.security==="public"},security(){return this.v||"secure"}}};function f_(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon"),a=t.resolveComponent("ux-button");return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-security-cell",o.security])},[o.canEdit?(t.openBlock(),t.createBlock(a,{key:0,size:"sm",loading:s.processing,onClick:t.withModifiers(o.clicked,["stop","prevent"])},{default:t.withCtx(()=>[t.createVNode(l,{icon:o.public?"fa-lock-open":"fa-lock"},null,8,["icon"])]),_:1},8,["loading","onClick"])):(t.openBlock(),t.createBlock(l,{key:1,icon:o.public?"fa-lock-open":"fa-lock"},null,8,["icon"]))],2)}const h_=w(m_,[["render",f_],["__scopeId","data-v-45dd2b07"]]),p_={mixins:[le],methods:{open(){window.open(this.href)}},computed:{actualValue(){return String(this.value||"").trim()},href(){let e=this.actualValue;return/^https?:\/\//i.test(e)?e:"https://"+e}}},g_={class:"table-url-cell"},y_=["href"];function k_(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("td",g_,[o.actualValue?(t.openBlock(),t.createElementBlock("a",{key:0,href:o.href,onClick:n[0]||(n[0]=t.withModifiers((...a)=>o.open&&o.open(...a),["stop","prevent"])),target:"_blank"},[t.createTextVNode(t.toDisplayString(o.actualValue)+" ",1),t.createVNode(l,{right:"",icon:"fa-external-link"})],8,y_)):t.createCommentVNode("",!0)])}const Fd=w(p_,[["render",k_],["__scopeId","data-v-aa99a5e7"]]);var Id=function(e,n,r){if(!n.hasOwnProperty(r)){var i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,i)}};const Ad={props:{template:String,parent:Object,templateProps:{type:Object,default:function(){return{}}}},render:function(){if(this.template){var e=this.parent||this.$parent,n=e.$data;n===void 0&&(n={});var r=e.$props;r===void 0&&(r={});var i=e.$options;i===void 0&&(i={});var s=i.components;s===void 0&&(s={});var o=i.computed;o===void 0&&(o={});var l=i.methods;l===void 0&&(l={});var a=this.$data;a===void 0&&(a={});var c=this.$props;c===void 0&&(c={});var d=this.$options;d===void 0&&(d={});var u=d.methods;u===void 0&&(u={});var m=d.computed;m===void 0&&(m={});var f=d.components;f===void 0&&(f={});var h={$data:{},$props:{},$options:{},components:{},computed:{},methods:{}};Object.keys(n).forEach(function(b){a[b]===void 0&&(h.$data[b]=n[b])}),Object.keys(r).forEach(function(b){c[b]===void 0&&(h.$props[b]=r[b])}),Object.keys(l).forEach(function(b){u[b]===void 0&&(h.methods[b]=l[b])}),Object.keys(o).forEach(function(b){m[b]===void 0&&(h.computed[b]=o[b])}),Object.keys(s).forEach(function(b){f[b]===void 0&&(h.components[b]=s[b])});var g=Object.keys(h.methods||{}),p=Object.keys(h.$data||{}),y=Object.keys(h.$props||{}),k=Object.keys(this.templateProps),x=p.concat(y).concat(g).concat(k),S=(P=e,q={},g.forEach(function(b){return Id(P,q,b)}),q),I=function(b){var F={};return b.forEach(function(O){O&&Object.getOwnPropertyNames(O).forEach(function(U){return Id(O,F,U)})}),F}([h.$data,h.$props,S,this.templateProps]);return t.h({template:this.template||"<div></div>",props:x,computed:h.computed,components:h.components,provide:this.$parent.$.provides?this.$parent.$.provides:{}},Object.assign({},I))}var P,q}},__={components:{Compile:Ad},mixins:[le]},w_={class:"table-computed-cell"};function x_(e,n,r,i,s,o){const l=t.resolveComponent("compile");return t.openBlock(),t.createElementBlock("td",w_,[t.createVNode(l,{template:this.column.code},null,8,["template"])])}const b_=w(__,[["render",x_],["__scopeId","data-v-05dd3203"]]),C_={props:{multi:{type:Boolean},last:{type:Boolean},value:{required:!0},type:{type:String},widget:{type:String}},computed:{reference(){return!!(this.value&&this.value._id)},renderValue(){return this.value?this.value.title||this.value.name||this.value:void 0},date(){return _.fromISO(this.value).toFormat("dd MMM yyyy")},actualWidget(){var e;if(this.widget)e=this.widget;else switch(this.type){case"date":e="datetime";break}return e}},methods:{clicked(e){this.$sdk.dispatch("item:view",e)}}};function V_(e,n,r,i,s,o){const l=t.resolveComponent("ux-pill");return o.reference?(t.openBlock(),t.createBlock(l,{key:0,tag:"a",value:r.value,onClick:n[0]||(n[0]=t.withModifiers(a=>o.clicked(r.value),["stop","prevent"]))},null,8,["value"])):r.type=="date"?(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createTextVNode(t.toDisplayString(o.date),1)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:2},[t.createTextVNode(t.toDisplayString(o.renderValue),1),r.multi&&!r.last?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createTextVNode(", ")],64)):t.createCommentVNode("",!0)],64))}const N_=w(C_,[["render",V_],["__scopeId","data-v-27442ac9"]]),E_=".total",B_={mixins:[le],methods:{clicked(e){this.menuOpen=!1,this.$sdk.dispatch("item:view",e)}},data(){return{menuOpen:!1}},computed:{path(){return this.column.key||""},rawPath(){return this.path.slice(0,-E_.length)},itemPath(){return`${this.rawPath}.items`},value(){return ht(this.row,this.column.key)},items(){return ht(this.row,this.itemPath)}}},S_={class:"table-complex-cell"},T_={class:"items"};function D_(e,n,r,i,s,o){const l=t.resolveComponent("ux-button"),a=t.resolveComponent("ux-pill"),c=t.resolveComponent("ux-menu");return t.openBlock(),t.createElementBlock("td",S_,[t.createVNode(c,{modelValue:s.menuOpen,"onUpdate:modelValue":n[1]||(n[1]=d=>s.menuOpen=d)},{activator:t.withCtx(({on:d})=>[t.createVNode(l,t.mergeProps({size:"sm",onClick:n[0]||(n[0]=t.withModifiers(()=>{},["stop","prevent"]))},t.toHandlers(d),{icon:""}),{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.value),1)]),_:2},1040)]),default:t.withCtx(()=>[t.createElementVNode("div",T_,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.items,d=>(t.openBlock(),t.createBlock(a,{tag:"a",value:d,onClick:t.withModifiers(u=>o.clicked(d),["stop","prevent"])},null,8,["value","onClick"]))),256))])]),_:1},8,["modelValue"])])}const O_=w(B_,[["render",D_],["__scopeId","data-v-1cdab26c"]]),M_={mixins:[le],computed:{email(){var e;return this.row.username||((e=this.row.user)==null?void 0:e.email)||this.row.userEmailAddress||this.row.collectionEmailAddress}}},F_={class:"table-persona-email-cell"};function I_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",F_,t.toDisplayString(o.email),1)}const A_=w(M_,[["render",I_],["__scopeId","data-v-9c894a39"]]),L_={mixins:[le],computed:{className(){return this.isConnected?"connected":this.isInvited?"invited":this.isManaged?"managed":"empty"},isConnected(){return!!this.row.user},isInvited(){return!this.isConnected&&this.row.collectionEmailAddress},isManaged(){return!this.isConnected&&!this.isInvited},email(){var e;return this.row.username||((e=this.row.user)==null?void 0:e.email)||this.row.userEmailAddress||this.row.collectionEmailAddress},text(){switch(this.className){case"connected":return"Qik User";case"invited":return"Invite sent";case"managed":return"App user";default:return""}},tooltip(){var r,i,s,o;const e=this,n=(i=(r=e.user)==null?void 0:r.organisation)!=null&&i.title?`'${(o=(s=e.user)==null?void 0:s.organisation)==null?void 0:o.title}'`:void 0;switch(e.className){case"connected":return`This user can sign in to ${n||"your organisation"} on the Qik platform.`;case"invited":return"We've sent an invite to this user to join your organisation on Qik.";case"managed":return"This user can only sign in to your applications.";default:return""}},icon(){switch(this.className){case"connected":return"far fa-user";case"invited":return"far fa-envelope";case"managed":return"far fa-user";default:return}}}},$_={class:"pill"};function P_(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon"),a=t.resolveComponent("tippy");return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-persona-invite-cell",o.className])},[t.createVNode(a,{content:o.tooltip},{default:t.withCtx(()=>[t.createElementVNode("div",$_,[t.createVNode(l,{icon:o.icon,left:""},null,8,["icon"]),t.createTextVNode(" "+t.toDisplayString(o.text),1)])]),_:1},8,["content"])],2)}const R_=w(L_,[["render",P_],["__scopeId","data-v-be3bef4b"]]),U_={mixins:[le],computed:{status(){return String(this.value||"").toLowerCase()}}},j_={key:0,class:"pill"};function q_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-status-cell",o.status])},[o.status?(t.openBlock(),t.createElementBlock("div",j_,t.toDisplayString(o.status),1)):t.createCommentVNode("",!0)],2)}const z_=w(U_,[["render",q_],["__scopeId","data-v-357810c2"]]),W_={mixins:[le],computed:{typeKey(){var e;return(e=this.row.meta)==null?void 0:e.type},subtitle(){var l,a,c,d,u,m,f;const e=this,n=this.row,r=n.subtitle,i=n.description,s=(l=n.meta)==null?void 0:l.description,o=r||i||s;switch(this.typeKey){case"runsheet":return n.event?`${n.event.title} • ${e.$sdk.date.readableEventDate(n.event)}`:"";case"venue":return[(a=n.address)==null?void 0:a.addressLine1,(c=n.address)==null?void 0:c.addressLine2,(d=n.address)==null?void 0:d.suburb,(u=n.address)==null?void 0:u.state,(m=n.address)==null?void 0:m.postalCode,(f=n.address)==null?void 0:f.country].filter(Boolean).join(" ");case"event":if(n.startDate,n.endDate,e.$sdk.date)return o?`${e.$sdk.date.readableEventDate(n)} • ${o}`:`${e.$sdk.date.readableEventDate(n)}`;break}return o}}},H_={class:"title"},G_={key:0,class:"subtitle"};function Y_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",{class:t.normalizeClass(["table-title-cell",e.status])},[t.createElementVNode("div",H_,t.toDisplayString(e.value),1),o.subtitle?(t.openBlock(),t.createElementBlock("div",G_,t.toDisplayString(o.subtitle),1)):t.createCommentVNode("",!0)],2)}const J_=w(W_,[["render",Y_],["__scopeId","data-v-bf723bb2"]]),K_={props:{value:{type:Object}},computed:{style(){var r,i;const e=(r=this.value)==null?void 0:r.color,n=(i=this.value)==null?void 0:i.bgColor;if(e||n)return{backgroundColor:n||e}}}};function Z_(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("span",{class:"ux-circle",style:t.normalizeStyle(o.style)},null,4)}const pr=w(K_,[["render",Z_],["__scopeId","data-v-6f2d4cea"]]),X_={mixins:[le],components:{UxCircle:pr},computed:{scopes(){return this.column.key==="_id"?[this.row]:(this.value||[]).filter(function({unit:n}){return!n})}}},Q_={class:"scope-circles-cell"};function v_(e,n,r,i,s,o){const l=t.resolveComponent("ux-circle"),a=t.resolveComponent("tippy");return t.openBlock(),t.createElementBlock("td",Q_,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.scopes,c=>(t.openBlock(),t.createBlock(a,{content:c.title},{default:t.withCtx(()=>[t.createVNode(l,{value:c},null,8,["value"])]),_:2},1032,["content"]))),256))])}const ew=w(X_,[["render",v_],["__scopeId","data-v-f79f00ee"]]),tw={mixins:[le],created(){this.$glossary.ensure()},computed:{glossary(){return this.$glossary.hash},match(){return this.glossary?this.glossary[this.value]:null},title(){var e;return((e=this.match)==null?void 0:e.title)||this.value}}},nw={class:"content-type-cell"};function rw(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("td",nw,t.toDisplayString(o.title),1)}const ow=w(tw,[["render",rw],["__scopeId","data-v-26ccbfe4"]]),iw={mixins:[le],computed:{count(){return this.rosters.reduce(function(e,n){return n.slots.forEach(function(r){e+=r.assignments.length}),e},0)},rosters(){return Object.entries(this.row.join_roster||{}).map(function([n,r]){return{title:n,slots:r.items}})},rosterEnabled(){return this.$sdk.access.hasFeature(this.user,"rostering")?this.$sdk.access.canKnowOf(this.user,"roster")||this.$sdk.access.canKnowOf(this.user,"assignment"):void 0}}},sw={class:"table-roster-cell"},lw={class:"event-title"},aw={class:"event-date"},cw={class:"event-subtitle"},dw={class:"preview"},uw={class:"grid"},mw={class:"face"};function fw(e,n,r,i,s,o){const l=t.resolveComponent("ux-button"),a=t.resolveComponent("ux-panel-header"),c=t.resolveComponent("ux-avatar"),d=t.resolveComponent("flex-cell"),u=t.resolveComponent("flex-row"),m=t.resolveComponent("ux-panel-body"),f=t.resolveComponent("ux-panel"),h=t.resolveComponent("ux-menu");return t.openBlock(),t.createElementBlock("td",sw,[o.rosterEnabled&&o.count?(t.openBlock(),t.createBlock(h,{key:0,right:"",group:"roster-preview"},{activator:t.withCtx(({on:g})=>[t.createVNode(l,t.mergeProps({size:"sm"},t.toHandlers(g),{icon:"",onClick:n[0]||(n[0]=t.withModifiers(()=>{},["stop"]))}),{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.count),1)]),_:2},1040)]),default:t.withCtx(()=>[t.createVNode(f,null,{default:t.withCtx(()=>[t.createVNode(a,null,{default:t.withCtx(()=>[t.createElementVNode("div",lw,t.toDisplayString(e.row.title),1),t.createElementVNode("div",aw,t.toDisplayString(e.$sdk.date.readableEventDate(e.row)),1),t.createElementVNode("div",cw,t.toDisplayString(e.row.subtitle),1)]),_:1}),t.createVNode(m,null,{default:t.withCtx(()=>[t.createElementVNode("div",dw,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.rosters,g=>(t.openBlock(),t.createElementBlock("div",null,[t.createElementVNode("div",uw,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(g.slots,p=>(t.openBlock(),t.createElementBlock("div",null,[t.createElementVNode("h4",null,t.toDisplayString(p.title),1),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(p.assignments,y=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["assignment",y.state||"unknown"])},[t.createVNode(u,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(d,{shrink:""},{default:t.withCtx(()=>[t.createElementVNode("div",mw,[t.createVNode(c,{initials:`${y.profile.firstName} ${y.profile.lastName}`,id:y.profile},null,8,["initials","id"])])]),_:2},1024),t.createVNode(d,null,{default:t.withCtx(()=>{var k,x;return[t.createTextVNode(t.toDisplayString((k=y.profile)==null?void 0:k.firstName)+" "+t.toDisplayString((x=y.profile)==null?void 0:x.lastName),1)]}),_:2},1024)]),_:2},1024)],2))),256))]))),256))])]))),256))])]),_:1})]),_:1})]),_:1})):t.createCommentVNode("",!0)])}const hw=w(iw,[["render",fw],["__scopeId","data-v-88720bfa"]]),pw={mixins:[le],data(){return{runsheets:[],creating:!1}},created(){var e,n;this.runsheets=((n=(e=this.row.join_runsheet)==null?void 0:e.runsheet)==null?void 0:n.items)||[]},methods:{async addRunsheet(){const e=this;e.creating=!0,e.$sdk.global.create("runsheet",{model:{event:e.row}}).then(function(n){e.runsheets.push(n),e.openRunsheet(n),e.creating=!1},function(n){e.creating=!1})},async openRunsheet(e){const n=this.$sdk.access.canEditItem(this.user,e);return console.log("OPEN",n,e),n?this.editRunsheet(e):this.viewRunsheet(e)},async editRunsheet(e){const n=await this.$sdk.global.edit(e,!0);e.title=n.title},async viewRunsheet(e){const n=await this.$sdk.global.view(e,!0);e.title=n.title}},computed:{count(){var e;return(e=this.runsheets)==null?void 0:e.length}}},gw={class:"table-roster-cell"},yw={class:"wrp"};function kw(e,n,r,i,s,o){const l=t.resolveComponent("ux-button"),a=t.resolveComponent("ux-panel-body"),c=t.resolveComponent("ux-list-item"),d=t.resolveComponent("ux-list"),u=t.resolveComponent("ux-panel"),m=t.resolveComponent("ux-menu"),f=t.resolveComponent("ux-icon"),h=t.resolveDirective("tippy");return t.openBlock(),t.createElementBlock("td",gw,[t.withDirectives((t.openBlock(),t.createElementBlock("div",yw,[o.count?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[o.count>1?(t.openBlock(),t.createBlock(m,{key:0},{activator:t.withCtx(({on:g})=>[t.createVNode(l,t.mergeProps({size:"xs"},t.toHandlers(g),{onClick:n[0]||(n[0]=t.withModifiers(()=>{},["stop"])),icon:""}),{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.count),1)]),_:2},1040)]),default:t.withCtx(()=>[t.createVNode(u,null,{default:t.withCtx(()=>[t.createVNode(a,null,{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.count)+" Run Sheet"+t.toDisplayString(o.count===1?"":"s"),1)]),_:1}),t.createVNode(d,null,{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(s.runsheets,g=>(t.openBlock(),t.createBlock(c,{onClick:p=>o.openRunsheet(g)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(g.title)+" ",1)]),_:2},1032,["onClick"]))),256))]),_:1})]),_:1})]),_:1})):(t.openBlock(),t.createBlock(l,{key:1,size:"xs",icon:"",onClick:n[1]||(n[1]=t.withModifiers(g=>o.openRunsheet(s.runsheets[0]),["stop"]))},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.count),1)]),_:1}))],64)):(t.openBlock(),t.createBlock(l,{key:1,size:"xs",icon:"",loading:s.creating,onClick:t.withModifiers(o.addRunsheet,["stop"])},{default:t.withCtx(()=>[t.createVNode(f,{icon:"fa-plus"})]),_:1},8,["loading","onClick"]))])),[[h,{placement:"bottom",content:`${o.count} Run Sheets`}]])])}const _w=w(pw,[["render",kw],["__scopeId","data-v-b904ed97"]]);function Li(e,n){if(!e||!n)return;const r=n.split("|");n=r[0];const i=r[1];var s=ht(e,n);if(s)return i&&Array.isArray(s)?s.filter(function(d){var m;const u=(m=d==null?void 0:d.meta)==null?void 0:m.definition;if(i==="null")return!u;if(u)return u===i}):s;const o=n.split("."),l=o.shift(),a=o.join("."),c=ht(e,l);return Array.isArray(c)?c.map(function(d){return Li(d,a)}).flat().filter(Boolean):Li(c,a)}const ww={data(){return{component:null}},components:{ValueRenderer:N_},async created(){const e=this;let n,r=e.column.type,i=e.column.renderer,s=e.column.key;if(!i)switch(s){case"fileSize":i="filesize";break;case"duration":i="duration";break;case"title":i="title";break;case"status":case"paymentStatus":case"meta.status":i="status";break;case"meta.tags":i="tag";break;case"meta.definition":i="type";break}switch(e.column.widget){case"button":break;default:i=i||e.column.widget;break}switch(r){case"boolean":i="boolean";break;case"reference":e.column.referenceType==="image"&&(i="thumbnail");break}switch(i){case"filesize":n=l_;break;case"duration":n=u_;break;case"button":n=qk;break;case"security":n=h_;break;case"boolean":n=Md;break;case"roster":n=hw;break;case"runsheet":n=_w;break;case"personainvite":n=R_;break;case"personaemail":n=A_;break;case"time":case"timefield":n=Ok;break;case"date":case"datetime":n=Od;break;case"due":n=n_;break;case"circles":n=ew;break;case"title":n=J_;break;case"type":n=ow;break;case"complex":n=O_;break;case"status":n=z_;break;case"computed":n=b_;break;case"url":n=Fd;break;case"currency":n=Pk;break;case"tag":n=bk;break;case"avatar":n=Bk;break;case"thumbnail":n=Ak;break;default:switch(r){case"date":n=Od;break;case"boolean":n=Md;break;case"url":n=Fd;break}break}e.component=n},props:{column:{type:Object,required:!0},row:{type:Object,required:!0}},computed:{nowrap(){return this.column.wrap===!1},multiValue(){return Array.isArray(this.value)},renderer(){return this.column.renderer},renderValue(){var e=this.value;if(e!=null)return e.title||e.name||e},value(){var e=Li(this.row,this.column.key);return e}}},xw={class:"value"};function bw(e,n,r,i,s,o){const l=t.resolveComponent("value-renderer");return s.component?(t.openBlock(),t.createBlock(t.resolveDynamicComponent(s.component),{key:0,column:r.column,row:r.row,value:o.value},null,8,["column","row","value"])):(t.openBlock(),t.createElementBlock("td",{key:1,class:t.normalizeClass(["table-cell",{nowrap:o.nowrap}])},[o.multiValue?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:0},t.renderList(o.value,(a,c)=>(t.openBlock(),t.createElementBlock("span",xw,[t.createVNode(l,{type:r.column.type,multi:"",last:c===o.value.length-1,value:a},null,8,["type","last","value"])]))),256)):(t.openBlock(),t.createBlock(l,{key:1,type:r.column.type,value:o.value},null,8,["type","value"]))],2))}const Ld=w(ww,[["render",bw],["__scopeId","data-v-43da03cf"]]),Cw={components:{TableCell:Ld},props:{selected:{type:Boolean},index:{type:Number},row:{type:Object,required:!0},columns:{type:Array,required:!0},enableActions:{type:Boolean,default(){return!1}},enableSelection:{type:Boolean,default(){return!0}}},emits:["click:cell","click:row","click:actions","mousedown:select","mouseenter:select"],methods:{clickCell(e){this.$emit("click:cell",{row:this.row,column:e}),this.$emit("click:row",this.row)},clickActions(e){this.$emit("click:actions",e)},mousedownSelect(e){this.$emit("mousedown:select",this.row,this.index,e)},mouseenterSelect(){this.$emit("mouseenter:select",this.row,this.index)}},computed:{classes(){var n,r;var e=[];return this.selected&&e.push("selected"),((r=(n=this.row)==null?void 0:n.meta)==null?void 0:r.status)==="inactive"&&e.push("inactive"),e}}};function Vw(e,n,r,i,s,o){const l=t.resolveComponent("ux-checkbox"),a=t.resolveComponent("table-cell"),c=t.resolveComponent("ux-icon"),d=t.resolveComponent("ux-button");return t.openBlock(),t.createElementBlock("tr",{class:t.normalizeClass([o.classes,"table-row"])},[t.renderSlot(e.$slots,"default",{},()=>[r.enableSelection?(t.openBlock(),t.createElementBlock("th",{key:0,class:"table-cell table-select first shrink",onMousedown:n[0]||(n[0]=t.withModifiers((...u)=>o.mousedownSelect&&o.mousedownSelect(...u),["prevent"])),onMouseenter:n[1]||(n[1]=(...u)=>o.mouseenterSelect&&o.mouseenterSelect(...u)),onClick:n[2]||(n[2]=t.withModifiers(()=>{},["stop","prevent"]))},[t.createVNode(l,{value:r.selected},null,8,["value"])],32)):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.columns,(u,m)=>(t.openBlock(),t.createBlock(a,{key:`${u.path||u.key}-${m}-${u.type}-${u.renderer}`,onClick:t.withModifiers(f=>o.clickCell(u),["stop","prevent"]),column:u,row:r.row},null,8,["onClick","column","row"]))),128)),r.enableActions?(t.openBlock(),t.createElementBlock("th",{key:1,class:"table-cell last shrink",onClick:n[3]||(n[3]=t.withModifiers(u=>o.clickActions(r.row),["stop","prevent"]))},[t.createVNode(d,{size:"xs",icon:""},{default:t.withCtx(()=>[t.createVNode(c,{icon:"fa-ellipsis"})]),_:1})])):t.createCommentVNode("",!0)],!0)],2)}const Nw=w(Cw,[["render",Vw],["__scopeId","data-v-e196f762"]]),$d={data(){return{scrollTop:0}},methods:{updateScroll(e){var n=this.$refs.scroll;n=(n==null?void 0:n.$el)||n,n&&(this.scrollTop=n.scrollTop)}},mounted(){var e=this.$refs.scroll;e=(e==null?void 0:e.$el)||e,e&&e.addEventListener("scroll",this.updateScroll)},beforeUnmount(){var e=this.$refs.scroll;e=(e==null?void 0:e.$el)||e,e&&e.removeEventListener("scroll",this.updateScroll)},activated(){var e=this.$refs.scroll;e=(e==null?void 0:e.$el)||e,e&&(e.scrollTop=this.scrollTop)}},Ew={mixins:[$d],components:{TableRow:Nw,TableCell:Ld},emits:["update:sort","select:multiple","deselect:multiple","select:multiple","click:row","click:cell","click:actions","select:row:toggle"],watch:{rows(){this.$refs.scroll.scroll({top:0,left:0})},sort(e){this.sorting=e},sorting(e){this.$emit("update:sort",e)}},props:{total:{type:Number},columns:{type:Array,default(){return[]}},rows:{type:Array,default(){return[]}},scrollable:{type:Boolean,default(){return!0}},enableActions:{type:Boolean,default(){return!1}},enableSelection:{type:Boolean,default(){return!0}},sort:{type:Object,default(){return{key:"meta.created",type:"date",direction:"desc"}}},selection:{type:Array,default(){return[]}},selectAll:{type:Function},deselectAll:{type:Function},group:{type:Object,default(){return{}}}},data(){return{sorting:this.sort,lastSelectedIndex:null,lastSelectAction:null,dragging:!1,dragMode:null,dragStart:null}},beforeUnmount(){window.removeEventListener("mouseup",this.endDrag),window.removeEventListener("mousemove",this.checkDragStart)},computed:{groupedRows(){const e=this.group.key,n=this.group.type||"string";if(e){const{values:r}=this.renderRows.reduce(function(i,s){let o=ht(s,e);o=String(o);let l=i.keys[o];return l||(l=i.keys[o]={title:o,rows:[]},i.values.push(l)),i},{values:[],keys:{}});return r}return[{rows:this.renderRows}]},currentSortDirection(){var e;return((e=this.sorting)==null?void 0:e.direction)||"asc"},selectionHash(){var e=this;return e.selection.reduce(function(n,r){var i=r._id||r.id;return n[i]=r,n},{})},pageSelected(){var e=this;if(!(!e.rows||!e.rows.length))return!e.rows.some(function(n){return!e.selectionHash[n._id||n.id]})},renderColumns(){return this.columns.map(function(n){var r=Object.assign({},n);return r.class=[],r.shrink&&r.class.push("shrink"),r})},renderRows(){return this.rows},someSelectedOnPage(){return this.rows.some(this.isSelected)}},methods:{togglePage(){var e=this;e.pageSelected?e.deselectPage():e.selectPage()},selectPage(){var e=this;e.$emit("select:multiple",e.rows)},deselectPage(){var e=this;e.$emit("deselect:multiple",e.rows)},isSelected(e){var n=this,r=e._id||e.id;return n.selection.some(function(i){var s=i._id||i.id;return i==e||s==r})},classes(e){let n=[];return this.isSelected(e)&&n.push("selected"),n},selectRange(e,n){const r=Math.min(e,n),i=Math.max(e,n)+1,s=this.renderRows.slice(r,i);this.$emit("select:multiple",s)},deselectRange(e,n){const r=Math.min(e,n),i=Math.max(e,n)+1,s=this.renderRows.slice(r,i);this.$emit("deselect:multiple",s)},toggleSort(e){var o,l;const n=(o=this.sorting)==null?void 0:o.key,r=((l=this.sorting)==null?void 0:l.direction)||"asc";let{key:i,direction:s}=e;i===n&&(s=r==="dsc"?"asc":"dsc"),this.sorting={key:i,direction:s,type:e.type}},clickRow(e){this.$emit("click:row",e)},clickCell({row:e,column:n}){this.$emit("click:cell",{row:e,column:n})},clickActions(e){this.$emit("click:actions",e)},mousedownSelect(e,n,r){const s=this.isSelected(e)?"deselect":"select";if(r.shiftKey&&this.lastSelectedIndex!=null&&this.lastSelectedIndex!==n){this.lastSelectAction==="deselect"?this.deselectRange(this.lastSelectedIndex,n):this.selectRange(this.lastSelectedIndex,n),this.lastSelectedIndex=n;return}s==="select"?this.$emit("select:multiple",[e]):this.$emit("deselect:multiple",[e]),this.lastSelectedIndex=n,this.lastSelectAction=s,this.dragMode=s,this.dragStart={x:r.clientX,y:r.clientY},window.addEventListener("mousemove",this.checkDragStart),window.addEventListener("mouseup",this.endDrag,{once:!0})},mouseenterSelect(e,n){if(!this.dragging)return;const r=this.isSelected(e);this.dragMode==="select"&&!r?this.$emit("select:multiple",[e]):this.dragMode==="deselect"&&r&&this.$emit("deselect:multiple",[e])},checkDragStart(e){if(!this.dragStart)return;const n=e.clientX-this.dragStart.x,r=e.clientY-this.dragStart.y;n*n+r*r>=9&&(this.dragging=!0,window.removeEventListener("mousemove",this.checkDragStart))},endDrag(){this.dragging=!1,this.dragMode=null,this.dragStart=null,window.removeEventListener("mouseup",this.endDrag),window.removeEventListener("mousemove",this.checkDragStart)}}},Bw={class:"table-scroll",ref:"scroll"},Sw={key:0,class:"first table-select shrink"},Tw=["onClick"],Dw={key:1,class:"last shrink"},Ow={key:0};function Mw(e,n,r,i,s,o){const l=t.resolveComponent("ux-checkbox"),a=t.resolveComponent("ux-list-item"),c=t.resolveComponent("ux-list"),d=t.resolveComponent("ux-menu"),u=t.resolveComponent("flex-cell"),m=t.resolveComponent("flex-row"),f=t.resolveComponent("table-row");return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["table-wrapper",{dragging:s.dragging}]),onMouseup:n[4]||(n[4]=(...h)=>o.endDrag&&o.endDrag(...h))},[t.createElementVNode("div",Bw,[t.createElementVNode("table",null,[t.createElementVNode("thead",null,[t.createElementVNode("tr",null,[r.enableSelection?(t.openBlock(),t.createElementBlock("th",Sw,[t.createVNode(d,null,{activator:t.withCtx(({on:h})=>[t.createVNode(l,t.mergeProps(t.toHandlers(h),{value:o.pageSelected}),null,16,["value"])]),default:t.withCtx(()=>[t.createVNode(c,null,{default:t.withCtx(()=>[t.createVNode(a,{onClick:n[0]||(n[0]=h=>o.selectPage())},{default:t.withCtx(()=>[t.createTextVNode(" Select Page ")]),_:1}),o.someSelectedOnPage?(t.openBlock(),t.createBlock(a,{key:0,onClick:n[1]||(n[1]=h=>o.deselectPage())},{default:t.withCtx(()=>[t.createTextVNode(" Deselect Page ")]),_:1})):t.createCommentVNode("",!0),r.selectAll?(t.openBlock(),t.createBlock(a,{key:1,onClick:n[2]||(n[2]=h=>r.selectAll())},{default:t.withCtx(()=>[t.createTextVNode(" Select All ("+t.toDisplayString(r.total)+") ",1)]),_:1})):t.createCommentVNode("",!0),r.deselectAll?(t.openBlock(),t.createBlock(a,{key:2,onClick:n[3]||(n[3]=h=>r.deselectAll())},{default:t.withCtx(()=>[t.createTextVNode(" Deselect All ")]),_:1})):t.createCommentVNode("",!0)]),_:1})]),_:1})])):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.renderColumns,h=>{var g;return t.openBlock(),t.createElementBlock("th",{onClick:p=>o.toggleSort(h),class:t.normalizeClass([{sortable:h.sortable!==!1,active:h.key===((g=s.sorting)==null?void 0:g.key)},h.class])},[t.createVNode(m,{gap:"",vcenter:""},{default:t.withCtx(()=>{var p;return[t.createVNode(u,null,{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(h.title),1)]),_:2},1024),h.key===((p=s.sorting)==null?void 0:p.key)?(t.openBlock(),t.createBlock(u,{key:0,class:"caret",shrink:""},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.currentSortDirection==="asc"?"▲":"▼"),1)]),_:1})):t.createCommentVNode("",!0)]}),_:2},1024)],10,Tw)}),256)),r.enableActions?(t.openBlock(),t.createElementBlock("th",Dw,[t.renderSlot(e.$slots,"corner",{},void 0,!0)])):t.createCommentVNode("",!0)])]),t.createElementVNode("tbody",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.groupedRows,h=>(t.openBlock(),t.createElementBlock(t.Fragment,null,[h.title?(t.openBlock(),t.createElementBlock("tr",Ow,[t.createElementVNode("td",null,t.toDisplayString(h.title),1)])):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(h.rows,(g,p)=>(t.openBlock(),t.createBlock(f,{enableSelection:r.enableSelection,enableActions:r.enableActions,key:g._id,"onClick:cell":o.clickCell,"onClick:row":o.clickRow,"onMousedown:select":o.mousedownSelect,"onMouseenter:select":o.mouseenterSelect,"onClick:actions":o.clickActions,selected:o.isSelected(g),row:g,index:p,columns:r.columns},null,8,["enableSelection","enableActions","onClick:cell","onClick:row","onMousedown:select","onMouseenter:select","onClick:actions","selected","row","index","columns"]))),128))],64))),256))])])],512)],34)}const Pd=w(Ew,[["render",Mw],["__scopeId","data-v-ba74a660"]]);var gr={exports:{}},Rd;function Fw(){if(Rd)return gr.exports;Rd=1;var e=Object.prototype.hasOwnProperty;function n(s){return"[Throws: "+(s?s.message:"?")+"]"}function r(s,o){if(e.call(s,o))try{return s[o]}catch(l){return n(l)}return s[o]}function i(s){var o=[];function l(a){if(a===null||typeof a!="object")return a;if(o.indexOf(a)!==-1)return"[Circular]";if(o.push(a),typeof a.toJSON=="function")try{var c=l(a.toJSON());return o.pop(),c}catch(m){return n(m)}if(Array.isArray(a)){var d=a.map(l);return o.pop(),d}var u=Object.keys(a).reduce(function(m,f){return m[f]=l(r(a,f)),m},{});return o.pop(),u}return l(s)}return gr.exports=function(s,o,l){return JSON.stringify(i(s),o,l)},gr.exports.ensureProperties=i,gr.exports}var Iw=Fw();const $i=ft(Iw);function Aw(e,n){return e==null||n=="date"&&e.toString&&e.toString()==="Invalid Date"}function Ud(e){return e!=null}const z={emits:["touched","update:modelValue"],props:{field:{type:Object,default(){return{}}},parentModel:{type:Object}},data(){return{dynamicOptions:[],asyncOptionsAreLoading:this.field.asyncOptions,value:this.modelValue}},watch:{modelValue(e,n){this.model=e}},mounted(){this.checkAutofocus()},async created(){const e=this;e.hasAsyncOptions&&await e.reloadAsyncOptions()},inject:{form:{default(){}},fieldPath:{default(){}}},computed:{asyncOptionsURL(){const e=this;if(e.field.asyncOptions&&String(e.field.asyncOptions||"").trim().length)return e.field.asyncOptions;if(e.field.dynamicOptions){const n=e.$sdk.utils.id(e.field.dynamicOptions);if(n)return e.$sdk.api.generateEndpointURL(`/smartlist/${n}/select`)}},hasAuthenticationToken(){return this.$sdk.auth.getCurrentToken()},hasAsyncOptions(){var e;if(this.asyncOptionsURL)return!0;if(this.field.type==="reference"){if((e=this.field.allowedReferences)!=null&&e.length)return!1;switch(this.field.widget){case"select":if(this.hasAuthenticationToken)return!0;break;default:return!1}if(this.field.lockFilter)return!0}return!1},loadingAsyncOptions(){return this.hasAsyncOptions&&this.asyncOptionsAreLoading},optionLookup(){var e=this;return e.options.reduce(function(n,r){const i=e.getValue(r);return n[i]=r,n},{})},selectableOptions(){return this.options},required(){return this.minimum},model:{get(){var e=this.cleanOutput(this.value);return e},set(e){let n;(this.isGroup||this.widget==="form")&&(e===this.value?n=!1:n=!0);const r=this.cleanInput(e),i=this.cleanInput(this.value);($i(r)!=$i(i)||n)&&(this.value=r,this.checkAutofocus(),this.dispatch())}},options(){var e=this;if(e.field.type==="reference"){const n=(e.field.allowedReferences||[]).filter(Boolean);if(n.length)return n.map(function(r){let{_id:i,title:s}=r;return s=s||[r.firstName,r.lastName].filter(Boolean).join(" "),{title:s,value:i,_id:i}})}return e.hasAsyncOptions?e.dynamicOptions:(e.field.options||[]).reduce(function(n,r){if(!r)return n;const i=e.getValue(r);var o={title:r.title||r.name||r.label||i,value:i,none:r.none,group:r.group,source:r};return e.field.type=="reference"&&(o._id=i),n.push(o),n},[])},prefix(){return this.field.suffix},suffix(){return this.field.suffix},type(){return this.field.type||"string"},key(){return this.field.key},isGroup(){return this.type==="group"},asObject(){return this.isGroup&&!!this.field.asObject},layoutGroup(){return this.isGroup&&!this.field.asObject},canAddValue(){if(!this.singleValue&&!(this.options.length&&this.selectableOptions.length===0))return this.maximum===0||this.numValues<this.maximum},canRemoveValue(){return this.numValues>this.minimum},widget(){return this.field.widget},singleValue(){if(this.asObject){var e=this.minimum===1&&this.maximum===1;return e}else return this.maximum===1},multiValue(){return!this.singleValue},label(){return this.field.title},title(){return this.label},plural(){return this.field.plural},description(){return this.field.description},placeholder(){return this.field.placeholder||this.field.hint},addLabel(){return this.field.addLabel?this.field.addLabel:this.numValues?`Add another ${this.label}`:`Add ${this.label}`},removeLabel(){return"Remove"},size(){return this.field.size},numValues(){return this.singleValue?1:(this.value||[]).length||0},showLabel(){return this.field.title&&!this.field.hideTitle},showDescription(){return this.description},fields(){var e=this.field.fields;if(e&&e.length)return e},minimum(){if(this.layoutGroup)return 1;var e=parseInt(this.field.minimum||0);return isNaN(e)&&(e=0),e=Math.max(e,0),e=this.maximum?Math.min(e,this.maximum):e,parseInt(e)},maximum(){if(this.layoutGroup)return 1;var e=parseInt(this.field.maximum||0);return isNaN(e)&&(e=0),e=Math.max(e,0),parseInt(e)},ask(){var e=parseInt(this.field.ask);return e=Math.max(e,this.minimum),this.maximum&&(e=Math.min(e,this.maximum)),e},minDate(){if(this.field.minDate)return new Date(this.field.minDate)},maxDate(){if(this.field.maxDate)return new Date(this.field.maxDate)}},methods:{async reloadAsyncOptions(){const e=this;if(!e.hasAsyncOptions){e.asyncOptionsAreLoading=!1;return}if(e.asyncOptionsAreLoading=!0,e.asyncOptionsURL){const{data:n}=await e.$sdk.api.get(e.asyncOptionsURL);e.dynamicOptions=(n||[]).map(function(r){let i=r==null?void 0:r.title;i||(i=r==null?void 0:r.name),i||(i=r==null?void 0:r.label),i||(i=[r.firstName,r.lastName].filter(Boolean).join(" ").trim()),i||(i=r.value||String(r));const s=String((r==null?void 0:r.value)||(r==null?void 0:r.title)||(r==null?void 0:r.name)||(r==null?void 0:r.label)||r),o=e.$sdk.utils.id((r==null?void 0:r._id)||r);return{title:i,value:s,_id:o}})}else if(e.hasAuthenticationToken){const n=e.field.referenceType,r={filter:e.field.lockFilter,sort:{key:"title",direction:"asc",type:"string"},page:{size:1e3}},{items:i}=await e.$sdk.content.list(n,r);e.dynamicOptions=i.map(function({_id:s,title:o}){return{value:s,title:o,_id:s}})}e.asyncOptionsAreLoading=!1},cleanTextInput(e,n,r){switch(n){case"url":e=r.$sdk.utils.parseURL(e);break;case"key":e=String(r.$sdk.utils.machineName(e||"")||"").trim();break;case"integer":e=parseInt(String(e).replace(/[^0-9-]/g,"")),isNaN(e)&&(e=void 0);break;case"number":case"decimal":case"float":e=Number(String(e).replace(/[^0-9.-]/g,"")),isNaN(e)&&(e=void 0);break}return e},checkAutofocus(){if(this.field.autofocus){if(this.value)return;this.$nextTick(function(){this.refocus()})}},getValue(e){if(!e)return this.cleanTextInput(e);var n=this.cleanTextInput(e._id||e.value),r=Ud(n);return!r&&e.title&&!this.returnObject&&(n=e.title),n=this.cleanTextInput(n),Ud(n)?n:e},getLabel(e){if(e){var n=e.title;return!n&&n!==0&&n!==!1&&(n=e.name),!n&&n!==0&&n!==!1&&(n=e.label),!n&&n!==0&&n!==!1&&(n=e.value),typeof n=="object"?"(no title)":n}},touch(){this.$emit("touched")},getNewDefaultEntry(){},add(){if(this.canAddValue){var e=this.cleanInputValue(this.getNewDefaultEntry());(!this.value||!Array.isArray(this.value))&&(this.value=[]),this.value.push(e),this.dispatch(),this.$nextTick(function(){this.refocus()}),this.touch()}},remove(e){var n=this.model.indexOf(e);this.model.splice(n,1),this.dispatch(),this.touch()},dispatch(){this.$emit("update:modelValue",this.value)},cleanInputValue(e){return e},cleanOutputValue(e){return e},cleanOutput(e){var n=this;return Aw(e,n.field.type)?n.multiValue?e=[]:e=void 0:n.multiValue?(Array.isArray(e)||(e=[]),e.forEach(function(r,i){e[i]=n.cleanOutputValue(r)})):e=n.cleanOutputValue(e),e},cleanInput(e){var n=this;if(n.multiValue){for(e||(e=[]),Array.isArray(e)||(e=[e]),n.maximum&&e.length>n.maximum&&(e.length=n.maximum);e.length<n.minimum;)e.push(n.cleanInputValue(n.getNewDefaultEntry()));e=e.map(function(r){var i=n.cleanInputValue(r);return i})}else e&&(e=n.cleanInputValue(e));return e},refocus(){var e=this.$refs.input;if(e){var n;Array.isArray(e)?(console.log("ELEMENTS LENGTH?",e),n=e[e.length-1]):n=e,n&&(console.log("INPUT",n),n.focus())}}}};function Lw(e){return e===void 0||typeof e>"u"||e===null||String(e)==="null"||String(e)==="undefined"}const $w={data(){return{candidate:null}},props:{modelValue:{},pills:{type:Boolean,default:!1}},mixins:[z],created(){this.model=this.model},methods:{displayLabelFromValue(e){if(!e)return;const n=e.value||e,r=this.optionLookup[n]||{};return r.title||r.name||e.title||e.value||e},addValue(e){this.canAddValue&&this.model.indexOf(e)===-1&&(this.model=[...this.model,e])},removeValue(e){var n=this.model.slice();e!=-1&&(n.splice(e,1),this.model=n)},cleanOutput(e){var n=this;return Lw(e)?n.multiValue?e=[]:e=void 0:n.multiValue?e=(e||[]).filter(function(r){return r!=null}).map(function(r){return n.getValue(r)}):e=n.getValue(e),e},cleanInput(e){var n=this;if(n.multiValue)e||(e=[]),Array.isArray(e)||(e=[e]),n.maximum&&e.length>n.maximum&&(e.length=n.maximum),e=e.filter(function(i){return i!=null}).map(function(i){var s=n.getValue(i);return n.returnObject?n.optionLookup[s]:s});else{var r=n.getValue(e);switch(e=n.returnObject?n.optionLookup[r]:r,e){case"":switch(n.type){case"decimal":case"float":case"number":case"integer":e=void 0;break}break}}return e}},watch:{candidate(e){e&&(this.addValue(e),this.candidate=null)}},computed:{noneTitle(){return this.field.placeholder||"None"},usePills(){return this.field.pills||this.pills},returnObject(){return this.type=="reference"},classes(){var e=[];return this.multiValue?e.push("multiple"):e.push("single"),this.usePills&&e.push("pills"),e},summary(){if(this.multiValue)return"Select an option";const e=this.selectableOptions.find(function(i){return i.none}),n=(e==null?void 0:e.title)||(e==null?void 0:e.label),r=this.model;return r||r===!1||r===0?this.getLabel(this.optionLookup[this.model]):n||this.noneTitle||this.title||"Click to select"},grouped(){const e=this,{values:n}=e.selectableOptions.reduce(function(r,i){const s=i.group||"";let o=r.hash[s];return o||(o=r.hash[s]={title:s,options:[]},r.values.push(o)),o.options.push(i),r},{hash:{},values:[]});if(!(n.length<=1))return n},modelLookup(){var e=this;return e.multiValue?e.model.reduce(function(n,r){const i=e.getValue(r);return n[i]=r,n},{}):{}},selectableOptions(){var r;const e=this;let n=e.options;return e.multiValue&&(n=n.filter(function(i){return!e.modelLookup[e.getValue(i)]})),(r=e.field)!=null&&r.sorted?n.sort(function(i,s){var o=(i.title||i).toLowerCase(),l=(s.title||s).toLowerCase();return o<l?-1:o>l?1:0}):n},showNoneOption(){return!(!(this.singleValue&&!this.minimum)||this.selectableOptions.find(function(r){return r.none}))}}},Pw=e=>(t.pushScopeId("data-v-9fabb548"),e=e(),t.popScopeId(),e),Rw={key:0,class:"ux-field-title"},Uw={key:0,class:"ux-required-marker"},jw={key:1,class:"ux-field-description"},qw={key:2,class:"select-tags"},zw=["onClick"],Ww={key:3},Hw={key:4,class:"select-input-wrapper"},Gw={class:"ui-select-button"},Yw=Pw(()=>t.createElementVNode("option",{value:""},"Select an option",-1)),Jw=["label"],Kw=["value"],Zw=["value"],Xw={class:"ui-select-button"},Qw=["multiple"],vw={key:0,value:""},e1=["label"],t1=["value"],n1=["value"];function r1(e,n,r,i,s,o){var u,m;const l=t.resolveComponent("flex-cell"),a=t.resolveComponent("ux-icon"),c=t.resolveComponent("flex-row"),d=t.resolveComponent("ux-button");return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["native-select",o.classes])},[e.showLabel?(t.openBlock(),t.createElementBlock("label",Rw,[t.createTextVNode(t.toDisplayString(e.label)+" ",1),e.required?(t.openBlock(),t.createElementBlock("span",Uw,"*")):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),e.showDescription?(t.openBlock(),t.createElementBlock("div",jw,t.toDisplayString(e.description),1)):t.createCommentVNode("",!0),e.multiValue?(t.openBlock(),t.createElementBlock("div",qw,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.model,(f,h)=>(t.openBlock(),t.createElementBlock("div",{class:"select-tag",key:f.value||f},[t.createVNode(c,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(l,null,{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.displayLabelFromValue(f)),1)]),_:2},1024),t.createVNode(l,{shrink:""},{default:t.withCtx(()=>[t.createElementVNode("a",{onClick:g=>o.removeValue(h)},[t.createVNode(a,{icon:"fa-times"})],8,zw)]),_:2},1024)]),_:2},1024)]))),128))])):t.createCommentVNode("",!0),e.loadingAsyncOptions?(t.openBlock(),t.createElementBlock("div",Ww,[t.createVNode(a,{icon:"fa-spinner",spin:"",left:""}),t.createTextVNode(" Loading Options ")])):(t.openBlock(),t.createElementBlock("div",Hw,[e.multiValue?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[e.canAddValue?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createElementVNode("div",Gw,[t.renderSlot(e.$slots,"default",{},()=>[t.createVNode(d,{size:e.size,tag:"div"},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.summary),1)]),_:1},8,["size"])],!0)]),t.withDirectives((t.openBlock(),t.createElementBlock("select",{onFocus:n[0]||(n[0]=(...f)=>e.touch&&e.touch(...f)),"onUpdate:modelValue":n[1]||(n[1]=f=>s.candidate=f),key:(u=e.model)==null?void 0:u.length},[Yw,o.grouped?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:0},t.renderList(o.grouped,f=>(t.openBlock(),t.createElementBlock("optgroup",{label:f.title,key:f.title},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(f.options,h=>(t.openBlock(),t.createElementBlock("option",{value:h.value},t.toDisplayString(h.title),9,Kw))),256))],8,Jw))),128)):(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:1},t.renderList(o.selectableOptions,f=>(t.openBlock(),t.createElementBlock("option",{value:f.value},t.toDisplayString(f.title),9,Zw))),256))],32)),[[t.vModelSelect,s.candidate]])],64)):t.createCommentVNode("",!0)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createElementVNode("div",Xw,[t.renderSlot(e.$slots,"default",{},()=>[t.createVNode(d,{size:e.size,tag:"div"},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(o.summary),1)]),_:1},8,["size"])],!0)]),t.withDirectives((t.openBlock(),t.createElementBlock("select",{onFocus:n[2]||(n[2]=(...f)=>e.touch&&e.touch(...f)),multiple:e.multiValue,"onUpdate:modelValue":n[3]||(n[3]=f=>e.model=f),key:(m=e.model)==null?void 0:m.length},[o.showNoneOption?(t.openBlock(),t.createElementBlock("option",vw,t.toDisplayString(o.noneTitle),1)):t.createCommentVNode("",!0),o.grouped?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:1},t.renderList(o.grouped,f=>(t.openBlock(),t.createElementBlock("optgroup",{label:f.title,key:f.title},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(f.options,h=>(t.openBlock(),t.createElementBlock("option",{value:h.value},t.toDisplayString(h.title),9,t1))),256))],8,e1))),128)):(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:2},t.renderList(o.selectableOptions,f=>(t.openBlock(),t.createElementBlock("option",{value:f.value},t.toDisplayString(f.title),9,n1))),256))],40,Qw)),[[t.vModelSelect,e.model]])],64))]))],2)}const Ke=w($w,[["render",r1],["__scopeId","data-v-9fabb548"]]),o1={props:{total:{type:Number,default(){return 0}},page:{type:Object,default(){return{size:50,index:1}}},sizeOptions:{type:Array,default(){return[50,100,250,500]}}},components:{NativeSelect:Ke},watch:{totalPages(){this.currentPage=0}},computed:{perPage:{get(){return this.pageModel.size},set(e){e=Math.max(e,1),this.pageModel.size=e,this.dispatch()}},pageField(){return{type:"integer",maximum:1,minimum:1,options:Array(this.totalPages).fill(1).map((e,n)=>e+n)}},totalPages(){return Math.ceil(this.total/this.perPage)},startIndex(){return(this.currentPage-1)*this.pageModel.size},displayStartIndex(){return this.total?this.startIndex+1:0},endIndex(){return Math.min(this.startIndex+this.pageModel.size,this.total)},currentPage:{get(){return this.pageModel.index},set(e){this.totalPages&&(e=Math.min(this.totalPages,e)),e=Math.max(e,1),this.pageModel.index=e,this.dispatch()}}},methods:{dispatch(){return this.$emit("update:page",this.pageModel)},previousPage(){this.currentPage--},nextPage(){this.currentPage++}},data(){return{pageModel:this.page,perPageField:{minimum:1,maximum:1,options:this.sizeOptions.map(function(e){return{title:`${e} per page`,value:e}})}}}};function i1(e,n,r,i,s,o){const l=t.resolveComponent("native-select"),a=t.resolveComponent("flex-cell"),c=t.resolveComponent("ux-icon"),d=t.resolveComponent("ux-button"),u=t.resolveComponent("flex-row");return t.openBlock(),t.createBlock(u,{center:"",gap:""},{default:t.withCtx(()=>[t.createVNode(a,{shrink:"",class:"text"},{default:t.withCtx(()=>[t.createVNode(l,{modelValue:o.perPage,"onUpdate:modelValue":n[0]||(n[0]=m=>o.perPage=m),field:s.perPageField},{default:t.withCtx(()=>[e.$device.breakpoint.xs?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createTextVNode(t.toDisplayString(o.displayStartIndex)+"-"+t.toDisplayString(o.endIndex)+" of "+t.toDisplayString(r.total),1)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createTextVNode("Showing "+t.toDisplayString(o.displayStartIndex)+" to "+t.toDisplayString(o.endIndex)+" of "+t.toDisplayString(r.total)+" total",1)],64))]),_:1},8,["modelValue","field"])]),_:1}),t.createVNode(a),o.totalPages>1?(t.openBlock(),t.createBlock(a,{key:0,shrink:""},{default:t.withCtx(()=>[t.createVNode(u,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(a,{shrink:"",class:"text"},{default:t.withCtx(()=>[t.createVNode(l,{modelValue:o.currentPage,"onUpdate:modelValue":n[1]||(n[1]=m=>o.currentPage=m),field:o.pageField},{default:t.withCtx(()=>[e.$device.breakpoint.xs?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createTextVNode(t.toDisplayString(o.currentPage)+"/"+t.toDisplayString(o.totalPages),1)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createTextVNode("Page "+t.toDisplayString(o.currentPage)+" of "+t.toDisplayString(o.totalPages),1)],64))]),_:1},8,["modelValue","field"])]),_:1}),t.createVNode(a,{shrink:""},{default:t.withCtx(()=>[t.createVNode(d,{size:"sm",icon:"",onClick:n[2]||(n[2]=m=>o.previousPage())},{default:t.withCtx(()=>[t.createVNode(c,{icon:"fa-arrow-left"})]),_:1})]),_:1}),t.createVNode(a,{shrink:""},{default:t.withCtx(()=>[t.createVNode(d,{size:"sm",icon:"",onClick:n[3]||(n[3]=m=>o.nextPage())},{default:t.withCtx(()=>[t.createVNode(c,{icon:"fa-arrow-right"})]),_:1})]),_:1})]),_:1})]),_:1})):t.createCommentVNode("",!0)]),_:1})}const jd=w(o1,[["render",i1],["__scopeId","data-v-93d339c8"]]);function s1(e){return t.getCurrentScope()?(t.onScopeDispose(e),!0):!1}function qd(e){return typeof e=="function"?e():t.unref(e)}const l1=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const a1=e=>e!=null,Pi=()=>{};function Ri(e){var n;const r=qd(e);return(n=r==null?void 0:r.$el)!=null?n:r}const c1=l1?window:void 0;function d1(){const e=t.ref(!1),n=t.getCurrentInstance();return n&&t.onMounted(()=>{e.value=!0},n),e}function u1(e){const n=d1();return t.computed(()=>(n.value,!!e()))}function m1(e,n,r={}){const{root:i,rootMargin:s="0px",threshold:o=.1,window:l=c1,immediate:a=!0}=r,c=u1(()=>l&&"IntersectionObserver"in l),d=t.computed(()=>{const g=qd(e);return(Array.isArray(g)?g:[g]).map(Ri).filter(a1)});let u=Pi;const m=t.ref(a),f=c.value?t.watch(()=>[d.value,Ri(i),m.value],([g,p])=>{if(u(),!m.value||!g.length)return;const y=new IntersectionObserver(n,{root:Ri(p),rootMargin:s,threshold:o});g.forEach(k=>k&&y.observe(k)),u=()=>{y.disconnect(),u=Pi}},{immediate:a,flush:"post"}):Pi,h=()=>{u(),f(),m.value=!1};return s1(h),{isSupported:c,isActive:m,pause(){u(),m.value=!1},resume(){m.value=!0},stop:h}}const f1={setup(){const e=t.ref(!1),n=t.ref(),{stop:r}=m1(n,([{isIntersecting:i}])=>{i&&(e.value=!0,r())},{rootMargin:"600px"});return{targetEl:n,shouldRender:e}}},h1={ref:"targetEl"};function p1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",h1,[i.shouldRender?t.renderSlot(e.$slots,"default",{key:0}):t.createCommentVNode("",!0)],512)}const zd=w(f1,[["render",p1]]),g1={props:{icon:{type:[Object,String],default(){return"fa-exclamation"}},type:{type:String,default:"info"}},computed:{classes(){var e=[];return e.push(`ux-info-${this.type}`),e}}},y1={class:"icon-circle"};function k1(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon"),a=t.resolveComponent("flex-cell"),c=t.resolveComponent("flex-row");return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-info-box",o.classes])},[t.createVNode(c,{style:{gap:"1em"},center:""},{default:t.withCtx(()=>[r.icon?(t.openBlock(),t.createBlock(a,{key:0,shrink:""},{default:t.withCtx(()=>[t.createElementVNode("div",y1,[t.createVNode(l,{icon:r.icon},null,8,["icon"])])]),_:1})):t.createCommentVNode("",!0),t.createVNode(a,null,{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3})]),_:3})],2)}const Wd=w(g1,[["render",k1],["__scopeId","data-v-9669e7c0"]]),_1={props:{id:{type:[Object,String]},initials:{type:[String,Object]},cacheKey:{type:[String,Number]}},data(){return{stringID:this.$sdk.utils.id(this.id)}},watch:{id(e){this.stringID=this.$sdk.utils.id(e)}},computed:{initialString(){var s,o,l;if(typeof this.initials=="string")return this.initials;const e=((s=this.initials)==null?void 0:s.firstName)||"",n=((o=this.initials)==null?void 0:o.lastName)||"",r=`${e} ${n}`.trim(),i=(l=this.initials)==null?void 0:l.title;return r||i},initialLetters(){const e=this.initialString||"";if(!e||!e.length)return"";const n=e.split(/\s+/);let r="";return n[0]&&(r+=String(n[0][0]||"").toUpperCase()),n[1]&&(r+=String(n[1][0]||"").toUpperCase()),r},url(){const e={};return this.cacheKey&&(e.cacheKey=this.cacheKey),this.$sdk.api.generateEndpointURL(`/image/${this.stringID}`,e,{file:!0})},style(){const e={};return e.backgroundImage=`url(${this.url})`,e}}},w1={key:0,class:"initials"};function x1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["avatar-image",{"with-initials":o.initialLetters}])},[o.initialLetters?(t.openBlock(),t.createElementBlock("div",w1,t.toDisplayString(o.initialLetters),1)):t.createCommentVNode("",!0),t.createElementVNode("div",{class:"avatar-img",style:t.normalizeStyle(o.style)},null,4)],2)}const Ui=w(_1,[["render",x1],["__scopeId","data-v-0acb5372"]]),b1={props:{large:{type:Boolean}}},C1=[(e=>(t.pushScopeId("data-v-d9a57955"),e=e(),t.popScopeId(),e))(()=>t.createElementVNode("svg",{width:"24",height:"24",stroke:"#000",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},[t.createElementVNode("g",{class:"spinner_V8m1"},[t.createElementVNode("circle",{cx:"12",cy:"12",r:"9.5",fill:"none","stroke-width":"2"})])],-1))];function V1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-spinner",{large:r.large}])},C1,2)}const Pt=w(b1,[["render",V1],["__scopeId","data-v-d9a57955"]]),N1={components:{Spinner:Pt},props:{to:{type:[Object,String]},icon:{type:Boolean},color:{type:String,default:"default"},bgColor:{type:String},fgColor:{type:String},tag:{type:String},href:{type:String},target:{type:String},loading:{type:Boolean},active:{type:Boolean},disabled:{type:Boolean},block:{type:Boolean},size:{type:String,default:"md"}},computed:{style(){var e={};return this.bgColor&&(e.backgroundColor=this.bgColor),this.fgColor&&(e.color=this.fgColor),e},classes(){var e=[];return e.push(`ux-btn-${this.size}`),this.block&&e.push("ux-btn-block"),this.loading&&e.push("ux-btn-loading"),this.active&&e.push("ux-btn-active"),this.icon&&e.push("ux-btn-icon"),e.push(`ux-btn-color-${this.color}`),this.disabled&&e.push("ux-btn-disabled"),e},element(){switch(this.tag){case"span":return this.tag;case"submit":return"button";default:return this.to||this.href?"ux-link":this.tag||"button"}}}},E1={class:"ux-btn-text"};function B1(e,n,r,i,s,o){const l=t.resolveComponent("spinner");return t.openBlock(),t.createBlock(t.resolveDynamicComponent(o.element),{type:"button",active:r.active,loading:r.loading,to:r.to,href:r.href,target:r.target,style:t.normalizeStyle(o.style),class:t.normalizeClass([o.classes,"ux-btn"]),disabled:r.disabled},{default:t.withCtx(()=>[r.loading?(t.openBlock(),t.createBlock(l,{key:0})):t.createCommentVNode("",!0),t.createElementVNode("span",E1,[t.renderSlot(e.$slots,"default",{},void 0,!0)])]),_:3},8,["active","loading","to","href","target","style","class","disabled"])}const Hd=w(N1,[["render",B1],["__scopeId","data-v-ea56e98b"]]),S1={props:{value:{type:Boolean,default(){return!1}}},computed:{classes(){var e=[];return this.value?e.push("ux-checkbox-true"):e.push("ux-checkbox-false"),e}}};function T1(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("button",{class:t.normalizeClass(["ux-checkbox",o.classes])},[t.createVNode(l,{class:"icon",icon:"fa-check"})],2)}const yr=w(S1,[["render",T1],["__scopeId","data-v-54bb07ba"]]),D1={props:{value:{type:Boolean,default(){return!1}},loading:{type:Boolean,default(){return!1}}},computed:{classes(){var e=[];return this.value?e.push("ux-switch-true"):e.push("ux-switch-false"),this.loading&&e.push("ux-switch-loading"),e}}};function O1(e,n,r,i,s,o){const l=t.resolveComponent("ux-icon");return t.openBlock(),t.createElementBlock("a",{class:t.normalizeClass(["ux-switch",o.classes])},[t.createElementVNode("span",null,[t.createVNode(l,{spin:"",icon:"fa-spinner"})])],2)}const ji=w(D1,[["render",O1],["__scopeId","data-v-1a0e83ee"]]),M1={props:{to:{type:[Object,String]},href:{type:String},target:{type:String},disabled:{type:Boolean},active:{type:Boolean}},methods:{clicked(e){var n=this;if(n.to&&(n.buildMode||n.nuxtMode))return e.preventDefault(),e.stopImmediatePropagation(),n.$sdk.app.to(n.to);if(n.href){if(n.buildMode){e.preventDefault(),window.open(n.href);return}if(n.nuxtMode){e.preventDefault(),e.stopImmediatePropagation();return}}}},computed:{actualHref(){if(this.href)return this.href;if(this.nuxtMode)return this.to?this.$sdk.app.createHref(this.to):void 0;if(this.to&&this.$router&&this.$router.resolve){const e=this.$router;this.$route;const n=!1,{location:r,route:i,href:s}=e.resolve(this.to,this.$route,n);return s}},nuxtMode(){return this.to&&this.$sdk.nuxt&&this.$sdk.app&&this.$sdk.app.createHref},buildMode(){return!!this.$sdk&&this.$sdk.app&&this.$sdk.app.builder},class(){var e=[];return this.disabled&&e.push("disabled"),this.active&&e.push("active"),(this.href||this.to)&&e.push("haslink"),e},element(){return this.nuxtMode||this.buildMode?"a":this.to?"router-link":"a"}}};function F1(e,n,r,i,s,o){return t.openBlock(),t.createBlock(t.resolveDynamicComponent(o.element),{onClick:o.clicked,to:r.to,href:o.actualHref,target:r.target,class:t.normalizeClass([o.class,"ux-link"])},{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["onClick","to","href","target","class"])}const Gd=w(M1,[["render",F1],["__scopeId","data-v-7a924ee2"]]),I1={props:{icon:{type:[Object,String]},spin:{type:Boolean},left:{type:Boolean},right:{type:Boolean},fixed:{type:Boolean}},computed:{classes(){var e=[];return e.push(this.icon),this.spin&&e.push("fa-spin"),this.left&&e.push("ux-icon-left"),this.right&&e.push("ux-icon-right"),this.fixed&&e.push("ux-icon-fixed"),e},element(){return"i"}}};function A1(e,n,r,i,s,o){return t.openBlock(),t.createBlock(t.resolveDynamicComponent(o.element),{class:t.normalizeClass(["ux-icon fa",o.classes])},null,8,["class"])}const Yd=w(I1,[["render",A1],["__scopeId","data-v-e7a15ac2"]]),kr={cache:{}},L1={props:{group:{type:String},right:{type:Boolean,default:!1},bottom:{type:Boolean,default:!1},stop:{type:Boolean,default:!1},flex:{type:Boolean,default:!1},closeOnClick:{type:Boolean,default:!0},visible:{type:Boolean,default:!0},modelValue:{type:Boolean,default:!1}},data(){return{outerStyle:{},innerStyle:{},isExpanded:this.modelValue,isVisible:this.visible,triggerEvent:null,refMenu:null,mounted:!1}},watch:{modelValue(e){this.expanded=e},visible(e){this.isVisible=e}},mounted(){this.refMenu=this.$refs.menu,this.mounted=!0},beforeUnmount(){this.removeListeners(),this.refMenu=null,this.mounted=!1,kr.cache[this.group]===this&&(kr.cache[this.group]=null)},methods:{removeListeners(){document.removeEventListener("click",this.globalClick),this.refMenu&&this.refMenu.removeEventListener("click",this.immediateClick)},addEventListeners(){document.addEventListener("click",this.globalClick),this.refMenu&&this.refMenu.addEventListener("click",this.immediateClick)},immediateClick(e){this.expanded&&this.closeOnClick&&(e.stopImmediatePropagation(),this.expanded=!1)},globalClick(e){if(this.triggerEvent!==e){var n=this.$refs.menu,r=e.srcElement;n&&n.contains(r)?this.closeOnClick&&(this.expanded=!1):this.expanded=!1}},position(){const e=this.$el.getBoundingClientRect();let n=e.left+window.scrollX,r=e.bottom+window.scrollY;this.outerStyle.left=`${n}px`,this.outerStyle.top=`${r}px`,this.innerStyle={},this.right&&(this.innerStyle.right=`-${e.width}px`),this.bottom&&(this.innerStyle.bottom=`${e.height}px`);var i=this.getMaxZIndex();this.outerStyle.zIndex=i,this.$nextTick(()=>{this.adjustForViewportBoundaries(e)})},adjustForViewportBoundaries(e){if(!this.refMenu)return;this.refMenu.getBoundingClientRect();const n={width:window.innerWidth,height:window.innerHeight};let r=e.left+window.scrollX,i=e.bottom+window.scrollY,s=!1;const o={...this.innerStyle};this.innerStyle={},this.$nextTick(()=>{const l=this.refMenu.getBoundingClientRect(),a=e.left+l.width>n.width,c=e.left,d=n.width-e.right;a&&c>d?(r=e.right+window.scrollX-l.width,s=!0):this.right&&!a&&(this.innerStyle.right=`-${e.width}px`);const u=e.bottom+l.height>n.height,m=e.top,f=n.height-e.bottom;u&&m>f?(i=e.top+window.scrollY-l.height,s=!0):this.bottom&&!u&&(this.innerStyle.bottom=`${e.height}px`),s?(this.outerStyle.left=`${Math.max(0,r)}px`,this.outerStyle.top=`${Math.max(0,i)}px`):this.innerStyle=o,this.ensureWithinViewport()})},ensureWithinViewport(){if(!this.refMenu)return;const e=this.refMenu.getBoundingClientRect(),n={width:window.innerWidth,height:window.innerHeight};let r=parseInt(this.outerStyle.left)||0,i=parseInt(this.outerStyle.top)||0;e.right>n.width&&(r-=e.right-n.width+10),e.left<0&&(r+=Math.abs(e.left)+10),e.bottom>n.height&&(i-=e.bottom-n.height+10),e.top<0&&(i+=Math.abs(e.top)+10),this.outerStyle.left=`${Math.max(0,r)}px`,this.outerStyle.top=`${Math.max(0,i)}px`},getMaxZIndex(){return Math.max(...Array.from(document.querySelectorAll("body *"),e=>parseFloat(window.getComputedStyle(e).zIndex)).filter(e=>!Number.isNaN(e)),0)},close(){this.expanded=!1}},computed:{expanded:{get(){return this.isExpanded},set(e){var n;this.group&&(n=kr.cache[this.group]),this.isExpanded!=e&&(this.isExpanded=e,e?(this.position(),this.addEventListeners(),kr.cache[this.group]=this,n&&n!=this&&(n.expanded=!1)):this.removeListeners(),this.$emit("update:modelValue",e))}},on(){var e=this;return{click(n){e.stop&&n.stopImmediatePropagation(),e.triggerEvent=n,e.expanded=!e.expanded}}}}};function $1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-menu",{right:r.right}])},[t.createElementVNode("span",null,[t.renderSlot(e.$slots,"activator",{on:o.on},void 0,!0)]),(t.openBlock(),t.createBlock(t.Teleport,{to:"body"},[t.createVNode(t.Transition,{name:"ux-menu-transition",appear:""},{default:t.withCtx(()=>[s.isExpanded?t.withDirectives((t.openBlock(),t.createElementBlock("div",{key:0,class:"ux-menu-outer",style:t.normalizeStyle(s.outerStyle)},[t.createElementVNode("div",{class:t.normalizeClass(["ux-menu-panel",{flex:r.flex}]),ref:"menu",style:t.normalizeStyle(s.innerStyle)},[t.renderSlot(e.$slots,"default",{},void 0,!0)],6)],4)),[[t.vShow,s.isVisible]]):t.createCommentVNode("",!0)]),_:3})]))],2)}const Jd=w(L1,[["render",$1],["__scopeId","data-v-6be4a759"]]),P1={name:"menulist",props:{items:{type:Array,default(){return[]}},depth:{type:Number,default:0},expandOn:{type:String,default:"none"},isolate:{type:Boolean,default:!0},collapseOnRouteChange:{type:Boolean,default:!0},displayCaret:{type:Boolean,default:!0}},mounted(){this.mounted=!0,this.addRouteChangeListeners()},beforeUnmount(){this.mounted=!1,this.removeRouteChangeListeners(),this.removeListeners()},computed:{actualDepth(){const e=this.depth;return isNaN(e)||!parseInt(e)?0:Math.max(e,0)},filteredItems(){const e=this;let n=e.tree.filter(function(r){return!(r.advancedOptions&&e.$sdk.utils.checkContextVisibility&&!e.$sdk.utils.checkContextVisibility(r.contextVisibility)||r.disabled)});return this.actualDepth===1&&(n=n.map(function(r){return{...r,items:[]}})),n}},data(){return{currentExpandedItems:[],tree:JSON.parse(JSON.stringify(this.items))}},methods:{globalClick(e){this.currentExpandedItems=[]},routeChanged(){this.collapseOnRouteChange&&this.collapseAll()},addRouteChangeListeners(){this.$sdk.addEventListener("route:change",this.routeChanged)},removeRouteChangeListeners(){this.$sdk.removeEventListener("route:change",this.routeChanged)},addListeners(){var n;const e=(n=this.$el)==null?void 0:n.ownerDocument;e&&e.body.addEventListener("click",this.globalClick)},removeListeners(){var n;const e=(n=this.$el)==null?void 0:n.ownerDocument;e&&e.body.removeEventListener("click",this.globalClick)},expandItem(e){e.expanded=!0,this.currentExpandedItems.push(e)},collapseItem(e){const n=this.currentExpandedItems.indexOf(e);n!==-1&&(e.expanded=!1,this.currentExpandedItems.splice(n,1))},collapseAll(){this.currentExpandedItems.forEach(function(e){e.expanded=!1}),this.currentExpandedItems=[],this.currentExpandedItems.length?this.addListeners():this.removeListeners()},toggle(e){const n=e.expanded;this.isolate&&(this.currentExpandedItems.forEach(function(i){i.expanded=!1}),this.currentExpandedItems=[]);const r=this.currentExpandedItems.indexOf(e);n||r!==-1?this.collapseItem(e):this.expandItem(e),this.currentExpandedItems.length?this.addListeners():this.removeListeners()}},watch:{items:{handler(e){this.tree=JSON.parse(JSON.stringify(e))},deep:!0}}};function R1(e,n,r,i,s,o){const l=t.resolveComponent("flex-cell"),a=t.resolveComponent("ux-icon"),c=t.resolveComponent("flex-row"),d=t.resolveComponent("ux-link"),u=t.resolveComponent("menulist",!0);return t.openBlock(),t.createElementBlock("ul",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.filteredItems,m=>{var f;return t.openBlock(),t.createElementBlock("li",{class:t.normalizeClass({expanded:m.expanded,collapsed:!m.expanded}),key:m.title},[r.expandOn==="click"&&((f=m.items)!=null&&f.length)?(t.openBlock(),t.createBlock(d,{key:0,onClick:t.withModifiers(h=>o.toggle(m),["stop","prevent"]),class:t.normalizeClass(m.class)},{default:t.withCtx(()=>[t.createVNode(c,{center:""},{default:t.withCtx(()=>[t.createVNode(l,null,{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(m.title),1)]),_:2},1024),r.displayCaret?(t.openBlock(),t.createBlock(l,{key:0,shrink:""},{default:t.withCtx(()=>[t.createVNode(a,{class:"caret",icon:"fa-angle-down"})]),_:1})):t.createCommentVNode("",!0)]),_:2},1024)]),_:2},1032,["onClick","class"])):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[m.type==="url"?(t.openBlock(),t.createBlock(d,{key:0,class:t.normalizeClass(m.class),target:m.target,href:m.href||m.url},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(m.title),1)]),_:2},1032,["class","target","href"])):m.type==="route"?(t.openBlock(),t.createBlock(d,{key:1,class:t.normalizeClass(m.class),to:{name:m.route}},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(m.title),1)]),_:2},1032,["class","to"])):t.createCommentVNode("",!0)],64)),m.items&&m.items.length?(t.openBlock(),t.createBlock(u,{key:2,expandOn:r.expandOn,items:m.items,displayCaret:r.displayCaret,isolate:r.isolate,depth:o.actualDepth-1},null,8,["expandOn","items","displayCaret","isolate","depth"])):t.createCommentVNode("",!0)],2)}),128))])}const Kd=w(P1,[["render",R1],["__scopeId","data-v-cbfd31c1"]]),U1={props:{item:{type:[Object,String]},alt:{type:String},width:{type:[Number,String]},height:{type:[Number,String]},auto:{type:Boolean,default:!0},inline:{type:Boolean},quality:{type:[Number,String]},contain:{type:Boolean,default:!0},preview:{type:Boolean,default:!1},crop:{type:Boolean},cover:{type:Boolean},format:{type:String},upscale:{type:Boolean,default:!0},type:{type:String,default:"image"},svg:{type:Boolean},lazy:{type:Boolean},eager:{type:Boolean}},data(){return{model:this.item,retries:0,cacheBuster:0,retryTimer:null}},watch:{item(e){this.model=e}},beforeMount(){this.$sdk.auth.ensureValidToken()},mounted(){const e=this.$refs.img;e&&e.addEventListener("error",this.imageLoadError)},beforeUnmount(){const e=this.$refs.img;e&&e.removeEventListener("error",this.imageLoadError)},methods:{imageLoadError(e){const n=this;n.retryTimer&&(clearTimeout(n.retryTimer),n.retryTimer=!1),n.retryTimer=setTimeout(function(){n.retries<5&&(n.cacheBuster++,n.retries++)},500)}},computed:{actualFormat(){var r,i;const e=((r=this.item)==null?void 0:r.fileMime)==="image/heic",n=((i=this.item)==null?void 0:i.fileExtension)==="heic";return e||n?"png":this.format},loading(){if(this.lazy)return"lazy";if(this.eager)return"eager"},altText(){var e;return this.alt||((e=this.model)==null?void 0:e.title)},className(){var e=[];return this.portrait&&e.push("img-portrait"),e.join(" ")},isSvg(){var e;if(this.svg)return!0;switch((e=this.item)==null?void 0:e.fileMime){case"image/svg+xml":case"image/svg":return!0}},portrait(){return this.crop?this.dimensionHeight>this.dimensionWidth:this.modelHeight>this.modelWidth},manualWidth(){return parseInt(this.width)},manualHeight(){return parseInt(this.height)},modelWidth(){var e;return parseInt((e=this.model)==null?void 0:e.width)},modelHeight(){var e;return parseInt((e=this.model)==null?void 0:e.height)},id(){return this.$sdk.utils.id(this.model)},params(){var n,r,i,s;var e={};if(e.access_token=this.$sdk.auth.getCurrentToken(),e.cb=this.cacheBuster,this.manualWidth&&(e.w=this.manualWidth?this.manualWidth:void 0),this.manualHeight&&(e.h=this.manualHeight?this.manualHeight:void 0),this.upscale&&(e.u=!0),this.auto&&!e.w&&!e.h){const o=(s=(i=(r=(n=this.$sdk.app)==null?void 0:n.device)==null?void 0:r.image)==null?void 0:i.auto)==null?void 0:s.med;o&&(e.w=o,e.u=!1)}return this.crop?e.c=!0:this.contain||(e.c=!!parseInt(this.manualWidth)&&!!parseInt(this.manualHeight)),this.quality&&(e.q=parseInt(this.quality)),this.actualFormat&&(e.f=this.actualFormat),e},src(){return this.$sdk.api.generateEndpointURL(`/image/${this.id}`,this.params,{file:!0})},previewSrc(){var e=Object.assign({},this.params);return e.w=50,delete e.h,this.$sdk.api.generateEndpointURL(`/image/${this.id}`,e,{file:!0})},imageStyle(){var e={};return this.crop||(e["object-fit"]="contain"),this.cover&&(e["object-fit"]="cover"),this.inline?e.maxWidth="100%":(e.width="100%",e.height="100%",e.top="0",e.left="0",e.position="absolute"),e},dimensionWidth(){if(this.manualHeight&&this.manualWidth)return this.manualWidth;if(this.modelWidth&&this.modelHeight)return this.modelWidth},dimensionHeight(){if(this.manualHeight&&this.manualWidth)return this.manualHeight;if(this.modelWidth&&this.modelHeight)return this.modelHeight},style(){var r,i,s;var e={};this.inline?e.display="inline-block":this.dimensionHeight&&this.dimensionWidth&&(e.height=0,e.overflow="hidden",e.paddingBottom=`${this.dimensionHeight/this.dimensionWidth*100}%`,e.position="relative");var n=(s=(i=(r=this.model)==null?void 0:r.fileMeta)==null?void 0:i.colors)==null?void 0:s.colors;return n&&n.length&&(e.backgroundColor=n[0]),this.isSvg||this.preview&&(e.backgroundImage=`url(${this.previewSrc})`),e}}},j1=["alt","data"],q1=["loading","alt","src"];function z1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-image",o.className]),style:t.normalizeStyle(o.style)},[r.svg?(t.openBlock(),t.createElementBlock("object",{key:0,alt:o.altText,type:"image/svg+xml",data:o.src},null,8,j1)):(t.openBlock(),t.createElementBlock("img",{key:1,ref:"img",loading:o.loading,alt:o.altText,style:t.normalizeStyle(o.imageStyle),src:o.src},null,12,q1))],6)}const Zd=w(U1,[["render",z1],["__scopeId","data-v-ba449734"]]),W1={props:{item:{type:[Object,String]},width:{type:[Number,String]},height:{type:[Number,String]},controls:{type:Boolean,default:!0},controlslist:{type:String},autoplay:{type:Boolean,default:!1},playsinline:{type:Boolean,default:!1},loop:{type:Boolean,default:!1},muted:{type:Boolean,default:!1}},data(){return{model:this.item,isMuted:this.muted||this.autoplay,playsInline:this.playsinline||this.autoplay}},watch:{playsinline(e){this.playsInline=e},muted(e){this.isMuted=e}},beforeMount(){this.$sdk.auth.ensureValidToken()},computed:{padHeight(){return this.actualHeight&&this.actualWidth?`${this.actualHeight/this.actualWidth*100}%`:void 0},youtubeSrc(){return`https://www.youtube.com/embed/${this.mediaID}`},title(){var e;return(e=this.model)==null?void 0:e.title},mediaID(){var e;return(e=this.model)==null?void 0:e.mediaIntegrationID},mediaType(){var e;return((e=this.model)==null?void 0:e.mediaIntegrationType)||"upload"},mimetype(){var e;return((e=this.model)==null?void 0:e.fileMime)||"video/mp4"},actualWidth(){return parseInt(this.width)||this.modelWidth||1920},actualHeight(){return parseInt(this.height)||this.modelHeight||1080},className(){var e=[];return this.portrait&&e.push("video-portrait"),e.push(`video-type-${this.mediaType}`),e.join(" ")},portrait(){return this.actualHeight>this.actualWidth},modelWidth(){var e;return parseInt(((e=this.model)==null?void 0:e.width)||0)},modelHeight(){var e;return parseInt(((e=this.model)==null?void 0:e.height)||0)},id(){return this.$sdk.utils.id(this.model)},params(){var e={};return e.access_token=this.$sdk.auth.getCurrentToken(),e},src(){return this.$sdk.api.generateEndpointURL(`/video/${this.id}`,this.params,{file:!0})},thumbnailSrc(){var e=Object.assign({},this.params);return e.w=this.actualWidth,e.h=this.actualHeight,delete e.h,this.$sdk.api.generateEndpointURL(`/image/${this.id}/poster.png`,e,{file:!0})},embedStyle(){var e={};return this.padHeight&&(e.height=0,e.paddingBottom=this.padHeight,e.overflow="hidden",e.position="relative"),e}}},H1=["poster","playsinline","muted","loop","autoplay","width","height","controls","controlslist"],G1=["src","type"],Y1=["width","height","src","title"];function J1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["ux-video",o.className])},[o.mediaType==="upload"?(t.openBlock(),t.createElementBlock("div",{key:0,class:"ux-video-embed ux-video-embed-upload",style:t.normalizeStyle(o.embedStyle)},[t.createElementVNode("video",{poster:o.thumbnailSrc,playsinline:s.playsInline,muted:s.isMuted,loop:r.loop,autoplay:r.autoplay,width:o.actualWidth,height:o.actualHeight,controls:r.controls,controlslist:r.controlslist},[t.createElementVNode("source",{src:o.src,type:o.mimetype},null,8,G1),t.createTextVNode(" Your browser does not support the video tag. ")],8,H1)],4)):t.createCommentVNode("",!0),o.mediaType==="youtube"?(t.openBlock(),t.createElementBlock("div",{key:1,class:"ux-video-embed ux-video-embed-youtube",style:t.normalizeStyle(o.embedStyle)},[t.createElementVNode("iframe",{width:o.actualWidth,height:o.actualHeight,src:o.youtubeSrc,title:o.title,frameborder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",allowfullscreen:""},null,8,Y1)],4)):t.createCommentVNode("",!0)],2)}const Xd=w(W1,[["render",J1],["__scopeId","data-v-8f908e0a"]]),K1={props:{value:{type:Number},active:{type:Boolean}},computed:{classes(){var e=[];return e.push(this.icon),this.spin&&e.push("fa-spin"),this.left&&e.push("ux-icon-left"),this.right&&e.push("ux-icon-right"),e},percent(){return this.value},barStyle(){return{width:`${this.percent}%`}},element(){return"i"}}},Z1={class:"ux-progress"};function X1(e,n,r,i,s,o){return t.openBlock(),t.createElementBlock("div",Z1,[t.createElementVNode("div",{class:t.normalizeClass(["ux-progress-bg",{active:r.active}])},null,2),t.createElementVNode("div",{class:"ux-progress-fg",style:t.normalizeStyle(o.barStyle)},null,4)])}const qi=w(K1,[["render",X1],["__scopeId","data-v-6e492d1a"]]),Q1={props:{value:{},tag:{type:String,default:"span"},clickable:{type:Boolean},deleteable:{type:Boolean},icon:{type:String}},computed:{avatar(){var s;const e=(s=this.value)==null?void 0:s._id;if(!e)return;const n=e.slice(8,10)==="24",r=e.slice(8,10)==="70",i=e.slice(8,10)==="71";if(n||r||i)return e},elementType(){return this.tag||"span"},title(){var e,n,r,i,s,o,l,a;return[(e=this.value)==null?void 0:e.title,(n=this.value)==null?void 0:n.name,(r=this.value)!=null&&r.firstName&&((i=this.value)!=null&&i.lastName)?`${(s=this.value)==null?void 0:s.firstName} ${(o=this.value)==null?void 0:o.lastName}`:(l=this.value)==null?void 0:l.firstName,(a=this.value)==null?void 0:a.firstName,this.value].filter(Boolean)[0]},subtitle(){var e;if((e=this.value)!=null&&e.startDate)return this.$sdk.date?this.$sdk.date.readableEventDate(this.value):void 0},hasLink(){return this.tag==="a"||this.clickable},style(){var r,i;const e=(r=this.value)==null?void 0:r.color,n=(i=this.value)==null?void 0:i.bgColor;if(e||n)return{color:e,backgroundColor:n}}}},v1={key:0,class:"pill-avatar"},ex={class:"font-sm font-muted"};function tx(e,n,r,i,s,o){const l=t.resolveComponent("ux-avatar"),a=t.resolveComponent("ux-icon"),c=t.resolveComponent("flex-cell"),d=t.resolveComponent("flex-row");return t.openBlock(),t.createBlock(t.resolveDynamicComponent(o.elementType),{class:t.normalizeClass(["ux-pill",{"has-link":o.hasLink}]),style:t.normalizeStyle(o.style)},{default:t.withCtx(()=>[t.createVNode(d,{gap:"",center:""},{default:t.withCtx(()=>[t.createVNode(c,null,{default:t.withCtx(()=>[o.avatar?(t.openBlock(),t.createElementBlock("div",v1,[t.createVNode(l,{id:o.avatar,initials:o.title},null,8,["id","initials"])])):t.createCommentVNode("",!0),o.subtitle?(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[r.icon?(t.openBlock(),t.createBlock(a,{key:0,icon:r.icon,left:""},null,8,["icon"])):t.createCommentVNode("",!0),t.createTextVNode(t.toDisplayString(o.title),1),t.createElementVNode("span",ex," • "+t.toDisplayString(o.subtitle),1)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:2},[r.icon?(t.openBlock(),t.createBlock(a,{key:0,icon:r.icon,left:""},null,8,["icon"])):t.createCommentVNode("",!0),t.createTextVNode(t.toDisplayString(o.title),1)],64))]),_:1}),r.deleteable?(t.openBlock(),t.createBlock(c,{key:0,shrink:""},{default:t.withCtx(()=>[t.createVNode(a,{icon:"fa-times"})]),_:1})):t.createCommentVNode("",!0)]),_:1})]),_:1},8,["class","style"])}const Qd=w(Q1,[["render",tx],["__scopeId","data-v-709f24b0"]]),nx={},rx={class:"ux-list"};function ox(e,n){return t.openBlock(),t.createElementBlock("ul",rx,[t.renderSlot(e.$slots,"default",{},void 0,!0)])}const vd=w(nx,[["render",ox],["__scopeId","data-v-670de630"]]),ix={props:{to:{type:[Object,String]},href:{type:String},target:{type:String},disabled:{type:Boolean}},computed:{element(){return this.to||this.href?"ux-link":"div"}}};function sx(e,n,r,i,s,o){return t.openBlock(),t.createBlock(t.resolveDynamicComponent(o.element),{class:"ux-list-item",to:r.to,href:r.href,target:r.target,disabled:r.disabled},{default:t.withCtx(()=>[t.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["to","href","target","disabled"])}const eu=w(ix,[["render",sx],["__scopeId","data-v-a5de8929"]]);var K;(function(e){e[e.AM=0]="AM",e[e.PM=1]="PM"})(K||(K={}));var oe;(function(e){e[e.SUNDAY=0]="SUNDAY",e[e.MONDAY=1]="MONDAY",e[e.TUESDAY=2]="TUESDAY",e[e.WEDNESDAY=3]="WEDNESDAY",e[e.THURSDAY=4]="THURSDAY",e[e.FRIDAY=5]="FRIDAY",e[e.SATURDAY=6]="SATURDAY"})(oe||(oe={}));var $e;(function(e){e[e.JANUARY=1]="JANUARY",e[e.FEBRUARY=2]="FEBRUARY",e[e.MARCH=3]="MARCH",e[e.APRIL=4]="APRIL",e[e.MAY=5]="MAY",e[e.JUNE=6]="JUNE",e[e.JULY=7]="JULY",e[e.AUGUST=8]="AUGUST",e[e.SEPTEMBER=9]="SEPTEMBER",e[e.OCTOBER=10]="OCTOBER",e[e.NOVEMBER=11]="NOVEMBER",e[e.DECEMBER=12]="DECEMBER"})($e||($e={}));function Rt(e,n){e.assign("day",n.getDate()),e.assign("month",n.getMonth()+1),e.assign("year",n.getFullYear())}function tu(e,n){e.assign("hour",n.getHours()),e.assign("minute",n.getMinutes()),e.assign("second",n.getSeconds()),e.assign("millisecond",n.getMilliseconds()),e.assign("meridiem",n.getHours()<12?K.AM:K.PM)}function sn(e,n){e.imply("day",n.getDate()),e.imply("month",n.getMonth()+1),e.imply("year",n.getFullYear())}function zi(e,n){e.imply("hour",n.getHours()),e.imply("minute",n.getMinutes()),e.imply("second",n.getSeconds()),e.imply("millisecond",n.getMilliseconds()),e.imply("meridiem",n.getHours()<12?K.AM:K.PM)}const lx={ACDT:630,ACST:570,ADT:-180,AEDT:660,AEST:600,AFT:270,AKDT:-480,AKST:-540,ALMT:360,AMST:-180,AMT:-240,ANAST:720,ANAT:720,AQTT:300,ART:-180,AST:-240,AWDT:540,AWST:480,AZOST:0,AZOT:-60,AZST:300,AZT:240,BNT:480,BOT:-240,BRST:-120,BRT:-180,BST:60,BTT:360,CAST:480,CAT:120,CCT:390,CDT:-300,CEST:120,CET:{timezoneOffsetDuringDst:2*60,timezoneOffsetNonDst:60,dstStart:e=>nu(e,$e.MARCH,oe.SUNDAY,2),dstEnd:e=>nu(e,$e.OCTOBER,oe.SUNDAY,3)},CHADT:825,CHAST:765,CKT:-600,CLST:-180,CLT:-240,COT:-300,CST:-360,CT:{timezoneOffsetDuringDst:-5*60,timezoneOffsetNonDst:-6*60,dstStart:e=>pt(e,$e.MARCH,oe.SUNDAY,2,2),dstEnd:e=>pt(e,$e.NOVEMBER,oe.SUNDAY,1,2)},CVT:-60,CXT:420,ChST:600,DAVT:420,EASST:-300,EAST:-360,EAT:180,ECT:-300,EDT:-240,EEST:180,EET:120,EGST:0,EGT:-60,EST:-300,ET:{timezoneOffsetDuringDst:-4*60,timezoneOffsetNonDst:-5*60,dstStart:e=>pt(e,$e.MARCH,oe.SUNDAY,2,2),dstEnd:e=>pt(e,$e.NOVEMBER,oe.SUNDAY,1,2)},FJST:780,FJT:720,FKST:-180,FKT:-240,FNT:-120,GALT:-360,GAMT:-540,GET:240,GFT:-180,GILT:720,GMT:0,GST:240,GYT:-240,HAA:-180,HAC:-300,HADT:-540,HAE:-240,HAP:-420,HAR:-360,HAST:-600,HAT:-90,HAY:-480,HKT:480,HLV:-210,HNA:-240,HNC:-360,HNE:-300,HNP:-480,HNR:-420,HNT:-150,HNY:-540,HOVT:420,ICT:420,IDT:180,IOT:360,IRDT:270,IRKST:540,IRKT:540,IRST:210,IST:330,JST:540,KGT:360,KRAST:480,KRAT:480,KST:540,KUYT:240,LHDT:660,LHST:630,LINT:840,MAGST:720,MAGT:720,MART:-510,MAWT:300,MDT:-360,MESZ:120,MEZ:60,MHT:720,MMT:390,MSD:240,MSK:180,MST:-420,MT:{timezoneOffsetDuringDst:-6*60,timezoneOffsetNonDst:-7*60,dstStart:e=>pt(e,$e.MARCH,oe.SUNDAY,2,2),dstEnd:e=>pt(e,$e.NOVEMBER,oe.SUNDAY,1,2)},MUT:240,MVT:300,MYT:480,NCT:660,NDT:-90,NFT:690,NOVST:420,NOVT:360,NPT:345,NST:-150,NUT:-660,NZDT:780,NZST:720,OMSST:420,OMST:420,PDT:-420,PET:-300,PETST:720,PETT:720,PGT:600,PHOT:780,PHT:480,PKT:300,PMDT:-120,PMST:-180,PONT:660,PST:-480,PT:{timezoneOffsetDuringDst:-7*60,timezoneOffsetNonDst:-8*60,dstStart:e=>pt(e,$e.MARCH,oe.SUNDAY,2,2),dstEnd:e=>pt(e,$e.NOVEMBER,oe.SUNDAY,1,2)},PWT:540,PYST:-180,PYT:-240,RET:240,SAMT:240,SAST:120,SBT:660,SCT:240,SGT:480,SRT:-180,SST:-660,TAHT:-600,TFT:300,TJT:300,TKT:780,TLT:540,TMT:300,TVT:720,ULAT:480,UTC:0,UYST:-120,UYT:-180,UZT:300,VET:-210,VLAST:660,VLAT:660,VUT:660,WAST:120,WAT:60,WEST:60,WESZ:60,WET:0,WEZ:0,WFT:720,WGST:-120,WGT:-180,WIB:420,WIT:540,WITA:480,WST:780,WT:0,YAKST:600,YAKT:600,YAPT:600,YEKST:360,YEKT:360};function pt(e,n,r,i,s=0){let o=0,l=0;for(;l<i;)o++,new Date(e,n-1,o).getDay()===r&&l++;return new Date(e,n-1,o,s)}function nu(e,n,r,i=0){const s=r===0?7:r,o=new Date(e,n-1+1,1,12),l=o.getDay()===0?7:o.getDay();let a;return l===s?a=7:l<s?a=7+l-s:a=l-s,o.setDate(o.getDate()-a),new Date(e,n-1,o.getDate(),i)}function ru(e,n,r={}){if(e==null)return null;if(typeof e=="number")return e;const i=r[e]??lx[e];return i==null?null:typeof i=="number"?i:n==null?null:n>i.dstStart(n.getFullYear())&&!(n>i.dstEnd(n.getFullYear()))?i.timezoneOffsetDuringDst:i.timezoneOffsetNonDst}const ax={day:0,second:0,millisecond:0};function Ee(e,n){let r=new Date(e);if(n.y&&(n.year=n.y,delete n.y),n.mo&&(n.month=n.mo,delete n.mo),n.M&&(n.month=n.M,delete n.M),n.w&&(n.week=n.w,delete n.w),n.d&&(n.day=n.d,delete n.d),n.h&&(n.hour=n.h,delete n.h),n.m&&(n.minute=n.m,delete n.m),n.s&&(n.second=n.s,delete n.s),n.ms&&(n.millisecond=n.ms,delete n.ms),"year"in n){const i=Math.floor(n.year);r.setFullYear(r.getFullYear()+i);const s=n.year-i;s>0&&(n.month=(n==null?void 0:n.month)??0,n.month+=s*12)}if("quarter"in n){const i=Math.floor(n.quarter);r.setMonth(r.getMonth()+i*3)}if("month"in n){const i=Math.floor(n.month);r.setMonth(r.getMonth()+i);const s=n.month-i;s>0&&(n.week=(n==null?void 0:n.week)??0,n.week+=s*4)}if("week"in n){const i=Math.floor(n.week);r.setDate(r.getDate()+i*7);const s=n.week-i;s>0&&(n.day=(n==null?void 0:n.day)??0,n.day+=Math.round(s*7))}if("day"in n){const i=Math.floor(n.day);r.setDate(r.getDate()+i);const s=n.day-i;s>0&&(n.hour=(n==null?void 0:n.hour)??0,n.hour+=Math.round(s*24))}if("hour"in n){const i=Math.floor(n.hour);r.setHours(r.getHours()+i);const s=n.hour-i;s>0&&(n.minute=(n==null?void 0:n.minute)??0,n.minute+=Math.round(s*60))}if("minute"in n){const i=Math.floor(n.minute);r.setMinutes(r.getMinutes()+i);const s=n.minute-i;s>0&&(n.second=(n==null?void 0:n.second)??0,n.second+=Math.round(s*60))}if("second"in n){const i=Math.floor(n.second);r.setSeconds(r.getSeconds()+i);const s=n.second-i;s>0&&(n.millisecond=(n==null?void 0:n.millisecond)??0,n.millisecond+=Math.round(s*1e3))}if("millisecond"in n){const i=Math.floor(n.millisecond);r.setMilliseconds(r.getMilliseconds()+i)}return r}function _r(e){const n={};for(const r in e)n[r]=-e[r];return n}class gt{constructor(n,r){W(this,"instant");W(this,"timezoneOffset");this.instant=n??new Date,this.timezoneOffset=r??null}static fromDate(n){return new gt(n)}static fromInput(n,r){if(n instanceof Date)return gt.fromDate(n);const i=(n==null?void 0:n.instant)??new Date,s=ru(n==null?void 0:n.timezone,i,r);return new gt(i,s)}getDateWithAdjustedTimezone(){const n=new Date(this.instant);return this.timezoneOffset!==null&&n.setMinutes(n.getMinutes()-this.getSystemTimezoneAdjustmentMinute(this.instant)),n}getSystemTimezoneAdjustmentMinute(n,r){(!n||n.getTime()<0)&&(n=new Date);const i=-n.getTimezoneOffset(),s=r??this.timezoneOffset??i;return i-s}getTimezoneOffset(){return this.timezoneOffset??-this.instant.getTimezoneOffset()}}class ee{constructor(n,r){W(this,"knownValues");W(this,"impliedValues");W(this,"reference");W(this,"_tags",new Set);if(this.reference=n,this.knownValues={},this.impliedValues={},r)for(const s in r)this.knownValues[s]=r[s];const i=n.getDateWithAdjustedTimezone();this.imply("day",i.getDate()),this.imply("month",i.getMonth()+1),this.imply("year",i.getFullYear()),this.imply("hour",12),this.imply("minute",0),this.imply("second",0),this.imply("millisecond",0)}static createRelativeFromReference(n,r=ax){let i=Ee(n.getDateWithAdjustedTimezone(),r);const s=new ee(n);return s.addTag("result/relativeDate"),"hour"in r||"minute"in r||"second"in r||"millisecond"in r?(s.addTag("result/relativeDateAndTime"),tu(s,i),Rt(s,i),s.assign("timezoneOffset",n.getTimezoneOffset())):(zi(s,i),s.imply("timezoneOffset",n.getTimezoneOffset()),"day"in r?(s.assign("day",i.getDate()),s.assign("month",i.getMonth()+1),s.assign("year",i.getFullYear()),s.assign("weekday",i.getDay())):"week"in r?(s.assign("day",i.getDate()),s.assign("month",i.getMonth()+1),s.assign("year",i.getFullYear()),s.imply("weekday",i.getDay())):(s.imply("day",i.getDate()),"month"in r?(s.assign("month",i.getMonth()+1),s.assign("year",i.getFullYear())):(s.imply("month",i.getMonth()+1),"year"in r?s.assign("year",i.getFullYear()):s.imply("year",i.getFullYear())))),s}get(n){return n in this.knownValues?this.knownValues[n]:n in this.impliedValues?this.impliedValues[n]:null}isCertain(n){return n in this.knownValues}getCertainComponents(){return Object.keys(this.knownValues)}imply(n,r){return n in this.knownValues?this:(this.impliedValues[n]=r,this)}assign(n,r){return this.knownValues[n]=r,delete this.impliedValues[n],this}addDurationAsImplied(n){const r=this.dateWithoutTimezoneAdjustment(),i=Ee(r,n);return("day"in n||"week"in n||"month"in n||"year"in n)&&(this.delete(["day","weekday","month","year"]),this.imply("day",i.getDate()),this.imply("weekday",i.getDay()),this.imply("month",i.getMonth()+1),this.imply("year",i.getFullYear())),("second"in n||"minute"in n||"hour"in n)&&(this.delete(["second","minute","hour"]),this.imply("second",i.getSeconds()),this.imply("minute",i.getMinutes()),this.imply("hour",i.getHours())),this}delete(n){typeof n=="string"&&(n=[n]);for(const r of n)delete this.knownValues[r],delete this.impliedValues[r]}clone(){const n=new ee(this.reference);n.knownValues={},n.impliedValues={};for(const r in this.knownValues)n.knownValues[r]=this.knownValues[r];for(const r in this.impliedValues)n.impliedValues[r]=this.impliedValues[r];return n}isOnlyDate(){return!this.isCertain("hour")&&!this.isCertain("minute")&&!this.isCertain("second")}isOnlyTime(){return!this.isCertain("weekday")&&!this.isCertain("day")&&!this.isCertain("month")&&!this.isCertain("year")}isOnlyWeekdayComponent(){return this.isCertain("weekday")&&!this.isCertain("day")&&!this.isCertain("month")}isDateWithUnknownYear(){return this.isCertain("month")&&!this.isCertain("year")}isValidDate(){const n=this.dateWithoutTimezoneAdjustment();return!(n.getFullYear()!==this.get("year")||n.getMonth()!==this.get("month")-1||n.getDate()!==this.get("day")||this.get("hour")!=null&&n.getHours()!=this.get("hour")||this.get("minute")!=null&&n.getMinutes()!=this.get("minute"))}toString(){return`[ParsingComponents {
|
|
2
2
|
tags: ${JSON.stringify(Array.from(this._tags).sort())},
|
|
3
3
|
knownValues: ${JSON.stringify(this.knownValues)},
|
|
4
4
|
impliedValues: ${JSON.stringify(this.impliedValues)}},
|