orio-ui 1.0.1 → 1.0.2

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.
Files changed (61) hide show
  1. package/README.md +9 -7
  2. package/dist/module.cjs +5 -0
  3. package/dist/module.d.mts +3 -0
  4. package/dist/module.d.ts +3 -0
  5. package/dist/module.json +12 -0
  6. package/dist/module.mjs +24 -0
  7. package/dist/runtime/assets/css/animation.css +1 -0
  8. package/dist/runtime/assets/css/colors.css +1 -0
  9. package/{src/runtime/assets/css/cool-gradient-hover.scss → dist/runtime/assets/css/cool-gradient-hover.css} +4 -14
  10. package/dist/runtime/assets/css/main.css +1 -0
  11. package/dist/runtime/assets/css/scroll.css +1 -0
  12. package/{src → dist}/runtime/components/Button.vue +38 -46
  13. package/dist/runtime/components/CheckBox.vue +93 -0
  14. package/{src → dist}/runtime/components/ControlElement.vue +13 -16
  15. package/{src → dist}/runtime/components/DashedContainer.vue +6 -7
  16. package/dist/runtime/components/DatePicker.vue +30 -0
  17. package/{src → dist}/runtime/components/DateRangePicker.vue +14 -15
  18. package/{src → dist}/runtime/components/EmptyState.vue +22 -28
  19. package/{src → dist}/runtime/components/Icon.vue +1 -12
  20. package/{src → dist}/runtime/components/Input.vue +18 -24
  21. package/{src → dist}/runtime/components/Modal.vue +1 -43
  22. package/{src → dist}/runtime/components/Popover.vue +1 -1
  23. package/{src → dist}/runtime/components/Selector.vue +36 -52
  24. package/dist/runtime/components/Tag.vue +21 -0
  25. package/{src → dist}/runtime/components/Textarea.vue +18 -24
  26. package/{src → dist}/runtime/components/view/Dates.vue +1 -3
  27. package/{src → dist}/runtime/components/view/Separator.vue +1 -5
  28. package/{src → dist}/runtime/components/view/Text.vue +38 -42
  29. package/dist/runtime/composables/index.d.ts +4 -0
  30. package/dist/runtime/composables/index.js +6 -0
  31. package/dist/runtime/composables/useApi.d.ts +10 -0
  32. package/dist/runtime/composables/useApi.js +9 -0
  33. package/dist/runtime/composables/useFuzzySearch.d.ts +10 -0
  34. package/dist/runtime/composables/useFuzzySearch.js +22 -0
  35. package/dist/runtime/composables/useModal.d.ts +15 -0
  36. package/dist/runtime/composables/useModal.js +28 -0
  37. package/dist/runtime/composables/useTheme.d.ts +6 -0
  38. package/dist/runtime/composables/useTheme.js +23 -0
  39. package/dist/runtime/index.d.ts +20 -0
  40. package/dist/runtime/index.js +20 -0
  41. package/dist/runtime/utils/icon-registry.d.ts +2 -0
  42. package/{src/runtime/utils/icon-registry.ts → dist/runtime/utils/icon-registry.js} +5 -20
  43. package/dist/types.d.mts +7 -0
  44. package/dist/types.d.ts +7 -0
  45. package/package.json +11 -15
  46. package/nuxt.config.ts +0 -38
  47. package/src/module.ts +0 -16
  48. package/src/runtime/assets/css/animation.css +0 -88
  49. package/src/runtime/assets/css/colors.css +0 -142
  50. package/src/runtime/assets/css/main.css +0 -11
  51. package/src/runtime/assets/css/scroll.css +0 -46
  52. package/src/runtime/components/CheckBox.vue +0 -103
  53. package/src/runtime/components/DatePicker.vue +0 -84
  54. package/src/runtime/components/Tag.vue +0 -49
  55. package/src/runtime/composables/index.ts +0 -9
  56. package/src/runtime/composables/useApi.ts +0 -32
  57. package/src/runtime/composables/useFuzzySearch.ts +0 -51
  58. package/src/runtime/composables/useModal.ts +0 -47
  59. package/src/runtime/composables/useTheme.ts +0 -31
  60. package/src/runtime/index.ts +0 -25
  61. /package/{src → dist}/runtime/components/LoadingSpinner.vue +0 -0
@@ -151,7 +151,7 @@ const selectorAttrs = computed(() => ({ getOptionKey, getOptionLabel }));
151
151
  </orio-control-element>
152
152
  </template>
153
153
 
154
- <style lang="scss" scoped>
154
+ <style scoped>
155
155
  .selector-trigger {
156
156
  z-index: 1;
157
157
  min-height: 1.5rem;
@@ -160,74 +160,58 @@ const selectorAttrs = computed(() => ({ getOptionKey, getOptionLabel }));
160
160
  align-items: center;
161
161
  justify-content: space-between;
162
162
  cursor: pointer;
163
-
164
163
  background: var(--color-bg);
165
164
  border: 1px solid var(--color-border);
166
165
  border-radius: 6px;
167
166
  padding: 0.5rem 0.75rem;
168
167
  font-size: 0.95rem;
169
168
  color: var(--color-text);
170
- transition:
171
- border-color 0.2s ease,
172
- box-shadow 0.2s ease,
173
- background-color 0.2s ease;
174
-
175
- &:hover {
176
- border-color: var(--color-accent);
177
- background-color: var(--color-surface); /* subtle lift */
178
- }
179
-
180
- &:focus-within {
181
- border-color: var(--color-accent);
182
- box-shadow: 0 0 0 2px var(--color-surface);
183
- }
184
-
185
- .icon {
186
- color: var(--color-muted);
187
- transition: color 0.2s ease;
188
- }
189
-
190
- &:hover .icon {
191
- color: var(--color-accent);
192
- }
169
+ transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
170
+ }
171
+ .selector-trigger:hover {
172
+ border-color: var(--color-accent);
173
+ background-color: var(--color-surface); /* subtle lift */
174
+ }
175
+ .selector-trigger:focus-within {
176
+ border-color: var(--color-accent);
177
+ box-shadow: 0 0 0 2px var(--color-surface);
178
+ }
179
+ .selector-trigger .icon {
180
+ color: var(--color-muted);
181
+ transition: color 0.2s ease;
182
+ }
183
+ .selector-trigger:hover .icon {
184
+ color: var(--color-accent);
193
185
  }
194
186
 
195
187
  .selector-content {
196
188
  min-width: 15rem;
197
189
  max-height: 20rem;
198
190
  overflow: auto;
199
-
200
191
  background: var(--color-bg);
201
192
  border: 1px solid var(--color-border);
202
193
  border-radius: 6px;
203
194
  margin-top: 0.25rem;
204
195
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
205
-
206
- ul {
207
- list-style: none;
208
- padding: 0;
209
- margin: 0;
210
-
211
- li {
212
- padding: 0.5rem 0.75rem;
213
- cursor: pointer;
214
- transition:
215
- background-color 0.15s ease,
216
- color 0.15s ease;
217
-
218
- color: var(--color-text);
219
-
220
- &:hover {
221
- background-color: var(--color-surface); /* neutral lift */
222
- }
223
-
224
- &.selected {
225
- background-color: var(--color-accent);
226
- color: var(--color-accent-soft);
227
- font-weight: 500;
228
- }
229
- }
230
- }
196
+ }
197
+ .selector-content ul {
198
+ list-style: none;
199
+ padding: 0;
200
+ margin: 0;
201
+ }
202
+ .selector-content ul li {
203
+ padding: 0.5rem 0.75rem;
204
+ cursor: pointer;
205
+ transition: background-color 0.15s ease, color 0.15s ease;
206
+ color: var(--color-text);
207
+ }
208
+ .selector-content ul li:hover {
209
+ background-color: var(--color-surface); /* neutral lift */
210
+ }
211
+ .selector-content ul li.selected {
212
+ background-color: var(--color-accent);
213
+ color: var(--color-accent-soft);
214
+ font-weight: 500;
231
215
  }
232
216
 
233
217
  .trigger-content {
@@ -0,0 +1,21 @@
1
+ <script setup lang="ts">
2
+ export type TagStyle = 'neutral' | 'accent';
3
+
4
+ interface Props {
5
+ text: string;
6
+ variant?: TagStyle;
7
+ }
8
+ withDefaults(defineProps<Props>(), {
9
+ variant: 'neutral',
10
+ });
11
+ </script>
12
+
13
+ <template>
14
+ <span class="tag" :class="`tag--${variant}`">
15
+ {{ text }}
16
+ </span>
17
+ </template>
18
+
19
+ <style scoped>
20
+ .tag{border:1px solid transparent;border-radius:1rem;display:inline-block;font-size:.8rem;font-weight:500;line-height:1;max-height:1rem;padding:.25rem .6rem;-webkit-user-select:none;-moz-user-select:none;user-select:none}.tag--neutral{background-color:var(--color-surface);border-color:color-mix(in srgb,var(--color-border) 80%,var(--color-accent) 20%);color:var(--color-muted)}.tag--accent{background-color:var(--color-accent-soft);border-color:var(--color-accent-border);color:var(--color-accent)}
21
+ </style>
@@ -15,7 +15,7 @@ const modelValue = defineModel<string>({ default: '' });
15
15
  </orio-control-element>
16
16
  </template>
17
17
 
18
- <style lang="scss" scoped>
18
+ <style scoped>
19
19
  .textarea {
20
20
  width: 100%;
21
21
  padding: 0.5rem 0.75rem;
@@ -27,28 +27,22 @@ const modelValue = defineModel<string>({ default: '' });
27
27
  background-color: var(--color-bg);
28
28
  box-sizing: border-box;
29
29
  resize: vertical; /* Let user resize vertically only */
30
- transition:
31
- border-color 0.2s ease,
32
- box-shadow 0.2s ease;
33
-
34
- &::placeholder {
35
- color: var(--color-muted);
36
- }
37
-
38
- &:hover {
39
- border-color: var(--color-accent);
40
- }
41
-
42
- &:focus {
43
- border-color: var(--color-accent);
44
- box-shadow: 0 0 0 2px var(--color-accent-soft);
45
- outline: none;
46
- }
47
-
48
- &:disabled {
49
- background-color: var(--color-surface);
50
- color: var(--color-muted);
51
- cursor: not-allowed;
52
- }
30
+ transition: border-color 0.2s ease, box-shadow 0.2s ease;
31
+ }
32
+ .textarea::placeholder {
33
+ color: var(--color-muted);
34
+ }
35
+ .textarea:hover {
36
+ border-color: var(--color-accent);
37
+ }
38
+ .textarea:focus {
39
+ border-color: var(--color-accent);
40
+ box-shadow: 0 0 0 2px var(--color-accent-soft);
41
+ outline: none;
42
+ }
43
+ .textarea:disabled {
44
+ background-color: var(--color-surface);
45
+ color: var(--color-muted);
46
+ cursor: not-allowed;
53
47
  }
54
48
  </style>
@@ -55,7 +55,5 @@ const endDate = computed(() => {
55
55
  </template>
56
56
 
57
57
  <style scoped>
58
- .view-date * {
59
- display: inline;
60
- }
58
+ .view-date *{display:inline}
61
59
  </style>
@@ -22,9 +22,5 @@ const margin = computed(() => `${props.margin}rem`);
22
22
  </template>
23
23
 
24
24
  <style scoped>
25
- div {
26
- width: 100%;
27
- border-block-end: v-bind(sizePx) v-bind(style) var(--color-border);
28
- margin-block: v-bind(margin);
29
- }
25
+ div{border-block-end:v-bind(sizePx) v-bind(style) var(--color-border);margin-block:v-bind(margin);width:100%}
30
26
  </style>
@@ -32,52 +32,48 @@ const clampLines = computed(() => Number(props.lineClamp ?? 1));
32
32
  </div>
33
33
  </template>
34
34
 
35
- <style lang="scss" scoped>
35
+ <style scoped>
36
36
  div {
37
37
  white-space: pre-wrap;
38
38
  display: flex;
39
39
  align-items: center;
40
40
  gap: 0.25rem;
41
-
42
- &.clamp {
43
- display: -webkit-box;
44
- overflow: hidden;
45
- line-clamp: v-bind(clampLines);
46
- -webkit-line-clamp: v-bind(clampLines);
47
- -webkit-box-orient: vertical;
48
- }
49
-
50
- &.uppercase {
51
- text-transform: uppercase;
52
- }
53
-
54
- &.text {
55
- color: var(--color-text);
56
- }
57
- &.title {
58
- font-weight: bold;
59
- color: var(--color-text);
60
- }
61
- &.subtitle {
62
- font-weight: semi-bold;
63
- color: var(--color-muted);
64
- }
65
- &.italics {
66
- font-style: italic;
67
- color: var(--color-muted);
68
- }
69
-
70
- &.small {
71
- font-size: 0.75rem;
72
- }
73
- &.medium {
74
- font-size: 0.875rem;
75
- }
76
- &.large {
77
- font-size: 1.25rem;
78
- }
79
- &.extra-large {
80
- font-size: 1.75rem;
81
- }
41
+ }
42
+ div.clamp {
43
+ display: -webkit-box;
44
+ overflow: hidden;
45
+ line-clamp: v-bind(clampLines);
46
+ -webkit-line-clamp: v-bind(clampLines);
47
+ -webkit-box-orient: vertical;
48
+ }
49
+ div.uppercase {
50
+ text-transform: uppercase;
51
+ }
52
+ div.text {
53
+ color: var(--color-text);
54
+ }
55
+ div.title {
56
+ font-weight: bold;
57
+ color: var(--color-text);
58
+ }
59
+ div.subtitle {
60
+ font-weight: semi-bold;
61
+ color: var(--color-muted);
62
+ }
63
+ div.italics {
64
+ font-style: italic;
65
+ color: var(--color-muted);
66
+ }
67
+ div.small {
68
+ font-size: 0.75rem;
69
+ }
70
+ div.medium {
71
+ font-size: 0.875rem;
72
+ }
73
+ div.large {
74
+ font-size: 1.25rem;
75
+ }
76
+ div.extra-large {
77
+ font-size: 1.75rem;
82
78
  }
83
79
  </style>
@@ -0,0 +1,4 @@
1
+ export { useApi, type ApiOptions, type RequestBody, type RequestMethod, } from './useApi.js';
2
+ export { useFuzzySearch } from './useFuzzySearch.js';
3
+ export { useModal, type ModalProps, type OriginRect } from './useModal.js';
4
+ export { useTheme } from './useTheme.js';
@@ -0,0 +1,6 @@
1
+ export {
2
+ useApi
3
+ } from "./useApi.js";
4
+ export { useFuzzySearch } from "./useFuzzySearch.js";
5
+ export { useModal } from "./useModal.js";
6
+ export { useTheme } from "./useTheme.js";
@@ -0,0 +1,10 @@
1
+ export type RequestBody = Record<string, unknown>;
2
+ export type RequestMethod = 'GET' | 'POST' | 'PUT' | 'DELETE' | 'PATCH';
3
+ export interface ApiOptions {
4
+ method?: RequestMethod;
5
+ body?: RequestBody;
6
+ signal?: AbortSignal;
7
+ query?: Record<string, unknown>;
8
+ }
9
+ export declare function useApi<T = unknown>(url: string): Promise<T>;
10
+ export declare function useApi<T = unknown>(url: string, options: ApiOptions): Promise<T>;
@@ -0,0 +1,9 @@
1
+ import { $fetch } from "ofetch";
2
+ export async function useApi(url, options) {
3
+ return await $fetch(url, {
4
+ method: options?.method || "GET",
5
+ body: options?.body,
6
+ signal: options?.signal,
7
+ query: options?.query
8
+ });
9
+ }
@@ -0,0 +1,10 @@
1
+ import { type MaybeRef } from 'vue';
2
+ import { useFuse, type FuseOptions } from '@vueuse/integrations/useFuse';
3
+ /**
4
+ * Search using Fuse.js fuzzy search
5
+ * @param dataSource - Array of strings or objects to search
6
+ * @param search - Search query string
7
+ * @param options - Fuse.js options (e.g., { keys: ['name'] })
8
+ */
9
+ export declare function useFuzzySearch(dataSource: MaybeRef<string[]>, search: MaybeRef<string>): ReturnType<typeof useFuse>;
10
+ export declare function useFuzzySearch<T extends object>(dataSource: MaybeRef<T[]>, search: MaybeRef<string>, options: FuseOptions<T>): ReturnType<typeof useFuse>;
@@ -0,0 +1,22 @@
1
+ import { computed, unref } from "vue";
2
+ import { useFuse } from "@vueuse/integrations/useFuse";
3
+ export function useFuzzySearch(dataSource, search, options) {
4
+ const isObjectArray = !!options;
5
+ if (!isObjectArray) {
6
+ const wrappedData = computed(() => {
7
+ const data = unref(dataSource);
8
+ return data.map((str) => ({ value: str }));
9
+ });
10
+ const { results } = useFuse(search, wrappedData, {
11
+ fuseOptions: { keys: ["value"] },
12
+ matchAllWhenSearchEmpty: true
13
+ });
14
+ return computed(() => results.value.map(({ item }) => item.value));
15
+ } else {
16
+ const { results } = useFuse(search, dataSource, {
17
+ fuseOptions: options,
18
+ matchAllWhenSearchEmpty: true
19
+ });
20
+ return computed(() => results.value.map(({ item }) => item));
21
+ }
22
+ }
@@ -0,0 +1,15 @@
1
+ export interface OriginRect {
2
+ x: number;
3
+ y: number;
4
+ width: number;
5
+ height: number;
6
+ }
7
+ export interface ModalProps {
8
+ show: boolean;
9
+ origin: OriginRect | null;
10
+ 'onUpdate:show': (state: boolean) => void;
11
+ }
12
+ export declare function useModal(): {
13
+ modalProps: import("vue").Ref<any, any>;
14
+ openModal: (event?: MouseEvent) => void;
15
+ };
@@ -0,0 +1,28 @@
1
+ import { ref } from "vue";
2
+ export function useModal() {
3
+ const modalProps = ref({
4
+ show: false,
5
+ origin: null,
6
+ "onUpdate:show": (state) => updateShow(state)
7
+ });
8
+ function updateShow(state) {
9
+ modalProps.value.show = state;
10
+ }
11
+ function openModal(event) {
12
+ modalProps.value.origin = null;
13
+ if (!event) {
14
+ modalProps.value.show = true;
15
+ return;
16
+ }
17
+ const target = event.target;
18
+ const rect = target.getBoundingClientRect();
19
+ modalProps.value.origin = {
20
+ x: rect.left,
21
+ y: rect.top,
22
+ width: rect.width,
23
+ height: rect.height
24
+ };
25
+ modalProps.value.show = true;
26
+ }
27
+ return { modalProps, openModal };
28
+ }
@@ -0,0 +1,6 @@
1
+ export declare function useTheme(): {
2
+ theme: import("@vueuse/shared").RemovableRef<string>;
3
+ setTheme: (name: string) => void;
4
+ mode: import("@vueuse/shared").RemovableRef<string>;
5
+ setMode: (name: string) => void;
6
+ };
@@ -0,0 +1,23 @@
1
+ import { onMounted } from "vue";
2
+ import { useLocalStorage } from "@vueuse/core";
3
+ export function useTheme() {
4
+ const theme = useLocalStorage("orio-theme", "navy");
5
+ const mode = useLocalStorage("orio-mode", "dark");
6
+ function setTheme(name) {
7
+ theme.value = name;
8
+ if (typeof document !== "undefined") {
9
+ document.documentElement.setAttribute("data-theme", name);
10
+ }
11
+ }
12
+ function setMode(name) {
13
+ mode.value = name;
14
+ if (typeof document !== "undefined") {
15
+ document.documentElement.setAttribute("data-mode", name);
16
+ }
17
+ }
18
+ onMounted(() => {
19
+ setTheme(theme.value);
20
+ setMode(mode.value);
21
+ });
22
+ return { theme, setTheme, mode, setMode };
23
+ }
@@ -0,0 +1,20 @@
1
+ export { default as Button } from './components/Button.vue.js';
2
+ export { default as Input } from './components/Input.vue.js';
3
+ export { default as Textarea } from './components/Textarea.vue.js';
4
+ export { default as CheckBox } from './components/CheckBox.vue.js';
5
+ export { default as DatePicker } from './components/DatePicker.vue.js';
6
+ export { default as DateRangePicker } from './components/DateRangePicker.vue.js';
7
+ export { default as Selector } from './components/Selector.vue.js';
8
+ export { default as Tag } from './components/Tag.vue.js';
9
+ export { default as Icon } from './components/Icon.vue.js';
10
+ export { default as LoadingSpinner } from './components/LoadingSpinner.vue.js';
11
+ export { default as Modal } from './components/Modal.vue.js';
12
+ export { default as Popover } from './components/Popover.vue.js';
13
+ export { default as EmptyState } from './components/EmptyState.vue.js';
14
+ export { default as DashedContainer } from './components/DashedContainer.vue.js';
15
+ export { default as ControlElement } from './components/ControlElement.vue.js';
16
+ export { default as ViewText } from './components/view/Text.vue.js';
17
+ export { default as ViewDates } from './components/view/Dates.vue.js';
18
+ export { default as ViewSeparator } from './components/view/Separator.vue.js';
19
+ export * from './composables/index.js';
20
+ export { iconRegistry, type IconName } from './utils/icon-registry.js';
@@ -0,0 +1,20 @@
1
+ export { default as Button } from "./components/Button.vue";
2
+ export { default as Input } from "./components/Input.vue";
3
+ export { default as Textarea } from "./components/Textarea.vue";
4
+ export { default as CheckBox } from "./components/CheckBox.vue";
5
+ export { default as DatePicker } from "./components/DatePicker.vue";
6
+ export { default as DateRangePicker } from "./components/DateRangePicker.vue";
7
+ export { default as Selector } from "./components/Selector.vue";
8
+ export { default as Tag } from "./components/Tag.vue";
9
+ export { default as Icon } from "./components/Icon.vue";
10
+ export { default as LoadingSpinner } from "./components/LoadingSpinner.vue";
11
+ export { default as Modal } from "./components/Modal.vue";
12
+ export { default as Popover } from "./components/Popover.vue";
13
+ export { default as EmptyState } from "./components/EmptyState.vue";
14
+ export { default as DashedContainer } from "./components/DashedContainer.vue";
15
+ export { default as ControlElement } from "./components/ControlElement.vue";
16
+ export { default as ViewText } from "./components/view/Text.vue";
17
+ export { default as ViewDates } from "./components/view/Dates.vue";
18
+ export { default as ViewSeparator } from "./components/view/Separator.vue";
19
+ export * from "./composables/index.js";
20
+ export { iconRegistry } from "./utils/icon-registry.js";
@@ -0,0 +1,2 @@
1
+ export declare const iconRegistry: Record<string, string>;
2
+ export type IconName = keyof typeof iconRegistry;
@@ -1,41 +1,26 @@
1
- // Icon registry with bundled SVG icons
2
-
3
- export const iconRegistry: Record<string, string> = {
1
+ export const iconRegistry = {
4
2
  // Loading spinner (line-md:loading-loop)
5
- 'loading-loop': `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><circle cx="12" cy="2" r="0"><animate attributeName="r" begin="0" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(45 12 12)"><animate attributeName="r" begin="0.125s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(90 12 12)"><animate attributeName="r" begin="0.25s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(135 12 12)"><animate attributeName="r" begin="0.375s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(180 12 12)"><animate attributeName="r" begin="0.5s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(225 12 12)"><animate attributeName="r" begin="0.625s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(270 12 12)"><animate attributeName="r" begin="0.75s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(315 12 12)"><animate attributeName="r" begin="0.875s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle></svg>`,
6
-
3
+ "loading-loop": `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><circle cx="12" cy="2" r="0"><animate attributeName="r" begin="0" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(45 12 12)"><animate attributeName="r" begin="0.125s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(90 12 12)"><animate attributeName="r" begin="0.25s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(135 12 12)"><animate attributeName="r" begin="0.375s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(180 12 12)"><animate attributeName="r" begin="0.5s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(225 12 12)"><animate attributeName="r" begin="0.625s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(270 12 12)"><animate attributeName="r" begin="0.75s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle><circle cx="12" cy="2" r="0" transform="rotate(315 12 12)"><animate attributeName="r" begin="0.875s" calcMode="spline" dur="1s" keySplines="0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8;0.2 0.2 0.4 0.8" repeatCount="indefinite" values="0;2;0;0"/></circle></svg>`,
7
4
  // Chevron down (mdi-light:chevron-down)
8
- 'chevron-down': `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M7.41 8.59L12 13.17l4.59-4.58L18 10l-6 6l-6-6z"/></svg>`,
9
-
5
+ "chevron-down": `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M7.41 8.59L12 13.17l4.59-4.58L18 10l-6 6l-6-6z"/></svg>`,
10
6
  // Chevron up
11
- 'chevron-up': `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M7.41 15.41L12 10.83l4.59 4.58L18 14l-6-6l-6 6z"/></svg>`,
12
-
7
+ "chevron-up": `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M7.41 15.41L12 10.83l4.59 4.58L18 14l-6-6l-6 6z"/></svg>`,
13
8
  // Edit (material-symbols:edit-sharp)
14
9
  edit: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M3 21v-4.25L16.2 3.575q.3-.275.663-.425t.762-.15t.775.15t.65.45L20.425 5q.3.275.438.65T21 6.4q0 .4-.137.763t-.438.662L7.25 21zM17.6 7.8L19 6.4L17.6 5l-1.4 1.4z"/></svg>`,
15
-
16
10
  // Check / Checkmark
17
11
  check: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M9 16.17L4.83 12l-1.42 1.41L9 19L21 7l-1.41-1.41z"/></svg>`,
18
-
19
12
  // Plus / Add
20
13
  plus: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"/></svg>`,
21
-
22
14
  // Calendar
23
15
  calendar: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M19 4h-1V2h-2v2H8V2H6v2H5c-1.11 0-1.99.9-1.99 2L3 20a2 2 0 0 0 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2m0 16H5V10h14zm0-12H5V6h14zM7 12h5v5H7z"/></svg>`,
24
-
25
16
  // Close / X
26
17
  close: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M19 6.41L17.59 5L12 10.59L6.41 5L5 6.41L10.59 12L5 17.59L6.41 19L12 13.41L17.59 19L19 17.59L13.41 12z"/></svg>`,
27
-
28
18
  // Search / Magnifying glass
29
19
  search: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M15.5 14h-.79l-.28-.27A6.47 6.47 0 0 0 16 9.5A6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5S14 7.01 14 9.5S11.99 14 9.5 14"/></svg>`,
30
-
31
20
  // Upload
32
21
  upload: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M9 16h6v-6h4l-7-7l-7 7h4zm-4 2h14v2H5z"/></svg>`,
33
-
34
22
  // Download
35
23
  download: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M19 9h-4V3H9v6H5l7 7zM5 18v2h14v-2z"/></svg>`,
36
-
37
24
  // Delete / Trash
38
- delete: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zm2.46-7.12l1.41-1.41L12 12.59l2.12-2.12l1.41 1.41L13.41 14l2.12 2.12l-1.41 1.41L12 15.41l-2.12 2.12l-1.41-1.41L10.59 14zM15.5 4l-1-1h-5l-1 1H5v2h14V4z"/></svg>`,
25
+ delete: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zm2.46-7.12l1.41-1.41L12 12.59l2.12-2.12l1.41 1.41L13.41 14l2.12 2.12l-1.41 1.41L12 15.41l-2.12 2.12l-1.41-1.41L10.59 14zM15.5 4l-1-1h-5l-1 1H5v2h14V4z"/></svg>`
39
26
  };
40
-
41
- export type IconName = keyof typeof iconRegistry;
@@ -0,0 +1,7 @@
1
+ import type { NuxtModule } from '@nuxt/schema'
2
+
3
+ import type { default as Module } from './module.js'
4
+
5
+ export type ModuleOptions = typeof Module extends NuxtModule<infer O> ? Partial<O> : Record<string, any>
6
+
7
+ export { default } from './module.js'
@@ -0,0 +1,7 @@
1
+ import type { NuxtModule } from '@nuxt/schema'
2
+
3
+ import type { default as Module } from './module'
4
+
5
+ export type ModuleOptions = typeof Module extends NuxtModule<infer O> ? Partial<O> : Record<string, any>
6
+
7
+ export { default } from './module'
package/package.json CHANGED
@@ -1,30 +1,26 @@
1
1
  {
2
2
  "name": "orio-ui",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "Modern Nuxt component library with theme support",
5
5
  "type": "module",
6
- "main": "./src/runtime/index.ts",
7
- "types": "./src/runtime/index.ts",
6
+ "main": "./dist/module.mjs",
7
+ "types": "./dist/types.d.ts",
8
8
  "exports": {
9
9
  ".": {
10
- "types": "./src/runtime/index.ts",
11
- "import": "./src/runtime/index.ts"
10
+ "types": "./dist/types.d.ts",
11
+ "import": "./dist/module.mjs",
12
+ "require": "./dist/module.cjs"
12
13
  },
13
- "./composables": {
14
- "types": "./src/runtime/composables/index.ts",
15
- "import": "./src/runtime/composables/index.ts"
16
- },
17
- "./styles": "./src/runtime/assets/css/main.css",
18
- "./theme": "./src/runtime/assets/css/colors.css"
14
+ "./styles": "./dist/runtime/assets/css/main.css",
15
+ "./theme": "./dist/runtime/assets/css/colors.css"
19
16
  },
20
17
  "files": [
21
- "nuxt.config.ts",
22
- "src"
18
+ "dist"
23
19
  ],
24
20
  "scripts": {
25
21
  "dev": "vitepress dev docs",
26
- "build": "echo 'Build not needed for Nuxt layer'",
27
- "prepack": "echo 'Using source files directly'",
22
+ "build": "nuxt-module-build build",
23
+ "prepack": "npm run build",
28
24
  "test": "vitest",
29
25
  "test:unit": "vitest run",
30
26
  "test:watch": "vitest watch",