zignal-stencil-library 1.1.149 → 1.1.151
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/autocomplete-address_44.cjs.entry.js +88 -55
- package/dist/cjs/{dayjs-BSEUEjDP.js → dayjs-C-Yh2o_8.js} +1 -1
- package/dist/cjs/{index-BcqF7VoK.js → index-BXiJqJvp.js} +14 -2
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/quick-message-app.cjs.entry.js +3 -3
- package/dist/cjs/zignal-stencil-library.cjs.js +1 -1
- package/dist/collection/components/autocomplete-address/autocomplete-address.css +1 -1
- package/dist/collection/components/autocomplete-multiple-select/autocomplete-multiple-select.css +1 -1
- package/dist/collection/components/autocomplete-select/autocomplete-select.css +1 -1
- package/dist/collection/components/channel-box/channel-box.css +1 -1
- package/dist/collection/components/chat-app/chat-app.css +1 -1
- package/dist/collection/components/chat-header/chat-header.css +1 -1
- package/dist/collection/components/chat-input/chat-input.css +1 -1
- package/dist/collection/components/chat-input/chat-input.js +3 -2
- package/dist/collection/components/checkbox-list/checkbox-list.css +1 -1
- package/dist/collection/components/dialog-bill-editor/dialog-bill-editor.css +1 -1
- package/dist/collection/components/dialog-custom-filter/dialog-custom-filter.css +1 -1
- package/dist/collection/components/dialog-editor/dialog-editor.css +1 -1
- package/dist/collection/components/dialog-preview-media/dialog-preview-media.css +1 -1
- package/dist/collection/components/dialog-search/dialog-search.css +1 -1
- package/dist/collection/components/internal-component/chat-item.js +2 -2
- package/dist/collection/components/menu-chat-channel/menu-chat-channel.css +1 -1
- package/dist/collection/components/menu-chat-type/menu-chat-type.css +1 -1
- package/dist/collection/components/menu-list/menu-list.css +1 -1
- package/dist/collection/components/message-box/message-box.css +1 -1
- package/dist/collection/components/message-box/message-box.js +44 -11
- package/dist/collection/components/message-content/message-content.css +1 -1
- package/dist/collection/components/message-item/message-item.css +1 -1
- package/dist/collection/components/message-media/message-media.css +1 -1
- package/dist/collection/components/profile-history/profile-history.css +1 -1
- package/dist/collection/components/profile-info/profile-info.css +1 -1
- package/dist/collection/components/profile-media/profile-media.css +1 -1
- package/dist/collection/components/profile-tabs/profile-tabs.css +1 -1
- package/dist/collection/components/quick-message-add-template/quick-message-add-template.css +1 -1
- package/dist/collection/components/quick-message-app/quick-message-app.css +1 -1
- package/dist/collection/components/quick-message-file/quick-message-file.css +1 -1
- package/dist/collection/components/quick-message-image/quick-message-image.css +1 -1
- package/dist/collection/components/quick-message-modal/quick-message-modal.css +1 -1
- package/dist/collection/components/quick-message-template/quick-message-template.css +1 -1
- package/dist/collection/components/search-box/search-box.css +1 -1
- package/dist/collection/components/status-badge/status-badge.css +1 -1
- package/dist/collection/components/tag-list/tag-list.css +1 -1
- package/dist/collection/components/tag-or-status-item/tag-or-status-item.css +1 -1
- package/dist/collection/components/tag-popper/tag-popper.css +1 -1
- package/dist/collection/components/typography-clamp/typography-clamp.css +1 -1
- package/dist/collection/components/z-avatar/z-avatar.css +1 -1
- package/dist/collection/components/z-dialog/z-dialog.css +1 -1
- package/dist/components/autocomplete-address.js +1 -1
- package/dist/components/autocomplete-multiple-select.js +1 -1
- package/dist/components/autocomplete-select.js +1 -1
- package/dist/components/channel-box.js +1 -1
- package/dist/components/chat-app.js +39 -39
- package/dist/components/chat-header.js +1 -1
- package/dist/components/chat-input.js +1 -1
- package/dist/components/checkbox-list.js +1 -1
- package/dist/components/dialog-bill-editor.js +1 -1
- package/dist/components/dialog-custom-filter.js +1 -1
- package/dist/components/dialog-editor.js +1 -1
- package/dist/components/dialog-preview-media.js +1 -1
- package/dist/components/dialog-search.js +1 -1
- package/dist/components/index.js +14 -2
- package/dist/components/menu-chat-channel.js +1 -1
- package/dist/components/menu-chat-type.js +1 -1
- package/dist/components/menu-list.js +1 -1
- package/dist/components/message-box.js +1 -1
- package/dist/components/message-content.js +1 -1
- package/dist/components/message-item.js +1 -1
- package/dist/components/message-media.js +1 -1
- package/dist/components/p-9C7AwGvM.js +223 -0
- package/dist/components/p-BB9ah96y.js +554 -0
- package/dist/components/p-BRpYxO3M.js +119 -0
- package/dist/components/p-BTCmyW_D.js +98 -0
- package/dist/components/p-BYBimJCQ.js +312 -0
- package/dist/components/p-BZZk_Nhz.js +515 -0
- package/dist/components/p-BhBNwwRB.js +154 -0
- package/dist/components/p-Bmp0v9GX.js +51 -0
- package/dist/components/p-Bp0zz6Y6.js +135 -0
- package/dist/components/p-BsI1HZGG.js +266 -0
- package/dist/components/p-BzKx9Adn.js +611 -0
- package/dist/components/p-C5VvgOE9.js +599 -0
- package/dist/components/p-CE3c3IL-.js +128 -0
- package/dist/components/p-CNszmmDL.js +102 -0
- package/dist/components/p-COZKLVfW.js +168 -0
- package/dist/components/p-CYRSDtTf.js +57 -0
- package/dist/components/p-CZ3iEwuo.js +563 -0
- package/dist/components/p-C_PDZKGG.js +158 -0
- package/dist/components/p-CeBFtax1.js +166 -0
- package/dist/components/p-CimyVUlr.js +32 -0
- package/dist/components/p-Ck5c82Vm.js +74 -0
- package/dist/components/p-Cq4sFbGO.js +129 -0
- package/dist/components/p-CtoKbtXk.js +156 -0
- package/dist/components/p-D8oZapy4.js +230 -0
- package/dist/components/p-DKBK5jV_.js +122 -0
- package/dist/components/p-DOxk_wHY.js +107 -0
- package/dist/components/p-DQYxfaQG.js +108 -0
- package/dist/components/p-DSkVwgQ_.js +155 -0
- package/dist/components/p-DXAea_-R.js +96 -0
- package/dist/components/p-DfZBI89D.js +214 -0
- package/dist/components/p-Dt295Plo.js +178 -0
- package/dist/components/p-DtS5-nUS.js +231 -0
- package/dist/components/p-Dx2yZdeP.js +138 -0
- package/dist/components/p-MPfQpLuD.js +684 -0
- package/dist/components/p-_ZatmxBq.js +65 -0
- package/dist/components/p-vWZ6UOF3.js +161 -0
- package/dist/components/p-z4HeU4Nl.js +76 -0
- package/dist/components/p-zdFO-UlQ.js +171 -0
- package/dist/components/profile-history.js +1 -1
- package/dist/components/profile-info.js +1 -1
- package/dist/components/profile-media.js +1 -1
- package/dist/components/profile-tabs.js +1 -1
- package/dist/components/quick-message-add-template.js +1 -1
- package/dist/components/quick-message-app.js +6 -6
- package/dist/components/quick-message-file.js +1 -1
- package/dist/components/quick-message-image.js +1 -1
- package/dist/components/quick-message-modal.js +1 -1
- package/dist/components/quick-message-template.js +1 -1
- package/dist/components/search-box.js +1 -1
- package/dist/components/status-badge.js +1 -1
- package/dist/components/summarize-message-section.js +1 -1
- package/dist/components/tag-list.js +1 -1
- package/dist/components/tag-or-status-item.js +1 -1
- package/dist/components/tag-popper.js +1 -1
- package/dist/components/typography-clamp.js +1 -1
- package/dist/components/user-info-section.js +1 -1
- package/dist/components/z-avatar.js +1 -1
- package/dist/components/z-dialog.js +1 -1
- package/dist/esm/autocomplete-address_44.entry.js +88 -55
- package/dist/esm/{dayjs-CudFbPUo.js → dayjs-BzCDyqMN.js} +1 -1
- package/dist/esm/{index-B3nb31xy.js → index-DPOSmdTJ.js} +14 -2
- package/dist/esm/index.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/quick-message-app.entry.js +3 -3
- package/dist/esm/zignal-stencil-library.js +1 -1
- package/dist/types/components/message-box/message-box.d.ts +4 -0
- package/dist/zignal-stencil-library/index.esm.js +1 -1
- package/dist/zignal-stencil-library/p-DPOSmdTJ.js +1 -0
- package/dist/zignal-stencil-library/{p-QJh7p40E.js → p-DPcrmSvN.js} +1 -1
- package/dist/zignal-stencil-library/p-e66b7102.entry.js +2 -0
- package/dist/zignal-stencil-library/p-f6779826.entry.js +1 -0
- package/dist/zignal-stencil-library/zignal-stencil-library.esm.js +1 -1
- package/package.json +1 -1
- package/dist/components/p-5FDU529Q.js +0 -129
- package/dist/components/p-B3sv8Cpm.js +0 -684
- package/dist/components/p-B9PRtKKm.js +0 -554
- package/dist/components/p-BWv8MbzZ.js +0 -158
- package/dist/components/p-BZ7KCncK.js +0 -178
- package/dist/components/p-BaATyWCh.js +0 -102
- package/dist/components/p-Bd28bEf_.js +0 -155
- package/dist/components/p-Bk2GvoAQ.js +0 -515
- package/dist/components/p-BmD78zPG.js +0 -161
- package/dist/components/p-BpHIg6Zj.js +0 -122
- package/dist/components/p-C-wUv6vx.js +0 -98
- package/dist/components/p-C9lpq3mD.js +0 -578
- package/dist/components/p-CTCAyv3Q.js +0 -51
- package/dist/components/p-CWAhjm33.js +0 -74
- package/dist/components/p-CXYv5DLC.js +0 -128
- package/dist/components/p-C_OxAbGN.js +0 -598
- package/dist/components/p-CdDmXJDZ.js +0 -168
- package/dist/components/p-CgbHzdYE.js +0 -214
- package/dist/components/p-CmgyIFb-.js +0 -266
- package/dist/components/p-CnsAVxMy.js +0 -65
- package/dist/components/p-CpA5hc_o.js +0 -312
- package/dist/components/p-CzfGejIm.js +0 -119
- package/dist/components/p-D6IxrcVY.js +0 -166
- package/dist/components/p-D7LdFiVw.js +0 -57
- package/dist/components/p-D8yzEuEG.js +0 -108
- package/dist/components/p-DC0UH_ws.js +0 -231
- package/dist/components/p-DS1y2tKg.js +0 -563
- package/dist/components/p-DTaNTSq8.js +0 -107
- package/dist/components/p-D_Jqalu2.js +0 -135
- package/dist/components/p-DcC5eHv4.js +0 -230
- package/dist/components/p-DfKJdTvJ.js +0 -32
- package/dist/components/p-DrueVuU5.js +0 -223
- package/dist/components/p-DsWfCgkk.js +0 -154
- package/dist/components/p-Du5YXEgv.js +0 -156
- package/dist/components/p-Kj4A18ko.js +0 -138
- package/dist/components/p-KkLF26TT.js +0 -76
- package/dist/components/p-Sc5G6hdD.js +0 -96
- package/dist/components/p-j1XqaFsN.js +0 -171
- package/dist/zignal-stencil-library/p-47a5491a.entry.js +0 -1
- package/dist/zignal-stencil-library/p-B3nb31xy.js +0 -1
- package/dist/zignal-stencil-library/p-efc109b8.entry.js +0 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const t=t=>"string"==typeof t,e=()=>{let t,e;const s=new Promise(((s,i)=>{t=s,e=i}));return s.resolve=t,s.reject=e,s},s=t=>null==t?"":""+t,i=/###/g,n=t=>t&&t.indexOf("###")>-1?t.replace(i,"."):t,a=e=>!e||t(e),o=(e,s,i)=>{const o=t(s)?s.split("."):s;let r=0;for(;r<o.length-1;){if(a(e))return{};const t=n(o[r]);!e[t]&&i&&(e[t]=new i),e=Object.prototype.hasOwnProperty.call(e,t)?e[t]:{},++r}return a(e)?{}:{obj:e,k:n(o[r])}},r=(t,e,s)=>{const{obj:i,k:n}=o(t,e,Object);if(void 0!==i||1===e.length)return void(i[n]=s);let a=e[e.length-1],r=e.slice(0,e.length-1),h=o(t,r,Object);for(;void 0===h.obj&&r.length;)a=`${r[r.length-1]}.${a}`,r=r.slice(0,r.length-1),h=o(t,r,Object),h?.obj&&void 0!==h.obj[`${h.k}.${a}`]&&(h.obj=void 0);h.obj[`${h.k}.${a}`]=s},h=(t,e)=>{const{obj:s,k:i}=o(t,e);if(s&&Object.prototype.hasOwnProperty.call(s,i))return s[i]},l=(e,s,i)=>{for(const n in s)"__proto__"!==n&&"constructor"!==n&&(n in e?t(e[n])||e[n]instanceof String||t(s[n])||s[n]instanceof String?i&&(e[n]=s[n]):l(e[n],s[n],i):e[n]=s[n]);return e},c=t=>t.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var d={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const u=e=>t(e)?e.replace(/[&<>"'\/]/g,(t=>d[t])):e,_=[" ",",","?","!",";"],p=new class{constructor(t){this.capacity=t,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(t){const e=this.regExpMap.get(t);if(void 0!==e)return e;const s=new RegExp(t);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(t,s),this.regExpQueue.push(t),s}}(20),f=(t,e,s=".")=>{if(!t)return;if(t[e]){if(!Object.prototype.hasOwnProperty.call(t,e))return;return t[e]}const i=e.split(s);let n=t;for(let t=0;t<i.length;){if(!n||"object"!=typeof n)return;let e,a="";for(let o=t;o<i.length;++o)if(o!==t&&(a+=s),a+=i[o],e=n[a],void 0!==e){if(["string","number","boolean"].indexOf(typeof e)>-1&&o<i.length-1)continue;t+=o-t+1;break}n=e}return n},m=t=>t?.replace("_","-"),g={type:"logger",log(t){this.output("log",t)},warn(t){this.output("warn",t)},error(t){this.output("error",t)},output(t,e){console?.[t]?.apply?.(console,e)}};class y{constructor(t,e={}){this.init(t,e)}init(t,e={}){this.prefix=e.prefix||"i18next:",this.logger=t||g,this.options=e,this.debug=e.debug}log(...t){return this.forward(t,"log","",!0)}warn(...t){return this.forward(t,"warn","",!0)}error(...t){return this.forward(t,"error","")}deprecate(...t){return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}forward(e,s,i,n){return n&&!this.debug?null:(t(e[0])&&(e[0]=`${i}${this.prefix} ${e[0]}`),this.logger[s](e))}create(t){return new y(this.logger,{prefix:`${this.prefix}:${t}:`,...this.options})}clone(t){return(t=t||this.options).prefix=t.prefix||this.prefix,new y(this.logger,t)}}var v=new y;class b{constructor(){this.observers={}}on(t,e){return t.split(" ").forEach((t=>{this.observers[t]||(this.observers[t]=new Map);const s=this.observers[t].get(e)||0;this.observers[t].set(e,s+1)})),this}off(t,e){this.observers[t]&&(e?this.observers[t].delete(e):delete this.observers[t])}emit(t,...e){this.observers[t]&&Array.from(this.observers[t].entries()).forEach((([t,s])=>{for(let i=0;i<s;i++)t(...e)})),this.observers["*"]&&Array.from(this.observers["*"].entries()).forEach((([s,i])=>{for(let n=0;n<i;n++)s.apply(s,[t,...e])}))}}class $ extends b{constructor(t,e={ns:["translation"],defaultNS:"translation"}){super(),this.data=t||{},this.options=e,void 0===this.options.keySeparator&&(this.options.keySeparator="."),void 0===this.options.ignoreJSONStructure&&(this.options.ignoreJSONStructure=!0)}addNamespaces(t){this.options.ns.indexOf(t)<0&&this.options.ns.push(t)}removeNamespaces(t){const e=this.options.ns.indexOf(t);e>-1&&this.options.ns.splice(e,1)}getResource(e,s,i,n={}){const a=void 0!==n.keySeparator?n.keySeparator:this.options.keySeparator,o=void 0!==n.ignoreJSONStructure?n.ignoreJSONStructure:this.options.ignoreJSONStructure;let r;e.indexOf(".")>-1?r=e.split("."):(r=[e,s],i&&(Array.isArray(i)?r.push(...i):t(i)&&a?r.push(...i.split(a)):r.push(i)));const l=h(this.data,r);return!l&&!s&&!i&&e.indexOf(".")>-1&&(e=r[0],s=r[1],i=r.slice(2).join(".")),!l&&o&&t(i)?f(this.data?.[e]?.[s],i,a):l}addResource(t,e,s,i,n={silent:!1}){const a=void 0!==n.keySeparator?n.keySeparator:this.options.keySeparator;let o=[t,e];s&&(o=o.concat(a?s.split(a):s)),t.indexOf(".")>-1&&(o=t.split("."),i=e,e=o[1]),this.addNamespaces(e),r(this.data,o,i),n.silent||this.emit("added",t,e,s,i)}addResources(e,s,i,n={silent:!1}){for(const n in i)(t(i[n])||Array.isArray(i[n]))&&this.addResource(e,s,n,i[n],{silent:!0});n.silent||this.emit("added",e,s,i)}addResourceBundle(t,e,s,i,n,a={silent:!1,skipCopy:!1}){let o=[t,e];t.indexOf(".")>-1&&(o=t.split("."),i=s,s=e,e=o[1]),this.addNamespaces(e);let c=h(this.data,o)||{};a.skipCopy||(s=JSON.parse(JSON.stringify(s))),i?l(c,s,n):c={...c,...s},r(this.data,o,c),a.silent||this.emit("added",t,e,s)}removeResourceBundle(t,e){this.hasResourceBundle(t,e)&&delete this.data[t][e],this.removeNamespaces(e),this.emit("removed",t,e)}hasResourceBundle(t,e){return void 0!==this.getResource(t,e)}getResourceBundle(t,e){return e||(e=this.options.defaultNS),this.getResource(t,e)}getDataByLanguage(t){return this.data[t]}hasLanguageSomeTranslations(t){const e=this.getDataByLanguage(t);return!!(e&&Object.keys(e)||[]).find((t=>e[t]&&Object.keys(e[t]).length>0))}toJSON(){return this.data}}var w={processors:{},addPostProcessor(t){this.processors[t.name]=t},handle(t,e,s,i,n){return t.forEach((t=>{e=this.processors[t]?.process(e,s,i,n)??e})),e}};const x=Symbol("i18next/PATH_KEY");function k(t,e){const{[x]:s}=t(function(){const t=[],e=Object.create(null);let s;return e.get=(i,n)=>(s?.revoke?.(),n===x?t:(t.push(n),s=Proxy.revocable(i,e),s.proxy)),Proxy.revocable(Object.create(null),e).proxy}());return s.join(e?.keySeparator??".")}const S={},j=e=>!t(e)&&"boolean"!=typeof e&&"number"!=typeof e;class O extends b{constructor(t,e={}){super(),((t,e,s)=>{["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"].forEach((t=>{e[t]&&(s[t]=e[t])}))})(0,t,this),this.options=e,void 0===this.options.keySeparator&&(this.options.keySeparator="."),this.logger=v.create("translator")}changeLanguage(t){t&&(this.language=t)}exists(t,e={interpolation:{}}){const s={...e};if(null==t)return!1;const i=this.resolve(t,s);if(void 0===i?.res)return!1;const n=j(i.res);return!1!==s.returnObjects||!n}extractFromKey(e,s){let i=void 0!==s.nsSeparator?s.nsSeparator:this.options.nsSeparator;void 0===i&&(i=":");const n=void 0!==s.keySeparator?s.keySeparator:this.options.keySeparator;let a=s.ns||this.options.defaultNS||[];const o=i&&e.indexOf(i)>-1,r=!(this.options.userDefinedKeySeparator||s.keySeparator||this.options.userDefinedNsSeparator||s.nsSeparator||((t,e,s)=>{e=e||"",s=s||"";const i=_.filter((t=>e.indexOf(t)<0&&s.indexOf(t)<0));if(0===i.length)return!0;const n=p.getRegExp(`(${i.map((t=>"?"===t?"\\?":t)).join("|")})`);let a=!n.test(t);if(!a){const e=t.indexOf(s);e>0&&!n.test(t.substring(0,e))&&(a=!0)}return a})(e,i,n));if(o&&!r){const s=e.match(this.interpolator.nestingRegexp);if(s&&s.length>0)return{key:e,namespaces:t(a)?[a]:a};const o=e.split(i);(i!==n||i===n&&this.options.ns.indexOf(o[0])>-1)&&(a=o.shift()),e=o.join(n)}return{key:e,namespaces:t(a)?[a]:a}}translate(e,s,i){let n="object"==typeof s?{...s}:s;if("object"!=typeof n&&this.options.overloadTranslationOptionHandler&&(n=this.options.overloadTranslationOptionHandler(arguments)),"object"==typeof n&&(n={...n}),n||(n={}),null==e)return"";"function"==typeof e&&(e=k(e,{...this.options,...n})),Array.isArray(e)||(e=[String(e)]);const a=void 0!==n.returnDetails?n.returnDetails:this.options.returnDetails,o=void 0!==n.keySeparator?n.keySeparator:this.options.keySeparator,{key:r,namespaces:h}=this.extractFromKey(e[e.length-1],n),l=h[h.length-1];let c=void 0!==n.nsSeparator?n.nsSeparator:this.options.nsSeparator;void 0===c&&(c=":");const d=n.lng||this.language,u=n.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if("cimode"===d?.toLowerCase())return u?a?{res:`${l}${c}${r}`,usedKey:r,exactUsedKey:r,usedLng:d,usedNS:l,usedParams:this.getUsedParamsDetails(n)}:`${l}${c}${r}`:a?{res:r,usedKey:r,exactUsedKey:r,usedLng:d,usedNS:l,usedParams:this.getUsedParamsDetails(n)}:r;const _=this.resolve(e,n);let p=_?.res;const f=_?.usedKey||r,m=_?.exactUsedKey||r,g=void 0!==n.joinArrays?n.joinArrays:this.options.joinArrays,y=!this.i18nFormat||this.i18nFormat.handleAsObject,v=void 0!==n.count&&!t(n.count),b=O.hasDefaultValue(n),$=v?this.pluralResolver.getSuffix(d,n.count,n):"",w=n.ordinal&&v?this.pluralResolver.getSuffix(d,n.count,{ordinal:!1}):"",x=v&&!n.ordinal&&0===n.count,S=x&&n[`defaultValue${this.options.pluralSeparator}zero`]||n[`defaultValue${$}`]||n[`defaultValue${w}`]||n.defaultValue;let N=p;y&&!p&&b&&(N=S);const R=j(N),A=Object.prototype.toString.apply(N);if(!(y&&N&&R&&["[object Number]","[object Function]","[object RegExp]"].indexOf(A)<0)||t(g)&&Array.isArray(N))if(y&&t(g)&&Array.isArray(p))p=p.join(g),p&&(p=this.extendTranslation(p,e,n,i));else{let t=!1,s=!1;!this.isValidLookup(p)&&b&&(t=!0,p=S),this.isValidLookup(p)||(s=!0,p=r);const a=(n.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&s?void 0:p,h=b&&S!==p&&this.options.updateMissing;if(s||t||h){if(this.logger.log(h?"updateKey":"missingKey",d,l,r,h?S:p),o){const t=this.resolve(r,{...n,keySeparator:!1});t&&t.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let t=[];const e=this.languageUtils.getFallbackCodes(this.options.fallbackLng,n.lng||this.language);if("fallback"===this.options.saveMissingTo&&e&&e[0])for(let s=0;s<e.length;s++)t.push(e[s]);else"all"===this.options.saveMissingTo?t=this.languageUtils.toResolveHierarchy(n.lng||this.language):t.push(n.lng||this.language);const s=(t,e,s)=>{const i=b&&s!==p?s:a;this.options.missingKeyHandler?this.options.missingKeyHandler(t,l,e,i,h,n):this.backendConnector?.saveMissing&&this.backendConnector.saveMissing(t,l,e,i,h,n),this.emit("missingKey",t,l,e,p)};this.options.saveMissing&&(this.options.saveMissingPlurals&&v?t.forEach((t=>{const e=this.pluralResolver.getSuffixes(t,n);x&&n[`defaultValue${this.options.pluralSeparator}zero`]&&e.indexOf(`${this.options.pluralSeparator}zero`)<0&&e.push(`${this.options.pluralSeparator}zero`),e.forEach((e=>{s([t],r+e,n[`defaultValue${e}`]||S)}))})):s(t,r,S))}p=this.extendTranslation(p,e,n,_,i),s&&p===r&&this.options.appendNamespaceToMissingKey&&(p=`${l}${c}${r}`),(s||t)&&this.options.parseMissingKeyHandler&&(p=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}${c}${r}`:r,t?p:void 0,n))}else{if(!n.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const t=this.options.returnedObjectHandler?this.options.returnedObjectHandler(f,N,{...n,ns:h}):`key '${r} (${this.language})' returned an object instead of string.`;return a?(_.res=t,_.usedParams=this.getUsedParamsDetails(n),_):t}if(o){const t=Array.isArray(N),e=t?[]:{},s=t?m:f;for(const t in N)if(Object.prototype.hasOwnProperty.call(N,t)){const i=`${s}${o}${t}`;e[t]=this.translate(i,b&&!p?{...n,defaultValue:j(S)?S[t]:void 0,joinArrays:!1,ns:h}:{...n,joinArrays:!1,ns:h}),e[t]===i&&(e[t]=N[t])}p=e}}return a?(_.res=p,_.usedParams=this.getUsedParamsDetails(n),_):p}extendTranslation(e,s,i,n,a){if(this.i18nFormat?.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...i},i.lng||this.language||n.usedLng,n.usedNS,n.usedKey,{resolved:n});else if(!i.skipInterpolation){i.interpolation&&this.interpolator.init({...i,interpolation:{...this.options.interpolation,...i.interpolation}});const o=t(e)&&(void 0!==i?.interpolation?.skipOnVariables?i.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let r;if(o){const t=e.match(this.interpolator.nestingRegexp);r=t&&t.length}let h=i.replace&&!t(i.replace)?i.replace:i;if(this.options.interpolation.defaultVariables&&(h={...this.options.interpolation.defaultVariables,...h}),e=this.interpolator.interpolate(e,h,i.lng||this.language||n.usedLng,i),o){const t=e.match(this.interpolator.nestingRegexp);r<(t&&t.length)&&(i.nest=!1)}!i.lng&&n&&n.res&&(i.lng=this.language||n.usedLng),!1!==i.nest&&(e=this.interpolator.nest(e,((...t)=>a?.[0]!==t[0]||i.context?this.translate(...t,s):(this.logger.warn(`It seems you are nesting recursively key: ${t[0]} in key: ${s[0]}`),null)),i)),i.interpolation&&this.interpolator.reset()}const o=i.postProcess||this.options.postProcess,r=t(o)?[o]:o;return null!=e&&r?.length&&!1!==i.applyPostProcessor&&(e=w.handle(r,e,s,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...n,usedParams:this.getUsedParamsDetails(i)},...i}:i,this)),e}resolve(e,s={}){let i,n,a,o,r;return t(e)&&(e=[e]),e.forEach((e=>{if(this.isValidLookup(i))return;const h=this.extractFromKey(e,s),l=h.key;n=l;let c=h.namespaces;this.options.fallbackNS&&(c=c.concat(this.options.fallbackNS));const d=void 0!==s.count&&!t(s.count),u=d&&!s.ordinal&&0===s.count,_=void 0!==s.context&&(t(s.context)||"number"==typeof s.context)&&""!==s.context,p=s.lngs?s.lngs:this.languageUtils.toResolveHierarchy(s.lng||this.language,s.fallbackLng);c.forEach((t=>{this.isValidLookup(i)||(r=t,S[`${p[0]}-${t}`]||!this.utils?.hasLoadedNamespace||this.utils?.hasLoadedNamespace(r)||(S[`${p[0]}-${t}`]=!0,this.logger.warn(`key "${n}" for languages "${p.join(", ")}" won't get resolved as namespace "${r}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),p.forEach((e=>{if(this.isValidLookup(i))return;o=e;const n=[l];if(this.i18nFormat?.addLookupKeys)this.i18nFormat.addLookupKeys(n,l,e,t,s);else{let t;d&&(t=this.pluralResolver.getSuffix(e,s.count,s));const i=`${this.options.pluralSeparator}zero`,a=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(d&&(s.ordinal&&0===t.indexOf(a)&&n.push(l+t.replace(a,this.options.pluralSeparator)),n.push(l+t),u&&n.push(l+i)),_){const e=`${l}${this.options.contextSeparator||"_"}${s.context}`;n.push(e),d&&(s.ordinal&&0===t.indexOf(a)&&n.push(e+t.replace(a,this.options.pluralSeparator)),n.push(e+t),u&&n.push(e+i))}}let r;for(;r=n.pop();)this.isValidLookup(i)||(a=r,i=this.getResource(e,t,r,s))})))}))})),{res:i,usedKey:n,exactUsedKey:a,usedLng:o,usedNS:r}}isValidLookup(t){return!(void 0===t||!this.options.returnNull&&null===t||!this.options.returnEmptyString&&""===t)}getResource(t,e,s,i={}){return this.i18nFormat?.getResource?this.i18nFormat.getResource(t,e,s,i):this.resourceStore.getResource(t,e,s,i)}getUsedParamsDetails(e={}){const s=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],i=e.replace&&!t(e.replace);let n=i?e.replace:e;if(i&&void 0!==e.count&&(n.count=e.count),this.options.interpolation.defaultVariables&&(n={...this.options.interpolation.defaultVariables,...n}),!i){n={...n};for(const t of s)delete n[t]}return n}static hasDefaultValue(t){for(const e in t)if(Object.prototype.hasOwnProperty.call(t,e)&&"defaultValue"===e.substring(0,12)&&void 0!==t[e])return!0;return!1}}class N{constructor(t){this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=v.create("languageUtils")}getScriptPartFromCode(t){if(!(t=m(t))||t.indexOf("-")<0)return null;const e=t.split("-");return 2===e.length?null:(e.pop(),"x"===e[e.length-1].toLowerCase()?null:this.formatLanguageCode(e.join("-")))}getLanguagePartFromCode(t){if(!(t=m(t))||t.indexOf("-")<0)return t;const e=t.split("-");return this.formatLanguageCode(e[0])}formatLanguageCode(e){if(t(e)&&e.indexOf("-")>-1){let t;try{t=Intl.getCanonicalLocales(e)[0]}catch(t){}return t&&this.options.lowerCaseLng&&(t=t.toLowerCase()),t||(this.options.lowerCaseLng?e.toLowerCase():e)}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(t){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(t=this.getLanguagePartFromCode(t)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(t)>-1}getBestMatchFromCodes(t){if(!t)return null;let e;return t.forEach((t=>{if(e)return;const s=this.formatLanguageCode(t);this.options.supportedLngs&&!this.isSupportedCode(s)||(e=s)})),!e&&this.options.supportedLngs&&t.forEach((t=>{if(e)return;const s=this.getScriptPartFromCode(t);if(this.isSupportedCode(s))return e=s;const i=this.getLanguagePartFromCode(t);if(this.isSupportedCode(i))return e=i;e=this.options.supportedLngs.find((t=>t===i?t:t.indexOf("-")<0&&i.indexOf("-")<0?void 0:t.indexOf("-")>0&&i.indexOf("-")<0&&t.substring(0,t.indexOf("-"))===i||0===t.indexOf(i)&&i.length>1?t:void 0))})),e||(e=this.getFallbackCodes(this.options.fallbackLng)[0]),e}getFallbackCodes(e,s){if(!e)return[];if("function"==typeof e&&(e=e(s)),t(e)&&(e=[e]),Array.isArray(e))return e;if(!s)return e.default||[];let i=e[s];return i||(i=e[this.getScriptPartFromCode(s)]),i||(i=e[this.formatLanguageCode(s)]),i||(i=e[this.getLanguagePartFromCode(s)]),i||(i=e.default),i||[]}toResolveHierarchy(e,s){const i=this.getFallbackCodes((!1===s?[]:s)||this.options.fallbackLng||[],e),n=[],a=t=>{t&&(this.isSupportedCode(t)?n.push(t):this.logger.warn(`rejecting language code not found in supportedLngs: ${t}`))};return t(e)&&(e.indexOf("-")>-1||e.indexOf("_")>-1)?("languageOnly"!==this.options.load&&a(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&a(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&a(this.getLanguagePartFromCode(e))):t(e)&&a(this.formatLanguageCode(e)),i.forEach((t=>{n.indexOf(t)<0&&a(this.formatLanguageCode(t))})),n}}const R={zero:0,one:1,two:2,few:3,many:4,other:5},A={select:t=>1===t?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class P{constructor(t,e={}){this.languageUtils=t,this.options=e,this.logger=v.create("pluralResolver"),this.pluralRulesCache={}}addRule(t,e){this.rules[t]=e}clearCache(){this.pluralRulesCache={}}getRule(t,e={}){const s=m("dev"===t?"en":t),i=e.ordinal?"ordinal":"cardinal",n=JSON.stringify({cleanedCode:s,type:i});if(n in this.pluralRulesCache)return this.pluralRulesCache[n];let a;try{a=new Intl.PluralRules(s,{type:i})}catch(s){if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),A;if(!t.match(/-|_/))return A;const i=this.languageUtils.getLanguagePartFromCode(t);a=this.getRule(i,e)}return this.pluralRulesCache[n]=a,a}needsPlural(t,e={}){let s=this.getRule(t,e);return s||(s=this.getRule("dev",e)),s?.resolvedOptions().pluralCategories.length>1}getPluralFormsOfKey(t,e,s={}){return this.getSuffixes(t,s).map((t=>`${e}${t}`))}getSuffixes(t,e={}){let s=this.getRule(t,e);return s||(s=this.getRule("dev",e)),s?s.resolvedOptions().pluralCategories.sort(((t,e)=>R[t]-R[e])).map((t=>`${this.options.prepend}${e.ordinal?`ordinal${this.options.prepend}`:""}${t}`)):[]}getSuffix(t,e,s={}){const i=this.getRule(t,s);return i?`${this.options.prepend}${s.ordinal?`ordinal${this.options.prepend}`:""}${i.select(e)}`:(this.logger.warn(`no plural rule found for: ${t}`),this.getSuffix("dev",e,s))}}const L=(e,s,i,n=".",a=!0)=>{let o=((t,e,s)=>{const i=h(t,s);return void 0!==i?i:h(e,s)})(e,s,i);return!o&&a&&t(i)&&(o=f(e,i,n),void 0===o&&(o=f(s,i,n))),o},C=t=>t.replace(/\$/g,"$$$$");class E{constructor(t={}){this.logger=v.create("interpolator"),this.options=t,this.format=t?.interpolation?.format||(t=>t),this.init(t)}init(t={}){t.interpolation||(t.interpolation={escapeValue:!0});const{escape:e,escapeValue:s,useRawValueToEscape:i,prefix:n,prefixEscaped:a,suffix:o,suffixEscaped:r,formatSeparator:h,unescapeSuffix:l,unescapePrefix:d,nestingPrefix:_,nestingPrefixEscaped:p,nestingSuffix:f,nestingSuffixEscaped:m,nestingOptionsSeparator:g,maxReplaces:y,alwaysFormat:v}=t.interpolation;this.escape=void 0!==e?e:u,this.escapeValue=void 0===s||s,this.useRawValueToEscape=void 0!==i&&i,this.prefix=n?c(n):a||"{{",this.suffix=o?c(o):r||"}}",this.formatSeparator=h||",",this.unescapePrefix=l?"":d||"-",this.unescapeSuffix=this.unescapePrefix?"":l||"",this.nestingPrefix=_?c(_):p||c("$t("),this.nestingSuffix=f?c(f):m||c(")"),this.nestingOptionsSeparator=g||",",this.maxReplaces=y||1e3,this.alwaysFormat=void 0!==v&&v,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const t=(t,e)=>t?.source===e?(t.lastIndex=0,t):new RegExp(e,"g");this.regexp=t(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=t(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=t(this.nestingRegexp,`${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`)}interpolate(e,i,n,a){let o,r,h;const l=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=t=>{if(t.indexOf(this.formatSeparator)<0){const e=L(i,l,t,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(e,void 0,n,{...a,...i,interpolationkey:t}):e}const e=t.split(this.formatSeparator),s=e.shift().trim(),o=e.join(this.formatSeparator).trim();return this.format(L(i,l,s,this.options.keySeparator,this.options.ignoreJSONStructure),o,n,{...a,...i,interpolationkey:s})};this.resetRegExp();const d=a?.missingInterpolationHandler||this.options.missingInterpolationHandler,u=void 0!==a?.interpolation?.skipOnVariables?a.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:t=>C(t)},{regex:this.regexp,safeValue:t=>C(this.escapeValue?this.escape(t):t)}].forEach((i=>{for(h=0;o=i.regex.exec(e);){const n=o[1].trim();if(r=c(n),void 0===r)if("function"==typeof d){const s=d(e,o,a);r=t(s)?s:""}else if(a&&Object.prototype.hasOwnProperty.call(a,n))r="";else{if(u){r=o[0];continue}this.logger.warn(`missed to pass in variable ${n} for interpolating ${e}`),r=""}else t(r)||this.useRawValueToEscape||(r=s(r));const l=i.safeValue(r);if(e=e.replace(o[0],l),u?(i.regex.lastIndex+=r.length,i.regex.lastIndex-=o[0].length):i.regex.lastIndex=0,h++,h>=this.maxReplaces)break}})),e}nest(e,i,n={}){let a,o,r;const h=(t,e)=>{const s=this.nestingOptionsSeparator;if(t.indexOf(s)<0)return t;const i=t.split(new RegExp(`${s}[ ]*{`));let n=`{${i[1]}`;t=i[0],n=this.interpolate(n,r);const a=n.match(/'/g),o=n.match(/"/g);((a?.length??0)%2==0&&!o||o.length%2!=0)&&(n=n.replace(/'/g,'"'));try{r=JSON.parse(n),e&&(r={...e,...r})}catch(e){return this.logger.warn(`failed parsing options string in nesting for key ${t}`,e),`${t}${s}${n}`}return r.defaultValue&&r.defaultValue.indexOf(this.prefix)>-1&&delete r.defaultValue,t};for(;a=this.nestingRegexp.exec(e);){let l=[];r={...n},r=r.replace&&!t(r.replace)?r.replace:r,r.applyPostProcessor=!1,delete r.defaultValue;const c=/{.*}/.test(a[1])?a[1].lastIndexOf("}")+1:a[1].indexOf(this.formatSeparator);if(-1!==c&&(l=a[1].slice(c).split(this.formatSeparator).map((t=>t.trim())).filter(Boolean),a[1]=a[1].slice(0,c)),o=i(h.call(this,a[1].trim(),r),r),o&&a[0]===e&&!t(o))return o;t(o)||(o=s(o)),o||(this.logger.warn(`missed to resolve ${a[1]} for nesting ${e}`),o=""),l.length&&(o=l.reduce(((t,e)=>this.format(t,e,n.lng,{...n,interpolationkey:a[1].trim()})),o.trim())),e=e.replace(a[0],o),this.regexp.lastIndex=0}return e}}const T=t=>{const e={};return(s,i,n)=>{let a=n;n&&n.interpolationkey&&n.formatParams&&n.formatParams[n.interpolationkey]&&n[n.interpolationkey]&&(a={...a,[n.interpolationkey]:void 0});const o=i+JSON.stringify(a);let r=e[o];return r||(r=t(m(i),n),e[o]=r),r(s)}},I=t=>(e,s,i)=>t(m(s),i)(e);class M{constructor(t={}){this.logger=v.create("formatter"),this.options=t,this.init(t)}init(t,e={interpolation:{}}){this.formatSeparator=e.interpolation.formatSeparator||",";const s=e.cacheInBuiltFormats?T:I;this.formats={number:s(((t,e)=>{const s=new Intl.NumberFormat(t,{...e});return t=>s.format(t)})),currency:s(((t,e)=>{const s=new Intl.NumberFormat(t,{...e,style:"currency"});return t=>s.format(t)})),datetime:s(((t,e)=>{const s=new Intl.DateTimeFormat(t,{...e});return t=>s.format(t)})),relativetime:s(((t,e)=>{const s=new Intl.RelativeTimeFormat(t,{...e});return t=>s.format(t,e.range||"day")})),list:s(((t,e)=>{const s=new Intl.ListFormat(t,{...e});return t=>s.format(t)}))}}add(t,e){this.formats[t.toLowerCase().trim()]=e}addCached(t,e){this.formats[t.toLowerCase().trim()]=T(e)}format(t,e,s,i={}){const n=e.split(this.formatSeparator);if(n.length>1&&n[0].indexOf("(")>1&&n[0].indexOf(")")<0&&n.find((t=>t.indexOf(")")>-1))){const t=n.findIndex((t=>t.indexOf(")")>-1));n[0]=[n[0],...n.splice(1,t)].join(this.formatSeparator)}return n.reduce(((t,e)=>{const{formatName:n,formatOptions:a}=(t=>{let e=t.toLowerCase().trim();const s={};if(t.indexOf("(")>-1){const i=t.split("(");e=i[0].toLowerCase().trim();const n=i[1].substring(0,i[1].length-1);"currency"===e&&n.indexOf(":")<0?s.currency||(s.currency=n.trim()):"relativetime"===e&&n.indexOf(":")<0?s.range||(s.range=n.trim()):n.split(";").forEach((t=>{if(t){const[e,...i]=t.split(":"),n=i.join(":").trim().replace(/^'+|'+$/g,""),a=e.trim();s[a]||(s[a]=n),"false"===n&&(s[a]=!1),"true"===n&&(s[a]=!0),isNaN(n)||(s[a]=parseInt(n,10))}}))}return{formatName:e,formatOptions:s}})(e);if(this.formats[n]){let e=t;try{const o=i?.formatParams?.[i.interpolationkey]||{};e=this.formats[n](t,o.locale||o.lng||i.locale||i.lng||s,{...a,...i,...o})}catch(t){this.logger.warn(t)}return e}return this.logger.warn(`there was no format function for ${n}`),t}),t)}}class z extends b{constructor(t,e,s,i={}){super(),this.backend=t,this.store=e,this.services=s,this.languageUtils=s.languageUtils,this.options=i,this.logger=v.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=i.maxParallelReads||10,this.readingCalls=0,this.maxRetries=i.maxRetries>=0?i.maxRetries:5,this.retryTimeout=i.retryTimeout>=1?i.retryTimeout:350,this.state={},this.queue=[],this.backend?.init?.(s,i.backend,i)}queueLoad(t,e,s,i){const n={},a={},o={},r={};return t.forEach((t=>{let i=!0;e.forEach((e=>{const o=`${t}|${e}`;!s.reload&&this.store.hasResourceBundle(t,e)?this.state[o]=2:this.state[o]<0||(1===this.state[o]?void 0===a[o]&&(a[o]=!0):(this.state[o]=1,i=!1,void 0===a[o]&&(a[o]=!0),void 0===n[o]&&(n[o]=!0),void 0===r[e]&&(r[e]=!0)))})),i||(o[t]=!0)})),(Object.keys(n).length||Object.keys(a).length)&&this.queue.push({pending:a,pendingCount:Object.keys(a).length,loaded:{},errors:[],callback:i}),{toLoad:Object.keys(n),pending:Object.keys(a),toLoadLanguages:Object.keys(o),toLoadNamespaces:Object.keys(r)}}loaded(t,e,s){const i=t.split("|"),n=i[0],a=i[1];e&&this.emit("failedLoading",n,a,e),!e&&s&&this.store.addResourceBundle(n,a,s,void 0,void 0,{skipCopy:!0}),this.state[t]=e?-1:2,e&&s&&(this.state[t]=0);const r={};this.queue.forEach((s=>{((t,e,s)=>{const{obj:i,k:n}=o(t,e,Object);i[n]=i[n]||[],i[n].push(s)})(s.loaded,[n],a),((t,e)=>{void 0!==t.pending[e]&&(delete t.pending[e],t.pendingCount--)})(s,t),e&&s.errors.push(e),0!==s.pendingCount||s.done||(Object.keys(s.loaded).forEach((t=>{r[t]||(r[t]={});const e=s.loaded[t];e.length&&e.forEach((e=>{void 0===r[t][e]&&(r[t][e]=!0)}))})),s.done=!0,s.errors.length?s.callback(s.errors):s.callback())})),this.emit("loaded",r),this.queue=this.queue.filter((t=>!t.done))}read(t,e,s,i=0,n=this.retryTimeout,a){if(!t.length)return a(null,{});if(this.readingCalls>=this.maxParallelReads)return void this.waitingReads.push({lng:t,ns:e,fcName:s,tried:i,wait:n,callback:a});this.readingCalls++;const o=(o,r)=>{if(this.readingCalls--,this.waitingReads.length>0){const t=this.waitingReads.shift();this.read(t.lng,t.ns,t.fcName,t.tried,t.wait,t.callback)}o&&r&&i<this.maxRetries?setTimeout((()=>{this.read.call(this,t,e,s,i+1,2*n,a)}),n):a(o,r)},r=this.backend[s].bind(this.backend);if(2!==r.length)return r(t,e,o);try{const s=r(t,e);s&&"function"==typeof s.then?s.then((t=>o(null,t))).catch(o):o(null,s)}catch(t){o(t)}}prepareLoading(e,s,i={},n){if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),n&&n();t(e)&&(e=this.languageUtils.toResolveHierarchy(e)),t(s)&&(s=[s]);const a=this.queueLoad(e,s,i,n);if(!a.toLoad.length)return a.pending.length||n(),null;a.toLoad.forEach((t=>{this.loadOne(t)}))}load(t,e,s){this.prepareLoading(t,e,{},s)}reload(t,e,s){this.prepareLoading(t,e,{reload:!0},s)}loadOne(t,e=""){const s=t.split("|"),i=s[0],n=s[1];this.read(i,n,"read",void 0,void 0,((s,a)=>{s&&this.logger.warn(`${e}loading namespace ${n} for language ${i} failed`,s),!s&&a&&this.logger.log(`${e}loaded namespace ${n} for language ${i}`,a),this.loaded(t,s,a)}))}saveMissing(t,e,s,i,n,a={},o=()=>{}){if(!this.services?.utils?.hasLoadedNamespace||this.services?.utils?.hasLoadedNamespace(e)){if(null!=s&&""!==s){if(this.backend?.create){const r={...a,isUpdate:n},h=this.backend.create.bind(this.backend);if(h.length<6)try{let n;n=5===h.length?h(t,e,s,i,r):h(t,e,s,i),n&&"function"==typeof n.then?n.then((t=>o(null,t))).catch(o):o(null,n)}catch(t){o(t)}else h(t,e,s,i,o,r)}t&&t[0]&&this.store.addResource(t[0],e,s,i)}}else this.logger.warn(`did not save key "${s}" as the namespace "${e}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")}}const V=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let s={};if("object"==typeof e[1]&&(s=e[1]),t(e[1])&&(s.defaultValue=e[1]),t(e[2])&&(s.tDescription=e[2]),"object"==typeof e[2]||"object"==typeof e[3]){const t=e[3]||e[2];Object.keys(t).forEach((e=>{s[e]=t[e]}))}return s},interpolation:{escapeValue:!0,format:t=>t,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),B=e=>(t(e.ns)&&(e.ns=[e.ns]),t(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),t(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs?.indexOf?.("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),"boolean"==typeof e.initImmediate&&(e.initAsync=e.initImmediate),e),F=()=>{};class q extends b{constructor(t={},e){var s;if(super(),this.options=B(t),this.services={},this.logger=v,this.modules={external:[]},s=this,Object.getOwnPropertyNames(Object.getPrototypeOf(s)).forEach((t=>{"function"==typeof s[t]&&(s[t]=s[t].bind(s))})),e&&!this.isInitialized&&!t.isClone){if(!this.options.initAsync)return this.init(t,e),this;setTimeout((()=>{this.init(t,e)}),0)}}init(s={},i){this.isInitializing=!0,"function"==typeof s&&(i=s,s={}),null==s.defaultNS&&s.ns&&(t(s.ns)?s.defaultNS=s.ns:s.ns.indexOf("translation")<0&&(s.defaultNS=s.ns[0]));const n=V();this.options={...n,...this.options,...B(s)},this.options.interpolation={...n.interpolation,...this.options.interpolation},void 0!==s.keySeparator&&(this.options.userDefinedKeySeparator=s.keySeparator),void 0!==s.nsSeparator&&(this.options.userDefinedNsSeparator=s.nsSeparator);const a=t=>t?"function"==typeof t?new t:t:null;if(!this.options.isClone){let t;v.init(this.modules.logger?a(this.modules.logger):null,this.options),t=this.modules.formatter?this.modules.formatter:M;const e=new N(this.options);this.store=new $(this.options.resources,this.options);const s=this.services;s.logger=v,s.resourceStore=this.store,s.languageUtils=e,s.pluralResolver=new P(e,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),this.options.interpolation.format&&this.options.interpolation.format!==n.interpolation.format&&this.logger.deprecate("init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting"),!t||this.options.interpolation.format&&this.options.interpolation.format!==n.interpolation.format||(s.formatter=a(t),s.formatter.init&&s.formatter.init(s,this.options),this.options.interpolation.format=s.formatter.format.bind(s.formatter)),s.interpolator=new E(this.options),s.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},s.backendConnector=new z(a(this.modules.backend),s.resourceStore,s,this.options),s.backendConnector.on("*",((t,...e)=>{this.emit(t,...e)})),this.modules.languageDetector&&(s.languageDetector=a(this.modules.languageDetector),s.languageDetector.init&&s.languageDetector.init(s,this.options.detection,this.options)),this.modules.i18nFormat&&(s.i18nFormat=a(this.modules.i18nFormat),s.i18nFormat.init&&s.i18nFormat.init(this)),this.translator=new O(this.services,this.options),this.translator.on("*",((t,...e)=>{this.emit(t,...e)})),this.modules.external.forEach((t=>{t.init&&t.init(this)}))}if(this.format=this.options.interpolation.format,i||(i=F),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const t=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);t.length>0&&"dev"!==t[0]&&(this.options.lng=t[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach((t=>{this[t]=(...e)=>this.store[t](...e)})),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach((t=>{this[t]=(...e)=>(this.store[t](...e),this)}));const o=e(),r=()=>{const t=(t,e)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),o.resolve(e),i(t,e)};if(this.languages&&!this.isInitialized)return t(null,this.t.bind(this));this.changeLanguage(this.options.lng,t)};return this.options.resources||!this.options.initAsync?r():setTimeout(r,0),o}loadResources(e,s=F){let i=s;const n=t(e)?e:this.language;if("function"==typeof e&&(i=e),!this.options.resources||this.options.partialBundledLanguages){if("cimode"===n?.toLowerCase()&&(!this.options.preload||0===this.options.preload.length))return i();const t=[],e=e=>{e&&"cimode"!==e&&this.services.languageUtils.toResolveHierarchy(e).forEach((e=>{"cimode"!==e&&t.indexOf(e)<0&&t.push(e)}))};n?e(n):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach((t=>e(t))),this.options.preload?.forEach?.((t=>e(t))),this.services.backendConnector.load(t,this.options.ns,(t=>{t||this.resolvedLanguage||!this.language||this.setResolvedLanguage(this.language),i(t)}))}else i(null)}reloadResources(t,s,i){const n=e();return"function"==typeof t&&(i=t,t=void 0),"function"==typeof s&&(i=s,s=void 0),t||(t=this.languages),s||(s=this.options.ns),i||(i=F),this.services.backendConnector.reload(t,s,(t=>{n.resolve(),i(t)})),n}use(t){if(!t)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!t.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===t.type&&(this.modules.backend=t),("logger"===t.type||t.log&&t.warn&&t.error)&&(this.modules.logger=t),"languageDetector"===t.type&&(this.modules.languageDetector=t),"i18nFormat"===t.type&&(this.modules.i18nFormat=t),"postProcessor"===t.type&&w.addPostProcessor(t),"formatter"===t.type&&(this.modules.formatter=t),"3rdParty"===t.type&&this.modules.external.push(t),this}setResolvedLanguage(t){if(t&&this.languages&&!(["cimode","dev"].indexOf(t)>-1)){for(let t=0;t<this.languages.length;t++){const e=this.languages[t];if(!(["cimode","dev"].indexOf(e)>-1)&&this.store.hasLanguageSomeTranslations(e)){this.resolvedLanguage=e;break}}!this.resolvedLanguage&&this.languages.indexOf(t)<0&&this.store.hasLanguageSomeTranslations(t)&&(this.resolvedLanguage=t,this.languages.unshift(t))}}changeLanguage(s,i){this.isLanguageChangingTo=s;const n=e();this.emit("languageChanging",s);const a=t=>{this.language=t,this.languages=this.services.languageUtils.toResolveHierarchy(t),this.resolvedLanguage=void 0,this.setResolvedLanguage(t)},o=(t,e)=>{e?this.isLanguageChangingTo===s&&(a(e),this.translator.changeLanguage(e),this.isLanguageChangingTo=void 0,this.emit("languageChanged",e),this.logger.log("languageChanged",e)):this.isLanguageChangingTo=void 0,n.resolve(((...t)=>this.t(...t))),i&&i(t,((...t)=>this.t(...t)))},r=e=>{s||e||!this.services.languageDetector||(e=[]);const i=t(e)?e:e&&e[0],n=this.store.hasLanguageSomeTranslations(i)?i:this.services.languageUtils.getBestMatchFromCodes(t(e)?[e]:e);n&&(this.language||a(n),this.translator.language||this.translator.changeLanguage(n),this.services.languageDetector?.cacheUserLanguage?.(n)),this.loadResources(n,(t=>{o(t,n)}))};return s||!this.services.languageDetector||this.services.languageDetector.async?!s&&this.services.languageDetector&&this.services.languageDetector.async?0===this.services.languageDetector.detect.length?this.services.languageDetector.detect().then(r):this.services.languageDetector.detect(r):r(s):r(this.services.languageDetector.detect()),n}getFixedT(e,s,i){const n=(t,e,...s)=>{let a;a="object"!=typeof e?this.options.overloadTranslationOptionHandler([t,e].concat(s)):{...e},a.lng=a.lng||n.lng,a.lngs=a.lngs||n.lngs,a.ns=a.ns||n.ns,""!==a.keyPrefix&&(a.keyPrefix=a.keyPrefix||i||n.keyPrefix);const o=this.options.keySeparator||".";let r;return a.keyPrefix&&Array.isArray(t)?r=t.map((t=>("function"==typeof t&&(t=k(t,{...this.options,...e})),`${a.keyPrefix}${o}${t}`))):("function"==typeof t&&(t=k(t,{...this.options,...e})),r=a.keyPrefix?`${a.keyPrefix}${o}${t}`:t),this.t(r,a)};return t(e)?n.lng=e:n.lngs=e,n.ns=s,n.keyPrefix=i,n}t(...t){return this.translator?.translate(...t)}exists(...t){return this.translator?.exists(...t)}setDefaultNamespace(t){this.options.defaultNS=t}hasLoadedNamespace(t,e={}){if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const s=e.lng||this.resolvedLanguage||this.languages[0],i=!!this.options&&this.options.fallbackLng,n=this.languages[this.languages.length-1];if("cimode"===s.toLowerCase())return!0;const a=(t,e)=>{const s=this.services.backendConnector.state[`${t}|${e}`];return-1===s||0===s||2===s};if(e.precheck){const t=e.precheck(this,a);if(void 0!==t)return t}return!(!this.hasResourceBundle(s,t)&&this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages)&&(!a(s,t)||i&&!a(n,t)))}loadNamespaces(s,i){const n=e();return this.options.ns?(t(s)&&(s=[s]),s.forEach((t=>{this.options.ns.indexOf(t)<0&&this.options.ns.push(t)})),this.loadResources((t=>{n.resolve(),i&&i(t)})),n):(i&&i(),Promise.resolve())}loadLanguages(s,i){const n=e();t(s)&&(s=[s]);const a=this.options.preload||[],o=s.filter((t=>a.indexOf(t)<0&&this.services.languageUtils.isSupportedCode(t)));return o.length?(this.options.preload=a.concat(o),this.loadResources((t=>{n.resolve(),i&&i(t)})),n):(i&&i(),Promise.resolve())}dir(t){if(t||(t=this.resolvedLanguage||(this.languages?.length>0?this.languages[0]:this.language)),!t)return"rtl";try{const e=new Intl.Locale(t);if(e&&e.getTextInfo){const t=e.getTextInfo();if(t&&t.direction)return t.direction}}catch(t){}const e=this.services?.languageUtils||new N(V());return t.toLowerCase().indexOf("-latn")>1?"ltr":["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(e.getLanguagePartFromCode(t))>-1||t.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(t={},e){const s=new q(t,e);return s.createInstance=q.createInstance,s}cloneInstance(t={},e=F){const s=t.forkResourceStore;s&&delete t.forkResourceStore;const i={...this.options,...t,isClone:!0},n=new q(i);if(void 0===t.debug&&void 0===t.prefix||(n.logger=n.logger.clone(t)),["store","services","language"].forEach((t=>{n[t]=this[t]})),n.services={...this.services},n.services.utils={hasLoadedNamespace:n.hasLoadedNamespace.bind(n)},s){const t=Object.keys(this.store.data).reduce(((t,e)=>(t[e]={...this.store.data[e]},t[e]=Object.keys(t[e]).reduce(((s,i)=>(s[i]={...t[e][i]},s)),t[e]),t)),{});n.store=new $(t,i),n.services.resourceStore=n.store}return n.translator=new O(n.services,i),n.translator.on("*",((t,...e)=>{n.emit(t,...e)})),n.init(i,e),n.translator.options=i,n.translator.backendConnector.services.utils={hasLoadedNamespace:n.hasLoadedNamespace.bind(n)},n}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const K=q.createInstance(),D=K.t;K.init({resources:{en:{translation:{chat_tab:{chat:"Chat",chats_are_not_connected:"Chats are not connected",choose_page_you_want_to_connect:"Choose page you want to connect",add_channel_connection:"Add channel connection",add_connection:"Add connection",integrated_account:"Integrated accounts.",integrated_account_desc:"Manage your account.",search_chat:"Search chat",custom_filter:"Custom filter.",create_custom_filter:"Create custom filter.",advance_search:"Advanced search.",please_choose_chat_to_reply:"Please choose chat to reply.",no_user_found:"User cannot be found",all_chat:"All chat",already_read:"Read",unread:"Unread",filter_search_fields:"Name, nickname, email, phone number or message",read_status:"Reading status",last_reply:"Last reply",you_not_connect_chat:"You have not yet connected the chat.",see_original:"See original",see_translated:"See translated",see_send_text:"See sent",hide:"Hide",see_all_text:"See all",reply:"Reply",replied_to:"replied to",yourself:"Yourself",summary:"AI Summary",reply_token_info:"You have a free message quota of {total} messages within {remaining} minutes.",syncing_tag:"Retrieving the tag please wait a moment.",syncing_message:"Retrieving the chat please wait a moment.",advanced_search:"Advanced Search",add_custom_filter:"Add a custom filter",edit_custom_filter:"Edit custom filter"},quick_message:{title:"Quick message",app_title:"Quick message library",app_description:"Manage templates, images, and files for your team in one place.",tab_template:"Template",search_template:"Search message",add_template:"Add new template",template_name:"Template name",template_name_required:"Template name is required",template_name_warning:"Please specify a template name",template_counter:"Quick replies {count}/{max}",template_empty:"No templates available",updated_at:"{date} edit by {by}",edit_before_send:"Edit before send",send_now:"Send now",search_image:"Search image",image_empty:"No images available",display_list:"Switch to list view",display_grid:"Switch to grid view",send_images:"Send images",search_file:"Search file",file_empty:"No files available",send_files:"Send files",add_file:"Add file",created_at:"Created {date}",message:"Message",button:"Button",menu_list:"Menu list",add_button:"Add button",add_image:"Add image",change_image:"Change image",add_video:"Add video",change_video_link:"Change video link",link_video:"Video link",type_description_here:"Type description here",type_title_here:"Type title here",button_label:"Button text",button_action:"Action",button_label_placeholder:"Type button name",button_action_text:"Text",button_action_url:"Link",button_action_tel:"Phone number",button_action_url_placeholder:"https://www.example.com",button_action_tel_placeholder:"Ex. +66812345678",button_action_required:"Please fill out this field",button_action_url_invalid:"Link is invalid",button_action_tel_invalid:"Phone number is invalid",image_size_hint:"Supports files up to 10MB",image_too_large:"File is larger than 10MB",video_link_required:"Please provide a video link",video_link_invalid:"Video link is invalid",type_video_link_here:"Paste the video link here",count_template_content:"Reply",edit_button:"Edit button",move_up:"Move up",move_down:"Move down",move_left:"Move left",move_right:"Move right",delete_template_title:"Are you sure you want to delete this template?",delete_selected_items_confirmation:"Are you sure you want to delete the selected items?",delete_item_confirmation:"Are you sure you want to delete this item?",uploading:"Uploading...",rename_item:"Rename",name:"Name",edit_template:"Edit the template"},selected:"Selected",new:"new",enter_create:"Enter to create",used:"Used",select_all:"Select all",edit:"Edit",cancel:"Cancel",save:"Save",reset:"Reset",search:"Search",channel:"Channel",status:"Status",search_data:"Search",you:"You",image:"Image",video:"Video",file:"File",sent:"sent",today:"Today",translate:"Translate",profile_tab:{profile_this_chat:"Profile this chat",merged_profile:"Merged profile",add_tag:"Add tag",tag_empty:"No tag",compare_user:"Analyze user profiles.",compare_user_info:"Upon initial user merge, the system creates a Zignal Profile for this user.",ai_summary:"AI Summary",prob:"possibility",same_user:"to be the same person.",merge_user:"Merge user",compare_table:"Comparison table",match_user:"This user could be the same person.",view_data:"View",related_user:"Related users",history_info:"History for the last 30 days",no_activity_log:"No activities",go_to_message:"Go to the message",activity_action:"{action} {type}",last_update:"Last update"},tag:"Tag",no:"No",email:"Email",phone_no:"Phone No.",address:"Address",gender:"Gender",unread:"Unread",more:"More",inbox:"Inbox",spam:"Spam",info:"Info",file_and_image:"Files and Images",history:"History",about:"About",locale:"Locale",register_date:"Register Date",last_active_date:"Last Active",note:"Note",name:"Name",remove:"Remove",change:"Change",add:"Add",ok:"OK",error:"Error",send:"Send",confirm:"Confirm",delete:"delete",close:"Close",clear:"Clear",please_input:"Please input",not_found:"Not found",province:"Province",district:"District",sub_district:"Sub District",zip_code:"Zip Code",create:"Create",event:"Event",amount:"Amount",currency:"Currency",chat_filter:{admin:"Admin",chat_bot:"Chatbot",group:"Group",reset:"Reset",all:"All",friend:"Friend",type:"Type",type_for_line_oa:"For Line OA channel",search_result:"Search results",add_custom_filter:"Add a filter",filter_name:"Filter name",confirm_delete_filter:"Are you sure you want to delete this filter?",custom_filter:"Custom filter",select_filter_to_search:"Select a filter to search.",no_filter:"No filter",verify_slip:"Verify slip",verify_slip_more_than:"Verify slip more than",only_customer_zrmz:"Select only ZRMZ customers",shop_name:"Shop name",name:"Name",total_point:"Total points",remaining_point:"Remaining points",only_customer_zerva:"Select only Zerva customers",booking_no:"Booking number",service_date:"Date of service",end_date:"End date",start_date:"Start date",booking_status:"Booking status",payment_status:"Payment status",quantity:"quantity",times:"times"},sticker:"Sticker",audio:"Audio",location:"Location",text:"Text",template:"Template",ig_reel:"Reel",story_mention:"Story mention",share:"Share",type_message_here:"Type your message here",you_have_new_message:"You have new message",go_to_last_message:"Go to last message"}},th:{translation:{chat_tab:{chat:"แชท",chats_are_not_connected:"คุณยังไม่ได้เชื่อมต่อรวมแขท",choose_page_you_want_to_connect:"เลือกเพจที่ต้องการเชื่อมต่อ",add_channel_connection:"เพิ่มช่องทางเชื่อมต่อ",add_connection:"เพิ่มการเชื่อมต่อ",integrated_account:"บัญชีรวมแชทที่เชื่อมต่อ",integrated_account_desc:"จัดการบัญชีที่เชื่อมต่อของคุณ",search_chat:"ค้นหาแชท",custom_filter:"กรองข้อมูลแบบกำหนดเอง",create_custom_filter:"สร้างตัวกรองข้อมูลแบบกำหนดเอง",advance_search:"ค้นหาขั้นสูง",please_choose_chat_to_reply:"กรุณาเลือกผู้ใช้ที่ต้องการตอบกลับ",no_user_found:"ไม่พบผู้ใช้",all_chat:"แชททั้งหมด",already_read:"อ่านแล้ว",unread:"ยังไม่ได้อ่าน",filter_search_fields:"ชื่อ, ชื่อเล่น, อีเมล, เบอร์โทร หรือ ข้อความ",read_status:"สถานะการอ่าน",last_reply:"ตอบกลับล่าสุด",you_not_connect_chat:"คุณยังไม่ได้เชื่อมรวมแชท",see_original:"ดูข้อความต้นฉบับ",see_translated:"ดูข้อความที่แปลแล้ว",see_send_text:"ดูข้อความที่ส่งไป",hide:"ย่อ",see_all_text:"ดูข้อความทั้งหมด",reply:"ตอบกลับ",replied_to:"ได้ตอบกลับ",yourself:"ตัวคุณเอง",summary:"AI สรุปข้อความ",reply_token_info:"คุณมีโควต้าส่งข้อความฟรี {total} ข้อความ ภายใน {remaining} นาที",syncing_message:"กำลังดึงประวัติแชท กรุณารอสักครู่",syncing_tag:"กำลังดึงป้ายกำกับ กรุณารอสักครู่",advanced_search:"ค้นหาขั้นสูง",add_custom_filter:"เพิ่มตัวกรองกำหนดเอง",edit_custom_filter:"แก้ไขตัวกรองกำหนดเอง"},quick_message:{title:"เทมเพลตคำตอบ",app_title:"คลังเทมเพลต",app_description:"จัดการเทมเพลต รูปภาพ และไฟล์สำหรับทีมของคุณในที่เดียว",tab_template:"เทมเพลตคำตอบ",search_template:"ค้นหาข้อความ",add_template:"เพิ่มข้อความตอบกลับ",template_name:"ชื่อเทมเพลตข้อความ",template_name_required:"กรุณาระบุชื่อเทมเพลตข้อความ",template_name_warning:"โปรดระบุชื่อเทมเพลต",template_counter:"ข้อความตอบกลับ {count}/{max}",template_empty:"ยังไม่มีเทมเพลตคำตอบ",updated_at:"{date} แก้ไขโดย {by}",edit_before_send:"แก้ไขก่อนส่ง",send_now:"ส่งเลย",search_image:"ค้นหารูปภาพ",image_empty:"ยังไม่มีรูปภาพ",display_list:"เปลี่ยนเป็นแบบรายการ",display_grid:"เปลี่ยนเป็นแบบกริด",send_images:"ส่งรูปภาพ",search_file:"ค้นหาไฟล์",file_empty:"ยังไม่มีไฟล์",send_files:"ส่งไฟล์",add_file:"เพิ่มไฟล์",created_at:"สร้างเมื่อ {date}",message:"ข้อความ",button:"ปุ่มกด",menu_list:"เมนูลิสต์",add_button:"เพิ่มปุ่มกด",add_image:"เพิ่มรูปภาพ",change_image:"เปลี่ยนรูปภาพ",add_video:"เพิ่มวิดิโอ",change_video_link:"เปลี่ยนลิงก์วิดีโอ",link_video:"ลิงก์วิดิโอ",type_video_link_here:"วางลิงก์วิดีโอที่นี่",type_description_here:"พิมพ์รายละเอียดที่นี่",type_title_here:"พิมพ์หัวข้อที่นี่",button_label:"ข้อความปุ่ม",button_action:"การทำงาน",button_label_placeholder:"พิมพ์ชื่อปุ่ม",button_action_text:"ข้อความ",button_action_url:"ลิงก์",button_action_tel:"เบอร์โทรศัพท์",button_action_url_placeholder:"https://www.example.com",button_action_tel_placeholder:"ตัวอย่าง +66812345678",button_action_required:"กรุณากรอกข้อมูลนี้",button_action_url_invalid:"ลิงก์ไม่ถูกต้อง",button_action_tel_invalid:"เบอร์โทรศัพท์ไม่ถูกต้อง",image_size_hint:"รองรับไฟล์สูงสุด : 10MB",image_too_large:"ไฟล์มีขนาดเกิน 10MB",video_link_required:"กรุณาระบุลิงก์วิดีโอ",video_link_invalid:"ลิงก์วิดีโอไม่ถูกต้อง",count_template_content:"ข้อความตอบกลับ",edit_button:"แก้ไขปุ่มกด",move_up:"ย้ายขึ้น",move_down:"ย้ายลง",move_left:"ย้ายซ้าย",move_right:"ย้ายขวา",delete_template_title:"คุณต้องการลบข้อความตอบกลับนี้หรือไม่?",delete_selected_items_confirmation:"คุณต้องการลบรายการที่เลือกหรือไม่?",delete_item_confirmation:"คุณต้องการลบรายการนี้หรือไม่?",uploading:"กำลังอัปโหลด...",rename_item:"เปลี่ยนชื่อ",name:"ชื่อ",edit_template:"แก้ไขข้อความตอบกลับ"},selected:"เลือกแล้ว",new:"ใหม่",enter_create:"Enter เพื่อสร้าง",used:"มีแล้ว",select_all:"เลือกทั้งหมด",edit:"แก้ไข",cancel:"ยกเลิก",save:"บันทึก",reset:"ตั้งค่าใหม่",search:"ค้นหา",channel:"ช่องทาง",status:"สถานะ",search_data:"ค้นหาข้อมูล",you:"คุณ",image:"รูปภาพ",video:"วิดีโอ",file:"ไฟล์",sent:"ส่ง",today:"วันนี้",translate:"แปลภาษา",profile_tab:{profile_this_chat:"ข้อมูลโปรไฟล์แชทนี้",merged_profile:"ข้อมูลโปรไฟล์รวม",add_tag:"เพิ่มป้ายกำกับ",tag_empty:"ไม่มีป้ายกำกับ",compare_user:"เปรียบเทียบข้อมูลผู้ใช้",compare_user_info:"กรณีรวม user ในครั้งแรก ระบบสร้าง Profile Zignal ให้กับลูกค้าท่านนี้",ai_summary:"สรุปจาก AI",prob:"มีความเป็นไปได้",same_user:"ที่จะเป็นคนเดียวกัน",merge_user:"รวม User",compare_table:"ตารางเปรียบเทียบ",match_user:"ผู้ใช้รายนี้อาจเป็นคนเดียวกัน",view_data:"ดูข้อมูล",related_user:"ผู้ใช้ที่เกี่ยวข้องกัน",history_info:"ประวัติย้อนหลังสูงสุด 30 วัน",no_activity_log:"ไม่พบกิจกรรม",go_to_message:"ไปที่ข้อความ",activity_action:"{action}{type}",last_update:"อัปเดทล่าสุด"},tag:"ป้ายกำกับ",no:"ไม่ใช่",email:"อีเมล",phone_no:"เบอร์โทร",address:"ที่อยู่",gender:"เพศ",file_and_image:"ไฟล์&รูปภาพ",history:"ประวัติ",unread:"ยังไม่อ่าน",more:"ดูเพิ่ม",inbox:"อินบ็อกซ์",spam:"สแปม",info:"ข้อมูล",about:"เกี่ยวกับ",locale:"ภาษา",register_date:"วันที่สมัคร",last_active_date:"ตอบกลับล่าสุด",note:"หมายเหตุ",name:"ชื่อ",remove:"ลบ",change:"แก้ไข",add:"เพิ่ม",ok:"ตกลง",error:"เกิดข้อผิดพลาด",send:"ส่ง",confirm:"ยืนยัน",delete:"ลบ",close:"ปิด",clear:"ล้าง",please_input:"กรุณาระบุ",not_found:"ไม่พบ",province:"จังหวัด",district:"เขต/อำเภอ",sub_district:"แขวง/ตำบล",zip_code:"รหัสไปรษณีย์",create:"สร้าง",event:"อีเวนท์",amount:"จำนวนเงิน",currency:"หน่วยเงิน",chat_filter:{admin:"แอดมิน",chat_bot:"แชทบอท",group:"กลุ่ม",reset:"ล้าง",all:"ทั้งหมด",friend:"เพื่อน",type:"รูปแบบ",type_for_line_oa:"สำหรับช่องทาง Line OA",search_result:"ผลลัพธ์การค้นหา",add_custom_filter:"เพิ่มตัวกรอง",filter_name:"ชื่อตัวกรอง",confirm_delete_filter:"คุณแน่ใจว่าต้องการลบตัวกรองนี้หรือไม่?",custom_filter:"ตัวกรองกำหนดเอง",select_filter_to_search:"เลือกตัวกรองเพื่อค้นหา",no_filter:"ไม่มีตัวกรอง",verify_slip:"ตรวจสลิป",verify_slip_more_than:"ตรวจสลิปมากกว่า",only_customer_zrmz:"เลือกเฉพาะลูกค้า ZRMZ",shop_name:"ชื่อร้านค้า",name:"ชื่อ - นามสกุล",total_point:"คะแนนทั้งหมด",remaining_point:"คะแนนคงเหลือ",only_customer_zerva:"เลือกเฉพาะลูกค้า Zerva",booking_no:"เลขที่การจอง",service_date:"วันที่เข้ารับบริการ",end_date:"วันที่สิ้นสุด",start_date:"วันที่เริ่มต้น",booking_status:"สถานะการจอง",payment_status:"สถานะการชำระเงิน",quantity:"จำนวน",times:"ครั้ง"},sticker:"สติ๊กเกอร์",audio:"เสียง",location:"สถานที่",text:"ข้อความ",template:"เทมเพลต",ig_reel:"รีล",story_mention:"การกล่าวถึง",share:"แบ่งปัน",type_message_here:"พิมพ์ข้อความที่นี่",you_have_new_message:"คุณมีข้อความใหม่",go_to_last_message:"ไปที่ข้อความล่าสุด"}}},fallbackLng:"en",interpolation:{escapeValue:!1}});export{K as i,D as t}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as t}from"./p-B3nb31xy.js";import{g as n,f as r}from"./p-NR-FjQmT.js";function e(){return t.t}const i=(t,n=!1)=>{let r="#000";const e=t.includes("rgb")?"rgb":"hex";"hex"===e?r=t:"rgb"===e&&(r="#"+(t.match(/\d+/g)||[]).map((t=>{const n=parseInt(t,10).toString(16);return 1===n.length?"0"+n:n})).join(""));const i=(t=>.299*parseInt(t.substring(1,3),16)+.587*parseInt(t.substring(3,5),16)+.114*parseInt(t.substring(5,7),16))(r);return n?i>128?"#fff":"#000":i>128?"#000":"#fff"};function s(t){const n=new DataTransfer;return t.forEach(((t,r)=>{const e=t.split(","),i=e[0].match(/:(.*?);/),s=i?i[1]:"image/png",u=atob(e[1]);let a=u.length;const o=new Uint8Array(a);for(;a--;)o[a]=u.charCodeAt(a);const h=new File([o],`image${r}.png`,{type:s});n.items.add(h)})),n.files}const u=t=>(["e","E","+","-","ArrowDown"].includes(t.key)||"ArrowDown"===t.key&&(0===parseInt(t.target.value)||""===t.target.value))&&t.preventDefault(),a=t=>!("isConnected"in t)||t.isConnected,o=(()=>{let t;return(...n)=>{t&&clearTimeout(t),t=setTimeout((()=>{t=0,(t=>{for(let n of t.keys())t.set(n,t.get(n).filter(a))})(...n)}),2e3)}})(),h=t=>"function"==typeof t?t():t,c=(t,n)=>{const r=t.indexOf(n);r>=0&&(t[r]=t[t.length-1],t.length--)},f=(t,e)=>{const i=((t,n=(t,n)=>t!==n)=>{const r=h(t);let e=new Map(Object.entries(r??{}));const i={dispose:[],get:[],set:[],reset:[]},s=new Map,u=()=>{e=new Map(Object.entries(h(t)??{})),i.reset.forEach((t=>t()))},a=t=>(i.get.forEach((n=>n(t))),e.get(t)),o=(t,r)=>{const s=e.get(t);n(r,s,t)&&(e.set(t,r),i.set.forEach((n=>n(t,r,s))))},f="undefined"==typeof Proxy?{}:new Proxy(r,{get:(t,n)=>a(n),ownKeys:()=>Array.from(e.keys()),getOwnPropertyDescriptor:()=>({enumerable:!0,configurable:!0}),has:(t,n)=>e.has(n),set:(t,n,r)=>(o(n,r),!0)}),d=(t,n)=>(i[t].push(n),()=>{c(i[t],n)});return{state:f,get:a,set:o,on:d,onChange:(n,r)=>{const e=(t,e)=>{t===n&&r(e)},i=()=>r(h(t)[n]),u=d("set",e),a=d("reset",i);return s.set(r,{setHandler:e,resetHandler:i,propName:n}),()=>{u(),a(),s.delete(r)}},use:(...t)=>{const n=t.reduce(((t,n)=>(n.set&&t.push(d("set",n.set)),n.get&&t.push(d("get",n.get)),n.reset&&t.push(d("reset",n.reset)),n.dispose&&t.push(d("dispose",n.dispose)),t)),[]);return()=>n.forEach((t=>t()))},dispose:()=>{i.dispose.forEach((t=>t())),u()},reset:u,forceUpdate:t=>{const n=e.get(t);i.set.forEach((r=>r(t,n,n)))},removeListener:(t,n)=>{const r=s.get(n);r&&r.propName===t&&(c(i.set,r.setHandler),c(i.reset,r.resetHandler),s.delete(n))}}})(t,e);return i.use((()=>{if("function"!=typeof n)return{};const t=new Map;return{dispose:()=>t.clear(),get:r=>{const e=n();e&&((t,n,r)=>{const e=t.get(n);e?e.includes(r)||e.push(r):t.set(n,[r])})(t,r,e)},set:n=>{const e=t.get(n);e&&t.set(n,e.filter(r)),o(t)},reset:()=>{t.forEach((t=>t.forEach(r))),o(t)}}})()),i},d=f({language:"en",theme:"light",businessId:null,shopId:null,accessToken:null,isProduction:!1,timeZone:null,translationSettings:{is_auto:!1,target_language:null,exclude_languages:[]},isNotConnected:!1,connectionList:[],memberList:[]}),l=f({messages:[],reads:[],loadedKeys:new Set,readsMap:{}}),m=f({filterType:"quick"}),v=f({statuses:[]}),M=f({tags:[]}),Y=f({chats:[],loadedKeys:new Set}),_=f({user:null}),g=f({userAddress:null}),y=f({selectedChat:null,isSyncingTag:!1,isSyncingMessage:!1}),D=f({selectedMessageToReply:null}),p=f({isMobile:!1}),w=f({isShow:!1}),S=f({filters:[],selectedFilter:null,loading:!1});var b="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function H(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var T,k={exports:{}};function $(){return T||(T=1,k.exports=function(){var t=6e4,n=36e5,r="millisecond",e="second",i="minute",s="hour",u="day",a="week",o="month",h="quarter",c="year",f="date",d="Invalid Date",l=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,m=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,v={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var n=["th","st","nd","rd"],r=t%100;return"["+t+(n[(r-20)%10]||n[r]||n[0])+"]"}},M=function(t,n,r){var e=String(t);return!e||e.length>=n?t:""+Array(n+1-e.length).join(r)+t},Y={s:M,z:function(t){var n=-t.utcOffset(),r=Math.abs(n),e=Math.floor(r/60),i=r%60;return(n<=0?"+":"-")+M(e,2,"0")+":"+M(i,2,"0")},m:function t(n,r){if(n.date()<r.date())return-t(r,n);var e=12*(r.year()-n.year())+(r.month()-n.month()),i=n.clone().add(e,o),s=r-i<0,u=n.clone().add(e+(s?-1:1),o);return+(-(e+(r-i)/(s?i-u:u-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:o,y:c,w:a,d:u,D:f,h:s,m:i,s:e,ms:r,Q:h}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},_="en",g={};g[_]=v;var y="$isDayjsObject",D=function(t){return t instanceof b||!(!t||!t[y])},p=function t(n,r,e){var i;if(!n)return _;if("string"==typeof n){var s=n.toLowerCase();g[s]&&(i=s),r&&(g[s]=r,i=s);var u=n.split("-");if(!i&&u.length>1)return t(u[0])}else{var a=n.name;g[a]=n,i=a}return!e&&i&&(_=i),i||!e&&_},w=function(t,n){if(D(t))return t.clone();var r="object"==typeof n?n:{};return r.date=t,r.args=arguments,new b(r)},S=Y;S.l=p,S.i=D,S.w=function(t,n){return w(t,{locale:n.$L,utc:n.$u,x:n.$x,$offset:n.$offset})};var b=function(){function v(t){this.$L=p(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[y]=!0}var M=v.prototype;return M.parse=function(t){this.$d=function(t){var n=t.date,r=t.utc;if(null===n)return new Date(NaN);if(S.u(n))return new Date;if(n instanceof Date)return new Date(n);if("string"==typeof n&&!/Z$/i.test(n)){var e=n.match(l);if(e){var i=e[2]-1||0,s=(e[7]||"0").substring(0,3);return r?new Date(Date.UTC(e[1],i,e[3]||1,e[4]||0,e[5]||0,e[6]||0,s)):new Date(e[1],i,e[3]||1,e[4]||0,e[5]||0,e[6]||0,s)}}return new Date(n)}(t),this.init()},M.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},M.$utils=function(){return S},M.isValid=function(){return!(this.$d.toString()===d)},M.isSame=function(t,n){var r=w(t);return this.startOf(n)<=r&&r<=this.endOf(n)},M.isAfter=function(t,n){return w(t)<this.startOf(n)},M.isBefore=function(t,n){return this.endOf(n)<w(t)},M.$g=function(t,n,r){return S.u(t)?this[n]:this.set(r,t)},M.unix=function(){return Math.floor(this.valueOf()/1e3)},M.valueOf=function(){return this.$d.getTime()},M.startOf=function(t,n){var r=this,h=!!S.u(n)||n,d=S.p(t),l=function(t,n){var e=S.w(r.$u?Date.UTC(r.$y,n,t):new Date(r.$y,n,t),r);return h?e:e.endOf(u)},m=function(t,n){return S.w(r.toDate()[t].apply(r.toDate("s"),(h?[0,0,0,0]:[23,59,59,999]).slice(n)),r)},v=this.$W,M=this.$M,Y=this.$D,_="set"+(this.$u?"UTC":"");switch(d){case c:return h?l(1,0):l(31,11);case o:return h?l(1,M):l(0,M+1);case a:var g=this.$locale().weekStart||0,y=(v<g?v+7:v)-g;return l(h?Y-y:Y+(6-y),M);case u:case f:return m(_+"Hours",0);case s:return m(_+"Minutes",1);case i:return m(_+"Seconds",2);case e:return m(_+"Milliseconds",3);default:return this.clone()}},M.endOf=function(t){return this.startOf(t,!1)},M.$set=function(t,n){var a,h=S.p(t),d="set"+(this.$u?"UTC":""),l=(a={},a[u]=d+"Date",a[f]=d+"Date",a[o]=d+"Month",a[c]=d+"FullYear",a[s]=d+"Hours",a[i]=d+"Minutes",a[e]=d+"Seconds",a[r]=d+"Milliseconds",a)[h],m=h===u?this.$D+(n-this.$W):n;if(h===o||h===c){var v=this.clone().set(f,1);v.$d[l](m),v.init(),this.$d=v.set(f,Math.min(this.$D,v.daysInMonth())).$d}else l&&this.$d[l](m);return this.init(),this},M.set=function(t,n){return this.clone().$set(t,n)},M.get=function(t){return this[S.p(t)]()},M.add=function(r,h){var f,d=this;r=Number(r);var l=S.p(h),m=function(t){var n=w(d);return S.w(n.date(n.date()+Math.round(t*r)),d)};if(l===o)return this.set(o,this.$M+r);if(l===c)return this.set(c,this.$y+r);if(l===u)return m(1);if(l===a)return m(7);var v=(f={},f[i]=t,f[s]=n,f[e]=1e3,f)[l]||1,M=this.$d.getTime()+r*v;return S.w(M,this)},M.subtract=function(t,n){return this.add(-1*t,n)},M.format=function(t){var n=this,r=this.$locale();if(!this.isValid())return r.invalidDate||d;var e=t||"YYYY-MM-DDTHH:mm:ssZ",i=S.z(this),s=this.$H,u=this.$m,a=this.$M,o=r.weekdays,h=r.months,c=function(t,r,i,s){return t&&(t[r]||t(n,e))||i[r].slice(0,s)},f=function(t){return S.s(s%12||12,t,"0")},l=r.meridiem||function(t,n,r){var e=t<12?"AM":"PM";return r?e.toLowerCase():e};return e.replace(m,(function(t,e){return e||function(t){switch(t){case"YY":return String(n.$y).slice(-2);case"YYYY":return S.s(n.$y,4,"0");case"M":return a+1;case"MM":return S.s(a+1,2,"0");case"MMM":return c(r.monthsShort,a,h,3);case"MMMM":return c(h,a);case"D":return n.$D;case"DD":return S.s(n.$D,2,"0");case"d":return String(n.$W);case"dd":return c(r.weekdaysMin,n.$W,o,2);case"ddd":return c(r.weekdaysShort,n.$W,o,3);case"dddd":return o[n.$W];case"H":return String(s);case"HH":return S.s(s,2,"0");case"h":return f(1);case"hh":return f(2);case"a":return l(s,u,!0);case"A":return l(s,u,!1);case"m":return String(u);case"mm":return S.s(u,2,"0");case"s":return String(n.$s);case"ss":return S.s(n.$s,2,"0");case"SSS":return S.s(n.$ms,3,"0");case"Z":return i}return null}(t)||i.replace(":","")}))},M.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},M.diff=function(r,f,d){var l,m=this,v=S.p(f),M=w(r),Y=(M.utcOffset()-this.utcOffset())*t,_=this-M,g=function(){return S.m(m,M)};switch(v){case c:l=g()/12;break;case o:l=g();break;case h:l=g()/3;break;case a:l=(_-Y)/6048e5;break;case u:l=(_-Y)/864e5;break;case s:l=_/n;break;case i:l=_/t;break;case e:l=_/1e3;break;default:l=_}return d?l:S.a(l)},M.daysInMonth=function(){return this.endOf(o).$D},M.$locale=function(){return g[this.$L]},M.locale=function(t,n){if(!t)return this.$L;var r=this.clone(),e=p(t,n,!0);return e&&(r.$L=e),r},M.clone=function(){return S.w(this.$d,this)},M.toDate=function(){return new Date(this.valueOf())},M.toJSON=function(){return this.isValid()?this.toISOString():null},M.toISOString=function(){return this.$d.toISOString()},M.toString=function(){return this.$d.toUTCString()},v}(),H=b.prototype;return w.prototype=H,[["$ms",r],["$s",e],["$m",i],["$H",s],["$W",u],["$M",o],["$y",c],["$D",f]].forEach((function(t){H[t[1]]=function(n){return this.$g(n,t[0],t[1])}})),w.extend=function(t,n){return t.$i||(t(n,b,w),t.$i=!0),w},w.locale=p,w.isDayjs=D,w.unix=function(t){return w(1e3*t)},w.en=g[_],w.Ls=g,w.p={},w}()),k.exports}var L,j,x,A,I,N,Z,P,O=H($()),C={exports:{}},F=H((L||(L=1,C.exports=(j="minute",x=/[+-]\d\d(?::?\d\d)?/g,A=/([+-]|\d\d)/g,function(t,n,r){var e=n.prototype;r.utc=function(t){return new n({date:t,utc:!0,args:arguments})},e.utc=function(t){var n=r(this.toDate(),{locale:this.$L,utc:!0});return t?n.add(this.utcOffset(),j):n},e.local=function(){return r(this.toDate(),{locale:this.$L,utc:!1})};var i=e.parse;e.parse=function(t){t.utc&&(this.$u=!0),this.$utils().u(t.$offset)||(this.$offset=t.$offset),i.call(this,t)};var s=e.init;e.init=function(){if(this.$u){var t=this.$d;this.$y=t.getUTCFullYear(),this.$M=t.getUTCMonth(),this.$D=t.getUTCDate(),this.$W=t.getUTCDay(),this.$H=t.getUTCHours(),this.$m=t.getUTCMinutes(),this.$s=t.getUTCSeconds(),this.$ms=t.getUTCMilliseconds()}else s.call(this)};var u=e.utcOffset;e.utcOffset=function(t,n){var r=this.$utils().u;if(r(t))return this.$u?0:r(this.$offset)?u.call(this):this.$offset;if("string"==typeof t&&(t=function(t){void 0===t&&(t="");var n=t.match(x);if(!n)return null;var r=(""+n[0]).match(A)||["-",0,0],e=60*+r[1]+ +r[2];return 0===e?0:"+"===r[0]?e:-e}(t),null===t))return this;var e=Math.abs(t)<=16?60*t:t;if(0===e)return this.utc(n);var i=this.clone();if(n)return i.$offset=e,i.$u=!1,i;var s=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();return(i=this.local().add(e+s,j)).$offset=e,i.$x.$localOffset=s,i};var a=e.format;e.format=function(t){return a.call(this,t||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":""))},e.valueOf=function(){var t=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*t},e.isUTC=function(){return!!this.$u},e.toISOString=function(){return this.toDate().toISOString()},e.toString=function(){return this.toDate().toUTCString()};var o=e.toDate;e.toDate=function(t){return"s"===t&&this.$offset?r(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():o.call(this)};var h=e.diff;e.diff=function(t,n,e){if(t&&this.$u===t.$u)return h.call(this,t,n,e);var i=this.local(),s=r(t).local();return h.call(i,s,n,e)}})),C.exports)),U={exports:{}},q=(I||(I=1,U.exports=function(){var t={year:0,month:1,day:2,hour:3,minute:4,second:5},n={};return function(r,e,i){var s,u=function(t,r,e){void 0===e&&(e={});var i=new Date(t),s=function(t,r){void 0===r&&(r={});var e=r.timeZoneName||"short",i=t+"|"+e,s=n[i];return s||(s=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:e}),n[i]=s),s}(r,e);return s.formatToParts(i)},a=function(n,r){for(var e=u(n,r),s=[],a=0;a<e.length;a+=1){var o=e[a],h=t[o.type];h>=0&&(s[h]=parseInt(o.value,10))}var c=s[3],f=+n;return(i.utc(s[0]+"-"+s[1]+"-"+s[2]+" "+(24===c?0:c)+":"+s[4]+":"+s[5]+":000").valueOf()-(f-=f%1e3))/6e4},o=e.prototype;o.tz=function(t,n){void 0===t&&(t=s);var r,e=this.utcOffset(),u=this.toDate(),a=u.toLocaleString("en-US",{timeZone:t}),o=Math.round((u-new Date(a))/1e3/60),h=15*-Math.round(u.getTimezoneOffset()/15)-o;if(Number(h)){if(r=i(a,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(h,!0),n){var c=r.utcOffset();r=r.add(e-c,"minute")}}else r=this.utcOffset(0,n);return r.$x.$timezone=t,r},o.offsetName=function(t){var n=this.$x.$timezone||i.tz.guess(),r=u(this.valueOf(),n,{timeZoneName:t}).find((function(t){return"timezonename"===t.type.toLowerCase()}));return r&&r.value};var h=o.startOf;o.startOf=function(t,n){if(!this.$x||!this.$x.$timezone)return h.call(this,t,n);var r=i(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return h.call(r,t,n).tz(this.$x.$timezone,!0)},i.tz=function(t,n,r){var e=r&&n,u=r||n||s,o=a(+i(),u);if("string"!=typeof t)return i(t).tz(u);var h=function(t,n,r){var e=t-60*n*1e3,i=a(e,r);if(n===i)return[e,n];var s=a(e-=60*(i-n)*1e3,r);return i===s?[e,i]:[t-60*Math.min(i,s)*1e3,Math.max(i,s)]}(i.utc(t,e).valueOf(),o,u),c=h[1],f=i(h[0]).utcOffset(c);return f.$x.$timezone=u,f},i.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},i.tz.setDefault=function(t){s=t}}}()),U.exports),z=H(q),J={exports:{}},K=(N||(N=1,J.exports=function(){var t,n,r=1e3,e=6e4,i=36e5,s=864e5,u=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,a=31536e6,o=2628e6,h=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,c={years:a,months:o,days:s,hours:i,minutes:e,seconds:r,milliseconds:1,weeks:6048e5},f=function(t){return t instanceof _},d=function(t,n,r){return new _(t,r,n.$l)},l=function(t){return n.p(t)+"s"},m=function(t){return t<0},v=function(t){return m(t)?Math.ceil(t):Math.floor(t)},M=function(t){return Math.abs(t)},Y=function(t,n){return t?m(t)?{negative:!0,format:""+M(t)+n}:{negative:!1,format:""+t+n}:{negative:!1,format:""}},_=function(){function m(t,n,r){var e=this;if(this.$d={},this.$l=r,void 0===t&&(this.$ms=0,this.parseFromMilliseconds()),n)return d(t*c[l(n)],this);if("number"==typeof t)return this.$ms=t,this.parseFromMilliseconds(),this;if("object"==typeof t)return Object.keys(t).forEach((function(n){e.$d[l(n)]=t[n]})),this.calMilliseconds(),this;if("string"==typeof t){var i=t.match(h);if(i){var s=i.slice(2).map((function(t){return null!=t?Number(t):0}));return this.$d.years=s[0],this.$d.months=s[1],this.$d.weeks=s[2],this.$d.days=s[3],this.$d.hours=s[4],this.$d.minutes=s[5],this.$d.seconds=s[6],this.calMilliseconds(),this}}return this}var M=m.prototype;return M.calMilliseconds=function(){var t=this;this.$ms=Object.keys(this.$d).reduce((function(n,r){return n+(t.$d[r]||0)*c[r]}),0)},M.parseFromMilliseconds=function(){var t=this.$ms;this.$d.years=v(t/a),this.$d.months=v((t%=a)/o),this.$d.days=v((t%=o)/s),this.$d.hours=v((t%=s)/i),this.$d.minutes=v((t%=i)/e),this.$d.seconds=v((t%=e)/r),this.$d.milliseconds=t%=r},M.toISOString=function(){var t=Y(this.$d.years,"Y"),n=Y(this.$d.months,"M"),r=+this.$d.days||0;this.$d.weeks&&(r+=7*this.$d.weeks);var e=Y(r,"D"),i=Y(this.$d.hours,"H"),s=Y(this.$d.minutes,"M"),u=this.$d.seconds||0;this.$d.milliseconds&&(u+=this.$d.milliseconds/1e3,u=Math.round(1e3*u)/1e3);var a=Y(u,"S"),o=(t.negative||n.negative||e.negative||i.negative||s.negative||a.negative?"-":"")+"P"+t.format+n.format+e.format+(i.format||s.format||a.format?"T":"")+i.format+s.format+a.format;return"P"===o||"-P"===o?"P0D":o},M.toJSON=function(){return this.toISOString()},M.format=function(t){var r=t||"YYYY-MM-DDTHH:mm:ss",e={Y:this.$d.years,YY:n.s(this.$d.years,2,"0"),YYYY:n.s(this.$d.years,4,"0"),M:this.$d.months,MM:n.s(this.$d.months,2,"0"),D:this.$d.days,DD:n.s(this.$d.days,2,"0"),H:this.$d.hours,HH:n.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:n.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:n.s(this.$d.seconds,2,"0"),SSS:n.s(this.$d.milliseconds,3,"0")};return r.replace(u,(function(t,n){return n||String(e[t])}))},M.as=function(t){return this.$ms/c[l(t)]},M.get=function(t){var n=this.$ms,r=l(t);return"milliseconds"===r?n%=1e3:n="weeks"===r?v(n/c[r]):this.$d[r],n||0},M.add=function(t,n,r){var e;return e=n?t*c[l(n)]:f(t)?t.$ms:d(t,this).$ms,d(this.$ms+e*(r?-1:1),this)},M.subtract=function(t,n){return this.add(t,n,!0)},M.locale=function(t){var n=this.clone();return n.$l=t,n},M.clone=function(){return d(this.$ms,this)},M.humanize=function(n){return t().add(this.$ms,"ms").locale(this.$l).fromNow(!n)},M.valueOf=function(){return this.asMilliseconds()},M.milliseconds=function(){return this.get("milliseconds")},M.asMilliseconds=function(){return this.as("milliseconds")},M.seconds=function(){return this.get("seconds")},M.asSeconds=function(){return this.as("seconds")},M.minutes=function(){return this.get("minutes")},M.asMinutes=function(){return this.as("minutes")},M.hours=function(){return this.get("hours")},M.asHours=function(){return this.as("hours")},M.days=function(){return this.get("days")},M.asDays=function(){return this.as("days")},M.weeks=function(){return this.get("weeks")},M.asWeeks=function(){return this.as("weeks")},M.months=function(){return this.get("months")},M.asMonths=function(){return this.as("months")},M.years=function(){return this.get("years")},M.asYears=function(){return this.as("years")},m}(),g=function(t,n,r){return t.add(n.years()*r,"y").add(n.months()*r,"M").add(n.days()*r,"d").add(n.hours()*r,"h").add(n.minutes()*r,"m").add(n.seconds()*r,"s").add(n.milliseconds()*r,"ms")};return function(r,e,i){t=i,n=i().$utils(),i.duration=function(t,n){var r=i.locale();return d(t,{$l:r},n)},i.isDuration=f;var s=e.prototype.add,u=e.prototype.subtract;e.prototype.add=function(t,n){return f(t)?g(this,t,1):s.bind(this)(t,n)},e.prototype.subtract=function(t,n){return f(t)?g(this,t,-1):u.bind(this)(t,n)}}}()),J.exports),W=H(K),B={exports:{}},Q=(Z||(Z=1,B.exports=function(t,n,r){n.prototype.isBetween=function(t,n,e,i){var s=r(t),u=r(n),a="("===(i=i||"()")[0],o=")"===i[1];return(a?this.isAfter(s,e):!this.isBefore(s,e))&&(o?this.isBefore(u,e):!this.isAfter(u,e))||(a?this.isBefore(s,e):!this.isAfter(s,e))&&(o?this.isAfter(u,e):!this.isBefore(u,e))}}),B.exports),R=H(Q);P||(P=1,function(){var t=function(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}($()),n={name:"th",weekdays:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัสบดี_ศุกร์_เสาร์".split("_"),weekdaysShort:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัส_ศุกร์_เสาร์".split("_"),weekdaysMin:"อา._จ._อ._พ._พฤ._ศ._ส.".split("_"),months:"มกราคม_กุมภาพันธ์_มีนาคม_เมษายน_พฤษภาคม_มิถุนายน_กรกฎาคม_สิงหาคม_กันยายน_ตุลาคม_พฤศจิกายน_ธันวาคม".split("_"),monthsShort:"ม.ค._ก.พ._มี.ค._เม.ย._พ.ค._มิ.ย._ก.ค._ส.ค._ก.ย._ต.ค._พ.ย._ธ.ค.".split("_"),formats:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY เวลา H:mm",LLLL:"วันddddที่ D MMMM YYYY เวลา H:mm"},relativeTime:{future:"อีก %s",past:"%sที่แล้ว",s:"ไม่กี่วินาที",m:"1 นาที",mm:"%d นาที",h:"1 ชั่วโมง",hh:"%d ชั่วโมง",d:"1 วัน",dd:"%d วัน",M:"1 เดือน",MM:"%d เดือน",y:"1 ปี",yy:"%d ปี"},ordinal:function(t){return t+"."}};t.default.locale(n,null,!0)}()),O.extend(F),O.extend(z),O.extend(W),O.extend(R);const E=t=>O(t).isValid()?O(t).tz().format("HH:mm"):"",G=t=>O(t).isValid()?O(t).tz().format("DD/MM/YYYY"):"",V=t=>O().tz().format("DD MMM YYYY")===O(t).tz().format("DD MMM YYYY"),X=t=>O(t).isValid()?O(t).tz().format("DD MMM YYYY"):"",tt=t=>O(t).isValid()?O(t).tz().format("DD MMM YYYY HH:mm"):"",nt=t=>{O.locale(t)},rt=t=>{O.tz.setDefault(t)};export{X as A,G as B,rt as a,g as b,d as c,b as d,H as e,f,i as g,Y as h,m as i,S as j,v as k,y as l,V as m,E as n,tt as o,w as p,l as q,p as r,nt as s,M as t,e as u,O as v,_ as w,D as x,s as y,u as z}
|
|
1
|
+
import{i as t}from"./p-DPOSmdTJ.js";import{g as n,f as r}from"./p-NR-FjQmT.js";function e(){return t.t}const i=(t,n=!1)=>{let r="#000";const e=t.includes("rgb")?"rgb":"hex";"hex"===e?r=t:"rgb"===e&&(r="#"+(t.match(/\d+/g)||[]).map((t=>{const n=parseInt(t,10).toString(16);return 1===n.length?"0"+n:n})).join(""));const i=(t=>.299*parseInt(t.substring(1,3),16)+.587*parseInt(t.substring(3,5),16)+.114*parseInt(t.substring(5,7),16))(r);return n?i>128?"#fff":"#000":i>128?"#000":"#fff"};function s(t){const n=new DataTransfer;return t.forEach(((t,r)=>{const e=t.split(","),i=e[0].match(/:(.*?);/),s=i?i[1]:"image/png",u=atob(e[1]);let a=u.length;const o=new Uint8Array(a);for(;a--;)o[a]=u.charCodeAt(a);const h=new File([o],`image${r}.png`,{type:s});n.items.add(h)})),n.files}const u=t=>(["e","E","+","-","ArrowDown"].includes(t.key)||"ArrowDown"===t.key&&(0===parseInt(t.target.value)||""===t.target.value))&&t.preventDefault(),a=t=>!("isConnected"in t)||t.isConnected,o=(()=>{let t;return(...n)=>{t&&clearTimeout(t),t=setTimeout((()=>{t=0,(t=>{for(let n of t.keys())t.set(n,t.get(n).filter(a))})(...n)}),2e3)}})(),h=t=>"function"==typeof t?t():t,c=(t,n)=>{const r=t.indexOf(n);r>=0&&(t[r]=t[t.length-1],t.length--)},f=(t,e)=>{const i=((t,n=(t,n)=>t!==n)=>{const r=h(t);let e=new Map(Object.entries(r??{}));const i={dispose:[],get:[],set:[],reset:[]},s=new Map,u=()=>{e=new Map(Object.entries(h(t)??{})),i.reset.forEach((t=>t()))},a=t=>(i.get.forEach((n=>n(t))),e.get(t)),o=(t,r)=>{const s=e.get(t);n(r,s,t)&&(e.set(t,r),i.set.forEach((n=>n(t,r,s))))},f="undefined"==typeof Proxy?{}:new Proxy(r,{get:(t,n)=>a(n),ownKeys:()=>Array.from(e.keys()),getOwnPropertyDescriptor:()=>({enumerable:!0,configurable:!0}),has:(t,n)=>e.has(n),set:(t,n,r)=>(o(n,r),!0)}),d=(t,n)=>(i[t].push(n),()=>{c(i[t],n)});return{state:f,get:a,set:o,on:d,onChange:(n,r)=>{const e=(t,e)=>{t===n&&r(e)},i=()=>r(h(t)[n]),u=d("set",e),a=d("reset",i);return s.set(r,{setHandler:e,resetHandler:i,propName:n}),()=>{u(),a(),s.delete(r)}},use:(...t)=>{const n=t.reduce(((t,n)=>(n.set&&t.push(d("set",n.set)),n.get&&t.push(d("get",n.get)),n.reset&&t.push(d("reset",n.reset)),n.dispose&&t.push(d("dispose",n.dispose)),t)),[]);return()=>n.forEach((t=>t()))},dispose:()=>{i.dispose.forEach((t=>t())),u()},reset:u,forceUpdate:t=>{const n=e.get(t);i.set.forEach((r=>r(t,n,n)))},removeListener:(t,n)=>{const r=s.get(n);r&&r.propName===t&&(c(i.set,r.setHandler),c(i.reset,r.resetHandler),s.delete(n))}}})(t,e);return i.use((()=>{if("function"!=typeof n)return{};const t=new Map;return{dispose:()=>t.clear(),get:r=>{const e=n();e&&((t,n,r)=>{const e=t.get(n);e?e.includes(r)||e.push(r):t.set(n,[r])})(t,r,e)},set:n=>{const e=t.get(n);e&&t.set(n,e.filter(r)),o(t)},reset:()=>{t.forEach((t=>t.forEach(r))),o(t)}}})()),i},d=f({language:"en",theme:"light",businessId:null,shopId:null,accessToken:null,isProduction:!1,timeZone:null,translationSettings:{is_auto:!1,target_language:null,exclude_languages:[]},isNotConnected:!1,connectionList:[],memberList:[]}),l=f({messages:[],reads:[],loadedKeys:new Set,readsMap:{}}),m=f({filterType:"quick"}),v=f({statuses:[]}),M=f({tags:[]}),Y=f({chats:[],loadedKeys:new Set}),_=f({user:null}),g=f({userAddress:null}),y=f({selectedChat:null,isSyncingTag:!1,isSyncingMessage:!1}),D=f({selectedMessageToReply:null}),p=f({isMobile:!1}),w=f({isShow:!1}),S=f({filters:[],selectedFilter:null,loading:!1});var b="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function H(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var T,k={exports:{}};function $(){return T||(T=1,k.exports=function(){var t=6e4,n=36e5,r="millisecond",e="second",i="minute",s="hour",u="day",a="week",o="month",h="quarter",c="year",f="date",d="Invalid Date",l=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,m=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,v={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var n=["th","st","nd","rd"],r=t%100;return"["+t+(n[(r-20)%10]||n[r]||n[0])+"]"}},M=function(t,n,r){var e=String(t);return!e||e.length>=n?t:""+Array(n+1-e.length).join(r)+t},Y={s:M,z:function(t){var n=-t.utcOffset(),r=Math.abs(n),e=Math.floor(r/60),i=r%60;return(n<=0?"+":"-")+M(e,2,"0")+":"+M(i,2,"0")},m:function t(n,r){if(n.date()<r.date())return-t(r,n);var e=12*(r.year()-n.year())+(r.month()-n.month()),i=n.clone().add(e,o),s=r-i<0,u=n.clone().add(e+(s?-1:1),o);return+(-(e+(r-i)/(s?i-u:u-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:o,y:c,w:a,d:u,D:f,h:s,m:i,s:e,ms:r,Q:h}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},_="en",g={};g[_]=v;var y="$isDayjsObject",D=function(t){return t instanceof b||!(!t||!t[y])},p=function t(n,r,e){var i;if(!n)return _;if("string"==typeof n){var s=n.toLowerCase();g[s]&&(i=s),r&&(g[s]=r,i=s);var u=n.split("-");if(!i&&u.length>1)return t(u[0])}else{var a=n.name;g[a]=n,i=a}return!e&&i&&(_=i),i||!e&&_},w=function(t,n){if(D(t))return t.clone();var r="object"==typeof n?n:{};return r.date=t,r.args=arguments,new b(r)},S=Y;S.l=p,S.i=D,S.w=function(t,n){return w(t,{locale:n.$L,utc:n.$u,x:n.$x,$offset:n.$offset})};var b=function(){function v(t){this.$L=p(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[y]=!0}var M=v.prototype;return M.parse=function(t){this.$d=function(t){var n=t.date,r=t.utc;if(null===n)return new Date(NaN);if(S.u(n))return new Date;if(n instanceof Date)return new Date(n);if("string"==typeof n&&!/Z$/i.test(n)){var e=n.match(l);if(e){var i=e[2]-1||0,s=(e[7]||"0").substring(0,3);return r?new Date(Date.UTC(e[1],i,e[3]||1,e[4]||0,e[5]||0,e[6]||0,s)):new Date(e[1],i,e[3]||1,e[4]||0,e[5]||0,e[6]||0,s)}}return new Date(n)}(t),this.init()},M.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},M.$utils=function(){return S},M.isValid=function(){return!(this.$d.toString()===d)},M.isSame=function(t,n){var r=w(t);return this.startOf(n)<=r&&r<=this.endOf(n)},M.isAfter=function(t,n){return w(t)<this.startOf(n)},M.isBefore=function(t,n){return this.endOf(n)<w(t)},M.$g=function(t,n,r){return S.u(t)?this[n]:this.set(r,t)},M.unix=function(){return Math.floor(this.valueOf()/1e3)},M.valueOf=function(){return this.$d.getTime()},M.startOf=function(t,n){var r=this,h=!!S.u(n)||n,d=S.p(t),l=function(t,n){var e=S.w(r.$u?Date.UTC(r.$y,n,t):new Date(r.$y,n,t),r);return h?e:e.endOf(u)},m=function(t,n){return S.w(r.toDate()[t].apply(r.toDate("s"),(h?[0,0,0,0]:[23,59,59,999]).slice(n)),r)},v=this.$W,M=this.$M,Y=this.$D,_="set"+(this.$u?"UTC":"");switch(d){case c:return h?l(1,0):l(31,11);case o:return h?l(1,M):l(0,M+1);case a:var g=this.$locale().weekStart||0,y=(v<g?v+7:v)-g;return l(h?Y-y:Y+(6-y),M);case u:case f:return m(_+"Hours",0);case s:return m(_+"Minutes",1);case i:return m(_+"Seconds",2);case e:return m(_+"Milliseconds",3);default:return this.clone()}},M.endOf=function(t){return this.startOf(t,!1)},M.$set=function(t,n){var a,h=S.p(t),d="set"+(this.$u?"UTC":""),l=(a={},a[u]=d+"Date",a[f]=d+"Date",a[o]=d+"Month",a[c]=d+"FullYear",a[s]=d+"Hours",a[i]=d+"Minutes",a[e]=d+"Seconds",a[r]=d+"Milliseconds",a)[h],m=h===u?this.$D+(n-this.$W):n;if(h===o||h===c){var v=this.clone().set(f,1);v.$d[l](m),v.init(),this.$d=v.set(f,Math.min(this.$D,v.daysInMonth())).$d}else l&&this.$d[l](m);return this.init(),this},M.set=function(t,n){return this.clone().$set(t,n)},M.get=function(t){return this[S.p(t)]()},M.add=function(r,h){var f,d=this;r=Number(r);var l=S.p(h),m=function(t){var n=w(d);return S.w(n.date(n.date()+Math.round(t*r)),d)};if(l===o)return this.set(o,this.$M+r);if(l===c)return this.set(c,this.$y+r);if(l===u)return m(1);if(l===a)return m(7);var v=(f={},f[i]=t,f[s]=n,f[e]=1e3,f)[l]||1,M=this.$d.getTime()+r*v;return S.w(M,this)},M.subtract=function(t,n){return this.add(-1*t,n)},M.format=function(t){var n=this,r=this.$locale();if(!this.isValid())return r.invalidDate||d;var e=t||"YYYY-MM-DDTHH:mm:ssZ",i=S.z(this),s=this.$H,u=this.$m,a=this.$M,o=r.weekdays,h=r.months,c=function(t,r,i,s){return t&&(t[r]||t(n,e))||i[r].slice(0,s)},f=function(t){return S.s(s%12||12,t,"0")},l=r.meridiem||function(t,n,r){var e=t<12?"AM":"PM";return r?e.toLowerCase():e};return e.replace(m,(function(t,e){return e||function(t){switch(t){case"YY":return String(n.$y).slice(-2);case"YYYY":return S.s(n.$y,4,"0");case"M":return a+1;case"MM":return S.s(a+1,2,"0");case"MMM":return c(r.monthsShort,a,h,3);case"MMMM":return c(h,a);case"D":return n.$D;case"DD":return S.s(n.$D,2,"0");case"d":return String(n.$W);case"dd":return c(r.weekdaysMin,n.$W,o,2);case"ddd":return c(r.weekdaysShort,n.$W,o,3);case"dddd":return o[n.$W];case"H":return String(s);case"HH":return S.s(s,2,"0");case"h":return f(1);case"hh":return f(2);case"a":return l(s,u,!0);case"A":return l(s,u,!1);case"m":return String(u);case"mm":return S.s(u,2,"0");case"s":return String(n.$s);case"ss":return S.s(n.$s,2,"0");case"SSS":return S.s(n.$ms,3,"0");case"Z":return i}return null}(t)||i.replace(":","")}))},M.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},M.diff=function(r,f,d){var l,m=this,v=S.p(f),M=w(r),Y=(M.utcOffset()-this.utcOffset())*t,_=this-M,g=function(){return S.m(m,M)};switch(v){case c:l=g()/12;break;case o:l=g();break;case h:l=g()/3;break;case a:l=(_-Y)/6048e5;break;case u:l=(_-Y)/864e5;break;case s:l=_/n;break;case i:l=_/t;break;case e:l=_/1e3;break;default:l=_}return d?l:S.a(l)},M.daysInMonth=function(){return this.endOf(o).$D},M.$locale=function(){return g[this.$L]},M.locale=function(t,n){if(!t)return this.$L;var r=this.clone(),e=p(t,n,!0);return e&&(r.$L=e),r},M.clone=function(){return S.w(this.$d,this)},M.toDate=function(){return new Date(this.valueOf())},M.toJSON=function(){return this.isValid()?this.toISOString():null},M.toISOString=function(){return this.$d.toISOString()},M.toString=function(){return this.$d.toUTCString()},v}(),H=b.prototype;return w.prototype=H,[["$ms",r],["$s",e],["$m",i],["$H",s],["$W",u],["$M",o],["$y",c],["$D",f]].forEach((function(t){H[t[1]]=function(n){return this.$g(n,t[0],t[1])}})),w.extend=function(t,n){return t.$i||(t(n,b,w),t.$i=!0),w},w.locale=p,w.isDayjs=D,w.unix=function(t){return w(1e3*t)},w.en=g[_],w.Ls=g,w.p={},w}()),k.exports}var L,j,x,A,I,N,P,Z,O=H($()),C={exports:{}},F=H((L||(L=1,C.exports=(j="minute",x=/[+-]\d\d(?::?\d\d)?/g,A=/([+-]|\d\d)/g,function(t,n,r){var e=n.prototype;r.utc=function(t){return new n({date:t,utc:!0,args:arguments})},e.utc=function(t){var n=r(this.toDate(),{locale:this.$L,utc:!0});return t?n.add(this.utcOffset(),j):n},e.local=function(){return r(this.toDate(),{locale:this.$L,utc:!1})};var i=e.parse;e.parse=function(t){t.utc&&(this.$u=!0),this.$utils().u(t.$offset)||(this.$offset=t.$offset),i.call(this,t)};var s=e.init;e.init=function(){if(this.$u){var t=this.$d;this.$y=t.getUTCFullYear(),this.$M=t.getUTCMonth(),this.$D=t.getUTCDate(),this.$W=t.getUTCDay(),this.$H=t.getUTCHours(),this.$m=t.getUTCMinutes(),this.$s=t.getUTCSeconds(),this.$ms=t.getUTCMilliseconds()}else s.call(this)};var u=e.utcOffset;e.utcOffset=function(t,n){var r=this.$utils().u;if(r(t))return this.$u?0:r(this.$offset)?u.call(this):this.$offset;if("string"==typeof t&&(t=function(t){void 0===t&&(t="");var n=t.match(x);if(!n)return null;var r=(""+n[0]).match(A)||["-",0,0],e=60*+r[1]+ +r[2];return 0===e?0:"+"===r[0]?e:-e}(t),null===t))return this;var e=Math.abs(t)<=16?60*t:t;if(0===e)return this.utc(n);var i=this.clone();if(n)return i.$offset=e,i.$u=!1,i;var s=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();return(i=this.local().add(e+s,j)).$offset=e,i.$x.$localOffset=s,i};var a=e.format;e.format=function(t){return a.call(this,t||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":""))},e.valueOf=function(){var t=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*t},e.isUTC=function(){return!!this.$u},e.toISOString=function(){return this.toDate().toISOString()},e.toString=function(){return this.toDate().toUTCString()};var o=e.toDate;e.toDate=function(t){return"s"===t&&this.$offset?r(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():o.call(this)};var h=e.diff;e.diff=function(t,n,e){if(t&&this.$u===t.$u)return h.call(this,t,n,e);var i=this.local(),s=r(t).local();return h.call(i,s,n,e)}})),C.exports)),U={exports:{}},J=(I||(I=1,U.exports=function(){var t={year:0,month:1,day:2,hour:3,minute:4,second:5},n={};return function(r,e,i){var s,u=function(t,r,e){void 0===e&&(e={});var i=new Date(t),s=function(t,r){void 0===r&&(r={});var e=r.timeZoneName||"short",i=t+"|"+e,s=n[i];return s||(s=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:e}),n[i]=s),s}(r,e);return s.formatToParts(i)},a=function(n,r){for(var e=u(n,r),s=[],a=0;a<e.length;a+=1){var o=e[a],h=t[o.type];h>=0&&(s[h]=parseInt(o.value,10))}var c=s[3],f=+n;return(i.utc(s[0]+"-"+s[1]+"-"+s[2]+" "+(24===c?0:c)+":"+s[4]+":"+s[5]+":000").valueOf()-(f-=f%1e3))/6e4},o=e.prototype;o.tz=function(t,n){void 0===t&&(t=s);var r,e=this.utcOffset(),u=this.toDate(),a=u.toLocaleString("en-US",{timeZone:t}),o=Math.round((u-new Date(a))/1e3/60),h=15*-Math.round(u.getTimezoneOffset()/15)-o;if(Number(h)){if(r=i(a,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(h,!0),n){var c=r.utcOffset();r=r.add(e-c,"minute")}}else r=this.utcOffset(0,n);return r.$x.$timezone=t,r},o.offsetName=function(t){var n=this.$x.$timezone||i.tz.guess(),r=u(this.valueOf(),n,{timeZoneName:t}).find((function(t){return"timezonename"===t.type.toLowerCase()}));return r&&r.value};var h=o.startOf;o.startOf=function(t,n){if(!this.$x||!this.$x.$timezone)return h.call(this,t,n);var r=i(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return h.call(r,t,n).tz(this.$x.$timezone,!0)},i.tz=function(t,n,r){var e=r&&n,u=r||n||s,o=a(+i(),u);if("string"!=typeof t)return i(t).tz(u);var h=function(t,n,r){var e=t-60*n*1e3,i=a(e,r);if(n===i)return[e,n];var s=a(e-=60*(i-n)*1e3,r);return i===s?[e,i]:[t-60*Math.min(i,s)*1e3,Math.max(i,s)]}(i.utc(t,e).valueOf(),o,u),c=h[1],f=i(h[0]).utcOffset(c);return f.$x.$timezone=u,f},i.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},i.tz.setDefault=function(t){s=t}}}()),U.exports),q=H(J),z={exports:{}},K=(N||(N=1,z.exports=function(){var t,n,r=1e3,e=6e4,i=36e5,s=864e5,u=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,a=31536e6,o=2628e6,h=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,c={years:a,months:o,days:s,hours:i,minutes:e,seconds:r,milliseconds:1,weeks:6048e5},f=function(t){return t instanceof _},d=function(t,n,r){return new _(t,r,n.$l)},l=function(t){return n.p(t)+"s"},m=function(t){return t<0},v=function(t){return m(t)?Math.ceil(t):Math.floor(t)},M=function(t){return Math.abs(t)},Y=function(t,n){return t?m(t)?{negative:!0,format:""+M(t)+n}:{negative:!1,format:""+t+n}:{negative:!1,format:""}},_=function(){function m(t,n,r){var e=this;if(this.$d={},this.$l=r,void 0===t&&(this.$ms=0,this.parseFromMilliseconds()),n)return d(t*c[l(n)],this);if("number"==typeof t)return this.$ms=t,this.parseFromMilliseconds(),this;if("object"==typeof t)return Object.keys(t).forEach((function(n){e.$d[l(n)]=t[n]})),this.calMilliseconds(),this;if("string"==typeof t){var i=t.match(h);if(i){var s=i.slice(2).map((function(t){return null!=t?Number(t):0}));return this.$d.years=s[0],this.$d.months=s[1],this.$d.weeks=s[2],this.$d.days=s[3],this.$d.hours=s[4],this.$d.minutes=s[5],this.$d.seconds=s[6],this.calMilliseconds(),this}}return this}var M=m.prototype;return M.calMilliseconds=function(){var t=this;this.$ms=Object.keys(this.$d).reduce((function(n,r){return n+(t.$d[r]||0)*c[r]}),0)},M.parseFromMilliseconds=function(){var t=this.$ms;this.$d.years=v(t/a),this.$d.months=v((t%=a)/o),this.$d.days=v((t%=o)/s),this.$d.hours=v((t%=s)/i),this.$d.minutes=v((t%=i)/e),this.$d.seconds=v((t%=e)/r),this.$d.milliseconds=t%=r},M.toISOString=function(){var t=Y(this.$d.years,"Y"),n=Y(this.$d.months,"M"),r=+this.$d.days||0;this.$d.weeks&&(r+=7*this.$d.weeks);var e=Y(r,"D"),i=Y(this.$d.hours,"H"),s=Y(this.$d.minutes,"M"),u=this.$d.seconds||0;this.$d.milliseconds&&(u+=this.$d.milliseconds/1e3,u=Math.round(1e3*u)/1e3);var a=Y(u,"S"),o=(t.negative||n.negative||e.negative||i.negative||s.negative||a.negative?"-":"")+"P"+t.format+n.format+e.format+(i.format||s.format||a.format?"T":"")+i.format+s.format+a.format;return"P"===o||"-P"===o?"P0D":o},M.toJSON=function(){return this.toISOString()},M.format=function(t){var r=t||"YYYY-MM-DDTHH:mm:ss",e={Y:this.$d.years,YY:n.s(this.$d.years,2,"0"),YYYY:n.s(this.$d.years,4,"0"),M:this.$d.months,MM:n.s(this.$d.months,2,"0"),D:this.$d.days,DD:n.s(this.$d.days,2,"0"),H:this.$d.hours,HH:n.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:n.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:n.s(this.$d.seconds,2,"0"),SSS:n.s(this.$d.milliseconds,3,"0")};return r.replace(u,(function(t,n){return n||String(e[t])}))},M.as=function(t){return this.$ms/c[l(t)]},M.get=function(t){var n=this.$ms,r=l(t);return"milliseconds"===r?n%=1e3:n="weeks"===r?v(n/c[r]):this.$d[r],n||0},M.add=function(t,n,r){var e;return e=n?t*c[l(n)]:f(t)?t.$ms:d(t,this).$ms,d(this.$ms+e*(r?-1:1),this)},M.subtract=function(t,n){return this.add(t,n,!0)},M.locale=function(t){var n=this.clone();return n.$l=t,n},M.clone=function(){return d(this.$ms,this)},M.humanize=function(n){return t().add(this.$ms,"ms").locale(this.$l).fromNow(!n)},M.valueOf=function(){return this.asMilliseconds()},M.milliseconds=function(){return this.get("milliseconds")},M.asMilliseconds=function(){return this.as("milliseconds")},M.seconds=function(){return this.get("seconds")},M.asSeconds=function(){return this.as("seconds")},M.minutes=function(){return this.get("minutes")},M.asMinutes=function(){return this.as("minutes")},M.hours=function(){return this.get("hours")},M.asHours=function(){return this.as("hours")},M.days=function(){return this.get("days")},M.asDays=function(){return this.as("days")},M.weeks=function(){return this.get("weeks")},M.asWeeks=function(){return this.as("weeks")},M.months=function(){return this.get("months")},M.asMonths=function(){return this.as("months")},M.years=function(){return this.get("years")},M.asYears=function(){return this.as("years")},m}(),g=function(t,n,r){return t.add(n.years()*r,"y").add(n.months()*r,"M").add(n.days()*r,"d").add(n.hours()*r,"h").add(n.minutes()*r,"m").add(n.seconds()*r,"s").add(n.milliseconds()*r,"ms")};return function(r,e,i){t=i,n=i().$utils(),i.duration=function(t,n){var r=i.locale();return d(t,{$l:r},n)},i.isDuration=f;var s=e.prototype.add,u=e.prototype.subtract;e.prototype.add=function(t,n){return f(t)?g(this,t,1):s.bind(this)(t,n)},e.prototype.subtract=function(t,n){return f(t)?g(this,t,-1):u.bind(this)(t,n)}}}()),z.exports),W=H(K),Q={exports:{}},R=(P||(P=1,Q.exports=function(t,n,r){n.prototype.isBetween=function(t,n,e,i){var s=r(t),u=r(n),a="("===(i=i||"()")[0],o=")"===i[1];return(a?this.isAfter(s,e):!this.isBefore(s,e))&&(o?this.isBefore(u,e):!this.isAfter(u,e))||(a?this.isBefore(s,e):!this.isAfter(s,e))&&(o?this.isAfter(u,e):!this.isBefore(u,e))}}),Q.exports),B=H(R);Z||(Z=1,function(){var t=function(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}($()),n={name:"th",weekdays:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัสบดี_ศุกร์_เสาร์".split("_"),weekdaysShort:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัส_ศุกร์_เสาร์".split("_"),weekdaysMin:"อา._จ._อ._พ._พฤ._ศ._ส.".split("_"),months:"มกราคม_กุมภาพันธ์_มีนาคม_เมษายน_พฤษภาคม_มิถุนายน_กรกฎาคม_สิงหาคม_กันยายน_ตุลาคม_พฤศจิกายน_ธันวาคม".split("_"),monthsShort:"ม.ค._ก.พ._มี.ค._เม.ย._พ.ค._มิ.ย._ก.ค._ส.ค._ก.ย._ต.ค._พ.ย._ธ.ค.".split("_"),formats:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY เวลา H:mm",LLLL:"วันddddที่ D MMMM YYYY เวลา H:mm"},relativeTime:{future:"อีก %s",past:"%sที่แล้ว",s:"ไม่กี่วินาที",m:"1 นาที",mm:"%d นาที",h:"1 ชั่วโมง",hh:"%d ชั่วโมง",d:"1 วัน",dd:"%d วัน",M:"1 เดือน",MM:"%d เดือน",y:"1 ปี",yy:"%d ปี"},ordinal:function(t){return t+"."}};t.default.locale(n,null,!0)}()),O.extend(F),O.extend(q),O.extend(W),O.extend(B);const E=t=>O(t).isValid()?O(t).tz().format("HH:mm"):"",G=t=>O(t).isValid()?O(t).tz().format("DD/MM/YYYY"):"",V=t=>O().tz().format("DD MMM YYYY")===O(t).tz().format("DD MMM YYYY"),X=t=>O(t).isValid()?O(t).tz().format("DD MMM YYYY"):"",tt=t=>O(t).isValid()?O(t).tz().format("DD MMM YYYY HH:mm"):"",nt=t=>{O.locale(t)},rt=t=>{O.tz.setDefault(t)};export{X as A,G as B,rt as a,g as b,d as c,b as d,H as e,f,i as g,Y as h,m as i,S as j,v as k,y as l,V as m,E as n,tt as o,w as p,l as q,p as r,nt as s,M as t,e as u,O as v,_ as w,D as x,s as y,u as z}
|