@xenterprises/nuxt-x-marketing 0.0.8 → 0.0.9

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/app.config.ts CHANGED
@@ -13,6 +13,7 @@ export default defineAppConfig({
13
13
  header: {
14
14
  logo: {
15
15
  src: "",
16
+ srcDark: "",
16
17
  alt: "",
17
18
  },
18
19
  nav: {
@@ -50,16 +51,20 @@ declare module "@nuxt/schema" {
50
51
  header?: {
51
52
  logo?: {
52
53
  src?: string;
54
+ srcDark?: string;
53
55
  alt?: string;
54
56
  };
55
57
  nav?: {
56
58
  buttons?: {
57
59
  label: string;
58
60
  to: string;
61
+ icon?: string;
62
+ target?: string;
59
63
  }[];
60
64
  links?: {
61
65
  label: string;
62
66
  to: string;
67
+ target?: string;
63
68
  }[];
64
69
  };
65
70
  };
@@ -86,6 +91,7 @@ declare module "@nuxt/schema" {
86
91
  links: {
87
92
  label: string;
88
93
  to: string;
94
+ target?: string;
89
95
  }[];
90
96
  }[];
91
97
  };
@@ -69,6 +69,7 @@
69
69
  >
70
70
  <nuxt-link
71
71
  :to="link?.to"
72
+ :target="link?.target ? link?.target : '_self'"
72
73
  class="text-white hover:text-gray-200 font-medium leading-relaxed"
73
74
  >{{ link?.label }}</nuxt-link
74
75
  >
@@ -1,23 +1,28 @@
1
1
  <template>
2
2
  <UHeader :links="links">
3
3
  <template #logo>
4
- <UColorModeImage
5
- :light="header?.logo?.src"
6
- :dark="
7
- header?.logo?.srcDark ? header?.logo?.srcDark : header?.logo?.src
8
- "
9
- :alt="header?.logo?.alt"
10
- class="h-8"
11
- v-if="header?.logo?.src"
12
- />
4
+ <nuxt-link to="/" v-if="header?.logo?.src">
5
+ <UColorModeImage
6
+ :light="header?.logo?.src"
7
+ :dark="
8
+ header?.logo?.srcDark ? header?.logo?.srcDark : header?.logo?.src
9
+ "
10
+ :alt="header?.logo?.alt"
11
+ class="h-8"
12
+ />
13
+ </nuxt-link>
13
14
  <span v-else>{{ header?.logo?.alt }}</span>
14
15
  </template>
15
16
 
16
17
  <template #right>
17
18
  <span v-for="(button, index) in header?.nav?.buttons" :key="index"
18
- ><UButton class="hidden md:block py-2" :to="button?.to">{{
19
- button?.label
20
- }}</UButton></span
19
+ ><UButton
20
+ class="hidden md:block py-2"
21
+ :to="button?.to"
22
+ :icon="button?.icon ? button?.icon : null"
23
+ :target="link?.target ? link?.target : '_self'"
24
+ >{{ button?.label }}</UButton
25
+ ></span
21
26
  >
22
27
  </template>
23
28
 
@@ -27,6 +32,8 @@
27
32
  ><UButton
28
33
  class="md:hidden mt-5 py-2 w-full flex flex-row justify-center"
29
34
  :to="button?.to"
35
+ :icon="button?.icon ? button?.icon : null"
36
+ :target="link?.target ? link?.target : '_self'"
30
37
  >{{ button?.label }}</UButton
31
38
  ></span
32
39
  >
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@xenterprises/nuxt-x-marketing",
3
3
  "type": "module",
4
- "version": "0.0.8",
4
+ "version": "0.0.9",
5
5
  "main": "./nuxt.config.ts",
6
6
  "scripts": {
7
7
  "dev": "nuxi dev .playground",