@edgedev/create-edge-app 1.1.2 → 1.1.3
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/layouts/app.vue +55 -29
- package/package.json +1 -1
- package/plugins/icons.ts +31 -3
package/layouts/app.vue
CHANGED
|
@@ -104,6 +104,30 @@ const menuItems = [
|
|
|
104
104
|
icon: 'Package',
|
|
105
105
|
},
|
|
106
106
|
]
|
|
107
|
+
|
|
108
|
+
const slots = useSlots()
|
|
109
|
+
const hasLeftPanel = computed(() => {
|
|
110
|
+
const leftPanelSlot = slots['left-panel']
|
|
111
|
+
if (!leftPanelSlot) {
|
|
112
|
+
return false
|
|
113
|
+
}
|
|
114
|
+
const slotContent = leftPanelSlot()
|
|
115
|
+
return slotContent.length > 0 && slotContent.some(node => node.children && node.children.length > 0)
|
|
116
|
+
})
|
|
117
|
+
|
|
118
|
+
const leftPanelDefaultSize = computed(() => {
|
|
119
|
+
if (hasLeftPanel.value) {
|
|
120
|
+
return 20
|
|
121
|
+
}
|
|
122
|
+
return 0
|
|
123
|
+
})
|
|
124
|
+
|
|
125
|
+
const mainPanelDefaultSize = computed(() => {
|
|
126
|
+
if (hasLeftPanel.value) {
|
|
127
|
+
return 80
|
|
128
|
+
}
|
|
129
|
+
return 100
|
|
130
|
+
})
|
|
107
131
|
</script>
|
|
108
132
|
|
|
109
133
|
<template>
|
|
@@ -156,35 +180,37 @@ const menuItems = [
|
|
|
156
180
|
</template>
|
|
157
181
|
</edge-side-bar>
|
|
158
182
|
</div>
|
|
159
|
-
<
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
>
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
<
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
183
|
+
<ResizablePanelGroup
|
|
184
|
+
direction="horizontal"
|
|
185
|
+
class="h-full w-full"
|
|
186
|
+
>
|
|
187
|
+
<ResizablePanel class="bg-sidebar text-sidebar-foreground" :default-size="leftPanelDefaultSize">
|
|
188
|
+
<slot name="left-panel" />
|
|
189
|
+
</ResizablePanel>
|
|
190
|
+
<ResizableHandle v-if="hasLeftPanel" with-handle />
|
|
191
|
+
<ResizablePanel :default-size="mainPanelDefaultSize">
|
|
192
|
+
<div class="grow h-full flex flex-col h-screen">
|
|
193
|
+
<edge-menu
|
|
194
|
+
v-if="edgeFirebase.user.loggedIn"
|
|
195
|
+
type="nav"
|
|
196
|
+
nav-class="justify-left"
|
|
197
|
+
class="px-1 border-none"
|
|
198
|
+
>
|
|
199
|
+
<template #start>
|
|
200
|
+
<edge-shad-button
|
|
201
|
+
v-show="edgeGlobal.edgeState.sidebar.isMobile"
|
|
202
|
+
variant="icon"
|
|
203
|
+
class="p-1"
|
|
204
|
+
@click="edgeGlobal.edgeState.sidebar.toggleSidebar"
|
|
205
|
+
>
|
|
206
|
+
<MenuSquare />
|
|
207
|
+
</edge-shad-button>
|
|
208
|
+
</template>
|
|
209
|
+
</edge-menu>
|
|
210
|
+
<slot />
|
|
211
|
+
</div>
|
|
212
|
+
</ResizablePanel>
|
|
213
|
+
</ResizablePanelGroup>
|
|
188
214
|
</edge-sidebar-provider>
|
|
189
215
|
</div>
|
|
190
216
|
</div>
|
package/package.json
CHANGED
package/plugins/icons.ts
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
|
+
AlertCircle,
|
|
2
3
|
ArrowLeft,
|
|
3
4
|
ArrowRight,
|
|
5
|
+
BookImage,
|
|
4
6
|
Box,
|
|
5
7
|
Braces,
|
|
6
8
|
Brackets,
|
|
@@ -8,30 +10,42 @@ import {
|
|
|
8
10
|
Check,
|
|
9
11
|
ChevronDown,
|
|
10
12
|
ChevronLeft,
|
|
13
|
+
ChevronLeftCircle,
|
|
11
14
|
ChevronRight,
|
|
15
|
+
ChevronRightCircle,
|
|
16
|
+
ChevronUp,
|
|
12
17
|
ChevronsUpDown,
|
|
13
18
|
CircleUser,
|
|
14
19
|
Copy,
|
|
15
20
|
Eye,
|
|
16
21
|
EyeOff,
|
|
17
22
|
FilePenLine,
|
|
23
|
+
Fullscreen,
|
|
18
24
|
Grip,
|
|
19
25
|
Group,
|
|
20
|
-
|
|
21
|
-
|
|
26
|
+
Hourglass,
|
|
27
|
+
Image,
|
|
28
|
+
Info, LayoutDashboard,
|
|
22
29
|
List,
|
|
23
30
|
ListPlus,
|
|
24
31
|
Loader2,
|
|
25
|
-
LogOut,
|
|
32
|
+
LogOut,
|
|
33
|
+
MenuSquare,
|
|
34
|
+
MoreHorizontal,
|
|
35
|
+
Newspaper,
|
|
26
36
|
Package,
|
|
37
|
+
PauseCircle,
|
|
27
38
|
Pencil,
|
|
28
39
|
PlusIcon,
|
|
29
40
|
Settings,
|
|
30
41
|
Settings2,
|
|
31
42
|
Trash,
|
|
32
43
|
TrashIcon,
|
|
44
|
+
Upload,
|
|
33
45
|
User,
|
|
34
46
|
Users,
|
|
47
|
+
X,
|
|
48
|
+
ZoomIn,
|
|
35
49
|
} from 'lucide-vue-next'
|
|
36
50
|
|
|
37
51
|
export default defineNuxtPlugin((nuxtApp) => {
|
|
@@ -50,6 +64,7 @@ export default defineNuxtPlugin((nuxtApp) => {
|
|
|
50
64
|
nuxtApp.vueApp.component('EyeOff', EyeOff)
|
|
51
65
|
nuxtApp.vueApp.component('CircleUser', CircleUser)
|
|
52
66
|
nuxtApp.vueApp.component('Group', Group)
|
|
67
|
+
nuxtApp.vueApp.component('Hourglass', Hourglass)
|
|
53
68
|
nuxtApp.vueApp.component('Settings', Settings)
|
|
54
69
|
nuxtApp.vueApp.component('Users', Users)
|
|
55
70
|
nuxtApp.vueApp.component('Settings2', Settings2)
|
|
@@ -65,8 +80,21 @@ export default defineNuxtPlugin((nuxtApp) => {
|
|
|
65
80
|
nuxtApp.vueApp.component('Box', Box)
|
|
66
81
|
nuxtApp.vueApp.component('LogOut', LogOut)
|
|
67
82
|
nuxtApp.vueApp.component('Info', Info)
|
|
83
|
+
nuxtApp.vueApp.component('Image', Image)
|
|
68
84
|
nuxtApp.vueApp.component('FilePenLine', FilePenLine)
|
|
69
85
|
nuxtApp.vueApp.component('List', List)
|
|
70
86
|
nuxtApp.vueApp.component('Copy', Copy)
|
|
71
87
|
nuxtApp.vueApp.component('LayoutDashboard', LayoutDashboard)
|
|
88
|
+
nuxtApp.vueApp.component('Upload', Upload)
|
|
89
|
+
nuxtApp.vueApp.component('X', X)
|
|
90
|
+
nuxtApp.vueApp.component('ZoomIn', ZoomIn)
|
|
91
|
+
nuxtApp.vueApp.component('Newspaper', Newspaper)
|
|
92
|
+
nuxtApp.vueApp.component('BookImage', BookImage)
|
|
93
|
+
nuxtApp.vueApp.component('AlertCircle', AlertCircle)
|
|
94
|
+
nuxtApp.vueApp.component('PauseCircle', PauseCircle)
|
|
95
|
+
nuxtApp.vueApp.component('ChevronUp', ChevronUp)
|
|
96
|
+
nuxtApp.vueApp.component('ChevronLeftCircle', ChevronLeftCircle)
|
|
97
|
+
nuxtApp.vueApp.component('ChevronRightCircle', ChevronRightCircle)
|
|
98
|
+
nuxtApp.vueApp.component('Fullscreen', Fullscreen)
|
|
99
|
+
nuxtApp.vueApp.component('MenuSquare', MenuSquare)
|
|
72
100
|
})
|