sprof 0.0.48 → 0.0.49

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.
Files changed (3) hide show
  1. package/dist/sprof.js +3527 -3528
  2. package/dist/sprof.umd.cjs +12 -12
  3. package/package.json +1 -1
@@ -1,4 +1,4 @@
1
- (function(v,i){typeof exports=="object"&&typeof module<"u"?i(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],i):(v=typeof globalThis<"u"?globalThis:v||self,i(v.sprof={},v.Vue))})(this,function(v,i){"use strict";var np=Object.defineProperty;var ip=(v,i,Ee)=>i in v?np(v,i,{enumerable:!0,configurable:!0,writable:!0,value:Ee}):v[i]=Ee;var l=(v,i,Ee)=>ip(v,typeof i!="symbol"?i+"":i,Ee);var Le;var Ee=typeof document<"u"?document.currentScript:null;const xa={key:0,class:"mainblock"},Ba={class:"mainblock-right"},Ia={class:"title"},Ra={class:"body"},$a=i.defineComponent({__name:"AdaptiveContainer",props:{menuWidth:{type:String,required:!1,default:"0px"},mobileWidth:{type:String,required:!1,default:"1330px"}},setup(t){const e=t,n=i.ref(!1),r=i.ref(!0),o=i.ref(window.matchMedia("(max-width: 1330px)").matches),s=()=>{r.value=!r.value};return i.onBeforeMount(async()=>{window.addEventListener("resize",()=>{switch(e.mobileWidth){case"1330px":return o.value=window.matchMedia("(max-width: 1330px)").matches;case"1024px":return o.value=window.matchMedia("(max-width: 1024px)").matches;case"768px":return o.value=window.matchMedia("(max-width: 768px)").matches}return o.value=window.matchMedia("(max-width: 1330px)").matches}),n.value=!0}),(a,d)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[i.renderSlot(a.$slots,"main",{},void 0,!0),i.unref(n)?(i.openBlock(),i.createElementBlock("div",xa,[i.createElementVNode("div",{class:"mainblock-left",style:i.normalizeStyle({minWidth:i.unref(o)?"100%":t.menuWidth,maxWidth:i.unref(o)?"100%":t.menuWidth,marginLeft:i.unref(o)?"-110%":"0",position:i.unref(o)?"fixed":"relative",top:i.unref(o)?"140px":""})},[i.createElementVNode("div",{class:"left-menu",style:i.normalizeStyle({minWidth:i.unref(o)?"auto":t.menuWidth,boxShadow:i.unref(o)?"0 0px 10px 0px rgba(0 0 0 / 20%)":"",marginLeft:!i.unref(r)&&i.unref(o)?"110%":"0",borderTopLeftRadius:i.unref(o)?"0":"",borderBottomLeftRadius:i.unref(o)?"0":""}),onClick:d[0]||(d[0]=c=>s())},[i.renderSlot(a.$slots,"menu",{},void 0,!0)],4)],4),i.createElementVNode("div",Ba,[i.createElementVNode("div",Ia,[i.createElementVNode("div",{class:"icon",style:i.normalizeStyle({display:i.unref(o)?"flex":"none"}),onClick:d[1]||(d[1]=c=>s())},[i.renderSlot(a.$slots,"icon",{},void 0,!0)],4),i.renderSlot(a.$slots,"title",{},void 0,!0)]),i.createElementVNode("div",Ra,[i.renderSlot(a.$slots,"body",{},void 0,!0)])])])):i.createCommentVNode("",!0)],64))}}),M=(t,e)=>{const n=t.__vccOpts||t;for(const[r,o]of e)n[r]=o;return n},Yi=M($a,[["__scopeId","data-v-7b0ea2a1"]]),Na={class:"mainblock-right"},Aa={class:"body"},Qi=M(i.defineComponent({__name:"AdaptiveContainerHorizontal",props:{menuWidth:{type:String,required:!1,default:"0px"},leftWidth:{type:String,required:!1,default:"0px"},mobileWidth:{type:String,required:!1,default:"1330px"},titleSticky:{type:Boolean,required:!1,default:!1}},setup(t){const e=t,n=i.ref(!1),r=i.ref(!0),o=i.ref(window.matchMedia("(max-width: 1330px)").matches),s=()=>{r.value=!r.value};return i.onBeforeMount(async()=>{window.addEventListener("resize",()=>{switch(e.mobileWidth){case"1330px":return o.value=window.matchMedia("(max-width: 1330px)").matches;case"1024px":return o.value=window.matchMedia("(max-width: 1024px)").matches;case"768px":return o.value=window.matchMedia("(max-width: 768px)").matches}return o.value=window.matchMedia("(max-width: 1330px)").matches}),n.value=!0}),(a,d)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[i.renderSlot(a.$slots,"main",{},void 0,!0),i.unref(n)?(i.openBlock(),i.createElementBlock("div",{key:0,class:"mainblock",style:i.normalizeStyle({display:i.unref(o)?"block":"flex"})},[i.createElementVNode("div",{class:"mainblock-left",style:i.normalizeStyle({minWidth:i.unref(o)?"100%":t.menuWidth,display:t.leftWidth!=="0px"?"flex":"none",top:i.unref(o)?"58px":"80px"})},[i.createElementVNode("div",{class:"left-menu",style:i.normalizeStyle({minWidth:i.unref(o)?"100%":t.menuWidth,boxShadow:i.unref(o)?"0 0px 10px 0px rgba(0 0 0 / 20%)":"",marginLeft:(!i.unref(r)&&i.unref(o),"0"),overflowX:i.unref(o)?"scroll":"hidden",display:i.unref(o)?"flex":"block",background:i.unref(o)?"#ffffff":"",overflowY:i.unref(o)?"hidden":"auto"}),onClick:d[0]||(d[0]=c=>s())},[i.renderSlot(a.$slots,"menu",{},void 0,!0)],4)],4),i.createElementVNode("div",Na,[i.createElementVNode("div",{class:"title",style:i.normalizeStyle({position:t.titleSticky?"sticky":"relative",top:t.titleSticky?i.unref(o)?"108px":"58px":"0",zIndex:t.titleSticky?"10":""})},[i.createElementVNode("div",{class:"icon",style:i.normalizeStyle({display:i.unref(o)?"flex":"none"}),onClick:d[1]||(d[1]=c=>s())},[i.renderSlot(a.$slots,"icon",{},void 0,!0)],4),i.renderSlot(a.$slots,"title",{},void 0,!0)],4),i.createElementVNode("div",Aa,[i.renderSlot(a.$slots,"body",{},void 0,!0)])])],4)):i.createCommentVNode("",!0)],64))}}),[["__scopeId","data-v-aa16a0ab"]]);var me=(t=>(t.Login="login",t.Register="register",t.Restore="restore",t.Refresh="refresh",t))(me||{}),se=(t=>(t.Primary="primary",t.Success="success",t.Warning="warning",t.Error="error",t.Info="info",t))(se||{});class je{constructor(e,n,r,o){l(this,"text","Сохранить");l(this,"type",se.Success);l(this,"condition",!0);l(this,"action");l(this,"id","button");l(this,"disabled",!1);this.text=e,this.type=r,this.action=n,o!==void 0&&(this.condition=o)}static Primary(e,n,r){return new je(e,n,se.Primary,r)}static Success(e,n,r){return new je(e,n,se.Success,r)}static Warning(e,n,r){return new je(e,n,se.Warning,r)}static Error(e,n,r){return new je(e,n,se.Error,r)}}class Ki extends je{constructor(){super(...arguments);l(this,"id","auth-button");l(this,"status",me.Login);l(this,"submit",!1)}GetStatus(){return this.status}}let Pn=class extends Ki{constructor(){super(...arguments);l(this,"id","auth-button-login");l(this,"text","Войти");l(this,"isSubmit",!1);l(this,"disabled",!1)}};class Tn extends Ki{constructor(){super(...arguments);l(this,"id","auth-button-register");l(this,"text","Зарегистрироваться");l(this,"isSubmit",!1);l(this,"disabled",!1)}}class Pa{constructor(){l(this,"value","");l(this,"label","");l(this,"placeholder","");l(this,"validator")}Validate(){return this.validator?(this.validator.validate(this.value),this.validator.errors):[]}Reset(){this.value=""}}class Ot extends Pa{constructor(){super(...arguments);l(this,"method");l(this,"id","field-auth");l(this,"name","")}}var ot=(t=>(t.Login="login",t.Email="email",t.Phone="phone",t.VK="vk",t.ESIA="esia",t))(ot||{});const Ta=/\S+@\S+\.\S+/;class er{constructor(){l(this,"errors",[])}validate(e){return(e===""||!e)&&this.errors.push("Введите email"),Ta.test(e)||this.errors.push("Некорректный email"),this.errors}}class _t extends Ot{constructor(){super(...arguments);l(this,"id","field-auth-email");l(this,"label","Email");l(this,"name","email");l(this,"placeholder","Введите email");l(this,"validator",new er);l(this,"method",ot.Email)}}class za{constructor(){l(this,"errors",[]);l(this,"length",6)}validate(e){return e===""||!e?(this.errors.push("Введите пароль"),this.errors):(e.length<this.length&&this.errors.push("Пароль недостаточной длины"),this.errors)}}class qt extends Ot{constructor(){super(...arguments);l(this,"label","Пароль");l(this,"validator",new za);l(this,"name","password");l(this,"placeholder","Введите пароль");l(this,"id","field-auth-password")}}class tr extends Ot{constructor(){super(...arguments);l(this,"label","Повторите пароль");l(this,"id","field-auth-password-repeat")}}const nr={[me.Login]:{methods:[ot.Email],title:"Вход в систему",action:"login",buttons:[new Pn,new Tn],fields:[new _t,new qt],errorMessage:"Неверно указан email или пароль",successMessage:"Вы успешно вошли в систему"},[me.Register]:{methods:[],title:"Регистрация",action:"register",buttons:[new Tn,new Pn],fields:[new _t,new qt,new tr],errorMessage:"Неверно указан email или пароль",successMessage:"Вы успешно зарегистрировались в системе, войдите под своим паролем"},[me.Restore]:{title:"Восстановление пароля",methods:[],action:"restorePassword",successMessage:"Ссылка для восстановления пароля отправлена на Вашу почту",errorMessage:"Неверно указан email",buttons:[],fields:[new _t]},[me.Refresh]:{methods:[],title:"Создание нового пароля",action:"passwordChange",successMessage:"Воспользуйтесь новым паролем для входа",errorMessage:"Неверно указан email",buttons:[],fields:[new qt]}};let Va=class{constructor(){l(this,"settings",nr);l(this,"status",me.Login);l(this,"selectedMethod",ot.Email)}async Block(e){await e()}GetValues(){const e=this.GetFields(),n=new Map;return e.forEach(r=>{r.value&&n.set(r.name,r.value)}),n}Validate(){return[]}GetFields(){return this.GetCurSet().fields.filter(e=>!e.method||e.method===this.selectedMethod)}GetMethods(){return this.GetCurSet().methods}Status(){return this.status}GetCurSet(){return this.settings[this.status]}IsLogin(){return this.status===me.Login}IsRegister(){return this.status===me.Register}IsRestore(){return this.status===me.Restore}IsRefresh(){return this.status===me.Refresh}SetStatus(e){this.status=e}GetTitle(){return this.GetCurSet().title}GetButtons(){const e=this.GetCurSet().buttons;return e.forEach(n=>{n.submit=!1}),e.length>0&&(e[0].submit=!0),e}GetSuccessMessage(){return this.GetCurSet().successMessage}GetErrorMessage(){return this.GetCurSet().errorMessage}GetAction(){return this.GetCurSet().action}ResetFields(){this.GetCurSet().fields.forEach(e=>e.Reset())}Reset(){this.status=me.Login}};class Fa{constructor(){l(this,"visible",!1);l(this,"closable",!1)}IsClosable(){return this.closable}IsVisible(){return this.visible}Close(){this.visible=!1}Open(e){e&&(this.closable=!0),this.visible=!0}}class ve{static Get(e){const n=localStorage.getItem(e);if(n)return JSON.parse(n)}static Set(e,n){n&&localStorage.setItem(e,JSON.stringify(n))}static Remove(e){localStorage.removeItem(e)}}var we=(t=>(t.User="user",t.AccessToken="accessToken",t.RefreshToken="refreshToken",t))(we||{});class Da{set(e){this.setAccessToken(e.accessToken),this.setRefreshToken(e.refreshToken)}getAccessToken(){return ve.Get(we.AccessToken)}getRefreshToken(){return ve.Get(we.RefreshToken)}setAccessToken(e){ve.Set(we.AccessToken,e)}setRefreshToken(e){ve.Set(we.RefreshToken,e)}reset(){ve.Remove(we.AccessToken),ve.Remove(we.RefreshToken)}actualize(){this.setAccessToken(this.getAccessToken()),this.setRefreshToken(this.getAccessToken())}}class La{constructor(){l(this,"user");l(this,"userConstructor")}AssignTo(e){e.user=this.get()}setUserConstructor(e){this.userConstructor=e}get(){if(this.userConstructor)return this.user=new this.userConstructor(ve.Get(we.User)),this.user}set(e){this.userConstructor&&(this.user=new this.userConstructor(e),ve.Set(we.User,this.user))}reset(){this.user=void 0,ve.Remove(we.User)}actualize(){const e=ve.Get(we.User);e&&this.set(e)}}class Ha{constructor(){l(this,"isAuth",!1);l(this,"user",new La);l(this,"tokens",new Da);l(this,"preventLogout",!1)}DeprecateLogout(){this.preventLogout=!0}AllowLogout(){this.preventLogout=!1}get IsAuth(){return this.isAuth}get User(){return this.user.get()}SetUserConstructor(e){this.user.setUserConstructor(e)}SetState(e){this.user.set(e.user),this.tokens.set(e.tokens),this.isAuth=!0}Logout(){if(this.preventLogout){m.Notification.Warning("В текущий момент Вы не можете выйти из системы");return}this.user.reset(),this.tokens.reset(),this.isAuth=!1}Actualize(){if(this.user.actualize(),this.tokens.actualize(),this.user.get()&&this.tokens.getAccessToken()&&this.tokens.getRefreshToken()){this.isAuth=!0;return}this.Logout()}}class Oa{constructor(){l(this,"form",new Va);l(this,"status",new Ha);l(this,"modal",new Fa)}get Form(){return this.form}get Status(){return this.status}get Modal(){return this.modal}}const ir=new Oa;class _a extends Ot{constructor(){super(...arguments);l(this,"label","Логин");l(this,"name","login");l(this,"validator",new er);l(this,"method",ot.Login);l(this,"id","field-auth-login")}}class He{constructor(e){l(this,"id");l(this,"address");l(this,"description");l(this,"contactId");m.H.Classes.BuildClass(this,e)}static Create(){const e=new He;return e.id=m.H.Classes.CreateUUID(),e}}class pe{constructor(e){l(this,"name","");l(this,"url","");l(this,"src","");l(this,"raw");l(this,"blob");l(this,"file");l(this,"id");l(this,"originalName","");l(this,"fileSystemPath","");m.H.Classes.BuildClass(this,e)}getFileUrl(){const e=this.url?this.url:`${m.H.Static.StaticUrl}/${this.fileSystemPath}`;return new URL(e,typeof document>"u"&&typeof location>"u"?require("url").pathToFileURL(__filename).href:typeof document>"u"?location.href:Ee&&Ee.tagName.toUpperCase()==="SCRIPT"&&Ee.src||new URL("sprof.umd.cjs",document.baseURI).href)}getFileListObject(){return{name:this.originalName,url:this.url}}static CreatePreviewFile(e,n){const r=new pe;return r.id=n??m.H.Classes.CreateUUID(),r.originalName=e.name,r.file=e.blob,r.fileSystemPath=m.H.Classes.CreateUUID(),r}uploadNewFile(e){this.id||(this.id=m.H.Classes.CreateUUID()),this.originalName=e.name,this.file=e.blob,this.fileSystemPath=m.H.Classes.CreateUUID()}setFile(e){this.file=e,this.url=e.src}uploadAndSetFile(e){this.uploadNewFile(e),this.setFile(e),this.url=e.url}clearFile(){this.url="",this.file=void 0,this.fileSystemPath="",this.originalName=""}errorImg(e,n){if(e.target){let r="";return n&&(r=`@/assets/img/${n}`),new URL(r,typeof document>"u"&&typeof location>"u"?require("url").pathToFileURL(__filename).href:typeof document>"u"?location.href:Ee&&Ee.tagName.toUpperCase()==="SCRIPT"&&Ee.src||new URL("sprof.umd.cjs",document.baseURI).href)}}getFileInfos(){return[this]}isPdf(){return this.getExtension(this.originalName)===""}getExtension(e){const n=e.split(".");return n[n.length-1]}}var rr=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};/*! *****************************************************************************
1
+ (function(v,i){typeof exports=="object"&&typeof module<"u"?i(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],i):(v=typeof globalThis<"u"?globalThis:v||self,i(v.sprof={},v.Vue))})(this,function(v,i){"use strict";var rp=Object.defineProperty;var op=(v,i,Me)=>i in v?rp(v,i,{enumerable:!0,configurable:!0,writable:!0,value:Me}):v[i]=Me;var l=(v,i,Me)=>op(v,typeof i!="symbol"?i+"":i,Me);var Fe,Re,$e;var Me=typeof document<"u"?document.currentScript:null;const Ia={key:0,class:"mainblock"},Ra={class:"mainblock-right"},$a={class:"title"},Na={class:"body"},Aa=i.defineComponent({__name:"AdaptiveContainer",props:{menuWidth:{type:String,required:!1,default:"0px"},mobileWidth:{type:String,required:!1,default:"1330px"}},setup(t){const e=t,n=i.ref(!1),r=i.ref(!0),o=i.ref(window.matchMedia("(max-width: 1330px)").matches),s=()=>{r.value=!r.value};return i.onBeforeMount(async()=>{window.addEventListener("resize",()=>{switch(e.mobileWidth){case"1330px":return o.value=window.matchMedia("(max-width: 1330px)").matches;case"1024px":return o.value=window.matchMedia("(max-width: 1024px)").matches;case"768px":return o.value=window.matchMedia("(max-width: 768px)").matches}return o.value=window.matchMedia("(max-width: 1330px)").matches}),n.value=!0}),(a,d)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[i.renderSlot(a.$slots,"main",{},void 0,!0),i.unref(n)?(i.openBlock(),i.createElementBlock("div",Ia,[i.createElementVNode("div",{class:"mainblock-left",style:i.normalizeStyle({minWidth:i.unref(o)?"100%":t.menuWidth,maxWidth:i.unref(o)?"100%":t.menuWidth,marginLeft:i.unref(o)?"-110%":"0",position:i.unref(o)?"fixed":"relative",top:i.unref(o)?"140px":""})},[i.createElementVNode("div",{class:"left-menu",style:i.normalizeStyle({minWidth:i.unref(o)?"auto":t.menuWidth,boxShadow:i.unref(o)?"0 0px 10px 0px rgba(0 0 0 / 20%)":"",marginLeft:!i.unref(r)&&i.unref(o)?"110%":"0",borderTopLeftRadius:i.unref(o)?"0":"",borderBottomLeftRadius:i.unref(o)?"0":""}),onClick:d[0]||(d[0]=c=>s())},[i.renderSlot(a.$slots,"menu",{},void 0,!0)],4)],4),i.createElementVNode("div",Ra,[i.createElementVNode("div",$a,[i.createElementVNode("div",{class:"icon",style:i.normalizeStyle({display:i.unref(o)?"flex":"none"}),onClick:d[1]||(d[1]=c=>s())},[i.renderSlot(a.$slots,"icon",{},void 0,!0)],4),i.renderSlot(a.$slots,"title",{},void 0,!0)]),i.createElementVNode("div",Na,[i.renderSlot(a.$slots,"body",{},void 0,!0)])])])):i.createCommentVNode("",!0)],64))}}),M=(t,e)=>{const n=t.__vccOpts||t;for(const[r,o]of e)n[r]=o;return n},Qi=M(Aa,[["__scopeId","data-v-7b0ea2a1"]]),Pa={class:"mainblock-right"},Ta={class:"body"},Ki=M(i.defineComponent({__name:"AdaptiveContainerHorizontal",props:{menuWidth:{type:String,required:!1,default:"0px"},leftWidth:{type:String,required:!1,default:"0px"},mobileWidth:{type:String,required:!1,default:"1330px"},titleSticky:{type:Boolean,required:!1,default:!1}},setup(t){const e=t,n=i.ref(!1),r=i.ref(!0),o=i.ref(window.matchMedia("(max-width: 1330px)").matches),s=()=>{r.value=!r.value};return i.onBeforeMount(async()=>{window.addEventListener("resize",()=>{switch(e.mobileWidth){case"1330px":return o.value=window.matchMedia("(max-width: 1330px)").matches;case"1024px":return o.value=window.matchMedia("(max-width: 1024px)").matches;case"768px":return o.value=window.matchMedia("(max-width: 768px)").matches}return o.value=window.matchMedia("(max-width: 1330px)").matches}),n.value=!0}),(a,d)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[i.renderSlot(a.$slots,"main",{},void 0,!0),i.unref(n)?(i.openBlock(),i.createElementBlock("div",{key:0,class:"mainblock",style:i.normalizeStyle({display:i.unref(o)?"block":"flex"})},[i.createElementVNode("div",{class:"mainblock-left",style:i.normalizeStyle({minWidth:i.unref(o)?"100%":t.menuWidth,display:t.leftWidth!=="0px"?"flex":"none",top:i.unref(o)?"58px":"80px"})},[i.createElementVNode("div",{class:"left-menu",style:i.normalizeStyle({minWidth:i.unref(o)?"100%":t.menuWidth,boxShadow:i.unref(o)?"0 0px 10px 0px rgba(0 0 0 / 20%)":"",marginLeft:(!i.unref(r)&&i.unref(o),"0"),overflowX:i.unref(o)?"scroll":"hidden",display:i.unref(o)?"flex":"block",background:i.unref(o)?"#ffffff":"",overflowY:i.unref(o)?"hidden":"auto"}),onClick:d[0]||(d[0]=c=>s())},[i.renderSlot(a.$slots,"menu",{},void 0,!0)],4)],4),i.createElementVNode("div",Pa,[i.createElementVNode("div",{class:"title",style:i.normalizeStyle({position:t.titleSticky?"sticky":"relative",top:t.titleSticky?i.unref(o)?"108px":"58px":"0",zIndex:t.titleSticky?"10":""})},[i.createElementVNode("div",{class:"icon",style:i.normalizeStyle({display:i.unref(o)?"flex":"none"}),onClick:d[1]||(d[1]=c=>s())},[i.renderSlot(a.$slots,"icon",{},void 0,!0)],4),i.renderSlot(a.$slots,"title",{},void 0,!0)],4),i.createElementVNode("div",Ta,[i.renderSlot(a.$slots,"body",{},void 0,!0)])])],4)):i.createCommentVNode("",!0)],64))}}),[["__scopeId","data-v-aa16a0ab"]]);var ge=(t=>(t.Login="login",t.Register="register",t.Restore="restore",t.Refresh="refresh",t))(ge||{}),le=(t=>(t.Primary="primary",t.Success="success",t.Warning="warning",t.Error="error",t.Info="info",t))(le||{});class Je{constructor(e,n,r,o){l(this,"text","Сохранить");l(this,"type",le.Success);l(this,"condition",!0);l(this,"action");l(this,"id","button");l(this,"disabled",!1);this.text=e,this.type=r,this.action=n,o!==void 0&&(this.condition=o)}static Primary(e,n,r){return new Je(e,n,le.Primary,r)}static Success(e,n,r){return new Je(e,n,le.Success,r)}static Warning(e,n,r){return new Je(e,n,le.Warning,r)}static Error(e,n,r){return new Je(e,n,le.Error,r)}}class er extends Je{constructor(){super(...arguments);l(this,"id","auth-button");l(this,"status",ge.Login);l(this,"submit",!1)}GetStatus(){return this.status}}let Tn=class extends er{constructor(){super(...arguments);l(this,"id","auth-button-login");l(this,"text","Войти");l(this,"isSubmit",!1);l(this,"disabled",!1)}};class zn extends er{constructor(){super(...arguments);l(this,"id","auth-button-register");l(this,"text","Зарегистрироваться");l(this,"isSubmit",!1);l(this,"disabled",!1)}}class za{constructor(){l(this,"value","");l(this,"label","");l(this,"placeholder","");l(this,"validator")}Validate(){return this.validator?(this.validator.validate(this.value),this.validator.errors):[]}Reset(){this.value=""}}class _t extends za{constructor(){super(...arguments);l(this,"method");l(this,"id","field-auth");l(this,"name","")}}var st=(t=>(t.Login="login",t.Email="email",t.Phone="phone",t.VK="vk",t.ESIA="esia",t))(st||{});const Va=/\S+@\S+\.\S+/;class tr{constructor(){l(this,"errors",[])}validate(e){return(e===""||!e)&&this.errors.push("Введите email"),Va.test(e)||this.errors.push("Некорректный email"),this.errors}}class qt extends _t{constructor(){super(...arguments);l(this,"id","field-auth-email");l(this,"label","Email");l(this,"name","email");l(this,"placeholder","Введите email");l(this,"validator",new tr);l(this,"method",st.Email)}}class Fa{constructor(){l(this,"errors",[]);l(this,"length",6)}validate(e){return e===""||!e?(this.errors.push("Введите пароль"),this.errors):(e.length<this.length&&this.errors.push("Пароль недостаточной длины"),this.errors)}}class Ut extends _t{constructor(){super(...arguments);l(this,"label","Пароль");l(this,"validator",new Fa);l(this,"name","password");l(this,"placeholder","Введите пароль");l(this,"id","field-auth-password")}}class nr extends _t{constructor(){super(...arguments);l(this,"label","Повторите пароль");l(this,"id","field-auth-password-repeat")}}const ir={[ge.Login]:{methods:[st.Email],title:"Вход в систему",action:"login",buttons:[new Tn,new zn],fields:[new qt,new Ut],errorMessage:"Неверно указан email или пароль",successMessage:"Вы успешно вошли в систему"},[ge.Register]:{methods:[],title:"Регистрация",action:"register",buttons:[new zn,new Tn],fields:[new qt,new Ut,new nr],errorMessage:"Неверно указан email или пароль",successMessage:"Вы успешно зарегистрировались в системе, войдите под своим паролем"},[ge.Restore]:{title:"Восстановление пароля",methods:[],action:"restorePassword",successMessage:"Ссылка для восстановления пароля отправлена на Вашу почту",errorMessage:"Неверно указан email",buttons:[],fields:[new qt]},[ge.Refresh]:{methods:[],title:"Создание нового пароля",action:"passwordChange",successMessage:"Воспользуйтесь новым паролем для входа",errorMessage:"Неверно указан email",buttons:[],fields:[new Ut]}};let Da=class{constructor(){l(this,"settings",ir);l(this,"status",ge.Login);l(this,"selectedMethod",st.Email)}async Block(e){await e()}GetValues(){const e=this.GetFields(),n=new Map;return e.forEach(r=>{r.value&&n.set(r.name,r.value)}),n}Validate(){return[]}GetFields(){return this.GetCurSet().fields.filter(e=>!e.method||e.method===this.selectedMethod)}GetMethods(){return this.GetCurSet().methods}Status(){return this.status}GetCurSet(){return this.settings[this.status]}IsLogin(){return this.status===ge.Login}IsRegister(){return this.status===ge.Register}IsRestore(){return this.status===ge.Restore}IsRefresh(){return this.status===ge.Refresh}SetStatus(e){this.status=e}GetTitle(){return this.GetCurSet().title}GetButtons(){const e=this.GetCurSet().buttons;return e.forEach(n=>{n.submit=!1}),e.length>0&&(e[0].submit=!0),e}GetSuccessMessage(){return this.GetCurSet().successMessage}GetErrorMessage(){return this.GetCurSet().errorMessage}GetAction(){return this.GetCurSet().action}ResetFields(){this.GetCurSet().fields.forEach(e=>e.Reset())}Reset(){this.status=ge.Login}};class La{constructor(){l(this,"visible",!1);l(this,"closable",!1)}IsClosable(){return this.closable}IsVisible(){return this.visible}Close(){this.visible=!1}Open(e){e&&(this.closable=!0),this.visible=!0}}class xe{static Get(e){const n=localStorage.getItem(e);if(n)return JSON.parse(n)}static Set(e,n){n&&localStorage.setItem(e,JSON.stringify(n))}static Remove(e){localStorage.removeItem(e)}}var Ce=(t=>(t.User="user",t.AccessToken="accessToken",t.RefreshToken="refreshToken",t))(Ce||{});class Oa{set(e){this.setAccessToken(e.accessToken),this.setRefreshToken(e.refreshToken)}getAccessToken(){return xe.Get(Ce.AccessToken)}getRefreshToken(){return xe.Get(Ce.RefreshToken)}setAccessToken(e){xe.Set(Ce.AccessToken,e)}setRefreshToken(e){xe.Set(Ce.RefreshToken,e)}reset(){xe.Remove(Ce.AccessToken),xe.Remove(Ce.RefreshToken)}actualize(){this.setAccessToken(this.getAccessToken()),this.setRefreshToken(this.getAccessToken())}}class Ha{constructor(){l(this,"user");l(this,"userConstructor")}AssignTo(e){e.user=this.get()}setUserConstructor(e){this.userConstructor=e}get(){if(this.userConstructor)return this.user=new this.userConstructor(xe.Get(Ce.User)),this.user}set(e){this.userConstructor&&(this.user=new this.userConstructor(e),xe.Set(Ce.User,this.user))}reset(){this.user=void 0,xe.Remove(Ce.User)}actualize(){const e=xe.Get(Ce.User);e&&this.set(e)}}class _a{constructor(){l(this,"isAuth",!1);l(this,"user",new Ha);l(this,"tokens",new Oa);l(this,"preventLogout",!1)}DeprecateLogout(){this.preventLogout=!0}AllowLogout(){this.preventLogout=!1}get IsAuth(){return this.isAuth}get User(){return this.user.get()}SetUserConstructor(e){this.user.setUserConstructor(e)}SetState(e){this.user.set(e.user),this.tokens.set(e.tokens),this.isAuth=!0}Logout(){if(this.preventLogout){Notification.Warning("В текущий момент Вы не можете выйти из системы");return}this.user.reset(),this.tokens.reset(),this.isAuth=!1}Actualize(){if(this.user.actualize(),this.tokens.actualize(),this.user.get()&&this.tokens.getAccessToken()&&this.tokens.getRefreshToken()){this.isAuth=!0;return}this.Logout()}}class qa{constructor(){l(this,"form",new Da);l(this,"status",new _a);l(this,"modal",new La)}get Form(){return this.form}get Status(){return this.status}get Modal(){return this.modal}}const rr=new qa;class Ua extends _t{constructor(){super(...arguments);l(this,"label","Логин");l(this,"name","login");l(this,"validator",new tr);l(this,"method",st.Login);l(this,"id","field-auth-login")}}class Ue{constructor(e){l(this,"id");l(this,"address");l(this,"description");l(this,"contactId");Classes.BuildClass(this,e)}static Create(){const e=new Ue;return e.id=Classes.CreateUUID(),e}}class ye{constructor(e){l(this,"name","");l(this,"url","");l(this,"src","");l(this,"raw");l(this,"blob");l(this,"file");l(this,"id");l(this,"originalName","");l(this,"fileSystemPath","");Classes.BuildClass(this,e)}getFileUrl(){const e=this.url?this.url:`${H.Static.StaticUrl}/${this.fileSystemPath}`;return new URL(e,typeof document>"u"&&typeof location>"u"?require("url").pathToFileURL(__filename).href:typeof document>"u"?location.href:Me&&Me.tagName.toUpperCase()==="SCRIPT"&&Me.src||new URL("sprof.umd.cjs",document.baseURI).href)}getFileListObject(){return{name:this.originalName,url:this.url}}static CreatePreviewFile(e,n){const r=new ye;return r.id=n??Classes.CreateUUID(),r.originalName=e.name,r.file=e.blob,r.fileSystemPath=Classes.CreateUUID(),r}uploadNewFile(e){this.id||(this.id=Classes.CreateUUID()),this.originalName=e.name,this.file=e.blob,this.fileSystemPath=Classes.CreateUUID()}setFile(e){this.file=e,this.url=e.src}uploadAndSetFile(e){this.uploadNewFile(e),this.setFile(e),this.url=e.url}clearFile(){this.url="",this.file=void 0,this.fileSystemPath="",this.originalName=""}errorImg(e,n){if(e.target){let r="";return n&&(r=`@/assets/img/${n}`),new URL(r,typeof document>"u"&&typeof location>"u"?require("url").pathToFileURL(__filename).href:typeof document>"u"?location.href:Me&&Me.tagName.toUpperCase()==="SCRIPT"&&Me.src||new URL("sprof.umd.cjs",document.baseURI).href)}}getFileInfos(){return[this]}isPdf(){return this.getExtension(this.originalName)===""}getExtension(e){const n=e.split(".");return n[n.length-1]}}var or=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};/*! *****************************************************************************
2
2
  Copyright (C) Microsoft. All rights reserved.
3
3
  Licensed under the Apache License, Version 2.0 (the "License"); you may not use
4
4
  this file except in compliance with the License. You may obtain a copy of the
@@ -11,21 +11,21 @@
11
11
 
12
12
  See the Apache Version 2.0 License for specific language governing permissions
13
13
  and limitations under the License.
14
- ***************************************************************************** */var or;(function(t){(function(e){var n=typeof globalThis=="object"?globalThis:typeof rr=="object"?rr:typeof self=="object"?self:typeof this=="object"?this:d(),r=o(t);typeof n.Reflect<"u"&&(r=o(n.Reflect,r)),e(r,n),typeof n.Reflect>"u"&&(n.Reflect=t);function o(c,u){return function(h,f){Object.defineProperty(c,h,{configurable:!0,writable:!0,value:f}),u&&u(h,f)}}function s(){try{return Function("return this;")()}catch{}}function a(){try{return(0,eval)("(function() { return this; })()")}catch{}}function d(){return s()||a()}})(function(e,n){var r=Object.prototype.hasOwnProperty,o=typeof Symbol=="function",s=o&&typeof Symbol.toPrimitive<"u"?Symbol.toPrimitive:"@@toPrimitive",a=o&&typeof Symbol.iterator<"u"?Symbol.iterator:"@@iterator",d=typeof Object.create=="function",c={__proto__:[]}instanceof Array,u=!d&&!c,h={create:d?function(){return Ji(Object.create(null))}:c?function(){return Ji({__proto__:null})}:function(){return Ji({})},has:u?function(w,C){return r.call(w,C)}:function(w,C){return C in w},get:u?function(w,C){return r.call(w,C)?w[C]:void 0}:function(w,C){return w[C]}},f=Object.getPrototypeOf(Function),p=typeof Map=="function"&&typeof Map.prototype.entries=="function"?Map:Ym(),y=typeof Set=="function"&&typeof Set.prototype.entries=="function"?Set:Qm(),g=typeof WeakMap=="function"?WeakMap:Km(),k=o?Symbol.for("@reflect-metadata:registry"):void 0,b=Zm(),B=Jm(b);function D(w,C,E,x){if(z(E)){if(!fa(w))throw new TypeError;if(!ma(C))throw new TypeError;return Hm(w,C)}else{if(!fa(w))throw new TypeError;if(!Y(C))throw new TypeError;if(!Y(x)&&!z(x)&&!St(x))throw new TypeError;return St(x)&&(x=void 0),E=Te(E),Om(w,C,E,x)}}e("decorate",D);function L(w,C){function E(x,P){if(!Y(x))throw new TypeError;if(!z(P)&&!Gm(P))throw new TypeError;la(w,C,x,P)}return E}e("metadata",L);function V(w,C,E,x){if(!Y(E))throw new TypeError;return z(x)||(x=Te(x)),la(w,C,E,x)}e("defineMetadata",V);function T(w,C,E){if(!Y(C))throw new TypeError;return z(E)||(E=Te(E)),oa(w,C,E)}e("hasMetadata",T);function ye(w,C,E){if(!Y(C))throw new TypeError;return z(E)||(E=Te(E)),Gi(w,C,E)}e("hasOwnMetadata",ye);function ke(w,C,E){if(!Y(C))throw new TypeError;return z(E)||(E=Te(E)),sa(w,C,E)}e("getMetadata",ke);function Ge(w,C,E){if(!Y(C))throw new TypeError;return z(E)||(E=Te(E)),aa(w,C,E)}e("getOwnMetadata",Ge);function Ct(w,C){if(!Y(w))throw new TypeError;return z(C)||(C=Te(C)),ca(w,C)}e("getMetadataKeys",Ct);function $n(w,C){if(!Y(w))throw new TypeError;return z(C)||(C=Te(C)),da(w,C)}e("getOwnMetadataKeys",$n);function Lm(w,C,E){if(!Y(C))throw new TypeError;if(z(E)||(E=Te(E)),!Y(C))throw new TypeError;z(E)||(E=Te(E));var x=Ht(C,E,!1);return z(x)?!1:x.OrdinaryDeleteMetadata(w,C,E)}e("deleteMetadata",Lm);function Hm(w,C){for(var E=w.length-1;E>=0;--E){var x=w[E],P=x(C);if(!z(P)&&!St(P)){if(!ma(P))throw new TypeError;C=P}}return C}function Om(w,C,E,x){for(var P=w.length-1;P>=0;--P){var te=w[P],Q=te(C,E,x);if(!z(Q)&&!St(Q)){if(!Y(Q))throw new TypeError;x=Q}}return x}function oa(w,C,E){var x=Gi(w,C,E);if(x)return!0;var P=Zi(C);return St(P)?!1:oa(w,P,E)}function Gi(w,C,E){var x=Ht(C,E,!1);return z(x)?!1:ha(x.OrdinaryHasOwnMetadata(w,C,E))}function sa(w,C,E){var x=Gi(w,C,E);if(x)return aa(w,C,E);var P=Zi(C);if(!St(P))return sa(w,P,E)}function aa(w,C,E){var x=Ht(C,E,!1);if(!z(x))return x.OrdinaryGetOwnMetadata(w,C,E)}function la(w,C,E,x){var P=Ht(E,x,!0);P.OrdinaryDefineOwnMetadata(w,C,E,x)}function ca(w,C){var E=da(w,C),x=Zi(w);if(x===null)return E;var P=ca(x,C);if(P.length<=0)return E;if(E.length<=0)return P;for(var te=new y,Q=[],O=0,I=E;O<I.length;O++){var R=I[O],$=te.has(R);$||(te.add(R),Q.push(R))}for(var N=0,_=P;N<_.length;N++){var R=_[N],$=te.has(R);$||(te.add(R),Q.push(R))}return Q}function da(w,C){var E=Ht(w,C,!1);return E?E.OrdinaryOwnMetadataKeys(w,C):[]}function ua(w){if(w===null)return 1;switch(typeof w){case"undefined":return 0;case"boolean":return 2;case"string":return 3;case"symbol":return 4;case"number":return 5;case"object":return w===null?1:6;default:return 6}}function z(w){return w===void 0}function St(w){return w===null}function _m(w){return typeof w=="symbol"}function Y(w){return typeof w=="object"?w!==null:typeof w=="function"}function qm(w,C){switch(ua(w)){case 0:return w;case 1:return w;case 2:return w;case 3:return w;case 4:return w;case 5:return w}var E="string",x=pa(w,s);if(x!==void 0){var P=x.call(w,E);if(Y(P))throw new TypeError;return P}return Um(w)}function Um(w,C){var E,x;{var P=w.toString;if(Nn(P)){var x=P.call(w);if(!Y(x))return x}var E=w.valueOf;if(Nn(E)){var x=E.call(w);if(!Y(x))return x}}throw new TypeError}function ha(w){return!!w}function Wm(w){return""+w}function Te(w){var C=qm(w);return _m(C)?C:Wm(C)}function fa(w){return Array.isArray?Array.isArray(w):w instanceof Object?w instanceof Array:Object.prototype.toString.call(w)==="[object Array]"}function Nn(w){return typeof w=="function"}function ma(w){return typeof w=="function"}function Gm(w){switch(ua(w)){case 3:return!0;case 4:return!0;default:return!1}}function ji(w,C){return w===C||w!==w&&C!==C}function pa(w,C){var E=w[C];if(E!=null){if(!Nn(E))throw new TypeError;return E}}function ga(w){var C=pa(w,a);if(!Nn(C))throw new TypeError;var E=C.call(w);if(!Y(E))throw new TypeError;return E}function ya(w){return w.value}function wa(w){var C=w.next();return C.done?!1:C}function ba(w){var C=w.return;C&&C.call(w)}function Zi(w){var C=Object.getPrototypeOf(w);if(typeof w!="function"||w===f||C!==f)return C;var E=w.prototype,x=E&&Object.getPrototypeOf(E);if(x==null||x===Object.prototype)return C;var P=x.constructor;return typeof P!="function"||P===w?C:P}function jm(){var w;!z(k)&&typeof n.Reflect<"u"&&!(k in n.Reflect)&&typeof n.Reflect.defineMetadata=="function"&&(w=Xm(n.Reflect));var C,E,x,P=new g,te={registerProvider:Q,getProvider:I,setProvider:$};return te;function Q(N){if(!Object.isExtensible(te))throw new Error("Cannot add provider to a frozen registry.");switch(!0){case w===N:break;case z(C):C=N;break;case C===N:break;case z(E):E=N;break;case E===N:break;default:x===void 0&&(x=new y),x.add(N);break}}function O(N,_){if(!z(C)){if(C.isProviderFor(N,_))return C;if(!z(E)){if(E.isProviderFor(N,_))return C;if(!z(x))for(var G=ga(x);;){var j=wa(G);if(!j)return;var Be=ya(j);if(Be.isProviderFor(N,_))return ba(G),Be}}}if(!z(w)&&w.isProviderFor(N,_))return w}function I(N,_){var G=P.get(N),j;return z(G)||(j=G.get(_)),z(j)&&(j=O(N,_),z(j)||(z(G)&&(G=new p,P.set(N,G)),G.set(_,j))),j}function R(N){if(z(N))throw new TypeError;return C===N||E===N||!z(x)&&x.has(N)}function $(N,_,G){if(!R(G))throw new Error("Metadata provider not registered.");var j=I(N,_);if(j!==G){if(!z(j))return!1;var Be=P.get(N);z(Be)&&(Be=new p,P.set(N,Be)),Be.set(_,G)}return!0}}function Zm(){var w;return!z(k)&&Y(n.Reflect)&&Object.isExtensible(n.Reflect)&&(w=n.Reflect[k]),z(w)&&(w=jm()),!z(k)&&Y(n.Reflect)&&Object.isExtensible(n.Reflect)&&Object.defineProperty(n.Reflect,k,{enumerable:!1,configurable:!1,writable:!1,value:w}),w}function Jm(w){var C=new g,E={isProviderFor:function(R,$){var N=C.get(R);return z(N)?!1:N.has($)},OrdinaryDefineOwnMetadata:Q,OrdinaryHasOwnMetadata:P,OrdinaryGetOwnMetadata:te,OrdinaryOwnMetadataKeys:O,OrdinaryDeleteMetadata:I};return b.registerProvider(E),E;function x(R,$,N){var _=C.get(R),G=!1;if(z(_)){if(!N)return;_=new p,C.set(R,_),G=!0}var j=_.get($);if(z(j)){if(!N)return;if(j=new p,_.set($,j),!w.setProvider(R,$,E))throw _.delete($),G&&C.delete(R),new Error("Wrong provider for target.")}return j}function P(R,$,N){var _=x($,N,!1);return z(_)?!1:ha(_.has(R))}function te(R,$,N){var _=x($,N,!1);if(!z(_))return _.get(R)}function Q(R,$,N,_){var G=x(N,_,!0);G.set(R,$)}function O(R,$){var N=[],_=x(R,$,!1);if(z(_))return N;for(var G=_.keys(),j=ga(G),Be=0;;){var Ca=wa(j);if(!Ca)return N.length=Be,N;var ep=ya(Ca);try{N[Be]=ep}catch(tp){try{ba(j)}finally{throw tp}}Be++}}function I(R,$,N){var _=x($,N,!1);if(z(_)||!_.delete(R))return!1;if(_.size===0){var G=C.get($);z(G)||(G.delete(N),G.size===0&&C.delete(G))}return!0}}function Xm(w){var C=w.defineMetadata,E=w.hasOwnMetadata,x=w.getOwnMetadata,P=w.getOwnMetadataKeys,te=w.deleteMetadata,Q=new g,O={isProviderFor:function(I,R){var $=Q.get(I);return!z($)&&$.has(R)?!0:P(I,R).length?(z($)&&($=new y,Q.set(I,$)),$.add(R),!0):!1},OrdinaryDefineOwnMetadata:C,OrdinaryHasOwnMetadata:E,OrdinaryGetOwnMetadata:x,OrdinaryOwnMetadataKeys:P,OrdinaryDeleteMetadata:te};return O}function Ht(w,C,E){var x=b.getProvider(w,C);if(!z(x))return x;if(E){if(b.setProvider(w,C,B))return B;throw new Error("Illegal state.")}}function Ym(){var w={},C=[],E=function(){function O(I,R,$){this._index=0,this._keys=I,this._values=R,this._selector=$}return O.prototype["@@iterator"]=function(){return this},O.prototype[a]=function(){return this},O.prototype.next=function(){var I=this._index;if(I>=0&&I<this._keys.length){var R=this._selector(this._keys[I],this._values[I]);return I+1>=this._keys.length?(this._index=-1,this._keys=C,this._values=C):this._index++,{value:R,done:!1}}return{value:void 0,done:!0}},O.prototype.throw=function(I){throw this._index>=0&&(this._index=-1,this._keys=C,this._values=C),I},O.prototype.return=function(I){return this._index>=0&&(this._index=-1,this._keys=C,this._values=C),{value:I,done:!0}},O}(),x=function(){function O(){this._keys=[],this._values=[],this._cacheKey=w,this._cacheIndex=-2}return Object.defineProperty(O.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),O.prototype.has=function(I){return this._find(I,!1)>=0},O.prototype.get=function(I){var R=this._find(I,!1);return R>=0?this._values[R]:void 0},O.prototype.set=function(I,R){var $=this._find(I,!0);return this._values[$]=R,this},O.prototype.delete=function(I){var R=this._find(I,!1);if(R>=0){for(var $=this._keys.length,N=R+1;N<$;N++)this._keys[N-1]=this._keys[N],this._values[N-1]=this._values[N];return this._keys.length--,this._values.length--,ji(I,this._cacheKey)&&(this._cacheKey=w,this._cacheIndex=-2),!0}return!1},O.prototype.clear=function(){this._keys.length=0,this._values.length=0,this._cacheKey=w,this._cacheIndex=-2},O.prototype.keys=function(){return new E(this._keys,this._values,P)},O.prototype.values=function(){return new E(this._keys,this._values,te)},O.prototype.entries=function(){return new E(this._keys,this._values,Q)},O.prototype["@@iterator"]=function(){return this.entries()},O.prototype[a]=function(){return this.entries()},O.prototype._find=function(I,R){if(!ji(this._cacheKey,I)){this._cacheIndex=-1;for(var $=0;$<this._keys.length;$++)if(ji(this._keys[$],I)){this._cacheIndex=$;break}}return this._cacheIndex<0&&R&&(this._cacheIndex=this._keys.length,this._keys.push(I),this._values.push(void 0)),this._cacheIndex},O}();return x;function P(O,I){return O}function te(O,I){return I}function Q(O,I){return[O,I]}}function Qm(){var w=function(){function C(){this._map=new p}return Object.defineProperty(C.prototype,"size",{get:function(){return this._map.size},enumerable:!0,configurable:!0}),C.prototype.has=function(E){return this._map.has(E)},C.prototype.add=function(E){return this._map.set(E,E),this},C.prototype.delete=function(E){return this._map.delete(E)},C.prototype.clear=function(){this._map.clear()},C.prototype.keys=function(){return this._map.keys()},C.prototype.values=function(){return this._map.keys()},C.prototype.entries=function(){return this._map.entries()},C.prototype["@@iterator"]=function(){return this.keys()},C.prototype[a]=function(){return this.keys()},C}();return w}function Km(){var w=16,C=h.create(),E=x();return function(){function I(){this._key=x()}return I.prototype.has=function(R){var $=P(R,!1);return $!==void 0?h.has($,this._key):!1},I.prototype.get=function(R){var $=P(R,!1);return $!==void 0?h.get($,this._key):void 0},I.prototype.set=function(R,$){var N=P(R,!0);return N[this._key]=$,this},I.prototype.delete=function(R){var $=P(R,!1);return $!==void 0?delete $[this._key]:!1},I.prototype.clear=function(){this._key=x()},I}();function x(){var I;do I="@@WeakMap@@"+O();while(h.has(C,I));return C[I]=!0,I}function P(I,R){if(!r.call(I,E)){if(!R)return;Object.defineProperty(I,E,{value:h.create()})}return I[E]}function te(I,R){for(var $=0;$<R;++$)I[$]=Math.random()*255|0;return I}function Q(I){if(typeof Uint8Array=="function"){var R=new Uint8Array(I);return typeof crypto<"u"?crypto.getRandomValues(R):typeof msCrypto<"u"?msCrypto.getRandomValues(R):te(R,I),R}return te(new Array(I),I)}function O(){var I=Q(w);I[6]=I[6]&79|64,I[8]=I[8]&191|128;for(var R="",$=0;$<w;++$){var N=I[$];($===4||$===6||$===8)&&(R+="-"),N<16&&(R+="0"),R+=N.toString(16).toLowerCase()}return R}}function Ji(w){return w.__=void 0,delete w.__,w}})})(or||(or={}));let Ut;const qa=new Uint8Array(16);function Ua(){if(!Ut&&(Ut=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Ut))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Ut(qa)}const ne=[];for(let t=0;t<256;++t)ne.push((t+256).toString(16).slice(1));function Wa(t,e=0){return ne[t[e+0]]+ne[t[e+1]]+ne[t[e+2]]+ne[t[e+3]]+"-"+ne[t[e+4]]+ne[t[e+5]]+"-"+ne[t[e+6]]+ne[t[e+7]]+"-"+ne[t[e+8]]+ne[t[e+9]]+"-"+ne[t[e+10]]+ne[t[e+11]]+ne[t[e+12]]+ne[t[e+13]]+ne[t[e+14]]+ne[t[e+15]]}const sr={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function ce(t,e,n){if(sr.randomUUID&&!e&&!t)return sr.randomUUID();t=t||{};const r=t.random||(t.rng||Ua)();return r[6]=r[6]&15|64,r[8]=r[8]&63|128,Wa(r)}const rt=class rt{static BuildClass(e,n){n&&Object.keys(n).forEach(r=>{const o=n[r];if(this.isPrimitive(o))e[r]instanceof Date?e[r]=new Date(o):e[r]=o;else if(o!=null&&!Array.isArray(o))if(e[r]&&e[r].constructor)e[r]=new e[r].constructor(o);else{const s=Reflect.getMetadata(r,e);s&&(e[r]=new s[r](o))}if(Array.isArray(o)){const s=Reflect.getMetadata(r,e);s&&(e[r]=o.map(a=>new s[r](a)))}})}static isPrimitive(e){return e!==null&&typeof e<"u"&&e!==Object(e)}static RemoveFromClassByIndex(e,n,r){rt.RemoveFromClass(e,n,r)}static RemoveFromClassById(e,n,r){if(!e)return;const o=n.findIndex(s=>s.id===e);rt.RemoveFromClass(o,n,r)}static RemoveFromClass(e,n,r){if(e<0)return;const o=n[e].id;o&&r&&r.push(o),n.splice(e,1)}static GetPropertyName(e){const n=new e;return new Proxy(n,{get(r,o){return o}})}static CreateUUID(){return ce()}static InitClassInstance(e,n){const r=e.constructor(n);return rt.BuildClass(r),r.id=rt.CreateUUID(),r}static ExistsWithId(e,n){return e.some(r=>r.id===n)}};l(rt,"GetClassConstructor",e=>(n,r)=>{const o=Reflect.getMetadata(`property:${r}`,n)||{};o[r]=e,Reflect.defineMetadata(r,o,n)});let Oe=rt;class ar{constructor(e){l(this,"id");l(this,"name","");l(this,"surname","");l(this,"patronymic","");l(this,"citizenship","");l(this,"placeBirth","");l(this,"carNumber","");l(this,"carModel","");l(this,"snils","");l(this,"isMale",!0);l(this,"dateBirth",new Date);l(this,"contactId");l(this,"slug","");l(this,"postIndex","");l(this,"address","");l(this,"editNameMode",!1);Oe.BuildClass(this,e)}setEditNameMode(e){this.editNameMode=e}getFullName(){return!this.surname.length&&!this.name.length&&!this.patronymic.length?"":`${this.surname} ${this.name} ${this.patronymic}`}getInitialsName(){return`${this.name.slice(0,1)}.${this.patronymic.slice(0,1)}. ${this.surname}`}getGender(e){return e?this.isMale?"Мужской":"Женский":this.isMale?"М":"Ж"}capitalizeName(){this.name=m.H.Strings.Capitalize(this.name),this.surname=m.H.Strings.Capitalize(this.surname),this.patronymic=m.H.Strings.Capitalize(this.patronymic)}trimName(){this.name=this.name.trim(),this.surname=this.surname.trim(),this.patronymic=this.patronymic.trim()}sanitizeName(){this.trimName(),this.capitalizeName()}setFullName(e){this.surname=e.surname,this.name=e.name,this.patronymic=e.patronymic}}const Ga=Object.freeze(Object.defineProperty({__proto__:null,Auth:ir,AuthButtonLogin:Pn,AuthButtonRegister:Tn,AuthFormSettings:nr,AuthFormStatuses:me,AuthMethods:ot,Email:He,EmailField:_t,FileInfo:pe,Human:ar,LoginField:_a,PasswordField:qt,PasswordRepeatField:tr},Symbol.toStringTag,{value:"Module"}));class ja{constructor(){l(this,"title","");l(this,"buttons",[])}Set(e="",n){typeof e=="function"?this.title=e():typeof e=="string"?this.title=e:this.title=e.value,this.buttons=n}}const Za=new ja;class Ja{constructor(){l(this,"menu",[]);l(this,"path","");l(this,"isOpen",!0);l(this,"filterString","")}Set(e){this.menu=e}Get(){return this.filterString?this.filterMenu():this.menu}filterMenu(){return this.menu.filter(e=>{var n;return m.H.Strings.SearchIn(e.name,this.filterString)||((n=e.children)==null?void 0:n.some(r=>m.H.Strings.SearchIn(r.name,this.filterString)))})}IsOpen(){return this.isOpen}Toggle(){this.isOpen=!this.isOpen}SetPath(e){this.path=e}GetPath(){return this.path}SetFilter(e){this.filterString=e}GetChildren(e){var n;return this.filterString?(n=e.children)==null?void 0:n.filter(r=>m.H.Strings.SearchIn(r.name,this.filterString)):e.children}}const Xa=new Ja;class Ya{constructor(){l(this,"Menu",Xa);l(this,"Head",Za)}}const Qa=new Ya;class lr{constructor(){l(this,"visible",!1)}hide(){this.visible=!1}show(){this.hide(),this.visible=!0}IsVisible(){return this.visible}}class cr extends lr{constructor(){super(...arguments);l(this,"type",se.Success);l(this,"text","");l(this,"title","")}showMessage(n,r){this.hide(),this.type=r,typeof n=="string"?this.text=n:(this.text=n.text,this.title=n.title??""),super.show()}GetText(){return this.text}GetTitle(){return this.title}GetType(){return this.type}Info(n){this.showMessage(n,se.Info)}Success(n){this.showMessage(n,se.Success)}Error(n){this.showMessage(n,se.Error)}Warning(n){this.showMessage(n,se.Warning)}FormMessage(n){let r="<strong>Проверьте правильность введенных данных:</strong><ul>";for(const o of Object.keys(n))n[o][0]&&n[o][0].message&&(r+=`<li>${n[o][0].message}</li>`);return r+="</ul>",r}}class Ka extends cr{constructor(){super(...arguments);l(this,"confirmButtonText","Да");l(this,"cancelButtonText","Нет");l(this,"resolve");l(this,"reject")}GetConfirmButtonText(){return this.confirmButtonText}GetCancelButtonText(){return this.cancelButtonText}Show(n){return super.show(),typeof n!="string"&&(this.confirmButtonText=n.confirmButtonText,this.cancelButtonText=n.cancelButtonText),new Promise((r,o)=>{this.resolve=r,this.reject=o})}Save(){return this.Show({text:"У вас есть несохранённые изменения",confirmButtonText:"Сохранить",cancelButtonText:"Не сохранять"})}Submit(){this.resolve(!0),this.hide()}Cancel(){this.reject(),this.hide()}hide(){this.resolve=void 0,this.reject=void 0,super.hide()}}const el=new Ka;class st{constructor(e){l(this,"id");l(this,"number");l(this,"description");l(this,"contactId");m.H.Classes.BuildClass(this,e)}static Create(){const e=new st;return e.id=m.H.Classes.CreateUUID(),e}}class zn{constructor(e){l(this,"id");l(this,"address");l(this,"description");m.H.Classes.BuildClass(this,e)}}class dr{constructor(e){l(this,"id");l(this,"address");l(this,"description");m.H.Classes.BuildClass(this,e)}}var tl=Object.defineProperty,Wt=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&tl(e,n,o),o};const Et=class Sa{constructor(e){l(this,"id");l(this,"description","");l(this,"time","");l(this,"latitude","");l(this,"longitude","");l(this,"emails",[]);l(this,"postAddresses",[new zn]);l(this,"phones",[]);l(this,"websites",[]);m.H.Classes.BuildClass(this,e)}addEmail(){const e=He.Create();return e.contactId=this.id,this.emails.push(e),e}addPhone(){const e=st.Create();return e.contactId=this.id,this.phones.push(e),e}static Create(){const e=new Sa;return e.id=m.H.Classes.CreateUUID(),e}removeEmail(e){m.H.Classes.RemoveFromClassById(e,this.emails)}removePhone(e){m.H.Classes.RemoveFromClassById(e,this.phones)}addPostAddress(){this.postAddresses.push(new zn)}addWebsite(){this.websites.push(new dr)}pushFirst(){this.emails.length||this.emails.push(new He),this.phones.length||this.phones.push(new st)}getCoords(){return[Number(this.latitude),Number(this.longitude)]}updateDescription(e){this.description=e}updateTime(e){this.time=e}updateLatitude(e){this.latitude=e}updateLongitutde(e){this.longitude=e}};Wt([Oe.GetClassConstructor(He)],Et.prototype,"emails"),Wt([Oe.GetClassConstructor(zn)],Et.prototype,"postAddresses"),Wt([Oe.GetClassConstructor(st)],Et.prototype,"phones"),Wt([Oe.GetClassConstructor(dr)],Et.prototype,"websites");let Vn=Et;var Z=(t=>(t.Date="date",t.String="string",t.Boolean="boolean",t.Number="number",t.Set="set",t.Join="join",t))(Z||{}),ae=(t=>(t.Eq="=",t.Ne="!=",t.Gt=">",t.Lt="<",t.Btw="between",t.In="in",t.Like="like",t.Null="is null",t.NotNull="is not null",t))(ae||{});class _e{static Shuffle(e){for(let n=e.length-1;n>0;n--){const r=Math.floor(Math.random()*(n+1));[e[n],e[r]]=[e[r],e[n]]}}static GenerateNumsRange(e,n,r=1){return Array.from({length:(n-e)/r+1},(o,s)=>e+s*r)}static GetLast(e){return e[e.length-1]}static GetFirst(e){return e[0]}static GetRandEL(e){return e[Math.floor(Math.random()*e.length)]}static Sort(e){e.forEach((n,r)=>n.order=r)}static Refill(e,n){e.splice(0,e.length),e.push(...n)}static Eq(e,n){return e.length===n.length&&(e==null?void 0:e.every((r,o)=>e[o]==n[o]))}static SwipeById(e,n,r){const o=e.findIndex(a=>n.id===a.id),s=e.findIndex(a=>r.id===a.id);o||s||([e[o],e[s]]=[e[s],e[o]])}static Swap(e,n,r){if(n<0||n>=e.length||r<0||r>=e.length)return;const o=e[n];e[n]=e[r],e[r]=o}static MoveUp(e,n){e[n].order=n-1,e[n-1]&&(e[n-1].order=n),[e[n],e[n-1]]=[e[n-1],e[n]]}static MoveDown(e,n){e[n].order=n+1,e[n+1]&&(e[n+1].order=n),[e[n],e[n+1]]=[e[n+1],e[n]]}}var nl=Object.defineProperty,il=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&nl(e,n,o),o};const ur=class kt{constructor(e){l(this,"id");l(this,"model","");l(this,"label","");l(this,"col","");l(this,"operator",ae.Eq);l(this,"date1");l(this,"date2");l(this,"value1","");l(this,"boolean",!1);l(this,"number",0);l(this,"type",Z.String);l(this,"set",[]);l(this,"isSet",!1);l(this,"joinTable","");l(this,"joinTableModel","");l(this,"joinTableFk","");l(this,"joinTablePk","");l(this,"joinTableId","");l(this,"joinTableIdCol","");m.H.Classes.BuildClass(this,e)}eq(e){if(!e)return!1;if(this.type===Z.Join){const n=e.model===this.model&&e.operator===this.operator&&this.joinTableModel===e.joinTableModel;return e.operator===ae.In?n&&_e.Eq(this.set,e.set):n}return e.model===this.model&&e.col===this.col&&e.operator===this.operator}valueEq(e){return!this||!e||!this.eq(e)?!1:this.type===Z.Boolean?this.boolean===(e==null?void 0:e.boolean):this.type===Z.String?this.value1===(e==null?void 0:e.value1):this.type===Z.Join&&this.set.length?_e.Eq(this.set,e.set):!1}toUrlQuery(){const e=this.type?`"type":"${this.type}"`:"",n=this.model?`"model":"${this.model}"`:"",r=this.col?`"col":"${this.col}"`:"",o=this.operator?`"operator":"${this.operator}"`:"",s=this.value1?`"value1":"${this.value1}"`:"",a=this.type===Z.Boolean?`"boolean":${this.boolean}`:"",d=this.type===Z.Date&&this.date1?`"date1":"${this.date1.toISOString()}"`:"",c=this.type===Z.Date&&this.date2?`"date2":"${this.date2.toISOString()}"`:"",u=this.type===Z.Number?`"number":${this.number}`:"",h=this.type===Z.Set||this.operator===ae.In?`"set":${JSON.stringify(this.set)}`:"",f=this.type===Z.Join?`"joinTableModel":"${this.joinTableModel}"`:"";return[e,n,r,o,s,a,d,c,u,h,f].filter(p=>p!=="").toString()}fromUrlQuery(e){this.model=e.get("model")??"",this.col=e.get("col")??"",this.label=e.get("label")??"",this.operator=e.get("operator")??"",this.value1=e.get("value1")??"",this.type=e.get("type")??"",this.boolean=!!(e.get("boolean")??""),this.joinTableModel=e.get("joinTableModel")??"",this.joinTableId=e.get("joinTableId")??"",this.joinTableFk=e.get("joinTableFk")??"",this.joinTableIdCol=e.get("joinTableIdCol")??"",this.joinTablePk=e.get("joinTablePk")??""}isUnaryFilter(){return this.operator===ae.Eq||this.operator===ae.Gt||this.operator===ae.Lt}isBetweenFilter(){return this.operator===ae.Btw}isSetFilter(){return this.operator===ae.In}static Create(e,n,r){const o=new kt;return o.model=e.GetClassName(),o.col=n??"",o.type=r,o.type===Z.Number&&(o.value1="0"),o.type===Z.String&&(o.value1=""),o.type===Z.Boolean&&(o.value1="false",o.operator=ae.Eq),o}static CreateFilterModel(e,n,r){const o=new kt;return o.id=ce(),o.model=typeof e=="string"?e:e.GetClassName(),o.col=n??"",o.type=r,o.type===Z.Number&&(o.value1="0"),o.type===Z.String&&(o.value1=""),o.type===Z.Boolean&&(o.value1="false"),o}static CreateFilterModelWithJoin(e,n,r,o,s,a,d,c){const u=new kt;return u.id=ce(),u.joinTable=r,u.joinTablePk=o,u.joinTableFk=s,u.col=n,u.type=a,d&&(u.joinTableId=d),c&&(u.joinTableIdCol=c),u}static CreateFilterModelWithJoinV2(e,n,r,o,s,a,d){const c=new kt;return c.model=e,c.joinTableModel=r,c.joinTablePk=o,c.joinTableFk=s,c.col=n,c.type=Z.Join,a&&(c.joinTableId=a),d&&(c.joinTableIdCol=d),c}static OnlyIfSecondModelExists(e,n){const r=new kt;return r.id=ce(),r.model=m.H.Strings.ToCamelCase(e.GetClassName()),r.joinTableModel=m.H.Strings.ToCamelCase(n.GetClassName()),r.type=Z.Join,r}addToSet(...e){e.forEach(n=>{if(this.set.indexOf(n)===-1){this.set.push(n);return}this.set=this.set.filter(r=>r!==n)})}pushToSet(...e){e.forEach(n=>{this.set.indexOf(n)===-1&&this.set.push(n)})}replaceSet(...e){this.set=e}setBoolean(e){this.boolean=e}toRef(){return i.ref(this)}setDate1(e){this.date1=e}setDate2(e){this.date2=e}dropDates(){this.setDate1(),this.setDate2()}setDatesRange(e,n){if(!e&&!n){this.dropDates();return}if(!n){this.setDate1(e),this.operator=ae.Eq;return}this.setDate2(n),this.operator=ae.Btw}};il([m.H.Classes.GetClassConstructor(String)],ur.prototype,"set");let Fn=ur;class rl{constructor(){l(this,"operation",ae.Lt);l(this,"column","");l(this,"value");l(this,"initial",!0);l(this,"tableName","");l(this,"version","");l(this,"model","")}toUrlQuery(){const e=this.operation?`"operation":"${this.operation}"`:"",n=this.column?`"column":"${this.column}"`:"",r=this.value&&typeof this.value.toISOString=="function"?this.value.toISOString():this.value,o=r?`"value":"${r}"`:"",s=this.model?`"model":"${this.model}"`:"",a=`"initial":${this.initial}`;return[e,n,o,s,a].filter(d=>d!=="").toString()}fromUrlQuery(e){e.cursvalue&&(this.value=e.cursvalue),e.curscolumn&&(this.column=String(e.curscolumn)),e.cursinitial!==void 0&&(this.initial=!!e.cursinitial),e.curstableName&&(this.tableName=String(e.curstableName)),e.cursoperation&&(this.operation=e.cursoperation)}}class Gt{constructor(e){l(this,"offset",0);l(this,"limit",25);l(this,"cursor",new rl);l(this,"cursorMode",!1);l(this,"append",!1);l(this,"allLoaded",!1);l(this,"version","");m.H.Classes.BuildClass(this,e)}setLoadMore(e,n,r){this.cursor.value=e,this.cursor.initial=!1,this.cursor.operation=ae.Gt,this.cursor.column=n,this.cursor.tableName=r,this.cursorMode=!0}setLoadMoreV2(e,n,r){this.cursor.value=e,this.cursor.initial=!1,this.cursor.operation=ae.Gt,this.cursor.column=n,this.cursor.model=r,this.cursorMode=!0,this.version="v2"}setOffset(e){this.offset=e}toUrlQuery(){const e=`"offset":${this.offset}`,n=`"limit":${this.limit}`,r=`"cursorMode":${this.cursorMode}`,o=`"append":${this.append}`,s=`"allLoaded":${this.allLoaded}`,a=`"cursor":{${this.cursor.toUrlQuery()}}`;return[e,n,r,o,s,a].toString()}fromUrlQuery(){const e=window.location.search,n=e.substring(e.indexOf("p=")+2,e.lastIndexOf("|")),r=new URLSearchParams(decodeURIComponent(n));this.offset=Number(r.get("offset")),this.limit=Number(r.get("col"))}setAllLoaded(e){this.allLoaded=!(e>=this.limit)}resetAllLoaded(){this.allLoaded=!1}getPageNum(){return this.offset/this.limit+1}drop(){this.offset=0,this.limit=25,m.H.Classes.BuildClass(this)}}class jt{constructor(){l(this,"model","");l(this,"cols",[]);l(this,"models",[])}static Create(e,n){const r=new jt;return r.model=e.GetClassName(),r.cols=n,r}}var Ie=(t=>(t.Asc="asc",t.Desc="desc",t))(Ie||{});class Zt{constructor(e){l(this,"model","");l(this,"col","");l(this,"order");l(this,"label","");l(this,"default",!1);l(this,"selected",!1);m.H.Classes.BuildClass(this,e)}static Create(e,n,r=Ie.Asc,o,s){const a=new Zt;return a.model=e.GetClassName(),a.col=n??"",a.order=r??Ie.Asc,a.label=o??"",a.default=s??!1,a}isAsc(){return this.order===Ie.Asc}isDesc(){return this.order===Ie.Desc}eq(e){return e.model===this.model&&e.col===this.col&&e.order===this.order}toUrlQuery(){const e=this.model?`"model":"${this.model}"`:"",n=this.col?`"col":"${this.col}"`:"",r=this.order?`"order":"${this.order}"`:"";return[e,n,r].toString()}async fromUrlQuery(){const e=window.location.search,n=e.substring(e.indexOf("s=")+2,e.indexOf("|")),r=new URLSearchParams(decodeURIComponent(n));this.model=r.get("model")??"",this.col=r.get("col")??"",this.label=r.get("label")??"",this.default=!!r.get("default"),this.order=r.get("order")??""}}var ol=Object.defineProperty,Jt=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&ol(e,n,o),o};const vt=(Le=class{constructor(e){l(this,"id");l(this,"f",[]);l(this,"s",[]);l(this,"p",new Gt);l(this,"t",new jt);m.H.Classes.BuildClass(this,e)}static Get(){return this.instance||(this.instance=new Le),this.instance}createFrom(e){const n=new Le(JSON.parse(e));this.f=n.f}clearForHTTP(){const e=new Le(this);return e.f=this.f.map(n=>m.H.FTSP.EmptyEntiries(n)),e.s=this.s.map(n=>m.H.FTSP.EmptyEntiries(n)),e.p=m.H.FTSP.EmptyEntiries(this.p),e.t=m.H.FTSP.EmptyEntiries(this.t),e}static EmptyEntiries(e){if(!e)return;const r=Object.entries(e).filter(([o,s])=>o!=="label"&&s!==""&&s!==null);return Object.fromEntries(r)}findFilterModel(e){return this.f.find(n=>e.id===n.id)}getFirstSortModel(){return _e.GetLast(this.s)}setSortModel(e){e&&(this.s[0]=e)}setS(e){this.s[0]=e}setF(e){this.f.push(e)}replaceF(e,n){this.removeF(n),e&&this.setF(e)}removeF(e){const n=this.f.findIndex(r=>r.eq(e));m.H.Classes.RemoveFromClassByIndex(n,this.f)}reset(){this.f=[],this.s=[],this.p=new Gt}resetF(){this.f=[]}},l(Le,"instance"),Le);Jt([m.H.Classes.GetClassConstructor(Fn)],vt.prototype,"f"),Jt([m.H.Classes.GetClassConstructor(Zt)],vt.prototype,"s"),Jt([m.H.Classes.GetClassConstructor(Gt)],vt.prototype,"p"),Jt([m.H.Classes.GetClassConstructor(jt)],vt.prototype,"t");let sl=vt;var hr=(t=>(t.simple="simple",t.oneToMany="oneToMany",t.manyToMany="manyToMany",t))(hr||{}),le=(t=>(t.String="string",t.Text="text",t.Number="number",t.Date="date",t.DateTime="dateTime",t.Radio="radio",t.Set="set",t.Boolean="boolean",t.Files="files",t.File="file",t.MatrixRadio="matrixRadio",t.MatrixSet="matrixSet",t))(le||{});class Dn{constructor(e){l(this,"id");l(this,"name",le.String);l(this,"valueRelation",hr.simple);m.H.Classes.BuildClass(this,e)}isString(){return this.name==="string"}isNumber(){return this.name==="number"}isDate(){return this.name==="date"}isDateTime(){return this.name==="dateTime"}isRadio(){return this.name==="radio"}isSet(){return this.name==="set"}isText(){return this.name==="text"}isBoolean(){return this.name==="boolean"}isFile(){return this.name==="file"}isFiles(){return this.name==="files"}getComponentType(){if(this.name===le.Radio)return"RadioProp";if(this.name===le.Set)return"SetProp";if(this.name===le.Number)return"NumberProp";if(this.name===le.String)return"StringProp"}}/*!
14
+ ***************************************************************************** */var sr;(function(t){(function(e){var n=typeof globalThis=="object"?globalThis:typeof or=="object"?or:typeof self=="object"?self:typeof this=="object"?this:d(),r=o(t);typeof n.Reflect<"u"&&(r=o(n.Reflect,r)),e(r,n),typeof n.Reflect>"u"&&(n.Reflect=t);function o(c,u){return function(h,f){Object.defineProperty(c,h,{configurable:!0,writable:!0,value:f}),u&&u(h,f)}}function s(){try{return Function("return this;")()}catch{}}function a(){try{return(0,eval)("(function() { return this; })()")}catch{}}function d(){return s()||a()}})(function(e,n){var r=Object.prototype.hasOwnProperty,o=typeof Symbol=="function",s=o&&typeof Symbol.toPrimitive<"u"?Symbol.toPrimitive:"@@toPrimitive",a=o&&typeof Symbol.iterator<"u"?Symbol.iterator:"@@iterator",d=typeof Object.create=="function",c={__proto__:[]}instanceof Array,u=!d&&!c,h={create:d?function(){return Xi(Object.create(null))}:c?function(){return Xi({__proto__:null})}:function(){return Xi({})},has:u?function(y,b){return r.call(y,b)}:function(y,b){return b in y},get:u?function(y,b){return r.call(y,b)?y[b]:void 0}:function(y,b){return y[b]}},f=Object.getPrototypeOf(Function),m=typeof Map=="function"&&typeof Map.prototype.entries=="function"?Map:Km(),g=typeof Set=="function"&&typeof Set.prototype.entries=="function"?Set:ep(),p=typeof WeakMap=="function"?WeakMap:tp(),k=o?Symbol.for("@reflect-metadata:registry"):void 0,w=Xm(),B=Ym(w);function D(y,b,E,x){if(z(E)){if(!pa(y))throw new TypeError;if(!ga(b))throw new TypeError;return _m(y,b)}else{if(!pa(y))throw new TypeError;if(!K(b))throw new TypeError;if(!K(x)&&!z(x)&&!kt(x))throw new TypeError;return kt(x)&&(x=void 0),E=De(E),qm(y,b,E,x)}}e("decorate",D);function L(y,b){function E(x,P){if(!K(x))throw new TypeError;if(!z(P)&&!Zm(P))throw new TypeError;da(y,b,x,P)}return E}e("metadata",L);function V(y,b,E,x){if(!K(E))throw new TypeError;return z(x)||(x=De(x)),da(y,b,E,x)}e("defineMetadata",V);function T(y,b,E){if(!K(b))throw new TypeError;return z(E)||(E=De(E)),aa(y,b,E)}e("hasMetadata",T);function be(y,b,E){if(!K(b))throw new TypeError;return z(E)||(E=De(E)),ji(y,b,E)}e("hasOwnMetadata",be);function ve(y,b,E){if(!K(b))throw new TypeError;return z(E)||(E=De(E)),la(y,b,E)}e("getMetadata",ve);function Ze(y,b,E){if(!K(b))throw new TypeError;return z(E)||(E=De(E)),ca(y,b,E)}e("getOwnMetadata",Ze);function St(y,b){if(!K(y))throw new TypeError;return z(b)||(b=De(b)),ua(y,b)}e("getMetadataKeys",St);function Nn(y,b){if(!K(y))throw new TypeError;return z(b)||(b=De(b)),ha(y,b)}e("getOwnMetadataKeys",Nn);function Hm(y,b,E){if(!K(b))throw new TypeError;if(z(E)||(E=De(E)),!K(b))throw new TypeError;z(E)||(E=De(E));var x=Ht(b,E,!1);return z(x)?!1:x.OrdinaryDeleteMetadata(y,b,E)}e("deleteMetadata",Hm);function _m(y,b){for(var E=y.length-1;E>=0;--E){var x=y[E],P=x(b);if(!z(P)&&!kt(P)){if(!ga(P))throw new TypeError;b=P}}return b}function qm(y,b,E,x){for(var P=y.length-1;P>=0;--P){var ie=y[P],ee=ie(b,E,x);if(!z(ee)&&!kt(ee)){if(!K(ee))throw new TypeError;x=ee}}return x}function aa(y,b,E){var x=ji(y,b,E);if(x)return!0;var P=Ji(b);return kt(P)?!1:aa(y,P,E)}function ji(y,b,E){var x=Ht(b,E,!1);return z(x)?!1:ma(x.OrdinaryHasOwnMetadata(y,b,E))}function la(y,b,E){var x=ji(y,b,E);if(x)return ca(y,b,E);var P=Ji(b);if(!kt(P))return la(y,P,E)}function ca(y,b,E){var x=Ht(b,E,!1);if(!z(x))return x.OrdinaryGetOwnMetadata(y,b,E)}function da(y,b,E,x){var P=Ht(E,x,!0);P.OrdinaryDefineOwnMetadata(y,b,E,x)}function ua(y,b){var E=ha(y,b),x=Ji(y);if(x===null)return E;var P=ua(x,b);if(P.length<=0)return E;if(E.length<=0)return P;for(var ie=new g,ee=[],_=0,I=E;_<I.length;_++){var R=I[_],$=ie.has(R);$||(ie.add(R),ee.push(R))}for(var N=0,q=P;N<q.length;N++){var R=q[N],$=ie.has(R);$||(ie.add(R),ee.push(R))}return ee}function ha(y,b){var E=Ht(y,b,!1);return E?E.OrdinaryOwnMetadataKeys(y,b):[]}function fa(y){if(y===null)return 1;switch(typeof y){case"undefined":return 0;case"boolean":return 2;case"string":return 3;case"symbol":return 4;case"number":return 5;case"object":return y===null?1:6;default:return 6}}function z(y){return y===void 0}function kt(y){return y===null}function Um(y){return typeof y=="symbol"}function K(y){return typeof y=="object"?y!==null:typeof y=="function"}function Wm(y,b){switch(fa(y)){case 0:return y;case 1:return y;case 2:return y;case 3:return y;case 4:return y;case 5:return y}var E="string",x=ya(y,s);if(x!==void 0){var P=x.call(y,E);if(K(P))throw new TypeError;return P}return Gm(y)}function Gm(y,b){var E,x;{var P=y.toString;if(An(P)){var x=P.call(y);if(!K(x))return x}var E=y.valueOf;if(An(E)){var x=E.call(y);if(!K(x))return x}}throw new TypeError}function ma(y){return!!y}function jm(y){return""+y}function De(y){var b=Wm(y);return Um(b)?b:jm(b)}function pa(y){return Array.isArray?Array.isArray(y):y instanceof Object?y instanceof Array:Object.prototype.toString.call(y)==="[object Array]"}function An(y){return typeof y=="function"}function ga(y){return typeof y=="function"}function Zm(y){switch(fa(y)){case 3:return!0;case 4:return!0;default:return!1}}function Zi(y,b){return y===b||y!==y&&b!==b}function ya(y,b){var E=y[b];if(E!=null){if(!An(E))throw new TypeError;return E}}function wa(y){var b=ya(y,a);if(!An(b))throw new TypeError;var E=b.call(y);if(!K(E))throw new TypeError;return E}function ba(y){return y.value}function Ca(y){var b=y.next();return b.done?!1:b}function Sa(y){var b=y.return;b&&b.call(y)}function Ji(y){var b=Object.getPrototypeOf(y);if(typeof y!="function"||y===f||b!==f)return b;var E=y.prototype,x=E&&Object.getPrototypeOf(E);if(x==null||x===Object.prototype)return b;var P=x.constructor;return typeof P!="function"||P===y?b:P}function Jm(){var y;!z(k)&&typeof n.Reflect<"u"&&!(k in n.Reflect)&&typeof n.Reflect.defineMetadata=="function"&&(y=Qm(n.Reflect));var b,E,x,P=new p,ie={registerProvider:ee,getProvider:I,setProvider:$};return ie;function ee(N){if(!Object.isExtensible(ie))throw new Error("Cannot add provider to a frozen registry.");switch(!0){case y===N:break;case z(b):b=N;break;case b===N:break;case z(E):E=N;break;case E===N:break;default:x===void 0&&(x=new g),x.add(N);break}}function _(N,q){if(!z(b)){if(b.isProviderFor(N,q))return b;if(!z(E)){if(E.isProviderFor(N,q))return b;if(!z(x))for(var j=wa(x);;){var J=Ca(j);if(!J)return;var Ne=ba(J);if(Ne.isProviderFor(N,q))return Sa(j),Ne}}}if(!z(y)&&y.isProviderFor(N,q))return y}function I(N,q){var j=P.get(N),J;return z(j)||(J=j.get(q)),z(J)&&(J=_(N,q),z(J)||(z(j)&&(j=new m,P.set(N,j)),j.set(q,J))),J}function R(N){if(z(N))throw new TypeError;return b===N||E===N||!z(x)&&x.has(N)}function $(N,q,j){if(!R(j))throw new Error("Metadata provider not registered.");var J=I(N,q);if(J!==j){if(!z(J))return!1;var Ne=P.get(N);z(Ne)&&(Ne=new m,P.set(N,Ne)),Ne.set(q,j)}return!0}}function Xm(){var y;return!z(k)&&K(n.Reflect)&&Object.isExtensible(n.Reflect)&&(y=n.Reflect[k]),z(y)&&(y=Jm()),!z(k)&&K(n.Reflect)&&Object.isExtensible(n.Reflect)&&Object.defineProperty(n.Reflect,k,{enumerable:!1,configurable:!1,writable:!1,value:y}),y}function Ym(y){var b=new p,E={isProviderFor:function(R,$){var N=b.get(R);return z(N)?!1:N.has($)},OrdinaryDefineOwnMetadata:ee,OrdinaryHasOwnMetadata:P,OrdinaryGetOwnMetadata:ie,OrdinaryOwnMetadataKeys:_,OrdinaryDeleteMetadata:I};return w.registerProvider(E),E;function x(R,$,N){var q=b.get(R),j=!1;if(z(q)){if(!N)return;q=new m,b.set(R,q),j=!0}var J=q.get($);if(z(J)){if(!N)return;if(J=new m,q.set($,J),!y.setProvider(R,$,E))throw q.delete($),j&&b.delete(R),new Error("Wrong provider for target.")}return J}function P(R,$,N){var q=x($,N,!1);return z(q)?!1:ma(q.has(R))}function ie(R,$,N){var q=x($,N,!1);if(!z(q))return q.get(R)}function ee(R,$,N,q){var j=x(N,q,!0);j.set(R,$)}function _(R,$){var N=[],q=x(R,$,!1);if(z(q))return N;for(var j=q.keys(),J=wa(j),Ne=0;;){var ka=Ca(J);if(!ka)return N.length=Ne,N;var np=ba(ka);try{N[Ne]=np}catch(ip){try{Sa(J)}finally{throw ip}}Ne++}}function I(R,$,N){var q=x($,N,!1);if(z(q)||!q.delete(R))return!1;if(q.size===0){var j=b.get($);z(j)||(j.delete(N),j.size===0&&b.delete(j))}return!0}}function Qm(y){var b=y.defineMetadata,E=y.hasOwnMetadata,x=y.getOwnMetadata,P=y.getOwnMetadataKeys,ie=y.deleteMetadata,ee=new p,_={isProviderFor:function(I,R){var $=ee.get(I);return!z($)&&$.has(R)?!0:P(I,R).length?(z($)&&($=new g,ee.set(I,$)),$.add(R),!0):!1},OrdinaryDefineOwnMetadata:b,OrdinaryHasOwnMetadata:E,OrdinaryGetOwnMetadata:x,OrdinaryOwnMetadataKeys:P,OrdinaryDeleteMetadata:ie};return _}function Ht(y,b,E){var x=w.getProvider(y,b);if(!z(x))return x;if(E){if(w.setProvider(y,b,B))return B;throw new Error("Illegal state.")}}function Km(){var y={},b=[],E=function(){function _(I,R,$){this._index=0,this._keys=I,this._values=R,this._selector=$}return _.prototype["@@iterator"]=function(){return this},_.prototype[a]=function(){return this},_.prototype.next=function(){var I=this._index;if(I>=0&&I<this._keys.length){var R=this._selector(this._keys[I],this._values[I]);return I+1>=this._keys.length?(this._index=-1,this._keys=b,this._values=b):this._index++,{value:R,done:!1}}return{value:void 0,done:!0}},_.prototype.throw=function(I){throw this._index>=0&&(this._index=-1,this._keys=b,this._values=b),I},_.prototype.return=function(I){return this._index>=0&&(this._index=-1,this._keys=b,this._values=b),{value:I,done:!0}},_}(),x=function(){function _(){this._keys=[],this._values=[],this._cacheKey=y,this._cacheIndex=-2}return Object.defineProperty(_.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),_.prototype.has=function(I){return this._find(I,!1)>=0},_.prototype.get=function(I){var R=this._find(I,!1);return R>=0?this._values[R]:void 0},_.prototype.set=function(I,R){var $=this._find(I,!0);return this._values[$]=R,this},_.prototype.delete=function(I){var R=this._find(I,!1);if(R>=0){for(var $=this._keys.length,N=R+1;N<$;N++)this._keys[N-1]=this._keys[N],this._values[N-1]=this._values[N];return this._keys.length--,this._values.length--,Zi(I,this._cacheKey)&&(this._cacheKey=y,this._cacheIndex=-2),!0}return!1},_.prototype.clear=function(){this._keys.length=0,this._values.length=0,this._cacheKey=y,this._cacheIndex=-2},_.prototype.keys=function(){return new E(this._keys,this._values,P)},_.prototype.values=function(){return new E(this._keys,this._values,ie)},_.prototype.entries=function(){return new E(this._keys,this._values,ee)},_.prototype["@@iterator"]=function(){return this.entries()},_.prototype[a]=function(){return this.entries()},_.prototype._find=function(I,R){if(!Zi(this._cacheKey,I)){this._cacheIndex=-1;for(var $=0;$<this._keys.length;$++)if(Zi(this._keys[$],I)){this._cacheIndex=$;break}}return this._cacheIndex<0&&R&&(this._cacheIndex=this._keys.length,this._keys.push(I),this._values.push(void 0)),this._cacheIndex},_}();return x;function P(_,I){return _}function ie(_,I){return I}function ee(_,I){return[_,I]}}function ep(){var y=function(){function b(){this._map=new m}return Object.defineProperty(b.prototype,"size",{get:function(){return this._map.size},enumerable:!0,configurable:!0}),b.prototype.has=function(E){return this._map.has(E)},b.prototype.add=function(E){return this._map.set(E,E),this},b.prototype.delete=function(E){return this._map.delete(E)},b.prototype.clear=function(){this._map.clear()},b.prototype.keys=function(){return this._map.keys()},b.prototype.values=function(){return this._map.keys()},b.prototype.entries=function(){return this._map.entries()},b.prototype["@@iterator"]=function(){return this.keys()},b.prototype[a]=function(){return this.keys()},b}();return y}function tp(){var y=16,b=h.create(),E=x();return function(){function I(){this._key=x()}return I.prototype.has=function(R){var $=P(R,!1);return $!==void 0?h.has($,this._key):!1},I.prototype.get=function(R){var $=P(R,!1);return $!==void 0?h.get($,this._key):void 0},I.prototype.set=function(R,$){var N=P(R,!0);return N[this._key]=$,this},I.prototype.delete=function(R){var $=P(R,!1);return $!==void 0?delete $[this._key]:!1},I.prototype.clear=function(){this._key=x()},I}();function x(){var I;do I="@@WeakMap@@"+_();while(h.has(b,I));return b[I]=!0,I}function P(I,R){if(!r.call(I,E)){if(!R)return;Object.defineProperty(I,E,{value:h.create()})}return I[E]}function ie(I,R){for(var $=0;$<R;++$)I[$]=Math.random()*255|0;return I}function ee(I){if(typeof Uint8Array=="function"){var R=new Uint8Array(I);return typeof crypto<"u"?crypto.getRandomValues(R):typeof msCrypto<"u"?msCrypto.getRandomValues(R):ie(R,I),R}return ie(new Array(I),I)}function _(){var I=ee(y);I[6]=I[6]&79|64,I[8]=I[8]&191|128;for(var R="",$=0;$<y;++$){var N=I[$];($===4||$===6||$===8)&&(R+="-"),N<16&&(R+="0"),R+=N.toString(16).toLowerCase()}return R}}function Xi(y){return y.__=void 0,delete y.__,y}})})(sr||(sr={}));let Wt;const Wa=new Uint8Array(16);function Ga(){if(!Wt&&(Wt=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Wt))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Wt(Wa)}const re=[];for(let t=0;t<256;++t)re.push((t+256).toString(16).slice(1));function ja(t,e=0){return re[t[e+0]]+re[t[e+1]]+re[t[e+2]]+re[t[e+3]]+"-"+re[t[e+4]]+re[t[e+5]]+"-"+re[t[e+6]]+re[t[e+7]]+"-"+re[t[e+8]]+re[t[e+9]]+"-"+re[t[e+10]]+re[t[e+11]]+re[t[e+12]]+re[t[e+13]]+re[t[e+14]]+re[t[e+15]]}const ar={randomUUID:typeof crypto<"u"&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function ue(t,e,n){if(ar.randomUUID&&!e&&!t)return ar.randomUUID();t=t||{};const r=t.random||(t.rng||Ga)();return r[6]=r[6]&15|64,r[8]=r[8]&63|128,ja(r)}let Z=(Fe=class{static BuildClass(e,n){n&&Object.keys(n).forEach(r=>{const o=n[r];if(this.isPrimitive(o))e[r]instanceof Date?e[r]=new Date(o):e[r]=o;else if(o!=null&&!Array.isArray(o))if(e[r]&&e[r].constructor)e[r]=new e[r].constructor(o);else{const s=Reflect.getMetadata(r,e);s&&(e[r]=new s[r](o))}if(Array.isArray(o)){const s=Reflect.getMetadata(r,e);s&&(e[r]=o.map(a=>new s[r](a)))}})}static isPrimitive(e){return e!==null&&typeof e<"u"&&e!==Object(e)}static RemoveFromClassByIndex(e,n,r){Fe.RemoveFromClass(e,n,r)}static RemoveFromClassById(e,n,r){if(!e)return;const o=n.findIndex(s=>s.id===e);Fe.RemoveFromClass(o,n,r)}static RemoveFromClass(e,n,r){if(e<0)return;const o=n[e].id;o&&r&&r.push(o),n.splice(e,1)}static GetPropertyName(e){const n=new e;return new Proxy(n,{get(r,o){return o}})}static CreateUUID(){return ue()}static InitClassInstance(e,n){const r=e.constructor(n);return Fe.BuildClass(r),r.id=Fe.CreateUUID(),r}static ExistsWithId(e,n){return e.some(r=>r.id===n)}},l(Fe,"GetClassConstructor",e=>(n,r)=>{const o=Reflect.getMetadata(`property:${r}`,n)||{};o[r]=e,Reflect.defineMetadata(r,o,n)}),Fe);class lr{constructor(e){l(this,"id");l(this,"name","");l(this,"surname","");l(this,"patronymic","");l(this,"citizenship","");l(this,"placeBirth","");l(this,"carNumber","");l(this,"carModel","");l(this,"snils","");l(this,"isMale",!0);l(this,"dateBirth",new Date);l(this,"contactId");l(this,"slug","");l(this,"postIndex","");l(this,"address","");l(this,"editNameMode",!1);Z.BuildClass(this,e)}setEditNameMode(e){this.editNameMode=e}getFullName(){return!this.surname.length&&!this.name.length&&!this.patronymic.length?"":`${this.surname} ${this.name} ${this.patronymic}`}getInitialsName(){return`${this.name.slice(0,1)}.${this.patronymic.slice(0,1)}. ${this.surname}`}getGender(e){return e?this.isMale?"Мужской":"Женский":this.isMale?"М":"Ж"}capitalizeName(){this.name=H.Strings.Capitalize(this.name),this.surname=H.Strings.Capitalize(this.surname),this.patronymic=H.Strings.Capitalize(this.patronymic)}trimName(){this.name=this.name.trim(),this.surname=this.surname.trim(),this.patronymic=this.patronymic.trim()}sanitizeName(){this.trimName(),this.capitalizeName()}setFullName(e){this.surname=e.surname,this.name=e.name,this.patronymic=e.patronymic}}const Za=Object.freeze(Object.defineProperty({__proto__:null,Auth:rr,AuthButtonLogin:Tn,AuthButtonRegister:zn,AuthFormSettings:ir,AuthFormStatuses:ge,AuthMethods:st,Email:Ue,EmailField:qt,FileInfo:ye,Human:lr,LoginField:Ua,PasswordField:Ut,PasswordRepeatField:nr},Symbol.toStringTag,{value:"Module"}));class Ja{constructor(){l(this,"title","");l(this,"buttons",[])}Set(e="",n){typeof e=="function"?this.title=e():typeof e=="string"?this.title=e:this.title=e.value,this.buttons=n}}const Xa=new Ja;class Ya{constructor(){l(this,"menu",[]);l(this,"path","");l(this,"isOpen",!0);l(this,"filterString","")}Set(e){this.menu=e}Get(){return this.filterString?this.filterMenu():this.menu}filterMenu(){return this.menu.filter(e=>{var n;return Strings.SearchIn(e.name,this.filterString)||((n=e.children)==null?void 0:n.some(r=>Strings.SearchIn(r.name,this.filterString)))})}IsOpen(){return this.isOpen}Toggle(){this.isOpen=!this.isOpen}SetPath(e){this.path=e}GetPath(){return this.path}SetFilter(e){this.filterString=e}GetChildren(e){var n;return this.filterString?(n=e.children)==null?void 0:n.filter(r=>Strings.SearchIn(r.name,this.filterString)):e.children}}const Qa=new Ya;class Ka{constructor(){l(this,"Menu",Qa);l(this,"Head",Xa)}}const el=new Ka;class cr{constructor(){l(this,"visible",!1)}hide(){this.visible=!1}show(){this.hide(),this.visible=!0}IsVisible(){return this.visible}}class dr extends cr{constructor(){super(...arguments);l(this,"type",le.Success);l(this,"text","");l(this,"title","")}showMessage(n,r){this.hide(),this.type=r,typeof n=="string"?this.text=n:(this.text=n.text,this.title=n.title??""),super.show()}GetText(){return this.text}GetTitle(){return this.title}GetType(){return this.type}Info(n){this.showMessage(n,le.Info)}Success(n){this.showMessage(n,le.Success)}Error(n){this.showMessage(n,le.Error)}Warning(n){this.showMessage(n,le.Warning)}FormMessage(n){let r="<strong>Проверьте правильность введенных данных:</strong><ul>";for(const o of Object.keys(n))n[o][0]&&n[o][0].message&&(r+=`<li>${n[o][0].message}</li>`);return r+="</ul>",r}}class tl extends dr{constructor(){super(...arguments);l(this,"confirmButtonText","Да");l(this,"cancelButtonText","Нет");l(this,"resolve");l(this,"reject")}GetConfirmButtonText(){return this.confirmButtonText}GetCancelButtonText(){return this.cancelButtonText}Show(n){return super.show(),typeof n!="string"&&(this.confirmButtonText=n.confirmButtonText,this.cancelButtonText=n.cancelButtonText),new Promise((r,o)=>{this.resolve=r,this.reject=o})}Save(){return this.Show({text:"У вас есть несохранённые изменения",confirmButtonText:"Сохранить",cancelButtonText:"Не сохранять"})}Submit(){this.resolve(!0),this.hide()}Cancel(){this.reject(),this.hide()}hide(){this.resolve=void 0,this.reject=void 0,super.hide()}}const nl=new tl;class at{constructor(e){l(this,"id");l(this,"number");l(this,"description");l(this,"contactId");Classes.BuildClass(this,e)}static Create(){const e=new at;return e.id=Classes.CreateUUID(),e}}class Vn{constructor(e){l(this,"id");l(this,"address");l(this,"description");Classes.BuildClass(this,e)}}class ur{constructor(e){l(this,"id");l(this,"address");l(this,"description");Classes.BuildClass(this,e)}}var il=Object.defineProperty,Gt=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&il(e,n,o),o};const vt=class Ea{constructor(e){l(this,"id");l(this,"description","");l(this,"time","");l(this,"latitude","");l(this,"longitude","");l(this,"emails",[]);l(this,"postAddresses",[new Vn]);l(this,"phones",[]);l(this,"websites",[]);Z.BuildClass(this,e)}addEmail(){const e=Ue.Create();return e.contactId=this.id,this.emails.push(e),e}addPhone(){const e=at.Create();return e.contactId=this.id,this.phones.push(e),e}static Create(){const e=new Ea;return e.id=Z.CreateUUID(),e}removeEmail(e){Z.RemoveFromClassById(e,this.emails)}removePhone(e){Z.RemoveFromClassById(e,this.phones)}addPostAddress(){this.postAddresses.push(new Vn)}addWebsite(){this.websites.push(new ur)}pushFirst(){this.emails.length||this.emails.push(new Ue),this.phones.length||this.phones.push(new at)}getCoords(){return[Number(this.latitude),Number(this.longitude)]}updateDescription(e){this.description=e}updateTime(e){this.time=e}updateLatitude(e){this.latitude=e}updateLongitutde(e){this.longitude=e}};Gt([Z.GetClassConstructor(Ue)],vt.prototype,"emails"),Gt([Z.GetClassConstructor(Vn)],vt.prototype,"postAddresses"),Gt([Z.GetClassConstructor(at)],vt.prototype,"phones"),Gt([Z.GetClassConstructor(ur)],vt.prototype,"websites");let Fn=vt;var X=(t=>(t.Date="date",t.String="string",t.Boolean="boolean",t.Number="number",t.Set="set",t.Join="join",t))(X||{}),ce=(t=>(t.Eq="=",t.Ne="!=",t.Gt=">",t.Lt="<",t.Btw="between",t.In="in",t.Like="like",t.Null="is null",t.NotNull="is not null",t))(ce||{});class We{static Shuffle(e){for(let n=e.length-1;n>0;n--){const r=Math.floor(Math.random()*(n+1));[e[n],e[r]]=[e[r],e[n]]}}static GenerateNumsRange(e,n,r=1){return Array.from({length:(n-e)/r+1},(o,s)=>e+s*r)}static GetLast(e){return e[e.length-1]}static GetFirst(e){return e[0]}static GetRandEL(e){return e[Math.floor(Math.random()*e.length)]}static Sort(e){e.forEach((n,r)=>n.order=r)}static Refill(e,n){e.splice(0,e.length),e.push(...n)}static Eq(e,n){return e.length===n.length&&(e==null?void 0:e.every((r,o)=>e[o]==n[o]))}static SwipeById(e,n,r){const o=e.findIndex(a=>n.id===a.id),s=e.findIndex(a=>r.id===a.id);o||s||([e[o],e[s]]=[e[s],e[o]])}static Swap(e,n,r){if(n<0||n>=e.length||r<0||r>=e.length)return;const o=e[n];e[n]=e[r],e[r]=o}static MoveUp(e,n){e[n].order=n-1,e[n-1]&&(e[n-1].order=n),[e[n],e[n-1]]=[e[n-1],e[n]]}static MoveDown(e,n){e[n].order=n+1,e[n+1]&&(e[n+1].order=n),[e[n],e[n+1]]=[e[n+1],e[n]]}}let Dn=class qe{static Capitalize(e){return e?e[0].toUpperCase()+e.slice(1):""}static ToCamelCase(e){const n=new RegExp(["[А-Я][а-я][A-Z][a-z]+","[А-Я]+(?=[А-Я][а-я])","[A-Z]+(?=[A-Z][a-z])","[А-Я]+","[A-Z]+","[а-я]+","[a-z]+","[0-9]+"].join("|"),"g");return e.match(n).map((o,s)=>s===0?o.toLowerCase():qe.Capitalize(o.toLowerCase())).join("")}static ToKebabCase(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase()}static GetStringBetweenChars(e,n,r){return e.substring(e.indexOf(n)+2,e.lastIndexOf(r))}static Translit(e,n){const r={q:"й",w:"ц",e:"у",r:"к",t:"е",y:"н",u:"г",i:"ш",o:"щ",p:"з","[":"х","]":"ъ",a:"ф",s:"ы",d:"в",f:"а",g:"п",h:"р",j:"о",k:"л",l:"д",";":"ж","'":"э",z:"я",x:"ч",c:"с",v:"м",b:"и",n:"т",m:"ь",",":"б",".":"ю","/":"."};return n&&/[а-яА-Я]/g.test(e)?e.replace(/[А-я/,.;'\][]/g,o=>{if(o===o.toLowerCase()){const a=Object.keys(r).find(d=>r[d]===o);return a||""}const s=Object.keys(r).find(a=>r[a]===o.toLowerCase());return s?s.toUpperCase():""}):e.replace(/[A-z/,.;'\][]/g,o=>o===o.toLowerCase()?r[o]:r[o.toLowerCase()].toUpperCase())}static RemoveEmoji(e){const n=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;return e.replace(n,"")}static CanBeTranslited(e){return/^[~`!@#$%^&*()_+=[\]\\{}|;':",.\/<>?a-zA-Z0-9-]+$/.test(e)}static StringsEquals(e,n){const r=e.toLowerCase().replaceAll(/\s/g,""),o=n.toLowerCase().replaceAll(/\s/g,""),s=qe.Translit(r),a=qe.Translit(o);return r.includes(o)||s.includes(o)||r.includes(a)}static SearchIn(e,n){return qe.StringsEquals(e,n)}static FormatToPercentage(e){return`${e}%`}static WrapSubStr(e,n){const r=new RegExp(qe.GetVariants(n).join("|"),"gi");return e.replace(r,`<span class="search-text">${n}</span>`)}static GetVariants(e){const n=qe.Translit(e);return[e,qe.Capitalize(e),e.toLowerCase(),e.toUpperCase(),n,qe.Capitalize(n),n.toLowerCase(),n.toUpperCase()]}static ContainsNum(e){return/\d/.test(e)}static CreateGuid(){const e=function(){return((1+Math.random())*65536|0).toString(16).substring(1)};return e()+e()+"-"+e()+"-"+e()+"-"+e()+"-"+e()+e()+e()}static JoinSnake(...e){return e.join("_")}static GetDynamicCountName(e,n){const r=[2,0,1,1,1,2];return e.length+" "+n[e.length%100>4&&e.length%100<20?2:r[e.length%10<5?e.length%10:5]]}};var rl=Object.defineProperty,ol=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&rl(e,n,o),o};const hr=class Et{constructor(e){l(this,"id");l(this,"model","");l(this,"label","");l(this,"col","");l(this,"operator",ce.Eq);l(this,"date1");l(this,"date2");l(this,"value1","");l(this,"boolean",!1);l(this,"number",0);l(this,"type",X.String);l(this,"set",[]);l(this,"isSet",!1);l(this,"joinTable","");l(this,"joinTableModel","");l(this,"joinTableFk","");l(this,"joinTablePk","");l(this,"joinTableId","");l(this,"joinTableIdCol","");Z.BuildClass(this,e)}eq(e){if(!e)return!1;if(this.type===X.Join){const n=e.model===this.model&&e.operator===this.operator&&this.joinTableModel===e.joinTableModel;return e.operator===ce.In?n&&We.Eq(this.set,e.set):n}return e.model===this.model&&e.col===this.col&&e.operator===this.operator}valueEq(e){return!this||!e||!this.eq(e)?!1:this.type===X.Boolean?this.boolean===(e==null?void 0:e.boolean):this.type===X.String?this.value1===(e==null?void 0:e.value1):this.type===X.Join&&this.set.length?We.Eq(this.set,e.set):!1}toUrlQuery(){const e=this.type?`"type":"${this.type}"`:"",n=this.model?`"model":"${this.model}"`:"",r=this.col?`"col":"${this.col}"`:"",o=this.operator?`"operator":"${this.operator}"`:"",s=this.value1?`"value1":"${this.value1}"`:"",a=this.type===X.Boolean?`"boolean":${this.boolean}`:"",d=this.type===X.Date&&this.date1?`"date1":"${this.date1.toISOString()}"`:"",c=this.type===X.Date&&this.date2?`"date2":"${this.date2.toISOString()}"`:"",u=this.type===X.Number?`"number":${this.number}`:"",h=this.type===X.Set||this.operator===ce.In?`"set":${JSON.stringify(this.set)}`:"",f=this.type===X.Join?`"joinTableModel":"${this.joinTableModel}"`:"";return[e,n,r,o,s,a,d,c,u,h,f].filter(m=>m!=="").toString()}fromUrlQuery(e){this.model=e.get("model")??"",this.col=e.get("col")??"",this.label=e.get("label")??"",this.operator=e.get("operator")??"",this.value1=e.get("value1")??"",this.type=e.get("type")??"",this.boolean=!!(e.get("boolean")??""),this.joinTableModel=e.get("joinTableModel")??"",this.joinTableId=e.get("joinTableId")??"",this.joinTableFk=e.get("joinTableFk")??"",this.joinTableIdCol=e.get("joinTableIdCol")??"",this.joinTablePk=e.get("joinTablePk")??""}isUnaryFilter(){return this.operator===ce.Eq||this.operator===ce.Gt||this.operator===ce.Lt}isBetweenFilter(){return this.operator===ce.Btw}isSetFilter(){return this.operator===ce.In}static Create(e,n,r){const o=new Et;return o.model=e.GetClassName(),o.col=n??"",o.type=r,o.type===X.Number&&(o.value1="0"),o.type===X.String&&(o.value1=""),o.type===X.Boolean&&(o.value1="false",o.operator=ce.Eq),o}static CreateFilterModel(e,n,r){const o=new Et;return o.id=ue(),o.model=typeof e=="string"?e:e.GetClassName(),o.col=n??"",o.type=r,o.type===X.Number&&(o.value1="0"),o.type===X.String&&(o.value1=""),o.type===X.Boolean&&(o.value1="false"),o}static CreateFilterModelWithJoin(e,n,r,o,s,a,d,c){const u=new Et;return u.id=ue(),u.joinTable=r,u.joinTablePk=o,u.joinTableFk=s,u.col=n,u.type=a,d&&(u.joinTableId=d),c&&(u.joinTableIdCol=c),u}static CreateFilterModelWithJoinV2(e,n,r,o,s,a,d){const c=new Et;return c.model=e,c.joinTableModel=r,c.joinTablePk=o,c.joinTableFk=s,c.col=n,c.type=X.Join,a&&(c.joinTableId=a),d&&(c.joinTableIdCol=d),c}static OnlyIfSecondModelExists(e,n){const r=new Et;return r.id=ue(),r.model=Dn.ToCamelCase(e.GetClassName()),r.joinTableModel=Dn.ToCamelCase(n.GetClassName()),r.type=X.Join,r}addToSet(...e){e.forEach(n=>{if(this.set.indexOf(n)===-1){this.set.push(n);return}this.set=this.set.filter(r=>r!==n)})}pushToSet(...e){e.forEach(n=>{this.set.indexOf(n)===-1&&this.set.push(n)})}replaceSet(...e){this.set=e}setBoolean(e){this.boolean=e}toRef(){return i.ref(this)}setDate1(e){this.date1=e}setDate2(e){this.date2=e}dropDates(){this.setDate1(),this.setDate2()}setDatesRange(e,n){if(!e&&!n){this.dropDates();return}if(!n){this.setDate1(e),this.operator=ce.Eq;return}this.setDate2(n),this.operator=ce.Btw}};ol([Z.GetClassConstructor(String)],hr.prototype,"set");let Ln=hr;class sl{constructor(){l(this,"operation",ce.Lt);l(this,"column","");l(this,"value");l(this,"initial",!0);l(this,"tableName","");l(this,"version","");l(this,"model","")}toUrlQuery(){const e=this.operation?`"operation":"${this.operation}"`:"",n=this.column?`"column":"${this.column}"`:"",r=this.value&&typeof this.value.toISOString=="function"?this.value.toISOString():this.value,o=r?`"value":"${r}"`:"",s=this.model?`"model":"${this.model}"`:"",a=`"initial":${this.initial}`;return[e,n,o,s,a].filter(d=>d!=="").toString()}fromUrlQuery(e){e.cursvalue&&(this.value=e.cursvalue),e.curscolumn&&(this.column=String(e.curscolumn)),e.cursinitial!==void 0&&(this.initial=!!e.cursinitial),e.curstableName&&(this.tableName=String(e.curstableName)),e.cursoperation&&(this.operation=e.cursoperation)}}class jt{constructor(e){l(this,"offset",0);l(this,"limit",25);l(this,"cursor",new sl);l(this,"cursorMode",!1);l(this,"append",!1);l(this,"allLoaded",!1);l(this,"version","");Z.BuildClass(this,e)}setLoadMore(e,n,r){this.cursor.value=e,this.cursor.initial=!1,this.cursor.operation=ce.Gt,this.cursor.column=n,this.cursor.tableName=r,this.cursorMode=!0}setLoadMoreV2(e,n,r){this.cursor.value=e,this.cursor.initial=!1,this.cursor.operation=ce.Gt,this.cursor.column=n,this.cursor.model=r,this.cursorMode=!0,this.version="v2"}setOffset(e){this.offset=e}toUrlQuery(){const e=`"offset":${this.offset}`,n=`"limit":${this.limit}`,r=`"cursorMode":${this.cursorMode}`,o=`"append":${this.append}`,s=`"allLoaded":${this.allLoaded}`,a=`"cursor":{${this.cursor.toUrlQuery()}}`;return[e,n,r,o,s,a].toString()}fromUrlQuery(){const e=window.location.search,n=e.substring(e.indexOf("p=")+2,e.lastIndexOf("|")),r=new URLSearchParams(decodeURIComponent(n));this.offset=Number(r.get("offset")),this.limit=Number(r.get("col"))}setAllLoaded(e){this.allLoaded=!(e>=this.limit)}resetAllLoaded(){this.allLoaded=!1}getPageNum(){return this.offset/this.limit+1}drop(){this.offset=0,this.limit=25,Z.BuildClass(this)}}class Zt{constructor(){l(this,"model","");l(this,"cols",[]);l(this,"models",[])}static Create(e,n){const r=new Zt;return r.model=e.GetClassName(),r.cols=n,r}}var Ae=(t=>(t.Asc="asc",t.Desc="desc",t))(Ae||{});class Jt{constructor(e){l(this,"model","");l(this,"col","");l(this,"order");l(this,"label","");l(this,"default",!1);l(this,"selected",!1);Classes.BuildClass(this,e)}static Create(e,n,r=Ae.Asc,o,s){const a=new Jt;return a.model=e.GetClassName(),a.col=n??"",a.order=r??Ae.Asc,a.label=o??"",a.default=s??!1,a}isAsc(){return this.order===Ae.Asc}isDesc(){return this.order===Ae.Desc}eq(e){return e.model===this.model&&e.col===this.col&&e.order===this.order}toUrlQuery(){const e=this.model?`"model":"${this.model}"`:"",n=this.col?`"col":"${this.col}"`:"",r=this.order?`"order":"${this.order}"`:"";return[e,n,r].toString()}async fromUrlQuery(){const e=window.location.search,n=e.substring(e.indexOf("s=")+2,e.indexOf("|")),r=new URLSearchParams(decodeURIComponent(n));this.model=r.get("model")??"",this.col=r.get("col")??"",this.label=r.get("label")??"",this.default=!!r.get("default"),this.order=r.get("order")??""}}var al=Object.defineProperty,Xt=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&al(e,n,o),o};const Mt=(Re=class{constructor(e){l(this,"id");l(this,"f",[]);l(this,"s",[]);l(this,"p",new jt);l(this,"t",new Zt);Z.BuildClass(this,e)}static Get(){return this.instance||(this.instance=new Re),this.instance}createFrom(e){const n=new Re(JSON.parse(e));this.f=n.f}clearForHTTP(){const e=new Re(this);return e.f=this.f.map(n=>H.FTSP.EmptyEntiries(n)),e.s=this.s.map(n=>H.FTSP.EmptyEntiries(n)),e.p=Re.EmptyEntiries(this.p),e.t=Re.EmptyEntiries(this.t),e}static EmptyEntiries(e){if(!e)return;const r=Object.entries(e).filter(([o,s])=>o!=="label"&&s!==""&&s!==null);return Object.fromEntries(r)}findFilterModel(e){return this.f.find(n=>e.id===n.id)}getFirstSortModel(){return We.GetLast(this.s)}setSortModel(e){e&&(this.s[0]=e)}setS(e){this.s[0]=e}setF(e){this.f.push(e)}replaceF(e,n){this.removeF(n),e&&this.setF(e)}removeF(e){const n=this.f.findIndex(r=>r.eq(e));Z.RemoveFromClassByIndex(n,this.f)}reset(){this.f=[],this.s=[],this.p=new jt}resetF(){this.f=[]}},l(Re,"instance"),Re);Xt([Z.GetClassConstructor(Ln)],Mt.prototype,"f"),Xt([Z.GetClassConstructor(Jt)],Mt.prototype,"s"),Xt([Z.GetClassConstructor(jt)],Mt.prototype,"p"),Xt([Z.GetClassConstructor(Zt)],Mt.prototype,"t");let fr=Mt;var mr=(t=>(t.simple="simple",t.oneToMany="oneToMany",t.manyToMany="manyToMany",t))(mr||{}),de=(t=>(t.String="string",t.Text="text",t.Number="number",t.Date="date",t.DateTime="dateTime",t.Radio="radio",t.Set="set",t.Boolean="boolean",t.Files="files",t.File="file",t.MatrixRadio="matrixRadio",t.MatrixSet="matrixSet",t))(de||{});class On{constructor(e){l(this,"id");l(this,"name",de.String);l(this,"valueRelation",mr.simple);Classes.BuildClass(this,e)}isString(){return this.name==="string"}isNumber(){return this.name==="number"}isDate(){return this.name==="date"}isDateTime(){return this.name==="dateTime"}isRadio(){return this.name==="radio"}isSet(){return this.name==="set"}isText(){return this.name==="text"}isBoolean(){return this.name==="boolean"}isFile(){return this.name==="file"}isFiles(){return this.name==="files"}getComponentType(){if(this.name===de.Radio)return"RadioProp";if(this.name===de.Set)return"SetProp";if(this.name===de.Number)return"NumberProp";if(this.name===de.String)return"StringProp"}}/*!
15
15
  * vue-router v4.4.5
16
16
  * (c) 2024 Eduardo San Martin Morote
17
17
  * @license MIT
18
- */function fr(t){const e=Array.from(arguments).slice(1);console.warn.apply(console,["[Vue Router warn]: "+t].concat(e))}var mr;(function(t){t.pop="pop",t.push="push"})(mr||(mr={}));var pr;(function(t){t.back="back",t.forward="forward",t.unknown=""})(pr||(pr={})),Symbol(process.env.NODE_ENV!=="production"?"navigation failure":"");var gr;(function(t){t[t.aborted=4]="aborted",t[t.cancelled=8]="cancelled",t[t.duplicated=16]="duplicated"})(gr||(gr={}));const al=Symbol(process.env.NODE_ENV!=="production"?"router view location matched":"");Symbol(process.env.NODE_ENV!=="production"?"router view depth":""),Symbol(process.env.NODE_ENV!=="production"?"router":""),Symbol(process.env.NODE_ENV!=="production"?"route location":""),Symbol(process.env.NODE_ENV!=="production"?"router view location":"");function ll(t,e,n){const r=()=>{t[e].delete(n)};i.onUnmounted(r),i.onDeactivated(r),i.onActivated(()=>{t[e].add(n)}),t[e].add(n)}function cl(t){if(process.env.NODE_ENV!=="production"&&!i.getCurrentInstance()){fr("getCurrentInstance() returned null. onBeforeRouteLeave() must be called at the top of a setup function");return}const e=i.inject(al,{}).value;if(!e){process.env.NODE_ENV!=="production"&&fr("No active route record was found when calling `onBeforeRouteLeave()`. Make sure you call this function inside a component child of <router-view>. Maybe you called it inside of App.vue?");return}ll(e,"leaveGuards",t)}function yr(t,e){const n=[],r=e||Ie.Asc,o=r===Ie.Asc?Ie.Desc:Ie.Asc;return Object.values(t).forEach(s=>{n.push(s(r)),n.push(s(o))}),n.length>0&&!n.some(s=>s.default)&&(n[0].default=!0),e&&n.forEach(s=>{s.default&&(s.default=s.order===e)}),n}class dl{constructor(){l(this,"list",[]);l(this,"defaultSortModel");l(this,"changeFlag",!1)}Set(e){this.Reset(),e&&(Array.isArray(e)?this.list=e:this.list=yr(e),this.SetDefault())}SetDefault(){this.defaultSortModel=this.list.find(e=>e.default)??this.list[0],this.changeFlag=!this.changeFlag}Get(){return this.list}GetDefault(){return this.defaultSortModel}Reset(){this.list=[],this.defaultSortModel=void 0}}const Re=new dl;function wr(){const t=i.ref(!1),e=i.ref(!1);return{confirmLeave:t,saveButtonClick:e,beforeWindowUnload:s=>{t.value&&s.preventDefault()},formUpdated:()=>{t.value=!0},showConfirmModal:(s,a)=>{t.value&&!e.value?s():a()}}}const ul=(()=>{const t=(s,a)=>i.onBeforeMount(async()=>{var d;m.H.FTSP.Get().reset(),Re.Set(a==null?void 0:a.sortsLib),m.H.FTSP.Get().setSortModel(Re.GetDefault()),Re.Set(a==null?void 0:a.sortsLib),m.H.FTSP.Get().setSortModel(Re.GetDefault()),m.Paginator.storeModule=(d=a==null?void 0:a.pagination)==null?void 0:d.storeModule,await s()}),{saveButtonClick:e,showConfirmModal:n}=wr(),r=s=>cl((a,d,c)=>{n((s||o)(),c)}),o=s=>async()=>{e.value=!0;try{s&&await s(),m.Notification.Success("Сохранено")}catch(a){m.Notification.Success("Что-то пошло не так. "+a);return}};return{onBeforeMount:t,onBeforeRouteLeave:r,submit:o}})();var Ln=(t=>(t.XS="xs",t.S="s",t.M="m",t.L="l",t.XL="xl",t))(Ln||{});function br(t,e){return function(){return t.apply(e,arguments)}}const{toString:hl}=Object.prototype,{getPrototypeOf:Hn}=Object,Xt=(t=>e=>{const n=hl.call(e);return t[n]||(t[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Me=t=>(t=t.toLowerCase(),e=>Xt(e)===t),Yt=t=>e=>typeof e===t,{isArray:at}=Array,Mt=Yt("undefined");function fl(t){return t!==null&&!Mt(t)&&t.constructor!==null&&!Mt(t.constructor)&&ge(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const Cr=Me("ArrayBuffer");function ml(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&Cr(t.buffer),e}const pl=Yt("string"),ge=Yt("function"),Sr=Yt("number"),Qt=t=>t!==null&&typeof t=="object",gl=t=>t===!0||t===!1,Kt=t=>{if(Xt(t)!=="object")return!1;const e=Hn(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)},yl=Me("Date"),wl=Me("File"),bl=Me("Blob"),Cl=Me("FileList"),Sl=t=>Qt(t)&&ge(t.pipe),kl=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||ge(t.append)&&((e=Xt(t))==="formdata"||e==="object"&&ge(t.toString)&&t.toString()==="[object FormData]"))},El=Me("URLSearchParams"),[vl,Ml,xl,Bl]=["ReadableStream","Request","Response","Headers"].map(Me),Il=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function xt(t,e,{allOwnKeys:n=!1}={}){if(t===null||typeof t>"u")return;let r,o;if(typeof t!="object"&&(t=[t]),at(t))for(r=0,o=t.length;r<o;r++)e.call(null,t[r],r,t);else{const s=n?Object.getOwnPropertyNames(t):Object.keys(t),a=s.length;let d;for(r=0;r<a;r++)d=s[r],e.call(null,t[d],d,t)}}function kr(t,e){e=e.toLowerCase();const n=Object.keys(t);let r=n.length,o;for(;r-- >0;)if(o=n[r],e===o.toLowerCase())return o;return null}const Ze=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Er=t=>!Mt(t)&&t!==Ze;function On(){const{caseless:t}=Er(this)&&this||{},e={},n=(r,o)=>{const s=t&&kr(e,o)||o;Kt(e[s])&&Kt(r)?e[s]=On(e[s],r):Kt(r)?e[s]=On({},r):at(r)?e[s]=r.slice():e[s]=r};for(let r=0,o=arguments.length;r<o;r++)arguments[r]&&xt(arguments[r],n);return e}const Rl=(t,e,n,{allOwnKeys:r}={})=>(xt(e,(o,s)=>{n&&ge(o)?t[s]=br(o,n):t[s]=o},{allOwnKeys:r}),t),$l=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),Nl=(t,e,n,r)=>{t.prototype=Object.create(e.prototype,r),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),n&&Object.assign(t.prototype,n)},Al=(t,e,n,r)=>{let o,s,a;const d={};if(e=e||{},t==null)return e;do{for(o=Object.getOwnPropertyNames(t),s=o.length;s-- >0;)a=o[s],(!r||r(a,t,e))&&!d[a]&&(e[a]=t[a],d[a]=!0);t=n!==!1&&Hn(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},Pl=(t,e,n)=>{t=String(t),(n===void 0||n>t.length)&&(n=t.length),n-=e.length;const r=t.indexOf(e,n);return r!==-1&&r===n},Tl=t=>{if(!t)return null;if(at(t))return t;let e=t.length;if(!Sr(e))return null;const n=new Array(e);for(;e-- >0;)n[e]=t[e];return n},zl=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&Hn(Uint8Array)),Vl=(t,e)=>{const r=(t&&t[Symbol.iterator]).call(t);let o;for(;(o=r.next())&&!o.done;){const s=o.value;e.call(t,s[0],s[1])}},Fl=(t,e)=>{let n;const r=[];for(;(n=t.exec(e))!==null;)r.push(n);return r},Dl=Me("HTMLFormElement"),Ll=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),vr=(({hasOwnProperty:t})=>(e,n)=>t.call(e,n))(Object.prototype),Hl=Me("RegExp"),Mr=(t,e)=>{const n=Object.getOwnPropertyDescriptors(t),r={};xt(n,(o,s)=>{let a;(a=e(o,s,t))!==!1&&(r[s]=a||o)}),Object.defineProperties(t,r)},Ol=t=>{Mr(t,(e,n)=>{if(ge(t)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=t[n];if(ge(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},_l=(t,e)=>{const n={},r=o=>{o.forEach(s=>{n[s]=!0})};return at(t)?r(t):r(String(t).split(e)),n},ql=()=>{},Ul=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e,_n="abcdefghijklmnopqrstuvwxyz",xr="0123456789",Br={DIGIT:xr,ALPHA:_n,ALPHA_DIGIT:_n+_n.toUpperCase()+xr},Wl=(t=16,e=Br.ALPHA_DIGIT)=>{let n="";const{length:r}=e;for(;t--;)n+=e[Math.random()*r|0];return n};function Gl(t){return!!(t&&ge(t.append)&&t[Symbol.toStringTag]==="FormData"&&t[Symbol.iterator])}const jl=t=>{const e=new Array(10),n=(r,o)=>{if(Qt(r)){if(e.indexOf(r)>=0)return;if(!("toJSON"in r)){e[o]=r;const s=at(r)?[]:{};return xt(r,(a,d)=>{const c=n(a,o+1);!Mt(c)&&(s[d]=c)}),e[o]=void 0,s}}return r};return n(t,0)},Zl=Me("AsyncFunction"),Jl=t=>t&&(Qt(t)||ge(t))&&ge(t.then)&&ge(t.catch),Ir=((t,e)=>t?setImmediate:e?((n,r)=>(Ze.addEventListener("message",({source:o,data:s})=>{o===Ze&&s===n&&r.length&&r.shift()()},!1),o=>{r.push(o),Ze.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",ge(Ze.postMessage)),Xl=typeof queueMicrotask<"u"?queueMicrotask.bind(Ze):typeof process<"u"&&process.nextTick||Ir,S={isArray:at,isArrayBuffer:Cr,isBuffer:fl,isFormData:kl,isArrayBufferView:ml,isString:pl,isNumber:Sr,isBoolean:gl,isObject:Qt,isPlainObject:Kt,isReadableStream:vl,isRequest:Ml,isResponse:xl,isHeaders:Bl,isUndefined:Mt,isDate:yl,isFile:wl,isBlob:bl,isRegExp:Hl,isFunction:ge,isStream:Sl,isURLSearchParams:El,isTypedArray:zl,isFileList:Cl,forEach:xt,merge:On,extend:Rl,trim:Il,stripBOM:$l,inherits:Nl,toFlatObject:Al,kindOf:Xt,kindOfTest:Me,endsWith:Pl,toArray:Tl,forEachEntry:Vl,matchAll:Fl,isHTMLForm:Dl,hasOwnProperty:vr,hasOwnProp:vr,reduceDescriptors:Mr,freezeMethods:Ol,toObjectSet:_l,toCamelCase:Ll,noop:ql,toFiniteNumber:Ul,findKey:kr,global:Ze,isContextDefined:Er,ALPHABET:Br,generateString:Wl,isSpecCompliantForm:Gl,toJSONObject:jl,isAsyncFn:Zl,isThenable:Jl,setImmediate:Ir,asap:Xl};function F(t,e,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o,this.status=o.status?o.status:null)}S.inherits(F,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:S.toJSONObject(this.config),code:this.code,status:this.status}}});const Rr=F.prototype,$r={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{$r[t]={value:t}}),Object.defineProperties(F,$r),Object.defineProperty(Rr,"isAxiosError",{value:!0}),F.from=(t,e,n,r,o,s)=>{const a=Object.create(Rr);return S.toFlatObject(t,a,function(c){return c!==Error.prototype},d=>d!=="isAxiosError"),F.call(a,t.message,e,n,r,o),a.cause=t,a.name=t.name,s&&Object.assign(a,s),a};const Yl=null;function qn(t){return S.isPlainObject(t)||S.isArray(t)}function Nr(t){return S.endsWith(t,"[]")?t.slice(0,-2):t}function Ar(t,e,n){return t?t.concat(e).map(function(o,s){return o=Nr(o),!n&&s?"["+o+"]":o}).join(n?".":""):e}function Ql(t){return S.isArray(t)&&!t.some(qn)}const Kl=S.toFlatObject(S,{},null,function(e){return/^is[A-Z]/.test(e)});function en(t,e,n){if(!S.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,n=S.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(k,b){return!S.isUndefined(b[k])});const r=n.metaTokens,o=n.visitor||h,s=n.dots,a=n.indexes,c=(n.Blob||typeof Blob<"u"&&Blob)&&S.isSpecCompliantForm(e);if(!S.isFunction(o))throw new TypeError("visitor must be a function");function u(g){if(g===null)return"";if(S.isDate(g))return g.toISOString();if(!c&&S.isBlob(g))throw new F("Blob is not supported. Use a Buffer instead.");return S.isArrayBuffer(g)||S.isTypedArray(g)?c&&typeof Blob=="function"?new Blob([g]):Buffer.from(g):g}function h(g,k,b){let B=g;if(g&&!b&&typeof g=="object"){if(S.endsWith(k,"{}"))k=r?k:k.slice(0,-2),g=JSON.stringify(g);else if(S.isArray(g)&&Ql(g)||(S.isFileList(g)||S.endsWith(k,"[]"))&&(B=S.toArray(g)))return k=Nr(k),B.forEach(function(L,V){!(S.isUndefined(L)||L===null)&&e.append(a===!0?Ar([k],V,s):a===null?k:k+"[]",u(L))}),!1}return qn(g)?!0:(e.append(Ar(b,k,s),u(g)),!1)}const f=[],p=Object.assign(Kl,{defaultVisitor:h,convertValue:u,isVisitable:qn});function y(g,k){if(!S.isUndefined(g)){if(f.indexOf(g)!==-1)throw Error("Circular reference detected in "+k.join("."));f.push(g),S.forEach(g,function(B,D){(!(S.isUndefined(B)||B===null)&&o.call(e,B,S.isString(D)?D.trim():D,k,p))===!0&&y(B,k?k.concat(D):[D])}),f.pop()}}if(!S.isObject(t))throw new TypeError("data must be an object");return y(t),e}function Pr(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function Un(t,e){this._pairs=[],t&&en(t,this,e)}const Tr=Un.prototype;Tr.append=function(e,n){this._pairs.push([e,n])},Tr.toString=function(e){const n=e?function(r){return e.call(this,r,Pr)}:Pr;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function ec(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function zr(t,e,n){if(!e)return t;const r=n&&n.encode||ec,o=n&&n.serialize;let s;if(o?s=o(e,n):s=S.isURLSearchParams(e)?e.toString():new Un(e,n).toString(r),s){const a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+s}return t}class Vr{constructor(){this.handlers=[]}use(e,n,r){return this.handlers.push({fulfilled:e,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){S.forEach(this.handlers,function(r){r!==null&&e(r)})}}const Fr={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},tc={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:Un,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},Wn=typeof window<"u"&&typeof document<"u",Gn=typeof navigator=="object"&&navigator||void 0,nc=Wn&&(!Gn||["ReactNative","NativeScript","NS"].indexOf(Gn.product)<0),ic=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",rc=Wn&&window.location.href||"http://localhost",de={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Wn,hasStandardBrowserEnv:nc,hasStandardBrowserWebWorkerEnv:ic,navigator:Gn,origin:rc},Symbol.toStringTag,{value:"Module"})),...tc};function oc(t,e){return en(t,new de.classes.URLSearchParams,Object.assign({visitor:function(n,r,o,s){return de.isNode&&S.isBuffer(n)?(this.append(r,n.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)}},e))}function sc(t){return S.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function ac(t){const e={},n=Object.keys(t);let r;const o=n.length;let s;for(r=0;r<o;r++)s=n[r],e[s]=t[s];return e}function Dr(t){function e(n,r,o,s){let a=n[s++];if(a==="__proto__")return!0;const d=Number.isFinite(+a),c=s>=n.length;return a=!a&&S.isArray(o)?o.length:a,c?(S.hasOwnProp(o,a)?o[a]=[o[a],r]:o[a]=r,!d):((!o[a]||!S.isObject(o[a]))&&(o[a]=[]),e(n,r,o[a],s)&&S.isArray(o[a])&&(o[a]=ac(o[a])),!d)}if(S.isFormData(t)&&S.isFunction(t.entries)){const n={};return S.forEachEntry(t,(r,o)=>{e(sc(r),o,n,0)}),n}return null}function lc(t,e,n){if(S.isString(t))try{return(e||JSON.parse)(t),S.trim(t)}catch(r){if(r.name!=="SyntaxError")throw r}return(0,JSON.stringify)(t)}const Bt={transitional:Fr,adapter:["xhr","http","fetch"],transformRequest:[function(e,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,s=S.isObject(e);if(s&&S.isHTMLForm(e)&&(e=new FormData(e)),S.isFormData(e))return o?JSON.stringify(Dr(e)):e;if(S.isArrayBuffer(e)||S.isBuffer(e)||S.isStream(e)||S.isFile(e)||S.isBlob(e)||S.isReadableStream(e))return e;if(S.isArrayBufferView(e))return e.buffer;if(S.isURLSearchParams(e))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let d;if(s){if(r.indexOf("application/x-www-form-urlencoded")>-1)return oc(e,this.formSerializer).toString();if((d=S.isFileList(e))||r.indexOf("multipart/form-data")>-1){const c=this.env&&this.env.FormData;return en(d?{"files[]":e}:e,c&&new c,this.formSerializer)}}return s||o?(n.setContentType("application/json",!1),lc(e)):e}],transformResponse:[function(e){const n=this.transitional||Bt.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(S.isResponse(e)||S.isReadableStream(e))return e;if(e&&S.isString(e)&&(r&&!this.responseType||o)){const a=!(n&&n.silentJSONParsing)&&o;try{return JSON.parse(e)}catch(d){if(a)throw d.name==="SyntaxError"?F.from(d,F.ERR_BAD_RESPONSE,this,null,this.response):d}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:de.classes.FormData,Blob:de.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};S.forEach(["delete","get","head","post","put","patch"],t=>{Bt.headers[t]={}});const cc=S.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),dc=t=>{const e={};let n,r,o;return t&&t.split(`
19
- `).forEach(function(a){o=a.indexOf(":"),n=a.substring(0,o).trim().toLowerCase(),r=a.substring(o+1).trim(),!(!n||e[n]&&cc[n])&&(n==="set-cookie"?e[n]?e[n].push(r):e[n]=[r]:e[n]=e[n]?e[n]+", "+r:r)}),e},Lr=Symbol("internals");function It(t){return t&&String(t).trim().toLowerCase()}function tn(t){return t===!1||t==null?t:S.isArray(t)?t.map(tn):String(t)}function uc(t){const e=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(t);)e[r[1]]=r[2];return e}const hc=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function jn(t,e,n,r,o){if(S.isFunction(r))return r.call(this,e,n);if(o&&(e=n),!!S.isString(e)){if(S.isString(r))return e.indexOf(r)!==-1;if(S.isRegExp(r))return r.test(e)}}function fc(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,n,r)=>n.toUpperCase()+r)}function mc(t,e){const n=S.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(t,r+n,{value:function(o,s,a){return this[r].call(this,e,o,s,a)},configurable:!0})})}class ue{constructor(e){e&&this.set(e)}set(e,n,r){const o=this;function s(d,c,u){const h=It(c);if(!h)throw new Error("header name must be a non-empty string");const f=S.findKey(o,h);(!f||o[f]===void 0||u===!0||u===void 0&&o[f]!==!1)&&(o[f||c]=tn(d))}const a=(d,c)=>S.forEach(d,(u,h)=>s(u,h,c));if(S.isPlainObject(e)||e instanceof this.constructor)a(e,n);else if(S.isString(e)&&(e=e.trim())&&!hc(e))a(dc(e),n);else if(S.isHeaders(e))for(const[d,c]of e.entries())s(c,d,r);else e!=null&&s(n,e,r);return this}get(e,n){if(e=It(e),e){const r=S.findKey(this,e);if(r){const o=this[r];if(!n)return o;if(n===!0)return uc(o);if(S.isFunction(n))return n.call(this,o,r);if(S.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,n){if(e=It(e),e){const r=S.findKey(this,e);return!!(r&&this[r]!==void 0&&(!n||jn(this,this[r],r,n)))}return!1}delete(e,n){const r=this;let o=!1;function s(a){if(a=It(a),a){const d=S.findKey(r,a);d&&(!n||jn(r,r[d],d,n))&&(delete r[d],o=!0)}}return S.isArray(e)?e.forEach(s):s(e),o}clear(e){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const s=n[r];(!e||jn(this,this[s],s,e,!0))&&(delete this[s],o=!0)}return o}normalize(e){const n=this,r={};return S.forEach(this,(o,s)=>{const a=S.findKey(r,s);if(a){n[a]=tn(o),delete n[s];return}const d=e?fc(s):String(s).trim();d!==s&&delete n[s],n[d]=tn(o),r[d]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const n=Object.create(null);return S.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=e&&S.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,n])=>e+": "+n).join(`
20
- `)}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(o=>r.set(o)),r}static accessor(e){const r=(this[Lr]=this[Lr]={accessors:{}}).accessors,o=this.prototype;function s(a){const d=It(a);r[d]||(mc(o,a),r[d]=!0)}return S.isArray(e)?e.forEach(s):s(e),this}}ue.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),S.reduceDescriptors(ue.prototype,({value:t},e)=>{let n=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(r){this[n]=r}}}),S.freezeMethods(ue);function Zn(t,e){const n=this||Bt,r=e||n,o=ue.from(r.headers);let s=r.data;return S.forEach(t,function(d){s=d.call(n,s,o.normalize(),e?e.status:void 0)}),o.normalize(),s}function Hr(t){return!!(t&&t.__CANCEL__)}function lt(t,e,n){F.call(this,t??"canceled",F.ERR_CANCELED,e,n),this.name="CanceledError"}S.inherits(lt,F,{__CANCEL__:!0});function Or(t,e,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?t(n):e(new F("Request failed with status code "+n.status,[F.ERR_BAD_REQUEST,F.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function pc(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function gc(t,e){t=t||10;const n=new Array(t),r=new Array(t);let o=0,s=0,a;return e=e!==void 0?e:1e3,function(c){const u=Date.now(),h=r[s];a||(a=u),n[o]=c,r[o]=u;let f=s,p=0;for(;f!==o;)p+=n[f++],f=f%t;if(o=(o+1)%t,o===s&&(s=(s+1)%t),u-a<e)return;const y=h&&u-h;return y?Math.round(p*1e3/y):void 0}}function yc(t,e){let n=0,r=1e3/e,o,s;const a=(u,h=Date.now())=>{n=h,o=null,s&&(clearTimeout(s),s=null),t.apply(null,u)};return[(...u)=>{const h=Date.now(),f=h-n;f>=r?a(u,h):(o=u,s||(s=setTimeout(()=>{s=null,a(o)},r-f)))},()=>o&&a(o)]}const nn=(t,e,n=3)=>{let r=0;const o=gc(50,250);return yc(s=>{const a=s.loaded,d=s.lengthComputable?s.total:void 0,c=a-r,u=o(c),h=a<=d;r=a;const f={loaded:a,total:d,progress:d?a/d:void 0,bytes:c,rate:u||void 0,estimated:u&&d&&h?(d-a)/u:void 0,event:s,lengthComputable:d!=null,[e?"download":"upload"]:!0};t(f)},n)},_r=(t,e)=>{const n=t!=null;return[r=>e[0]({lengthComputable:n,total:t,loaded:r}),e[1]]},qr=t=>(...e)=>S.asap(()=>t(...e)),wc=de.hasStandardBrowserEnv?function(){const e=de.navigator&&/(msie|trident)/i.test(de.navigator.userAgent),n=document.createElement("a");let r;function o(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=o(window.location.href),function(a){const d=S.isString(a)?o(a):a;return d.protocol===r.protocol&&d.host===r.host}}():function(){return function(){return!0}}(),bc=de.hasStandardBrowserEnv?{write(t,e,n,r,o,s){const a=[t+"="+encodeURIComponent(e)];S.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),S.isString(r)&&a.push("path="+r),S.isString(o)&&a.push("domain="+o),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 Cc(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function Sc(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function Ur(t,e){return t&&!Cc(e)?Sc(t,e):e}const Wr=t=>t instanceof ue?{...t}:t;function Je(t,e){e=e||{};const n={};function r(u,h,f){return S.isPlainObject(u)&&S.isPlainObject(h)?S.merge.call({caseless:f},u,h):S.isPlainObject(h)?S.merge({},h):S.isArray(h)?h.slice():h}function o(u,h,f){if(S.isUndefined(h)){if(!S.isUndefined(u))return r(void 0,u,f)}else return r(u,h,f)}function s(u,h){if(!S.isUndefined(h))return r(void 0,h)}function a(u,h){if(S.isUndefined(h)){if(!S.isUndefined(u))return r(void 0,u)}else return r(void 0,h)}function d(u,h,f){if(f in e)return r(u,h);if(f in t)return r(void 0,u)}const c={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:d,headers:(u,h)=>o(Wr(u),Wr(h),!0)};return S.forEach(Object.keys(Object.assign({},t,e)),function(h){const f=c[h]||o,p=f(t[h],e[h],h);S.isUndefined(p)&&f!==d||(n[h]=p)}),n}const Gr=t=>{const e=Je({},t);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:s,headers:a,auth:d}=e;e.headers=a=ue.from(a),e.url=zr(Ur(e.baseURL,e.url),t.params,t.paramsSerializer),d&&a.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?unescape(encodeURIComponent(d.password)):"")));let c;if(S.isFormData(n)){if(de.hasStandardBrowserEnv||de.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((c=a.getContentType())!==!1){const[u,...h]=c?c.split(";").map(f=>f.trim()).filter(Boolean):[];a.setContentType([u||"multipart/form-data",...h].join("; "))}}if(de.hasStandardBrowserEnv&&(r&&S.isFunction(r)&&(r=r(e)),r||r!==!1&&wc(e.url))){const u=o&&s&&bc.read(s);u&&a.set(o,u)}return e},kc=typeof XMLHttpRequest<"u"&&function(t){return new Promise(function(n,r){const o=Gr(t);let s=o.data;const a=ue.from(o.headers).normalize();let{responseType:d,onUploadProgress:c,onDownloadProgress:u}=o,h,f,p,y,g;function k(){y&&y(),g&&g(),o.cancelToken&&o.cancelToken.unsubscribe(h),o.signal&&o.signal.removeEventListener("abort",h)}let b=new XMLHttpRequest;b.open(o.method.toUpperCase(),o.url,!0),b.timeout=o.timeout;function B(){if(!b)return;const L=ue.from("getAllResponseHeaders"in b&&b.getAllResponseHeaders()),T={data:!d||d==="text"||d==="json"?b.responseText:b.response,status:b.status,statusText:b.statusText,headers:L,config:t,request:b};Or(function(ke){n(ke),k()},function(ke){r(ke),k()},T),b=null}"onloadend"in b?b.onloadend=B:b.onreadystatechange=function(){!b||b.readyState!==4||b.status===0&&!(b.responseURL&&b.responseURL.indexOf("file:")===0)||setTimeout(B)},b.onabort=function(){b&&(r(new F("Request aborted",F.ECONNABORTED,t,b)),b=null)},b.onerror=function(){r(new F("Network Error",F.ERR_NETWORK,t,b)),b=null},b.ontimeout=function(){let V=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const T=o.transitional||Fr;o.timeoutErrorMessage&&(V=o.timeoutErrorMessage),r(new F(V,T.clarifyTimeoutError?F.ETIMEDOUT:F.ECONNABORTED,t,b)),b=null},s===void 0&&a.setContentType(null),"setRequestHeader"in b&&S.forEach(a.toJSON(),function(V,T){b.setRequestHeader(T,V)}),S.isUndefined(o.withCredentials)||(b.withCredentials=!!o.withCredentials),d&&d!=="json"&&(b.responseType=o.responseType),u&&([p,g]=nn(u,!0),b.addEventListener("progress",p)),c&&b.upload&&([f,y]=nn(c),b.upload.addEventListener("progress",f),b.upload.addEventListener("loadend",y)),(o.cancelToken||o.signal)&&(h=L=>{b&&(r(!L||L.type?new lt(null,t,b):L),b.abort(),b=null)},o.cancelToken&&o.cancelToken.subscribe(h),o.signal&&(o.signal.aborted?h():o.signal.addEventListener("abort",h)));const D=pc(o.url);if(D&&de.protocols.indexOf(D)===-1){r(new F("Unsupported protocol "+D+":",F.ERR_BAD_REQUEST,t));return}b.send(s||null)})},Ec=(t,e)=>{const{length:n}=t=t?t.filter(Boolean):[];if(e||n){let r=new AbortController,o;const s=function(u){if(!o){o=!0,d();const h=u instanceof Error?u:this.reason;r.abort(h instanceof F?h:new lt(h instanceof Error?h.message:h))}};let a=e&&setTimeout(()=>{a=null,s(new F(`timeout ${e} of ms exceeded`,F.ETIMEDOUT))},e);const d=()=>{t&&(a&&clearTimeout(a),a=null,t.forEach(u=>{u.unsubscribe?u.unsubscribe(s):u.removeEventListener("abort",s)}),t=null)};t.forEach(u=>u.addEventListener("abort",s));const{signal:c}=r;return c.unsubscribe=()=>S.asap(d),c}},vc=function*(t,e){let n=t.byteLength;if(n<e){yield t;return}let r=0,o;for(;r<n;)o=r+e,yield t.slice(r,o),r=o},Mc=async function*(t,e){for await(const n of xc(t))yield*vc(n,e)},xc=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()}},jr=(t,e,n,r)=>{const o=Mc(t,e);let s=0,a,d=c=>{a||(a=!0,r&&r(c))};return new ReadableStream({async pull(c){try{const{done:u,value:h}=await o.next();if(u){d(),c.close();return}let f=h.byteLength;if(n){let p=s+=f;n(p)}c.enqueue(new Uint8Array(h))}catch(u){throw d(u),u}},cancel(c){return d(c),o.return()}},{highWaterMark:2})},rn=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",Zr=rn&&typeof ReadableStream=="function",Bc=rn&&(typeof TextEncoder=="function"?(t=>e=>t.encode(e))(new TextEncoder):async t=>new Uint8Array(await new Response(t).arrayBuffer())),Jr=(t,...e)=>{try{return!!t(...e)}catch{return!1}},Ic=Zr&&Jr(()=>{let t=!1;const e=new Request(de.origin,{body:new ReadableStream,method:"POST",get duplex(){return t=!0,"half"}}).headers.has("Content-Type");return t&&!e}),Xr=64*1024,Jn=Zr&&Jr(()=>S.isReadableStream(new Response("").body)),on={stream:Jn&&(t=>t.body)};rn&&(t=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!on[e]&&(on[e]=S.isFunction(t[e])?n=>n[e]():(n,r)=>{throw new F(`Response type '${e}' is not supported`,F.ERR_NOT_SUPPORT,r)})})})(new Response);const Rc=async t=>{if(t==null)return 0;if(S.isBlob(t))return t.size;if(S.isSpecCompliantForm(t))return(await new Request(de.origin,{method:"POST",body:t}).arrayBuffer()).byteLength;if(S.isArrayBufferView(t)||S.isArrayBuffer(t))return t.byteLength;if(S.isURLSearchParams(t)&&(t=t+""),S.isString(t))return(await Bc(t)).byteLength},$c=async(t,e)=>{const n=S.toFiniteNumber(t.getContentLength());return n??Rc(e)},Xn={http:Yl,xhr:kc,fetch:rn&&(async t=>{let{url:e,method:n,data:r,signal:o,cancelToken:s,timeout:a,onDownloadProgress:d,onUploadProgress:c,responseType:u,headers:h,withCredentials:f="same-origin",fetchOptions:p}=Gr(t);u=u?(u+"").toLowerCase():"text";let y=Ec([o,s&&s.toAbortSignal()],a),g;const k=y&&y.unsubscribe&&(()=>{y.unsubscribe()});let b;try{if(c&&Ic&&n!=="get"&&n!=="head"&&(b=await $c(h,r))!==0){let T=new Request(e,{method:"POST",body:r,duplex:"half"}),ye;if(S.isFormData(r)&&(ye=T.headers.get("content-type"))&&h.setContentType(ye),T.body){const[ke,Ge]=_r(b,nn(qr(c)));r=jr(T.body,Xr,ke,Ge)}}S.isString(f)||(f=f?"include":"omit");const B="credentials"in Request.prototype;g=new Request(e,{...p,signal:y,method:n.toUpperCase(),headers:h.normalize().toJSON(),body:r,duplex:"half",credentials:B?f:void 0});let D=await fetch(g);const L=Jn&&(u==="stream"||u==="response");if(Jn&&(d||L&&k)){const T={};["status","statusText","headers"].forEach(Ct=>{T[Ct]=D[Ct]});const ye=S.toFiniteNumber(D.headers.get("content-length")),[ke,Ge]=d&&_r(ye,nn(qr(d),!0))||[];D=new Response(jr(D.body,Xr,ke,()=>{Ge&&Ge(),k&&k()}),T)}u=u||"text";let V=await on[S.findKey(on,u)||"text"](D,t);return!L&&k&&k(),await new Promise((T,ye)=>{Or(T,ye,{data:V,headers:ue.from(D.headers),status:D.status,statusText:D.statusText,config:t,request:g})})}catch(B){throw k&&k(),B&&B.name==="TypeError"&&/fetch/i.test(B.message)?Object.assign(new F("Network Error",F.ERR_NETWORK,t,g),{cause:B.cause||B}):F.from(B,B&&B.code,t,g)}})};S.forEach(Xn,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const Yr=t=>`- ${t}`,Nc=t=>S.isFunction(t)||t===null||t===!1,Qr={getAdapter:t=>{t=S.isArray(t)?t:[t];const{length:e}=t;let n,r;const o={};for(let s=0;s<e;s++){n=t[s];let a;if(r=n,!Nc(n)&&(r=Xn[(a=String(n)).toLowerCase()],r===void 0))throw new F(`Unknown adapter '${a}'`);if(r)break;o[a||"#"+s]=r}if(!r){const s=Object.entries(o).map(([d,c])=>`adapter ${d} `+(c===!1?"is not supported by the environment":"is not available in the build"));let a=e?s.length>1?`since :
21
- `+s.map(Yr).join(`
22
- `):" "+Yr(s[0]):"as no adapter specified";throw new F("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return r},adapters:Xn};function Yn(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new lt(null,t)}function Kr(t){return Yn(t),t.headers=ue.from(t.headers),t.data=Zn.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),Qr.getAdapter(t.adapter||Bt.adapter)(t).then(function(r){return Yn(t),r.data=Zn.call(t,t.transformResponse,r),r.headers=ue.from(r.headers),r},function(r){return Hr(r)||(Yn(t),r&&r.response&&(r.response.data=Zn.call(t,t.transformResponse,r.response),r.response.headers=ue.from(r.response.headers))),Promise.reject(r)})}const eo="1.7.7",Qn={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{Qn[t]=function(r){return typeof r===t||"a"+(e<1?"n ":" ")+t}});const to={};Qn.transitional=function(e,n,r){function o(s,a){return"[Axios v"+eo+"] Transitional option '"+s+"'"+a+(r?". "+r:"")}return(s,a,d)=>{if(e===!1)throw new F(o(a," has been removed"+(n?" in "+n:"")),F.ERR_DEPRECATED);return n&&!to[a]&&(to[a]=!0,console.warn(o(a," has been deprecated since v"+n+" and will be removed in the near future"))),e?e(s,a,d):!0}};function Ac(t,e,n){if(typeof t!="object")throw new F("options must be an object",F.ERR_BAD_OPTION_VALUE);const r=Object.keys(t);let o=r.length;for(;o-- >0;){const s=r[o],a=e[s];if(a){const d=t[s],c=d===void 0||a(d,s,t);if(c!==!0)throw new F("option "+s+" must be "+c,F.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new F("Unknown option "+s,F.ERR_BAD_OPTION)}}const Kn={assertOptions:Ac,validators:Qn},qe=Kn.validators;class Xe{constructor(e){this.defaults=e,this.interceptors={request:new Vr,response:new Vr}}async request(e,n){try{return await this._request(e,n)}catch(r){if(r instanceof Error){let o;Error.captureStackTrace?Error.captureStackTrace(o={}):o=new Error;const s=o.stack?o.stack.replace(/^.+\n/,""):"";try{r.stack?s&&!String(r.stack).endsWith(s.replace(/^.+\n.+\n/,""))&&(r.stack+=`
23
- `+s):r.stack=s}catch{}}throw r}}_request(e,n){typeof e=="string"?(n=n||{},n.url=e):n=e||{},n=Je(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:s}=n;r!==void 0&&Kn.assertOptions(r,{silentJSONParsing:qe.transitional(qe.boolean),forcedJSONParsing:qe.transitional(qe.boolean),clarifyTimeoutError:qe.transitional(qe.boolean)},!1),o!=null&&(S.isFunction(o)?n.paramsSerializer={serialize:o}:Kn.assertOptions(o,{encode:qe.function,serialize:qe.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let a=s&&S.merge(s.common,s[n.method]);s&&S.forEach(["delete","get","head","post","put","patch","common"],g=>{delete s[g]}),n.headers=ue.concat(a,s);const d=[];let c=!0;this.interceptors.request.forEach(function(k){typeof k.runWhen=="function"&&k.runWhen(n)===!1||(c=c&&k.synchronous,d.unshift(k.fulfilled,k.rejected))});const u=[];this.interceptors.response.forEach(function(k){u.push(k.fulfilled,k.rejected)});let h,f=0,p;if(!c){const g=[Kr.bind(this),void 0];for(g.unshift.apply(g,d),g.push.apply(g,u),p=g.length,h=Promise.resolve(n);f<p;)h=h.then(g[f++],g[f++]);return h}p=d.length;let y=n;for(f=0;f<p;){const g=d[f++],k=d[f++];try{y=g(y)}catch(b){k.call(this,b);break}}try{h=Kr.call(this,y)}catch(g){return Promise.reject(g)}for(f=0,p=u.length;f<p;)h=h.then(u[f++],u[f++]);return h}getUri(e){e=Je(this.defaults,e);const n=Ur(e.baseURL,e.url);return zr(n,e.params,e.paramsSerializer)}}S.forEach(["delete","get","head","options"],function(e){Xe.prototype[e]=function(n,r){return this.request(Je(r||{},{method:e,url:n,data:(r||{}).data}))}}),S.forEach(["post","put","patch"],function(e){function n(r){return function(s,a,d){return this.request(Je(d||{},{method:e,headers:r?{"Content-Type":"multipart/form-data"}:{},url:s,data:a}))}}Xe.prototype[e]=n(),Xe.prototype[e+"Form"]=n(!0)});class ei{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(o=>{if(!r._listeners)return;let s=r._listeners.length;for(;s-- >0;)r._listeners[s](o);r._listeners=null}),this.promise.then=o=>{let s;const a=new Promise(d=>{r.subscribe(d),s=d}).then(o);return a.cancel=function(){r.unsubscribe(s)},a},e(function(s,a,d){r.reason||(r.reason=new lt(s,a,d),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 ei(function(o){e=o}),cancel:e}}}function Pc(t){return function(n){return t.apply(null,n)}}function Tc(t){return S.isObject(t)&&t.isAxiosError===!0}const ti={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(ti).forEach(([t,e])=>{ti[e]=t});function no(t){const e=new Xe(t),n=br(Xe.prototype.request,e);return S.extend(n,Xe.prototype,e,{allOwnKeys:!0}),S.extend(n,e,null,{allOwnKeys:!0}),n.create=function(o){return no(Je(t,o))},n}const J=no(Bt);J.Axios=Xe,J.CanceledError=lt,J.CancelToken=ei,J.isCancel=Hr,J.VERSION=eo,J.toFormData=en,J.AxiosError=F,J.Cancel=J.CanceledError,J.all=function(e){return Promise.all(e)},J.spread=Pc,J.isAxiosError=Tc,J.mergeConfig=Je,J.AxiosHeaders=ue,J.formToJSON=t=>Dr(S.isHTMLForm(t)?new FormData(t):t),J.getAdapter=Qr.getAdapter,J.HttpStatusCode=ti,J.default=J;var Rt=(t=>(t.GET="get",t.POST="post",t.PUT="put",t.DELETE="delete",t))(Rt||{});const $t=(()=>{function t(){const c=o();return!(!c||c==="undefined")}function e(c){c.accessToken&&localStorage.setItem("access_token",c.accessToken),c.refreshToken&&localStorage.setItem("refresh_token",c.refreshToken)}function n(){const c=localStorage.getItem("user");return c?JSON.parse(c).id:""}function r(){const c=localStorage.getItem("user");if(c)return JSON.parse(c)}function o(){return localStorage.getItem("access_token")}function s(){return localStorage.getItem("refresh_token")}function a(){localStorage.removeItem("access_token"),localStorage.removeItem("refresh_token")}function d(c){if(!t())return;const u=$t.getUser();u&&(u.human=c,localStorage.setItem("user",JSON.stringify(u)))}return{isAuth:t,setTokens:e,getAccessToken:o,getRefreshToken:s,getUserId:n,clearTokens:a,getUser:r,updateHuman:d}})();class ni{constructor(e){l(this,"code",400);l(this,"err","");m.H.Classes.BuildClass(this,e)}getErr(){return this.capitalizedErr()}capitalizedErr(){return this.err.charAt(0).toUpperCase()+this.err.slice(1)}static async Handle(e,n){const r=e.config;if(e.response){if(e.response.status===401&&!r._retry)return r._retry=!0,n.defaults.headers.common.token=$t.getAccessToken(),e.config.headers.token=$t.getAccessToken(),e.config.baseURL=void 0,n.request(r);if(e.response.status>=500){if(e.response.data==="неверный логин или пароль"){m.Notification.Error("Неверный логин или пароль");return}m.Notification.Error("Ошибка на сервере, попробуйте позже")}if(e.response.status>=400&&e.response.status<500){const o=new ni(e.response.data).getErr();o&&m.Notification.Error(o)}return Promise.reject(e)}}}const ct=J.create();ct.interceptors.response.use(t=>t,async t=>await ni.Handle(t,ct));class Nt{static async Get(e,n,r){return await ct({method:Rt.GET,url:e,headers:n,responseType:r})}static async Post(e,n,r,o){return n["Content-Type"]="multipart/form-data",await ct({method:Rt.POST,url:e,headers:n,responseType:r,data:o})}static async Put(e,n,r){return n["Content-Type"]="multipart/form-data",await ct({method:Rt.PUT,url:e,headers:n,data:r})}static async Delete(e,n){return await ct({method:Rt.DELETE,url:e,headers:n})}}let zc=class ka{constructor(e){l(this,"name","");m.H.Classes.BuildClass(this,e)}static Set(){}static Get(e,n){const r=sessionStorage.getItem(e);if(r){const o=JSON.parse(r),s=new Date,a=new Date(o.time),d=s.getTime()-a.getTime();return Math.round(d/6e4)>(n||10)?null:o.data}else return null}static async TryGet(e,n,r){let o;return o=ka.Get(e,r),o||(o=await n()),o}};var ii=(t=>(t.ContentType="Content-Type",t.Token="token",t))(ii||{}),io=(t=>(t.ApplicationJson="application/json",t.MultipartFormData="multipart/form-data",t))(io||{});const W=class W{static Setup(e,n,r){this.baseUrl=e,this.apiVersion=n,this.apiHost=r}static newWebSocket(e){const n=this.apiHost.replace("http","ws")+"/ws/"+e;return new WebSocket(n)}static download(e,n){const r=W.getDownloadFileName(e,n.headers),o=URL.createObjectURL(n.data),s=document.createElement("a");s.href=o,s.setAttribute("download",r),s.setAttribute("target","_blank"),document.body.appendChild(s),s.click()}static getDownloadFileName(e,n){if(e)return e;const r=n["content-disposition"],o=r.indexOf('"')+1,s=r.lastIndexOf('"'),a=r.substring(o,s);return a||"file"}static getHeaders(e){const n=ve.Get(we.AccessToken);return e||(e=W.headers),n&&(e[ii.Token]=n),e??W.headers}static returnResponse(e,n){if(n)return e!=null&&e.isBlob?W.download(e.downloadFileName,n):n.data}static async Get(e){return W.returnResponse(e,await Nt.Get(W.buildUrl((e==null?void 0:e.query)??""),W.getHeaders(e==null?void 0:e.headers),W.getResponseType(e==null?void 0:e.isBlob)))}static async Post(e){return W.returnResponse(e,await Nt.Post(W.buildUrl(e==null?void 0:e.query),W.getHeaders(e==null?void 0:e.headers),W.getResponseType(e.isBlob),W.createFormDataPayload(e==null?void 0:e.payload,e==null?void 0:e.fileInfos)))}static async Put(e){return W.returnResponse(e,await Nt.Put(W.buildUrl(e==null?void 0:e.query),W.getHeaders(e==null?void 0:e.headers),W.createFormDataPayload(e==null?void 0:e.payload,e==null?void 0:e.fileInfos)))}static async Delete(e){return W.returnResponse(e,await Nt.Delete(W.buildUrl(e==null?void 0:e.query),W.getHeaders(e==null?void 0:e.headers)))}static async Subscribe(e){const{query:n}=e;return new EventSource(W.buildUrl(n))}static buildUrl(e){const n=e??"";return this.baseUrl+this.apiVersion+n}static getResponseType(e){return e?"blob":"json"}static createFormDataPayload(e,n){const r=new FormData;if(r.append("form",JSON.stringify(e)),n)for(const o of n)o.file&&r.append(o.id??"files",o.file,o.originalName);return r}};l(W,"baseUrl",""),l(W,"apiVersion",""),l(W,"apiHost",""),l(W,"headers",{[ii.ContentType]:io.ApplicationJson});let ie=W;class K{constructor(e,n){l(this,"items",i.reactive([]));l(this,"item");l(this,"count",i.ref(0));l(this,"classConstructor");l(this,"url","");this.classConstructor=e,this.item=i.reactive(new this.classConstructor),this.url=n}Set(e){Object.assign(this.item,new this.classConstructor(e))}Item(){return this.item}getUrl(e){return e?`${this.url}/${e}`:this.url}async GetAll(e){let n;const r=ie.Get;e&&e.withCache?n=await zc.TryGet(this.getUrl(),r):n=await r({query:this.getUrl()}),Array.isArray(n)?this.SetAll(n):this.SetAllWithCount(n)}async Get(e){e||(e=m.H.Router.Id()),this.Set(await ie.Get({query:this.getUrl(e)}))}async FTSP(e){var a;const r=((e==null?void 0:e.ftsp)??m.H.FTSP.Get()).clearForHTTP(),o={payload:{ftsp:r},query:this.getUrl("ftsp")},s=await ie.Post(o);if(!(!s||!s.ftsp))if(Array.isArray(s.data))this.SetAll(s.data);else{if(r.p.append){this.AppendToAll((a=s.data)==null?void 0:a.items);return}this.SetAllWithCount(s.data)}}async Create(e){const n=e??this.item,r={payload:n,query:this.getUrl()};return n.getFileInfos&&(r.fileInfos=n.getFileInfos(),r.fileInfos.forEach(o=>o.url="")),await ie.Post(r)}async CreateAndSet(e){const n=await this.Create(e);this.Set(n)}async CreateMany(e){if(!e)return;const n=[];e.forEach(r=>{n.push(new Promise(()=>this.Create(r)))}),Promise.all(n)}async Update(e){const n=e??this.item,r={query:this.getUrl(`${n.id}`),payload:n};return n.getFileInfos&&(r.fileInfos=n.getFileInfos(),r.fileInfos.forEach(o=>o.url="")),await ie.Put(r)}async UpdateAndSet(e){const n=await this.Update(e);this.Set(n)}async UpdateAndReset(e){await this.Update(e??this.item),this.Set()}async Remove(e){if(!e){console.warn("BaseStore/Remove. id is undefined");return}await ie.Delete({query:this.getUrl(`${e}`)}),this.RemoveItem(e)}async UpdateMany(e){if(e||(e=this.items),!e)return;const n=[];e.forEach(r=>{n.push(new Promise(()=>this.Update(r)))}),Promise.all(n)}SetAll(e){e&&(this.items.splice(0,this.items.length),this.items.push(...e.map(n=>new this.classConstructor(n))))}SetAllWithCount(e){e&&(this.SetAll(e.items),this.count.value=e.count)}RemoveItem(e){const n=this.items.findIndex(r=>r.id===e);this.items.splice(n,1)}AppendToAll(e){if(!e)return;const n=e.map(r=>new this.classConstructor(r));this.items.push(...n)}ResetState(){this.ResetItem(),this.ClearItems(),this.count.value=0}ResetItem(){m.H.Classes.BuildClass(this.item,new this.classConstructor)}ClearItems(){this.items.splice(0,this.items.length)}UnshiftToAll(e){this.items.unshift(new this.classConstructor(e))}Items(){return this.items}Count(){return this.count}}class Vc{constructor(e){l(this,"name","");m.H.Classes.BuildClass(this,e)}cache(){}getFromCache(e){const n=sessionStorage.getItem(this.name);if(n){const r=JSON.parse(n),o=new Date,s=new Date(r.time),a=o.getTime()-s.getTime();return Math.round(a/6e4)>(e||10)?null:r.data}else return null}async storeGetWithCache(e,n){let r;return r=this.getFromCache(n),r||(r=await e(),r&&this.cache()),r}}function Fc(t,e){t=="left"&&e.next(),t=="right"&&e.prev()}const Dc=["#31af5e","#ff4d3b","#006BB5","#f3911c"];class Lc{static GetRandColor(e){return _e.GetRandEL(e??Dc)}}class ri{static Get(e,n,r="-"){return!e||!n?"":`${e}${r}${n}`}static In(e,n,r){return e>=n&&e<=r}static Intersects(e,n,r,o){return e===r||n===o||e>r&&e<o||n>r&&n<o||n>o&&e<r}}const ro=1e3,oo=60*ro,oi=60*oo;var At=(t=>(t.FiveMinutes="5",t.HourQuarter="15",t.HourHalf="30",t.Hour="60",t))(At||{});const sn={5:["00","05","10","15","20","25","30","35","40","45","50","55"],15:["00","15","30","45"],30:["00","30"],60:["00"]};class H{static S(e){return ro*e}static M(e){return oo*e}static H(e){return oi*e}static D(e){return oi*e}static W(e){return oi*e}static NormalizeTime(e){return String(e).padStart(2,"0")}static HMtoM(e){const n=H.SplitHM(e);return n.length>1?H.HtoM(n[0])+n[1]:H.HtoM(n[0])}static HtoM(e){return Number(e)*60}static SplitHM(e){if(!e)return[];const n=e.split(":");return[Number(n[0]),Number(n[1])]}static HmsToHm(e){const n=H.SplitHM(e);return H.ConcatHM(n[0],n[1])}static AddMtoHM(e,n){const r=new Date,o=H.SplitHM(e);r.setHours(o[0],o[1],0,0);const s=new Date(r.getTime()+n*6e4),a=s.getHours(),d=s.getMinutes();return H.ConcatHM(a,d)}static ConcatHM(e,n){return`${e}:${H.NormalizeTime(n)}`}static DiffM(e,n){return H.Gt(n,e)?H.HMtoM(n)-H.HMtoM(e):H.HMtoM(e)-H.HMtoM(n)}static GetPeriod(e,n){return ri.Get(e,n)}static Gt(e,n){return H.HMtoM(e)>H.HMtoM(n)}static GtOrEq(e,n){return H.Gt(e,n)||H.Eq(e,n)}static Eq(e,n){return H.HMtoM(e)===H.HMtoM(n)}static PeriodInPeriod(e,n,r,o){return H.HMtoM(e)>=H.HMtoM(r)&&H.HMtoM(n)<=H.HMtoM(o)}static PeriodsIntersects(e,n,r,o){return ri.Intersects(H.HMtoM(e),H.HMtoM(n),H.HMtoM(r),H.HMtoM(o))}}let Hc=class{constructor(){l(this,"startHour",9);l(this,"endHour",19);l(this,"timelinePxHeight",50);l(this,"timelineStep",At.FiveMinutes);l(this,"activeTime","");l(this,"activeObjectId","");l(this,"dragged",!1);l(this,"draggedStartTime","");l(this,"draggedEndTime","");l(this,"timelines",sn[At.FiveMinutes])}startDrag(e,n){this.draggedStartTime=e,this.draggedEndTime=n,this.dragged=!0}endDrag(){this.activeTime="",this.dragged=!1}setTimelineStep(e){this.timelineStep=e,this.setTimelines()}setTimelines(){this.timelines=sn[this.timelineStep]}getScheduleHeight(){return this.getHourHeight()*this.getHoursArr().length}getHourHeight(){return this.timelinePxHeight*this.timelines.length}getHoursArr(){return _e.GenerateNumsRange(this.startHour,this.endHour)}};const si=t=>t===8||t===46,Oc=t=>t>46&&t<58,_c=t=>t>34&&t<41,qc=t=>t+".",Uc=(t,e,n)=>{si(e)||_c(e)||(!Oc(e)||n>9)&&t.preventDefault()};function Wc(t,e){if(e>8){let n=t.substring(0,2).replace(".","1");Number(n)>31&&(n="31");let r=t.substring(3,5).replace(".","1");Number(r)>12&&(r="12");let o=t.substring(6,10).replace(".","1");Number(o)>2100&&(o="2100"),t=n+"."+r+"."+o}return t}function Gc(t){const e=t.keyCode;let n=t.srcElement.value;const r=n.length;Uc(t,e,r),!si(e)&&(r===2||r===5)&&(n=qc(n));const o=t.srcElement.value+String.fromCharCode(t.which);if(si(e)){t.srcElement.value=n;return}n.length===0&&Number(o)>3&&(n="3",t.preventDefault()),n.length===1&&Number(o)>31&&(n="31",t.preventDefault()),o.length===5&&Number(o.substring(3,5))>12&&(n=n.substring(0,3)+"12",t.preventDefault()),n=Wc(n,r),t.srcElement.value=n}const jc=["ВС","ПН","ВТ","СР","ЧТ","ПТ","СБ"],Zc="ru-RU";class ze{constructor(){l(this,"locale","ru-RU")}static Format(e,n){if(!e)return"";const r={year:"numeric",month:"2-digit",day:"2-digit",hour:void 0,minute:void 0};return n&&(r.year=n.year||n.year===void 0?n.year:r.year,r.month=n.month||n.month===void 0?n.month:r.month,r.day=n.day||n.day===void 0?n.day:r.day,r.hour=n.hour??r.hour,r.minute=n.minute??r.minute),Intl.DateTimeFormat(Zc,r).format(new Date(e))}static FromRuStr(e){const n=e.split(".");return new Date(`${n[2]}-${n[1]}-${n[0]}`)}static GetPeriod(e,n,r){return`${this.Format(e,r)}-${this.Format(n,r)}`}static GetShortDayName(e){return e?jc[e.getDay()]:""}static GetCurrentWeekPeriod(e){const n=new Date,r=new Date(n.getFullYear(),n.getMonth(),n.getDate()-n.getDay()+1),o=new Date(n.getFullYear(),n.getMonth(),r.getDate()+7);return this.GetPeriod(r,o,e||{month:"2-digit",day:"numeric",year:void 0})}static GetDurationInDay(e,n){const r=new Date,o=new Date,s=ze.SplitHourTime(e),a=ze.SplitHourTime(n);return r.setHours(s[0],s[1],0,0),o.setHours(a[0],a[1],0,0),(o.getTime()-r.getTime())/1e3/60}static HourTimeinMunutes(e){const n=ze.SplitHourTime(e);return n[0]*60+n[1]}static SplitHourTime(e){const n=e.split(":");return[Number(n[0]),Number(n[1])]}static AddMinutesToHM(e,n){const r=new Date,o=ze.SplitHourTime(e);r.setHours(o[0],o[1],0,0);const s=new Date(r.getTime()+n*6e4),a=s.getHours(),d=s.getMinutes();return`${a}:${d}`}static GetMonthsDiff(e,n){return n.getMonth()-e.getMonth()+12*(n.getFullYear()-e.getFullYear())}static StringToDate(e){const n=e.split(".");return new Date(`${n[2]}-${n[1]}-${n[0]}`)}static GetDateOrToday(e){return e?e.date:new Date}static InPeriod(e,n,r){return new Date(e)>=new Date(n)&&new Date(e)<=new Date(r)}static GetDatesFromPeriod(e,n){const r=[new Date(e)];let o=e;for(;o<=n;)o=ze.AddDays(o,1),r.push(o);return r}static AddDays(e,n){const r=new Date(e);return r.setDate(r.getDate()+n),r}static Eq(e,n){return e.getTime()===n.getTime()}}class Jc{constructor(){l(this,"dragged",!1);l(this,"dragImg",new Image);this.dragImg.src="data:image/gif;base64,R0lGODlhAQABAIAAAAUEBAAAACwAAAAAAQABAAACAkQBADs="}start(e){this.dragged=!0,e&&e.dataTransfer&&e.dataTransfer.setDragImage(this.dragImg,0,0)}end(){this.dragged=!1}isDragged(){return this.dragged}}class Xc{static Get(e){const n=e.split(".");return n[n.length-1]}}const Yc=(()=>{function t(s,a){localStorage.setItem(`${s}_favourite`,a.toString())}function e(s,a){const d=localStorage.getItem(`${s}_favourite`);return d?d.split(",").includes(a):!1}function n(s,a){const d=localStorage.getItem(`${s}_favourite`);if(!d){t(s,[a]);return}const c=d.split(",");c.push(a),t(s,c)}function r(s,a){const d=localStorage.getItem(`${s}_favourite`);if(!d)return;const c=d.split(",").filter(u=>u!==a);t(s,c)}function o(){for(const s in localStorage)s.includes("_favourite")&&localStorage.removeItem(s)}return{addToFavourite:n,removeFromFavourite:r,setFavourite:t,isFavourite:e,clearFavourite:o}})();function so(t,e){const n=[];if(t)for(let r=0;r<Math.ceil(t.length/e);r++)n[r]=t.slice(r*e,r*e+e);return n}const Rn=class Rn{static Format(e){let n=e;if(!n)e=n;else{(n[0]==="7"||n[0]==="8")&&n.length!==1&&(n=n.slice(1));const r=n.replace(/\+7|[^\d]/g,""),o=r.length;switch(!0){case o===0:e="";break;case(o===1&&n.length===1&&r==="7"):case(o===1&&n.length===1&&r==="8"):e="+7 (";break;case o<4:e=`+7 (${r}`;break;case o<7:e=`+7 (${r.slice(0,3)}) ${r.slice(3)}`;break;case o<9:e=`+7 (${r.slice(0,3)}) ${r.slice(3,6)}-${r.slice(6,8)}`;break;default:e=`+7 (${r.slice(0,3)}) ${r.slice(3,6)}-${r.slice(6,8)}-${r.slice(8,10)}`;break}}return e}static getPhoneRegExp(){return/^(\s*)?(\+)?([- _():=+]?\d[- _():=+]?){10,14}(\s*)?$/}};l(Rn,"validatePhone",(e,n,r)=>{Rn.getPhoneRegExp().test(n)||!n?r():r(new Error("Пожалуйста, введите корректный номер телефона"))});let ai=Rn;class Qc{static Count(e){const n=e.filter(s=>s.rating!==0);let r=0;n.forEach(s=>r=r+s.rating);const o=r/n.length;return isNaN(o)?0:Number((r/n.length).toFixed(2))}}const Kc="p-button",ed=i.defineComponent({inheritAttrs:!1,__name:"PButton",props:{text:{type:String,default:"",required:!1},margin:{type:String,default:"",required:!1},padding:{type:String,default:"",required:!1},width:{type:String,default:"",required:!1},height:{type:String,default:"",required:!1},skin:{type:String,default:"base",required:!1},size:{type:String,default:Ln.M,required:!1},type:{type:String,default:se.Primary,required:!1},fontSize:{type:String,default:"",required:!1}},emits:["click"],setup(t,{emit:e}){const n=t,r=e,o=()=>{r("click")},s=i.computed(()=>m.H.Strings.JoinSnake(Kc,n.skin)),a=i.computed(()=>m.H.Strings.JoinSnake(s.value,n.type)),d=i.computed(()=>m.H.Strings.JoinSnake(s.value,n.size)),c=i.computed(()=>[s.value,a.value,d.value]);return(u,h)=>(i.openBlock(),i.createElementBlock("button",i.mergeProps(u.$attrs,{style:{margin:t.margin,padding:t.padding,maxWidth:t.width,minWidth:t.width,minHeight:t.height,maxHeight:t.height,fontSize:t.fontSize},class:i.unref(c),onClick:i.withModifiers(o,["prevent"])}),[i.renderSlot(u.$slots,"default",{},void 0,!0),i.createTextVNode(" "+i.toDisplayString(t.text),1)],16))}}),be=M(ed,[["__scopeId","data-v-4aae85d5"]]);var td=Object.defineProperty,nd=(t,e,n)=>e in t?td(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,an=(t,e,n)=>nd(t,typeof e!="symbol"?e+"":e,n);const ao={"#":{pattern:/[0-9]/},"@":{pattern:/[a-zA-Z]/},"*":{pattern:/[a-zA-Z0-9]/}},lo=(t,e,n)=>t.replaceAll(e,"").replace(n,".").replace("..",".").replace(/[^.\d]/g,""),co=(t,e,n)=>{var r;return new Intl.NumberFormat(((r=n.number)==null?void 0:r.locale)??"en",{minimumFractionDigits:t,maximumFractionDigits:e,roundingMode:"trunc"})},id=(t,e=!0,n)=>{var r,o,s,a;const d=((r=n.number)==null?void 0:r.unsigned)==null&&t.startsWith("-")?"-":"",c=((o=n.number)==null?void 0:o.fraction)??0;let u=co(0,c,n);const h=u.formatToParts(1000.12),f=((s=h.find(b=>b.type==="group"))==null?void 0:s.value)??" ",p=((a=h.find(b=>b.type==="decimal"))==null?void 0:a.value)??".",y=lo(t,f,p);if(Number.isNaN(parseFloat(y)))return d;const g=y.split(".");if(g[1]!=null&&g[1].length>=1){const b=g[1].length<=c?g[1].length:c;u=co(b,c,n)}let k=u.format(parseFloat(y));return e?c>0&&y.endsWith(".")&&!y.slice(0,-1).includes(".")&&(k+=p):k=lo(k,f,p),d+k};let rd=class{constructor(e={}){an(this,"opts",{}),an(this,"memo",new Map);const n={...e};if(n.tokens!=null){n.tokens=n.tokensReplace?{...n.tokens}:{...ao,...n.tokens};for(const r of Object.values(n.tokens))typeof r.pattern=="string"&&(r.pattern=new RegExp(r.pattern))}else n.tokens=ao;Array.isArray(n.mask)&&(n.mask.length>1?n.mask=[...n.mask].sort((r,o)=>r.length-o.length):n.mask=n.mask[0]??""),n.mask===""&&(n.mask=null),this.opts=n}masked(e){return this.process(e,this.findMask(e))}unmasked(e){return this.process(e,this.findMask(e),!1)}isEager(){return this.opts.eager===!0}isReversed(){return this.opts.reversed===!0}completed(e){const n=this.findMask(e);if(this.opts.mask==null||n==null)return!1;const r=this.process(e,n).length;return typeof this.opts.mask=="string"?r>=this.opts.mask.length:r>=n.length}findMask(e){const n=this.opts.mask;if(n==null)return null;if(typeof n=="string")return n;if(typeof n=="function")return n(e);const r=this.process(e,n.slice(-1).pop()??"",!1);return n.find(o=>this.process(e,o,!1).length>=r.length)??""}escapeMask(e){const n=[],r=[];return e.split("").forEach((o,s)=>{o==="!"&&e[s-1]!=="!"?r.push(s-r.length):n.push(o)}),{mask:n.join(""),escaped:r}}process(e,n,r=!0){if(this.opts.number!=null)return id(e,r,this.opts);if(n==null)return e;const o=`v=${e},mr=${n},m=${r?1:0}`;if(this.memo.has(o))return this.memo.get(o);const{mask:s,escaped:a}=this.escapeMask(n),d=[],c=this.opts.tokens!=null?this.opts.tokens:{},u=this.isReversed()?-1:1,h=this.isReversed()?"unshift":"push",f=this.isReversed()?0:s.length-1,p=this.isReversed()?()=>b>-1&&B>-1:()=>b<s.length&&B<e.length,y=L=>!this.isReversed()&&L<=f||this.isReversed()&&L>=f;let g,k=-1,b=this.isReversed()?s.length-1:0,B=this.isReversed()?e.length-1:0,D=!1;for(;p();){const L=s.charAt(b),V=c[L],T=(V==null?void 0:V.transform)!=null?V.transform(e.charAt(B)):e.charAt(B);if(!a.includes(b)&&V!=null?(T.match(V.pattern)!=null?(d[h](T),V.repeated?(k===-1?k=b:b===f&&b!==k&&(b=k-u),f===k&&(b-=u)):V.multiple&&(D=!0,b-=u),b+=u):V.multiple?D&&(b+=u,B-=u,D=!1):T===g?g=void 0:V.optional&&(b+=u,B-=u),B+=u):(r&&!this.isEager()&&d[h](L),T===L&&!this.isEager()?B+=u:g=L,this.isEager()||(b+=u)),this.isEager())for(;y(b)&&(c[s.charAt(b)]==null||a.includes(b));){if(r){if(d[h](s.charAt(b)),e.charAt(B)===s.charAt(b)){b+=u,B+=u;continue}}else s.charAt(b)===e.charAt(B)&&(B+=u);b+=u}}return this.memo.set(o,d.join("")),this.memo.get(o)}};const uo=t=>JSON.parse(t.replaceAll("'",'"')),od=(t,e={})=>{const n={...e};t.dataset.maska!=null&&t.dataset.maska!==""&&(n.mask=sd(t.dataset.maska)),t.dataset.maskaEager!=null&&(n.eager=ln(t.dataset.maskaEager)),t.dataset.maskaReversed!=null&&(n.reversed=ln(t.dataset.maskaReversed)),t.dataset.maskaTokensReplace!=null&&(n.tokensReplace=ln(t.dataset.maskaTokensReplace)),t.dataset.maskaTokens!=null&&(n.tokens=ad(t.dataset.maskaTokens));const r={};return t.dataset.maskaNumberLocale!=null&&(r.locale=t.dataset.maskaNumberLocale),t.dataset.maskaNumberFraction!=null&&(r.fraction=parseInt(t.dataset.maskaNumberFraction)),t.dataset.maskaNumberUnsigned!=null&&(r.unsigned=ln(t.dataset.maskaNumberUnsigned)),(t.dataset.maskaNumber!=null||Object.values(r).length>0)&&(n.number=r),n},ln=t=>t!==""?!!JSON.parse(t):!0,sd=t=>t.startsWith("[")&&t.endsWith("]")?uo(t):t,ad=t=>{if(t.startsWith("{")&&t.endsWith("}"))return uo(t);const e={};return t.split("|").forEach(n=>{const r=n.split(":");e[r[0]]={pattern:new RegExp(r[1]),optional:r[2]==="optional",multiple:r[2]==="multiple",repeated:r[2]==="repeated"}}),e};let ld=class{constructor(e,n={}){an(this,"items",new Map),an(this,"onInput",r=>{if(r instanceof CustomEvent&&r.type==="input"&&!r.isTrusted&&!r.bubbles)return;const o=r.target,s=this.items.get(o),a="inputType"in r&&r.inputType.startsWith("delete"),d=s.isEager(),c=a&&d&&s.unmasked(o.value)===""?"":o.value;this.fixCursor(o,a,()=>this.setValue(o,c))}),this.options=n,this.init(this.getInputs(e))}update(e={}){this.options={...e},this.init(Array.from(this.items.keys()))}updateValue(e){e.value!==""&&e.value!==this.processInput(e).masked&&this.setValue(e,e.value)}destroy(){for(const e of this.items.keys())e.removeEventListener("input",this.onInput);this.items.clear()}init(e){const n=this.getOptions(this.options);for(const r of e){this.items.has(r)||r.addEventListener("input",this.onInput,{capture:!0});const o=new rd(od(r,n));this.items.set(r,o),queueMicrotask(()=>this.updateValue(r)),r.selectionStart===null&&o.isEager()&&console.warn("Maska: input of `%s` type is not supported",r.type)}}getInputs(e){return typeof e=="string"?Array.from(document.querySelectorAll(e)):"length"in e?Array.from(e):[e]}getOptions(e){const{onMaska:n,preProcess:r,postProcess:o,...s}=e;return s}fixCursor(e,n,r){const o=e.selectionStart,s=e.value;if(r(),o===null||o===s.length&&!n)return;const a=e.value,d=s.slice(0,o),c=a.slice(0,o),u=this.processInput(e,d).unmasked,h=this.processInput(e,c).unmasked;let f=o;d!==c&&(f+=n?a.length-s.length:u.length-h.length),e.setSelectionRange(f,f)}setValue(e,n){const r=this.processInput(e,n);e.value=r.masked,this.options.onMaska!=null&&(Array.isArray(this.options.onMaska)?this.options.onMaska.forEach(o=>o(r)):this.options.onMaska(r)),e.dispatchEvent(new CustomEvent("maska",{detail:r})),e.dispatchEvent(new CustomEvent("input",{detail:r.masked}))}processInput(e,n){const r=this.items.get(e);let o=n??e.value;this.options.preProcess!=null&&(o=this.options.preProcess(o));let s=r.masked(o);return this.options.postProcess!=null&&(s=this.options.postProcess(s)),{masked:s,unmasked:r.unmasked(o),completed:r.completed(o)}}};const li=new WeakMap,cd=(t,e)=>{if(t.arg==null||t.instance==null)return;const n="setup"in t.instance.$.type;t.arg in t.instance?t.instance[t.arg]=e:n&&console.warn("Maska: please expose `%s` using defineExpose",t.arg)},ho=(t,e)=>{var n;const r=t instanceof HTMLInputElement?t:t.querySelector("input");if(r==null||(r==null?void 0:r.type)==="file")return;let o={};if(e.value!=null&&(o=typeof e.value=="string"?{mask:e.value}:{...e.value}),e.arg!=null){const s=a=>{const d=e.modifiers.unmasked?a.unmasked:e.modifiers.completed?a.completed:a.masked;cd(e,d)};o.onMaska=o.onMaska==null?s:Array.isArray(o.onMaska)?[...o.onMaska,s]:[o.onMaska,s]}li.has(r)?(n=li.get(r))==null||n.update(o):li.set(r,new ld(r,o))},dd=["for"],ud={class:"left-field"},hd=["disabled"],fd={class:"right-field"},dt=M(i.defineComponent({__name:"PInput",props:i.mergeModels({label:{type:String,default:"",required:!1},margin:{type:String,required:!1,default:""},disabled:{type:Boolean,required:!1,default:!1},padding:{type:String,default:"",required:!1},mask:{type:String,required:!1,default:void 0},borderColor:{type:String,default:"var(--input-border-color)",required:!1},color:{type:String,default:"var(--input-font-color)",required:!1}},{modelValue:{},modelModifiers:{}}),emits:i.mergeModels(["blur","input"],["update:modelValue"]),setup(t){const e=i.useModel(t,"modelValue");return(n,r)=>(i.openBlock(),i.createElementBlock("div",{class:"text-field",style:i.normalizeStyle({margin:t.margin,padding:t.padding})},[t.label?(i.openBlock(),i.createElementBlock("label",{key:0,class:"text-field__label",for:t.label},i.toDisplayString(t.label),9,dd)):i.createCommentVNode("",!0),i.createElementVNode("div",{class:"field",style:i.normalizeStyle({borderColor:t.borderColor})},[i.createElementVNode("div",ud,[i.renderSlot(n.$slots,"default",{},void 0,!0)]),i.withDirectives(i.createElementVNode("input",i.mergeProps(n.$attrs,{"onUpdate:modelValue":r[0]||(r[0]=o=>e.value=o),class:"text-field__input",style:{color:t.color},disabled:t.disabled,onBlur:r[1]||(r[1]=o=>n.$emit("blur",e.value)),onInput:r[2]||(r[2]=o=>n.$emit("input",e.value))}),null,16,hd),[[i.vModelDynamic,e.value],[i.unref(ho),t.mask]]),i.createElementVNode("div",fd,[i.renderSlot(n.$slots,"right",{},void 0,!0)])],4)],4))}}),[["__scopeId","data-v-3e6801ac"]]),md={class:"btn-group"},cn=M(i.defineComponent({__name:"AuthForm",props:{width:{type:String,default:"300px"},margin:{type:String,default:"auto"},padding:{type:String,default:"60px 100px"}},emits:["submit"],setup(t,{emit:e}){const n=m.Auth.Form,r=i.ref(!1),o=e,s=i.computed(()=>n.GetButtons()),a=async d=>{await m.Auth.Form.Block(async()=>{if(!d.submit)return n.SetStatus(d.GetStatus());const c=n.Validate();if(c.length>0){m.Notification.Error(c.join(", "));return}o("submit")})};return i.onBeforeUnmount(()=>{n.Reset()}),(d,c)=>{const u=dt,h=be;return i.openBlock(),i.createElementBlock("div",{class:"auth-card",style:i.normalizeStyle({width:t.width,margin:t.margin,padding:t.padding})},[i.createElementVNode("div",null,i.toDisplayString(("PF"in d?d.PF:i.unref(m)).Auth.Form.GetTitle()),1),i.createElementVNode("div",null,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(("PF"in d?d.PF:i.unref(m)).Auth.Form.GetFields(),f=>(i.openBlock(),i.createBlock(u,{id:f.id,key:f,modelValue:f.value,"onUpdate:modelValue":p=>f.value=p,placeholder:f.label,margin:"10px 0 0 0"},null,8,["id","modelValue","onUpdate:modelValue","placeholder"]))),128)),i.createVNode(h,{type:"primary",skin:"text_ano",text:"Забыли пароль?",width:"124px",margin:"0 0 0 5px"}),i.createElementVNode("div",md,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(s),f=>(i.openBlock(),i.createBlock(h,{id:f.id,key:f.GetStatus(),disabled:i.unref(r),type:"primary",skin:"base",text:f.text,color:f.submit?"blue":"grey",margin:"10px 0 0 0",width:"100%",height:"52px",onClick:p=>a(f)},null,8,["id","disabled","text","color","onClick"]))),128))])])],4)}}}),[["__scopeId","data-v-4ca1b015"]]),pd={class:"bg"},ci=M(i.defineComponent({__name:"AuthPage",setup(t){const e=()=>{m.Auth.Form.IsLogin()&&m.H.Router.ToHome()};return(n,r)=>{const o=cn;return i.openBlock(),i.createElementBlock("div",pd,[i.createVNode(o,{width:"760px",margin:"0 auto",onAction:e})])}}}),[["__scopeId","data-v-d59b7e97"]]),gd={},yd={style:{"text-align":"center"}};function wd(t,e){return i.openBlock(),i.createElementBlock("div",yd,e[0]||(e[0]=[i.createElementVNode("h1",null,"Страница не найдена",-1)]))}const di=M(gd,[["render",wd]]),bd=[{path:"/",redirect:"/login"},{path:"/login",component:ci,meta:{layout:"LoginLayout"}},{path:"/:pathMatch(.*)*",name:"NotFound",component:di}],We=class We{static SetRouter(e){this.router=e,this.AddRoutes(bd)}static GetRouter(){return this.router}static AddRoutes(e){e.forEach(n=>{this.GetRouter().addRoute(n)})}static async To(e){await this.GetRouter().push(e)}static async ToHome(){}static async Replace(e){await this.GetRouter().replace(e)}static Id(){return We.GetStringParam("id")}static Slug(){return We.GetStringParam("slug")}static async Back(){this.GetRouter().go(-1)}static GetQid(){return We.GetStringQueryParam("qid")}static Route(){return this.GetRouter().currentRoute.value}static RouterPushBlank(e){const n=this.GetRouter().resolve({path:e});window.open(n==null?void 0:n.href,"_blank")}static GetPath(){var n;const e=(n=We.Route())==null?void 0:n.path.split("/");return!e||e.length<=0?"":e[e.length-1]}static async ToAdmin(e){if(!e){await this.GetRouter().push("/admin");return}let n=e;n[0]==="/"&&(n=e.substring(1)),await We.To(`/admin/${n}`)}static GetStringQueryParam(e){return String(this.Route().query[e])}static GetNumberQueryParam(e){return Number(this.Route().query[e]??0)}static GetStringParam(e){return this.Route().params[e]}static Resolve(e){return this.GetRouter().resolve(e)}};l(We,"router");let ui=We;class Cd{static async Auth(e){e&&e()}static Dev(){}}class Sd{constructor(){l(this,"startHour",9);l(this,"startHM",`${this.startHour}:00`);l(this,"endHour",19);l(this,"endHM",`${this.endHour}:00`);l(this,"timelinePxHeight",50);l(this,"timelineStep",At.FiveMinutes);l(this,"timelines",sn[At.FiveMinutes])}periodIsCorrect(e,n){return H.GtOrEq(e,this.startHM)&&H.GtOrEq(this.endHM,n)}setTimelineStep(e){this.timelineStep=e,this.setTimelines()}setTimelines(){this.timelines=sn[this.timelineStep]}getScheduleHeight(){return this.getHourHeight()*this.getHoursArr().length}getHourHeight(){return this.timelinePxHeight*this.timelines.length}getHoursArr(){return _e.GenerateNumsRange(this.startHour,this.endHour)}timeIsFree(e,n,r,o){return o.filter(s=>s.id!==r).every(s=>!H.PeriodsIntersects(e,n,s.startTime,s.endTime))}sortByStartTime(e){e.sort((n,r)=>H.HMtoM(n.startTime)-H.HMtoM(r.startTime))}}const kd=-68;function Ed(t,e){if(!t){document.body.scrollTo({top:0,behavior:"smooth"});return}const n=document.querySelector(t),r=e??kd;let o=0;n&&(o=n.getBoundingClientRect().top+r+document.body.scrollTop),o&&document.body.scrollTo({top:o,behavior:"smooth"})}class vd{static Sort(e){e.forEach((n,r)=>n.order=r)}}class fo{static Setup(e){this.staticUrl=e}static get StaticUrl(){return this.staticUrl}}l(fo,"staticUrl","");class $e{static Capitalize(e){return e?e[0].toUpperCase()+e.slice(1):""}static ToCamelCase(e){const n=new RegExp(["[А-Я][а-я][A-Z][a-z]+","[А-Я]+(?=[А-Я][а-я])","[A-Z]+(?=[A-Z][a-z])","[А-Я]+","[A-Z]+","[а-я]+","[a-z]+","[0-9]+"].join("|"),"g");return e.match(n).map((o,s)=>s===0?o.toLowerCase():$e.Capitalize(o.toLowerCase())).join("")}static ToKebabCase(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase()}static GetStringBetweenChars(e,n,r){return e.substring(e.indexOf(n)+2,e.lastIndexOf(r))}static Translit(e,n){const r={q:"й",w:"ц",e:"у",r:"к",t:"е",y:"н",u:"г",i:"ш",o:"щ",p:"з","[":"х","]":"ъ",a:"ф",s:"ы",d:"в",f:"а",g:"п",h:"р",j:"о",k:"л",l:"д",";":"ж","'":"э",z:"я",x:"ч",c:"с",v:"м",b:"и",n:"т",m:"ь",",":"б",".":"ю","/":"."};return n&&/[а-яА-Я]/g.test(e)?e.replace(/[А-я/,.;'\][]/g,o=>{if(o===o.toLowerCase()){const a=Object.keys(r).find(d=>r[d]===o);return a||""}const s=Object.keys(r).find(a=>r[a]===o.toLowerCase());return s?s.toUpperCase():""}):e.replace(/[A-z/,.;'\][]/g,o=>o===o.toLowerCase()?r[o]:r[o.toLowerCase()].toUpperCase())}static RemoveEmoji(e){const n=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;return e.replace(n,"")}static CanBeTranslited(e){return/^[~`!@#$%^&*()_+=[\]\\{}|;':",.\/<>?a-zA-Z0-9-]+$/.test(e)}static StringsEquals(e,n){const r=e.toLowerCase().replaceAll(/\s/g,""),o=n.toLowerCase().replaceAll(/\s/g,""),s=$e.Translit(r),a=$e.Translit(o);return r.includes(o)||s.includes(o)||r.includes(a)}static SearchIn(e,n){return $e.StringsEquals(e,n)}static FormatToPercentage(e){return`${e}%`}static WrapSubStr(e,n){const r=new RegExp($e.GetVariants(n).join("|"),"gi");return e.replace(r,`<span class="search-text">${n}</span>`)}static GetVariants(e){const n=$e.Translit(e);return[e,$e.Capitalize(e),e.toLowerCase(),e.toUpperCase(),n,$e.Capitalize(n),n.toLowerCase(),n.toUpperCase()]}static ContainsNum(e){return/\d/.test(e)}static CreateGuid(){const e=function(){return((1+Math.random())*65536|0).toString(16).substring(1)};return e()+e()+"-"+e()+"-"+e()+"-"+e()+"-"+e()+e()+e()}static JoinSnake(...e){return e.join("_")}static GetDynamicCountName(e,n){const r=[2,0,1,1,1,2];return e.length+" "+n[e.length%100>4&&e.length%100<20?2:r[e.length%10<5?e.length%10:5]]}}class Pt{static Wait(e,n){return new Promise(r=>setTimeout(()=>r(n),e))}static WaitS(e,n){return Pt.Wait(H.S(e),n)}static WaitM(e,n){return Pt.Wait(H.M(e),n)}}function Md(t,e){let n=!0;return t.value.validate(r=>(r||(n=!1),n)),n}const xd=t=>new Promise(e=>{if(document.querySelector(t))return e(document.querySelector(t));const n=new MutationObserver(()=>{document.querySelector(t)&&(n.disconnect(),e(document.querySelector(t)))});n.observe(document.body,{childList:!0,subtree:!0})});class dn{constructor(e){l(this,"id");l(this,"message","");l(this,"userName");l(this,"createdOn",new Date);l(this,"chatId");l(this,"type","message");m.H.Classes.BuildClass(this,e)}static Create(e,n,r,o){const s=new dn;return s.id=ce(),s.chatId=e,s.message=r,s.userName=o,s}static CreatePingMessage(){const e=new dn;return e.type="ping",e.id=ce(),e}isMessage(){return this.type==="message"||this.type===""}}const Bd="";class Id{constructor(e="",n="",r="set"){l(this,"client");l(this,"endpoint","");l(this,"query","");l(this,"period",2e4);m.H.Classes.BuildClass(this,{endpoint:e,query:n,mutation:r}),this.connect(),this.ping()}send(e){!this.client||this.client.readyState!==1||this.client.send(e)}ping(){setInterval(this.sendPing.bind(this),this.period)}sendPing(){!this.client||this.client.readyState!==1||this.send(JSON.stringify(dn.CreatePingMessage()))}setOnMessage(){this.client&&(this.client.onmessage=e=>{e.data})}buildUrl(){const e=`ws/${this.endpoint}/${this.query}`;return new URL(e,Bd.replace("http","ws")).toString()}connect(){this.client=new WebSocket(this.buildUrl()),this.client.onclose=this.reconnect,this.client.onerror=this.reconnect}reconnect(){setTimeout(this.connect,3e3)}}const Rd=Object.freeze(Object.defineProperty({__proto__:null,Arrays:_e,Axios:Nt,BaseStore:K,Button:je,Cache:Vc,CarouselSwipe:Fc,Classes:Oe,Color:Lc,Contact:Vn,CreateSortModels:yr,Cursor:Hc,DateMask:Gc,Dates:ze,Dragger:Jc,Email:He,Extension:Xc,FTSP:sl,Favourite:Yc,FilterModel:Fn,Hooks:ul,HttpClient:ie,MakeCarousel:so,Period:ri,PhoneService:ai,Rating:Qc,Router:ui,RouterGuard:Cd,Scheduler:Sd,Scroll:Ed,Sizes:Ln,SortModel:Zt,Sorter:vd,Static:fo,Statuses:se,Strings:$e,Time:H,Timer:Pt,Token:$t,ValueType:Dn,WaitElement:xd,WebSocketClient:Id,useConfirmLeavePage:wr,validate:Md},Symbol.toStringTag,{value:"Module"}));class $d extends lr{Show(){super.show()}Hide(){super.hide()}}const Nd=new $d;class Ad extends cr{constructor(){super(...arguments);l(this,"duration",H.S(3))}showMessage(n,r){super.showMessage(n,r),typeof n!="string"&&(this.duration=n.duration??this.duration),Pt.Wait(this.GetDuration()).then(()=>super.hide())}GetDuration(){return this.duration}Dev(){const n="В режиме разработки",r=se.Warning;super.showMessage(n,r)}Save(){const n="Изменения успешно сохранены",r=se.Success;super.showMessage(n,r)}}const Pd=new Ad;class Td{constructor(){l(this,"limit",25);l(this,"count",0);l(this,"curPage",1);l(this,"storeModule","")}setCurPage(e){this.curPage=e}pagesCount(){return Math.ceil(this.count/this.limit)??1}reset(){this.count=0,this.curPage=1}}const zd=new Td;let Vd=class{async Login(e){const n=e??m.Auth.Form.GetValues(),r=await ie.Post({query:"auth/login",payload:n});if(!r)throw m.Notification.Error("Ошибка авторизации"),"Ошибка авторизации";m.Auth.Status.SetState(r)}async LoginAs(e){if(!await ie.Post({query:"auth/login-as",payload:{email:e}})){m.Notification.Error("Ошибка авторизации");return}}async Register(){}async RestorePassword(){}async passwordChange(){await ie.Put({query:"auth/password-change"})}async RefreshToken(){await ie.Post({query:"auth/refresh-token",payload:{refreshToken:$t.getRefreshToken()}})}async CheckUuid(e){await ie.Get({query:`auth/check-uuid/${e.userId}/${e.uniqueId}`})}};const Fd=new Vd;let Dd=class extends K{constructor(){super(Vn,"contacts")}};const Ld=new Dd;class un{constructor(e){l(this,"id");l(this,"ratio",0);l(this,"src","");l(this,"store","");m.H.Classes.BuildClass(this,e)}static CreateCropper(e,n,r){const o=new un;return o.src=e,o.id=r,n&&(o.ratio=n),o}}let Hd=class{constructor(){l(this,"cropper",new un)}Open(e){this.cropper=e}Cropper(){return this.cropper}Ratio(){return this.cropper.ratio}};const Od=new Hd;let _d=class extends K{constructor(){super(He,"emails")}};const qd=new _d;let Ud=class extends K{constructor(){super(pe,"file-infos")}};const Wd=new Ud;class hi{constructor(e){l(this,"id");l(this,"ftsp");l(this,"name","");m.H.Classes.BuildClass(this,e)}static Create(e){const n=new hi;return n.id=m.H.Classes.CreateUUID(),n.ftsp=JSON.stringify(e),n}}let Gd=class extends K{constructor(){super(hi,"ftsp-presets")}};const jd=new Gd;let Zd=class extends K{constructor(){super(ar,"humans")}};const Jd=new Zd;class mo{constructor(e){l(this,"id");l(this,"name","");l(this,"order",0);l(this,"downloadToFile",!1);l(this,"pageSectionId");l(this,"scan",new pe);l(this,"scanId");e&&(this.id=e==null?void 0:e.id,this.name=e.name,this.order=e.order,this.downloadToFile=e.downloadToFile,this.pageSectionId=e.pageSectionId,e.scan&&(this.scan=new pe(e.scan)),this.scanId=e.scanId)}getFileInfos(){return[this.scan]}uploadScan(e){return this.scan.id||(this.scan.id=ce()),this.scan.originalName=e.name,this.scan.file=e.raw,this.scan.fileSystemPath=ce(),this.scan.url=e.url,this.scan}getFileName(){return this.name?this.name:this.scan.originalName}}class Xd{constructor(e){l(this,"id");l(this,"documentType",new Ye);l(this,"documentTypeId");l(this,"order",0);m.H.Classes.BuildClass(this,e)}getFileInfos(){const e=[];return e.push(...this.documentType.getFileInfos()),e}}var Yd=Object.defineProperty,po=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&Yd(e,n,o),o};class Ye{constructor(e){l(this,"id");l(this,"name","");l(this,"singleScan",!1);l(this,"scan");l(this,"scanId");l(this,"order",0);l(this,"description","");l(this,"scans",[]);l(this,"scansForDelete",[]);l(this,"pageSectionDocuments",[]);l(this,"pageSectionDocumentsForDelete",[]);l(this,"pageSectionImages",[]);l(this,"pageSectionImagesForDelete",[]);l(this,"pageSideMenuId");l(this,"pageId");l(this,"text","");l(this,"documents",[]);m.H.Classes.BuildClass(this,e),this.documents=this.pageSectionDocuments,this.text=this.description.replace("<p>undefined</p>","")}addDocument(){const e=new mo;e.order=this.pageSectionDocuments.length-1,this.pageSectionDocuments.push(e)}getFileInfos(){const e=[];return this.pageSectionDocuments.forEach(n=>{e.push(...n.getFileInfos())}),e}infoExists(e){const n=m.H.Strings.SearchIn(this.name,e),r=m.H.Strings.SearchIn(this.description,e),o=this.getDocuments(e);return n||r||o.length>0}getDocuments(e){return this.pageSectionDocuments.filter(n=>m.H.Strings.SearchIn(n.name,e))}getDescription(e){return e?m.H.Strings.WrapSubStr(this.description,e):this.description}filter(e){if(!e){this.text=this.description,this.documents=this.pageSectionDocuments;return}this.text=m.H.Strings.SearchIn(this.description,e)?m.H.Strings.WrapSubStr(this.description,e):"",this.documents=this.pageSectionDocuments.filter(n=>m.H.Strings.SearchIn(n.name,e))}}po([m.H.Classes.GetClassConstructor(mo)],Ye.prototype,"pageSectionDocuments"),po([m.H.Classes.GetClassConstructor(Xd)],Ye.prototype,"pageSectionImages");class Qd{constructor(e){l(this,"id");l(this,"document",new Ye);l(this,"documentId");l(this,"pageId");m.H.Classes.BuildClass(this,e)}static GetFileInfos(e){const n=[];return e.forEach(r=>{const o=r.document.scan;o&&n.push(o)}),n}}var Kd=Object.defineProperty,eu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&Kd(e,n,o),o};class go{constructor(e){l(this,"id");l(this,"pageId");l(this,"fileInfoId");l(this,"fileInfo");l(this,"description");m.H.Classes.BuildClass(this,e)}}eu([m.H.Classes.GetClassConstructor(pe)],go.prototype,"fileInfo");var tu=Object.defineProperty,nu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&tu(e,n,o),o};class ut{constructor(e){l(this,"id");l(this,"name","Новое меню");l(this,"order",0);l(this,"description","");l(this,"routeAnchor","");l(this,"slug","");l(this,"pageSections",[]);l(this,"pageSectionsForDelete",[]);l(this,"showContent",!1);l(this,"pageId");l(this,"selected",!1);l(this,"sections",[]);l(this,"text","");m.H.Classes.BuildClass(this,e),this.sections=this.pageSections,this.text=this.description.replace("<p>undefined</p>","")}getFileInfos(){const e=[];return this.pageSections.forEach(n=>{e.push(...n.getFileInfos())}),e}addPageSection(){const e=new Ye;e.order=this.pageSections.length+1,e.name=`Новой раздел ${e.order}`,e.id=m.H.Classes.CreateUUID(),this.pageSections.push(e)}infoExists(e){const n=m.H.Strings.SearchIn(this.name,e),r=m.H.Strings.SearchIn(this.description,e),o=this.getPageSections(e).length>0;return n||r||o}getPageSections(e){return e.length?this.pageSections.filter(n=>n.infoExists(e)):this.pageSections}filter(e){e.length?(this.sections=this.pageSections.filter(n=>n.infoExists(e)),this.text=m.H.Strings.SearchIn(this.description,e)?m.H.Strings.WrapSubStr(this.description,e):""):(this.sections=this.pageSections,this.text=this.description),this.sections.forEach(n=>n.filter(e))}}nu([m.H.Classes.GetClassConstructor(Ye)],ut.prototype,"pageSections");var yo=(t=>(t.User="USER",t.Admin="ADMIN",t))(yo||{});class iu{constructor(e){l(this,"id");l(this,"name",yo.User);l(this,"label","");l(this,"startPage","");m.H.Classes.BuildClass(this,e)}}var ru=Object.defineProperty,hn=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&ru(e,n,o),o};class ht{constructor(e){l(this,"id");l(this,"title","");l(this,"content","");l(this,"slug","");l(this,"pagesGroup","Без группы");l(this,"link","");l(this,"withComments",!1);l(this,"showContacts",!1);l(this,"collaps",!1);l(this,"showContent",!1);l(this,"pageImages",[]);l(this,"pageImagesForDelete",[]);l(this,"pageImagesNames",[]);l(this,"pageSideMenus",[]);l(this,"menus",[]);l(this,"pageSideMenusForDelete",[]);l(this,"pageSections",[]);l(this,"pageSectionsForDelete",[]);l(this,"pageDocuments",[]);l(this,"contact",new Vn);l(this,"contactId");l(this,"role",new iu);l(this,"roleId");l(this,"filterStr","");l(this,"activeMenuId","");m.H.Classes.BuildClass(this,e),this.menus=this.pageSideMenus}getActiveMenu(){const e=this.pageSideMenus.find(n=>n.id===this.activeMenuId);return e||this.pageSideMenus[0]}setActiveMenuId(e){this.activeMenuId=e}getLink(){return this.slug!==""?`/pages/${this.slug}`:"404"}getFileInfos(){const e=[];return this.pageSideMenus.forEach(n=>{e.push(...n.getFileInfos())}),this.pageDocuments.forEach(n=>{n.document.scan&&e.push(n.document.scan)}),this.pageImages.forEach(n=>{n.fileInfo&&e.push(n.fileInfo)}),e}addSideMenu(){const e=new ut;return e.order=this.pageSideMenus.length+1,e.name=`Новое меню ${e.order}`,e.id=ce(),this.pageSideMenus.push(e),e.id}selectSideMenu(e,n){if(!e&&this.pageSideMenus.length>0){this.pageSideMenus[0].selected=!0;return}this.pageSideMenus.forEach(r=>{n?r.selected=r.id===e:r.selected=r.slug===e})}getSelectedSideMenu(){const e=this.pageSideMenus.find(n=>n.selected);return e||new ut}addCustomSectionsToSideMenu(e){e.forEach(n=>{const r=new ut;r.id=n.id,r.name=n.name,typeof n.order<"u"?this.pageSideMenus.splice(n.order,0,r):this.pageSideMenus.push(r)})}getPageSideMenus(){if(this.showContacts&&!this.pageSideMenus.find(e=>e.id==="contacts")){const e=new ut;e.id="contacts",e.name="Контакты",this.pageSideMenus.push(e)}return this.filterStr===""?this.pageSideMenus:this.pageSideMenus.filter(e=>e.infoExists(this.filterStr))}filter(){this.filterStr===""?this.menus=this.pageSideMenus:this.menus=this.pageSideMenus.filter(e=>e.infoExists(this.filterStr)),this.menus.forEach(e=>e.filter(this.filterStr))}static GetClassName(){return"page"}}hn([m.H.Classes.GetClassConstructor(go)],ht.prototype,"pageImages"),hn([m.H.Classes.GetClassConstructor(ut)],ht.prototype,"pageSideMenus"),hn([m.H.Classes.GetClassConstructor(Ye)],ht.prototype,"pageSections"),hn([m.H.Classes.GetClassConstructor(Qd)],ht.prototype,"pageDocuments");class wo{constructor(e){l(this,"id");l(this,"name","");l(this,"link","");l(this,"selected",!1);l(this,"hide",!1);l(this,"editMode",!1);l(this,"color","");l(this,"background","");l(this,"page",new ht);l(this,"pageId");l(this,"order",0);l(this,"menuId");l(this,"iconId");l(this,"icon",new pe);l(this,"iconName","");l(this,"svgCode","");m.H.Classes.BuildClass(this,e)}getLink(){return this.isLink()&&!this.isPageLink()?this.link:!this.isLink()&&this.isPageLink()?this.page.getLink():""}isLink(){return this.link!==""}isPageLink(){return this.pageId!==void 0&&this.pageId!==""}addFile(e){this.icon.id||(this.icon.id=ce()),this.icon.originalName=e.name,this.icon.file=e.raw}}var ou=Object.defineProperty,su=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&ou(e,n,o),o};class bo{constructor(e){l(this,"id");l(this,"name","");l(this,"link","");l(this,"top",!0);l(this,"side",!0);l(this,"show",!1);l(this,"hide",!1);l(this,"active",!1);l(this,"order",0);l(this,"selected",!1);l(this,"editMode",!1);l(this,"page",new ht);l(this,"pageId");l(this,"subMenus",[]);l(this,"subMenusForDelete",[]);l(this,"iconId");l(this,"icon",new pe);m.H.Classes.BuildClass(this,e)}getLink(){return this.isLink()&&!this.isPageLink()?this.link:!this.isLink()&&this.isPageLink()?this.page.getLink():""}withoutChildren(){return this.subMenus.length===0}isLink(){return this.link!==""}isPageLink(){return!!this.pageId&&this.pageId!==""}getFileInfos(){const e=[];return e.push(this.icon),this.subMenus.forEach(n=>{e.push(n.icon)}),e}addFile(e){this.icon.id||(this.icon.id=ce()),this.icon.originalName=e.name,this.icon.file=e.raw}addSubMenu(){this.subMenus.push(new wo)}removeSubMenu(e){const n=this.subMenus[e].id;n&&this.subMenusForDelete.push(n),this.subMenus.splice(e,1)}setColorsForSubMenus(){const e=["#00A248","#E63021","#006BB5","#F3911F","#6F6D6B"];let n=0;this.subMenus.forEach(r=>{r.color=e[n],n=e.length-1?n=0:n++})}containPath(e){return this.getLink()===e||!!this.subMenus.find(n=>n.getLink()===e)}static GetClassName(){return"menu"}}su([m.H.Classes.GetClassConstructor(wo)],bo.prototype,"subMenus");let au=class extends m.H.BaseStore{constructor(){super(bo,"menus")}};const lu=new au;let cu=class extends K{constructor(){super(st,"phones")}};const du=new cu;class uu{constructor(e){l(this,"id");l(this,"nameRus","");m.H.Classes.BuildClass(this,e)}}var hu=Object.defineProperty,fu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&hu(e,n,o),o};class Co{constructor(e){l(this,"id");l(this,"nameRus","");l(this,"fields",[]);m.H.Classes.BuildClass(this,e)}}fu([m.H.Classes.GetClassConstructor(uu)],Co.prototype,"fields");let mu=class extends K{constructor(){super(Co,"schemas")}};const pu=new mu;class So{constructor(e){l(this,"id","");l(this,"value","");l(this,"label","");l(this,"key","");l(this,"description","");l(this,"route","");l(this,"searchElementMetas",[]);m.H.Classes.BuildClass(this,e)}}class gu{constructor(e){l(this,"id");l(this,"name","");l(this,"label","");m.H.Classes.BuildClass(this,e)}}var yu=Object.defineProperty,ko=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&yu(e,n,o),o};class ft{constructor(e){l(this,"id");l(this,"key","");l(this,"label","");l(this,"order",0);l(this,"route","");l(this,"table","");l(this,"active",!0);l(this,"searchColumn","");l(this,"descriptionColumn","");l(this,"labelColumn","");l(this,"valueColumn","");l(this,"options",[]);l(this,"searchGroupMetaColumns",[]);m.H.Classes.BuildClass(this,e)}}ko([m.H.Classes.GetClassConstructor(So)],ft.prototype,"options"),ko([m.H.Classes.GetClassConstructor(gu)],ft.prototype,"searchGroupMetaColumns");class fi{constructor(e){l(this,"query","");l(this,"key","");l(this,"params","");l(this,"suggester",!1);l(this,"mustBeTranslated",!0);l(this,"options",[]);l(this,"searchGroupId","");l(this,"searchGroups",[]);l(this,"searchGroup",new ft);l(this,"searchObjects",[]);l(this,"pagination",new Gt);l(this,"count",0);e&&(this.query=e.query,e.searchGroups&&(this.searchGroups=e.searchGroups.map(n=>new ft(n))),e.searchGroup&&(this.searchGroup=new ft(e.searchGroup)),e.options&&(this.options=e.options.map(n=>new So(n))),this.count=e.count)}toUrl(){return JSON.stringify(this)}async setSearchGroup(e){const n=this.searchGroups.find(r=>r.id===e);n?this.searchGroup=n:this.searchGroup=new ft}async reproduceFromRoute(){this.setQuery(),await this.setSearchGroup(m.H.Router.Route().query.groupId)}setQuery(){const e=m.H.Router.Route().query.query;e&&(this.query=e)}}let wu=class{constructor(){l(this,"isSearchDrawerOpen",i.ref(!1));l(this,"searchModel",i.reactive(new fi));l(this,"searchGroups",i.reactive([]));l(this,"count",0)}async Search(e){const n=await ie.Get({query:`?key=${e.key}&query=${e.query}`});n&&n.searchGroup&&n.searchGroup.options.forEach(r=>{e.searchObjects.push({id:r.id,value:r.value,label:r.label,description:r.description})})}async mainSearch(e){this.SetSearchModel(await ie.Get({query:`/main?searchModel=${e.toUrl()}`}))}async Full(e){e.options=[],e.searchGroups.forEach(r=>{r.options=[]});const n=await ie.Get({query:`main?searchModel=${e.toUrl()}`});this.SetSearchModel(n)}ToggleDrawer(e){this.isSearchDrawerOpen.value=e,this.searchModel=new fi}SetSearchModel(e){e&&(this.searchModel=new fi(e))}SetSearchGroups(){}IsSearchDrawerOpen(){return this.isSearchDrawerOpen}SearchModel(){return this.searchModel}SearchGroups(){return this.searchGroups}Count(){return this.count}};const bu=new wu;class mi{constructor(e){l(this,"id");l(this,"login","");l(this,"email","");l(this,"password","");m.H.Classes.BuildClass(this,e)}static Create(){const e=new mi;return e.id=m.H.Classes.CreateUUID(),e}}let Cu=class extends K{constructor(){super(mi,"users-accounts")}};const Su=new Cu;let ku=class extends K{constructor(){super(Dn,"value-types")}};const Eu=new ku,vu=Object.freeze(Object.defineProperty({__proto__:null,Auth:Fd,Contacts:Ld,Cropper:Od,Emails:qd,FTSPPresets:jd,FileInfos:Wd,Humans:Jd,Menus:lu,Phones:du,Schemas:pu,Search:bu,UserAccounts:Su,ValueTypes:Eu},Symbol.toStringTag,{value:"Module"}));class m{}l(m,"Auth",i.reactive(ir)),l(m,"AdminUI",i.reactive(Qa)),l(m,"Dialog",i.reactive(el)),l(m,"Notification",i.reactive(Pd)),l(m,"Loading",i.reactive(Nd)),l(m,"Paginator",i.reactive(zd)),l(m,"S",vu),l(m,"H",Rd),l(m,"C",Ga);class Qe{constructor(e){l(this,"id");l(this,"name","");l(this,"score",0);l(this,"order",0);l(this,"showMoreQuestions",!1);l(this,"showOther",!1);l(this,"fieldId");l(this,"isMatrixY",!1);m.H.Classes.BuildClass(this,e)}static Create(e){const n=new Qe;return n.id=m.H.Classes.CreateUUID(),n.fieldId=e,n}}class Eo{constructor(e){l(this,"id");l(this,"name","");l(this,"order",0);l(this,"fieldId");m.H.Classes.BuildClass(this,e)}}class pi{constructor(e){l(this,"id");l(this,"name","");l(this,"order",0);m.H.Classes.BuildClass(this,e)}}class mt{constructor(e){l(this,"id");l(this,"name","");l(this,"fieldId");m.H.Classes.BuildClass(this,e)}static Create(e){const n=new mt;return n.id=m.H.Classes.CreateUUID(),n.fieldId=e,n}}var Mu=Object.defineProperty,Tt=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&Mu(e,n,o),o};const Ke=class An{constructor(e){l(this,"id");l(this,"name","");l(this,"code","");l(this,"valueTypeId");l(this,"order",0);l(this,"ageCompare",!1);l(this,"answerVariants",[]);l(this,"answerVariantsForDelete",[]);l(this,"fieldExamples",[]);l(this,"fieldVariants",[]);l(this,"valueType",new Dn);l(this,"fieldMeasures",[]);l(this,"showSet",!1);l(this,"showRadio",!1);l(this,"isEdit",!1);l(this,"children",[]);l(this,"parentId");l(this,"formSectionId");l(this,"selected",!1);m.H.Classes.BuildClass(this,e),this.changeRelation([this.valueType])}getMatrixX(){return this.answerVariants.filter(e=>!e.isMatrixY)}getMatrixY(){return this.answerVariants.filter(e=>e.isMatrixY)}static Create(e){const n=new An;return n.id=m.H.Classes.CreateUUID(),n.formSectionId=e,n}getRegisterPropertyRadioOriginalValue(e){const n=this.answerVariants.find(r=>r.id===e);return n?n.name:""}addRadioItem(e){const n=new Qe(e);n.order=this.answerVariants.length,this.answerVariants.push(n)}removeRadioItem(e){const n=this.answerVariants[e].id;n&&this.answerVariantsForDelete.push(n),this.answerVariants.splice(e,1)}changeRelation(e){const n=e.find(r=>r.id===this.valueTypeId);if(n){if(n.isRadio()){this.showRadio=!0,this.showSet=!1;return}if(n.isSet()){this.showSet=!0,this.showRadio=!1;return}this.showSet=!1,this.showRadio=!1,this.valueType=n}}editRegisterProperty(e){this.isEdit=e??!this.isEdit}sortExamples(){this.fieldExamples.forEach((e,n)=>e.order=n)}addRegisterPropertyMeasure(e){this.fieldMeasures.push(new pi(e))}addRegisterPropertyVariant(){this.fieldVariants.push(new mt)}getIdWithoutDashes(){return this.id?this.id.replaceAll(/[^a-zA-Z]+/g,""):""}static GetClassName(){return"Field"}setType(e){this.valueType=e,this.valueTypeId=e.id}setName(e){this.name=e}addAnswerVariant(){const e=Qe.Create(this.id);return e.name="Вариант",e.order=this.answerVariants.length,this.answerVariants.push(e),e}addChild(){const e=An.Create();return e.parentId=this.id,e.name="Вопрос",e.order=this.children.length,this.children.push(e),e}addFieldVariant(){const e=mt.Create(this.id);return this.fieldVariants.push(e),e}copy(){const e=new An(this);return e.id=m.H.Classes.CreateUUID(),e.answerVariants.forEach(n=>{n.id=m.H.Classes.CreateUUID(),n.fieldId=e.id}),e.children=e.children.map(n=>{const r=n.copy();return r.parentId=e.id,r}),e}};Tt([m.H.Classes.GetClassConstructor(Qe)],Ke.prototype,"answerVariants"),Tt([m.H.Classes.GetClassConstructor(Eo)],Ke.prototype,"fieldExamples"),Tt([m.H.Classes.GetClassConstructor(mt)],Ke.prototype,"fieldVariants"),Tt([m.H.Classes.GetClassConstructor(pi)],Ke.prototype,"fieldMeasures"),Tt([m.H.Classes.GetClassConstructor(Ke)],Ke.prototype,"children");let fn=Ke;class gi{constructor(e){l(this,"id");l(this,"answerId");l(this,"comment","");l(this,"fileInfoId");l(this,"fileInfo",new pe);m.H.Classes.BuildClass(this,e)}}class et{constructor(e){l(this,"id");l(this,"answerVariantId");l(this,"answerVariantIdY");l(this,"fieldFillId");m.H.Classes.BuildClass(this,e)}static Create(e,n){const r=new et;return r.id=ce(),r.fieldFillId=e,r.answerVariantId=n,r}static GetClassName(){return"selectedAnswerVariant"}}var xu=Object.defineProperty,vo=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&xu(e,n,o),o};const yi=class Xi{constructor(e){l(this,"id");l(this,"valueString");l(this,"valueOther");l(this,"valueNumber");l(this,"valueDate");l(this,"fileInfo",new pe);l(this,"fileInfoId");l(this,"order",0);l(this,"selectedAnswerVariants",[]);l(this,"patientId");l(this,"fieldId");l(this,"formFillId");l(this,"answerVariantId");l(this,"filled",!1);l(this,"researchResultId");l(this,"answerFiles",[]);l(this,"answerFilesForDelete",[]);m.H.Classes.BuildClass(this,e)}setFilled(e){this.filled=e}static Create(e,n){const r=new Xi;return r.id=ce(),r.fieldId=e.id,r.formFillId=n,r.order=e.order,r.valueNumber=0,r.valueString="",r.valueDate=new Date,r}setString(e){this.valueString=e,this.valueString&&(this.filled=this.valueString.length>0)}setNumber(e){this.valueNumber=e,this.valueNumber&&(this.filled=!0)}setOther(e){this.valueOther=e,this.valueOther&&(this.filled=this.valueOther.length>0)}setDate(e){this.valueDate=e,this.filled=!0}setRadio(e){this.answerVariantId=e,this.filled=!!this.answerVariantId}static CreateMany(e,n){return e.map(r=>Xi.Create(r,n))}addFile(){const e=new gi;return e.id=ce(),e.answerId=this.id,this.answerFiles.push(e),e}getFileInfos(){const e=[];return this.answerFiles.forEach(n=>e.push(n.fileInfo)),e}getSelectedAnswerVariant(){return!0}setMatrixRadioValue(e,n){const r=et.Create(this.id,e);return r.answerVariantIdY=n,this.selectedAnswerVariants.push(r),this.filled=!0,r}getMatrixValue(e,n){return this.selectedAnswerVariants.find(r=>r.answerVariantId===e&&r.answerVariantIdY===n)}addSelectedAnswerVariant(e){const n=et.Create(this.id,e);return this.selectedAnswerVariants.push(n),this.filled=!0,n}static GetClassName(){return"answer"}showOther(e){const n=e.find(r=>r.showOther);return n?this.answerVariantId===n.id||this.selectedAnswerVariants.some(r=>r.answerVariantId===n.id):!1}};vo([m.H.Classes.GetClassConstructor(et)],yi.prototype,"selectedAnswerVariants"),vo([m.H.Classes.GetClassConstructor(gi)],yi.prototype,"answerFiles");let pt=yi;class Bu{constructor(e){l(this,"id");l(this,"fieldId");m.H.Classes.BuildClass(this,e)}static GetClassName(){return"fieldFilter"}}var Iu=Object.defineProperty,Ru=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&Iu(e,n,o),o};const Mo=class Ea{constructor(e){l(this,"id");l(this,"name","");l(this,"order",0);l(this,"fields",[]);l(this,"formId");m.H.Classes.BuildClass(this,e)}static GetClassName(){return"formSection"}getN(){return`${this.order+1}`}getFieldN(e){return`${this.getN()}.${e+1}`}getSubFieldN(e,n){return`${this.getFieldN(e)}.${n+1}`}static Create(e){const n=new Ea;return n.id=m.H.Classes.CreateUUID(),n.formId=e,n}addField(){const e=fn.Create(this.id);return this.fields.push(e),this.sortFields(),e}sortFields(){this.fields.forEach((e,n)=>e.order=n)}getAnswerVariants(){const e=[];return this.fields.forEach(n=>e.push(...n.answerVariants)),e}};Ru([m.H.Classes.GetClassConstructor(fn)],Mo.prototype,"fields");let mn=Mo;var $u=Object.defineProperty,Nu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&$u(e,n,o),o};const xo=class va{constructor(e){l(this,"id");l(this,"name","");l(this,"order",0);l(this,"isLaboratory",!1);l(this,"formSections",[]);l(this,"isEdit",!1);l(this,"withDates",!1);l(this,"withScores",!1);l(this,"selectedForExport",!1);l(this,"filterString","");l(this,"showOnlyNotFilled",!1);l(this,"showOnlyFilled",!1);m.H.Classes.BuildClass(this,e)}static GetClassName(){return"Form"}static Create(){const e=new va;return e.id=m.H.Classes.CreateUUID(),e}editRegisterGroup(e){this.isEdit=e??!this.isEdit}addFormSection(){const e=mn.Create(this.id);return this.formSections.push(e),m.H.Sorter.Sort(this.formSections),e}getFields(){const e=this.formSections.map(r=>r.fields).flat(),n=e.map(r=>r.children).flat();return e.concat(n).filter(r=>r.children.length===0)}};Nu([m.H.Classes.GetClassConstructor(mn)],xo.prototype,"formSections");let Bo=xo;var Au=Object.defineProperty,Pu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&Au(e,n,o),o};const Io=class Ma{constructor(e){l(this,"id");l(this,"date",new Date);l(this,"editMode",!1);l(this,"userFormId");l(this,"fillingPercentage",0);l(this,"fieldFills",[]);l(this,"num","");l(this,"formId");m.H.Classes.BuildClass(this,e)}static Create(e){const n=new Ma;return n.id=m.H.Classes.CreateUUID(),n.formId=e.id,n.fieldFills.push(...pt.CreateMany(e.getFields(),n.id)),n}addFieldFill(e){this.fieldFills.push(e)}getFieldFill(e){var n;return(n=this.fieldFills)==null?void 0:n.find(r=>r.fieldId===e)}pushRegisterProperty(e){const n=new pt;n.researchResultId=e,this.fieldFills.push(n)}getRegisterPropertyToPatient(e){return this.fieldFills.filter(n=>n.researchResultId===e)}getOrCreateFieldFill(e){let n=this.getFieldFill(e.id);return n||(n=pt.Create(e),this.addFieldFill(n)),n}getFileInfos(){const e=[];return this.fieldFills.forEach(n=>e.push(...n.getFileInfos())),e}calculateFilling(){const e=this.fieldFills.filter(r=>r.filled).length,n=this.fieldFills.length;this.fillingPercentage=Math.round(e/n*100)}getFieldFillByFieldId(e){return this.fieldFills.find(n=>n.fieldId===e)}getFieldVariantFieldFill(e){return this.fieldFills.find(n=>n.answerVariantId===e)}getFieldsFieldFillsMap(e){const n={};return e.forEach(r=>{var o;if(r.code){const s=(o=this.getFieldFillByFieldId(r.id))==null?void 0:o.valueNumber;n[r.code]=s}}),n}getIdWithoutDashes(){return this.id?this.id.replaceAll(/[^a-zA-Z]+/g,""):""}};Pu([m.H.Classes.GetClassConstructor(pt)],Io.prototype,"fieldFills");let Ro=Io;const Tu=Object.freeze(Object.defineProperty({__proto__:null,AnswerVariant:Qe,Field:fn,FieldExample:Eo,FieldFill:pt,FieldFillFile:gi,FieldFilter:Bu,FieldMeasure:pi,FieldVariant:mt,Form:Bo,FormFill:Ro,FormSection:mn,SelectedAnswerVariant:et},Symbol.toStringTag,{value:"Module"}));let zu=class extends K{constructor(){super(Qe,"answer-variants")}};const Vu=new zu;let Fu=class extends K{constructor(){super(pt,"field-fills")}};const Du=new Fu;let Lu=class extends K{constructor(){super(fn,"fields")}};const Hu=new Lu;let Ou=class extends K{constructor(){super(Ro,"form-fills")}};const _u=new Ou;let qu=class extends K{constructor(){super(mn,"form-sections")}};const Uu=new qu;let Wu=class extends K{constructor(){super(Bo,"forms")}};const Gu=new Wu;let ju=class extends K{constructor(){super(et,"selected-answer-variants")}};const Zu=new ju,Ju=Object.freeze(Object.defineProperty({__proto__:null,C:Tu,S:Object.freeze(Object.defineProperty({__proto__:null,AnswerVariants:Vu,FieldFills:Du,Fields:Hu,FormFills:_u,FormSections:Uu,Forms:Gu,SelectedAnswerVariants:Zu},Symbol.toStringTag,{value:"Module"}))},Symbol.toStringTag,{value:"Module"}));class pn{constructor(e){l(this,"id");l(this,"name","");l(this,"label","");m.H.Classes.BuildClass(this,e)}static Create(e,n){const r=new pn;return r.id=m.H.Classes.CreateUUID(),r.name=e,r.label=n,r}}const Xu=Object.freeze(Object.defineProperty({__proto__:null,ColorTheme:pn},Symbol.toStringTag,{value:"Module"}));let Yu=class extends K{constructor(){super(pn,"color-themes")}};const Qu=new Yu,Ku=Object.freeze(Object.defineProperty({__proto__:null,Forms:Ju,Settings:Object.freeze(Object.defineProperty({__proto__:null,C:Xu,S:Object.freeze(Object.defineProperty({__proto__:null,ColorThemes:Qu},Symbol.toStringTag,{value:"Module"}))},Symbol.toStringTag,{value:"Module"}))},Symbol.toStringTag,{value:"Module"})),eh={class:"item"},th={class:"move"},nh={class:"item-tools"},ih=["onClick"],rh={class:"item-description"},oh=["onUpdate:modelValue"],$o=M(i.defineComponent({__name:"AdminGallery",props:{fileList:{type:Array,reguired:!0,default:()=>[]},fileListForDelete:{type:Array,default:()=>[]},defaultRatio:{type:Number,required:!1,default:1},upload:{type:Boolean,required:!1,default:!0}},emits:["addImage","ratio","remove"],setup(t,{emit:e}){const n=t,r=e,o=async a=>{r("addImage",a)},s=async a=>{m.H.Classes.RemoveFromClassById(a.id,n.fileList,[]),r("remove",a)};return(a,d)=>{const c=i.resolveComponent("UploderImage"),u=i.resolveComponent("draggable"),h=i.resolveComponent("Move");return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createVNode(u,{class:"groups",list:t.fileList,"item-key":"id",handle:".move",onEnd:d[0]||(d[0]=f=>i.unref(_e).Sort(t.fileList))},{item:i.withCtx(({element:f,index:p})=>[i.createElementVNode("div",eh,[i.createElementVNode("div",th,[i.createElementVNode("div",nh,[d[1]||(d[1]=i.createElementVNode("svg",{class:"icon-move"},[i.createElementVNode("use",{"xlink:href":"#move"})],-1)),i.createElementVNode("button",{class:"admin-del2",onClick:i.withModifiers(y=>s(f),["prevent"])},"Удалить",8,ih)]),i.createVNode(c,{"file-info":f,height:150,"default-ratio":t.defaultRatio,onRemoveFile:y=>("PF"in a?a.PF:i.unref(m)).H.Classes.RemoveFromClassByIndex(p,t.fileList,t.fileListForDelete),onCrop:y=>o(f)},null,8,["file-info","default-ratio","onRemoveFile","onCrop"])]),i.createElementVNode("div",rh,[i.withDirectives(i.createElementVNode("input",{"onUpdate:modelValue":y=>f.description=y,class:"item-description-form",placeholder:"..."},null,8,oh),[[i.vModelText,f.description]])])])]),_:1},8,["list"]),i.createVNode(h)],64)}}}),[["__scopeId","data-v-7e3c8bac"]]),wi=M(i.defineComponent({__name:"IconCheckDefault",props:{size:{type:String,default:"22px"},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#check_on"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"check_on",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},[i.createElementVNode("path",{d:"M29.3678 7.25259C29.2732 7.3128 28.8775 7.6999 28.5076 8.13001C27.7076 9.02463 16.2409 22.0483 16.2065 22.0999C16.1549 22.1601 15.6732 21.73 13.9786 20.1042C8.31835 14.6934 8.5334 14.8827 8.03448 14.8827C7.69899 14.8827 7.59577 14.9257 7.3463 15.1752C7.09684 15.4246 7.05383 15.5279 7.05383 15.8547C7.05383 16.3365 6.98501 16.259 10.1506 19.2354C11.5011 20.4999 13.256 22.1601 14.056 22.9171C15.6302 24.4225 15.9485 24.6461 16.3872 24.5687C16.7399 24.4999 16.7743 24.4569 20.0947 20.6891C21.5485 19.0289 23.2689 17.0762 23.914 16.3451C29.4624 10.0655 30.6495 8.69775 30.77 8.48269C30.942 8.14721 30.8474 7.6999 30.5377 7.38162C30.3399 7.19237 30.2194 7.14076 29.9183 7.14076C29.7119 7.14936 29.471 7.19237 29.3678 7.25259Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-ef4acbe9"]]),sh=["value"],bi=M(i.defineComponent({__name:"PCheckBox",props:i.mergeModels({label:{type:String,default:""},fontSize:{type:String,default:"14px"},value:{type:[String,Boolean],default:void 0},size:{type:String,default:"22px"},borderRadius:{type:String,default:""},padding:{type:String,default:""},margin:{type:String,default:""},width:{type:String,default:""}},{modelValue:{type:Boolean},modelModifiers:{}}),emits:i.mergeModels(["change"],["update:modelValue"]),setup(t,{emit:e}){const n=i.useModel(t,"modelValue"),r=e,o=()=>{r("change",n.value)};return(s,a)=>{const d=wi;return i.openBlock(),i.createElementBlock("div",{id:"some",class:"check-line",style:i.normalizeStyle({padding:t.padding,margin:t.margin,maxWidth:t.width})},[i.createElementVNode("label",{class:"check-field__label",style:i.normalizeStyle({fontSize:t.fontSize})},[i.withDirectives(i.createElementVNode("input",{"onUpdate:modelValue":a[0]||(a[0]=c=>n.value=c),class:"check-field__input",type:"checkbox",value:t.value,onChange:o},null,40,sh),[[i.vModelCheckbox,n.value]]),i.createElementVNode("div",{id:"abc",class:"box",style:i.normalizeStyle({width:t.size,height:t.size,borderRadius:t.borderRadius})},[n.value?(i.openBlock(),i.createElementBlock("div",{key:0,class:"check-icon",style:i.normalizeStyle({width:t.size,height:t.size})},[i.createVNode(d,{margin:"auto",size:t.size},null,8,["size"])],4)):i.createCommentVNode("",!0)],4),i.createTextVNode(" "+i.toDisplayString(t.label),1)],4)],4)}}}),[["__scopeId","data-v-5d8bdbbf"]]),ah=["for"],lh={class:"field"},ch={class:"left-field"},dh=["id","value","name"],uh={class:"right-field"},No=M(i.defineComponent({__name:"PDatePicker",props:i.mergeModels({text:{type:String,default:"",required:!1},label:{type:String,default:"",required:!1},placeholder:{type:String,default:"",required:!1},margin:{type:String,required:!1,default:""},padding:{type:String,default:"",required:!1}},{modelValue:{required:!0},modelModifiers:{}}),emits:i.mergeModels(["blur","input"],["update:modelValue"]),setup(t,{emit:e}){const n=e,r=i.useModel(t,"modelValue"),o=a=>{const c=a.target.valueAsDate;c?(r.value=c,n("input",s(r.value))):(r.value=null,n("input",null))},s=a=>a?new Date(a.getTime()-a.getTimezoneOffset()*60*1e3).toISOString().split("T")[0]:"";return(a,d)=>(i.openBlock(),i.createElementBlock("div",{class:"text-field",style:i.normalizeStyle({margin:t.margin,padding:t.padding})},[t.label?(i.openBlock(),i.createElementBlock("label",{key:0,class:"text-field__label",for:t.label},i.toDisplayString(t.label),9,ah)):i.createCommentVNode("",!0),i.createElementVNode("div",lh,[i.createElementVNode("div",ch,[i.renderSlot(a.$slots,"default",{},void 0,!0)]),i.createElementVNode("input",{id:t.label,max:"2100",min:"1900",value:s(r.value),class:"text-field__input",type:"date",name:t.label,onInput:o},null,40,dh),i.createElementVNode("div",uh,[i.renderSlot(a.$slots,"right",{},void 0,!0)])])],4))}}),[["__scopeId","data-v-b77c7363"]]),Ci=M(i.defineComponent({inheritAttrs:!1,__name:"PFlex",props:{margin:{type:String,default:"",required:!1},padding:{type:String,default:"",required:!1},width:{type:String,default:"",required:!1},minWidth:{type:String,default:"",required:!1},maxWidth:{type:String,default:"",required:!1},height:{type:String,default:"",required:!1},justifyContent:{type:String,default:"",required:!1},background:{type:String,default:"",required:!1},alignItems:{type:String,default:"",required:!1}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:"flex-line",style:i.normalizeStyle({margin:t.margin,padding:t.padding,width:t.width,minWidth:t.minWidth,maxWidth:t.maxWidth,height:t.height,justifyContent:t.justifyContent,background:t.background,alignItems:t.alignItems})},[i.renderSlot(e.$slots,"default",{},void 0,!0)],4))}}),[["__scopeId","data-v-6c788e9a"]]),Si=i.defineComponent({__name:"PInputDate",props:i.mergeModels({placeholder:{type:String,default:"Укажите дату"},width:{type:String,required:!1,default:"auto"},margin:{type:String,required:!1,default:""},label:{type:String,default:"",required:!1}},{modelValue:{default:new Date},modelModifiers:{}}),emits:i.mergeModels(["update:modelValue","change","beforeChange"],["update:modelValue"]),setup(t,{emit:e}){const n=e,r=i.useModel(t,"modelValue"),o=ze.Format(r.value),s=i.ref(o),a=c=>{if(!d(c))return;const u=ze.FromRuStr(c);r.value=u,n("beforeChange",u),n("change",u)},d=c=>c.length!=10?(s.value=o,m.Notification.Error("Неверный формат даты"),!1):Number(s.value.slice(0,2))>31?(s.value=o,m.Notification.Error("Неверный день месяца"),!1):Number(s.value.slice(3,5))>12?(s.value=o,m.Notification.Error("Неверный месяц"),!1):Number(s.value.slice(6,10))>2100?(s.value=o,m.Notification.Error("Неверный год"),!1):!0;return(c,u)=>{const h=dt;return i.openBlock(),i.createElementBlock("div",{class:"style-container",style:i.normalizeStyle({width:t.width,position:"relative"})},[i.createVNode(h,{modelValue:i.unref(s),"onUpdate:modelValue":u[0]||(u[0]=f=>i.isRef(s)?s.value=f:null),mask:"##.##.####",placeholder:t.placeholder,margin:t.margin,label:t.label,onBlur:a,onKeydown:i.withKeys(i.withModifiers(f=>{},["prevent"]),["enter"])},null,8,["modelValue","placeholder","margin","label","onKeydown"])],4)}}}),hh={class:"number"},Ao=M(i.defineComponent({__name:"PInputNumber",props:{modelValue:{type:Number,required:!0,default:0}},emits:["update:modelValue","change"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.modelValue??0),s=()=>{o.value++,r("update:modelValue",o.value),r("change")},a=()=>{o.value--,r("update:modelValue",o.value),r("change")},d=()=>{r("update:modelValue",o.value),r("change")};return(c,u)=>(i.openBlock(),i.createElementBlock("div",hh,[i.createElementVNode("button",{class:"number-minus",type:"button",onClick:a},u[1]||(u[1]=[i.createElementVNode("svg",{class:"icon-minus"},[i.createElementVNode("use",{"xlink:href":"#minus"})],-1)])),i.withDirectives(i.createElementVNode("input",{"onUpdate:modelValue":u[0]||(u[0]=h=>i.isRef(o)?o.value=h:null),class:"input-field",type:"number",min:"0",step:"0.1",onInput:d},null,544),[[i.vModelText,i.unref(o)]]),i.createElementVNode("button",{class:"number-plus",type:"button",onClick:s},u[2]||(u[2]=[i.createElementVNode("svg",{class:"icon-plus"},[i.createElementVNode("use",{"xlink:href":"#plus"})],-1)]))]))}}),[["__scopeId","data-v-f53b6419"]]),fh=["innerHTML"],mh={key:1},he=M(i.defineComponent({__name:"PString",props:{string:{type:String,required:!1,default:""},color:{type:String,required:!1,default:"var(--font-color)"},fontSize:{type:String,required:!1,default:"var(--font-size-default)"},fontWeight:{type:String,required:!1,default:""},background:{type:String,required:!1,default:""},padding:{type:String,required:!1,default:""},width:{type:String,required:!1,default:""},minWidth:{type:String,required:!1,default:""},margin:{type:String,required:!1,default:""},customClass:{type:String,required:!1,default:""},justifyContent:{type:String,required:!1,default:"center"},isHtml:{type:Boolean,required:!1,default:!1}},emits:["click"],setup(t){const e=t,n={color:e.color,fontSize:e.fontSize,fontWeight:e.fontWeight,background:e.background,padding:e.padding,width:e.width,maxWidth:e.width,minWidth:e.minWidth,margin:e.margin,justifyContent:e.justifyContent};return(r,o)=>(i.openBlock(),i.createElementBlock("div",{class:i.normalizeClass(["string",t.customClass]),style:n,onClick:o[0]||(o[0]=s=>r.$emit("click"))},[t.isHtml?(i.openBlock(),i.createElementBlock("span",{key:0,innerHTML:t.string},null,8,fh)):(i.openBlock(),i.createElementBlock("span",mh,i.toDisplayString(t.string),1))],2))}}),[["__scopeId","data-v-bd8f6c8f"]]),Po=M(i.defineComponent({__name:"PLeftSlider",props:{open:{type:Boolean,default:!1},shadow:{type:Boolean,default:!0},border:{type:Boolean,default:!0},shift:{type:Boolean,default:!0},widthClosed:{type:String,required:!1,default:"30px"},widthOpened:{type:String,required:!1,default:"300px"},titleOpen:{type:String,required:!1,default:"Скрыть меню"},titleClose:{type:String,required:!1,default:"Показать меню"},background:{type:String,required:!1,default:"inherit"}},emits:["open"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.open);i.watch(()=>n.open,()=>{o.value=!o.value});const s=a=>{o.value=!o.value,r("open",a)};return(a,d)=>{const c=he;return i.openBlock(),i.createElementBlock(i.Fragment,null,[t.shift?i.createCommentVNode("",!0):(i.openBlock(),i.createElementBlock("div",{key:0,style:i.normalizeStyle({minWidth:t.widthClosed,maxWidth:t.widthClosed})},null,4)),i.createElementVNode("div",{class:"LS-body",style:i.normalizeStyle({marginLeft:i.unref(o)?"0":`calc(${t.widthClosed} - ${t.widthOpened})`,minWidth:t.widthOpened,maxWidth:t.widthOpened,boxShadow:t.shadow?"5px 0 5px -3px rgba(0,0,0,0.3)":"none",position:t.shift?"relative":"absolute",background:t.background})},[i.createElementVNode("div",{class:"LS-content",style:i.normalizeStyle({width:`calc(${t.widthOpened} - ${t.widthClosed})`})},[i.renderSlot(a.$slots,"default",{},void 0,!0)],4),i.createElementVNode("div",{class:"click-line",style:i.normalizeStyle({width:t.widthClosed}),onClick:d[0]||(d[0]=u=>s(!i.unref(o)))},[i.unref(o)?(i.openBlock(),i.createBlock(c,{key:0,string:t.titleOpen,"font-size":"16px",padding:"0",color:"inherit"},null,8,["string"])):i.createCommentVNode("",!0),i.unref(o)?i.createCommentVNode("",!0):(i.openBlock(),i.createBlock(c,{key:1,string:t.titleClose,"font-size":"16px",padding:"0",color:"inherit"},null,8,["string"]))],4)],4)],64)}}}),[["__scopeId","data-v-3ea7497e"]]),To=M(i.defineComponent({__name:"PList",props:{margin:{type:String,required:!1,default:""},padding:{type:String,required:!1,default:""},width:{type:String,required:!1,default:"300px"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("ul",{style:i.normalizeStyle({margin:t.margin,padding:t.padding,width:t.width})},[i.renderSlot(e.$slots,"default",{},void 0,!0)],4))}}),[["__scopeId","data-v-84953e34"]]),zo=M(i.defineComponent({__name:"PListItem",props:{margin:{type:String,required:!1,default:""},padding:{type:String,required:!1,default:""},showDivider:{type:Boolean,required:!1,default:!1}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("li",{style:i.normalizeStyle({margin:t.margin,padding:t.padding,borderBottom:t.showDivider?"1px solid":"none"})},[i.renderSlot(e.$slots,"default",{},void 0,!0)],4))}}),[["__scopeId","data-v-4cb3c766"]]),ph=["for"],gh=["id","name","checked","value"],Vo=M(i.defineComponent({__name:"PRadio",props:i.mergeModels({label:{type:String,default:""},name:{type:String,default:"group"},fontSize:{type:String,default:"14px"},size:{type:String,default:"20px"},borderRadius:{type:String,default:""},padding:{type:String,default:""},margin:{type:String,default:""},width:{type:String,default:"auto"},value:{type:[String,Boolean],default:void 0}},{modelValue:{},modelModifiers:{}}),emits:i.mergeModels(["change"],["update:modelValue"]),setup(t,{emit:e}){const n=i.useModel(t,"modelValue"),r=e,o=t,s=m.H.Strings.CreateGuid(),a=i.computed(()=>n.value===o.value),d=()=>{r("change",o.value)};return(c,u)=>(i.openBlock(),i.createElementBlock("div",{class:"radio-line",style:i.normalizeStyle({padding:t.padding,margin:t.margin,maxWidth:t.width})},[i.createElementVNode("label",{class:"radio-field__label",for:i.unref(s),style:i.normalizeStyle({fontSize:t.fontSize})},[i.withDirectives(i.createElementVNode("input",{id:i.unref(s),"onUpdate:modelValue":u[0]||(u[0]=h=>n.value=h),name:t.name,checked:i.unref(a),class:"radio-field__input",type:"radio",value:t.value},null,8,gh),[[i.vModelRadio,n.value]]),i.createElementVNode("div",{class:"box",style:i.normalizeStyle({width:t.size,height:t.size,borderRadius:t.borderRadius}),onClick:d},[n.value===t.value?(i.openBlock(),i.createElementBlock("div",{key:0,class:"radio-dot",style:i.normalizeStyle({width:`calc(${t.size} - 50%)`,height:`calc(${t.size} - 50%)`})},null,4)):i.createCommentVNode("",!0)],4),i.createElementVNode("span",{onClick:d},i.toDisplayString(t.label),1)],12,ph)],4))}}),[["__scopeId","data-v-3cc907bd"]]),yh={class:"wrapper"},wh={class:"content"},Fo=M(i.defineComponent({__name:"PRightSlider",props:{open:{type:Boolean,default:!1},shadow:{type:Boolean,default:!0},border:{type:Boolean,default:!0},shift:{type:Boolean,default:!0},widthClosed:{type:String,required:!1,default:"30px"},widthOpened:{type:String,required:!1,default:"300px"},titleOpen:{type:String,required:!1,default:"Скрыть"},titleClose:{type:String,required:!1,default:"Показать"},background:{type:String,required:!1,default:"inherit"}},emits:["open"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.open);i.watch(()=>n.open,()=>{o.value=!o.value});const s=a=>{o.value=!o.value,r("open",a)};return(a,d)=>{const c=he;return i.openBlock(),i.createElementBlock("div",yh,[i.createElementVNode("div",wh,[i.renderSlot(a.$slots,"content",{},void 0,!0)]),i.createElementVNode("div",{class:"RS-body",style:i.normalizeStyle({marginRight:i.unref(o)?"0":`calc(${t.widthClosed} - ${t.widthOpened})`,minWidth:t.widthOpened,maxWidth:t.widthOpened,boxShadow:t.shadow?"-5px 0 5px -3px rgba(0,0,0,0.3)":"none",position:t.shift?"relative":"absolute"})},[i.createElementVNode("div",{class:"click-line",style:i.normalizeStyle({width:t.widthClosed}),onClick:d[0]||(d[0]=u=>s(!i.unref(o)))},[i.unref(o)?(i.openBlock(),i.createBlock(c,{key:0,string:t.titleOpen,"font-size":"16px",padding:"0",color:"inherit"},null,8,["string"])):i.createCommentVNode("",!0),i.unref(o)?i.createCommentVNode("",!0):(i.openBlock(),i.createBlock(c,{key:1,string:t.titleClose,"font-size":"16px",padding:"0",color:"inherit"},null,8,["string"]))],4),i.createElementVNode("div",{class:"RS-content",style:i.normalizeStyle({width:`calc(${t.widthOpened} - ${t.widthClosed} - 2px)`,background:t.background})},[i.renderSlot(a.$slots,"default",{},void 0,!0)],4)],4)])}}}),[["__scopeId","data-v-6f8cc35c"]]),ki=M(i.defineComponent({__name:"IconSelectArrow",props:{size:{type:String,default:"20px"},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#arrow-down"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"arrow-down",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 20"},[i.createElementVNode("path",{d:"M3.08417 4.43062C2.86268 4.4769 2.70731 4.56285 2.52549 4.74467C2.29408 4.97607 2.20152 5.2174 2.22136 5.55459C2.25111 6.0207 1.96681 5.70996 6.78995 10.5397C9.18995 12.9463 11.2263 14.9662 11.309 15.029C11.5238 15.1843 11.7123 15.2471 11.99 15.2505C12.4693 15.2538 12.109 15.581 17.1106 10.5728C22.0891 5.58764 21.7288 5.98103 21.7255 5.505C21.7255 5.37607 21.7023 5.21078 21.6726 5.13145C21.5106 4.68186 21.0511 4.38434 20.5817 4.4174C20.1519 4.44715 20.4263 4.19591 16.0164 8.60252L11.9833 12.629L8.06598 8.71161C5.91061 6.55624 4.0726 4.73475 3.98003 4.66202C3.71227 4.45376 3.38499 4.36781 3.08417 4.43062Z",fill:"currentColor"}),i.createElementVNode("path",{d:"M9.69602 16.8994C9.70593 16.9292 9.72577 17.0184 9.73569 17.1044C9.76213 17.2664 9.7985 17.2994 9.83486 17.1903C9.84478 17.154 9.89106 17.1143 9.93734 17.1044C10.0464 17.078 10.0365 17.0548 9.87453 16.9589C9.6861 16.8465 9.67288 16.8432 9.69602 16.8994Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-db435ef1"]]),zt=M(i.defineComponent({__name:"IconClose",props:{size:{type:String,default:"24px"},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#close"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"close",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 28 28"},[i.createElementVNode("path",{d:"M7.53508 7.18138C7.03684 7.5158 6.86132 8.14496 7.1161 8.66643C7.18971 8.8138 8.02201 9.69236 9.44881 11.1207C10.6718 12.345 11.8211 13.49 12.0023 13.6714L12.3251 14.0058L9.80551 16.5224C7.92576 18.4043 7.25199 19.1184 7.14441 19.3225C6.83867 19.9346 7.0425 20.5865 7.637 20.8926C7.89745 21.0286 8.41268 21.0343 8.6618 20.9096C8.76372 20.8585 10.0037 19.6626 11.4191 18.2455L14.001 15.6666L16.5432 18.2229C18.1964 19.8723 19.1703 20.8132 19.3232 20.8869C19.5779 21.0116 20.0309 21.0399 20.2913 20.9379C20.5178 20.8529 20.8632 20.5015 20.9368 20.2747C21.0274 19.9913 21.0161 19.5719 20.9028 19.3508C20.8519 19.2431 19.6516 17.9961 18.2361 16.5791L15.6656 14.0001L18.2191 11.4495C19.7138 9.95309 20.8179 8.80813 20.8858 8.6721C21.0104 8.42837 21.0387 7.98058 20.9425 7.73119C20.8519 7.50446 20.5971 7.23239 20.3593 7.11336C20.0988 6.97733 19.6516 6.96599 19.3628 7.08502C19.2212 7.14737 18.3097 8.01459 16.5771 9.74904L14.001 12.328L11.4191 9.75471C9.6583 7.99192 8.77504 7.14737 8.63349 7.08502C8.51459 7.03968 8.28246 7 8.1126 7C7.86347 7 7.76156 7.03401 7.53508 7.18138Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-8d8cfcf1"]]),bh=["for"],Ch={class:"field"},Sh={class:"left-field"},kh={class:"arrow"},Eh={selected:"",hidden:""},vh={class:"right-field"},tt=M(i.defineComponent({inheritAttrs:!1,__name:"PSelect",props:i.mergeModels({label:{type:String,default:"",required:!1},placeholder:{type:String,default:"",required:!1},value:{type:String,default:"",required:!1},readonly:{type:Boolean,default:!1,required:!1},disabled:{type:Boolean,default:!1,required:!1},margin:{type:String,required:!1,default:""},padding:{type:String,required:!1,default:""},clearable:{type:Boolean,required:!1,default:!0},width:{type:String,required:!1,default:""},borderColor:{type:String,required:!1,default:""},color:{type:String,required:!1,default:""}},{modelValue:{},modelModifiers:{}}),emits:i.mergeModels(["change","clear"],["update:modelValue"]),setup(t,{emit:e}){const n=i.useModel(t,"modelValue"),r=i.ref(!0),o=e,s=i.ref(!1),a=()=>{r.value=!1,o("change",n.value)},d=()=>{o("clear",void 0),o("change",void 0),r.value=!0};return(c,u)=>{const h=ki;return i.openBlock(),i.createElementBlock("div",{class:"text-field",style:i.normalizeStyle({margin:t.margin,padding:t.padding,width:t.width})},[t.label?(i.openBlock(),i.createElementBlock("label",{key:0,class:"text-field__label",for:t.label},i.toDisplayString(t.label),9,bh)):i.createCommentVNode("",!0),i.createElementVNode("div",Ch,[i.createElementVNode("div",Sh,[i.renderSlot(c.$slots,"left",{},void 0,!0)]),i.createElementVNode("div",{class:"sl",onMouseover:u[1]||(u[1]=f=>s.value=!0),onMouseleave:u[2]||(u[2]=f=>s.value=!1)},[t.clearable?i.withDirectives((i.openBlock(),i.createElementBlock("div",{key:0,class:"clear",onClick:d},[i.createVNode(zt,{margin:"0"})],512)),[[i.vShow,i.unref(s)]]):i.createCommentVNode("",!0),i.createElementVNode("div",kh,[i.createVNode(h,{margin:"2px 2px 0 0"})]),i.withDirectives(i.createElementVNode("select",i.mergeProps(c.$attrs,{"onUpdate:modelValue":u[0]||(u[0]=f=>n.value=f),class:"text-field__input",onChange:a}),[i.createElementVNode("option",Eh,i.toDisplayString(t.placeholder),1),i.renderSlot(c.$slots,"default",{},void 0,!0)],16),[[i.vModelSelect,n.value]])],32),i.createElementVNode("div",vh,[i.renderSlot(c.$slots,"right",{},void 0,!0)])])],4)}}}),[["__scopeId","data-v-60aea6d2"]]),gn=M(i.defineComponent({__name:"PSticky",props:{shadow:{type:Boolean,default:!1},zIndex:{type:Number,default:0},background:{type:String,default:"inherit"},padding:{type:String,default:"0"},top:{type:String,default:"0"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:"sticky-block",style:i.normalizeStyle({zIndex:1+t.zIndex,top:t.top,background:t.background,padding:t.padding,boxShadow:t.shadow?"0 0 5px 2px rgba(0,0,0,0.3)":"none"})},[i.renderSlot(e.$slots,"default",{},void 0,!0)],4))}}),[["__scopeId","data-v-db44b76d"]]),Mh=["for"],xh={class:"left-field"},Bh={class:"right-field"},Do=M(i.defineComponent({__name:"PTextarea",props:i.mergeModels({label:{type:String,default:"",required:!1},margin:{type:String,required:!1,default:"0"},padding:{type:String,default:"0",required:!1},mask:{type:String,required:!1,default:void 0},borderColor:{type:String,default:"var(--input-border-color)",required:!1},color:{type:String,default:"var(--input-font-color)",required:!1}},{modelValue:{},modelModifiers:{}}),emits:i.mergeModels(["blur","input"],["update:modelValue"]),setup(t){const e=i.useModel(t,"modelValue");return(n,r)=>(i.openBlock(),i.createElementBlock("div",{class:"text-field",style:i.normalizeStyle({margin:t.margin,padding:t.padding})},[t.label?(i.openBlock(),i.createElementBlock("label",{key:0,class:"text-field__label",for:t.label},i.toDisplayString(t.label),9,Mh)):i.createCommentVNode("",!0),i.createElementVNode("div",{class:"field",style:i.normalizeStyle({borderColor:t.borderColor})},[i.createElementVNode("div",xh,[i.renderSlot(n.$slots,"default",{},void 0,!0)]),i.withDirectives(i.createElementVNode("textarea",i.mergeProps(n.$attrs,{"onUpdate:modelValue":r[0]||(r[0]=o=>e.value=o),class:"text-field__input",style:{color:t.color},onBlur:r[1]||(r[1]=o=>n.$emit("blur",e.value)),onInput:r[2]||(r[2]=o=>n.$emit("input",e.value))}),null,16),[[i.vModelText,e.value],[i.unref(ho),t.mask]]),i.createElementVNode("div",Bh,[i.renderSlot(n.$slots,"right",{},void 0,!0)])],4)],4))}}),[["__scopeId","data-v-172b61e5"]]),Ih={class:"top-slider-content"},Rh={class:"center"},Lo=M(i.defineComponent({__name:"PTopSlider",props:{sliderOffHeight:{type:String,required:!1,default:"53px"},sliderOnHeight:{type:String,required:!1,default:"220px"},background:{type:String,required:!1,default:"inherit"},open:{type:Boolean,default:!1}},emits:["open"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.open);i.watch(()=>n.open,()=>{o.value=!o.value});const s=a=>{o.value=!o.value,r("open",a)};return(a,d)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[i.unref(o)?i.createCommentVNode("",!0):(i.openBlock(),i.createElementBlock("div",{key:0,class:"blur",onClick:[d[0]||(d[0]=i.withModifiers(c=>o.value=!0,["prevent"])),d[1]||(d[1]=i.withModifiers(()=>{},["stop"]))]})),i.createElementVNode("div",{class:"top-slider",style:i.normalizeStyle({marginTop:i.unref(o)?"0":`calc(${t.sliderOffHeight} - ${t.sliderOnHeight})`,height:t.sliderOnHeight}),onClick:d[3]||(d[3]=i.withModifiers(()=>{},["stop"]))},[i.createElementVNode("div",Ih,[i.createElementVNode("div",Rh,[i.renderSlot(a.$slots,"default",{},void 0,!0)])]),i.createElementVNode("div",{class:"click-line",style:i.normalizeStyle({height:t.sliderOffHeight}),onClick:d[2]||(d[2]=c=>s(!i.unref(o)))},[i.renderSlot(a.$slots,"title",{},void 0,!0)],4)],4)],64))}}),[["__scopeId","data-v-12ffd2e2"]]),Vt=M(i.defineComponent({__name:"PModal",props:{showCloseDialog:{type:Boolean,required:!1,default:!1},closable:{type:Boolean,required:!1,default:!1},show:{type:Boolean,default:!1},title:{type:String,default:""},width:{type:String,default:"760px"},margin:{type:String,default:"auto"},top:{type:String,default:"20vh"},padding:{type:String,default:"var(--modal-window-padding)"},showClose:{type:Boolean,default:!1}},emits:["save","close"],setup(t,{emit:e}){const n=t,r=e,o=a=>{a.key==="Escape"&&s()};i.onMounted(()=>{document.body.addEventListener("keydown",o)}),i.onBeforeUnmount(()=>{document.body.removeEventListener("keydown",o)});const s=()=>{n.closable&&r("close")};return(a,d)=>{const c=zt;return i.openBlock(),i.createElementBlock(i.Fragment,null,[t.show?(i.openBlock(),i.createElementBlock("div",{key:0,class:"blur",onClick:s})):i.createCommentVNode("",!0),t.show?(i.openBlock(),i.createElementBlock("div",{key:1,class:"modal-w",style:i.normalizeStyle({maxWidth:t.width,width:t.width,margin:t.margin,padding:t.padding,top:t.top})},[t.closable?(i.openBlock(),i.createElementBlock("div",{key:0,class:"icon-box",onClick:s},[i.createVNode(c,{size:"20px"})])):i.createCommentVNode("",!0),i.renderSlot(a.$slots,"default",{},void 0,!0)],4)):i.createCommentVNode("",!0)],64)}}}),[["__scopeId","data-v-41f0eae5"]]),Ho=i.defineComponent({__name:"AuthModal",emits:["submit"],setup(t){const e=()=>{m.Auth.Form.Reset(),m.Auth.Modal.Close()};return(n,r)=>{const o=cn,s=Vt;return i.openBlock(),i.createBlock(s,{show:("PF"in n?n.PF:i.unref(m)).Auth.Modal.IsVisible(),closable:("PF"in n?n.PF:i.unref(m)).Auth.Modal.IsClosable(),onClose:e},{default:i.withCtx(()=>[i.createVNode(o,{width:"760px",onAction:r[0]||(r[0]=a=>n.$emit("submit"))})]),_:1},8,["show","closable"])}}}),Ft=M(i.defineComponent({__name:"GridContainer",props:{maxWidth:{type:String,required:!1,default:""},width:{type:String,required:!1,default:"100%"},background:{type:String,required:!1,default:"inherit"},gridGap:{type:String,required:!1,default:"10px"},gridTemplateColumns:{type:String,required:!1,default:"repeat(auto-fit, minmax(250px, 1fr))"},gridTemplateRows:{type:String,required:!1,default:"repeat(0 0px)"},margin:{type:String,required:!1,default:"10px 0 0 0"},customClass:{type:String,required:!1,default:""}},setup(t){return i.useCssVars(e=>({59355408:t.maxWidth,"24aaa640":t.width,"0833ce18":t.background,"65d0bfaa":t.gridGap,"2373d8d7":t.gridTemplateColumns,ea2919c2:t.gridTemplateRows,"5f2f1c74":t.margin})),(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:i.normalizeClass(["grid-block",t.customClass])},[i.renderSlot(e.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-352a1099"]]);var Ve=(t=>(t.None="None",t.Next="Next",t.Prev="Prev",t))(Ve||{});const $h={class:"container"},Nh={class:"slide-box"},Ah={class:"link-number"},Ph=["id","onClick"],Oo=M(i.defineComponent({__name:"CarouselImages",props:{events:{type:Array,required:!0},quantity:{type:Number,default:1,required:!1},animationTime:{type:Number,default:500},height:{type:String,default:"360px"},maxHeight:{type:String,default:"360px"},startActiveGroupIndex:{type:Number,default:0}},emits:["openModalWindow"],setup(t){i.useCssVars(y=>({"17adb052":n}));const e=t,n=`${e.animationTime}ms`,r=i.ref(e.startActiveGroupIndex),o=i.ref(Ve.None),s=i.ref(so(e.events,e.quantity)),a=i.computed(()=>s.value[r.value]);i.onMounted(()=>{});const d=()=>r.value=r.value+1<s.value.length?r.value+1:0,c=()=>r.value=r.value-1<0?s.value.length-1:r.value-1,u=y=>{o.value=y,setTimeout(()=>o.value=Ve.None,e.animationTime)},h=y=>{y!=r.value&&(u(y<r.value?Ve.Prev:Ve.Next),setTimeout(()=>r.value=y,e.animationTime/2))},f=()=>{u(Ve.Next),setTimeout(d,e.animationTime/2)},p=()=>{u(Ve.Prev),setTimeout(c,e.animationTime/2)};return(y,g)=>(i.openBlock(),i.createElementBlock("div",{class:"field",style:i.normalizeStyle({height:t.height,maxHeight:t.maxHeight})},[i.createElementVNode("div",$h,[(i.openBlock(),i.createElementBlock("svg",{class:"icon-arrow",onClick:g[0]||(g[0]=i.withModifiers(k=>p(),["stop"]))},g[2]||(g[2]=[i.createElementVNode("use",{"xlink:href":"#arrow-prev"},null,-1)]))),i.createElementVNode("div",Nh,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(a),(k,b)=>(i.openBlock(),i.createElementBlock("div",{key:b,class:i.normalizeClass({animationnext:i.unref(o)===i.unref(Ve).Next,animationprev:i.unref(o)===i.unref(Ve).Prev})},g[3]||(g[3]=[i.createElementVNode("div",{class:"image"},[i.createElementVNode("div",{class:"image-box"})],-1)]),2))),128))]),(i.openBlock(),i.createElementBlock("svg",{class:"icon-arrow",onClick:g[1]||(g[1]=i.withModifiers(k=>f(),["stop"]))},g[4]||(g[4]=[i.createElementVNode("use",{"xlink:href":"#arrow-next"},null,-1)])))]),i.createElementVNode("div",Ah,[i.createVNode(Ft,{"grid-template-columns":"repeat(auto-fit, minmax(26px, 1fr))","grid-gap":"5px",margin:"0"},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(s),(k,b)=>(i.openBlock(),i.createElementBlock("div",{id:b.toString(),key:b,class:"number",style:i.normalizeStyle({background:b.toString()===i.unref(r).toString()?"#9D9D9D":""}),onClick:i.withModifiers(B=>h(b),["stop"])},i.toDisplayString(b+1),13,Ph))),128))]),_:1})])],4))}}),[["__scopeId","data-v-3493284a"]]),_o=i.defineComponent({__name:"ContextWindow",props:{x:{type:Number,default:-1},y:{type:Number,default:-1}},emits:["close"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.x),s=i.ref(n.y),a=i.computed(()=>o.value+"px"),d=i.computed(()=>s.value+"px"),c=()=>{r("close")};return(u,h)=>{const f=i.resolveDirective("click-outside");return i.withDirectives((i.openBlock(),i.createElementBlock("div",{class:"context-window",style:i.normalizeStyle({left:i.unref(a),top:i.unref(d)})},[i.renderSlot(u.$slots,"default")],4)),[[f,c]])}}}),Th={class:"date-range"},qo=M(i.defineComponent({__name:"DateInputRange",props:{start:{type:Date,default:void 0},end:{type:Date,default:void 0}},emits:["update:start","update:end","setStart","setEnd"],setup(t,{emit:e}){const n=t,r=e;i.watch(()=>[n.start,n.end],()=>{n.start||(o.value=void 0),n.end||(s.value=void 0)});const o=i.ref(n.start),s=i.ref(n.end),a=c=>{if(o.value=c,!n.end||c>n.end){m.Notification.Warning("Дата начала больше даты окончания");return}r("update:start",c),r("setStart",c)},d=c=>{if(s.value=c,!n.start||c<n.start){m.Notification.Warning("Дата начала больше даты окончания");return}r("update:end",c),r("setEnd",c)};return(c,u)=>{const h=Si;return i.openBlock(),i.createElementBlock("div",Th,[i.createVNode(h,{"model-value":i.unref(o),"onUpdate:modelValue":u[0]||(u[0]=f=>i.isRef(o)?o.value=f:null),onChange:a},null,8,["model-value"]),u[2]||(u[2]=i.createTextVNode(" - ")),i.createVNode(h,{"model-value":i.unref(s),"onUpdate:modelValue":u[1]||(u[1]=f=>i.isRef(s)?s.value=f:null),onChange:d},null,8,["model-value"])])}}}),[["__scopeId","data-v-69b3ebc4"]]),zh=i.defineComponent({name:"DateInputRangeV2"}),Vh={class:"date-range"};function Fh(t,e,n,r,o,s){return i.openBlock(),i.createElementBlock("div",Vh,[i.renderSlot(t.$slots,"default",{},void 0,!0)])}const Uo=M(zh,[["render",Fh],["__scopeId","data-v-80580591"]]),Dh={class:"drop-item"},Lh={key:0,class:"drop-item-list"},Wo=M(i.defineComponent({__name:"DropList",props:{name:{type:String,default:"Name"},rolledUp:{type:Boolean,default:!0}},setup(t){const e=t,n=i.ref(e.rolledUp),r=async()=>{n.value=!n.value};return(o,s)=>{const a=he,d=i.resolveComponent("IconArrowDrop");return i.openBlock(),i.createElementBlock("div",Dh,[i.createElementVNode("div",{class:"drop-item-name",onClick:s[0]||(s[0]=c=>r())},[i.createVNode(a,{"font-size":"13px","font-weight":"600",string:t.name,"justify-content":"left",width:"auto",margin:"0 5px 0 0",padding:"6px 0",color:"inherit"},null,8,["string"]),i.createElementVNode("div",{style:i.normalizeStyle({transform:i.unref(n)?"":"rotate(-90deg)",display:"flex",alignItems:"center",margin:"0 0 2px 0"})},[i.createVNode(d,{size:"10px",margin:"0"})],4)]),i.unref(n)?(i.openBlock(),i.createElementBlock("div",Lh,[i.renderSlot(o.$slots,"default",{},void 0,!0)])):i.createCommentVNode("",!0)])}}}),[["__scopeId","data-v-75ec18f4"]]),Go=M(i.defineComponent({__name:"FilterCheckbox",props:{model:{type:Object,default:()=>new Fn,required:!0}},emits:["load"],setup(t,{emit:e}){const n=t,r=i.ref(!1),o=e,s=()=>{n.model.setBoolean(r.value),r.value?m.H.FTSP.Get().setF(n.model):m.H.FTSP.Get().removeF(n.model),o("load")};return(a,d)=>{const c=bi;return i.openBlock(),i.createBlock(c,{modelValue:i.unref(r),"onUpdate:modelValue":d[0]||(d[0]=u=>i.isRef(r)?r.value=u:null),label:t.model.label,size:"mini",onChange:s},null,8,["modelValue","label"])}}}),[["__scopeId","data-v-c8f7d6ec"]]),Hh={key:0,class:"blur"},Oh={style:{display:"flex","justify-content":"center"}},nt=M(i.defineComponent({__name:"InfoItem",props:{background:{type:String,required:!1,default:""},padding:{type:String,required:!1,default:""},width:{type:String,required:!1,default:""},openWidth:{type:String,required:!1,default:"auto"},openHeight:{type:String,required:!1,default:"auto"},maxWidth:{type:String,required:!1,default:""},minWidth:{type:String,required:!1,default:""},margin:{type:String,required:!1,default:""},height:{type:String,required:!1,default:""},withOpenWindow:{type:Boolean,required:!1,default:!0},colorSelected:{type:String,required:!1,default:"#1979CF"},borderColor:{type:String,required:!1,default:"#E3E3E3"},withHover:{type:Boolean,required:!1,default:!0},title:{type:String,required:!1,default:""},customClass:{type:String,required:!1,default:""},close:{type:Boolean,required:!1,default:!0},baseBoxMargin:{type:String,required:!1,default:""},closeWindowOverflow:{type:String,required:!1,default:""},showSaveDialog:{type:Boolean,required:!1,default:!1}},emits:["click","keyup-enter","after-close"],setup(t,{emit:e}){const n=t,r=e,o=n.customClass!==""?n.customClass:"inside-class",s=i.ref(!1),a=i.ref(!1),d=i.ref(!1),c=i.ref(n.close);i.watch(()=>n.close,()=>{a.value=!1});const u=V=>{V.stopPropagation(),V.key==="Escape"&&(n.showSaveDialog?d.value=!0:a.value=!1)};i.watch(a,async()=>{var V,T;await i.nextTick(),a.value?((T=(V=document.getElementById("info-item-opened-content"))==null?void 0:V.querySelector("input"))==null||T.focus(),document.body.addEventListener("keydown",u)):document.body.removeEventListener("keydown",u,!1),a.value===!1&&r("after-close")});const h=()=>{r("click"),a.value=!!n.withOpenWindow,c.value!==n.close&&(a.value=!1,c.value=!c.value)},f=i.computed(()=>n.customClass===""?{width:n.width,minHeight:"40px",height:"auto",maxWidth:n.maxWidth,minWidth:n.minWidth,margin:n.baseBoxMargin}:void 0),p=i.computed(()=>a.value&&n.withOpenWindow),y=i.computed(()=>({background:n.background?n.background:void 0,zIndex:p.value?"2":"0",padding:p.value?"0":n.padding,margin:n.margin,width:p.value?n.openWidth:n.width,height:p.value?n.openHeight:n.height,minHeight:"40px",maxWidth:n.maxWidth,minWidth:n.minWidth,borderColor:s.value||a.value?n.colorSelected:n.borderColor,color:s.value?n.colorSelected:"#343E5C",boxShadow:s.value||a.value?`0px 0px 1px 1px ${n.colorSelected}`:"none",alignItems:p.value?"end":"center",cursor:(n.withHover,"pointer")})),g=i.computed(()=>({height:p.value?"0":"",overflow:n.closeWindowOverflow,width:n.width})),k=i.computed(()=>({height:p.value?"auto":"0"})),b=i.computed(()=>({color:s.value?n.colorSelected:"#343E5C",fill:s.value?n.colorSelected:"#343E5C",background:n.background})),B=()=>{n.showSaveDialog?d.value=!0:a.value=!1},D=async()=>{await r("keyup-enter"),n.close&&(a.value=!1),d.value=!1},L=()=>{a.value=!1,d.value=!1};return(V,T)=>{const ye=he,ke=be,Ge=Vt,Ct=i.resolveDirective("click-outside");return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.unref(a)?(i.openBlock(),i.createElementBlock("div",Hh)):i.createCommentVNode("",!0),i.createElementVNode("div",{class:"base-box",style:i.normalizeStyle(i.unref(f)),onClick:T[2]||(T[2]=i.withModifiers($n=>h(),["prevent","stop"]))},[i.createElementVNode("div",{class:i.normalizeClass(["body",i.unref(o)]),style:i.normalizeStyle(i.unref(y)),onMouseenter:T[0]||(T[0]=$n=>t.withHover?s.value=!0:s.value=!1),onMouseleave:T[1]||(T[1]=$n=>s.value=!1)},[i.unref(a)?i.createCommentVNode("",!0):(i.openBlock(),i.createElementBlock("div",{key:0,class:i.normalizeClass(["close-window",t.customClass]),style:i.normalizeStyle(i.unref(g))},[i.renderSlot(V.$slots,"default",{},void 0,!0)],6)),i.unref(a)?i.withDirectives((i.openBlock(),i.createElementBlock("div",{key:1,id:"info-item-opened-content",class:"open-window",style:i.normalizeStyle(i.unref(k))},[i.renderSlot(V.$slots,"open-inside-content",{},void 0,!0)],4)),[[Ct,B,void 0,{prevent:!0}]]):i.createCommentVNode("",!0),i.createElementVNode("div",{class:"top-title",style:i.normalizeStyle(i.unref(b))},[i.renderSlot(V.$slots,"title",{},()=>[i.createVNode(ye,{string:t.title,"font-size":"10px",padding:"0 0 0 3px",style:i.normalizeStyle({color:i.unref(s)?"#006BB4":"#c4c4c4",transition:"0.2s"})},null,8,["string","style"])],!0)],4)],38)],4),i.createVNode(Ge,{show:i.unref(d),title:"У вас остались несохраненные изменения, вы уверены что хотите закрыть окно?"},{default:i.withCtx(()=>[i.createElementVNode("div",Oh,[i.createVNode(ke,{text:"Не сохранять",onClick:L}),i.createVNode(ke,{text:"Сохранять",onClick:D})])]),_:1},8,["show"])],64)}}}),[["__scopeId","data-v-4788a262"]]),jo=M(i.defineComponent({__name:"FiltersButtonsSelect",props:{models:{type:Array,default:()=>[]},defaultLabel:{type:String,default:"Все"},inverse:{type:Boolean,required:!1,default:!1}},emits:["load"],setup(t,{emit:e}){const n=e,r=i.ref(void 0),o=async a=>{m.H.FTSP.Get().replaceF(a,r.value),r.value=a,m.H.FTSP.Get().p.drop()},s=async a=>{await o(a),n("load")};return(a,d)=>{const c=he,u=be,h=Ft,f=nt;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createVNode(c,{string:t.defaultLabel,"font-size":"14px",padding:"0",margin:"20px 0 0 10px"},null,8,["string"]),i.createVNode(f,{margin:"5px 0 0 0px","with-open-window":!1,height:"auto",background:"#F5F5F5","border-color":"#C4C4C4",padding:"7px","with-hover":!1},{title:i.withCtx(()=>d[0]||(d[0]=[])),default:i.withCtx(()=>[i.createVNode(h,{"max-width":"100%","grid-gap":"7px","grid-template-columns":"repeat(auto-fit, minmax(100%, 1fr))",margin:"0px"},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(t.models,(p,y)=>(i.openBlock(),i.createBlock(u,{key:y,color:"blue",height:"auto",text:p.label,"is-toggle":p.valueEq(i.unref(r)),"toggle-mode":!0,inverse:t.inverse,onClick:g=>s(p.valueEq(i.unref(r))?void 0:p)},null,8,["text","is-toggle","inverse","onClick"]))),128))]),_:1})]),_:1})],64)}}}),[["__scopeId","data-v-3725dd8f"]]),_h=["value","label"],Zo=M(i.defineComponent({__name:"FilterSelect",props:{models:{type:Array,default:()=>[]},defaultLabel:{type:String,default:"Все"},inverse:{type:Boolean,required:!1,default:!1}},emits:["load"],setup(t,{emit:e}){const n=e,r=m.H.FTSP.Get(),o=i.ref(void 0),s=async d=>{r.replaceF(d,o.value),o.value=d},a=async d=>{d?await s(o.value):await s(void 0),n("load")};return(d,c)=>{const u=tt;return i.openBlock(),i.createBlock(u,{modelValue:i.unref(o),"onUpdate:modelValue":c[0]||(c[0]=h=>i.isRef(o)?o.value=h:null),clearable:i.unref(o),placeholder:t.defaultLabel,onChange:a},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(t.models,(h,f)=>(i.openBlock(),i.createElementBlock("option",{key:f,value:h,label:h.label},null,8,_h))),128))]),_:1},8,["modelValue","clearable","placeholder"])}}}),[["__scopeId","data-v-b5c8a87a"]]),Jo=M(i.defineComponent({__name:"FTSPPanel",setup(t){return i.onBeforeMount(async()=>{}),(e,n)=>(i.openBlock(),i.createElementBlock("div"))}}),[["__scopeId","data-v-36d19577"]]),Xo=M(i.defineComponent({__name:"GeneralItem",props:{background:{type:String,required:!1,default:"#ffffff"},height:{type:String,required:!1,default:"40px"},width:{type:String,required:!1,default:"auto"},ready:{type:String,required:!1,default:"0%"},padding:{type:String,required:!1,default:"10px"},borderColor:{type:String,required:!1,default:"#343D5C"},margin:{type:String,required:!1,default:"5px"},scale:{type:Boolean,required:!1,default:!0},fontSize:{type:String,required:!1,default:"14px"},withIcon:{type:Boolean,required:!1,default:!1}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock("div",{class:"general-block-item",style:i.normalizeStyle({background:t.background,height:t.height,width:t.width,borderColor:t.borderColor,padding:t.padding,margin:t.margin,transform:t.scale&&i.unref(e)?"scale(1.03, 1.03)":""}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},[i.createElementVNode("div",{class:"green",style:i.normalizeStyle({width:`${t.ready}`})},null,4),i.createElementVNode("div",{class:"general-block-item-title",style:i.normalizeStyle({fontSize:t.fontSize})},[i.renderSlot(n.$slots,"general-item",{},void 0,!0)],4),i.createElementVNode("div",{class:"tools-icon",style:i.normalizeStyle({display:t.withIcon?"flex":"none"})},r[2]||(r[2]=[i.createElementVNode("svg",{class:"icon-del"},[i.createElementVNode("use",{"xlink:href":"#del"})],-1)]),4),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"del",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 10 10"},[i.createElementVNode("path",{d:"M2.91797 8.75C2.6888 8.75 2.49255 8.66833 2.32922 8.505C2.16589 8.34167 2.08436 8.14556 2.08464 7.91667V2.5H1.66797V1.66667H3.7513V1.25H6.2513V1.66667H8.33464V2.5H7.91797V7.91667C7.91797 8.14583 7.8363 8.34208 7.67297 8.50542C7.50964 8.66875 7.31352 8.75028 7.08464 8.75H2.91797ZM7.08464 2.5H2.91797V7.91667H7.08464V2.5ZM3.7513 7.08333H4.58464V3.33333H3.7513V7.08333ZM5.41797 7.08333H6.2513V3.33333H5.41797V7.08333Z"})])],-1))],36))}}),[["__scopeId","data-v-d7e51e08"]]),Yo=M(i.defineComponent({__name:"IconDownload",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#download"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"download",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},[i.createElementVNode("path",{d:"M15.6443 5.06141C15.0797 5.29331 15.0998 5.06141 15.0998 12.1393C15.0998 15.7388 15.0696 18.6728 15.0293 18.6728C14.9889 18.6728 14.1521 17.8763 13.1842 16.9083C11.6819 15.4061 11.3592 15.1338 11.0467 15.0733C10.724 15.0229 10.6333 15.0632 10.3611 15.3254C10.1292 15.5573 10.0586 15.7186 10.0586 16.0211C10.0586 16.3941 10.1594 16.5151 12.8615 19.2071C15.4326 21.7681 15.6947 22 16.0073 22C16.3198 22 16.582 21.7681 19.153 19.2071C21.9156 16.4546 21.9559 16.4042 21.9559 15.9908C21.9559 15.4867 21.6535 15.1641 21.109 15.0733C20.736 15.0128 20.7259 15.0229 18.8808 16.868C17.0357 18.6929 17.0155 18.7131 17.0155 18.3703C17.0054 18.1787 16.9953 15.2145 16.9853 11.7965L16.9651 5.56554L16.713 5.31348C16.4307 5.03117 15.9669 4.92026 15.6443 5.06141Z"}),i.createElementVNode("path",{d:"M5.30247 20.3872L5 20.6997L5.04033 22.081C5.07058 23.4321 5.08066 23.4825 5.44363 24.2488C6.09899 25.6099 7.17782 26.5173 8.59945 26.8904C9.47663 27.1122 22.5335 27.1223 23.4006 26.8904C25.044 26.4669 26.3245 25.2671 26.8084 23.7043C26.9496 23.2506 27 22.7868 27 21.8794C27 20.6796 27 20.6695 26.7076 20.3771C26.3144 19.9839 25.901 19.9839 25.4675 20.3771L25.1347 20.6695L25.1045 21.8189C25.0843 22.8776 25.0541 23.0086 24.7516 23.6035C24.3987 24.3093 23.7938 24.8235 23.088 25.0251C22.5839 25.1663 9.4363 25.1663 8.93217 25.0251C8.30706 24.8436 7.64161 24.3093 7.29881 23.7144C7.00642 23.2002 6.98625 23.0691 6.93584 21.9197L6.88543 20.6695L6.5527 20.3771C6.11916 19.9839 5.70577 19.9839 5.30247 20.3872Z"})])],-1))],64))}}),[["__scopeId","data-v-40934683"]]),Qo=M(i.defineComponent({__name:"IconFilter",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#filter"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"filter",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},[i.createElementVNode("path",{d:"M8.58216 5.14236C6.22884 5.77558 4.70721 8.02494 5.04745 10.3688C5.61452 14.2627 10.3684 15.8127 13.0714 12.9962C13.6385 12.4103 14.319 11.2194 14.319 10.8225C14.319 10.6902 14.9428 10.6713 20.3771 10.6713H26.4353L26.7094 10.3972C27.0969 10.0097 27.0969 9.44261 26.7094 9.05511L26.4353 8.78103H20.396H14.3662L14.1867 8.23287C13.4589 5.9646 10.8599 4.52803 8.58216 5.14236ZM10.9638 7.21215C13.0525 8.24232 13.0336 11.2194 10.9355 12.2496C10.2172 12.5993 9.20593 12.6276 8.54436 12.2968C6.21939 11.1533 6.43676 7.81702 8.8846 7.01368C9.45166 6.8341 10.3495 6.91916 10.9638 7.21215Z"}),i.createElementVNode("path",{d:"M21.5953 17.6266C21.1133 17.7211 20.2155 18.0519 19.8752 18.2599C18.9868 18.7986 18.0322 20.0083 17.8054 20.8778L17.6826 21.3504H12.3616C6.66257 21.3504 6.63422 21.3504 6.37904 21.8135C6.20892 22.1443 6.26562 22.6452 6.51135 22.9287L6.73818 23.1933L12.1915 23.2406L17.6448 23.2878L17.8621 23.8738C18.4292 25.4427 19.7334 26.6052 21.2929 26.936C22.1057 27.1061 23.3154 27.0021 24.062 26.6997C25.3379 26.1799 26.4059 25.0174 26.8029 23.7037C26.9635 23.165 27.0013 22.8625 26.9635 22.0781C26.9352 21.1991 26.8974 21.0479 26.5855 20.3864C25.8105 18.7513 24.2794 17.7117 22.5499 17.6172C22.1529 17.5983 21.7276 17.6077 21.5953 17.6266ZM23.5517 19.8004C24.081 20.0556 24.5913 20.5754 24.8748 21.1519C24.9977 21.4071 25.045 21.7095 25.045 22.3427C25.045 23.1555 25.0261 23.2311 24.7236 23.7415C23.5611 25.6412 20.8014 25.5656 19.7902 23.5997C19.5066 23.0421 19.4405 22.0119 19.6484 21.3787C20.1682 19.8004 22.0206 19.0537 23.5517 19.8004Z"})])],-1))],64))}}),[["__scopeId","data-v-496ff188"]]),Ko=M(i.defineComponent({__name:"IconArrowLeft",props:{size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#arrow-left"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"arrow-left",fill:"none",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},[i.createElementVNode("path",{d:"M13.4323 2.0816C13.3788 2.0909 13.2951 2.12113 13.2462 2.14904C13.1997 2.17462 11.5439 3.85601 9.56715 5.8816C6.70668 8.81648 5.96017 9.59322 5.90436 9.69787C5.84622 9.8095 5.83691 9.85601 5.83691 9.99787C5.83691 10.1397 5.84622 10.1886 5.90436 10.2979C6.00436 10.4886 13.102 17.7746 13.2764 17.8653C13.3695 17.9142 13.423 17.9258 13.5555 17.9258C13.916 17.9235 14.1788 17.6583 14.1788 17.2932C14.1788 17.0374 14.1392 16.9769 13.623 16.4467C13.3695 16.1862 11.8555 14.6328 10.2555 12.9909C8.65552 11.349 7.35087 9.99787 7.35552 9.9909C7.36017 9.9816 8.86715 8.43276 10.7044 6.54904C12.5416 4.66532 14.0671 3.08392 14.0951 3.03508C14.2392 2.79555 14.1951 2.45834 13.9927 2.25834C13.8462 2.1095 13.6323 2.04206 13.4323 2.0816Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-11a9207f"]]),es=M(i.defineComponent({__name:"IconEdit",props:{size:{type:String,default:""},margin:{type:String,default:"0 15px 0 0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#edit"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"edit",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},[i.createElementVNode("path",{d:"M21.993 4.16087C21.6831 4.26049 21.2404 4.48185 20.9969 4.64787C20.1778 5.22342 4.60489 20.9402 4.39459 21.4051C4.11789 22.0138 3 25.8434 3 26.1865C3 26.5961 3.30991 27.1938 3.65302 27.4373C4.2507 27.8689 4.58275 27.8468 6.88493 27.1716C8.06923 26.8174 9.23138 26.4411 9.47488 26.3194C10.0062 26.0537 25.4795 10.6468 26.0772 9.79458C26.8519 8.67669 26.9626 7.32637 26.3871 6.10887C25.6234 4.48185 23.6754 3.61853 21.993 4.16087ZM24.0406 6.25276C24.7379 6.70655 25.0035 7.69162 24.6272 8.44426C24.4501 8.78737 9.331 24.0393 8.73332 24.471C8.48982 24.6481 5.2247 25.6995 5.13616 25.6331C5.11402 25.611 5.42393 24.5042 5.82239 23.1871L6.12123 22.1909L14.1125 14.1886C22.5243 5.76576 22.4911 5.79896 23.3101 5.94285C23.4983 5.97605 23.8192 6.11994 24.0406 6.25276Z",fill:"currentColor"}),i.createElementVNode("path",{d:"M15.098 25.9216C14.5446 26.1872 14.4118 27.1169 14.8656 27.5265C15.0759 27.7146 15.4743 27.7257 21.1302 27.7589C25.325 27.781 27.273 27.7478 27.4722 27.6703C28.0367 27.4268 28.1806 26.6521 27.7489 26.154L27.4833 25.8441L21.4069 25.822C17.2674 25.8109 15.264 25.833 15.098 25.9216Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-74cd505c"]]),ts=M(i.defineComponent({__name:"IconEmail",props:{size:{type:String,default:""},margin:{type:String,default:"0 10px 0 0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#email"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"email",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[i.createElementVNode("path",{d:"M20 20H4C3.46957 20 2.96086 19.7893 2.58579 19.4142C2.21071 19.0391 2 18.5304 2 18V5.913C2.02243 5.39779 2.24301 4.91116 2.61568 4.5547C2.98835 4.19824 3.4843 3.99951 4 4H20C20.5304 4 21.0391 4.21071 21.4142 4.58579C21.7893 4.96086 22 5.46957 22 6V18C22 18.5304 21.7893 19.0391 21.4142 19.4142C21.0391 19.7893 20.5304 20 20 20ZM4 7.868V18H20V7.868L12 13.2L4 7.868ZM4.8 6L12 10.8L19.2 6H4.8Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-b89c9521"]]),ns=M(i.defineComponent({__name:"IconMove",props:{size:{type:String,default:"24px"},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#icon-move"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"icon-move",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 22 22"},[i.createElementVNode("path",{d:"M8.91736 3.08529L6.83471 5.17059H8.0843H9.33058V7.25588V9.34117H7.24793H5.16529L5.15868 8.09993L5.14876 6.85868L3.07273 8.93404L1 11.0127L3.08264 13.098L5.16529 15.1833V13.9321V12.6843H7.24793H9.33058V14.7696V16.8548H7.89256C7.10248 16.8548 6.45455 16.8648 6.45785 16.878C6.45785 16.8946 6.60992 17.0402 6.79504 17.2057C7.16529 17.5367 8.90744 19.1189 9.38017 19.5525C10.7058 20.7639 10.9967 21.0188 11.0331 20.999C11.0562 20.9857 12.0876 20.0523 13.3273 18.9236L15.5785 16.8714L14.124 16.8615L12.6694 16.8548V14.7696V12.6843H14.7521H16.8347V13.9255C16.8347 14.6074 16.8446 15.1668 16.8612 15.1668C16.8975 15.1668 21 11.0491 21 11.0127C21 10.9763 16.8975 6.85868 16.8612 6.85868C16.8446 6.85868 16.8347 7.41807 16.8347 8.09993V9.34117H14.7521H12.6694V7.25588V5.17059H13.9091C14.5901 5.17059 15.1488 5.16066 15.1488 5.14411C15.1488 5.12094 11.043 1 11.0165 1C11.0066 1 10.0612 1.93673 8.91736 3.08529ZM12.081 3.24086C12.6595 3.82011 13.1322 4.30337 13.1322 4.31661C13.1322 4.33316 12.8413 4.34309 12.4876 4.34309H11.843V7.25588V10.1687H14.7686H17.6942V9.53646C17.6909 9.18891 17.6975 8.89763 17.7041 8.89101C17.7074 8.88439 18.1934 9.36103 18.7785 9.9469L19.843 11.0127L18.7686 12.0885L17.6942 13.1642V12.9325C17.6909 12.8034 17.6876 12.5155 17.6843 12.2871L17.6777 11.8733L14.762 11.8634L11.843 11.8568V14.7696V17.6823L12.6331 17.689L13.4264 17.6989L12.2165 18.7978L11.0066 19.9L10.7223 19.6419C10.5669 19.5028 10.4314 19.3804 10.4215 19.3704C10.405 19.3539 9.92893 18.917 9.28099 18.3311C9.09917 18.1656 8.86777 17.9538 8.7686 17.8578L8.58678 17.6823H9.37355H10.157V14.7696V11.8568H7.24793H4.33884L4.33223 12.5022L4.32231 13.1477L3.25455 12.0785L2.19008 11.0127L3.25455 9.94359L4.32231 8.87446L4.33223 9.52322L4.33884 10.1687H7.24793H10.157V7.25588V4.34309L9.5124 4.33647L8.86446 4.32654L9.93223 3.25741C10.5174 2.67154 11.0066 2.1916 11.0165 2.1916C11.0264 2.1916 11.5058 2.66492 12.081 3.24086Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-47aba5d0"]]),is=M(i.defineComponent({__name:"IconPhone",props:{size:{type:String,default:""},margin:{type:String,default:"0 10px 0 0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#phone"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"phone",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[i.createElementVNode("path",{d:"M19.4998 21.75H19.3723C4.63482 20.9025 2.54232 8.4675 2.24982 4.6725C2.22625 4.37744 2.26114 4.08062 2.35248 3.79906C2.44382 3.5175 2.58981 3.25673 2.78211 3.03169C2.9744 2.80665 3.20921 2.62177 3.47308 2.48763C3.73695 2.35349 4.02469 2.27274 4.31982 2.25H8.45232C8.75274 2.24971 9.04632 2.33963 9.29504 2.50812C9.54377 2.67661 9.73617 2.9159 9.84732 3.195L10.9873 6C11.0971 6.27266 11.1243 6.57156 11.0657 6.85957C11.007 7.14758 10.865 7.412 10.6573 7.62L9.05982 9.2325C9.30936 10.6506 9.98846 11.9578 11.0052 12.9772C12.022 13.9967 13.3274 14.6792 14.7448 14.9325L16.3723 13.32C16.5834 13.1146 16.8504 12.9759 17.1398 12.9213C17.4292 12.8666 17.7283 12.8983 17.9998 13.0125L20.8273 14.145C21.1022 14.2597 21.3367 14.4536 21.501 14.702C21.6653 14.9504 21.7519 15.2422 21.7498 15.54V19.5C21.7498 20.0967 21.5128 20.669 21.0908 21.091C20.6689 21.5129 20.0966 21.75 19.4998 21.75ZM4.49982 3.75C4.30091 3.75 4.11014 3.82902 3.96949 3.96967C3.82884 4.11032 3.74982 4.30109 3.74982 4.5V4.56C4.09482 9 6.30732 19.5 19.4548 20.25C19.5534 20.2561 19.6521 20.2427 19.7454 20.2105C19.8388 20.1783 19.9248 20.1281 19.9987 20.0626C20.0726 19.9971 20.1328 19.9176 20.1759 19.8288C20.219 19.74 20.2441 19.6436 20.2498 19.545V15.54L17.4223 14.4075L15.2698 16.545L14.9098 16.5C8.38482 15.6825 7.49982 9.1575 7.49982 9.09L7.45482 8.73L9.58482 6.5775L8.45982 3.75H4.49982Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-cb2db6a7"]]),Ei=M(i.defineComponent({__name:"IconSearch",props:{size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#search"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"search",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[i.createElementVNode("path",{d:"M11 19C12.775 18.9996 14.4988 18.4054 15.897 17.312L20.293 21.708L21.707 20.294L17.311 15.898C18.405 14.4997 18.9996 12.7754 19 11C19 6.589 15.411 3 11 3C6.589 3 3 6.589 3 11C3 15.411 6.589 19 11 19ZM11 5C14.309 5 17 7.691 17 11C17 14.309 14.309 17 11 17C7.691 17 5 14.309 5 11C5 7.691 7.691 5 11 5Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-1b900a88"]]),yn=M(i.defineComponent({__name:"ArrowLeft",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#arrow-left"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"arrow-left",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[i.createElementVNode("path",{d:"M656.733 149.806C659.446 147.019 662.69 144.804 666.274 143.292C669.857 141.779 673.707 141 677.597 141C681.486 141 685.337 141.779 688.92 143.292C692.503 144.804 695.748 147.019 698.461 149.806C704.024 155.518 707.138 163.176 707.138 171.15C707.138 179.123 704.024 186.782 698.461 192.494L386.589 512.366L698.461 832.302C701.269 835.176 703.483 838.575 704.976 842.305C706.47 846.035 707.215 850.022 707.167 854.04C707.119 858.057 706.281 862.026 704.699 865.72C703.118 869.413 700.824 872.759 697.949 875.566C695.211 878.242 691.972 880.351 688.417 881.774C684.863 883.197 681.063 883.904 677.235 883.857C673.407 883.809 669.625 883.007 666.107 881.497C662.589 879.986 659.404 877.797 656.733 875.054L325.085 534.702C319.26 528.726 316 520.711 316 512.366C316 504.021 319.26 496.006 325.085 490.03L656.733 149.806Z"})])],-1))],64))}}),[["__scopeId","data-v-31d7e282"]]),wn=M(i.defineComponent({__name:"ArrowRight",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#arrow-right"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"arrow-right",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[i.createElementVNode("path",{d:"M366.436 875.054C363.723 877.84 360.479 880.055 356.895 881.568C353.312 883.08 349.462 883.859 345.572 883.859C341.683 883.859 337.832 883.08 334.249 881.568C330.666 880.055 327.421 877.84 324.708 875.054C319.145 869.342 316.031 861.683 316.031 853.71C316.031 845.736 319.145 838.077 324.708 832.366L636.58 512.494L324.708 192.558C321.9 189.684 319.686 186.284 318.193 182.555C316.699 178.825 315.954 174.837 316.002 170.82C316.049 166.802 316.888 162.833 318.47 159.14C320.051 155.446 322.345 152.1 325.22 149.294C327.958 146.618 331.197 144.508 334.752 143.086C338.306 141.663 342.106 140.955 345.934 141.003C349.762 141.05 353.544 141.852 357.062 143.363C360.58 144.873 363.765 147.063 366.436 149.806L698.084 490.158C703.909 496.134 707.169 504.148 707.169 512.494C707.169 520.839 703.909 528.854 698.084 534.83L366.436 875.054Z"})])],-1))],64))}}),[["__scopeId","data-v-ac346343"]]),vi=M(i.defineComponent({__name:"DoubleArrowLeft",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#double-arrow-left"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"double-arrow-left",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[i.createElementVNode("path",{d:"M529.408 149.376C532.121 146.589 535.365 144.374 538.949 142.862C542.532 141.35 546.382 140.57 550.272 140.57C554.161 140.57 558.011 141.35 561.595 142.862C565.178 144.374 568.422 146.589 571.136 149.376C576.699 155.088 579.813 162.746 579.813 170.72C579.813 178.694 576.699 186.352 571.136 192.064L259.264 511.936L571.136 831.872C573.943 834.746 576.157 838.145 577.651 841.875C579.145 845.605 579.889 849.593 579.842 853.61C579.794 857.628 578.956 861.597 577.374 865.29C575.792 868.984 573.499 872.329 570.624 875.136C567.886 877.812 564.647 879.922 561.092 881.344C557.538 882.767 553.738 883.475 549.91 883.427C546.081 883.38 542.3 882.578 538.782 881.067C535.264 879.556 532.079 877.367 529.408 874.624L197.76 534.272C191.935 528.296 188.675 520.281 188.675 511.936C188.675 503.591 191.935 495.576 197.76 489.6L529.408 149.376ZM785.408 149.376C788.121 146.589 791.365 144.374 794.949 142.862C798.532 141.35 802.382 140.57 806.272 140.57C810.161 140.57 814.011 141.35 817.595 142.862C821.178 144.374 824.422 146.589 827.136 149.376C832.699 155.088 835.813 162.746 835.813 170.72C835.813 178.694 832.699 186.352 827.136 192.064L515.264 511.936L827.136 831.872C829.943 834.746 832.157 838.145 833.651 841.875C835.145 845.605 835.889 849.593 835.842 853.61C835.794 857.628 834.956 861.597 833.374 865.29C831.792 868.984 829.499 872.329 826.624 875.136C823.886 877.812 820.647 879.922 817.092 881.344C813.538 882.767 809.738 883.475 805.91 883.427C802.081 883.38 798.3 882.578 794.782 881.067C791.264 879.556 788.079 877.367 785.408 874.624L453.76 534.272C447.935 528.296 444.675 520.281 444.675 511.936C444.675 503.591 447.935 495.576 453.76 489.6L785.408 149.376Z"})])],-1))],64))}}),[["__scopeId","data-v-646afc45"]]),Mi=M(i.defineComponent({__name:"DoubleArrowRight",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#double-arrow-right"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"double-arrow-right",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[i.createElementVNode("path",{d:"M495.111 874.624C492.397 877.411 489.153 879.626 485.57 881.138C481.987 882.65 478.136 883.43 474.247 883.43C470.357 883.43 466.507 882.65 462.924 881.138C459.34 879.626 456.096 877.411 453.383 874.624C447.819 868.912 444.706 861.254 444.706 853.28C444.706 845.306 447.819 837.648 453.383 831.936L765.255 512.064L453.383 192.128C450.575 189.254 448.361 185.855 446.867 182.125C445.374 178.395 444.629 174.407 444.677 170.39C444.724 166.372 445.563 162.403 447.145 158.71C448.726 155.016 451.02 151.671 453.895 148.864C456.633 146.188 459.872 144.078 463.426 142.656C466.981 141.233 470.781 140.525 474.609 140.573C478.437 140.62 482.219 141.422 485.737 142.933C489.254 144.444 492.44 146.633 495.111 149.376L826.759 489.728C832.584 495.704 835.844 503.719 835.844 512.064C835.844 520.409 832.584 528.424 826.759 534.4L495.111 874.624ZM239.111 874.624C236.397 877.411 233.153 879.626 229.57 881.138C225.987 882.65 222.136 883.43 218.247 883.43C214.357 883.43 210.507 882.65 206.924 881.138C203.34 879.626 200.096 877.411 197.383 874.624C191.819 868.912 188.706 861.254 188.706 853.28C188.706 845.306 191.819 837.648 197.383 831.936L509.255 512.064L197.383 192.128C194.575 189.254 192.361 185.855 190.867 182.125C189.374 178.395 188.629 174.407 188.677 170.39C188.724 166.372 189.563 162.403 191.145 158.71C192.726 155.016 195.02 151.671 197.895 148.864C200.633 146.188 203.872 144.078 207.426 142.656C210.981 141.233 214.781 140.525 218.609 140.573C222.437 140.62 226.219 141.422 229.737 142.933C233.254 144.444 236.44 146.633 239.111 149.376L570.759 489.728C576.584 495.704 579.844 503.719 579.844 512.064C579.844 520.409 576.584 528.424 570.759 534.4L239.111 874.624Z"})])],-1))],64))}}),[["__scopeId","data-v-ef44f40e"]]),xi=M(i.defineComponent({__name:"EllipsisSvg",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#ellipsis"},null,-1)]),38)),r[3]||(r[3]=i.createStaticVNode('<svg width="0" height="0" class="hidden" data-v-1c5f4e97><symbol id="ellipsis" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 240 240" data-v-1c5f4e97><path d="M65 135C73.2843 135 80 128.284 80 120C80 111.716 73.2843 105 65 105C56.7157 105 50 111.716 50 120C50 128.284 56.7157 135 65 135Z" data-v-1c5f4e97></path><path d="M120 135C128.284 135 135 128.284 135 120C135 111.716 128.284 105 120 105C111.716 105 105 111.716 105 120C105 128.284 111.716 135 120 135Z" data-v-1c5f4e97></path><path d="M175 135C183.284 135 190 128.284 190 120C190 111.716 183.284 105 175 105C166.716 105 160 111.716 160 120C160 128.284 166.716 135 175 135Z" data-v-1c5f4e97></path></symbol></svg>',1))],64))}}),[["__scopeId","data-v-1c5f4e97"]]);function rs(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function q(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?rs(Object(n),!0).forEach(function(r){Ce(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):rs(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Ce(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function qh(t,e){if(t==null)return{};var n,r,o=function(a,d){if(a==null)return{};var c,u,h={},f=Object.keys(a);for(u=0;u<f.length;u++)c=f[u],d.indexOf(c)>=0||(h[c]=a[c]);return h}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(r=0;r<s.length;r++)n=s[r],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(o[n]=t[n])}return o}function it(t){return function(e){if(Array.isArray(e))return Bi(e)}(t)||function(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}(t)||function(e,n){if(e){if(typeof e=="string")return Bi(e,n);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Bi(e,n)}}(t)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
24
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function Bi(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var os,Uh,bn,X=(os=function(t){/*!
18
+ */function pr(t){const e=Array.from(arguments).slice(1);console.warn.apply(console,["[Vue Router warn]: "+t].concat(e))}var gr;(function(t){t.pop="pop",t.push="push"})(gr||(gr={}));var yr;(function(t){t.back="back",t.forward="forward",t.unknown=""})(yr||(yr={})),Symbol(process.env.NODE_ENV!=="production"?"navigation failure":"");var wr;(function(t){t[t.aborted=4]="aborted",t[t.cancelled=8]="cancelled",t[t.duplicated=16]="duplicated"})(wr||(wr={}));const ll=Symbol(process.env.NODE_ENV!=="production"?"router view location matched":"");Symbol(process.env.NODE_ENV!=="production"?"router view depth":""),Symbol(process.env.NODE_ENV!=="production"?"router":""),Symbol(process.env.NODE_ENV!=="production"?"route location":""),Symbol(process.env.NODE_ENV!=="production"?"router view location":"");function cl(t,e,n){const r=()=>{t[e].delete(n)};i.onUnmounted(r),i.onDeactivated(r),i.onActivated(()=>{t[e].add(n)}),t[e].add(n)}function dl(t){if(process.env.NODE_ENV!=="production"&&!i.getCurrentInstance()){pr("getCurrentInstance() returned null. onBeforeRouteLeave() must be called at the top of a setup function");return}const e=i.inject(ll,{}).value;if(!e){process.env.NODE_ENV!=="production"&&pr("No active route record was found when calling `onBeforeRouteLeave()`. Make sure you call this function inside a component child of <router-view>. Maybe you called it inside of App.vue?");return}cl(e,"leaveGuards",t)}function br(t,e){const n=[],r=e||Ae.Asc,o=r===Ae.Asc?Ae.Desc:Ae.Asc;return Object.values(t).forEach(s=>{n.push(s(r)),n.push(s(o))}),n.length>0&&!n.some(s=>s.default)&&(n[0].default=!0),e&&n.forEach(s=>{s.default&&(s.default=s.order===e)}),n}class ul{constructor(){l(this,"list",[]);l(this,"defaultSortModel");l(this,"changeFlag",!1)}Set(e){this.Reset(),e&&(Array.isArray(e)?this.list=e:this.list=br(e),this.SetDefault())}SetDefault(){this.defaultSortModel=this.list.find(e=>e.default)??this.list[0],this.changeFlag=!this.changeFlag}Get(){return this.list}GetDefault(){return this.defaultSortModel}Reset(){this.list=[],this.defaultSortModel=void 0}}const Pe=new ul;function Cr(){const t=i.ref(!1),e=i.ref(!1);return{confirmLeave:t,saveButtonClick:e,beforeWindowUnload:s=>{t.value&&s.preventDefault()},formUpdated:()=>{t.value=!0},showConfirmModal:(s,a)=>{t.value&&!e.value?s():a()}}}const hl=(()=>{const t=(s,a)=>i.onBeforeMount(async()=>{var d;S.H.FTSP.Get().reset(),Pe.Set(a==null?void 0:a.sortsLib),S.H.FTSP.Get().setSortModel(Pe.GetDefault()),Pe.Set(a==null?void 0:a.sortsLib),S.H.FTSP.Get().setSortModel(Pe.GetDefault()),S.Paginator.storeModule=(d=a==null?void 0:a.pagination)==null?void 0:d.storeModule,await s()}),{saveButtonClick:e,showConfirmModal:n}=Cr(),r=s=>dl((a,d,c)=>{n((s||o)(),c)}),o=s=>async()=>{e.value=!0;try{s&&await s(),S.Notification.Success("Сохранено")}catch(a){S.Notification.Success("Что-то пошло не так. "+a);return}};return{onBeforeMount:t,onBeforeRouteLeave:r,submit:o}})();var Hn=(t=>(t.XS="xs",t.S="s",t.M="m",t.L="l",t.XL="xl",t))(Hn||{});function Sr(t,e){return function(){return t.apply(e,arguments)}}const{toString:fl}=Object.prototype,{getPrototypeOf:_n}=Object,Yt=(t=>e=>{const n=fl.call(e);return t[n]||(t[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Be=t=>(t=t.toLowerCase(),e=>Yt(e)===t),Qt=t=>e=>typeof e===t,{isArray:lt}=Array,xt=Qt("undefined");function ml(t){return t!==null&&!xt(t)&&t.constructor!==null&&!xt(t.constructor)&&we(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const kr=Be("ArrayBuffer");function pl(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&kr(t.buffer),e}const gl=Qt("string"),we=Qt("function"),Er=Qt("number"),Kt=t=>t!==null&&typeof t=="object",yl=t=>t===!0||t===!1,en=t=>{if(Yt(t)!=="object")return!1;const e=_n(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)},wl=Be("Date"),bl=Be("File"),Cl=Be("Blob"),Sl=Be("FileList"),kl=t=>Kt(t)&&we(t.pipe),El=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||we(t.append)&&((e=Yt(t))==="formdata"||e==="object"&&we(t.toString)&&t.toString()==="[object FormData]"))},vl=Be("URLSearchParams"),[Ml,xl,Bl,Il]=["ReadableStream","Request","Response","Headers"].map(Be),Rl=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Bt(t,e,{allOwnKeys:n=!1}={}){if(t===null||typeof t>"u")return;let r,o;if(typeof t!="object"&&(t=[t]),lt(t))for(r=0,o=t.length;r<o;r++)e.call(null,t[r],r,t);else{const s=n?Object.getOwnPropertyNames(t):Object.keys(t),a=s.length;let d;for(r=0;r<a;r++)d=s[r],e.call(null,t[d],d,t)}}function vr(t,e){e=e.toLowerCase();const n=Object.keys(t);let r=n.length,o;for(;r-- >0;)if(o=n[r],e===o.toLowerCase())return o;return null}const Xe=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Mr=t=>!xt(t)&&t!==Xe;function qn(){const{caseless:t}=Mr(this)&&this||{},e={},n=(r,o)=>{const s=t&&vr(e,o)||o;en(e[s])&&en(r)?e[s]=qn(e[s],r):en(r)?e[s]=qn({},r):lt(r)?e[s]=r.slice():e[s]=r};for(let r=0,o=arguments.length;r<o;r++)arguments[r]&&Bt(arguments[r],n);return e}const $l=(t,e,n,{allOwnKeys:r}={})=>(Bt(e,(o,s)=>{n&&we(o)?t[s]=Sr(o,n):t[s]=o},{allOwnKeys:r}),t),Nl=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),Al=(t,e,n,r)=>{t.prototype=Object.create(e.prototype,r),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),n&&Object.assign(t.prototype,n)},Pl=(t,e,n,r)=>{let o,s,a;const d={};if(e=e||{},t==null)return e;do{for(o=Object.getOwnPropertyNames(t),s=o.length;s-- >0;)a=o[s],(!r||r(a,t,e))&&!d[a]&&(e[a]=t[a],d[a]=!0);t=n!==!1&&_n(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},Tl=(t,e,n)=>{t=String(t),(n===void 0||n>t.length)&&(n=t.length),n-=e.length;const r=t.indexOf(e,n);return r!==-1&&r===n},zl=t=>{if(!t)return null;if(lt(t))return t;let e=t.length;if(!Er(e))return null;const n=new Array(e);for(;e-- >0;)n[e]=t[e];return n},Vl=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&_n(Uint8Array)),Fl=(t,e)=>{const r=(t&&t[Symbol.iterator]).call(t);let o;for(;(o=r.next())&&!o.done;){const s=o.value;e.call(t,s[0],s[1])}},Dl=(t,e)=>{let n;const r=[];for(;(n=t.exec(e))!==null;)r.push(n);return r},Ll=Be("HTMLFormElement"),Ol=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),xr=(({hasOwnProperty:t})=>(e,n)=>t.call(e,n))(Object.prototype),Hl=Be("RegExp"),Br=(t,e)=>{const n=Object.getOwnPropertyDescriptors(t),r={};Bt(n,(o,s)=>{let a;(a=e(o,s,t))!==!1&&(r[s]=a||o)}),Object.defineProperties(t,r)},_l=t=>{Br(t,(e,n)=>{if(we(t)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=t[n];if(we(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},ql=(t,e)=>{const n={},r=o=>{o.forEach(s=>{n[s]=!0})};return lt(t)?r(t):r(String(t).split(e)),n},Ul=()=>{},Wl=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e,Un="abcdefghijklmnopqrstuvwxyz",Ir="0123456789",Rr={DIGIT:Ir,ALPHA:Un,ALPHA_DIGIT:Un+Un.toUpperCase()+Ir},Gl=(t=16,e=Rr.ALPHA_DIGIT)=>{let n="";const{length:r}=e;for(;t--;)n+=e[Math.random()*r|0];return n};function jl(t){return!!(t&&we(t.append)&&t[Symbol.toStringTag]==="FormData"&&t[Symbol.iterator])}const Zl=t=>{const e=new Array(10),n=(r,o)=>{if(Kt(r)){if(e.indexOf(r)>=0)return;if(!("toJSON"in r)){e[o]=r;const s=lt(r)?[]:{};return Bt(r,(a,d)=>{const c=n(a,o+1);!xt(c)&&(s[d]=c)}),e[o]=void 0,s}}return r};return n(t,0)},Jl=Be("AsyncFunction"),Xl=t=>t&&(Kt(t)||we(t))&&we(t.then)&&we(t.catch),$r=((t,e)=>t?setImmediate:e?((n,r)=>(Xe.addEventListener("message",({source:o,data:s})=>{o===Xe&&s===n&&r.length&&r.shift()()},!1),o=>{r.push(o),Xe.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",we(Xe.postMessage)),Yl=typeof queueMicrotask<"u"?queueMicrotask.bind(Xe):typeof process<"u"&&process.nextTick||$r,C={isArray:lt,isArrayBuffer:kr,isBuffer:ml,isFormData:El,isArrayBufferView:pl,isString:gl,isNumber:Er,isBoolean:yl,isObject:Kt,isPlainObject:en,isReadableStream:Ml,isRequest:xl,isResponse:Bl,isHeaders:Il,isUndefined:xt,isDate:wl,isFile:bl,isBlob:Cl,isRegExp:Hl,isFunction:we,isStream:kl,isURLSearchParams:vl,isTypedArray:Vl,isFileList:Sl,forEach:Bt,merge:qn,extend:$l,trim:Rl,stripBOM:Nl,inherits:Al,toFlatObject:Pl,kindOf:Yt,kindOfTest:Be,endsWith:Tl,toArray:zl,forEachEntry:Fl,matchAll:Dl,isHTMLForm:Ll,hasOwnProperty:xr,hasOwnProp:xr,reduceDescriptors:Br,freezeMethods:_l,toObjectSet:ql,toCamelCase:Ol,noop:Ul,toFiniteNumber:Wl,findKey:vr,global:Xe,isContextDefined:Mr,ALPHABET:Rr,generateString:Gl,isSpecCompliantForm:jl,toJSONObject:Zl,isAsyncFn:Jl,isThenable:Xl,setImmediate:$r,asap:Yl};function F(t,e,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o,this.status=o.status?o.status:null)}C.inherits(F,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:C.toJSONObject(this.config),code:this.code,status:this.status}}});const Nr=F.prototype,Ar={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{Ar[t]={value:t}}),Object.defineProperties(F,Ar),Object.defineProperty(Nr,"isAxiosError",{value:!0}),F.from=(t,e,n,r,o,s)=>{const a=Object.create(Nr);return C.toFlatObject(t,a,function(c){return c!==Error.prototype},d=>d!=="isAxiosError"),F.call(a,t.message,e,n,r,o),a.cause=t,a.name=t.name,s&&Object.assign(a,s),a};const Ql=null;function Wn(t){return C.isPlainObject(t)||C.isArray(t)}function Pr(t){return C.endsWith(t,"[]")?t.slice(0,-2):t}function Tr(t,e,n){return t?t.concat(e).map(function(o,s){return o=Pr(o),!n&&s?"["+o+"]":o}).join(n?".":""):e}function Kl(t){return C.isArray(t)&&!t.some(Wn)}const ec=C.toFlatObject(C,{},null,function(e){return/^is[A-Z]/.test(e)});function tn(t,e,n){if(!C.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,n=C.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(k,w){return!C.isUndefined(w[k])});const r=n.metaTokens,o=n.visitor||h,s=n.dots,a=n.indexes,c=(n.Blob||typeof Blob<"u"&&Blob)&&C.isSpecCompliantForm(e);if(!C.isFunction(o))throw new TypeError("visitor must be a function");function u(p){if(p===null)return"";if(C.isDate(p))return p.toISOString();if(!c&&C.isBlob(p))throw new F("Blob is not supported. Use a Buffer instead.");return C.isArrayBuffer(p)||C.isTypedArray(p)?c&&typeof Blob=="function"?new Blob([p]):Buffer.from(p):p}function h(p,k,w){let B=p;if(p&&!w&&typeof p=="object"){if(C.endsWith(k,"{}"))k=r?k:k.slice(0,-2),p=JSON.stringify(p);else if(C.isArray(p)&&Kl(p)||(C.isFileList(p)||C.endsWith(k,"[]"))&&(B=C.toArray(p)))return k=Pr(k),B.forEach(function(L,V){!(C.isUndefined(L)||L===null)&&e.append(a===!0?Tr([k],V,s):a===null?k:k+"[]",u(L))}),!1}return Wn(p)?!0:(e.append(Tr(w,k,s),u(p)),!1)}const f=[],m=Object.assign(ec,{defaultVisitor:h,convertValue:u,isVisitable:Wn});function g(p,k){if(!C.isUndefined(p)){if(f.indexOf(p)!==-1)throw Error("Circular reference detected in "+k.join("."));f.push(p),C.forEach(p,function(B,D){(!(C.isUndefined(B)||B===null)&&o.call(e,B,C.isString(D)?D.trim():D,k,m))===!0&&g(B,k?k.concat(D):[D])}),f.pop()}}if(!C.isObject(t))throw new TypeError("data must be an object");return g(t),e}function zr(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function Gn(t,e){this._pairs=[],t&&tn(t,this,e)}const Vr=Gn.prototype;Vr.append=function(e,n){this._pairs.push([e,n])},Vr.toString=function(e){const n=e?function(r){return e.call(this,r,zr)}:zr;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function tc(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Fr(t,e,n){if(!e)return t;const r=n&&n.encode||tc,o=n&&n.serialize;let s;if(o?s=o(e,n):s=C.isURLSearchParams(e)?e.toString():new Gn(e,n).toString(r),s){const a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+s}return t}class Dr{constructor(){this.handlers=[]}use(e,n,r){return this.handlers.push({fulfilled:e,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){C.forEach(this.handlers,function(r){r!==null&&e(r)})}}const Lr={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},nc={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:Gn,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},jn=typeof window<"u"&&typeof document<"u",Zn=typeof navigator=="object"&&navigator||void 0,ic=jn&&(!Zn||["ReactNative","NativeScript","NS"].indexOf(Zn.product)<0),rc=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",oc=jn&&window.location.href||"http://localhost",he={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:jn,hasStandardBrowserEnv:ic,hasStandardBrowserWebWorkerEnv:rc,navigator:Zn,origin:oc},Symbol.toStringTag,{value:"Module"})),...nc};function sc(t,e){return tn(t,new he.classes.URLSearchParams,Object.assign({visitor:function(n,r,o,s){return he.isNode&&C.isBuffer(n)?(this.append(r,n.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)}},e))}function ac(t){return C.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function lc(t){const e={},n=Object.keys(t);let r;const o=n.length;let s;for(r=0;r<o;r++)s=n[r],e[s]=t[s];return e}function Or(t){function e(n,r,o,s){let a=n[s++];if(a==="__proto__")return!0;const d=Number.isFinite(+a),c=s>=n.length;return a=!a&&C.isArray(o)?o.length:a,c?(C.hasOwnProp(o,a)?o[a]=[o[a],r]:o[a]=r,!d):((!o[a]||!C.isObject(o[a]))&&(o[a]=[]),e(n,r,o[a],s)&&C.isArray(o[a])&&(o[a]=lc(o[a])),!d)}if(C.isFormData(t)&&C.isFunction(t.entries)){const n={};return C.forEachEntry(t,(r,o)=>{e(ac(r),o,n,0)}),n}return null}function cc(t,e,n){if(C.isString(t))try{return(e||JSON.parse)(t),C.trim(t)}catch(r){if(r.name!=="SyntaxError")throw r}return(0,JSON.stringify)(t)}const It={transitional:Lr,adapter:["xhr","http","fetch"],transformRequest:[function(e,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,s=C.isObject(e);if(s&&C.isHTMLForm(e)&&(e=new FormData(e)),C.isFormData(e))return o?JSON.stringify(Or(e)):e;if(C.isArrayBuffer(e)||C.isBuffer(e)||C.isStream(e)||C.isFile(e)||C.isBlob(e)||C.isReadableStream(e))return e;if(C.isArrayBufferView(e))return e.buffer;if(C.isURLSearchParams(e))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let d;if(s){if(r.indexOf("application/x-www-form-urlencoded")>-1)return sc(e,this.formSerializer).toString();if((d=C.isFileList(e))||r.indexOf("multipart/form-data")>-1){const c=this.env&&this.env.FormData;return tn(d?{"files[]":e}:e,c&&new c,this.formSerializer)}}return s||o?(n.setContentType("application/json",!1),cc(e)):e}],transformResponse:[function(e){const n=this.transitional||It.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(C.isResponse(e)||C.isReadableStream(e))return e;if(e&&C.isString(e)&&(r&&!this.responseType||o)){const a=!(n&&n.silentJSONParsing)&&o;try{return JSON.parse(e)}catch(d){if(a)throw d.name==="SyntaxError"?F.from(d,F.ERR_BAD_RESPONSE,this,null,this.response):d}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:he.classes.FormData,Blob:he.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};C.forEach(["delete","get","head","post","put","patch"],t=>{It.headers[t]={}});const dc=C.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),uc=t=>{const e={};let n,r,o;return t&&t.split(`
19
+ `).forEach(function(a){o=a.indexOf(":"),n=a.substring(0,o).trim().toLowerCase(),r=a.substring(o+1).trim(),!(!n||e[n]&&dc[n])&&(n==="set-cookie"?e[n]?e[n].push(r):e[n]=[r]:e[n]=e[n]?e[n]+", "+r:r)}),e},Hr=Symbol("internals");function Rt(t){return t&&String(t).trim().toLowerCase()}function nn(t){return t===!1||t==null?t:C.isArray(t)?t.map(nn):String(t)}function hc(t){const e=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(t);)e[r[1]]=r[2];return e}const fc=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function Jn(t,e,n,r,o){if(C.isFunction(r))return r.call(this,e,n);if(o&&(e=n),!!C.isString(e)){if(C.isString(r))return e.indexOf(r)!==-1;if(C.isRegExp(r))return r.test(e)}}function mc(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,n,r)=>n.toUpperCase()+r)}function pc(t,e){const n=C.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(t,r+n,{value:function(o,s,a){return this[r].call(this,e,o,s,a)},configurable:!0})})}class fe{constructor(e){e&&this.set(e)}set(e,n,r){const o=this;function s(d,c,u){const h=Rt(c);if(!h)throw new Error("header name must be a non-empty string");const f=C.findKey(o,h);(!f||o[f]===void 0||u===!0||u===void 0&&o[f]!==!1)&&(o[f||c]=nn(d))}const a=(d,c)=>C.forEach(d,(u,h)=>s(u,h,c));if(C.isPlainObject(e)||e instanceof this.constructor)a(e,n);else if(C.isString(e)&&(e=e.trim())&&!fc(e))a(uc(e),n);else if(C.isHeaders(e))for(const[d,c]of e.entries())s(c,d,r);else e!=null&&s(n,e,r);return this}get(e,n){if(e=Rt(e),e){const r=C.findKey(this,e);if(r){const o=this[r];if(!n)return o;if(n===!0)return hc(o);if(C.isFunction(n))return n.call(this,o,r);if(C.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,n){if(e=Rt(e),e){const r=C.findKey(this,e);return!!(r&&this[r]!==void 0&&(!n||Jn(this,this[r],r,n)))}return!1}delete(e,n){const r=this;let o=!1;function s(a){if(a=Rt(a),a){const d=C.findKey(r,a);d&&(!n||Jn(r,r[d],d,n))&&(delete r[d],o=!0)}}return C.isArray(e)?e.forEach(s):s(e),o}clear(e){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const s=n[r];(!e||Jn(this,this[s],s,e,!0))&&(delete this[s],o=!0)}return o}normalize(e){const n=this,r={};return C.forEach(this,(o,s)=>{const a=C.findKey(r,s);if(a){n[a]=nn(o),delete n[s];return}const d=e?mc(s):String(s).trim();d!==s&&delete n[s],n[d]=nn(o),r[d]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const n=Object.create(null);return C.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=e&&C.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,n])=>e+": "+n).join(`
20
+ `)}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(o=>r.set(o)),r}static accessor(e){const r=(this[Hr]=this[Hr]={accessors:{}}).accessors,o=this.prototype;function s(a){const d=Rt(a);r[d]||(pc(o,a),r[d]=!0)}return C.isArray(e)?e.forEach(s):s(e),this}}fe.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),C.reduceDescriptors(fe.prototype,({value:t},e)=>{let n=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(r){this[n]=r}}}),C.freezeMethods(fe);function Xn(t,e){const n=this||It,r=e||n,o=fe.from(r.headers);let s=r.data;return C.forEach(t,function(d){s=d.call(n,s,o.normalize(),e?e.status:void 0)}),o.normalize(),s}function _r(t){return!!(t&&t.__CANCEL__)}function ct(t,e,n){F.call(this,t??"canceled",F.ERR_CANCELED,e,n),this.name="CanceledError"}C.inherits(ct,F,{__CANCEL__:!0});function qr(t,e,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?t(n):e(new F("Request failed with status code "+n.status,[F.ERR_BAD_REQUEST,F.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function gc(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function yc(t,e){t=t||10;const n=new Array(t),r=new Array(t);let o=0,s=0,a;return e=e!==void 0?e:1e3,function(c){const u=Date.now(),h=r[s];a||(a=u),n[o]=c,r[o]=u;let f=s,m=0;for(;f!==o;)m+=n[f++],f=f%t;if(o=(o+1)%t,o===s&&(s=(s+1)%t),u-a<e)return;const g=h&&u-h;return g?Math.round(m*1e3/g):void 0}}function wc(t,e){let n=0,r=1e3/e,o,s;const a=(u,h=Date.now())=>{n=h,o=null,s&&(clearTimeout(s),s=null),t.apply(null,u)};return[(...u)=>{const h=Date.now(),f=h-n;f>=r?a(u,h):(o=u,s||(s=setTimeout(()=>{s=null,a(o)},r-f)))},()=>o&&a(o)]}const rn=(t,e,n=3)=>{let r=0;const o=yc(50,250);return wc(s=>{const a=s.loaded,d=s.lengthComputable?s.total:void 0,c=a-r,u=o(c),h=a<=d;r=a;const f={loaded:a,total:d,progress:d?a/d:void 0,bytes:c,rate:u||void 0,estimated:u&&d&&h?(d-a)/u:void 0,event:s,lengthComputable:d!=null,[e?"download":"upload"]:!0};t(f)},n)},Ur=(t,e)=>{const n=t!=null;return[r=>e[0]({lengthComputable:n,total:t,loaded:r}),e[1]]},Wr=t=>(...e)=>C.asap(()=>t(...e)),bc=he.hasStandardBrowserEnv?function(){const e=he.navigator&&/(msie|trident)/i.test(he.navigator.userAgent),n=document.createElement("a");let r;function o(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=o(window.location.href),function(a){const d=C.isString(a)?o(a):a;return d.protocol===r.protocol&&d.host===r.host}}():function(){return function(){return!0}}(),Cc=he.hasStandardBrowserEnv?{write(t,e,n,r,o,s){const a=[t+"="+encodeURIComponent(e)];C.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),C.isString(r)&&a.push("path="+r),C.isString(o)&&a.push("domain="+o),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 Sc(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function kc(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function Gr(t,e){return t&&!Sc(e)?kc(t,e):e}const jr=t=>t instanceof fe?{...t}:t;function Ye(t,e){e=e||{};const n={};function r(u,h,f){return C.isPlainObject(u)&&C.isPlainObject(h)?C.merge.call({caseless:f},u,h):C.isPlainObject(h)?C.merge({},h):C.isArray(h)?h.slice():h}function o(u,h,f){if(C.isUndefined(h)){if(!C.isUndefined(u))return r(void 0,u,f)}else return r(u,h,f)}function s(u,h){if(!C.isUndefined(h))return r(void 0,h)}function a(u,h){if(C.isUndefined(h)){if(!C.isUndefined(u))return r(void 0,u)}else return r(void 0,h)}function d(u,h,f){if(f in e)return r(u,h);if(f in t)return r(void 0,u)}const c={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:d,headers:(u,h)=>o(jr(u),jr(h),!0)};return C.forEach(Object.keys(Object.assign({},t,e)),function(h){const f=c[h]||o,m=f(t[h],e[h],h);C.isUndefined(m)&&f!==d||(n[h]=m)}),n}const Zr=t=>{const e=Ye({},t);let{data:n,withXSRFToken:r,xsrfHeaderName:o,xsrfCookieName:s,headers:a,auth:d}=e;e.headers=a=fe.from(a),e.url=Fr(Gr(e.baseURL,e.url),t.params,t.paramsSerializer),d&&a.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?unescape(encodeURIComponent(d.password)):"")));let c;if(C.isFormData(n)){if(he.hasStandardBrowserEnv||he.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((c=a.getContentType())!==!1){const[u,...h]=c?c.split(";").map(f=>f.trim()).filter(Boolean):[];a.setContentType([u||"multipart/form-data",...h].join("; "))}}if(he.hasStandardBrowserEnv&&(r&&C.isFunction(r)&&(r=r(e)),r||r!==!1&&bc(e.url))){const u=o&&s&&Cc.read(s);u&&a.set(o,u)}return e},Ec=typeof XMLHttpRequest<"u"&&function(t){return new Promise(function(n,r){const o=Zr(t);let s=o.data;const a=fe.from(o.headers).normalize();let{responseType:d,onUploadProgress:c,onDownloadProgress:u}=o,h,f,m,g,p;function k(){g&&g(),p&&p(),o.cancelToken&&o.cancelToken.unsubscribe(h),o.signal&&o.signal.removeEventListener("abort",h)}let w=new XMLHttpRequest;w.open(o.method.toUpperCase(),o.url,!0),w.timeout=o.timeout;function B(){if(!w)return;const L=fe.from("getAllResponseHeaders"in w&&w.getAllResponseHeaders()),T={data:!d||d==="text"||d==="json"?w.responseText:w.response,status:w.status,statusText:w.statusText,headers:L,config:t,request:w};qr(function(ve){n(ve),k()},function(ve){r(ve),k()},T),w=null}"onloadend"in w?w.onloadend=B:w.onreadystatechange=function(){!w||w.readyState!==4||w.status===0&&!(w.responseURL&&w.responseURL.indexOf("file:")===0)||setTimeout(B)},w.onabort=function(){w&&(r(new F("Request aborted",F.ECONNABORTED,t,w)),w=null)},w.onerror=function(){r(new F("Network Error",F.ERR_NETWORK,t,w)),w=null},w.ontimeout=function(){let V=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const T=o.transitional||Lr;o.timeoutErrorMessage&&(V=o.timeoutErrorMessage),r(new F(V,T.clarifyTimeoutError?F.ETIMEDOUT:F.ECONNABORTED,t,w)),w=null},s===void 0&&a.setContentType(null),"setRequestHeader"in w&&C.forEach(a.toJSON(),function(V,T){w.setRequestHeader(T,V)}),C.isUndefined(o.withCredentials)||(w.withCredentials=!!o.withCredentials),d&&d!=="json"&&(w.responseType=o.responseType),u&&([m,p]=rn(u,!0),w.addEventListener("progress",m)),c&&w.upload&&([f,g]=rn(c),w.upload.addEventListener("progress",f),w.upload.addEventListener("loadend",g)),(o.cancelToken||o.signal)&&(h=L=>{w&&(r(!L||L.type?new ct(null,t,w):L),w.abort(),w=null)},o.cancelToken&&o.cancelToken.subscribe(h),o.signal&&(o.signal.aborted?h():o.signal.addEventListener("abort",h)));const D=gc(o.url);if(D&&he.protocols.indexOf(D)===-1){r(new F("Unsupported protocol "+D+":",F.ERR_BAD_REQUEST,t));return}w.send(s||null)})},vc=(t,e)=>{const{length:n}=t=t?t.filter(Boolean):[];if(e||n){let r=new AbortController,o;const s=function(u){if(!o){o=!0,d();const h=u instanceof Error?u:this.reason;r.abort(h instanceof F?h:new ct(h instanceof Error?h.message:h))}};let a=e&&setTimeout(()=>{a=null,s(new F(`timeout ${e} of ms exceeded`,F.ETIMEDOUT))},e);const d=()=>{t&&(a&&clearTimeout(a),a=null,t.forEach(u=>{u.unsubscribe?u.unsubscribe(s):u.removeEventListener("abort",s)}),t=null)};t.forEach(u=>u.addEventListener("abort",s));const{signal:c}=r;return c.unsubscribe=()=>C.asap(d),c}},Mc=function*(t,e){let n=t.byteLength;if(n<e){yield t;return}let r=0,o;for(;r<n;)o=r+e,yield t.slice(r,o),r=o},xc=async function*(t,e){for await(const n of Bc(t))yield*Mc(n,e)},Bc=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()}},Jr=(t,e,n,r)=>{const o=xc(t,e);let s=0,a,d=c=>{a||(a=!0,r&&r(c))};return new ReadableStream({async pull(c){try{const{done:u,value:h}=await o.next();if(u){d(),c.close();return}let f=h.byteLength;if(n){let m=s+=f;n(m)}c.enqueue(new Uint8Array(h))}catch(u){throw d(u),u}},cancel(c){return d(c),o.return()}},{highWaterMark:2})},on=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",Xr=on&&typeof ReadableStream=="function",Ic=on&&(typeof TextEncoder=="function"?(t=>e=>t.encode(e))(new TextEncoder):async t=>new Uint8Array(await new Response(t).arrayBuffer())),Yr=(t,...e)=>{try{return!!t(...e)}catch{return!1}},Rc=Xr&&Yr(()=>{let t=!1;const e=new Request(he.origin,{body:new ReadableStream,method:"POST",get duplex(){return t=!0,"half"}}).headers.has("Content-Type");return t&&!e}),Qr=64*1024,Yn=Xr&&Yr(()=>C.isReadableStream(new Response("").body)),sn={stream:Yn&&(t=>t.body)};on&&(t=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!sn[e]&&(sn[e]=C.isFunction(t[e])?n=>n[e]():(n,r)=>{throw new F(`Response type '${e}' is not supported`,F.ERR_NOT_SUPPORT,r)})})})(new Response);const $c=async t=>{if(t==null)return 0;if(C.isBlob(t))return t.size;if(C.isSpecCompliantForm(t))return(await new Request(he.origin,{method:"POST",body:t}).arrayBuffer()).byteLength;if(C.isArrayBufferView(t)||C.isArrayBuffer(t))return t.byteLength;if(C.isURLSearchParams(t)&&(t=t+""),C.isString(t))return(await Ic(t)).byteLength},Nc=async(t,e)=>{const n=C.toFiniteNumber(t.getContentLength());return n??$c(e)},Qn={http:Ql,xhr:Ec,fetch:on&&(async t=>{let{url:e,method:n,data:r,signal:o,cancelToken:s,timeout:a,onDownloadProgress:d,onUploadProgress:c,responseType:u,headers:h,withCredentials:f="same-origin",fetchOptions:m}=Zr(t);u=u?(u+"").toLowerCase():"text";let g=vc([o,s&&s.toAbortSignal()],a),p;const k=g&&g.unsubscribe&&(()=>{g.unsubscribe()});let w;try{if(c&&Rc&&n!=="get"&&n!=="head"&&(w=await Nc(h,r))!==0){let T=new Request(e,{method:"POST",body:r,duplex:"half"}),be;if(C.isFormData(r)&&(be=T.headers.get("content-type"))&&h.setContentType(be),T.body){const[ve,Ze]=Ur(w,rn(Wr(c)));r=Jr(T.body,Qr,ve,Ze)}}C.isString(f)||(f=f?"include":"omit");const B="credentials"in Request.prototype;p=new Request(e,{...m,signal:g,method:n.toUpperCase(),headers:h.normalize().toJSON(),body:r,duplex:"half",credentials:B?f:void 0});let D=await fetch(p);const L=Yn&&(u==="stream"||u==="response");if(Yn&&(d||L&&k)){const T={};["status","statusText","headers"].forEach(St=>{T[St]=D[St]});const be=C.toFiniteNumber(D.headers.get("content-length")),[ve,Ze]=d&&Ur(be,rn(Wr(d),!0))||[];D=new Response(Jr(D.body,Qr,ve,()=>{Ze&&Ze(),k&&k()}),T)}u=u||"text";let V=await sn[C.findKey(sn,u)||"text"](D,t);return!L&&k&&k(),await new Promise((T,be)=>{qr(T,be,{data:V,headers:fe.from(D.headers),status:D.status,statusText:D.statusText,config:t,request:p})})}catch(B){throw k&&k(),B&&B.name==="TypeError"&&/fetch/i.test(B.message)?Object.assign(new F("Network Error",F.ERR_NETWORK,t,p),{cause:B.cause||B}):F.from(B,B&&B.code,t,p)}})};C.forEach(Qn,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const Kr=t=>`- ${t}`,Ac=t=>C.isFunction(t)||t===null||t===!1,eo={getAdapter:t=>{t=C.isArray(t)?t:[t];const{length:e}=t;let n,r;const o={};for(let s=0;s<e;s++){n=t[s];let a;if(r=n,!Ac(n)&&(r=Qn[(a=String(n)).toLowerCase()],r===void 0))throw new F(`Unknown adapter '${a}'`);if(r)break;o[a||"#"+s]=r}if(!r){const s=Object.entries(o).map(([d,c])=>`adapter ${d} `+(c===!1?"is not supported by the environment":"is not available in the build"));let a=e?s.length>1?`since :
21
+ `+s.map(Kr).join(`
22
+ `):" "+Kr(s[0]):"as no adapter specified";throw new F("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return r},adapters:Qn};function Kn(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new ct(null,t)}function to(t){return Kn(t),t.headers=fe.from(t.headers),t.data=Xn.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),eo.getAdapter(t.adapter||It.adapter)(t).then(function(r){return Kn(t),r.data=Xn.call(t,t.transformResponse,r),r.headers=fe.from(r.headers),r},function(r){return _r(r)||(Kn(t),r&&r.response&&(r.response.data=Xn.call(t,t.transformResponse,r.response),r.response.headers=fe.from(r.response.headers))),Promise.reject(r)})}const no="1.7.7",ei={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{ei[t]=function(r){return typeof r===t||"a"+(e<1?"n ":" ")+t}});const io={};ei.transitional=function(e,n,r){function o(s,a){return"[Axios v"+no+"] Transitional option '"+s+"'"+a+(r?". "+r:"")}return(s,a,d)=>{if(e===!1)throw new F(o(a," has been removed"+(n?" in "+n:"")),F.ERR_DEPRECATED);return n&&!io[a]&&(io[a]=!0,console.warn(o(a," has been deprecated since v"+n+" and will be removed in the near future"))),e?e(s,a,d):!0}};function Pc(t,e,n){if(typeof t!="object")throw new F("options must be an object",F.ERR_BAD_OPTION_VALUE);const r=Object.keys(t);let o=r.length;for(;o-- >0;){const s=r[o],a=e[s];if(a){const d=t[s],c=d===void 0||a(d,s,t);if(c!==!0)throw new F("option "+s+" must be "+c,F.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new F("Unknown option "+s,F.ERR_BAD_OPTION)}}const ti={assertOptions:Pc,validators:ei},Ge=ti.validators;class Qe{constructor(e){this.defaults=e,this.interceptors={request:new Dr,response:new Dr}}async request(e,n){try{return await this._request(e,n)}catch(r){if(r instanceof Error){let o;Error.captureStackTrace?Error.captureStackTrace(o={}):o=new Error;const s=o.stack?o.stack.replace(/^.+\n/,""):"";try{r.stack?s&&!String(r.stack).endsWith(s.replace(/^.+\n.+\n/,""))&&(r.stack+=`
23
+ `+s):r.stack=s}catch{}}throw r}}_request(e,n){typeof e=="string"?(n=n||{},n.url=e):n=e||{},n=Ye(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:s}=n;r!==void 0&&ti.assertOptions(r,{silentJSONParsing:Ge.transitional(Ge.boolean),forcedJSONParsing:Ge.transitional(Ge.boolean),clarifyTimeoutError:Ge.transitional(Ge.boolean)},!1),o!=null&&(C.isFunction(o)?n.paramsSerializer={serialize:o}:ti.assertOptions(o,{encode:Ge.function,serialize:Ge.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let a=s&&C.merge(s.common,s[n.method]);s&&C.forEach(["delete","get","head","post","put","patch","common"],p=>{delete s[p]}),n.headers=fe.concat(a,s);const d=[];let c=!0;this.interceptors.request.forEach(function(k){typeof k.runWhen=="function"&&k.runWhen(n)===!1||(c=c&&k.synchronous,d.unshift(k.fulfilled,k.rejected))});const u=[];this.interceptors.response.forEach(function(k){u.push(k.fulfilled,k.rejected)});let h,f=0,m;if(!c){const p=[to.bind(this),void 0];for(p.unshift.apply(p,d),p.push.apply(p,u),m=p.length,h=Promise.resolve(n);f<m;)h=h.then(p[f++],p[f++]);return h}m=d.length;let g=n;for(f=0;f<m;){const p=d[f++],k=d[f++];try{g=p(g)}catch(w){k.call(this,w);break}}try{h=to.call(this,g)}catch(p){return Promise.reject(p)}for(f=0,m=u.length;f<m;)h=h.then(u[f++],u[f++]);return h}getUri(e){e=Ye(this.defaults,e);const n=Gr(e.baseURL,e.url);return Fr(n,e.params,e.paramsSerializer)}}C.forEach(["delete","get","head","options"],function(e){Qe.prototype[e]=function(n,r){return this.request(Ye(r||{},{method:e,url:n,data:(r||{}).data}))}}),C.forEach(["post","put","patch"],function(e){function n(r){return function(s,a,d){return this.request(Ye(d||{},{method:e,headers:r?{"Content-Type":"multipart/form-data"}:{},url:s,data:a}))}}Qe.prototype[e]=n(),Qe.prototype[e+"Form"]=n(!0)});class ni{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(o=>{if(!r._listeners)return;let s=r._listeners.length;for(;s-- >0;)r._listeners[s](o);r._listeners=null}),this.promise.then=o=>{let s;const a=new Promise(d=>{r.subscribe(d),s=d}).then(o);return a.cancel=function(){r.unsubscribe(s)},a},e(function(s,a,d){r.reason||(r.reason=new ct(s,a,d),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 ni(function(o){e=o}),cancel:e}}}function Tc(t){return function(n){return t.apply(null,n)}}function zc(t){return C.isObject(t)&&t.isAxiosError===!0}const ii={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(ii).forEach(([t,e])=>{ii[e]=t});function ro(t){const e=new Qe(t),n=Sr(Qe.prototype.request,e);return C.extend(n,Qe.prototype,e,{allOwnKeys:!0}),C.extend(n,e,null,{allOwnKeys:!0}),n.create=function(o){return ro(Ye(t,o))},n}const Y=ro(It);Y.Axios=Qe,Y.CanceledError=ct,Y.CancelToken=ni,Y.isCancel=_r,Y.VERSION=no,Y.toFormData=tn,Y.AxiosError=F,Y.Cancel=Y.CanceledError,Y.all=function(e){return Promise.all(e)},Y.spread=Tc,Y.isAxiosError=zc,Y.mergeConfig=Ye,Y.AxiosHeaders=fe,Y.formToJSON=t=>Or(C.isHTMLForm(t)?new FormData(t):t),Y.getAdapter=eo.getAdapter,Y.HttpStatusCode=ii,Y.default=Y;var $t=(t=>(t.GET="get",t.POST="post",t.PUT="put",t.DELETE="delete",t))($t||{});const Nt=(()=>{function t(){const c=o();return!(!c||c==="undefined")}function e(c){c.accessToken&&localStorage.setItem("access_token",c.accessToken),c.refreshToken&&localStorage.setItem("refresh_token",c.refreshToken)}function n(){const c=localStorage.getItem("user");return c?JSON.parse(c).id:""}function r(){const c=localStorage.getItem("user");if(c)return JSON.parse(c)}function o(){return localStorage.getItem("access_token")}function s(){return localStorage.getItem("refresh_token")}function a(){localStorage.removeItem("access_token"),localStorage.removeItem("refresh_token")}function d(c){if(!t())return;const u=Nt.getUser();u&&(u.human=c,localStorage.setItem("user",JSON.stringify(u)))}return{isAuth:t,setTokens:e,getAccessToken:o,getRefreshToken:s,getUserId:n,clearTokens:a,getUser:r,updateHuman:d}})();class ri{constructor(e){l(this,"code",400);l(this,"err","");Classes.BuildClass(this,e)}getErr(){return this.capitalizedErr()}capitalizedErr(){return this.err.charAt(0).toUpperCase()+this.err.slice(1)}static async Handle(e,n){const r=e.config;if(e.response){if(e.response.status===401&&!r._retry)return r._retry=!0,n.defaults.headers.common.token=Nt.getAccessToken(),e.config.headers.token=Nt.getAccessToken(),e.config.baseURL=void 0,n.request(r);if(e.response.status>=500){if(e.response.data==="неверный логин или пароль"){Notification.Error("Неверный логин или пароль");return}Notification.Error("Ошибка на сервере, попробуйте позже")}if(e.response.status>=400&&e.response.status<500){const o=new ri(e.response.data).getErr();o&&Notification.Error(o)}return Promise.reject(e)}}}const dt=Y.create();dt.interceptors.response.use(t=>t,async t=>await ri.Handle(t,dt));class At{static async Get(e,n,r){return await dt({method:$t.GET,url:e,headers:n,responseType:r})}static async Post(e,n,r,o){return n["Content-Type"]="multipart/form-data",await dt({method:$t.POST,url:e,headers:n,responseType:r,data:o})}static async Put(e,n,r){return n["Content-Type"]="multipart/form-data",await dt({method:$t.PUT,url:e,headers:n,data:r})}static async Delete(e,n){return await dt({method:$t.DELETE,url:e,headers:n})}}let Vc=class va{constructor(e){l(this,"name","");Classes.BuildClass(this,e)}static Set(){}static Get(e,n){const r=sessionStorage.getItem(e);if(r){const o=JSON.parse(r),s=new Date,a=new Date(o.time),d=s.getTime()-a.getTime();return Math.round(d/6e4)>(n||10)?null:o.data}else return null}static async TryGet(e,n,r){let o;return o=va.Get(e,r),o||(o=await n()),o}};var oi=(t=>(t.ContentType="Content-Type",t.Token="token",t))(oi||{}),oo=(t=>(t.ApplicationJson="application/json",t.MultipartFormData="multipart/form-data",t))(oo||{});const G=class G{static Setup(e,n,r){this.baseUrl=e,this.apiVersion=n,this.apiHost=r}static newWebSocket(e){const n=this.apiHost.replace("http","ws")+"/ws/"+e;return new WebSocket(n)}static download(e,n){const r=G.getDownloadFileName(e,n.headers),o=URL.createObjectURL(n.data),s=document.createElement("a");s.href=o,s.setAttribute("download",r),s.setAttribute("target","_blank"),document.body.appendChild(s),s.click()}static getDownloadFileName(e,n){if(e)return e;const r=n["content-disposition"],o=r.indexOf('"')+1,s=r.lastIndexOf('"'),a=r.substring(o,s);return a||"file"}static getHeaders(e){const n=xe.Get(Ce.AccessToken);return e||(e=G.headers),n&&(e[oi.Token]=n),e??G.headers}static returnResponse(e,n){if(n)return e!=null&&e.isBlob?G.download(e.downloadFileName,n):n.data}static async Get(e){return G.returnResponse(e,await At.Get(G.buildUrl((e==null?void 0:e.query)??""),G.getHeaders(e==null?void 0:e.headers),G.getResponseType(e==null?void 0:e.isBlob)))}static async Post(e){return G.returnResponse(e,await At.Post(G.buildUrl(e==null?void 0:e.query),G.getHeaders(e==null?void 0:e.headers),G.getResponseType(e.isBlob),G.createFormDataPayload(e==null?void 0:e.payload,e==null?void 0:e.fileInfos)))}static async Put(e){return G.returnResponse(e,await At.Put(G.buildUrl(e==null?void 0:e.query),G.getHeaders(e==null?void 0:e.headers),G.createFormDataPayload(e==null?void 0:e.payload,e==null?void 0:e.fileInfos)))}static async Delete(e){return G.returnResponse(e,await At.Delete(G.buildUrl(e==null?void 0:e.query),G.getHeaders(e==null?void 0:e.headers)))}static async Subscribe(e){const{query:n}=e;return new EventSource(G.buildUrl(n))}static buildUrl(e){const n=e??"";return this.baseUrl+this.apiVersion+n}static getResponseType(e){return e?"blob":"json"}static createFormDataPayload(e,n){const r=new FormData;if(r.append("form",JSON.stringify(e)),n)for(const o of n)o.file&&r.append(o.id??"files",o.file,o.originalName);return r}};l(G,"baseUrl",""),l(G,"apiVersion",""),l(G,"apiHost",""),l(G,"headers",{[oi.ContentType]:oo.ApplicationJson});let oe=G;class te{constructor(e,n){l(this,"items",i.reactive([]));l(this,"item");l(this,"count",i.ref(0));l(this,"classConstructor");l(this,"url","");this.classConstructor=e,this.item=i.reactive(new this.classConstructor),this.url=n}Set(e){Object.assign(this.item,new this.classConstructor(e))}Item(){return this.item}getUrl(e){return e?`${this.url}/${e}`:this.url}async GetAll(e){let n;const r=oe.Get;e&&e.withCache?n=await Vc.TryGet(this.getUrl(),r):n=await r({query:this.getUrl()}),Array.isArray(n)?this.SetAll(n):this.SetAllWithCount(n)}async Get(e){e||(e=Router.Id()),this.Set(await oe.Get({query:this.getUrl(e)}))}async FTSP(e){var a;const r=((e==null?void 0:e.ftsp)??fr.Get()).clearForHTTP(),o={payload:{ftsp:r},query:this.getUrl("ftsp")},s=await oe.Post(o);if(!(!s||!s.ftsp))if(Array.isArray(s.data))this.SetAll(s.data);else{if(r.p.append){this.AppendToAll((a=s.data)==null?void 0:a.items);return}this.SetAllWithCount(s.data)}}async Create(e){const n=e??this.item,r={payload:n,query:this.getUrl()};return n.getFileInfos&&(r.fileInfos=n.getFileInfos(),r.fileInfos.forEach(o=>o.url="")),await oe.Post(r)}async CreateAndSet(e){const n=await this.Create(e);this.Set(n)}async CreateMany(e){if(!e)return;const n=[];e.forEach(r=>{n.push(new Promise(()=>this.Create(r)))}),Promise.all(n)}async Update(e){const n=e??this.item,r={query:this.getUrl(`${n.id}`),payload:n};return n.getFileInfos&&(r.fileInfos=n.getFileInfos(),r.fileInfos.forEach(o=>o.url="")),await oe.Put(r)}async UpdateAndSet(e){const n=await this.Update(e);this.Set(n)}async UpdateAndReset(e){await this.Update(e??this.item),this.Set()}async Remove(e){if(!e){console.warn("BaseStore/Remove. id is undefined");return}await oe.Delete({query:this.getUrl(`${e}`)}),this.RemoveItem(e)}async UpdateMany(e){if(e||(e=this.items),!e)return;const n=[];e.forEach(r=>{n.push(new Promise(()=>this.Update(r)))}),Promise.all(n)}SetAll(e){e&&(this.items.splice(0,this.items.length),this.items.push(...e.map(n=>new this.classConstructor(n))))}SetAllWithCount(e){e&&(this.SetAll(e.items),this.count.value=e.count)}RemoveItem(e){const n=this.items.findIndex(r=>r.id===e);this.items.splice(n,1)}AppendToAll(e){if(!e)return;const n=e.map(r=>new this.classConstructor(r));this.items.push(...n)}ResetState(){this.ResetItem(),this.ClearItems(),this.count.value=0}ResetItem(){Classes.BuildClass(this.item,new this.classConstructor)}ClearItems(){this.items.splice(0,this.items.length)}UnshiftToAll(e){this.items.unshift(new this.classConstructor(e))}Items(){return this.items}Count(){return this.count}}class Fc{constructor(e){l(this,"name","");Classes.BuildClass(this,e)}cache(){}getFromCache(e){const n=sessionStorage.getItem(this.name);if(n){const r=JSON.parse(n),o=new Date,s=new Date(r.time),a=o.getTime()-s.getTime();return Math.round(a/6e4)>(e||10)?null:r.data}else return null}async storeGetWithCache(e,n){let r;return r=this.getFromCache(n),r||(r=await e(),r&&this.cache()),r}}function Dc(t,e){t=="left"&&e.next(),t=="right"&&e.prev()}const Lc=["#31af5e","#ff4d3b","#006BB5","#f3911c"];class Oc{static GetRandColor(e){return We.GetRandEL(e??Lc)}}class si{static Get(e,n,r="-"){return!e||!n?"":`${e}${r}${n}`}static In(e,n,r){return e>=n&&e<=r}static Intersects(e,n,r,o){return e===r||n===o||e>r&&e<o||n>r&&n<o||n>o&&e<r}}const so=1e3,ao=60*so,ai=60*ao;var Pt=(t=>(t.FiveMinutes="5",t.HourQuarter="15",t.HourHalf="30",t.Hour="60",t))(Pt||{});const an={5:["00","05","10","15","20","25","30","35","40","45","50","55"],15:["00","15","30","45"],30:["00","30"],60:["00"]};class O{static S(e){return so*e}static M(e){return ao*e}static H(e){return ai*e}static D(e){return ai*e}static W(e){return ai*e}static NormalizeTime(e){return String(e).padStart(2,"0")}static HMtoM(e){const n=O.SplitHM(e);return n.length>1?O.HtoM(n[0])+n[1]:O.HtoM(n[0])}static HtoM(e){return Number(e)*60}static SplitHM(e){if(!e)return[];const n=e.split(":");return[Number(n[0]),Number(n[1])]}static HmsToHm(e){const n=O.SplitHM(e);return O.ConcatHM(n[0],n[1])}static AddMtoHM(e,n){const r=new Date,o=O.SplitHM(e);r.setHours(o[0],o[1],0,0);const s=new Date(r.getTime()+n*6e4),a=s.getHours(),d=s.getMinutes();return O.ConcatHM(a,d)}static ConcatHM(e,n){return`${e}:${O.NormalizeTime(n)}`}static DiffM(e,n){return O.Gt(n,e)?O.HMtoM(n)-O.HMtoM(e):O.HMtoM(e)-O.HMtoM(n)}static GetPeriod(e,n){return si.Get(e,n)}static Gt(e,n){return O.HMtoM(e)>O.HMtoM(n)}static GtOrEq(e,n){return O.Gt(e,n)||O.Eq(e,n)}static Eq(e,n){return O.HMtoM(e)===O.HMtoM(n)}static PeriodInPeriod(e,n,r,o){return O.HMtoM(e)>=O.HMtoM(r)&&O.HMtoM(n)<=O.HMtoM(o)}static PeriodsIntersects(e,n,r,o){return si.Intersects(O.HMtoM(e),O.HMtoM(n),O.HMtoM(r),O.HMtoM(o))}}let Hc=class{constructor(){l(this,"startHour",9);l(this,"endHour",19);l(this,"timelinePxHeight",50);l(this,"timelineStep",Pt.FiveMinutes);l(this,"activeTime","");l(this,"activeObjectId","");l(this,"dragged",!1);l(this,"draggedStartTime","");l(this,"draggedEndTime","");l(this,"timelines",an[Pt.FiveMinutes])}startDrag(e,n){this.draggedStartTime=e,this.draggedEndTime=n,this.dragged=!0}endDrag(){this.activeTime="",this.dragged=!1}setTimelineStep(e){this.timelineStep=e,this.setTimelines()}setTimelines(){this.timelines=an[this.timelineStep]}getScheduleHeight(){return this.getHourHeight()*this.getHoursArr().length}getHourHeight(){return this.timelinePxHeight*this.timelines.length}getHoursArr(){return We.GenerateNumsRange(this.startHour,this.endHour)}};const li=t=>t===8||t===46,_c=t=>t>46&&t<58,qc=t=>t>34&&t<41,Uc=t=>t+".",Wc=(t,e,n)=>{li(e)||qc(e)||(!_c(e)||n>9)&&t.preventDefault()};function Gc(t,e){if(e>8){let n=t.substring(0,2).replace(".","1");Number(n)>31&&(n="31");let r=t.substring(3,5).replace(".","1");Number(r)>12&&(r="12");let o=t.substring(6,10).replace(".","1");Number(o)>2100&&(o="2100"),t=n+"."+r+"."+o}return t}function jc(t){const e=t.keyCode;let n=t.srcElement.value;const r=n.length;Wc(t,e,r),!li(e)&&(r===2||r===5)&&(n=Uc(n));const o=t.srcElement.value+String.fromCharCode(t.which);if(li(e)){t.srcElement.value=n;return}n.length===0&&Number(o)>3&&(n="3",t.preventDefault()),n.length===1&&Number(o)>31&&(n="31",t.preventDefault()),o.length===5&&Number(o.substring(3,5))>12&&(n=n.substring(0,3)+"12",t.preventDefault()),n=Gc(n,r),t.srcElement.value=n}const Zc=["ВС","ПН","ВТ","СР","ЧТ","ПТ","СБ"],Jc="ru-RU";class Le{constructor(){l(this,"locale","ru-RU")}static Format(e,n){if(!e)return"";const r={year:"numeric",month:"2-digit",day:"2-digit",hour:void 0,minute:void 0};return n&&(r.year=n.year||n.year===void 0?n.year:r.year,r.month=n.month||n.month===void 0?n.month:r.month,r.day=n.day||n.day===void 0?n.day:r.day,r.hour=n.hour??r.hour,r.minute=n.minute??r.minute),Intl.DateTimeFormat(Jc,r).format(new Date(e))}static FromRuStr(e){const n=e.split(".");return new Date(`${n[2]}-${n[1]}-${n[0]}`)}static GetPeriod(e,n,r){return`${this.Format(e,r)}-${this.Format(n,r)}`}static GetShortDayName(e){return e?Zc[e.getDay()]:""}static GetCurrentWeekPeriod(e){const n=new Date,r=new Date(n.getFullYear(),n.getMonth(),n.getDate()-n.getDay()+1),o=new Date(n.getFullYear(),n.getMonth(),r.getDate()+7);return this.GetPeriod(r,o,e||{month:"2-digit",day:"numeric",year:void 0})}static GetDurationInDay(e,n){const r=new Date,o=new Date,s=Le.SplitHourTime(e),a=Le.SplitHourTime(n);return r.setHours(s[0],s[1],0,0),o.setHours(a[0],a[1],0,0),(o.getTime()-r.getTime())/1e3/60}static HourTimeinMunutes(e){const n=Le.SplitHourTime(e);return n[0]*60+n[1]}static SplitHourTime(e){const n=e.split(":");return[Number(n[0]),Number(n[1])]}static AddMinutesToHM(e,n){const r=new Date,o=Le.SplitHourTime(e);r.setHours(o[0],o[1],0,0);const s=new Date(r.getTime()+n*6e4),a=s.getHours(),d=s.getMinutes();return`${a}:${d}`}static GetMonthsDiff(e,n){return n.getMonth()-e.getMonth()+12*(n.getFullYear()-e.getFullYear())}static StringToDate(e){const n=e.split(".");return new Date(`${n[2]}-${n[1]}-${n[0]}`)}static GetDateOrToday(e){return e?e.date:new Date}static InPeriod(e,n,r){return new Date(e)>=new Date(n)&&new Date(e)<=new Date(r)}static GetDatesFromPeriod(e,n){const r=[new Date(e)];let o=e;for(;o<=n;)o=Le.AddDays(o,1),r.push(o);return r}static AddDays(e,n){const r=new Date(e);return r.setDate(r.getDate()+n),r}static Eq(e,n){return e.getTime()===n.getTime()}}class Xc{constructor(){l(this,"dragged",!1);l(this,"dragImg",new Image);this.dragImg.src="data:image/gif;base64,R0lGODlhAQABAIAAAAUEBAAAACwAAAAAAQABAAACAkQBADs="}start(e){this.dragged=!0,e&&e.dataTransfer&&e.dataTransfer.setDragImage(this.dragImg,0,0)}end(){this.dragged=!1}isDragged(){return this.dragged}}class Yc{static Get(e){const n=e.split(".");return n[n.length-1]}}const Qc=(()=>{function t(s,a){localStorage.setItem(`${s}_favourite`,a.toString())}function e(s,a){const d=localStorage.getItem(`${s}_favourite`);return d?d.split(",").includes(a):!1}function n(s,a){const d=localStorage.getItem(`${s}_favourite`);if(!d){t(s,[a]);return}const c=d.split(",");c.push(a),t(s,c)}function r(s,a){const d=localStorage.getItem(`${s}_favourite`);if(!d)return;const c=d.split(",").filter(u=>u!==a);t(s,c)}function o(){for(const s in localStorage)s.includes("_favourite")&&localStorage.removeItem(s)}return{addToFavourite:n,removeFromFavourite:r,setFavourite:t,isFavourite:e,clearFavourite:o}})();function lo(t,e){const n=[];if(t)for(let r=0;r<Math.ceil(t.length/e);r++)n[r]=t.slice(r*e,r*e+e);return n}const $n=class $n{static Format(e){let n=e;if(!n)e=n;else{(n[0]==="7"||n[0]==="8")&&n.length!==1&&(n=n.slice(1));const r=n.replace(/\+7|[^\d]/g,""),o=r.length;switch(!0){case o===0:e="";break;case(o===1&&n.length===1&&r==="7"):case(o===1&&n.length===1&&r==="8"):e="+7 (";break;case o<4:e=`+7 (${r}`;break;case o<7:e=`+7 (${r.slice(0,3)}) ${r.slice(3)}`;break;case o<9:e=`+7 (${r.slice(0,3)}) ${r.slice(3,6)}-${r.slice(6,8)}`;break;default:e=`+7 (${r.slice(0,3)}) ${r.slice(3,6)}-${r.slice(6,8)}-${r.slice(8,10)}`;break}}return e}static getPhoneRegExp(){return/^(\s*)?(\+)?([- _():=+]?\d[- _():=+]?){10,14}(\s*)?$/}};l($n,"validatePhone",(e,n,r)=>{$n.getPhoneRegExp().test(n)||!n?r():r(new Error("Пожалуйста, введите корректный номер телефона"))});let ci=$n;class Kc{static Count(e){const n=e.filter(s=>s.rating!==0);let r=0;n.forEach(s=>r=r+s.rating);const o=r/n.length;return isNaN(o)?0:Number((r/n.length).toFixed(2))}}const ed="p-button",td=i.defineComponent({inheritAttrs:!1,__name:"PButton",props:{text:{type:String,default:"",required:!1},margin:{type:String,default:"",required:!1},padding:{type:String,default:"",required:!1},width:{type:String,default:"",required:!1},height:{type:String,default:"",required:!1},skin:{type:String,default:"base",required:!1},size:{type:String,default:Hn.M,required:!1},type:{type:String,default:le.Primary,required:!1},fontSize:{type:String,default:"",required:!1}},emits:["click"],setup(t,{emit:e}){const n=t,r=e,o=()=>{r("click")},s=i.computed(()=>S.H.Strings.JoinSnake(ed,n.skin)),a=i.computed(()=>S.H.Strings.JoinSnake(s.value,n.type)),d=i.computed(()=>S.H.Strings.JoinSnake(s.value,n.size)),c=i.computed(()=>[s.value,a.value,d.value]);return(u,h)=>(i.openBlock(),i.createElementBlock("button",i.mergeProps(u.$attrs,{style:{margin:t.margin,padding:t.padding,maxWidth:t.width,minWidth:t.width,minHeight:t.height,maxHeight:t.height,fontSize:t.fontSize},class:i.unref(c),onClick:i.withModifiers(o,["prevent"])}),[i.renderSlot(u.$slots,"default",{},void 0,!0),i.createTextVNode(" "+i.toDisplayString(t.text),1)],16))}}),Se=M(td,[["__scopeId","data-v-4aae85d5"]]);var nd=Object.defineProperty,id=(t,e,n)=>e in t?nd(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,ln=(t,e,n)=>id(t,typeof e!="symbol"?e+"":e,n);const co={"#":{pattern:/[0-9]/},"@":{pattern:/[a-zA-Z]/},"*":{pattern:/[a-zA-Z0-9]/}},uo=(t,e,n)=>t.replaceAll(e,"").replace(n,".").replace("..",".").replace(/[^.\d]/g,""),ho=(t,e,n)=>{var r;return new Intl.NumberFormat(((r=n.number)==null?void 0:r.locale)??"en",{minimumFractionDigits:t,maximumFractionDigits:e,roundingMode:"trunc"})},rd=(t,e=!0,n)=>{var r,o,s,a;const d=((r=n.number)==null?void 0:r.unsigned)==null&&t.startsWith("-")?"-":"",c=((o=n.number)==null?void 0:o.fraction)??0;let u=ho(0,c,n);const h=u.formatToParts(1000.12),f=((s=h.find(w=>w.type==="group"))==null?void 0:s.value)??" ",m=((a=h.find(w=>w.type==="decimal"))==null?void 0:a.value)??".",g=uo(t,f,m);if(Number.isNaN(parseFloat(g)))return d;const p=g.split(".");if(p[1]!=null&&p[1].length>=1){const w=p[1].length<=c?p[1].length:c;u=ho(w,c,n)}let k=u.format(parseFloat(g));return e?c>0&&g.endsWith(".")&&!g.slice(0,-1).includes(".")&&(k+=m):k=uo(k,f,m),d+k};let od=class{constructor(e={}){ln(this,"opts",{}),ln(this,"memo",new Map);const n={...e};if(n.tokens!=null){n.tokens=n.tokensReplace?{...n.tokens}:{...co,...n.tokens};for(const r of Object.values(n.tokens))typeof r.pattern=="string"&&(r.pattern=new RegExp(r.pattern))}else n.tokens=co;Array.isArray(n.mask)&&(n.mask.length>1?n.mask=[...n.mask].sort((r,o)=>r.length-o.length):n.mask=n.mask[0]??""),n.mask===""&&(n.mask=null),this.opts=n}masked(e){return this.process(e,this.findMask(e))}unmasked(e){return this.process(e,this.findMask(e),!1)}isEager(){return this.opts.eager===!0}isReversed(){return this.opts.reversed===!0}completed(e){const n=this.findMask(e);if(this.opts.mask==null||n==null)return!1;const r=this.process(e,n).length;return typeof this.opts.mask=="string"?r>=this.opts.mask.length:r>=n.length}findMask(e){const n=this.opts.mask;if(n==null)return null;if(typeof n=="string")return n;if(typeof n=="function")return n(e);const r=this.process(e,n.slice(-1).pop()??"",!1);return n.find(o=>this.process(e,o,!1).length>=r.length)??""}escapeMask(e){const n=[],r=[];return e.split("").forEach((o,s)=>{o==="!"&&e[s-1]!=="!"?r.push(s-r.length):n.push(o)}),{mask:n.join(""),escaped:r}}process(e,n,r=!0){if(this.opts.number!=null)return rd(e,r,this.opts);if(n==null)return e;const o=`v=${e},mr=${n},m=${r?1:0}`;if(this.memo.has(o))return this.memo.get(o);const{mask:s,escaped:a}=this.escapeMask(n),d=[],c=this.opts.tokens!=null?this.opts.tokens:{},u=this.isReversed()?-1:1,h=this.isReversed()?"unshift":"push",f=this.isReversed()?0:s.length-1,m=this.isReversed()?()=>w>-1&&B>-1:()=>w<s.length&&B<e.length,g=L=>!this.isReversed()&&L<=f||this.isReversed()&&L>=f;let p,k=-1,w=this.isReversed()?s.length-1:0,B=this.isReversed()?e.length-1:0,D=!1;for(;m();){const L=s.charAt(w),V=c[L],T=(V==null?void 0:V.transform)!=null?V.transform(e.charAt(B)):e.charAt(B);if(!a.includes(w)&&V!=null?(T.match(V.pattern)!=null?(d[h](T),V.repeated?(k===-1?k=w:w===f&&w!==k&&(w=k-u),f===k&&(w-=u)):V.multiple&&(D=!0,w-=u),w+=u):V.multiple?D&&(w+=u,B-=u,D=!1):T===p?p=void 0:V.optional&&(w+=u,B-=u),B+=u):(r&&!this.isEager()&&d[h](L),T===L&&!this.isEager()?B+=u:p=L,this.isEager()||(w+=u)),this.isEager())for(;g(w)&&(c[s.charAt(w)]==null||a.includes(w));){if(r){if(d[h](s.charAt(w)),e.charAt(B)===s.charAt(w)){w+=u,B+=u;continue}}else s.charAt(w)===e.charAt(B)&&(B+=u);w+=u}}return this.memo.set(o,d.join("")),this.memo.get(o)}};const fo=t=>JSON.parse(t.replaceAll("'",'"')),sd=(t,e={})=>{const n={...e};t.dataset.maska!=null&&t.dataset.maska!==""&&(n.mask=ad(t.dataset.maska)),t.dataset.maskaEager!=null&&(n.eager=cn(t.dataset.maskaEager)),t.dataset.maskaReversed!=null&&(n.reversed=cn(t.dataset.maskaReversed)),t.dataset.maskaTokensReplace!=null&&(n.tokensReplace=cn(t.dataset.maskaTokensReplace)),t.dataset.maskaTokens!=null&&(n.tokens=ld(t.dataset.maskaTokens));const r={};return t.dataset.maskaNumberLocale!=null&&(r.locale=t.dataset.maskaNumberLocale),t.dataset.maskaNumberFraction!=null&&(r.fraction=parseInt(t.dataset.maskaNumberFraction)),t.dataset.maskaNumberUnsigned!=null&&(r.unsigned=cn(t.dataset.maskaNumberUnsigned)),(t.dataset.maskaNumber!=null||Object.values(r).length>0)&&(n.number=r),n},cn=t=>t!==""?!!JSON.parse(t):!0,ad=t=>t.startsWith("[")&&t.endsWith("]")?fo(t):t,ld=t=>{if(t.startsWith("{")&&t.endsWith("}"))return fo(t);const e={};return t.split("|").forEach(n=>{const r=n.split(":");e[r[0]]={pattern:new RegExp(r[1]),optional:r[2]==="optional",multiple:r[2]==="multiple",repeated:r[2]==="repeated"}}),e};let cd=class{constructor(e,n={}){ln(this,"items",new Map),ln(this,"onInput",r=>{if(r instanceof CustomEvent&&r.type==="input"&&!r.isTrusted&&!r.bubbles)return;const o=r.target,s=this.items.get(o),a="inputType"in r&&r.inputType.startsWith("delete"),d=s.isEager(),c=a&&d&&s.unmasked(o.value)===""?"":o.value;this.fixCursor(o,a,()=>this.setValue(o,c))}),this.options=n,this.init(this.getInputs(e))}update(e={}){this.options={...e},this.init(Array.from(this.items.keys()))}updateValue(e){e.value!==""&&e.value!==this.processInput(e).masked&&this.setValue(e,e.value)}destroy(){for(const e of this.items.keys())e.removeEventListener("input",this.onInput);this.items.clear()}init(e){const n=this.getOptions(this.options);for(const r of e){this.items.has(r)||r.addEventListener("input",this.onInput,{capture:!0});const o=new od(sd(r,n));this.items.set(r,o),queueMicrotask(()=>this.updateValue(r)),r.selectionStart===null&&o.isEager()&&console.warn("Maska: input of `%s` type is not supported",r.type)}}getInputs(e){return typeof e=="string"?Array.from(document.querySelectorAll(e)):"length"in e?Array.from(e):[e]}getOptions(e){const{onMaska:n,preProcess:r,postProcess:o,...s}=e;return s}fixCursor(e,n,r){const o=e.selectionStart,s=e.value;if(r(),o===null||o===s.length&&!n)return;const a=e.value,d=s.slice(0,o),c=a.slice(0,o),u=this.processInput(e,d).unmasked,h=this.processInput(e,c).unmasked;let f=o;d!==c&&(f+=n?a.length-s.length:u.length-h.length),e.setSelectionRange(f,f)}setValue(e,n){const r=this.processInput(e,n);e.value=r.masked,this.options.onMaska!=null&&(Array.isArray(this.options.onMaska)?this.options.onMaska.forEach(o=>o(r)):this.options.onMaska(r)),e.dispatchEvent(new CustomEvent("maska",{detail:r})),e.dispatchEvent(new CustomEvent("input",{detail:r.masked}))}processInput(e,n){const r=this.items.get(e);let o=n??e.value;this.options.preProcess!=null&&(o=this.options.preProcess(o));let s=r.masked(o);return this.options.postProcess!=null&&(s=this.options.postProcess(s)),{masked:s,unmasked:r.unmasked(o),completed:r.completed(o)}}};const di=new WeakMap,dd=(t,e)=>{if(t.arg==null||t.instance==null)return;const n="setup"in t.instance.$.type;t.arg in t.instance?t.instance[t.arg]=e:n&&console.warn("Maska: please expose `%s` using defineExpose",t.arg)},mo=(t,e)=>{var n;const r=t instanceof HTMLInputElement?t:t.querySelector("input");if(r==null||(r==null?void 0:r.type)==="file")return;let o={};if(e.value!=null&&(o=typeof e.value=="string"?{mask:e.value}:{...e.value}),e.arg!=null){const s=a=>{const d=e.modifiers.unmasked?a.unmasked:e.modifiers.completed?a.completed:a.masked;dd(e,d)};o.onMaska=o.onMaska==null?s:Array.isArray(o.onMaska)?[...o.onMaska,s]:[o.onMaska,s]}di.has(r)?(n=di.get(r))==null||n.update(o):di.set(r,new cd(r,o))},ud=["for"],hd={class:"left-field"},fd=["disabled"],md={class:"right-field"},ut=M(i.defineComponent({__name:"PInput",props:i.mergeModels({label:{type:String,default:"",required:!1},margin:{type:String,required:!1,default:""},disabled:{type:Boolean,required:!1,default:!1},padding:{type:String,default:"",required:!1},mask:{type:String,required:!1,default:void 0},borderColor:{type:String,default:"var(--input-border-color)",required:!1},color:{type:String,default:"var(--input-font-color)",required:!1}},{modelValue:{},modelModifiers:{}}),emits:i.mergeModels(["blur","input"],["update:modelValue"]),setup(t){const e=i.useModel(t,"modelValue");return(n,r)=>(i.openBlock(),i.createElementBlock("div",{class:"text-field",style:i.normalizeStyle({margin:t.margin,padding:t.padding})},[t.label?(i.openBlock(),i.createElementBlock("label",{key:0,class:"text-field__label",for:t.label},i.toDisplayString(t.label),9,ud)):i.createCommentVNode("",!0),i.createElementVNode("div",{class:"field",style:i.normalizeStyle({borderColor:t.borderColor})},[i.createElementVNode("div",hd,[i.renderSlot(n.$slots,"default",{},void 0,!0)]),i.withDirectives(i.createElementVNode("input",i.mergeProps(n.$attrs,{"onUpdate:modelValue":r[0]||(r[0]=o=>e.value=o),class:"text-field__input",style:{color:t.color},disabled:t.disabled,onBlur:r[1]||(r[1]=o=>n.$emit("blur",e.value)),onInput:r[2]||(r[2]=o=>n.$emit("input",e.value))}),null,16,fd),[[i.vModelDynamic,e.value],[i.unref(mo),t.mask]]),i.createElementVNode("div",md,[i.renderSlot(n.$slots,"right",{},void 0,!0)])],4)],4))}}),[["__scopeId","data-v-3e6801ac"]]),pd={class:"btn-group"},dn=M(i.defineComponent({__name:"AuthForm",props:{width:{type:String,default:"300px"},margin:{type:String,default:"auto"},padding:{type:String,default:"60px 100px"}},emits:["submit"],setup(t,{emit:e}){const n=S.Auth.Form,r=i.ref(!1),o=e,s=i.computed(()=>n.GetButtons()),a=async d=>{await S.Auth.Form.Block(async()=>{if(!d.submit)return n.SetStatus(d.GetStatus());const c=n.Validate();if(c.length>0){S.Notification.Error(c.join(", "));return}o("submit")})};return i.onBeforeUnmount(()=>{n.Reset()}),(d,c)=>{const u=ut,h=Se;return i.openBlock(),i.createElementBlock("div",{class:"auth-card",style:i.normalizeStyle({width:t.width,margin:t.margin,padding:t.padding})},[i.createElementVNode("div",null,i.toDisplayString(("PF"in d?d.PF:i.unref(S)).Auth.Form.GetTitle()),1),i.createElementVNode("div",null,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(("PF"in d?d.PF:i.unref(S)).Auth.Form.GetFields(),f=>(i.openBlock(),i.createBlock(u,{id:f.id,key:f,modelValue:f.value,"onUpdate:modelValue":m=>f.value=m,placeholder:f.label,margin:"10px 0 0 0"},null,8,["id","modelValue","onUpdate:modelValue","placeholder"]))),128)),i.createVNode(h,{type:"primary",skin:"text_ano",text:"Забыли пароль?",width:"124px",margin:"0 0 0 5px"}),i.createElementVNode("div",pd,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(s),f=>(i.openBlock(),i.createBlock(h,{id:f.id,key:f.GetStatus(),disabled:i.unref(r),type:"primary",skin:"base",text:f.text,color:f.submit?"blue":"grey",margin:"10px 0 0 0",width:"100%",height:"52px",onClick:m=>a(f)},null,8,["id","disabled","text","color","onClick"]))),128))])])],4)}}}),[["__scopeId","data-v-4ca1b015"]]),gd={class:"bg"},ui=M(i.defineComponent({__name:"AuthPage",setup(t){const e=()=>{S.Auth.Form.IsLogin()&&S.H.Router.ToHome()};return(n,r)=>{const o=dn;return i.openBlock(),i.createElementBlock("div",gd,[i.createVNode(o,{width:"760px",margin:"0 auto",onAction:e})])}}}),[["__scopeId","data-v-d59b7e97"]]),yd={},wd={style:{"text-align":"center"}};function bd(t,e){return i.openBlock(),i.createElementBlock("div",wd,e[0]||(e[0]=[i.createElementVNode("h1",null,"Страница не найдена",-1)]))}const hi=M(yd,[["render",bd]]),Cd=[{path:"/",redirect:"/login"},{path:"/login",component:ui,meta:{layout:"LoginLayout"}},{path:"/:pathMatch(.*)*",name:"NotFound",component:hi}];let Sd=($e=class{static SetRouter(e){this.router=e,this.AddRoutes(Cd)}static GetRouter(){return this.router}static AddRoutes(e){e.forEach(n=>{this.GetRouter().addRoute(n)})}static async To(e){await this.GetRouter().push(e)}static async ToHome(){}static async Replace(e){await this.GetRouter().replace(e)}static Id(){return $e.GetStringParam("id")}static Slug(){return $e.GetStringParam("slug")}static async Back(){this.GetRouter().go(-1)}static GetQid(){return $e.GetStringQueryParam("qid")}static Route(){return this.GetRouter().currentRoute.value}static RouterPushBlank(e){const n=this.GetRouter().resolve({path:e});window.open(n==null?void 0:n.href,"_blank")}static GetPath(){var n;const e=(n=$e.Route())==null?void 0:n.path.split("/");return!e||e.length<=0?"":e[e.length-1]}static async ToAdmin(e){if(!e){await this.GetRouter().push("/admin");return}let n=e;n[0]==="/"&&(n=e.substring(1)),await $e.To(`/admin/${n}`)}static GetStringQueryParam(e){return String(this.Route().query[e])}static GetNumberQueryParam(e){return Number(this.Route().query[e]??0)}static GetStringParam(e){return this.Route().params[e]}static Resolve(e){return this.GetRouter().resolve(e)}},l($e,"router"),$e);class kd{static async Auth(e){e&&e()}static Dev(){}}class Ed{constructor(){l(this,"startHour",9);l(this,"startHM",`${this.startHour}:00`);l(this,"endHour",19);l(this,"endHM",`${this.endHour}:00`);l(this,"timelinePxHeight",50);l(this,"timelineStep",Pt.FiveMinutes);l(this,"timelines",an[Pt.FiveMinutes])}periodIsCorrect(e,n){return O.GtOrEq(e,this.startHM)&&O.GtOrEq(this.endHM,n)}setTimelineStep(e){this.timelineStep=e,this.setTimelines()}setTimelines(){this.timelines=an[this.timelineStep]}getScheduleHeight(){return this.getHourHeight()*this.getHoursArr().length}getHourHeight(){return this.timelinePxHeight*this.timelines.length}getHoursArr(){return We.GenerateNumsRange(this.startHour,this.endHour)}timeIsFree(e,n,r,o){return o.filter(s=>s.id!==r).every(s=>!O.PeriodsIntersects(e,n,s.startTime,s.endTime))}sortByStartTime(e){e.sort((n,r)=>O.HMtoM(n.startTime)-O.HMtoM(r.startTime))}}const vd=-68;function Md(t,e){if(!t){document.body.scrollTo({top:0,behavior:"smooth"});return}const n=document.querySelector(t),r=e??vd;let o=0;n&&(o=n.getBoundingClientRect().top+r+document.body.scrollTop),o&&document.body.scrollTo({top:o,behavior:"smooth"})}class xd{static Sort(e){e.forEach((n,r)=>n.order=r)}}class po{static Setup(e){this.staticUrl=e}static get StaticUrl(){return this.staticUrl}}l(po,"staticUrl","");class Tt{static Wait(e,n){return new Promise(r=>setTimeout(()=>r(n),e))}static WaitS(e,n){return Tt.Wait(O.S(e),n)}static WaitM(e,n){return Tt.Wait(O.M(e),n)}}function Bd(t,e){let n=!0;return t.value.validate(r=>(r||(n=!1),n)),n}const Id=t=>new Promise(e=>{if(document.querySelector(t))return e(document.querySelector(t));const n=new MutationObserver(()=>{document.querySelector(t)&&(n.disconnect(),e(document.querySelector(t)))});n.observe(document.body,{childList:!0,subtree:!0})});class un{constructor(e){l(this,"id");l(this,"message","");l(this,"userName");l(this,"createdOn",new Date);l(this,"chatId");l(this,"type","message");Classes.BuildClass(this,e)}static Create(e,n,r,o){const s=new un;return s.id=ue(),s.chatId=e,s.message=r,s.userName=o,s}static CreatePingMessage(){const e=new un;return e.type="ping",e.id=ue(),e}isMessage(){return this.type==="message"||this.type===""}}const Rd="";class $d{constructor(e="",n="",r="set"){l(this,"client");l(this,"endpoint","");l(this,"query","");l(this,"period",2e4);Classes.BuildClass(this,{endpoint:e,query:n,mutation:r}),this.connect(),this.ping()}send(e){!this.client||this.client.readyState!==1||this.client.send(e)}ping(){setInterval(this.sendPing.bind(this),this.period)}sendPing(){!this.client||this.client.readyState!==1||this.send(JSON.stringify(un.CreatePingMessage()))}setOnMessage(){this.client&&(this.client.onmessage=e=>{e.data})}buildUrl(){const e=`ws/${this.endpoint}/${this.query}`;return new URL(e,Rd.replace("http","ws")).toString()}connect(){this.client=new WebSocket(this.buildUrl()),this.client.onclose=this.reconnect,this.client.onerror=this.reconnect}reconnect(){setTimeout(this.connect,3e3)}}const Nd=Object.freeze(Object.defineProperty({__proto__:null,Arrays:We,Axios:At,BaseStore:te,Button:Je,Cache:Fc,CarouselSwipe:Dc,Classes:Z,Color:Oc,Contact:Fn,CreateSortModels:br,Cursor:Hc,DateMask:jc,Dates:Le,Dragger:Xc,Email:Ue,Extension:Yc,FTSP:fr,Favourite:Qc,FilterModel:Ln,Hooks:hl,HttpClient:oe,MakeCarousel:lo,Period:si,PhoneService:ci,Rating:Kc,Router:Sd,RouterGuard:kd,Scheduler:Ed,Scroll:Md,Sizes:Hn,SortModel:Jt,Sorter:xd,Static:po,Statuses:le,Strings:Dn,Time:O,Timer:Tt,Token:Nt,ValueType:On,WaitElement:Id,WebSocketClient:$d,useConfirmLeavePage:Cr,validate:Bd},Symbol.toStringTag,{value:"Module"}));class Ad extends cr{Show(){super.show()}Hide(){super.hide()}}const Pd=new Ad;class Td extends dr{constructor(){super(...arguments);l(this,"duration",O.S(3))}showMessage(n,r){super.showMessage(n,r),typeof n!="string"&&(this.duration=n.duration??this.duration),Tt.Wait(this.GetDuration()).then(()=>super.hide())}GetDuration(){return this.duration}Dev(){const n="В режиме разработки",r=le.Warning;super.showMessage(n,r)}Save(){const n="Изменения успешно сохранены",r=le.Success;super.showMessage(n,r)}}const zd=new Td;class Vd{constructor(){l(this,"limit",25);l(this,"count",0);l(this,"curPage",1);l(this,"storeModule","")}setCurPage(e){this.curPage=e}pagesCount(){return Math.ceil(this.count/this.limit)??1}reset(){this.count=0,this.curPage=1}}const Fd=new Vd;let Dd=class{async Login(e){const n=e??S.Auth.Form.GetValues(),r=await oe.Post({query:"auth/login",payload:n});if(!r)throw S.Notification.Error("Ошибка авторизации"),"Ошибка авторизации";S.Auth.Status.SetState(r)}async LoginAs(e){if(!await oe.Post({query:"auth/login-as",payload:{email:e}})){S.Notification.Error("Ошибка авторизации");return}}async Register(){}async RestorePassword(){}async passwordChange(){await oe.Put({query:"auth/password-change"})}async RefreshToken(){await oe.Post({query:"auth/refresh-token",payload:{refreshToken:Nt.getRefreshToken()}})}async CheckUuid(e){await oe.Get({query:`auth/check-uuid/${e.userId}/${e.uniqueId}`})}};const Ld=new Dd;let Od=class extends te{constructor(){super(Fn,"contacts")}};const Hd=new Od;class hn{constructor(e){l(this,"id");l(this,"ratio",0);l(this,"src","");l(this,"store","");Classes.BuildClass(this,e)}static CreateCropper(e,n,r){const o=new hn;return o.src=e,o.id=r,n&&(o.ratio=n),o}}let _d=class{constructor(){l(this,"cropper",new hn)}Open(e){this.cropper=e}Cropper(){return this.cropper}Ratio(){return this.cropper.ratio}};const qd=new _d;let Ud=class extends te{constructor(){super(Ue,"emails")}};const Wd=new Ud;let Gd=class extends te{constructor(){super(ye,"file-infos")}};const jd=new Gd;class fi{constructor(e){l(this,"id");l(this,"ftsp");l(this,"name","");Classes.BuildClass(this,e)}static Create(e){const n=new fi;return n.id=Classes.CreateUUID(),n.ftsp=JSON.stringify(e),n}}let Zd=class extends te{constructor(){super(fi,"ftsp-presets")}};const Jd=new Zd;let Xd=class extends te{constructor(){super(lr,"humans")}};const Yd=new Xd;class go{constructor(e){l(this,"id");l(this,"name","");l(this,"order",0);l(this,"downloadToFile",!1);l(this,"pageSectionId");l(this,"scan",new ye);l(this,"scanId");e&&(this.id=e==null?void 0:e.id,this.name=e.name,this.order=e.order,this.downloadToFile=e.downloadToFile,this.pageSectionId=e.pageSectionId,e.scan&&(this.scan=new ye(e.scan)),this.scanId=e.scanId)}getFileInfos(){return[this.scan]}uploadScan(e){return this.scan.id||(this.scan.id=ue()),this.scan.originalName=e.name,this.scan.file=e.raw,this.scan.fileSystemPath=ue(),this.scan.url=e.url,this.scan}getFileName(){return this.name?this.name:this.scan.originalName}}class Qd{constructor(e){l(this,"id");l(this,"documentType",new Ke);l(this,"documentTypeId");l(this,"order",0);Classes.BuildClass(this,e)}getFileInfos(){const e=[];return e.push(...this.documentType.getFileInfos()),e}}var Kd=Object.defineProperty,yo=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&Kd(e,n,o),o};class Ke{constructor(e){l(this,"id");l(this,"name","");l(this,"singleScan",!1);l(this,"scan");l(this,"scanId");l(this,"order",0);l(this,"description","");l(this,"scans",[]);l(this,"scansForDelete",[]);l(this,"pageSectionDocuments",[]);l(this,"pageSectionDocumentsForDelete",[]);l(this,"pageSectionImages",[]);l(this,"pageSectionImagesForDelete",[]);l(this,"pageSideMenuId");l(this,"pageId");l(this,"text","");l(this,"documents",[]);Classes.BuildClass(this,e),this.documents=this.pageSectionDocuments,this.text=this.description.replace("<p>undefined</p>","")}addDocument(){const e=new go;e.order=this.pageSectionDocuments.length-1,this.pageSectionDocuments.push(e)}getFileInfos(){const e=[];return this.pageSectionDocuments.forEach(n=>{e.push(...n.getFileInfos())}),e}infoExists(e){const n=H.Strings.SearchIn(this.name,e),r=H.Strings.SearchIn(this.description,e),o=this.getDocuments(e);return n||r||o.length>0}getDocuments(e){return this.pageSectionDocuments.filter(n=>H.Strings.SearchIn(n.name,e))}getDescription(e){return e?H.Strings.WrapSubStr(this.description,e):this.description}filter(e){if(!e){this.text=this.description,this.documents=this.pageSectionDocuments;return}this.text=H.Strings.SearchIn(this.description,e)?H.Strings.WrapSubStr(this.description,e):"",this.documents=this.pageSectionDocuments.filter(n=>H.Strings.SearchIn(n.name,e))}}yo([Classes.GetClassConstructor(go)],Ke.prototype,"pageSectionDocuments"),yo([Classes.GetClassConstructor(Qd)],Ke.prototype,"pageSectionImages");class eu{constructor(e){l(this,"id");l(this,"document",new Ke);l(this,"documentId");l(this,"pageId");Classes.BuildClass(this,e)}static GetFileInfos(e){const n=[];return e.forEach(r=>{const o=r.document.scan;o&&n.push(o)}),n}}var tu=Object.defineProperty,nu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&tu(e,n,o),o};class wo{constructor(e){l(this,"id");l(this,"pageId");l(this,"fileInfoId");l(this,"fileInfo");l(this,"description");Classes.BuildClass(this,e)}}nu([Classes.GetClassConstructor(ye)],wo.prototype,"fileInfo");var iu=Object.defineProperty,ru=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&iu(e,n,o),o};class ht{constructor(e){l(this,"id");l(this,"name","Новое меню");l(this,"order",0);l(this,"description","");l(this,"routeAnchor","");l(this,"slug","");l(this,"pageSections",[]);l(this,"pageSectionsForDelete",[]);l(this,"showContent",!1);l(this,"pageId");l(this,"selected",!1);l(this,"sections",[]);l(this,"text","");Classes.BuildClass(this,e),this.sections=this.pageSections,this.text=this.description.replace("<p>undefined</p>","")}getFileInfos(){const e=[];return this.pageSections.forEach(n=>{e.push(...n.getFileInfos())}),e}addPageSection(){const e=new Ke;e.order=this.pageSections.length+1,e.name=`Новой раздел ${e.order}`,e.id=Classes.CreateUUID(),this.pageSections.push(e)}infoExists(e){const n=H.Strings.SearchIn(this.name,e),r=H.Strings.SearchIn(this.description,e),o=this.getPageSections(e).length>0;return n||r||o}getPageSections(e){return e.length?this.pageSections.filter(n=>n.infoExists(e)):this.pageSections}filter(e){e.length?(this.sections=this.pageSections.filter(n=>n.infoExists(e)),this.text=H.Strings.SearchIn(this.description,e)?H.Strings.WrapSubStr(this.description,e):""):(this.sections=this.pageSections,this.text=this.description),this.sections.forEach(n=>n.filter(e))}}ru([Classes.GetClassConstructor(Ke)],ht.prototype,"pageSections");var bo=(t=>(t.User="USER",t.Admin="ADMIN",t))(bo||{});class ou{constructor(e){l(this,"id");l(this,"name",bo.User);l(this,"label","");l(this,"startPage","");Classes.BuildClass(this,e)}}var su=Object.defineProperty,fn=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&su(e,n,o),o};class ft{constructor(e){l(this,"id");l(this,"title","");l(this,"content","");l(this,"slug","");l(this,"pagesGroup","Без группы");l(this,"link","");l(this,"withComments",!1);l(this,"showContacts",!1);l(this,"collaps",!1);l(this,"showContent",!1);l(this,"pageImages",[]);l(this,"pageImagesForDelete",[]);l(this,"pageImagesNames",[]);l(this,"pageSideMenus",[]);l(this,"menus",[]);l(this,"pageSideMenusForDelete",[]);l(this,"pageSections",[]);l(this,"pageSectionsForDelete",[]);l(this,"pageDocuments",[]);l(this,"contact",new Fn);l(this,"contactId");l(this,"role",new ou);l(this,"roleId");l(this,"filterStr","");l(this,"activeMenuId","");Classes.BuildClass(this,e),this.menus=this.pageSideMenus}getActiveMenu(){const e=this.pageSideMenus.find(n=>n.id===this.activeMenuId);return e||this.pageSideMenus[0]}setActiveMenuId(e){this.activeMenuId=e}getLink(){return this.slug!==""?`/pages/${this.slug}`:"404"}getFileInfos(){const e=[];return this.pageSideMenus.forEach(n=>{e.push(...n.getFileInfos())}),this.pageDocuments.forEach(n=>{n.document.scan&&e.push(n.document.scan)}),this.pageImages.forEach(n=>{n.fileInfo&&e.push(n.fileInfo)}),e}addSideMenu(){const e=new ht;return e.order=this.pageSideMenus.length+1,e.name=`Новое меню ${e.order}`,e.id=ue(),this.pageSideMenus.push(e),e.id}selectSideMenu(e,n){if(!e&&this.pageSideMenus.length>0){this.pageSideMenus[0].selected=!0;return}this.pageSideMenus.forEach(r=>{n?r.selected=r.id===e:r.selected=r.slug===e})}getSelectedSideMenu(){const e=this.pageSideMenus.find(n=>n.selected);return e||new ht}addCustomSectionsToSideMenu(e){e.forEach(n=>{const r=new ht;r.id=n.id,r.name=n.name,typeof n.order<"u"?this.pageSideMenus.splice(n.order,0,r):this.pageSideMenus.push(r)})}getPageSideMenus(){if(this.showContacts&&!this.pageSideMenus.find(e=>e.id==="contacts")){const e=new ht;e.id="contacts",e.name="Контакты",this.pageSideMenus.push(e)}return this.filterStr===""?this.pageSideMenus:this.pageSideMenus.filter(e=>e.infoExists(this.filterStr))}filter(){this.filterStr===""?this.menus=this.pageSideMenus:this.menus=this.pageSideMenus.filter(e=>e.infoExists(this.filterStr)),this.menus.forEach(e=>e.filter(this.filterStr))}static GetClassName(){return"page"}}fn([Classes.GetClassConstructor(wo)],ft.prototype,"pageImages"),fn([Classes.GetClassConstructor(ht)],ft.prototype,"pageSideMenus"),fn([Classes.GetClassConstructor(Ke)],ft.prototype,"pageSections"),fn([Classes.GetClassConstructor(eu)],ft.prototype,"pageDocuments");class Co{constructor(e){l(this,"id");l(this,"name","");l(this,"link","");l(this,"selected",!1);l(this,"hide",!1);l(this,"editMode",!1);l(this,"color","");l(this,"background","");l(this,"page",new ft);l(this,"pageId");l(this,"order",0);l(this,"menuId");l(this,"iconId");l(this,"icon",new ye);l(this,"iconName","");l(this,"svgCode","");Classes.BuildClass(this,e)}getLink(){return this.isLink()&&!this.isPageLink()?this.link:!this.isLink()&&this.isPageLink()?this.page.getLink():""}isLink(){return this.link!==""}isPageLink(){return this.pageId!==void 0&&this.pageId!==""}addFile(e){this.icon.id||(this.icon.id=ue()),this.icon.originalName=e.name,this.icon.file=e.raw}}var au=Object.defineProperty,lu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&au(e,n,o),o};class So{constructor(e){l(this,"id");l(this,"name","");l(this,"link","");l(this,"top",!0);l(this,"side",!0);l(this,"show",!1);l(this,"hide",!1);l(this,"active",!1);l(this,"order",0);l(this,"selected",!1);l(this,"editMode",!1);l(this,"page",new ft);l(this,"pageId");l(this,"subMenus",[]);l(this,"subMenusForDelete",[]);l(this,"iconId");l(this,"icon",new ye);Classes.BuildClass(this,e)}getLink(){return this.isLink()&&!this.isPageLink()?this.link:!this.isLink()&&this.isPageLink()?this.page.getLink():""}withoutChildren(){return this.subMenus.length===0}isLink(){return this.link!==""}isPageLink(){return!!this.pageId&&this.pageId!==""}getFileInfos(){const e=[];return e.push(this.icon),this.subMenus.forEach(n=>{e.push(n.icon)}),e}addFile(e){this.icon.id||(this.icon.id=ue()),this.icon.originalName=e.name,this.icon.file=e.raw}addSubMenu(){this.subMenus.push(new Co)}removeSubMenu(e){const n=this.subMenus[e].id;n&&this.subMenusForDelete.push(n),this.subMenus.splice(e,1)}setColorsForSubMenus(){const e=["#00A248","#E63021","#006BB5","#F3911F","#6F6D6B"];let n=0;this.subMenus.forEach(r=>{r.color=e[n],n=e.length-1?n=0:n++})}containPath(e){return this.getLink()===e||!!this.subMenus.find(n=>n.getLink()===e)}static GetClassName(){return"menu"}}lu([Classes.GetClassConstructor(Co)],So.prototype,"subMenus");let cu=class extends S.H.BaseStore{constructor(){super(So,"menus")}};const du=new cu;let uu=class extends te{constructor(){super(at,"phones")}};const hu=new uu;class fu{constructor(e){l(this,"id");l(this,"nameRus","");Classes.BuildClass(this,e)}}var mu=Object.defineProperty,pu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&mu(e,n,o),o};class ko{constructor(e){l(this,"id");l(this,"nameRus","");l(this,"fields",[]);Classes.BuildClass(this,e)}}pu([Classes.GetClassConstructor(fu)],ko.prototype,"fields");let gu=class extends te{constructor(){super(ko,"schemas")}};const yu=new gu;class Eo{constructor(e){l(this,"id","");l(this,"value","");l(this,"label","");l(this,"key","");l(this,"description","");l(this,"route","");l(this,"searchElementMetas",[]);Classes.BuildClass(this,e)}}class wu{constructor(e){l(this,"id");l(this,"name","");l(this,"label","");Classes.BuildClass(this,e)}}var bu=Object.defineProperty,vo=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&bu(e,n,o),o};class mt{constructor(e){l(this,"id");l(this,"key","");l(this,"label","");l(this,"order",0);l(this,"route","");l(this,"table","");l(this,"active",!0);l(this,"searchColumn","");l(this,"descriptionColumn","");l(this,"labelColumn","");l(this,"valueColumn","");l(this,"options",[]);l(this,"searchGroupMetaColumns",[]);Z.BuildClass(this,e)}}vo([Z.GetClassConstructor(Eo)],mt.prototype,"options"),vo([Z.GetClassConstructor(wu)],mt.prototype,"searchGroupMetaColumns");class mi{constructor(e){l(this,"query","");l(this,"key","");l(this,"params","");l(this,"suggester",!1);l(this,"mustBeTranslated",!0);l(this,"options",[]);l(this,"searchGroupId","");l(this,"searchGroups",[]);l(this,"searchGroup",new mt);l(this,"searchObjects",[]);l(this,"pagination",new jt);l(this,"count",0);e&&(this.query=e.query,e.searchGroups&&(this.searchGroups=e.searchGroups.map(n=>new mt(n))),e.searchGroup&&(this.searchGroup=new mt(e.searchGroup)),e.options&&(this.options=e.options.map(n=>new Eo(n))),this.count=e.count)}toUrl(){return JSON.stringify(this)}async setSearchGroup(e){const n=this.searchGroups.find(r=>r.id===e);n?this.searchGroup=n:this.searchGroup=new mt}async reproduceFromRoute(){this.setQuery(),await this.setSearchGroup(H.Router.Route().query.groupId)}setQuery(){const e=H.Router.Route().query.query;e&&(this.query=e)}}let Cu=class{constructor(){l(this,"isSearchDrawerOpen",i.ref(!1));l(this,"searchModel",i.reactive(new mi));l(this,"searchGroups",i.reactive([]));l(this,"count",0)}async Search(e){const n=await oe.Get({query:`?key=${e.key}&query=${e.query}`});n&&n.searchGroup&&n.searchGroup.options.forEach(r=>{e.searchObjects.push({id:r.id,value:r.value,label:r.label,description:r.description})})}async mainSearch(e){this.SetSearchModel(await oe.Get({query:`/main?searchModel=${e.toUrl()}`}))}async Full(e){e.options=[],e.searchGroups.forEach(r=>{r.options=[]});const n=await oe.Get({query:`main?searchModel=${e.toUrl()}`});this.SetSearchModel(n)}ToggleDrawer(e){this.isSearchDrawerOpen.value=e,this.searchModel=new mi}SetSearchModel(e){e&&(this.searchModel=new mi(e))}SetSearchGroups(){}IsSearchDrawerOpen(){return this.isSearchDrawerOpen}SearchModel(){return this.searchModel}SearchGroups(){return this.searchGroups}Count(){return this.count}};const Su=new Cu;class pi{constructor(e){l(this,"id");l(this,"login","");l(this,"email","");l(this,"password","");Classes.BuildClass(this,e)}static Create(){const e=new pi;return e.id=Classes.CreateUUID(),e}}let ku=class extends te{constructor(){super(pi,"users-accounts")}};const Eu=new ku;let vu=class extends te{constructor(){super(On,"value-types")}};const Mu=new vu,xu=Object.freeze(Object.defineProperty({__proto__:null,Auth:Ld,Contacts:Hd,Cropper:qd,Emails:Wd,FTSPPresets:Jd,FileInfos:jd,Humans:Yd,Menus:du,Phones:hu,Schemas:yu,Search:Su,UserAccounts:Eu,ValueTypes:Mu},Symbol.toStringTag,{value:"Module"}));class S{}l(S,"Auth",i.reactive(rr)),l(S,"AdminUI",i.reactive(el)),l(S,"Dialog",i.reactive(nl)),l(S,"Notification",i.reactive(zd)),l(S,"Loading",i.reactive(Pd)),l(S,"Paginator",i.reactive(Fd)),l(S,"S",xu),l(S,"H",Nd),l(S,"C",Za);class et{constructor(e){l(this,"id");l(this,"name","");l(this,"score",0);l(this,"order",0);l(this,"showMoreQuestions",!1);l(this,"showOther",!1);l(this,"fieldId");l(this,"isMatrixY",!1);S.H.Classes.BuildClass(this,e)}static Create(e){const n=new et;return n.id=S.H.Classes.CreateUUID(),n.fieldId=e,n}}class Mo{constructor(e){l(this,"id");l(this,"name","");l(this,"order",0);l(this,"fieldId");S.H.Classes.BuildClass(this,e)}}class gi{constructor(e){l(this,"id");l(this,"name","");l(this,"order",0);S.H.Classes.BuildClass(this,e)}}class pt{constructor(e){l(this,"id");l(this,"name","");l(this,"fieldId");S.H.Classes.BuildClass(this,e)}static Create(e){const n=new pt;return n.id=S.H.Classes.CreateUUID(),n.fieldId=e,n}}var Bu=Object.defineProperty,zt=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&Bu(e,n,o),o};const tt=class Pn{constructor(e){l(this,"id");l(this,"name","");l(this,"code","");l(this,"valueTypeId");l(this,"order",0);l(this,"ageCompare",!1);l(this,"answerVariants",[]);l(this,"answerVariantsForDelete",[]);l(this,"fieldExamples",[]);l(this,"fieldVariants",[]);l(this,"valueType",new On);l(this,"fieldMeasures",[]);l(this,"showSet",!1);l(this,"showRadio",!1);l(this,"isEdit",!1);l(this,"children",[]);l(this,"parentId");l(this,"formSectionId");l(this,"selected",!1);S.H.Classes.BuildClass(this,e),this.changeRelation([this.valueType])}getMatrixX(){return this.answerVariants.filter(e=>!e.isMatrixY)}getMatrixY(){return this.answerVariants.filter(e=>e.isMatrixY)}static Create(e){const n=new Pn;return n.id=S.H.Classes.CreateUUID(),n.formSectionId=e,n}getRegisterPropertyRadioOriginalValue(e){const n=this.answerVariants.find(r=>r.id===e);return n?n.name:""}addRadioItem(e){const n=new et(e);n.order=this.answerVariants.length,this.answerVariants.push(n)}removeRadioItem(e){const n=this.answerVariants[e].id;n&&this.answerVariantsForDelete.push(n),this.answerVariants.splice(e,1)}changeRelation(e){const n=e.find(r=>r.id===this.valueTypeId);if(n){if(n.isRadio()){this.showRadio=!0,this.showSet=!1;return}if(n.isSet()){this.showSet=!0,this.showRadio=!1;return}this.showSet=!1,this.showRadio=!1,this.valueType=n}}editRegisterProperty(e){this.isEdit=e??!this.isEdit}sortExamples(){this.fieldExamples.forEach((e,n)=>e.order=n)}addRegisterPropertyMeasure(e){this.fieldMeasures.push(new gi(e))}addRegisterPropertyVariant(){this.fieldVariants.push(new pt)}getIdWithoutDashes(){return this.id?this.id.replaceAll(/[^a-zA-Z]+/g,""):""}static GetClassName(){return"Field"}setType(e){this.valueType=e,this.valueTypeId=e.id}setName(e){this.name=e}addAnswerVariant(){const e=et.Create(this.id);return e.name="Вариант",e.order=this.answerVariants.length,this.answerVariants.push(e),e}addChild(){const e=Pn.Create();return e.parentId=this.id,e.name="Вопрос",e.order=this.children.length,this.children.push(e),e}addFieldVariant(){const e=pt.Create(this.id);return this.fieldVariants.push(e),e}copy(){const e=new Pn(this);return e.id=S.H.Classes.CreateUUID(),e.answerVariants.forEach(n=>{n.id=S.H.Classes.CreateUUID(),n.fieldId=e.id}),e.children=e.children.map(n=>{const r=n.copy();return r.parentId=e.id,r}),e}};zt([S.H.Classes.GetClassConstructor(et)],tt.prototype,"answerVariants"),zt([S.H.Classes.GetClassConstructor(Mo)],tt.prototype,"fieldExamples"),zt([S.H.Classes.GetClassConstructor(pt)],tt.prototype,"fieldVariants"),zt([S.H.Classes.GetClassConstructor(gi)],tt.prototype,"fieldMeasures"),zt([S.H.Classes.GetClassConstructor(tt)],tt.prototype,"children");let mn=tt;class yi{constructor(e){l(this,"id");l(this,"answerId");l(this,"comment","");l(this,"fileInfoId");l(this,"fileInfo",new ye);S.H.Classes.BuildClass(this,e)}}class nt{constructor(e){l(this,"id");l(this,"answerVariantId");l(this,"answerVariantIdY");l(this,"fieldFillId");S.H.Classes.BuildClass(this,e)}static Create(e,n){const r=new nt;return r.id=ue(),r.fieldFillId=e,r.answerVariantId=n,r}static GetClassName(){return"selectedAnswerVariant"}}var Iu=Object.defineProperty,xo=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&Iu(e,n,o),o};const wi=class Yi{constructor(e){l(this,"id");l(this,"valueString");l(this,"valueOther");l(this,"valueNumber");l(this,"valueDate");l(this,"fileInfo",new ye);l(this,"fileInfoId");l(this,"order",0);l(this,"selectedAnswerVariants",[]);l(this,"patientId");l(this,"fieldId");l(this,"formFillId");l(this,"answerVariantId");l(this,"filled",!1);l(this,"researchResultId");l(this,"answerFiles",[]);l(this,"answerFilesForDelete",[]);S.H.Classes.BuildClass(this,e)}setFilled(e){this.filled=e}static Create(e,n){const r=new Yi;return r.id=ue(),r.fieldId=e.id,r.formFillId=n,r.order=e.order,r.valueNumber=0,r.valueString="",r.valueDate=new Date,r}setString(e){this.valueString=e,this.valueString&&(this.filled=this.valueString.length>0)}setNumber(e){this.valueNumber=e,this.valueNumber&&(this.filled=!0)}setOther(e){this.valueOther=e,this.valueOther&&(this.filled=this.valueOther.length>0)}setDate(e){this.valueDate=e,this.filled=!0}setRadio(e){this.answerVariantId=e,this.filled=!!this.answerVariantId}static CreateMany(e,n){return e.map(r=>Yi.Create(r,n))}addFile(){const e=new yi;return e.id=ue(),e.answerId=this.id,this.answerFiles.push(e),e}getFileInfos(){const e=[];return this.answerFiles.forEach(n=>e.push(n.fileInfo)),e}getSelectedAnswerVariant(){return!0}setMatrixRadioValue(e,n){const r=nt.Create(this.id,e);return r.answerVariantIdY=n,this.selectedAnswerVariants.push(r),this.filled=!0,r}getMatrixValue(e,n){return this.selectedAnswerVariants.find(r=>r.answerVariantId===e&&r.answerVariantIdY===n)}addSelectedAnswerVariant(e){const n=nt.Create(this.id,e);return this.selectedAnswerVariants.push(n),this.filled=!0,n}static GetClassName(){return"answer"}showOther(e){const n=e.find(r=>r.showOther);return n?this.answerVariantId===n.id||this.selectedAnswerVariants.some(r=>r.answerVariantId===n.id):!1}};xo([S.H.Classes.GetClassConstructor(nt)],wi.prototype,"selectedAnswerVariants"),xo([S.H.Classes.GetClassConstructor(yi)],wi.prototype,"answerFiles");let gt=wi;class Ru{constructor(e){l(this,"id");l(this,"fieldId");S.H.Classes.BuildClass(this,e)}static GetClassName(){return"fieldFilter"}}var $u=Object.defineProperty,Nu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&$u(e,n,o),o};const Bo=class Ma{constructor(e){l(this,"id");l(this,"name","");l(this,"order",0);l(this,"fields",[]);l(this,"formId");S.H.Classes.BuildClass(this,e)}static GetClassName(){return"formSection"}getN(){return`${this.order+1}`}getFieldN(e){return`${this.getN()}.${e+1}`}getSubFieldN(e,n){return`${this.getFieldN(e)}.${n+1}`}static Create(e){const n=new Ma;return n.id=S.H.Classes.CreateUUID(),n.formId=e,n}addField(){const e=mn.Create(this.id);return this.fields.push(e),this.sortFields(),e}sortFields(){this.fields.forEach((e,n)=>e.order=n)}getAnswerVariants(){const e=[];return this.fields.forEach(n=>e.push(...n.answerVariants)),e}};Nu([S.H.Classes.GetClassConstructor(mn)],Bo.prototype,"fields");let pn=Bo;var Au=Object.defineProperty,Pu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&Au(e,n,o),o};const Io=class xa{constructor(e){l(this,"id");l(this,"name","");l(this,"order",0);l(this,"isLaboratory",!1);l(this,"formSections",[]);l(this,"isEdit",!1);l(this,"withDates",!1);l(this,"withScores",!1);l(this,"selectedForExport",!1);l(this,"filterString","");l(this,"showOnlyNotFilled",!1);l(this,"showOnlyFilled",!1);S.H.Classes.BuildClass(this,e)}static GetClassName(){return"Form"}static Create(){const e=new xa;return e.id=S.H.Classes.CreateUUID(),e}editRegisterGroup(e){this.isEdit=e??!this.isEdit}addFormSection(){const e=pn.Create(this.id);return this.formSections.push(e),S.H.Sorter.Sort(this.formSections),e}getFields(){const e=this.formSections.map(r=>r.fields).flat(),n=e.map(r=>r.children).flat();return e.concat(n).filter(r=>r.children.length===0)}};Pu([S.H.Classes.GetClassConstructor(pn)],Io.prototype,"formSections");let Ro=Io;var Tu=Object.defineProperty,zu=(t,e,n,r)=>{for(var o=void 0,s=t.length-1,a;s>=0;s--)(a=t[s])&&(o=a(e,n,o)||o);return o&&Tu(e,n,o),o};const $o=class Ba{constructor(e){l(this,"id");l(this,"date",new Date);l(this,"editMode",!1);l(this,"userFormId");l(this,"fillingPercentage",0);l(this,"fieldFills",[]);l(this,"num","");l(this,"formId");S.H.Classes.BuildClass(this,e)}static Create(e){const n=new Ba;return n.id=S.H.Classes.CreateUUID(),n.formId=e.id,n.fieldFills.push(...gt.CreateMany(e.getFields(),n.id)),n}addFieldFill(e){this.fieldFills.push(e)}getFieldFill(e){var n;return(n=this.fieldFills)==null?void 0:n.find(r=>r.fieldId===e)}pushRegisterProperty(e){const n=new gt;n.researchResultId=e,this.fieldFills.push(n)}getRegisterPropertyToPatient(e){return this.fieldFills.filter(n=>n.researchResultId===e)}getOrCreateFieldFill(e){let n=this.getFieldFill(e.id);return n||(n=gt.Create(e),this.addFieldFill(n)),n}getFileInfos(){const e=[];return this.fieldFills.forEach(n=>e.push(...n.getFileInfos())),e}calculateFilling(){const e=this.fieldFills.filter(r=>r.filled).length,n=this.fieldFills.length;this.fillingPercentage=Math.round(e/n*100)}getFieldFillByFieldId(e){return this.fieldFills.find(n=>n.fieldId===e)}getFieldVariantFieldFill(e){return this.fieldFills.find(n=>n.answerVariantId===e)}getFieldsFieldFillsMap(e){const n={};return e.forEach(r=>{var o;if(r.code){const s=(o=this.getFieldFillByFieldId(r.id))==null?void 0:o.valueNumber;n[r.code]=s}}),n}getIdWithoutDashes(){return this.id?this.id.replaceAll(/[^a-zA-Z]+/g,""):""}};zu([S.H.Classes.GetClassConstructor(gt)],$o.prototype,"fieldFills");let No=$o;const Vu=Object.freeze(Object.defineProperty({__proto__:null,AnswerVariant:et,Field:mn,FieldExample:Mo,FieldFill:gt,FieldFillFile:yi,FieldFilter:Ru,FieldMeasure:gi,FieldVariant:pt,Form:Ro,FormFill:No,FormSection:pn,SelectedAnswerVariant:nt},Symbol.toStringTag,{value:"Module"}));let Fu=class extends te{constructor(){super(et,"answer-variants")}};const Du=new Fu;let Lu=class extends te{constructor(){super(gt,"field-fills")}};const Ou=new Lu;let Hu=class extends te{constructor(){super(mn,"fields")}};const _u=new Hu;let qu=class extends te{constructor(){super(No,"form-fills")}};const Uu=new qu;let Wu=class extends te{constructor(){super(pn,"form-sections")}};const Gu=new Wu;let ju=class extends te{constructor(){super(Ro,"forms")}};const Zu=new ju;let Ju=class extends te{constructor(){super(nt,"selected-answer-variants")}};const Xu=new Ju,Yu=Object.freeze(Object.defineProperty({__proto__:null,C:Vu,S:Object.freeze(Object.defineProperty({__proto__:null,AnswerVariants:Du,FieldFills:Ou,Fields:_u,FormFills:Uu,FormSections:Gu,Forms:Zu,SelectedAnswerVariants:Xu},Symbol.toStringTag,{value:"Module"}))},Symbol.toStringTag,{value:"Module"}));class gn{constructor(e){l(this,"id");l(this,"name","");l(this,"label","");S.H.Classes.BuildClass(this,e)}static Create(e,n){const r=new gn;return r.id=S.H.Classes.CreateUUID(),r.name=e,r.label=n,r}}const Qu=Object.freeze(Object.defineProperty({__proto__:null,ColorTheme:gn},Symbol.toStringTag,{value:"Module"}));let Ku=class extends te{constructor(){super(gn,"color-themes")}};const eh=new Ku,th=Object.freeze(Object.defineProperty({__proto__:null,Forms:Yu,Settings:Object.freeze(Object.defineProperty({__proto__:null,C:Qu,S:Object.freeze(Object.defineProperty({__proto__:null,ColorThemes:eh},Symbol.toStringTag,{value:"Module"}))},Symbol.toStringTag,{value:"Module"}))},Symbol.toStringTag,{value:"Module"})),nh={class:"item"},ih={class:"move"},rh={class:"item-tools"},oh=["onClick"],sh={class:"item-description"},ah=["onUpdate:modelValue"],Ao=M(i.defineComponent({__name:"AdminGallery",props:{fileList:{type:Array,reguired:!0,default:()=>[]},fileListForDelete:{type:Array,default:()=>[]},defaultRatio:{type:Number,required:!1,default:1},upload:{type:Boolean,required:!1,default:!0}},emits:["addImage","ratio","remove"],setup(t,{emit:e}){const n=t,r=e,o=async a=>{r("addImage",a)},s=async a=>{S.H.Classes.RemoveFromClassById(a.id,n.fileList,[]),r("remove",a)};return(a,d)=>{const c=i.resolveComponent("UploderImage"),u=i.resolveComponent("draggable"),h=i.resolveComponent("Move");return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createVNode(u,{class:"groups",list:t.fileList,"item-key":"id",handle:".move",onEnd:d[0]||(d[0]=f=>i.unref(We).Sort(t.fileList))},{item:i.withCtx(({element:f,index:m})=>[i.createElementVNode("div",nh,[i.createElementVNode("div",ih,[i.createElementVNode("div",rh,[d[1]||(d[1]=i.createElementVNode("svg",{class:"icon-move"},[i.createElementVNode("use",{"xlink:href":"#move"})],-1)),i.createElementVNode("button",{class:"admin-del2",onClick:i.withModifiers(g=>s(f),["prevent"])},"Удалить",8,oh)]),i.createVNode(c,{"file-info":f,height:150,"default-ratio":t.defaultRatio,onRemoveFile:g=>("PF"in a?a.PF:i.unref(S)).H.Classes.RemoveFromClassByIndex(m,t.fileList,t.fileListForDelete),onCrop:g=>o(f)},null,8,["file-info","default-ratio","onRemoveFile","onCrop"])]),i.createElementVNode("div",sh,[i.withDirectives(i.createElementVNode("input",{"onUpdate:modelValue":g=>f.description=g,class:"item-description-form",placeholder:"..."},null,8,ah),[[i.vModelText,f.description]])])])]),_:1},8,["list"]),i.createVNode(h)],64)}}}),[["__scopeId","data-v-7e3c8bac"]]),bi=M(i.defineComponent({__name:"IconCheckDefault",props:{size:{type:String,default:"22px"},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#check_on"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"check_on",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},[i.createElementVNode("path",{d:"M29.3678 7.25259C29.2732 7.3128 28.8775 7.6999 28.5076 8.13001C27.7076 9.02463 16.2409 22.0483 16.2065 22.0999C16.1549 22.1601 15.6732 21.73 13.9786 20.1042C8.31835 14.6934 8.5334 14.8827 8.03448 14.8827C7.69899 14.8827 7.59577 14.9257 7.3463 15.1752C7.09684 15.4246 7.05383 15.5279 7.05383 15.8547C7.05383 16.3365 6.98501 16.259 10.1506 19.2354C11.5011 20.4999 13.256 22.1601 14.056 22.9171C15.6302 24.4225 15.9485 24.6461 16.3872 24.5687C16.7399 24.4999 16.7743 24.4569 20.0947 20.6891C21.5485 19.0289 23.2689 17.0762 23.914 16.3451C29.4624 10.0655 30.6495 8.69775 30.77 8.48269C30.942 8.14721 30.8474 7.6999 30.5377 7.38162C30.3399 7.19237 30.2194 7.14076 29.9183 7.14076C29.7119 7.14936 29.471 7.19237 29.3678 7.25259Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-ef4acbe9"]]),lh=["value"],Ci=M(i.defineComponent({__name:"PCheckBox",props:i.mergeModels({label:{type:String,default:""},fontSize:{type:String,default:"14px"},value:{type:[String,Boolean],default:void 0},size:{type:String,default:"22px"},borderRadius:{type:String,default:""},padding:{type:String,default:""},margin:{type:String,default:""},width:{type:String,default:""}},{modelValue:{type:Boolean},modelModifiers:{}}),emits:i.mergeModels(["change"],["update:modelValue"]),setup(t,{emit:e}){const n=i.useModel(t,"modelValue"),r=e,o=()=>{r("change",n.value)};return(s,a)=>{const d=bi;return i.openBlock(),i.createElementBlock("div",{id:"some",class:"check-line",style:i.normalizeStyle({padding:t.padding,margin:t.margin,maxWidth:t.width})},[i.createElementVNode("label",{class:"check-field__label",style:i.normalizeStyle({fontSize:t.fontSize})},[i.withDirectives(i.createElementVNode("input",{"onUpdate:modelValue":a[0]||(a[0]=c=>n.value=c),class:"check-field__input",type:"checkbox",value:t.value,onChange:o},null,40,lh),[[i.vModelCheckbox,n.value]]),i.createElementVNode("div",{id:"abc",class:"box",style:i.normalizeStyle({width:t.size,height:t.size,borderRadius:t.borderRadius})},[n.value?(i.openBlock(),i.createElementBlock("div",{key:0,class:"check-icon",style:i.normalizeStyle({width:t.size,height:t.size})},[i.createVNode(d,{margin:"auto",size:t.size},null,8,["size"])],4)):i.createCommentVNode("",!0)],4),i.createTextVNode(" "+i.toDisplayString(t.label),1)],4)],4)}}}),[["__scopeId","data-v-5d8bdbbf"]]),ch=["for"],dh={class:"field"},uh={class:"left-field"},hh=["id","value","name"],fh={class:"right-field"},Po=M(i.defineComponent({__name:"PDatePicker",props:i.mergeModels({text:{type:String,default:"",required:!1},label:{type:String,default:"",required:!1},placeholder:{type:String,default:"",required:!1},margin:{type:String,required:!1,default:""},padding:{type:String,default:"",required:!1}},{modelValue:{required:!0},modelModifiers:{}}),emits:i.mergeModels(["blur","input"],["update:modelValue"]),setup(t,{emit:e}){const n=e,r=i.useModel(t,"modelValue"),o=a=>{const c=a.target.valueAsDate;c?(r.value=c,n("input",s(r.value))):(r.value=null,n("input",null))},s=a=>a?new Date(a.getTime()-a.getTimezoneOffset()*60*1e3).toISOString().split("T")[0]:"";return(a,d)=>(i.openBlock(),i.createElementBlock("div",{class:"text-field",style:i.normalizeStyle({margin:t.margin,padding:t.padding})},[t.label?(i.openBlock(),i.createElementBlock("label",{key:0,class:"text-field__label",for:t.label},i.toDisplayString(t.label),9,ch)):i.createCommentVNode("",!0),i.createElementVNode("div",dh,[i.createElementVNode("div",uh,[i.renderSlot(a.$slots,"default",{},void 0,!0)]),i.createElementVNode("input",{id:t.label,max:"2100",min:"1900",value:s(r.value),class:"text-field__input",type:"date",name:t.label,onInput:o},null,40,hh),i.createElementVNode("div",fh,[i.renderSlot(a.$slots,"right",{},void 0,!0)])])],4))}}),[["__scopeId","data-v-b77c7363"]]),Si=M(i.defineComponent({inheritAttrs:!1,__name:"PFlex",props:{margin:{type:String,default:"",required:!1},padding:{type:String,default:"",required:!1},width:{type:String,default:"",required:!1},minWidth:{type:String,default:"",required:!1},maxWidth:{type:String,default:"",required:!1},height:{type:String,default:"",required:!1},justifyContent:{type:String,default:"",required:!1},background:{type:String,default:"",required:!1},alignItems:{type:String,default:"",required:!1}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:"flex-line",style:i.normalizeStyle({margin:t.margin,padding:t.padding,width:t.width,minWidth:t.minWidth,maxWidth:t.maxWidth,height:t.height,justifyContent:t.justifyContent,background:t.background,alignItems:t.alignItems})},[i.renderSlot(e.$slots,"default",{},void 0,!0)],4))}}),[["__scopeId","data-v-6c788e9a"]]),ki=i.defineComponent({__name:"PInputDate",props:i.mergeModels({placeholder:{type:String,default:"Укажите дату"},width:{type:String,required:!1,default:"auto"},margin:{type:String,required:!1,default:""},label:{type:String,default:"",required:!1}},{modelValue:{default:new Date},modelModifiers:{}}),emits:i.mergeModels(["update:modelValue","change","beforeChange"],["update:modelValue"]),setup(t,{emit:e}){const n=e,r=i.useModel(t,"modelValue"),o=Le.Format(r.value),s=i.ref(o),a=c=>{if(!d(c))return;const u=Le.FromRuStr(c);r.value=u,n("beforeChange",u),n("change",u)},d=c=>c.length!=10?(s.value=o,S.Notification.Error("Неверный формат даты"),!1):Number(s.value.slice(0,2))>31?(s.value=o,S.Notification.Error("Неверный день месяца"),!1):Number(s.value.slice(3,5))>12?(s.value=o,S.Notification.Error("Неверный месяц"),!1):Number(s.value.slice(6,10))>2100?(s.value=o,S.Notification.Error("Неверный год"),!1):!0;return(c,u)=>{const h=ut;return i.openBlock(),i.createElementBlock("div",{class:"style-container",style:i.normalizeStyle({width:t.width,position:"relative"})},[i.createVNode(h,{modelValue:i.unref(s),"onUpdate:modelValue":u[0]||(u[0]=f=>i.isRef(s)?s.value=f:null),mask:"##.##.####",placeholder:t.placeholder,margin:t.margin,label:t.label,onBlur:a,onKeydown:i.withKeys(i.withModifiers(f=>{},["prevent"]),["enter"])},null,8,["modelValue","placeholder","margin","label","onKeydown"])],4)}}}),mh={class:"number"},To=M(i.defineComponent({__name:"PInputNumber",props:{modelValue:{type:Number,required:!0,default:0}},emits:["update:modelValue","change"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.modelValue??0),s=()=>{o.value++,r("update:modelValue",o.value),r("change")},a=()=>{o.value--,r("update:modelValue",o.value),r("change")},d=()=>{r("update:modelValue",o.value),r("change")};return(c,u)=>(i.openBlock(),i.createElementBlock("div",mh,[i.createElementVNode("button",{class:"number-minus",type:"button",onClick:a},u[1]||(u[1]=[i.createElementVNode("svg",{class:"icon-minus"},[i.createElementVNode("use",{"xlink:href":"#minus"})],-1)])),i.withDirectives(i.createElementVNode("input",{"onUpdate:modelValue":u[0]||(u[0]=h=>i.isRef(o)?o.value=h:null),class:"input-field",type:"number",min:"0",step:"0.1",onInput:d},null,544),[[i.vModelText,i.unref(o)]]),i.createElementVNode("button",{class:"number-plus",type:"button",onClick:s},u[2]||(u[2]=[i.createElementVNode("svg",{class:"icon-plus"},[i.createElementVNode("use",{"xlink:href":"#plus"})],-1)]))]))}}),[["__scopeId","data-v-f53b6419"]]),ph=["innerHTML"],gh={key:1},me=M(i.defineComponent({__name:"PString",props:{string:{type:String,required:!1,default:""},color:{type:String,required:!1,default:"var(--font-color)"},fontSize:{type:String,required:!1,default:"var(--font-size-default)"},fontWeight:{type:String,required:!1,default:""},background:{type:String,required:!1,default:""},padding:{type:String,required:!1,default:""},width:{type:String,required:!1,default:""},minWidth:{type:String,required:!1,default:""},margin:{type:String,required:!1,default:""},customClass:{type:String,required:!1,default:""},justifyContent:{type:String,required:!1,default:"center"},isHtml:{type:Boolean,required:!1,default:!1}},emits:["click"],setup(t){const e=t,n={color:e.color,fontSize:e.fontSize,fontWeight:e.fontWeight,background:e.background,padding:e.padding,width:e.width,maxWidth:e.width,minWidth:e.minWidth,margin:e.margin,justifyContent:e.justifyContent};return(r,o)=>(i.openBlock(),i.createElementBlock("div",{class:i.normalizeClass(["string",t.customClass]),style:n,onClick:o[0]||(o[0]=s=>r.$emit("click"))},[t.isHtml?(i.openBlock(),i.createElementBlock("span",{key:0,innerHTML:t.string},null,8,ph)):(i.openBlock(),i.createElementBlock("span",gh,i.toDisplayString(t.string),1))],2))}}),[["__scopeId","data-v-bd8f6c8f"]]),zo=M(i.defineComponent({__name:"PLeftSlider",props:{open:{type:Boolean,default:!1},shadow:{type:Boolean,default:!0},border:{type:Boolean,default:!0},shift:{type:Boolean,default:!0},widthClosed:{type:String,required:!1,default:"30px"},widthOpened:{type:String,required:!1,default:"300px"},titleOpen:{type:String,required:!1,default:"Скрыть меню"},titleClose:{type:String,required:!1,default:"Показать меню"},background:{type:String,required:!1,default:"inherit"}},emits:["open"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.open);i.watch(()=>n.open,()=>{o.value=!o.value});const s=a=>{o.value=!o.value,r("open",a)};return(a,d)=>{const c=me;return i.openBlock(),i.createElementBlock(i.Fragment,null,[t.shift?i.createCommentVNode("",!0):(i.openBlock(),i.createElementBlock("div",{key:0,style:i.normalizeStyle({minWidth:t.widthClosed,maxWidth:t.widthClosed})},null,4)),i.createElementVNode("div",{class:"LS-body",style:i.normalizeStyle({marginLeft:i.unref(o)?"0":`calc(${t.widthClosed} - ${t.widthOpened})`,minWidth:t.widthOpened,maxWidth:t.widthOpened,boxShadow:t.shadow?"5px 0 5px -3px rgba(0,0,0,0.3)":"none",position:t.shift?"relative":"absolute",background:t.background})},[i.createElementVNode("div",{class:"LS-content",style:i.normalizeStyle({width:`calc(${t.widthOpened} - ${t.widthClosed})`})},[i.renderSlot(a.$slots,"default",{},void 0,!0)],4),i.createElementVNode("div",{class:"click-line",style:i.normalizeStyle({width:t.widthClosed}),onClick:d[0]||(d[0]=u=>s(!i.unref(o)))},[i.unref(o)?(i.openBlock(),i.createBlock(c,{key:0,string:t.titleOpen,"font-size":"16px",padding:"0",color:"inherit"},null,8,["string"])):i.createCommentVNode("",!0),i.unref(o)?i.createCommentVNode("",!0):(i.openBlock(),i.createBlock(c,{key:1,string:t.titleClose,"font-size":"16px",padding:"0",color:"inherit"},null,8,["string"]))],4)],4)],64)}}}),[["__scopeId","data-v-3ea7497e"]]),Vo=M(i.defineComponent({__name:"PList",props:{margin:{type:String,required:!1,default:""},padding:{type:String,required:!1,default:""},width:{type:String,required:!1,default:"300px"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("ul",{style:i.normalizeStyle({margin:t.margin,padding:t.padding,width:t.width})},[i.renderSlot(e.$slots,"default",{},void 0,!0)],4))}}),[["__scopeId","data-v-84953e34"]]),Fo=M(i.defineComponent({__name:"PListItem",props:{margin:{type:String,required:!1,default:""},padding:{type:String,required:!1,default:""},showDivider:{type:Boolean,required:!1,default:!1}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("li",{style:i.normalizeStyle({margin:t.margin,padding:t.padding,borderBottom:t.showDivider?"1px solid":"none"})},[i.renderSlot(e.$slots,"default",{},void 0,!0)],4))}}),[["__scopeId","data-v-4cb3c766"]]),yh=["for"],wh=["id","name","checked","value"],Do=M(i.defineComponent({__name:"PRadio",props:i.mergeModels({label:{type:String,default:""},name:{type:String,default:"group"},fontSize:{type:String,default:"14px"},size:{type:String,default:"20px"},borderRadius:{type:String,default:""},padding:{type:String,default:""},margin:{type:String,default:""},width:{type:String,default:"auto"},value:{type:[String,Boolean],default:void 0}},{modelValue:{},modelModifiers:{}}),emits:i.mergeModels(["change"],["update:modelValue"]),setup(t,{emit:e}){const n=i.useModel(t,"modelValue"),r=e,o=t,s=S.H.Strings.CreateGuid(),a=i.computed(()=>n.value===o.value),d=()=>{r("change",o.value)};return(c,u)=>(i.openBlock(),i.createElementBlock("div",{class:"radio-line",style:i.normalizeStyle({padding:t.padding,margin:t.margin,maxWidth:t.width})},[i.createElementVNode("label",{class:"radio-field__label",for:i.unref(s),style:i.normalizeStyle({fontSize:t.fontSize})},[i.withDirectives(i.createElementVNode("input",{id:i.unref(s),"onUpdate:modelValue":u[0]||(u[0]=h=>n.value=h),name:t.name,checked:i.unref(a),class:"radio-field__input",type:"radio",value:t.value},null,8,wh),[[i.vModelRadio,n.value]]),i.createElementVNode("div",{class:"box",style:i.normalizeStyle({width:t.size,height:t.size,borderRadius:t.borderRadius}),onClick:d},[n.value===t.value?(i.openBlock(),i.createElementBlock("div",{key:0,class:"radio-dot",style:i.normalizeStyle({width:`calc(${t.size} - 50%)`,height:`calc(${t.size} - 50%)`})},null,4)):i.createCommentVNode("",!0)],4),i.createElementVNode("span",{onClick:d},i.toDisplayString(t.label),1)],12,yh)],4))}}),[["__scopeId","data-v-3cc907bd"]]),bh={class:"wrapper"},Ch={class:"content"},Lo=M(i.defineComponent({__name:"PRightSlider",props:{open:{type:Boolean,default:!1},shadow:{type:Boolean,default:!0},border:{type:Boolean,default:!0},shift:{type:Boolean,default:!0},widthClosed:{type:String,required:!1,default:"30px"},widthOpened:{type:String,required:!1,default:"300px"},titleOpen:{type:String,required:!1,default:"Скрыть"},titleClose:{type:String,required:!1,default:"Показать"},background:{type:String,required:!1,default:"inherit"}},emits:["open"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.open);i.watch(()=>n.open,()=>{o.value=!o.value});const s=a=>{o.value=!o.value,r("open",a)};return(a,d)=>{const c=me;return i.openBlock(),i.createElementBlock("div",bh,[i.createElementVNode("div",Ch,[i.renderSlot(a.$slots,"content",{},void 0,!0)]),i.createElementVNode("div",{class:"RS-body",style:i.normalizeStyle({marginRight:i.unref(o)?"0":`calc(${t.widthClosed} - ${t.widthOpened})`,minWidth:t.widthOpened,maxWidth:t.widthOpened,boxShadow:t.shadow?"-5px 0 5px -3px rgba(0,0,0,0.3)":"none",position:t.shift?"relative":"absolute"})},[i.createElementVNode("div",{class:"click-line",style:i.normalizeStyle({width:t.widthClosed}),onClick:d[0]||(d[0]=u=>s(!i.unref(o)))},[i.unref(o)?(i.openBlock(),i.createBlock(c,{key:0,string:t.titleOpen,"font-size":"16px",padding:"0",color:"inherit"},null,8,["string"])):i.createCommentVNode("",!0),i.unref(o)?i.createCommentVNode("",!0):(i.openBlock(),i.createBlock(c,{key:1,string:t.titleClose,"font-size":"16px",padding:"0",color:"inherit"},null,8,["string"]))],4),i.createElementVNode("div",{class:"RS-content",style:i.normalizeStyle({width:`calc(${t.widthOpened} - ${t.widthClosed} - 2px)`,background:t.background})},[i.renderSlot(a.$slots,"default",{},void 0,!0)],4)],4)])}}}),[["__scopeId","data-v-6f8cc35c"]]),Ei=M(i.defineComponent({__name:"IconSelectArrow",props:{size:{type:String,default:"20px"},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#arrow-down"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"arrow-down",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 20"},[i.createElementVNode("path",{d:"M3.08417 4.43062C2.86268 4.4769 2.70731 4.56285 2.52549 4.74467C2.29408 4.97607 2.20152 5.2174 2.22136 5.55459C2.25111 6.0207 1.96681 5.70996 6.78995 10.5397C9.18995 12.9463 11.2263 14.9662 11.309 15.029C11.5238 15.1843 11.7123 15.2471 11.99 15.2505C12.4693 15.2538 12.109 15.581 17.1106 10.5728C22.0891 5.58764 21.7288 5.98103 21.7255 5.505C21.7255 5.37607 21.7023 5.21078 21.6726 5.13145C21.5106 4.68186 21.0511 4.38434 20.5817 4.4174C20.1519 4.44715 20.4263 4.19591 16.0164 8.60252L11.9833 12.629L8.06598 8.71161C5.91061 6.55624 4.0726 4.73475 3.98003 4.66202C3.71227 4.45376 3.38499 4.36781 3.08417 4.43062Z",fill:"currentColor"}),i.createElementVNode("path",{d:"M9.69602 16.8994C9.70593 16.9292 9.72577 17.0184 9.73569 17.1044C9.76213 17.2664 9.7985 17.2994 9.83486 17.1903C9.84478 17.154 9.89106 17.1143 9.93734 17.1044C10.0464 17.078 10.0365 17.0548 9.87453 16.9589C9.6861 16.8465 9.67288 16.8432 9.69602 16.8994Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-db435ef1"]]),Vt=M(i.defineComponent({__name:"IconClose",props:{size:{type:String,default:"24px"},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#close"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"close",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 28 28"},[i.createElementVNode("path",{d:"M7.53508 7.18138C7.03684 7.5158 6.86132 8.14496 7.1161 8.66643C7.18971 8.8138 8.02201 9.69236 9.44881 11.1207C10.6718 12.345 11.8211 13.49 12.0023 13.6714L12.3251 14.0058L9.80551 16.5224C7.92576 18.4043 7.25199 19.1184 7.14441 19.3225C6.83867 19.9346 7.0425 20.5865 7.637 20.8926C7.89745 21.0286 8.41268 21.0343 8.6618 20.9096C8.76372 20.8585 10.0037 19.6626 11.4191 18.2455L14.001 15.6666L16.5432 18.2229C18.1964 19.8723 19.1703 20.8132 19.3232 20.8869C19.5779 21.0116 20.0309 21.0399 20.2913 20.9379C20.5178 20.8529 20.8632 20.5015 20.9368 20.2747C21.0274 19.9913 21.0161 19.5719 20.9028 19.3508C20.8519 19.2431 19.6516 17.9961 18.2361 16.5791L15.6656 14.0001L18.2191 11.4495C19.7138 9.95309 20.8179 8.80813 20.8858 8.6721C21.0104 8.42837 21.0387 7.98058 20.9425 7.73119C20.8519 7.50446 20.5971 7.23239 20.3593 7.11336C20.0988 6.97733 19.6516 6.96599 19.3628 7.08502C19.2212 7.14737 18.3097 8.01459 16.5771 9.74904L14.001 12.328L11.4191 9.75471C9.6583 7.99192 8.77504 7.14737 8.63349 7.08502C8.51459 7.03968 8.28246 7 8.1126 7C7.86347 7 7.76156 7.03401 7.53508 7.18138Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-8d8cfcf1"]]),Sh=["for"],kh={class:"field"},Eh={class:"left-field"},vh={class:"arrow"},Mh={selected:"",hidden:""},xh={class:"right-field"},it=M(i.defineComponent({inheritAttrs:!1,__name:"PSelect",props:i.mergeModels({label:{type:String,default:"",required:!1},placeholder:{type:String,default:"",required:!1},value:{type:String,default:"",required:!1},readonly:{type:Boolean,default:!1,required:!1},disabled:{type:Boolean,default:!1,required:!1},margin:{type:String,required:!1,default:""},padding:{type:String,required:!1,default:""},clearable:{type:Boolean,required:!1,default:!0},width:{type:String,required:!1,default:""},borderColor:{type:String,required:!1,default:""},color:{type:String,required:!1,default:""}},{modelValue:{},modelModifiers:{}}),emits:i.mergeModels(["change","clear"],["update:modelValue"]),setup(t,{emit:e}){const n=i.useModel(t,"modelValue"),r=i.ref(!0),o=e,s=i.ref(!1),a=()=>{r.value=!1,o("change",n.value)},d=()=>{o("clear",void 0),o("change",void 0),r.value=!0};return(c,u)=>{const h=Ei;return i.openBlock(),i.createElementBlock("div",{class:"text-field",style:i.normalizeStyle({margin:t.margin,padding:t.padding,width:t.width})},[t.label?(i.openBlock(),i.createElementBlock("label",{key:0,class:"text-field__label",for:t.label},i.toDisplayString(t.label),9,Sh)):i.createCommentVNode("",!0),i.createElementVNode("div",kh,[i.createElementVNode("div",Eh,[i.renderSlot(c.$slots,"left",{},void 0,!0)]),i.createElementVNode("div",{class:"sl",onMouseover:u[1]||(u[1]=f=>s.value=!0),onMouseleave:u[2]||(u[2]=f=>s.value=!1)},[t.clearable?i.withDirectives((i.openBlock(),i.createElementBlock("div",{key:0,class:"clear",onClick:d},[i.createVNode(Vt,{margin:"0"})],512)),[[i.vShow,i.unref(s)]]):i.createCommentVNode("",!0),i.createElementVNode("div",vh,[i.createVNode(h,{margin:"2px 2px 0 0"})]),i.withDirectives(i.createElementVNode("select",i.mergeProps(c.$attrs,{"onUpdate:modelValue":u[0]||(u[0]=f=>n.value=f),class:"text-field__input",onChange:a}),[i.createElementVNode("option",Mh,i.toDisplayString(t.placeholder),1),i.renderSlot(c.$slots,"default",{},void 0,!0)],16),[[i.vModelSelect,n.value]])],32),i.createElementVNode("div",xh,[i.renderSlot(c.$slots,"right",{},void 0,!0)])])],4)}}}),[["__scopeId","data-v-60aea6d2"]]),yn=M(i.defineComponent({__name:"PSticky",props:{shadow:{type:Boolean,default:!1},zIndex:{type:Number,default:0},background:{type:String,default:"inherit"},padding:{type:String,default:"0"},top:{type:String,default:"0"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:"sticky-block",style:i.normalizeStyle({zIndex:1+t.zIndex,top:t.top,background:t.background,padding:t.padding,boxShadow:t.shadow?"0 0 5px 2px rgba(0,0,0,0.3)":"none"})},[i.renderSlot(e.$slots,"default",{},void 0,!0)],4))}}),[["__scopeId","data-v-db44b76d"]]),Bh=["for"],Ih={class:"left-field"},Rh={class:"right-field"},Oo=M(i.defineComponent({__name:"PTextarea",props:i.mergeModels({label:{type:String,default:"",required:!1},margin:{type:String,required:!1,default:"0"},padding:{type:String,default:"0",required:!1},mask:{type:String,required:!1,default:void 0},borderColor:{type:String,default:"var(--input-border-color)",required:!1},color:{type:String,default:"var(--input-font-color)",required:!1}},{modelValue:{},modelModifiers:{}}),emits:i.mergeModels(["blur","input"],["update:modelValue"]),setup(t){const e=i.useModel(t,"modelValue");return(n,r)=>(i.openBlock(),i.createElementBlock("div",{class:"text-field",style:i.normalizeStyle({margin:t.margin,padding:t.padding})},[t.label?(i.openBlock(),i.createElementBlock("label",{key:0,class:"text-field__label",for:t.label},i.toDisplayString(t.label),9,Bh)):i.createCommentVNode("",!0),i.createElementVNode("div",{class:"field",style:i.normalizeStyle({borderColor:t.borderColor})},[i.createElementVNode("div",Ih,[i.renderSlot(n.$slots,"default",{},void 0,!0)]),i.withDirectives(i.createElementVNode("textarea",i.mergeProps(n.$attrs,{"onUpdate:modelValue":r[0]||(r[0]=o=>e.value=o),class:"text-field__input",style:{color:t.color},onBlur:r[1]||(r[1]=o=>n.$emit("blur",e.value)),onInput:r[2]||(r[2]=o=>n.$emit("input",e.value))}),null,16),[[i.vModelText,e.value],[i.unref(mo),t.mask]]),i.createElementVNode("div",Rh,[i.renderSlot(n.$slots,"right",{},void 0,!0)])],4)],4))}}),[["__scopeId","data-v-172b61e5"]]),$h={class:"top-slider-content"},Nh={class:"center"},Ho=M(i.defineComponent({__name:"PTopSlider",props:{sliderOffHeight:{type:String,required:!1,default:"53px"},sliderOnHeight:{type:String,required:!1,default:"220px"},background:{type:String,required:!1,default:"inherit"},open:{type:Boolean,default:!1}},emits:["open"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.open);i.watch(()=>n.open,()=>{o.value=!o.value});const s=a=>{o.value=!o.value,r("open",a)};return(a,d)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[i.unref(o)?i.createCommentVNode("",!0):(i.openBlock(),i.createElementBlock("div",{key:0,class:"blur",onClick:[d[0]||(d[0]=i.withModifiers(c=>o.value=!0,["prevent"])),d[1]||(d[1]=i.withModifiers(()=>{},["stop"]))]})),i.createElementVNode("div",{class:"top-slider",style:i.normalizeStyle({marginTop:i.unref(o)?"0":`calc(${t.sliderOffHeight} - ${t.sliderOnHeight})`,height:t.sliderOnHeight}),onClick:d[3]||(d[3]=i.withModifiers(()=>{},["stop"]))},[i.createElementVNode("div",$h,[i.createElementVNode("div",Nh,[i.renderSlot(a.$slots,"default",{},void 0,!0)])]),i.createElementVNode("div",{class:"click-line",style:i.normalizeStyle({height:t.sliderOffHeight}),onClick:d[2]||(d[2]=c=>s(!i.unref(o)))},[i.renderSlot(a.$slots,"title",{},void 0,!0)],4)],4)],64))}}),[["__scopeId","data-v-12ffd2e2"]]),Ft=M(i.defineComponent({__name:"PModal",props:{showCloseDialog:{type:Boolean,required:!1,default:!1},closable:{type:Boolean,required:!1,default:!1},show:{type:Boolean,default:!1},title:{type:String,default:""},width:{type:String,default:"760px"},margin:{type:String,default:"auto"},top:{type:String,default:"20vh"},padding:{type:String,default:"var(--modal-window-padding)"},showClose:{type:Boolean,default:!1}},emits:["save","close"],setup(t,{emit:e}){const n=t,r=e,o=a=>{a.key==="Escape"&&s()};i.onMounted(()=>{document.body.addEventListener("keydown",o)}),i.onBeforeUnmount(()=>{document.body.removeEventListener("keydown",o)});const s=()=>{n.closable&&r("close")};return(a,d)=>{const c=Vt;return i.openBlock(),i.createElementBlock(i.Fragment,null,[t.show?(i.openBlock(),i.createElementBlock("div",{key:0,class:"blur",onClick:s})):i.createCommentVNode("",!0),t.show?(i.openBlock(),i.createElementBlock("div",{key:1,class:"modal-w",style:i.normalizeStyle({maxWidth:t.width,width:t.width,margin:t.margin,padding:t.padding,top:t.top})},[t.closable?(i.openBlock(),i.createElementBlock("div",{key:0,class:"icon-box",onClick:s},[i.createVNode(c,{size:"20px"})])):i.createCommentVNode("",!0),i.renderSlot(a.$slots,"default",{},void 0,!0)],4)):i.createCommentVNode("",!0)],64)}}}),[["__scopeId","data-v-41f0eae5"]]),_o=i.defineComponent({__name:"AuthModal",emits:["submit"],setup(t){const e=()=>{S.Auth.Form.Reset(),S.Auth.Modal.Close()};return(n,r)=>{const o=dn,s=Ft;return i.openBlock(),i.createBlock(s,{show:("PF"in n?n.PF:i.unref(S)).Auth.Modal.IsVisible(),closable:("PF"in n?n.PF:i.unref(S)).Auth.Modal.IsClosable(),onClose:e},{default:i.withCtx(()=>[i.createVNode(o,{width:"760px",onAction:r[0]||(r[0]=a=>n.$emit("submit"))})]),_:1},8,["show","closable"])}}}),Dt=M(i.defineComponent({__name:"GridContainer",props:{maxWidth:{type:String,required:!1,default:""},width:{type:String,required:!1,default:"100%"},background:{type:String,required:!1,default:"inherit"},gridGap:{type:String,required:!1,default:"10px"},gridTemplateColumns:{type:String,required:!1,default:"repeat(auto-fit, minmax(250px, 1fr))"},gridTemplateRows:{type:String,required:!1,default:"repeat(0 0px)"},margin:{type:String,required:!1,default:"10px 0 0 0"},customClass:{type:String,required:!1,default:""}},setup(t){return i.useCssVars(e=>({59355408:t.maxWidth,"24aaa640":t.width,"0833ce18":t.background,"65d0bfaa":t.gridGap,"2373d8d7":t.gridTemplateColumns,ea2919c2:t.gridTemplateRows,"5f2f1c74":t.margin})),(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:i.normalizeClass(["grid-block",t.customClass])},[i.renderSlot(e.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-352a1099"]]);var Oe=(t=>(t.None="None",t.Next="Next",t.Prev="Prev",t))(Oe||{});const Ah={class:"container"},Ph={class:"slide-box"},Th={class:"link-number"},zh=["id","onClick"],qo=M(i.defineComponent({__name:"CarouselImages",props:{events:{type:Array,required:!0},quantity:{type:Number,default:1,required:!1},animationTime:{type:Number,default:500},height:{type:String,default:"360px"},maxHeight:{type:String,default:"360px"},startActiveGroupIndex:{type:Number,default:0}},emits:["openModalWindow"],setup(t){i.useCssVars(g=>({"17adb052":n}));const e=t,n=`${e.animationTime}ms`,r=i.ref(e.startActiveGroupIndex),o=i.ref(Oe.None),s=i.ref(lo(e.events,e.quantity)),a=i.computed(()=>s.value[r.value]);i.onMounted(()=>{});const d=()=>r.value=r.value+1<s.value.length?r.value+1:0,c=()=>r.value=r.value-1<0?s.value.length-1:r.value-1,u=g=>{o.value=g,setTimeout(()=>o.value=Oe.None,e.animationTime)},h=g=>{g!=r.value&&(u(g<r.value?Oe.Prev:Oe.Next),setTimeout(()=>r.value=g,e.animationTime/2))},f=()=>{u(Oe.Next),setTimeout(d,e.animationTime/2)},m=()=>{u(Oe.Prev),setTimeout(c,e.animationTime/2)};return(g,p)=>(i.openBlock(),i.createElementBlock("div",{class:"field",style:i.normalizeStyle({height:t.height,maxHeight:t.maxHeight})},[i.createElementVNode("div",Ah,[(i.openBlock(),i.createElementBlock("svg",{class:"icon-arrow",onClick:p[0]||(p[0]=i.withModifiers(k=>m(),["stop"]))},p[2]||(p[2]=[i.createElementVNode("use",{"xlink:href":"#arrow-prev"},null,-1)]))),i.createElementVNode("div",Ph,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(a),(k,w)=>(i.openBlock(),i.createElementBlock("div",{key:w,class:i.normalizeClass({animationnext:i.unref(o)===i.unref(Oe).Next,animationprev:i.unref(o)===i.unref(Oe).Prev})},p[3]||(p[3]=[i.createElementVNode("div",{class:"image"},[i.createElementVNode("div",{class:"image-box"})],-1)]),2))),128))]),(i.openBlock(),i.createElementBlock("svg",{class:"icon-arrow",onClick:p[1]||(p[1]=i.withModifiers(k=>f(),["stop"]))},p[4]||(p[4]=[i.createElementVNode("use",{"xlink:href":"#arrow-next"},null,-1)])))]),i.createElementVNode("div",Th,[i.createVNode(Dt,{"grid-template-columns":"repeat(auto-fit, minmax(26px, 1fr))","grid-gap":"5px",margin:"0"},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(s),(k,w)=>(i.openBlock(),i.createElementBlock("div",{id:w.toString(),key:w,class:"number",style:i.normalizeStyle({background:w.toString()===i.unref(r).toString()?"#9D9D9D":""}),onClick:i.withModifiers(B=>h(w),["stop"])},i.toDisplayString(w+1),13,zh))),128))]),_:1})])],4))}}),[["__scopeId","data-v-3493284a"]]),Uo=i.defineComponent({__name:"ContextWindow",props:{x:{type:Number,default:-1},y:{type:Number,default:-1}},emits:["close"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.x),s=i.ref(n.y),a=i.computed(()=>o.value+"px"),d=i.computed(()=>s.value+"px"),c=()=>{r("close")};return(u,h)=>{const f=i.resolveDirective("click-outside");return i.withDirectives((i.openBlock(),i.createElementBlock("div",{class:"context-window",style:i.normalizeStyle({left:i.unref(a),top:i.unref(d)})},[i.renderSlot(u.$slots,"default")],4)),[[f,c]])}}}),Vh={class:"date-range"},Wo=M(i.defineComponent({__name:"DateInputRange",props:{start:{type:Date,default:void 0},end:{type:Date,default:void 0}},emits:["update:start","update:end","setStart","setEnd"],setup(t,{emit:e}){const n=t,r=e;i.watch(()=>[n.start,n.end],()=>{n.start||(o.value=void 0),n.end||(s.value=void 0)});const o=i.ref(n.start),s=i.ref(n.end),a=c=>{if(o.value=c,!n.end||c>n.end){S.Notification.Warning("Дата начала больше даты окончания");return}r("update:start",c),r("setStart",c)},d=c=>{if(s.value=c,!n.start||c<n.start){S.Notification.Warning("Дата начала больше даты окончания");return}r("update:end",c),r("setEnd",c)};return(c,u)=>{const h=ki;return i.openBlock(),i.createElementBlock("div",Vh,[i.createVNode(h,{"model-value":i.unref(o),"onUpdate:modelValue":u[0]||(u[0]=f=>i.isRef(o)?o.value=f:null),onChange:a},null,8,["model-value"]),u[2]||(u[2]=i.createTextVNode(" - ")),i.createVNode(h,{"model-value":i.unref(s),"onUpdate:modelValue":u[1]||(u[1]=f=>i.isRef(s)?s.value=f:null),onChange:d},null,8,["model-value"])])}}}),[["__scopeId","data-v-69b3ebc4"]]),Fh=i.defineComponent({name:"DateInputRangeV2"}),Dh={class:"date-range"};function Lh(t,e,n,r,o,s){return i.openBlock(),i.createElementBlock("div",Dh,[i.renderSlot(t.$slots,"default",{},void 0,!0)])}const Go=M(Fh,[["render",Lh],["__scopeId","data-v-80580591"]]),Oh={class:"drop-item"},Hh={key:0,class:"drop-item-list"},jo=M(i.defineComponent({__name:"DropList",props:{name:{type:String,default:"Name"},rolledUp:{type:Boolean,default:!0}},setup(t){const e=t,n=i.ref(e.rolledUp),r=async()=>{n.value=!n.value};return(o,s)=>{const a=me,d=i.resolveComponent("IconArrowDrop");return i.openBlock(),i.createElementBlock("div",Oh,[i.createElementVNode("div",{class:"drop-item-name",onClick:s[0]||(s[0]=c=>r())},[i.createVNode(a,{"font-size":"13px","font-weight":"600",string:t.name,"justify-content":"left",width:"auto",margin:"0 5px 0 0",padding:"6px 0",color:"inherit"},null,8,["string"]),i.createElementVNode("div",{style:i.normalizeStyle({transform:i.unref(n)?"":"rotate(-90deg)",display:"flex",alignItems:"center",margin:"0 0 2px 0"})},[i.createVNode(d,{size:"10px",margin:"0"})],4)]),i.unref(n)?(i.openBlock(),i.createElementBlock("div",Hh,[i.renderSlot(o.$slots,"default",{},void 0,!0)])):i.createCommentVNode("",!0)])}}}),[["__scopeId","data-v-75ec18f4"]]),Zo=M(i.defineComponent({__name:"FilterCheckbox",props:{model:{type:Object,default:()=>new Ln,required:!0}},emits:["load"],setup(t,{emit:e}){const n=t,r=i.ref(!1),o=e,s=()=>{n.model.setBoolean(r.value),r.value?S.H.FTSP.Get().setF(n.model):S.H.FTSP.Get().removeF(n.model),o("load")};return(a,d)=>{const c=Ci;return i.openBlock(),i.createBlock(c,{modelValue:i.unref(r),"onUpdate:modelValue":d[0]||(d[0]=u=>i.isRef(r)?r.value=u:null),label:t.model.label,size:"mini",onChange:s},null,8,["modelValue","label"])}}}),[["__scopeId","data-v-c8f7d6ec"]]),_h={key:0,class:"blur"},qh={style:{display:"flex","justify-content":"center"}},rt=M(i.defineComponent({__name:"InfoItem",props:{background:{type:String,required:!1,default:""},padding:{type:String,required:!1,default:""},width:{type:String,required:!1,default:""},openWidth:{type:String,required:!1,default:"auto"},openHeight:{type:String,required:!1,default:"auto"},maxWidth:{type:String,required:!1,default:""},minWidth:{type:String,required:!1,default:""},margin:{type:String,required:!1,default:""},height:{type:String,required:!1,default:""},withOpenWindow:{type:Boolean,required:!1,default:!0},colorSelected:{type:String,required:!1,default:"#1979CF"},borderColor:{type:String,required:!1,default:"#E3E3E3"},withHover:{type:Boolean,required:!1,default:!0},title:{type:String,required:!1,default:""},customClass:{type:String,required:!1,default:""},close:{type:Boolean,required:!1,default:!0},baseBoxMargin:{type:String,required:!1,default:""},closeWindowOverflow:{type:String,required:!1,default:""},showSaveDialog:{type:Boolean,required:!1,default:!1}},emits:["click","keyup-enter","after-close"],setup(t,{emit:e}){const n=t,r=e,o=n.customClass!==""?n.customClass:"inside-class",s=i.ref(!1),a=i.ref(!1),d=i.ref(!1),c=i.ref(n.close);i.watch(()=>n.close,()=>{a.value=!1});const u=V=>{V.stopPropagation(),V.key==="Escape"&&(n.showSaveDialog?d.value=!0:a.value=!1)};i.watch(a,async()=>{var V,T;await i.nextTick(),a.value?((T=(V=document.getElementById("info-item-opened-content"))==null?void 0:V.querySelector("input"))==null||T.focus(),document.body.addEventListener("keydown",u)):document.body.removeEventListener("keydown",u,!1),a.value===!1&&r("after-close")});const h=()=>{r("click"),a.value=!!n.withOpenWindow,c.value!==n.close&&(a.value=!1,c.value=!c.value)},f=i.computed(()=>n.customClass===""?{width:n.width,minHeight:"40px",height:"auto",maxWidth:n.maxWidth,minWidth:n.minWidth,margin:n.baseBoxMargin}:void 0),m=i.computed(()=>a.value&&n.withOpenWindow),g=i.computed(()=>({background:n.background?n.background:void 0,zIndex:m.value?"2":"0",padding:m.value?"0":n.padding,margin:n.margin,width:m.value?n.openWidth:n.width,height:m.value?n.openHeight:n.height,minHeight:"40px",maxWidth:n.maxWidth,minWidth:n.minWidth,borderColor:s.value||a.value?n.colorSelected:n.borderColor,color:s.value?n.colorSelected:"#343E5C",boxShadow:s.value||a.value?`0px 0px 1px 1px ${n.colorSelected}`:"none",alignItems:m.value?"end":"center",cursor:(n.withHover,"pointer")})),p=i.computed(()=>({height:m.value?"0":"",overflow:n.closeWindowOverflow,width:n.width})),k=i.computed(()=>({height:m.value?"auto":"0"})),w=i.computed(()=>({color:s.value?n.colorSelected:"#343E5C",fill:s.value?n.colorSelected:"#343E5C",background:n.background})),B=()=>{n.showSaveDialog?d.value=!0:a.value=!1},D=async()=>{await r("keyup-enter"),n.close&&(a.value=!1),d.value=!1},L=()=>{a.value=!1,d.value=!1};return(V,T)=>{const be=me,ve=Se,Ze=Ft,St=i.resolveDirective("click-outside");return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.unref(a)?(i.openBlock(),i.createElementBlock("div",_h)):i.createCommentVNode("",!0),i.createElementVNode("div",{class:"base-box",style:i.normalizeStyle(i.unref(f)),onClick:T[2]||(T[2]=i.withModifiers(Nn=>h(),["prevent","stop"]))},[i.createElementVNode("div",{class:i.normalizeClass(["body",i.unref(o)]),style:i.normalizeStyle(i.unref(g)),onMouseenter:T[0]||(T[0]=Nn=>t.withHover?s.value=!0:s.value=!1),onMouseleave:T[1]||(T[1]=Nn=>s.value=!1)},[i.unref(a)?i.createCommentVNode("",!0):(i.openBlock(),i.createElementBlock("div",{key:0,class:i.normalizeClass(["close-window",t.customClass]),style:i.normalizeStyle(i.unref(p))},[i.renderSlot(V.$slots,"default",{},void 0,!0)],6)),i.unref(a)?i.withDirectives((i.openBlock(),i.createElementBlock("div",{key:1,id:"info-item-opened-content",class:"open-window",style:i.normalizeStyle(i.unref(k))},[i.renderSlot(V.$slots,"open-inside-content",{},void 0,!0)],4)),[[St,B,void 0,{prevent:!0}]]):i.createCommentVNode("",!0),i.createElementVNode("div",{class:"top-title",style:i.normalizeStyle(i.unref(w))},[i.renderSlot(V.$slots,"title",{},()=>[i.createVNode(be,{string:t.title,"font-size":"10px",padding:"0 0 0 3px",style:i.normalizeStyle({color:i.unref(s)?"#006BB4":"#c4c4c4",transition:"0.2s"})},null,8,["string","style"])],!0)],4)],38)],4),i.createVNode(Ze,{show:i.unref(d),title:"У вас остались несохраненные изменения, вы уверены что хотите закрыть окно?"},{default:i.withCtx(()=>[i.createElementVNode("div",qh,[i.createVNode(ve,{text:"Не сохранять",onClick:L}),i.createVNode(ve,{text:"Сохранять",onClick:D})])]),_:1},8,["show"])],64)}}}),[["__scopeId","data-v-4788a262"]]),Jo=M(i.defineComponent({__name:"FiltersButtonsSelect",props:{models:{type:Array,default:()=>[]},defaultLabel:{type:String,default:"Все"},inverse:{type:Boolean,required:!1,default:!1}},emits:["load"],setup(t,{emit:e}){const n=e,r=i.ref(void 0),o=async a=>{S.H.FTSP.Get().replaceF(a,r.value),r.value=a,S.H.FTSP.Get().p.drop()},s=async a=>{await o(a),n("load")};return(a,d)=>{const c=me,u=Se,h=Dt,f=rt;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createVNode(c,{string:t.defaultLabel,"font-size":"14px",padding:"0",margin:"20px 0 0 10px"},null,8,["string"]),i.createVNode(f,{margin:"5px 0 0 0px","with-open-window":!1,height:"auto",background:"#F5F5F5","border-color":"#C4C4C4",padding:"7px","with-hover":!1},{title:i.withCtx(()=>d[0]||(d[0]=[])),default:i.withCtx(()=>[i.createVNode(h,{"max-width":"100%","grid-gap":"7px","grid-template-columns":"repeat(auto-fit, minmax(100%, 1fr))",margin:"0px"},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(t.models,(m,g)=>(i.openBlock(),i.createBlock(u,{key:g,color:"blue",height:"auto",text:m.label,"is-toggle":m.valueEq(i.unref(r)),"toggle-mode":!0,inverse:t.inverse,onClick:p=>s(m.valueEq(i.unref(r))?void 0:m)},null,8,["text","is-toggle","inverse","onClick"]))),128))]),_:1})]),_:1})],64)}}}),[["__scopeId","data-v-3725dd8f"]]),Uh=["value","label"],Xo=M(i.defineComponent({__name:"FilterSelect",props:{models:{type:Array,default:()=>[]},defaultLabel:{type:String,default:"Все"},inverse:{type:Boolean,required:!1,default:!1}},emits:["load"],setup(t,{emit:e}){const n=e,r=S.H.FTSP.Get(),o=i.ref(void 0),s=async d=>{r.replaceF(d,o.value),o.value=d},a=async d=>{d?await s(o.value):await s(void 0),n("load")};return(d,c)=>{const u=it;return i.openBlock(),i.createBlock(u,{modelValue:i.unref(o),"onUpdate:modelValue":c[0]||(c[0]=h=>i.isRef(o)?o.value=h:null),clearable:i.unref(o),placeholder:t.defaultLabel,onChange:a},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(t.models,(h,f)=>(i.openBlock(),i.createElementBlock("option",{key:f,value:h,label:h.label},null,8,Uh))),128))]),_:1},8,["modelValue","clearable","placeholder"])}}}),[["__scopeId","data-v-b5c8a87a"]]),Yo=M(i.defineComponent({__name:"FTSPPanel",setup(t){return i.onBeforeMount(async()=>{}),(e,n)=>(i.openBlock(),i.createElementBlock("div"))}}),[["__scopeId","data-v-36d19577"]]),Qo=M(i.defineComponent({__name:"GeneralItem",props:{background:{type:String,required:!1,default:"#ffffff"},height:{type:String,required:!1,default:"40px"},width:{type:String,required:!1,default:"auto"},ready:{type:String,required:!1,default:"0%"},padding:{type:String,required:!1,default:"10px"},borderColor:{type:String,required:!1,default:"#343D5C"},margin:{type:String,required:!1,default:"5px"},scale:{type:Boolean,required:!1,default:!0},fontSize:{type:String,required:!1,default:"14px"},withIcon:{type:Boolean,required:!1,default:!1}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock("div",{class:"general-block-item",style:i.normalizeStyle({background:t.background,height:t.height,width:t.width,borderColor:t.borderColor,padding:t.padding,margin:t.margin,transform:t.scale&&i.unref(e)?"scale(1.03, 1.03)":""}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},[i.createElementVNode("div",{class:"green",style:i.normalizeStyle({width:`${t.ready}`})},null,4),i.createElementVNode("div",{class:"general-block-item-title",style:i.normalizeStyle({fontSize:t.fontSize})},[i.renderSlot(n.$slots,"general-item",{},void 0,!0)],4),i.createElementVNode("div",{class:"tools-icon",style:i.normalizeStyle({display:t.withIcon?"flex":"none"})},r[2]||(r[2]=[i.createElementVNode("svg",{class:"icon-del"},[i.createElementVNode("use",{"xlink:href":"#del"})],-1)]),4),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"del",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 10 10"},[i.createElementVNode("path",{d:"M2.91797 8.75C2.6888 8.75 2.49255 8.66833 2.32922 8.505C2.16589 8.34167 2.08436 8.14556 2.08464 7.91667V2.5H1.66797V1.66667H3.7513V1.25H6.2513V1.66667H8.33464V2.5H7.91797V7.91667C7.91797 8.14583 7.8363 8.34208 7.67297 8.50542C7.50964 8.66875 7.31352 8.75028 7.08464 8.75H2.91797ZM7.08464 2.5H2.91797V7.91667H7.08464V2.5ZM3.7513 7.08333H4.58464V3.33333H3.7513V7.08333ZM5.41797 7.08333H6.2513V3.33333H5.41797V7.08333Z"})])],-1))],36))}}),[["__scopeId","data-v-d7e51e08"]]),Ko=M(i.defineComponent({__name:"IconDownload",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#download"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"download",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},[i.createElementVNode("path",{d:"M15.6443 5.06141C15.0797 5.29331 15.0998 5.06141 15.0998 12.1393C15.0998 15.7388 15.0696 18.6728 15.0293 18.6728C14.9889 18.6728 14.1521 17.8763 13.1842 16.9083C11.6819 15.4061 11.3592 15.1338 11.0467 15.0733C10.724 15.0229 10.6333 15.0632 10.3611 15.3254C10.1292 15.5573 10.0586 15.7186 10.0586 16.0211C10.0586 16.3941 10.1594 16.5151 12.8615 19.2071C15.4326 21.7681 15.6947 22 16.0073 22C16.3198 22 16.582 21.7681 19.153 19.2071C21.9156 16.4546 21.9559 16.4042 21.9559 15.9908C21.9559 15.4867 21.6535 15.1641 21.109 15.0733C20.736 15.0128 20.7259 15.0229 18.8808 16.868C17.0357 18.6929 17.0155 18.7131 17.0155 18.3703C17.0054 18.1787 16.9953 15.2145 16.9853 11.7965L16.9651 5.56554L16.713 5.31348C16.4307 5.03117 15.9669 4.92026 15.6443 5.06141Z"}),i.createElementVNode("path",{d:"M5.30247 20.3872L5 20.6997L5.04033 22.081C5.07058 23.4321 5.08066 23.4825 5.44363 24.2488C6.09899 25.6099 7.17782 26.5173 8.59945 26.8904C9.47663 27.1122 22.5335 27.1223 23.4006 26.8904C25.044 26.4669 26.3245 25.2671 26.8084 23.7043C26.9496 23.2506 27 22.7868 27 21.8794C27 20.6796 27 20.6695 26.7076 20.3771C26.3144 19.9839 25.901 19.9839 25.4675 20.3771L25.1347 20.6695L25.1045 21.8189C25.0843 22.8776 25.0541 23.0086 24.7516 23.6035C24.3987 24.3093 23.7938 24.8235 23.088 25.0251C22.5839 25.1663 9.4363 25.1663 8.93217 25.0251C8.30706 24.8436 7.64161 24.3093 7.29881 23.7144C7.00642 23.2002 6.98625 23.0691 6.93584 21.9197L6.88543 20.6695L6.5527 20.3771C6.11916 19.9839 5.70577 19.9839 5.30247 20.3872Z"})])],-1))],64))}}),[["__scopeId","data-v-40934683"]]),es=M(i.defineComponent({__name:"IconFilter",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#filter"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"filter",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},[i.createElementVNode("path",{d:"M8.58216 5.14236C6.22884 5.77558 4.70721 8.02494 5.04745 10.3688C5.61452 14.2627 10.3684 15.8127 13.0714 12.9962C13.6385 12.4103 14.319 11.2194 14.319 10.8225C14.319 10.6902 14.9428 10.6713 20.3771 10.6713H26.4353L26.7094 10.3972C27.0969 10.0097 27.0969 9.44261 26.7094 9.05511L26.4353 8.78103H20.396H14.3662L14.1867 8.23287C13.4589 5.9646 10.8599 4.52803 8.58216 5.14236ZM10.9638 7.21215C13.0525 8.24232 13.0336 11.2194 10.9355 12.2496C10.2172 12.5993 9.20593 12.6276 8.54436 12.2968C6.21939 11.1533 6.43676 7.81702 8.8846 7.01368C9.45166 6.8341 10.3495 6.91916 10.9638 7.21215Z"}),i.createElementVNode("path",{d:"M21.5953 17.6266C21.1133 17.7211 20.2155 18.0519 19.8752 18.2599C18.9868 18.7986 18.0322 20.0083 17.8054 20.8778L17.6826 21.3504H12.3616C6.66257 21.3504 6.63422 21.3504 6.37904 21.8135C6.20892 22.1443 6.26562 22.6452 6.51135 22.9287L6.73818 23.1933L12.1915 23.2406L17.6448 23.2878L17.8621 23.8738C18.4292 25.4427 19.7334 26.6052 21.2929 26.936C22.1057 27.1061 23.3154 27.0021 24.062 26.6997C25.3379 26.1799 26.4059 25.0174 26.8029 23.7037C26.9635 23.165 27.0013 22.8625 26.9635 22.0781C26.9352 21.1991 26.8974 21.0479 26.5855 20.3864C25.8105 18.7513 24.2794 17.7117 22.5499 17.6172C22.1529 17.5983 21.7276 17.6077 21.5953 17.6266ZM23.5517 19.8004C24.081 20.0556 24.5913 20.5754 24.8748 21.1519C24.9977 21.4071 25.045 21.7095 25.045 22.3427C25.045 23.1555 25.0261 23.2311 24.7236 23.7415C23.5611 25.6412 20.8014 25.5656 19.7902 23.5997C19.5066 23.0421 19.4405 22.0119 19.6484 21.3787C20.1682 19.8004 22.0206 19.0537 23.5517 19.8004Z"})])],-1))],64))}}),[["__scopeId","data-v-496ff188"]]),ts=M(i.defineComponent({__name:"IconArrowLeft",props:{size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#arrow-left"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"arrow-left",fill:"none",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},[i.createElementVNode("path",{d:"M13.4323 2.0816C13.3788 2.0909 13.2951 2.12113 13.2462 2.14904C13.1997 2.17462 11.5439 3.85601 9.56715 5.8816C6.70668 8.81648 5.96017 9.59322 5.90436 9.69787C5.84622 9.8095 5.83691 9.85601 5.83691 9.99787C5.83691 10.1397 5.84622 10.1886 5.90436 10.2979C6.00436 10.4886 13.102 17.7746 13.2764 17.8653C13.3695 17.9142 13.423 17.9258 13.5555 17.9258C13.916 17.9235 14.1788 17.6583 14.1788 17.2932C14.1788 17.0374 14.1392 16.9769 13.623 16.4467C13.3695 16.1862 11.8555 14.6328 10.2555 12.9909C8.65552 11.349 7.35087 9.99787 7.35552 9.9909C7.36017 9.9816 8.86715 8.43276 10.7044 6.54904C12.5416 4.66532 14.0671 3.08392 14.0951 3.03508C14.2392 2.79555 14.1951 2.45834 13.9927 2.25834C13.8462 2.1095 13.6323 2.04206 13.4323 2.0816Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-11a9207f"]]),ns=M(i.defineComponent({__name:"IconEdit",props:{size:{type:String,default:""},margin:{type:String,default:"0 15px 0 0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#edit"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"edit",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},[i.createElementVNode("path",{d:"M21.993 4.16087C21.6831 4.26049 21.2404 4.48185 20.9969 4.64787C20.1778 5.22342 4.60489 20.9402 4.39459 21.4051C4.11789 22.0138 3 25.8434 3 26.1865C3 26.5961 3.30991 27.1938 3.65302 27.4373C4.2507 27.8689 4.58275 27.8468 6.88493 27.1716C8.06923 26.8174 9.23138 26.4411 9.47488 26.3194C10.0062 26.0537 25.4795 10.6468 26.0772 9.79458C26.8519 8.67669 26.9626 7.32637 26.3871 6.10887C25.6234 4.48185 23.6754 3.61853 21.993 4.16087ZM24.0406 6.25276C24.7379 6.70655 25.0035 7.69162 24.6272 8.44426C24.4501 8.78737 9.331 24.0393 8.73332 24.471C8.48982 24.6481 5.2247 25.6995 5.13616 25.6331C5.11402 25.611 5.42393 24.5042 5.82239 23.1871L6.12123 22.1909L14.1125 14.1886C22.5243 5.76576 22.4911 5.79896 23.3101 5.94285C23.4983 5.97605 23.8192 6.11994 24.0406 6.25276Z",fill:"currentColor"}),i.createElementVNode("path",{d:"M15.098 25.9216C14.5446 26.1872 14.4118 27.1169 14.8656 27.5265C15.0759 27.7146 15.4743 27.7257 21.1302 27.7589C25.325 27.781 27.273 27.7478 27.4722 27.6703C28.0367 27.4268 28.1806 26.6521 27.7489 26.154L27.4833 25.8441L21.4069 25.822C17.2674 25.8109 15.264 25.833 15.098 25.9216Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-74cd505c"]]),is=M(i.defineComponent({__name:"IconEmail",props:{size:{type:String,default:""},margin:{type:String,default:"0 10px 0 0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#email"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"email",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[i.createElementVNode("path",{d:"M20 20H4C3.46957 20 2.96086 19.7893 2.58579 19.4142C2.21071 19.0391 2 18.5304 2 18V5.913C2.02243 5.39779 2.24301 4.91116 2.61568 4.5547C2.98835 4.19824 3.4843 3.99951 4 4H20C20.5304 4 21.0391 4.21071 21.4142 4.58579C21.7893 4.96086 22 5.46957 22 6V18C22 18.5304 21.7893 19.0391 21.4142 19.4142C21.0391 19.7893 20.5304 20 20 20ZM4 7.868V18H20V7.868L12 13.2L4 7.868ZM4.8 6L12 10.8L19.2 6H4.8Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-b89c9521"]]),rs=M(i.defineComponent({__name:"IconMove",props:{size:{type:String,default:"24px"},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#icon-move"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"icon-move",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 22 22"},[i.createElementVNode("path",{d:"M8.91736 3.08529L6.83471 5.17059H8.0843H9.33058V7.25588V9.34117H7.24793H5.16529L5.15868 8.09993L5.14876 6.85868L3.07273 8.93404L1 11.0127L3.08264 13.098L5.16529 15.1833V13.9321V12.6843H7.24793H9.33058V14.7696V16.8548H7.89256C7.10248 16.8548 6.45455 16.8648 6.45785 16.878C6.45785 16.8946 6.60992 17.0402 6.79504 17.2057C7.16529 17.5367 8.90744 19.1189 9.38017 19.5525C10.7058 20.7639 10.9967 21.0188 11.0331 20.999C11.0562 20.9857 12.0876 20.0523 13.3273 18.9236L15.5785 16.8714L14.124 16.8615L12.6694 16.8548V14.7696V12.6843H14.7521H16.8347V13.9255C16.8347 14.6074 16.8446 15.1668 16.8612 15.1668C16.8975 15.1668 21 11.0491 21 11.0127C21 10.9763 16.8975 6.85868 16.8612 6.85868C16.8446 6.85868 16.8347 7.41807 16.8347 8.09993V9.34117H14.7521H12.6694V7.25588V5.17059H13.9091C14.5901 5.17059 15.1488 5.16066 15.1488 5.14411C15.1488 5.12094 11.043 1 11.0165 1C11.0066 1 10.0612 1.93673 8.91736 3.08529ZM12.081 3.24086C12.6595 3.82011 13.1322 4.30337 13.1322 4.31661C13.1322 4.33316 12.8413 4.34309 12.4876 4.34309H11.843V7.25588V10.1687H14.7686H17.6942V9.53646C17.6909 9.18891 17.6975 8.89763 17.7041 8.89101C17.7074 8.88439 18.1934 9.36103 18.7785 9.9469L19.843 11.0127L18.7686 12.0885L17.6942 13.1642V12.9325C17.6909 12.8034 17.6876 12.5155 17.6843 12.2871L17.6777 11.8733L14.762 11.8634L11.843 11.8568V14.7696V17.6823L12.6331 17.689L13.4264 17.6989L12.2165 18.7978L11.0066 19.9L10.7223 19.6419C10.5669 19.5028 10.4314 19.3804 10.4215 19.3704C10.405 19.3539 9.92893 18.917 9.28099 18.3311C9.09917 18.1656 8.86777 17.9538 8.7686 17.8578L8.58678 17.6823H9.37355H10.157V14.7696V11.8568H7.24793H4.33884L4.33223 12.5022L4.32231 13.1477L3.25455 12.0785L2.19008 11.0127L3.25455 9.94359L4.32231 8.87446L4.33223 9.52322L4.33884 10.1687H7.24793H10.157V7.25588V4.34309L9.5124 4.33647L8.86446 4.32654L9.93223 3.25741C10.5174 2.67154 11.0066 2.1916 11.0165 2.1916C11.0264 2.1916 11.5058 2.66492 12.081 3.24086Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-47aba5d0"]]),os=M(i.defineComponent({__name:"IconPhone",props:{size:{type:String,default:""},margin:{type:String,default:"0 10px 0 0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#phone"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"phone",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[i.createElementVNode("path",{d:"M19.4998 21.75H19.3723C4.63482 20.9025 2.54232 8.4675 2.24982 4.6725C2.22625 4.37744 2.26114 4.08062 2.35248 3.79906C2.44382 3.5175 2.58981 3.25673 2.78211 3.03169C2.9744 2.80665 3.20921 2.62177 3.47308 2.48763C3.73695 2.35349 4.02469 2.27274 4.31982 2.25H8.45232C8.75274 2.24971 9.04632 2.33963 9.29504 2.50812C9.54377 2.67661 9.73617 2.9159 9.84732 3.195L10.9873 6C11.0971 6.27266 11.1243 6.57156 11.0657 6.85957C11.007 7.14758 10.865 7.412 10.6573 7.62L9.05982 9.2325C9.30936 10.6506 9.98846 11.9578 11.0052 12.9772C12.022 13.9967 13.3274 14.6792 14.7448 14.9325L16.3723 13.32C16.5834 13.1146 16.8504 12.9759 17.1398 12.9213C17.4292 12.8666 17.7283 12.8983 17.9998 13.0125L20.8273 14.145C21.1022 14.2597 21.3367 14.4536 21.501 14.702C21.6653 14.9504 21.7519 15.2422 21.7498 15.54V19.5C21.7498 20.0967 21.5128 20.669 21.0908 21.091C20.6689 21.5129 20.0966 21.75 19.4998 21.75ZM4.49982 3.75C4.30091 3.75 4.11014 3.82902 3.96949 3.96967C3.82884 4.11032 3.74982 4.30109 3.74982 4.5V4.56C4.09482 9 6.30732 19.5 19.4548 20.25C19.5534 20.2561 19.6521 20.2427 19.7454 20.2105C19.8388 20.1783 19.9248 20.1281 19.9987 20.0626C20.0726 19.9971 20.1328 19.9176 20.1759 19.8288C20.219 19.74 20.2441 19.6436 20.2498 19.545V15.54L17.4223 14.4075L15.2698 16.545L14.9098 16.5C8.38482 15.6825 7.49982 9.1575 7.49982 9.09L7.45482 8.73L9.58482 6.5775L8.45982 3.75H4.49982Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-cb2db6a7"]]),vi=M(i.defineComponent({__name:"IconSearch",props:{size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size})},n[0]||(n[0]=[i.createElementVNode("use",{"xlink:href":"#search"},null,-1)]),6)),n[1]||(n[1]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"search",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[i.createElementVNode("path",{d:"M11 19C12.775 18.9996 14.4988 18.4054 15.897 17.312L20.293 21.708L21.707 20.294L17.311 15.898C18.405 14.4997 18.9996 12.7754 19 11C19 6.589 15.411 3 11 3C6.589 3 3 6.589 3 11C3 15.411 6.589 19 11 19ZM11 5C14.309 5 17 7.691 17 11C17 14.309 14.309 17 11 17C7.691 17 5 14.309 5 11C5 7.691 7.691 5 11 5Z",fill:"currentColor"})])],-1))],64))}}),[["__scopeId","data-v-1b900a88"]]),wn=M(i.defineComponent({__name:"ArrowLeft",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#arrow-left"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"arrow-left",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[i.createElementVNode("path",{d:"M656.733 149.806C659.446 147.019 662.69 144.804 666.274 143.292C669.857 141.779 673.707 141 677.597 141C681.486 141 685.337 141.779 688.92 143.292C692.503 144.804 695.748 147.019 698.461 149.806C704.024 155.518 707.138 163.176 707.138 171.15C707.138 179.123 704.024 186.782 698.461 192.494L386.589 512.366L698.461 832.302C701.269 835.176 703.483 838.575 704.976 842.305C706.47 846.035 707.215 850.022 707.167 854.04C707.119 858.057 706.281 862.026 704.699 865.72C703.118 869.413 700.824 872.759 697.949 875.566C695.211 878.242 691.972 880.351 688.417 881.774C684.863 883.197 681.063 883.904 677.235 883.857C673.407 883.809 669.625 883.007 666.107 881.497C662.589 879.986 659.404 877.797 656.733 875.054L325.085 534.702C319.26 528.726 316 520.711 316 512.366C316 504.021 319.26 496.006 325.085 490.03L656.733 149.806Z"})])],-1))],64))}}),[["__scopeId","data-v-31d7e282"]]),bn=M(i.defineComponent({__name:"ArrowRight",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#arrow-right"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"arrow-right",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[i.createElementVNode("path",{d:"M366.436 875.054C363.723 877.84 360.479 880.055 356.895 881.568C353.312 883.08 349.462 883.859 345.572 883.859C341.683 883.859 337.832 883.08 334.249 881.568C330.666 880.055 327.421 877.84 324.708 875.054C319.145 869.342 316.031 861.683 316.031 853.71C316.031 845.736 319.145 838.077 324.708 832.366L636.58 512.494L324.708 192.558C321.9 189.684 319.686 186.284 318.193 182.555C316.699 178.825 315.954 174.837 316.002 170.82C316.049 166.802 316.888 162.833 318.47 159.14C320.051 155.446 322.345 152.1 325.22 149.294C327.958 146.618 331.197 144.508 334.752 143.086C338.306 141.663 342.106 140.955 345.934 141.003C349.762 141.05 353.544 141.852 357.062 143.363C360.58 144.873 363.765 147.063 366.436 149.806L698.084 490.158C703.909 496.134 707.169 504.148 707.169 512.494C707.169 520.839 703.909 528.854 698.084 534.83L366.436 875.054Z"})])],-1))],64))}}),[["__scopeId","data-v-ac346343"]]),Mi=M(i.defineComponent({__name:"DoubleArrowLeft",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#double-arrow-left"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"double-arrow-left",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[i.createElementVNode("path",{d:"M529.408 149.376C532.121 146.589 535.365 144.374 538.949 142.862C542.532 141.35 546.382 140.57 550.272 140.57C554.161 140.57 558.011 141.35 561.595 142.862C565.178 144.374 568.422 146.589 571.136 149.376C576.699 155.088 579.813 162.746 579.813 170.72C579.813 178.694 576.699 186.352 571.136 192.064L259.264 511.936L571.136 831.872C573.943 834.746 576.157 838.145 577.651 841.875C579.145 845.605 579.889 849.593 579.842 853.61C579.794 857.628 578.956 861.597 577.374 865.29C575.792 868.984 573.499 872.329 570.624 875.136C567.886 877.812 564.647 879.922 561.092 881.344C557.538 882.767 553.738 883.475 549.91 883.427C546.081 883.38 542.3 882.578 538.782 881.067C535.264 879.556 532.079 877.367 529.408 874.624L197.76 534.272C191.935 528.296 188.675 520.281 188.675 511.936C188.675 503.591 191.935 495.576 197.76 489.6L529.408 149.376ZM785.408 149.376C788.121 146.589 791.365 144.374 794.949 142.862C798.532 141.35 802.382 140.57 806.272 140.57C810.161 140.57 814.011 141.35 817.595 142.862C821.178 144.374 824.422 146.589 827.136 149.376C832.699 155.088 835.813 162.746 835.813 170.72C835.813 178.694 832.699 186.352 827.136 192.064L515.264 511.936L827.136 831.872C829.943 834.746 832.157 838.145 833.651 841.875C835.145 845.605 835.889 849.593 835.842 853.61C835.794 857.628 834.956 861.597 833.374 865.29C831.792 868.984 829.499 872.329 826.624 875.136C823.886 877.812 820.647 879.922 817.092 881.344C813.538 882.767 809.738 883.475 805.91 883.427C802.081 883.38 798.3 882.578 794.782 881.067C791.264 879.556 788.079 877.367 785.408 874.624L453.76 534.272C447.935 528.296 444.675 520.281 444.675 511.936C444.675 503.591 447.935 495.576 453.76 489.6L785.408 149.376Z"})])],-1))],64))}}),[["__scopeId","data-v-646afc45"]]),xi=M(i.defineComponent({__name:"DoubleArrowRight",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#double-arrow-right"},null,-1)]),38)),r[3]||(r[3]=i.createElementVNode("svg",{width:"0",height:"0",class:"hidden"},[i.createElementVNode("symbol",{id:"double-arrow-right",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[i.createElementVNode("path",{d:"M495.111 874.624C492.397 877.411 489.153 879.626 485.57 881.138C481.987 882.65 478.136 883.43 474.247 883.43C470.357 883.43 466.507 882.65 462.924 881.138C459.34 879.626 456.096 877.411 453.383 874.624C447.819 868.912 444.706 861.254 444.706 853.28C444.706 845.306 447.819 837.648 453.383 831.936L765.255 512.064L453.383 192.128C450.575 189.254 448.361 185.855 446.867 182.125C445.374 178.395 444.629 174.407 444.677 170.39C444.724 166.372 445.563 162.403 447.145 158.71C448.726 155.016 451.02 151.671 453.895 148.864C456.633 146.188 459.872 144.078 463.426 142.656C466.981 141.233 470.781 140.525 474.609 140.573C478.437 140.62 482.219 141.422 485.737 142.933C489.254 144.444 492.44 146.633 495.111 149.376L826.759 489.728C832.584 495.704 835.844 503.719 835.844 512.064C835.844 520.409 832.584 528.424 826.759 534.4L495.111 874.624ZM239.111 874.624C236.397 877.411 233.153 879.626 229.57 881.138C225.987 882.65 222.136 883.43 218.247 883.43C214.357 883.43 210.507 882.65 206.924 881.138C203.34 879.626 200.096 877.411 197.383 874.624C191.819 868.912 188.706 861.254 188.706 853.28C188.706 845.306 191.819 837.648 197.383 831.936L509.255 512.064L197.383 192.128C194.575 189.254 192.361 185.855 190.867 182.125C189.374 178.395 188.629 174.407 188.677 170.39C188.724 166.372 189.563 162.403 191.145 158.71C192.726 155.016 195.02 151.671 197.895 148.864C200.633 146.188 203.872 144.078 207.426 142.656C210.981 141.233 214.781 140.525 218.609 140.573C222.437 140.62 226.219 141.422 229.737 142.933C233.254 144.444 236.44 146.633 239.111 149.376L570.759 489.728C576.584 495.704 579.844 503.719 579.844 512.064C579.844 520.409 576.584 528.424 570.759 534.4L239.111 874.624Z"})])],-1))],64))}}),[["__scopeId","data-v-ef44f40e"]]),Bi=M(i.defineComponent({__name:"EllipsisSvg",props:{color:{type:String,default:""},hoverColor:{type:String,default:""},size:{type:String,default:""},margin:{type:String,default:"0"},iconClass:{type:String,required:!1,default:""}},setup(t){const e=i.ref(!1);return(n,r)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[(i.openBlock(),i.createElementBlock("svg",{class:i.normalizeClass(["icon",t.iconClass]),style:i.normalizeStyle({margin:t.margin,width:t.size,height:t.size,fill:t.hoverColor?i.unref(e)?t.hoverColor:t.color:(i.unref(e),t.color)}),onMouseenter:r[0]||(r[0]=o=>e.value=!0),onMouseleave:r[1]||(r[1]=o=>e.value=!1)},r[2]||(r[2]=[i.createElementVNode("use",{"xlink:href":"#ellipsis"},null,-1)]),38)),r[3]||(r[3]=i.createStaticVNode('<svg width="0" height="0" class="hidden" data-v-1c5f4e97><symbol id="ellipsis" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 240 240" data-v-1c5f4e97><path d="M65 135C73.2843 135 80 128.284 80 120C80 111.716 73.2843 105 65 105C56.7157 105 50 111.716 50 120C50 128.284 56.7157 135 65 135Z" data-v-1c5f4e97></path><path d="M120 135C128.284 135 135 128.284 135 120C135 111.716 128.284 105 120 105C111.716 105 105 111.716 105 120C105 128.284 111.716 135 120 135Z" data-v-1c5f4e97></path><path d="M175 135C183.284 135 190 128.284 190 120C190 111.716 183.284 105 175 105C166.716 105 160 111.716 160 120C160 128.284 166.716 135 175 135Z" data-v-1c5f4e97></path></symbol></svg>',1))],64))}}),[["__scopeId","data-v-1c5f4e97"]]);function ss(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function U(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?ss(Object(n),!0).forEach(function(r){ke(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ss(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function ke(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Wh(t,e){if(t==null)return{};var n,r,o=function(a,d){if(a==null)return{};var c,u,h={},f=Object.keys(a);for(u=0;u<f.length;u++)c=f[u],d.indexOf(c)>=0||(h[c]=a[c]);return h}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(r=0;r<s.length;r++)n=s[r],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(o[n]=t[n])}return o}function ot(t){return function(e){if(Array.isArray(e))return Ii(e)}(t)||function(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}(t)||function(e,n){if(e){if(typeof e=="string")return Ii(e,n);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Ii(e,n)}}(t)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
24
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function Ii(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var as,Gh,Cn,Q=(as=function(t){/*!
25
25
  Copyright (c) 2018 Jed Watson.
26
26
  Licensed under the MIT License (MIT), see
27
27
  http://jedwatson.github.io/classnames
28
- */(function(){var e={}.hasOwnProperty;function n(){for(var r=[],o=0;o<arguments.length;o++){var s=arguments[o];if(s){var a=typeof s;if(a==="string"||a==="number")r.push(s);else if(Array.isArray(s)){if(s.length){var d=n.apply(null,s);d&&r.push(d)}}else if(a==="object")if(s.toString===Object.prototype.toString)for(var c in s)e.call(s,c)&&s[c]&&r.push(c);else r.push(s.toString())}}return r.join(" ")}t.exports?(n.default=n,t.exports=n):window.classNames=n})()},os(bn={path:Uh,exports:{},require:function(t,e){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(e==null&&bn.path)}},bn.exports),bn.exports),xe=function(t){return function(e,n){if(!e)return t;var r;typeof e=="string"?r=e:n=e;var o=t;return r&&(o+="__"+r),o+(n?Object.keys(n).reduce(function(s,a){var d=n[a];return d&&(s+=" "+(typeof d=="boolean"?o+"--"+a:o+"--"+a+"_"+d)),s},""):"")}};function Ii(t,e,n){var r,o,s,a,d;function c(){var h=Date.now()-a;h<e&&h>=0?r=setTimeout(c,e-h):(r=null,n||(d=t.apply(s,o),s=o=null))}e==null&&(e=100);var u=function(){s=this,o=arguments,a=Date.now();var h=n&&!r;return r||(r=setTimeout(c,e)),h&&(d=t.apply(s,o),s=o=null),d};return u.clear=function(){r&&(clearTimeout(r),r=null)},u.flush=function(){r&&(d=t.apply(s,o),s=o=null,clearTimeout(r),r=null)},u}Ii.debounce=Ii;var Ri=Ii,A=function(){return A=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t},A.apply(this,arguments)};/*! *****************************************************************************
28
+ */(function(){var e={}.hasOwnProperty;function n(){for(var r=[],o=0;o<arguments.length;o++){var s=arguments[o];if(s){var a=typeof s;if(a==="string"||a==="number")r.push(s);else if(Array.isArray(s)){if(s.length){var d=n.apply(null,s);d&&r.push(d)}}else if(a==="object")if(s.toString===Object.prototype.toString)for(var c in s)e.call(s,c)&&s[c]&&r.push(c);else r.push(s.toString())}}return r.join(" ")}t.exports?(n.default=n,t.exports=n):window.classNames=n})()},as(Cn={path:Gh,exports:{},require:function(t,e){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(e==null&&Cn.path)}},Cn.exports),Cn.exports),Ie=function(t){return function(e,n){if(!e)return t;var r;typeof e=="string"?r=e:n=e;var o=t;return r&&(o+="__"+r),o+(n?Object.keys(n).reduce(function(s,a){var d=n[a];return d&&(s+=" "+(typeof d=="boolean"?o+"--"+a:o+"--"+a+"_"+d)),s},""):"")}};function Ri(t,e,n){var r,o,s,a,d;function c(){var h=Date.now()-a;h<e&&h>=0?r=setTimeout(c,e-h):(r=null,n||(d=t.apply(s,o),s=o=null))}e==null&&(e=100);var u=function(){s=this,o=arguments,a=Date.now();var h=n&&!r;return r||(r=setTimeout(c,e)),h&&(d=t.apply(s,o),s=o=null),d};return u.clear=function(){r&&(clearTimeout(r),r=null)},u.flush=function(){r&&(d=t.apply(s,o),s=o=null,clearTimeout(r),r=null)},u}Ri.debounce=Ri;var $i=Ri,A=function(){return A=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t},A.apply(this,arguments)};/*! *****************************************************************************
29
29
  Copyright (c) Microsoft Corporation.
30
30
 
31
31
  Permission to use, copy, modify, and/or distribute this software for any
@@ -38,5 +38,5 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
38
38
  LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
39
39
  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
40
40
  PERFORMANCE OF THIS SOFTWARE.
41
- ***************************************************************************** */function ss(t,e){var n,r;return t&&e?(n=""+t+e[0].toUpperCase()+e.slice(1),r=t+"-"+e):(n=t||e,r=t||e),{name:n,classname:r}}function as(t){return/^blob:/.test(t)}function ls(t){return as(t)||function(e){return/^data:/.test(e)}(t)}function gt(t){return!!(t&&t.constructor&&t.call&&t.apply)}function ee(t){return t===void 0}function Cn(t){return typeof t=="object"&&t!==null}function $i(t,e,n){var r={};return Cn(t)?(Object.keys(e).forEach(function(o){ee(t[o])?r[o]=e[o]:Cn(e[o])?Cn(t[o])?r[o]=$i(t[o],e[o],n[o]):r[o]=t[o]?e[o]:n[o]:e[o]===!0||e[o]===!1?r[o]=!!t[o]:r[o]=t[o]}),r):t?e:n}function Sn(t){var e=Number(t);return Number.isNaN(e)?t:e}function cs(t){return typeof(t=="number"||function(e){return typeof e=="object"&&e!==null}(t)&&toString.call(t)=="[object Number]")&&!ds(t)}function ds(t){return t!=t}function us(t,e){return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}var Dt=function(t,e){t===void 0&&(t={}),e===void 0&&(e={}),this.type="manipulateImage",this.move=t,this.scale=e},Wh=function(t,e){e===void 0&&(e={}),this.type="resize",this.directions=t,this.params=e},Ni=function(t){this.type="move",this.directions=t},Gh=function(){function t(e,n,r,o,s){this.type="drag",this.nativeEvent=e,this.position=r,this.previousPosition=o,this.element=n,this.anchor=s}return t.prototype.shift=function(){var e=this,n=e.element,r=e.anchor,o=e.position;if(n){var s=n.getBoundingClientRect(),a=s.left,d=s.top;return{left:o.left-a-r.left,top:o.top-d-r.top}}return{left:0,top:0}},t}(),Ai={name:"DraggableElement",props:{classname:{type:String}},beforeMount:function(){window.addEventListener("mouseup",this.onMouseUp,{passive:!1}),window.addEventListener("mousemove",this.onMouseMove,{passive:!1}),window.addEventListener("touchmove",this.onTouchMove,{passive:!1}),window.addEventListener("touchend",this.onTouchEnd,{passive:!1})},beforeUnmount:function(){window.removeEventListener("mouseup",this.onMouseUp),window.removeEventListener("mousemove",this.onMouseMove),window.removeEventListener("touchmove",this.onTouchMove),window.removeEventListener("touchend",this.onTouchEnd)},mounted:function(){if(!this.$refs.draggable)throw new Error('You should add ref "draggable" to your root element to use draggable mixin');this.touches=[],this.hovered=!1},methods:{onMouseOver:function(){this.hovered||(this.hovered=!0,this.$emit("enter"))},onMouseLeave:function(){this.hovered&&!this.touches.length&&(this.hovered=!1,this.$emit("leave"))},onTouchStart:function(t){t.cancelable&&!this.disabled&&t.touches.length===1&&(this.touches=it(t.touches),this.hovered||(this.$emit("enter"),this.hovered=!0),t.touches.length&&this.initAnchor(this.touches.reduce(function(e,n){return{clientX:e.clientX+n.clientX/t.touches.length,clientY:e.clientY+n.clientY/t.touches.length}},{clientX:0,clientY:0})),t.preventDefault&&t.preventDefault(),t.stopPropagation())},onTouchEnd:function(){this.processEnd()},onTouchMove:function(t){this.touches.length&&(this.processMove(t,t.touches),t.preventDefault&&t.preventDefault(),t.stopPropagation&&t.stopPropagation())},onMouseDown:function(t){if(!this.disabled){var e={fake:!0,clientX:t.clientX,clientY:t.clientY};this.touches=[e],this.initAnchor(e),t.stopPropagation()}},onMouseMove:function(t){this.touches.length&&(this.processMove(t,[{fake:!0,clientX:t.clientX,clientY:t.clientY}]),t.preventDefault&&t.preventDefault())},onMouseUp:function(){this.processEnd()},initAnchor:function(t){var e=this.$refs.draggable.getBoundingClientRect(),n=e.left,r=e.right,o=e.bottom,s=e.top;this.anchor={left:t.clientX-n,top:t.clientY-s,bottom:o-t.clientY,right:r-t.clientX}},processMove:function(t,e){var n=it(e);if(this.touches.length){if(this.touches.length===1&&n.length===1){var r=this.$refs.draggable;this.$emit("drag",new Gh(t,r,{left:n[0].clientX,top:n[0].clientY},{left:this.touches[0].clientX,top:this.touches[0].clientY},this.anchor))}this.touches=n}},processEnd:function(){this.touches.length&&this.$emit("drag-end"),this.hovered&&(this.$emit("leave"),this.hovered=!1),this.touches=[]}},emits:["drag","drag-end","leave","enter"]};Ai.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"draggable",class:n.classname,onTouchstart:e[1]||(e[1]=function(){return s.onTouchStart&&s.onTouchStart.apply(s,arguments)}),onMousedown:e[2]||(e[2]=function(){return s.onMouseDown&&s.onMouseDown.apply(s,arguments)}),onMouseover:e[3]||(e[3]=function(){return s.onMouseOver&&s.onMouseOver.apply(s,arguments)}),onMouseleave:e[4]||(e[4]=function(){return s.onMouseLeave&&s.onMouseLeave.apply(s,arguments)})},[i.renderSlot(t.$slots,"default")],34)};var Pi=xe("vue-handler-wrapper"),hs={name:"HandlerWrapper",components:{DraggableElement:Ai},props:{horizontalPosition:{type:String},verticalPosition:{type:String},disabled:{type:Boolean,default:!1}},computed:{classes:function(){var t;if(this.horizontalPosition||this.verticalPosition){var e,n=ss(this.horizontalPosition,this.verticalPosition);t=Pi((Ce(e={},n.classname,!0),Ce(e,"disabled",this.disabled),e))}else t=Pi({disabled:this.disabled});return{root:t,draggable:Pi("draggable")}}},emits:["leave","enter","drag","drag-end"]};hs.render=function(t,e,n,r,o,s){var a=i.resolveComponent("DraggableElement");return i.openBlock(),i.createBlock("div",{class:s.classes.root},[i.createVNode(a,{class:s.classes.draggable,onDrag:e[1]||(e[1]=function(d){return t.$emit("drag",d)}),onDragEnd:e[2]||(e[2]=function(d){return t.$emit("drag-end")}),onLeave:e[3]||(e[3]=function(d){return t.$emit("leave")}),onEnter:e[4]||(e[4]=function(d){return t.$emit("enter")})},{default:i.withCtx(function(){return[i.renderSlot(t.$slots,"default")]}),_:3},8,["class"])],2)};var jh=xe("vue-line-wrapper"),fs={name:"LineWrapper",components:{DraggableElement:Ai},props:{position:{type:String,required:!0},disabled:{type:Boolean,default:!1}},computed:{classname:function(){var t;return jh((Ce(t={},this.position,!0),Ce(t,"disabled",this.disabled),t))}},emits:["leave","enter","drag","drag-end"]};fs.render=function(t,e,n,r,o,s){var a=i.resolveComponent("DraggableElement");return i.openBlock(),i.createBlock(a,{class:s.classname,onDrag:e[1]||(e[1]=function(d){return t.$emit("drag",d)}),onDragEnd:e[2]||(e[2]=function(d){return t.$emit("drag-end")}),onLeave:e[3]||(e[3]=function(d){return t.$emit("leave")}),onEnter:e[4]||(e[4]=function(d){return t.$emit("enter")})},{default:i.withCtx(function(){return[i.renderSlot(t.$slots,"default")]}),_:3},8,["class"])};var Ne=["left","right","top","bottom"],Zh=["left","right"],Jh=["top","bottom"],Xh=["left","top"],Yh=["fill-area","fit-area","stencil","none"],ms={left:0,top:0,width:0,height:0};function ps(t,e,n){return!(n=n||["width","height","left","top"]).some(function(r){return t[r]!==e[r]})}function Ae(t){return{left:t.left,top:t.top,right:t.left+t.width,bottom:t.top+t.height}}function yt(t,e){return{left:t.left-e.left,top:t.top-e.top}}function re(t){return{left:t.left+t.width/2,top:t.top+t.height/2}}function Lt(t,e){var n={left:0,top:0,right:0,bottom:0};return Ne.forEach(function(r){var o=e[r],s=Ae(t)[r];n[r]=o!==void 0&&s!==void 0?r==="left"||r==="top"?Math.max(0,o-s):Math.max(0,s-o):0}),n}function Pe(t,e){return{left:t.left-e.left,top:t.top-e.top,width:t.width+e.left+e.right,height:t.height+e.top+e.bottom}}function kn(t){return{left:-t.left,top:-t.top}}function fe(t,e){return A(A({},t),{left:t.left+e.left,top:t.top+e.top})}function Se(t,e,n,r){if(e!==1){if(n){var o=re(t);return{width:t.width*e,height:t.height*e,left:t.left+t.width*(1-e)/2+(n.left-o.left)*(1-e),top:t.top+t.height*(1-e)/2+(n.top-o.top)*(1-e)}}return{width:t.width*e,height:t.height*e,left:t.left+t.width*(1-e)/2,top:t.top+t.height*(1-e)/2}}return t}function U(t){return t.width/t.height}function wt(t,e){return Math.min(e.right!==void 0&&e.left!==void 0?(e.right-e.left)/t.width:1/0,e.bottom!==void 0&&e.top!==void 0?(e.bottom-e.top)/t.height:1/0)}function bt(t,e){var n={left:0,top:0},r=Lt(t,e);return r.left&&r.left>0?n.left=r.left:r.right&&r.right>0&&(n.left=-r.right),r.top&&r.top>0?n.top=r.top:r.bottom&&r.bottom>0&&(n.top=-r.bottom),n}function Ti(t,e){var n;return e.minimum&&t<e.minimum?n=e.minimum:e.maximum&&t>e.maximum&&(n=e.maximum),n}function gs(t,e){var n=U(t),r=U(e);return e.width<1/0&&e.height<1/0?n>r?{width:e.width,height:e.width/n}:{width:e.height*n,height:e.height}:e.width<1/0?{width:e.width,height:e.width/n}:e.height<1/0?{width:e.height*n,height:e.height}:t}function ys(t,e){var n=e*Math.PI/180;return{width:Math.abs(t.width*Math.cos(n))+Math.abs(t.height*Math.sin(n)),height:Math.abs(t.width*Math.sin(n))+Math.abs(t.height*Math.cos(n))}}function Ue(t,e){var n=e*Math.PI/180;return{left:t.left*Math.cos(n)-t.top*Math.sin(n),top:t.left*Math.sin(n)+t.top*Math.cos(n)}}function En(t,e){var n=Lt(oe(t,e),e);return n.left+n.right+n.top+n.bottom?n.left+n.right>n.top+n.bottom?Math.min((t.width+n.left+n.right)/t.width,wt(t,e)):Math.min((t.height+n.top+n.bottom)/t.height,wt(t,e)):1}function oe(t,e,n){n===void 0&&(n=!1);var r=bt(t,e);return fe(t,n?kn(r):r)}function zi(t){return{width:t.right!==void 0&&t.left!==void 0?t.right-t.left:1/0,height:t.bottom!==void 0&&t.top!==void 0?t.bottom-t.top:1/0}}function Qh(t,e){return A(A({},t),{minWidth:Math.min(e.width,t.minWidth),minHeight:Math.min(e.height,t.minHeight),maxWidth:Math.min(e.width,t.maxWidth),maxHeight:Math.min(e.height,t.maxHeight)})}function ws(t,e,n){n===void 0&&(n=!0);var r={};return Ne.forEach(function(o){var s=t[o],a=e[o];s!==void 0&&a!==void 0?r[o]=o==="left"||o==="top"?n?Math.max(s,a):Math.min(s,a):n?Math.min(s,a):Math.max(s,a):a!==void 0?r[o]=a:s!==void 0&&(r[o]=s)}),r}function vn(t,e){return ws(t,e,!0)}function bs(t){var e=t.size,n=t.aspectRatio,r=t.ignoreMinimum,o=t.sizeRestrictions;return!!((e.correctRatio||U(e)>=n.minimum&&U(e)<=n.maximum)&&e.height<=o.maxHeight&&e.width<=o.maxWidth&&e.width&&e.height&&(r||e.height>=o.minHeight&&e.width>=o.minWidth))}function Cs(t,e){return Math.pow(t.width-e.width,2)+Math.pow(t.height-e.height,2)}function Fe(t){var e=t.width,n=t.height,r=t.sizeRestrictions,o={minimum:t.aspectRatio&&t.aspectRatio.minimum||0,maximum:t.aspectRatio&&t.aspectRatio.maximum||1/0},s={width:Math.max(r.minWidth,Math.min(r.maxWidth,e)),height:Math.max(r.minHeight,Math.min(r.maxHeight,n))};function a(u,h){return h===void 0&&(h=!1),u.reduce(function(f,p){return bs({size:p,aspectRatio:o,sizeRestrictions:r,ignoreMinimum:h})&&(!f||Cs(p,{width:e,height:n})<Cs(f,{width:e,height:n}))?p:f},null)}var d=[];o&&[o.minimum,o.maximum].forEach(function(u){u&&d.push({width:s.width,height:s.width/u,correctRatio:!0},{width:s.height*u,height:s.height,correctRatio:!0})}),bs({size:s,aspectRatio:o,sizeRestrictions:r})&&d.push(s);var c=a(d)||a(d,!0);return c&&{width:c.width,height:c.height}}function Vi(t){var e=t.event,n=t.coordinates,r=t.positionRestrictions,o=r===void 0?{}:r,s=fe(n,e.directions);return fe(s,bt(s,o))}function Kh(t){var e=t.coordinates,n=t.transform,r=t.imageSize,o=t.sizeRestrictions,s=t.positionRestrictions,a=t.aspectRatio,d=t.visibleArea,c=function(h,f){return Vi({coordinates:h,positionRestrictions:s,event:new Ni({left:f.left-h.left,top:f.top-h.top})})},u=A({},e);return(Array.isArray(n)?n:[n]).forEach(function(h){var f={};ee((f=typeof h=="function"?h({coordinates:u,imageSize:r,visibleArea:d}):h).width)&&ee(f.height)||(u=function(p,y){var g=A(A(A({},p),Fe({width:y.width,height:y.height,sizeRestrictions:o,aspectRatio:a})),{left:0,top:0});return c(g,{left:p.left,top:p.top})}(u,A(A({},u),f))),ee(f.left)&&ee(f.top)||(u=c(u,A(A({},u),f)))}),u}function ef(t){t.event;var e=t.getAreaRestrictions,n=t.boundaries,r=t.coordinates,o=t.visibleArea;t.aspectRatio;var s=t.stencilSize,a=t.sizeRestrictions,d=t.positionRestrictions;t.stencilReference;var c,u,h,f=A({},r),p=A({},o),y=A({},s);c=U(y),u=U(f),h===void 0&&(h=.001),(c===0||u===0?Math.abs(u-c)<h:Math.abs(u/c)<1+h&&Math.abs(u/c)>1-h)||(f=A(A({},f),Fe({sizeRestrictions:a,width:f.width,height:f.height,aspectRatio:{minimum:U(y),maximum:U(y)}})));var g=En(p=Se(p,f.width*n.width/(p.width*y.width)),e({visibleArea:p,type:"resize"}));return g!==1&&(p=Se(p,g),f=Se(f,g)),p=oe(p=fe(p,yt(re(f),re(p))),e({visibleArea:p,type:"move"})),{coordinates:f=oe(f,vn(Ae(p),d)),visibleArea:p}}function tf(t){var e=t.event,n=t.getAreaRestrictions,r=t.boundaries,o=t.coordinates,s=t.visibleArea;t.aspectRatio,t.stencilSize,t.sizeRestrictions;var a=t.positionRestrictions;t.stencilReference;var d=A({},o),c=A({},s);if(o&&s&&e.type!=="manipulateImage"){var u={width:0,height:0};c.width,r.width,U(r)>U(d)?(u.height=.8*r.height,u.width=u.height*U(d)):(u.width=.8*r.width,u.height=u.width*U(d));var h=En(c=Se(c,d.width*r.width/(c.width*u.width)),n({visibleArea:c,type:"resize"}));c=Se(c,h),h!==1&&(u.height/=h,u.width/=h),c=oe(c=fe(c,yt(re(d),re(c))),n({visibleArea:c,type:"move"})),d=oe(d,vn(Ae(c),a))}return{coordinates:d,visibleArea:c}}function nf(t){var e=t.event,n=t.coordinates,r=t.visibleArea,o=t.getAreaRestrictions,s=A({},r),a=A({},n);if(e.type==="setCoordinates"){var d=Math.max(0,a.width-s.width),c=Math.max(0,a.height-s.height);d>c?s=Se(s,Math.min(a.width/s.width,wt(s,o({visibleArea:s,type:"resize"})))):c>d&&(s=Se(s,Math.min(a.height/s.height,wt(s,o({visibleArea:s,type:"resize"}))))),s=oe(s=fe(s,kn(bt(a,Ae(s)))),o({visibleArea:s,type:"move"}))}return{visibleArea:s,coordinates:a}}function rf(t){var e=t.imageSize,n=t.visibleArea,r=t.coordinates,o=n||e;return{left:(n?n.left:0)+o.width/2-r.width/2,top:(n?n.top:0)+o.height/2-r.height/2}}function of(t){var e=t.imageSize,n=t.visibleArea,r=t.aspectRatio,o=t.sizeRestrictions,s=n||e,a=Math.min(r.maximum||1/0,Math.max(r.minimum||0,U(s))),d=s.width<s.height?{width:.8*s.width,height:.8*s.width/a}:{height:.8*s.height,width:.8*s.height*a};return Fe(A(A({},d),{aspectRatio:r,sizeRestrictions:o}))}function sf(t){var e,n,r=t.imageSize,o=t.visibleArea,s=t.boundaries,a=t.aspectRatio,d=t.sizeRestrictions,c=t.stencilSize,u=o||r;return U(u)>U(s)?n=(e=c.height*u.height/s.height)*U(c):e=(n=c.width*u.width/s.width)/U(c),Fe({width:n,height:e,aspectRatio:a,sizeRestrictions:d})}function af(t){var e=t.getAreaRestrictions,n=t.coordinates,r=t.imageSize,o=U(t.boundaries);if(n){var s={height:Math.max(n.height,r.height),width:Math.max(n.width,r.width)},a=gs({width:U(s)>o?s.width:s.height*o,height:U(s)>o?s.width/o:s.height},zi(e())),d={left:n.left+n.width/2-a.width/2,top:n.top+n.height/2-a.height/2,width:a.width,height:a.height},c=Lt(n,Ae(A({left:0,top:0},r))),u={};return!c.left&&!c.right&&d.width<=r.width&&(u.left=0,u.right=r.width),!c.top&&!c.bottom&&d.height<=r.height&&(u.top=0,u.bottom=r.height),oe(d,u)}var h=U(r);return a={height:h>o?r.height:r.width/o,width:h>o?r.height*o:r.width},{left:r.width/2-a.width/2,top:r.height/2-a.height/2,width:a.width,height:a.height}}function Mn(t,e){return ws(t,Ae(e))}function lf(t){var e=t.event,n=t.coordinates,r=t.visibleArea,o=t.sizeRestrictions,s=t.getAreaRestrictions,a=t.positionRestrictions,d=t.adjustStencil,c=e.scale,u=e.move,h=A({},r),f=A({},n),p=1,y=1,g=c.factor&&Math.abs(c.factor-1)>.001;h=fe(h,{left:u.left||0,top:u.top||0});var k={stencil:{minimum:Math.max(o.minWidth?o.minWidth/f.width:0,o.minHeight?o.minHeight/f.height:0),maximum:Math.min(o.maxWidth?o.maxWidth/f.width:1/0,o.maxHeight?o.maxHeight/f.height:1/0,wt(f,a))},area:{maximum:wt(h,s({visibleArea:h,type:"resize"}))}};c.factor&&g&&(c.factor<1?(y=Math.max(c.factor,k.stencil.minimum))>1&&(y=1):c.factor>1&&(y=Math.min(c.factor,Math.min(k.area.maximum,k.stencil.maximum)))<1&&(y=1)),y&&(h=Se(h,y,c.center));var b=n.left-r.left,B=r.width+r.left-(n.width+n.left),D=n.top-r.top,L=r.height+r.top-(n.height+n.top);return h=oe(h=fe(h,bt(h,{left:a.left!==void 0?a.left-b*y:void 0,top:a.top!==void 0?a.top-D*y:void 0,bottom:a.bottom!==void 0?a.bottom+L*y:void 0,right:a.right!==void 0?a.right+B*y:void 0})),s({visibleArea:h,type:"move"})),f.width=f.width*y,f.height=f.height*y,f.left=h.left+b*y,f.top=h.top+D*y,f=oe(f,vn(Ae(h),a)),c.factor&&g&&d&&(c.factor>1?p=Math.min(k.area.maximum,c.factor)/y:c.factor<1&&(p=Math.max(f.height/h.height,f.width/h.width,c.factor/y)),p!==1&&(h=fe(h=oe(h=Se(h,p,c.factor>1?c.center:re(f)),s({visibleArea:h,type:"move"})),kn(bt(f,Ae(h)))))),{coordinates:f,visibleArea:h}}function cf(t){var e=t.aspectRatio,n=t.getAreaRestrictions,r=t.coordinates,o=t.visibleArea,s=t.sizeRestrictions,a=t.positionRestrictions,d=t.imageSize,c=t.previousImageSize,u=t.angle,h=A({},r),f=A({},o),p=Ue(re(A({left:0,top:0},c)),u);return(h=A(A({},Fe({sizeRestrictions:s,aspectRatio:e,width:h.width,height:h.height})),Ue(re(h),u))).left-=p.left-d.width/2+h.width/2,h.top-=p.top-d.height/2+h.height/2,f=Se(f,En(f,n({visibleArea:f,type:"resize"}))),{coordinates:h=oe(h,a),visibleArea:f=oe(f=fe(f,yt(re(h),re(r))),n({visibleArea:f,type:"move"}))}}function df(t){var e=t.flip,n=t.previousFlip,r=t.rotate,o=t.getAreaRestrictions,s=t.coordinates,a=t.visibleArea,d=t.imageSize,c=A({},s),u=A({},a),h=n.horizontal!==e.horizontal,f=n.vertical!==e.vertical;if(h||f){var p=Ue({left:d.width/2,top:d.height/2},-r),y=Ue(re(c),-r),g=Ue({left:h?p.left-(y.left-p.left):y.left,top:f?p.top-(y.top-p.top):y.top},r);c=fe(c,yt(g,re(c))),y=Ue(re(u),-r),u=oe(u=fe(u,yt(g=Ue({left:h?p.left-(y.left-p.left):y.left,top:f?p.top-(y.top-p.top):y.top},r),re(u))),o({visibleArea:u,type:"move"}))}return{coordinates:c,visibleArea:u}}function Ss(t){var e=t.directions,n=t.coordinates,r=t.positionRestrictions,o=r===void 0?{}:r,s=t.sizeRestrictions,a=t.preserveRatio,d=t.compensate,c=A({},e),u=Pe(n,c).width,h=Pe(n,c).height;u<0&&(c.left<0&&c.right<0?(c.left=-(n.width-s.minWidth)/(c.left/c.right),c.right=-(n.width-s.minWidth)/(c.right/c.left)):c.left<0?c.left=-(n.width-s.minWidth):c.right<0&&(c.right=-(n.width-s.minWidth))),h<0&&(c.top<0&&c.bottom<0?(c.top=-(n.height-s.minHeight)/(c.top/c.bottom),c.bottom=-(n.height-s.minHeight)/(c.bottom/c.top)):c.top<0?c.top=-(n.height-s.minHeight):c.bottom<0&&(c.bottom=-(n.height-s.minHeight)));var f=Lt(Pe(n,c),o);d&&(f.left&&f.left>0&&f.right===0?(c.right+=f.left,c.left-=f.left):f.right&&f.right>0&&f.left===0&&(c.left+=f.right,c.right-=f.right),f.top&&f.top>0&&f.bottom===0?(c.bottom+=f.top,c.top-=f.top):f.bottom&&f.bottom>0&&f.top===0&&(c.top+=f.bottom,c.bottom-=f.bottom),f=Lt(Pe(n,c),o));var p={width:1/0,height:1/0,left:1/0,right:1/0,top:1/0,bottom:1/0};if(Ne.forEach(function(k){var b=f[k];b&&c[k]&&(p[k]=Math.max(0,1-b/c[k]))}),a){var y=Math.min.apply(null,Ne.map(function(k){return p[k]}));y!==1/0&&Ne.forEach(function(k){c[k]*=y})}else Ne.forEach(function(k){p[k]!==1/0&&(c[k]*=p[k])});if(u=Pe(n,c).width,h=Pe(n,c).height,c.right+c.left&&(u>s.maxWidth?p.width=(s.maxWidth-n.width)/(c.right+c.left):u<s.minWidth&&(p.width=(s.minWidth-n.width)/(c.right+c.left))),c.bottom+c.top&&(h>s.maxHeight?p.height=(s.maxHeight-n.height)/(c.bottom+c.top):h<s.minHeight&&(p.height=(s.minHeight-n.height)/(c.bottom+c.top))),a){var g=Math.min(p.width,p.height);g!==1/0&&Ne.forEach(function(k){c[k]*=g})}else p.width!==1/0&&Zh.forEach(function(k){c[k]*=p.width}),p.height!==1/0&&Jh.forEach(function(k){c[k]*=p.height});return c}function xn(t,e,n){return e==0&&n==0?t/2:e==0?0:n==0?t:t*Math.abs(e/(e+n))}var uf=xe("vue-simple-handler"),hf=xe("vue-simple-handler-wrapper"),Fi={name:"SimpleHandler",components:{HandlerWrapper:hs},props:{defaultClass:{type:String},hoverClass:{type:String},wrapperClass:{type:String},horizontalPosition:{type:String},verticalPosition:{type:String},disabled:{type:Boolean,default:!1}},data:function(){return{hover:!1}},computed:{classes:function(){var t,e=(Ce(t={},this.horizontalPosition,!!this.horizontalPosition),Ce(t,this.verticalPosition,!!this.verticalPosition),Ce(t,"".concat(this.horizontalPosition,"-").concat(this.verticalPosition),!!(this.verticalPosition&&this.horizontalPosition)),Ce(t,"hover",this.hover),t);return{default:X(uf(e),this.defaultClass,this.hover&&this.hoverClass),wrapper:X(hf(e),this.wrapperClass)}}},methods:{onDrag:function(t){this.$emit("drag",t)},onEnter:function(){this.hover=!0},onLeave:function(){this.hover=!1},onDragEnd:function(){this.$emit("drag-end")}},emits:["drag","drag-end"]};Fi.render=function(t,e,n,r,o,s){var a=i.resolveComponent("HandlerWrapper");return i.openBlock(),i.createBlock(a,{class:s.classes.wrapper,"vertical-position":n.verticalPosition,"horizontal-position":n.horizontalPosition,disabled:n.disabled,onDrag:s.onDrag,onDragEnd:s.onDragEnd,onEnter:s.onEnter,onLeave:s.onLeave},{default:i.withCtx(function(){return[i.createVNode("div",{class:s.classes.default},null,2)]}),_:1},8,["class","vertical-position","horizontal-position","disabled","onDrag","onDragEnd","onEnter","onLeave"])};var ff=xe("vue-simple-line"),mf=xe("vue-simple-line-wrapper"),Di={name:"SimpleLine",components:{LineWrapper:fs},props:{defaultClass:{type:String},hoverClass:{type:String},wrapperClass:{type:String},position:{type:String},disabled:{type:Boolean,default:!1}},data:function(){return{hover:!1}},computed:{classes:function(){return{root:X(ff(Ce({},this.position,!0)),this.defaultClass,this.hover&&this.hoverClass),wrapper:X(mf(Ce({},this.position,!0)),this.wrapperClass)}}},methods:{onDrag:function(t){this.$emit("drag",t)},onEnter:function(){this.hover=!0},onLeave:function(){this.hover=!1},onDragEnd:function(){this.$emit("drag-end")}},emits:["drag","drag-end"]};Di.render=function(t,e,n,r,o,s){var a=i.resolveComponent("LineWrapper");return i.openBlock(),i.createBlock(a,{class:s.classes.wrapper,position:n.position,disabled:n.disabled,onDrag:s.onDrag,onDragEnd:s.onDragEnd,onEnter:s.onEnter,onLeave:s.onLeave},{default:i.withCtx(function(){return[i.createVNode("div",{class:s.classes.root},null,2)]}),_:1},8,["class","position","disabled","onDrag","onDragEnd","onEnter","onLeave"])};var Li=xe("vue-bounding-box"),pf=["east","west",null],gf=["south","north",null],ks={name:"BoundingBox",props:{width:{type:Number},height:{type:Number},transitions:{type:Object},handlers:{type:Object,default:function(){return{eastNorth:!0,north:!0,westNorth:!0,west:!0,westSouth:!0,south:!0,eastSouth:!0,east:!0}}},handlersComponent:{type:[Object,String],default:function(){return Fi}},handlersClasses:{type:Object,default:function(){return{}}},handlersWrappersClasses:{type:Object,default:function(){return{}}},lines:{type:Object,default:function(){return{west:!0,north:!0,east:!0,south:!0}}},linesComponent:{type:[Object,String],default:function(){return Di}},linesClasses:{type:Object,default:function(){return{}}},linesWrappersClasses:{type:Object,default:function(){return{}}},resizable:{type:Boolean,default:!0}},data:function(){var t=[];return pf.forEach(function(e){gf.forEach(function(n){if(e!==n){var r=ss(e,n),o=r.name,s=r.classname;t.push({name:o,classname:s,verticalDirection:n,horizontalDirection:e})}})}),{points:t}},computed:{style:function(){var t={};return this.width&&this.height&&(t.width="".concat(this.width,"px"),t.height="".concat(this.height,"px"),this.transitions&&this.transitions.enabled&&(t.transition="".concat(this.transitions.time,"ms ").concat(this.transitions.timingFunction))),t},classes:function(){var t=this.handlersClasses,e=this.handlersWrappersClasses,n=this.linesClasses,r=this.linesWrappersClasses;return{root:Li(),handlers:t,handlersWrappers:e,lines:n,linesWrappers:r}},lineNodes:function(){var t=this,e=[];return this.points.forEach(function(n){n.horizontalDirection&&n.verticalDirection||!t.lines[n.name]||e.push({name:n.name,component:t.linesComponent,class:X(t.classes.lines.default,t.classes.lines[n.name],!t.resizable&&t.classes.lines.disabled),wrapperClass:X(t.classes.linesWrappers.default,t.classes.linesWrappers[n.name],!t.resizable&&t.classes.linesWrappers.disabled),hoverClass:t.classes.lines.hover,verticalDirection:n.verticalDirection,horizontalDirection:n.horizontalDirection,disabled:!t.resizable})}),e},handlerNodes:function(){var t=this,e=[],n=this.width,r=this.height;return this.points.forEach(function(o){if(t.handlers[o.name]){var s={name:o.name,component:t.handlersComponent,class:X(t.classes.handlers.default,t.classes.handlers[o.name]),wrapperClass:X(t.classes.handlersWrappers.default,t.classes.handlersWrappers[o.name]),hoverClass:t.classes.handlers.hover,verticalDirection:o.verticalDirection,horizontalDirection:o.horizontalDirection,disabled:!t.resizable};if(n&&r){var a=o.horizontalDirection,d=o.verticalDirection,c=a==="east"?n:a==="west"?0:n/2,u=d==="south"?r:d==="north"?0:r/2;s.wrapperClass=Li("handler"),s.wrapperStyle={transform:"translate(".concat(c,"px, ").concat(u,"px)")},t.transitions&&t.transitions.enabled&&(s.wrapperStyle.transition="".concat(t.transitions.time,"ms ").concat(t.transitions.timingFunction))}else s.wrapperClass=Li("handler",Ce({},o.classname,!0));e.push(s)}}),e}},beforeMount:function(){window.addEventListener("mouseup",this.onMouseUp,{passive:!1}),window.addEventListener("mousemove",this.onMouseMove,{passive:!1}),window.addEventListener("touchmove",this.onTouchMove,{passive:!1}),window.addEventListener("touchend",this.onTouchEnd,{passive:!1})},beforeUnmount:function(){window.removeEventListener("mouseup",this.onMouseUp),window.removeEventListener("mousemove",this.onMouseMove),window.removeEventListener("touchmove",this.onTouchMove),window.removeEventListener("touchend",this.onTouchEnd)},mounted:function(){this.touches=[]},methods:{onEnd:function(){this.$emit("resize-end")},onHandlerDrag:function(t,e,n){var r,o=t.shift(),s=o.left,a=o.top,d={left:0,right:0,top:0,bottom:0};e==="west"?d.left-=s:e==="east"&&(d.right+=s),n==="north"?d.top-=a:n==="south"&&(d.bottom+=a),!n&&e?r="width":n&&!e&&(r="height"),this.resizable&&this.$emit("resize",new Wh(d,{allowedDirections:{left:e==="west"||!e,right:e==="east"||!e,bottom:n==="south"||!n,top:n==="north"||!n},preserveAspectRatio:t.nativeEvent&&t.nativeEvent.shiftKey,respectDirection:r}))}},emits:["resize","resize-end"]};ks.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"box",class:s.classes.root,style:s.style},[i.renderSlot(t.$slots,"default"),i.createVNode("div",null,[(i.openBlock(!0),i.createBlock(i.Fragment,null,i.renderList(s.lineNodes,function(a){return i.openBlock(),i.createBlock(i.resolveDynamicComponent(a.component),{key:a.name,"default-class":a.class,"hover-class":a.hoverClass,"wrapper-class":a.wrapperClass,position:a.name,disabled:a.disabled,onDrag:function(d){return s.onHandlerDrag(d,a.horizontalDirection,a.verticalDirection)},onDragEnd:e[1]||(e[1]=function(d){return s.onEnd()})},null,8,["default-class","hover-class","wrapper-class","position","disabled","onDrag"])}),128))]),(i.openBlock(!0),i.createBlock(i.Fragment,null,i.renderList(s.handlerNodes,function(a){return i.openBlock(),i.createBlock("div",{key:a.name,style:a.wrapperStyle,class:a.wrapperClass},[(i.openBlock(),i.createBlock(i.resolveDynamicComponent(a.component),{"default-class":a.class,"hover-class":a.hoverClass,"wrapper-class":a.wrapperClass,"horizontal-position":a.horizontalDirection,"vertical-position":a.verticalDirection,disabled:a.disabled,onDrag:function(d){return s.onHandlerDrag(d,a.horizontalDirection,a.verticalDirection)},onDragEnd:e[2]||(e[2]=function(d){return s.onEnd()})},null,8,["default-class","hover-class","wrapper-class","horizontal-position","vertical-position","disabled","onDrag"]))],6)}),128))],6)};var yf=xe("vue-draggable-area"),Es={name:"DraggableArea",props:{movable:{type:Boolean,default:!0},activationDistance:{type:Number,default:20}},computed:{classnames:function(){return{default:yf()}}},beforeMount:function(){window.addEventListener("mouseup",this.onMouseUp,{passive:!1}),window.addEventListener("mousemove",this.onMouseMove,{passive:!1}),window.addEventListener("touchmove",this.onTouchMove,{passive:!1}),window.addEventListener("touchend",this.onTouchEnd,{passive:!1})},beforeUnmount:function(){window.removeEventListener("mouseup",this.onMouseUp),window.removeEventListener("mousemove",this.onMouseMove),window.removeEventListener("touchmove",this.onTouchMove),window.removeEventListener("touchend",this.onTouchEnd)},mounted:function(){this.touches=[],this.touchStarted=!1},methods:{onTouchStart:function(t){if(t.cancelable){var e=this.movable&&t.touches.length===1;e&&(this.touches=it(t.touches)),(this.touchStarted||e)&&(t.preventDefault(),t.stopPropagation())}},onTouchEnd:function(){this.touchStarted=!1,this.processEnd()},onTouchMove:function(t){this.touches.length>=1&&(this.touchStarted?(this.processMove(t,t.touches),t.preventDefault(),t.stopPropagation()):us({x:this.touches[0].clientX,y:this.touches[0].clientY},{x:t.touches[0].clientX,y:t.touches[0].clientY})>this.activationDistance&&(this.initAnchor({clientX:t.touches[0].clientX,clientY:t.touches[0].clientY}),this.touchStarted=!0))},onMouseDown:function(t){if(this.movable&&t.button===0){var e={fake:!0,clientX:t.clientX,clientY:t.clientY};this.touches=[e],this.initAnchor(e),t.stopPropagation()}},onMouseMove:function(t){this.touches.length&&(this.processMove(t,[{fake:!0,clientX:t.clientX,clientY:t.clientY}]),t.preventDefault&&t.cancelable&&t.preventDefault(),t.stopPropagation())},onMouseUp:function(){this.processEnd()},initAnchor:function(t){var e=this.$refs.container.getBoundingClientRect(),n=e.left,r=e.top;this.anchor={x:t.clientX-n,y:t.clientY-r}},processMove:function(t,e){var n=it(e);if(this.touches.length){var r=this.$refs.container.getBoundingClientRect(),o=r.left,s=r.top;this.touches.length===1&&n.length===1&&this.$emit("move",new Ni({left:n[0].clientX-(o+this.anchor.x),top:n[0].clientY-(s+this.anchor.y)}))}},processEnd:function(){this.touches.length&&this.$emit("move-end"),this.touches=[]}},emits:["move","move-end"]};Es.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"container",onTouchstart:e[1]||(e[1]=function(){return s.onTouchStart&&s.onTouchStart.apply(s,arguments)}),onMousedown:e[2]||(e[2]=function(){return s.onMouseDown&&s.onMouseDown.apply(s,arguments)})},[i.renderSlot(t.$slots,"default")],544)};function Hi(t){var e,n;return{rotate:t.rotate||0,flip:{horizontal:((e=t==null?void 0:t.flip)===null||e===void 0?void 0:e.horizontal)||!1,vertical:((n=t==null?void 0:t.flip)===null||n===void 0?void 0:n.vertical)||!1}}}function wf(t){return new Promise(function(e,n){try{if(t)if(/^data:/i.test(t))e(function(c){c=c.replace(/^data:([^;]+);base64,/gim,"");for(var u=atob(c),h=u.length,f=new ArrayBuffer(h),p=new Uint8Array(f),y=0;y<h;y++)p[y]=u.charCodeAt(y);return f}(t));else if(/^blob:/i.test(t)){var r=new FileReader;r.onload=function(c){e(c.target.result)},s=t,a=function(c){r.readAsArrayBuffer(c)},(d=new XMLHttpRequest).open("GET",s,!0),d.responseType="blob",d.onload=function(){this.status!=200&&this.status!==0||a(this.response)},d.send()}else{var o=new XMLHttpRequest;o.onreadystatechange=function(){o.readyState===4&&(o.status===200||o.status===0?e(o.response):n("Warning: could not load an image to parse its orientation"),o=null)},o.onprogress=function(){o.getResponseHeader("content-type")!=="image/jpeg"&&o.abort()},o.withCredentials=!1,o.open("GET",t,!0),o.responseType="arraybuffer",o.send(null)}else n("Error: the image is empty")}catch(c){n(c)}var s,a,d})}function vs(t){var e=t.rotate,n=t.flip,r=t.scaleX,o=t.scaleY,s="";return s+=" rotate("+e+"deg) ",s+=" scaleX("+r*(n.horizontal?-1:1)+") ",s+=" scaleY("+o*(n.vertical?-1:1)+") "}function bf(t){try{var e,n=new DataView(t),r=void 0,o=void 0,s=void 0,a=void 0;if(n.getUint8(0)===255&&n.getUint8(1)===216)for(var d=n.byteLength,c=2;c+1<d;){if(n.getUint8(c)===255&&n.getUint8(c+1)===225){s=c;break}c++}if(s&&(r=s+10,function(y,g,k){var b,B="";for(b=g,k+=g;b<k;b++)B+=String.fromCharCode(y.getUint8(b));return B}(n,s+4,4)==="Exif")){var u=n.getUint16(r);if(((o=u===18761)||u===19789)&&n.getUint16(r+2,o)===42){var h=n.getUint32(r+4,o);h>=8&&(a=r+h)}}if(a){for(var f=n.getUint16(a,o),p=0;p<f;p++)if(c=a+12*p+2,n.getUint16(c,o)===274){c+=8,e=n.getUint16(c,o),n.setUint16(c,1,o);break}}return e}catch{return null}}function Ms(t,e){var n=e.getBoundingClientRect(),r=n.left,o=n.top,s={left:0,top:0},a=0;return t.forEach(function(d){s.left+=(d.clientX-r)/t.length,s.top+=(d.clientY-o)/t.length}),t.forEach(function(d){a+=us({x:s.left,y:s.top},{x:d.clientX-r,y:d.clientY-o})}),{centerMass:s,spread:a,count:t.length}}var xs={props:{touchMove:{type:Boolean,required:!0},mouseMove:{type:Boolean,required:!0},touchResize:{type:Boolean,required:!0},wheelResize:{type:[Boolean,Object],required:!0},eventsFilter:{type:Function,required:!1}},beforeMount:function(){window.addEventListener("mouseup",this.onMouseUp,{passive:!1}),window.addEventListener("mousemove",this.onMouseMove,{passive:!1}),window.addEventListener("touchmove",this.onTouchMove,{passive:!1}),window.addEventListener("touchend",this.onTouchEnd,{passive:!1})},beforeUnmount:function(){window.removeEventListener("mouseup",this.onMouseUp),window.removeEventListener("mousemove",this.onMouseMove),window.removeEventListener("touchmove",this.onTouchMove),window.removeEventListener("touchend",this.onTouchEnd)},created:function(){this.transforming=!1,this.debouncedProcessEnd=Ri(this.processEnd),this.touches=[]},methods:{processMove:function(t,e){if(this.touches.length){if(this.touches.length===1&&e.length===1)this.$emit("move",new Dt({left:this.touches[0].clientX-e[0].clientX,top:this.touches[0].clientY-e[0].clientY}));else if(this.touches.length>1&&this.touchResize){var n=Ms(e,this.$refs.container),r=this.oldGeometricProperties;r.count===n.count&&r.count>1&&this.$emit("resize",new Dt({left:r.centerMass.left-n.centerMass.left,top:r.centerMass.top-n.centerMass.top},{factor:r.spread/n.spread,center:n.centerMass})),this.oldGeometricProperties=n}this.touches=e}},processEnd:function(){this.transforming&&(this.transforming=!1,this.$emit("transform-end"))},processStart:function(){this.transforming=!0,this.debouncedProcessEnd.clear()},processEvent:function(t){return this.eventsFilter?this.eventsFilter(t,this.transforming)!==!1:(t.preventDefault(),t.stopPropagation(),!0)},onTouchStart:function(t){if(t.cancelable&&(this.touchMove||this.touchResize&&t.touches.length>1)&&this.processEvent(t)){var e=this.$refs.container,n=e.getBoundingClientRect(),r=n.left,o=n.top,s=n.bottom,a=n.right;this.touches=it(t.touches).filter(function(d){return d.clientX>r&&d.clientX<a&&d.clientY>o&&d.clientY<s}),this.oldGeometricProperties=Ms(this.touches,e)}},onTouchEnd:function(t){t.touches.length===0&&(this.touches=[],this.processEnd())},onTouchMove:function(t){var e=this;if(this.touches.length){var n=it(t.touches).filter(function(r){return!r.identifier||e.touches.find(function(o){return o.identifier===r.identifier})});this.processEvent(t)&&(this.processMove(t,n),this.processStart())}},onMouseDown:function(t){if(this.mouseMove&&"buttons"in t&&t.buttons===1&&this.processEvent(t)){var e={fake:!0,clientX:t.clientX,clientY:t.clientY};this.touches=[e],this.processStart()}},onMouseMove:function(t){this.touches.length&&this.processEvent(t)&&this.processMove(t,[{clientX:t.clientX,clientY:t.clientY}])},onMouseUp:function(){this.touches=[],this.processEnd()},onWheel:function(t){if(this.wheelResize&&this.processEvent(t)){var e=this.$refs.container.getBoundingClientRect(),n=e.left,r=e.top,o=1+this.wheelResize.ratio*(a=t.deltaY||t.detail||t.wheelDelta,(d=+a)==0||ds(d)?d:d>0?1:-1),s={left:t.clientX-n,top:t.clientY-r};this.$emit("resize",new Dt({},{factor:o,center:s})),this.touches.length||this.debouncedProcessEnd()}var a,d}},emits:["resize","move","transform-end"]};xs.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"container",onTouchstart:e[1]||(e[1]=function(){return s.onTouchStart&&s.onTouchStart.apply(s,arguments)}),onMousedown:e[2]||(e[2]=function(){return s.onMouseDown&&s.onMouseDown.apply(s,arguments)}),onWheel:e[3]||(e[3]=function(){return s.onWheel&&s.onWheel.apply(s,arguments)})},[i.renderSlot(t.$slots,"default")],544)};var Oi={components:{TransformableImage:xs},props:{touchMove:{type:Boolean,required:!0},mouseMove:{type:Boolean,required:!0},touchResize:{type:Boolean,required:!0},wheelResize:{type:[Boolean,Object],required:!0}},emits:["resize","move"]};Oi.render=function(t,e,n,r,o,s){var a=i.resolveComponent("transformable-image");return i.openBlock(),i.createBlock(a,{"touch-move":n.touchMove,"touch-resize":n.touchResize,"mouse-move":n.mouseMove,"wheel-resize":n.wheelResize,onMove:e[1]||(e[1]=function(d){return t.$emit("move",d)}),onResize:e[2]||(e[2]=function(d){return t.$emit("resize",d)})},{default:i.withCtx(function(){return[i.renderSlot(t.$slots,"default")]}),_:3},8,["touch-move","touch-resize","mouse-move","wheel-resize"])};var Bn=xe("vue-preview"),Bs={props:{coordinates:{type:Object},transitions:{type:Object},image:{type:Object,default:function(){return{}}},imageClass:{type:String},width:{type:Number},height:{type:Number},fill:{type:Boolean}},data:function(){return{calculatedImageSize:{width:0,height:0},calculatedSize:{width:0,height:0}}},computed:{classes:function(){return{root:Bn({fill:this.fill}),wrapper:Bn("wrapper"),imageWrapper:Bn("image-wrapper"),image:X(Bn("image"),this.imageClass)}},style:function(){if(this.fill)return{};var t={};return this.width&&(t.width="".concat(this.size.width,"px")),this.height&&(t.height="".concat(this.size.height,"px")),this.transitions&&this.transitions.enabled&&(t.transition="".concat(this.transitions.time,"ms ").concat(this.transitions.timingFunction)),t},wrapperStyle:function(){var t={width:"".concat(this.size.width,"px"),height:"".concat(this.size.height,"px"),left:"calc(50% - ".concat(this.size.width/2,"px)"),top:"calc(50% - ".concat(this.size.height/2,"px)")};return this.transitions&&this.transitions.enabled&&(t.transition="".concat(this.transitions.time,"ms ").concat(this.transitions.timingFunction)),t},imageStyle:function(){if(this.coordinates&&this.image){var t=this.coordinates.width/this.size.width,e=q(q({rotate:0,flip:{horizontal:!1,vertical:!1}},this.image.transforms),{},{scaleX:1/t,scaleY:1/t}),n=this.imageSize.width,r=this.imageSize.height,o=ys({width:n,height:r},e.rotate),s={width:"".concat(n,"px"),height:"".concat(r,"px"),left:"0px",top:"0px"},a={rotate:{left:(n-o.width)*e.scaleX/2,top:(r-o.height)*e.scaleY/2},scale:{left:(1-e.scaleX)*n/2,top:(1-e.scaleY)*r/2}};return s.transform=`translate(
42
- `.concat(-this.coordinates.left/t-a.rotate.left-a.scale.left,"px,").concat(-this.coordinates.top/t-a.rotate.top-a.scale.top,"px) ")+vs(e),this.transitions&&this.transitions.enabled&&(s.transition="".concat(this.transitions.time,"ms ").concat(this.transitions.timingFunction)),s}return{}},size:function(){return{width:this.width||this.calculatedSize.width,height:this.height||this.calculatedSize.height}},imageSize:function(){return{width:this.image.width||this.calculatedImageSize.width,height:this.image.height||this.calculatedImageSize.height}}},watch:{image:function(t){(t.width||t.height)&&this.onChangeImage()}},mounted:function(){var t=this;this.onChangeImage(),this.$refs.image.addEventListener("load",function(){t.refreshImage()}),window.addEventListener("resize",this.refresh),window.addEventListener("orientationchange",this.refresh)},unmounted:function(){window.removeEventListener("resize",this.refresh),window.removeEventListener("orientationchange",this.refresh)},methods:{refreshImage:function(){var t=this.$refs.image;this.calculatedImageSize.height=t.naturalHeight,this.calculatedImageSize.width=t.naturalWidth},refresh:function(){var t=this.$refs.root;this.width||(this.calculatedSize.width=t.clientWidth),this.height||(this.calculatedSize.height=t.clientHeight)},onChangeImage:function(){var t=this.$refs.image;t&&t.complete&&this.refreshImage(),this.refresh()}}};Bs.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"root",class:s.classes.root,style:s.style},[i.createVNode("div",{ref:"wrapper",class:s.classes.wrapper,style:s.wrapperStyle},[i.withDirectives(i.createVNode("img",{ref:"image",src:n.image&&n.image.src,class:s.classes.image,style:s.imageStyle},null,14,["src"]),[[i.vShow,n.image&&n.image.src]])],6)],6)};var Is={components:{Preview:Bs},inheritAttrs:!1};Is.render=function(t,e,n,r,o,s){var a=i.resolveComponent("preview");return i.openBlock(),i.createBlock(a,i.mergeProps(t.$attrs,{fill:!0}),null,16)};var _i=xe("vue-rectangle-stencil"),Rs={name:"RectangleStencil",components:{StencilPreview:Is,BoundingBox:ks,DraggableArea:Es},props:{image:{type:Object},coordinates:{type:Object},stencilCoordinates:{type:Object},handlers:{type:Object},handlersComponent:{type:[Object,String],default:function(){return Fi}},lines:{type:Object},linesComponent:{type:[Object,String],default:function(){return Di}},aspectRatio:{type:[Number,String]},minAspectRatio:{type:[Number,String]},maxAspectRatio:{type:[Number,String]},movable:{type:Boolean,default:!0},resizable:{type:Boolean,default:!0},transitions:{type:Object},movingClass:{type:String},resizingClass:{type:String},previewClass:{type:String},boundingBoxClass:{type:String},linesClasses:{type:Object,default:function(){return{}}},linesWrappersClasses:{type:Object,default:function(){return{}}},handlersClasses:{type:Object,default:function(){return{}}},handlersWrappersClasses:{type:Object,default:function(){return{}}}},data:function(){return{moving:!1,resizing:!1}},computed:{classes:function(){return{stencil:X(_i({movable:this.movable,moving:this.moving,resizing:this.resizing}),this.moving&&this.movingClass,this.resizing&&this.resizingClass),preview:X(_i("preview"),this.previewClass),boundingBox:X(_i("bounding-box"),this.boundingBoxClass)}},style:function(){var t=this.stencilCoordinates,e=t.height,n=t.width,r=t.left,o=t.top,s={width:"".concat(n,"px"),height:"".concat(e,"px"),transform:"translate(".concat(r,"px, ").concat(o,"px)")};return this.transitions&&this.transitions.enabled&&(s.transition="".concat(this.transitions.time,"ms ").concat(this.transitions.timingFunction)),s}},methods:{onMove:function(t){this.$emit("move",t),this.moving=!0},onMoveEnd:function(){this.$emit("move-end"),this.moving=!1},onResize:function(t){this.$emit("resize",t),this.resizing=!0},onResizeEnd:function(){this.$emit("resize-end"),this.resizing=!1},aspectRatios:function(){return{minimum:this.aspectRatio||this.minAspectRatio,maximum:this.aspectRatio||this.maxAspectRatio}}},emits:["resize","resize-end","move","move-end"]};Rs.render=function(t,e,n,r,o,s){var a=i.resolveComponent("stencil-preview"),d=i.resolveComponent("draggable-area"),c=i.resolveComponent("bounding-box");return i.openBlock(),i.createBlock("div",{class:s.classes.stencil,style:s.style},[i.createVNode(c,{width:n.stencilCoordinates.width,height:n.stencilCoordinates.height,transitions:n.transitions,class:s.classes.boundingBox,handlers:n.handlers,"handlers-component":n.handlersComponent,"handlers-classes":n.handlersClasses,"handlers-wrappers-classes":n.handlersWrappersClasses,lines:n.lines,"lines-component":n.linesComponent,"lines-classes":n.linesClasses,"lines-wrappers-classes":n.linesWrappersClasses,resizable:n.resizable,onResize:s.onResize,onResizeEnd:s.onResizeEnd},{default:i.withCtx(function(){return[i.createVNode(d,{movable:n.movable,onMove:s.onMove,onMoveEnd:s.onMoveEnd},{default:i.withCtx(function(){return[i.createVNode(a,{image:n.image,coordinates:n.coordinates,width:n.stencilCoordinates.width,height:n.stencilCoordinates.height,class:s.classes.preview,transitions:n.transitions},null,8,["image","coordinates","width","height","class","transitions"])]}),_:1},8,["movable","onMove","onMoveEnd"])]}),_:1},8,["width","height","transitions","class","handlers","handlers-component","handlers-classes","handlers-wrappers-classes","lines","lines-component","lines-classes","lines-wrappers-classes","resizable","onResize","onResizeEnd"])],6)};var Cf=["transitions"],De=xe("vue-advanced-cropper"),$s={name:"Cropper",components:{BackgroundWrapper:Oi},props:{src:{type:String,default:null},stencilComponent:{type:[Object,String],default:function(){return Rs}},backgroundWrapperComponent:{type:[Object,String],default:function(){return Oi}},stencilProps:{type:Object,default:function(){return{}}},autoZoom:{type:Boolean,default:!1},imageClass:{type:String},boundariesClass:{type:String},backgroundClass:{type:String},foregroundClass:{type:String},minWidth:{type:[Number,String]},minHeight:{type:[Number,String]},maxWidth:{type:[Number,String]},maxHeight:{type:[Number,String]},debounce:{type:[Boolean,Number],default:500},transitions:{type:Boolean,default:!0},checkOrientation:{type:Boolean,default:!0},canvas:{type:[Object,Boolean],default:!0},crossOrigin:{type:[Boolean,String],default:void 0},transitionTime:{type:Number,default:300},imageRestriction:{type:String,default:"fit-area",validator:function(t){return Yh.indexOf(t)!==-1}},roundResult:{type:Boolean,default:!0},defaultSize:{type:[Function,Object]},defaultPosition:{type:[Function,Object]},defaultVisibleArea:{type:[Function,Object]},defaultTransforms:{type:[Function,Object]},defaultBoundaries:{type:[Function,String],validator:function(t){return!(typeof t=="string"&&t!=="fill"&&t!=="fit")}},priority:{type:String,default:"coordinates"},stencilSize:{type:[Object,Function]},resizeImage:{type:[Boolean,Object],default:!0},moveImage:{type:[Boolean,Object],default:!0},autoZoomAlgorithm:{type:Function},resizeAlgorithm:{type:Function,default:function(t){var e=t.event,n=t.coordinates,r=t.aspectRatio,o=t.positionRestrictions,s=t.sizeRestrictions,a=A(A({},n),{right:n.left+n.width,bottom:n.top+n.height}),d=e.params||{},c=A({},e.directions),u=d.allowedDirections||{left:!0,right:!0,bottom:!0,top:!0};s.widthFrozen&&(c.left=0,c.right=0),s.heightFrozen&&(c.top=0,c.bottom=0),Ne.forEach(function(V){u[V]||(c[V]=0)});var h=Pe(a,c=Ss({coordinates:a,directions:c,sizeRestrictions:s,positionRestrictions:o})).width,f=Pe(a,c).height,p=d.preserveRatio?U(a):Ti(h/f,r);if(p){var y=d.respectDirection;if(y||(y=a.width>=a.height||p===1?"width":"height"),y==="width"){var g=h/p-a.height;if(u.top&&u.bottom){var k=c.top,b=c.bottom;c.bottom=xn(g,b,k),c.top=xn(g,k,b)}else u.bottom?c.bottom=g:u.top?c.top=g:u.right?c.right=0:u.left&&(c.left=0)}else if(y==="height"){var B=a.width-f*p;if(u.left&&u.right){var D=c.left,L=c.right;c.left=-xn(B,D,L),c.right=-xn(B,L,D)}else u.left?c.left=-B:u.right?c.right=-B:u.top?c.top=0:u.bottom&&(c.bottom=0)}c=Ss({directions:c,coordinates:a,sizeRestrictions:s,positionRestrictions:o,preserveRatio:!0,compensate:d.compensate})}return h=Pe(a,c).width,f=Pe(a,c).height,(p=d.preserveRatio?U(a):Ti(h/f,r))&&Math.abs(p-h/f)>.001&&Ne.forEach(function(V){u[V]||(c[V]=0)}),Vi({event:new Ni({left:-c.left,top:-c.top}),coordinates:{width:n.width+c.right+c.left,height:n.height+c.top+c.bottom,left:n.left,top:n.top},positionRestrictions:o})}},moveAlgorithm:{type:Function,default:Vi},initStretcher:{type:Function,default:function(t){var e=t.stretcher,n=t.imageSize,r=U(n);e.style.width=n.width+"px",e.style.height=e.clientWidth/r+"px",e.style.width=e.clientWidth+"px"}},fitCoordinates:{type:Function,default:function(t){var e=t.visibleArea,n=t.coordinates,r=t.aspectRatio,o=t.sizeRestrictions,s=t.positionRestrictions,a=A(A({},n),Fe({width:n.width,height:n.height,aspectRatio:r,sizeRestrictions:{maxWidth:e.width,maxHeight:e.height,minHeight:Math.min(e.height,o.minHeight),minWidth:Math.min(e.width,o.minWidth)}}));return a=oe(a=fe(a,yt(re(n),re(a))),vn(Ae(e),s))}},fitVisibleArea:{type:Function,default:function(t){var e=t.visibleArea,n=t.boundaries,r=t.getAreaRestrictions,o=t.coordinates,s=A({},e);s.height=s.width/U(n),s.top+=(e.height-s.height)/2,(o.height-s.height>0||o.width-s.width>0)&&(s=Se(s,Math.max(o.height/s.height,o.width/s.width)));var a=kn(bt(o,Ae(s=Se(s,En(s,r({visibleArea:s,type:"resize"}))))));return s.width<o.width&&(a.left=0),s.height<o.height&&(a.top=0),s=oe(s=fe(s,a),r({visibleArea:s,type:"move"}))}},areaRestrictionsAlgorithm:{type:Function,default:function(t){var e=t.visibleArea,n=t.boundaries,r=t.imageSize,o=t.imageRestriction,s=t.type,a={};return o==="fill-area"?a={left:0,top:0,right:r.width,bottom:r.height}:o==="fit-area"&&(U(n)>U(r)?(a={top:0,bottom:r.height},e&&s==="move"&&(e.width>r.width?(a.left=-(e.width-r.width)/2,a.right=r.width-a.left):(a.left=0,a.right=r.width))):(a={left:0,right:r.width},e&&s==="move"&&(e.height>r.height?(a.top=-(e.height-r.height)/2,a.bottom=r.height-a.top):(a.top=0,a.bottom=r.height)))),a}},sizeRestrictionsAlgorithm:{type:Function,default:function(t){return{minWidth:t.minWidth,minHeight:t.minHeight,maxWidth:t.maxWidth,maxHeight:t.maxHeight}}},positionRestrictionsAlgorithm:{type:Function,default:function(t){var e=t.imageSize,n={};return t.imageRestriction!=="none"&&(n={left:0,top:0,right:e.width,bottom:e.height}),n}}},data:function(){return{transitionsActive:!1,imageLoaded:!1,imageAttributes:{width:null,height:null,crossOrigin:null,src:null},defaultImageTransforms:{rotate:0,flip:{horizontal:!1,vertical:!1}},appliedImageTransforms:{rotate:0,flip:{horizontal:!1,vertical:!1}},boundaries:{width:0,height:0},visibleArea:null,coordinates:q({},ms)}},computed:{image:function(){return{src:this.imageAttributes.src,width:this.imageAttributes.width,height:this.imageAttributes.height,transforms:this.imageTransforms}},imageTransforms:function(){return{rotate:this.appliedImageTransforms.rotate,flip:{horizontal:this.appliedImageTransforms.flip.horizontal,vertical:this.appliedImageTransforms.flip.vertical},translateX:this.visibleArea?this.visibleArea.left/this.coefficient:0,translateY:this.visibleArea?this.visibleArea.top/this.coefficient:0,scaleX:1/this.coefficient,scaleY:1/this.coefficient}},imageSize:function(){var t=function(e){return e*Math.PI/180}(this.imageTransforms.rotate);return{width:Math.abs(this.imageAttributes.width*Math.cos(t))+Math.abs(this.imageAttributes.height*Math.sin(t)),height:Math.abs(this.imageAttributes.width*Math.sin(t))+Math.abs(this.imageAttributes.height*Math.cos(t))}},initialized:function(){return!!(this.visibleArea&&this.imageLoaded)},settings:function(){var t=$i(this.resizeImage,{touch:!0,wheel:{ratio:.1},adjustStencil:!0},{touch:!1,wheel:!1,adjustStencil:!1});return{moveImage:$i(this.moveImage,{touch:!0,mouse:!0},{touch:!1,mouse:!1}),resizeImage:t}},coefficient:function(){return this.visibleArea?this.visibleArea.width/this.boundaries.width:0},areaRestrictions:function(){return this.imageLoaded?this.areaRestrictionsAlgorithm({imageSize:this.imageSize,imageRestriction:this.imageRestriction,boundaries:this.boundaries}):{}},transitionsOptions:function(){return{enabled:this.transitionsActive,timingFunction:"ease-in-out",time:350}},sizeRestrictions:function(){if(this.boundaries.width&&this.boundaries.height&&this.imageSize.width&&this.imageSize.height){var t=this.sizeRestrictionsAlgorithm({imageSize:this.imageSize,minWidth:ee(this.minWidth)?0:Sn(this.minWidth),minHeight:ee(this.minHeight)?0:Sn(this.minHeight),maxWidth:ee(this.maxWidth)?1/0:Sn(this.maxWidth),maxHeight:ee(this.maxHeight)?1/0:Sn(this.maxHeight)});if(t=function(r){var o=r.areaRestrictions,s=r.sizeRestrictions,a=r.boundaries,d=r.positionRestrictions,c=A(A({},s),{minWidth:s.minWidth!==void 0?s.minWidth:0,minHeight:s.minHeight!==void 0?s.minHeight:0,maxWidth:s.maxWidth!==void 0?s.maxWidth:1/0,maxHeight:s.maxHeight!==void 0?s.maxHeight:1/0});d.left!==void 0&&d.right!==void 0&&(c.maxWidth=Math.min(c.maxWidth,d.right-d.left)),d.bottom!==void 0&&d.top!==void 0&&(c.maxHeight=Math.min(c.maxHeight,d.bottom-d.top));var u=zi(o),h=gs(a,u);return u.width<1/0&&(!c.maxWidth||c.maxWidth>h.width)&&(c.maxWidth=Math.min(c.maxWidth,h.width)),u.height<1/0&&(!c.maxHeight||c.maxHeight>h.height)&&(c.maxHeight=Math.min(c.maxHeight,h.height)),c.minWidth>c.maxWidth&&(c.minWidth=c.maxWidth,c.widthFrozen=!0),c.minHeight>c.maxHeight&&(c.minHeight=c.maxHeight,c.heightFrozen=!0),c}({sizeRestrictions:t,areaRestrictions:this.getAreaRestrictions({visibleArea:this.visibleArea,type:"resize"}),imageSize:this.imageSize,boundaries:this.boundaries,positionRestrictions:this.positionRestrictions,imageRestriction:this.imageRestriction,visibleArea:this.visibleArea,stencilSize:this.getStencilSize()}),this.visibleArea&&this.stencilSize){var e=this.getStencilSize(),n=zi(this.getAreaRestrictions({visibleArea:this.visibleArea,type:"resize"}));t.maxWidth=Math.min(t.maxWidth,n.width*e.width/this.boundaries.width),t.maxHeight=Math.min(t.maxHeight,n.height*e.height/this.boundaries.height),t.maxWidth<t.minWidth&&(t.minWidth=t.maxWidth),t.maxHeight<t.minHeight&&(t.minHeight=t.maxHeight)}return t}return{minWidth:0,minHeight:0,maxWidth:0,maxHeight:0}},positionRestrictions:function(){return this.positionRestrictionsAlgorithm({imageSize:this.imageSize,imageRestriction:this.imageRestriction})},classes:function(){return{cropper:De(),image:X(De("image"),this.imageClass),stencil:De("stencil"),boundaries:X(De("boundaries"),this.boundariesClass),stretcher:X(De("stretcher")),background:X(De("background"),this.backgroundClass),foreground:X(De("foreground"),this.foregroundClass),imageWrapper:X(De("image-wrapper")),cropperWrapper:X(De("cropper-wrapper"))}},stencilCoordinates:function(){if(this.initialized){var t=this.coordinates,e=t.width,n=t.height,r=t.left,o=t.top;return{width:e/this.coefficient,height:n/this.coefficient,left:(r-this.visibleArea.left)/this.coefficient,top:(o-this.visibleArea.top)/this.coefficient}}return this.defaultCoordinates()},boundariesStyle:function(){var t={width:this.boundaries.width?"".concat(Math.round(this.boundaries.width),"px"):"auto",height:this.boundaries.height?"".concat(Math.round(this.boundaries.height),"px"):"auto",transition:"opacity ".concat(this.transitionTime,"ms"),pointerEvents:this.imageLoaded?"all":"none"};return this.imageLoaded||(t.opacity="0"),t},imageStyle:function(){var t=this.imageAttributes.width>this.imageAttributes.height?{width:Math.min(1024,this.imageAttributes.width),height:Math.min(1024,this.imageAttributes.width)/(this.imageAttributes.width/this.imageAttributes.height)}:{height:Math.min(1024,this.imageAttributes.height),width:Math.min(1024,this.imageAttributes.height)*(this.imageAttributes.width/this.imageAttributes.height)},e={left:(t.width-this.imageSize.width)/(2*this.coefficient),top:(t.height-this.imageSize.height)/(2*this.coefficient)},n={left:(1-1/this.coefficient)*t.width/2,top:(1-1/this.coefficient)*t.height/2},r=q(q({},this.imageTransforms),{},{scaleX:this.imageTransforms.scaleX*(this.imageAttributes.width/t.width),scaleY:this.imageTransforms.scaleY*(this.imageAttributes.height/t.height)}),o={width:"".concat(t.width,"px"),height:"".concat(t.height,"px"),left:"0px",top:"0px",transform:"translate(".concat(-e.left-n.left-this.imageTransforms.translateX,"px, ").concat(-e.top-n.top-this.imageTransforms.translateY,"px)")+vs(r)};return this.transitionsOptions.enabled&&(o.transition="".concat(this.transitionsOptions.time,"ms ").concat(this.transitionsOptions.timingFunction)),o}},watch:{src:function(){this.onChangeImage()},stencilComponent:function(){var t=this;this.$nextTick(function(){t.resetCoordinates(),t.runAutoZoom("setCoordinates"),t.onChange()})},minWidth:function(){this.onPropsChange()},maxWidth:function(){this.onPropsChange()},minHeight:function(){this.onPropsChange()},maxHeight:function(){this.onPropsChange()},imageRestriction:function(){this.reset()},stencilProps:function(t,e){["aspectRatio","minAspectRatio","maxAspectRatio"].find(function(n){return t[n]!==e[n]})&&this.$nextTick(this.onPropsChange)}},created:function(){this.debouncedUpdate=Ri(this.update,this.debounce),this.debouncedDisableTransitions=Ri(this.disableTransitions,this.transitionsOptions.time),this.awaiting=!1},mounted:function(){this.$refs.image.addEventListener("load",this.onSuccessLoadImage),this.$refs.image.addEventListener("error",this.onFailLoadImage),this.onChangeImage(),window.addEventListener("resize",this.refresh),window.addEventListener("orientationchange",this.refresh)},unmounted:function(){window.removeEventListener("resize",this.refresh),window.removeEventListener("orientationchange",this.refresh),this.imageAttributes.revoke&&this.imageAttributes.src&&URL.revokeObjectURL(this.imageAttributes.src),this.debouncedUpdate.clear(),this.debouncedDisableTransitions.clear()},methods:{getResult:function(){var t=this.initialized?this.prepareResult(q({},this.coordinates)):this.defaultCoordinates(),e={rotate:this.imageTransforms.rotate%360,flip:q({},this.imageTransforms.flip)};if(this.src&&this.imageLoaded){var n=this;return{image:this.image,coordinates:t,visibleArea:this.visibleArea?q({},this.visibleArea):null,imageTransforms:e,get canvas(){return n.canvas?n.getCanvas():void 0}}}return{image:this.image,coordinates:t,visibleArea:this.visibleArea?q({},this.visibleArea):null,canvas:void 0,imageTransforms:e}},zoom:function(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.transitions,o=r===void 0||r;this.onManipulateImage(new Dt({},{factor:1/t,center:e}),{normalize:!1,transitions:o})},move:function(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.transitions,o=r===void 0||r;this.onManipulateImage(new Dt({left:t||0,top:e||0}),{normalize:!1,transitions:o})},setCoordinates:function(t){var e=this,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.autoZoom,o=r===void 0||r,s=n.transitions,a=s===void 0||s;this.$nextTick(function(){e.imageLoaded?(e.transitionsActive||(a&&e.enableTransitions(),e.coordinates=e.applyTransform(t),o&&e.runAutoZoom("setCoordinates"),a&&e.debouncedDisableTransitions()),e.onChange()):e.delayedTransforms=t})},refresh:function(){var t=this,e=this.$refs.image;if(this.src&&e)return this.initialized?this.updateVisibleArea().then(function(){t.onChange()}):this.resetVisibleArea().then(function(){t.onChange()})},reset:function(){var t=this;return this.resetVisibleArea().then(function(){t.onChange(!1)})},awaitRender:function(t){var e=this;this.awaiting||(this.awaiting=!0,this.$nextTick(function(){t(),e.awaiting=!1}))},prepareResult:function(t){return this.roundResult?function(e){var n=e.coordinates,r=e.sizeRestrictions,o=e.positionRestrictions,s={width:Math.round(n.width),height:Math.round(n.height),left:Math.round(n.left),top:Math.round(n.top)};return s.width>r.maxWidth?s.width=Math.floor(n.width):s.width<r.minWidth&&(s.width=Math.ceil(n.width)),s.height>r.maxHeight?s.height=Math.floor(n.height):s.height<r.minHeight&&(s.height=Math.ceil(n.height)),oe(s,o)}(q(q({},this.getPublicProperties()),{},{positionRestrictions:Mn(this.positionRestrictions,this.visibleArea),coordinates:t})):t},processAutoZoom:function(t,e,n,r){var o=this.autoZoomAlgorithm;o||(o=this.stencilSize?ef:this.autoZoom?tf:nf);var s=o({event:{type:t,params:r},visibleArea:e,coordinates:n,boundaries:this.boundaries,aspectRatio:this.getAspectRatio(),positionRestrictions:this.positionRestrictions,getAreaRestrictions:this.getAreaRestrictions,sizeRestrictions:this.sizeRestrictions,stencilSize:this.getStencilSize()});return q(q({},s),{},{changed:!ps(s.visibleArea,e)||!ps(s.coordinates,n)})},runAutoZoom:function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=e.transitions,r=n!==void 0&&n,o=qh(e,Cf),s=this.processAutoZoom(t,this.visibleArea,this.coordinates,o),a=s.visibleArea,d=s.coordinates,c=s.changed;r&&c&&this.enableTransitions(),this.visibleArea=a,this.coordinates=d,r&&c&&this.debouncedDisableTransitions()},normalizeEvent:function(t){return function(e){var n=e.event,r=e.visibleArea,o=e.coefficient;if(n.type==="manipulateImage")return A(A({},n),{move:{left:n.move&&n.move.left?o*n.move.left:0,top:n.move&&n.move.top?o*n.move.top:0},scale:{factor:n.scale&&n.scale.factor?n.scale.factor:1,center:n.scale&&n.scale.center?{left:n.scale.center.left*o+r.left,top:n.scale.center.top*o+r.top}:null}});if(n.type==="resize"){var s=A(A({},n),{directions:A({},n.directions)});return Ne.forEach(function(d){s.directions[d]*=o}),s}if(n.type==="move"){var a=A(A({},n),{directions:A({},n.directions)});return Xh.forEach(function(d){a.directions[d]*=o}),a}return n}(q(q({},this.getPublicProperties()),{},{event:t}))},getCanvas:function(){if(this.$refs.canvas){var t=this.$refs.canvas,e=this.$refs.image,n=this.imageTransforms.rotate!==0||this.imageTransforms.flip.horizontal||this.imageTransforms.flip.vertical?function(d,c,u){var h=u.rotate,f=u.flip,p={width:c.naturalWidth,height:c.naturalHeight},y=ys(p,h),g=d.getContext("2d");d.height=y.height,d.width=y.width,g.save();var k=Ue(re(A({left:0,top:0},p)),h);return g.translate(-(k.left-y.width/2),-(k.top-y.height/2)),g.rotate(h*Math.PI/180),g.translate(f.horizontal?p.width:0,f.vertical?p.height:0),g.scale(f.horizontal?-1:1,f.vertical?-1:1),g.drawImage(c,0,0,p.width,p.height),g.restore(),d}(this.$refs.sourceCanvas,e,this.imageTransforms):e,r=q({minWidth:0,minHeight:0,maxWidth:1/0,maxHeight:1/0,maxArea:this.maxCanvasSize,imageSmoothingEnabled:!0,imageSmoothingQuality:"high",fillColor:"transparent"},this.canvas),o=function(d){return d.find(function(c){return u=c,!Number.isNaN(parseFloat(u))&&isFinite(u);var u})},s=Fe({sizeRestrictions:{minWidth:o([r.width,r.minWidth])||0,minHeight:o([r.height,r.minHeight])||0,maxWidth:o([r.width,r.maxWidth])||1/0,maxHeight:o([r.height,r.maxHeight])||1/0},width:this.coordinates.width,height:this.coordinates.height,aspectRatio:{minimum:this.coordinates.width/this.coordinates.height,maximum:this.coordinates.width/this.coordinates.height}});if(r.maxArea&&s.width*s.height>r.maxArea){var a=Math.sqrt(r.maxArea/(s.width*s.height));s={width:Math.round(a*s.width),height:Math.round(a*s.height)}}return function(d,c,u,h,f){d.width=h?h.width:u.width,d.height=h?h.height:u.height;var p=d.getContext("2d");p.clearRect(0,0,d.width,d.height),f&&(f.imageSmoothingEnabled&&(p.imageSmoothingEnabled=f.imageSmoothingEnabled),f.imageSmoothingQuality&&(p.imageSmoothingQuality=f.imageSmoothingQuality),f.fillColor&&(p.fillStyle=f.fillColor,p.fillRect(0,0,d.width,d.height),p.save()));var y=u.left<0?-u.left:0,g=u.top<0?-u.top:0;p.drawImage(c,u.left+y,u.top+g,u.width,u.height,y*(d.width/u.width),g*(d.height/u.height),d.width,d.height)}(t,n,this.coordinates,s,r),t}},update:function(){this.$emit("change",this.getResult())},applyTransform:function(t){var e=arguments.length>1&&arguments[1]!==void 0&&arguments[1],n=this.visibleArea&&e?Qh(this.sizeRestrictions,this.visibleArea):this.sizeRestrictions,r=this.visibleArea&&e?Mn(this.positionRestrictions,this.visibleArea):this.positionRestrictions;return Kh({transform:t,coordinates:this.coordinates,imageSize:this.imageSize,sizeRestrictions:n,positionRestrictions:r,aspectRatio:this.getAspectRatio(),visibleArea:this.visibleArea})},resetCoordinates:function(){var t=this;if(this.$refs.image){this.$refs.cropper,this.$refs.image;var e=this.defaultSize;e||(e=this.stencilSize?sf:of);var n=this.sizeRestrictions;n.minWidth,n.minHeight,n.maxWidth,n.maxHeight;var r=gt(e)?e({boundaries:this.boundaries,imageSize:this.imageSize,aspectRatio:this.getAspectRatio(),sizeRestrictions:this.sizeRestrictions,stencilSize:this.getStencilSize(),visibleArea:this.visibleArea}):e,o=this.defaultPosition||rf,s=[r,function(a){var d=a.coordinates;return q({},gt(o)?o({coordinates:d,imageSize:t.imageSize,visibleArea:t.visibleArea}):t.defaultPosition)}];this.delayedTransforms&&s.push.apply(s,it(Array.isArray(this.delayedTransforms)?this.delayedTransforms:[this.delayedTransforms])),this.coordinates=this.applyTransform(s,!0),this.delayedTransforms=null}},clearImage:function(){var t=this;this.imageLoaded=!1,setTimeout(function(){var e=t.$refs.stretcher;e&&(e.style.height="auto",e.style.width="auto"),t.coordinates=t.defaultCoordinates(),t.boundaries={width:0,height:0}},this.transitionTime)},enableTransitions:function(){this.transitions&&(this.transitionsActive=!0)},disableTransitions:function(){this.transitionsActive=!1},updateBoundaries:function(){var t=this,e=this.$refs.stretcher,n=this.$refs.cropper;return this.initStretcher({cropper:n,stretcher:e,imageSize:this.imageSize}),this.$nextTick().then(function(){var r={cropper:n,imageSize:t.imageSize};if(gt(t.defaultBoundaries)?t.boundaries=t.defaultBoundaries(r):t.defaultBoundaries==="fit"?t.boundaries=function(o){var s=o.cropper,a=o.imageSize,d=s.clientHeight,c=s.clientWidth,u=d,h=a.width*d/a.height;return h>c&&(h=c,u=a.height*c/a.width),{width:h,height:u}}(r):t.boundaries=function(o){var s=o.cropper;return{width:s.clientWidth,height:s.clientHeight}}(r),!t.boundaries.width||!t.boundaries.height)throw new Error("It's impossible to fit the cropper in the current container")})},resetVisibleArea:function(){var t=this;return this.appliedImageTransforms=q(q({},this.defaultImageTransforms),{},{flip:q({},this.defaultImageTransforms.flip)}),this.updateBoundaries().then(function(){t.priority!=="visible-area"&&(t.visibleArea=null,t.resetCoordinates());var e,n,r,o,s,a,d=t.defaultVisibleArea||af;t.visibleArea=gt(d)?d({imageSize:t.imageSize,boundaries:t.boundaries,coordinates:t.priority!=="visible-area"?t.coordinates:null,getAreaRestrictions:t.getAreaRestrictions,stencilSize:t.getStencilSize()}):t.defaultVisibleArea,t.visibleArea=(e={visibleArea:t.visibleArea,boundaries:t.boundaries,getAreaRestrictions:t.getAreaRestrictions},n=e.visibleArea,r=e.boundaries,o=e.getAreaRestrictions,s=A({},n),a=U(r),s.width/s.height!==a&&(s.height=s.width/a),oe(s,o({visibleArea:s,type:"move"}))),t.priority==="visible-area"?t.resetCoordinates():t.coordinates=t.fitCoordinates({visibleArea:t.visibleArea,coordinates:t.coordinates,aspectRatio:t.getAspectRatio(),positionRestrictions:t.positionRestrictions,sizeRestrictions:t.sizeRestrictions}),t.runAutoZoom("resetVisibleArea")}).catch(function(){t.visibleArea=null})},updateVisibleArea:function(){var t=this;return this.updateBoundaries().then(function(){t.visibleArea=t.fitVisibleArea({imageSize:t.imageSize,boundaries:t.boundaries,visibleArea:t.visibleArea,coordinates:t.coordinates,getAreaRestrictions:t.getAreaRestrictions}),t.coordinates=t.fitCoordinates({visibleArea:t.visibleArea,coordinates:t.coordinates,aspectRatio:t.getAspectRatio(),positionRestrictions:t.positionRestrictions,sizeRestrictions:t.sizeRestrictions}),t.runAutoZoom("updateVisibleArea")}).catch(function(){t.visibleArea=null})},onChange:function(){var t=!(arguments.length>0&&arguments[0]!==void 0)||arguments[0];t&&this.debounce?this.debouncedUpdate():this.update()},onChangeImage:function(){var t,e=this;if(this.imageLoaded=!1,this.delayedTransforms=null,this.src){if(function(o){if(ls(o))return!1;var s=window.location,a=/(\w+:)?(?:\/\/)([\w.-]+)?(?::(\d+))?\/?/.exec(o)||[],d={protocol:a[1]||"",host:a[2]||"",port:a[3]||""},c=function(u){return u.port||((u.protocol||s.protocol)==="http"?80:433)};return!(!d.protocol&&!d.host&&!d.port||d.protocol&&d.protocol==s.protocol&&d.host&&d.host==s.host&&d.host&&c(d)==c(s))}(this.src)){var n=ee(this.crossOrigin)?this.canvas:this.crossOrigin;n===!0&&(n="anonymous"),this.imageAttributes.crossOrigin=n||null}if(this.checkOrientation){var r=(t=this.src,new Promise(function(o){wf(t).then(function(s){var a=bf(s);o(s?{source:t,arrayBuffer:s,orientation:a}:{source:t,arrayBuffer:null,orientation:null})}).catch(function(s){console.warn(s),o({source:t,arrayBuffer:null,orientation:null})})}));setTimeout(function(){r.then(e.onParseImage)},this.transitionTime)}else setTimeout(function(){e.onParseImage({source:e.src})},this.transitionTime)}else this.clearImage()},onFailLoadImage:function(){this.imageAttributes.src&&(this.clearImage(),this.$emit("error"))},onSuccessLoadImage:function(){var t=this,e=this.$refs.image;e&&!this.imageLoaded&&(this.imageAttributes.height=e.naturalHeight,this.imageAttributes.width=e.naturalWidth,this.imageLoaded=!0,this.resetVisibleArea().then(function(){t.$emit("ready"),t.onChange(!1)}))},onParseImage:function(t){var e=this,n=t.source,r=t.arrayBuffer,o=t.orientation;this.imageAttributes.revoke&&this.imageAttributes.src&&URL.revokeObjectURL(this.imageAttributes.src),this.imageAttributes.revoke=!1,r&&o&&o>1?as(n)||!ls(n)?(this.imageAttributes.src=URL.createObjectURL(new Blob([r])),this.imageAttributes.revoke=!0):this.imageAttributes.src=function(s){for(var a=[],d=new Uint8Array(s);d.length>0;){var c=d.subarray(0,8192);a.push(String.fromCharCode.apply(null,Array.from?Array.from(c):c.slice())),d=d.subarray(8192)}return"data:image/jpeg;base64,"+btoa(a.join(""))}(r):this.imageAttributes.src=n,gt(this.defaultTransforms)?this.appliedImageTransforms=Hi(this.defaultTransforms()):Cn(this.defaultTransforms)?this.appliedImageTransforms=Hi(this.defaultTransforms):this.appliedImageTransforms=function(s){var a=Hi({});if(s)switch(s){case 2:a.flip.horizontal=!0;break;case 3:a.rotate=-180;break;case 4:a.flip.vertical=!0;break;case 5:a.rotate=90,a.flip.vertical=!0;break;case 6:a.rotate=90;break;case 7:a.rotate=90,a.flip.horizontal=!0;break;case 8:a.rotate=-90}return a}(o),this.defaultImageTransforms=q(q({},this.appliedImageTransforms),{},{flip:q({},this.appliedImageTransforms.flip)}),this.$nextTick(function(){var s=e.$refs.image;s&&s.complete&&(function(a){return!!a.naturalWidth}(s)?e.onSuccessLoadImage():e.onFailLoadImage())})},onResizeEnd:function(){this.runAutoZoom("resize",{transitions:!0})},onMoveEnd:function(){this.runAutoZoom("move",{transitions:!0})},onMove:function(t){var e=this;this.transitionsOptions.enabled||this.awaitRender(function(){e.coordinates=e.moveAlgorithm(q(q({},e.getPublicProperties()),{},{positionRestrictions:Mn(e.positionRestrictions,e.visibleArea),coordinates:e.coordinates,event:e.normalizeEvent(t)})),e.onChange()})},onResize:function(t){var e=this;this.transitionsOptions.enabled||this.stencilSize&&!this.autoZoom||this.awaitRender(function(){var n=e.sizeRestrictions,r=Math.min(e.coordinates.width,e.coordinates.height,20*e.coefficient);e.coordinates=e.resizeAlgorithm(q(q({},e.getPublicProperties()),{},{positionRestrictions:Mn(e.positionRestrictions,e.visibleArea),sizeRestrictions:{maxWidth:Math.min(n.maxWidth,e.visibleArea.width),maxHeight:Math.min(n.maxHeight,e.visibleArea.height),minWidth:Math.max(n.minWidth,r),minHeight:Math.max(n.minHeight,r)},event:e.normalizeEvent(t)})),e.onChange(),e.ticking=!1})},onManipulateImage:function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!this.transitionsOptions.enabled){var n=e.transitions,r=n!==void 0&&n,o=e.normalize,s=o===void 0||o;r&&this.enableTransitions();var a=lf(q(q({},this.getPublicProperties()),{},{event:s?this.normalizeEvent(t):t,getAreaRestrictions:this.getAreaRestrictions,imageRestriction:this.imageRestriction,adjustStencil:!this.stencilSize&&this.settings.resizeImage.adjustStencil})),d=a.visibleArea,c=a.coordinates;this.visibleArea=d,this.coordinates=c,this.runAutoZoom("manipulateImage"),this.onChange(),r&&this.debouncedDisableTransitions()}},onPropsChange:function(){this.coordinates=this.applyTransform(this.coordinates,!0),this.onChange(!1)},getAreaRestrictions:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=t.visibleArea,n=t.type,r=n===void 0?"move":n;return this.areaRestrictionsAlgorithm({boundaries:this.boundaries,imageSize:this.imageSize,imageRestriction:this.imageRestriction,visibleArea:e,type:r})},getAspectRatio:function(t){var e,n,r=this.stencilProps,o=r.aspectRatio,s=r.minAspectRatio,a=r.maxAspectRatio;if(this.$refs.stencil&&this.$refs.stencil.aspectRatios){var d=this.$refs.stencil.aspectRatios();e=d.minimum,n=d.maximum}if(ee(e)&&(e=ee(o)?s:o),ee(n)&&(n=ee(o)?a:o),!t&&(ee(e)||ee(n))){var c=this.getStencilSize(),u=c?U(c):null;ee(e)&&(e=cs(u)?u:void 0),ee(n)&&(n=cs(u)?u:void 0)}return{minimum:e,maximum:n}},getStencilSize:function(){if(this.stencilSize)return t={currentStencilSize:{width:this.stencilCoordinates.width,height:this.stencilCoordinates.height},stencilSize:this.stencilSize,boundaries:this.boundaries,coefficient:this.coefficient,coordinates:this.coordinates,aspectRatio:this.getAspectRatio(!0)},e=t.boundaries,n=t.stencilSize,r=t.aspectRatio,Ti(U(o=gt(n)?n({boundaries:e,aspectRatio:r}):n),r)&&(o=Fe({sizeRestrictions:{maxWidth:e.width,maxHeight:e.height,minWidth:0,minHeight:0},width:o.width,height:o.height,aspectRatio:{minimum:r.minimum,maximum:r.maximum}})),(o.width>e.width||o.height>e.height)&&(o=Fe({sizeRestrictions:{maxWidth:e.width,maxHeight:e.height,minWidth:0,minHeight:0},width:o.width,height:o.height,aspectRatio:{minimum:U(o),maximum:U(o)}})),o;var t,e,n,r,o},getPublicProperties:function(){return{coefficient:this.coefficient,visibleArea:this.visibleArea,coordinates:this.coordinates,boundaries:this.boundaries,sizeRestrictions:this.sizeRestrictions,positionRestrictions:this.positionRestrictions,aspectRatio:this.getAspectRatio(),imageRestriction:this.imageRestriction}},defaultCoordinates:function(){return q({},ms)},flip:function(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.transitions,o=r===void 0||r;if(!this.transitionsActive){o&&this.enableTransitions();var s=q({},this.imageTransforms.flip),a=df({flip:{horizontal:t?!s.horizontal:s.horizontal,vertical:e?!s.vertical:s.vertical},previousFlip:s,rotate:this.imageTransforms.rotate,visibleArea:this.visibleArea,coordinates:this.coordinates,imageSize:this.imageSize,positionRestrictions:this.positionRestrictions,sizeRestrictions:this.sizeRestrictions,getAreaRestrictions:this.getAreaRestrictions,aspectRatio:this.getAspectRatio()}),d=a.visibleArea,c=a.coordinates;t&&(this.appliedImageTransforms.flip.horizontal=!this.appliedImageTransforms.flip.horizontal),e&&(this.appliedImageTransforms.flip.vertical=!this.appliedImageTransforms.flip.vertical),this.visibleArea=d,this.coordinates=c,this.onChange(),o&&this.debouncedDisableTransitions()}},rotate:function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=e.transitions,r=n===void 0||n;if(!this.transitionsActive){r&&this.enableTransitions();var o=q({},this.imageSize);this.appliedImageTransforms.rotate+=t;var s=cf({visibleArea:this.visibleArea,coordinates:this.coordinates,previousImageSize:o,imageSize:this.imageSize,angle:t,positionRestrictions:this.positionRestrictions,sizeRestrictions:this.sizeRestrictions,getAreaRestrictions:this.getAreaRestrictions,aspectRatio:this.getAspectRatio()}),a=s.visibleArea,d=s.coordinates,c=this.processAutoZoom("rotateImage",a,d);a=c.visibleArea,d=c.coordinates,this.visibleArea=a,this.coordinates=d,this.onChange(),r&&this.debouncedDisableTransitions()}}},emits:["change","error","ready"]},Sf={key:0,ref:"canvas",style:{display:"none"}},kf={key:1,ref:"sourceCanvas",style:{display:"none"}};$s.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"cropper",class:s.classes.cropper},[i.createVNode("div",{ref:"stretcher",class:s.classes.stretcher},null,2),i.createVNode("div",{class:s.classes.boundaries,style:s.boundariesStyle},[(i.openBlock(),i.createBlock(i.resolveDynamicComponent(n.backgroundWrapperComponent),{class:s.classes.cropperWrapper,"wheel-resize":s.settings.resizeImage.wheel,"touch-resize":s.settings.resizeImage.touch,"touch-move":s.settings.moveImage.touch,"mouse-move":s.settings.moveImage.mouse,onMove:s.onManipulateImage,onResize:s.onManipulateImage},{default:i.withCtx(function(){return[i.createVNode("div",{class:s.classes.background,style:s.boundariesStyle},null,6),i.createVNode("div",{class:s.classes.imageWrapper},[i.createVNode("img",{ref:"image",crossorigin:o.imageAttributes.crossOrigin,src:o.imageAttributes.src,class:s.classes.image,style:s.imageStyle,onMousedown:e[1]||(e[1]=i.withModifiers(function(){},["prevent"]))},null,46,["crossorigin","src"])],2),i.createVNode("div",{class:s.classes.foreground,style:s.boundariesStyle},null,6),i.withDirectives((i.openBlock(),i.createBlock(i.resolveDynamicComponent(n.stencilComponent),i.mergeProps({ref:"stencil",image:s.image,coordinates:o.coordinates,"stencil-coordinates":s.stencilCoordinates,transitions:s.transitionsOptions},n.stencilProps,{onResize:s.onResize,onResizeEnd:s.onResizeEnd,onMove:s.onMove,onMoveEnd:s.onMoveEnd}),null,16,["image","coordinates","stencil-coordinates","transitions","onResize","onResizeEnd","onMove","onMoveEnd"])),[[i.vShow,o.imageLoaded]]),n.canvas?(i.openBlock(),i.createBlock("canvas",Sf,null,512)):i.createCommentVNode("",!0),n.canvas?(i.openBlock(),i.createBlock("canvas",kf,null,512)):i.createCommentVNode("",!0)]}),_:1},8,["class","wheel-resize","touch-resize","touch-move","mouse-move","onMove","onResize"]))],6)],2)};const Ef={class:"background-container"},vf={class:"tools-line"},Mf={class:"line-block"},xf={class:"dialog-footer"},qi=M(i.defineComponent({__name:"ImageCropper",props:{open:{type:Boolean,required:!0},defaultRatio:{type:Number,required:!1,default:1}},emits:["crop","close"],setup(t,{emit:e}){const n=t,r=e,o=m.S.Cropper.Cropper(),s=i.ref(n.defaultRatio);o.ratio=s.value;const a=async()=>{s.value===0?o.ratio=0:o.ratio=s.value},d=i.ref({width:0,height:0,left:0,top:0}),c=i.ref(!1),u=i.ref(""),h=i.ref(),f=async()=>{c.value=!0;const y=h.value.getResult();o.ratio===0&&(s.value=d.value.width/d.value.height),y&&y.canvas.toBlob(g=>{var k;r("crop",{blob:g,src:(k=y.canvas)==null?void 0:k.toDataURL()})}),c.value=!1},p=y=>{var g;d.value=y.coordinates,u.value=(g=y.canvas)==null?void 0:g.toDataURL()};return(y,g)=>{const k=tt,b=i.resolveComponent("el-form-item"),B=i.resolveComponent("el-form"),D=i.resolveComponent("el-button"),L=Vt;return i.openBlock(),i.createBlock(L,{show:t.open,title:"Настройка изображения","close-on-click-modal":!1,"close-on-press-escape":!1,"show-close":!1},{default:i.withCtx(()=>[i.createElementVNode("div",Ef,[i.createElementVNode("div",vf,[i.createElementVNode("div",Mf,[i.createVNode(B,null,{default:i.withCtx(()=>[i.createVNode(b,{label:"Задайте пропорции фото:"},{default:i.withCtx(()=>[i.createVNode(k,{modelValue:i.unref(s),"onUpdate:modelValue":g[0]||(g[0]=V=>i.isRef(s)?s.value=V:null),label:"Пропорции изображения",onChange:a},{default:i.withCtx(()=>g[1]||(g[1]=[i.createElementVNode("option",{label:"2:3 (формат A4)",value:2/3},null,-1),i.createElementVNode("option",{label:"4:3 (для карточек новостей)",value:4/3},null,-1),i.createElementVNode("option",{label:"1:1 (для фото сотрудников)",value:1},null,-1),i.createElementVNode("option",{label:"3:2",value:3/2},null,-1),i.createElementVNode("option",{label:"16:9",value:16/9},null,-1),i.createElementVNode("option",{label:"3:4 (вертикальное изображение)",value:3/4},null,-1),i.createElementVNode("option",{label:"Задать пропорции вручную",value:0},null,-1)])),_:1},8,["modelValue"])]),_:1})]),_:1})])]),i.createVNode(i.unref($s),{ref_key:"cropperRef",ref:h,src:i.unref(o).src,"stencil-props":{aspectRatio:i.unref(o).ratio},style:{"max-height":"50vh","min-height":"50vh"},onChange:p},null,8,["src","stencil-props"]),i.createElementVNode("div",xf,[i.createVNode(D,{loading:i.unref(c),type:"success",onClick:f},{default:i.withCtx(()=>g[2]||(g[2]=[i.createTextVNode(" Сохранить ")])),_:1},8,["loading"])])])]),_:1},8,["show"])}}}),[["__scopeId","data-v-cab0e63b"]]),Ns=M(i.defineComponent({__name:"InfoItemSelectButtons",props:{selected:{type:String,required:!0},title:{type:String,required:!0},list:{type:Array,required:!0}},emits:["select","reset"],setup(t,{emit:e}){const n=i.ref(!1),r=e,o=s=>{n.value=!n.value,r("select",s)};return(s,a)=>{const d=he,c=be,u=nt;return i.openBlock(),i.createBlock(u,{close:i.unref(n),title:t.title,"close-window-overflow":"hidden","with-hover":!0,"with-open-window":!0},{"open-inside-content":i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(t.list,h=>(i.openBlock(),i.createBlock(c,{key:h,type:"admin",color:"blue",text:h,onClick:f=>o(h)},null,8,["text","onClick"]))),128)),i.createVNode(c,{type:"admin",color:"blue",text:"Сбросить",onClick:a[0]||(a[0]=h=>o(void 0))})]),default:i.withCtx(()=>[i.createVNode(d,{string:t.selected,"font-size":"14px",width:"100%"},null,8,["string"])]),_:1},8,["close","title"])}}}),[["__scopeId","data-v-89897936"]]),Bf={class:"mainblock"},If={class:"mainline"},As=M(i.defineComponent({__name:"LeftRightContainer",props:{leftWidth:{type:String,required:!1,default:"0px"},background:{type:String,required:!1,default:"inherit"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",Bf,[i.createElementVNode("div",If,[i.createElementVNode("div",{class:"mainblock-left",style:i.normalizeStyle({minWidth:t.leftWidth,maxWidth:t.leftWidth,background:t.background,display:t.leftWidth!=="0px"?"block":"none"})},[i.renderSlot(e.$slots,"left",{},void 0,!0)],4),i.createElementVNode("div",{class:"mainblock-right",style:i.normalizeStyle({background:t.background})},[i.renderSlot(e.$slots,"right",{},void 0,!0)],4)])]))}}),[["__scopeId","data-v-a4bc6b16"]]),Rf={class:"message-title"},$f={class:"message-text"},In=M(i.defineComponent({__name:"MessageBody",props:{title:{type:String,default:"",required:!1},text:{type:String,default:"",required:!1}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",null,[i.createElementVNode("div",Rf,i.toDisplayString(t.title),1),i.createElementVNode("div",$f,i.toDisplayString(t.text),1)]))}}),[["__scopeId","data-v-e3c1e672"]]),Nf=i.defineComponent({name:"CollapseContainer",props:{initActiveIdx:{type:Number,default:0}},setup(t){const e=i.ref(t.initActiveIdx),n=r=>{e.value=r};return i.watch(()=>t.initActiveIdx,()=>{n(t.initActiveIdx)}),{changeActiveId:n,activeIdx:e}}});function Af(t,e,n,r,o,s){return i.openBlock(),i.createElementBlock("div",null,[i.renderSlot(t.$slots,"default",{activeIdx:t.activeIdx,changeActiveId:t.changeActiveId})])}const Ps=M(Nf,[["render",Af]]),Pf=i.defineComponent({name:"CollapseItem",props:{tabId:{type:String,required:!1,default:""},activeId:{type:String,default:""},isCollaps:{type:Boolean,default:!0},title:{type:String,default:""},showToolsOnHover:{type:Boolean,default:!0},background:{type:String,required:!1,default:"#ffffff"},backgroundAttention:{type:String,required:!1,default:"#ffffff"},changeColor:{type:Boolean,default:!1},margin:{type:String,default:"10px 8px 2px 2px"},padding:{type:String,default:"0 10px"},selectable:{type:Boolean,default:!1}},emits:["changeActiveId"],setup(t,{emit:e}){const n=i.ref(t.activeId==="0"),r=()=>{n.value=!n.value,e("changeActiveId",t.tabId)};return i.onUpdated(()=>{t.activeId&&t.activeId!==t.tabId&&(n.value=!0)}),i.onBeforeMount(()=>{t.activeId&&t.activeId!==t.tabId&&(n.value=!1)}),{collapsed:n,handleItemClick:r}}}),Tf=["for"],zf={class:"inside-icon"};function Vf(t,e,n,r,o,s){return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createElementVNode("div",{class:"tab",style:i.normalizeStyle({margin:t.margin,height:t.isCollaps&&t.collapsed?"60px":"","box-shadow":t.selectable&&t.activeId===t.tabId?"0px 0px 1px 2px #1979cf":""})},[t.isCollaps&&t.collapsed?(i.openBlock(),i.createElementBlock("svg",{key:0,class:"icon-arrow",onClick:e[0]||(e[0]=(...a)=>t.handleItemClick&&t.handleItemClick(...a))},e[3]||(e[3]=[i.createElementVNode("use",{"xlink:href":"#arrow-down"},null,-1)]))):t.isCollaps&&!t.collapsed?(i.openBlock(),i.createElementBlock("svg",{key:1,class:"icon-arrow",onClick:e[1]||(e[1]=(...a)=>t.handleItemClick&&t.handleItemClick(...a))},e[4]||(e[4]=[i.createElementVNode("use",{"xlink:href":"#arrow-up"},null,-1)]))):i.createCommentVNode("",!0),i.createElementVNode("label",{for:t.tabId,onClick:e[2]||(e[2]=(...a)=>t.handleItemClick&&t.handleItemClick(...a))},[i.createElementVNode("div",{style:i.normalizeStyle({cursor:t.isCollaps?"pointer":"default",background:t.changeColor?t.background:t.backgroundAttention,padding:t.padding,borderRadius:"5px"}),class:"tab-name"},[i.createElementVNode("div",zf,[i.renderSlot(t.$slots,"icon",{},void 0,!0)]),t.title?(i.openBlock(),i.createElementBlock("div",{key:0,class:"title-in",style:i.normalizeStyle({marginRight:t.isCollaps?"50px":"0",width:t.isCollaps?"calc(100% - 50px)":"100%"})},i.toDisplayString(t.title),5)):(i.openBlock(),i.createElementBlock("div",{key:1,class:"title-in",style:i.normalizeStyle({marginRight:t.isCollaps?"50px":"0",width:t.isCollaps?"calc(100% - 50px)":"100%"})},[i.renderSlot(t.$slots,"inside-title",{},void 0,!0)],4)),i.createElementVNode("div",{class:i.normalizeClass(["tools-bar",{"hidden-part":t.showToolsOnHover}])},[i.renderSlot(t.$slots,"tools",{},void 0,!0)],2)],4)],8,Tf),i.createElementVNode("div",{style:i.normalizeStyle({maxHeight:t.isCollaps?"":"1000000vh",background:t.changeColor?t.background:t.backgroundAttention}),class:i.normalizeClass(t.collapsed?"tab-content-down":"tab-content-up")},[i.renderSlot(t.$slots,"inside-content",{},void 0,!0)],6)],4),e[5]||(e[5]=i.createStaticVNode('<svg width="0" height="0" class="hidden" data-v-50a7d390><symbol id="arrow-down" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" data-v-50a7d390><path d="M5 6L10 11L15 6L17 7L10 14L3 7L5 6Z" fill="currentColor" data-v-50a7d390></path></symbol><symbol id="arrow-up" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" data-v-50a7d390><path d="M15 14L10 9L5 14L3 13L10 6L17 13L15 14Z" fill="currentColor" data-v-50a7d390></path></symbol></svg>',1))],64)}const Ts=M(Pf,[["render",Vf],["__scopeId","data-v-50a7d390"]]),Ff={class:"tab"},Df={class:"rotate"},zs=M(i.defineComponent({__name:"VerticalCollapseContainer",setup(t){const e=i.ref(!1),n=async()=>{e.value=!e.value};return(r,o)=>{const s=wn,a=yn;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createElementVNode("div",Ff,[i.renderSlot(r.$slots,"main",{},void 0,!0),i.createElementVNode("div",{style:i.normalizeStyle({width:i.unref(e)?"50%":"20px",transition:"0.3s"}),class:"left"},[i.createElementVNode("div",{style:i.normalizeStyle({width:i.unref(e)?"100%":"0",transition:"0.3s"}),class:"left-content"},[i.renderSlot(r.$slots,"inside-content-left",{},void 0,!0)],4),i.createElementVNode("div",{class:"arrow-bar",onClick:n},[i.createElementVNode("div",Df,[i.renderSlot(r.$slots,"inside-title",{},void 0,!0)]),i.unref(e)?(i.openBlock(),i.createBlock(s,{key:0,"icon-class":"icon-arrow"})):(i.openBlock(),i.createBlock(a,{key:1,"icon-class":"icon-arrow"}))])],4),i.createElementVNode("div",{style:i.normalizeStyle({width:i.unref(e)?"50%":"100%",transition:"0.3s"}),class:"right"},[i.renderSlot(r.$slots,"inside-content-right",{},void 0,!0)],4)]),i.createVNode(a),i.createVNode(s)],64)}}}),[["__scopeId","data-v-d802b6b9"]]),Lf={class:"add-block_body"},Vs=M(i.defineComponent({__name:"PAdd",props:{background:{type:String,required:!1,default:"inherit"},margin:{type:String,required:!1,default:"0"},padding:{type:String,required:!1,default:"0"},top:{type:String,required:!1,default:"0"},zIndex:{type:Number,required:!1,default:0}},setup(t){return(e,n)=>{const r=gn;return i.openBlock(),i.createElementBlock("div",{class:"add-block",style:i.normalizeStyle({margin:t.margin,background:t.background,padding:t.padding})},[i.createVNode(r,{top:t.top,"z-index":t.zIndex},{default:i.withCtx(()=>[i.renderSlot(e.$slots,"title",{},void 0,!0)]),_:3},8,["top","z-index"]),i.createElementVNode("div",Lf,[i.renderSlot(e.$slots,"default",{},void 0,!0)])],4)}}}),[["__scopeId","data-v-b93bc8b1"]]),Ui=M(i.defineComponent({__name:"PContainer",props:{background:{type:String,required:!1,default:"inherit"},margin:{type:String,required:!1,default:"0"},padding:{type:String,required:!1,default:"0"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:"add-block",style:i.normalizeStyle({margin:t.margin,background:t.background,padding:t.padding})},[i.renderSlot(e.$slots,"default",{},void 0,!0)],4))}}),[["__scopeId","data-v-b89bdc7a"]]),Hf={class:"add-block_body"},Fs=M(i.defineComponent({__name:"PContainerStickyHead",props:{background:{type:String,required:!1,default:"inherit"},margin:{type:String,required:!1,default:"0"},padding:{type:String,required:!1,default:"0"},top:{type:String,required:!1,default:"0"},zIndex:{type:Number,required:!1,default:0}},setup(t){return(e,n)=>{const r=gn,o=Ui;return i.openBlock(),i.createBlock(o,{background:t.background,margin:t.margin,padding:t.padding},{default:i.withCtx(()=>[i.createVNode(r,{top:t.top,"z-index":t.zIndex},{default:i.withCtx(()=>[i.renderSlot(e.$slots,"title",{},void 0,!0)]),_:3},8,["top","z-index"]),i.createElementVNode("div",Hf,[i.renderSlot(e.$slots,"default",{},void 0,!0)])]),_:3},8,["background","margin","padding"])}}}),[["__scopeId","data-v-e59e418e"]]),Of={class:"del-block_title"},_f={class:"del-block_body"},Ds=M(i.defineComponent({__name:"PDel",props:{background:{type:String,required:!1,default:"inherit"},margin:{type:String,required:!1,default:"10px 10px 10px 50px"},padding:{type:String,required:!1,default:"10px"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:"del-block",style:i.normalizeStyle({margin:t.margin,background:t.background,padding:t.padding})},[i.createElementVNode("div",Of,[i.renderSlot(e.$slots,"title",{},void 0,!0)]),i.createElementVNode("div",_f,[i.renderSlot(e.$slots,"default",{},void 0,!0)])],4))}}),[["__scopeId","data-v-362b7b0d"]]),qf=["onClick"],Ls=M(i.defineComponent({__name:"PTabs",props:{tabs:{type:Object,required:!0},tabHeight:{type:String,required:!1,default:"40px"},height:{type:String,required:!1,default:""},minMenuItemWidth:{type:String,required:!1,default:"150px"},outTopMargin:{type:String,required:!1,default:"40px"},background:{type:String,required:!1,default:"#ffffff"}},emits:["select"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.tabs[0]),s=i.ref(0),a=i.ref(window.innerWidth),d=i.ref(),c=i.ref(Number(n.tabHeight.replace(/[^+\d]/g,""))),u=()=>{a.value=window.innerWidth,c.value=d.value?d.value.clientHeight:Number(n.tabHeight.replace(/[^+\d]/g,""))};i.onMounted(()=>window.addEventListener("resize",u)),i.onUnmounted(()=>window.removeEventListener("resize",u));const h=i.computed(()=>`calc(100% - ${c.value}px + 1px)`),f=(p,y)=>{o.value=p,s.value=y,r("select",p)};return(p,y)=>(i.openBlock(),i.createElementBlock("div",{class:"mainblock",style:i.normalizeStyle({height:`calc(100% - ${t.outTopMargin} - ${t.tabHeight}`})},[i.createElementVNode("div",{ref_key:"menuRef",ref:d,class:"top-menu",style:i.normalizeStyle({gridTemplateColumns:`repeat(auto-fit, minmax(${t.minMenuItemWidth}, 1fr))`})},[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(t.tabs,(g,k)=>(i.openBlock(),i.createElementBlock("div",{key:k},[i.createElementVNode("div",{class:i.normalizeClass({"selected-tab":k===i.unref(s),tab:k!==i.unref(s)}),style:i.normalizeStyle({minHeight:t.tabHeight,maxHeight:t.tabHeight}),onClick:b=>f(g,k)},i.toDisplayString(g.name),15,qf)]))),128))],4),i.createElementVNode("div",{class:"body-container",style:i.normalizeStyle({background:t.background,height:i.unref(h)})},[i.renderSlot(p.$slots,"default",{},()=>[(i.openBlock(),i.createBlock(i.resolveDynamicComponent(i.unref(o).component)))],!0)],4)],4))}}),[["__scopeId","data-v-3cb80968"]]),Uf=["id"],Wf=["for"],Gf={class:"left-field"},jf=["href","download"],Zf={key:1,class:"text-field__input"},Jf={class:"right-field"},Xf=i.defineComponent({__name:"UploaderFile",props:{fileInfo:{type:Object,required:!1,default:new pe},formats:{type:Array,default:()=>["pdf","jpeg","jpg"]},label:{type:String,default:"Label",required:!1},margin:{type:String,required:!1,default:"10px 0 0 0"},disabled:{type:Boolean,required:!1,default:!1},padding:{type:String,default:"",required:!1},mask:{type:String,required:!1,default:void 0},borderColor:{type:String,default:"var(--input-border-color)",required:!1},color:{type:String,default:"var(--input-font-color)",required:!1},placeholder:{type:String,required:!1,default:""}},emits:["upload","remove"],setup(t,{emit:e}){const n=t,r=e,o=m.H.Strings.CreateGuid(),s=m.H.Strings.CreateGuid(),a=()=>{const u=document.getElementById(o);if(!u.files)return;const h=u.files[0];if(h){if(!c(h.name)){m.Notification.Error("Загруженный файл должен быть в формате pdf, jpg или jpeg");return}n.fileInfo.uploadAndSetFile(h),r("upload",n.fileInfo)}},d=()=>{n.fileInfo.clearFile(),r("remove",n.fileInfo)};i.onMounted(()=>{const u=document.getElementById(s);u&&(u.onclick=()=>{var h;return(h=document.getElementById(o))==null?void 0:h.click()})});const c=u=>{let h=m.H.Extension.Get(u);return!!n.formats.includes(h.toLowerCase())};return(u,h)=>{const f=he,p=Ci,y=be;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createElementVNode("input",{id:i.unref(o),type:"file",hidden:"",onChange:a},null,40,Uf),i.createElementVNode("div",{class:"text-field",style:i.normalizeStyle({margin:t.margin,padding:t.padding})},[t.label?(i.openBlock(),i.createElementBlock("label",{key:0,class:"text-field__label",for:t.label},i.toDisplayString(t.label),9,Wf)):i.createCommentVNode("",!0),i.createElementVNode("div",{class:"field",style:i.normalizeStyle({borderColor:t.borderColor})},[i.createElementVNode("div",Gf,[i.createVNode(p,null,{default:i.withCtx(()=>[i.renderSlot(u.$slots,"default",{},void 0,!0),i.createVNode(f,{string:t.placeholder,"font-size":"var(--font-size-default:)",color:"var(--input-label-color)",margin:"0 10px 0 0"},null,8,["string"])]),_:3})]),t.fileInfo&&t.fileInfo.originalName?(i.openBlock(),i.createElementBlock("div",{key:0,class:"text-field__input",style:i.normalizeStyle({color:t.color})},[i.createElementVNode("a",{href:t.fileInfo.getFileUrl(),target:"_blank",download:t.fileInfo.originalName},[i.createElementVNode("div",null,i.toDisplayString(t.fileInfo.originalName),1)],8,jf),i.createVNode(y,{skin:"text",type:"del",onClick:d},{default:i.withCtx(()=>[i.createVNode(zt,{size:"20px",margin:"0 5px"})]),_:1})],4)):(i.openBlock(),i.createElementBlock("div",Zf,[i.createVNode(f,{string:"Файл не загружен","font-size":"var(--inpur-font-size-default)",color:"var(--palette-warning)",margin:"0 10px 0 0"})])),i.createElementVNode("div",Jf,[i.createVNode(y,{id:i.unref(s),skin:"text",type:"success","data-test":"upload-btn",text:t.fileInfo&&t.fileInfo.originalName?"Обновить":"Загрузить",margin:"0"},null,8,["id","text"])])],4)],4)],64)}}}),Hs=M(Xf,[["__scopeId","data-v-51318b14"]]),Yf={class:"container"},Qf={key:0,class:"result"},Kf={class:"list"},em=["onClick"],Wi=M(i.defineComponent({inheritAttrs:!1,__name:"PAutocomplete",props:{modelValue:{type:String,default:""},searchFunc:{type:Function,default:()=>{}},suggestions:{type:Array,default:[]}},emits:["select","input"],setup(t,{emit:e}){const n=e,r=t,o=i.ref(r.modelValue),s=i.ref([]);async function a(){n("input",o.value),await d()}async function d(){r.searchFunc&&(s.value=await r.searchFunc(o.value))}async function c(u){n("select",u)}return(u,h)=>{const f=Ei,p=dt;return i.openBlock(),i.createElementBlock("div",Yf,[i.createVNode(p,{modelValue:i.unref(o),"onUpdate:modelValue":h[0]||(h[0]=y=>i.isRef(o)?o.value=y:null),placeholder:"Найти",onInput:a},{right:i.withCtx(()=>[i.createVNode(f)]),_:1},8,["modelValue"]),i.unref(o)?(i.openBlock(),i.createElementBlock("div",Qf,[i.createElementVNode("ul",Kf,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(s),y=>(i.openBlock(),i.createElementBlock("li",{key:y.value,onClick:g=>c(y)},i.toDisplayString(y.label),9,em))),128))])])):i.createCommentVNode("",!0)])}}}),[["__scopeId","data-v-58b78c5c"]]),tm={class:"footer"},Os=M(i.defineComponent({__name:"PDialog",setup(t){const e=i.computed(()=>{switch(m.Dialog.GetType()){case"info":return"message primary";case"success":return"message success";case"warning":return"message warning";case"error":return"message danger";default:return"message neutral"}});return(n,r)=>{const o=In,s=be;return i.openBlock(),i.createBlock(i.Transition,{name:"fade"},{default:i.withCtx(()=>[("PF"in n?n.PF:i.unref(m)).Dialog.IsVisible()?(i.openBlock(),i.createElementBlock("div",{key:0,class:i.normalizeClass(i.unref(e))},[i.createVNode(o,{title:("PF"in n?n.PF:i.unref(m)).Dialog.GetTitle(),text:("PF"in n?n.PF:i.unref(m)).Dialog.GetText()},null,8,["title","text"]),i.createElementVNode("div",tm,[i.createVNode(s,{type:"primary",text:("PF"in n?n.PF:i.unref(m)).Dialog.GetConfirmButtonText(),margin:"10px 0 0 0",onClick:r[0]||(r[0]=a=>("PF"in n?n.PF:i.unref(m)).Dialog.Submit())},null,8,["text"]),i.createVNode(s,{type:"warning",text:("PF"in n?n.PF:i.unref(m)).Dialog.GetCancelButtonText(),margin:"10px 0 0 0",onClick:r[1]||(r[1]=a=>("PF"in n?n.PF:i.unref(m)).Dialog.Cancel())},null,8,["text"])])],2)):i.createCommentVNode("",!0)]),_:1})}}}),[["__scopeId","data-v-3af87587"]]),_s=M(i.defineComponent({__name:"PhoneForm",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(t){const e=i.useModel(t,"modelValue"),n=async()=>{await m.S.Phones.Update(e.value)};return(r,o)=>{const s=dt;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createVNode(s,{modelValue:e.value.number,"onUpdate:modelValue":o[0]||(o[0]=a=>e.value.number=a),onBlur:n},null,8,["modelValue"]),i.createVNode(s,{modelValue:e.value.description,"onUpdate:modelValue":o[1]||(o[1]=a=>e.value.description=a),onBlur:n},null,8,["modelValue"])],64)}}}),[["__scopeId","data-v-6de09525"]]),nm={};function im(t,e){return i.openBlock(),i.createElementBlock(i.Fragment,null,[e[0]||(e[0]=i.createElementVNode("div",{class:"blur"},null,-1)),e[1]||(e[1]=i.createElementVNode("div",{class:"loader-container"},[i.createElementVNode("div",{class:"loader",style:{"--b":"20px",width:"200px","--n":"10"}})],-1))],64)}const qs=M(nm,[["render",im],["__scopeId","data-v-879cfd55"]]),Us=M(i.defineComponent({__name:"PNotification",setup(t){const e=i.computed(()=>{switch(m.Notification.GetType()){case"info":return"message info";case"success":return"message success";case"warning":return"message warning";case"error":return"message error";default:return"message neutral"}});return(n,r)=>{const o=In;return i.openBlock(),i.createBlock(i.Transition,{name:"fade"},{default:i.withCtx(()=>[("PF"in n?n.PF:i.unref(m)).Notification.IsVisible()?(i.openBlock(),i.createElementBlock("div",{key:0,class:i.normalizeClass(i.unref(e))},[i.createVNode(o,{title:("PF"in n?n.PF:i.unref(m)).Notification.GetTitle(),text:("PF"in n?n.PF:i.unref(m)).Notification.GetText()},null,8,["title","text"])],2)):i.createCommentVNode("",!0)]),_:1})}}}),[["__scopeId","data-v-ec6a4660"]]),rm={style:{display:"flex","justify-content":"center",width:"100%"}},om={class:"pag-number"},sm={class:"pag-ul"},am={key:2},Ws=M(i.defineComponent({__name:"PPagination",props:{showConfirm:{type:Boolean,default:!1},justifyContent:{type:String,default:"center"},store:{type:Object,required:!0}},emits:["cancel","save"],setup(t,{emit:e}){const n=t,r=y=>y?"active":"neutral",o=y=>y?"not-active":"neutral",s=m.Paginator,a=i.ref(!1),d=i.ref(!1),c=e;s.count=n.store.Count().value;const u=async y=>{if(y!==s.curPage){if(y<1&&(y=1),y>s.pagesCount()&&(y=s.pagesCount()),!n.showConfirm)return await h(y);m.Dialog.Save().then(async()=>{c("save"),await h(y)}).catch(async()=>{m.Notification.Warning("Изменения не были сохранены"),c("cancel"),await h(y)})}},h=async(y,g)=>{s.setCurPage(y),m.H.FTSP.Get().p.offset=(y-1)*s.limit,await n.store.FTSP(),p()},f=i.computed(()=>{const y=s.pagesCount();return y<8?m.H.Arrays.GenerateNumsRange(2,y-1).filter(g=>g<y&&g>1):m.H.Arrays.GenerateNumsRange(s.curPage-2,s.curPage+3).filter(g=>g<y&&g>1)}),p=()=>{const y=document.querySelector(".el-table__body-wrapper"),g=document.querySelector("#list");y?y.scrollTo({top:0}):g&&g.scrollTo({top:0})};return i.onBeforeUnmount(()=>{m.H.FTSP.Get().p.drop()}),(y,g)=>{const k=yn,b=be,B=vi,D=xi,L=Mi,V=wn;return i.openBlock(),i.createElementBlock("div",rm,[i.createElementVNode("div",{class:"pag-container",style:i.normalizeStyle({justifyContent:t.justifyContent})},[i.createElementVNode("div",om,[i.createVNode(b,{skin:"pag",type:o(i.unref(s).curPage===1),onClick:g[0]||(g[0]=T=>u(i.unref(s).curPage-1))},{default:i.withCtx(()=>[i.createVNode(k)]),_:1},8,["type"]),i.createElementVNode("ul",sm,[i.createElementVNode("li",null,[i.createVNode(b,{skin:"pag",type:r(i.unref(s).curPage===1),text:"1",onClick:g[1]||(g[1]=T=>u(1))},null,8,["type"])]),i.unref(s).pagesCount()>8&&i.unref(s).curPage>4?(i.openBlock(),i.createElementBlock("li",{key:0,onMouseenter:g[3]||(g[3]=T=>a.value=!0),onMouseleave:g[4]||(g[4]=T=>a.value=!1)},[i.createVNode(b,{skin:"pag",type:"neutral",onClick:g[2]||(g[2]=T=>u(i.unref(s).curPage-5))},{default:i.withCtx(()=>[i.unref(a)?(i.openBlock(),i.createBlock(B,{key:0})):(i.openBlock(),i.createBlock(D,{key:1}))]),_:1})],32)):i.createCommentVNode("",!0),(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(f),T=>(i.openBlock(),i.createElementBlock("li",{key:T},[i.createVNode(b,{skin:"pag",type:r(T===i.unref(s).curPage),text:T,onClick:ye=>u(T)},null,8,["type","text","onClick"])]))),128)),i.unref(s).pagesCount()>=8&&i.unref(s).curPage<i.unref(s).pagesCount()-3?(i.openBlock(),i.createElementBlock("li",{key:1,onMouseenter:g[6]||(g[6]=T=>d.value=!0),onMouseleave:g[7]||(g[7]=T=>d.value=!1)},[i.createVNode(b,{skin:"pag",type:"neutral",onClick:g[5]||(g[5]=T=>u(i.unref(s).curPage+5))},{default:i.withCtx(()=>[i.unref(d)?(i.openBlock(),i.createBlock(L,{key:0})):(i.openBlock(),i.createBlock(D,{key:1}))]),_:1})],32)):i.createCommentVNode("",!0),i.unref(s).pagesCount()>1?(i.openBlock(),i.createElementBlock("li",am,[i.createVNode(b,{skin:"pag",type:r(i.unref(s).pagesCount()===i.unref(s).curPage),text:i.unref(s).pagesCount(),onClick:g[8]||(g[8]=T=>u(i.unref(s).pagesCount()))},null,8,["type","text"])])):i.createCommentVNode("",!0)]),i.createVNode(b,{skin:"pag",type:o(i.unref(s).curPage===i.unref(s).pagesCount()),onClick:g[9]||(g[9]=T=>u(i.unref(s).curPage+1))},{default:i.withCtx(()=>[i.createVNode(V)]),_:1},8,["type"])])],4)])}}}),[["__scopeId","data-v-5aea8b91"]]),Gs=M(i.defineComponent({__name:"RemoteSearch",props:{keyValue:{type:String,default:""},modelValue:{type:String,default:""},storeModule:{type:String,default:""},placeholder:{type:String,default:"Начните вводить запрос"},showSuggestions:{type:Boolean,default:!0},maxWidth:{type:[Number,String],default:350},focus:{type:Boolean,default:!1}},emits:["select","load","input"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.modelValue),s=i.ref(),a=m.S.Search.SearchModel();i.watch(()=>n.focus,()=>{n.focus&&setTimeout(()=>{s.value.focus(),o.value=""},500)});const d=async h=>{if(h.length<2)return;s.value.activated=!0,a.searchObjects=[],a.query=h,a.key=n.keyValue;const f=a.searchGroups.find(p=>p.key===n.keyValue);return f&&(a.searchGroup=f),await m.S.Search.Search(a),a.searchObjects},c=async h=>{r("select",h),o.value=""},u=h=>{r("input",h),h.length===0&&r("input","")};return(h,f)=>{const p=Wi;return i.openBlock(),i.createBlock(p,{ref_key:"searchForm",ref:s,modelValue:i.unref(o),"onUpdate:modelValue":f[0]||(f[0]=y=>i.isRef(o)?o.value=y:null),"value-key":"label",style:{width:"100%","margin-right":"10px"},placeholder:t.placeholder,"search-func":d,"trigger-on-focus":t.showSuggestions,suggestions:i.unref(a).searchObjects,onSelect:c,onInput:u},{suffix:i.withCtx(()=>f[1]||(f[1]=[i.createElementVNode("i",{class:"el-icon-search"},null,-1)])),_:1},8,["modelValue","placeholder","trigger-on-focus","suggestions"])}}}),[["__scopeId","data-v-f236facf"]]),lm={class:"mainblock-body"},cm={class:"mainblock-footer"},js=M(i.defineComponent({__name:"ResearcheContainer",props:{background:{type:String,required:!1,default:"inherit"},padding:{type:String,required:!1,default:"0px 10px"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:"mainblock",style:i.normalizeStyle({background:t.background,padding:t.padding})},[i.createElementVNode("div",{class:"mainblock-header",style:i.normalizeStyle({background:t.background})},[i.renderSlot(e.$slots,"header",{},void 0,!0)],4),i.createElementVNode("div",lm,[i.renderSlot(e.$slots,"body",{},void 0,!0)]),i.createElementVNode("div",cm,[i.renderSlot(e.$slots,"footer",{},void 0,!0)])],4))}}),[["__scopeId","data-v-a670fb4a"]]),dm={class:"right-slider-content"},um={class:"right-slider-content-header"},hm={class:"right-slider-content-box"},fm={class:"right-slider-button"},Zs=M(i.defineComponent({__name:"RightSliderContainer",props:{sliderOffWidth:{type:String,required:!1,default:"30px"},sliderOnWidth:{type:String,required:!1,default:"260px"},background:{type:String,required:!1,default:"inherit"},toggle:{type:Boolean,default:!1},titleOpen:{type:String,required:!1,default:"Скрыть список исследований"},titleClose:{type:String,required:!1,default:"Показать список исследований"}},emits:["toggle"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(!1);i.watch(()=>n.toggle,()=>{o.value=!o.value});const s=a=>{o.value=!o.value,r("toggle",a)};return(a,d)=>{const c=he;return i.openBlock(),i.createElementBlock("div",{class:"right-slider",style:i.normalizeStyle({marginRight:i.unref(o)?`calc(${t.sliderOffWidth} - ${t.sliderOnWidth})`:"0",width:t.sliderOnWidth})},[i.createElementVNode("div",{class:"click-line",onClick:d[0]||(d[0]=u=>s(!i.unref(o)))},[i.unref(o)?(i.openBlock(),i.createBlock(c,{key:0,string:t.titleClose,"font-size":"16px",padding:"0",color:"#343E5C"},null,8,["string"])):i.createCommentVNode("",!0),i.unref(o)?i.createCommentVNode("",!0):(i.openBlock(),i.createBlock(c,{key:1,string:t.titleOpen,"font-size":"16px",padding:"0",color:"#343E5C"},null,8,["string"]))]),i.createElementVNode("div",dm,[i.createElementVNode("div",um,[i.renderSlot(a.$slots,"header",{},void 0,!0)]),i.createElementVNode("div",hm,[i.renderSlot(a.$slots,"default",{},void 0,!0)])]),i.createElementVNode("div",fm,[i.renderSlot(a.$slots,"button",{},void 0,!0)])],4)}}}),[["__scopeId","data-v-495a90f9"]]),mm={class:"mainblock"},pm={class:"body-block"},gm={class:"tab-block"},Js=M(i.defineComponent({__name:"RightTabsContainer",props:{sliderOffWidth:{type:String,required:!1,default:"101px"},sliderOnWidth:{type:String,required:!1,default:"332px"},background:{type:String,required:!1,default:"inherit"},isToggle:{type:Boolean,required:!1,default:!1},mobileWidth:{type:String,required:!1,default:"768px"}},emits:["toggle"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(!1),s=i.ref(window.matchMedia("(max-width: 768px)").matches),a=c=>{r("toggle",c)},d=i.ref(!1);return i.onBeforeMount(async()=>{window.addEventListener("resize",()=>{switch(n.mobileWidth){case"1330px":return s.value=window.matchMedia("(max-width: 1330px)").matches;case"1215px":return s.value=window.matchMedia("(max-width: 1215px)").matches;case"1024px":return s.value=window.matchMedia("(max-width: 1024px)").matches;case"768px":return s.value=window.matchMedia("(max-width: 768px)").matches}return s.value=window.matchMedia("(max-width: 1330px)").matches}),o.value=!0}),(c,u)=>(i.openBlock(),i.createElementBlock("div",mm,[i.createElementVNode("div",{class:"slider-block",style:i.normalizeStyle({marginRight:i.unref(s)?t.isToggle?"49px":`calc(49px - ${t.sliderOnWidth})`:t.isToggle?t.sliderOffWidth:`calc(${t.sliderOffWidth} - ${t.sliderOnWidth})`,width:t.sliderOnWidth,minHeight:t.sliderOffWidth,height:t.isToggle?"auto":"100px"})},[i.createElementVNode("div",{class:"slider-icon",style:i.normalizeStyle({border:t.isToggle?"1px solid #379FFF":"1px solid #00B5A4",background:t.isToggle?"#ffffff":"#C7ECEA"}),onClick:u[0]||(u[0]=h=>a(!t.isToggle)),onMouseenter:u[1]||(u[1]=h=>d.value=!0),onMouseleave:u[2]||(u[2]=h=>d.value=!1)},[i.createElementVNode("div",{class:"icon-block",style:i.normalizeStyle({transform:i.unref(d)?t.isToggle?"rotate(-225deg) scale(1.2, 1.2)":"rotate(0deg) scale(1.2, 1.2)":t.isToggle?"rotate(-225deg)":"rotate(0deg)",fill:t.isToggle?"#379FFF":"#00B5A4"})},[i.renderSlot(c.$slots,"icon",{},void 0,!0)],4)],36),i.createElementVNode("div",{class:"slider-info",style:i.normalizeStyle({width:`calc(${t.sliderOnWidth} - ${t.sliderOffWidth})`})},[i.renderSlot(c.$slots,"slider-body",{},void 0,!0)],4)],4),i.createElementVNode("div",pm,[i.renderSlot(c.$slots,"body",{},void 0,!0)]),i.createElementVNode("div",gm,[i.renderSlot(c.$slots,"tabs",{},void 0,!0)])]))}}),[["__scopeId","data-v-eaeca0cc"]]),ym=["label","value"],Xs=M(i.defineComponent({__name:"SelectValueType",props:{selectedType:{type:String,required:!0}},emits:["select"],setup(t,{emit:e}){const n={[le.String]:"Текстовый ответ",[le.Text]:"Развёрнутый текстовый ответ",[le.Number]:"Числовой ответ",[le.Date]:"Ответ в виде даты",[le.Radio]:"Выбор одного из вариантов",[le.Set]:"Выбор нескольких вариантов",[le.File]:"Ответ в виде файла",[le.MatrixRadio]:"Матрица с одним выбором",[le.MatrixSet]:"Матрица с несколькими выборами"},r=e,o=s=>{r("select",s)};return(s,a)=>{const d=he,c=tt;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createVNode(d,{string:"Выберите вид ответа:","font-size":"14px",padding:"0","justify-content":"left",margin:"10px 0"}),i.createVNode(c,{"model-value":t.selectedType,placeholder:"Вид ответа",onChange:o},{default:i.withCtx(()=>[(i.openBlock(),i.createElementBlock(i.Fragment,null,i.renderList(n,(u,h)=>i.createElementVNode("option",{key:u,label:u,value:h},null,8,ym)),64))]),_:1},8,["model-value"])],64)}}}),[["__scopeId","data-v-6be05cd5"]]),wm={class:"field"},Ys=M(i.defineComponent({__name:"SingleNameToggleForm",props:{withName:{type:Object,required:!0}},emits:["submit"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(!1),s=i.ref(),a=i.ref(n.withName.name),d=i.ref(!1),c=()=>{d.value=!1},u=async()=>{a.value.trim(),n.withName.setName&&n.withName.setName(a.value),o.value=!o.value,r("submit")};return(h,f)=>{const p=he,y=i.resolveComponent("el-input"),g=i.resolveComponent("el-form-item"),k=i.resolveComponent("el-form"),b=be;return i.openBlock(),i.createBlock(k,{ref_key:"form",ref:s,style:{width:"100%"}},{default:i.withCtx(()=>[i.createVNode(nt,{title:"Название","show-save-dialog":d.value,icon:"edit-title","with-hover":!0,close:o.value,width:"100%",onKeyupEnter:u,onAfterClose:c},{"open-inside-content":i.withCtx(()=>[i.createVNode(nt,{title:"",icon:"edit-title","with-open-window":!1,"with-hover":!1,"border-color":"#ffffff","base-box-margin":"0 0 15px 0",padding:"0",width:"100%","custom-class":"test","open-width":"100%"},{default:i.withCtx(()=>[i.createElementVNode("div",wm,[i.createVNode(k,null,{default:i.withCtx(()=>[i.createVNode(g,{style:{width:"100%"},prop:"surname"},{default:i.withCtx(()=>[i.createVNode(y,{modelValue:a.value,"onUpdate:modelValue":f[0]||(f[0]=B=>a.value=B),style:{width:"100%"},autosize:!0,type:"textarea"},null,8,["modelValue"])]),_:1})]),_:1})])]),_:1}),i.createVNode(b,{type:"admin",color:"blue",text:"Сохранить",onClick:u})]),default:i.withCtx(()=>[a.value.length?(i.openBlock(),i.createBlock(p,{key:0,string:a.value.length>60?a.value.slice(0,60)+"...":a.value},null,8,["string"])):(i.openBlock(),i.createBlock(p,{key:1,string:"Введите данные",color:"#B0A4C0"}))]),_:1},8,["show-save-dialog","close"])]),_:1},512)}}}),[["__scopeId","data-v-890163ac"]]),bm=["label","value"],Qs=M(i.defineComponent({__name:"SortList",props:{maxWidth:{type:[Number,String],default:250}},emits:["load"],setup(t,{emit:e}){const n=i.ref(!1),r=e,o=i.ref();i.onBeforeMount(()=>{n.value=!0,o.value=Re.GetDefault(),m.H.FTSP.Get().setSortModel(o.value)});const s=async d=>{o.value=d??Re.GetDefault(),m.H.FTSP.Get().setSortModel(o.value),m.H.FTSP.Get().p.drop(),r("load")},a=async d=>{m.H.FTSP.Get().p.drop(),await s(d)};return(d,c)=>{var h;const u=tt;return i.unref(n)?(i.openBlock(),i.createBlock(u,{key:0,modelValue:i.unref(o),"onUpdate:modelValue":c[0]||(c[0]=f=>i.isRef(o)?o.value=f:null),"popper-append-to-body":!1,clearable:!((h=i.unref(o))!=null&&h.default),"value-key":"label",onChange:a,onClear:c[1]||(c[1]=f=>a())},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(Re).Get(),(f,p)=>(i.openBlock(),i.createElementBlock("option",{key:p,label:f.label,value:f},null,8,bm))),128))]),_:1},8,["modelValue","clearable"])):i.createCommentVNode("",!0)}}}),[["__scopeId","data-v-ef96d2ea"]]),Cm=["label","value"],Ks=M(i.defineComponent({__name:"SortSelect",props:{maxWidth:{type:[Number,String],default:250}},emits:["load"],setup(t,{emit:e}){const n=e,r=i.ref();i.onBeforeMount(()=>{r.value=Re.GetDefault()});const o=async a=>{a||(r.value=Re.GetDefault()),m.H.FTSP.Get().setSortModel(r.value),m.H.FTSP.Get().p.drop(),n("load")},s=async a=>{await o(a)};return(a,d)=>{var u;const c=tt;return i.openBlock(),i.createBlock(c,{modelValue:i.unref(r),"onUpdate:modelValue":d[0]||(d[0]=h=>i.isRef(r)?r.value=h:null),"popper-append-to-body":!1,clearable:!((u=i.unref(r))!=null&&u.default),"value-key":"label",onChange:s},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(Re).Get(),(h,f)=>(i.openBlock(),i.createElementBlock("option",{key:f,label:h.label,value:h},null,8,Cm))),128))]),_:1},8,["modelValue","clearable"])}}}),[["__scopeId","data-v-8f7ad510"]]),Sm={class:"switch-container"},km={class:"line"},Em={class:"line"},ea=M(i.defineComponent({__name:"Switch3Pos",props:{firstModel:{type:Object,required:!0},secondModel:{type:Object,required:!0},defaultLabel:{type:String,default:"Все"}},emits:["load"],setup(t,{emit:e}){const n=t,r={background:"inherit",border:"1px solid #c4c4c4"},o=()=>n.firstModel.valueEq(u.value)?void 0:r,s=()=>u.value?r:void 0,a=()=>n.secondModel.valueEq(u.value)?void 0:r,d=f=>{var y;return{color:(y=u.value)!=null&&y.valueEq(f)?"#006bb4":"#B0A4C0"}},c=e,u=i.ref(void 0),h=async f=>{var p;(p=u.value)!=null&&p.valueEq(f)||(m.H.FTSP.Get().replaceF(f,u.value),u.value=f,c("load"))};return(f,p)=>{const y=he;return i.openBlock(),i.createElementBlock("div",Sm,[i.createElementVNode("div",km,[i.createVNode(y,{string:t.firstModel.label,"font-size":"12px",padding:"0",style:i.normalizeStyle(d(t.firstModel)),onClick:p[0]||(p[0]=g=>h(t.firstModel))},null,8,["string","style"]),i.createVNode(y,{string:"Все","font-size":"12px",padding:"0",style:i.normalizeStyle(d()),onClick:p[1]||(p[1]=g=>h())},null,8,["style"]),i.createVNode(y,{string:t.secondModel.label,"font-size":"12px",padding:"0",style:i.normalizeStyle(d(t.secondModel)),onClick:p[2]||(p[2]=g=>h(t.secondModel))},null,8,["string","style"])]),i.createElementVNode("div",Em,[i.createElementVNode("div",{class:i.normalizeClass(["switch-knob1",{active:t.firstModel.valueEq(i.unref(u))}]),style:i.normalizeStyle(o()),onClick:p[3]||(p[3]=g=>h(t.firstModel))},null,6),i.createElementVNode("div",{class:i.normalizeClass(["switch-knob2",{active:!i.unref(u)}]),style:i.normalizeStyle(s()),onClick:p[4]||(p[4]=g=>h())},null,6),i.createElementVNode("div",{class:i.normalizeClass(["switch-knob3",{active:t.secondModel.valueEq(i.unref(u))}]),style:i.normalizeStyle(a()),onClick:p[5]||(p[5]=g=>h(t.secondModel))},null,6),p[6]||(p[6]=i.createElementVNode("div",{class:"switch-axis"},null,-1)),p[7]||(p[7]=i.createElementVNode("div",{class:"switch-axis-dash1"},null,-1)),p[8]||(p[8]=i.createElementVNode("div",{class:"switch-axis-dash2"},null,-1)),p[9]||(p[9]=i.createElementVNode("div",{class:"switch-axis-dash3"},null,-1))])])}}}),[["__scopeId","data-v-5dcc4d3d"]]),vm={},Mm={class:"flex"};function xm(t,e){return i.openBlock(),i.createElementBlock("div",Mm,[i.renderSlot(t.$slots,"default",{},void 0,!0)])}const ta=M(vm,[["render",xm],["__scopeId","data-v-4d1abb74"]]),na=M(i.defineComponent({__name:"ToggleInfoItem",props:{title:{type:String,required:!0},content:{type:String,required:!0}},emits:["submit"],setup(t,{emit:e}){const n=i.ref(!1),r=e,o=async()=>{r("submit"),n.value=!n.value};return(s,a)=>{const d=he,c=be,u=Ft,h=nt;return i.openBlock(),i.createBlock(h,{title:t.title,icon:"edit-title","with-hover":!0,close:i.unref(n),width:"100%",onKeyupEnter:o},{"open-inside-content":i.withCtx(()=>[i.createVNode(u,{"custom-class":"grid"},{default:i.withCtx(()=>[i.renderSlot(s.$slots,"default",{},void 0,!0),i.createVNode(c,{type:"admin",color:"blue",text:"Сохранить",onClick:o})]),_:3})]),default:i.withCtx(()=>[t.content.length>0?(i.openBlock(),i.createBlock(d,{key:0,string:t.content},null,8,["string"])):(i.openBlock(),i.createBlock(d,{key:1,string:"Введите данные",color:"#B0A4C0"}))]),_:3},8,["title","close"])}}}),[["__scopeId","data-v-994f6522"]]),Bm={class:"top-slider-content"},Im={class:"center"},ia=M(i.defineComponent({__name:"TopSliderContainer",props:{sliderOffHeight:{type:String,required:!1,default:"53px"},sliderOnHeight:{type:String,required:!1,default:"220px"},background:{type:String,required:!1,default:"inherit"},toggle:{type:Boolean,default:!1}},emits:["toggle"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(!0);i.watch(()=>n.toggle,()=>{o.value=!o.value});const s=a=>{o.value=!o.value,r("toggle",a)};return(a,d)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[i.unref(o)?i.createCommentVNode("",!0):(i.openBlock(),i.createElementBlock("div",{key:0,class:"blur",onClick:[d[0]||(d[0]=i.withModifiers(c=>o.value=!0,["prevent"])),d[1]||(d[1]=i.withModifiers(()=>{},["stop"]))]})),i.createElementVNode("div",{class:"top-slider",style:i.normalizeStyle({marginTop:i.unref(o)?`calc(${t.sliderOffHeight} - ${t.sliderOnHeight})`:"0",height:t.sliderOnHeight}),onClick:d[3]||(d[3]=i.withModifiers(()=>{},["stop"]))},[i.createElementVNode("div",Bm,[i.createElementVNode("div",Im,[i.renderSlot(a.$slots,"default",{},void 0,!0)])]),i.createElementVNode("div",{class:"click-line",style:i.normalizeStyle({height:t.sliderOffHeight}),onClick:d[2]||(d[2]=c=>s(!i.unref(o)))},[i.renderSlot(a.$slots,"title",{},void 0,!0)],4)],4)],64))}}),[["__scopeId","data-v-fec4dfde"]]),Rm={id:"drop-area",class:"img-container"},$m={key:0},Nm=["src"],Am={class:"tools-button"},Pm={class:"ins"},Tm={key:1},zm=["id"],ra=M(i.defineComponent({__name:"UploaderImage",props:{withCrop:{type:Boolean,default:!0},fileInfo:{type:pe,required:!0},height:{type:Number,default:150},width:{type:Number,default:150},cropRatio:{type:Boolean,default:!0},emitCrop:{type:Boolean,default:!1},defaultRatio:{type:Number,required:!1,default:1}},emits:["crop","removeFile"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(void 0),s=m.H.Strings.CreateGuid(),a=i.ref(!1),d=i.ref(),c=b=>{const B=n.cropRatio?n.defaultRatio:0;m.S.Cropper.Open(un.CreateCropper(b.url,B,n.fileInfo.id)),a.value=!0},u=()=>{m.Dialog.Show({text:"Вы хотите удалить изображение",confirmButtonText:"Удалить",cancelButtonText:"Не удалять"}).then(()=>{o.value=void 0,d.value.clearFiles(),r("removeFile")})},h=b=>{n.fileInfo.setFile(b),n.fileInfo.fileSystemPath&&(o.value=n.fileInfo),a.value=!1,r("crop")};i.onBeforeMount(()=>{n.fileInfo.fileSystemPath&&(o.value=n.fileInfo,o.value.url=n.fileInfo.getFileUrl())});let f=null;i.onMounted(()=>{const b=document.getElementById("drop-area");b&&(b.addEventListener("dragover",B=>{p(B),b.classList.add("drag-over")}),b.addEventListener("dragleave",B=>{p(B),b.classList.remove("drag-over")}),b.addEventListener("dragenter",p),b.addEventListener("dragleave",p),b.addEventListener("drop",g),f=document.getElementById(s))});function p(b){b.preventDefault(),b.stopPropagation()}const y=()=>{f&&f.click()};function g(b){if(b.preventDefault(),!b.dataTransfer)return;const B=b.dataTransfer.files;B.length&&f&&(f.files=B,k())}const k=()=>{if(!f||!f.files||!f.files.length)return;const b=f.files[0];b.url=URL.createObjectURL(b),o.value=b,n.fileInfo.uploadNewFile(b),c(o.value)};return(b,B)=>{const D=be,L=qi;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createElementVNode("div",Rm,[i.unref(o)?(i.openBlock(),i.createElementBlock("div",$m,[i.createElementVNode("div",{class:"img-block",style:i.normalizeStyle({width:t.height*t.defaultRatio-2+"px",height:t.height+"px"})},[i.createElementVNode("img",{class:"el-upload-list__item-thumbnail",src:i.unref(o).url,alt:"upload-image"},null,8,Nm)],4),i.createElementVNode("div",Am,[i.createElementVNode("div",Pm,[i.createVNode(D,{skin:"text",text:"Изменить","font-size":"20px",width:"300px",margin:"100px 0 0 0",onClick:B[0]||(B[0]=V=>c(i.unref(o)))}),i.createVNode(D,{skin:"text",text:"Удалить","font-size":"20px",width:"300px",margin:"50px 0 0 0",onClick:B[1]||(B[1]=V=>u())})])])])):(i.openBlock(),i.createElementBlock("div",Tm,[i.createElementVNode("div",{class:"add-button",style:i.normalizeStyle({width:t.height*t.defaultRatio-2+"px",height:t.height+"px"})},[i.createVNode(D,{skin:"text",text:"Добавить","font-size":"20px",onClick:y})],4)]))]),i.createElementVNode("input",{id:i.unref(s),type:"file",hidden:"",onChange:k},null,40,zm),t.withCrop?(i.openBlock(),i.createBlock(L,{key:0,open:i.unref(a),"default-ratio":t.defaultRatio,onCrop:h,onClose:B[2]||(B[2]=V=>a.value=!1)},null,8,["open","default-ratio"])):i.createCommentVNode("",!0)],64)}}}),[["__scopeId","data-v-4b143fdb"]]),Vm=["Orders"],Fm={install:function(t){t.component("PButton",be),t.component("PCheckBox",bi),t.component("PDatePicker",No),t.component("PFlex",Ci),t.component("PInput",dt),t.component("PInputDate",Si),t.component("PInputNumber",Ao),t.component("PLeftSlider",Po),t.component("PList",To),t.component("PListItem",zo),t.component("PRadio",Vo),t.component("PRightSlider",Fo),t.component("PSelect",tt),t.component("PSticky",gn),t.component("PString",he),t.component("PTextarea",Do),t.component("PTopSlider",Lo),t.component("IconDownload",Yo),t.component("IconFilter",Qo),t.component("ArrowLeft",yn),t.component("ArrowRight",wn),t.component("DoubleArrowLeft",vi),t.component("DoubleArrowRight",Mi),t.component("EllipsisSvg",xi),t.component("IconArrowLeft",Ko),t.component("IconCheckDefault",wi),t.component("IconClose",zt),t.component("IconEdit",es),t.component("IconEmail",ts),t.component("IconMove",ns),t.component("IconPhone",is),t.component("IconSearch",Ei),t.component("IconSelectArrow",ki),t.component("CollapseContainer",Ps),t.component("CollapseItem",Ts),t.component("VerticalCollapseContainer",zs),t.component("PAdd",Vs),t.component("PContainer",Ui),t.component("PContainerStickyHead",Fs),t.component("PDel",Ds),t.component("PTabs",Ls),t.component("UploaderFile",Hs),t.component("AuthForm",cn),t.component("PModal",Vt),t.component("AuthPage",ci),t.component("PageNotFound",di),t.component("AdaptiveContainer",Yi),t.component("AdaptiveContainerHorizontal",Qi),t.component("AdminGallery",$o),t.component("AuthModal",Ho),t.component("CarouselImages",Oo),t.component("ContextWindow",_o),t.component("DateInputRangeV2",Uo),t.component("DateInputRange",qo),t.component("DropList",Wo),t.component("FilterCheckbox",Go),t.component("FiltersButtonsSelect",jo),t.component("FilterSelect",Zo),t.component("FTSPPanel",Jo),t.component("GeneralItem",Xo),t.component("GridContainer",Ft),t.component("ImageCropper",qi),t.component("InfoItem",nt),t.component("InfoItemSelectButtons",Ns),t.component("LeftRightContainer",As),t.component("MessageBody",In),t.component("PAutocomplete",Wi),t.component("PDialog",Os),t.component("PhoneForm",_s),t.component("PLoader",qs),t.component("PNotification",Us),t.component("PPagination",Ws),t.component("RemoteSearch",Gs),t.component("ResearcheContainer",js),t.component("RightSliderContainer",Zs),t.component("RightTabsContainer",Js),t.component("SelectValueType",Xs),t.component("SingleNameToggleForm",Ys),t.component("SortList",Qs),t.component("SortSelect",Ks),t.component("Switch3Pos",ea),t.component("ThemeWrapper",ta),t.component("ToggleInfoItem",na),t.component("TopSliderContainer",ia),t.component("UploaderImage",ra)}},Dm=["PF","PFM"];v.AdaptiveContainer=Yi,v.AdaptiveContainerHorizontal=Qi,v.AdminGallery=$o,v.ArrowLeft=yn,v.ArrowRight=wn,v.AuthForm=cn,v.AuthModal=Ho,v.AuthPage=ci,v.CarouselImages=Oo,v.CollapseContainer=Ps,v.CollapseItem=Ts,v.ContextWindow=_o,v.DateInputRange=qo,v.DateInputRange_v2=Uo,v.DoubleArrowLeft=vi,v.DoubleArrowRight=Mi,v.DropList=Wo,v.EllipsisSvg=xi,v.FTSPPanel=Jo,v.FilterCheckbox=Go,v.FilterSelect=Zo,v.FiltersButtonsSelect=jo,v.GeneralItem=Xo,v.GridContainer=Ft,v.IconArrowLeft=Ko,v.IconCheckDefault=wi,v.IconClose=zt,v.IconDownload=Yo,v.IconEdit=es,v.IconEmail=ts,v.IconFilter=Qo,v.IconMove=ns,v.IconPhone=is,v.IconSearch=Ei,v.IconSelectArrow=ki,v.ImageCropper=qi,v.InfoItem=nt,v.InfoItemSelectButtons=Ns,v.LeftRightContainer=As,v.MessageBody=In,v.Orders=Ie,v.PAdd=Vs,v.PAutocomplete=Wi,v.PButton=be,v.PCheckBox=bi,v.PContainer=Ui,v.PContainerStickyHead=Fs,v.PDatePicker=No,v.PDel=Ds,v.PDialog=Os,v.PFM=Ku,v.PFlex=Ci,v.PInput=dt,v.PInputDate=Si,v.PInputNumber=Ao,v.PLeftSlider=Po,v.PList=To,v.PListItem=zo,v.PLoader=qs,v.PModal=Vt,v.PNotification=Us,v.PPagination=Ws,v.PRadio=Vo,v.PRightSlider=Fo,v.PSelect=tt,v.PSticky=gn,v.PString=he,v.PTabs=Ls,v.PTextarea=Do,v.PTopSlider=Lo,v.PageNotFound=di,v.PhoneForm=_s,v.RemoteSearch=Gs,v.ResearcheContainer=js,v.RightSliderContainer=Zs,v.RightTabsContainer=Js,v.SelectValueType=Xs,v.SingleNameToggleForm=Ys,v.SortList=Qs,v.SortSelect=Ks,v.Switch3Pos=ea,v.ThemeWrapper=ta,v.ToggleInfoItem=na,v.TopSliderContainer=ia,v.UploaderFile=Hs,v.UploaderImage=ra,v.VerticalCollapseContainer=zs,v.pfName=Dm,v.servicesComponents=Fm,v.typesNames=Vm,Object.defineProperty(v,Symbol.toStringTag,{value:"Module"})});
41
+ ***************************************************************************** */function ls(t,e){var n,r;return t&&e?(n=""+t+e[0].toUpperCase()+e.slice(1),r=t+"-"+e):(n=t||e,r=t||e),{name:n,classname:r}}function cs(t){return/^blob:/.test(t)}function ds(t){return cs(t)||function(e){return/^data:/.test(e)}(t)}function yt(t){return!!(t&&t.constructor&&t.call&&t.apply)}function ne(t){return t===void 0}function Sn(t){return typeof t=="object"&&t!==null}function Ni(t,e,n){var r={};return Sn(t)?(Object.keys(e).forEach(function(o){ne(t[o])?r[o]=e[o]:Sn(e[o])?Sn(t[o])?r[o]=Ni(t[o],e[o],n[o]):r[o]=t[o]?e[o]:n[o]:e[o]===!0||e[o]===!1?r[o]=!!t[o]:r[o]=t[o]}),r):t?e:n}function kn(t){var e=Number(t);return Number.isNaN(e)?t:e}function us(t){return typeof(t=="number"||function(e){return typeof e=="object"&&e!==null}(t)&&toString.call(t)=="[object Number]")&&!hs(t)}function hs(t){return t!=t}function fs(t,e){return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}var Lt=function(t,e){t===void 0&&(t={}),e===void 0&&(e={}),this.type="manipulateImage",this.move=t,this.scale=e},jh=function(t,e){e===void 0&&(e={}),this.type="resize",this.directions=t,this.params=e},Ai=function(t){this.type="move",this.directions=t},Zh=function(){function t(e,n,r,o,s){this.type="drag",this.nativeEvent=e,this.position=r,this.previousPosition=o,this.element=n,this.anchor=s}return t.prototype.shift=function(){var e=this,n=e.element,r=e.anchor,o=e.position;if(n){var s=n.getBoundingClientRect(),a=s.left,d=s.top;return{left:o.left-a-r.left,top:o.top-d-r.top}}return{left:0,top:0}},t}(),Pi={name:"DraggableElement",props:{classname:{type:String}},beforeMount:function(){window.addEventListener("mouseup",this.onMouseUp,{passive:!1}),window.addEventListener("mousemove",this.onMouseMove,{passive:!1}),window.addEventListener("touchmove",this.onTouchMove,{passive:!1}),window.addEventListener("touchend",this.onTouchEnd,{passive:!1})},beforeUnmount:function(){window.removeEventListener("mouseup",this.onMouseUp),window.removeEventListener("mousemove",this.onMouseMove),window.removeEventListener("touchmove",this.onTouchMove),window.removeEventListener("touchend",this.onTouchEnd)},mounted:function(){if(!this.$refs.draggable)throw new Error('You should add ref "draggable" to your root element to use draggable mixin');this.touches=[],this.hovered=!1},methods:{onMouseOver:function(){this.hovered||(this.hovered=!0,this.$emit("enter"))},onMouseLeave:function(){this.hovered&&!this.touches.length&&(this.hovered=!1,this.$emit("leave"))},onTouchStart:function(t){t.cancelable&&!this.disabled&&t.touches.length===1&&(this.touches=ot(t.touches),this.hovered||(this.$emit("enter"),this.hovered=!0),t.touches.length&&this.initAnchor(this.touches.reduce(function(e,n){return{clientX:e.clientX+n.clientX/t.touches.length,clientY:e.clientY+n.clientY/t.touches.length}},{clientX:0,clientY:0})),t.preventDefault&&t.preventDefault(),t.stopPropagation())},onTouchEnd:function(){this.processEnd()},onTouchMove:function(t){this.touches.length&&(this.processMove(t,t.touches),t.preventDefault&&t.preventDefault(),t.stopPropagation&&t.stopPropagation())},onMouseDown:function(t){if(!this.disabled){var e={fake:!0,clientX:t.clientX,clientY:t.clientY};this.touches=[e],this.initAnchor(e),t.stopPropagation()}},onMouseMove:function(t){this.touches.length&&(this.processMove(t,[{fake:!0,clientX:t.clientX,clientY:t.clientY}]),t.preventDefault&&t.preventDefault())},onMouseUp:function(){this.processEnd()},initAnchor:function(t){var e=this.$refs.draggable.getBoundingClientRect(),n=e.left,r=e.right,o=e.bottom,s=e.top;this.anchor={left:t.clientX-n,top:t.clientY-s,bottom:o-t.clientY,right:r-t.clientX}},processMove:function(t,e){var n=ot(e);if(this.touches.length){if(this.touches.length===1&&n.length===1){var r=this.$refs.draggable;this.$emit("drag",new Zh(t,r,{left:n[0].clientX,top:n[0].clientY},{left:this.touches[0].clientX,top:this.touches[0].clientY},this.anchor))}this.touches=n}},processEnd:function(){this.touches.length&&this.$emit("drag-end"),this.hovered&&(this.$emit("leave"),this.hovered=!1),this.touches=[]}},emits:["drag","drag-end","leave","enter"]};Pi.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"draggable",class:n.classname,onTouchstart:e[1]||(e[1]=function(){return s.onTouchStart&&s.onTouchStart.apply(s,arguments)}),onMousedown:e[2]||(e[2]=function(){return s.onMouseDown&&s.onMouseDown.apply(s,arguments)}),onMouseover:e[3]||(e[3]=function(){return s.onMouseOver&&s.onMouseOver.apply(s,arguments)}),onMouseleave:e[4]||(e[4]=function(){return s.onMouseLeave&&s.onMouseLeave.apply(s,arguments)})},[i.renderSlot(t.$slots,"default")],34)};var Ti=Ie("vue-handler-wrapper"),ms={name:"HandlerWrapper",components:{DraggableElement:Pi},props:{horizontalPosition:{type:String},verticalPosition:{type:String},disabled:{type:Boolean,default:!1}},computed:{classes:function(){var t;if(this.horizontalPosition||this.verticalPosition){var e,n=ls(this.horizontalPosition,this.verticalPosition);t=Ti((ke(e={},n.classname,!0),ke(e,"disabled",this.disabled),e))}else t=Ti({disabled:this.disabled});return{root:t,draggable:Ti("draggable")}}},emits:["leave","enter","drag","drag-end"]};ms.render=function(t,e,n,r,o,s){var a=i.resolveComponent("DraggableElement");return i.openBlock(),i.createBlock("div",{class:s.classes.root},[i.createVNode(a,{class:s.classes.draggable,onDrag:e[1]||(e[1]=function(d){return t.$emit("drag",d)}),onDragEnd:e[2]||(e[2]=function(d){return t.$emit("drag-end")}),onLeave:e[3]||(e[3]=function(d){return t.$emit("leave")}),onEnter:e[4]||(e[4]=function(d){return t.$emit("enter")})},{default:i.withCtx(function(){return[i.renderSlot(t.$slots,"default")]}),_:3},8,["class"])],2)};var Jh=Ie("vue-line-wrapper"),ps={name:"LineWrapper",components:{DraggableElement:Pi},props:{position:{type:String,required:!0},disabled:{type:Boolean,default:!1}},computed:{classname:function(){var t;return Jh((ke(t={},this.position,!0),ke(t,"disabled",this.disabled),t))}},emits:["leave","enter","drag","drag-end"]};ps.render=function(t,e,n,r,o,s){var a=i.resolveComponent("DraggableElement");return i.openBlock(),i.createBlock(a,{class:s.classname,onDrag:e[1]||(e[1]=function(d){return t.$emit("drag",d)}),onDragEnd:e[2]||(e[2]=function(d){return t.$emit("drag-end")}),onLeave:e[3]||(e[3]=function(d){return t.$emit("leave")}),onEnter:e[4]||(e[4]=function(d){return t.$emit("enter")})},{default:i.withCtx(function(){return[i.renderSlot(t.$slots,"default")]}),_:3},8,["class"])};var Te=["left","right","top","bottom"],Xh=["left","right"],Yh=["top","bottom"],Qh=["left","top"],Kh=["fill-area","fit-area","stencil","none"],gs={left:0,top:0,width:0,height:0};function ys(t,e,n){return!(n=n||["width","height","left","top"]).some(function(r){return t[r]!==e[r]})}function ze(t){return{left:t.left,top:t.top,right:t.left+t.width,bottom:t.top+t.height}}function wt(t,e){return{left:t.left-e.left,top:t.top-e.top}}function se(t){return{left:t.left+t.width/2,top:t.top+t.height/2}}function Ot(t,e){var n={left:0,top:0,right:0,bottom:0};return Te.forEach(function(r){var o=e[r],s=ze(t)[r];n[r]=o!==void 0&&s!==void 0?r==="left"||r==="top"?Math.max(0,o-s):Math.max(0,s-o):0}),n}function Ve(t,e){return{left:t.left-e.left,top:t.top-e.top,width:t.width+e.left+e.right,height:t.height+e.top+e.bottom}}function En(t){return{left:-t.left,top:-t.top}}function pe(t,e){return A(A({},t),{left:t.left+e.left,top:t.top+e.top})}function Ee(t,e,n,r){if(e!==1){if(n){var o=se(t);return{width:t.width*e,height:t.height*e,left:t.left+t.width*(1-e)/2+(n.left-o.left)*(1-e),top:t.top+t.height*(1-e)/2+(n.top-o.top)*(1-e)}}return{width:t.width*e,height:t.height*e,left:t.left+t.width*(1-e)/2,top:t.top+t.height*(1-e)/2}}return t}function W(t){return t.width/t.height}function bt(t,e){return Math.min(e.right!==void 0&&e.left!==void 0?(e.right-e.left)/t.width:1/0,e.bottom!==void 0&&e.top!==void 0?(e.bottom-e.top)/t.height:1/0)}function Ct(t,e){var n={left:0,top:0},r=Ot(t,e);return r.left&&r.left>0?n.left=r.left:r.right&&r.right>0&&(n.left=-r.right),r.top&&r.top>0?n.top=r.top:r.bottom&&r.bottom>0&&(n.top=-r.bottom),n}function zi(t,e){var n;return e.minimum&&t<e.minimum?n=e.minimum:e.maximum&&t>e.maximum&&(n=e.maximum),n}function ws(t,e){var n=W(t),r=W(e);return e.width<1/0&&e.height<1/0?n>r?{width:e.width,height:e.width/n}:{width:e.height*n,height:e.height}:e.width<1/0?{width:e.width,height:e.width/n}:e.height<1/0?{width:e.height*n,height:e.height}:t}function bs(t,e){var n=e*Math.PI/180;return{width:Math.abs(t.width*Math.cos(n))+Math.abs(t.height*Math.sin(n)),height:Math.abs(t.width*Math.sin(n))+Math.abs(t.height*Math.cos(n))}}function je(t,e){var n=e*Math.PI/180;return{left:t.left*Math.cos(n)-t.top*Math.sin(n),top:t.left*Math.sin(n)+t.top*Math.cos(n)}}function vn(t,e){var n=Ot(ae(t,e),e);return n.left+n.right+n.top+n.bottom?n.left+n.right>n.top+n.bottom?Math.min((t.width+n.left+n.right)/t.width,bt(t,e)):Math.min((t.height+n.top+n.bottom)/t.height,bt(t,e)):1}function ae(t,e,n){n===void 0&&(n=!1);var r=Ct(t,e);return pe(t,n?En(r):r)}function Vi(t){return{width:t.right!==void 0&&t.left!==void 0?t.right-t.left:1/0,height:t.bottom!==void 0&&t.top!==void 0?t.bottom-t.top:1/0}}function ef(t,e){return A(A({},t),{minWidth:Math.min(e.width,t.minWidth),minHeight:Math.min(e.height,t.minHeight),maxWidth:Math.min(e.width,t.maxWidth),maxHeight:Math.min(e.height,t.maxHeight)})}function Cs(t,e,n){n===void 0&&(n=!0);var r={};return Te.forEach(function(o){var s=t[o],a=e[o];s!==void 0&&a!==void 0?r[o]=o==="left"||o==="top"?n?Math.max(s,a):Math.min(s,a):n?Math.min(s,a):Math.max(s,a):a!==void 0?r[o]=a:s!==void 0&&(r[o]=s)}),r}function Mn(t,e){return Cs(t,e,!0)}function Ss(t){var e=t.size,n=t.aspectRatio,r=t.ignoreMinimum,o=t.sizeRestrictions;return!!((e.correctRatio||W(e)>=n.minimum&&W(e)<=n.maximum)&&e.height<=o.maxHeight&&e.width<=o.maxWidth&&e.width&&e.height&&(r||e.height>=o.minHeight&&e.width>=o.minWidth))}function ks(t,e){return Math.pow(t.width-e.width,2)+Math.pow(t.height-e.height,2)}function He(t){var e=t.width,n=t.height,r=t.sizeRestrictions,o={minimum:t.aspectRatio&&t.aspectRatio.minimum||0,maximum:t.aspectRatio&&t.aspectRatio.maximum||1/0},s={width:Math.max(r.minWidth,Math.min(r.maxWidth,e)),height:Math.max(r.minHeight,Math.min(r.maxHeight,n))};function a(u,h){return h===void 0&&(h=!1),u.reduce(function(f,m){return Ss({size:m,aspectRatio:o,sizeRestrictions:r,ignoreMinimum:h})&&(!f||ks(m,{width:e,height:n})<ks(f,{width:e,height:n}))?m:f},null)}var d=[];o&&[o.minimum,o.maximum].forEach(function(u){u&&d.push({width:s.width,height:s.width/u,correctRatio:!0},{width:s.height*u,height:s.height,correctRatio:!0})}),Ss({size:s,aspectRatio:o,sizeRestrictions:r})&&d.push(s);var c=a(d)||a(d,!0);return c&&{width:c.width,height:c.height}}function Fi(t){var e=t.event,n=t.coordinates,r=t.positionRestrictions,o=r===void 0?{}:r,s=pe(n,e.directions);return pe(s,Ct(s,o))}function tf(t){var e=t.coordinates,n=t.transform,r=t.imageSize,o=t.sizeRestrictions,s=t.positionRestrictions,a=t.aspectRatio,d=t.visibleArea,c=function(h,f){return Fi({coordinates:h,positionRestrictions:s,event:new Ai({left:f.left-h.left,top:f.top-h.top})})},u=A({},e);return(Array.isArray(n)?n:[n]).forEach(function(h){var f={};ne((f=typeof h=="function"?h({coordinates:u,imageSize:r,visibleArea:d}):h).width)&&ne(f.height)||(u=function(m,g){var p=A(A(A({},m),He({width:g.width,height:g.height,sizeRestrictions:o,aspectRatio:a})),{left:0,top:0});return c(p,{left:m.left,top:m.top})}(u,A(A({},u),f))),ne(f.left)&&ne(f.top)||(u=c(u,A(A({},u),f)))}),u}function nf(t){t.event;var e=t.getAreaRestrictions,n=t.boundaries,r=t.coordinates,o=t.visibleArea;t.aspectRatio;var s=t.stencilSize,a=t.sizeRestrictions,d=t.positionRestrictions;t.stencilReference;var c,u,h,f=A({},r),m=A({},o),g=A({},s);c=W(g),u=W(f),h===void 0&&(h=.001),(c===0||u===0?Math.abs(u-c)<h:Math.abs(u/c)<1+h&&Math.abs(u/c)>1-h)||(f=A(A({},f),He({sizeRestrictions:a,width:f.width,height:f.height,aspectRatio:{minimum:W(g),maximum:W(g)}})));var p=vn(m=Ee(m,f.width*n.width/(m.width*g.width)),e({visibleArea:m,type:"resize"}));return p!==1&&(m=Ee(m,p),f=Ee(f,p)),m=ae(m=pe(m,wt(se(f),se(m))),e({visibleArea:m,type:"move"})),{coordinates:f=ae(f,Mn(ze(m),d)),visibleArea:m}}function rf(t){var e=t.event,n=t.getAreaRestrictions,r=t.boundaries,o=t.coordinates,s=t.visibleArea;t.aspectRatio,t.stencilSize,t.sizeRestrictions;var a=t.positionRestrictions;t.stencilReference;var d=A({},o),c=A({},s);if(o&&s&&e.type!=="manipulateImage"){var u={width:0,height:0};c.width,r.width,W(r)>W(d)?(u.height=.8*r.height,u.width=u.height*W(d)):(u.width=.8*r.width,u.height=u.width*W(d));var h=vn(c=Ee(c,d.width*r.width/(c.width*u.width)),n({visibleArea:c,type:"resize"}));c=Ee(c,h),h!==1&&(u.height/=h,u.width/=h),c=ae(c=pe(c,wt(se(d),se(c))),n({visibleArea:c,type:"move"})),d=ae(d,Mn(ze(c),a))}return{coordinates:d,visibleArea:c}}function of(t){var e=t.event,n=t.coordinates,r=t.visibleArea,o=t.getAreaRestrictions,s=A({},r),a=A({},n);if(e.type==="setCoordinates"){var d=Math.max(0,a.width-s.width),c=Math.max(0,a.height-s.height);d>c?s=Ee(s,Math.min(a.width/s.width,bt(s,o({visibleArea:s,type:"resize"})))):c>d&&(s=Ee(s,Math.min(a.height/s.height,bt(s,o({visibleArea:s,type:"resize"}))))),s=ae(s=pe(s,En(Ct(a,ze(s)))),o({visibleArea:s,type:"move"}))}return{visibleArea:s,coordinates:a}}function sf(t){var e=t.imageSize,n=t.visibleArea,r=t.coordinates,o=n||e;return{left:(n?n.left:0)+o.width/2-r.width/2,top:(n?n.top:0)+o.height/2-r.height/2}}function af(t){var e=t.imageSize,n=t.visibleArea,r=t.aspectRatio,o=t.sizeRestrictions,s=n||e,a=Math.min(r.maximum||1/0,Math.max(r.minimum||0,W(s))),d=s.width<s.height?{width:.8*s.width,height:.8*s.width/a}:{height:.8*s.height,width:.8*s.height*a};return He(A(A({},d),{aspectRatio:r,sizeRestrictions:o}))}function lf(t){var e,n,r=t.imageSize,o=t.visibleArea,s=t.boundaries,a=t.aspectRatio,d=t.sizeRestrictions,c=t.stencilSize,u=o||r;return W(u)>W(s)?n=(e=c.height*u.height/s.height)*W(c):e=(n=c.width*u.width/s.width)/W(c),He({width:n,height:e,aspectRatio:a,sizeRestrictions:d})}function cf(t){var e=t.getAreaRestrictions,n=t.coordinates,r=t.imageSize,o=W(t.boundaries);if(n){var s={height:Math.max(n.height,r.height),width:Math.max(n.width,r.width)},a=ws({width:W(s)>o?s.width:s.height*o,height:W(s)>o?s.width/o:s.height},Vi(e())),d={left:n.left+n.width/2-a.width/2,top:n.top+n.height/2-a.height/2,width:a.width,height:a.height},c=Ot(n,ze(A({left:0,top:0},r))),u={};return!c.left&&!c.right&&d.width<=r.width&&(u.left=0,u.right=r.width),!c.top&&!c.bottom&&d.height<=r.height&&(u.top=0,u.bottom=r.height),ae(d,u)}var h=W(r);return a={height:h>o?r.height:r.width/o,width:h>o?r.height*o:r.width},{left:r.width/2-a.width/2,top:r.height/2-a.height/2,width:a.width,height:a.height}}function xn(t,e){return Cs(t,ze(e))}function df(t){var e=t.event,n=t.coordinates,r=t.visibleArea,o=t.sizeRestrictions,s=t.getAreaRestrictions,a=t.positionRestrictions,d=t.adjustStencil,c=e.scale,u=e.move,h=A({},r),f=A({},n),m=1,g=1,p=c.factor&&Math.abs(c.factor-1)>.001;h=pe(h,{left:u.left||0,top:u.top||0});var k={stencil:{minimum:Math.max(o.minWidth?o.minWidth/f.width:0,o.minHeight?o.minHeight/f.height:0),maximum:Math.min(o.maxWidth?o.maxWidth/f.width:1/0,o.maxHeight?o.maxHeight/f.height:1/0,bt(f,a))},area:{maximum:bt(h,s({visibleArea:h,type:"resize"}))}};c.factor&&p&&(c.factor<1?(g=Math.max(c.factor,k.stencil.minimum))>1&&(g=1):c.factor>1&&(g=Math.min(c.factor,Math.min(k.area.maximum,k.stencil.maximum)))<1&&(g=1)),g&&(h=Ee(h,g,c.center));var w=n.left-r.left,B=r.width+r.left-(n.width+n.left),D=n.top-r.top,L=r.height+r.top-(n.height+n.top);return h=ae(h=pe(h,Ct(h,{left:a.left!==void 0?a.left-w*g:void 0,top:a.top!==void 0?a.top-D*g:void 0,bottom:a.bottom!==void 0?a.bottom+L*g:void 0,right:a.right!==void 0?a.right+B*g:void 0})),s({visibleArea:h,type:"move"})),f.width=f.width*g,f.height=f.height*g,f.left=h.left+w*g,f.top=h.top+D*g,f=ae(f,Mn(ze(h),a)),c.factor&&p&&d&&(c.factor>1?m=Math.min(k.area.maximum,c.factor)/g:c.factor<1&&(m=Math.max(f.height/h.height,f.width/h.width,c.factor/g)),m!==1&&(h=pe(h=ae(h=Ee(h,m,c.factor>1?c.center:se(f)),s({visibleArea:h,type:"move"})),En(Ct(f,ze(h)))))),{coordinates:f,visibleArea:h}}function uf(t){var e=t.aspectRatio,n=t.getAreaRestrictions,r=t.coordinates,o=t.visibleArea,s=t.sizeRestrictions,a=t.positionRestrictions,d=t.imageSize,c=t.previousImageSize,u=t.angle,h=A({},r),f=A({},o),m=je(se(A({left:0,top:0},c)),u);return(h=A(A({},He({sizeRestrictions:s,aspectRatio:e,width:h.width,height:h.height})),je(se(h),u))).left-=m.left-d.width/2+h.width/2,h.top-=m.top-d.height/2+h.height/2,f=Ee(f,vn(f,n({visibleArea:f,type:"resize"}))),{coordinates:h=ae(h,a),visibleArea:f=ae(f=pe(f,wt(se(h),se(r))),n({visibleArea:f,type:"move"}))}}function hf(t){var e=t.flip,n=t.previousFlip,r=t.rotate,o=t.getAreaRestrictions,s=t.coordinates,a=t.visibleArea,d=t.imageSize,c=A({},s),u=A({},a),h=n.horizontal!==e.horizontal,f=n.vertical!==e.vertical;if(h||f){var m=je({left:d.width/2,top:d.height/2},-r),g=je(se(c),-r),p=je({left:h?m.left-(g.left-m.left):g.left,top:f?m.top-(g.top-m.top):g.top},r);c=pe(c,wt(p,se(c))),g=je(se(u),-r),u=ae(u=pe(u,wt(p=je({left:h?m.left-(g.left-m.left):g.left,top:f?m.top-(g.top-m.top):g.top},r),se(u))),o({visibleArea:u,type:"move"}))}return{coordinates:c,visibleArea:u}}function Es(t){var e=t.directions,n=t.coordinates,r=t.positionRestrictions,o=r===void 0?{}:r,s=t.sizeRestrictions,a=t.preserveRatio,d=t.compensate,c=A({},e),u=Ve(n,c).width,h=Ve(n,c).height;u<0&&(c.left<0&&c.right<0?(c.left=-(n.width-s.minWidth)/(c.left/c.right),c.right=-(n.width-s.minWidth)/(c.right/c.left)):c.left<0?c.left=-(n.width-s.minWidth):c.right<0&&(c.right=-(n.width-s.minWidth))),h<0&&(c.top<0&&c.bottom<0?(c.top=-(n.height-s.minHeight)/(c.top/c.bottom),c.bottom=-(n.height-s.minHeight)/(c.bottom/c.top)):c.top<0?c.top=-(n.height-s.minHeight):c.bottom<0&&(c.bottom=-(n.height-s.minHeight)));var f=Ot(Ve(n,c),o);d&&(f.left&&f.left>0&&f.right===0?(c.right+=f.left,c.left-=f.left):f.right&&f.right>0&&f.left===0&&(c.left+=f.right,c.right-=f.right),f.top&&f.top>0&&f.bottom===0?(c.bottom+=f.top,c.top-=f.top):f.bottom&&f.bottom>0&&f.top===0&&(c.top+=f.bottom,c.bottom-=f.bottom),f=Ot(Ve(n,c),o));var m={width:1/0,height:1/0,left:1/0,right:1/0,top:1/0,bottom:1/0};if(Te.forEach(function(k){var w=f[k];w&&c[k]&&(m[k]=Math.max(0,1-w/c[k]))}),a){var g=Math.min.apply(null,Te.map(function(k){return m[k]}));g!==1/0&&Te.forEach(function(k){c[k]*=g})}else Te.forEach(function(k){m[k]!==1/0&&(c[k]*=m[k])});if(u=Ve(n,c).width,h=Ve(n,c).height,c.right+c.left&&(u>s.maxWidth?m.width=(s.maxWidth-n.width)/(c.right+c.left):u<s.minWidth&&(m.width=(s.minWidth-n.width)/(c.right+c.left))),c.bottom+c.top&&(h>s.maxHeight?m.height=(s.maxHeight-n.height)/(c.bottom+c.top):h<s.minHeight&&(m.height=(s.minHeight-n.height)/(c.bottom+c.top))),a){var p=Math.min(m.width,m.height);p!==1/0&&Te.forEach(function(k){c[k]*=p})}else m.width!==1/0&&Xh.forEach(function(k){c[k]*=m.width}),m.height!==1/0&&Yh.forEach(function(k){c[k]*=m.height});return c}function Bn(t,e,n){return e==0&&n==0?t/2:e==0?0:n==0?t:t*Math.abs(e/(e+n))}var ff=Ie("vue-simple-handler"),mf=Ie("vue-simple-handler-wrapper"),Di={name:"SimpleHandler",components:{HandlerWrapper:ms},props:{defaultClass:{type:String},hoverClass:{type:String},wrapperClass:{type:String},horizontalPosition:{type:String},verticalPosition:{type:String},disabled:{type:Boolean,default:!1}},data:function(){return{hover:!1}},computed:{classes:function(){var t,e=(ke(t={},this.horizontalPosition,!!this.horizontalPosition),ke(t,this.verticalPosition,!!this.verticalPosition),ke(t,"".concat(this.horizontalPosition,"-").concat(this.verticalPosition),!!(this.verticalPosition&&this.horizontalPosition)),ke(t,"hover",this.hover),t);return{default:Q(ff(e),this.defaultClass,this.hover&&this.hoverClass),wrapper:Q(mf(e),this.wrapperClass)}}},methods:{onDrag:function(t){this.$emit("drag",t)},onEnter:function(){this.hover=!0},onLeave:function(){this.hover=!1},onDragEnd:function(){this.$emit("drag-end")}},emits:["drag","drag-end"]};Di.render=function(t,e,n,r,o,s){var a=i.resolveComponent("HandlerWrapper");return i.openBlock(),i.createBlock(a,{class:s.classes.wrapper,"vertical-position":n.verticalPosition,"horizontal-position":n.horizontalPosition,disabled:n.disabled,onDrag:s.onDrag,onDragEnd:s.onDragEnd,onEnter:s.onEnter,onLeave:s.onLeave},{default:i.withCtx(function(){return[i.createVNode("div",{class:s.classes.default},null,2)]}),_:1},8,["class","vertical-position","horizontal-position","disabled","onDrag","onDragEnd","onEnter","onLeave"])};var pf=Ie("vue-simple-line"),gf=Ie("vue-simple-line-wrapper"),Li={name:"SimpleLine",components:{LineWrapper:ps},props:{defaultClass:{type:String},hoverClass:{type:String},wrapperClass:{type:String},position:{type:String},disabled:{type:Boolean,default:!1}},data:function(){return{hover:!1}},computed:{classes:function(){return{root:Q(pf(ke({},this.position,!0)),this.defaultClass,this.hover&&this.hoverClass),wrapper:Q(gf(ke({},this.position,!0)),this.wrapperClass)}}},methods:{onDrag:function(t){this.$emit("drag",t)},onEnter:function(){this.hover=!0},onLeave:function(){this.hover=!1},onDragEnd:function(){this.$emit("drag-end")}},emits:["drag","drag-end"]};Li.render=function(t,e,n,r,o,s){var a=i.resolveComponent("LineWrapper");return i.openBlock(),i.createBlock(a,{class:s.classes.wrapper,position:n.position,disabled:n.disabled,onDrag:s.onDrag,onDragEnd:s.onDragEnd,onEnter:s.onEnter,onLeave:s.onLeave},{default:i.withCtx(function(){return[i.createVNode("div",{class:s.classes.root},null,2)]}),_:1},8,["class","position","disabled","onDrag","onDragEnd","onEnter","onLeave"])};var Oi=Ie("vue-bounding-box"),yf=["east","west",null],wf=["south","north",null],vs={name:"BoundingBox",props:{width:{type:Number},height:{type:Number},transitions:{type:Object},handlers:{type:Object,default:function(){return{eastNorth:!0,north:!0,westNorth:!0,west:!0,westSouth:!0,south:!0,eastSouth:!0,east:!0}}},handlersComponent:{type:[Object,String],default:function(){return Di}},handlersClasses:{type:Object,default:function(){return{}}},handlersWrappersClasses:{type:Object,default:function(){return{}}},lines:{type:Object,default:function(){return{west:!0,north:!0,east:!0,south:!0}}},linesComponent:{type:[Object,String],default:function(){return Li}},linesClasses:{type:Object,default:function(){return{}}},linesWrappersClasses:{type:Object,default:function(){return{}}},resizable:{type:Boolean,default:!0}},data:function(){var t=[];return yf.forEach(function(e){wf.forEach(function(n){if(e!==n){var r=ls(e,n),o=r.name,s=r.classname;t.push({name:o,classname:s,verticalDirection:n,horizontalDirection:e})}})}),{points:t}},computed:{style:function(){var t={};return this.width&&this.height&&(t.width="".concat(this.width,"px"),t.height="".concat(this.height,"px"),this.transitions&&this.transitions.enabled&&(t.transition="".concat(this.transitions.time,"ms ").concat(this.transitions.timingFunction))),t},classes:function(){var t=this.handlersClasses,e=this.handlersWrappersClasses,n=this.linesClasses,r=this.linesWrappersClasses;return{root:Oi(),handlers:t,handlersWrappers:e,lines:n,linesWrappers:r}},lineNodes:function(){var t=this,e=[];return this.points.forEach(function(n){n.horizontalDirection&&n.verticalDirection||!t.lines[n.name]||e.push({name:n.name,component:t.linesComponent,class:Q(t.classes.lines.default,t.classes.lines[n.name],!t.resizable&&t.classes.lines.disabled),wrapperClass:Q(t.classes.linesWrappers.default,t.classes.linesWrappers[n.name],!t.resizable&&t.classes.linesWrappers.disabled),hoverClass:t.classes.lines.hover,verticalDirection:n.verticalDirection,horizontalDirection:n.horizontalDirection,disabled:!t.resizable})}),e},handlerNodes:function(){var t=this,e=[],n=this.width,r=this.height;return this.points.forEach(function(o){if(t.handlers[o.name]){var s={name:o.name,component:t.handlersComponent,class:Q(t.classes.handlers.default,t.classes.handlers[o.name]),wrapperClass:Q(t.classes.handlersWrappers.default,t.classes.handlersWrappers[o.name]),hoverClass:t.classes.handlers.hover,verticalDirection:o.verticalDirection,horizontalDirection:o.horizontalDirection,disabled:!t.resizable};if(n&&r){var a=o.horizontalDirection,d=o.verticalDirection,c=a==="east"?n:a==="west"?0:n/2,u=d==="south"?r:d==="north"?0:r/2;s.wrapperClass=Oi("handler"),s.wrapperStyle={transform:"translate(".concat(c,"px, ").concat(u,"px)")},t.transitions&&t.transitions.enabled&&(s.wrapperStyle.transition="".concat(t.transitions.time,"ms ").concat(t.transitions.timingFunction))}else s.wrapperClass=Oi("handler",ke({},o.classname,!0));e.push(s)}}),e}},beforeMount:function(){window.addEventListener("mouseup",this.onMouseUp,{passive:!1}),window.addEventListener("mousemove",this.onMouseMove,{passive:!1}),window.addEventListener("touchmove",this.onTouchMove,{passive:!1}),window.addEventListener("touchend",this.onTouchEnd,{passive:!1})},beforeUnmount:function(){window.removeEventListener("mouseup",this.onMouseUp),window.removeEventListener("mousemove",this.onMouseMove),window.removeEventListener("touchmove",this.onTouchMove),window.removeEventListener("touchend",this.onTouchEnd)},mounted:function(){this.touches=[]},methods:{onEnd:function(){this.$emit("resize-end")},onHandlerDrag:function(t,e,n){var r,o=t.shift(),s=o.left,a=o.top,d={left:0,right:0,top:0,bottom:0};e==="west"?d.left-=s:e==="east"&&(d.right+=s),n==="north"?d.top-=a:n==="south"&&(d.bottom+=a),!n&&e?r="width":n&&!e&&(r="height"),this.resizable&&this.$emit("resize",new jh(d,{allowedDirections:{left:e==="west"||!e,right:e==="east"||!e,bottom:n==="south"||!n,top:n==="north"||!n},preserveAspectRatio:t.nativeEvent&&t.nativeEvent.shiftKey,respectDirection:r}))}},emits:["resize","resize-end"]};vs.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"box",class:s.classes.root,style:s.style},[i.renderSlot(t.$slots,"default"),i.createVNode("div",null,[(i.openBlock(!0),i.createBlock(i.Fragment,null,i.renderList(s.lineNodes,function(a){return i.openBlock(),i.createBlock(i.resolveDynamicComponent(a.component),{key:a.name,"default-class":a.class,"hover-class":a.hoverClass,"wrapper-class":a.wrapperClass,position:a.name,disabled:a.disabled,onDrag:function(d){return s.onHandlerDrag(d,a.horizontalDirection,a.verticalDirection)},onDragEnd:e[1]||(e[1]=function(d){return s.onEnd()})},null,8,["default-class","hover-class","wrapper-class","position","disabled","onDrag"])}),128))]),(i.openBlock(!0),i.createBlock(i.Fragment,null,i.renderList(s.handlerNodes,function(a){return i.openBlock(),i.createBlock("div",{key:a.name,style:a.wrapperStyle,class:a.wrapperClass},[(i.openBlock(),i.createBlock(i.resolveDynamicComponent(a.component),{"default-class":a.class,"hover-class":a.hoverClass,"wrapper-class":a.wrapperClass,"horizontal-position":a.horizontalDirection,"vertical-position":a.verticalDirection,disabled:a.disabled,onDrag:function(d){return s.onHandlerDrag(d,a.horizontalDirection,a.verticalDirection)},onDragEnd:e[2]||(e[2]=function(d){return s.onEnd()})},null,8,["default-class","hover-class","wrapper-class","horizontal-position","vertical-position","disabled","onDrag"]))],6)}),128))],6)};var bf=Ie("vue-draggable-area"),Ms={name:"DraggableArea",props:{movable:{type:Boolean,default:!0},activationDistance:{type:Number,default:20}},computed:{classnames:function(){return{default:bf()}}},beforeMount:function(){window.addEventListener("mouseup",this.onMouseUp,{passive:!1}),window.addEventListener("mousemove",this.onMouseMove,{passive:!1}),window.addEventListener("touchmove",this.onTouchMove,{passive:!1}),window.addEventListener("touchend",this.onTouchEnd,{passive:!1})},beforeUnmount:function(){window.removeEventListener("mouseup",this.onMouseUp),window.removeEventListener("mousemove",this.onMouseMove),window.removeEventListener("touchmove",this.onTouchMove),window.removeEventListener("touchend",this.onTouchEnd)},mounted:function(){this.touches=[],this.touchStarted=!1},methods:{onTouchStart:function(t){if(t.cancelable){var e=this.movable&&t.touches.length===1;e&&(this.touches=ot(t.touches)),(this.touchStarted||e)&&(t.preventDefault(),t.stopPropagation())}},onTouchEnd:function(){this.touchStarted=!1,this.processEnd()},onTouchMove:function(t){this.touches.length>=1&&(this.touchStarted?(this.processMove(t,t.touches),t.preventDefault(),t.stopPropagation()):fs({x:this.touches[0].clientX,y:this.touches[0].clientY},{x:t.touches[0].clientX,y:t.touches[0].clientY})>this.activationDistance&&(this.initAnchor({clientX:t.touches[0].clientX,clientY:t.touches[0].clientY}),this.touchStarted=!0))},onMouseDown:function(t){if(this.movable&&t.button===0){var e={fake:!0,clientX:t.clientX,clientY:t.clientY};this.touches=[e],this.initAnchor(e),t.stopPropagation()}},onMouseMove:function(t){this.touches.length&&(this.processMove(t,[{fake:!0,clientX:t.clientX,clientY:t.clientY}]),t.preventDefault&&t.cancelable&&t.preventDefault(),t.stopPropagation())},onMouseUp:function(){this.processEnd()},initAnchor:function(t){var e=this.$refs.container.getBoundingClientRect(),n=e.left,r=e.top;this.anchor={x:t.clientX-n,y:t.clientY-r}},processMove:function(t,e){var n=ot(e);if(this.touches.length){var r=this.$refs.container.getBoundingClientRect(),o=r.left,s=r.top;this.touches.length===1&&n.length===1&&this.$emit("move",new Ai({left:n[0].clientX-(o+this.anchor.x),top:n[0].clientY-(s+this.anchor.y)}))}},processEnd:function(){this.touches.length&&this.$emit("move-end"),this.touches=[]}},emits:["move","move-end"]};Ms.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"container",onTouchstart:e[1]||(e[1]=function(){return s.onTouchStart&&s.onTouchStart.apply(s,arguments)}),onMousedown:e[2]||(e[2]=function(){return s.onMouseDown&&s.onMouseDown.apply(s,arguments)})},[i.renderSlot(t.$slots,"default")],544)};function Hi(t){var e,n;return{rotate:t.rotate||0,flip:{horizontal:((e=t==null?void 0:t.flip)===null||e===void 0?void 0:e.horizontal)||!1,vertical:((n=t==null?void 0:t.flip)===null||n===void 0?void 0:n.vertical)||!1}}}function Cf(t){return new Promise(function(e,n){try{if(t)if(/^data:/i.test(t))e(function(c){c=c.replace(/^data:([^;]+);base64,/gim,"");for(var u=atob(c),h=u.length,f=new ArrayBuffer(h),m=new Uint8Array(f),g=0;g<h;g++)m[g]=u.charCodeAt(g);return f}(t));else if(/^blob:/i.test(t)){var r=new FileReader;r.onload=function(c){e(c.target.result)},s=t,a=function(c){r.readAsArrayBuffer(c)},(d=new XMLHttpRequest).open("GET",s,!0),d.responseType="blob",d.onload=function(){this.status!=200&&this.status!==0||a(this.response)},d.send()}else{var o=new XMLHttpRequest;o.onreadystatechange=function(){o.readyState===4&&(o.status===200||o.status===0?e(o.response):n("Warning: could not load an image to parse its orientation"),o=null)},o.onprogress=function(){o.getResponseHeader("content-type")!=="image/jpeg"&&o.abort()},o.withCredentials=!1,o.open("GET",t,!0),o.responseType="arraybuffer",o.send(null)}else n("Error: the image is empty")}catch(c){n(c)}var s,a,d})}function xs(t){var e=t.rotate,n=t.flip,r=t.scaleX,o=t.scaleY,s="";return s+=" rotate("+e+"deg) ",s+=" scaleX("+r*(n.horizontal?-1:1)+") ",s+=" scaleY("+o*(n.vertical?-1:1)+") "}function Sf(t){try{var e,n=new DataView(t),r=void 0,o=void 0,s=void 0,a=void 0;if(n.getUint8(0)===255&&n.getUint8(1)===216)for(var d=n.byteLength,c=2;c+1<d;){if(n.getUint8(c)===255&&n.getUint8(c+1)===225){s=c;break}c++}if(s&&(r=s+10,function(g,p,k){var w,B="";for(w=p,k+=p;w<k;w++)B+=String.fromCharCode(g.getUint8(w));return B}(n,s+4,4)==="Exif")){var u=n.getUint16(r);if(((o=u===18761)||u===19789)&&n.getUint16(r+2,o)===42){var h=n.getUint32(r+4,o);h>=8&&(a=r+h)}}if(a){for(var f=n.getUint16(a,o),m=0;m<f;m++)if(c=a+12*m+2,n.getUint16(c,o)===274){c+=8,e=n.getUint16(c,o),n.setUint16(c,1,o);break}}return e}catch{return null}}function Bs(t,e){var n=e.getBoundingClientRect(),r=n.left,o=n.top,s={left:0,top:0},a=0;return t.forEach(function(d){s.left+=(d.clientX-r)/t.length,s.top+=(d.clientY-o)/t.length}),t.forEach(function(d){a+=fs({x:s.left,y:s.top},{x:d.clientX-r,y:d.clientY-o})}),{centerMass:s,spread:a,count:t.length}}var Is={props:{touchMove:{type:Boolean,required:!0},mouseMove:{type:Boolean,required:!0},touchResize:{type:Boolean,required:!0},wheelResize:{type:[Boolean,Object],required:!0},eventsFilter:{type:Function,required:!1}},beforeMount:function(){window.addEventListener("mouseup",this.onMouseUp,{passive:!1}),window.addEventListener("mousemove",this.onMouseMove,{passive:!1}),window.addEventListener("touchmove",this.onTouchMove,{passive:!1}),window.addEventListener("touchend",this.onTouchEnd,{passive:!1})},beforeUnmount:function(){window.removeEventListener("mouseup",this.onMouseUp),window.removeEventListener("mousemove",this.onMouseMove),window.removeEventListener("touchmove",this.onTouchMove),window.removeEventListener("touchend",this.onTouchEnd)},created:function(){this.transforming=!1,this.debouncedProcessEnd=$i(this.processEnd),this.touches=[]},methods:{processMove:function(t,e){if(this.touches.length){if(this.touches.length===1&&e.length===1)this.$emit("move",new Lt({left:this.touches[0].clientX-e[0].clientX,top:this.touches[0].clientY-e[0].clientY}));else if(this.touches.length>1&&this.touchResize){var n=Bs(e,this.$refs.container),r=this.oldGeometricProperties;r.count===n.count&&r.count>1&&this.$emit("resize",new Lt({left:r.centerMass.left-n.centerMass.left,top:r.centerMass.top-n.centerMass.top},{factor:r.spread/n.spread,center:n.centerMass})),this.oldGeometricProperties=n}this.touches=e}},processEnd:function(){this.transforming&&(this.transforming=!1,this.$emit("transform-end"))},processStart:function(){this.transforming=!0,this.debouncedProcessEnd.clear()},processEvent:function(t){return this.eventsFilter?this.eventsFilter(t,this.transforming)!==!1:(t.preventDefault(),t.stopPropagation(),!0)},onTouchStart:function(t){if(t.cancelable&&(this.touchMove||this.touchResize&&t.touches.length>1)&&this.processEvent(t)){var e=this.$refs.container,n=e.getBoundingClientRect(),r=n.left,o=n.top,s=n.bottom,a=n.right;this.touches=ot(t.touches).filter(function(d){return d.clientX>r&&d.clientX<a&&d.clientY>o&&d.clientY<s}),this.oldGeometricProperties=Bs(this.touches,e)}},onTouchEnd:function(t){t.touches.length===0&&(this.touches=[],this.processEnd())},onTouchMove:function(t){var e=this;if(this.touches.length){var n=ot(t.touches).filter(function(r){return!r.identifier||e.touches.find(function(o){return o.identifier===r.identifier})});this.processEvent(t)&&(this.processMove(t,n),this.processStart())}},onMouseDown:function(t){if(this.mouseMove&&"buttons"in t&&t.buttons===1&&this.processEvent(t)){var e={fake:!0,clientX:t.clientX,clientY:t.clientY};this.touches=[e],this.processStart()}},onMouseMove:function(t){this.touches.length&&this.processEvent(t)&&this.processMove(t,[{clientX:t.clientX,clientY:t.clientY}])},onMouseUp:function(){this.touches=[],this.processEnd()},onWheel:function(t){if(this.wheelResize&&this.processEvent(t)){var e=this.$refs.container.getBoundingClientRect(),n=e.left,r=e.top,o=1+this.wheelResize.ratio*(a=t.deltaY||t.detail||t.wheelDelta,(d=+a)==0||hs(d)?d:d>0?1:-1),s={left:t.clientX-n,top:t.clientY-r};this.$emit("resize",new Lt({},{factor:o,center:s})),this.touches.length||this.debouncedProcessEnd()}var a,d}},emits:["resize","move","transform-end"]};Is.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"container",onTouchstart:e[1]||(e[1]=function(){return s.onTouchStart&&s.onTouchStart.apply(s,arguments)}),onMousedown:e[2]||(e[2]=function(){return s.onMouseDown&&s.onMouseDown.apply(s,arguments)}),onWheel:e[3]||(e[3]=function(){return s.onWheel&&s.onWheel.apply(s,arguments)})},[i.renderSlot(t.$slots,"default")],544)};var _i={components:{TransformableImage:Is},props:{touchMove:{type:Boolean,required:!0},mouseMove:{type:Boolean,required:!0},touchResize:{type:Boolean,required:!0},wheelResize:{type:[Boolean,Object],required:!0}},emits:["resize","move"]};_i.render=function(t,e,n,r,o,s){var a=i.resolveComponent("transformable-image");return i.openBlock(),i.createBlock(a,{"touch-move":n.touchMove,"touch-resize":n.touchResize,"mouse-move":n.mouseMove,"wheel-resize":n.wheelResize,onMove:e[1]||(e[1]=function(d){return t.$emit("move",d)}),onResize:e[2]||(e[2]=function(d){return t.$emit("resize",d)})},{default:i.withCtx(function(){return[i.renderSlot(t.$slots,"default")]}),_:3},8,["touch-move","touch-resize","mouse-move","wheel-resize"])};var In=Ie("vue-preview"),Rs={props:{coordinates:{type:Object},transitions:{type:Object},image:{type:Object,default:function(){return{}}},imageClass:{type:String},width:{type:Number},height:{type:Number},fill:{type:Boolean}},data:function(){return{calculatedImageSize:{width:0,height:0},calculatedSize:{width:0,height:0}}},computed:{classes:function(){return{root:In({fill:this.fill}),wrapper:In("wrapper"),imageWrapper:In("image-wrapper"),image:Q(In("image"),this.imageClass)}},style:function(){if(this.fill)return{};var t={};return this.width&&(t.width="".concat(this.size.width,"px")),this.height&&(t.height="".concat(this.size.height,"px")),this.transitions&&this.transitions.enabled&&(t.transition="".concat(this.transitions.time,"ms ").concat(this.transitions.timingFunction)),t},wrapperStyle:function(){var t={width:"".concat(this.size.width,"px"),height:"".concat(this.size.height,"px"),left:"calc(50% - ".concat(this.size.width/2,"px)"),top:"calc(50% - ".concat(this.size.height/2,"px)")};return this.transitions&&this.transitions.enabled&&(t.transition="".concat(this.transitions.time,"ms ").concat(this.transitions.timingFunction)),t},imageStyle:function(){if(this.coordinates&&this.image){var t=this.coordinates.width/this.size.width,e=U(U({rotate:0,flip:{horizontal:!1,vertical:!1}},this.image.transforms),{},{scaleX:1/t,scaleY:1/t}),n=this.imageSize.width,r=this.imageSize.height,o=bs({width:n,height:r},e.rotate),s={width:"".concat(n,"px"),height:"".concat(r,"px"),left:"0px",top:"0px"},a={rotate:{left:(n-o.width)*e.scaleX/2,top:(r-o.height)*e.scaleY/2},scale:{left:(1-e.scaleX)*n/2,top:(1-e.scaleY)*r/2}};return s.transform=`translate(
42
+ `.concat(-this.coordinates.left/t-a.rotate.left-a.scale.left,"px,").concat(-this.coordinates.top/t-a.rotate.top-a.scale.top,"px) ")+xs(e),this.transitions&&this.transitions.enabled&&(s.transition="".concat(this.transitions.time,"ms ").concat(this.transitions.timingFunction)),s}return{}},size:function(){return{width:this.width||this.calculatedSize.width,height:this.height||this.calculatedSize.height}},imageSize:function(){return{width:this.image.width||this.calculatedImageSize.width,height:this.image.height||this.calculatedImageSize.height}}},watch:{image:function(t){(t.width||t.height)&&this.onChangeImage()}},mounted:function(){var t=this;this.onChangeImage(),this.$refs.image.addEventListener("load",function(){t.refreshImage()}),window.addEventListener("resize",this.refresh),window.addEventListener("orientationchange",this.refresh)},unmounted:function(){window.removeEventListener("resize",this.refresh),window.removeEventListener("orientationchange",this.refresh)},methods:{refreshImage:function(){var t=this.$refs.image;this.calculatedImageSize.height=t.naturalHeight,this.calculatedImageSize.width=t.naturalWidth},refresh:function(){var t=this.$refs.root;this.width||(this.calculatedSize.width=t.clientWidth),this.height||(this.calculatedSize.height=t.clientHeight)},onChangeImage:function(){var t=this.$refs.image;t&&t.complete&&this.refreshImage(),this.refresh()}}};Rs.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"root",class:s.classes.root,style:s.style},[i.createVNode("div",{ref:"wrapper",class:s.classes.wrapper,style:s.wrapperStyle},[i.withDirectives(i.createVNode("img",{ref:"image",src:n.image&&n.image.src,class:s.classes.image,style:s.imageStyle},null,14,["src"]),[[i.vShow,n.image&&n.image.src]])],6)],6)};var $s={components:{Preview:Rs},inheritAttrs:!1};$s.render=function(t,e,n,r,o,s){var a=i.resolveComponent("preview");return i.openBlock(),i.createBlock(a,i.mergeProps(t.$attrs,{fill:!0}),null,16)};var qi=Ie("vue-rectangle-stencil"),Ns={name:"RectangleStencil",components:{StencilPreview:$s,BoundingBox:vs,DraggableArea:Ms},props:{image:{type:Object},coordinates:{type:Object},stencilCoordinates:{type:Object},handlers:{type:Object},handlersComponent:{type:[Object,String],default:function(){return Di}},lines:{type:Object},linesComponent:{type:[Object,String],default:function(){return Li}},aspectRatio:{type:[Number,String]},minAspectRatio:{type:[Number,String]},maxAspectRatio:{type:[Number,String]},movable:{type:Boolean,default:!0},resizable:{type:Boolean,default:!0},transitions:{type:Object},movingClass:{type:String},resizingClass:{type:String},previewClass:{type:String},boundingBoxClass:{type:String},linesClasses:{type:Object,default:function(){return{}}},linesWrappersClasses:{type:Object,default:function(){return{}}},handlersClasses:{type:Object,default:function(){return{}}},handlersWrappersClasses:{type:Object,default:function(){return{}}}},data:function(){return{moving:!1,resizing:!1}},computed:{classes:function(){return{stencil:Q(qi({movable:this.movable,moving:this.moving,resizing:this.resizing}),this.moving&&this.movingClass,this.resizing&&this.resizingClass),preview:Q(qi("preview"),this.previewClass),boundingBox:Q(qi("bounding-box"),this.boundingBoxClass)}},style:function(){var t=this.stencilCoordinates,e=t.height,n=t.width,r=t.left,o=t.top,s={width:"".concat(n,"px"),height:"".concat(e,"px"),transform:"translate(".concat(r,"px, ").concat(o,"px)")};return this.transitions&&this.transitions.enabled&&(s.transition="".concat(this.transitions.time,"ms ").concat(this.transitions.timingFunction)),s}},methods:{onMove:function(t){this.$emit("move",t),this.moving=!0},onMoveEnd:function(){this.$emit("move-end"),this.moving=!1},onResize:function(t){this.$emit("resize",t),this.resizing=!0},onResizeEnd:function(){this.$emit("resize-end"),this.resizing=!1},aspectRatios:function(){return{minimum:this.aspectRatio||this.minAspectRatio,maximum:this.aspectRatio||this.maxAspectRatio}}},emits:["resize","resize-end","move","move-end"]};Ns.render=function(t,e,n,r,o,s){var a=i.resolveComponent("stencil-preview"),d=i.resolveComponent("draggable-area"),c=i.resolveComponent("bounding-box");return i.openBlock(),i.createBlock("div",{class:s.classes.stencil,style:s.style},[i.createVNode(c,{width:n.stencilCoordinates.width,height:n.stencilCoordinates.height,transitions:n.transitions,class:s.classes.boundingBox,handlers:n.handlers,"handlers-component":n.handlersComponent,"handlers-classes":n.handlersClasses,"handlers-wrappers-classes":n.handlersWrappersClasses,lines:n.lines,"lines-component":n.linesComponent,"lines-classes":n.linesClasses,"lines-wrappers-classes":n.linesWrappersClasses,resizable:n.resizable,onResize:s.onResize,onResizeEnd:s.onResizeEnd},{default:i.withCtx(function(){return[i.createVNode(d,{movable:n.movable,onMove:s.onMove,onMoveEnd:s.onMoveEnd},{default:i.withCtx(function(){return[i.createVNode(a,{image:n.image,coordinates:n.coordinates,width:n.stencilCoordinates.width,height:n.stencilCoordinates.height,class:s.classes.preview,transitions:n.transitions},null,8,["image","coordinates","width","height","class","transitions"])]}),_:1},8,["movable","onMove","onMoveEnd"])]}),_:1},8,["width","height","transitions","class","handlers","handlers-component","handlers-classes","handlers-wrappers-classes","lines","lines-component","lines-classes","lines-wrappers-classes","resizable","onResize","onResizeEnd"])],6)};var kf=["transitions"],_e=Ie("vue-advanced-cropper"),As={name:"Cropper",components:{BackgroundWrapper:_i},props:{src:{type:String,default:null},stencilComponent:{type:[Object,String],default:function(){return Ns}},backgroundWrapperComponent:{type:[Object,String],default:function(){return _i}},stencilProps:{type:Object,default:function(){return{}}},autoZoom:{type:Boolean,default:!1},imageClass:{type:String},boundariesClass:{type:String},backgroundClass:{type:String},foregroundClass:{type:String},minWidth:{type:[Number,String]},minHeight:{type:[Number,String]},maxWidth:{type:[Number,String]},maxHeight:{type:[Number,String]},debounce:{type:[Boolean,Number],default:500},transitions:{type:Boolean,default:!0},checkOrientation:{type:Boolean,default:!0},canvas:{type:[Object,Boolean],default:!0},crossOrigin:{type:[Boolean,String],default:void 0},transitionTime:{type:Number,default:300},imageRestriction:{type:String,default:"fit-area",validator:function(t){return Kh.indexOf(t)!==-1}},roundResult:{type:Boolean,default:!0},defaultSize:{type:[Function,Object]},defaultPosition:{type:[Function,Object]},defaultVisibleArea:{type:[Function,Object]},defaultTransforms:{type:[Function,Object]},defaultBoundaries:{type:[Function,String],validator:function(t){return!(typeof t=="string"&&t!=="fill"&&t!=="fit")}},priority:{type:String,default:"coordinates"},stencilSize:{type:[Object,Function]},resizeImage:{type:[Boolean,Object],default:!0},moveImage:{type:[Boolean,Object],default:!0},autoZoomAlgorithm:{type:Function},resizeAlgorithm:{type:Function,default:function(t){var e=t.event,n=t.coordinates,r=t.aspectRatio,o=t.positionRestrictions,s=t.sizeRestrictions,a=A(A({},n),{right:n.left+n.width,bottom:n.top+n.height}),d=e.params||{},c=A({},e.directions),u=d.allowedDirections||{left:!0,right:!0,bottom:!0,top:!0};s.widthFrozen&&(c.left=0,c.right=0),s.heightFrozen&&(c.top=0,c.bottom=0),Te.forEach(function(V){u[V]||(c[V]=0)});var h=Ve(a,c=Es({coordinates:a,directions:c,sizeRestrictions:s,positionRestrictions:o})).width,f=Ve(a,c).height,m=d.preserveRatio?W(a):zi(h/f,r);if(m){var g=d.respectDirection;if(g||(g=a.width>=a.height||m===1?"width":"height"),g==="width"){var p=h/m-a.height;if(u.top&&u.bottom){var k=c.top,w=c.bottom;c.bottom=Bn(p,w,k),c.top=Bn(p,k,w)}else u.bottom?c.bottom=p:u.top?c.top=p:u.right?c.right=0:u.left&&(c.left=0)}else if(g==="height"){var B=a.width-f*m;if(u.left&&u.right){var D=c.left,L=c.right;c.left=-Bn(B,D,L),c.right=-Bn(B,L,D)}else u.left?c.left=-B:u.right?c.right=-B:u.top?c.top=0:u.bottom&&(c.bottom=0)}c=Es({directions:c,coordinates:a,sizeRestrictions:s,positionRestrictions:o,preserveRatio:!0,compensate:d.compensate})}return h=Ve(a,c).width,f=Ve(a,c).height,(m=d.preserveRatio?W(a):zi(h/f,r))&&Math.abs(m-h/f)>.001&&Te.forEach(function(V){u[V]||(c[V]=0)}),Fi({event:new Ai({left:-c.left,top:-c.top}),coordinates:{width:n.width+c.right+c.left,height:n.height+c.top+c.bottom,left:n.left,top:n.top},positionRestrictions:o})}},moveAlgorithm:{type:Function,default:Fi},initStretcher:{type:Function,default:function(t){var e=t.stretcher,n=t.imageSize,r=W(n);e.style.width=n.width+"px",e.style.height=e.clientWidth/r+"px",e.style.width=e.clientWidth+"px"}},fitCoordinates:{type:Function,default:function(t){var e=t.visibleArea,n=t.coordinates,r=t.aspectRatio,o=t.sizeRestrictions,s=t.positionRestrictions,a=A(A({},n),He({width:n.width,height:n.height,aspectRatio:r,sizeRestrictions:{maxWidth:e.width,maxHeight:e.height,minHeight:Math.min(e.height,o.minHeight),minWidth:Math.min(e.width,o.minWidth)}}));return a=ae(a=pe(a,wt(se(n),se(a))),Mn(ze(e),s))}},fitVisibleArea:{type:Function,default:function(t){var e=t.visibleArea,n=t.boundaries,r=t.getAreaRestrictions,o=t.coordinates,s=A({},e);s.height=s.width/W(n),s.top+=(e.height-s.height)/2,(o.height-s.height>0||o.width-s.width>0)&&(s=Ee(s,Math.max(o.height/s.height,o.width/s.width)));var a=En(Ct(o,ze(s=Ee(s,vn(s,r({visibleArea:s,type:"resize"}))))));return s.width<o.width&&(a.left=0),s.height<o.height&&(a.top=0),s=ae(s=pe(s,a),r({visibleArea:s,type:"move"}))}},areaRestrictionsAlgorithm:{type:Function,default:function(t){var e=t.visibleArea,n=t.boundaries,r=t.imageSize,o=t.imageRestriction,s=t.type,a={};return o==="fill-area"?a={left:0,top:0,right:r.width,bottom:r.height}:o==="fit-area"&&(W(n)>W(r)?(a={top:0,bottom:r.height},e&&s==="move"&&(e.width>r.width?(a.left=-(e.width-r.width)/2,a.right=r.width-a.left):(a.left=0,a.right=r.width))):(a={left:0,right:r.width},e&&s==="move"&&(e.height>r.height?(a.top=-(e.height-r.height)/2,a.bottom=r.height-a.top):(a.top=0,a.bottom=r.height)))),a}},sizeRestrictionsAlgorithm:{type:Function,default:function(t){return{minWidth:t.minWidth,minHeight:t.minHeight,maxWidth:t.maxWidth,maxHeight:t.maxHeight}}},positionRestrictionsAlgorithm:{type:Function,default:function(t){var e=t.imageSize,n={};return t.imageRestriction!=="none"&&(n={left:0,top:0,right:e.width,bottom:e.height}),n}}},data:function(){return{transitionsActive:!1,imageLoaded:!1,imageAttributes:{width:null,height:null,crossOrigin:null,src:null},defaultImageTransforms:{rotate:0,flip:{horizontal:!1,vertical:!1}},appliedImageTransforms:{rotate:0,flip:{horizontal:!1,vertical:!1}},boundaries:{width:0,height:0},visibleArea:null,coordinates:U({},gs)}},computed:{image:function(){return{src:this.imageAttributes.src,width:this.imageAttributes.width,height:this.imageAttributes.height,transforms:this.imageTransforms}},imageTransforms:function(){return{rotate:this.appliedImageTransforms.rotate,flip:{horizontal:this.appliedImageTransforms.flip.horizontal,vertical:this.appliedImageTransforms.flip.vertical},translateX:this.visibleArea?this.visibleArea.left/this.coefficient:0,translateY:this.visibleArea?this.visibleArea.top/this.coefficient:0,scaleX:1/this.coefficient,scaleY:1/this.coefficient}},imageSize:function(){var t=function(e){return e*Math.PI/180}(this.imageTransforms.rotate);return{width:Math.abs(this.imageAttributes.width*Math.cos(t))+Math.abs(this.imageAttributes.height*Math.sin(t)),height:Math.abs(this.imageAttributes.width*Math.sin(t))+Math.abs(this.imageAttributes.height*Math.cos(t))}},initialized:function(){return!!(this.visibleArea&&this.imageLoaded)},settings:function(){var t=Ni(this.resizeImage,{touch:!0,wheel:{ratio:.1},adjustStencil:!0},{touch:!1,wheel:!1,adjustStencil:!1});return{moveImage:Ni(this.moveImage,{touch:!0,mouse:!0},{touch:!1,mouse:!1}),resizeImage:t}},coefficient:function(){return this.visibleArea?this.visibleArea.width/this.boundaries.width:0},areaRestrictions:function(){return this.imageLoaded?this.areaRestrictionsAlgorithm({imageSize:this.imageSize,imageRestriction:this.imageRestriction,boundaries:this.boundaries}):{}},transitionsOptions:function(){return{enabled:this.transitionsActive,timingFunction:"ease-in-out",time:350}},sizeRestrictions:function(){if(this.boundaries.width&&this.boundaries.height&&this.imageSize.width&&this.imageSize.height){var t=this.sizeRestrictionsAlgorithm({imageSize:this.imageSize,minWidth:ne(this.minWidth)?0:kn(this.minWidth),minHeight:ne(this.minHeight)?0:kn(this.minHeight),maxWidth:ne(this.maxWidth)?1/0:kn(this.maxWidth),maxHeight:ne(this.maxHeight)?1/0:kn(this.maxHeight)});if(t=function(r){var o=r.areaRestrictions,s=r.sizeRestrictions,a=r.boundaries,d=r.positionRestrictions,c=A(A({},s),{minWidth:s.minWidth!==void 0?s.minWidth:0,minHeight:s.minHeight!==void 0?s.minHeight:0,maxWidth:s.maxWidth!==void 0?s.maxWidth:1/0,maxHeight:s.maxHeight!==void 0?s.maxHeight:1/0});d.left!==void 0&&d.right!==void 0&&(c.maxWidth=Math.min(c.maxWidth,d.right-d.left)),d.bottom!==void 0&&d.top!==void 0&&(c.maxHeight=Math.min(c.maxHeight,d.bottom-d.top));var u=Vi(o),h=ws(a,u);return u.width<1/0&&(!c.maxWidth||c.maxWidth>h.width)&&(c.maxWidth=Math.min(c.maxWidth,h.width)),u.height<1/0&&(!c.maxHeight||c.maxHeight>h.height)&&(c.maxHeight=Math.min(c.maxHeight,h.height)),c.minWidth>c.maxWidth&&(c.minWidth=c.maxWidth,c.widthFrozen=!0),c.minHeight>c.maxHeight&&(c.minHeight=c.maxHeight,c.heightFrozen=!0),c}({sizeRestrictions:t,areaRestrictions:this.getAreaRestrictions({visibleArea:this.visibleArea,type:"resize"}),imageSize:this.imageSize,boundaries:this.boundaries,positionRestrictions:this.positionRestrictions,imageRestriction:this.imageRestriction,visibleArea:this.visibleArea,stencilSize:this.getStencilSize()}),this.visibleArea&&this.stencilSize){var e=this.getStencilSize(),n=Vi(this.getAreaRestrictions({visibleArea:this.visibleArea,type:"resize"}));t.maxWidth=Math.min(t.maxWidth,n.width*e.width/this.boundaries.width),t.maxHeight=Math.min(t.maxHeight,n.height*e.height/this.boundaries.height),t.maxWidth<t.minWidth&&(t.minWidth=t.maxWidth),t.maxHeight<t.minHeight&&(t.minHeight=t.maxHeight)}return t}return{minWidth:0,minHeight:0,maxWidth:0,maxHeight:0}},positionRestrictions:function(){return this.positionRestrictionsAlgorithm({imageSize:this.imageSize,imageRestriction:this.imageRestriction})},classes:function(){return{cropper:_e(),image:Q(_e("image"),this.imageClass),stencil:_e("stencil"),boundaries:Q(_e("boundaries"),this.boundariesClass),stretcher:Q(_e("stretcher")),background:Q(_e("background"),this.backgroundClass),foreground:Q(_e("foreground"),this.foregroundClass),imageWrapper:Q(_e("image-wrapper")),cropperWrapper:Q(_e("cropper-wrapper"))}},stencilCoordinates:function(){if(this.initialized){var t=this.coordinates,e=t.width,n=t.height,r=t.left,o=t.top;return{width:e/this.coefficient,height:n/this.coefficient,left:(r-this.visibleArea.left)/this.coefficient,top:(o-this.visibleArea.top)/this.coefficient}}return this.defaultCoordinates()},boundariesStyle:function(){var t={width:this.boundaries.width?"".concat(Math.round(this.boundaries.width),"px"):"auto",height:this.boundaries.height?"".concat(Math.round(this.boundaries.height),"px"):"auto",transition:"opacity ".concat(this.transitionTime,"ms"),pointerEvents:this.imageLoaded?"all":"none"};return this.imageLoaded||(t.opacity="0"),t},imageStyle:function(){var t=this.imageAttributes.width>this.imageAttributes.height?{width:Math.min(1024,this.imageAttributes.width),height:Math.min(1024,this.imageAttributes.width)/(this.imageAttributes.width/this.imageAttributes.height)}:{height:Math.min(1024,this.imageAttributes.height),width:Math.min(1024,this.imageAttributes.height)*(this.imageAttributes.width/this.imageAttributes.height)},e={left:(t.width-this.imageSize.width)/(2*this.coefficient),top:(t.height-this.imageSize.height)/(2*this.coefficient)},n={left:(1-1/this.coefficient)*t.width/2,top:(1-1/this.coefficient)*t.height/2},r=U(U({},this.imageTransforms),{},{scaleX:this.imageTransforms.scaleX*(this.imageAttributes.width/t.width),scaleY:this.imageTransforms.scaleY*(this.imageAttributes.height/t.height)}),o={width:"".concat(t.width,"px"),height:"".concat(t.height,"px"),left:"0px",top:"0px",transform:"translate(".concat(-e.left-n.left-this.imageTransforms.translateX,"px, ").concat(-e.top-n.top-this.imageTransforms.translateY,"px)")+xs(r)};return this.transitionsOptions.enabled&&(o.transition="".concat(this.transitionsOptions.time,"ms ").concat(this.transitionsOptions.timingFunction)),o}},watch:{src:function(){this.onChangeImage()},stencilComponent:function(){var t=this;this.$nextTick(function(){t.resetCoordinates(),t.runAutoZoom("setCoordinates"),t.onChange()})},minWidth:function(){this.onPropsChange()},maxWidth:function(){this.onPropsChange()},minHeight:function(){this.onPropsChange()},maxHeight:function(){this.onPropsChange()},imageRestriction:function(){this.reset()},stencilProps:function(t,e){["aspectRatio","minAspectRatio","maxAspectRatio"].find(function(n){return t[n]!==e[n]})&&this.$nextTick(this.onPropsChange)}},created:function(){this.debouncedUpdate=$i(this.update,this.debounce),this.debouncedDisableTransitions=$i(this.disableTransitions,this.transitionsOptions.time),this.awaiting=!1},mounted:function(){this.$refs.image.addEventListener("load",this.onSuccessLoadImage),this.$refs.image.addEventListener("error",this.onFailLoadImage),this.onChangeImage(),window.addEventListener("resize",this.refresh),window.addEventListener("orientationchange",this.refresh)},unmounted:function(){window.removeEventListener("resize",this.refresh),window.removeEventListener("orientationchange",this.refresh),this.imageAttributes.revoke&&this.imageAttributes.src&&URL.revokeObjectURL(this.imageAttributes.src),this.debouncedUpdate.clear(),this.debouncedDisableTransitions.clear()},methods:{getResult:function(){var t=this.initialized?this.prepareResult(U({},this.coordinates)):this.defaultCoordinates(),e={rotate:this.imageTransforms.rotate%360,flip:U({},this.imageTransforms.flip)};if(this.src&&this.imageLoaded){var n=this;return{image:this.image,coordinates:t,visibleArea:this.visibleArea?U({},this.visibleArea):null,imageTransforms:e,get canvas(){return n.canvas?n.getCanvas():void 0}}}return{image:this.image,coordinates:t,visibleArea:this.visibleArea?U({},this.visibleArea):null,canvas:void 0,imageTransforms:e}},zoom:function(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.transitions,o=r===void 0||r;this.onManipulateImage(new Lt({},{factor:1/t,center:e}),{normalize:!1,transitions:o})},move:function(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.transitions,o=r===void 0||r;this.onManipulateImage(new Lt({left:t||0,top:e||0}),{normalize:!1,transitions:o})},setCoordinates:function(t){var e=this,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.autoZoom,o=r===void 0||r,s=n.transitions,a=s===void 0||s;this.$nextTick(function(){e.imageLoaded?(e.transitionsActive||(a&&e.enableTransitions(),e.coordinates=e.applyTransform(t),o&&e.runAutoZoom("setCoordinates"),a&&e.debouncedDisableTransitions()),e.onChange()):e.delayedTransforms=t})},refresh:function(){var t=this,e=this.$refs.image;if(this.src&&e)return this.initialized?this.updateVisibleArea().then(function(){t.onChange()}):this.resetVisibleArea().then(function(){t.onChange()})},reset:function(){var t=this;return this.resetVisibleArea().then(function(){t.onChange(!1)})},awaitRender:function(t){var e=this;this.awaiting||(this.awaiting=!0,this.$nextTick(function(){t(),e.awaiting=!1}))},prepareResult:function(t){return this.roundResult?function(e){var n=e.coordinates,r=e.sizeRestrictions,o=e.positionRestrictions,s={width:Math.round(n.width),height:Math.round(n.height),left:Math.round(n.left),top:Math.round(n.top)};return s.width>r.maxWidth?s.width=Math.floor(n.width):s.width<r.minWidth&&(s.width=Math.ceil(n.width)),s.height>r.maxHeight?s.height=Math.floor(n.height):s.height<r.minHeight&&(s.height=Math.ceil(n.height)),ae(s,o)}(U(U({},this.getPublicProperties()),{},{positionRestrictions:xn(this.positionRestrictions,this.visibleArea),coordinates:t})):t},processAutoZoom:function(t,e,n,r){var o=this.autoZoomAlgorithm;o||(o=this.stencilSize?nf:this.autoZoom?rf:of);var s=o({event:{type:t,params:r},visibleArea:e,coordinates:n,boundaries:this.boundaries,aspectRatio:this.getAspectRatio(),positionRestrictions:this.positionRestrictions,getAreaRestrictions:this.getAreaRestrictions,sizeRestrictions:this.sizeRestrictions,stencilSize:this.getStencilSize()});return U(U({},s),{},{changed:!ys(s.visibleArea,e)||!ys(s.coordinates,n)})},runAutoZoom:function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=e.transitions,r=n!==void 0&&n,o=Wh(e,kf),s=this.processAutoZoom(t,this.visibleArea,this.coordinates,o),a=s.visibleArea,d=s.coordinates,c=s.changed;r&&c&&this.enableTransitions(),this.visibleArea=a,this.coordinates=d,r&&c&&this.debouncedDisableTransitions()},normalizeEvent:function(t){return function(e){var n=e.event,r=e.visibleArea,o=e.coefficient;if(n.type==="manipulateImage")return A(A({},n),{move:{left:n.move&&n.move.left?o*n.move.left:0,top:n.move&&n.move.top?o*n.move.top:0},scale:{factor:n.scale&&n.scale.factor?n.scale.factor:1,center:n.scale&&n.scale.center?{left:n.scale.center.left*o+r.left,top:n.scale.center.top*o+r.top}:null}});if(n.type==="resize"){var s=A(A({},n),{directions:A({},n.directions)});return Te.forEach(function(d){s.directions[d]*=o}),s}if(n.type==="move"){var a=A(A({},n),{directions:A({},n.directions)});return Qh.forEach(function(d){a.directions[d]*=o}),a}return n}(U(U({},this.getPublicProperties()),{},{event:t}))},getCanvas:function(){if(this.$refs.canvas){var t=this.$refs.canvas,e=this.$refs.image,n=this.imageTransforms.rotate!==0||this.imageTransforms.flip.horizontal||this.imageTransforms.flip.vertical?function(d,c,u){var h=u.rotate,f=u.flip,m={width:c.naturalWidth,height:c.naturalHeight},g=bs(m,h),p=d.getContext("2d");d.height=g.height,d.width=g.width,p.save();var k=je(se(A({left:0,top:0},m)),h);return p.translate(-(k.left-g.width/2),-(k.top-g.height/2)),p.rotate(h*Math.PI/180),p.translate(f.horizontal?m.width:0,f.vertical?m.height:0),p.scale(f.horizontal?-1:1,f.vertical?-1:1),p.drawImage(c,0,0,m.width,m.height),p.restore(),d}(this.$refs.sourceCanvas,e,this.imageTransforms):e,r=U({minWidth:0,minHeight:0,maxWidth:1/0,maxHeight:1/0,maxArea:this.maxCanvasSize,imageSmoothingEnabled:!0,imageSmoothingQuality:"high",fillColor:"transparent"},this.canvas),o=function(d){return d.find(function(c){return u=c,!Number.isNaN(parseFloat(u))&&isFinite(u);var u})},s=He({sizeRestrictions:{minWidth:o([r.width,r.minWidth])||0,minHeight:o([r.height,r.minHeight])||0,maxWidth:o([r.width,r.maxWidth])||1/0,maxHeight:o([r.height,r.maxHeight])||1/0},width:this.coordinates.width,height:this.coordinates.height,aspectRatio:{minimum:this.coordinates.width/this.coordinates.height,maximum:this.coordinates.width/this.coordinates.height}});if(r.maxArea&&s.width*s.height>r.maxArea){var a=Math.sqrt(r.maxArea/(s.width*s.height));s={width:Math.round(a*s.width),height:Math.round(a*s.height)}}return function(d,c,u,h,f){d.width=h?h.width:u.width,d.height=h?h.height:u.height;var m=d.getContext("2d");m.clearRect(0,0,d.width,d.height),f&&(f.imageSmoothingEnabled&&(m.imageSmoothingEnabled=f.imageSmoothingEnabled),f.imageSmoothingQuality&&(m.imageSmoothingQuality=f.imageSmoothingQuality),f.fillColor&&(m.fillStyle=f.fillColor,m.fillRect(0,0,d.width,d.height),m.save()));var g=u.left<0?-u.left:0,p=u.top<0?-u.top:0;m.drawImage(c,u.left+g,u.top+p,u.width,u.height,g*(d.width/u.width),p*(d.height/u.height),d.width,d.height)}(t,n,this.coordinates,s,r),t}},update:function(){this.$emit("change",this.getResult())},applyTransform:function(t){var e=arguments.length>1&&arguments[1]!==void 0&&arguments[1],n=this.visibleArea&&e?ef(this.sizeRestrictions,this.visibleArea):this.sizeRestrictions,r=this.visibleArea&&e?xn(this.positionRestrictions,this.visibleArea):this.positionRestrictions;return tf({transform:t,coordinates:this.coordinates,imageSize:this.imageSize,sizeRestrictions:n,positionRestrictions:r,aspectRatio:this.getAspectRatio(),visibleArea:this.visibleArea})},resetCoordinates:function(){var t=this;if(this.$refs.image){this.$refs.cropper,this.$refs.image;var e=this.defaultSize;e||(e=this.stencilSize?lf:af);var n=this.sizeRestrictions;n.minWidth,n.minHeight,n.maxWidth,n.maxHeight;var r=yt(e)?e({boundaries:this.boundaries,imageSize:this.imageSize,aspectRatio:this.getAspectRatio(),sizeRestrictions:this.sizeRestrictions,stencilSize:this.getStencilSize(),visibleArea:this.visibleArea}):e,o=this.defaultPosition||sf,s=[r,function(a){var d=a.coordinates;return U({},yt(o)?o({coordinates:d,imageSize:t.imageSize,visibleArea:t.visibleArea}):t.defaultPosition)}];this.delayedTransforms&&s.push.apply(s,ot(Array.isArray(this.delayedTransforms)?this.delayedTransforms:[this.delayedTransforms])),this.coordinates=this.applyTransform(s,!0),this.delayedTransforms=null}},clearImage:function(){var t=this;this.imageLoaded=!1,setTimeout(function(){var e=t.$refs.stretcher;e&&(e.style.height="auto",e.style.width="auto"),t.coordinates=t.defaultCoordinates(),t.boundaries={width:0,height:0}},this.transitionTime)},enableTransitions:function(){this.transitions&&(this.transitionsActive=!0)},disableTransitions:function(){this.transitionsActive=!1},updateBoundaries:function(){var t=this,e=this.$refs.stretcher,n=this.$refs.cropper;return this.initStretcher({cropper:n,stretcher:e,imageSize:this.imageSize}),this.$nextTick().then(function(){var r={cropper:n,imageSize:t.imageSize};if(yt(t.defaultBoundaries)?t.boundaries=t.defaultBoundaries(r):t.defaultBoundaries==="fit"?t.boundaries=function(o){var s=o.cropper,a=o.imageSize,d=s.clientHeight,c=s.clientWidth,u=d,h=a.width*d/a.height;return h>c&&(h=c,u=a.height*c/a.width),{width:h,height:u}}(r):t.boundaries=function(o){var s=o.cropper;return{width:s.clientWidth,height:s.clientHeight}}(r),!t.boundaries.width||!t.boundaries.height)throw new Error("It's impossible to fit the cropper in the current container")})},resetVisibleArea:function(){var t=this;return this.appliedImageTransforms=U(U({},this.defaultImageTransforms),{},{flip:U({},this.defaultImageTransforms.flip)}),this.updateBoundaries().then(function(){t.priority!=="visible-area"&&(t.visibleArea=null,t.resetCoordinates());var e,n,r,o,s,a,d=t.defaultVisibleArea||cf;t.visibleArea=yt(d)?d({imageSize:t.imageSize,boundaries:t.boundaries,coordinates:t.priority!=="visible-area"?t.coordinates:null,getAreaRestrictions:t.getAreaRestrictions,stencilSize:t.getStencilSize()}):t.defaultVisibleArea,t.visibleArea=(e={visibleArea:t.visibleArea,boundaries:t.boundaries,getAreaRestrictions:t.getAreaRestrictions},n=e.visibleArea,r=e.boundaries,o=e.getAreaRestrictions,s=A({},n),a=W(r),s.width/s.height!==a&&(s.height=s.width/a),ae(s,o({visibleArea:s,type:"move"}))),t.priority==="visible-area"?t.resetCoordinates():t.coordinates=t.fitCoordinates({visibleArea:t.visibleArea,coordinates:t.coordinates,aspectRatio:t.getAspectRatio(),positionRestrictions:t.positionRestrictions,sizeRestrictions:t.sizeRestrictions}),t.runAutoZoom("resetVisibleArea")}).catch(function(){t.visibleArea=null})},updateVisibleArea:function(){var t=this;return this.updateBoundaries().then(function(){t.visibleArea=t.fitVisibleArea({imageSize:t.imageSize,boundaries:t.boundaries,visibleArea:t.visibleArea,coordinates:t.coordinates,getAreaRestrictions:t.getAreaRestrictions}),t.coordinates=t.fitCoordinates({visibleArea:t.visibleArea,coordinates:t.coordinates,aspectRatio:t.getAspectRatio(),positionRestrictions:t.positionRestrictions,sizeRestrictions:t.sizeRestrictions}),t.runAutoZoom("updateVisibleArea")}).catch(function(){t.visibleArea=null})},onChange:function(){var t=!(arguments.length>0&&arguments[0]!==void 0)||arguments[0];t&&this.debounce?this.debouncedUpdate():this.update()},onChangeImage:function(){var t,e=this;if(this.imageLoaded=!1,this.delayedTransforms=null,this.src){if(function(o){if(ds(o))return!1;var s=window.location,a=/(\w+:)?(?:\/\/)([\w.-]+)?(?::(\d+))?\/?/.exec(o)||[],d={protocol:a[1]||"",host:a[2]||"",port:a[3]||""},c=function(u){return u.port||((u.protocol||s.protocol)==="http"?80:433)};return!(!d.protocol&&!d.host&&!d.port||d.protocol&&d.protocol==s.protocol&&d.host&&d.host==s.host&&d.host&&c(d)==c(s))}(this.src)){var n=ne(this.crossOrigin)?this.canvas:this.crossOrigin;n===!0&&(n="anonymous"),this.imageAttributes.crossOrigin=n||null}if(this.checkOrientation){var r=(t=this.src,new Promise(function(o){Cf(t).then(function(s){var a=Sf(s);o(s?{source:t,arrayBuffer:s,orientation:a}:{source:t,arrayBuffer:null,orientation:null})}).catch(function(s){console.warn(s),o({source:t,arrayBuffer:null,orientation:null})})}));setTimeout(function(){r.then(e.onParseImage)},this.transitionTime)}else setTimeout(function(){e.onParseImage({source:e.src})},this.transitionTime)}else this.clearImage()},onFailLoadImage:function(){this.imageAttributes.src&&(this.clearImage(),this.$emit("error"))},onSuccessLoadImage:function(){var t=this,e=this.$refs.image;e&&!this.imageLoaded&&(this.imageAttributes.height=e.naturalHeight,this.imageAttributes.width=e.naturalWidth,this.imageLoaded=!0,this.resetVisibleArea().then(function(){t.$emit("ready"),t.onChange(!1)}))},onParseImage:function(t){var e=this,n=t.source,r=t.arrayBuffer,o=t.orientation;this.imageAttributes.revoke&&this.imageAttributes.src&&URL.revokeObjectURL(this.imageAttributes.src),this.imageAttributes.revoke=!1,r&&o&&o>1?cs(n)||!ds(n)?(this.imageAttributes.src=URL.createObjectURL(new Blob([r])),this.imageAttributes.revoke=!0):this.imageAttributes.src=function(s){for(var a=[],d=new Uint8Array(s);d.length>0;){var c=d.subarray(0,8192);a.push(String.fromCharCode.apply(null,Array.from?Array.from(c):c.slice())),d=d.subarray(8192)}return"data:image/jpeg;base64,"+btoa(a.join(""))}(r):this.imageAttributes.src=n,yt(this.defaultTransforms)?this.appliedImageTransforms=Hi(this.defaultTransforms()):Sn(this.defaultTransforms)?this.appliedImageTransforms=Hi(this.defaultTransforms):this.appliedImageTransforms=function(s){var a=Hi({});if(s)switch(s){case 2:a.flip.horizontal=!0;break;case 3:a.rotate=-180;break;case 4:a.flip.vertical=!0;break;case 5:a.rotate=90,a.flip.vertical=!0;break;case 6:a.rotate=90;break;case 7:a.rotate=90,a.flip.horizontal=!0;break;case 8:a.rotate=-90}return a}(o),this.defaultImageTransforms=U(U({},this.appliedImageTransforms),{},{flip:U({},this.appliedImageTransforms.flip)}),this.$nextTick(function(){var s=e.$refs.image;s&&s.complete&&(function(a){return!!a.naturalWidth}(s)?e.onSuccessLoadImage():e.onFailLoadImage())})},onResizeEnd:function(){this.runAutoZoom("resize",{transitions:!0})},onMoveEnd:function(){this.runAutoZoom("move",{transitions:!0})},onMove:function(t){var e=this;this.transitionsOptions.enabled||this.awaitRender(function(){e.coordinates=e.moveAlgorithm(U(U({},e.getPublicProperties()),{},{positionRestrictions:xn(e.positionRestrictions,e.visibleArea),coordinates:e.coordinates,event:e.normalizeEvent(t)})),e.onChange()})},onResize:function(t){var e=this;this.transitionsOptions.enabled||this.stencilSize&&!this.autoZoom||this.awaitRender(function(){var n=e.sizeRestrictions,r=Math.min(e.coordinates.width,e.coordinates.height,20*e.coefficient);e.coordinates=e.resizeAlgorithm(U(U({},e.getPublicProperties()),{},{positionRestrictions:xn(e.positionRestrictions,e.visibleArea),sizeRestrictions:{maxWidth:Math.min(n.maxWidth,e.visibleArea.width),maxHeight:Math.min(n.maxHeight,e.visibleArea.height),minWidth:Math.max(n.minWidth,r),minHeight:Math.max(n.minHeight,r)},event:e.normalizeEvent(t)})),e.onChange(),e.ticking=!1})},onManipulateImage:function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!this.transitionsOptions.enabled){var n=e.transitions,r=n!==void 0&&n,o=e.normalize,s=o===void 0||o;r&&this.enableTransitions();var a=df(U(U({},this.getPublicProperties()),{},{event:s?this.normalizeEvent(t):t,getAreaRestrictions:this.getAreaRestrictions,imageRestriction:this.imageRestriction,adjustStencil:!this.stencilSize&&this.settings.resizeImage.adjustStencil})),d=a.visibleArea,c=a.coordinates;this.visibleArea=d,this.coordinates=c,this.runAutoZoom("manipulateImage"),this.onChange(),r&&this.debouncedDisableTransitions()}},onPropsChange:function(){this.coordinates=this.applyTransform(this.coordinates,!0),this.onChange(!1)},getAreaRestrictions:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},e=t.visibleArea,n=t.type,r=n===void 0?"move":n;return this.areaRestrictionsAlgorithm({boundaries:this.boundaries,imageSize:this.imageSize,imageRestriction:this.imageRestriction,visibleArea:e,type:r})},getAspectRatio:function(t){var e,n,r=this.stencilProps,o=r.aspectRatio,s=r.minAspectRatio,a=r.maxAspectRatio;if(this.$refs.stencil&&this.$refs.stencil.aspectRatios){var d=this.$refs.stencil.aspectRatios();e=d.minimum,n=d.maximum}if(ne(e)&&(e=ne(o)?s:o),ne(n)&&(n=ne(o)?a:o),!t&&(ne(e)||ne(n))){var c=this.getStencilSize(),u=c?W(c):null;ne(e)&&(e=us(u)?u:void 0),ne(n)&&(n=us(u)?u:void 0)}return{minimum:e,maximum:n}},getStencilSize:function(){if(this.stencilSize)return t={currentStencilSize:{width:this.stencilCoordinates.width,height:this.stencilCoordinates.height},stencilSize:this.stencilSize,boundaries:this.boundaries,coefficient:this.coefficient,coordinates:this.coordinates,aspectRatio:this.getAspectRatio(!0)},e=t.boundaries,n=t.stencilSize,r=t.aspectRatio,zi(W(o=yt(n)?n({boundaries:e,aspectRatio:r}):n),r)&&(o=He({sizeRestrictions:{maxWidth:e.width,maxHeight:e.height,minWidth:0,minHeight:0},width:o.width,height:o.height,aspectRatio:{minimum:r.minimum,maximum:r.maximum}})),(o.width>e.width||o.height>e.height)&&(o=He({sizeRestrictions:{maxWidth:e.width,maxHeight:e.height,minWidth:0,minHeight:0},width:o.width,height:o.height,aspectRatio:{minimum:W(o),maximum:W(o)}})),o;var t,e,n,r,o},getPublicProperties:function(){return{coefficient:this.coefficient,visibleArea:this.visibleArea,coordinates:this.coordinates,boundaries:this.boundaries,sizeRestrictions:this.sizeRestrictions,positionRestrictions:this.positionRestrictions,aspectRatio:this.getAspectRatio(),imageRestriction:this.imageRestriction}},defaultCoordinates:function(){return U({},gs)},flip:function(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.transitions,o=r===void 0||r;if(!this.transitionsActive){o&&this.enableTransitions();var s=U({},this.imageTransforms.flip),a=hf({flip:{horizontal:t?!s.horizontal:s.horizontal,vertical:e?!s.vertical:s.vertical},previousFlip:s,rotate:this.imageTransforms.rotate,visibleArea:this.visibleArea,coordinates:this.coordinates,imageSize:this.imageSize,positionRestrictions:this.positionRestrictions,sizeRestrictions:this.sizeRestrictions,getAreaRestrictions:this.getAreaRestrictions,aspectRatio:this.getAspectRatio()}),d=a.visibleArea,c=a.coordinates;t&&(this.appliedImageTransforms.flip.horizontal=!this.appliedImageTransforms.flip.horizontal),e&&(this.appliedImageTransforms.flip.vertical=!this.appliedImageTransforms.flip.vertical),this.visibleArea=d,this.coordinates=c,this.onChange(),o&&this.debouncedDisableTransitions()}},rotate:function(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=e.transitions,r=n===void 0||n;if(!this.transitionsActive){r&&this.enableTransitions();var o=U({},this.imageSize);this.appliedImageTransforms.rotate+=t;var s=uf({visibleArea:this.visibleArea,coordinates:this.coordinates,previousImageSize:o,imageSize:this.imageSize,angle:t,positionRestrictions:this.positionRestrictions,sizeRestrictions:this.sizeRestrictions,getAreaRestrictions:this.getAreaRestrictions,aspectRatio:this.getAspectRatio()}),a=s.visibleArea,d=s.coordinates,c=this.processAutoZoom("rotateImage",a,d);a=c.visibleArea,d=c.coordinates,this.visibleArea=a,this.coordinates=d,this.onChange(),r&&this.debouncedDisableTransitions()}}},emits:["change","error","ready"]},Ef={key:0,ref:"canvas",style:{display:"none"}},vf={key:1,ref:"sourceCanvas",style:{display:"none"}};As.render=function(t,e,n,r,o,s){return i.openBlock(),i.createBlock("div",{ref:"cropper",class:s.classes.cropper},[i.createVNode("div",{ref:"stretcher",class:s.classes.stretcher},null,2),i.createVNode("div",{class:s.classes.boundaries,style:s.boundariesStyle},[(i.openBlock(),i.createBlock(i.resolveDynamicComponent(n.backgroundWrapperComponent),{class:s.classes.cropperWrapper,"wheel-resize":s.settings.resizeImage.wheel,"touch-resize":s.settings.resizeImage.touch,"touch-move":s.settings.moveImage.touch,"mouse-move":s.settings.moveImage.mouse,onMove:s.onManipulateImage,onResize:s.onManipulateImage},{default:i.withCtx(function(){return[i.createVNode("div",{class:s.classes.background,style:s.boundariesStyle},null,6),i.createVNode("div",{class:s.classes.imageWrapper},[i.createVNode("img",{ref:"image",crossorigin:o.imageAttributes.crossOrigin,src:o.imageAttributes.src,class:s.classes.image,style:s.imageStyle,onMousedown:e[1]||(e[1]=i.withModifiers(function(){},["prevent"]))},null,46,["crossorigin","src"])],2),i.createVNode("div",{class:s.classes.foreground,style:s.boundariesStyle},null,6),i.withDirectives((i.openBlock(),i.createBlock(i.resolveDynamicComponent(n.stencilComponent),i.mergeProps({ref:"stencil",image:s.image,coordinates:o.coordinates,"stencil-coordinates":s.stencilCoordinates,transitions:s.transitionsOptions},n.stencilProps,{onResize:s.onResize,onResizeEnd:s.onResizeEnd,onMove:s.onMove,onMoveEnd:s.onMoveEnd}),null,16,["image","coordinates","stencil-coordinates","transitions","onResize","onResizeEnd","onMove","onMoveEnd"])),[[i.vShow,o.imageLoaded]]),n.canvas?(i.openBlock(),i.createBlock("canvas",Ef,null,512)):i.createCommentVNode("",!0),n.canvas?(i.openBlock(),i.createBlock("canvas",vf,null,512)):i.createCommentVNode("",!0)]}),_:1},8,["class","wheel-resize","touch-resize","touch-move","mouse-move","onMove","onResize"]))],6)],2)};const Mf={class:"background-container"},xf={class:"tools-line"},Bf={class:"line-block"},If={class:"dialog-footer"},Ui=M(i.defineComponent({__name:"ImageCropper",props:{open:{type:Boolean,required:!0},defaultRatio:{type:Number,required:!1,default:1}},emits:["crop","close"],setup(t,{emit:e}){const n=t,r=e,o=S.S.Cropper.Cropper(),s=i.ref(n.defaultRatio);o.ratio=s.value;const a=async()=>{s.value===0?o.ratio=0:o.ratio=s.value},d=i.ref({width:0,height:0,left:0,top:0}),c=i.ref(!1),u=i.ref(""),h=i.ref(),f=async()=>{c.value=!0;const g=h.value.getResult();o.ratio===0&&(s.value=d.value.width/d.value.height),g&&g.canvas.toBlob(p=>{var k;r("crop",{blob:p,src:(k=g.canvas)==null?void 0:k.toDataURL()})}),c.value=!1},m=g=>{var p;d.value=g.coordinates,u.value=(p=g.canvas)==null?void 0:p.toDataURL()};return(g,p)=>{const k=it,w=i.resolveComponent("el-form-item"),B=i.resolveComponent("el-form"),D=i.resolveComponent("el-button"),L=Ft;return i.openBlock(),i.createBlock(L,{show:t.open,title:"Настройка изображения","close-on-click-modal":!1,"close-on-press-escape":!1,"show-close":!1},{default:i.withCtx(()=>[i.createElementVNode("div",Mf,[i.createElementVNode("div",xf,[i.createElementVNode("div",Bf,[i.createVNode(B,null,{default:i.withCtx(()=>[i.createVNode(w,{label:"Задайте пропорции фото:"},{default:i.withCtx(()=>[i.createVNode(k,{modelValue:i.unref(s),"onUpdate:modelValue":p[0]||(p[0]=V=>i.isRef(s)?s.value=V:null),label:"Пропорции изображения",onChange:a},{default:i.withCtx(()=>p[1]||(p[1]=[i.createElementVNode("option",{label:"2:3 (формат A4)",value:2/3},null,-1),i.createElementVNode("option",{label:"4:3 (для карточек новостей)",value:4/3},null,-1),i.createElementVNode("option",{label:"1:1 (для фото сотрудников)",value:1},null,-1),i.createElementVNode("option",{label:"3:2",value:3/2},null,-1),i.createElementVNode("option",{label:"16:9",value:16/9},null,-1),i.createElementVNode("option",{label:"3:4 (вертикальное изображение)",value:3/4},null,-1),i.createElementVNode("option",{label:"Задать пропорции вручную",value:0},null,-1)])),_:1},8,["modelValue"])]),_:1})]),_:1})])]),i.createVNode(i.unref(As),{ref_key:"cropperRef",ref:h,src:i.unref(o).src,"stencil-props":{aspectRatio:i.unref(o).ratio},style:{"max-height":"50vh","min-height":"50vh"},onChange:m},null,8,["src","stencil-props"]),i.createElementVNode("div",If,[i.createVNode(D,{loading:i.unref(c),type:"success",onClick:f},{default:i.withCtx(()=>p[2]||(p[2]=[i.createTextVNode(" Сохранить ")])),_:1},8,["loading"])])])]),_:1},8,["show"])}}}),[["__scopeId","data-v-cab0e63b"]]),Ps=M(i.defineComponent({__name:"InfoItemSelectButtons",props:{selected:{type:String,required:!0},title:{type:String,required:!0},list:{type:Array,required:!0}},emits:["select","reset"],setup(t,{emit:e}){const n=i.ref(!1),r=e,o=s=>{n.value=!n.value,r("select",s)};return(s,a)=>{const d=me,c=Se,u=rt;return i.openBlock(),i.createBlock(u,{close:i.unref(n),title:t.title,"close-window-overflow":"hidden","with-hover":!0,"with-open-window":!0},{"open-inside-content":i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(t.list,h=>(i.openBlock(),i.createBlock(c,{key:h,type:"admin",color:"blue",text:h,onClick:f=>o(h)},null,8,["text","onClick"]))),128)),i.createVNode(c,{type:"admin",color:"blue",text:"Сбросить",onClick:a[0]||(a[0]=h=>o(void 0))})]),default:i.withCtx(()=>[i.createVNode(d,{string:t.selected,"font-size":"14px",width:"100%"},null,8,["string"])]),_:1},8,["close","title"])}}}),[["__scopeId","data-v-89897936"]]),Rf={class:"mainblock"},$f={class:"mainline"},Ts=M(i.defineComponent({__name:"LeftRightContainer",props:{leftWidth:{type:String,required:!1,default:"0px"},background:{type:String,required:!1,default:"inherit"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",Rf,[i.createElementVNode("div",$f,[i.createElementVNode("div",{class:"mainblock-left",style:i.normalizeStyle({minWidth:t.leftWidth,maxWidth:t.leftWidth,background:t.background,display:t.leftWidth!=="0px"?"block":"none"})},[i.renderSlot(e.$slots,"left",{},void 0,!0)],4),i.createElementVNode("div",{class:"mainblock-right",style:i.normalizeStyle({background:t.background})},[i.renderSlot(e.$slots,"right",{},void 0,!0)],4)])]))}}),[["__scopeId","data-v-a4bc6b16"]]),Nf={class:"message-title"},Af={class:"message-text"},Rn=M(i.defineComponent({__name:"MessageBody",props:{title:{type:String,default:"",required:!1},text:{type:String,default:"",required:!1}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",null,[i.createElementVNode("div",Nf,i.toDisplayString(t.title),1),i.createElementVNode("div",Af,i.toDisplayString(t.text),1)]))}}),[["__scopeId","data-v-e3c1e672"]]),Pf=i.defineComponent({name:"CollapseContainer",props:{initActiveIdx:{type:Number,default:0}},setup(t){const e=i.ref(t.initActiveIdx),n=r=>{e.value=r};return i.watch(()=>t.initActiveIdx,()=>{n(t.initActiveIdx)}),{changeActiveId:n,activeIdx:e}}});function Tf(t,e,n,r,o,s){return i.openBlock(),i.createElementBlock("div",null,[i.renderSlot(t.$slots,"default",{activeIdx:t.activeIdx,changeActiveId:t.changeActiveId})])}const zs=M(Pf,[["render",Tf]]),zf=i.defineComponent({name:"CollapseItem",props:{tabId:{type:String,required:!1,default:""},activeId:{type:String,default:""},isCollaps:{type:Boolean,default:!0},title:{type:String,default:""},showToolsOnHover:{type:Boolean,default:!0},background:{type:String,required:!1,default:"#ffffff"},backgroundAttention:{type:String,required:!1,default:"#ffffff"},changeColor:{type:Boolean,default:!1},margin:{type:String,default:"10px 8px 2px 2px"},padding:{type:String,default:"0 10px"},selectable:{type:Boolean,default:!1}},emits:["changeActiveId"],setup(t,{emit:e}){const n=i.ref(t.activeId==="0"),r=()=>{n.value=!n.value,e("changeActiveId",t.tabId)};return i.onUpdated(()=>{t.activeId&&t.activeId!==t.tabId&&(n.value=!0)}),i.onBeforeMount(()=>{t.activeId&&t.activeId!==t.tabId&&(n.value=!1)}),{collapsed:n,handleItemClick:r}}}),Vf=["for"],Ff={class:"inside-icon"};function Df(t,e,n,r,o,s){return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createElementVNode("div",{class:"tab",style:i.normalizeStyle({margin:t.margin,height:t.isCollaps&&t.collapsed?"60px":"","box-shadow":t.selectable&&t.activeId===t.tabId?"0px 0px 1px 2px #1979cf":""})},[t.isCollaps&&t.collapsed?(i.openBlock(),i.createElementBlock("svg",{key:0,class:"icon-arrow",onClick:e[0]||(e[0]=(...a)=>t.handleItemClick&&t.handleItemClick(...a))},e[3]||(e[3]=[i.createElementVNode("use",{"xlink:href":"#arrow-down"},null,-1)]))):t.isCollaps&&!t.collapsed?(i.openBlock(),i.createElementBlock("svg",{key:1,class:"icon-arrow",onClick:e[1]||(e[1]=(...a)=>t.handleItemClick&&t.handleItemClick(...a))},e[4]||(e[4]=[i.createElementVNode("use",{"xlink:href":"#arrow-up"},null,-1)]))):i.createCommentVNode("",!0),i.createElementVNode("label",{for:t.tabId,onClick:e[2]||(e[2]=(...a)=>t.handleItemClick&&t.handleItemClick(...a))},[i.createElementVNode("div",{style:i.normalizeStyle({cursor:t.isCollaps?"pointer":"default",background:t.changeColor?t.background:t.backgroundAttention,padding:t.padding,borderRadius:"5px"}),class:"tab-name"},[i.createElementVNode("div",Ff,[i.renderSlot(t.$slots,"icon",{},void 0,!0)]),t.title?(i.openBlock(),i.createElementBlock("div",{key:0,class:"title-in",style:i.normalizeStyle({marginRight:t.isCollaps?"50px":"0",width:t.isCollaps?"calc(100% - 50px)":"100%"})},i.toDisplayString(t.title),5)):(i.openBlock(),i.createElementBlock("div",{key:1,class:"title-in",style:i.normalizeStyle({marginRight:t.isCollaps?"50px":"0",width:t.isCollaps?"calc(100% - 50px)":"100%"})},[i.renderSlot(t.$slots,"inside-title",{},void 0,!0)],4)),i.createElementVNode("div",{class:i.normalizeClass(["tools-bar",{"hidden-part":t.showToolsOnHover}])},[i.renderSlot(t.$slots,"tools",{},void 0,!0)],2)],4)],8,Vf),i.createElementVNode("div",{style:i.normalizeStyle({maxHeight:t.isCollaps?"":"1000000vh",background:t.changeColor?t.background:t.backgroundAttention}),class:i.normalizeClass(t.collapsed?"tab-content-down":"tab-content-up")},[i.renderSlot(t.$slots,"inside-content",{},void 0,!0)],6)],4),e[5]||(e[5]=i.createStaticVNode('<svg width="0" height="0" class="hidden" data-v-50a7d390><symbol id="arrow-down" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" data-v-50a7d390><path d="M5 6L10 11L15 6L17 7L10 14L3 7L5 6Z" fill="currentColor" data-v-50a7d390></path></symbol><symbol id="arrow-up" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" data-v-50a7d390><path d="M15 14L10 9L5 14L3 13L10 6L17 13L15 14Z" fill="currentColor" data-v-50a7d390></path></symbol></svg>',1))],64)}const Vs=M(zf,[["render",Df],["__scopeId","data-v-50a7d390"]]),Lf={class:"tab"},Of={class:"rotate"},Fs=M(i.defineComponent({__name:"VerticalCollapseContainer",setup(t){const e=i.ref(!1),n=async()=>{e.value=!e.value};return(r,o)=>{const s=bn,a=wn;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createElementVNode("div",Lf,[i.renderSlot(r.$slots,"main",{},void 0,!0),i.createElementVNode("div",{style:i.normalizeStyle({width:i.unref(e)?"50%":"20px",transition:"0.3s"}),class:"left"},[i.createElementVNode("div",{style:i.normalizeStyle({width:i.unref(e)?"100%":"0",transition:"0.3s"}),class:"left-content"},[i.renderSlot(r.$slots,"inside-content-left",{},void 0,!0)],4),i.createElementVNode("div",{class:"arrow-bar",onClick:n},[i.createElementVNode("div",Of,[i.renderSlot(r.$slots,"inside-title",{},void 0,!0)]),i.unref(e)?(i.openBlock(),i.createBlock(s,{key:0,"icon-class":"icon-arrow"})):(i.openBlock(),i.createBlock(a,{key:1,"icon-class":"icon-arrow"}))])],4),i.createElementVNode("div",{style:i.normalizeStyle({width:i.unref(e)?"50%":"100%",transition:"0.3s"}),class:"right"},[i.renderSlot(r.$slots,"inside-content-right",{},void 0,!0)],4)]),i.createVNode(a),i.createVNode(s)],64)}}}),[["__scopeId","data-v-d802b6b9"]]),Hf={class:"add-block_body"},Ds=M(i.defineComponent({__name:"PAdd",props:{background:{type:String,required:!1,default:"inherit"},margin:{type:String,required:!1,default:"0"},padding:{type:String,required:!1,default:"0"},top:{type:String,required:!1,default:"0"},zIndex:{type:Number,required:!1,default:0}},setup(t){return(e,n)=>{const r=yn;return i.openBlock(),i.createElementBlock("div",{class:"add-block",style:i.normalizeStyle({margin:t.margin,background:t.background,padding:t.padding})},[i.createVNode(r,{top:t.top,"z-index":t.zIndex},{default:i.withCtx(()=>[i.renderSlot(e.$slots,"title",{},void 0,!0)]),_:3},8,["top","z-index"]),i.createElementVNode("div",Hf,[i.renderSlot(e.$slots,"default",{},void 0,!0)])],4)}}}),[["__scopeId","data-v-b93bc8b1"]]),Wi=M(i.defineComponent({__name:"PContainer",props:{background:{type:String,required:!1,default:"inherit"},margin:{type:String,required:!1,default:"0"},padding:{type:String,required:!1,default:"0"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:"add-block",style:i.normalizeStyle({margin:t.margin,background:t.background,padding:t.padding})},[i.renderSlot(e.$slots,"default",{},void 0,!0)],4))}}),[["__scopeId","data-v-b89bdc7a"]]),_f={class:"add-block_body"},Ls=M(i.defineComponent({__name:"PContainerStickyHead",props:{background:{type:String,required:!1,default:"inherit"},margin:{type:String,required:!1,default:"0"},padding:{type:String,required:!1,default:"0"},top:{type:String,required:!1,default:"0"},zIndex:{type:Number,required:!1,default:0}},setup(t){return(e,n)=>{const r=yn,o=Wi;return i.openBlock(),i.createBlock(o,{background:t.background,margin:t.margin,padding:t.padding},{default:i.withCtx(()=>[i.createVNode(r,{top:t.top,"z-index":t.zIndex},{default:i.withCtx(()=>[i.renderSlot(e.$slots,"title",{},void 0,!0)]),_:3},8,["top","z-index"]),i.createElementVNode("div",_f,[i.renderSlot(e.$slots,"default",{},void 0,!0)])]),_:3},8,["background","margin","padding"])}}}),[["__scopeId","data-v-e59e418e"]]),qf={class:"del-block_title"},Uf={class:"del-block_body"},Os=M(i.defineComponent({__name:"PDel",props:{background:{type:String,required:!1,default:"inherit"},margin:{type:String,required:!1,default:"10px 10px 10px 50px"},padding:{type:String,required:!1,default:"10px"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:"del-block",style:i.normalizeStyle({margin:t.margin,background:t.background,padding:t.padding})},[i.createElementVNode("div",qf,[i.renderSlot(e.$slots,"title",{},void 0,!0)]),i.createElementVNode("div",Uf,[i.renderSlot(e.$slots,"default",{},void 0,!0)])],4))}}),[["__scopeId","data-v-362b7b0d"]]),Wf=["onClick"],Hs=M(i.defineComponent({__name:"PTabs",props:{tabs:{type:Object,required:!0},tabHeight:{type:String,required:!1,default:"40px"},height:{type:String,required:!1,default:""},minMenuItemWidth:{type:String,required:!1,default:"150px"},outTopMargin:{type:String,required:!1,default:"40px"},background:{type:String,required:!1,default:"#ffffff"}},emits:["select"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.tabs[0]),s=i.ref(0),a=i.ref(window.innerWidth),d=i.ref(),c=i.ref(Number(n.tabHeight.replace(/[^+\d]/g,""))),u=()=>{a.value=window.innerWidth,c.value=d.value?d.value.clientHeight:Number(n.tabHeight.replace(/[^+\d]/g,""))};i.onMounted(()=>window.addEventListener("resize",u)),i.onUnmounted(()=>window.removeEventListener("resize",u));const h=i.computed(()=>`calc(100% - ${c.value}px + 1px)`),f=(m,g)=>{o.value=m,s.value=g,r("select",m)};return(m,g)=>(i.openBlock(),i.createElementBlock("div",{class:"mainblock",style:i.normalizeStyle({height:`calc(100% - ${t.outTopMargin} - ${t.tabHeight}`})},[i.createElementVNode("div",{ref_key:"menuRef",ref:d,class:"top-menu",style:i.normalizeStyle({gridTemplateColumns:`repeat(auto-fit, minmax(${t.minMenuItemWidth}, 1fr))`})},[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(t.tabs,(p,k)=>(i.openBlock(),i.createElementBlock("div",{key:k},[i.createElementVNode("div",{class:i.normalizeClass({"selected-tab":k===i.unref(s),tab:k!==i.unref(s)}),style:i.normalizeStyle({minHeight:t.tabHeight,maxHeight:t.tabHeight}),onClick:w=>f(p,k)},i.toDisplayString(p.name),15,Wf)]))),128))],4),i.createElementVNode("div",{class:"body-container",style:i.normalizeStyle({background:t.background,height:i.unref(h)})},[i.renderSlot(m.$slots,"default",{},()=>[(i.openBlock(),i.createBlock(i.resolveDynamicComponent(i.unref(o).component)))],!0)],4)],4))}}),[["__scopeId","data-v-3cb80968"]]),Gf=["id"],jf=["for"],Zf={class:"left-field"},Jf=["href","download"],Xf={key:1,class:"text-field__input"},Yf={class:"right-field"},Qf=i.defineComponent({__name:"UploaderFile",props:{fileInfo:{type:Object,required:!1,default:new ye},formats:{type:Array,default:()=>["pdf","jpeg","jpg"]},label:{type:String,default:"Label",required:!1},margin:{type:String,required:!1,default:"10px 0 0 0"},disabled:{type:Boolean,required:!1,default:!1},padding:{type:String,default:"",required:!1},mask:{type:String,required:!1,default:void 0},borderColor:{type:String,default:"var(--input-border-color)",required:!1},color:{type:String,default:"var(--input-font-color)",required:!1},placeholder:{type:String,required:!1,default:""}},emits:["upload","remove"],setup(t,{emit:e}){const n=t,r=e,o=S.H.Strings.CreateGuid(),s=S.H.Strings.CreateGuid(),a=()=>{const u=document.getElementById(o);if(!u.files)return;const h=u.files[0];if(h){if(!c(h.name)){S.Notification.Error("Загруженный файл должен быть в формате pdf, jpg или jpeg");return}n.fileInfo.uploadAndSetFile(h),r("upload",n.fileInfo)}},d=()=>{n.fileInfo.clearFile(),r("remove",n.fileInfo)};i.onMounted(()=>{const u=document.getElementById(s);u&&(u.onclick=()=>{var h;return(h=document.getElementById(o))==null?void 0:h.click()})});const c=u=>{let h=S.H.Extension.Get(u);return!!n.formats.includes(h.toLowerCase())};return(u,h)=>{const f=me,m=Si,g=Se;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createElementVNode("input",{id:i.unref(o),type:"file",hidden:"",onChange:a},null,40,Gf),i.createElementVNode("div",{class:"text-field",style:i.normalizeStyle({margin:t.margin,padding:t.padding})},[t.label?(i.openBlock(),i.createElementBlock("label",{key:0,class:"text-field__label",for:t.label},i.toDisplayString(t.label),9,jf)):i.createCommentVNode("",!0),i.createElementVNode("div",{class:"field",style:i.normalizeStyle({borderColor:t.borderColor})},[i.createElementVNode("div",Zf,[i.createVNode(m,null,{default:i.withCtx(()=>[i.renderSlot(u.$slots,"default",{},void 0,!0),i.createVNode(f,{string:t.placeholder,"font-size":"var(--font-size-default:)",color:"var(--input-label-color)",margin:"0 10px 0 0"},null,8,["string"])]),_:3})]),t.fileInfo&&t.fileInfo.originalName?(i.openBlock(),i.createElementBlock("div",{key:0,class:"text-field__input",style:i.normalizeStyle({color:t.color})},[i.createElementVNode("a",{href:t.fileInfo.getFileUrl(),target:"_blank",download:t.fileInfo.originalName},[i.createElementVNode("div",null,i.toDisplayString(t.fileInfo.originalName),1)],8,Jf),i.createVNode(g,{skin:"text",type:"del",onClick:d},{default:i.withCtx(()=>[i.createVNode(Vt,{size:"20px",margin:"0 5px"})]),_:1})],4)):(i.openBlock(),i.createElementBlock("div",Xf,[i.createVNode(f,{string:"Файл не загружен","font-size":"var(--inpur-font-size-default)",color:"var(--palette-warning)",margin:"0 10px 0 0"})])),i.createElementVNode("div",Yf,[i.createVNode(g,{id:i.unref(s),skin:"text",type:"success","data-test":"upload-btn",text:t.fileInfo&&t.fileInfo.originalName?"Обновить":"Загрузить",margin:"0"},null,8,["id","text"])])],4)],4)],64)}}}),_s=M(Qf,[["__scopeId","data-v-51318b14"]]),Kf={class:"container"},em={key:0,class:"result"},tm={class:"list"},nm=["onClick"],Gi=M(i.defineComponent({inheritAttrs:!1,__name:"PAutocomplete",props:{modelValue:{type:String,default:""},searchFunc:{type:Function,default:()=>{}},suggestions:{type:Array,default:[]}},emits:["select","input"],setup(t,{emit:e}){const n=e,r=t,o=i.ref(r.modelValue),s=i.ref([]);async function a(){n("input",o.value),await d()}async function d(){r.searchFunc&&(s.value=await r.searchFunc(o.value))}async function c(u){n("select",u)}return(u,h)=>{const f=vi,m=ut;return i.openBlock(),i.createElementBlock("div",Kf,[i.createVNode(m,{modelValue:i.unref(o),"onUpdate:modelValue":h[0]||(h[0]=g=>i.isRef(o)?o.value=g:null),placeholder:"Найти",onInput:a},{right:i.withCtx(()=>[i.createVNode(f)]),_:1},8,["modelValue"]),i.unref(o)?(i.openBlock(),i.createElementBlock("div",em,[i.createElementVNode("ul",tm,[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(s),g=>(i.openBlock(),i.createElementBlock("li",{key:g.value,onClick:p=>c(g)},i.toDisplayString(g.label),9,nm))),128))])])):i.createCommentVNode("",!0)])}}}),[["__scopeId","data-v-58b78c5c"]]),im={class:"footer"},qs=M(i.defineComponent({__name:"PDialog",setup(t){const e=i.computed(()=>{switch(S.Dialog.GetType()){case"info":return"message primary";case"success":return"message success";case"warning":return"message warning";case"error":return"message danger";default:return"message neutral"}});return(n,r)=>{const o=Rn,s=Se;return i.openBlock(),i.createBlock(i.Transition,{name:"fade"},{default:i.withCtx(()=>[("PF"in n?n.PF:i.unref(S)).Dialog.IsVisible()?(i.openBlock(),i.createElementBlock("div",{key:0,class:i.normalizeClass(i.unref(e))},[i.createVNode(o,{title:("PF"in n?n.PF:i.unref(S)).Dialog.GetTitle(),text:("PF"in n?n.PF:i.unref(S)).Dialog.GetText()},null,8,["title","text"]),i.createElementVNode("div",im,[i.createVNode(s,{type:"primary",text:("PF"in n?n.PF:i.unref(S)).Dialog.GetConfirmButtonText(),margin:"10px 0 0 0",onClick:r[0]||(r[0]=a=>("PF"in n?n.PF:i.unref(S)).Dialog.Submit())},null,8,["text"]),i.createVNode(s,{type:"warning",text:("PF"in n?n.PF:i.unref(S)).Dialog.GetCancelButtonText(),margin:"10px 0 0 0",onClick:r[1]||(r[1]=a=>("PF"in n?n.PF:i.unref(S)).Dialog.Cancel())},null,8,["text"])])],2)):i.createCommentVNode("",!0)]),_:1})}}}),[["__scopeId","data-v-3af87587"]]),Us=M(i.defineComponent({__name:"PhoneForm",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(t){const e=i.useModel(t,"modelValue"),n=async()=>{await S.S.Phones.Update(e.value)};return(r,o)=>{const s=ut;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createVNode(s,{modelValue:e.value.number,"onUpdate:modelValue":o[0]||(o[0]=a=>e.value.number=a),onBlur:n},null,8,["modelValue"]),i.createVNode(s,{modelValue:e.value.description,"onUpdate:modelValue":o[1]||(o[1]=a=>e.value.description=a),onBlur:n},null,8,["modelValue"])],64)}}}),[["__scopeId","data-v-6de09525"]]),rm={};function om(t,e){return i.openBlock(),i.createElementBlock(i.Fragment,null,[e[0]||(e[0]=i.createElementVNode("div",{class:"blur"},null,-1)),e[1]||(e[1]=i.createElementVNode("div",{class:"loader-container"},[i.createElementVNode("div",{class:"loader",style:{"--b":"20px",width:"200px","--n":"10"}})],-1))],64)}const Ws=M(rm,[["render",om],["__scopeId","data-v-879cfd55"]]),Gs=M(i.defineComponent({__name:"PNotification",setup(t){const e=i.computed(()=>{switch(S.Notification.GetType()){case"info":return"message info";case"success":return"message success";case"warning":return"message warning";case"error":return"message error";default:return"message neutral"}});return(n,r)=>{const o=Rn;return i.openBlock(),i.createBlock(i.Transition,{name:"fade"},{default:i.withCtx(()=>[("PF"in n?n.PF:i.unref(S)).Notification.IsVisible()?(i.openBlock(),i.createElementBlock("div",{key:0,class:i.normalizeClass(i.unref(e))},[i.createVNode(o,{title:("PF"in n?n.PF:i.unref(S)).Notification.GetTitle(),text:("PF"in n?n.PF:i.unref(S)).Notification.GetText()},null,8,["title","text"])],2)):i.createCommentVNode("",!0)]),_:1})}}}),[["__scopeId","data-v-ec6a4660"]]),sm={style:{display:"flex","justify-content":"center",width:"100%"}},am={class:"pag-number"},lm={class:"pag-ul"},cm={key:2},js=M(i.defineComponent({__name:"PPagination",props:{showConfirm:{type:Boolean,default:!1},justifyContent:{type:String,default:"center"},store:{type:Object,required:!0}},emits:["cancel","save"],setup(t,{emit:e}){const n=t,r=g=>g?"active":"neutral",o=g=>g?"not-active":"neutral",s=S.Paginator,a=i.ref(!1),d=i.ref(!1),c=e;s.count=n.store.Count().value;const u=async g=>{if(g!==s.curPage){if(g<1&&(g=1),g>s.pagesCount()&&(g=s.pagesCount()),!n.showConfirm)return await h(g);S.Dialog.Save().then(async()=>{c("save"),await h(g)}).catch(async()=>{S.Notification.Warning("Изменения не были сохранены"),c("cancel"),await h(g)})}},h=async(g,p)=>{s.setCurPage(g),S.H.FTSP.Get().p.offset=(g-1)*s.limit,await n.store.FTSP(),m()},f=i.computed(()=>{const g=s.pagesCount();return g<8?S.H.Arrays.GenerateNumsRange(2,g-1).filter(p=>p<g&&p>1):S.H.Arrays.GenerateNumsRange(s.curPage-2,s.curPage+3).filter(p=>p<g&&p>1)}),m=()=>{const g=document.querySelector(".el-table__body-wrapper"),p=document.querySelector("#list");g?g.scrollTo({top:0}):p&&p.scrollTo({top:0})};return i.onBeforeUnmount(()=>{S.H.FTSP.Get().p.drop()}),(g,p)=>{const k=wn,w=Se,B=Mi,D=Bi,L=xi,V=bn;return i.openBlock(),i.createElementBlock("div",sm,[i.createElementVNode("div",{class:"pag-container",style:i.normalizeStyle({justifyContent:t.justifyContent})},[i.createElementVNode("div",am,[i.createVNode(w,{skin:"pag",type:o(i.unref(s).curPage===1),onClick:p[0]||(p[0]=T=>u(i.unref(s).curPage-1))},{default:i.withCtx(()=>[i.createVNode(k)]),_:1},8,["type"]),i.createElementVNode("ul",lm,[i.createElementVNode("li",null,[i.createVNode(w,{skin:"pag",type:r(i.unref(s).curPage===1),text:"1",onClick:p[1]||(p[1]=T=>u(1))},null,8,["type"])]),i.unref(s).pagesCount()>8&&i.unref(s).curPage>4?(i.openBlock(),i.createElementBlock("li",{key:0,onMouseenter:p[3]||(p[3]=T=>a.value=!0),onMouseleave:p[4]||(p[4]=T=>a.value=!1)},[i.createVNode(w,{skin:"pag",type:"neutral",onClick:p[2]||(p[2]=T=>u(i.unref(s).curPage-5))},{default:i.withCtx(()=>[i.unref(a)?(i.openBlock(),i.createBlock(B,{key:0})):(i.openBlock(),i.createBlock(D,{key:1}))]),_:1})],32)):i.createCommentVNode("",!0),(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(f),T=>(i.openBlock(),i.createElementBlock("li",{key:T},[i.createVNode(w,{skin:"pag",type:r(T===i.unref(s).curPage),text:T,onClick:be=>u(T)},null,8,["type","text","onClick"])]))),128)),i.unref(s).pagesCount()>=8&&i.unref(s).curPage<i.unref(s).pagesCount()-3?(i.openBlock(),i.createElementBlock("li",{key:1,onMouseenter:p[6]||(p[6]=T=>d.value=!0),onMouseleave:p[7]||(p[7]=T=>d.value=!1)},[i.createVNode(w,{skin:"pag",type:"neutral",onClick:p[5]||(p[5]=T=>u(i.unref(s).curPage+5))},{default:i.withCtx(()=>[i.unref(d)?(i.openBlock(),i.createBlock(L,{key:0})):(i.openBlock(),i.createBlock(D,{key:1}))]),_:1})],32)):i.createCommentVNode("",!0),i.unref(s).pagesCount()>1?(i.openBlock(),i.createElementBlock("li",cm,[i.createVNode(w,{skin:"pag",type:r(i.unref(s).pagesCount()===i.unref(s).curPage),text:i.unref(s).pagesCount(),onClick:p[8]||(p[8]=T=>u(i.unref(s).pagesCount()))},null,8,["type","text"])])):i.createCommentVNode("",!0)]),i.createVNode(w,{skin:"pag",type:o(i.unref(s).curPage===i.unref(s).pagesCount()),onClick:p[9]||(p[9]=T=>u(i.unref(s).curPage+1))},{default:i.withCtx(()=>[i.createVNode(V)]),_:1},8,["type"])])],4)])}}}),[["__scopeId","data-v-5aea8b91"]]),Zs=M(i.defineComponent({__name:"RemoteSearch",props:{keyValue:{type:String,default:""},modelValue:{type:String,default:""},storeModule:{type:String,default:""},placeholder:{type:String,default:"Начните вводить запрос"},showSuggestions:{type:Boolean,default:!0},maxWidth:{type:[Number,String],default:350},focus:{type:Boolean,default:!1}},emits:["select","load","input"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(n.modelValue),s=i.ref(),a=S.S.Search.SearchModel();i.watch(()=>n.focus,()=>{n.focus&&setTimeout(()=>{s.value.focus(),o.value=""},500)});const d=async h=>{if(h.length<2)return;s.value.activated=!0,a.searchObjects=[],a.query=h,a.key=n.keyValue;const f=a.searchGroups.find(m=>m.key===n.keyValue);return f&&(a.searchGroup=f),await S.S.Search.Search(a),a.searchObjects},c=async h=>{r("select",h),o.value=""},u=h=>{r("input",h),h.length===0&&r("input","")};return(h,f)=>{const m=Gi;return i.openBlock(),i.createBlock(m,{ref_key:"searchForm",ref:s,modelValue:i.unref(o),"onUpdate:modelValue":f[0]||(f[0]=g=>i.isRef(o)?o.value=g:null),"value-key":"label",style:{width:"100%","margin-right":"10px"},placeholder:t.placeholder,"search-func":d,"trigger-on-focus":t.showSuggestions,suggestions:i.unref(a).searchObjects,onSelect:c,onInput:u},{suffix:i.withCtx(()=>f[1]||(f[1]=[i.createElementVNode("i",{class:"el-icon-search"},null,-1)])),_:1},8,["modelValue","placeholder","trigger-on-focus","suggestions"])}}}),[["__scopeId","data-v-f236facf"]]),dm={class:"mainblock-body"},um={class:"mainblock-footer"},Js=M(i.defineComponent({__name:"ResearcheContainer",props:{background:{type:String,required:!1,default:"inherit"},padding:{type:String,required:!1,default:"0px 10px"}},setup(t){return(e,n)=>(i.openBlock(),i.createElementBlock("div",{class:"mainblock",style:i.normalizeStyle({background:t.background,padding:t.padding})},[i.createElementVNode("div",{class:"mainblock-header",style:i.normalizeStyle({background:t.background})},[i.renderSlot(e.$slots,"header",{},void 0,!0)],4),i.createElementVNode("div",dm,[i.renderSlot(e.$slots,"body",{},void 0,!0)]),i.createElementVNode("div",um,[i.renderSlot(e.$slots,"footer",{},void 0,!0)])],4))}}),[["__scopeId","data-v-a670fb4a"]]),hm={class:"right-slider-content"},fm={class:"right-slider-content-header"},mm={class:"right-slider-content-box"},pm={class:"right-slider-button"},Xs=M(i.defineComponent({__name:"RightSliderContainer",props:{sliderOffWidth:{type:String,required:!1,default:"30px"},sliderOnWidth:{type:String,required:!1,default:"260px"},background:{type:String,required:!1,default:"inherit"},toggle:{type:Boolean,default:!1},titleOpen:{type:String,required:!1,default:"Скрыть список исследований"},titleClose:{type:String,required:!1,default:"Показать список исследований"}},emits:["toggle"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(!1);i.watch(()=>n.toggle,()=>{o.value=!o.value});const s=a=>{o.value=!o.value,r("toggle",a)};return(a,d)=>{const c=me;return i.openBlock(),i.createElementBlock("div",{class:"right-slider",style:i.normalizeStyle({marginRight:i.unref(o)?`calc(${t.sliderOffWidth} - ${t.sliderOnWidth})`:"0",width:t.sliderOnWidth})},[i.createElementVNode("div",{class:"click-line",onClick:d[0]||(d[0]=u=>s(!i.unref(o)))},[i.unref(o)?(i.openBlock(),i.createBlock(c,{key:0,string:t.titleClose,"font-size":"16px",padding:"0",color:"#343E5C"},null,8,["string"])):i.createCommentVNode("",!0),i.unref(o)?i.createCommentVNode("",!0):(i.openBlock(),i.createBlock(c,{key:1,string:t.titleOpen,"font-size":"16px",padding:"0",color:"#343E5C"},null,8,["string"]))]),i.createElementVNode("div",hm,[i.createElementVNode("div",fm,[i.renderSlot(a.$slots,"header",{},void 0,!0)]),i.createElementVNode("div",mm,[i.renderSlot(a.$slots,"default",{},void 0,!0)])]),i.createElementVNode("div",pm,[i.renderSlot(a.$slots,"button",{},void 0,!0)])],4)}}}),[["__scopeId","data-v-495a90f9"]]),gm={class:"mainblock"},ym={class:"body-block"},wm={class:"tab-block"},Ys=M(i.defineComponent({__name:"RightTabsContainer",props:{sliderOffWidth:{type:String,required:!1,default:"101px"},sliderOnWidth:{type:String,required:!1,default:"332px"},background:{type:String,required:!1,default:"inherit"},isToggle:{type:Boolean,required:!1,default:!1},mobileWidth:{type:String,required:!1,default:"768px"}},emits:["toggle"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(!1),s=i.ref(window.matchMedia("(max-width: 768px)").matches),a=c=>{r("toggle",c)},d=i.ref(!1);return i.onBeforeMount(async()=>{window.addEventListener("resize",()=>{switch(n.mobileWidth){case"1330px":return s.value=window.matchMedia("(max-width: 1330px)").matches;case"1215px":return s.value=window.matchMedia("(max-width: 1215px)").matches;case"1024px":return s.value=window.matchMedia("(max-width: 1024px)").matches;case"768px":return s.value=window.matchMedia("(max-width: 768px)").matches}return s.value=window.matchMedia("(max-width: 1330px)").matches}),o.value=!0}),(c,u)=>(i.openBlock(),i.createElementBlock("div",gm,[i.createElementVNode("div",{class:"slider-block",style:i.normalizeStyle({marginRight:i.unref(s)?t.isToggle?"49px":`calc(49px - ${t.sliderOnWidth})`:t.isToggle?t.sliderOffWidth:`calc(${t.sliderOffWidth} - ${t.sliderOnWidth})`,width:t.sliderOnWidth,minHeight:t.sliderOffWidth,height:t.isToggle?"auto":"100px"})},[i.createElementVNode("div",{class:"slider-icon",style:i.normalizeStyle({border:t.isToggle?"1px solid #379FFF":"1px solid #00B5A4",background:t.isToggle?"#ffffff":"#C7ECEA"}),onClick:u[0]||(u[0]=h=>a(!t.isToggle)),onMouseenter:u[1]||(u[1]=h=>d.value=!0),onMouseleave:u[2]||(u[2]=h=>d.value=!1)},[i.createElementVNode("div",{class:"icon-block",style:i.normalizeStyle({transform:i.unref(d)?t.isToggle?"rotate(-225deg) scale(1.2, 1.2)":"rotate(0deg) scale(1.2, 1.2)":t.isToggle?"rotate(-225deg)":"rotate(0deg)",fill:t.isToggle?"#379FFF":"#00B5A4"})},[i.renderSlot(c.$slots,"icon",{},void 0,!0)],4)],36),i.createElementVNode("div",{class:"slider-info",style:i.normalizeStyle({width:`calc(${t.sliderOnWidth} - ${t.sliderOffWidth})`})},[i.renderSlot(c.$slots,"slider-body",{},void 0,!0)],4)],4),i.createElementVNode("div",ym,[i.renderSlot(c.$slots,"body",{},void 0,!0)]),i.createElementVNode("div",wm,[i.renderSlot(c.$slots,"tabs",{},void 0,!0)])]))}}),[["__scopeId","data-v-eaeca0cc"]]),bm=["label","value"],Qs=M(i.defineComponent({__name:"SelectValueType",props:{selectedType:{type:String,required:!0}},emits:["select"],setup(t,{emit:e}){const n={[de.String]:"Текстовый ответ",[de.Text]:"Развёрнутый текстовый ответ",[de.Number]:"Числовой ответ",[de.Date]:"Ответ в виде даты",[de.Radio]:"Выбор одного из вариантов",[de.Set]:"Выбор нескольких вариантов",[de.File]:"Ответ в виде файла",[de.MatrixRadio]:"Матрица с одним выбором",[de.MatrixSet]:"Матрица с несколькими выборами"},r=e,o=s=>{r("select",s)};return(s,a)=>{const d=me,c=it;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createVNode(d,{string:"Выберите вид ответа:","font-size":"14px",padding:"0","justify-content":"left",margin:"10px 0"}),i.createVNode(c,{"model-value":t.selectedType,placeholder:"Вид ответа",onChange:o},{default:i.withCtx(()=>[(i.openBlock(),i.createElementBlock(i.Fragment,null,i.renderList(n,(u,h)=>i.createElementVNode("option",{key:u,label:u,value:h},null,8,bm)),64))]),_:1},8,["model-value"])],64)}}}),[["__scopeId","data-v-6be05cd5"]]),Cm={class:"field"},Ks=M(i.defineComponent({__name:"SingleNameToggleForm",props:{withName:{type:Object,required:!0}},emits:["submit"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(!1),s=i.ref(),a=i.ref(n.withName.name),d=i.ref(!1),c=()=>{d.value=!1},u=async()=>{a.value.trim(),n.withName.setName&&n.withName.setName(a.value),o.value=!o.value,r("submit")};return(h,f)=>{const m=me,g=i.resolveComponent("el-input"),p=i.resolveComponent("el-form-item"),k=i.resolveComponent("el-form"),w=Se;return i.openBlock(),i.createBlock(k,{ref_key:"form",ref:s,style:{width:"100%"}},{default:i.withCtx(()=>[i.createVNode(rt,{title:"Название","show-save-dialog":d.value,icon:"edit-title","with-hover":!0,close:o.value,width:"100%",onKeyupEnter:u,onAfterClose:c},{"open-inside-content":i.withCtx(()=>[i.createVNode(rt,{title:"",icon:"edit-title","with-open-window":!1,"with-hover":!1,"border-color":"#ffffff","base-box-margin":"0 0 15px 0",padding:"0",width:"100%","custom-class":"test","open-width":"100%"},{default:i.withCtx(()=>[i.createElementVNode("div",Cm,[i.createVNode(k,null,{default:i.withCtx(()=>[i.createVNode(p,{style:{width:"100%"},prop:"surname"},{default:i.withCtx(()=>[i.createVNode(g,{modelValue:a.value,"onUpdate:modelValue":f[0]||(f[0]=B=>a.value=B),style:{width:"100%"},autosize:!0,type:"textarea"},null,8,["modelValue"])]),_:1})]),_:1})])]),_:1}),i.createVNode(w,{type:"admin",color:"blue",text:"Сохранить",onClick:u})]),default:i.withCtx(()=>[a.value.length?(i.openBlock(),i.createBlock(m,{key:0,string:a.value.length>60?a.value.slice(0,60)+"...":a.value},null,8,["string"])):(i.openBlock(),i.createBlock(m,{key:1,string:"Введите данные",color:"#B0A4C0"}))]),_:1},8,["show-save-dialog","close"])]),_:1},512)}}}),[["__scopeId","data-v-890163ac"]]),Sm=["label","value"],ea=M(i.defineComponent({__name:"SortList",props:{maxWidth:{type:[Number,String],default:250}},emits:["load"],setup(t,{emit:e}){const n=i.ref(!1),r=e,o=i.ref();i.onBeforeMount(()=>{n.value=!0,o.value=Pe.GetDefault(),S.H.FTSP.Get().setSortModel(o.value)});const s=async d=>{o.value=d??Pe.GetDefault(),S.H.FTSP.Get().setSortModel(o.value),S.H.FTSP.Get().p.drop(),r("load")},a=async d=>{S.H.FTSP.Get().p.drop(),await s(d)};return(d,c)=>{var h;const u=it;return i.unref(n)?(i.openBlock(),i.createBlock(u,{key:0,modelValue:i.unref(o),"onUpdate:modelValue":c[0]||(c[0]=f=>i.isRef(o)?o.value=f:null),"popper-append-to-body":!1,clearable:!((h=i.unref(o))!=null&&h.default),"value-key":"label",onChange:a,onClear:c[1]||(c[1]=f=>a())},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(Pe).Get(),(f,m)=>(i.openBlock(),i.createElementBlock("option",{key:m,label:f.label,value:f},null,8,Sm))),128))]),_:1},8,["modelValue","clearable"])):i.createCommentVNode("",!0)}}}),[["__scopeId","data-v-ef96d2ea"]]),km=["label","value"],ta=M(i.defineComponent({__name:"SortSelect",props:{maxWidth:{type:[Number,String],default:250}},emits:["load"],setup(t,{emit:e}){const n=e,r=i.ref();i.onBeforeMount(()=>{r.value=Pe.GetDefault()});const o=async a=>{a||(r.value=Pe.GetDefault()),S.H.FTSP.Get().setSortModel(r.value),S.H.FTSP.Get().p.drop(),n("load")},s=async a=>{await o(a)};return(a,d)=>{var u;const c=it;return i.openBlock(),i.createBlock(c,{modelValue:i.unref(r),"onUpdate:modelValue":d[0]||(d[0]=h=>i.isRef(r)?r.value=h:null),"popper-append-to-body":!1,clearable:!((u=i.unref(r))!=null&&u.default),"value-key":"label",onChange:s},{default:i.withCtx(()=>[(i.openBlock(!0),i.createElementBlock(i.Fragment,null,i.renderList(i.unref(Pe).Get(),(h,f)=>(i.openBlock(),i.createElementBlock("option",{key:f,label:h.label,value:h},null,8,km))),128))]),_:1},8,["modelValue","clearable"])}}}),[["__scopeId","data-v-8f7ad510"]]),Em={class:"switch-container"},vm={class:"line"},Mm={class:"line"},na=M(i.defineComponent({__name:"Switch3Pos",props:{firstModel:{type:Object,required:!0},secondModel:{type:Object,required:!0},defaultLabel:{type:String,default:"Все"}},emits:["load"],setup(t,{emit:e}){const n=t,r={background:"inherit",border:"1px solid #c4c4c4"},o=()=>n.firstModel.valueEq(u.value)?void 0:r,s=()=>u.value?r:void 0,a=()=>n.secondModel.valueEq(u.value)?void 0:r,d=f=>{var g;return{color:(g=u.value)!=null&&g.valueEq(f)?"#006bb4":"#B0A4C0"}},c=e,u=i.ref(void 0),h=async f=>{var m;(m=u.value)!=null&&m.valueEq(f)||(S.H.FTSP.Get().replaceF(f,u.value),u.value=f,c("load"))};return(f,m)=>{const g=me;return i.openBlock(),i.createElementBlock("div",Em,[i.createElementVNode("div",vm,[i.createVNode(g,{string:t.firstModel.label,"font-size":"12px",padding:"0",style:i.normalizeStyle(d(t.firstModel)),onClick:m[0]||(m[0]=p=>h(t.firstModel))},null,8,["string","style"]),i.createVNode(g,{string:"Все","font-size":"12px",padding:"0",style:i.normalizeStyle(d()),onClick:m[1]||(m[1]=p=>h())},null,8,["style"]),i.createVNode(g,{string:t.secondModel.label,"font-size":"12px",padding:"0",style:i.normalizeStyle(d(t.secondModel)),onClick:m[2]||(m[2]=p=>h(t.secondModel))},null,8,["string","style"])]),i.createElementVNode("div",Mm,[i.createElementVNode("div",{class:i.normalizeClass(["switch-knob1",{active:t.firstModel.valueEq(i.unref(u))}]),style:i.normalizeStyle(o()),onClick:m[3]||(m[3]=p=>h(t.firstModel))},null,6),i.createElementVNode("div",{class:i.normalizeClass(["switch-knob2",{active:!i.unref(u)}]),style:i.normalizeStyle(s()),onClick:m[4]||(m[4]=p=>h())},null,6),i.createElementVNode("div",{class:i.normalizeClass(["switch-knob3",{active:t.secondModel.valueEq(i.unref(u))}]),style:i.normalizeStyle(a()),onClick:m[5]||(m[5]=p=>h(t.secondModel))},null,6),m[6]||(m[6]=i.createElementVNode("div",{class:"switch-axis"},null,-1)),m[7]||(m[7]=i.createElementVNode("div",{class:"switch-axis-dash1"},null,-1)),m[8]||(m[8]=i.createElementVNode("div",{class:"switch-axis-dash2"},null,-1)),m[9]||(m[9]=i.createElementVNode("div",{class:"switch-axis-dash3"},null,-1))])])}}}),[["__scopeId","data-v-5dcc4d3d"]]),xm={},Bm={class:"flex"};function Im(t,e){return i.openBlock(),i.createElementBlock("div",Bm,[i.renderSlot(t.$slots,"default",{},void 0,!0)])}const ia=M(xm,[["render",Im],["__scopeId","data-v-4d1abb74"]]),ra=M(i.defineComponent({__name:"ToggleInfoItem",props:{title:{type:String,required:!0},content:{type:String,required:!0}},emits:["submit"],setup(t,{emit:e}){const n=i.ref(!1),r=e,o=async()=>{r("submit"),n.value=!n.value};return(s,a)=>{const d=me,c=Se,u=Dt,h=rt;return i.openBlock(),i.createBlock(h,{title:t.title,icon:"edit-title","with-hover":!0,close:i.unref(n),width:"100%",onKeyupEnter:o},{"open-inside-content":i.withCtx(()=>[i.createVNode(u,{"custom-class":"grid"},{default:i.withCtx(()=>[i.renderSlot(s.$slots,"default",{},void 0,!0),i.createVNode(c,{type:"admin",color:"blue",text:"Сохранить",onClick:o})]),_:3})]),default:i.withCtx(()=>[t.content.length>0?(i.openBlock(),i.createBlock(d,{key:0,string:t.content},null,8,["string"])):(i.openBlock(),i.createBlock(d,{key:1,string:"Введите данные",color:"#B0A4C0"}))]),_:3},8,["title","close"])}}}),[["__scopeId","data-v-994f6522"]]),Rm={class:"top-slider-content"},$m={class:"center"},oa=M(i.defineComponent({__name:"TopSliderContainer",props:{sliderOffHeight:{type:String,required:!1,default:"53px"},sliderOnHeight:{type:String,required:!1,default:"220px"},background:{type:String,required:!1,default:"inherit"},toggle:{type:Boolean,default:!1}},emits:["toggle"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(!0);i.watch(()=>n.toggle,()=>{o.value=!o.value});const s=a=>{o.value=!o.value,r("toggle",a)};return(a,d)=>(i.openBlock(),i.createElementBlock(i.Fragment,null,[i.unref(o)?i.createCommentVNode("",!0):(i.openBlock(),i.createElementBlock("div",{key:0,class:"blur",onClick:[d[0]||(d[0]=i.withModifiers(c=>o.value=!0,["prevent"])),d[1]||(d[1]=i.withModifiers(()=>{},["stop"]))]})),i.createElementVNode("div",{class:"top-slider",style:i.normalizeStyle({marginTop:i.unref(o)?`calc(${t.sliderOffHeight} - ${t.sliderOnHeight})`:"0",height:t.sliderOnHeight}),onClick:d[3]||(d[3]=i.withModifiers(()=>{},["stop"]))},[i.createElementVNode("div",Rm,[i.createElementVNode("div",$m,[i.renderSlot(a.$slots,"default",{},void 0,!0)])]),i.createElementVNode("div",{class:"click-line",style:i.normalizeStyle({height:t.sliderOffHeight}),onClick:d[2]||(d[2]=c=>s(!i.unref(o)))},[i.renderSlot(a.$slots,"title",{},void 0,!0)],4)],4)],64))}}),[["__scopeId","data-v-fec4dfde"]]),Nm={id:"drop-area",class:"img-container"},Am={key:0},Pm=["src"],Tm={class:"tools-button"},zm={class:"ins"},Vm={key:1},Fm=["id"],sa=M(i.defineComponent({__name:"UploaderImage",props:{withCrop:{type:Boolean,default:!0},fileInfo:{type:ye,required:!0},height:{type:Number,default:150},width:{type:Number,default:150},cropRatio:{type:Boolean,default:!0},emitCrop:{type:Boolean,default:!1},defaultRatio:{type:Number,required:!1,default:1}},emits:["crop","removeFile"],setup(t,{emit:e}){const n=t,r=e,o=i.ref(void 0),s=S.H.Strings.CreateGuid(),a=i.ref(!1),d=i.ref(),c=w=>{const B=n.cropRatio?n.defaultRatio:0;S.S.Cropper.Open(hn.CreateCropper(w.url,B,n.fileInfo.id)),a.value=!0},u=()=>{S.Dialog.Show({text:"Вы хотите удалить изображение",confirmButtonText:"Удалить",cancelButtonText:"Не удалять"}).then(()=>{o.value=void 0,d.value.clearFiles(),r("removeFile")})},h=w=>{n.fileInfo.setFile(w),n.fileInfo.fileSystemPath&&(o.value=n.fileInfo),a.value=!1,r("crop")};i.onBeforeMount(()=>{n.fileInfo.fileSystemPath&&(o.value=n.fileInfo,o.value.url=n.fileInfo.getFileUrl())});let f=null;i.onMounted(()=>{const w=document.getElementById("drop-area");w&&(w.addEventListener("dragover",B=>{m(B),w.classList.add("drag-over")}),w.addEventListener("dragleave",B=>{m(B),w.classList.remove("drag-over")}),w.addEventListener("dragenter",m),w.addEventListener("dragleave",m),w.addEventListener("drop",p),f=document.getElementById(s))});function m(w){w.preventDefault(),w.stopPropagation()}const g=()=>{f&&f.click()};function p(w){if(w.preventDefault(),!w.dataTransfer)return;const B=w.dataTransfer.files;B.length&&f&&(f.files=B,k())}const k=()=>{if(!f||!f.files||!f.files.length)return;const w=f.files[0];w.url=URL.createObjectURL(w),o.value=w,n.fileInfo.uploadNewFile(w),c(o.value)};return(w,B)=>{const D=Se,L=Ui;return i.openBlock(),i.createElementBlock(i.Fragment,null,[i.createElementVNode("div",Nm,[i.unref(o)?(i.openBlock(),i.createElementBlock("div",Am,[i.createElementVNode("div",{class:"img-block",style:i.normalizeStyle({width:t.height*t.defaultRatio-2+"px",height:t.height+"px"})},[i.createElementVNode("img",{class:"el-upload-list__item-thumbnail",src:i.unref(o).url,alt:"upload-image"},null,8,Pm)],4),i.createElementVNode("div",Tm,[i.createElementVNode("div",zm,[i.createVNode(D,{skin:"text",text:"Изменить","font-size":"20px",width:"300px",margin:"100px 0 0 0",onClick:B[0]||(B[0]=V=>c(i.unref(o)))}),i.createVNode(D,{skin:"text",text:"Удалить","font-size":"20px",width:"300px",margin:"50px 0 0 0",onClick:B[1]||(B[1]=V=>u())})])])])):(i.openBlock(),i.createElementBlock("div",Vm,[i.createElementVNode("div",{class:"add-button",style:i.normalizeStyle({width:t.height*t.defaultRatio-2+"px",height:t.height+"px"})},[i.createVNode(D,{skin:"text",text:"Добавить","font-size":"20px",onClick:g})],4)]))]),i.createElementVNode("input",{id:i.unref(s),type:"file",hidden:"",onChange:k},null,40,Fm),t.withCrop?(i.openBlock(),i.createBlock(L,{key:0,open:i.unref(a),"default-ratio":t.defaultRatio,onCrop:h,onClose:B[2]||(B[2]=V=>a.value=!1)},null,8,["open","default-ratio"])):i.createCommentVNode("",!0)],64)}}}),[["__scopeId","data-v-4b143fdb"]]),Dm=["Orders"],Lm={install:function(t){t.component("PButton",Se),t.component("PCheckBox",Ci),t.component("PDatePicker",Po),t.component("PFlex",Si),t.component("PInput",ut),t.component("PInputDate",ki),t.component("PInputNumber",To),t.component("PLeftSlider",zo),t.component("PList",Vo),t.component("PListItem",Fo),t.component("PRadio",Do),t.component("PRightSlider",Lo),t.component("PSelect",it),t.component("PSticky",yn),t.component("PString",me),t.component("PTextarea",Oo),t.component("PTopSlider",Ho),t.component("IconDownload",Ko),t.component("IconFilter",es),t.component("ArrowLeft",wn),t.component("ArrowRight",bn),t.component("DoubleArrowLeft",Mi),t.component("DoubleArrowRight",xi),t.component("EllipsisSvg",Bi),t.component("IconArrowLeft",ts),t.component("IconCheckDefault",bi),t.component("IconClose",Vt),t.component("IconEdit",ns),t.component("IconEmail",is),t.component("IconMove",rs),t.component("IconPhone",os),t.component("IconSearch",vi),t.component("IconSelectArrow",Ei),t.component("CollapseContainer",zs),t.component("CollapseItem",Vs),t.component("VerticalCollapseContainer",Fs),t.component("PAdd",Ds),t.component("PContainer",Wi),t.component("PContainerStickyHead",Ls),t.component("PDel",Os),t.component("PTabs",Hs),t.component("UploaderFile",_s),t.component("AuthForm",dn),t.component("PModal",Ft),t.component("AuthPage",ui),t.component("PageNotFound",hi),t.component("AdaptiveContainer",Qi),t.component("AdaptiveContainerHorizontal",Ki),t.component("AdminGallery",Ao),t.component("AuthModal",_o),t.component("CarouselImages",qo),t.component("ContextWindow",Uo),t.component("DateInputRangeV2",Go),t.component("DateInputRange",Wo),t.component("DropList",jo),t.component("FilterCheckbox",Zo),t.component("FiltersButtonsSelect",Jo),t.component("FilterSelect",Xo),t.component("FTSPPanel",Yo),t.component("GeneralItem",Qo),t.component("GridContainer",Dt),t.component("ImageCropper",Ui),t.component("InfoItem",rt),t.component("InfoItemSelectButtons",Ps),t.component("LeftRightContainer",Ts),t.component("MessageBody",Rn),t.component("PAutocomplete",Gi),t.component("PDialog",qs),t.component("PhoneForm",Us),t.component("PLoader",Ws),t.component("PNotification",Gs),t.component("PPagination",js),t.component("RemoteSearch",Zs),t.component("ResearcheContainer",Js),t.component("RightSliderContainer",Xs),t.component("RightTabsContainer",Ys),t.component("SelectValueType",Qs),t.component("SingleNameToggleForm",Ks),t.component("SortList",ea),t.component("SortSelect",ta),t.component("Switch3Pos",na),t.component("ThemeWrapper",ia),t.component("ToggleInfoItem",ra),t.component("TopSliderContainer",oa),t.component("UploaderImage",sa)}},Om=["PF","PFM"];v.AdaptiveContainer=Qi,v.AdaptiveContainerHorizontal=Ki,v.AdminGallery=Ao,v.ArrowLeft=wn,v.ArrowRight=bn,v.AuthForm=dn,v.AuthModal=_o,v.AuthPage=ui,v.CarouselImages=qo,v.CollapseContainer=zs,v.CollapseItem=Vs,v.ContextWindow=Uo,v.DateInputRange=Wo,v.DateInputRange_v2=Go,v.DoubleArrowLeft=Mi,v.DoubleArrowRight=xi,v.DropList=jo,v.EllipsisSvg=Bi,v.FTSPPanel=Yo,v.FilterCheckbox=Zo,v.FilterSelect=Xo,v.FiltersButtonsSelect=Jo,v.GeneralItem=Qo,v.GridContainer=Dt,v.IconArrowLeft=ts,v.IconCheckDefault=bi,v.IconClose=Vt,v.IconDownload=Ko,v.IconEdit=ns,v.IconEmail=is,v.IconFilter=es,v.IconMove=rs,v.IconPhone=os,v.IconSearch=vi,v.IconSelectArrow=Ei,v.ImageCropper=Ui,v.InfoItem=rt,v.InfoItemSelectButtons=Ps,v.LeftRightContainer=Ts,v.MessageBody=Rn,v.Orders=Ae,v.PAdd=Ds,v.PAutocomplete=Gi,v.PButton=Se,v.PCheckBox=Ci,v.PContainer=Wi,v.PContainerStickyHead=Ls,v.PDatePicker=Po,v.PDel=Os,v.PDialog=qs,v.PFM=th,v.PFlex=Si,v.PInput=ut,v.PInputDate=ki,v.PInputNumber=To,v.PLeftSlider=zo,v.PList=Vo,v.PListItem=Fo,v.PLoader=Ws,v.PModal=Ft,v.PNotification=Gs,v.PPagination=js,v.PRadio=Do,v.PRightSlider=Lo,v.PSelect=it,v.PSticky=yn,v.PString=me,v.PTabs=Hs,v.PTextarea=Oo,v.PTopSlider=Ho,v.PageNotFound=hi,v.PhoneForm=Us,v.RemoteSearch=Zs,v.ResearcheContainer=Js,v.RightSliderContainer=Xs,v.RightTabsContainer=Ys,v.SelectValueType=Qs,v.SingleNameToggleForm=Ks,v.SortList=ea,v.SortSelect=ta,v.Switch3Pos=na,v.ThemeWrapper=ia,v.ToggleInfoItem=ra,v.TopSliderContainer=oa,v.UploaderFile=_s,v.UploaderImage=sa,v.VerticalCollapseContainer=Fs,v.pfName=Om,v.servicesComponents=Lm,v.typesNames=Dm,Object.defineProperty(v,Symbol.toStringTag,{value:"Module"})});