rimelight-components 1.10.0 → 2.0.1

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
@@ -17,12 +17,13 @@ Find and replace all on all files (CMD+SHIFT+F):
17
17
  My new Nuxt module for doing amazing things.
18
18
 
19
19
  - [✨  Release Notes](/CHANGELOG.md)
20
- <!-- - [🏀 Online playground](https://stackblitz.com/github/your-org/my-module?file=playground%2Fapp.vue) -->
21
- <!-- - [📖 &nbsp;Documentation](https://example.com) -->
20
+ <!-- - [🏀 Online playground](https://stackblitz.com/github/your-org/my-module?file=playground%2Fapp.vue) -->
21
+ <!-- - [📖 &nbsp;Documentation](https://example.com) -->
22
22
 
23
23
  ## Features
24
24
 
25
25
  <!-- Highlight some of the features your module provide here -->
26
+
26
27
  - ⛰ &nbsp;Foo
27
28
  - 🚠 &nbsp;Bar
28
29
  - 🌲 &nbsp;Baz
@@ -37,7 +38,6 @@ npx nuxi module add my-module
37
38
 
38
39
  That's it! You can now use My Module in your Nuxt app ✨
39
40
 
40
-
41
41
  ## Contribution
42
42
 
43
43
  <details>
@@ -69,16 +69,13 @@ That's it! You can now use My Module in your Nuxt app ✨
69
69
 
70
70
  </details>
71
71
 
72
-
73
72
  <!-- Badges -->
73
+
74
74
  [npm-version-src]: https://img.shields.io/npm/v/my-module/latest.svg?style=flat&colorA=020420&colorB=00DC82
75
75
  [npm-version-href]: https://npmjs.com/package/my-module
76
-
77
76
  [npm-downloads-src]: https://img.shields.io/npm/dm/my-module.svg?style=flat&colorA=020420&colorB=00DC82
78
77
  [npm-downloads-href]: https://npm.chart.dev/my-module
79
-
80
78
  [license-src]: https://img.shields.io/npm/l/my-module.svg?style=flat&colorA=020420&colorB=00DC82
81
79
  [license-href]: https://npmjs.com/package/my-module
82
-
83
80
  [nuxt-src]: https://img.shields.io/badge/Nuxt-020420?logo=nuxt.js
84
81
  [nuxt-href]: https://nuxt.com
package/dist/module.d.mts CHANGED
@@ -6,6 +6,11 @@ interface CalloutOptions {
6
6
  tooltip: string;
7
7
  }
8
8
  interface ModuleOptions {
9
+ /**
10
+ * Prefix for components
11
+ * @defaultValue `RC`
12
+ */
13
+ prefix?: string;
9
14
  callouts: {
10
15
  info: CalloutOptions;
11
16
  success: CalloutOptions;
@@ -19,3 +24,4 @@ interface ModuleOptions {
19
24
  declare const _default: _nuxt_schema.NuxtModule<ModuleOptions, ModuleOptions, false>;
20
25
 
21
26
  export { _default as default };
27
+ export type { ModuleOptions };
package/dist/module.json CHANGED
@@ -1,12 +1,13 @@
1
1
  {
2
2
  "name": "rimelight-components",
3
- "version": "0.0.1",
3
+ "version": "2.0.1",
4
+ "docs": "https://rimelight.com/tools/rimelight-components",
4
5
  "configKey": "rimelightComponents",
5
6
  "compatibility": {
6
7
  "nuxt": ">=4.0.0"
7
8
  },
8
9
  "builder": {
9
10
  "@nuxt/module-builder": "1.0.2",
10
- "unbuild": "unknown"
11
+ "unbuild": "3.6.1"
11
12
  }
12
13
  }
package/dist/module.mjs CHANGED
@@ -1,6 +1,14 @@
1
- import { defineNuxtModule, createResolver, addComponentsDir, addImportsDir } from '@nuxt/kit';
1
+ import { addTemplate, defineNuxtModule, createResolver, addComponentsDir, addImportsDir } from '@nuxt/kit';
2
+ import { defu } from 'defu';
3
+ import { readdirSync } from 'node:fs';
4
+ import { basename } from 'node:path';
5
+
6
+ const name = "rimelight-components";
7
+ const version = "2.0.1";
8
+ const homepage = "https://rimelight.com/tools/rimelight-components";
2
9
 
3
10
  const defaultOptions = {
11
+ prefix: "RC",
4
12
  callouts: {
5
13
  info: {
6
14
  icon: "lucide:shield-alert",
@@ -39,10 +47,48 @@ const defaultOptions = {
39
47
  }
40
48
  }
41
49
  };
50
+
51
+ function addBlockMapTemplates(blockNames, resolver) {
52
+ const template = addTemplate({
53
+ filename: "rimelight-blocks-map.mjs",
54
+ getContents: () => {
55
+ let content = "export const BLOCK_COMPONENT_MAP = {\n";
56
+ blockNames.forEach((name) => {
57
+ const componentPath = `rimelight-components/runtime/components/blocks/${name}.vue`;
58
+ content += ` '${name}': () => import('${componentPath}'),
59
+ `;
60
+ });
61
+ content += "}\n";
62
+ return content;
63
+ },
64
+ write: true
65
+ });
66
+ addTemplate({
67
+ filename: "rimelight-blocks-map.d.ts",
68
+ getContents: () => {
69
+ const componentImporterType = '() => Promise<{ default: import("vue").Component }>';
70
+ let content = `// Generated by rimelight-components Nuxt Module
71
+ `;
72
+ content += `import { Component } from 'vue'
73
+ `;
74
+ content += `export declare const BLOCK_COMPONENT_MAP: { [key: string]: ${componentImporterType} | undefined }
75
+ `;
76
+ blockNames.forEach((name) => {
77
+ content += `export declare const ${name}: ${componentImporterType}
78
+ `;
79
+ });
80
+ return content;
81
+ },
82
+ write: true
83
+ });
84
+ return template;
85
+ }
86
+
42
87
  const module = defineNuxtModule({
43
88
  meta: {
44
- name: "rimelight-components",
45
- version: "0.0.1",
89
+ name,
90
+ version,
91
+ docs: homepage,
46
92
  configKey: "rimelightComponents",
47
93
  compatibility: {
48
94
  nuxt: ">=4.0.0"
@@ -100,14 +146,26 @@ const module = defineNuxtModule({
100
146
  },
101
147
  setup(options, nuxt) {
102
148
  const resolver = createResolver(import.meta.url);
103
- nuxt.options.appConfig.rimelightComponents = options;
149
+ nuxt.options.appConfig.rimelightComponents = defu(
150
+ nuxt.options.appConfig.rimelightComponents || {},
151
+ options
152
+ );
104
153
  addComponentsDir({
105
154
  path: resolver.resolve("./runtime/components/"),
106
155
  pathPrefix: false,
107
- prefix: "RC",
156
+ prefix: options.prefix,
108
157
  global: true
109
158
  });
110
159
  addImportsDir(resolver.resolve("./runtime/composables"));
160
+ addImportsDir(resolver.resolve("./runtime/types"));
161
+ addImportsDir(resolver.resolve("./runtime/utils"));
162
+ const blocksPath = resolver.resolve("./runtime/components/blocks");
163
+ const blockFiles = readdirSync(blocksPath).filter(
164
+ (name2) => name2.endsWith(".vue")
165
+ );
166
+ const blockNames = blockFiles.map((file) => basename(file, ".vue"));
167
+ const template = addBlockMapTemplates(blockNames);
168
+ nuxt.options.alias["#build/rimelight-blocks-map"] = template.dst;
111
169
  },
112
170
  onInstall() {
113
171
  console.log("Setting up rimelight-components for the first time!");
@@ -2,9 +2,9 @@
2
2
 
3
3
  <template>
4
4
  <footer class="py-8 lg:py-12">
5
- <UContainer class="gap-xl flex flex-col justify-between lg:flex-row">
5
+ <UContainer class="flex flex-col justify-between gap-xl lg:flex-row">
6
6
  <div
7
- class="gap-xl order-last flex flex-col items-center justify-between lg:order-1 lg:items-start"
7
+ class="order-last flex flex-col items-center justify-between gap-xl lg:order-1 lg:items-start"
8
8
  >
9
9
  <slot name="left" />
10
10
  </div>
@@ -12,7 +12,7 @@
12
12
  <slot name="center" />
13
13
  </div>
14
14
  <div
15
- class="gap-xl order-first flex flex-col items-center justify-between lg:order-3 lg:flex-1 lg:items-end"
15
+ class="order-first flex flex-col items-center justify-between gap-xl lg:order-3 lg:flex-1 lg:items-end"
16
16
  >
17
17
  <slot name="right" />
18
18
  </div>
@@ -14,11 +14,7 @@ const {
14
14
 
15
15
  <template>
16
16
  <UForm>
17
- <UFormField
18
- name="email"
19
- :label="fieldLabel"
20
- :description="description"
21
- >
17
+ <UFormField name="email" :label="fieldLabel" :description="description">
22
18
  <UFieldGroup class="pt-2">
23
19
  <UInput type="email" :placeholder="placeholder" />
24
20
  <UButton type="submit" :label="buttonLabel" />
@@ -3,8 +3,8 @@ interface Props {
3
3
  duration?: number;
4
4
  }
5
5
  declare const __VLS_export: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {
6
- duration: number;
7
6
  circleStrokeWidth: number;
7
+ duration: number;
8
8
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
9
9
  declare const _default: typeof __VLS_export;
10
10
  export default _default;
@@ -55,7 +55,7 @@ const durationInSeconds = computed(() => `${props.duration}s`);
55
55
  <div v-if="isVisible">
56
56
  <UButton
57
57
  variant="ghost"
58
- class="fixed bottom-4 right-4 z-50 size-20 lg:size-16"
58
+ class="fixed right-4 bottom-4 z-50 size-20 lg:size-16"
59
59
  @click="scrollToTop"
60
60
  >
61
61
  <div class="progress-circle-base size-full">
@@ -3,8 +3,8 @@ interface Props {
3
3
  duration?: number;
4
4
  }
5
5
  declare const __VLS_export: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {
6
- duration: number;
7
6
  circleStrokeWidth: number;
7
+ duration: number;
8
8
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
9
9
  declare const _default: typeof __VLS_export;
10
10
  export default _default;
@@ -9,7 +9,7 @@ const { src, alt, caption } = defineProps({
9
9
  <template>
10
10
  <figure class="mx-auto">
11
11
  <img :src="src" :alt="alt" class="h-auto w-full object-cover" />
12
- <figcaption v-if="caption" class="text-muted mt-4 text-center text-sm">
12
+ <figcaption v-if="caption" class="mt-4 text-center text-sm text-muted">
13
13
  {{ caption }}
14
14
  </figcaption>
15
15
  </figure>
@@ -1,6 +1,6 @@
1
1
  <script setup>
2
2
  import { computed } from "vue";
3
- import { slugify } from "../../utils/slugify";
3
+ import { slugify } from "../../utils";
4
4
  const { level, title, description, children } = defineProps({
5
5
  level: { type: Number, required: true },
6
6
  title: { type: String, required: true },
@@ -9,21 +9,21 @@ const {} = defineProps({
9
9
  </script>
10
10
 
11
11
  <template>
12
- <UCard>
13
- <NuxtImg :src="src" :alt="alt" />
14
- <div class="flex flex-col gap-xs">
15
- <h3 class="text-xl font-bold">
16
- {{ name }}
17
- </h3>
18
- <span class="text-sm">{{ role }}</span>
19
- </div>
20
- <p class="text-md">
21
- {{ description }}
22
- </p>
23
- <template #footer>
24
- <div class="flex flex-row gap-md">
25
- <slot name="links" />
26
- </div>
27
- </template>
28
- </UCard>
12
+ <UCard>
13
+ <NuxtImg :src="src" :alt="alt" />
14
+ <div class="flex flex-col gap-xs">
15
+ <h3 class="text-xl font-bold">
16
+ {{ name }}
17
+ </h3>
18
+ <span class="text-sm">{{ role }}</span>
19
+ </div>
20
+ <p class="text-md">
21
+ {{ description }}
22
+ </p>
23
+ <template #footer>
24
+ <div class="flex flex-row gap-md">
25
+ <slot name="links" />
26
+ </div>
27
+ </template>
28
+ </UCard>
29
29
  </template>
@@ -1,5 +1,8 @@
1
1
  <script setup>
2
- import { useClipboard, useToast, useRoute, computed } from "#imports";
2
+ import { useRoute } from "#imports";
3
+ import { computed } from "vue";
4
+ import { useClipboard } from "@vueuse/core";
5
+ import { useToast } from "#imports";
3
6
  import { tv } from "tailwind-variants";
4
7
  import { slugify } from "../../utils";
5
8
  const { copy } = useClipboard();
@@ -24,21 +24,21 @@ const {
24
24
  <ULink v-if="previousTitle" :to="previousTo" class="h-full">
25
25
  <UCard
26
26
  variant="outline"
27
- class="hover:bg-elevated/50 focus-visible:outline-primary group block h-full bg-transparent"
27
+ class="group block h-full bg-transparent hover:bg-elevated/50 focus-visible:outline-primary"
28
28
  >
29
- <div class="gap-md flex flex-col">
30
- <div class="gap-xs flex flex-col">
29
+ <div class="flex flex-col gap-md">
30
+ <div class="flex flex-col gap-xs">
31
31
  <UButton
32
32
  variant="outline"
33
33
  icon="lucide:arrow-left"
34
- class="group-hover text-primary group-hover:text-highlighted w-fit rounded-full"
34
+ class="group-hover w-fit rounded-full text-primary group-hover:text-highlighted"
35
35
  />
36
36
  <span class="text-muted">
37
37
  {{ $t("navigation_previous") }}
38
38
  {{ $t(pageType) }}
39
39
  </span>
40
40
  </div>
41
- <div class="gap-xs flex flex-col">
41
+ <div class="flex flex-col gap-xs">
42
42
  <p class="text-primary group-hover:text-highlighted">
43
43
  {{ previousTitle }}
44
44
  </p>
@@ -54,25 +54,25 @@ const {
54
54
  <ULink v-if="nextTitle" :to="nextTo" class="h-full">
55
55
  <UCard
56
56
  variant="outline"
57
- class="hover:bg-elevated/50 focus-visible:outline-primary group block h-full bg-transparent"
57
+ class="group block h-full bg-transparent hover:bg-elevated/50 focus-visible:outline-primary"
58
58
  >
59
- <div class="gap-md flex flex-col items-end">
60
- <div class="gap-xs flex flex-col items-end">
59
+ <div class="flex flex-col items-end gap-md">
60
+ <div class="flex flex-col items-end gap-xs">
61
61
  <UButton
62
62
  variant="outline"
63
63
  icon="lucide:arrow-right"
64
- class="text-primary group-hover:text-highlighted w-fit rounded-full"
64
+ class="w-fit rounded-full text-primary group-hover:text-highlighted"
65
65
  />
66
66
  <span class="text-muted">
67
67
  {{ $t("navigation_next") }}
68
68
  {{ $t(pageType) }}</span
69
69
  >
70
70
  </div>
71
- <div class="gap-xs flex flex-col items-end">
72
- <p class="text-primary group-hover:text-highlighted text-right">
71
+ <div class="flex flex-col items-end gap-xs">
72
+ <p class="text-right text-primary group-hover:text-highlighted">
73
73
  {{ nextTitle }}
74
74
  </p>
75
- <p class="text-toned text-right">
75
+ <p class="text-right text-toned">
76
76
  {{ nextDescription }}
77
77
  </p>
78
78
  </div>
@@ -19,7 +19,7 @@ const getComponent = (block) => {
19
19
  </script>
20
20
 
21
21
  <template>
22
- <div class="gap-lg flex flex-col">
22
+ <div class="flex flex-col gap-lg">
23
23
  <UEmpty
24
24
  v-if="!blocks || blocks.length === 0"
25
25
  variant="naked"
@@ -1,6 +1,6 @@
1
1
  <script setup>
2
2
  import { computed } from "vue";
3
- import { slugify } from "../../utils/slugify";
3
+ import { slugify } from "../../utils";
4
4
  const {
5
5
  pageBlocks,
6
6
  title = "table_of_contents",
@@ -1,5 +1,7 @@
1
1
  <script setup>
2
- import { useClipboard, useToast, computed } from "#imports";
2
+ import { computed } from "vue";
3
+ import { useClipboard } from "@vueuse/core";
4
+ import { useToast } from "#imports";
3
5
  const { copy } = useClipboard();
4
6
  const toast = useToast();
5
7
  const { name, hex, rgb, hsl, oklch, cmyk } = defineProps({
@@ -44,12 +46,12 @@ const color = computed(() => {
44
46
  <template #header v-if="name">
45
47
  <h3 class="text-lg font-bold">{{ name }}</h3>
46
48
  </template>
47
- <div class="gap-sm flex flex-col items-center xl:flex-row xl:items-start">
49
+ <div class="flex flex-col items-center gap-sm xl:flex-row xl:items-start">
48
50
  <div
49
- class="p-sm flex aspect-square size-48"
51
+ class="flex aspect-square size-48 p-sm"
50
52
  :style="{ backgroundColor: color }"
51
53
  >
52
- <div class="gap-xs flex flex-col justify-end text-xs">
54
+ <div class="flex flex-col justify-end gap-xs text-xs">
53
55
  <span v-if="name" class="text-sm">{{ formatColor(name) }}</span>
54
56
  <span v-if="hex">HEX {{ formatColor(hex) }}</span>
55
57
  <span v-if="rgb">{{ formatColor(rgb) }}</span>
@@ -58,7 +60,7 @@ const color = computed(() => {
58
60
  <span v-if="cmyk">{{ formatColor(cmyk) }}</span>
59
61
  </div>
60
62
  </div>
61
- <div class="gap-sm flex w-full flex-col justify-center">
63
+ <div class="flex w-full flex-col justify-center gap-sm">
62
64
  <UButton
63
65
  v-if="hex"
64
66
  variant="outline"
@@ -22,7 +22,7 @@ const image = computed(() => {
22
22
  <h3 class="text-lg font-bold">{{ name }}</h3>
23
23
  <span></span>
24
24
  </template>
25
- <div class="gap-sm flex flex-col">
25
+ <div class="flex flex-col gap-sm">
26
26
  <h1>H1</h1>
27
27
  <p>{{}}</p>
28
28
  </div>
@@ -31,8 +31,8 @@ const image = computed(() => {
31
31
  <p>a b c d e f g h i j k l m n o p q r s t u v w x y z</p>
32
32
  <p>A B C D E F G H I J K L M N O P Q R S T U V W X Y Z</p>
33
33
  <p></p>
34
- <div class="gap-sm flex flex-col items-center xl:flex-row xl:items-start">
35
- <div class="gap-sm flex w-full flex-col justify-center">
34
+ <div class="flex flex-col items-center gap-sm xl:flex-row xl:items-start">
35
+ <div class="flex w-full flex-col justify-center gap-sm">
36
36
  <UButton
37
37
  v-if="jpg"
38
38
  variant="outline"
@@ -21,9 +21,9 @@ const image = computed(() => {
21
21
  <template #header v-if="name">
22
22
  <h3 class="text-lg font-bold">{{ name }}</h3>
23
23
  </template>
24
- <div class="gap-sm flex flex-col items-center xl:flex-row xl:items-start">
24
+ <div class="flex flex-col items-center gap-sm xl:flex-row xl:items-start">
25
25
  <NuxtImg :src="image" class="size-48" />
26
- <div class="gap-sm flex w-full flex-col justify-center">
26
+ <div class="flex w-full flex-col justify-center gap-sm">
27
27
  <UButton
28
28
  v-if="jpg"
29
29
  variant="outline"
@@ -1,30 +1,30 @@
1
- <script setup lang="ts"></script>
2
-
3
- <template>
4
- <div
5
- class="relative flex items-center justify-center overflow-hidden rounded-sm border border-dashed border-accented px-4 opacity-75"
6
- >
7
- <svg class="absolute inset-0 h-full w-full stroke-inverted/10">
8
- <defs>
9
- <pattern
10
- id="pattern-5c1e4f0e-62d5-498b-8ff0-cf77bb448c8e"
11
- x="0"
12
- y="0"
13
- width="10"
14
- height="10"
15
- patternUnits="userSpaceOnUse"
16
- >
17
- <path d="M-3 13 15-5M-5 5l18-18M-1 21 17 3" />
18
- </pattern>
19
- </defs>
20
- <rect
21
- stroke="none"
22
- fill="url(#pattern-5c1e4f0e-62d5-498b-8ff0-cf77bb448c8e)"
23
- width="100%"
24
- height="100%"
25
- />
26
- </svg>
27
-
28
- <slot />
29
- </div>
30
- </template>
1
+ <script setup lang="ts"></script>
2
+
3
+ <template>
4
+ <div
5
+ class="relative flex items-center justify-center overflow-hidden rounded-sm border border-dashed border-accented px-4 opacity-75"
6
+ >
7
+ <svg class="absolute inset-0 h-full w-full stroke-inverted/10">
8
+ <defs>
9
+ <pattern
10
+ id="pattern-5c1e4f0e-62d5-498b-8ff0-cf77bb448c8e"
11
+ x="0"
12
+ y="0"
13
+ width="10"
14
+ height="10"
15
+ patternUnits="userSpaceOnUse"
16
+ >
17
+ <path d="M-3 13 15-5M-5 5l18-18M-1 21 17 3" />
18
+ </pattern>
19
+ </defs>
20
+ <rect
21
+ stroke="none"
22
+ fill="url(#pattern-5c1e4f0e-62d5-498b-8ff0-cf77bb448c8e)"
23
+ width="100%"
24
+ height="100%"
25
+ />
26
+ </svg>
27
+
28
+ <slot />
29
+ </div>
30
+ </template>
@@ -1,3 +1,3 @@
1
1
  {
2
- "extends": "../../../.nuxt/tsconfig.server.json",
2
+ "extends": "../../../.nuxt/tsconfig.server.json"
3
3
  }
@@ -0,0 +1,6 @@
1
+ declare module "#build/app.config" {
2
+ import type { AppConfig } from "@nuxt/schema"
3
+
4
+ const _default: AppConfig
5
+ export default _default
6
+ }
@@ -1,16 +1,10 @@
1
1
  import { defineAsyncComponent } from "vue";
2
- const BLOCK_COMPONENTS = import.meta.glob(
3
- "../components/blocks/*.vue"
4
- );
5
- const typeToRelativePath = (type) => {
6
- return `/components/blocks/${type}.vue`;
7
- };
2
+ import { BLOCK_COMPONENT_MAP } from "#build/rimelight-blocks-map";
8
3
  export const getBlockComponent = (type) => {
9
- const componentPath = typeToRelativePath(type);
10
- const componentImporter = BLOCK_COMPONENTS[componentPath];
4
+ const componentImporter = BLOCK_COMPONENT_MAP[type];
11
5
  if (!componentImporter) {
12
6
  console.warn(
13
- `[BlockMapper] Block component not found for type: ${type}. Expected path: ${componentPath}`
7
+ `[BlockMapper] Block component not found for type: ${type}. Please check block name.`
14
8
  );
15
9
  return void 0;
16
10
  }
@@ -7,5 +7,5 @@ export function slugify(text) {
7
7
  if (!text) {
8
8
  return "";
9
9
  }
10
- return text.toString().normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase().trim().replace(/\s+/g, "-").replace(/[^\w\-]+/g, "").replace(/\-\-+/g, "-").replace(/^-+/, "").replace(/-+$/, "");
10
+ return text.toString().normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase().trim().replace(/\s+/g, "-").replace(/[^\w-]+/g, "").replace(/--+/g, "-").replace(/^-+/, "").replace(/-+$/, "");
11
11
  }
package/dist/types.d.mts CHANGED
@@ -1,7 +1,3 @@
1
- import type { NuxtModule } from '@nuxt/schema'
2
-
3
- import type { default as Module } from './module.mjs'
4
-
5
- export type ModuleOptions = typeof Module extends NuxtModule<infer O> ? Partial<O> : Record<string, any>
6
-
7
1
  export { default } from './module.mjs'
2
+
3
+ export { type ModuleOptions } from './module.mjs'
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
+ "type": "module",
2
3
  "name": "rimelight-components",
3
- "description": "My new Nuxt module",
4
- "version": "1.10.0",
4
+ "description": "A component library by Rimelight Entertainment.",
5
+ "version": "2.0.1",
5
6
  "repository": {
6
7
  "type": "git",
7
8
  "url": "git+https://github.com/Rimelight-Entertainment/rimelight-components.git"
8
9
  },
9
10
  "homepage": "https://rimelight.com/tools/rimelight-components",
10
- "type": "module",
11
11
  "license": "MIT",
12
12
  "keywords": [
13
13
  "rimelight",
@@ -33,11 +33,30 @@
33
33
  "import": "./dist/runtime/utils/*.js"
34
34
  }
35
35
  },
36
+ "style": "./dist/runtime/index.css",
36
37
  "main": "./dist/module.mjs",
37
38
  "typesVersions": {
38
39
  "*": {
39
40
  ".": [
40
- "./dist/types.d.mts"
41
+ "./dist/module.d.mts"
42
+ ],
43
+ "vite": [
44
+ "./dist/vite.d.mts"
45
+ ],
46
+ "./runtime/*": [
47
+ "./dist/runtime/index.d.ts"
48
+ ],
49
+ "components/*": [
50
+ "./dist/runtime/components/*"
51
+ ],
52
+ "composables/*": [
53
+ "./dist/runtime/composables/*"
54
+ ],
55
+ "utils": [
56
+ "./dist/runtime/utils/index.d.ts"
57
+ ],
58
+ "utils/*": [
59
+ "./dist/runtime/utils/*.d.ts"
41
60
  ]
42
61
  }
43
62
  },
@@ -45,21 +64,21 @@
45
64
  "dist"
46
65
  ],
47
66
  "scripts": {
48
- "prepack": "nuxt-module-build build",
49
- "dev": "bun run dev:prepare && nuxi dev playground",
50
- "dev:build": "nuxi build playground",
67
+ "build": "nuxt-module-build build",
68
+ "dev": "bun run dev:prepare && nuxt dev playground",
69
+ "dev:build": "nuxt build playground",
51
70
  "dev:prepare": "nuxt-module-build build --stub && nuxt-module-build prepare && nuxi prepare playground",
52
- "release": "bun run lint && bun run test && bun run prepack && changelogen --release && bun publish && git push --follow-tags",
71
+ "prepack": "bun run build",
53
72
  "typecheck": "vue-tsc --noEmit && nuxt typecheck",
54
73
  "lint": "oxlint .",
55
74
  "lint:fix": "oxlint . --fix",
75
+ "format": "prettier . --check .",
76
+ "format:fix": "prettier . --write .",
56
77
  "test": "vitest run",
57
78
  "test:watch": "vitest watch",
58
- "test:types": "vue-tsc --noEmit && cd playground && vue-tsc --noEmit"
79
+ "test:types": "vue-tsc --noEmit && cd playground && vue-tsc --noEmit",
80
+ "release": "bun run lint && bun run test && bun run prepack && changelogen --release && bun publish && git push --follow-tags"
59
81
  },
60
- "workspaces": [
61
- "playground"
62
- ],
63
82
  "dependencies": {
64
83
  "@nuxt/image": "^1.11.0",
65
84
  "@nuxt/kit": "^4.2.0",
@@ -68,6 +87,7 @@
68
87
  "@vueuse/core": "^14.0.0",
69
88
  "@vueuse/nuxt": "^14.0.0",
70
89
  "date-fns": "^4.1.0",
90
+ "defu": "^6.1.4",
71
91
  "nuxt": "^4.2.0",
72
92
  "tailwind-variants": "^3.1.1",
73
93
  "vue": "^3.5.22"
@@ -96,5 +116,8 @@
96
116
  "trustedDependencies": [
97
117
  "@parcel/watcher",
98
118
  "@tailwindcss/oxide"
99
- ]
119
+ ],
120
+ "resolutions": {
121
+ "rimelight-components": "workspace:*"
122
+ }
100
123
  }
@@ -1,6 +0,0 @@
1
- /**
2
- * Converts a string to a URL-friendly slug.
3
- * @param str The input string.
4
- * @returns The slugified string.
5
- */
6
- export declare function slugify(str: string): string;
@@ -1,3 +0,0 @@
1
- export function slugify(str) {
2
- return str.toLowerCase().trim().replace(/[^\w\s-]/g, "").replace(/[\s_-]+/g, "-").replace(/^-+|-+$/g, "");
3
- }