scrubbed-tailwind-components-v2 2.0.3 → 2.0.4-b-rc2
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/README.md
CHANGED
|
@@ -1,51 +1,81 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Scrubbed Tailwind Components v2
|
|
2
2
|
|
|
3
|
-
This
|
|
3
|
+
Scrubbed Tailwind Components v2 is a Vue 3 component library that provides a set of pre-built and beautifully styled components using Tailwind CSS. This library is designed to help you quickly build modern and responsive user interfaces.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## Installation
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
To use Scrubbed Tailwind Components v2 in your project, you can install it via npm:
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
```sh
|
|
10
|
+
npm install scrubbed-tailwind-components-v2
|
|
11
|
+
```
|
|
10
12
|
|
|
11
|
-
|
|
13
|
+
## Usage
|
|
12
14
|
|
|
13
|
-
|
|
15
|
+
You can import and use the components in your Vue application like this:
|
|
14
16
|
|
|
15
|
-
```
|
|
16
|
-
|
|
17
|
+
```vue
|
|
18
|
+
<script setup>
|
|
19
|
+
import { Button } from "scrubbed-tailwind-components-v2";
|
|
20
|
+
</script>
|
|
21
|
+
|
|
22
|
+
<template>
|
|
23
|
+
<Button>Click me</Button>
|
|
24
|
+
</template>
|
|
17
25
|
```
|
|
18
26
|
|
|
19
|
-
|
|
27
|
+
## Development
|
|
20
28
|
|
|
21
|
-
|
|
22
|
-
npm run dev
|
|
23
|
-
```
|
|
29
|
+
This project uses Vite for development and building.
|
|
24
30
|
|
|
25
|
-
###
|
|
31
|
+
### Recommended IDE Setup
|
|
26
32
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
```
|
|
33
|
+
- [VSCode](https://code.visualstudio.com/)
|
|
34
|
+
- [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur)
|
|
30
35
|
|
|
31
|
-
###
|
|
36
|
+
### Project Setup
|
|
37
|
+
|
|
38
|
+
To set up the development environment, clone the repository and install the dependencies:
|
|
32
39
|
|
|
33
40
|
```sh
|
|
34
|
-
|
|
41
|
+
git clone https://[your-username]@bitbucket.org/devteam_scrubbed/scrubbed-tailwind-components-v2.git
|
|
42
|
+
cd scrubbed-tailwind-components-v2
|
|
43
|
+
npm install
|
|
35
44
|
```
|
|
36
45
|
|
|
37
|
-
###
|
|
46
|
+
### Compile and Hot-Reload for Development
|
|
47
|
+
|
|
48
|
+
To start the development server with hot-reloading, run the following command:
|
|
38
49
|
|
|
39
50
|
```sh
|
|
40
|
-
npm run
|
|
51
|
+
npm run dev
|
|
41
52
|
```
|
|
42
53
|
|
|
43
|
-
|
|
44
|
-
It is much faster than the production build.
|
|
54
|
+
### Compile and Minify for Production
|
|
45
55
|
|
|
46
|
-
|
|
56
|
+
To build the library for production, run:
|
|
47
57
|
|
|
48
58
|
```sh
|
|
49
59
|
npm run build
|
|
50
|
-
npm run test:e2e
|
|
51
60
|
```
|
|
61
|
+
|
|
62
|
+
### Testing
|
|
63
|
+
|
|
64
|
+
This project uses Cypress for both component and end-to-end testing.
|
|
65
|
+
|
|
66
|
+
- **Run component tests (headless):**
|
|
67
|
+
```sh
|
|
68
|
+
npm run test:unit
|
|
69
|
+
```
|
|
70
|
+
- **Run component tests (headed):**
|
|
71
|
+
```sh
|
|
72
|
+
npm run test:unit:dev
|
|
73
|
+
```
|
|
74
|
+
- **Run end-to-end tests (headless):**
|
|
75
|
+
```sh
|
|
76
|
+
npm run test:e2e
|
|
77
|
+
```
|
|
78
|
+
- **Run end-to-end tests (headed):**
|
|
79
|
+
```sh
|
|
80
|
+
npm run test:e2e:dev
|
|
81
|
+
```
|
|
@@ -1 +1 @@
|
|
|
1
|
-
@starting-style{.backdrop[data-v-aaece1c7]{opacity:0}}.link[data-v-0fab71c0]{border:1px solid transparent}.link[data-v-0fab71c0]:has(.router-link-active){border:1px solid rgba(255,255,255,.75);background:linear-gradient(101deg,#e9eef54d 6.76%,#105fa24d 100.14%);box-shadow:0 4px 17px -1px #30537426;-webkit-backdrop-filter:blur(1px);backdrop-filter:blur(1px)}.tab[data-v-9e06f71f]{border:1px solid transparent}.tab-active[data-v-9e06f71f]{border-radius:10px;border:1px solid rgba(255,255,255,.75);background:linear-gradient(101deg,#e9eef54d 6.76%,#105fa24d 100.14%);box-shadow:0 4px 17px -1px #30537426;-webkit-backdrop-filter:blur(1px);backdrop-filter:blur(1px)}
|
|
1
|
+
@starting-style{.backdrop[data-v-aaece1c7]{opacity:0}}.link[data-v-0fab71c0]{border:1px solid transparent}.link[data-v-0fab71c0]:has(.router-link-active){border:1px solid rgba(255,255,255,.75);background:linear-gradient(101deg,#e9eef54d 6.76%,#105fa24d 100.14%);box-shadow:0 4px 17px -1px #30537426;-webkit-backdrop-filter:blur(1px);backdrop-filter:blur(1px)}.fade-in-dialog-enter-active{transition:all .15s cubic-bezier(.08,.82,.17,1)}.fade-in-dialog-leave-active{transition:all .15s cubic-bezier(.46,.03,.52,.96)}.fade-in-dialog-enter-from,.fade-in-dialog-leave-to{transform:scale(.95);opacity:0}.fade-in-dialog-enter-active{transition-delay:.05s}.fade-in-enter-active,.fade-in-leave-active{transition:opacity .15s ease}.fade-in-enter-from,.fade-in-leave-to{opacity:0}.slide-enter-active{transition:all .5s cubic-bezier(.08,.82,.17,1)}.slide-leave-active{transition:all .15s cubic-bezier(.46,.03,.52,.96)}.slide-enter-from,.slide-leave-to{opacity:0;transform:translate(100%)}.slide-enter-active{transition-delay:.18s}.tab[data-v-9e06f71f]{border:1px solid transparent}.tab-active[data-v-9e06f71f]{border-radius:10px;border:1px solid rgba(255,255,255,.75);background:linear-gradient(101deg,#e9eef54d 6.76%,#105fa24d 100.14%);box-shadow:0 4px 17px -1px #30537426;-webkit-backdrop-filter:blur(1px);backdrop-filter:blur(1px)}
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { inject as m, createElementBlock as l, openBlock as
|
|
2
|
-
import { RouterLink as
|
|
3
|
-
const
|
|
1
|
+
import { inject as m, createElementBlock as l, openBlock as s, normalizeClass as _, unref as u, createElementVNode as d, renderSlot as i, createBlock as p, withCtx as f, ref as g, provide as y, createVNode as x, Fragment as A, Teleport as B, normalizeStyle as H, watch as W, createCommentVNode as v, resolveComponent as q, mergeProps as k, useModel as T, withDirectives as $, vModelCheckbox as O, onMounted as U, onUnmounted as Z, Transition as S, useSlots as R, resolveDynamicComponent as E, cloneVNode as G, vModelText as z, vModelRadio as J, vModelSelect as Y, renderList as D, toDisplayString as P, createTextVNode as F, computed as X } from "vue";
|
|
2
|
+
import { RouterLink as I, useRoute as j } from "vue-router";
|
|
3
|
+
const Q = { class: "flex w-full items-center justify-between" }, K = { class: "flex items-center gap-2" }, ee = { class: "flex items-center gap-10" }, te = { class: "hidden gap-6 sm:flex" }, oe = {
|
|
4
4
|
__name: "AppHeader",
|
|
5
5
|
setup(e) {
|
|
6
|
-
const
|
|
7
|
-
return (
|
|
8
|
-
class:
|
|
6
|
+
const t = m("APP_DATA"), { isSidebarToggled: o, toggleSidebar: r } = t;
|
|
7
|
+
return (n, a) => (s(), l("header", {
|
|
8
|
+
class: _(["fixed top-0 flex h-16 w-dvw items-center bg-white/50 px-3 backdrop-blur sm:px-6", { "rounded-t-2xl": u(o) }])
|
|
9
9
|
}, [
|
|
10
|
-
d("nav",
|
|
11
|
-
d("div",
|
|
10
|
+
d("nav", Q, [
|
|
11
|
+
d("div", K, [
|
|
12
12
|
d("button", {
|
|
13
|
-
onClick:
|
|
13
|
+
onClick: a[0] || (a[0] = (c) => u(r)()),
|
|
14
14
|
class: "block cursor-pointer rounded-full p-2 hover:bg-neutral-100 sm:hidden"
|
|
15
|
-
},
|
|
15
|
+
}, a[1] || (a[1] = [
|
|
16
16
|
d("svg", {
|
|
17
17
|
xmlns: "http://www.w3.org/2000/svg",
|
|
18
18
|
width: "24",
|
|
@@ -30,206 +30,186 @@ const O = { class: "flex w-full items-center justify-between" }, U = { class: "f
|
|
|
30
30
|
d("path", { d: "M4 6h16" })
|
|
31
31
|
], -1)
|
|
32
32
|
])),
|
|
33
|
-
i(
|
|
33
|
+
i(n.$slots, "header-img")
|
|
34
34
|
]),
|
|
35
|
-
d("div",
|
|
36
|
-
d("ul",
|
|
37
|
-
i(
|
|
35
|
+
d("div", ee, [
|
|
36
|
+
d("ul", te, [
|
|
37
|
+
i(n.$slots, "header-links")
|
|
38
38
|
]),
|
|
39
|
-
i(
|
|
39
|
+
i(n.$slots, "header-actions")
|
|
40
40
|
])
|
|
41
41
|
])
|
|
42
42
|
], 2));
|
|
43
43
|
}
|
|
44
|
-
},
|
|
44
|
+
}, ne = ["href"], re = {
|
|
45
45
|
__name: "AppHeaderLink",
|
|
46
46
|
props: {
|
|
47
47
|
to: { type: String, required: !0 }
|
|
48
48
|
},
|
|
49
49
|
setup(e) {
|
|
50
|
-
const
|
|
51
|
-
return (
|
|
52
|
-
|
|
50
|
+
const t = e;
|
|
51
|
+
return (o, r) => (s(), l("li", null, [
|
|
52
|
+
t.to.startsWith("/") ? (s(), p(u(I), {
|
|
53
53
|
key: 0,
|
|
54
54
|
class: "hover:text-primary-950 [&.router-link-active]:text-primary-950 text-xs uppercase text-neutral-600 hover:transition-all [&.router-link-active]:font-semibold",
|
|
55
|
-
to:
|
|
55
|
+
to: t.to
|
|
56
56
|
}, {
|
|
57
|
-
default:
|
|
58
|
-
i(
|
|
57
|
+
default: f(() => [
|
|
58
|
+
i(o.$slots, "default")
|
|
59
59
|
]),
|
|
60
60
|
_: 3
|
|
61
|
-
}, 8, ["to"])) : (
|
|
61
|
+
}, 8, ["to"])) : (s(), l("a", {
|
|
62
62
|
key: 1,
|
|
63
63
|
class: "hover:text-primary-950 text-xs uppercase text-neutral-600 hover:transition-all",
|
|
64
|
-
href:
|
|
64
|
+
href: t.to
|
|
65
65
|
}, [
|
|
66
|
-
i(
|
|
67
|
-
], 8,
|
|
66
|
+
i(o.$slots, "default")
|
|
67
|
+
], 8, ne))
|
|
68
68
|
]));
|
|
69
69
|
}
|
|
70
|
-
},
|
|
70
|
+
}, se = { class: "relative" }, ae = { class: "flex" }, le = {
|
|
71
71
|
__name: "AppLayout",
|
|
72
72
|
setup(e) {
|
|
73
|
-
const
|
|
74
|
-
function
|
|
75
|
-
window.innerWidth <= 640 ? (
|
|
73
|
+
const t = g(!1);
|
|
74
|
+
function o() {
|
|
75
|
+
window.innerWidth <= 640 ? (t.value = !t.value, r()) : t.value && (t.value = !1, r());
|
|
76
76
|
}
|
|
77
|
-
function
|
|
78
|
-
const
|
|
79
|
-
|
|
77
|
+
function r() {
|
|
78
|
+
const n = document.querySelector("body");
|
|
79
|
+
n.classList.contains("bg-black") ? n.classList.remove("bg-black") : n.classList.add("bg-black");
|
|
80
80
|
}
|
|
81
|
-
return
|
|
82
|
-
class:
|
|
83
|
-
"scale-93 origin-[center_top] translate-y-4":
|
|
81
|
+
return y("APP_DATA", { isSidebarToggled: t, toggleSidebar: o }), (n, a) => (s(), l("div", {
|
|
82
|
+
class: _(["bg-white transition-all duration-500 ease-[cubic-bezier(.32,.72,0,1)]", {
|
|
83
|
+
"scale-93 origin-[center_top] translate-y-4": t.value
|
|
84
84
|
}])
|
|
85
85
|
}, [
|
|
86
|
-
d("div",
|
|
87
|
-
i(
|
|
88
|
-
d("div",
|
|
89
|
-
i(
|
|
86
|
+
d("div", se, [
|
|
87
|
+
i(n.$slots, "header"),
|
|
88
|
+
d("div", ae, [
|
|
89
|
+
i(n.$slots, "content")
|
|
90
90
|
])
|
|
91
91
|
])
|
|
92
92
|
], 2));
|
|
93
93
|
}
|
|
94
|
-
},
|
|
94
|
+
}, ie = {
|
|
95
95
|
__name: "AppMain",
|
|
96
96
|
setup(e) {
|
|
97
|
-
const
|
|
98
|
-
return (
|
|
99
|
-
class:
|
|
97
|
+
const t = m("APP_DATA"), { isSidebarToggled: o } = t;
|
|
98
|
+
return (r, n) => (s(), l("main", {
|
|
99
|
+
class: _([
|
|
100
100
|
"bg-background-main fixed z-[-1] h-svh w-full overflow-auto px-6 pb-9 pt-24 sm:top-16 sm:ml-[223px] sm:h-[calc(100dvh-4rem)] sm:w-[calc(100dvw-223px)] sm:pt-9",
|
|
101
|
-
u(
|
|
101
|
+
u(o) ? "overflow-hidden rounded-t-xl sm:rounded-none" : "sm:rounded-tl-2xl"
|
|
102
102
|
])
|
|
103
103
|
}, [
|
|
104
|
-
i(
|
|
104
|
+
i(r.$slots, "default")
|
|
105
105
|
], 2));
|
|
106
106
|
}
|
|
107
|
-
},
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
resetSelectorOpacity: n
|
|
120
|
-
}), (t, s) => (a(), l("div", oe, [
|
|
121
|
-
i(t.$slots, "default"),
|
|
122
|
-
d("div", {
|
|
123
|
-
class: "bg-brand-primary-100 absolute left-0 z-[-1] h-[32px] w-10 rounded-full opacity-0 transition-all ease-in-out",
|
|
124
|
-
ref_key: "selector",
|
|
125
|
-
ref: o
|
|
126
|
-
}, null, 512)
|
|
127
|
-
]));
|
|
128
|
-
}
|
|
129
|
-
}, ne = {
|
|
107
|
+
}, b = (e, t) => {
|
|
108
|
+
const o = e.__vccOpts || e;
|
|
109
|
+
for (const [r, n] of t)
|
|
110
|
+
o[r] = n;
|
|
111
|
+
return o;
|
|
112
|
+
}, de = {}, ue = { class: "flex w-full overflow-x-auto border-b-[1px] border-neutral-200 [&::-webkit-scrollbar]:hidden" };
|
|
113
|
+
function ce(e, t) {
|
|
114
|
+
return s(), l("div", ue, [
|
|
115
|
+
i(e.$slots, "default")
|
|
116
|
+
]);
|
|
117
|
+
}
|
|
118
|
+
const pe = /* @__PURE__ */ b(de, [["render", ce]]), me = { class: "shrink-0" }, fe = {
|
|
130
119
|
__name: "AppNavTab",
|
|
131
120
|
props: {
|
|
132
121
|
to: { type: String, required: !0 }
|
|
133
122
|
},
|
|
134
123
|
setup(e) {
|
|
135
|
-
const
|
|
136
|
-
return (
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
ref_key: "tab",
|
|
141
|
-
ref: s
|
|
142
|
-
}, [
|
|
143
|
-
B(u(S), {
|
|
144
|
-
class: "[&.router-link-exact-active]:text-primary-950 [&.router-link-exact-active]:border-brand-primary-700 hover:text-brand-primary-700 [&.router-link-exact-active]:hover:text-brand-primary-700 flex h-12 shrink-0 items-center justify-between gap-2 border-b-2 border-transparent px-3 text-sm text-neutral-600 transition-all hover:font-medium [&.router-link-exact-active]:font-medium",
|
|
145
|
-
to: o.to
|
|
124
|
+
const t = e;
|
|
125
|
+
return g(null), (o, r) => (s(), l("div", me, [
|
|
126
|
+
x(u(I), {
|
|
127
|
+
class: "[&.router-link-exact-active]:text-primary-950 [&.router-link-exact-active]:border-brand-primary-700 hover:text-brand-primary-700 group relative flex h-12 shrink-0 items-center justify-between gap-2 border-b-2 border-transparent px-3 text-sm text-neutral-600 transition-all [&.router-link-exact-active]:font-medium",
|
|
128
|
+
to: t.to
|
|
146
129
|
}, {
|
|
147
|
-
default:
|
|
148
|
-
i(
|
|
130
|
+
default: f(() => [
|
|
131
|
+
i(o.$slots, "default"),
|
|
132
|
+
r[0] || (r[0] = d("div", { class: "bg-primary-100 absolute inset-x-0 z-[-1] h-8 w-full rounded-lg opacity-0 transition-all contain-strict group-hover:transform-none group-hover:opacity-100 group-hover:[transform-origin:50%_50%_0px]" }, null, -1))
|
|
149
133
|
]),
|
|
150
|
-
_: 3
|
|
134
|
+
_: 3,
|
|
135
|
+
__: [0]
|
|
151
136
|
}, 8, ["to"])
|
|
152
|
-
]
|
|
137
|
+
]));
|
|
153
138
|
}
|
|
154
|
-
},
|
|
155
|
-
const r = e.__vccOpts || e;
|
|
156
|
-
for (const [n, t] of o)
|
|
157
|
-
r[n] = t;
|
|
158
|
-
return r;
|
|
159
|
-
}, se = { class: "fixed left-0 top-0 hidden w-[223px] space-y-4 bg-white px-4 py-8 sm:top-[64px] sm:block" }, ae = {
|
|
139
|
+
}, _e = { class: "fixed left-0 top-0 hidden w-[223px] space-y-4 bg-white px-4 py-8 sm:top-[64px] sm:block" }, ge = {
|
|
160
140
|
__name: "AppSidebar",
|
|
161
141
|
setup(e) {
|
|
162
|
-
const
|
|
163
|
-
return (
|
|
164
|
-
d("aside",
|
|
165
|
-
i(
|
|
142
|
+
const t = m("APP_DATA"), { isSidebarToggled: o, toggleSidebar: r } = t;
|
|
143
|
+
return (n, a) => (s(), l(A, null, [
|
|
144
|
+
d("aside", _e, [
|
|
145
|
+
i(n.$slots, "default", {}, void 0, !0)
|
|
166
146
|
]),
|
|
167
|
-
(
|
|
147
|
+
(s(), p(B, { to: "body" }, [
|
|
168
148
|
d("div", {
|
|
169
149
|
class: "shadow-t-2xl fixed bottom-0 z-50 h-[60svh] w-full space-y-4 overflow-y-scroll rounded-t-2xl bg-white p-4 transition-all duration-500 ease-[cubic-bezier(.32,.72,0,1)] [&::-webkit-scrollbar]:hidden",
|
|
170
|
-
style:
|
|
171
|
-
u(
|
|
150
|
+
style: H(
|
|
151
|
+
u(o) ? "transform: translateZ(0)" : "transform: translate3d(0,60svh,0)"
|
|
172
152
|
)
|
|
173
153
|
}, [
|
|
174
|
-
i(
|
|
154
|
+
i(n.$slots, "default", {}, void 0, !0)
|
|
175
155
|
], 4),
|
|
176
156
|
d("div", {
|
|
177
|
-
onClick:
|
|
178
|
-
class:
|
|
157
|
+
onClick: a[0] || (a[0] = (c) => u(r)()),
|
|
158
|
+
class: _([
|
|
179
159
|
"backdrop backdrop-blur-[0.50px] transition-all duration-300 [transition-behavior:allow-discrete]",
|
|
180
|
-
u(
|
|
160
|
+
u(o) ? "fixed inset-0 z-40 block bg-black/80 opacity-100" : "hidden"
|
|
181
161
|
])
|
|
182
162
|
}, null, 2)
|
|
183
163
|
]))
|
|
184
164
|
], 64));
|
|
185
165
|
}
|
|
186
|
-
},
|
|
166
|
+
}, be = /* @__PURE__ */ b(ge, [["__scopeId", "data-v-aaece1c7"]]), he = { class: "flex flex-col" }, ve = {
|
|
187
167
|
__name: "AppSidebarItem",
|
|
188
168
|
setup(e) {
|
|
189
|
-
|
|
190
|
-
const
|
|
191
|
-
function
|
|
192
|
-
|
|
169
|
+
j();
|
|
170
|
+
const t = g(!1);
|
|
171
|
+
function o() {
|
|
172
|
+
t.value = !t.value;
|
|
193
173
|
}
|
|
194
|
-
return
|
|
195
|
-
i(
|
|
174
|
+
return y("SIDEBAR_TOGGLE", { toggled: t, toggleSidebarItem: o }), (r, n) => (s(), l("div", he, [
|
|
175
|
+
i(r.$slots, "default")
|
|
196
176
|
]));
|
|
197
177
|
}
|
|
198
|
-
},
|
|
178
|
+
}, xe = ["to"], ke = {
|
|
199
179
|
__name: "AppSidebarItemChild",
|
|
200
180
|
props: {
|
|
201
181
|
to: { type: String, required: !0 }
|
|
202
182
|
},
|
|
203
183
|
setup(e) {
|
|
204
|
-
const
|
|
205
|
-
return (
|
|
184
|
+
const t = e;
|
|
185
|
+
return (o, r) => t.to.startsWith("/") ? (s(), p(u(I), {
|
|
206
186
|
key: 0,
|
|
207
187
|
class: "[&.router-link-exact-active]:text-primary-950 [&.router-link-exact-active]:bg-background-main text-primary-950 hover:bg-background-main block h-10 items-center gap-3 overflow-hidden text-ellipsis whitespace-nowrap rounded-lg px-3 text-xs leading-[40px] transition-all [&.router-link-exact-active]:font-medium",
|
|
208
|
-
to:
|
|
188
|
+
to: t.to
|
|
209
189
|
}, {
|
|
210
|
-
default:
|
|
211
|
-
i(
|
|
190
|
+
default: f(() => [
|
|
191
|
+
i(o.$slots, "default")
|
|
212
192
|
]),
|
|
213
193
|
_: 3
|
|
214
|
-
}, 8, ["to"])) : (
|
|
194
|
+
}, 8, ["to"])) : (s(), l("a", {
|
|
215
195
|
key: 1,
|
|
216
196
|
class: "text-primary-950 hover:bg-background-main block h-10 items-center gap-3 overflow-hidden text-ellipsis whitespace-nowrap rounded-lg px-3 text-xs leading-[40px] transition-all",
|
|
217
|
-
to:
|
|
197
|
+
to: t.to
|
|
218
198
|
}, [
|
|
219
|
-
i(
|
|
220
|
-
], 8,
|
|
199
|
+
i(o.$slots, "default")
|
|
200
|
+
], 8, xe));
|
|
221
201
|
}
|
|
222
|
-
},
|
|
202
|
+
}, ye = {
|
|
223
203
|
__name: "AppSidebarItemChildren",
|
|
224
204
|
setup(e) {
|
|
225
|
-
const
|
|
226
|
-
return (
|
|
227
|
-
class:
|
|
205
|
+
const t = m("SIDEBAR_TOGGLE"), { toggled: o } = t;
|
|
206
|
+
return (r, n) => (s(), l("div", {
|
|
207
|
+
class: _(["max-h-0 overflow-y-hidden rounded-b-lg opacity-0 transition-all", { "mt-2 max-h-max overflow-y-auto px-2 opacity-100": u(o) }])
|
|
228
208
|
}, [
|
|
229
|
-
i(
|
|
209
|
+
i(r.$slots, "default")
|
|
230
210
|
], 2));
|
|
231
211
|
}
|
|
232
|
-
},
|
|
212
|
+
}, $e = { class: "link group/sidebar-item hover:bg-background-main has-[&.router-link-active]:bg-background-main peer flex h-10 items-center justify-between rounded-lg px-3 transition-all" }, we = ["href"], Ae = {
|
|
233
213
|
__name: "AppSidebarItemParent",
|
|
234
214
|
props: {
|
|
235
215
|
to: { type: String, required: !0 },
|
|
@@ -237,37 +217,37 @@ const O = { class: "flex w-full items-center justify-between" }, U = { class: "f
|
|
|
237
217
|
hasChildren: { type: Boolean, default: !1 }
|
|
238
218
|
},
|
|
239
219
|
setup(e) {
|
|
240
|
-
const
|
|
241
|
-
function
|
|
242
|
-
|
|
243
|
-
(
|
|
244
|
-
) ?
|
|
220
|
+
const t = j(), o = e, r = m("SIDEBAR_TOGGLE"), n = m("APP_DATA"), { toggled: a, toggleSidebarItem: c } = r, { toggleSidebar: w } = n;
|
|
221
|
+
function L() {
|
|
222
|
+
t.matched.some(
|
|
223
|
+
(h) => o.name === h.name
|
|
224
|
+
) ? a.value = !0 : a.value = !1;
|
|
245
225
|
}
|
|
246
|
-
return
|
|
247
|
-
|
|
226
|
+
return W(t, () => L(), { immediate: !0 }), (C, h) => (s(), l("div", $e, [
|
|
227
|
+
o.to.startsWith("/") ? (s(), p(u(I), {
|
|
248
228
|
key: 0,
|
|
249
|
-
onClick:
|
|
229
|
+
onClick: h[0] || (h[0] = (N) => u(w)()),
|
|
250
230
|
class: "[&.router-link-active]:text-primary-800 [&.router-link-active]:text-primary-800 text-primary-950 peer flex h-full w-full items-center gap-3 text-xs [&.router-link-active]:font-medium",
|
|
251
|
-
to:
|
|
231
|
+
to: o.to
|
|
252
232
|
}, {
|
|
253
|
-
default:
|
|
254
|
-
i(
|
|
233
|
+
default: f(() => [
|
|
234
|
+
i(C.$slots, "default", {}, void 0, !0)
|
|
255
235
|
]),
|
|
256
236
|
_: 3
|
|
257
|
-
}, 8, ["to"])) : (
|
|
237
|
+
}, 8, ["to"])) : (s(), l("a", {
|
|
258
238
|
key: 1,
|
|
259
239
|
class: "text-primary-950 peer flex h-full w-full items-center gap-3 text-xs",
|
|
260
|
-
href:
|
|
240
|
+
href: o.to
|
|
261
241
|
}, [
|
|
262
|
-
i(
|
|
263
|
-
], 8,
|
|
264
|
-
|
|
242
|
+
i(C.$slots, "default", {}, void 0, !0)
|
|
243
|
+
], 8, we)),
|
|
244
|
+
o.hasChildren ? (s(), l("button", {
|
|
265
245
|
key: 2,
|
|
266
|
-
onClick:
|
|
246
|
+
onClick: h[1] || (h[1] = (N) => u(c)()),
|
|
267
247
|
class: "cursor-pointer rounded-full p-1 transition-all hover:bg-neutral-100",
|
|
268
248
|
type: "button"
|
|
269
249
|
}, [
|
|
270
|
-
(
|
|
250
|
+
(s(), l("svg", {
|
|
271
251
|
xmlns: "http://www.w3.org/2000/svg",
|
|
272
252
|
width: "16",
|
|
273
253
|
height: "16",
|
|
@@ -277,34 +257,34 @@ const O = { class: "flex w-full items-center justify-between" }, U = { class: "f
|
|
|
277
257
|
"stroke-width": "2",
|
|
278
258
|
"stroke-linecap": "round",
|
|
279
259
|
"stroke-linejoin": "round",
|
|
280
|
-
class:
|
|
281
|
-
},
|
|
260
|
+
class: _(["lucide lucide-chevron-down-icon lucide-chevron-down stroke-primary-800 transition-all duration-300", { "rotate-180": u(a) }])
|
|
261
|
+
}, h[2] || (h[2] = [
|
|
282
262
|
d("path", { d: "m6 9 6 6 6-6" }, null, -1)
|
|
283
263
|
]), 2))
|
|
284
|
-
])) :
|
|
264
|
+
])) : v("", !0)
|
|
285
265
|
]));
|
|
286
266
|
}
|
|
287
|
-
},
|
|
267
|
+
}, Se = /* @__PURE__ */ b(Ae, [["__scopeId", "data-v-0fab71c0"]]), Te = { class: "hover:bg-background-main has-[&.router-link-active]:active has-[&.router-link-active]:bg-primary-700 peer flex h-10 items-center justify-between rounded-lg px-3 transition-all" }, Ie = {
|
|
288
268
|
__name: "AppSidebarToggle",
|
|
289
269
|
setup(e) {
|
|
290
|
-
const
|
|
291
|
-
return (
|
|
292
|
-
const
|
|
293
|
-
return
|
|
294
|
-
|
|
270
|
+
const t = m("SIDEBAR_TOGGLE");
|
|
271
|
+
return (o, r) => {
|
|
272
|
+
const n = q("RouterLink");
|
|
273
|
+
return s(), l("div", Te, [
|
|
274
|
+
x(n, {
|
|
295
275
|
class: "text-primary-950 peer flex h-full w-full items-center gap-3 text-xs [&.router-link-active]:font-medium [&.router-link-active]:text-white",
|
|
296
276
|
to: "/"
|
|
297
277
|
}, {
|
|
298
|
-
default:
|
|
299
|
-
i(
|
|
278
|
+
default: f(() => [
|
|
279
|
+
i(o.$slots, "default")
|
|
300
280
|
]),
|
|
301
281
|
_: 3
|
|
302
282
|
}),
|
|
303
283
|
d("button", {
|
|
304
|
-
onClick:
|
|
284
|
+
onClick: r[0] || (r[0] = (a) => u(t).toggleSidebarItem()),
|
|
305
285
|
class: "cursor-pointer",
|
|
306
286
|
type: "button"
|
|
307
|
-
},
|
|
287
|
+
}, r[1] || (r[1] = [
|
|
308
288
|
d("svg", {
|
|
309
289
|
xmlns: "http://www.w3.org/2000/svg",
|
|
310
290
|
width: "16",
|
|
@@ -323,33 +303,33 @@ const O = { class: "flex w-full items-center justify-between" }, U = { class: "f
|
|
|
323
303
|
]);
|
|
324
304
|
};
|
|
325
305
|
}
|
|
326
|
-
},
|
|
306
|
+
}, Ce = {}, De = {
|
|
327
307
|
key: 0,
|
|
328
308
|
class: "text-primary-950 px-1 text-sm font-medium"
|
|
329
|
-
},
|
|
330
|
-
function
|
|
331
|
-
return
|
|
332
|
-
e.$slots.title ? (
|
|
309
|
+
}, Be = { class: "mt-2" };
|
|
310
|
+
function Me(e, t) {
|
|
311
|
+
return s(), l("nav", null, [
|
|
312
|
+
e.$slots.title ? (s(), l("b", De, [
|
|
333
313
|
i(e.$slots, "title")
|
|
334
|
-
])) :
|
|
335
|
-
d("div",
|
|
314
|
+
])) : v("", !0),
|
|
315
|
+
d("div", Be, [
|
|
336
316
|
i(e.$slots, "items")
|
|
337
317
|
])
|
|
338
318
|
]);
|
|
339
319
|
}
|
|
340
|
-
const
|
|
341
|
-
function
|
|
342
|
-
return
|
|
320
|
+
const Ve = /* @__PURE__ */ b(Ce, [["render", Me]]), Le = {}, Pe = { class: "rounded-full px-3 py-1 text-xs font-medium" };
|
|
321
|
+
function Re(e, t) {
|
|
322
|
+
return s(), l("div", Pe, [
|
|
343
323
|
i(e.$slots, "default")
|
|
344
324
|
]);
|
|
345
325
|
}
|
|
346
|
-
const
|
|
326
|
+
const Ee = /* @__PURE__ */ b(Le, [["render", Re]]), Ge = {
|
|
347
327
|
__name: "Button",
|
|
348
328
|
props: {
|
|
349
329
|
variant: { type: String, default: "primary" }
|
|
350
330
|
},
|
|
351
331
|
setup(e) {
|
|
352
|
-
const
|
|
332
|
+
const t = e, o = {
|
|
353
333
|
primary: [
|
|
354
334
|
"bg-brand-primary-700",
|
|
355
335
|
"text-white",
|
|
@@ -370,19 +350,19 @@ const Ie = /* @__PURE__ */ v(Ae, [["render", Se]]), Te = {
|
|
|
370
350
|
"hover:bg-danger-600-hovered"
|
|
371
351
|
]
|
|
372
352
|
};
|
|
373
|
-
return (
|
|
374
|
-
class: ["cursor-pointer rounded-lg px-4 py-2 text-xs transition-all disabled:cursor-not-allowed disabled:opacity-50",
|
|
353
|
+
return (r, n) => (s(), l("button", k(r.$attrs, {
|
|
354
|
+
class: ["cursor-pointer rounded-lg px-4 py-2 text-xs transition-all disabled:cursor-not-allowed disabled:opacity-50", o[t.variant]]
|
|
375
355
|
}), [
|
|
376
|
-
i(
|
|
356
|
+
i(r.$slots, "default")
|
|
377
357
|
], 16));
|
|
378
358
|
}
|
|
379
|
-
},
|
|
380
|
-
function
|
|
381
|
-
return
|
|
359
|
+
}, ze = {}, je = { class: "rounded-2xl bg-white p-6" };
|
|
360
|
+
function Ne(e, t) {
|
|
361
|
+
return s(), l("div", je, [
|
|
382
362
|
i(e.$slots, "default")
|
|
383
363
|
]);
|
|
384
364
|
}
|
|
385
|
-
const
|
|
365
|
+
const M = /* @__PURE__ */ b(ze, [["render", Ne]]), He = {
|
|
386
366
|
__name: "Checkbox",
|
|
387
367
|
props: {
|
|
388
368
|
modelValue: {},
|
|
@@ -390,12 +370,12 @@ const De = /* @__PURE__ */ v(Ce, [["render", Ve]]), Le = {
|
|
|
390
370
|
},
|
|
391
371
|
emits: ["update:modelValue"],
|
|
392
372
|
setup(e) {
|
|
393
|
-
const
|
|
394
|
-
return (
|
|
395
|
-
onClick:
|
|
373
|
+
const t = T(e, "modelValue"), o = g(null);
|
|
374
|
+
return (r, n) => (s(), l("button", {
|
|
375
|
+
onClick: n[1] || (n[1] = (a) => o.value.click()),
|
|
396
376
|
class: "group/checkbox bg-neutral-100 has-checked:bg-primary-700 flex size-4 cursor-pointer items-center justify-center rounded-sm transition-all"
|
|
397
377
|
}, [
|
|
398
|
-
|
|
378
|
+
n[2] || (n[2] = d("svg", {
|
|
399
379
|
xmlns: "http://www.w3.org/2000/svg",
|
|
400
380
|
width: "14",
|
|
401
381
|
height: "14",
|
|
@@ -409,48 +389,106 @@ const De = /* @__PURE__ */ v(Ce, [["render", Ve]]), Le = {
|
|
|
409
389
|
}, [
|
|
410
390
|
d("path", { d: "M20 6 9 17l-5-5" })
|
|
411
391
|
], -1)),
|
|
412
|
-
|
|
413
|
-
"onUpdate:modelValue":
|
|
392
|
+
$(d("input", k(r.$attrs, {
|
|
393
|
+
"onUpdate:modelValue": n[0] || (n[0] = (a) => t.value = a),
|
|
414
394
|
type: "checkbox",
|
|
415
395
|
ref_key: "checkboxRef",
|
|
416
|
-
ref:
|
|
396
|
+
ref: o,
|
|
417
397
|
hidden: ""
|
|
418
398
|
}), null, 16), [
|
|
419
|
-
[
|
|
399
|
+
[O, t.value]
|
|
420
400
|
])
|
|
421
401
|
]));
|
|
422
402
|
}
|
|
423
|
-
},
|
|
403
|
+
}, We = {
|
|
404
|
+
__name: "Dialog",
|
|
405
|
+
setup(e) {
|
|
406
|
+
const t = g(!1);
|
|
407
|
+
function o() {
|
|
408
|
+
t.value = !t.value;
|
|
409
|
+
}
|
|
410
|
+
return y("DIALOG_META", { toggled: t, toggleDialog: o }), (r, n) => i(r.$slots, "default");
|
|
411
|
+
}
|
|
412
|
+
}, qe = { class: "pointer-events-auto fixed inset-0 z-[500] min-h-screen bg-black/80 backdrop-blur-[2px]" }, V = {
|
|
424
413
|
__name: "DialogBackground",
|
|
425
414
|
setup(e) {
|
|
426
|
-
return
|
|
415
|
+
return U(() => {
|
|
427
416
|
document.querySelector("body").classList.add("overflow-hidden");
|
|
428
|
-
}),
|
|
417
|
+
}), Z(() => {
|
|
429
418
|
document.querySelector("body").classList.remove("overflow-hidden");
|
|
430
|
-
}), (
|
|
431
|
-
i(
|
|
419
|
+
}), (t, o) => (s(), l("div", qe, [
|
|
420
|
+
i(t.$slots, "default")
|
|
421
|
+
]));
|
|
422
|
+
}
|
|
423
|
+
}, Oe = {
|
|
424
|
+
__name: "DialogContent",
|
|
425
|
+
props: {
|
|
426
|
+
class: { type: String }
|
|
427
|
+
},
|
|
428
|
+
setup(e) {
|
|
429
|
+
const t = e, { toggled: o, toggleDialog: r } = m("DIALOG_META");
|
|
430
|
+
return (n, a) => (s(), p(B, { to: "body" }, [
|
|
431
|
+
x(S, { name: "fade-in" }, {
|
|
432
|
+
default: f(() => [
|
|
433
|
+
u(o) ? (s(), p(V, {
|
|
434
|
+
key: 0,
|
|
435
|
+
onClick: a[0] || (a[0] = (c) => u(r)())
|
|
436
|
+
})) : v("", !0)
|
|
437
|
+
]),
|
|
438
|
+
_: 1
|
|
439
|
+
}),
|
|
440
|
+
x(S, { name: "fade-in-dialog" }, {
|
|
441
|
+
default: f(() => [
|
|
442
|
+
u(o) ? (s(), p(M, {
|
|
443
|
+
key: 0,
|
|
444
|
+
class: _(["fixed left-1/2 top-1/2 z-[600] -translate-x-1/2 -translate-y-1/2 rounded-xl bg-white transition-all", t.class])
|
|
445
|
+
}, {
|
|
446
|
+
default: f(() => [
|
|
447
|
+
i(n.$slots, "default")
|
|
448
|
+
]),
|
|
449
|
+
_: 3
|
|
450
|
+
}, 8, ["class"])) : v("", !0)
|
|
451
|
+
]),
|
|
452
|
+
_: 3
|
|
453
|
+
})
|
|
432
454
|
]));
|
|
433
455
|
}
|
|
434
|
-
},
|
|
456
|
+
}, Ue = {
|
|
457
|
+
__name: "DialogToggle",
|
|
458
|
+
setup(e) {
|
|
459
|
+
const t = R(), { toggleDialog: o } = m("DIALOG_META");
|
|
460
|
+
return (r, n) => {
|
|
461
|
+
var a, c;
|
|
462
|
+
return s(), p(E(
|
|
463
|
+
G((c = (a = u(t)).default) == null ? void 0 : c.call(a)[0], {
|
|
464
|
+
onClick: u(o)
|
|
465
|
+
})
|
|
466
|
+
));
|
|
467
|
+
};
|
|
468
|
+
}
|
|
469
|
+
}, Ze = {
|
|
435
470
|
__name: "Input",
|
|
436
|
-
props:
|
|
471
|
+
props: {
|
|
472
|
+
modelValue: {},
|
|
473
|
+
modelModifiers: {}
|
|
474
|
+
},
|
|
475
|
+
emits: ["update:modelValue"],
|
|
437
476
|
setup(e) {
|
|
438
|
-
const
|
|
439
|
-
return (
|
|
440
|
-
"onUpdate:modelValue":
|
|
441
|
-
onInput: t[1] || (t[1] = (s) => n.$emit("update:modelValue", s.target.value)),
|
|
477
|
+
const t = T(e, "modelValue");
|
|
478
|
+
return (o, r) => $((s(), l("input", {
|
|
479
|
+
"onUpdate:modelValue": r[0] || (r[0] = (n) => t.value = n),
|
|
442
480
|
class: "text-primary-950 focus:ring-primary-700 neutral-400:text-neutral-400 rounded-lg border-[1px] border-neutral-200 bg-white px-3 py-2 text-xs outline-none transition-all focus:ring-2 focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50"
|
|
443
|
-
}, null,
|
|
444
|
-
[
|
|
481
|
+
}, null, 512)), [
|
|
482
|
+
[z, t.value]
|
|
445
483
|
]);
|
|
446
484
|
}
|
|
447
|
-
},
|
|
448
|
-
function
|
|
449
|
-
return
|
|
485
|
+
}, Je = {};
|
|
486
|
+
function Ye(e, t) {
|
|
487
|
+
return s(), l("label", k(e.$attrs, { class: "text-primary-950 text-xs transition-all" }), [
|
|
450
488
|
i(e.$slots, "default")
|
|
451
489
|
], 16);
|
|
452
490
|
}
|
|
453
|
-
const
|
|
491
|
+
const Fe = /* @__PURE__ */ b(Je, [["render", Ye]]), Xe = {
|
|
454
492
|
__name: "Radio",
|
|
455
493
|
props: {
|
|
456
494
|
modelValue: {},
|
|
@@ -458,153 +496,246 @@ const Ge = /* @__PURE__ */ v(Ne, [["render", je]]), ze = {
|
|
|
458
496
|
},
|
|
459
497
|
emits: ["update:modelValue"],
|
|
460
498
|
setup(e) {
|
|
461
|
-
const
|
|
462
|
-
return (
|
|
463
|
-
onClick:
|
|
499
|
+
const t = T(e, "modelValue"), o = g(null);
|
|
500
|
+
return (r, n) => (s(), l("button", {
|
|
501
|
+
onClick: n[1] || (n[1] = (a) => o.value.click()),
|
|
464
502
|
class: "group/radio bg-neutral-100 has-checked:bg-white has-checked:border-primary-700 flex size-4 cursor-pointer items-center justify-center rounded-full border-[1px] border-transparent"
|
|
465
503
|
}, [
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
"onUpdate:modelValue":
|
|
504
|
+
n[2] || (n[2] = d("div", { class: "group-has-checked/radio:bg-primary-700 group-has-checked/radio:opacity-100 size-[10px] rounded-full opacity-0 transition-all" }, null, -1)),
|
|
505
|
+
$(d("input", k(r.$attrs, {
|
|
506
|
+
"onUpdate:modelValue": n[0] || (n[0] = (a) => t.value = a),
|
|
469
507
|
type: "radio",
|
|
470
508
|
ref_key: "radioRef",
|
|
471
|
-
ref:
|
|
509
|
+
ref: o,
|
|
472
510
|
hidden: ""
|
|
473
511
|
}), null, 16), [
|
|
474
|
-
[
|
|
512
|
+
[J, t.value]
|
|
475
513
|
])
|
|
476
514
|
]));
|
|
477
515
|
}
|
|
478
|
-
},
|
|
516
|
+
}, Qe = "bg-[url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSJub25lIiBzdHJva2U9IiM1YjYxNmUiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIiBjbGFzcz0ibHVjaWRlIGx1Y2lkZS1jaGV2cm9uLWRvd24iPjxwYXRoIGQ9Im02IDkgNiA2IDYtNiIvPjwvc3ZnPg==')]", Ke = {
|
|
479
517
|
__name: "Select",
|
|
518
|
+
props: {
|
|
519
|
+
modelValue: {},
|
|
520
|
+
modelModifiers: {}
|
|
521
|
+
},
|
|
522
|
+
emits: ["update:modelValue"],
|
|
480
523
|
setup(e) {
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
524
|
+
const t = T(e, "modelValue");
|
|
525
|
+
return (o, r) => $((s(), l("select", k(o.$attrs, {
|
|
526
|
+
"onUpdate:modelValue": r[0] || (r[0] = (n) => t.value = n),
|
|
527
|
+
class: ["text-primary-950 focus:ring-primary-700 appearance-none rounded-lg border-[1px] border-neutral-200 bg-white bg-[length:16px] bg-[right_12px_center] bg-no-repeat px-3 py-2 text-xs outline-none transition-all focus:ring-2 focus:ring-offset-2", Qe]
|
|
484
528
|
}), [
|
|
485
529
|
i(o.$slots, "default")
|
|
486
|
-
], 16))
|
|
530
|
+
], 16)), [
|
|
531
|
+
[Y, t.value]
|
|
532
|
+
]);
|
|
533
|
+
}
|
|
534
|
+
}, et = {
|
|
535
|
+
__name: "Sheet",
|
|
536
|
+
setup(e) {
|
|
537
|
+
const t = g(!1);
|
|
538
|
+
function o() {
|
|
539
|
+
t.value = !t.value;
|
|
540
|
+
}
|
|
541
|
+
return y("SHEET_META", { toggled: t, toggleSheet: o }), (r, n) => i(r.$slots, "default");
|
|
542
|
+
}
|
|
543
|
+
}, tt = {
|
|
544
|
+
__name: "SheetContent",
|
|
545
|
+
props: {
|
|
546
|
+
class: { type: String }
|
|
547
|
+
},
|
|
548
|
+
setup(e) {
|
|
549
|
+
const t = e, { toggled: o, toggleSheet: r } = m("SHEET_META");
|
|
550
|
+
return (n, a) => (s(), p(B, { to: "body" }, [
|
|
551
|
+
x(S, { name: "fade-in" }, {
|
|
552
|
+
default: f(() => [
|
|
553
|
+
u(o) ? (s(), p(V, {
|
|
554
|
+
key: 0,
|
|
555
|
+
onClick: a[0] || (a[0] = (c) => u(r)())
|
|
556
|
+
})) : v("", !0)
|
|
557
|
+
]),
|
|
558
|
+
_: 1
|
|
559
|
+
}),
|
|
560
|
+
x(S, { name: "slide" }, {
|
|
561
|
+
default: f(() => [
|
|
562
|
+
u(o) ? (s(), p(M, {
|
|
563
|
+
key: 0,
|
|
564
|
+
class: _(["fixed right-0 top-1/2 z-[600] h-full w-3/4 -translate-y-1/2 rounded-e-none bg-white transition-all md:right-[1rem] md:h-[calc(100dvh-2rem)] md:w-96 md:rounded-xl", t.class])
|
|
565
|
+
}, {
|
|
566
|
+
default: f(() => [
|
|
567
|
+
i(n.$slots, "default")
|
|
568
|
+
]),
|
|
569
|
+
_: 3
|
|
570
|
+
}, 8, ["class"])) : v("", !0)
|
|
571
|
+
]),
|
|
572
|
+
_: 3
|
|
573
|
+
})
|
|
574
|
+
]));
|
|
575
|
+
}
|
|
576
|
+
}, ot = {
|
|
577
|
+
__name: "SheetToggle",
|
|
578
|
+
setup(e) {
|
|
579
|
+
const t = R(), { toggleSheet: o } = m("SHEET_META");
|
|
580
|
+
return (r, n) => {
|
|
581
|
+
var a, c;
|
|
582
|
+
return s(), p(E(
|
|
583
|
+
G((c = (a = u(t)).default) == null ? void 0 : c.call(a)[0], {
|
|
584
|
+
onClick: u(o)
|
|
585
|
+
})
|
|
586
|
+
));
|
|
587
|
+
};
|
|
487
588
|
}
|
|
488
|
-
},
|
|
589
|
+
}, nt = {}, rt = { class: "bg-primary-100 animate-pulse rounded-lg" };
|
|
590
|
+
function st(e, t) {
|
|
591
|
+
return s(), l("div", rt);
|
|
592
|
+
}
|
|
593
|
+
const at = /* @__PURE__ */ b(nt, [["render", st]]), lt = {
|
|
594
|
+
__name: "Switch",
|
|
595
|
+
setup(e) {
|
|
596
|
+
const t = g(!1);
|
|
597
|
+
function o() {
|
|
598
|
+
t.value = !t.value;
|
|
599
|
+
}
|
|
600
|
+
return (r, n) => (s(), l("button", {
|
|
601
|
+
onClick: n[0] || (n[0] = (a) => o()),
|
|
602
|
+
class: _(["h-6 w-11 cursor-pointer rounded-full p-0.5 transition-colors disabled:cursor-not-allowed disabled:opacity-50", t.value ? "bg-brand-primary-700" : "bg-neutral-100"]),
|
|
603
|
+
role: "switch",
|
|
604
|
+
type: "button"
|
|
605
|
+
}, [
|
|
606
|
+
d("span", {
|
|
607
|
+
class: _(["pointer-events-none block size-5 rounded-full bg-white shadow-md transition-transform", { "translate-x-full": t.value }])
|
|
608
|
+
}, null, 2)
|
|
609
|
+
], 2));
|
|
610
|
+
}
|
|
611
|
+
}, it = { class: "w-full" }, dt = { class: "h-16" }, ut = { key: 0 }, ct = {
|
|
489
612
|
key: 0,
|
|
490
613
|
class: "pe-4"
|
|
491
|
-
},
|
|
614
|
+
}, pt = {
|
|
492
615
|
__name: "Table",
|
|
493
616
|
props: {
|
|
494
617
|
columns: { type: Array, required: !0 },
|
|
495
618
|
data: { type: Array, required: !0 }
|
|
496
619
|
},
|
|
497
620
|
setup(e) {
|
|
498
|
-
const
|
|
499
|
-
return (
|
|
621
|
+
const t = e;
|
|
622
|
+
return (o, r) => (s(), l("table", it, [
|
|
500
623
|
d("thead", null, [
|
|
501
|
-
d("tr",
|
|
502
|
-
(
|
|
503
|
-
key:
|
|
624
|
+
d("tr", dt, [
|
|
625
|
+
(s(!0), l(A, null, D(t.columns, (n) => (s(), l("th", {
|
|
626
|
+
key: n.key,
|
|
504
627
|
class: "text-xs font-medium text-neutral-600 first-of-type:ps-4"
|
|
505
|
-
},
|
|
506
|
-
|
|
628
|
+
}, P(n.label), 1))), 128)),
|
|
629
|
+
o.$slots.actions ? (s(), l("th", ut)) : v("", !0)
|
|
507
630
|
])
|
|
508
631
|
]),
|
|
509
632
|
d("tbody", null, [
|
|
510
|
-
(
|
|
511
|
-
key:
|
|
633
|
+
(s(!0), l(A, null, D(t.data, (n, a) => (s(), l("tr", {
|
|
634
|
+
key: a,
|
|
512
635
|
class: "odd:bg-background-main/50 hover:bg-background-main min-h-16 rounded-md transition-all"
|
|
513
636
|
}, [
|
|
514
|
-
(
|
|
637
|
+
(s(!0), l(A, null, D(t.columns, (c) => (s(), l("td", {
|
|
515
638
|
key: c.key,
|
|
516
639
|
class: "text-primary-950 py-4 text-xs first-of-type:rounded-s-md first-of-type:ps-4 last-of-type:rounded-e-md last-of-type:pe-4"
|
|
517
640
|
}, [
|
|
518
|
-
i(
|
|
519
|
-
|
|
641
|
+
i(o.$slots, c.key, { row: n }, () => [
|
|
642
|
+
F(P(n[c.key]), 1)
|
|
520
643
|
])
|
|
521
644
|
]))), 128)),
|
|
522
|
-
|
|
523
|
-
i(
|
|
524
|
-
])) :
|
|
645
|
+
o.$slots.actions ? (s(), l("td", ct, [
|
|
646
|
+
i(o.$slots, "actions", { row: n })
|
|
647
|
+
])) : v("", !0)
|
|
525
648
|
]))), 128))
|
|
526
649
|
])
|
|
527
650
|
]));
|
|
528
651
|
}
|
|
529
|
-
},
|
|
652
|
+
}, mt = { class: "overflow-x-scroll rounded-xl bg-neutral-100/50 p-1 [&::-webkit-scrollbar]:hidden" }, ft = {
|
|
530
653
|
__name: "Tabs",
|
|
531
654
|
props: {
|
|
532
655
|
default: { default: null }
|
|
533
656
|
},
|
|
534
657
|
setup(e) {
|
|
535
|
-
const
|
|
536
|
-
function n
|
|
537
|
-
|
|
658
|
+
const o = g(e.default);
|
|
659
|
+
function r(n) {
|
|
660
|
+
o.value = n;
|
|
538
661
|
}
|
|
539
|
-
return
|
|
540
|
-
i(
|
|
662
|
+
return y("TAB_DATA", { currentValue: o, setCurrentValue: r }), (n, a) => (s(), l("div", mt, [
|
|
663
|
+
i(n.$slots, "default")
|
|
541
664
|
]));
|
|
542
665
|
}
|
|
543
|
-
},
|
|
666
|
+
}, _t = {
|
|
544
667
|
__name: "TabItem",
|
|
545
668
|
props: {
|
|
546
669
|
value: { required: !0 }
|
|
547
670
|
},
|
|
548
671
|
setup(e) {
|
|
549
|
-
const
|
|
672
|
+
const t = e, o = m("TAB_DATA"), { currentValue: r, setCurrentValue: n } = o, a = X(() => r.value === t.value ? [
|
|
550
673
|
"bg-white",
|
|
551
674
|
"font-medium",
|
|
552
675
|
"text-primary-700",
|
|
553
676
|
"shadow-xl",
|
|
554
677
|
"tab-active"
|
|
555
678
|
] : "text-neutral-600");
|
|
556
|
-
return (c,
|
|
557
|
-
onClick:
|
|
558
|
-
class:
|
|
679
|
+
return (c, w) => (s(), l("button", {
|
|
680
|
+
onClick: w[0] || (w[0] = (L) => u(n)(t.value)),
|
|
681
|
+
class: _(["tab h-8 cursor-pointer rounded-lg px-3 text-xs transition-all disabled:cursor-not-allowed disabled:opacity-50", a.value])
|
|
559
682
|
}, [
|
|
560
683
|
i(c.$slots, "default", {}, void 0, !0)
|
|
561
684
|
], 2));
|
|
562
685
|
}
|
|
563
|
-
},
|
|
686
|
+
}, gt = /* @__PURE__ */ b(_t, [["__scopeId", "data-v-9e06f71f"]]), bt = {
|
|
564
687
|
__name: "TextArea",
|
|
565
688
|
props: ["modelValue"],
|
|
566
689
|
setup(e) {
|
|
567
|
-
const
|
|
568
|
-
return (
|
|
569
|
-
onInput:
|
|
570
|
-
},
|
|
571
|
-
"onUpdate:modelValue":
|
|
690
|
+
const o = g(e.modelValue);
|
|
691
|
+
return (r, n) => $((s(), l("textarea", k({
|
|
692
|
+
onInput: n[0] || (n[0] = (a) => r.$emit("update:modelValue", a.target.value))
|
|
693
|
+
}, r.$attrs, {
|
|
694
|
+
"onUpdate:modelValue": n[1] || (n[1] = (a) => o.value = a),
|
|
572
695
|
class: "border-neutral-200 text-primary-950 neutral-400:text-neutral-400 focus:ring-primary-700 rounded-lg border-[1px] px-3 py-2 text-xs outline-none transition-all focus:ring-2 focus:ring-offset-2"
|
|
573
696
|
}), null, 16)), [
|
|
574
|
-
[
|
|
697
|
+
[z, o.value]
|
|
575
698
|
]);
|
|
576
699
|
}
|
|
577
|
-
},
|
|
700
|
+
}, xt = {
|
|
578
701
|
install(e) {
|
|
579
|
-
e.component("AppHeader",
|
|
702
|
+
e.component("AppHeader", oe), e.component("AppHeaderLink", re), e.component("AppLayout", le), e.component("AppMain", ie), e.component("AppNavTabs", pe), e.component("AppNavTab", fe), e.component("AppSidebar", be), e.component("AppSidebarItem", ve), e.component("AppSidebarItemChild", ke), e.component("AppSidebarItemChildren", ye), e.component("AppSidebarItemParent", Se), e.component("AppSidebarToggle", Ie), e.component("AppSidebarNavSection", Ve), e.component("Badge", Ee), e.component("Button", Ge), e.component("Checkbox", He), e.component("Card", M), e.component("Dialog", We), e.component("DialogContent", Oe), e.component("DialogToggle", Ue), e.component("DialogBackground", V), e.component("Input", Ze), e.component("Label", Fe), e.component("Radio", Xe), e.component("Select", Ke), e.component("Sheet", et), e.component("SheetContent", tt), e.component("SheetToggle", ot), e.component("SkeletonLoader", at), e.component("Switch", lt), e.component("Table", pt), e.component("Tabs", ft), e.component("TabItem", gt), e.component("TextArea", bt);
|
|
580
703
|
}
|
|
581
704
|
};
|
|
582
705
|
export {
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
tt as
|
|
706
|
+
oe as AppHeader,
|
|
707
|
+
re as AppHeaderLink,
|
|
708
|
+
le as AppLayout,
|
|
709
|
+
ie as AppMain,
|
|
710
|
+
fe as AppNavTab,
|
|
711
|
+
pe as AppNavTabs,
|
|
712
|
+
be as AppSidebar,
|
|
713
|
+
ve as AppSidebarItem,
|
|
714
|
+
ke as AppSidebarItemChild,
|
|
715
|
+
ye as AppSidebarItemChildren,
|
|
716
|
+
Se as AppSidebarItemParent,
|
|
717
|
+
Ve as AppSidebarNavSection,
|
|
718
|
+
Ie as AppSidebarToggle,
|
|
719
|
+
Ee as Badge,
|
|
720
|
+
Ge as Button,
|
|
721
|
+
M as Card,
|
|
722
|
+
He as Checkbox,
|
|
723
|
+
We as Dialog,
|
|
724
|
+
V as DialogBackground,
|
|
725
|
+
Oe as DialogContent,
|
|
726
|
+
Ue as DialogToggle,
|
|
727
|
+
Ze as Input,
|
|
728
|
+
Fe as Label,
|
|
729
|
+
Xe as Radio,
|
|
730
|
+
Ke as Select,
|
|
731
|
+
et as Sheet,
|
|
732
|
+
tt as SheetContent,
|
|
733
|
+
ot as SheetToggle,
|
|
734
|
+
at as SkeletonLoader,
|
|
735
|
+
lt as Switch,
|
|
736
|
+
gt as TabItem,
|
|
737
|
+
pt as Table,
|
|
738
|
+
ft as Tabs,
|
|
739
|
+
bt as TextArea,
|
|
740
|
+
xt as default
|
|
610
741
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(s,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("vue-router")):typeof define=="function"&&define.amd?define(["exports","vue","vue-router"],e):(s=typeof globalThis<"u"?globalThis:s||self,e(s.ScrubbedTailwindComponentsV2={},s.Vue,s.vueRouter))})(this,function(s,e,m){"use strict";const W={class:"flex w-full items-center justify-between"},H={class:"flex items-center gap-2"},q={class:"flex items-center gap-10"},O={class:"hidden gap-6 sm:flex"},b={__name:"AppHeader",setup(t){const o=e.inject("APP_DATA"),{isSidebarToggled:n,toggleSidebar:l}=o;return(r,a)=>(e.openBlock(),e.createElementBlock("header",{class:e.normalizeClass(["fixed flex h-16 w-dvw items-center bg-white/50 px-3 backdrop-blur sm:px-6",{"rounded-t-2xl":e.unref(n)}])},[e.createElementVNode("nav",W,[e.createElementVNode("div",H,[e.createElementVNode("button",{onClick:a[0]||(a[0]=i=>e.unref(l)()),class:"block cursor-pointer rounded-full p-2 hover:bg-neutral-100 sm:hidden"},a[1]||(a[1]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:"lucide lucide-menu-icon lucide-menu size-5 stroke-neutral-600"},[e.createElementVNode("path",{d:"M4 12h16"}),e.createElementVNode("path",{d:"M4 18h16"}),e.createElementVNode("path",{d:"M4 6h16"})],-1)])),e.renderSlot(r.$slots,"header-img")]),e.createElementVNode("div",q,[e.createElementVNode("ul",O,[e.renderSlot(r.$slots,"header-links")]),e.renderSlot(r.$slots,"header-actions")])])],2))}},U=["href"],k={__name:"AppHeaderLink",props:{to:{type:String,required:!0}},setup(t){const o=t;return(n,l)=>(e.openBlock(),e.createElementBlock("li",null,[o.to.startsWith("/")?(e.openBlock(),e.createBlock(e.unref(m.RouterLink),{key:0,class:"hover:text-primary-950 [&.router-link-active]:text-primary-950 text-xs uppercase text-neutral-600 hover:transition-all [&.router-link-active]:font-semibold",to:o.to},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},8,["to"])):(e.openBlock(),e.createElementBlock("a",{key:1,class:"hover:text-primary-950 text-xs uppercase text-neutral-600 hover:transition-all",href:o.to},[e.renderSlot(n.$slots,"default")],8,U))]))}},Z={class:"relative"},J={class:"flex"},h={__name:"AppLayout",setup(t){const o=e.ref(!1);function n(){window.innerWidth<=640?(o.value=!o.value,l()):o.value&&(o.value=!1,l())}function l(){const r=document.querySelector("body");r.classList.contains("bg-black")?r.classList.remove("bg-black"):r.classList.add("bg-black")}return e.provide("APP_DATA",{isSidebarToggled:o,toggleSidebar:n}),(r,a)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["bg-white transition-all duration-500 ease-[cubic-bezier(.32,.72,0,1)]",{"scale-93 origin-[center_top] translate-y-4":o.value}])},[e.createElementVNode("div",Z,[e.renderSlot(r.$slots,"header"),e.createElementVNode("div",J,[e.renderSlot(r.$slots,"content")])])],2))}},_={__name:"AppMain",setup(t){const o=e.inject("APP_DATA"),{isSidebarToggled:n}=o;return(l,r)=>(e.openBlock(),e.createElementBlock("main",{class:e.normalizeClass(["bg-background-main fixed z-[-1] h-svh w-full overflow-auto px-6 pb-9 pt-24 sm:top-16 sm:ml-[223px] sm:h-[calc(100dvh-4rem)] sm:w-[calc(100dvw-223px)] sm:pt-9",e.unref(n)?"overflow-hidden rounded-t-xl sm:rounded-none":"sm:rounded-tl-2xl"])},[e.renderSlot(l.$slots,"default")],2))}},Y={class:"group flex w-full overflow-x-auto border-b-[1px] border-neutral-200"},g={__name:"AppNavTabs",setup(t){const o=e.ref(null);function n(r,a,i){o.value.style=`left: ${r}px; top: calc(${a}px + 6px); opacity: 1; width: ${i}px`}function l(r,a,i){o.value.style=`left: ${r}px; top: calc(${a}px + 6px); opacity: 0; width: ${i}px`}return e.provide("NAV_TABS",{setSelectorAttributes:n,resetSelectorOpacity:l}),(r,a)=>(e.openBlock(),e.createElementBlock("div",Y,[e.renderSlot(r.$slots,"default"),e.createElementVNode("div",{class:"bg-brand-primary-100 absolute left-0 z-[-1] h-[32px] w-10 rounded-full opacity-0 transition-all ease-in-out",ref_key:"selector",ref:o},null,512)]))}},x={__name:"AppNavTab",props:{to:{type:String,required:!0}},setup(t){const o=t,n=e.inject("NAV_TABS"),{setSelectorAttributes:l,resetSelectorOpacity:r}=n,a=e.ref(null);return(i,c)=>(e.openBlock(),e.createElementBlock("div",{onMouseover:c[0]||(c[0]=u=>e.unref(l)(a.value.offsetLeft,a.value.offsetTop,a.value.clientWidth)),onMouseleave:c[1]||(c[1]=u=>e.unref(r)(a.value.offsetLeft,a.value.offsetTop,a.value.clientWidth)),class:"shrink-0",ref_key:"tab",ref:a},[e.createVNode(e.unref(m.RouterLink),{class:"[&.router-link-exact-active]:text-primary-950 [&.router-link-exact-active]:border-brand-primary-700 hover:text-brand-primary-700 [&.router-link-exact-active]:hover:text-brand-primary-700 flex h-12 shrink-0 items-center justify-between gap-2 border-b-2 border-transparent px-3 text-sm text-neutral-600 transition-all hover:font-medium [&.router-link-exact-active]:font-medium",to:o.to},{default:e.withCtx(()=>[e.renderSlot(i.$slots,"default")]),_:3},8,["to"])],544))}},p=(t,o)=>{const n=t.__vccOpts||t;for(const[l,r]of o)n[l]=r;return n},F={class:"fixed left-0 top-0 hidden w-[223px] space-y-4 bg-white px-4 py-8 sm:top-[64px] sm:block"},y=p({__name:"AppSidebar",setup(t){const o=e.inject("APP_DATA"),{isSidebarToggled:n,toggleSidebar:l}=o;return(r,a)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("aside",F,[e.renderSlot(r.$slots,"default",{},void 0,!0)]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createElementVNode("div",{class:"shadow-t-2xl fixed bottom-0 z-50 h-[60svh] w-full space-y-4 overflow-y-scroll rounded-t-2xl bg-white p-4 transition-all duration-500 ease-[cubic-bezier(.32,.72,0,1)] [&::-webkit-scrollbar]:hidden",style:e.normalizeStyle(e.unref(n)?"transform: translateZ(0)":"transform: translate3d(0,60svh,0)")},[e.renderSlot(r.$slots,"default",{},void 0,!0)],4),e.createElementVNode("div",{onClick:a[0]||(a[0]=i=>e.unref(l)()),class:e.normalizeClass(["backdrop backdrop-blur-[0.50px] transition-all duration-300 [transition-behavior:allow-discrete]",e.unref(n)?"fixed inset-0 z-40 block bg-black/80 opacity-100":"hidden"])},null,2)]))],64))}},[["__scopeId","data-v-aaece1c7"]]),X={class:"flex flex-col"},B={__name:"AppSidebarItem",setup(t){m.useRoute();const o=e.ref(!1);function n(){o.value=!o.value}return e.provide("SIDEBAR_TOGGLE",{toggled:o,toggleSidebarItem:n}),(l,r)=>(e.openBlock(),e.createElementBlock("div",X,[e.renderSlot(l.$slots,"default")]))}},Q=["to"],$={__name:"AppSidebarItemChild",props:{to:{type:String,required:!0}},setup(t){const o=t;return(n,l)=>o.to.startsWith("/")?(e.openBlock(),e.createBlock(e.unref(m.RouterLink),{key:0,class:"[&.router-link-exact-active]:text-primary-950 [&.router-link-exact-active]:bg-background-main text-primary-950 hover:bg-background-main block h-10 items-center gap-3 overflow-hidden text-ellipsis whitespace-nowrap rounded-lg px-3 text-xs leading-[40px] transition-all [&.router-link-exact-active]:font-medium",to:o.to},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},8,["to"])):(e.openBlock(),e.createElementBlock("a",{key:1,class:"text-primary-950 hover:bg-background-main block h-10 items-center gap-3 overflow-hidden text-ellipsis whitespace-nowrap rounded-lg px-3 text-xs leading-[40px] transition-all",to:o.to},[e.renderSlot(n.$slots,"default")],8,Q))}},w={__name:"AppSidebarItemChildren",setup(t){const o=e.inject("SIDEBAR_TOGGLE"),{toggled:n}=o;return(l,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["max-h-0 overflow-y-hidden rounded-b-lg opacity-0 transition-all",{"mt-2 max-h-max overflow-y-auto px-2 opacity-100":e.unref(n)}])},[e.renderSlot(l.$slots,"default")],2))}},K={class:"link group/sidebar-item hover:bg-background-main has-[&.router-link-active]:bg-background-main peer flex h-10 items-center justify-between rounded-lg px-3 transition-all"},v=["href"],S=p({__name:"AppSidebarItemParent",props:{to:{type:String,required:!0},name:{type:String},hasChildren:{type:Boolean,default:!1}},setup(t){const o=m.useRoute(),n=t,l=e.inject("SIDEBAR_TOGGLE"),r=e.inject("APP_DATA"),{toggled:a,toggleSidebarItem:i}=l,{toggleSidebar:c}=r;function u(){o.matched.some(d=>n.name===d.name)?a.value=!0:a.value=!1}return e.watch(o,()=>u(),{immediate:!0}),(f,d)=>(e.openBlock(),e.createElementBlock("div",K,[n.to.startsWith("/")?(e.openBlock(),e.createBlock(e.unref(m.RouterLink),{key:0,onClick:d[0]||(d[0]=ye=>e.unref(c)()),class:"[&.router-link-active]:text-primary-800 [&.router-link-active]:text-primary-800 text-primary-950 peer flex h-full w-full items-center gap-3 text-xs [&.router-link-active]:font-medium",to:n.to},{default:e.withCtx(()=>[e.renderSlot(f.$slots,"default",{},void 0,!0)]),_:3},8,["to"])):(e.openBlock(),e.createElementBlock("a",{key:1,class:"text-primary-950 peer flex h-full w-full items-center gap-3 text-xs",href:n.to},[e.renderSlot(f.$slots,"default",{},void 0,!0)],8,v)),n.hasChildren?(e.openBlock(),e.createElementBlock("button",{key:2,onClick:d[1]||(d[1]=ye=>e.unref(i)()),class:"cursor-pointer rounded-full p-1 transition-all hover:bg-neutral-100",type:"button"},[(e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:e.normalizeClass(["lucide lucide-chevron-down-icon lucide-chevron-down stroke-primary-800 transition-all duration-300",{"rotate-180":e.unref(a)}])},d[2]||(d[2]=[e.createElementVNode("path",{d:"m6 9 6 6 6-6"},null,-1)]),2))])):e.createCommentVNode("",!0)]))}},[["__scopeId","data-v-0fab71c0"]]),ee={class:"hover:bg-background-main has-[&.router-link-active]:active has-[&.router-link-active]:bg-primary-700 peer flex h-10 items-center justify-between rounded-lg px-3 transition-all"},A={__name:"AppSidebarToggle",setup(t){const o=e.inject("SIDEBAR_TOGGLE");return(n,l)=>{const r=e.resolveComponent("RouterLink");return e.openBlock(),e.createElementBlock("div",ee,[e.createVNode(r,{class:"text-primary-950 peer flex h-full w-full items-center gap-3 text-xs [&.router-link-active]:font-medium [&.router-link-active]:text-white",to:"/"},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3}),e.createElementVNode("button",{onClick:l[0]||(l[0]=a=>e.unref(o).toggleSidebarItem()),class:"cursor-pointer",type:"button"},l[1]||(l[1]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:"lucide lucide-chevron-down-icon lucide-chevron-down stroke-white"},[e.createElementVNode("path",{d:"m6 9 6 6 6-6"})],-1)]))])}}},te={},oe={key:0,class:"text-primary-950 px-1 text-sm font-medium"},re={class:"mt-2"};function ne(t,o){return e.openBlock(),e.createElementBlock("nav",null,[t.$slots.title?(e.openBlock(),e.createElementBlock("b",oe,[e.renderSlot(t.$slots,"title")])):e.createCommentVNode("",!0),e.createElementVNode("div",re,[e.renderSlot(t.$slots,"items")])])}const E=p(te,[["render",ne]]),le={},ae={class:"rounded-full px-3 py-1 text-xs font-medium"};function se(t,o){return e.openBlock(),e.createElementBlock("div",ae,[e.renderSlot(t.$slots,"default")])}const V=p(le,[["render",se]]),I={__name:"Button",props:{variant:{type:String,default:"primary"}},setup(t){const o=t,n={primary:["bg-brand-primary-700","text-white","active:bg-primary-950 hover:bg-primary-800"],secondary:["bg-neutral-100","text-primary-900"],outlined:["border-[1px]","border-neutral-200","text-primary-900","hover:bg-neutral-100"],ghost:["font-medium","text-primary-900","hover:bg-neutral-100"],destructive:["bg-danger-600","text-white","active:bg-danger-600-active","hover:bg-danger-600-hovered"]};return(l,r)=>(e.openBlock(),e.createElementBlock("button",e.mergeProps(l.$attrs,{class:["cursor-pointer rounded-lg px-4 py-2 text-xs transition-all disabled:cursor-not-allowed disabled:opacity-50",n[o.variant]]}),[e.renderSlot(l.$slots,"default")],16))}},ie={},ce={class:"rounded-2xl bg-white p-6"};function de(t,o){return e.openBlock(),e.createElementBlock("div",ce,[e.renderSlot(t.$slots,"default")])}const T=p(ie,[["render",de]]),N={__name:"Checkbox",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(t){const o=e.useModel(t,"modelValue"),n=e.ref(null);return(l,r)=>(e.openBlock(),e.createElementBlock("button",{onClick:r[1]||(r[1]=a=>n.value.click()),class:"group/checkbox bg-neutral-100 has-checked:bg-primary-700 flex size-4 cursor-pointer items-center justify-center rounded-sm transition-all"},[r[2]||(r[2]=e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:"lucide lucide-check-icon lucide-check hidden stroke-white group-has-[:checked]/checkbox:block"},[e.createElementVNode("path",{d:"M20 6 9 17l-5-5"})],-1)),e.withDirectives(e.createElementVNode("input",e.mergeProps(l.$attrs,{"onUpdate:modelValue":r[0]||(r[0]=a=>o.value=a),type:"checkbox",ref_key:"checkboxRef",ref:n,hidden:""}),null,16),[[e.vModelCheckbox,o.value]])]))}},pe={class:"pointer-events-auto fixed inset-0 z-[100] min-h-screen bg-black/80 backdrop-blur-[2px]"},C={__name:"DialogBackground",setup(t){return e.onMounted(()=>{document.querySelector("body").classList.add("overflow-hidden")}),e.onUnmounted(()=>{document.querySelector("body").classList.remove("overflow-hidden")}),(o,n)=>(e.openBlock(),e.createElementBlock("div",pe,[e.renderSlot(o.$slots,"default")]))}},P={__name:"Input",props:["modelValue"],setup(t){const o=t,n=e.ref(o.modelValue);return(l,r)=>e.withDirectives((e.openBlock(),e.createElementBlock("input",{"onUpdate:modelValue":r[0]||(r[0]=a=>n.value=a),onInput:r[1]||(r[1]=a=>l.$emit("update:modelValue",a.target.value)),class:"text-primary-950 focus:ring-primary-700 neutral-400:text-neutral-400 rounded-lg border-[1px] border-neutral-200 bg-white px-3 py-2 text-xs outline-none transition-all focus:ring-2 focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50"},null,544)),[[e.vModelText,n.value]])}},me={};function ue(t,o){return e.openBlock(),e.createElementBlock("label",e.mergeProps(t.$attrs,{class:"text-primary-950 text-xs transition-all"}),[e.renderSlot(t.$slots,"default")],16)}const D=p(me,[["render",ue]]),L={__name:"Radio",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(t){const o=e.useModel(t,"modelValue"),n=e.ref(null);return(l,r)=>(e.openBlock(),e.createElementBlock("button",{onClick:r[1]||(r[1]=a=>n.value.click()),class:"group/radio bg-neutral-100 has-checked:bg-white has-checked:border-primary-700 flex size-4 cursor-pointer items-center justify-center rounded-full border-[1px] border-transparent"},[r[2]||(r[2]=e.createElementVNode("div",{class:"group-has-checked/radio:bg-primary-700 group-has-checked/radio:opacity-100 size-[10px] rounded-full opacity-0 transition-all"},null,-1)),e.withDirectives(e.createElementVNode("input",e.mergeProps(l.$attrs,{"onUpdate:modelValue":r[0]||(r[0]=a=>o.value=a),type:"radio",ref_key:"radioRef",ref:n,hidden:""}),null,16),[[e.vModelRadio,o.value]])]))}},fe="bg-[url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSJub25lIiBzdHJva2U9IiM1YjYxNmUiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIiBjbGFzcz0ibHVjaWRlIGx1Y2lkZS1jaGV2cm9uLWRvd24iPjxwYXRoIGQ9Im02IDkgNiA2IDYtNiIvPjwvc3ZnPg==')]",j={__name:"Select",setup(t){return(o,n)=>(e.openBlock(),e.createElementBlock("select",e.mergeProps(o.$attrs,{onChange:n[0]||(n[0]=l=>o.$emit("update:modelValue",l.target.value)),class:["border-neutral-200 text-primary-950 focus:ring-primary-700 appearance-none rounded-lg border-[1px] bg-white bg-[length:16px] bg-[right_12px_center] bg-no-repeat px-3 py-2 text-xs outline-none transition-all focus:ring-2 focus:ring-offset-2",fe]}),[e.renderSlot(o.$slots,"default")],16))}},be={class:"w-full"},ke={class:"h-16"},he={key:0},_e={key:0,class:"pe-4"},M={__name:"Table",props:{columns:{type:Array,required:!0},data:{type:Array,required:!0}},setup(t){const o=t;return(n,l)=>(e.openBlock(),e.createElementBlock("table",be,[e.createElementVNode("thead",null,[e.createElementVNode("tr",ke,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,r=>(e.openBlock(),e.createElementBlock("th",{key:r.key,class:"text-xs font-medium text-neutral-600 first-of-type:ps-4"},e.toDisplayString(r.label),1))),128)),n.$slots.actions?(e.openBlock(),e.createElementBlock("th",he)):e.createCommentVNode("",!0)])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.data,(r,a)=>(e.openBlock(),e.createElementBlock("tr",{key:a,class:"odd:bg-background-main/50 hover:bg-background-main min-h-16 rounded-md transition-all"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,i=>(e.openBlock(),e.createElementBlock("td",{key:i.key,class:"text-primary-950 py-4 text-xs first-of-type:rounded-s-md first-of-type:ps-4 last-of-type:rounded-e-md last-of-type:pe-4"},[e.renderSlot(n.$slots,i.key,{row:r},()=>[e.createTextVNode(e.toDisplayString(r[i.key]),1)])]))),128)),n.$slots.actions?(e.openBlock(),e.createElementBlock("td",_e,[e.renderSlot(n.$slots,"actions",{row:r})])):e.createCommentVNode("",!0)]))),128))])]))}},ge={class:"overflow-x-scroll rounded-xl bg-neutral-100/50 p-1 [&::-webkit-scrollbar]:hidden"},R={__name:"Tabs",props:{default:{default:null}},setup(t){const o=t,n=e.ref(o.default);function l(r){n.value=r}return e.provide("TAB_DATA",{currentValue:n,setCurrentValue:l}),(r,a)=>(e.openBlock(),e.createElementBlock("div",ge,[e.renderSlot(r.$slots,"default")]))}},z=p({__name:"TabItem",props:{value:{required:!0}},setup(t){const o=t,n=e.inject("TAB_DATA"),{currentValue:l,setCurrentValue:r}=n,a=e.computed(()=>l.value===o.value?["bg-white","font-medium","text-primary-700","shadow-xl","tab-active"]:"text-neutral-600");return(i,c)=>(e.openBlock(),e.createElementBlock("button",{onClick:c[0]||(c[0]=u=>e.unref(r)(o.value)),class:e.normalizeClass(["tab h-8 cursor-pointer rounded-lg px-3 text-xs transition-all disabled:cursor-not-allowed disabled:opacity-50",a.value])},[e.renderSlot(i.$slots,"default",{},void 0,!0)],2))}},[["__scopeId","data-v-9e06f71f"]]),G={__name:"TextArea",props:["modelValue"],setup(t){const o=t,n=e.ref(o.modelValue);return(l,r)=>e.withDirectives((e.openBlock(),e.createElementBlock("textarea",e.mergeProps({onInput:r[0]||(r[0]=a=>l.$emit("update:modelValue",a.target.value))},l.$attrs,{"onUpdate:modelValue":r[1]||(r[1]=a=>n.value=a),class:"border-neutral-200 text-primary-950 neutral-400:text-neutral-400 focus:ring-primary-700 rounded-lg border-[1px] px-3 py-2 text-xs outline-none transition-all focus:ring-2 focus:ring-offset-2"}),null,16)),[[e.vModelText,n.value]])}},xe={install(t){t.component("AppHeader",b),t.component("AppHeaderLink",k),t.component("AppLayout",h),t.component("AppMain",_),t.component("AppNavTabs",g),t.component("AppNavTab",x),t.component("AppSidebar",y),t.component("AppSidebarItem",B),t.component("AppSidebarItemChild",$),t.component("AppSidebarItemChildren",w),t.component("AppSidebarItemParent",S),t.component("AppSidebarToggle",A),t.component("AppSidebarNavSection",E),t.component("Badge",V),t.component("Button",I),t.component("Checkbox",N),t.component("Card",T),t.component("DialogBackground",C),t.component("Input",P),t.component("Label",D),t.component("Radio",L),t.component("Select",j),t.component("Table",M),t.component("Tabs",R),t.component("TabItem",z),t.component("TextArea",G)}};s.AppHeader=b,s.AppHeaderLink=k,s.AppLayout=h,s.AppMain=_,s.AppNavTab=x,s.AppNavTabs=g,s.AppSidebar=y,s.AppSidebarItem=B,s.AppSidebarItemChild=$,s.AppSidebarItemChildren=w,s.AppSidebarItemParent=S,s.AppSidebarNavSection=E,s.AppSidebarToggle=A,s.Badge=V,s.Button=I,s.Card=T,s.Checkbox=N,s.DialogBackground=C,s.Input=P,s.Label=D,s.Radio=L,s.Select=j,s.TabItem=z,s.Table=M,s.Tabs=R,s.TextArea=G,s.default=xe,Object.defineProperties(s,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
1
|
+
(function(a,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("vue-router")):typeof define=="function"&&define.amd?define(["exports","vue","vue-router"],e):(a=typeof globalThis<"u"?globalThis:a||self,e(a.ScrubbedTailwindComponentsV2={},a.Vue,a.vueRouter))})(this,function(a,e,p){"use strict";const F={class:"flex w-full items-center justify-between"},X={class:"flex items-center gap-2"},Q={class:"flex items-center gap-10"},K={class:"hidden gap-6 sm:flex"},g={__name:"AppHeader",setup(t){const o=e.inject("APP_DATA"),{isSidebarToggled:n,toggleSidebar:l}=o;return(r,s)=>(e.openBlock(),e.createElementBlock("header",{class:e.normalizeClass(["fixed top-0 flex h-16 w-dvw items-center bg-white/50 px-3 backdrop-blur sm:px-6",{"rounded-t-2xl":e.unref(n)}])},[e.createElementVNode("nav",F,[e.createElementVNode("div",X,[e.createElementVNode("button",{onClick:s[0]||(s[0]=c=>e.unref(l)()),class:"block cursor-pointer rounded-full p-2 hover:bg-neutral-100 sm:hidden"},s[1]||(s[1]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:"lucide lucide-menu-icon lucide-menu size-5 stroke-neutral-600"},[e.createElementVNode("path",{d:"M4 12h16"}),e.createElementVNode("path",{d:"M4 18h16"}),e.createElementVNode("path",{d:"M4 6h16"})],-1)])),e.renderSlot(r.$slots,"header-img")]),e.createElementVNode("div",Q,[e.createElementVNode("ul",K,[e.renderSlot(r.$slots,"header-links")]),e.renderSlot(r.$slots,"header-actions")])])],2))}},v=["href"],k={__name:"AppHeaderLink",props:{to:{type:String,required:!0}},setup(t){const o=t;return(n,l)=>(e.openBlock(),e.createElementBlock("li",null,[o.to.startsWith("/")?(e.openBlock(),e.createBlock(e.unref(p.RouterLink),{key:0,class:"hover:text-primary-950 [&.router-link-active]:text-primary-950 text-xs uppercase text-neutral-600 hover:transition-all [&.router-link-active]:font-semibold",to:o.to},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},8,["to"])):(e.openBlock(),e.createElementBlock("a",{key:1,class:"hover:text-primary-950 text-xs uppercase text-neutral-600 hover:transition-all",href:o.to},[e.renderSlot(n.$slots,"default")],8,v))]))}},ee={class:"relative"},te={class:"flex"},h={__name:"AppLayout",setup(t){const o=e.ref(!1);function n(){window.innerWidth<=640?(o.value=!o.value,l()):o.value&&(o.value=!1,l())}function l(){const r=document.querySelector("body");r.classList.contains("bg-black")?r.classList.remove("bg-black"):r.classList.add("bg-black")}return e.provide("APP_DATA",{isSidebarToggled:o,toggleSidebar:n}),(r,s)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["bg-white transition-all duration-500 ease-[cubic-bezier(.32,.72,0,1)]",{"scale-93 origin-[center_top] translate-y-4":o.value}])},[e.createElementVNode("div",ee,[e.renderSlot(r.$slots,"header"),e.createElementVNode("div",te,[e.renderSlot(r.$slots,"content")])])],2))}},b={__name:"AppMain",setup(t){const o=e.inject("APP_DATA"),{isSidebarToggled:n}=o;return(l,r)=>(e.openBlock(),e.createElementBlock("main",{class:e.normalizeClass(["bg-background-main fixed z-[-1] h-svh w-full overflow-auto px-6 pb-9 pt-24 sm:top-16 sm:ml-[223px] sm:h-[calc(100dvh-4rem)] sm:w-[calc(100dvw-223px)] sm:pt-9",e.unref(n)?"overflow-hidden rounded-t-xl sm:rounded-none":"sm:rounded-tl-2xl"])},[e.renderSlot(l.$slots,"default")],2))}},i=(t,o)=>{const n=t.__vccOpts||t;for(const[l,r]of o)n[l]=r;return n},oe={},ne={class:"flex w-full overflow-x-auto border-b-[1px] border-neutral-200 [&::-webkit-scrollbar]:hidden"};function re(t,o){return e.openBlock(),e.createElementBlock("div",ne,[e.renderSlot(t.$slots,"default")])}const x=i(oe,[["render",re]]),le={class:"shrink-0"},y={__name:"AppNavTab",props:{to:{type:String,required:!0}},setup(t){const o=t;return e.ref(null),(n,l)=>(e.openBlock(),e.createElementBlock("div",le,[e.createVNode(e.unref(p.RouterLink),{class:"[&.router-link-exact-active]:text-primary-950 [&.router-link-exact-active]:border-brand-primary-700 hover:text-brand-primary-700 group relative flex h-12 shrink-0 items-center justify-between gap-2 border-b-2 border-transparent px-3 text-sm text-neutral-600 transition-all [&.router-link-exact-active]:font-medium",to:o.to},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default"),l[0]||(l[0]=e.createElementVNode("div",{class:"bg-primary-100 absolute inset-x-0 z-[-1] h-8 w-full rounded-lg opacity-0 transition-all contain-strict group-hover:transform-none group-hover:opacity-100 group-hover:[transform-origin:50%_50%_0px]"},null,-1))]),_:3,__:[0]},8,["to"])]))}},ae={class:"fixed left-0 top-0 hidden w-[223px] space-y-4 bg-white px-4 py-8 sm:top-[64px] sm:block"},B=i({__name:"AppSidebar",setup(t){const o=e.inject("APP_DATA"),{isSidebarToggled:n,toggleSidebar:l}=o;return(r,s)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("aside",ae,[e.renderSlot(r.$slots,"default",{},void 0,!0)]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createElementVNode("div",{class:"shadow-t-2xl fixed bottom-0 z-50 h-[60svh] w-full space-y-4 overflow-y-scroll rounded-t-2xl bg-white p-4 transition-all duration-500 ease-[cubic-bezier(.32,.72,0,1)] [&::-webkit-scrollbar]:hidden",style:e.normalizeStyle(e.unref(n)?"transform: translateZ(0)":"transform: translate3d(0,60svh,0)")},[e.renderSlot(r.$slots,"default",{},void 0,!0)],4),e.createElementVNode("div",{onClick:s[0]||(s[0]=c=>e.unref(l)()),class:e.normalizeClass(["backdrop backdrop-blur-[0.50px] transition-all duration-300 [transition-behavior:allow-discrete]",e.unref(n)?"fixed inset-0 z-40 block bg-black/80 opacity-100":"hidden"])},null,2)]))],64))}},[["__scopeId","data-v-aaece1c7"]]),se={class:"flex flex-col"},S={__name:"AppSidebarItem",setup(t){p.useRoute();const o=e.ref(!1);function n(){o.value=!o.value}return e.provide("SIDEBAR_TOGGLE",{toggled:o,toggleSidebarItem:n}),(l,r)=>(e.openBlock(),e.createElementBlock("div",se,[e.renderSlot(l.$slots,"default")]))}},ce=["to"],w={__name:"AppSidebarItemChild",props:{to:{type:String,required:!0}},setup(t){const o=t;return(n,l)=>o.to.startsWith("/")?(e.openBlock(),e.createBlock(e.unref(p.RouterLink),{key:0,class:"[&.router-link-exact-active]:text-primary-950 [&.router-link-exact-active]:bg-background-main text-primary-950 hover:bg-background-main block h-10 items-center gap-3 overflow-hidden text-ellipsis whitespace-nowrap rounded-lg px-3 text-xs leading-[40px] transition-all [&.router-link-exact-active]:font-medium",to:o.to},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3},8,["to"])):(e.openBlock(),e.createElementBlock("a",{key:1,class:"text-primary-950 hover:bg-background-main block h-10 items-center gap-3 overflow-hidden text-ellipsis whitespace-nowrap rounded-lg px-3 text-xs leading-[40px] transition-all",to:o.to},[e.renderSlot(n.$slots,"default")],8,ce))}},$={__name:"AppSidebarItemChildren",setup(t){const o=e.inject("SIDEBAR_TOGGLE"),{toggled:n}=o;return(l,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["max-h-0 overflow-y-hidden rounded-b-lg opacity-0 transition-all",{"mt-2 max-h-max overflow-y-auto px-2 opacity-100":e.unref(n)}])},[e.renderSlot(l.$slots,"default")],2))}},ie={class:"link group/sidebar-item hover:bg-background-main has-[&.router-link-active]:bg-background-main peer flex h-10 items-center justify-between rounded-lg px-3 transition-all"},de=["href"],A=i({__name:"AppSidebarItemParent",props:{to:{type:String,required:!0},name:{type:String},hasChildren:{type:Boolean,default:!1}},setup(t){const o=p.useRoute(),n=t,l=e.inject("SIDEBAR_TOGGLE"),r=e.inject("APP_DATA"),{toggled:s,toggleSidebarItem:c}=l,{toggleSidebar:u}=r;function Y(){o.matched.some(d=>n.name===d.name)?s.value=!0:s.value=!1}return e.watch(o,()=>Y(),{immediate:!0}),(_,d)=>(e.openBlock(),e.createElementBlock("div",ie,[n.to.startsWith("/")?(e.openBlock(),e.createBlock(e.unref(p.RouterLink),{key:0,onClick:d[0]||(d[0]=Me=>e.unref(u)()),class:"[&.router-link-active]:text-primary-800 [&.router-link-active]:text-primary-800 text-primary-950 peer flex h-full w-full items-center gap-3 text-xs [&.router-link-active]:font-medium",to:n.to},{default:e.withCtx(()=>[e.renderSlot(_.$slots,"default",{},void 0,!0)]),_:3},8,["to"])):(e.openBlock(),e.createElementBlock("a",{key:1,class:"text-primary-950 peer flex h-full w-full items-center gap-3 text-xs",href:n.to},[e.renderSlot(_.$slots,"default",{},void 0,!0)],8,de)),n.hasChildren?(e.openBlock(),e.createElementBlock("button",{key:2,onClick:d[1]||(d[1]=Me=>e.unref(c)()),class:"cursor-pointer rounded-full p-1 transition-all hover:bg-neutral-100",type:"button"},[(e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:e.normalizeClass(["lucide lucide-chevron-down-icon lucide-chevron-down stroke-primary-800 transition-all duration-300",{"rotate-180":e.unref(s)}])},d[2]||(d[2]=[e.createElementVNode("path",{d:"m6 9 6 6 6-6"},null,-1)]),2))])):e.createCommentVNode("",!0)]))}},[["__scopeId","data-v-0fab71c0"]]),pe={class:"hover:bg-background-main has-[&.router-link-active]:active has-[&.router-link-active]:bg-primary-700 peer flex h-10 items-center justify-between rounded-lg px-3 transition-all"},E={__name:"AppSidebarToggle",setup(t){const o=e.inject("SIDEBAR_TOGGLE");return(n,l)=>{const r=e.resolveComponent("RouterLink");return e.openBlock(),e.createElementBlock("div",pe,[e.createVNode(r,{class:"text-primary-950 peer flex h-full w-full items-center gap-3 text-xs [&.router-link-active]:font-medium [&.router-link-active]:text-white",to:"/"},{default:e.withCtx(()=>[e.renderSlot(n.$slots,"default")]),_:3}),e.createElementVNode("button",{onClick:l[0]||(l[0]=s=>e.unref(o).toggleSidebarItem()),class:"cursor-pointer",type:"button"},l[1]||(l[1]=[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:"lucide lucide-chevron-down-icon lucide-chevron-down stroke-white"},[e.createElementVNode("path",{d:"m6 9 6 6 6-6"})],-1)]))])}}},me={},fe={key:0,class:"text-primary-950 px-1 text-sm font-medium"},ue={class:"mt-2"};function _e(t,o){return e.openBlock(),e.createElementBlock("nav",null,[t.$slots.title?(e.openBlock(),e.createElementBlock("b",fe,[e.renderSlot(t.$slots,"title")])):e.createCommentVNode("",!0),e.createElementVNode("div",ue,[e.renderSlot(t.$slots,"items")])])}const C=i(me,[["render",_e]]),ge={},ke={class:"rounded-full px-3 py-1 text-xs font-medium"};function he(t,o){return e.openBlock(),e.createElementBlock("div",ke,[e.renderSlot(t.$slots,"default")])}const T=i(ge,[["render",he]]),V={__name:"Button",props:{variant:{type:String,default:"primary"}},setup(t){const o=t,n={primary:["bg-brand-primary-700","text-white","active:bg-primary-950 hover:bg-primary-800"],secondary:["bg-neutral-100","text-primary-900"],outlined:["border-[1px]","border-neutral-200","text-primary-900","hover:bg-neutral-100"],ghost:["font-medium","text-primary-900","hover:bg-neutral-100"],destructive:["bg-danger-600","text-white","active:bg-danger-600-active","hover:bg-danger-600-hovered"]};return(l,r)=>(e.openBlock(),e.createElementBlock("button",e.mergeProps(l.$attrs,{class:["cursor-pointer rounded-lg px-4 py-2 text-xs transition-all disabled:cursor-not-allowed disabled:opacity-50",n[o.variant]]}),[e.renderSlot(l.$slots,"default")],16))}},be={},xe={class:"rounded-2xl bg-white p-6"};function ye(t,o){return e.openBlock(),e.createElementBlock("div",xe,[e.renderSlot(t.$slots,"default")])}const m=i(be,[["render",ye]]),I={__name:"Checkbox",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(t){const o=e.useModel(t,"modelValue"),n=e.ref(null);return(l,r)=>(e.openBlock(),e.createElementBlock("button",{onClick:r[1]||(r[1]=s=>n.value.click()),class:"group/checkbox bg-neutral-100 has-checked:bg-primary-700 flex size-4 cursor-pointer items-center justify-center rounded-sm transition-all"},[r[2]||(r[2]=e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:"lucide lucide-check-icon lucide-check hidden stroke-white group-has-[:checked]/checkbox:block"},[e.createElementVNode("path",{d:"M20 6 9 17l-5-5"})],-1)),e.withDirectives(e.createElementVNode("input",e.mergeProps(l.$attrs,{"onUpdate:modelValue":r[0]||(r[0]=s=>o.value=s),type:"checkbox",ref_key:"checkboxRef",ref:n,hidden:""}),null,16),[[e.vModelCheckbox,o.value]])]))}},N={__name:"Dialog",setup(t){const o=e.ref(!1);function n(){o.value=!o.value}return e.provide("DIALOG_META",{toggled:o,toggleDialog:n}),(l,r)=>e.renderSlot(l.$slots,"default")}},Be={class:"pointer-events-auto fixed inset-0 z-[500] min-h-screen bg-black/80 backdrop-blur-[2px]"},f={__name:"DialogBackground",setup(t){return e.onMounted(()=>{document.querySelector("body").classList.add("overflow-hidden")}),e.onUnmounted(()=>{document.querySelector("body").classList.remove("overflow-hidden")}),(o,n)=>(e.openBlock(),e.createElementBlock("div",Be,[e.renderSlot(o.$slots,"default")]))}},D={__name:"DialogContent",props:{class:{type:String}},setup(t){const o=t,{toggled:n,toggleDialog:l}=e.inject("DIALOG_META");return(r,s)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"fade-in"},{default:e.withCtx(()=>[e.unref(n)?(e.openBlock(),e.createBlock(f,{key:0,onClick:s[0]||(s[0]=c=>e.unref(l)())})):e.createCommentVNode("",!0)]),_:1}),e.createVNode(e.Transition,{name:"fade-in-dialog"},{default:e.withCtx(()=>[e.unref(n)?(e.openBlock(),e.createBlock(m,{key:0,class:e.normalizeClass(["fixed left-1/2 top-1/2 z-[600] -translate-x-1/2 -translate-y-1/2 rounded-xl bg-white transition-all",o.class])},{default:e.withCtx(()=>[e.renderSlot(r.$slots,"default")]),_:3},8,["class"])):e.createCommentVNode("",!0)]),_:3})]))}},L={__name:"DialogToggle",setup(t){const o=e.useSlots(),{toggleDialog:n}=e.inject("DIALOG_META");return(l,r)=>{var s,c;return e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.cloneVNode((c=(s=e.unref(o)).default)==null?void 0:c.call(s)[0],{onClick:e.unref(n)})))}}},M={__name:"Input",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(t){const o=e.useModel(t,"modelValue");return(n,l)=>e.withDirectives((e.openBlock(),e.createElementBlock("input",{"onUpdate:modelValue":l[0]||(l[0]=r=>o.value=r),class:"text-primary-950 focus:ring-primary-700 neutral-400:text-neutral-400 rounded-lg border-[1px] border-neutral-200 bg-white px-3 py-2 text-xs outline-none transition-all focus:ring-2 focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50"},null,512)),[[e.vModelText,o.value]])}},Se={};function we(t,o){return e.openBlock(),e.createElementBlock("label",e.mergeProps(t.$attrs,{class:"text-primary-950 text-xs transition-all"}),[e.renderSlot(t.$slots,"default")],16)}const P=i(Se,[["render",we]]),j={__name:"Radio",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(t){const o=e.useModel(t,"modelValue"),n=e.ref(null);return(l,r)=>(e.openBlock(),e.createElementBlock("button",{onClick:r[1]||(r[1]=s=>n.value.click()),class:"group/radio bg-neutral-100 has-checked:bg-white has-checked:border-primary-700 flex size-4 cursor-pointer items-center justify-center rounded-full border-[1px] border-transparent"},[r[2]||(r[2]=e.createElementVNode("div",{class:"group-has-checked/radio:bg-primary-700 group-has-checked/radio:opacity-100 size-[10px] rounded-full opacity-0 transition-all"},null,-1)),e.withDirectives(e.createElementVNode("input",e.mergeProps(l.$attrs,{"onUpdate:modelValue":r[0]||(r[0]=s=>o.value=s),type:"radio",ref_key:"radioRef",ref:n,hidden:""}),null,16),[[e.vModelRadio,o.value]])]))}},$e="bg-[url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSJub25lIiBzdHJva2U9IiM1YjYxNmUiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIiBjbGFzcz0ibHVjaWRlIGx1Y2lkZS1jaGV2cm9uLWRvd24iPjxwYXRoIGQ9Im02IDkgNiA2IDYtNiIvPjwvc3ZnPg==')]",z={__name:"Select",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(t){const o=e.useModel(t,"modelValue");return(n,l)=>e.withDirectives((e.openBlock(),e.createElementBlock("select",e.mergeProps(n.$attrs,{"onUpdate:modelValue":l[0]||(l[0]=r=>o.value=r),class:["text-primary-950 focus:ring-primary-700 appearance-none rounded-lg border-[1px] border-neutral-200 bg-white bg-[length:16px] bg-[right_12px_center] bg-no-repeat px-3 py-2 text-xs outline-none transition-all focus:ring-2 focus:ring-offset-2",$e]}),[e.renderSlot(n.$slots,"default")],16)),[[e.vModelSelect,o.value]])}},R={__name:"Sheet",setup(t){const o=e.ref(!1);function n(){o.value=!o.value}return e.provide("SHEET_META",{toggled:o,toggleSheet:n}),(l,r)=>e.renderSlot(l.$slots,"default")}},G={__name:"SheetContent",props:{class:{type:String}},setup(t){const o=t,{toggled:n,toggleSheet:l}=e.inject("SHEET_META");return(r,s)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"fade-in"},{default:e.withCtx(()=>[e.unref(n)?(e.openBlock(),e.createBlock(f,{key:0,onClick:s[0]||(s[0]=c=>e.unref(l)())})):e.createCommentVNode("",!0)]),_:1}),e.createVNode(e.Transition,{name:"slide"},{default:e.withCtx(()=>[e.unref(n)?(e.openBlock(),e.createBlock(m,{key:0,class:e.normalizeClass(["fixed right-0 top-1/2 z-[600] h-full w-3/4 -translate-y-1/2 rounded-e-none bg-white transition-all md:right-[1rem] md:h-[calc(100dvh-2rem)] md:w-96 md:rounded-xl",o.class])},{default:e.withCtx(()=>[e.renderSlot(r.$slots,"default")]),_:3},8,["class"])):e.createCommentVNode("",!0)]),_:3})]))}},H={__name:"SheetToggle",setup(t){const o=e.useSlots(),{toggleSheet:n}=e.inject("SHEET_META");return(l,r)=>{var s,c;return e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.cloneVNode((c=(s=e.unref(o)).default)==null?void 0:c.call(s)[0],{onClick:e.unref(n)})))}}},Ae={},Ee={class:"bg-primary-100 animate-pulse rounded-lg"};function Ce(t,o){return e.openBlock(),e.createElementBlock("div",Ee)}const W=i(Ae,[["render",Ce]]),q={__name:"Switch",setup(t){const o=e.ref(!1);function n(){o.value=!o.value}return(l,r)=>(e.openBlock(),e.createElementBlock("button",{onClick:r[0]||(r[0]=s=>n()),class:e.normalizeClass(["h-6 w-11 cursor-pointer rounded-full p-0.5 transition-colors disabled:cursor-not-allowed disabled:opacity-50",o.value?"bg-brand-primary-700":"bg-neutral-100"]),role:"switch",type:"button"},[e.createElementVNode("span",{class:e.normalizeClass(["pointer-events-none block size-5 rounded-full bg-white shadow-md transition-transform",{"translate-x-full":o.value}])},null,2)],2))}},Te={class:"w-full"},Ve={class:"h-16"},Ie={key:0},Ne={key:0,class:"pe-4"},O={__name:"Table",props:{columns:{type:Array,required:!0},data:{type:Array,required:!0}},setup(t){const o=t;return(n,l)=>(e.openBlock(),e.createElementBlock("table",Te,[e.createElementVNode("thead",null,[e.createElementVNode("tr",Ve,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,r=>(e.openBlock(),e.createElementBlock("th",{key:r.key,class:"text-xs font-medium text-neutral-600 first-of-type:ps-4"},e.toDisplayString(r.label),1))),128)),n.$slots.actions?(e.openBlock(),e.createElementBlock("th",Ie)):e.createCommentVNode("",!0)])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.data,(r,s)=>(e.openBlock(),e.createElementBlock("tr",{key:s,class:"odd:bg-background-main/50 hover:bg-background-main min-h-16 rounded-md transition-all"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,c=>(e.openBlock(),e.createElementBlock("td",{key:c.key,class:"text-primary-950 py-4 text-xs first-of-type:rounded-s-md first-of-type:ps-4 last-of-type:rounded-e-md last-of-type:pe-4"},[e.renderSlot(n.$slots,c.key,{row:r},()=>[e.createTextVNode(e.toDisplayString(r[c.key]),1)])]))),128)),n.$slots.actions?(e.openBlock(),e.createElementBlock("td",Ne,[e.renderSlot(n.$slots,"actions",{row:r})])):e.createCommentVNode("",!0)]))),128))])]))}},De={class:"overflow-x-scroll rounded-xl bg-neutral-100/50 p-1 [&::-webkit-scrollbar]:hidden"},U={__name:"Tabs",props:{default:{default:null}},setup(t){const o=t,n=e.ref(o.default);function l(r){n.value=r}return e.provide("TAB_DATA",{currentValue:n,setCurrentValue:l}),(r,s)=>(e.openBlock(),e.createElementBlock("div",De,[e.renderSlot(r.$slots,"default")]))}},Z=i({__name:"TabItem",props:{value:{required:!0}},setup(t){const o=t,n=e.inject("TAB_DATA"),{currentValue:l,setCurrentValue:r}=n,s=e.computed(()=>l.value===o.value?["bg-white","font-medium","text-primary-700","shadow-xl","tab-active"]:"text-neutral-600");return(c,u)=>(e.openBlock(),e.createElementBlock("button",{onClick:u[0]||(u[0]=Y=>e.unref(r)(o.value)),class:e.normalizeClass(["tab h-8 cursor-pointer rounded-lg px-3 text-xs transition-all disabled:cursor-not-allowed disabled:opacity-50",s.value])},[e.renderSlot(c.$slots,"default",{},void 0,!0)],2))}},[["__scopeId","data-v-9e06f71f"]]),J={__name:"TextArea",props:["modelValue"],setup(t){const o=t,n=e.ref(o.modelValue);return(l,r)=>e.withDirectives((e.openBlock(),e.createElementBlock("textarea",e.mergeProps({onInput:r[0]||(r[0]=s=>l.$emit("update:modelValue",s.target.value))},l.$attrs,{"onUpdate:modelValue":r[1]||(r[1]=s=>n.value=s),class:"border-neutral-200 text-primary-950 neutral-400:text-neutral-400 focus:ring-primary-700 rounded-lg border-[1px] px-3 py-2 text-xs outline-none transition-all focus:ring-2 focus:ring-offset-2"}),null,16)),[[e.vModelText,n.value]])}},Le={install(t){t.component("AppHeader",g),t.component("AppHeaderLink",k),t.component("AppLayout",h),t.component("AppMain",b),t.component("AppNavTabs",x),t.component("AppNavTab",y),t.component("AppSidebar",B),t.component("AppSidebarItem",S),t.component("AppSidebarItemChild",w),t.component("AppSidebarItemChildren",$),t.component("AppSidebarItemParent",A),t.component("AppSidebarToggle",E),t.component("AppSidebarNavSection",C),t.component("Badge",T),t.component("Button",V),t.component("Checkbox",I),t.component("Card",m),t.component("Dialog",N),t.component("DialogContent",D),t.component("DialogToggle",L),t.component("DialogBackground",f),t.component("Input",M),t.component("Label",P),t.component("Radio",j),t.component("Select",z),t.component("Sheet",R),t.component("SheetContent",G),t.component("SheetToggle",H),t.component("SkeletonLoader",W),t.component("Switch",q),t.component("Table",O),t.component("Tabs",U),t.component("TabItem",Z),t.component("TextArea",J)}};a.AppHeader=g,a.AppHeaderLink=k,a.AppLayout=h,a.AppMain=b,a.AppNavTab=y,a.AppNavTabs=x,a.AppSidebar=B,a.AppSidebarItem=S,a.AppSidebarItemChild=w,a.AppSidebarItemChildren=$,a.AppSidebarItemParent=A,a.AppSidebarNavSection=C,a.AppSidebarToggle=E,a.Badge=T,a.Button=V,a.Card=m,a.Checkbox=I,a.Dialog=N,a.DialogBackground=f,a.DialogContent=D,a.DialogToggle=L,a.Input=M,a.Label=P,a.Radio=j,a.Select=z,a.Sheet=R,a.SheetContent=G,a.SheetToggle=H,a.SkeletonLoader=W,a.Switch=q,a.TabItem=Z,a.Table=O,a.Tabs=U,a.TextArea=J,a.default=Le,Object.defineProperties(a,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|