@farris/ui-vue
Version:
Farris Vue, a Farris Design based Vue3 component library.
1 lines • 360 kB
JavaScript
(function(Z,r){typeof exports=="object"&&typeof module<"u"?r(exports,require("vue"),require("lodash-es"),require("../common/index.umd.js"),require("../button-edit/index.umd.js"),require("../number-spinner/index.umd.js"),require("../../designer/button-edit/index.umd.js"),require("../designer-canvas/index.umd.js"),require("@vueuse/core"),require("../data-view/index.umd.js"),require("../modal/index.umd.js"),require("../transfer/index.umd.js"),require("../tabs/index.umd.js"),require("../order/index.umd.js"),require("../condition/index.umd.js"),require("../checkbox/index.umd.js"),require("../filter-bar/index.umd.js"),require("../tooltip/index.umd.js"),require("../pagination/index.umd.js"),require("../button/index.umd.js"),require("../search-box/index.umd.js"),require("../tags/index.umd.js"),require("../dynamic-form/index.umd.js"),require("../dynamic-resolver/index.umd.js"),require("../property-panel/index.umd.js"),require("../accordion/index.umd.js"),require("../avatar/index.umd.js"),require("../button-group/index.umd.js"),require("../calendar/index.umd.js"),require("../capsule/index.umd.js"),require("../../designer/checkbox/index.umd.js"),require("../../designer/checkbox-group/index.umd.js"),require("../combo-list/index.umd.js"),require("../combo-tree/index.umd.js"),require("../component/index.umd.js"),require("../color-picker/index.umd.js"),require("../content-container/index.umd.js"),require("../date-picker/index.umd.js"),require("../../designer/data-grid/index.umd.js"),require("../dropdown/index.umd.js"),require("../events-editor/index.umd.js"),require("../field-selector/index.umd.js"),require("../binding-selector/index.umd.js"),require("../image-cropper/index.umd.js"),require("../../designer/input-group/index.umd.js"),require("../layout/index.umd.js"),require("../list-nav/index.umd.js"),require("../list-view/index.umd.js"),require("../lookup/index.umd.js"),require("../mapping-editor/index.umd.js"),require("../nav/index.umd.js"),require("../number-range/index.umd.js"),require("../page-header/index.umd.js"),require("../page-footer/index.umd.js"),require("../progress/index.umd.js"),require("../query-solution/index.umd.js"),require("../../designer/radio-group/index.umd.js"),require("../rate/index.umd.js"),require("../response-toolbar/index.umd.js"),require("../response-layout/index.umd.js"),require("../response-layout-editor/index.umd.js"),require("../section/index.umd.js"),require("../smoke-detector/index.umd.js"),require("../splitter/index.umd.js"),require("../step/index.umd.js"),require("../switch/index.umd.js"),require("../text/index.umd.js"),require("../time-picker/index.umd.js"),require("../tree-view/index.umd.js"),require("../uploader/index.umd.js"),require("../verify-detail/index.umd.js"),require("../video/index.umd.js"),require("../textarea/index.umd.js"),require("../schema-selector/index.umd.js"),require("../tree-grid/index.umd.js"),require("../event-parameter/index.umd.js"),require("../filter-condition-editor/index.umd.js"),require("../fieldset/index.umd.js"),require("../sort-condition-editor/index.umd.js"),require("../menu-lookup/index.umd.js"),require("../drawer/index.umd.js"),require("../json-editor/index.umd.js"),require("../property-editor/index.umd.js"),require("../expression-editor/index.umd.js"),require("../code-editor/index.umd.js"),require("../html-template/index.umd.js"),require("../external-container/index.umd.js"),require("../notify/index.umd.js")):typeof define=="function"&&define.amd?define(["exports","vue","lodash-es","../common/index.umd.js","../button-edit/index.umd.js","../number-spinner/index.umd.js","../../designer/button-edit/index.umd.js","../designer-canvas/index.umd.js","@vueuse/core","../data-view/index.umd.js","../modal/index.umd.js","../transfer/index.umd.js","../tabs/index.umd.js","../order/index.umd.js","../condition/index.umd.js","../checkbox/index.umd.js","../filter-bar/index.umd.js","../tooltip/index.umd.js","../pagination/index.umd.js","../button/index.umd.js","../search-box/index.umd.js","../tags/index.umd.js","../dynamic-form/index.umd.js","../dynamic-resolver/index.umd.js","../property-panel/index.umd.js","../accordion/index.umd.js","../avatar/index.umd.js","../button-group/index.umd.js","../calendar/index.umd.js","../capsule/index.umd.js","../../designer/checkbox/index.umd.js","../../designer/checkbox-group/index.umd.js","../combo-list/index.umd.js","../combo-tree/index.umd.js","../component/index.umd.js","../color-picker/index.umd.js","../content-container/index.umd.js","../date-picker/index.umd.js","../../designer/data-grid/index.umd.js","../dropdown/index.umd.js","../events-editor/index.umd.js","../field-selector/index.umd.js","../binding-selector/index.umd.js","../image-cropper/index.umd.js","../../designer/input-group/index.umd.js","../layout/index.umd.js","../list-nav/index.umd.js","../list-view/index.umd.js","../lookup/index.umd.js","../mapping-editor/index.umd.js","../nav/index.umd.js","../number-range/index.umd.js","../page-header/index.umd.js","../page-footer/index.umd.js","../progress/index.umd.js","../query-solution/index.umd.js","../../designer/radio-group/index.umd.js","../rate/index.umd.js","../response-toolbar/index.umd.js","../response-layout/index.umd.js","../response-layout-editor/index.umd.js","../section/index.umd.js","../smoke-detector/index.umd.js","../splitter/index.umd.js","../step/index.umd.js","../switch/index.umd.js","../text/index.umd.js","../time-picker/index.umd.js","../tree-view/index.umd.js","../uploader/index.umd.js","../verify-detail/index.umd.js","../video/index.umd.js","../textarea/index.umd.js","../schema-selector/index.umd.js","../tree-grid/index.umd.js","../event-parameter/index.umd.js","../filter-condition-editor/index.umd.js","../fieldset/index.umd.js","../sort-condition-editor/index.umd.js","../menu-lookup/index.umd.js","../drawer/index.umd.js","../json-editor/index.umd.js","../property-editor/index.umd.js","../expression-editor/index.umd.js","../code-editor/index.umd.js","../html-template/index.umd.js","../external-container/index.umd.js","../notify/index.umd.js"],r):(Z=typeof globalThis<"u"?globalThis:Z||self,r(Z["date-picker"]={},Z.Vue,Z.LodashES,Z.common,Z.FButtonEdit,Z.FNumberSpinner,Z.FButtonEdit$1,Z.designerCanvas,Z.VueUseCore,Z.dataView,null,Z.FTransfer,Z.FTabs,Z.FOrder,null,Z.checkbox,Z.FFilterBar,Z.FTooltip,Z.FPagination,Z.FButton$1,Z.FSearchBox,Z.FTags,Z.FDynamicForm,Z.dynamicResolver,null,Z.FAccordion,Z.FAvatar,Z.FButtonGroup,Z.FCalendar,Z.FCapsule,Z.FCheckbox,Z.FCheckboxGroup,Z.FComboList,Z.FComboTree,Z.FComponent,Z.FColorPicker,Z.FContentContainer,Z.FDatePicker,Z.FDataGrid,Z.FDropdown,Z.FEventsEditor,Z.FFieldSelector,Z.FBindingSelector,Z.FImageCropper,Z.FInputGroup$1,Z.FLayout,Z.FListNav,Z.FListView,Z.FLookup,Z.FMappingEditor,Z.FNav,Z.FNumberRange,Z.FPageHeader,Z.FPageFooter,Z.FProgress,Z.FQuerySolution,Z.FRadioGroup,Z.FRate,Z.FResponseToolbar,Z.FResponseLayout,Z.FResponseLayoutEditorSetting,Z.FSection,Z.FSmokeDetector,Z.FSplitter,Z.FStep,Z.FSwitch,Z.FText,Z.FTimePicker,Z.FTreeview,Z.FUploader,Z.FVerifyDetail,Z.FVideo,Z.FTextArea,Z.FSchemaSelector,Z.FTreeGrid$1,Z.FEventParameter,Z.FFilterConditionEditor,Z.FFieldset,Z.FSortConditionEditor,Z.FMenuLookup,Z.FDrawer,Z.FJsonEditor,Z.FPropertyEditor,Z.FExpressionEditor,Z.FCodeEditor,Z.FHtmlTemplate))})(this,function(Z,r,Fe,Ve,dr,Ut,qn,Yn,zn,Pe,Gu,fr,mr,hr,Uu,pr,yr,Gn,gr,vr,br,wr,bn,Cr,Xu,xr,Mr,Tr,kr,Sr,Un,Xn,wn,_r,Vr,Nr,Or,Fr,Pr,Er,Ir,Dr,Br,jr,Hr,Rr,$r,Lr,Wr,Ar,qr,Yr,zr,Gr,Ur,Xr,Qr,Kr,Jr,Zr,ea,ta,na,oa,ra,aa,ia,sa,la,ca,ua,da,fa,ma,ha,pa,ya,ga,va,ba,wa,Ca,xa,Ma,Ta,ka){"use strict";var Yu=Object.defineProperty;var zu=(Z,r,Fe)=>r in Z?Yu(Z,r,{enumerable:!0,configurable:!0,writable:!0,value:Fe}):Z[r]=Fe;var R=(Z,r,Fe)=>zu(Z,typeof r!="symbol"?r+"":r,Fe);const Xt=["日","一","二","三","四","五","六"];var it=(t=>(t[t.previous=1]="previous",t[t.current=2]="current",t[t.next=3]="next",t))(it||{});const Qn={dates:{Type:Array,default:[]},daysInWeek:{Type:Array,default:Xt},enableKeyboadNavigate:{Type:Boolean,default:!0},enableMarkCurrent:{Type:Boolean,default:!0},enablePeriod:{Type:Boolean,default:!1},firstDayOfTheWeek:{Type:Boolean,default:"Sun."},selected:{Type:Object,default:null},selectedPeriod:{Type:Object,default:null},selectedWeek:{Type:Object,default:null},selectMode:{Type:String,default:"day"},showWeekNumber:{Type:Boolean,default:!1},weekTitle:{Type:String,default:"Week"}};var wt=(t=>(t[t.enter=13]="enter",t[t.esc=27]="esc",t[t.space=32]="space",t[t.leftArrow=37]="leftArrow",t[t.upArrow=38]="upArrow",t[t.rightArrow=39]="rightArrow",t[t.downArrow=40]="downArrow",t[t.tab=9]="tab",t[t.shift=16]="shift",t))(wt||{});function Cn(){function t(n){const e=n.key||n.keyCode;return e==="Enter"||e===13?13:e==="Escape"||e===27?27:e===" "||e===32?32:e==="ArrowLeft"||e===37?37:e==="ArrowUp"||e===38?38:e==="ArrowRight"||e===39?39:e==="ArrowDown"||e===40?40:e==="Tab"||e===9?9:e==="Shift"||e===16?16:-1}return{getKeyCodeFromEvent:t}}function Ze(t){const n=Object.prototype.toString.call(t);return t instanceof Date||typeof t=="object"&&n==="[object Date]"?new t.constructor(+t):typeof t=="number"||n==="[object Number]"||typeof t=="string"||n==="[object String]"?new Date(t):new Date(NaN)}function ze(t,n){return t instanceof Date?new t.constructor(n):new Date(n)}function Kn(t,n){const e=Ze(t);return isNaN(n)?ze(t,NaN):(n&&e.setDate(e.getDate()+n),e)}const Jn=6048e5,Sa=864e5,_a=6e4,Va=36e5,Na=1e3;let Oa={};function Lt(){return Oa}function Ot(t,n){var c,u,d,h;const e=Lt(),o=(n==null?void 0:n.weekStartsOn)??((u=(c=n==null?void 0:n.locale)==null?void 0:c.options)==null?void 0:u.weekStartsOn)??e.weekStartsOn??((h=(d=e.locale)==null?void 0:d.options)==null?void 0:h.weekStartsOn)??0,a=Ze(t),i=a.getDay(),s=(i<o?7:0)+i-o;return a.setDate(a.getDate()-s),a.setHours(0,0,0,0),a}function Wt(t){return Ot(t,{weekStartsOn:1})}function Zn(t){const n=Ze(t),e=n.getFullYear(),o=ze(t,0);o.setFullYear(e+1,0,4),o.setHours(0,0,0,0);const a=Wt(o),i=ze(t,0);i.setFullYear(e,0,4),i.setHours(0,0,0,0);const s=Wt(i);return n.getTime()>=a.getTime()?e+1:n.getTime()>=s.getTime()?e:e-1}function eo(t){const n=Ze(t);return n.setHours(0,0,0,0),n}function on(t){const n=Ze(t),e=new Date(Date.UTC(n.getFullYear(),n.getMonth(),n.getDate(),n.getHours(),n.getMinutes(),n.getSeconds(),n.getMilliseconds()));return e.setUTCFullYear(n.getFullYear()),+t-+e}function Fa(t,n){const e=eo(t),o=eo(n),a=+e-on(e),i=+o-on(o);return Math.round((a-i)/Sa)}function Pa(t){const n=Zn(t),e=ze(t,0);return e.setFullYear(n,0,4),e.setHours(0,0,0,0),Wt(e)}function Ea(t){return t instanceof Date||typeof t=="object"&&Object.prototype.toString.call(t)==="[object Date]"}function xn(t){if(!Ea(t)&&typeof t!="number")return!1;const n=Ze(t);return!isNaN(Number(n))}function Ia(t){const n=Ze(t),e=ze(t,0);return e.setFullYear(n.getFullYear(),0,1),e.setHours(0,0,0,0),e}const Da={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},Ba=(t,n,e)=>{let o;const a=Da[t];return typeof a=="string"?o=a:n===1?o=a.one:o=a.other.replace("{{count}}",n.toString()),e!=null&&e.addSuffix?e.comparison&&e.comparison>0?"in "+o:o+" ago":o};function Mn(t){return(n={})=>{const e=n.width?String(n.width):t.defaultWidth;return t.formats[e]||t.formats[t.defaultWidth]}}const ja={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Ha={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Ra={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},$a={date:Mn({formats:ja,defaultWidth:"full"}),time:Mn({formats:Ha,defaultWidth:"full"}),dateTime:Mn({formats:Ra,defaultWidth:"full"})},La={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Wa=(t,n,e,o)=>La[t];function Qt(t){return(n,e)=>{const o=e!=null&&e.context?String(e.context):"standalone";let a;if(o==="formatting"&&t.formattingValues){const s=t.defaultFormattingWidth||t.defaultWidth,c=e!=null&&e.width?String(e.width):s;a=t.formattingValues[c]||t.formattingValues[s]}else{const s=t.defaultWidth,c=e!=null&&e.width?String(e.width):t.defaultWidth;a=t.values[c]||t.values[s]}const i=t.argumentCallback?t.argumentCallback(n):n;return a[i]}}const Aa={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},qa={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Ya={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},za={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Ga={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},Ua={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},Xa={ordinalNumber:(t,n)=>{const e=Number(t),o=e%100;if(o>20||o<10)switch(o%10){case 1:return e+"st";case 2:return e+"nd";case 3:return e+"rd"}return e+"th"},era:Qt({values:Aa,defaultWidth:"wide"}),quarter:Qt({values:qa,defaultWidth:"wide",argumentCallback:t=>t-1}),month:Qt({values:Ya,defaultWidth:"wide"}),day:Qt({values:za,defaultWidth:"wide"}),dayPeriod:Qt({values:Ga,defaultWidth:"wide",formattingValues:Ua,defaultFormattingWidth:"wide"})};function Kt(t){return(n,e={})=>{const o=e.width,a=o&&t.matchPatterns[o]||t.matchPatterns[t.defaultMatchWidth],i=n.match(a);if(!i)return null;const s=i[0],c=o&&t.parsePatterns[o]||t.parsePatterns[t.defaultParseWidth],u=Array.isArray(c)?Ka(c,l=>l.test(s)):Qa(c,l=>l.test(s));let d;d=t.valueCallback?t.valueCallback(u):u,d=e.valueCallback?e.valueCallback(d):d;const h=n.slice(s.length);return{value:d,rest:h}}}function Qa(t,n){for(const e in t)if(Object.prototype.hasOwnProperty.call(t,e)&&n(t[e]))return e}function Ka(t,n){for(let e=0;e<t.length;e++)if(n(t[e]))return e}function Ja(t){return(n,e={})=>{const o=n.match(t.matchPattern);if(!o)return null;const a=o[0],i=n.match(t.parsePattern);if(!i)return null;let s=t.valueCallback?t.valueCallback(i[0]):i[0];s=e.valueCallback?e.valueCallback(s):s;const c=n.slice(a.length);return{value:s,rest:c}}}const Za=/^(\d+)(th|st|nd|rd)?/i,ei=/\d+/i,ti={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},ni={any:[/^b/i,/^(a|c)/i]},oi={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},ri={any:[/1/i,/2/i,/3/i,/4/i]},ai={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},ii={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},si={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},li={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},ci={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},ui={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},di={ordinalNumber:Ja({matchPattern:Za,parsePattern:ei,valueCallback:t=>parseInt(t,10)}),era:Kt({matchPatterns:ti,defaultMatchWidth:"wide",parsePatterns:ni,defaultParseWidth:"any"}),quarter:Kt({matchPatterns:oi,defaultMatchWidth:"wide",parsePatterns:ri,defaultParseWidth:"any",valueCallback:t=>t+1}),month:Kt({matchPatterns:ai,defaultMatchWidth:"wide",parsePatterns:ii,defaultParseWidth:"any"}),day:Kt({matchPatterns:si,defaultMatchWidth:"wide",parsePatterns:li,defaultParseWidth:"any"}),dayPeriod:Kt({matchPatterns:ci,defaultMatchWidth:"any",parsePatterns:ui,defaultParseWidth:"any"})},to={code:"en-US",formatDistance:Ba,formatLong:$a,formatRelative:Wa,localize:Xa,match:di,options:{weekStartsOn:0,firstWeekContainsDate:1}};function fi(t){const n=Ze(t);return Fa(n,Ia(n))+1}function no(t){const n=Ze(t),e=+Wt(n)-+Pa(n);return Math.round(e/Jn)+1}function Tn(t,n){var h,l,f,m;const e=Ze(t),o=e.getFullYear(),a=Lt(),i=(n==null?void 0:n.firstWeekContainsDate)??((l=(h=n==null?void 0:n.locale)==null?void 0:h.options)==null?void 0:l.firstWeekContainsDate)??a.firstWeekContainsDate??((m=(f=a.locale)==null?void 0:f.options)==null?void 0:m.firstWeekContainsDate)??1,s=ze(t,0);s.setFullYear(o+1,0,i),s.setHours(0,0,0,0);const c=Ot(s,n),u=ze(t,0);u.setFullYear(o,0,i),u.setHours(0,0,0,0);const d=Ot(u,n);return e.getTime()>=c.getTime()?o+1:e.getTime()>=d.getTime()?o:o-1}function mi(t,n){var c,u,d,h;const e=Lt(),o=(n==null?void 0:n.firstWeekContainsDate)??((u=(c=n==null?void 0:n.locale)==null?void 0:c.options)==null?void 0:u.firstWeekContainsDate)??e.firstWeekContainsDate??((h=(d=e.locale)==null?void 0:d.options)==null?void 0:h.firstWeekContainsDate)??1,a=Tn(t,n),i=ze(t,0);return i.setFullYear(a,0,o),i.setHours(0,0,0,0),Ot(i,n)}function oo(t,n){const e=Ze(t),o=+Ot(e,n)-+mi(e,n);return Math.round(o/Jn)+1}function Be(t,n){const e=t<0?"-":"",o=Math.abs(t).toString().padStart(n,"0");return e+o}const Ft={y(t,n){const e=t.getFullYear(),o=e>0?e:1-e;return Be(n==="yy"?o%100:o,n.length)},M(t,n){const e=t.getMonth();return n==="M"?String(e+1):Be(e+1,2)},d(t,n){return Be(t.getDate(),n.length)},a(t,n){const e=t.getHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return e.toUpperCase();case"aaa":return e;case"aaaaa":return e[0];case"aaaa":default:return e==="am"?"a.m.":"p.m."}},h(t,n){return Be(t.getHours()%12||12,n.length)},H(t,n){return Be(t.getHours(),n.length)},m(t,n){return Be(t.getMinutes(),n.length)},s(t,n){return Be(t.getSeconds(),n.length)},S(t,n){const e=n.length,o=t.getMilliseconds(),a=Math.trunc(o*Math.pow(10,e-3));return Be(a,n.length)}},At={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},ro={G:function(t,n,e){const o=t.getFullYear()>0?1:0;switch(n){case"G":case"GG":case"GGG":return e.era(o,{width:"abbreviated"});case"GGGGG":return e.era(o,{width:"narrow"});case"GGGG":default:return e.era(o,{width:"wide"})}},y:function(t,n,e){if(n==="yo"){const o=t.getFullYear(),a=o>0?o:1-o;return e.ordinalNumber(a,{unit:"year"})}return Ft.y(t,n)},Y:function(t,n,e,o){const a=Tn(t,o),i=a>0?a:1-a;if(n==="YY"){const s=i%100;return Be(s,2)}return n==="Yo"?e.ordinalNumber(i,{unit:"year"}):Be(i,n.length)},R:function(t,n){const e=Zn(t);return Be(e,n.length)},u:function(t,n){const e=t.getFullYear();return Be(e,n.length)},Q:function(t,n,e){const o=Math.ceil((t.getMonth()+1)/3);switch(n){case"Q":return String(o);case"QQ":return Be(o,2);case"Qo":return e.ordinalNumber(o,{unit:"quarter"});case"QQQ":return e.quarter(o,{width:"abbreviated",context:"formatting"});case"QQQQQ":return e.quarter(o,{width:"narrow",context:"formatting"});case"QQQQ":default:return e.quarter(o,{width:"wide",context:"formatting"})}},q:function(t,n,e){const o=Math.ceil((t.getMonth()+1)/3);switch(n){case"q":return String(o);case"qq":return Be(o,2);case"qo":return e.ordinalNumber(o,{unit:"quarter"});case"qqq":return e.quarter(o,{width:"abbreviated",context:"standalone"});case"qqqqq":return e.quarter(o,{width:"narrow",context:"standalone"});case"qqqq":default:return e.quarter(o,{width:"wide",context:"standalone"})}},M:function(t,n,e){const o=t.getMonth();switch(n){case"M":case"MM":return Ft.M(t,n);case"Mo":return e.ordinalNumber(o+1,{unit:"month"});case"MMM":return e.month(o,{width:"abbreviated",context:"formatting"});case"MMMMM":return e.month(o,{width:"narrow",context:"formatting"});case"MMMM":default:return e.month(o,{width:"wide",context:"formatting"})}},L:function(t,n,e){const o=t.getMonth();switch(n){case"L":return String(o+1);case"LL":return Be(o+1,2);case"Lo":return e.ordinalNumber(o+1,{unit:"month"});case"LLL":return e.month(o,{width:"abbreviated",context:"standalone"});case"LLLLL":return e.month(o,{width:"narrow",context:"standalone"});case"LLLL":default:return e.month(o,{width:"wide",context:"standalone"})}},w:function(t,n,e,o){const a=oo(t,o);return n==="wo"?e.ordinalNumber(a,{unit:"week"}):Be(a,n.length)},I:function(t,n,e){const o=no(t);return n==="Io"?e.ordinalNumber(o,{unit:"week"}):Be(o,n.length)},d:function(t,n,e){return n==="do"?e.ordinalNumber(t.getDate(),{unit:"date"}):Ft.d(t,n)},D:function(t,n,e){const o=fi(t);return n==="Do"?e.ordinalNumber(o,{unit:"dayOfYear"}):Be(o,n.length)},E:function(t,n,e){const o=t.getDay();switch(n){case"E":case"EE":case"EEE":return e.day(o,{width:"abbreviated",context:"formatting"});case"EEEEE":return e.day(o,{width:"narrow",context:"formatting"});case"EEEEEE":return e.day(o,{width:"short",context:"formatting"});case"EEEE":default:return e.day(o,{width:"wide",context:"formatting"})}},e:function(t,n,e,o){const a=t.getDay(),i=(a-o.weekStartsOn+8)%7||7;switch(n){case"e":return String(i);case"ee":return Be(i,2);case"eo":return e.ordinalNumber(i,{unit:"day"});case"eee":return e.day(a,{width:"abbreviated",context:"formatting"});case"eeeee":return e.day(a,{width:"narrow",context:"formatting"});case"eeeeee":return e.day(a,{width:"short",context:"formatting"});case"eeee":default:return e.day(a,{width:"wide",context:"formatting"})}},c:function(t,n,e,o){const a=t.getDay(),i=(a-o.weekStartsOn+8)%7||7;switch(n){case"c":return String(i);case"cc":return Be(i,n.length);case"co":return e.ordinalNumber(i,{unit:"day"});case"ccc":return e.day(a,{width:"abbreviated",context:"standalone"});case"ccccc":return e.day(a,{width:"narrow",context:"standalone"});case"cccccc":return e.day(a,{width:"short",context:"standalone"});case"cccc":default:return e.day(a,{width:"wide",context:"standalone"})}},i:function(t,n,e){const o=t.getDay(),a=o===0?7:o;switch(n){case"i":return String(a);case"ii":return Be(a,n.length);case"io":return e.ordinalNumber(a,{unit:"day"});case"iii":return e.day(o,{width:"abbreviated",context:"formatting"});case"iiiii":return e.day(o,{width:"narrow",context:"formatting"});case"iiiiii":return e.day(o,{width:"short",context:"formatting"});case"iiii":default:return e.day(o,{width:"wide",context:"formatting"})}},a:function(t,n,e){const a=t.getHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return e.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"aaa":return e.dayPeriod(a,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return e.dayPeriod(a,{width:"narrow",context:"formatting"});case"aaaa":default:return e.dayPeriod(a,{width:"wide",context:"formatting"})}},b:function(t,n,e){const o=t.getHours();let a;switch(o===12?a=At.noon:o===0?a=At.midnight:a=o/12>=1?"pm":"am",n){case"b":case"bb":return e.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"bbb":return e.dayPeriod(a,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return e.dayPeriod(a,{width:"narrow",context:"formatting"});case"bbbb":default:return e.dayPeriod(a,{width:"wide",context:"formatting"})}},B:function(t,n,e){const o=t.getHours();let a;switch(o>=17?a=At.evening:o>=12?a=At.afternoon:o>=4?a=At.morning:a=At.night,n){case"B":case"BB":case"BBB":return e.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"BBBBB":return e.dayPeriod(a,{width:"narrow",context:"formatting"});case"BBBB":default:return e.dayPeriod(a,{width:"wide",context:"formatting"})}},h:function(t,n,e){if(n==="ho"){let o=t.getHours()%12;return o===0&&(o=12),e.ordinalNumber(o,{unit:"hour"})}return Ft.h(t,n)},H:function(t,n,e){return n==="Ho"?e.ordinalNumber(t.getHours(),{unit:"hour"}):Ft.H(t,n)},K:function(t,n,e){const o=t.getHours()%12;return n==="Ko"?e.ordinalNumber(o,{unit:"hour"}):Be(o,n.length)},k:function(t,n,e){let o=t.getHours();return o===0&&(o=24),n==="ko"?e.ordinalNumber(o,{unit:"hour"}):Be(o,n.length)},m:function(t,n,e){return n==="mo"?e.ordinalNumber(t.getMinutes(),{unit:"minute"}):Ft.m(t,n)},s:function(t,n,e){return n==="so"?e.ordinalNumber(t.getSeconds(),{unit:"second"}):Ft.s(t,n)},S:function(t,n){return Ft.S(t,n)},X:function(t,n,e){const o=t.getTimezoneOffset();if(o===0)return"Z";switch(n){case"X":return io(o);case"XXXX":case"XX":return Ht(o);case"XXXXX":case"XXX":default:return Ht(o,":")}},x:function(t,n,e){const o=t.getTimezoneOffset();switch(n){case"x":return io(o);case"xxxx":case"xx":return Ht(o);case"xxxxx":case"xxx":default:return Ht(o,":")}},O:function(t,n,e){const o=t.getTimezoneOffset();switch(n){case"O":case"OO":case"OOO":return"GMT"+ao(o,":");case"OOOO":default:return"GMT"+Ht(o,":")}},z:function(t,n,e){const o=t.getTimezoneOffset();switch(n){case"z":case"zz":case"zzz":return"GMT"+ao(o,":");case"zzzz":default:return"GMT"+Ht(o,":")}},t:function(t,n,e){const o=Math.trunc(t.getTime()/1e3);return Be(o,n.length)},T:function(t,n,e){const o=t.getTime();return Be(o,n.length)}};function ao(t,n=""){const e=t>0?"-":"+",o=Math.abs(t),a=Math.trunc(o/60),i=o%60;return i===0?e+String(a):e+String(a)+n+Be(i,2)}function io(t,n){return t%60===0?(t>0?"-":"+")+Be(Math.abs(t)/60,2):Ht(t,n)}function Ht(t,n=""){const e=t>0?"-":"+",o=Math.abs(t),a=Be(Math.trunc(o/60),2),i=Be(o%60,2);return e+a+n+i}const so=(t,n)=>{switch(t){case"P":return n.date({width:"short"});case"PP":return n.date({width:"medium"});case"PPP":return n.date({width:"long"});case"PPPP":default:return n.date({width:"full"})}},lo=(t,n)=>{switch(t){case"p":return n.time({width:"short"});case"pp":return n.time({width:"medium"});case"ppp":return n.time({width:"long"});case"pppp":default:return n.time({width:"full"})}},kn={p:lo,P:(t,n)=>{const e=t.match(/(P+)(p+)?/)||[],o=e[1],a=e[2];if(!a)return so(t,n);let i;switch(o){case"P":i=n.dateTime({width:"short"});break;case"PP":i=n.dateTime({width:"medium"});break;case"PPP":i=n.dateTime({width:"long"});break;case"PPPP":default:i=n.dateTime({width:"full"});break}return i.replace("{{date}}",so(o,n)).replace("{{time}}",lo(a,n))}},hi=/^D+$/,pi=/^Y+$/,yi=["D","DD","YY","YYYY"];function co(t){return hi.test(t)}function uo(t){return pi.test(t)}function Sn(t,n,e){const o=gi(t,n,e);if(console.warn(o),yi.includes(t))throw new RangeError(o)}function gi(t,n,e){const o=t[0]==="Y"?"years":"days of the month";return`Use \`${t.toLowerCase()}\` instead of \`${t}\` (in \`${n}\`) for formatting ${o} to the input \`${e}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const vi=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,bi=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,wi=/^'([^]*?)'?$/,Ci=/''/g,xi=/[a-zA-Z]/;function rn(t,n,e){var h,l,f,m;const o=Lt(),a=o.locale??to,i=o.firstWeekContainsDate??((l=(h=o.locale)==null?void 0:h.options)==null?void 0:l.firstWeekContainsDate)??1,s=o.weekStartsOn??((m=(f=o.locale)==null?void 0:f.options)==null?void 0:m.weekStartsOn)??0,c=Ze(t);if(!xn(c))throw new RangeError("Invalid time value");let u=n.match(bi).map(p=>{const T=p[0];if(T==="p"||T==="P"){const w=kn[T];return w(p,a.formatLong)}return p}).join("").match(vi).map(p=>{if(p==="''")return{isToken:!1,value:"'"};const T=p[0];if(T==="'")return{isToken:!1,value:Mi(p)};if(ro[T])return{isToken:!0,value:p};if(T.match(xi))throw new RangeError("Format string contains an unescaped latin alphabet character `"+T+"`");return{isToken:!1,value:p}});a.localize.preprocessor&&(u=a.localize.preprocessor(c,u));const d={firstWeekContainsDate:i,weekStartsOn:s,locale:a};return u.map(p=>{if(!p.isToken)return p.value;const T=p.value;(uo(T)||co(T))&&Sn(T,n,String(t));const w=ro[T[0]];return w(c,T,a.localize,d)}).join("")}function Mi(t){const n=t.match(wi);return n?n[1].replace(Ci,"'"):t}function Ti(){return Object.assign({},Lt())}function ki(t){let e=Ze(t).getDay();return e===0&&(e=7),e}function Si(t,n){const e=n instanceof Date?ze(n,0):new n(0);return e.setFullYear(t.getFullYear(),t.getMonth(),t.getDate()),e.setHours(t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()),e}const _i=10;class fo{constructor(){R(this,"subPriority",0)}validate(n,e){return!0}}class Vi extends fo{constructor(n,e,o,a,i){super(),this.value=n,this.validateValue=e,this.setValue=o,this.priority=a,i&&(this.subPriority=i)}validate(n,e){return this.validateValue(n,this.value,e)}set(n,e,o){return this.setValue(n,e,this.value,o)}}class Ni extends fo{constructor(){super(...arguments);R(this,"priority",_i);R(this,"subPriority",-1)}set(e,o){return o.timestampIsSet?e:ze(e,Si(e,Date))}}class Ie{run(n,e,o,a){const i=this.parse(n,e,o,a);return i?{setter:new Vi(i.value,this.validate,this.set,this.priority,this.subPriority),rest:i.rest}:null}validate(n,e,o){return!0}}class Oi extends Ie{constructor(){super(...arguments);R(this,"priority",140);R(this,"incompatibleTokens",["R","u","t","T"])}parse(e,o,a){switch(o){case"G":case"GG":case"GGG":return a.era(e,{width:"abbreviated"})||a.era(e,{width:"narrow"});case"GGGGG":return a.era(e,{width:"narrow"});case"GGGG":default:return a.era(e,{width:"wide"})||a.era(e,{width:"abbreviated"})||a.era(e,{width:"narrow"})}}set(e,o,a){return o.era=a,e.setFullYear(a,0,1),e.setHours(0,0,0,0),e}}const Xe={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},Ct={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function Qe(t,n){return t&&{value:n(t.value),rest:t.rest}}function qe(t,n){const e=n.match(t);return e?{value:parseInt(e[0],10),rest:n.slice(e[0].length)}:null}function xt(t,n){const e=n.match(t);if(!e)return null;if(e[0]==="Z")return{value:0,rest:n.slice(1)};const o=e[1]==="+"?1:-1,a=e[2]?parseInt(e[2],10):0,i=e[3]?parseInt(e[3],10):0,s=e[5]?parseInt(e[5],10):0;return{value:o*(a*Va+i*_a+s*Na),rest:n.slice(e[0].length)}}function mo(t){return qe(Xe.anyDigitsSigned,t)}function Ge(t,n){switch(t){case 1:return qe(Xe.singleDigit,n);case 2:return qe(Xe.twoDigits,n);case 3:return qe(Xe.threeDigits,n);case 4:return qe(Xe.fourDigits,n);default:return qe(new RegExp("^\\d{1,"+t+"}"),n)}}function an(t,n){switch(t){case 1:return qe(Xe.singleDigitSigned,n);case 2:return qe(Xe.twoDigitsSigned,n);case 3:return qe(Xe.threeDigitsSigned,n);case 4:return qe(Xe.fourDigitsSigned,n);default:return qe(new RegExp("^-?\\d{1,"+t+"}"),n)}}function _n(t){switch(t){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function ho(t,n){const e=n>0,o=e?n:1-n;let a;if(o<=50)a=t||100;else{const i=o+50,s=Math.trunc(i/100)*100,c=t>=i%100;a=t+s-(c?100:0)}return e?a:1-a}function po(t){return t%400===0||t%4===0&&t%100!==0}class Fi extends Ie{constructor(){super(...arguments);R(this,"priority",130);R(this,"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"])}parse(e,o,a){const i=s=>({year:s,isTwoDigitYear:o==="yy"});switch(o){case"y":return Qe(Ge(4,e),i);case"yo":return Qe(a.ordinalNumber(e,{unit:"year"}),i);default:return Qe(Ge(o.length,e),i)}}validate(e,o){return o.isTwoDigitYear||o.year>0}set(e,o,a){const i=e.getFullYear();if(a.isTwoDigitYear){const c=ho(a.year,i);return e.setFullYear(c,0,1),e.setHours(0,0,0,0),e}const s=!("era"in o)||o.era===1?a.year:1-a.year;return e.setFullYear(s,0,1),e.setHours(0,0,0,0),e}}class Pi extends Ie{constructor(){super(...arguments);R(this,"priority",130);R(this,"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"])}parse(e,o,a){const i=s=>({year:s,isTwoDigitYear:o==="YY"});switch(o){case"Y":return Qe(Ge(4,e),i);case"Yo":return Qe(a.ordinalNumber(e,{unit:"year"}),i);default:return Qe(Ge(o.length,e),i)}}validate(e,o){return o.isTwoDigitYear||o.year>0}set(e,o,a,i){const s=Tn(e,i);if(a.isTwoDigitYear){const u=ho(a.year,s);return e.setFullYear(u,0,i.firstWeekContainsDate),e.setHours(0,0,0,0),Ot(e,i)}const c=!("era"in o)||o.era===1?a.year:1-a.year;return e.setFullYear(c,0,i.firstWeekContainsDate),e.setHours(0,0,0,0),Ot(e,i)}}class Ei extends Ie{constructor(){super(...arguments);R(this,"priority",130);R(this,"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"])}parse(e,o){return an(o==="R"?4:o.length,e)}set(e,o,a){const i=ze(e,0);return i.setFullYear(a,0,4),i.setHours(0,0,0,0),Wt(i)}}class Ii extends Ie{constructor(){super(...arguments);R(this,"priority",130);R(this,"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"])}parse(e,o){return an(o==="u"?4:o.length,e)}set(e,o,a){return e.setFullYear(a,0,1),e.setHours(0,0,0,0),e}}class Di extends Ie{constructor(){super(...arguments);R(this,"priority",120);R(this,"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"])}parse(e,o,a){switch(o){case"Q":case"QQ":return Ge(o.length,e);case"Qo":return a.ordinalNumber(e,{unit:"quarter"});case"QQQ":return a.quarter(e,{width:"abbreviated",context:"formatting"})||a.quarter(e,{width:"narrow",context:"formatting"});case"QQQQQ":return a.quarter(e,{width:"narrow",context:"formatting"});case"QQQQ":default:return a.quarter(e,{width:"wide",context:"formatting"})||a.quarter(e,{width:"abbreviated",context:"formatting"})||a.quarter(e,{width:"narrow",context:"formatting"})}}validate(e,o){return o>=1&&o<=4}set(e,o,a){return e.setMonth((a-1)*3,1),e.setHours(0,0,0,0),e}}class Bi extends Ie{constructor(){super(...arguments);R(this,"priority",120);R(this,"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"])}parse(e,o,a){switch(o){case"q":case"qq":return Ge(o.length,e);case"qo":return a.ordinalNumber(e,{unit:"quarter"});case"qqq":return a.quarter(e,{width:"abbreviated",context:"standalone"})||a.quarter(e,{width:"narrow",context:"standalone"});case"qqqqq":return a.quarter(e,{width:"narrow",context:"standalone"});case"qqqq":default:return a.quarter(e,{width:"wide",context:"standalone"})||a.quarter(e,{width:"abbreviated",context:"standalone"})||a.quarter(e,{width:"narrow",context:"standalone"})}}validate(e,o){return o>=1&&o<=4}set(e,o,a){return e.setMonth((a-1)*3,1),e.setHours(0,0,0,0),e}}class ji extends Ie{constructor(){super(...arguments);R(this,"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]);R(this,"priority",110)}parse(e,o,a){const i=s=>s-1;switch(o){case"M":return Qe(qe(Xe.month,e),i);case"MM":return Qe(Ge(2,e),i);case"Mo":return Qe(a.ordinalNumber(e,{unit:"month"}),i);case"MMM":return a.month(e,{width:"abbreviated",context:"formatting"})||a.month(e,{width:"narrow",context:"formatting"});case"MMMMM":return a.month(e,{width:"narrow",context:"formatting"});case"MMMM":default:return a.month(e,{width:"wide",context:"formatting"})||a.month(e,{width:"abbreviated",context:"formatting"})||a.month(e,{width:"narrow",context:"formatting"})}}validate(e,o){return o>=0&&o<=11}set(e,o,a){return e.setMonth(a,1),e.setHours(0,0,0,0),e}}class Hi extends Ie{constructor(){super(...arguments);R(this,"priority",110);R(this,"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"])}parse(e,o,a){const i=s=>s-1;switch(o){case"L":return Qe(qe(Xe.month,e),i);case"LL":return Qe(Ge(2,e),i);case"Lo":return Qe(a.ordinalNumber(e,{unit:"month"}),i);case"LLL":return a.month(e,{width:"abbreviated",context:"standalone"})||a.month(e,{width:"narrow",context:"standalone"});case"LLLLL":return a.month(e,{width:"narrow",context:"standalone"});case"LLLL":default:return a.month(e,{width:"wide",context:"standalone"})||a.month(e,{width:"abbreviated",context:"standalone"})||a.month(e,{width:"narrow",context:"standalone"})}}validate(e,o){return o>=0&&o<=11}set(e,o,a){return e.setMonth(a,1),e.setHours(0,0,0,0),e}}function Ri(t,n,e){const o=Ze(t),a=oo(o,e)-n;return o.setDate(o.getDate()-a*7),o}class $i extends Ie{constructor(){super(...arguments);R(this,"priority",100);R(this,"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"])}parse(e,o,a){switch(o){case"w":return qe(Xe.week,e);case"wo":return a.ordinalNumber(e,{unit:"week"});default:return Ge(o.length,e)}}validate(e,o){return o>=1&&o<=53}set(e,o,a,i){return Ot(Ri(e,a,i),i)}}function Li(t,n){const e=Ze(t),o=no(e)-n;return e.setDate(e.getDate()-o*7),e}class Wi extends Ie{constructor(){super(...arguments);R(this,"priority",100);R(this,"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"])}parse(e,o,a){switch(o){case"I":return qe(Xe.week,e);case"Io":return a.ordinalNumber(e,{unit:"week"});default:return Ge(o.length,e)}}validate(e,o){return o>=1&&o<=53}set(e,o,a){return Wt(Li(e,a))}}const Ai=[31,28,31,30,31,30,31,31,30,31,30,31],qi=[31,29,31,30,31,30,31,31,30,31,30,31];class Yi extends Ie{constructor(){super(...arguments);R(this,"priority",90);R(this,"subPriority",1);R(this,"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"])}parse(e,o,a){switch(o){case"d":return qe(Xe.date,e);case"do":return a.ordinalNumber(e,{unit:"date"});default:return Ge(o.length,e)}}validate(e,o){const a=e.getFullYear(),i=po(a),s=e.getMonth();return i?o>=1&&o<=qi[s]:o>=1&&o<=Ai[s]}set(e,o,a){return e.setDate(a),e.setHours(0,0,0,0),e}}class zi extends Ie{constructor(){super(...arguments);R(this,"priority",90);R(this,"subpriority",1);R(this,"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"])}parse(e,o,a){switch(o){case"D":case"DD":return qe(Xe.dayOfYear,e);case"Do":return a.ordinalNumber(e,{unit:"date"});default:return Ge(o.length,e)}}validate(e,o){const a=e.getFullYear();return po(a)?o>=1&&o<=366:o>=1&&o<=365}set(e,o,a){return e.setMonth(0,a),e.setHours(0,0,0,0),e}}function Vn(t,n,e){var l,f,m,p;const o=Lt(),a=(e==null?void 0:e.weekStartsOn)??((f=(l=e==null?void 0:e.locale)==null?void 0:l.options)==null?void 0:f.weekStartsOn)??o.weekStartsOn??((p=(m=o.locale)==null?void 0:m.options)==null?void 0:p.weekStartsOn)??0,i=Ze(t),s=i.getDay(),u=(n%7+7)%7,d=7-a,h=n<0||n>6?n-(s+d)%7:(u+d)%7-(s+d)%7;return Kn(i,h)}class Gi extends Ie{constructor(){super(...arguments);R(this,"priority",90);R(this,"incompatibleTokens",["D","i","e","c","t","T"])}parse(e,o,a){switch(o){case"E":case"EE":case"EEE":return a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"});case"EEEEE":return a.day(e,{width:"narrow",context:"formatting"});case"EEEEEE":return a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"});case"EEEE":default:return a.day(e,{width:"wide",context:"formatting"})||a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"})}}validate(e,o){return o>=0&&o<=6}set(e,o,a,i){return e=Vn(e,a,i),e.setHours(0,0,0,0),e}}class Ui extends Ie{constructor(){super(...arguments);R(this,"priority",90);R(this,"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"])}parse(e,o,a,i){const s=c=>{const u=Math.floor((c-1)/7)*7;return(c+i.weekStartsOn+6)%7+u};switch(o){case"e":case"ee":return Qe(Ge(o.length,e),s);case"eo":return Qe(a.ordinalNumber(e,{unit:"day"}),s);case"eee":return a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"});case"eeeee":return a.day(e,{width:"narrow",context:"formatting"});case"eeeeee":return a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"});case"eeee":default:return a.day(e,{width:"wide",context:"formatting"})||a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"})}}validate(e,o){return o>=0&&o<=6}set(e,o,a,i){return e=Vn(e,a,i),e.setHours(0,0,0,0),e}}class Xi extends Ie{constructor(){super(...arguments);R(this,"priority",90);R(this,"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"])}parse(e,o,a,i){const s=c=>{const u=Math.floor((c-1)/7)*7;return(c+i.weekStartsOn+6)%7+u};switch(o){case"c":case"cc":return Qe(Ge(o.length,e),s);case"co":return Qe(a.ordinalNumber(e,{unit:"day"}),s);case"ccc":return a.day(e,{width:"abbreviated",context:"standalone"})||a.day(e,{width:"short",context:"standalone"})||a.day(e,{width:"narrow",context:"standalone"});case"ccccc":return a.day(e,{width:"narrow",context:"standalone"});case"cccccc":return a.day(e,{width:"short",context:"standalone"})||a.day(e,{width:"narrow",context:"standalone"});case"cccc":default:return a.day(e,{width:"wide",context:"standalone"})||a.day(e,{width:"abbreviated",context:"standalone"})||a.day(e,{width:"short",context:"standalone"})||a.day(e,{width:"narrow",context:"standalone"})}}validate(e,o){return o>=0&&o<=6}set(e,o,a,i){return e=Vn(e,a,i),e.setHours(0,0,0,0),e}}function Qi(t,n){const e=Ze(t),o=ki(e),a=n-o;return Kn(e,a)}class Ki extends Ie{constructor(){super(...arguments);R(this,"priority",90);R(this,"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"])}parse(e,o,a){const i=s=>s===0?7:s;switch(o){case"i":case"ii":return Ge(o.length,e);case"io":return a.ordinalNumber(e,{unit:"day"});case"iii":return Qe(a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"}),i);case"iiiii":return Qe(a.day(e,{width:"narrow",context:"formatting"}),i);case"iiiiii":return Qe(a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"}),i);case"iiii":default:return Qe(a.day(e,{width:"wide",context:"formatting"})||a.day(e,{width:"abbreviated",context:"formatting"})||a.day(e,{width:"short",context:"formatting"})||a.day(e,{width:"narrow",context:"formatting"}),i)}}validate(e,o){return o>=1&&o<=7}set(e,o,a){return e=Qi(e,a),e.setHours(0,0,0,0),e}}class Ji extends Ie{constructor(){super(...arguments);R(this,"priority",80);R(this,"incompatibleTokens",["b","B","H","k","t","T"])}parse(e,o,a){switch(o){case"a":case"aa":case"aaa":return a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaaa":return a.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaa":default:return a.dayPeriod(e,{width:"wide",context:"formatting"})||a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"})}}set(e,o,a){return e.setHours(_n(a),0,0,0),e}}class Zi extends Ie{constructor(){super(...arguments);R(this,"priority",80);R(this,"incompatibleTokens",["a","B","H","k","t","T"])}parse(e,o,a){switch(o){case"b":case"bb":case"bbb":return a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbbb":return a.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbb":default:return a.dayPeriod(e,{width:"wide",context:"formatting"})||a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"})}}set(e,o,a){return e.setHours(_n(a),0,0,0),e}}class es extends Ie{constructor(){super(...arguments);R(this,"priority",80);R(this,"incompatibleTokens",["a","b","t","T"])}parse(e,o,a){switch(o){case"B":case"BB":case"BBB":return a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBBB":return a.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBB":default:return a.dayPeriod(e,{width:"wide",context:"formatting"})||a.dayPeriod(e,{width:"abbreviated",context:"formatting"})||a.dayPeriod(e,{width:"narrow",context:"formatting"})}}set(e,o,a){return e.setHours(_n(a),0,0,0),e}}class ts extends Ie{constructor(){super(...arguments);R(this,"priority",70);R(this,"incompatibleTokens",["H","K","k","t","T"])}parse(e,o,a){switch(o){case"h":return qe(Xe.hour12h,e);case"ho":return a.ordinalNumber(e,{unit:"hour"});default:return Ge(o.length,e)}}validate(e,o){return o>=1&&o<=12}set(e,o,a){const i=e.getHours()>=12;return i&&a<12?e.setHours(a+12,0,0,0):!i&&a===12?e.setHours(0,0,0,0):e.setHours(a,0,0,0),e}}class ns extends Ie{constructor(){super(...arguments);R(this,"priority",70);R(this,"incompatibleTokens",["a","b","h","K","k","t","T"])}parse(e,o,a){switch(o){case"H":return qe(Xe.hour23h,e);case"Ho":return a.ordinalNumber(e,{unit:"hour"});default:return Ge(o.length,e)}}validate(e,o){return o>=0&&o<=23}set(e,o,a){return e.setHours(a,0,0,0),e}}class os extends Ie{constructor(){super(...arguments);R(this,"priority",70);R(this,"incompatibleTokens",["h","H","k","t","T"])}parse(e,o,a){switch(o){case"K":return qe(Xe.hour11h,e);case"Ko":return a.ordinalNumber(e,{unit:"hour"});default:return Ge(o.length,e)}}validate(e,o){return o>=0&&o<=11}set(e,o,a){return e.getHours()>=12&&a<12?e.setHours(a+12,0,0,0):e.setHours(a,0,0,0),e}}class rs extends Ie{constructor(){super(...arguments);R(this,"priority",70);R(this,"incompatibleTokens",["a","b","h","H","K","t","T"])}parse(e,o,a){switch(o){case"k":return qe(Xe.hour24h,e);case"ko":return a.ordinalNumber(e,{unit:"hour"});default:return Ge(o.length,e)}}validate(e,o){return o>=1&&o<=24}set(e,o,a){const i=a<=24?a%24:a;return e.setHours(i,0,0,0),e}}class as extends Ie{constructor(){super(...arguments);R(this,"priority",60);R(this,"incompatibleTokens",["t","T"])}parse(e,o,a){switch(o){case"m":return qe(Xe.minute,e);case"mo":return a.ordinalNumber(e,{unit:"minute"});default:return Ge(o.length,e)}}validate(e,o){return o>=0&&o<=59}set(e,o,a){return e.setMinutes(a,0,0),e}}class is extends Ie{constructor(){super(...arguments);R(this,"priority",50);R(this,"incompatibleTokens",["t","T"])}parse(e,o,a){switch(o){case"s":return qe(Xe.second,e);case"so":return a.ordinalNumber(e,{unit:"second"});default:return Ge(o.length,e)}}validate(e,o){return o>=0&&o<=59}set(e,o,a){return e.setSeconds(a,0),e}}class ss extends Ie{constructor(){super(...arguments);R(this,"priority",30);R(this,"incompatibleTokens",["t","T"])}parse(e,o){const a=i=>Math.trunc(i*Math.pow(10,-o.length+3));return Qe(Ge(o.length,e),a)}set(e,o,a){return e.setMilliseconds(a),e}}class ls extends Ie{constructor(){super(...arguments);R(this,"priority",10);R(this,"incompatibleTokens",["t","T","x"])}parse(e,o){switch(o){case"X":return xt(Ct.basicOptionalMinutes,e);case"XX":return xt(Ct.basic,e);case"XXXX":return xt(Ct.basicOptionalSeconds,e);case"XXXXX":return xt(Ct.extendedOptionalSeconds,e);case"XXX":default:return xt(Ct.extended,e)}}set(e,o,a){return o.timestampIsSet?e:ze(e,e.getTime()-on(e)-a)}}class cs extends Ie{constructor(){super(...arguments);R(this,"priority",10);R(this,"incompatibleTokens",["t","T","X"])}parse(e,o){switch(o){case"x":return xt(Ct.basicOptionalMinutes,e);case"xx":return xt(Ct.basic,e);case"xxxx":return xt(Ct.basicOptionalSeconds,e);case"xxxxx":return xt(Ct.extendedOptionalSeconds,e);case"xxx":default:return xt(Ct.extended,e)}}set(e,o,a){return o.timestampIsSet?e:ze(e,e.getTime()-on(e)-a)}}class us extends Ie{constructor(){super(...arguments);R(this,"priority",40);R(this,"incompatibleTokens","*")}parse(e){return mo(e)}set(e,o,a){return[ze(e,a*1e3),{timestampIsSet:!0}]}}class ds extends Ie{constructor(){super(...arguments);R(this,"priority",20);R(this,"incompatibleTokens","*")}parse(e){return mo(e)}set(e,o,a){return[ze(e,a),{timestampIsSet:!0}]}}const fs={G:new Oi,y:new Fi,Y:new Pi,R:new Ei,u:new Ii,Q:new Di,q:new Bi,M:new ji,L:new Hi,w:new $i,I:new Wi,d:new Yi,D:new zi,E:new Gi,e:new Ui,c:new Xi,i:new Ki,a:new Ji,b:new Zi,B:new es,h:new ts,H:new ns,K:new os,k:new rs,m:new as,s:new is,S:new ss,X:new ls,x:new cs,t:new us,T:new ds},ms=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,hs=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,ps=/^'([^]*?)'?$/,ys=/''/g,gs=/\S/,vs=/[a-zA-Z]/;function sn(t,n,e,o){var T,w,g,v;const a=Ti(),i=a.locale??to,s=a.firstWeekContainsDate??((w=(T=a.locale)==null?void 0:T.options)==null?void 0:w.firstWeekContainsDate)??1,c=a.weekStartsOn??((v=(g=a.locale)==null?void 0:g.options)==null?void 0:v.we