@prefabs.tech/vue3-layout 0.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +145 -0
- package/dist/NavMenuItem-BPQBXe7I.js +4 -0
- package/dist/PrefabsTechVue3Layout.es.js +19 -0
- package/dist/PrefabsTechVue3Layout.umd.js +1 -0
- package/dist/index-F-mM76Og.js +1890 -0
- package/dist/src/Layout.vue.d.ts +22 -0
- package/dist/src/Layout.vue.d.ts.map +1 -0
- package/dist/src/components/AppFooter.vue.d.ts +12 -0
- package/dist/src/components/AppFooter.vue.d.ts.map +1 -0
- package/dist/src/components/AppHeader.vue.d.ts +31 -0
- package/dist/src/components/AppHeader.vue.d.ts.map +1 -0
- package/dist/src/components/Copyright.vue.d.ts +26 -0
- package/dist/src/components/Copyright.vue.d.ts.map +1 -0
- package/dist/src/components/Logo.vue.d.ts +41 -0
- package/dist/src/components/Logo.vue.d.ts.map +1 -0
- package/dist/src/components/MainMenu.vue.d.ts +24 -0
- package/dist/src/components/MainMenu.vue.d.ts.map +1 -0
- package/dist/src/components/NavMenu.vue.d.ts +25 -0
- package/dist/src/components/NavMenu.vue.d.ts.map +1 -0
- package/dist/src/components/NavMenuItem.vue.d.ts +25 -0
- package/dist/src/components/NavMenuItem.vue.d.ts.map +1 -0
- package/dist/src/components/Sidebar.vue.d.ts +39 -0
- package/dist/src/components/Sidebar.vue.d.ts.map +1 -0
- package/dist/src/components/StickyCollapsibleFooter.vue.d.ts +22 -0
- package/dist/src/components/StickyCollapsibleFooter.vue.d.ts.map +1 -0
- package/dist/src/index.d.ts +44 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/layouts/BasicLayout.vue.d.ts +26 -0
- package/dist/src/layouts/BasicLayout.vue.d.ts.map +1 -0
- package/dist/src/layouts/NullLayout.vue.d.ts +3 -0
- package/dist/src/layouts/NullLayout.vue.d.ts.map +1 -0
- package/dist/src/layouts/SidebarHeaderLayout.vue.d.ts +52 -0
- package/dist/src/layouts/SidebarHeaderLayout.vue.d.ts.map +1 -0
- package/dist/src/layouts/SidebarOnlyLayout.vue.d.ts +39 -0
- package/dist/src/layouts/SidebarOnlyLayout.vue.d.ts.map +1 -0
- package/dist/src/types/config.d.ts +16 -0
- package/dist/src/types/config.d.ts.map +1 -0
- package/dist/src/types/index.d.ts +4 -0
- package/dist/src/types/index.d.ts.map +1 -0
- package/dist/src/types/layout.d.ts +3 -0
- package/dist/src/types/layout.d.ts.map +1 -0
- package/dist/src/types/menu.d.ts +18 -0
- package/dist/src/types/menu.d.ts.map +1 -0
- package/dist/vue3-layout.css +1 -0
- package/package.json +74 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2017 Olivier Pichon
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
# Prefabs Tech Vue3 Layout Plugin
|
|
2
|
+
|
|
3
|
+
## Requirements
|
|
4
|
+
|
|
5
|
+
* `@prefabs.tech/vue3-config: >= 0.6.5`
|
|
6
|
+
* `vue: >= 3.2`
|
|
7
|
+
* `vue-router: >= 4.0`
|
|
8
|
+
|
|
9
|
+
## Installation
|
|
10
|
+
|
|
11
|
+
### npm
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
npm install @prefabs.tech/vue3-layout @prefabs.tech/vue3-config`
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
### yarn
|
|
18
|
+
|
|
19
|
+
```bash
|
|
20
|
+
yarn add @prefabs.tech/vue3-layout @prefabs.tech/vue3-config
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
### PNPM
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
pnpm add @prefabs.tech/vue3-layout @prefabs.tech/vue3-config
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## Usage
|
|
30
|
+
|
|
31
|
+
### main.ts
|
|
32
|
+
|
|
33
|
+
Import and register the plugin in `main.ts`.
|
|
34
|
+
|
|
35
|
+
```ts
|
|
36
|
+
import layoutPlugin from "@prefabs.tech/vue3-layout";
|
|
37
|
+
import "@prefabs.tech/vue3-layout/dist/PrefabsTechVue3Layout.css";
|
|
38
|
+
|
|
39
|
+
app.use(layoutPlugin);
|
|
40
|
+
|
|
41
|
+
...
|
|
42
|
+
|
|
43
|
+
app.mount("#app");
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
### App.vue
|
|
47
|
+
|
|
48
|
+
* Wrap your router view in the `Layout` component.
|
|
49
|
+
* Optionnally, set a default layout. You can use one of our built-in layouts, or create your own. The default layout will be applied to all routes for which no layout is set.
|
|
50
|
+
|
|
51
|
+
```vue
|
|
52
|
+
<template>
|
|
53
|
+
<Layout :default-layout="defaultLayout">
|
|
54
|
+
<router-view />
|
|
55
|
+
</Layout>
|
|
56
|
+
<notifications />
|
|
57
|
+
</template>
|
|
58
|
+
|
|
59
|
+
<script setup lang="ts">
|
|
60
|
+
import { BasicLayout } from "@prefabs.tech/vue3-layout";
|
|
61
|
+
import { computed } from "vue";
|
|
62
|
+
|
|
63
|
+
const defaultLayout = computed(() => {
|
|
64
|
+
return BasicLayout;
|
|
65
|
+
});
|
|
66
|
+
</script>
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
### Set the layout for an individual route
|
|
70
|
+
|
|
71
|
+
The default layout set as the `default-layout` prop on the `Layout` component will apply by default to all routes, except those for which an explicit route is declared.
|
|
72
|
+
|
|
73
|
+
You can also customize the layout for individual routes by adding a `meta.layout` attribute to the route. The value of the attribute is the layout component you wish to use.
|
|
74
|
+
|
|
75
|
+
```ts
|
|
76
|
+
import { createRouter, createWebHistory } from "vue-router";
|
|
77
|
+
|
|
78
|
+
import CustomLayout from "@/layouts/CustomLayout.vue";
|
|
79
|
+
import Home from "@/views/Home.vue";
|
|
80
|
+
import ViewWithCustomLayout from "@/views/ViewWithCustomLayout.vue";
|
|
81
|
+
|
|
82
|
+
import type { RouteMeta, Router, RouterOptions } from "vue-router";
|
|
83
|
+
|
|
84
|
+
const router: Router = createRouter({
|
|
85
|
+
history: createWebHistory(import.meta.env.BASE_URL),
|
|
86
|
+
routes: [
|
|
87
|
+
{
|
|
88
|
+
component: HomeView,
|
|
89
|
+
name: "home",
|
|
90
|
+
path: "/",
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
component: AboutView,
|
|
94
|
+
meta: {
|
|
95
|
+
layout: CustomLayout,
|
|
96
|
+
},
|
|
97
|
+
name: "custom",
|
|
98
|
+
path: "/custom",
|
|
99
|
+
},
|
|
100
|
+
],
|
|
101
|
+
} as RouterOptions);
|
|
102
|
+
|
|
103
|
+
export default router;
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
## Configuration
|
|
107
|
+
|
|
108
|
+
| Name | Type | Description | Default value |
|
|
109
|
+
|------|------|-------------|---------------|
|
|
110
|
+
| `homeRoute` | `string` | The name of the "home" route, ie the route that points to your app's home page | `home` |
|
|
111
|
+
| `logo` `string` | The path to the logo | `/logo.png` |
|
|
112
|
+
| `mainMenu` | `{ name: string; route: string; }[]` | An array of items to display in the app header's main menu | none |
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
## CSS Variables
|
|
116
|
+
|
|
117
|
+
### Basic layout
|
|
118
|
+
|
|
119
|
+
| Name | Description | Default value |
|
|
120
|
+
|-------|------------|---------------|
|
|
121
|
+
| `layout-basic-gap` | Size of basic layout flex-box gap | `1rem` |
|
|
122
|
+
| `layout-basic-max-width` | Maximum width of header, main and footer elements | `1200px` |
|
|
123
|
+
| `layout-basic-padding-left` | Left padding for header, main and footer elements | `0.8rem` |
|
|
124
|
+
| `layout-basic-padding-right` | Right padding for header, main and footer elements | `0.8rem` |
|
|
125
|
+
|
|
126
|
+
### AppHeader
|
|
127
|
+
|
|
128
|
+
| Name | Description | Default value |
|
|
129
|
+
|-------|------------|---------------|
|
|
130
|
+
| `header-bg-color` | Color of header background | `transparent` |
|
|
131
|
+
| `header-border-color` | Color of header (bottom) border | `#4169e1` |
|
|
132
|
+
| `header-font-size` | Font size of header text | `1rem` |
|
|
133
|
+
| `header-padding-bottom` | Bottom padding for header | `0.8rem` |
|
|
134
|
+
| `header-padding-top` | Top padding for header | `0.8rem` |
|
|
135
|
+
|
|
136
|
+
### App footer
|
|
137
|
+
|
|
138
|
+
| Name | Description | Default value |
|
|
139
|
+
|-------|------------|---------------|
|
|
140
|
+
| `footer-bg-color` | Color of footer background | `transparent` |
|
|
141
|
+
| `footer-border-color` | Color of footer (top) border | `#4169e1` |
|
|
142
|
+
| `footer-font-size` | Font size of footer text | `1rem` |
|
|
143
|
+
| `footer-gap` | Size of footer flex-box gap | `0.5rem` |
|
|
144
|
+
| `footer-padding-bottom` | Bottom padding for footer | `0.8rem` |
|
|
145
|
+
| `footer-padding-top` | Top padding for footer | `0.8rem` |
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { a as t, b as r, c as i, d as p, e as u, f as l, g as y, N as d, h as L, i as b, j as n, k as S, p as c, u as f } from "./index-F-mM76Og.js";
|
|
2
|
+
import "@prefabs.tech/vue3-i18n";
|
|
3
|
+
import "vue";
|
|
4
|
+
export {
|
|
5
|
+
t as AppFooter,
|
|
6
|
+
r as AppHeader,
|
|
7
|
+
i as BasicLayout,
|
|
8
|
+
p as Copyright,
|
|
9
|
+
u as Layout,
|
|
10
|
+
l as Logo,
|
|
11
|
+
y as MainMenu,
|
|
12
|
+
d as NullLayout,
|
|
13
|
+
L as Sidebar,
|
|
14
|
+
b as SidebarHeaderLayout,
|
|
15
|
+
n as SidebarOnlyLayout,
|
|
16
|
+
S as StickyCollapsibleFooter,
|
|
17
|
+
c as default,
|
|
18
|
+
f as useTranslations
|
|
19
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(function(m,_){typeof exports=="object"&&typeof module<"u"?_(exports,require("@prefabs.tech/vue3-i18n"),require("vue"),require("@prefabs.tech/vue3-config"),require("@vueuse/core"),require("@prefabs.tech/vue3-ui"),require("vue-router")):typeof define=="function"&&define.amd?define(["exports","@prefabs.tech/vue3-i18n","vue","@prefabs.tech/vue3-config","@vueuse/core","@prefabs.tech/vue3-ui","vue-router"],_):(m=typeof globalThis<"u"?globalThis:m||self,_((m["@prefabs"]=m["@prefabs"]||{},m["@prefabs"]["tech/vue3-layout"]={}),m.PrefabsTechVue3I18n,m.Vue,m.PrefabsTechVue3Config,m.VueuseCore,m.PrefabsTechVue3UI,m.VueRouter))})(this,function(m,_,t,z,je,Pe,x){"use strict";const Oe={class:"copyright"},Fe=["href"],Re={name:"Copyright"},ne=t.defineComponent({...Re,props:{holder:{required:!0,type:String},showDisclaimer:Boolean,url:{required:!0,type:String}},setup(e){const n=e,r=Te(),{t:s}=_.useI18n({messages:r}),o=t.computed(()=>n.showDisclaimer?s("copyright.disclaimer"):null),i=new Date().getFullYear();return(l,c)=>(t.openBlock(),t.createElementBlock("div",Oe,[t.createTextVNode(" © "+t.toDisplayString(t.unref(i))+" ",1),t.createElementVNode("a",{href:e.url,target:"_blank"},t.toDisplayString(e.holder),9,Fe),t.createTextVNode(" "+t.toDisplayString(o.value),1)]))}}),De={class:"version"},ze={name:"AppFooter"},A=t.defineComponent({...ze,setup(e){const n=z.useConfig();return(r,s)=>(t.openBlock(),t.createElementBlock("footer",null,[t.renderSlot(r.$slots,"copyright",{},()=>[t.unref(n)?.copyright?(t.openBlock(),t.createBlock(ne,{key:0,holder:t.unref(n).copyright.holder,url:t.unref(n).copyright.url},null,8,["holder","url"])):t.createCommentVNode("",!0)]),t.renderSlot(r.$slots,"social"),t.renderSlot(r.$slots,"version",{},()=>[t.createElementVNode("div",De,t.toDisplayString(t.unref(n).appVersion),1)])]))}}),oe=/^[a-z0-9]+(-[a-z0-9]+)*$/,T=(e,n,r,s="")=>{const o=e.split(":");if(e.slice(0,1)==="@"){if(o.length<2||o.length>3)return null;s=o.shift().slice(1)}if(o.length>3||!o.length)return null;if(o.length>1){const c=o.pop(),a=o.pop(),d={provider:o.length>0?o[0]:s,prefix:a,name:c};return n&&!j(d)?null:d}const i=o[0],l=i.split("-");if(l.length>1){const c={provider:s,prefix:l.shift(),name:l.join("-")};return n&&!j(c)?null:c}if(r&&s===""){const c={provider:s,prefix:"",name:i};return n&&!j(c,r)?null:c}return null},j=(e,n)=>e?!!((n&&e.prefix===""||e.prefix)&&e.name):!1,re=Object.freeze({left:0,top:0,width:16,height:16}),P=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),O=Object.freeze({...re,...P}),q=Object.freeze({...O,body:"",hidden:!1});function qe(e,n){const r={};!e.hFlip!=!n.hFlip&&(r.hFlip=!0),!e.vFlip!=!n.vFlip&&(r.vFlip=!0);const s=((e.rotate||0)+(n.rotate||0))%4;return s&&(r.rotate=s),r}function se(e,n){const r=qe(e,n);for(const s in q)s in P?s in e&&!(s in r)&&(r[s]=P[s]):s in n?r[s]=n[s]:s in e&&(r[s]=e[s]);return r}function He(e,n){const r=e.icons,s=e.aliases||Object.create(null),o=Object.create(null);function i(l){if(r[l])return o[l]=[];if(!(l in o)){o[l]=null;const c=s[l]&&s[l].parent,a=c&&i(c);a&&(o[l]=[c].concat(a))}return o[l]}return Object.keys(r).concat(Object.keys(s)).forEach(i),o}function Ue(e,n,r){const s=e.icons,o=e.aliases||Object.create(null);let i={};function l(c){i=se(s[c]||o[c],i)}return l(n),r.forEach(l),se(e,i)}function ie(e,n){const r=[];if(typeof e!="object"||typeof e.icons!="object")return r;e.not_found instanceof Array&&e.not_found.forEach(o=>{n(o,null),r.push(o)});const s=He(e);for(const o in s){const i=s[o];i&&(n(o,Ue(e,o,i)),r.push(o))}return r}const Qe={provider:"",aliases:{},not_found:{},...re};function H(e,n){for(const r in n)if(r in e&&typeof e[r]!=typeof n[r])return!1;return!0}function le(e){if(typeof e!="object"||e===null)return null;const n=e;if(typeof n.prefix!="string"||!e.icons||typeof e.icons!="object"||!H(e,Qe))return null;const r=n.icons;for(const o in r){const i=r[o];if(!o||typeof i.body!="string"||!H(i,q))return null}const s=n.aliases||Object.create(null);for(const o in s){const i=s[o],l=i.parent;if(!o||typeof l!="string"||!r[l]&&!s[l]||!H(i,q))return null}return n}const ce=Object.create(null);function Ge(e,n){return{provider:e,prefix:n,icons:Object.create(null),missing:new Set}}function N(e,n){const r=ce[e]||(ce[e]=Object.create(null));return r[n]||(r[n]=Ge(e,n))}function ae(e,n){return le(n)?ie(n,(r,s)=>{s?e.icons[r]=s:e.missing.add(r)}):[]}function We(e,n,r){try{if(typeof r.body=="string")return e.icons[n]={...r},!0}catch{}return!1}let E=!1;function de(e){return typeof e=="boolean"&&(E=e),E}function Ze(e){const n=typeof e=="string"?T(e,!0,E):e;if(n){const r=N(n.provider,n.prefix),s=n.name;return r.icons[s]||(r.missing.has(s)?null:void 0)}}function Ke(e,n){const r=T(e,!0,E);if(!r)return!1;const s=N(r.provider,r.prefix);return n?We(s,r.name,n):(s.missing.add(r.name),!0)}function Ye(e,n){if(typeof e!="object")return!1;if(typeof n!="string"&&(n=e.provider||""),E&&!n&&!e.prefix){let o=!1;return le(e)&&(e.prefix="",ie(e,(i,l)=>{Ke(i,l)&&(o=!0)})),o}const r=e.prefix;if(!j({prefix:r,name:"a"}))return!1;const s=N(n,r);return!!ae(s,e)}const fe=Object.freeze({width:null,height:null}),ue=Object.freeze({...fe,...P}),Je=/(-?[0-9.]*[0-9]+[0-9.]*)/g,Xe=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function he(e,n,r){if(n===1)return e;if(r=r||100,typeof e=="number")return Math.ceil(e*n*r)/r;if(typeof e!="string")return e;const s=e.split(Je);if(s===null||!s.length)return e;const o=[];let i=s.shift(),l=Xe.test(i);for(;;){if(l){const c=parseFloat(i);isNaN(c)?o.push(i):o.push(Math.ceil(c*n*r)/r)}else o.push(i);if(i=s.shift(),i===void 0)return o.join("");l=!l}}function ve(e,n="defs"){let r="";const s=e.indexOf("<"+n);for(;s>=0;){const o=e.indexOf(">",s),i=e.indexOf("</"+n);if(o===-1||i===-1)break;const l=e.indexOf(">",i);if(l===-1)break;r+=e.slice(o+1,i).trim(),e=e.slice(0,s).trim()+e.slice(l+1)}return{defs:r,content:e}}function et(e,n){return e?"<defs>"+e+"</defs>"+n:n}function tt(e,n,r){const s=ve(e);return et(s.defs,n+s.content+r)}const nt=e=>e==="unset"||e==="undefined"||e==="none";function ot(e,n){const r={...O,...e},s={...ue,...n},o={left:r.left,top:r.top,width:r.width,height:r.height};let i=r.body;[r,s].forEach(k=>{const u=[],L=k.hFlip,$=k.vFlip;let C=k.rotate;L?$?C+=2:(u.push("translate("+(o.width+o.left).toString()+" "+(0-o.top).toString()+")"),u.push("scale(-1 1)"),o.top=o.left=0):$&&(u.push("translate("+(0-o.left).toString()+" "+(o.height+o.top).toString()+")"),u.push("scale(1 -1)"),o.top=o.left=0);let b;switch(C<0&&(C-=Math.floor(C/4)*4),C=C%4,C){case 1:b=o.height/2+o.top,u.unshift("rotate(90 "+b.toString()+" "+b.toString()+")");break;case 2:u.unshift("rotate(180 "+(o.width/2+o.left).toString()+" "+(o.height/2+o.top).toString()+")");break;case 3:b=o.width/2+o.left,u.unshift("rotate(-90 "+b.toString()+" "+b.toString()+")");break}C%2===1&&(o.left!==o.top&&(b=o.left,o.left=o.top,o.top=b),o.width!==o.height&&(b=o.width,o.width=o.height,o.height=b)),u.length&&(i=tt(i,'<g transform="'+u.join(" ")+'">',"</g>"))});const l=s.width,c=s.height,a=o.width,d=o.height;let f,h;l===null?(h=c===null?"1em":c==="auto"?d:c,f=he(h,a/d)):(f=l==="auto"?a:l,h=c===null?he(f,d/a):c==="auto"?d:c);const p={},y=(k,u)=>{nt(u)||(p[k]=u.toString())};y("width",f),y("height",h);const S=[o.left,o.top,a,d];return p.viewBox=S.join(" "),{attributes:p,viewBox:S,body:i}}const rt=/\sid="(\S+)"/g,st="IconifyId"+Date.now().toString(16)+(Math.random()*16777216|0).toString(16);let it=0;function lt(e,n=st){const r=[];let s;for(;s=rt.exec(e);)r.push(s[1]);if(!r.length)return e;const o="suffix"+(Math.random()*16777216|Date.now()).toString(16);return r.forEach(i=>{const l=typeof n=="function"?n(i):n+(it++).toString(),c=i.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");e=e.replace(new RegExp('([#;"])('+c+')([")]|\\.[a-z])',"g"),"$1"+l+o+"$3")}),e=e.replace(new RegExp(o,"g"),""),e}const U=Object.create(null);function ct(e,n){U[e]=n}function Q(e){return U[e]||U[""]}function G(e){let n;if(typeof e.resources=="string")n=[e.resources];else if(n=e.resources,!(n instanceof Array)||!n.length)return null;return{resources:n,path:e.path||"/",maxURL:e.maxURL||500,rotate:e.rotate||750,timeout:e.timeout||5e3,random:e.random===!0,index:e.index||0,dataAfterTimeout:e.dataAfterTimeout!==!1}}const W=Object.create(null),I=["https://api.simplesvg.com","https://api.unisvg.com"],F=[];for(;I.length>0;)I.length===1||Math.random()>.5?F.push(I.shift()):F.push(I.pop());W[""]=G({resources:["https://api.iconify.design"].concat(F)});function at(e,n){const r=G(n);return r===null?!1:(W[e]=r,!0)}function Z(e){return W[e]}let pe=(()=>{let e;try{if(e=fetch,typeof e=="function")return e}catch{}})();function dt(e,n){const r=Z(e);if(!r)return 0;let s;if(!r.maxURL)s=0;else{let o=0;r.resources.forEach(l=>{o=Math.max(o,l.length)});const i=n+".json?icons=";s=r.maxURL-o-r.path.length-i.length}return s}function ft(e){return e===404}const ut=(e,n,r)=>{const s=[],o=dt(e,n),i="icons";let l={type:i,provider:e,prefix:n,icons:[]},c=0;return r.forEach((a,d)=>{c+=a.length+1,c>=o&&d>0&&(s.push(l),l={type:i,provider:e,prefix:n,icons:[]},c=a.length),l.icons.push(a)}),s.push(l),s};function ht(e){if(typeof e=="string"){const n=Z(e);if(n)return n.path}return"/"}const pt={prepare:ut,send:(e,n,r)=>{if(!pe){r("abort",424);return}let s=ht(n.provider);switch(n.type){case"icons":{const i=n.prefix,c=n.icons.join(","),a=new URLSearchParams({icons:c});s+=i+".json?"+a.toString();break}case"custom":{const i=n.uri;s+=i.slice(0,1)==="/"?i.slice(1):i;break}default:r("abort",400);return}let o=503;pe(e+s).then(i=>{const l=i.status;if(l!==200){setTimeout(()=>{r(ft(l)?"abort":"next",l)});return}return o=501,i.json()}).then(i=>{if(typeof i!="object"||i===null){setTimeout(()=>{i===404?r("abort",i):r("next",o)});return}setTimeout(()=>{r("success",i)})}).catch(()=>{r("next",o)})}};function mt(e){const n={loaded:[],missing:[],pending:[]},r=Object.create(null);e.sort((o,i)=>o.provider!==i.provider?o.provider.localeCompare(i.provider):o.prefix!==i.prefix?o.prefix.localeCompare(i.prefix):o.name.localeCompare(i.name));let s={provider:"",prefix:"",name:""};return e.forEach(o=>{if(s.name===o.name&&s.prefix===o.prefix&&s.provider===o.provider)return;s=o;const i=o.provider,l=o.prefix,c=o.name,a=r[i]||(r[i]=Object.create(null)),d=a[l]||(a[l]=N(i,l));let f;c in d.icons?f=n.loaded:l===""||d.missing.has(c)?f=n.missing:f=n.pending;const h={provider:i,prefix:l,name:c};f.push(h)}),n}function me(e,n){e.forEach(r=>{const s=r.loaderCallbacks;s&&(r.loaderCallbacks=s.filter(o=>o.id!==n))})}function gt(e){e.pendingCallbacksFlag||(e.pendingCallbacksFlag=!0,setTimeout(()=>{e.pendingCallbacksFlag=!1;const n=e.loaderCallbacks?e.loaderCallbacks.slice(0):[];if(!n.length)return;let r=!1;const s=e.provider,o=e.prefix;n.forEach(i=>{const l=i.icons,c=l.pending.length;l.pending=l.pending.filter(a=>{if(a.prefix!==o)return!0;const d=a.name;if(e.icons[d])l.loaded.push({provider:s,prefix:o,name:d});else if(e.missing.has(d))l.missing.push({provider:s,prefix:o,name:d});else return r=!0,!0;return!1}),l.pending.length!==c&&(r||me([e],i.id),i.callback(l.loaded.slice(0),l.missing.slice(0),l.pending.slice(0),i.abort))})}))}let yt=0;function kt(e,n,r){const s=yt++,o=me.bind(null,r,s);if(!n.pending.length)return o;const i={id:s,icons:n,callback:e,abort:o};return r.forEach(l=>{(l.loaderCallbacks||(l.loaderCallbacks=[])).push(i)}),o}function bt(e,n=!0,r=!1){const s=[];return e.forEach(o=>{const i=typeof o=="string"?T(o,n,r):o;i&&s.push(i)}),s}var wt={resources:[],index:0,timeout:2e3,rotate:750,random:!1,dataAfterTimeout:!1};function St(e,n,r,s){const o=e.resources.length,i=e.random?Math.floor(Math.random()*o):e.index;let l;if(e.random){let g=e.resources.slice(0);for(l=[];g.length>1;){const w=Math.floor(Math.random()*g.length);l.push(g[w]),g=g.slice(0,w).concat(g.slice(w+1))}l=l.concat(g)}else l=e.resources.slice(i).concat(e.resources.slice(0,i));const c=Date.now();let a="pending",d=0,f,h=null,p=[],y=[];typeof s=="function"&&y.push(s);function S(){h&&(clearTimeout(h),h=null)}function k(){a==="pending"&&(a="aborted"),S(),p.forEach(g=>{g.status==="pending"&&(g.status="aborted")}),p=[]}function u(g,w){w&&(y=[]),typeof g=="function"&&y.push(g)}function L(){return{startTime:c,payload:n,status:a,queriesSent:d,queriesPending:p.length,subscribe:u,abort:k}}function $(){a="failed",y.forEach(g=>{g(void 0,f)})}function C(){p.forEach(g=>{g.status==="pending"&&(g.status="aborted")}),p=[]}function b(g,w,V){const D=w!=="success";switch(p=p.filter(B=>B!==g),a){case"pending":break;case"failed":if(D||!e.dataAfterTimeout)return;break;default:return}if(w==="abort"){f=V,$();return}if(D){f=V,p.length||(l.length?te():$());return}if(S(),C(),!e.random){const B=e.resources.indexOf(g.resource);B!==-1&&B!==e.index&&(e.index=B)}a="completed",y.forEach(B=>{B(V)})}function te(){if(a!=="pending")return;S();const g=l.shift();if(g===void 0){if(p.length){h=setTimeout(()=>{S(),a==="pending"&&(C(),$())},e.timeout);return}$();return}const w={status:"pending",resource:g,callback:(V,D)=>{b(w,V,D)}};p.push(w),d++,h=setTimeout(te,e.rotate),r(g,n,w.callback)}return setTimeout(te),L}function ge(e){const n={...wt,...e};let r=[];function s(){r=r.filter(c=>c().status==="pending")}function o(c,a,d){const f=St(n,c,a,(h,p)=>{s(),d&&d(h,p)});return r.push(f),f}function i(c){return r.find(a=>c(a))||null}return{query:o,find:i,setIndex:c=>{n.index=c},getIndex:()=>n.index,cleanup:s}}function ye(){}const K=Object.create(null);function Ct(e){if(!K[e]){const n=Z(e);if(!n)return;const r=ge(n),s={config:n,redundancy:r};K[e]=s}return K[e]}function _t(e,n,r){let s,o;if(typeof e=="string"){const i=Q(e);if(!i)return r(void 0,424),ye;o=i.send;const l=Ct(e);l&&(s=l.redundancy)}else{const i=G(e);if(i){s=ge(i);const l=e.resources?e.resources[0]:"",c=Q(l);c&&(o=c.send)}}return!s||!o?(r(void 0,424),ye):s.query(n,o,r)().abort}function ke(){}function $t(e){e.iconsLoaderFlag||(e.iconsLoaderFlag=!0,setTimeout(()=>{e.iconsLoaderFlag=!1,gt(e)}))}function Bt(e){const n=[],r=[];return e.forEach(s=>{(s.match(oe)?n:r).push(s)}),{valid:n,invalid:r}}function M(e,n,r){function s(){const o=e.pendingIcons;n.forEach(i=>{o&&o.delete(i),e.icons[i]||e.missing.add(i)})}if(r&&typeof r=="object")try{if(!ae(e,r).length){s();return}}catch(o){console.error(o)}s(),$t(e)}function be(e,n){e instanceof Promise?e.then(r=>{n(r)}).catch(()=>{n(null)}):n(e)}function Nt(e,n){e.iconsToLoad?e.iconsToLoad=e.iconsToLoad.concat(n).sort():e.iconsToLoad=n,e.iconsQueueFlag||(e.iconsQueueFlag=!0,setTimeout(()=>{e.iconsQueueFlag=!1;const{provider:r,prefix:s}=e,o=e.iconsToLoad;if(delete e.iconsToLoad,!o||!o.length)return;const i=e.loadIcon;if(e.loadIcons&&(o.length>1||!i)){be(e.loadIcons(o,s,r),f=>{M(e,o,f)});return}if(i){o.forEach(f=>{const h=i(f,s,r);be(h,p=>{const y=p?{prefix:s,icons:{[f]:p}}:null;M(e,[f],y)})});return}const{valid:l,invalid:c}=Bt(o);if(c.length&&M(e,c,null),!l.length)return;const a=s.match(oe)?Q(r):null;if(!a){M(e,l,null);return}a.prepare(r,s,l).forEach(f=>{_t(r,f,h=>{M(e,f.icons,h)})})}))}const Lt=(e,n)=>{const r=bt(e,!0,de()),s=mt(r);if(!s.pending.length){let a=!0;return n&&setTimeout(()=>{a&&n(s.loaded,s.missing,s.pending,ke)}),()=>{a=!1}}const o=Object.create(null),i=[];let l,c;return s.pending.forEach(a=>{const{provider:d,prefix:f}=a;if(f===c&&d===l)return;l=d,c=f,i.push(N(d,f));const h=o[d]||(o[d]=Object.create(null));h[f]||(h[f]=[])}),s.pending.forEach(a=>{const{provider:d,prefix:f,name:h}=a,p=N(d,f),y=p.pendingIcons||(p.pendingIcons=new Set);y.has(h)||(y.add(h),o[d][f].push(h))}),i.forEach(a=>{const d=o[a.provider][a.prefix];d.length&&Nt(a,d)}),n?kt(n,s,i):ke};function xt(e,n){const r={...e};for(const s in n){const o=n[s],i=typeof o;s in fe?(o===null||o&&(i==="string"||i==="number"))&&(r[s]=o):i===typeof r[s]&&(r[s]=s==="rotate"?o%4:o)}return r}const Et=/[\s,]+/;function It(e,n){n.split(Et).forEach(r=>{switch(r.trim()){case"horizontal":e.hFlip=!0;break;case"vertical":e.vFlip=!0;break}})}function Mt(e,n=0){const r=e.replace(/^-?[0-9.]*/,"");function s(o){for(;o<0;)o+=4;return o%4}if(r===""){const o=parseInt(e);return isNaN(o)?0:s(o)}else if(r!==e){let o=0;switch(r){case"%":o=25;break;case"deg":o=90}if(o){let i=parseFloat(e.slice(0,e.length-r.length));return isNaN(i)?0:(i=i/o,i%1===0?s(i):0)}}return n}function Vt(e,n){let r=e.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const s in n)r+=" "+s+'="'+n[s]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+r+">"+e+"</svg>"}function At(e){return e.replace(/"/g,"'").replace(/%/g,"%25").replace(/#/g,"%23").replace(/</g,"%3C").replace(/>/g,"%3E").replace(/\s+/g," ")}function Tt(e){return"data:image/svg+xml,"+At(e)}function jt(e){return'url("'+Tt(e)+'")'}const we={...ue,inline:!1},Pt={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":!0,role:"img"},Ot={display:"inline-block"},Y={backgroundColor:"currentColor"},Se={backgroundColor:"transparent"},Ce={Image:"var(--svg)",Repeat:"no-repeat",Size:"100% 100%"},_e={webkitMask:Y,mask:Y,background:Se};for(const e in _e){const n=_e[e];for(const r in Ce)n[e+r]=Ce[r]}const R={};["horizontal","vertical"].forEach(e=>{const n=e.slice(0,1)+"Flip";R[e+"-flip"]=n,R[e.slice(0,1)+"-flip"]=n,R[e+"Flip"]=n});function $e(e){return e+(e.match(/^[-0-9.]+$/)?"px":"")}const Be=(e,n)=>{const r=xt(we,n),s={...Pt},o=n.mode||"svg",i={},l=n.style,c=typeof l=="object"&&!(l instanceof Array)?l:{};for(let k in n){const u=n[k];if(u!==void 0)switch(k){case"icon":case"style":case"onLoad":case"mode":case"ssr":break;case"inline":case"hFlip":case"vFlip":r[k]=u===!0||u==="true"||u===1;break;case"flip":typeof u=="string"&&It(r,u);break;case"color":i.color=u;break;case"rotate":typeof u=="string"?r[k]=Mt(u):typeof u=="number"&&(r[k]=u);break;case"ariaHidden":case"aria-hidden":u!==!0&&u!=="true"&&delete s["aria-hidden"];break;default:{const L=R[k];L?(u===!0||u==="true"||u===1)&&(r[L]=!0):we[k]===void 0&&(s[k]=u)}}}const a=ot(e,r),d=a.attributes;if(r.inline&&(i.verticalAlign="-0.125em"),o==="svg"){s.style={...i,...c},Object.assign(s,d);let k=0,u=n.id;return typeof u=="string"&&(u=u.replace(/-/g,"_")),s.innerHTML=lt(a.body,u?()=>u+"ID"+k++:"iconifyVue"),t.h("svg",s)}const{body:f,width:h,height:p}=e,y=o==="mask"||(o==="bg"?!1:f.indexOf("currentColor")!==-1),S=Vt(f,{...d,width:h+"",height:p+""});return s.style={...i,"--svg":jt(S),width:$e(d.width),height:$e(d.height),...Ot,...y?Y:Se,...c},t.h("span",s)};if(de(!0),ct("",pt),typeof document<"u"&&typeof window<"u"){const e=window;if(e.IconifyPreload!==void 0){const n=e.IconifyPreload,r="Invalid IconifyPreload syntax.";typeof n=="object"&&n!==null&&(n instanceof Array?n:[n]).forEach(s=>{try{(typeof s!="object"||s===null||s instanceof Array||typeof s.icons!="object"||typeof s.prefix!="string"||!Ye(s))&&console.error(r)}catch{console.error(r)}})}if(e.IconifyProviders!==void 0){const n=e.IconifyProviders;if(typeof n=="object"&&n!==null)for(let r in n){const s="IconifyProviders["+r+"] is invalid.";try{const o=n[r];if(typeof o!="object"||!o||o.resources===void 0)continue;at(r,o)||console.error(s)}catch{console.error(s)}}}}const Ft={...O,body:""},Ne=t.defineComponent({inheritAttrs:!1,data(){return{_name:"",_loadingIcon:null,iconMounted:!1,counter:0}},mounted(){this.iconMounted=!0},unmounted(){this.abortLoading()},methods:{abortLoading(){this._loadingIcon&&(this._loadingIcon.abort(),this._loadingIcon=null)},getIcon(e,n,r){if(typeof e=="object"&&e!==null&&typeof e.body=="string")return this._name="",this.abortLoading(),{data:e};let s;if(typeof e!="string"||(s=T(e,!1,!0))===null)return this.abortLoading(),null;let o=Ze(s);if(!o)return(!this._loadingIcon||this._loadingIcon.name!==e)&&(this.abortLoading(),this._name="",o!==null&&(this._loadingIcon={name:e,abort:Lt([s],()=>{this.counter++})})),null;if(this.abortLoading(),this._name!==e&&(this._name=e,n&&n(e)),r){o=Object.assign({},o);const l=r(o.body,s.name,s.prefix,s.provider);typeof l=="string"&&(o.body=l)}const i=["iconify"];return s.prefix!==""&&i.push("iconify--"+s.prefix),s.provider!==""&&i.push("iconify--"+s.provider),{data:o,classes:i}}},render(){this.counter;const e=this.$attrs,n=this.iconMounted||e.ssr?this.getIcon(e.icon,e.onLoad,e.customise):null;if(!n)return Be(Ft,e);let r=e;return n.classes&&(r={...e,class:(typeof e.class=="string"?e.class+" ":"")+n.classes.join(" ")}),Be({...O,...n.data},r)}}),Rt={class:"logo"},Dt=["alt","src"],zt={key:1,class:"logo-default"},qt={name:"Logo"},J=t.defineComponent({...qt,props:{alt:{default:void 0,type:String},route:{default:void 0,type:String},src:{default:void 0,type:String}},setup(e){const n=e,{appName:r,appTitle:s,layout:o}=z.useConfig(),i=t.computed(()=>{if(r)return r.replace("@","").replace("/"," ")}),l=n.alt||o?.logoAlt||i.value||s||"My App",c=n.src||o?.logo,a=n.route||o?.logoRoute||"home";return(d,f)=>{const h=t.resolveComponent("router-link");return t.openBlock(),t.createElementBlock("div",Rt,[t.renderSlot(d.$slots,"default",{},()=>[t.createVNode(h,{to:{name:t.unref(a)}},{default:t.withCtx(()=>[t.unref(c)?(t.openBlock(),t.createElementBlock("img",{key:0,alt:t.unref(l),src:t.unref(c)},null,8,Dt)):(t.openBlock(),t.createElementBlock("span",zt,[t.createElementVNode("span",null,t.toDisplayString(t.unref(l)[0]),1),t.createElementVNode("span",null,t.toDisplayString(t.unref(l)),1)]))]),_:1},8,["to"])])])}}}),Ht={name:"MainMenu"},Le=t.defineComponent({...Ht,props:{routes:{required:!0,type:Array}},emits:["close"],setup(e){const n=e,r=x.useRoute(),s=x.useRouter(),o=t.computed(()=>{let c=n.routes?.find(a=>a.route===r?.name)?.route;return c||(c=i.value),c}),i=t.computed(()=>{const c=r?.matched;if(c?.length>1){const a=c[c.length-2];return l(a?.path)}return""}),l=c=>{const a=s.getRoutes().find(d=>d.path===c);return String(a?.name)};return(c,a)=>(t.openBlock(),t.createBlock(t.unref(Pe.ResponsiveMenu),{ref:"mainMenu","active-route":o.value??"home",routes:e.routes,onChangeRoute:a[0]||(a[0]=d=>c.$emit("close"))},null,8,["active-route","routes"]))}}),Ut=["data-expanded"],Qt={name:"AppHeader"},X=t.defineComponent({...Qt,props:{noLocaleSwitcher:Boolean,noLogo:Boolean,noMainMenu:Boolean},setup(e,{expose:n}){const{layout:r}=z.useConfig(),s=t.ref(null),o=t.ref(!1),i=r&&r?.homeRoute?r.homeRoute:void 0,l=()=>{o.value=!1},c=()=>{o.value=!o.value};return je.onClickOutside(s,a=>{o.value=!1}),n({expanded:o}),(a,d)=>(t.openBlock(),t.createElementBlock("header",{ref_key:"dzangolabVueAppHeader",ref:s},[t.renderSlot(a.$slots,"logo",{class:"logo"},()=>[e.noLogo?t.createCommentVNode("",!0):(t.openBlock(),t.createBlock(J,{key:0,route:t.unref(i)},null,8,["route"]))]),t.createElementVNode("nav",{"data-expanded":o.value},[t.renderSlot(a.$slots,"menu",{},()=>[t.unref(r)?.mainMenu&&!e.noMainMenu?(t.openBlock(),t.createBlock(Le,{key:0,class:"main-menu",routes:t.unref(r)?.mainMenu,onClose:l},null,8,["routes"])):t.createCommentVNode("",!0)]),t.renderSlot(a.$slots,"userMenu"),t.renderSlot(a.$slots,"addon"),t.renderSlot(a.$slots,"locales",{},()=>[e.noLocaleSwitcher?t.createCommentVNode("",!0):(t.openBlock(),t.createBlock(t.unref(_.LocaleSwitcher),{key:0,class:"locales"}))])],8,Ut),t.createElementVNode("div",{class:"toggle",onClick:c},[t.renderSlot(a.$slots,"toggle",{},()=>[o.value?(t.openBlock(),t.createBlock(t.unref(Ne),{key:0,icon:"fa6-solid:bars-staggered",height:"1.5rem"})):(t.openBlock(),t.createBlock(t.unref(Ne),{key:1,icon:"fa6-solid:bars",height:"1.5rem"}))])])],512))}}),Gt="data:image/svg+xml,%3csvg%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20stroke-width='0'%3e%3c/g%3e%3cg%20stroke-linecap='round'%20stroke-linejoin='round'%3e%3c/g%3e%3cg%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M15.7071%204.29289C16.0976%204.68342%2016.0976%205.31658%2015.7071%205.70711L9.41421%2012L15.7071%2018.2929C16.0976%2018.6834%2016.0976%2019.3166%2015.7071%2019.7071C15.3166%2020.0976%2014.6834%2020.0976%2014.2929%2019.7071L7.29289%2012.7071C7.10536%2012.5196%207%2012.2652%207%2012C7%2011.7348%207.10536%2011.4804%207.29289%2011.2929L14.2929%204.29289C14.6834%203.90237%2015.3166%203.90237%2015.7071%204.29289Z'%20fill='%23ffffff'%3e%3c/path%3e%3c/g%3e%3c/svg%3e",xe="data:image/svg+xml,%3csvg%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20stroke-width='0'%3e%3c/g%3e%3cg%20stroke-linecap='round'%20stroke-linejoin='round'%3e%3c/g%3e%3cg%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M8.29289%204.29289C8.68342%203.90237%209.31658%203.90237%209.70711%204.29289L16.7071%2011.2929C17.0976%2011.6834%2017.0976%2012.3166%2016.7071%2012.7071L9.70711%2019.7071C9.31658%2020.0976%208.68342%2020.0976%208.29289%2019.7071C7.90237%2019.3166%207.90237%2018.6834%208.29289%2018.2929L14.5858%2012L8.29289%205.70711C7.90237%205.31658%207.90237%204.68342%208.29289%204.29289Z'%20fill='%23ffffff'%3e%3c/path%3e%3c/g%3e%3c/svg%3e",Wt={class:"nav-menu-item"},Zt={key:1},Kt={key:2,class:"item-name"},Yt={key:3,class:"toggle-menu"},Jt={key:0,class:"sub-menu-item"},Xt={name:"NavMenuItem",components:{NavMenuItem:()=>Promise.resolve().then(()=>vt)}},Ee=t.defineComponent({...Xt,props:{item:{required:!0,type:Object},sidebarActive:{default:!0,required:!0,type:Boolean}},setup(e){const n=e,r=x.useRoute(),s=x.useRouter(),o=t.ref(!1),i=t.computed(()=>{const f=r?.matched;if(f?.length>1){const h=f[f.length-2];return a(h?.path)}return""}),l=t.computed(()=>{let f=r.name===n.item?.routeName;return f||(n.item?.routeName?f=!!i.value&&i.value===n.item?.routeName:!n.item?.routeName&&!n.item?.children?.length&&r.name===i.value&&(f=!0)),f}),c=t.computed(()=>!n.sidebarActive&&n.item.shortName),a=f=>{const h=s.getRoutes().find(p=>p.path===f);return String(h?.name)},d=()=>{n.item.routeName?s.push({name:n.item.routeName}):!n.item.routeName&&!n.item.children?.length?s.push({name:i.value}):o.value=!o.value};return n.item.children?.length&&(o.value=!!n.item.children.find(f=>r.name===f?.routeName)),(f,h)=>{const p=t.resolveComponent("NavMenuItem",!0);return t.openBlock(),t.createElementBlock("div",Wt,[t.createElementVNode("a",{class:t.normalizeClass([{active:l.value},"link"]),"aria-label":"open menu",onClick:d},[e.item.icon?(t.openBlock(),t.createElementBlock("i",{key:0,class:t.normalizeClass(["icon",e.item.icon,{"icon-only":!c.value&&!e.sidebarActive}])},null,2)):t.createCommentVNode("",!0),c.value?(t.openBlock(),t.createElementBlock("span",Zt,t.toDisplayString(e.item.shortName),1)):t.createCommentVNode("",!0),e.sidebarActive?(t.openBlock(),t.createElementBlock("span",Kt,t.toDisplayString(e.item.name),1)):t.createCommentVNode("",!0),e.item.children&&e.item.children.length?(t.openBlock(),t.createElementBlock("span",Yt,[(t.openBlock(),t.createElementBlock("svg",{class:t.normalizeClass({"up-chevron":o.value}),viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},h[0]||(h[0]=[t.createElementVNode("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M4.29289 8.29289C4.68342 7.90237 5.31658 7.90237 5.70711 8.29289L12 14.5858L18.2929 8.29289C18.6834 7.90237 19.3166 7.90237 19.7071 8.29289C20.0976 8.68342 20.0976 9.31658 19.7071 9.70711L12.7071 16.7071C12.3166 17.0976 11.6834 17.0976 11.2929 16.7071L4.29289 9.70711C3.90237 9.31658 3.90237 8.68342 4.29289 8.29289Z",fill:"currentColor"},null,-1)]),2))])):t.createCommentVNode("",!0)],2),t.createVNode(t.Transition,{name:"fade"},{default:t.withCtx(()=>[e.item.children&&e.item.children.length&&o.value?(t.openBlock(),t.createElementBlock("div",Jt,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.item.children,(y,S)=>(t.openBlock(),t.createBlock(p,{key:y.name+"-"+S,item:y,"sidebar-active":e.sidebarActive},null,8,["item","sidebar-active"]))),128))])):t.createCommentVNode("",!0)]),_:1})])}}}),vt=Object.freeze(Object.defineProperty({__proto__:null,default:Ee},Symbol.toStringTag,{value:"Module"})),en={class:"nav-menu"},tn={key:0,class:"menu"},nn={name:"NavMenu"},on=t.defineComponent({...nn,props:{menu:{required:!0,type:Array},sidebarActive:{default:!0,required:!0,type:Boolean}},setup(e){const n=e,r=t.computed(()=>n.menu?.map(s=>{if(s.hide)return null;const o=s.children?.filter(i=>!i.hide)||[];return s.children?.length&&!o.length?null:{...s,children:o.length?o:void 0}}).filter(Boolean));return(s,o)=>(t.openBlock(),t.createElementBlock("nav",en,[r.value?.length>0?(t.openBlock(),t.createElementBlock("div",tn,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.value,(i,l)=>(t.openBlock(),t.createBlock(Ee,{key:i.name+"-"+l,item:i,"sidebar-active":e.sidebarActive},null,8,["item","sidebar-active"]))),128))])):t.createCommentVNode("",!0)]))}}),rn={key:0,class:"sidebar"},sn={key:0,class:"header"},ln={class:"logo"},cn={class:"title"},an={key:0,alt:"minimize sidebar",src:Gt},dn={key:1,class:"extend",alt:"extend sidebar",src:xe},fn={class:"sidebar-menu-wrapper"},un={class:"nav"},hn={key:1,class:"footer"},pn={key:0,alt:"show sidebar",src:xe},mn={name:"Sidebar"},v=t.defineComponent({...mn,props:{menu:{required:!0,type:Array},noHeader:{default:!1,type:Boolean}},setup(e,{expose:n}){const r=e,s=t.computed(()=>i.value?!1:!r.menu?.filter(c=>!!c.shortName)?.length),o=t.useSlots(),i=t.ref(!0),l=()=>{window.innerWidth>=1025?i.value=!0:r.noHeader||(i.value=!1)};return t.onUnmounted(()=>{window.removeEventListener("resize",l)}),window.addEventListener("resize",l),l(),n({sidebarActive:i}),(c,a)=>s.value?(t.openBlock(),t.createElementBlock("div",{key:1,class:"no-sidebar",onClick:a[1]||(a[1]=d=>i.value=!0)},[i.value?t.createCommentVNode("",!0):(t.openBlock(),t.createElementBlock("img",pn))])):(t.openBlock(),t.createElementBlock("div",rn,[e.noHeader?t.createCommentVNode("",!0):(t.openBlock(),t.createElementBlock("div",sn,[t.createElementVNode("div",ln,[t.createVNode(J)]),t.createElementVNode("div",cn,[t.renderSlot(c.$slots,"title")]),t.createElementVNode("div",{class:"toggle",onClick:a[0]||(a[0]=d=>i.value=!i.value)},[t.createVNode(t.Transition,{name:"sidebar-toggle"},{default:t.withCtx(()=>[i.value?(t.openBlock(),t.createElementBlock("img",an)):(t.openBlock(),t.createElementBlock("img",dn))]),_:1})])])),t.createElementVNode("div",fn,[t.renderSlot(c.$slots,"default"),t.createElementVNode("ul",un,[t.renderSlot(c.$slots,"links",{},()=>[t.createVNode(on,{menu:e.menu,"sidebar-active":i.value},null,8,["menu","sidebar-active"])]),t.renderSlot(c.$slots,"afterNavLinks")]),t.renderSlot(c.$slots,"afterSidebarMenu")]),t.unref(o).footer?(t.openBlock(),t.createElementBlock("div",hn,[t.renderSlot(c.$slots,"footer")])):t.createCommentVNode("",!0)]))}}),gn={class:"content"},yn={name:"StickyCollapsibleFooter"},kn=t.defineComponent({...yn,props:{fixed:{default:!0,type:Boolean}},setup(e){return(n,r)=>(t.openBlock(),t.createElementBlock("footer",{class:t.normalizeClass(`sticky-collapsible ${e.fixed?"fixed":""}`)},[t.createElementVNode("div",gn,[t.renderSlot(n.$slots,"default")])],2))}}),bn=t.defineAsyncComponent({loader:()=>Promise.resolve().then(()=>Ln),timeout:3e3}),wn={name:"Layout"},Ie=t.defineComponent({...wn,props:{defaultLayout:{default:bn,type:Object}},setup(e){const n=e,r=x.useRoute(),s=t.useSlots(),o=Object.keys(s);let i=t.shallowRef(n.defaultLayout);const l=t.computed(()=>t.markRaw(i.value));return t.watch(()=>r.meta,async c=>{if(c?.layout)try{i.value=c.layout}catch{i.value=n.defaultLayout}else i.value=n.defaultLayout}),(c,a)=>(t.openBlock(),t.createBlock(t.resolveDynamicComponent(l.value),null,t.createSlots({default:t.withCtx(()=>[t.renderSlot(c.$slots,"default")]),_:2},[t.renderList(t.unref(o),d=>({name:d,fn:t.withCtx(()=>[t.renderSlot(c.$slots,d)])}))]),1024))}}),Sn={class:"layout basic"},Cn={name:"BasicLayout"},_n=t.defineComponent({...Cn,props:{noLocaleSwitcher:Boolean},setup(e){return(n,r)=>(t.openBlock(),t.createElementBlock("div",Sn,[t.renderSlot(n.$slots,"header",{},()=>[t.createVNode(X,{"no-locale-switcher":e.noLocaleSwitcher},{logo:t.withCtx(()=>[t.renderSlot(n.$slots,"logo")]),addon:t.withCtx(()=>[t.renderSlot(n.$slots,"addon")]),menu:t.withCtx(()=>[t.renderSlot(n.$slots,"menu")]),userMenu:t.withCtx(()=>[t.renderSlot(n.$slots,"userMenu")]),locales:t.withCtx(()=>[t.renderSlot(n.$slots,"locales")]),_:3},8,["no-locale-switcher"])]),t.createElementVNode("main",null,[t.renderSlot(n.$slots,"default")]),t.renderSlot(n.$slots,"footer",{},()=>[t.createVNode(A,null,{copyright:t.withCtx(()=>[t.renderSlot(n.$slots,"copyright")]),social:t.withCtx(()=>[t.renderSlot(n.$slots,"social")]),version:t.withCtx(()=>[t.renderSlot(n.$slots,"version")]),_:3})])]))}}),$n={name:"NullLayout"},Bn=(e,n)=>{const r=e.__vccOpts||e;for(const[s,o]of n)r[s]=o;return r};function Nn(e,n,r,s,o,i){return t.renderSlot(e.$slots,"default")}const Me=Bn($n,[["render",Nn]]),Ln=Object.freeze(Object.defineProperty({__proto__:null,default:Me},Symbol.toStringTag,{value:"Module"})),Ve="data:image/svg+xml,%3csvg%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20stroke-width='0'%3e%3c/g%3e%3cg%20stroke-linecap='round'%20stroke-linejoin='round'%3e%3c/g%3e%3cg%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M12%207C12.2652%207%2012.5196%207.10536%2012.7071%207.29289L19.7071%2014.2929C20.0976%2014.6834%2020.0976%2015.3166%2019.7071%2015.7071C19.3166%2016.0976%2018.6834%2016.0976%2018.2929%2015.7071L12%209.41421L5.70711%2015.7071C5.31658%2016.0976%204.68342%2016.0976%204.29289%2015.7071C3.90237%2015.3166%203.90237%2014.6834%204.29289%2014.2929L11.2929%207.29289C11.4804%207.10536%2011.7348%207%2012%207Z'%20fill='%23ffffff'%3e%3c/path%3e%3c/g%3e%3c/svg%3e",xn={class:"layout sidebar-header-layout"},En=t.defineComponent({__name:"SidebarHeaderLayout",props:{menu:{required:!0,type:Array},noLocaleSwitcher:Boolean,noSidebarHeader:{default:!1,type:Boolean},userMenuLocation:{default:"sidebar",type:String,validator:e=>["header","sidebar"].includes(e)}},setup(e){const n=t.ref(),r=t.ref(),s=t.ref(!1);t.watch(()=>n.value?.expanded,i=>{i&&(r.value.sidebarActive=!0)}),t.watch(()=>r.value?.sidebarActive,i=>{i||(n.value.expanded=!1)});const o=()=>{window.innerWidth>=576?s.value=!1:s.value=!0};return t.onUnmounted(()=>{window.removeEventListener("resize",o)}),window.addEventListener("resize",o),o(),(i,l)=>(t.openBlock(),t.createElementBlock("div",xn,[t.renderSlot(i.$slots,"header",{},()=>[t.createVNode(X,{ref_key:"appHeader",ref:n,"no-locale-switcher":e.noLocaleSwitcher,"no-logo":"","no-main-menu":""},t.createSlots({locales:t.withCtx(()=>[t.renderSlot(i.$slots,"locales")]),_:2},[e.userMenuLocation==="header"?{name:"userMenu",fn:t.withCtx(()=>[t.renderSlot(i.$slots,"userMenu")]),key:"0"}:void 0]),1032,["no-locale-switcher"])]),t.createVNode(v,{ref_key:"sidebar",ref:r,menu:e.menu,"no-header":e.noSidebarHeader,class:"layout-sidebar"},{afterNavLinks:t.withCtx(()=>[t.renderSlot(i.$slots,"afterNavLinks")]),afterSidebarMenu:t.withCtx(()=>[t.renderSlot(i.$slots,"afterSidebarMenu"),e.userMenuLocation==="sidebar"?t.renderSlot(i.$slots,"userMenu",{key:0}):t.createCommentVNode("",!0),s.value?t.renderSlot(i.$slots,"locales",{key:1},()=>[e.noLocaleSwitcher?t.createCommentVNode("",!0):(t.openBlock(),t.createBlock(t.unref(_.LocaleSwitcher),{key:0,class:"locales"},{icon:t.withCtx(()=>l[0]||(l[0]=[t.createElementVNode("img",{src:Ve,alt:"toggle icon"},null,-1)])),_:1}))]):t.createCommentVNode("",!0)]),footer:t.withCtx(()=>[t.renderSlot(i.$slots,"footer",{},()=>[t.createVNode(A)])]),_:3},8,["menu","no-header"]),t.createElementVNode("main",null,[t.renderSlot(i.$slots,"default")])]))}}),In={class:"layout sidebar-only"},Mn=t.defineComponent({__name:"SidebarOnlyLayout",props:{menu:{required:!0,type:Array},noLocaleSwitcher:Boolean,noHeader:{default:!1,type:Boolean}},setup(e){return(n,r)=>(t.openBlock(),t.createElementBlock("div",In,[t.createVNode(v,{menu:e.menu,"no-header":e.noHeader,class:"layout-sidebar"},{afterNavLinks:t.withCtx(()=>[t.renderSlot(n.$slots,"afterNavLinks")]),afterSidebarMenu:t.withCtx(()=>[t.renderSlot(n.$slots,"afterSidebarMenu"),t.renderSlot(n.$slots,"userMenu"),t.renderSlot(n.$slots,"locales",{},()=>[e.noLocaleSwitcher?t.createCommentVNode("",!0):(t.openBlock(),t.createBlock(t.unref(_.LocaleSwitcher),{key:0,class:"locales"},{icon:t.withCtx(()=>r[0]||(r[0]=[t.createElementVNode("img",{src:Ve,alt:"toggle icon"},null,-1)])),_:1}))])]),footer:t.withCtx(()=>[t.createVNode(A)]),_:3},8,["menu","no-header"]),t.createElementVNode("main",null,[t.renderSlot(n.$slots,"default")])]))}}),ee={en:{copyright:{disclaimer:"All rights reserved."}},fr:{copyright:{disclaimer:"Tous droits réservés."}}},Ae=Symbol.for("dzangolab.vue-layout.translations"),Te=()=>t.inject(Ae,ee),Vn={install:(e,n)=>{e.component("Layout",Ie);const r=n?.translations?_.prependMessages(ee,n.translations):ee;e.provide(Ae,r)}};m.AppFooter=A,m.AppHeader=X,m.BasicLayout=_n,m.Copyright=ne,m.Layout=Ie,m.Logo=J,m.MainMenu=Le,m.NullLayout=Me,m.Sidebar=v,m.SidebarHeaderLayout=En,m.SidebarOnlyLayout=Mn,m.StickyCollapsibleFooter=kn,m.default=Vn,m.useTranslations=Te,Object.defineProperties(m,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|