kmcom-nuxt-layers 5.0.2 → 5.0.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.
@@ -17,15 +17,17 @@
17
17
  color?: UiColors
18
18
  }>()
19
19
  const colorClass = useColor(color, 'text')
20
+ // `name` is a plain string here, not one of the app's typed route names
21
+ const to = computed(
22
+ () =>
23
+ ({ name, params: params ?? {}, query: query ?? {} }) as unknown as NonNullable<
24
+ Parameters<typeof navigateTo>[0]
25
+ >
26
+ )
20
27
  </script>
21
28
 
22
29
  <template>
23
- <ULink
24
- :to="{ name: name, params: params, query: query }"
25
- :variant
26
- :class="colorClass"
27
- v-bind="$attrs"
28
- >
30
+ <ULink :to :variant :class="colorClass" v-bind="$attrs">
29
31
  <slot />
30
32
  </ULink>
31
33
  </template>
@@ -14,6 +14,7 @@
14
14
  const activeSection = useState<string>('activeSection', () => '')
15
15
  const route = useRoute()
16
16
  const { close: closeNav } = useMastNav()
17
+ const { useZIndex } = useGridConfig()
17
18
 
18
19
  function dismiss() {
19
20
  emit('update:open', false)
@@ -38,7 +39,7 @@
38
39
  <div
39
40
  v-if="open"
40
41
  class="bg-default text-default fixed inset-0 flex flex-col items-center justify-center"
41
- :style="{ zIndex: useGridConfig().useZIndex('modal') }"
42
+ :style="{ zIndex: useZIndex('modal') }"
42
43
  >
43
44
  <button
44
45
  class="absolute top-[3vh] right-[5vw] cursor-pointer border-0 bg-transparent p-2"
@@ -1,5 +1,9 @@
1
+ <script setup lang="ts">
2
+ const site = useSite()
3
+ </script>
4
+
1
5
  <template>
2
- <span v-for="(word, index) in useSite().subtitleWords" :key="index" class="site-word">
6
+ <span v-for="(word, index) in site.subtitleWords" :key="index" class="site-word">
3
7
  {{ word }}
4
8
  </span>
5
9
  </template>
@@ -1,5 +1,9 @@
1
+ <script setup lang="ts">
2
+ const site = useSite()
3
+ </script>
4
+
1
5
  <template>
2
- <span v-for="(word, index) in useSite().titleWords" :key="index" class="site-word">
6
+ <span v-for="(word, index) in site.titleWords" :key="index" class="site-word">
3
7
  {{ word }}
4
8
  </span>
5
9
  </template>
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "kmcom-nuxt-layers",
3
3
  "private": false,
4
- "version": "5.0.2",
4
+ "version": "5.0.3",
5
5
  "description": "Composable Nuxt 4 layers for building scalable Vue applications",
6
6
  "exports": {
7
7
  "./layers/core": "./layers/core/nuxt.config.ts",