@eeplatform/nuxt-layer-common 1.0.0 → 1.1.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/CHANGELOG.md +6 -0
- package/components/Layout/Header.vue +13 -27
- package/composables/useLocal.ts +13 -14
- package/nuxt.config.ts +3 -5
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
class="text-h6 font-weight-medium text-decoration-none APP_NAME"
|
|
7
7
|
:to="{ name: APP_NAME_ROUTE }"
|
|
8
8
|
>
|
|
9
|
-
{{ APP_NAME }}
|
|
9
|
+
{{ props.title || APP_NAME }}
|
|
10
10
|
</nuxt-link>
|
|
11
11
|
</div>
|
|
12
12
|
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
stacked
|
|
57
57
|
rounded="xl"
|
|
58
58
|
variant="text"
|
|
59
|
-
class="text-capitalize text-
|
|
59
|
+
class="text-center text-capitalize text-caption"
|
|
60
60
|
@click="redirect(item.link, item.landingPage)"
|
|
61
61
|
>
|
|
62
62
|
{{ item.title }}
|
|
@@ -169,6 +169,13 @@
|
|
|
169
169
|
</template>
|
|
170
170
|
|
|
171
171
|
<script setup lang="ts">
|
|
172
|
+
const props = defineProps({
|
|
173
|
+
title: {
|
|
174
|
+
type: String,
|
|
175
|
+
default: "Title",
|
|
176
|
+
},
|
|
177
|
+
});
|
|
178
|
+
|
|
172
179
|
import { useTheme } from "vuetify";
|
|
173
180
|
|
|
174
181
|
const { getNameInitials, debounce } = useUtils();
|
|
@@ -186,15 +193,8 @@ watch(
|
|
|
186
193
|
|
|
187
194
|
const { redirect, apps, drawer } = useLocal();
|
|
188
195
|
|
|
189
|
-
const {
|
|
190
|
-
|
|
191
|
-
APP_ACCOUNT,
|
|
192
|
-
APP_ORG,
|
|
193
|
-
APP_ADMIN,
|
|
194
|
-
APP_NAME,
|
|
195
|
-
APP_NAME_ROUTE,
|
|
196
|
-
APP_AFFILIATE,
|
|
197
|
-
} = useRuntimeConfig().public;
|
|
196
|
+
const { APP_MAIN, APP_ACCOUNT, APP_ADMIN, APP_NAME, APP_NAME_ROUTE } =
|
|
197
|
+
useRuntimeConfig().public;
|
|
198
198
|
|
|
199
199
|
const theme = useTheme();
|
|
200
200
|
|
|
@@ -233,30 +233,16 @@ const name = computed(() => {
|
|
|
233
233
|
const defaultApps = computed(() => [
|
|
234
234
|
{
|
|
235
235
|
title: "Account",
|
|
236
|
-
icon: "
|
|
236
|
+
icon: "ph:user-circle-bold",
|
|
237
237
|
link: APP_ACCOUNT,
|
|
238
238
|
landingPage: "home",
|
|
239
239
|
},
|
|
240
|
-
{
|
|
241
|
-
title: "Business",
|
|
242
|
-
icon: "mdi-domain",
|
|
243
|
-
link: APP_ORG,
|
|
244
|
-
landingPage: currentUser.value?.defaultOrg
|
|
245
|
-
? `org/${currentUser.value?.defaultOrg}`
|
|
246
|
-
: "",
|
|
247
|
-
},
|
|
248
240
|
{
|
|
249
241
|
title: "Admin",
|
|
250
|
-
icon: "
|
|
242
|
+
icon: "ph:shield-checkered-bold",
|
|
251
243
|
link: APP_ADMIN,
|
|
252
244
|
landingPage: "home",
|
|
253
245
|
},
|
|
254
|
-
{
|
|
255
|
-
title: "Affiliate",
|
|
256
|
-
icon: "mdi-account-multiple-check",
|
|
257
|
-
link: APP_AFFILIATE,
|
|
258
|
-
landingPage: "home",
|
|
259
|
-
},
|
|
260
246
|
]);
|
|
261
247
|
</script>
|
|
262
248
|
|
package/composables/useLocal.ts
CHANGED
|
@@ -9,28 +9,27 @@ export default function useLocal() {
|
|
|
9
9
|
|
|
10
10
|
const drawer = useState("drawer", () => true);
|
|
11
11
|
|
|
12
|
-
const {
|
|
13
|
-
const { currentOrg } = useOrg();
|
|
12
|
+
const { APP_SCHOOL, APP_DIVISION, APP_REGION } = appConfig;
|
|
14
13
|
|
|
15
14
|
const apps = computed(() => {
|
|
16
15
|
return [
|
|
17
16
|
{
|
|
18
|
-
title: "
|
|
19
|
-
icon: "
|
|
20
|
-
link:
|
|
21
|
-
landingPage:
|
|
17
|
+
title: "School",
|
|
18
|
+
icon: "ph:building-bold",
|
|
19
|
+
link: APP_SCHOOL as string,
|
|
20
|
+
landingPage: "home",
|
|
22
21
|
},
|
|
23
22
|
{
|
|
24
|
-
title: "
|
|
25
|
-
icon: "
|
|
26
|
-
link:
|
|
27
|
-
landingPage:
|
|
23
|
+
title: "Division",
|
|
24
|
+
icon: "ph:building-apartment-bold",
|
|
25
|
+
link: APP_DIVISION as string,
|
|
26
|
+
landingPage: "home",
|
|
28
27
|
},
|
|
29
28
|
{
|
|
30
|
-
title: "
|
|
31
|
-
icon: "
|
|
32
|
-
link:
|
|
33
|
-
landingPage:
|
|
29
|
+
title: "Region",
|
|
30
|
+
icon: "ph:buildings-bold",
|
|
31
|
+
link: APP_REGION as string,
|
|
32
|
+
landingPage: "home",
|
|
34
33
|
},
|
|
35
34
|
];
|
|
36
35
|
});
|
package/nuxt.config.ts
CHANGED
|
@@ -21,11 +21,9 @@ export default defineNuxtConfig({
|
|
|
21
21
|
APP_MAIN: (process.env.APP_MAIN as string) ?? "",
|
|
22
22
|
APP_ACCOUNT: (process.env.APP_ACCOUNT as string) ?? "",
|
|
23
23
|
APP_ADMIN: (process.env.APP_ADMIN as string) ?? "",
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
APP_ASSET: (process.env.APP_ASSET as string) ?? "",
|
|
28
|
-
APP_FINANCE: (process.env.APP_FINANCE as string) ?? "",
|
|
24
|
+
APP_SCHOOL: (process.env.APP_SCHOOL as string) ?? "",
|
|
25
|
+
APP_DIVISION: (process.env.APP_DIVISION as string) ?? "",
|
|
26
|
+
APP_REGION: (process.env.APP_REGION as string) ?? "",
|
|
29
27
|
},
|
|
30
28
|
},
|
|
31
29
|
|