UNPKG

@farris/ui-vue

Version:

Farris Vue, a Farris Design based Vue3 component library.

1 lines 310 kB
(function(J,i){typeof exports=="object"&&typeof module<"u"?i(exports,require("vue"),require("lodash-es"),require("../button-edit/index.umd.js"),require("../common/index.umd.js"),require("../tags/index.umd.js"),require("../popover/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("../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("../../designer/button-edit/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("../number-spinner/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","../button-edit/index.umd.js","../common/index.umd.js","../tags/index.umd.js","../popover/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","../dynamic-form/index.umd.js","../dynamic-resolver/index.umd.js","../property-panel/index.umd.js","../accordion/index.umd.js","../avatar/index.umd.js","../../designer/button-edit/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","../number-spinner/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"],i):(J=typeof globalThis<"u"?globalThis:J||self,i(J["time-picker"]={},J.Vue,J.LodashES,J.FButtonEdit$1,J.common,J.FTags,J.FPopover,J.designerCanvas,J.VueUseCore,J.dataView,null,J.FTransfer,J.FTabs,J.FOrder,null,J.checkbox,J.FFilterBar,J.FTooltip,J.FPagination,J.FButton,J.FSearchBox,J.FDynamicForm,J.dynamicResolver,null,J.FAccordion,J.FAvatar,J.FButtonEdit$2,J.FButtonGroup,J.FCalendar,J.FCapsule,J.FCheckbox,J.FCheckboxGroup,J.FComboList,J.FComboTree,J.FComponent,J.FColorPicker,J.FContentContainer,J.FDatePicker,J.FDataGrid,J.FDropdown,J.FEventsEditor,J.FFieldSelector,J.FBindingSelector,J.FImageCropper,J.FInputGroup,J.FLayout,J.FListNav,J.FListView,J.FLookup,J.FMappingEditor,J.FNav,J.FNumberRange,J.FNumberSpinner,J.FPageHeader,J.FPageFooter,J.FProgress,J.FQuerySolution,J.FRadioGroup,J.FRate,J.FResponseToolbar,J.FResponseLayout,J.FResponseLayoutEditorSetting,J.FSection,J.FSmokeDetector,J.FSplitter,J.FStep,J.FSwitch,J.FText,J.FTimePicker$1,J.FTreeview,J.FUploader,J.FVerifyDetail,J.FVideo,J.FTextArea,J.FSchemaSelector,J.FTreeGrid$1,J.FEventParameter,J.FFilterConditionEditor,J.FFieldset,J.FSortConditionEditor,J.FMenuLookup,J.FDrawer,J.FJsonEditor,J.FPropertyEditor,J.FExpressionEditor,J.FCodeEditor,J.FHtmlTemplate))})(this,function(J,i,Oe,Dr,Me,_n,jr,Sn,Tn,Te,qu,Hr,Rr,$r,Au,Lr,Wr,kn,qr,Ar,Gr,an,zr,Gu,Yr,Ur,Xr,Qr,Kr,Jr,Mn,Vn,sn,Zr,eo,to,no,ro,oo,io,ao,so,lo,uo,co,fo,po,mo,ho,go,yo,vo,bo,wo,Co,xo,_o,So,To,ko,Mo,Vo,Fo,Eo,No,Oo,Io,Po,Bo,Do,jo,Ho,Ro,$o,Lo,Wo,qo,Ao,Go,zo,Yo,Uo,Xo,Qo,Ko,Jo,Zo){"use strict";var Lu=Object.defineProperty;var Wu=(J,i,Oe)=>i in J?Lu(J,i,{enumerable:!0,configurable:!0,writable:!0,value:Oe}):J[i]=Oe;var E=(J,i,Oe)=>Wu(J,typeof i!="symbol"?i+"":i,Oe);const Fn={},En={};function ln(n){const{properties:t,title:e,ignore:r}=n,o=r&&Array.isArray(r),a=Object.keys(t).reduce((s,l)=>((!o||!r.find(c=>c===l))&&(s[l]=t[l].type==="object"&&t[l].properties?ln(t[l]):Oe.cloneDeep(t[l].default)),s),{});if(e&&(!o||!r.find(s=>s==="id"))){const s=e.toLowerCase().replace(/-/g,"_");a.id=`${s}_${Math.random().toString().slice(2,6)}`}return a}function ei(n){const{properties:t,title:e,required:r}=n;if(r&&Array.isArray(r)){const o=r.reduce((a,s)=>(a[s]=t[s].type==="object"&&t[s].properties?ln(t[s]):Oe.cloneDeep(t[s].default),a),{});if(e&&r.find(a=>a==="id")){const a=e.toLowerCase().replace(/-/g,"_");o.id=`${a}_${Math.random().toString().slice(2,6)}`}return o}return{type:e}}function Nn(n,t={},e){const r=Fn[n];if(r){let o=ei(r);const a=En[n];return o=a?a({getSchemaByType:Nn},o,t,e):o,o}return null}function ti(n,t){const e=ln(t);return Object.keys(e).reduce((r,o)=>(Object.prototype.hasOwnProperty.call(n,o)&&(r[o]&&Oe.isPlainObject(r[o])&&Oe.isPlainObject(n[o]||!n[o])?Object.assign(r[o],n[o]||{}):r[o]=n[o]),r),e),e}function On(n,t){return Object.keys(n).filter(r=>n[r]!=null).reduce((r,o)=>{if(t.has(o)){const a=t.get(o);if(typeof a=="string")r[a]=n[o];else{const s=a(o,n[o],n);Object.assign(r,s)}}else r[o]=n[o];return r},{})}function ni(n,t,e=new Map){const r=ti(n,t);return On(r,e)}function ri(n={}){function t(f,d,u,p){if(typeof u=="number")return p[f].length===u;if(typeof u=="object"){const m=Object.keys(u)[0],h=u[m];if(m==="not")return Number(p[f].length)!==Number(h);if(m==="moreThan")return Number(p[f].length)>=Number(h);if(m==="lessThan")return Number(p[f].length)<=Number(h)}return!1}function e(f,d,u,p){return p[f]&&p[f].propertyValue&&String(p[f].propertyValue.value)===String(u)}const r=new Map([["length",t],["getProperty",e]]);Object.keys(n).reduce((f,d)=>(f.set(d,n[d]),f),r);function o(f,d){const u=f;return typeof d=="number"?[{target:u,operator:"length",param:null,value:Number(d)}]:typeof d=="boolean"?[{target:u,operator:"getProperty",param:f,value:!!d}]:typeof d=="object"?Object.keys(d).map(p=>{if(p==="length")return{target:u,operator:"length",param:null,value:d[p]};const m=p,h=d[p];return{target:u,operator:"getProperty",param:m,value:h}}):[]}function a(f){return Object.keys(f).reduce((u,p)=>{const m=o(p,f[p]);return u.push(...m),u},[])}function s(f,d){if(r.has(f.operator)){const u=r.get(f.operator);return u&&u(f.target,f.param,f.value,d)||!1}return!1}function l(f,d){return a(f).reduce((m,h)=>m&&s(h,d),!0)}function c(f,d){const u=Object.keys(f),p=u.includes("allOf"),m=u.includes("anyOf"),h=p||m,v=(h?f[h?p?"allOf":"anyOf":"allOf"]:[f]).map(b=>l(b,d));return p?!v.includes(!1):v.includes(!0)}return{parseValueSchema:c}}const de={button:{type:"button",name:"按钮"},"response-toolbar":{type:"response-toolbar",name:"工具栏"},"response-toolbar-item":{type:"response-toolbar-item",name:"按钮"},"content-container":{type:"content-container",name:"容器"},"input-group":{type:"input-group",name:"文本"},textarea:{type:"textarea",name:"多行文本"},lookup:{type:"lookup",name:"帮助"},"number-spinner":{type:"number-spinner",name:"数值"},"date-picker":{type:"date-picker",name:"日期"},switch:{type:"switch",name:"开关"},"radio-group":{type:"radio-group",name:"单选组"},"check-box":{type:"check-box",name:"复选框"},"check-group":{type:"check-group",name:"复选框组"},"combo-list":{type:"combo-list",name:"下拉列表"},"response-form":{type:"response-form",name:"卡片面板"},"response-layout":{type:"response-layout",name:"布局容器",icon:"response-layout-3"},"response-layout-item":{type:"response-layout-item",name:"布局",icon:"response-layout-1"},"tree-grid":{type:"tree-grid",name:"树表格"},"tree-grid-column":{type:"tree-grid-column",name:"树表格列"},"data-grid":{type:"data-grid",name:"表格"},"data-grid-column":{type:"data-grid-column",name:"表格列"},module:{type:"Module",name:"模块"},component:{type:"component",name:"组件"},tabs:{type:"tabs",name:"标签页"},"tab-page":{type:"tab-page",name:"标签页项",dependentParentControl:"Tab"},"tab-toolbar-item":{type:"tab-toolbar-item",name:"标签页工具栏按钮"},"html-template":{type:"html-template",name:"模板容器"},"time-picker":{type:"time-picker",name:"时间选择"},section:{type:"section",name:"分组面板"},"section-toolbar":{type:"section-toolbar",name:"分组面板工具栏"},"section-toolbar-item":{type:"section-toolbar-item",name:"分组面板按钮"},splitter:{type:"splitter",name:"分栏面板"},"splitter-pane":{type:"splitter-pane",name:"分栏面板项",dependentParentControl:"Splitter"},"component-ref":{type:"component-ref",name:"组件引用节点"},uploader:{type:"uploader",name:"附件上传"},"page-header":{type:"page-header",name:"页头"},"page-footer":{type:"page-footer",name:"页脚"},"tab-toolbar":{type:"tab-toolbar",name:"标签页工具栏"},fieldset:{type:"fieldset",name:"分组"},"query-solution":{type:"query-solution",name:"筛选方案"},drawer:{type:"drawer",name:"抽屉"},"external-container":{type:"external-container",name:"外部容器",icon:"content-container"},"list-nav":{type:"list-nav",name:"列表导航"},"filter-bar":{type:"filter-bar",name:"筛选条"}},oi={},ii={};ri();function Tt(n,t,e=new Map,r=(s,l,c,f)=>l,o={},a=s=>s){return Fn[t.title]=t,En[t.title]=r,oi[t.title]=o,ii[t.title]=a,(s={},l=!0)=>{if(!l)return On(s,e);const c=ni(s,t,e),f=Object.keys(n).reduce((d,u)=>(d[u]=n[u].default,d),{});return Object.assign(f,c)}}function At(n,t){return{customClass:t.class,customStyle:t.style}}function ai(){function n(t,e){const{dataSource:r}=t||{};return r===void 0?{}:{}}return{resolve:n}}function si(){function n(t,e){return t.selectItemById(e)}return{selectItemById:n}}function li(){function n(t,e){const{columns:r}=e;return t.updateColumns(r)}return{updateColumns:n}}const ui=new Map([["appearance",At]]),ci={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"https://farris-design.gitee.io/time-picker.schema.json",title:"time-picker",description:"A Farris Input Component",type:"object",properties:{id:{description:"The unique identifier for a time picker",type:"string"},type:{description:"The type string of time picker component",type:"string",default:"time-picker"},appearance:{description:"",type:"object",properties:{class:{type:"string"},style:{type:"string"}},default:{}},binding:{description:"",type:"object",default:{}},disabled:{type:"string",default:!1},editable:{description:"",type:"boolean",default:!0},placeholder:{description:"",type:"string",default:""},readonly:{description:"",type:"boolean",default:!1},required:{description:"",type:"boolean",default:!1},tabindex:{description:"",type:"number",default:-1},visible:{description:"",type:"boolean",default:!0},format:{description:"",type:"enum",default:"HH:mm:ss"},showHeader:{description:"",type:"boolean",default:!1},use12Hours:{description:"",type:"boolean",default:!1},hourStep:{description:"",type:"number",default:1},minuteStep:{description:"",type:"number",default:1},secondStep:{description:"",type:"number",default:1}},required:["type"],ignore:["id","appearance","binding","visible"]};function di(n,t,e){return t}const Gt={modelValue:{type:String,default:""},hourStep:{type:Number,default:1},minuteStep:{type:Number,default:1},secondStep:{type:Number,default:1},popupClassName:{type:String,default:""},placeholder:{type:String,default:"请选择时间"},placement:{type:String,default:"auto"},defaultOpenValue:{type:Date,default:null},format:{type:String,default:"HH:mm:ss"},isOpen:{type:Boolean,default:!1},showHeader:{type:Boolean,default:!1},use12Hours:{type:Boolean,default:!1},disabledHours:{type:Function,default:null},disabledMinutes:{type:Function,default:null},disabledSeconds:{type:Function,default:null},hideDisabledElements:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},editable:{type:Boolean,default:!0}},un=Tt(Gt,ci,ui,di),In={modelValue:{type:String,default:""},hourStep:{type:Number,default:1},minuteStep:{type:Number,default:1},secondStep:{type:Number,default:1},defaultOpenValue:{type:Date,default:null},disabledHours:{type:Function,default:null},disabledMinutes:{type:Function,default:null},disabledSeconds:{type:Function,default:null},format:{type:String,default:"HH:mm:ss"},isOpen:{type:Boolean,default:!1},use12Hours:{type:Boolean,default:!1},showHeader:{type:Boolean,default:!1},hideDisabledElements:{type:Boolean,default:!1}};function Ue(n){const t=Object.prototype.toString.call(n);return n instanceof Date||typeof n=="object"&&t==="[object Date]"?new n.constructor(+n):typeof n=="number"||t==="[object Number]"||typeof n=="string"||t==="[object String]"?new Date(n):new Date(NaN)}function We(n,t){return n instanceof Date?new n.constructor(t):new Date(t)}function Pn(n,t){const e=Ue(n);return isNaN(t)?We(n,NaN):(t&&e.setDate(e.getDate()+t),e)}const Bn=6048e5,fi=864e5,pi=6e4,mi=36e5,hi=1e3;let gi={};function Bt(){return gi}function yt(n,t){var l,c,f,d;const e=Bt(),r=(t==null?void 0:t.weekStartsOn)??((c=(l=t==null?void 0:t.locale)==null?void 0:l.options)==null?void 0:c.weekStartsOn)??e.weekStartsOn??((d=(f=e.locale)==null?void 0:f.options)==null?void 0:d.weekStartsOn)??0,o=Ue(n),a=o.getDay(),s=(a<r?7:0)+a-r;return o.setDate(o.getDate()-s),o.setHours(0,0,0,0),o}function Dt(n){return yt(n,{weekStartsOn:1})}function Dn(n){const t=Ue(n),e=t.getFullYear(),r=We(n,0);r.setFullYear(e+1,0,4),r.setHours(0,0,0,0);const o=Dt(r),a=We(n,0);a.setFullYear(e,0,4),a.setHours(0,0,0,0);const s=Dt(a);return t.getTime()>=o.getTime()?e+1:t.getTime()>=s.getTime()?e:e-1}function jn(n){const t=Ue(n);return t.setHours(0,0,0,0),t}function zt(n){const t=Ue(n),e=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return e.setUTCFullYear(t.getFullYear()),+n-+e}function yi(n,t){const e=jn(n),r=jn(t),o=+e-zt(e),a=+r-zt(r);return Math.round((o-a)/fi)}function vi(n){const t=Dn(n),e=We(n,0);return e.setFullYear(t,0,4),e.setHours(0,0,0,0),Dt(e)}function bi(n){return n instanceof Date||typeof n=="object"&&Object.prototype.toString.call(n)==="[object Date]"}function Hn(n){if(!bi(n)&&typeof n!="number")return!1;const t=Ue(n);return!isNaN(Number(t))}function wi(n){const t=Ue(n),e=We(n,0);return e.setFullYear(t.getFullYear(),0,1),e.setHours(0,0,0,0),e}const Ci={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"}},xi=(n,t,e)=>{let r;const o=Ci[n];return typeof o=="string"?r=o:t===1?r=o.one:r=o.other.replace("{{count}}",t.toString()),e!=null&&e.addSuffix?e.comparison&&e.comparison>0?"in "+r:r+" ago":r};function cn(n){return(t={})=>{const e=t.width?String(t.width):n.defaultWidth;return n.formats[e]||n.formats[n.defaultWidth]}}const _i={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Si={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},Ti={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},ki={date:cn({formats:_i,defaultWidth:"full"}),time:cn({formats:Si,defaultWidth:"full"}),dateTime:cn({formats:Ti,defaultWidth:"full"})},Mi={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Vi=(n,t,e,r)=>Mi[n];function Rt(n){return(t,e)=>{const r=e!=null&&e.context?String(e.context):"standalone";let o;if(r==="formatting"&&n.formattingValues){const s=n.defaultFormattingWidth||n.defaultWidth,l=e!=null&&e.width?String(e.width):s;o=n.formattingValues[l]||n.formattingValues[s]}else{const s=n.defaultWidth,l=e!=null&&e.width?String(e.width):n.defaultWidth;o=n.values[l]||n.values[s]}const a=n.argumentCallback?n.argumentCallback(t):t;return o[a]}}const Fi={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},Ei={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Ni={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"]},Oi={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"]},Ii={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"}},Pi={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"}},Bi={ordinalNumber:(n,t)=>{const e=Number(n),r=e%100;if(r>20||r<10)switch(r%10){case 1:return e+"st";case 2:return e+"nd";case 3:return e+"rd"}return e+"th"},era:Rt({values:Fi,defaultWidth:"wide"}),quarter:Rt({values:Ei,defaultWidth:"wide",argumentCallback:n=>n-1}),month:Rt({values:Ni,defaultWidth:"wide"}),day:Rt({values:Oi,defaultWidth:"wide"}),dayPeriod:Rt({values:Ii,defaultWidth:"wide",formattingValues:Pi,defaultFormattingWidth:"wide"})};function $t(n){return(t,e={})=>{const r=e.width,o=r&&n.matchPatterns[r]||n.matchPatterns[n.defaultMatchWidth],a=t.match(o);if(!a)return null;const s=a[0],l=r&&n.parsePatterns[r]||n.parsePatterns[n.defaultParseWidth],c=Array.isArray(l)?ji(l,u=>u.test(s)):Di(l,u=>u.test(s));let f;f=n.valueCallback?n.valueCallback(c):c,f=e.valueCallback?e.valueCallback(f):f;const d=t.slice(s.length);return{value:f,rest:d}}}function Di(n,t){for(const e in n)if(Object.prototype.hasOwnProperty.call(n,e)&&t(n[e]))return e}function ji(n,t){for(let e=0;e<n.length;e++)if(t(n[e]))return e}function Hi(n){return(t,e={})=>{const r=t.match(n.matchPattern);if(!r)return null;const o=r[0],a=t.match(n.parsePattern);if(!a)return null;let s=n.valueCallback?n.valueCallback(a[0]):a[0];s=e.valueCallback?e.valueCallback(s):s;const l=t.slice(o.length);return{value:s,rest:l}}}const Ri=/^(\d+)(th|st|nd|rd)?/i,$i=/\d+/i,Li={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},Wi={any:[/^b/i,/^(a|c)/i]},qi={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Ai={any:[/1/i,/2/i,/3/i,/4/i]},Gi={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},zi={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]},Yi={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},Ui={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]},Xi={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},Qi={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}},Ki={ordinalNumber:Hi({matchPattern:Ri,parsePattern:$i,valueCallback:n=>parseInt(n,10)}),era:$t({matchPatterns:Li,defaultMatchWidth:"wide",parsePatterns:Wi,defaultParseWidth:"any"}),quarter:$t({matchPatterns:qi,defaultMatchWidth:"wide",parsePatterns:Ai,defaultParseWidth:"any",valueCallback:n=>n+1}),month:$t({matchPatterns:Gi,defaultMatchWidth:"wide",parsePatterns:zi,defaultParseWidth:"any"}),day:$t({matchPatterns:Yi,defaultMatchWidth:"wide",parsePatterns:Ui,defaultParseWidth:"any"}),dayPeriod:$t({matchPatterns:Xi,defaultMatchWidth:"any",parsePatterns:Qi,defaultParseWidth:"any"})},Rn={code:"en-US",formatDistance:xi,formatLong:ki,formatRelative:Vi,localize:Bi,match:Ki,options:{weekStartsOn:0,firstWeekContainsDate:1}};function Ji(n){const t=Ue(n);return yi(t,wi(t))+1}function $n(n){const t=Ue(n),e=+Dt(t)-+vi(t);return Math.round(e/Bn)+1}function dn(n,t){var d,u,p,m;const e=Ue(n),r=e.getFullYear(),o=Bt(),a=(t==null?void 0:t.firstWeekContainsDate)??((u=(d=t==null?void 0:t.locale)==null?void 0:d.options)==null?void 0:u.firstWeekContainsDate)??o.firstWeekContainsDate??((m=(p=o.locale)==null?void 0:p.options)==null?void 0:m.firstWeekContainsDate)??1,s=We(n,0);s.setFullYear(r+1,0,a),s.setHours(0,0,0,0);const l=yt(s,t),c=We(n,0);c.setFullYear(r,0,a),c.setHours(0,0,0,0);const f=yt(c,t);return e.getTime()>=l.getTime()?r+1:e.getTime()>=f.getTime()?r:r-1}function Zi(n,t){var l,c,f,d;const e=Bt(),r=(t==null?void 0:t.firstWeekContainsDate)??((c=(l=t==null?void 0:t.locale)==null?void 0:l.options)==null?void 0:c.firstWeekContainsDate)??e.firstWeekContainsDate??((d=(f=e.locale)==null?void 0:f.options)==null?void 0:d.firstWeekContainsDate)??1,o=dn(n,t),a=We(n,0);return a.setFullYear(o,0,r),a.setHours(0,0,0,0),yt(a,t)}function Ln(n,t){const e=Ue(n),r=+yt(e,t)-+Zi(e,t);return Math.round(r/Bn)+1}function Fe(n,t){const e=n<0?"-":"",r=Math.abs(n).toString().padStart(t,"0");return e+r}const vt={y(n,t){const e=n.getFullYear(),r=e>0?e:1-e;return Fe(t==="yy"?r%100:r,t.length)},M(n,t){const e=n.getMonth();return t==="M"?String(e+1):Fe(e+1,2)},d(n,t){return Fe(n.getDate(),t.length)},a(n,t){const e=n.getHours()/12>=1?"pm":"am";switch(t){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(n,t){return Fe(n.getHours()%12||12,t.length)},H(n,t){return Fe(n.getHours(),t.length)},m(n,t){return Fe(n.getMinutes(),t.length)},s(n,t){return Fe(n.getSeconds(),t.length)},S(n,t){const e=t.length,r=n.getMilliseconds(),o=Math.trunc(r*Math.pow(10,e-3));return Fe(o,t.length)}},jt={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Wn={G:function(n,t,e){const r=n.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return e.era(r,{width:"abbreviated"});case"GGGGG":return e.era(r,{width:"narrow"});case"GGGG":default:return e.era(r,{width:"wide"})}},y:function(n,t,e){if(t==="yo"){const r=n.getFullYear(),o=r>0?r:1-r;return e.ordinalNumber(o,{unit:"year"})}return vt.y(n,t)},Y:function(n,t,e,r){const o=dn(n,r),a=o>0?o:1-o;if(t==="YY"){const s=a%100;return Fe(s,2)}return t==="Yo"?e.ordinalNumber(a,{unit:"year"}):Fe(a,t.length)},R:function(n,t){const e=Dn(n);return Fe(e,t.length)},u:function(n,t){const e=n.getFullYear();return Fe(e,t.length)},Q:function(n,t,e){const r=Math.ceil((n.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return Fe(r,2);case"Qo":return e.ordinalNumber(r,{unit:"quarter"});case"QQQ":return e.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return e.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return e.quarter(r,{width:"wide",context:"formatting"})}},q:function(n,t,e){const r=Math.ceil((n.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return Fe(r,2);case"qo":return e.ordinalNumber(r,{unit:"quarter"});case"qqq":return e.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return e.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return e.quarter(r,{width:"wide",context:"standalone"})}},M:function(n,t,e){const r=n.getMonth();switch(t){case"M":case"MM":return vt.M(n,t);case"Mo":return e.ordinalNumber(r+1,{unit:"month"});case"MMM":return e.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return e.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return e.month(r,{width:"wide",context:"formatting"})}},L:function(n,t,e){const r=n.getMonth();switch(t){case"L":return String(r+1);case"LL":return Fe(r+1,2);case"Lo":return e.ordinalNumber(r+1,{unit:"month"});case"LLL":return e.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return e.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return e.month(r,{width:"wide",context:"standalone"})}},w:function(n,t,e,r){const o=Ln(n,r);return t==="wo"?e.ordinalNumber(o,{unit:"week"}):Fe(o,t.length)},I:function(n,t,e){const r=$n(n);return t==="Io"?e.ordinalNumber(r,{unit:"week"}):Fe(r,t.length)},d:function(n,t,e){return t==="do"?e.ordinalNumber(n.getDate(),{unit:"date"}):vt.d(n,t)},D:function(n,t,e){const r=Ji(n);return t==="Do"?e.ordinalNumber(r,{unit:"dayOfYear"}):Fe(r,t.length)},E:function(n,t,e){const r=n.getDay();switch(t){case"E":case"EE":case"EEE":return e.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return e.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return e.day(r,{width:"short",context:"formatting"});case"EEEE":default:return e.day(r,{width:"wide",context:"formatting"})}},e:function(n,t,e,r){const o=n.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(a);case"ee":return Fe(a,2);case"eo":return e.ordinalNumber(a,{unit:"day"});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"})}},c:function(n,t,e,r){const o=n.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(a);case"cc":return Fe(a,t.length);case"co":return e.ordinalNumber(a,{unit:"day"});case"ccc":return e.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return e.day(o,{width:"narrow",context:"standalone"});case"cccccc":return e.day(o,{width:"short",context:"standalone"});case"cccc":default:return e.day(o,{width:"wide",context:"standalone"})}},i:function(n,t,e){const r=n.getDay(),o=r===0?7:r;switch(t){case"i":return String(o);case"ii":return Fe(o,t.length);case"io":return e.ordinalNumber(o,{unit:"day"});case"iii":return e.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return e.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return e.day(r,{width:"short",context:"formatting"});case"iiii":default:return e.day(r,{width:"wide",context:"formatting"})}},a:function(n,t,e){const o=n.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return e.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return e.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return e.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return e.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(n,t,e){const r=n.getHours();let o;switch(r===12?o=jt.noon:r===0?o=jt.midnight:o=r/12>=1?"pm":"am",t){case"b":case"bb":return e.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return e.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return e.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return e.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(n,t,e){const r=n.getHours();let o;switch(r>=17?o=jt.evening:r>=12?o=jt.afternoon:r>=4?o=jt.morning:o=jt.night,t){case"B":case"BB":case"BBB":return e.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return e.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return e.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(n,t,e){if(t==="ho"){let r=n.getHours()%12;return r===0&&(r=12),e.ordinalNumber(r,{unit:"hour"})}return vt.h(n,t)},H:function(n,t,e){return t==="Ho"?e.ordinalNumber(n.getHours(),{unit:"hour"}):vt.H(n,t)},K:function(n,t,e){const r=n.getHours()%12;return t==="Ko"?e.ordinalNumber(r,{unit:"hour"}):Fe(r,t.length)},k:function(n,t,e){let r=n.getHours();return r===0&&(r=24),t==="ko"?e.ordinalNumber(r,{unit:"hour"}):Fe(r,t.length)},m:function(n,t,e){return t==="mo"?e.ordinalNumber(n.getMinutes(),{unit:"minute"}):vt.m(n,t)},s:function(n,t,e){return t==="so"?e.ordinalNumber(n.getSeconds(),{unit:"second"}):vt.s(n,t)},S:function(n,t){return vt.S(n,t)},X:function(n,t,e){const r=n.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return An(r);case"XXXX":case"XX":return kt(r);case"XXXXX":case"XXX":default:return kt(r,":")}},x:function(n,t,e){const r=n.getTimezoneOffset();switch(t){case"x":return An(r);case"xxxx":case"xx":return kt(r);case"xxxxx":case"xxx":default:return kt(r,":")}},O:function(n,t,e){const r=n.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+qn(r,":");case"OOOO":default:return"GMT"+kt(r,":")}},z:function(n,t,e){const r=n.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+qn(r,":");case"zzzz":default:return"GMT"+kt(r,":")}},t:function(n,t,e){const r=Math.trunc(n.getTime()/1e3);return Fe(r,t.length)},T:function(n,t,e){const r=n.getTime();return Fe(r,t.length)}};function qn(n,t=""){const e=n>0?"-":"+",r=Math.abs(n),o=Math.trunc(r/60),a=r%60;return a===0?e+String(o):e+String(o)+t+Fe(a,2)}function An(n,t){return n%60===0?(n>0?"-":"+")+Fe(Math.abs(n)/60,2):kt(n,t)}function kt(n,t=""){const e=n>0?"-":"+",r=Math.abs(n),o=Fe(Math.trunc(r/60),2),a=Fe(r%60,2);return e+o+t+a}const Gn=(n,t)=>{switch(n){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},zn=(n,t)=>{switch(n){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},fn={p:zn,P:(n,t)=>{const e=n.match(/(P+)(p+)?/)||[],r=e[1],o=e[2];if(!o)return Gn(n,t);let a;switch(r){case"P":a=t.dateTime({width:"short"});break;case"PP":a=t.dateTime({width:"medium"});break;case"PPP":a=t.dateTime({width:"long"});break;case"PPPP":default:a=t.dateTime({width:"full"});break}return a.replace("{{date}}",Gn(r,t)).replace("{{time}}",zn(o,t))}},ea=/^D+$/,ta=/^Y+$/,na=["D","DD","YY","YYYY"];function Yn(n){return ea.test(n)}function Un(n){return ta.test(n)}function pn(n,t,e){const r=ra(n,t,e);if(console.warn(r),na.includes(n))throw new RangeError(r)}function ra(n,t,e){const r=n[0]==="Y"?"years":"days of the month";return`Use \`${n.toLowerCase()}\` instead of \`${n}\` (in \`${t}\`) for formatting ${r} to the input \`${e}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const oa=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,ia=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,aa=/^'([^]*?)'?$/,sa=/''/g,la=/[a-zA-Z]/;function Yt(n,t,e){var d,u,p,m;const r=Bt(),o=r.locale??Rn,a=r.firstWeekContainsDate??((u=(d=r.locale)==null?void 0:d.options)==null?void 0:u.firstWeekContainsDate)??1,s=r.weekStartsOn??((m=(p=r.locale)==null?void 0:p.options)==null?void 0:m.weekStartsOn)??0,l=Ue(n);if(!Hn(l))throw new RangeError("Invalid time value");let c=t.match(ia).map(h=>{const V=h[0];if(V==="p"||V==="P"){const C=fn[V];return C(h,o.formatLong)}return h}).join("").match(oa).map(h=>{if(h==="''")return{isToken:!1,value:"'"};const V=h[0];if(V==="'")return{isToken:!1,value:ua(h)};if(Wn[V])return{isToken:!0,value:h};if(V.match(la))throw new RangeError("Format string contains an unescaped latin alphabet character `"+V+"`");return{isToken:!1,value:h}});o.localize.preprocessor&&(c=o.localize.preprocessor(l,c));const f={firstWeekContainsDate:a,weekStartsOn:s,locale:o};return c.map(h=>{if(!h.isToken)return h.value;const V=h.value;(Un(V)||Yn(V))&&pn(V,t,String(n));const C=Wn[V[0]];return C(l,V,o.localize,f)}).join("")}function ua(n){const t=n.match(aa);return t?t[1].replace(sa,"'"):n}function ca(){return Object.assign({},Bt())}function da(n){let e=Ue(n).getDay();return e===0&&(e=7),e}function fa(n,t){const e=t instanceof Date?We(t,0):new t(0);return e.setFullYear(n.getFullYear(),n.getMonth(),n.getDate()),e.setHours(n.getHours(),n.getMinutes(),n.getSeconds(),n.getMilliseconds()),e}const pa=10;class Xn{constructor(){E(this,"subPriority",0)}validate(t,e){return!0}}class ma extends Xn{constructor(t,e,r,o,a){super(),this.value=t,this.validateValue=e,this.setValue=r,this.priority=o,a&&(this.subPriority=a)}validate(t,e){return this.validateValue(t,this.value,e)}set(t,e,r){return this.setValue(t,e,this.value,r)}}class ha extends Xn{constructor(){super(...arguments);E(this,"priority",pa);E(this,"subPriority",-1)}set(e,r){return r.timestampIsSet?e:We(e,fa(e,Date))}}class Ve{run(t,e,r,o){const a=this.parse(t,e,r,o);return a?{setter:new ma(a.value,this.validate,this.set,this.priority,this.subPriority),rest:a.rest}:null}validate(t,e,r){return!0}}class ga extends Ve{constructor(){super(...arguments);E(this,"priority",140);E(this,"incompatibleTokens",["R","u","t","T"])}parse(e,r,o){switch(r){case"G":case"GG":case"GGG":return o.era(e,{width:"abbreviated"})||o.era(e,{width:"narrow"});case"GGGGG":return o.era(e,{width:"narrow"});case"GGGG":default:return o.era(e,{width:"wide"})||o.era(e,{width:"abbreviated"})||o.era(e,{width:"narrow"})}}set(e,r,o){return r.era=o,e.setFullYear(o,0,1),e.setHours(0,0,0,0),e}}const Ae={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}/},ut={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 Ge(n,t){return n&&{value:t(n.value),rest:n.rest}}function $e(n,t){const e=t.match(n);return e?{value:parseInt(e[0],10),rest:t.slice(e[0].length)}:null}function ct(n,t){const e=t.match(n);if(!e)return null;if(e[0]==="Z")return{value:0,rest:t.slice(1)};const r=e[1]==="+"?1:-1,o=e[2]?parseInt(e[2],10):0,a=e[3]?parseInt(e[3],10):0,s=e[5]?parseInt(e[5],10):0;return{value:r*(o*mi+a*pi+s*hi),rest:t.slice(e[0].length)}}function Qn(n){return $e(Ae.anyDigitsSigned,n)}function qe(n,t){switch(n){case 1:return $e(Ae.singleDigit,t);case 2:return $e(Ae.twoDigits,t);case 3:return $e(Ae.threeDigits,t);case 4:return $e(Ae.fourDigits,t);default:return $e(new RegExp("^\\d{1,"+n+"}"),t)}}function Ut(n,t){switch(n){case 1:return $e(Ae.singleDigitSigned,t);case 2:return $e(Ae.twoDigitsSigned,t);case 3:return $e(Ae.threeDigitsSigned,t);case 4:return $e(Ae.fourDigitsSigned,t);default:return $e(new RegExp("^-?\\d{1,"+n+"}"),t)}}function mn(n){switch(n){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 Kn(n,t){const e=t>0,r=e?t:1-t;let o;if(r<=50)o=n||100;else{const a=r+50,s=Math.trunc(a/100)*100,l=n>=a%100;o=n+s-(l?100:0)}return e?o:1-o}function Jn(n){return n%400===0||n%4===0&&n%100!==0}class ya extends Ve{constructor(){super(...arguments);E(this,"priority",130);E(this,"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"])}parse(e,r,o){const a=s=>({year:s,isTwoDigitYear:r==="yy"});switch(r){case"y":return Ge(qe(4,e),a);case"yo":return Ge(o.ordinalNumber(e,{unit:"year"}),a);default:return Ge(qe(r.length,e),a)}}validate(e,r){return r.isTwoDigitYear||r.year>0}set(e,r,o){const a=e.getFullYear();if(o.isTwoDigitYear){const l=Kn(o.year,a);return e.setFullYear(l,0,1),e.setHours(0,0,0,0),e}const s=!("era"in r)||r.era===1?o.year:1-o.year;return e.setFullYear(s,0,1),e.setHours(0,0,0,0),e}}class va extends Ve{constructor(){super(...arguments);E(this,"priority",130);E(this,"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"])}parse(e,r,o){const a=s=>({year:s,isTwoDigitYear:r==="YY"});switch(r){case"Y":return Ge(qe(4,e),a);case"Yo":return Ge(o.ordinalNumber(e,{unit:"year"}),a);default:return Ge(qe(r.length,e),a)}}validate(e,r){return r.isTwoDigitYear||r.year>0}set(e,r,o,a){const s=dn(e,a);if(o.isTwoDigitYear){const c=Kn(o.year,s);return e.setFullYear(c,0,a.firstWeekContainsDate),e.setHours(0,0,0,0),yt(e,a)}const l=!("era"in r)||r.era===1?o.year:1-o.year;return e.setFullYear(l,0,a.firstWeekContainsDate),e.setHours(0,0,0,0),yt(e,a)}}class ba extends Ve{constructor(){super(...arguments);E(this,"priority",130);E(this,"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"])}parse(e,r){return Ut(r==="R"?4:r.length,e)}set(e,r,o){const a=We(e,0);return a.setFullYear(o,0,4),a.setHours(0,0,0,0),Dt(a)}}class wa extends Ve{constructor(){super(...arguments);E(this,"priority",130);E(this,"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"])}parse(e,r){return Ut(r==="u"?4:r.length,e)}set(e,r,o){return e.setFullYear(o,0,1),e.setHours(0,0,0,0),e}}class Ca extends Ve{constructor(){super(...arguments);E(this,"priority",120);E(this,"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"])}parse(e,r,o){switch(r){case"Q":case"QQ":return qe(r.length,e);case"Qo":return o.ordinalNumber(e,{unit:"quarter"});case"QQQ":return o.quarter(e,{width:"abbreviated",context:"formatting"})||o.quarter(e,{width:"narrow",context:"formatting"});case"QQQQQ":return o.quarter(e,{width:"narrow",context:"formatting"});case"QQQQ":default:return o.quarter(e,{width:"wide",context:"formatting"})||o.quarter(e,{width:"abbreviated",context:"formatting"})||o.quarter(e,{width:"narrow",context:"formatting"})}}validate(e,r){return r>=1&&r<=4}set(e,r,o){return e.setMonth((o-1)*3,1),e.setHours(0,0,0,0),e}}class xa extends Ve{constructor(){super(...arguments);E(this,"priority",120);E(this,"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"])}parse(e,r,o){switch(r){case"q":case"qq":return qe(r.length,e);case"qo":return o.ordinalNumber(e,{unit:"quarter"});case"qqq":return o.quarter(e,{width:"abbreviated",context:"standalone"})||o.quarter(e,{width:"narrow",context:"standalone"});case"qqqqq":return o.quarter(e,{width:"narrow",context:"standalone"});case"qqqq":default:return o.quarter(e,{width:"wide",context:"standalone"})||o.quarter(e,{width:"abbreviated",context:"standalone"})||o.quarter(e,{width:"narrow",context:"standalone"})}}validate(e,r){return r>=1&&r<=4}set(e,r,o){return e.setMonth((o-1)*3,1),e.setHours(0,0,0,0),e}}class _a extends Ve{constructor(){super(...arguments);E(this,"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]);E(this,"priority",110)}parse(e,r,o){const a=s=>s-1;switch(r){case"M":return Ge($e(Ae.month,e),a);case"MM":return Ge(qe(2,e),a);case"Mo":return Ge(o.ordinalNumber(e,{unit:"month"}),a);case"MMM":return o.month(e,{width:"abbreviated",context:"formatting"})||o.month(e,{width:"narrow",context:"formatting"});case"MMMMM":return o.month(e,{width:"narrow",context:"formatting"});case"MMMM":default:return o.month(e,{width:"wide",context:"formatting"})||o.month(e,{width:"abbreviated",context:"formatting"})||o.month(e,{width:"narrow",context:"formatting"})}}validate(e,r){return r>=0&&r<=11}set(e,r,o){return e.setMonth(o,1),e.setHours(0,0,0,0),e}}class Sa extends Ve{constructor(){super(...arguments);E(this,"priority",110);E(this,"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"])}parse(e,r,o){const a=s=>s-1;switch(r){case"L":return Ge($e(Ae.month,e),a);case"LL":return Ge(qe(2,e),a);case"Lo":return Ge(o.ordinalNumber(e,{unit:"month"}),a);case"LLL":return o.month(e,{width:"abbreviated",context:"standalone"})||o.month(e,{width:"narrow",context:"standalone"});case"LLLLL":return o.month(e,{width:"narrow",context:"standalone"});case"LLLL":default:return o.month(e,{width:"wide",context:"standalone"})||o.month(e,{width:"abbreviated",context:"standalone"})||o.month(e,{width:"narrow",context:"standalone"})}}validate(e,r){return r>=0&&r<=11}set(e,r,o){return e.setMonth(o,1),e.setHours(0,0,0,0),e}}function Ta(n,t,e){const r=Ue(n),o=Ln(r,e)-t;return r.setDate(r.getDate()-o*7),r}class ka extends Ve{constructor(){super(...arguments);E(this,"priority",100);E(this,"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"])}parse(e,r,o){switch(r){case"w":return $e(Ae.week,e);case"wo":return o.ordinalNumber(e,{unit:"week"});default:return qe(r.length,e)}}validate(e,r){return r>=1&&r<=53}set(e,r,o,a){return yt(Ta(e,o,a),a)}}function Ma(n,t){const e=Ue(n),r=$n(e)-t;return e.setDate(e.getDate()-r*7),e}class Va extends Ve{constructor(){super(...arguments);E(this,"priority",100);E(this,"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"])}parse(e,r,o){switch(r){case"I":return $e(Ae.week,e);case"Io":return o.ordinalNumber(e,{unit:"week"});default:return qe(r.length,e)}}validate(e,r){return r>=1&&r<=53}set(e,r,o){return Dt(Ma(e,o))}}const Fa=[31,28,31,30,31,30,31,31,30,31,30,31],Ea=[31,29,31,30,31,30,31,31,30,31,30,31];class Na extends Ve{constructor(){super(...arguments);E(this,"priority",90);E(this,"subPriority",1);E(this,"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"])}parse(e,r,o){switch(r){case"d":return $e(Ae.date,e);case"do":return o.ordinalNumber(e,{unit:"date"});default:return qe(r.length,e)}}validate(e,r){const o=e.getFullYear(),a=Jn(o),s=e.getMonth();return a?r>=1&&r<=Ea[s]:r>=1&&r<=Fa[s]}set(e,r,o){return e.setDate(o),e.setHours(0,0,0,0),e}}class Oa extends Ve{constructor(){super(...arguments);E(this,"priority",90);E(this,"subpriority",1);E(this,"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"])}parse(e,r,o){switch(r){case"D":case"DD":return $e(Ae.dayOfYear,e);case"Do":return o.ordinalNumber(e,{unit:"date"});default:return qe(r.length,e)}}validate(e,r){const o=e.getFullYear();return Jn(o)?r>=1&&r<=366:r>=1&&r<=365}set(e,r,o){return e.setMonth(0,o),e.setHours(0,0,0,0),e}}function hn(n,t,e){var u,p,m,h;const r=Bt(),o=(e==null?void 0:e.weekStartsOn)??((p=(u=e==null?void 0:e.locale)==null?void 0:u.options)==null?void 0:p.weekStartsOn)??r.weekStartsOn??((h=(m=r.locale)==null?void 0:m.options)==null?void 0:h.weekStartsOn)??0,a=Ue(n),s=a.getDay(),c=(t%7+7)%7,f=7-o,d=t<0||t>6?t-(s+f)%7:(c+f)%7-(s+f)%7;return Pn(a,d)}class Ia extends Ve{constructor(){super(...arguments);E(this,"priority",90);E(this,"incompatibleTokens",["D","i","e","c","t","T"])}parse(e,r,o){switch(r){case"E":case"EE":case"EEE":return o.day(e,{width:"abbreviated",context:"formatting"})||o.day(e,{width:"short",context:"formatting"})||o.day(e,{width:"narrow",context:"formatting"});case"EEEEE":return o.day(e,{width:"narrow",context:"formatting"});case"EEEEEE":return o.day(e,{width:"short",context:"formatting"})||o.day(e,{width:"narrow",context:"formatting"});case"EEEE":default:return o.day(e,{width:"wide",context:"formatting"})||o.day(e,{width:"abbreviated",context:"formatting"})||o.day(e,{width:"short",context:"formatting"})||o.day(e,{width:"narrow",context:"formatting"})}}validate(e,r){return r>=0&&r<=6}set(e,r,o,a){return e=hn(e,o,a),e.setHours(0,0,0,0),e}}class Pa extends Ve{constructor(){super(...arguments);E(this,"priority",90);E(this,"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"])}parse(e,r,o,a){const s=l=>{const c=Math.floor((l-1)/7)*7;return(l+a.weekStartsOn+6)%7+c};switch(r){case"e":case"ee":return Ge(qe(r.length,e),s);case"eo":return Ge(o.ordinalNumber(e,{unit:"day"}),s);case"eee":return o.day(e,{width:"abbreviated",context:"formatting"})||o.day(e,{width:"short",context:"formatting"})||o.day(e,{width:"narrow",context:"formatting"});case"eeeee":return o.day(e,{width:"narrow",context:"formatting"});case"eeeeee":return o.day(e,{width:"short",context:"formatting"})||o.day(e,{width:"narrow",context:"formatting"});case"eeee":default:return o.day(e,{width:"wide",context:"formatting"})||o.day(e,{width:"abbreviated",context:"formatting"})||o.day(e,{width:"short",context:"formatting"})||o.day(e,{width:"narrow",context:"formatting"})}}validate(e,r){return r>=0&&r<=6}set(e,r,o,a){return e=hn(e,o,a),e.setHours(0,0,0,0),e}}class Ba extends Ve{constructor(){super(...arguments);E(this,"priority",90);E(this,"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"])}parse(e,r,o,a){const s=l=>{const c=Math.floor((l-1)/7)*7;return(l+a.weekStartsOn+6)%7+c};switch(r){case"c":case"cc":return Ge(qe(r.length,e),s);case"co":return Ge(o.ordinalNumber(e,{unit:"day"}),s);case"ccc":return o.day(e,{width:"abbreviated",context:"standalone"})||o.day(e,{width:"short",context:"standalone"})||o.day(e,{width:"narrow",context:"standalone"});case"ccccc":return o.day(e,{width:"narrow",context:"standalone"});case"cccccc":return o.day(e,{width:"short",context:"standalone"})||o.day(e,{width:"narrow",context:"standalone"});case"cccc":default:return o.day(e,{width:"wide",context:"standalone"})||o.day(e,{width:"abbreviated",context:"standalone"})||o.day(e,{width:"short",context:"standalone"})||o.day(e,{width:"narrow",context:"standalone"})}}validate(e,r){return r>=0&&r<=6}set(e,r,o,a){return e=hn(e,o,a),e.setHours(0,0,0,0),e}}function Da(n,t){const e=Ue(n),r=da(e),o=t-r;return Pn(e,o)}class ja extends Ve{constructor(){super(...arguments);E(this,"