@opengis/admin 0.3.84 → 0.3.86
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/{add-page-D5h1nd44.js → add-page-CByeQYi1.js} +1 -1
- package/dist/{admin-interface-BL78T_tI.js → admin-interface-CFij1RI4.js} +1 -1
- package/dist/{admin-view-BdzII4mV.js → admin-view-BhZTNW31.js} +1 -1
- package/dist/admin.js +1 -1
- package/dist/admin.umd.cjs +1 -1
- package/dist/{card-view-CMZ6FcPZ.js → card-view-RhrOyyhe.js} +1 -1
- package/dist/{edit-page-BiCqun6l.js → edit-page-BZu_3g4o.js} +1 -1
- package/dist/{import-file-DoXCXa-Q.js → import-file-CrENtq-3.js} +188 -188
- package/dist/{profile-page-BvH-kg6j.js → profile-page-BJ0Mf6C2.js} +1 -1
- package/package.json +1 -1
- package/server/routes/widget/controllers/widget.get.js +15 -9
@@ -1,4 +1,4 @@
|
|
1
|
-
import { _ as d, s as f, u as g, g as m } from "./import-file-
|
1
|
+
import { _ as d, s as f, u as g, g as m } from "./import-file-CrENtq-3.js";
|
2
2
|
import { resolveComponent as b, openBlock as h, createElementBlock as x, createElementVNode as i, normalizeClass as y, normalizeStyle as p, createBlock as w, createCommentVNode as v } from "vue";
|
3
3
|
const $ = {
|
4
4
|
data() {
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { _ as S, h as Je, i as Ge, j as Qe, g as M, I as Xe, s as E, k as Ue, l as Q, A as X, V as Ye, m as Ze, n as et, o as tt, p as st, b as nt, q as lt, a as at, r as rt, t as ot, u as Ee } from "./import-file-
|
1
|
+
import { _ as S, h as Je, i as Ge, j as Qe, g as M, I as Xe, s as E, k as Ue, l as Q, A as X, V as Ye, m as Ze, n as et, o as tt, p as st, b as nt, q as lt, a as at, r as rt, t as ot, u as Ee } from "./import-file-CrENtq-3.js";
|
2
2
|
import { openBlock as r, createElementBlock as i, createTextVNode as P, toDisplayString as A, createElementVNode as a, normalizeClass as w, createCommentVNode as k, resolveComponent as f, Fragment as $, createVNode as x, withCtx as D, createBlock as v, renderList as V, withModifiers as it, createStaticVNode as dt, withDirectives as U, vModelCheckbox as ut, Transition as W, vModelText as ct, renderSlot as ht, vShow as Y, Teleport as pt, getCurrentInstance as Re, ref as J, resolveDynamicComponent as G, defineComponent as bt, withKeys as ft, normalizeStyle as K } from "vue";
|
3
3
|
const gt = {
|
4
4
|
data() {
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { openBlock as n, createElementBlock as u, createElementVNode as o, createStaticVNode as Q, resolveComponent as p, normalizeClass as f, createTextVNode as V, toDisplayString as B, createCommentVNode as w, createVNode as h, Transition as q, withCtx as _, withDirectives as W, Fragment as U, renderList as P, vShow as J, createBlock as T, resolveDynamicComponent as F, ref as le, onMounted as ae, computed as oe, withModifiers as ne } from "vue";
|
2
|
-
import { _ as y, I as K, s as g, a as X, u as A, b as se, c as Y, d as ue, e as ie, f as de, g as ce } from "./import-file-
|
2
|
+
import { _ as y, I as K, s as g, a as X, u as A, b as se, c as Y, d as ue, e as ie, f as de, g as ce } from "./import-file-CrENtq-3.js";
|
3
3
|
import "./user-B_2kh6ic.js";
|
4
4
|
const he = {}, ge = {
|
5
5
|
xmlns: "http://www.w3.org/2000/svg",
|
package/dist/admin.js
CHANGED
package/dist/admin.umd.cjs
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...n){const r=new this(e);return n.forEach(i=>r.set(i)),r}static accessor(e){const r=(this[kw]=this[kw]={accessors:{}}).accessors,i=this.prototype;function s(a){const o=oh(a);r[o]||(pR(i,a),r[o]=!0)}return Be.isArray(e)?e.forEach(s):s(e),this}}Yi.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),Be.reduceDescriptors(Yi.prototype,({value:t},e)=>{let n=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(r){this[n]=r}}}),Be.freezeMethods(Yi);function b0(t,e){const n=this||sh,r=e||n,i=Yi.from(r.headers);let s=r.data;return Be.forEach(t,function(o){s=o.call(n,s,i.normalize(),e?e.status:void 0)}),i.normalize(),s}function Ew(t){return!!(t&&t.__CANCEL__)}function id(t,e,n){on.call(this,t??"canceled",on.ERR_CANCELED,e,n),this.name="CanceledError"}Be.inherits(id,on,{__CANCEL__:!0});function Sw(t,e,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?t(n):e(new on("Request failed with status code "+n.status,[on.ERR_BAD_REQUEST,on.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function fR(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function mR(t,e){t=t||10;const n=new Array(t),r=new Array(t);let i=0,s=0,a;return e=e!==void 0?e:1e3,function(f){const g=Date.now(),y=r[s];a||(a=g),n[i]=f,r[i]=g;let v=s,w=0;for(;v!==i;)w+=n[v++],v=v%t;if(i=(i+1)%t,i===s&&(s=(s+1)%t),g-a<e)return;const T=y&&g-y;return T?Math.round(w*1e3/T):void 0}}function gR(t,e){let n=0,r=1e3/e,i,s;const a=(g,y=Date.now())=>{n=y,i=null,s&&(clearTimeout(s),s=null),t.apply(null,g)};return[(...g)=>{const y=Date.now(),v=y-n;v>=r?a(g,y):(i=g,s||(s=setTimeout(()=>{s=null,a(i)},r-v)))},()=>i&&a(i)]}const zf=(t,e,n=3)=>{let r=0;const i=mR(50,250);return gR(s=>{const a=s.loaded,o=s.lengthComputable?s.total:void 0,f=a-r,g=i(f),y=a<=o;r=a;const v={loaded:a,total:o,progress:o?a/o:void 0,bytes:f,rate:g||void 0,estimated:g&&o&&y?(o-a)/g:void 0,event:s,lengthComputable:o!=null,[e?"download":"upload"]:!0};t(v)},n)},Cw=(t,e)=>{const n=t!=null;return[r=>e[0]({lengthComputable:n,total:t,loaded:r}),e[1]]},Tw=t=>(...e)=>Be.asap(()=>t(...e)),yR=Gi.hasStandardBrowserEnv?function(){const e=Gi.navigator&&/(msie|trident)/i.test(Gi.navigator.userAgent),n=document.createElement("a");let r;function i(s){let a=s;return e&&(n.setAttribute("href",a),a=n.href),n.setAttribute("href",a),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=i(window.location.href),function(a){const o=Be.isString(a)?i(a):a;return o.protocol===r.protocol&&o.host===r.host}}():function(){return function(){return!0}}(),bR=Gi.hasStandardBrowserEnv?{write(t,e,n,r,i,s){const a=[t+"="+encodeURIComponent(e)];Be.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),Be.isString(r)&&a.push("path="+r),Be.isString(i)&&a.push("domain="+i),s===!0&&a.push("secure"),document.cookie=a.join("; ")},read(t){const e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(t){this.write(t,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function _R(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function xR(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function Aw(t,e){return t&&!_R(e)?xR(t,e):e}const Mw=t=>t instanceof Yi?{...t}:t;function Gl(t,e){e=e||{};const n={};function r(g,y,v){return Be.isPlainObject(g)&&Be.isPlainObject(y)?Be.merge.call({caseless:v},g,y):Be.isPlainObject(y)?Be.merge({},y):Be.isArray(y)?y.slice():y}function i(g,y,v){if(Be.isUndefined(y)){if(!Be.isUndefined(g))return r(void 0,g,v)}else return r(g,y,v)}function s(g,y){if(!Be.isUndefined(y))return r(void 0,y)}function a(g,y){if(Be.isUndefined(y)){if(!Be.isUndefined(g))return r(void 0,g)}else return r(void 0,y)}function o(g,y,v){if(v in e)return r(g,y);if(v in t)return r(void 0,g)}const f={url:s,method:s,data:s,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:o,headers:(g,y)=>i(Mw(g),Mw(y),!0)};return Be.forEach(Object.keys(Object.assign({},t,e)),function(y){const v=f[y]||i,w=v(t[y],e[y],y);Be.isUndefined(w)&&v!==o||(n[y]=w)}),n}const Dw=t=>{const e=Gl({},t);let{data:n,withXSRFToken:r,xsrfHeaderName:i,xsrfCookieName:s,headers:a,auth:o}=e;e.headers=a=Yi.from(a),e.url=_w(Aw(e.baseURL,e.url),t.params,t.paramsSerializer),o&&a.set("Authorization","Basic "+btoa((o.username||"")+":"+(o.password?unescape(encodeURIComponent(o.password)):"")));let f;if(Be.isFormData(n)){if(Gi.hasStandardBrowserEnv||Gi.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((f=a.getContentType())!==!1){const[g,...y]=f?f.split(";").map(v=>v.trim()).filter(Boolean):[];a.setContentType([g||"multipart/form-data",...y].join("; "))}}if(Gi.hasStandardBrowserEnv&&(r&&Be.isFunction(r)&&(r=r(e)),r||r!==!1&&yR(e.url))){const g=i&&s&&bR.read(s);g&&a.set(i,g)}return e},vR=typeof XMLHttpRequest<"u"&&function(t){return new Promise(function(n,r){const i=Dw(t);let s=i.data;const a=Yi.from(i.headers).normalize();let{responseType:o,onUploadProgress:f,onDownloadProgress:g}=i,y,v,w,T,D;function O(){T&&T(),D&&D(),i.cancelToken&&i.cancelToken.unsubscribe(y),i.signal&&i.signal.removeEventListener("abort",y)}let B=new XMLHttpRequest;B.open(i.method.toUpperCase(),i.url,!0),B.timeout=i.timeout;function L(){if(!B)return;const Z=Yi.from("getAllResponseHeaders"in B&&B.getAllResponseHeaders()),ue={data:!o||o==="text"||o==="json"?B.responseText:B.response,status:B.status,statusText:B.statusText,headers:Z,config:t,request:B};Sw(function(be){n(be),O()},function(be){r(be),O()},ue),B=null}"onloadend"in B?B.onloadend=L:B.onreadystatechange=function(){!B||B.readyState!==4||B.status===0&&!(B.responseURL&&B.responseURL.indexOf("file:")===0)||setTimeout(L)},B.onabort=function(){B&&(r(new on("Request aborted",on.ECONNABORTED,t,B)),B=null)},B.onerror=function(){r(new on("Network Error",on.ERR_NETWORK,t,B)),B=null},B.ontimeout=function(){let Y=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const ue=i.transitional||vw;i.timeoutErrorMessage&&(Y=i.timeoutErrorMessage),r(new on(Y,ue.clarifyTimeoutError?on.ETIMEDOUT:on.ECONNABORTED,t,B)),B=null},s===void 0&&a.setContentType(null),"setRequestHeader"in B&&Be.forEach(a.toJSON(),function(Y,ue){B.setRequestHeader(ue,Y)}),Be.isUndefined(i.withCredentials)||(B.withCredentials=!!i.withCredentials),o&&o!=="json"&&(B.responseType=i.responseType),g&&([w,D]=zf(g,!0),B.addEventListener("progress",w)),f&&B.upload&&([v,T]=zf(f),B.upload.addEventListener("progress",v),B.upload.addEventListener("loadend",T)),(i.cancelToken||i.signal)&&(y=Z=>{B&&(r(!Z||Z.type?new id(null,t,B):Z),B.abort(),B=null)},i.cancelToken&&i.cancelToken.subscribe(y),i.signal&&(i.signal.aborted?y():i.signal.addEventListener("abort",y)));const U=fR(i.url);if(U&&Gi.protocols.indexOf(U)===-1){r(new on("Unsupported protocol "+U+":",on.ERR_BAD_REQUEST,t));return}B.send(s||null)})},wR=(t,e)=>{const{length:n}=t=t?t.filter(Boolean):[];if(e||n){let r=new AbortController,i;const s=function(g){if(!i){i=!0,o();const y=g instanceof Error?g:this.reason;r.abort(y instanceof on?y:new id(y instanceof Error?y.message:y))}};let a=e&&setTimeout(()=>{a=null,s(new on(`timeout ${e} of ms exceeded`,on.ETIMEDOUT))},e);const o=()=>{t&&(a&&clearTimeout(a),a=null,t.forEach(g=>{g.unsubscribe?g.unsubscribe(s):g.removeEventListener("abort",s)}),t=null)};t.forEach(g=>g.addEventListener("abort",s));const{signal:f}=r;return f.unsubscribe=()=>Be.asap(o),f}},kR=function*(t,e){let n=t.byteLength;if(n<e){yield t;return}let r=0,i;for(;r<n;)i=r+e,yield t.slice(r,i),r=i},ER=async function*(t,e){for await(const n of SR(t))yield*kR(n,e)},SR=async function*(t){if(t[Symbol.asyncIterator]){yield*t;return}const e=t.getReader();try{for(;;){const{done:n,value:r}=await e.read();if(n)break;yield r}}finally{await e.cancel()}},Iw=(t,e,n,r)=>{const i=ER(t,e);let s=0,a,o=f=>{a||(a=!0,r&&r(f))};return new ReadableStream({async pull(f){try{const{done:g,value:y}=await i.next();if(g){o(),f.close();return}let v=y.byteLength;if(n){let w=s+=v;n(w)}f.enqueue(new Uint8Array(y))}catch(g){throw o(g),g}},cancel(f){return o(f),i.return()}},{highWaterMark:2})},Lf=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",Pw=Lf&&typeof ReadableStream=="function",CR=Lf&&(typeof TextEncoder=="function"?(t=>e=>t.encode(e))(new TextEncoder):async t=>new Uint8Array(await new Response(t).arrayBuffer())),Nw=(t,...e)=>{try{return!!t(...e)}catch{return!1}},TR=Pw&&Nw(()=>{let t=!1;const e=new Request(Gi.origin,{body:new ReadableStream,method:"POST",get duplex(){return t=!0,"half"}}).headers.has("Content-Type");return t&&!e}),Rw=64*1024,_0=Pw&&Nw(()=>Be.isReadableStream(new Response("").body)),Ff={stream:_0&&(t=>t.body)};Lf&&(t=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!Ff[e]&&(Ff[e]=Be.isFunction(t[e])?n=>n[e]():(n,r)=>{throw new on(`Response type '${e}' is not supported`,on.ERR_NOT_SUPPORT,r)})})})(new Response);const AR=async t=>{if(t==null)return 0;if(Be.isBlob(t))return t.size;if(Be.isSpecCompliantForm(t))return(await new Request(Gi.origin,{method:"POST",body:t}).arrayBuffer()).byteLength;if(Be.isArrayBufferView(t)||Be.isArrayBuffer(t))return t.byteLength;if(Be.isURLSearchParams(t)&&(t=t+""),Be.isString(t))return(await CR(t)).byteLength},MR=async(t,e)=>{const n=Be.toFiniteNumber(t.getContentLength());return n??AR(e)},x0={http:XN,xhr:vR,fetch:Lf&&(async t=>{let{url:e,method:n,data:r,signal:i,cancelToken:s,timeout:a,onDownloadProgress:o,onUploadProgress:f,responseType:g,headers:y,withCredentials:v="same-origin",fetchOptions:w}=Dw(t);g=g?(g+"").toLowerCase():"text";let T=wR([i,s&&s.toAbortSignal()],a),D;const O=T&&T.unsubscribe&&(()=>{T.unsubscribe()});let B;try{if(f&&TR&&n!=="get"&&n!=="head"&&(B=await MR(y,r))!==0){let ue=new Request(e,{method:"POST",body:r,duplex:"half"}),fe;if(Be.isFormData(r)&&(fe=ue.headers.get("content-type"))&&y.setContentType(fe),ue.body){const[be,Me]=Cw(B,zf(Tw(f)));r=Iw(ue.body,Rw,be,Me)}}Be.isString(v)||(v=v?"include":"omit");const L="credentials"in Request.prototype;D=new Request(e,{...w,signal:T,method:n.toUpperCase(),headers:y.normalize().toJSON(),body:r,duplex:"half",credentials:L?v:void 0});let U=await fetch(D);const Z=_0&&(g==="stream"||g==="response");if(_0&&(o||Z&&O)){const ue={};["status","statusText","headers"].forEach(ve=>{ue[ve]=U[ve]});const fe=Be.toFiniteNumber(U.headers.get("content-length")),[be,Me]=o&&Cw(fe,zf(Tw(o),!0))||[];U=new Response(Iw(U.body,Rw,be,()=>{Me&&Me(),O&&O()}),ue)}g=g||"text";let Y=await Ff[Be.findKey(Ff,g)||"text"](U,t);return!Z&&O&&O(),await new Promise((ue,fe)=>{Sw(ue,fe,{data:Y,headers:Yi.from(U.headers),status:U.status,statusText:U.statusText,config:t,request:D})})}catch(L){throw O&&O(),L&&L.name==="TypeError"&&/fetch/i.test(L.message)?Object.assign(new on("Network Error",on.ERR_NETWORK,t,D),{cause:L.cause||L}):on.from(L,L&&L.code,t,D)}})};Be.forEach(x0,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const Ow=t=>`- ${t}`,DR=t=>Be.isFunction(t)||t===null||t===!1,Bw={getAdapter:t=>{t=Be.isArray(t)?t:[t];const{length:e}=t;let n,r;const i={};for(let s=0;s<e;s++){n=t[s];let a;if(r=n,!DR(n)&&(r=x0[(a=String(n)).toLowerCase()],r===void 0))throw new on(`Unknown adapter '${a}'`);if(r)break;i[a||"#"+s]=r}if(!r){const s=Object.entries(i).map(([o,f])=>`adapter ${o} `+(f===!1?"is not supported by the environment":"is not available in the build"));let a=e?s.length>1?`since :
|
4
4
|
`+s.map(Ow).join(`
|
5
5
|
`):" "+Ow(s[0]):"as no adapter specified";throw new on("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return r},adapters:x0};function v0(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new id(null,t)}function Vw(t){return v0(t),t.headers=Yi.from(t.headers),t.data=b0.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),Bw.getAdapter(t.adapter||sh.adapter)(t).then(function(r){return v0(t),r.data=b0.call(t,t.transformResponse,r),r.headers=Yi.from(r.headers),r},function(r){return Ew(r)||(v0(t),r&&r.response&&(r.response.data=b0.call(t,t.transformResponse,r.response),r.response.headers=Yi.from(r.response.headers))),Promise.reject(r)})}const zw="1.7.7",w0={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{w0[t]=function(r){return typeof r===t||"a"+(e<1?"n ":" ")+t}});const Lw={};w0.transitional=function(e,n,r){function i(s,a){return"[Axios v"+zw+"] Transitional option '"+s+"'"+a+(r?". "+r:"")}return(s,a,o)=>{if(e===!1)throw new on(i(a," has been removed"+(n?" in "+n:"")),on.ERR_DEPRECATED);return n&&!Lw[a]&&(Lw[a]=!0,console.warn(i(a," has been deprecated since v"+n+" and will be removed in the near future"))),e?e(s,a,o):!0}};function IR(t,e,n){if(typeof t!="object")throw new on("options must be an object",on.ERR_BAD_OPTION_VALUE);const r=Object.keys(t);let i=r.length;for(;i-- >0;){const s=r[i],a=e[s];if(a){const o=t[s],f=o===void 0||a(o,s,t);if(f!==!0)throw new on("option "+s+" must be "+f,on.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new on("Unknown option "+s,on.ERR_BAD_OPTION)}}const k0={assertOptions:IR,validators:w0},Na=k0.validators;class Yl{constructor(e){this.defaults=e,this.interceptors={request:new xw,response:new xw}}async request(e,n){try{return await this._request(e,n)}catch(r){if(r instanceof Error){let i;Error.captureStackTrace?Error.captureStackTrace(i={}):i=new Error;const s=i.stack?i.stack.replace(/^.+\n/,""):"";try{r.stack?s&&!String(r.stack).endsWith(s.replace(/^.+\n.+\n/,""))&&(r.stack+=`
|
6
|
-
`+s):r.stack=s}catch{}}throw r}}_request(e,n){typeof e=="string"?(n=n||{},n.url=e):n=e||{},n=Gl(this.defaults,n);const{transitional:r,paramsSerializer:i,headers:s}=n;r!==void 0&&k0.assertOptions(r,{silentJSONParsing:Na.transitional(Na.boolean),forcedJSONParsing:Na.transitional(Na.boolean),clarifyTimeoutError:Na.transitional(Na.boolean)},!1),i!=null&&(Be.isFunction(i)?n.paramsSerializer={serialize:i}:k0.assertOptions(i,{encode:Na.function,serialize:Na.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let a=s&&Be.merge(s.common,s[n.method]);s&&Be.forEach(["delete","get","head","post","put","patch","common"],D=>{delete s[D]}),n.headers=Yi.concat(a,s);const o=[];let f=!0;this.interceptors.request.forEach(function(O){typeof O.runWhen=="function"&&O.runWhen(n)===!1||(f=f&&O.synchronous,o.unshift(O.fulfilled,O.rejected))});const g=[];this.interceptors.response.forEach(function(O){g.push(O.fulfilled,O.rejected)});let y,v=0,w;if(!f){const D=[Vw.bind(this),void 0];for(D.unshift.apply(D,o),D.push.apply(D,g),w=D.length,y=Promise.resolve(n);v<w;)y=y.then(D[v++],D[v++]);return y}w=o.length;let T=n;for(v=0;v<w;){const D=o[v++],O=o[v++];try{T=D(T)}catch(B){O.call(this,B);break}}try{y=Vw.call(this,T)}catch(D){return Promise.reject(D)}for(v=0,w=g.length;v<w;)y=y.then(g[v++],g[v++]);return y}getUri(e){e=Gl(this.defaults,e);const n=Aw(e.baseURL,e.url);return _w(n,e.params,e.paramsSerializer)}}Be.forEach(["delete","get","head","options"],function(e){Yl.prototype[e]=function(n,r){return this.request(Gl(r||{},{method:e,url:n,data:(r||{}).data}))}}),Be.forEach(["post","put","patch"],function(e){function n(r){return function(s,a,o){return this.request(Gl(o||{},{method:e,headers:r?{"Content-Type":"multipart/form-data"}:{},url:s,data:a}))}}Yl.prototype[e]=n(),Yl.prototype[e+"Form"]=n(!0)});class E0{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(s){n=s});const r=this;this.promise.then(i=>{if(!r._listeners)return;let s=r._listeners.length;for(;s-- >0;)r._listeners[s](i);r._listeners=null}),this.promise.then=i=>{let s;const a=new Promise(o=>{r.subscribe(o),s=o}).then(i);return a.cancel=function(){r.unsubscribe(s)},a},e(function(s,a,o){r.reason||(r.reason=new id(s,a,o),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const n=this._listeners.indexOf(e);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const e=new AbortController,n=r=>{e.abort(r)};return this.subscribe(n),e.signal.unsubscribe=()=>this.unsubscribe(n),e.signal}static source(){let e;return{token:new E0(function(i){e=i}),cancel:e}}}function PR(t){return function(n){return t.apply(null,n)}}function NR(t){return Be.isObject(t)&&t.isAxiosError===!0}const S0={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(S0).forEach(([t,e])=>{S0[e]=t});function Fw(t){const e=new Yl(t),n=rw(Yl.prototype.request,e);return Be.extend(n,Yl.prototype,e,{allOwnKeys:!0}),Be.extend(n,e,null,{allOwnKeys:!0}),n.create=function(i){return Fw(Gl(t,i))},n}const Ue=Fw(sh);Ue.Axios=Yl,Ue.CanceledError=id,Ue.CancelToken=E0,Ue.isCancel=Ew,Ue.VERSION=zw,Ue.toFormData=Bf,Ue.AxiosError=on,Ue.Cancel=Ue.CanceledError,Ue.all=function(e){return Promise.all(e)},Ue.spread=PR,Ue.isAxiosError=NR,Ue.mergeConfig=Gl,Ue.AxiosHeaders=Yi,Ue.formToJSON=t=>ww(Be.isHTMLForm(t)?new FormData(t):t),Ue.getAdapter=Bw.getAdapter,Ue.HttpStatusCode=S0,Ue.default=Ue;const it=d.ref({}),RR=()=>{const t=new CustomEvent("reloadTablePage");window.dispatchEvent(t)},$f=()=>{const t=new CustomEvent("reloadCardPage");window.dispatchEvent(t)},OR={class:"p-[10px]"},BR={class:"flex justify-end p-[20px] gap-[10px] border-t w-full"},VR=["onClick"],zR=["disabled"],LR={__name:"vs-plugin-form",props:{handleClose:Function},setup(t){var v;const{$notify:e=()=>1}=(v=d.getCurrentInstance())==null?void 0:v.proxy,n=d.ref(!1),r=d.ref(null);let i=d.ref(!1);const s=d.ref({}),a=d.ref(),o=d.ref({}),f=w=>{n.value=!1,r.value=null,s.value={},o.value={};const T=new CustomEvent("closeFormPlugin");T.message=w,window.dispatchEvent(T)},g=async()=>{var w,T,D,O,B,L,U,Z,Y,ue,fe;try{if(((w=o.value)==null?void 0:w.method)!=="POST"){const Me=await Ue.get(`${((T=o.value)==null?void 0:T.api)||"/api/table/"}${((D=o.value)==null?void 0:D.token)||((O=o.value)==null?void 0:O.id)||""}`);s.value=Me.data}(B=o.value)!=null&&B.init&&(s.value=(L=o.value)==null?void 0:L.init);const{data:be}=await Ue.get(`/api/template/form/${((U=o.value)==null?void 0:U.token)||((Z=o.value)==null?void 0:Z.form)}`);if(be!=null&&be.obj&&(s.value={...s.value,...be.obj}),(Y=o.value)!=null&&Y.obj){const Me=(fe=(ue=o.value)==null?void 0:ue.obj)==null?void 0:fe.split("#"),ve=Me==null?void 0:Me.reduce((Oe,je)=>{const[He,qe]=je==null?void 0:je.split("=");return Oe[He]=qe,Oe},{});s.value={...s.value,...ve}}r.value=(be==null?void 0:be.schema)||be}catch(be){console.error("Error fetching form scheme:",be)}finally{n.value=!0}},y=async()=>{var w,T,D,O,B;i=!0;try{await a.value.doValidation();const{data:L}=await Ue({method:((w=o.value)==null?void 0:w.method)||"PUT",url:`${((T=o.value)==null?void 0:T.api)||"/api/table/"}${((D=o.value)==null?void 0:D.token)||((O=o.value)==null?void 0:O.id)||""}`,data:s.value});$f(),RR(),f(L),e({title:"Успішно!",type:"success",message:"Операція виконана успішно"})}catch(L){e({title:"Помилка!",type:"error",message:L.message==="validation error"?"Перевірте правильність полів.":((B=L==null?void 0:L.response)==null?void 0:B.data)||"Сталася помилка"})}finally{i=!1}};return d.onMounted(()=>{window.addEventListener("openFormPlugin",({options:w})=>{o.value=w,n.value=!0,g()})}),(w,T)=>{var B;const D=d.resolveComponent("VsForm"),O=d.resolveComponent("VsDialog");return r.value?(d.openBlock(),d.createBlock(O,{key:0,title:((B=o.value)==null?void 0:B.title)||"Редагувати",visible:n.value,"onUpdate:visible":T[1]||(T[1]=L=>n.value=L),onOnClose:f},{footer:d.withCtx(({handleClose:L})=>[d.createElementVNode("div",BR,[d.createElementVNode("button",{style:{border:"1px solid #000"},onClick:U=>L(),class:"py-2 px-3 inline-flex items-center gap-x-2 text-sm whitespace-nowrap text-black border-gray-200 rounded-lg !border-gray-200 hover:bg-gray-100 duration-300"}," Скасувати ",8,VR),d.createElementVNode("button",{disabled:d.unref(i),onClick:y,class:"py-2 px-3 inline-flex items-center gap-x-2 text-[14px] font-[400] whitespace-nowrap text-white bg-blue-500 rounded-lg !border-gray-200 hover:bg-blue-700"}," Зберегти ",8,zR)])]),default:d.withCtx(()=>[d.createElementVNode("div",OR,[d.createVNode(D,{ref_key:"form",ref:a,scheme:r.value,modelValue:s.value,"onUpdate:modelValue":T[0]||(T[0]=L=>s.value=L),class:"p-0"},null,8,["scheme","modelValue"])])]),_:1},8,["title","visible"])):d.createCommentVNode("",!0)}}},FR={__name:"admin",setup(t){var n,r;document.title=((n=it.value)==null?void 0:n.titlePrefix)||""+((r=it.value)==null?void 0:r.title)||"",e(it.value.favicon);function e(i){let s=document.querySelector("link[rel~='icon']");s||(s=document.createElement("link"),s.rel="icon",document.getElementsByTagName("head")[0].appendChild(s)),s.href=i}return(i,s)=>{const a=d.resolveComponent("router-view");return d.openBlock(),d.createElementBlock(d.Fragment,null,[d.createVNode(a),d.createVNode(LR)],64)}}};function $R(){return $w().__VUE_DEVTOOLS_GLOBAL_HOOK__}function $w(){return typeof navigator<"u"&&typeof window<"u"?window:typeof globalThis<"u"?globalThis:{}}const jR=typeof Proxy=="function",HR="devtools-plugin:setup",UR="plugin:settings:set";let sd,C0;function WR(){var t;return sd!==void 0||(typeof window<"u"&&window.performance?(sd=!0,C0=window.performance):typeof globalThis<"u"&&(!((t=globalThis.perf_hooks)===null||t===void 0)&&t.performance)?(sd=!0,C0=globalThis.perf_hooks.performance):sd=!1),sd}function qR(){return WR()?C0.now():Date.now()}class GR{constructor(e,n){this.target=null,this.targetQueue=[],this.onQueue=[],this.plugin=e,this.hook=n;const r={};if(e.settings)for(const a in e.settings){const o=e.settings[a];r[a]=o.defaultValue}const i=`__vue-devtools-plugin-settings__${e.id}`;let s=Object.assign({},r);try{const a=localStorage.getItem(i),o=JSON.parse(a);Object.assign(s,o)}catch{}this.fallbacks={getSettings(){return s},setSettings(a){try{localStorage.setItem(i,JSON.stringify(a))}catch{}s=a},now(){return qR()}},n&&n.on(UR,(a,o)=>{a===this.plugin.id&&this.fallbacks.setSettings(o)}),this.proxiedOn=new Proxy({},{get:(a,o)=>this.target?this.target.on[o]:(...f)=>{this.onQueue.push({method:o,args:f})}}),this.proxiedTarget=new Proxy({},{get:(a,o)=>this.target?this.target[o]:o==="on"?this.proxiedOn:Object.keys(this.fallbacks).includes(o)?(...f)=>(this.targetQueue.push({method:o,args:f,resolve:()=>{}}),this.fallbacks[o](...f)):(...f)=>new Promise(g=>{this.targetQueue.push({method:o,args:f,resolve:g})})})}async setRealTarget(e){this.target=e;for(const n of this.onQueue)this.target.on[n.method](...n.args);for(const n of this.targetQueue)n.resolve(await this.target[n.method](...n.args))}}function YR(t,e){const n=t,r=$w(),i=$R(),s=jR&&n.enableEarlyProxy;if(i&&(r.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__||!s))i.emit(HR,t,e);else{const a=s?new GR(n,i):null;(r.__VUE_DEVTOOLS_PLUGINS__=r.__VUE_DEVTOOLS_PLUGINS__||[]).push({pluginDescriptor:n,setupFn:e,proxy:a}),a&&e(a.proxiedTarget)}}var Jt={};const Uo=typeof document<"u";function jw(t){return typeof t=="object"||"displayName"in t||"props"in t||"__vccOpts"in t}function ZR(t){return t.__esModule||t[Symbol.toStringTag]==="Module"||t.default&&jw(t.default)}const zn=Object.assign;function T0(t,e){const n={};for(const r in e){const i=e[r];n[r]=ps(i)?i.map(t):t(i)}return n}const ah=()=>{},ps=Array.isArray;function fn(t){const e=Array.from(arguments).slice(1);console.warn.apply(console,["[Vue Router warn]: "+t].concat(e))}const Hw=/#/g,XR=/&/g,KR=/\//g,JR=/=/g,QR=/\?/g,Uw=/\+/g,eO=/%5B/g,tO=/%5D/g,Ww=/%5E/g,nO=/%60/g,qw=/%7B/g,rO=/%7C/g,Gw=/%7D/g,iO=/%20/g;function A0(t){return encodeURI(""+t).replace(rO,"|").replace(eO,"[").replace(tO,"]")}function sO(t){return A0(t).replace(qw,"{").replace(Gw,"}").replace(Ww,"^")}function M0(t){return A0(t).replace(Uw,"%2B").replace(iO,"+").replace(Hw,"%23").replace(XR,"%26").replace(nO,"`").replace(qw,"{").replace(Gw,"}").replace(Ww,"^")}function oO(t){return M0(t).replace(JR,"%3D")}function aO(t){return A0(t).replace(Hw,"%23").replace(QR,"%3F")}function lO(t){return t==null?"":aO(t).replace(KR,"%2F")}function od(t){try{return decodeURIComponent(""+t)}catch{Jt.NODE_ENV!=="production"&&fn(`Error decoding "${t}". Using original value`)}return""+t}const cO=/\/$/,dO=t=>t.replace(cO,"");function D0(t,e,n="/"){let r,i={},s="",a="";const o=e.indexOf("#");let f=e.indexOf("?");return o<f&&o>=0&&(f=-1),f>-1&&(r=e.slice(0,f),s=e.slice(f+1,o>-1?o:e.length),i=t(s)),o>-1&&(r=r||e.slice(0,o),a=e.slice(o,e.length)),r=pO(r??e,n),{fullPath:r+(s&&"?")+s+a,path:r,query:i,hash:od(a)}}function uO(t,e){const n=e.query?t(e.query):"";return e.path+(n&&"?")+n+(e.hash||"")}function Yw(t,e){return!e||!t.toLowerCase().startsWith(e.toLowerCase())?t:t.slice(e.length)||"/"}function Zw(t,e,n){const r=e.matched.length-1,i=n.matched.length-1;return r>-1&&r===i&&Ra(e.matched[r],n.matched[i])&&Xw(e.params,n.params)&&t(e.query)===t(n.query)&&e.hash===n.hash}function Ra(t,e){return(t.aliasOf||t)===(e.aliasOf||e)}function Xw(t,e){if(Object.keys(t).length!==Object.keys(e).length)return!1;for(const n in t)if(!hO(t[n],e[n]))return!1;return!0}function hO(t,e){return ps(t)?Kw(t,e):ps(e)?Kw(e,t):t===e}function Kw(t,e){return ps(e)?t.length===e.length&&t.every((n,r)=>n===e[r]):t.length===1&&t[0]===e}function pO(t,e){if(t.startsWith("/"))return t;if(Jt.NODE_ENV!=="production"&&!e.startsWith("/"))return fn(`Cannot resolve a relative location without an absolute path. Trying to resolve "${t}" from "${e}". It should look like "/${e}".`),t;if(!t)return e;const n=e.split("/"),r=t.split("/"),i=r[r.length-1];(i===".."||i===".")&&r.push("");let s=n.length-1,a,o;for(a=0;a<r.length;a++)if(o=r[a],o!==".")if(o==="..")s>1&&s--;else break;return n.slice(0,s).join("/")+"/"+r.slice(a).join("/")}const Oa={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0};var lh;(function(t){t.pop="pop",t.push="push"})(lh||(lh={}));var ch;(function(t){t.back="back",t.forward="forward",t.unknown=""})(ch||(ch={}));function fO(t){if(!t)if(Uo){const e=document.querySelector("base");t=e&&e.getAttribute("href")||"/",t=t.replace(/^\w+:\/\/[^\/]+/,"")}else t="/";return t[0]!=="/"&&t[0]!=="#"&&(t="/"+t),dO(t)}const mO=/^[^#]+#/;function gO(t,e){return t.replace(mO,"#")+e}function yO(t,e){const n=document.documentElement.getBoundingClientRect(),r=t.getBoundingClientRect();return{behavior:e.behavior,left:r.left-n.left-(e.left||0),top:r.top-n.top-(e.top||0)}}const jf=()=>({left:window.scrollX,top:window.scrollY});function bO(t){let e;if("el"in t){const n=t.el,r=typeof n=="string"&&n.startsWith("#");if(Jt.NODE_ENV!=="production"&&typeof t.el=="string"&&(!r||!document.getElementById(t.el.slice(1))))try{const s=document.querySelector(t.el);if(r&&s){fn(`The selector "${t.el}" should be passed as "el: document.querySelector('${t.el}')" because it starts with "#".`);return}}catch{fn(`The selector "${t.el}" is invalid. If you are using an id selector, make sure to escape it. You can find more information about escaping characters in selectors at https://mathiasbynens.be/notes/css-escapes or use CSS.escape (https://developer.mozilla.org/en-US/docs/Web/API/CSS/escape).`);return}const i=typeof n=="string"?r?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!i){Jt.NODE_ENV!=="production"&&fn(`Couldn't find element using selector "${t.el}" returned by scrollBehavior.`);return}e=yO(i,t)}else e=t;"scrollBehavior"in document.documentElement.style?window.scrollTo(e):window.scrollTo(e.left!=null?e.left:window.scrollX,e.top!=null?e.top:window.scrollY)}function Jw(t,e){return(history.state?history.state.position-e:-1)+t}const I0=new Map;function _O(t,e){I0.set(t,e)}function xO(t){const e=I0.get(t);return I0.delete(t),e}let vO=()=>location.protocol+"//"+location.host;function Qw(t,e){const{pathname:n,search:r,hash:i}=e,s=t.indexOf("#");if(s>-1){let o=i.includes(t.slice(s))?t.slice(s).length:1,f=i.slice(o);return f[0]!=="/"&&(f="/"+f),Yw(f,"")}return Yw(n,t)+r+i}function wO(t,e,n,r){let i=[],s=[],a=null;const o=({state:w})=>{const T=Qw(t,location),D=n.value,O=e.value;let B=0;if(w){if(n.value=T,e.value=w,a&&a===D){a=null;return}B=O?w.position-O.position:0}else r(T);i.forEach(L=>{L(n.value,D,{delta:B,type:lh.pop,direction:B?B>0?ch.forward:ch.back:ch.unknown})})};function f(){a=n.value}function g(w){i.push(w);const T=()=>{const D=i.indexOf(w);D>-1&&i.splice(D,1)};return s.push(T),T}function y(){const{history:w}=window;w.state&&w.replaceState(zn({},w.state,{scroll:jf()}),"")}function v(){for(const w of s)w();s=[],window.removeEventListener("popstate",o),window.removeEventListener("beforeunload",y)}return window.addEventListener("popstate",o),window.addEventListener("beforeunload",y,{passive:!0}),{pauseListeners:f,listen:g,destroy:v}}function ek(t,e,n,r=!1,i=!1){return{back:t,current:e,forward:n,replaced:r,position:window.history.length,scroll:i?jf():null}}function kO(t){const{history:e,location:n}=window,r={value:Qw(t,n)},i={value:e.state};i.value||s(r.value,{back:null,current:r.value,forward:null,position:e.length-1,replaced:!0,scroll:null},!0);function s(f,g,y){const v=t.indexOf("#"),w=v>-1?(n.host&&document.querySelector("base")?t:t.slice(v))+f:vO()+t+f;try{e[y?"replaceState":"pushState"](g,"",w),i.value=g}catch(T){Jt.NODE_ENV!=="production"?fn("Error with push/replace State",T):console.error(T),n[y?"replace":"assign"](w)}}function a(f,g){const y=zn({},e.state,ek(i.value.back,f,i.value.forward,!0),g,{position:i.value.position});s(f,y,!0),r.value=f}function o(f,g){const y=zn({},i.value,e.state,{forward:f,scroll:jf()});Jt.NODE_ENV!=="production"&&!e.state&&fn(`history.state seems to have been manually replaced without preserving the necessary values. Make sure to preserve existing history state if you are manually calling history.replaceState:
|
6
|
+
`+s):r.stack=s}catch{}}throw r}}_request(e,n){typeof e=="string"?(n=n||{},n.url=e):n=e||{},n=Gl(this.defaults,n);const{transitional:r,paramsSerializer:i,headers:s}=n;r!==void 0&&k0.assertOptions(r,{silentJSONParsing:Na.transitional(Na.boolean),forcedJSONParsing:Na.transitional(Na.boolean),clarifyTimeoutError:Na.transitional(Na.boolean)},!1),i!=null&&(Be.isFunction(i)?n.paramsSerializer={serialize:i}:k0.assertOptions(i,{encode:Na.function,serialize:Na.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let a=s&&Be.merge(s.common,s[n.method]);s&&Be.forEach(["delete","get","head","post","put","patch","common"],D=>{delete s[D]}),n.headers=Yi.concat(a,s);const o=[];let f=!0;this.interceptors.request.forEach(function(O){typeof O.runWhen=="function"&&O.runWhen(n)===!1||(f=f&&O.synchronous,o.unshift(O.fulfilled,O.rejected))});const g=[];this.interceptors.response.forEach(function(O){g.push(O.fulfilled,O.rejected)});let y,v=0,w;if(!f){const D=[Vw.bind(this),void 0];for(D.unshift.apply(D,o),D.push.apply(D,g),w=D.length,y=Promise.resolve(n);v<w;)y=y.then(D[v++],D[v++]);return y}w=o.length;let T=n;for(v=0;v<w;){const D=o[v++],O=o[v++];try{T=D(T)}catch(B){O.call(this,B);break}}try{y=Vw.call(this,T)}catch(D){return Promise.reject(D)}for(v=0,w=g.length;v<w;)y=y.then(g[v++],g[v++]);return y}getUri(e){e=Gl(this.defaults,e);const n=Aw(e.baseURL,e.url);return _w(n,e.params,e.paramsSerializer)}}Be.forEach(["delete","get","head","options"],function(e){Yl.prototype[e]=function(n,r){return this.request(Gl(r||{},{method:e,url:n,data:(r||{}).data}))}}),Be.forEach(["post","put","patch"],function(e){function n(r){return function(s,a,o){return this.request(Gl(o||{},{method:e,headers:r?{"Content-Type":"multipart/form-data"}:{},url:s,data:a}))}}Yl.prototype[e]=n(),Yl.prototype[e+"Form"]=n(!0)});class E0{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(s){n=s});const r=this;this.promise.then(i=>{if(!r._listeners)return;let s=r._listeners.length;for(;s-- >0;)r._listeners[s](i);r._listeners=null}),this.promise.then=i=>{let s;const a=new Promise(o=>{r.subscribe(o),s=o}).then(i);return a.cancel=function(){r.unsubscribe(s)},a},e(function(s,a,o){r.reason||(r.reason=new id(s,a,o),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const n=this._listeners.indexOf(e);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const e=new AbortController,n=r=>{e.abort(r)};return this.subscribe(n),e.signal.unsubscribe=()=>this.unsubscribe(n),e.signal}static source(){let e;return{token:new E0(function(i){e=i}),cancel:e}}}function PR(t){return function(n){return t.apply(null,n)}}function NR(t){return Be.isObject(t)&&t.isAxiosError===!0}const S0={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(S0).forEach(([t,e])=>{S0[e]=t});function Fw(t){const e=new Yl(t),n=rw(Yl.prototype.request,e);return Be.extend(n,Yl.prototype,e,{allOwnKeys:!0}),Be.extend(n,e,null,{allOwnKeys:!0}),n.create=function(i){return Fw(Gl(t,i))},n}const Ue=Fw(sh);Ue.Axios=Yl,Ue.CanceledError=id,Ue.CancelToken=E0,Ue.isCancel=Ew,Ue.VERSION=zw,Ue.toFormData=Bf,Ue.AxiosError=on,Ue.Cancel=Ue.CanceledError,Ue.all=function(e){return Promise.all(e)},Ue.spread=PR,Ue.isAxiosError=NR,Ue.mergeConfig=Gl,Ue.AxiosHeaders=Yi,Ue.formToJSON=t=>ww(Be.isHTMLForm(t)?new FormData(t):t),Ue.getAdapter=Bw.getAdapter,Ue.HttpStatusCode=S0,Ue.default=Ue;const it=d.ref({}),RR=()=>{const t=new CustomEvent("reloadTablePage");window.dispatchEvent(t)},$f=()=>{const t=new CustomEvent("reloadCardPage");window.dispatchEvent(t)},OR={class:"p-[10px]"},BR={class:"flex justify-end p-[20px] gap-[10px] border-t w-full"},VR=["onClick"],zR=["disabled"],LR={__name:"vs-plugin-form",props:{handleClose:Function},setup(t){var v;const{$notify:e=()=>1}=(v=d.getCurrentInstance())==null?void 0:v.proxy,n=d.ref(!1),r=d.ref(null),i=d.ref(!1),s=d.ref({}),a=d.ref(),o=d.ref({}),f=w=>{n.value=!1,r.value=null,s.value={},o.value={};const T=new CustomEvent("closeFormPlugin");T.message=w,window.dispatchEvent(T)},g=async()=>{var w,T,D,O,B,L,U,Z,Y,ue,fe;try{if(((w=o.value)==null?void 0:w.method)!=="POST"){const Me=await Ue.get(`${((T=o.value)==null?void 0:T.api)||"/api/table/"}${((D=o.value)==null?void 0:D.token)||((O=o.value)==null?void 0:O.id)||""}`);s.value=Me.data}(B=o.value)!=null&&B.init&&(s.value=(L=o.value)==null?void 0:L.init);const{data:be}=await Ue.get(`/api/template/form/${((U=o.value)==null?void 0:U.token)||((Z=o.value)==null?void 0:Z.form)}`);if(be!=null&&be.obj&&(s.value={...s.value,...be.obj}),(Y=o.value)!=null&&Y.obj){const Me=(fe=(ue=o.value)==null?void 0:ue.obj)==null?void 0:fe.split("#"),ve=Me==null?void 0:Me.reduce((Oe,je)=>{const[He,qe]=je==null?void 0:je.split("=");return Oe[He]=qe,Oe},{});s.value={...s.value,...ve}}r.value=(be==null?void 0:be.schema)||be}catch(be){console.error("Error fetching form scheme:",be)}finally{n.value=!0}},y=async()=>{var w,T,D,O,B;if(!i.value){i.value=!0;try{await a.value.doValidation();const{data:L}=await Ue({method:((w=o.value)==null?void 0:w.method)||"PUT",url:`${((T=o.value)==null?void 0:T.api)||"/api/table/"}${((D=o.value)==null?void 0:D.token)||((O=o.value)==null?void 0:O.id)||""}`,data:s.value});$f(),RR(),f(L),e({title:"Успішно!",type:"success",message:"Операція виконана успішно"})}catch(L){e({title:"Помилка!",type:"error",message:L.message==="validation error"?"Перевірте правильність полів.":((B=L==null?void 0:L.response)==null?void 0:B.data)||"Сталася помилка"})}finally{i.value=!1}}};return d.onMounted(()=>{window.addEventListener("openFormPlugin",({options:w})=>{o.value=w,n.value=!0,g()})}),(w,T)=>{var B;const D=d.resolveComponent("VsForm"),O=d.resolveComponent("VsDialog");return r.value?(d.openBlock(),d.createBlock(O,{key:0,title:((B=o.value)==null?void 0:B.title)||"Редагувати",visible:n.value,"onUpdate:visible":T[1]||(T[1]=L=>n.value=L),onOnClose:f},{footer:d.withCtx(({handleClose:L})=>[d.createElementVNode("div",BR,[d.createElementVNode("button",{style:{border:"1px solid #000"},onClick:U=>L(),class:"py-2 px-3 inline-flex items-center gap-x-2 text-sm whitespace-nowrap text-black border-gray-200 rounded-lg !border-gray-200 hover:bg-gray-100 duration-300"}," Скасувати ",8,VR),d.createElementVNode("button",{disabled:i.value,onClick:y,class:"py-2 px-3 inline-flex items-center gap-x-2 text-[14px] font-[400] whitespace-nowrap text-white bg-blue-500 rounded-lg !border-gray-200 hover:bg-blue-700"}," Зберегти ",8,zR)])]),default:d.withCtx(()=>[d.createElementVNode("div",OR,[d.createVNode(D,{ref_key:"form",ref:a,scheme:r.value,modelValue:s.value,"onUpdate:modelValue":T[0]||(T[0]=L=>s.value=L),class:"p-0"},null,8,["scheme","modelValue"])])]),_:1},8,["title","visible"])):d.createCommentVNode("",!0)}}},FR={__name:"admin",setup(t){var n,r;document.title=((n=it.value)==null?void 0:n.titlePrefix)||""+((r=it.value)==null?void 0:r.title)||"",e(it.value.favicon);function e(i){let s=document.querySelector("link[rel~='icon']");s||(s=document.createElement("link"),s.rel="icon",document.getElementsByTagName("head")[0].appendChild(s)),s.href=i}return(i,s)=>{const a=d.resolveComponent("router-view");return d.openBlock(),d.createElementBlock(d.Fragment,null,[d.createVNode(a),d.createVNode(LR)],64)}}};function $R(){return $w().__VUE_DEVTOOLS_GLOBAL_HOOK__}function $w(){return typeof navigator<"u"&&typeof window<"u"?window:typeof globalThis<"u"?globalThis:{}}const jR=typeof Proxy=="function",HR="devtools-plugin:setup",UR="plugin:settings:set";let sd,C0;function WR(){var t;return sd!==void 0||(typeof window<"u"&&window.performance?(sd=!0,C0=window.performance):typeof globalThis<"u"&&(!((t=globalThis.perf_hooks)===null||t===void 0)&&t.performance)?(sd=!0,C0=globalThis.perf_hooks.performance):sd=!1),sd}function qR(){return WR()?C0.now():Date.now()}class GR{constructor(e,n){this.target=null,this.targetQueue=[],this.onQueue=[],this.plugin=e,this.hook=n;const r={};if(e.settings)for(const a in e.settings){const o=e.settings[a];r[a]=o.defaultValue}const i=`__vue-devtools-plugin-settings__${e.id}`;let s=Object.assign({},r);try{const a=localStorage.getItem(i),o=JSON.parse(a);Object.assign(s,o)}catch{}this.fallbacks={getSettings(){return s},setSettings(a){try{localStorage.setItem(i,JSON.stringify(a))}catch{}s=a},now(){return qR()}},n&&n.on(UR,(a,o)=>{a===this.plugin.id&&this.fallbacks.setSettings(o)}),this.proxiedOn=new Proxy({},{get:(a,o)=>this.target?this.target.on[o]:(...f)=>{this.onQueue.push({method:o,args:f})}}),this.proxiedTarget=new Proxy({},{get:(a,o)=>this.target?this.target[o]:o==="on"?this.proxiedOn:Object.keys(this.fallbacks).includes(o)?(...f)=>(this.targetQueue.push({method:o,args:f,resolve:()=>{}}),this.fallbacks[o](...f)):(...f)=>new Promise(g=>{this.targetQueue.push({method:o,args:f,resolve:g})})})}async setRealTarget(e){this.target=e;for(const n of this.onQueue)this.target.on[n.method](...n.args);for(const n of this.targetQueue)n.resolve(await this.target[n.method](...n.args))}}function YR(t,e){const n=t,r=$w(),i=$R(),s=jR&&n.enableEarlyProxy;if(i&&(r.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__||!s))i.emit(HR,t,e);else{const a=s?new GR(n,i):null;(r.__VUE_DEVTOOLS_PLUGINS__=r.__VUE_DEVTOOLS_PLUGINS__||[]).push({pluginDescriptor:n,setupFn:e,proxy:a}),a&&e(a.proxiedTarget)}}var Jt={};const Uo=typeof document<"u";function jw(t){return typeof t=="object"||"displayName"in t||"props"in t||"__vccOpts"in t}function ZR(t){return t.__esModule||t[Symbol.toStringTag]==="Module"||t.default&&jw(t.default)}const zn=Object.assign;function T0(t,e){const n={};for(const r in e){const i=e[r];n[r]=ps(i)?i.map(t):t(i)}return n}const ah=()=>{},ps=Array.isArray;function fn(t){const e=Array.from(arguments).slice(1);console.warn.apply(console,["[Vue Router warn]: "+t].concat(e))}const Hw=/#/g,XR=/&/g,KR=/\//g,JR=/=/g,QR=/\?/g,Uw=/\+/g,eO=/%5B/g,tO=/%5D/g,Ww=/%5E/g,nO=/%60/g,qw=/%7B/g,rO=/%7C/g,Gw=/%7D/g,iO=/%20/g;function A0(t){return encodeURI(""+t).replace(rO,"|").replace(eO,"[").replace(tO,"]")}function sO(t){return A0(t).replace(qw,"{").replace(Gw,"}").replace(Ww,"^")}function M0(t){return A0(t).replace(Uw,"%2B").replace(iO,"+").replace(Hw,"%23").replace(XR,"%26").replace(nO,"`").replace(qw,"{").replace(Gw,"}").replace(Ww,"^")}function oO(t){return M0(t).replace(JR,"%3D")}function aO(t){return A0(t).replace(Hw,"%23").replace(QR,"%3F")}function lO(t){return t==null?"":aO(t).replace(KR,"%2F")}function od(t){try{return decodeURIComponent(""+t)}catch{Jt.NODE_ENV!=="production"&&fn(`Error decoding "${t}". Using original value`)}return""+t}const cO=/\/$/,dO=t=>t.replace(cO,"");function D0(t,e,n="/"){let r,i={},s="",a="";const o=e.indexOf("#");let f=e.indexOf("?");return o<f&&o>=0&&(f=-1),f>-1&&(r=e.slice(0,f),s=e.slice(f+1,o>-1?o:e.length),i=t(s)),o>-1&&(r=r||e.slice(0,o),a=e.slice(o,e.length)),r=pO(r??e,n),{fullPath:r+(s&&"?")+s+a,path:r,query:i,hash:od(a)}}function uO(t,e){const n=e.query?t(e.query):"";return e.path+(n&&"?")+n+(e.hash||"")}function Yw(t,e){return!e||!t.toLowerCase().startsWith(e.toLowerCase())?t:t.slice(e.length)||"/"}function Zw(t,e,n){const r=e.matched.length-1,i=n.matched.length-1;return r>-1&&r===i&&Ra(e.matched[r],n.matched[i])&&Xw(e.params,n.params)&&t(e.query)===t(n.query)&&e.hash===n.hash}function Ra(t,e){return(t.aliasOf||t)===(e.aliasOf||e)}function Xw(t,e){if(Object.keys(t).length!==Object.keys(e).length)return!1;for(const n in t)if(!hO(t[n],e[n]))return!1;return!0}function hO(t,e){return ps(t)?Kw(t,e):ps(e)?Kw(e,t):t===e}function Kw(t,e){return ps(e)?t.length===e.length&&t.every((n,r)=>n===e[r]):t.length===1&&t[0]===e}function pO(t,e){if(t.startsWith("/"))return t;if(Jt.NODE_ENV!=="production"&&!e.startsWith("/"))return fn(`Cannot resolve a relative location without an absolute path. Trying to resolve "${t}" from "${e}". It should look like "/${e}".`),t;if(!t)return e;const n=e.split("/"),r=t.split("/"),i=r[r.length-1];(i===".."||i===".")&&r.push("");let s=n.length-1,a,o;for(a=0;a<r.length;a++)if(o=r[a],o!==".")if(o==="..")s>1&&s--;else break;return n.slice(0,s).join("/")+"/"+r.slice(a).join("/")}const Oa={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0};var lh;(function(t){t.pop="pop",t.push="push"})(lh||(lh={}));var ch;(function(t){t.back="back",t.forward="forward",t.unknown=""})(ch||(ch={}));function fO(t){if(!t)if(Uo){const e=document.querySelector("base");t=e&&e.getAttribute("href")||"/",t=t.replace(/^\w+:\/\/[^\/]+/,"")}else t="/";return t[0]!=="/"&&t[0]!=="#"&&(t="/"+t),dO(t)}const mO=/^[^#]+#/;function gO(t,e){return t.replace(mO,"#")+e}function yO(t,e){const n=document.documentElement.getBoundingClientRect(),r=t.getBoundingClientRect();return{behavior:e.behavior,left:r.left-n.left-(e.left||0),top:r.top-n.top-(e.top||0)}}const jf=()=>({left:window.scrollX,top:window.scrollY});function bO(t){let e;if("el"in t){const n=t.el,r=typeof n=="string"&&n.startsWith("#");if(Jt.NODE_ENV!=="production"&&typeof t.el=="string"&&(!r||!document.getElementById(t.el.slice(1))))try{const s=document.querySelector(t.el);if(r&&s){fn(`The selector "${t.el}" should be passed as "el: document.querySelector('${t.el}')" because it starts with "#".`);return}}catch{fn(`The selector "${t.el}" is invalid. If you are using an id selector, make sure to escape it. You can find more information about escaping characters in selectors at https://mathiasbynens.be/notes/css-escapes or use CSS.escape (https://developer.mozilla.org/en-US/docs/Web/API/CSS/escape).`);return}const i=typeof n=="string"?r?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!i){Jt.NODE_ENV!=="production"&&fn(`Couldn't find element using selector "${t.el}" returned by scrollBehavior.`);return}e=yO(i,t)}else e=t;"scrollBehavior"in document.documentElement.style?window.scrollTo(e):window.scrollTo(e.left!=null?e.left:window.scrollX,e.top!=null?e.top:window.scrollY)}function Jw(t,e){return(history.state?history.state.position-e:-1)+t}const I0=new Map;function _O(t,e){I0.set(t,e)}function xO(t){const e=I0.get(t);return I0.delete(t),e}let vO=()=>location.protocol+"//"+location.host;function Qw(t,e){const{pathname:n,search:r,hash:i}=e,s=t.indexOf("#");if(s>-1){let o=i.includes(t.slice(s))?t.slice(s).length:1,f=i.slice(o);return f[0]!=="/"&&(f="/"+f),Yw(f,"")}return Yw(n,t)+r+i}function wO(t,e,n,r){let i=[],s=[],a=null;const o=({state:w})=>{const T=Qw(t,location),D=n.value,O=e.value;let B=0;if(w){if(n.value=T,e.value=w,a&&a===D){a=null;return}B=O?w.position-O.position:0}else r(T);i.forEach(L=>{L(n.value,D,{delta:B,type:lh.pop,direction:B?B>0?ch.forward:ch.back:ch.unknown})})};function f(){a=n.value}function g(w){i.push(w);const T=()=>{const D=i.indexOf(w);D>-1&&i.splice(D,1)};return s.push(T),T}function y(){const{history:w}=window;w.state&&w.replaceState(zn({},w.state,{scroll:jf()}),"")}function v(){for(const w of s)w();s=[],window.removeEventListener("popstate",o),window.removeEventListener("beforeunload",y)}return window.addEventListener("popstate",o),window.addEventListener("beforeunload",y,{passive:!0}),{pauseListeners:f,listen:g,destroy:v}}function ek(t,e,n,r=!1,i=!1){return{back:t,current:e,forward:n,replaced:r,position:window.history.length,scroll:i?jf():null}}function kO(t){const{history:e,location:n}=window,r={value:Qw(t,n)},i={value:e.state};i.value||s(r.value,{back:null,current:r.value,forward:null,position:e.length-1,replaced:!0,scroll:null},!0);function s(f,g,y){const v=t.indexOf("#"),w=v>-1?(n.host&&document.querySelector("base")?t:t.slice(v))+f:vO()+t+f;try{e[y?"replaceState":"pushState"](g,"",w),i.value=g}catch(T){Jt.NODE_ENV!=="production"?fn("Error with push/replace State",T):console.error(T),n[y?"replace":"assign"](w)}}function a(f,g){const y=zn({},e.state,ek(i.value.back,f,i.value.forward,!0),g,{position:i.value.position});s(f,y,!0),r.value=f}function o(f,g){const y=zn({},i.value,e.state,{forward:f,scroll:jf()});Jt.NODE_ENV!=="production"&&!e.state&&fn(`history.state seems to have been manually replaced without preserving the necessary values. Make sure to preserve existing history state if you are manually calling history.replaceState:
|
7
7
|
|
8
8
|
history.replaceState(history.state, '', url)
|
9
9
|
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { _ as $, s as k, u as V, g as d } from "./import-file-
|
1
|
+
import { _ as $, s as k, u as V, g as d } from "./import-file-CrENtq-3.js";
|
2
2
|
import { resolveComponent as j, openBlock as p, createElementBlock as g, createElementVNode as m, normalizeClass as b, createCommentVNode as x, normalizeStyle as y, createBlock as E } from "vue";
|
3
3
|
const O = {
|
4
4
|
data() {
|