@myghf/ui 0.1.0 → 0.3.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.
Files changed (38) hide show
  1. package/README.md +241 -5
  2. package/dist/components/alert/Alert.vue.d.ts +46 -0
  3. package/dist/components/alert/Alert.vue.d.ts.map +1 -0
  4. package/dist/components/button/Button.vue.d.ts +4 -4
  5. package/dist/components/button/Button.vue.d.ts.map +1 -1
  6. package/dist/components/date-picker/DatePicker.vue.d.ts +24 -1
  7. package/dist/components/date-picker/DatePicker.vue.d.ts.map +1 -1
  8. package/dist/components/drawer/Drawer.vue.d.ts +54 -0
  9. package/dist/components/drawer/Drawer.vue.d.ts.map +1 -0
  10. package/dist/components/input-number/InputNumber.vue.d.ts +31 -0
  11. package/dist/components/input-number/InputNumber.vue.d.ts.map +1 -0
  12. package/dist/components/tag/Tag.vue.d.ts +4 -28
  13. package/dist/components/tag/Tag.vue.d.ts.map +1 -1
  14. package/dist/components/theme-toggle/ThemeToggle.vue.d.ts +10 -0
  15. package/dist/components/theme-toggle/ThemeToggle.vue.d.ts.map +1 -0
  16. package/dist/components/toast/Toast.vue.d.ts +12 -0
  17. package/dist/components/toast/Toast.vue.d.ts.map +1 -0
  18. package/dist/components/toast/Toaster.vue.d.ts +33 -0
  19. package/dist/components/toast/Toaster.vue.d.ts.map +1 -0
  20. package/dist/components/toast/useToast.d.ts +44 -0
  21. package/dist/components/toast/useToast.d.ts.map +1 -0
  22. package/dist/index.d.ts +17 -0
  23. package/dist/index.d.ts.map +1 -1
  24. package/dist/index.js +1286 -419
  25. package/dist/index.js.map +1 -1
  26. package/dist/lib/date.d.ts +7 -0
  27. package/dist/lib/date.d.ts.map +1 -1
  28. package/dist/lib/locale.d.ts +6 -0
  29. package/dist/lib/locale.d.ts.map +1 -0
  30. package/dist/lib/number.d.ts +16 -0
  31. package/dist/lib/number.d.ts.map +1 -0
  32. package/dist/lib/theme.d.ts +36 -0
  33. package/dist/lib/theme.d.ts.map +1 -0
  34. package/dist/lib/tones.d.ts +9 -0
  35. package/dist/lib/tones.d.ts.map +1 -0
  36. package/dist/tailwindPreset.js +71 -68
  37. package/dist/tokens.css +85 -72
  38. package/package.json +10 -2
@@ -7,4 +7,11 @@ export declare function clampTime(d: Date, time: string): Date;
7
7
  export declare function sortRange(a: Date, b: Date): [Date, Date];
8
8
  export declare function sortRange(a: Date | null, b: Date | null): [Date | null, Date | null];
9
9
  export declare function toISODate(d: Date): string;
10
+ export declare function buildHourOptions(hourFormat: '12' | '24'): number[];
11
+ export declare function buildMinuteOptions(minuteStep: number): number[];
12
+ export declare function to12Hour(hour24: number): {
13
+ hour: number;
14
+ meridiem: 'am' | 'pm';
15
+ };
16
+ export declare function from12Hour(hour: number, meridiem: 'am' | 'pm'): number;
10
17
  //# sourceMappingURL=date.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"date.d.ts","sourceRoot":"","sources":["../../src/lib/date.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAsC,KAAK,SAAS,EAAE,MAAM,yBAAyB,CAAA;AAE1G,wBAAgB,WAAW,CAAC,CAAC,EAAE,IAAI,GAAG,YAAY,CAEjD;AAED,wBAAgB,WAAW,CAAC,CAAC,EAAE,SAAS,GAAG,IAAI,CAG9C;AAED,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAG9C;AAED,wBAAgB,MAAM,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAI9C;AAED,wBAAgB,SAAS,CAAC,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI,CAIrD;AAED,wBAAgB,SAAS,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,GAAG,CAAC,IAAI,EAAE,IAAI,CAAC,CAAA;AACzD,wBAAgB,SAAS,CAAC,CAAC,EAAE,IAAI,GAAG,IAAI,EAAE,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,CAAC,IAAI,GAAG,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC,CAAA;AAMrF,wBAAgB,SAAS,CAAC,CAAC,EAAE,IAAI,GAAG,MAAM,CAIzC"}
1
+ {"version":3,"file":"date.d.ts","sourceRoot":"","sources":["../../src/lib/date.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAsC,KAAK,SAAS,EAAE,MAAM,yBAAyB,CAAA;AAE1G,wBAAgB,WAAW,CAAC,CAAC,EAAE,IAAI,GAAG,YAAY,CAEjD;AAED,wBAAgB,WAAW,CAAC,CAAC,EAAE,SAAS,GAAG,IAAI,CAG9C;AAED,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAG9C;AAED,wBAAgB,MAAM,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAI9C;AAED,wBAAgB,SAAS,CAAC,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI,CAIrD;AAED,wBAAgB,SAAS,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,GAAG,CAAC,IAAI,EAAE,IAAI,CAAC,CAAA;AACzD,wBAAgB,SAAS,CAAC,CAAC,EAAE,IAAI,GAAG,IAAI,EAAE,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,CAAC,IAAI,GAAG,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC,CAAA;AAMrF,wBAAgB,SAAS,CAAC,CAAC,EAAE,IAAI,GAAG,MAAM,CAIzC;AAED,wBAAgB,gBAAgB,CAAC,UAAU,EAAE,IAAI,GAAG,IAAI,GAAG,MAAM,EAAE,CAGlE;AAED,wBAAgB,kBAAkB,CAAC,UAAU,EAAE,MAAM,GAAG,MAAM,EAAE,CAK/D;AAED,wBAAgB,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,IAAI,GAAG,IAAI,CAAA;CAAE,CAKhF;AAED,wBAAgB,UAAU,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,GAAG,IAAI,GAAG,MAAM,CAGtE"}
@@ -0,0 +1,6 @@
1
+ export declare function getFirstDayOfWeek(locale: string): number;
2
+ export declare function getWeekdayLabels(locale: string, weekStartsOn: number): string[];
3
+ export declare function getMonthLabel(date: Date, locale: string): string;
4
+ export declare function formatLocalizedDate(date: Date, locale: string): string;
5
+ export declare function formatLocalizedTime(date: Date, locale: string, hourFormat: '12' | '24'): string;
6
+ //# sourceMappingURL=locale.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"locale.d.ts","sourceRoot":"","sources":["../../src/lib/locale.ts"],"names":[],"mappings":"AAAA,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAYxD;AAED,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,GAAG,MAAM,EAAE,CAO/E;AAED,wBAAgB,aAAa,CAAC,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,CAEhE;AAED,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,CAEtE;AAED,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,UAAU,EAAE,IAAI,GAAG,IAAI,GAAG,MAAM,CAM/F"}
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Normalise a numeric field value: empty and non-finite inputs collapse to
3
+ * `null`, while `0` and every other finite number pass through unchanged.
4
+ */
5
+ export declare function toNumberOrNull(value: number | null | undefined): number | null;
6
+ /**
7
+ * Compose the `Intl.NumberFormatOptions` for a number field. Later sources win,
8
+ * so explicit `formatOptions` override the `currency` shorthand and `integer`
9
+ * forces zero fraction digits regardless of what came before.
10
+ */
11
+ export declare function mergeFormatOptions(input: {
12
+ currency?: string;
13
+ formatOptions?: Intl.NumberFormatOptions;
14
+ integer?: boolean;
15
+ }): Intl.NumberFormatOptions;
16
+ //# sourceMappingURL=number.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"number.d.ts","sourceRoot":"","sources":["../../src/lib/number.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAAG,MAAM,GAAG,IAAI,CAG9E;AAED;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE;IACxC,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,aAAa,CAAC,EAAE,IAAI,CAAC,mBAAmB,CAAA;IACxC,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB,GAAG,IAAI,CAAC,mBAAmB,CAM3B"}
@@ -0,0 +1,36 @@
1
+ import { ComputedRef, Ref } from 'vue';
2
+ export type ThemeMode = 'light' | 'dark' | 'system';
3
+ export type ThemeAttribute = 'both' | 'class' | 'data-theme';
4
+ export interface UseThemeOptions {
5
+ /** localStorage key used to persist an explicit mode. Defaults to `'myghf-theme'`. */
6
+ storageKey?: string;
7
+ /** Which attribute(s) to write on `<html>`. Defaults to `'both'`. */
8
+ attribute?: ThemeAttribute;
9
+ /** Mode used when nothing is stored. Defaults to `'system'`. */
10
+ defaultMode?: ThemeMode;
11
+ }
12
+ export interface UseThemeReturn {
13
+ /** The user's chosen mode (`'system'` follows the OS). */
14
+ mode: Ref<ThemeMode>;
15
+ /** The effective mode after resolving `'system'` against the OS preference. */
16
+ resolved: ComputedRef<'light' | 'dark'>;
17
+ /** Convenience flag: `resolved === 'dark'`. */
18
+ isDark: ComputedRef<boolean>;
19
+ setMode(mode: ThemeMode): void;
20
+ toggle(): void;
21
+ enable(): void;
22
+ disable(): void;
23
+ reset(): void;
24
+ }
25
+ /**
26
+ * Builds an independent theme controller. Writes `.dark` and/or
27
+ * `data-theme="dark"` on `<html>` so the CSS dark token block activates.
28
+ * Safe to call during SSR: without a DOM it resolves to light and is a no-op.
29
+ */
30
+ export declare function createTheme(options?: UseThemeOptions): UseThemeReturn;
31
+ /**
32
+ * Returns a single shared theme controller, lazily created on first call.
33
+ * Later calls reuse it; in dev a mismatched options object logs a warning.
34
+ */
35
+ export declare function useTheme(options?: UseThemeOptions): UseThemeReturn;
36
+ //# sourceMappingURL=theme.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/lib/theme.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,GAAG,EAAE,MAAM,KAAK,CAAA;AAE3C,MAAM,MAAM,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,QAAQ,CAAA;AACnD,MAAM,MAAM,cAAc,GAAG,MAAM,GAAG,OAAO,GAAG,YAAY,CAAA;AAE5D,MAAM,WAAW,eAAe;IAC9B,sFAAsF;IACtF,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,qEAAqE;IACrE,SAAS,CAAC,EAAE,cAAc,CAAA;IAC1B,gEAAgE;IAChE,WAAW,CAAC,EAAE,SAAS,CAAA;CACxB;AAED,MAAM,WAAW,cAAc;IAC7B,0DAA0D;IAC1D,IAAI,EAAE,GAAG,CAAC,SAAS,CAAC,CAAA;IACpB,+EAA+E;IAC/E,QAAQ,EAAE,WAAW,CAAC,OAAO,GAAG,MAAM,CAAC,CAAA;IACvC,+CAA+C;IAC/C,MAAM,EAAE,WAAW,CAAC,OAAO,CAAC,CAAA;IAC5B,OAAO,CAAC,IAAI,EAAE,SAAS,GAAG,IAAI,CAAA;IAC9B,MAAM,IAAI,IAAI,CAAA;IACd,MAAM,IAAI,IAAI,CAAA;IACd,OAAO,IAAI,IAAI,CAAA;IACf,KAAK,IAAI,IAAI,CAAA;CACd;AA4CD;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,OAAO,GAAE,eAAoB,GAAG,cAAc,CA4EzE;AAKD;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,OAAO,CAAC,EAAE,eAAe,GAAG,cAAc,CAmBlE"}
@@ -0,0 +1,9 @@
1
+ export type Tone = 'info' | 'success' | 'warning' | 'danger' | 'secondary';
2
+ export interface ToneClasses {
3
+ soft: string;
4
+ outline: string;
5
+ icon: string;
6
+ role: 'alert' | 'status';
7
+ }
8
+ export declare const toneClasses: Record<Tone, ToneClasses>;
9
+ //# sourceMappingURL=tones.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tones.d.ts","sourceRoot":"","sources":["../../src/lib/tones.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,IAAI,GAAG,MAAM,GAAG,SAAS,GAAG,SAAS,GAAG,QAAQ,GAAG,WAAW,CAAA;AAE1E,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,EAAE,MAAM,CAAA;IACf,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,OAAO,GAAG,QAAQ,CAAA;CACzB;AAED,eAAO,MAAM,WAAW,EAAE,MAAM,CAAC,IAAI,EAAE,WAAW,CA+BjD,CAAA"}
@@ -1,90 +1,93 @@
1
1
  /** @type {import('tailwindcss').Config} */
2
2
  export default {
3
+ darkMode: ['class', '.dark'],
3
4
  theme: {
4
5
  extend: {
5
6
  fontFamily: {
6
- sans: ['DM Sans', 'system-ui', 'sans-serif'],
7
+ sans: ['Helvetica Neue', 'Helvetica', 'Arial', 'sans-serif'],
8
+ serif: ['Trajan Pro', 'Trajan', 'Times New Roman', 'serif'],
9
+ ar: ['GE SS Two', 'Adobe Arabic', 'Segoe UI', 'Tahoma', 'sans-serif'],
7
10
  },
8
11
  colors: {
9
12
  primary: {
10
- 50: 'rgb(var(--ahc-primary-50) / <alpha-value>)',
11
- 100: 'rgb(var(--ahc-primary-100) / <alpha-value>)',
12
- 200: 'rgb(var(--ahc-primary-200) / <alpha-value>)',
13
- 300: 'rgb(var(--ahc-primary-300) / <alpha-value>)',
14
- 400: 'rgb(var(--ahc-primary-400) / <alpha-value>)',
15
- 500: 'rgb(var(--ahc-primary-500) / <alpha-value>)',
16
- 600: 'rgb(var(--ahc-primary-600) / <alpha-value>)',
17
- 700: 'rgb(var(--ahc-primary-700) / <alpha-value>)',
18
- 800: 'rgb(var(--ahc-primary-800) / <alpha-value>)',
19
- 900: 'rgb(var(--ahc-primary-900) / <alpha-value>)',
13
+ 50: 'rgb(var(--myghf-primary-50) / <alpha-value>)',
14
+ 100: 'rgb(var(--myghf-primary-100) / <alpha-value>)',
15
+ 200: 'rgb(var(--myghf-primary-200) / <alpha-value>)',
16
+ 300: 'rgb(var(--myghf-primary-300) / <alpha-value>)',
17
+ 400: 'rgb(var(--myghf-primary-400) / <alpha-value>)',
18
+ 500: 'rgb(var(--myghf-primary-500) / <alpha-value>)',
19
+ 600: 'rgb(var(--myghf-primary-600) / <alpha-value>)',
20
+ 700: 'rgb(var(--myghf-primary-700) / <alpha-value>)',
21
+ 800: 'rgb(var(--myghf-primary-800) / <alpha-value>)',
22
+ 900: 'rgb(var(--myghf-primary-900) / <alpha-value>)',
20
23
  },
21
24
  secondary: {
22
- 50: 'rgb(var(--ahc-secondary-50) / <alpha-value>)',
23
- 100: 'rgb(var(--ahc-secondary-100) / <alpha-value>)',
24
- 200: 'rgb(var(--ahc-secondary-200) / <alpha-value>)',
25
- 300: 'rgb(var(--ahc-secondary-300) / <alpha-value>)',
26
- 400: 'rgb(var(--ahc-secondary-400) / <alpha-value>)',
27
- 500: 'rgb(var(--ahc-secondary-500) / <alpha-value>)',
28
- 600: 'rgb(var(--ahc-secondary-600) / <alpha-value>)',
29
- 700: 'rgb(var(--ahc-secondary-700) / <alpha-value>)',
30
- 800: 'rgb(var(--ahc-secondary-800) / <alpha-value>)',
31
- 900: 'rgb(var(--ahc-secondary-900) / <alpha-value>)',
25
+ 50: 'rgb(var(--myghf-secondary-50) / <alpha-value>)',
26
+ 100: 'rgb(var(--myghf-secondary-100) / <alpha-value>)',
27
+ 200: 'rgb(var(--myghf-secondary-200) / <alpha-value>)',
28
+ 300: 'rgb(var(--myghf-secondary-300) / <alpha-value>)',
29
+ 400: 'rgb(var(--myghf-secondary-400) / <alpha-value>)',
30
+ 500: 'rgb(var(--myghf-secondary-500) / <alpha-value>)',
31
+ 600: 'rgb(var(--myghf-secondary-600) / <alpha-value>)',
32
+ 700: 'rgb(var(--myghf-secondary-700) / <alpha-value>)',
33
+ 800: 'rgb(var(--myghf-secondary-800) / <alpha-value>)',
34
+ 900: 'rgb(var(--myghf-secondary-900) / <alpha-value>)',
32
35
  },
33
36
  success: {
34
- 50: 'rgb(var(--ahc-success-50) / <alpha-value>)',
35
- 100: 'rgb(var(--ahc-success-100) / <alpha-value>)',
36
- 200: 'rgb(var(--ahc-success-200) / <alpha-value>)',
37
- 300: 'rgb(var(--ahc-success-300) / <alpha-value>)',
38
- 400: 'rgb(var(--ahc-success-400) / <alpha-value>)',
39
- 500: 'rgb(var(--ahc-success-500) / <alpha-value>)',
40
- 600: 'rgb(var(--ahc-success-600) / <alpha-value>)',
41
- 700: 'rgb(var(--ahc-success-700) / <alpha-value>)',
42
- 800: 'rgb(var(--ahc-success-800) / <alpha-value>)',
43
- 900: 'rgb(var(--ahc-success-900) / <alpha-value>)',
37
+ 50: 'rgb(var(--myghf-success-50) / <alpha-value>)',
38
+ 100: 'rgb(var(--myghf-success-100) / <alpha-value>)',
39
+ 200: 'rgb(var(--myghf-success-200) / <alpha-value>)',
40
+ 300: 'rgb(var(--myghf-success-300) / <alpha-value>)',
41
+ 400: 'rgb(var(--myghf-success-400) / <alpha-value>)',
42
+ 500: 'rgb(var(--myghf-success-500) / <alpha-value>)',
43
+ 600: 'rgb(var(--myghf-success-600) / <alpha-value>)',
44
+ 700: 'rgb(var(--myghf-success-700) / <alpha-value>)',
45
+ 800: 'rgb(var(--myghf-success-800) / <alpha-value>)',
46
+ 900: 'rgb(var(--myghf-success-900) / <alpha-value>)',
44
47
  },
45
48
  warning: {
46
- 50: 'rgb(var(--ahc-warning-50) / <alpha-value>)',
47
- 100: 'rgb(var(--ahc-warning-100) / <alpha-value>)',
48
- 200: 'rgb(var(--ahc-warning-200) / <alpha-value>)',
49
- 300: 'rgb(var(--ahc-warning-300) / <alpha-value>)',
50
- 400: 'rgb(var(--ahc-warning-400) / <alpha-value>)',
51
- 500: 'rgb(var(--ahc-warning-500) / <alpha-value>)',
52
- 600: 'rgb(var(--ahc-warning-600) / <alpha-value>)',
53
- 700: 'rgb(var(--ahc-warning-700) / <alpha-value>)',
54
- 800: 'rgb(var(--ahc-warning-800) / <alpha-value>)',
55
- 900: 'rgb(var(--ahc-warning-900) / <alpha-value>)',
49
+ 50: 'rgb(var(--myghf-warning-50) / <alpha-value>)',
50
+ 100: 'rgb(var(--myghf-warning-100) / <alpha-value>)',
51
+ 200: 'rgb(var(--myghf-warning-200) / <alpha-value>)',
52
+ 300: 'rgb(var(--myghf-warning-300) / <alpha-value>)',
53
+ 400: 'rgb(var(--myghf-warning-400) / <alpha-value>)',
54
+ 500: 'rgb(var(--myghf-warning-500) / <alpha-value>)',
55
+ 600: 'rgb(var(--myghf-warning-600) / <alpha-value>)',
56
+ 700: 'rgb(var(--myghf-warning-700) / <alpha-value>)',
57
+ 800: 'rgb(var(--myghf-warning-800) / <alpha-value>)',
58
+ 900: 'rgb(var(--myghf-warning-900) / <alpha-value>)',
56
59
  },
57
60
  error: {
58
- 50: 'rgb(var(--ahc-error-50) / <alpha-value>)',
59
- 100: 'rgb(var(--ahc-error-100) / <alpha-value>)',
60
- 200: 'rgb(var(--ahc-error-200) / <alpha-value>)',
61
- 300: 'rgb(var(--ahc-error-300) / <alpha-value>)',
62
- 400: 'rgb(var(--ahc-error-400) / <alpha-value>)',
63
- 500: 'rgb(var(--ahc-error-500) / <alpha-value>)',
64
- 600: 'rgb(var(--ahc-error-600) / <alpha-value>)',
65
- 700: 'rgb(var(--ahc-error-700) / <alpha-value>)',
66
- 800: 'rgb(var(--ahc-error-800) / <alpha-value>)',
67
- 900: 'rgb(var(--ahc-error-900) / <alpha-value>)',
61
+ 50: 'rgb(var(--myghf-error-50) / <alpha-value>)',
62
+ 100: 'rgb(var(--myghf-error-100) / <alpha-value>)',
63
+ 200: 'rgb(var(--myghf-error-200) / <alpha-value>)',
64
+ 300: 'rgb(var(--myghf-error-300) / <alpha-value>)',
65
+ 400: 'rgb(var(--myghf-error-400) / <alpha-value>)',
66
+ 500: 'rgb(var(--myghf-error-500) / <alpha-value>)',
67
+ 600: 'rgb(var(--myghf-error-600) / <alpha-value>)',
68
+ 700: 'rgb(var(--myghf-error-700) / <alpha-value>)',
69
+ 800: 'rgb(var(--myghf-error-800) / <alpha-value>)',
70
+ 900: 'rgb(var(--myghf-error-900) / <alpha-value>)',
68
71
  },
69
72
  info: {
70
- 50: 'rgb(var(--ahc-info-50) / <alpha-value>)',
71
- 100: 'rgb(var(--ahc-info-100) / <alpha-value>)',
72
- 200: 'rgb(var(--ahc-info-200) / <alpha-value>)',
73
- 300: 'rgb(var(--ahc-info-300) / <alpha-value>)',
74
- 400: 'rgb(var(--ahc-info-400) / <alpha-value>)',
75
- 500: 'rgb(var(--ahc-info-500) / <alpha-value>)',
76
- 600: 'rgb(var(--ahc-info-600) / <alpha-value>)',
77
- 700: 'rgb(var(--ahc-info-700) / <alpha-value>)',
78
- 800: 'rgb(var(--ahc-info-800) / <alpha-value>)',
79
- 900: 'rgb(var(--ahc-info-900) / <alpha-value>)',
73
+ 50: 'rgb(var(--myghf-info-50) / <alpha-value>)',
74
+ 100: 'rgb(var(--myghf-info-100) / <alpha-value>)',
75
+ 200: 'rgb(var(--myghf-info-200) / <alpha-value>)',
76
+ 300: 'rgb(var(--myghf-info-300) / <alpha-value>)',
77
+ 400: 'rgb(var(--myghf-info-400) / <alpha-value>)',
78
+ 500: 'rgb(var(--myghf-info-500) / <alpha-value>)',
79
+ 600: 'rgb(var(--myghf-info-600) / <alpha-value>)',
80
+ 700: 'rgb(var(--myghf-info-700) / <alpha-value>)',
81
+ 800: 'rgb(var(--myghf-info-800) / <alpha-value>)',
82
+ 900: 'rgb(var(--myghf-info-900) / <alpha-value>)',
80
83
  },
81
- background: 'rgb(var(--ahc-background) / <alpha-value>)',
82
- foreground: 'rgb(var(--ahc-foreground) / <alpha-value>)',
83
- surface: 'rgb(var(--ahc-surface) / <alpha-value>)',
84
- 'surface-muted': 'rgb(var(--ahc-surface-muted) / <alpha-value>)',
85
- border: 'rgb(var(--ahc-border) / <alpha-value>)',
86
- muted: 'rgb(var(--ahc-muted) / <alpha-value>)',
87
- grey: 'rgb(var(--ahc-muted) / <alpha-value>)',
84
+ background: 'rgb(var(--myghf-background) / <alpha-value>)',
85
+ foreground: 'rgb(var(--myghf-foreground) / <alpha-value>)',
86
+ surface: 'rgb(var(--myghf-surface) / <alpha-value>)',
87
+ 'surface-muted': 'rgb(var(--myghf-surface-muted) / <alpha-value>)',
88
+ border: 'rgb(var(--myghf-border) / <alpha-value>)',
89
+ muted: 'rgb(var(--myghf-muted) / <alpha-value>)',
90
+ grey: 'rgb(var(--myghf-muted) / <alpha-value>)',
88
91
  },
89
92
  boxShadow: {
90
93
  popover: '0 4px 12px -2px rgb(0 0 0 / 0.08), 0 2px 4px -2px rgb(0 0 0 / 0.06)',
package/dist/tokens.css CHANGED
@@ -1,81 +1,94 @@
1
1
  :root {
2
2
  /* surfaces */
3
- --ahc-background: 248 249 250; /* #f8f9fa */
4
- --ahc-foreground: 15 23 42;
5
- --ahc-surface: 255 255 255;
6
- --ahc-surface-muted: 243 244 246;
7
- --ahc-border: 229 231 235;
8
- --ahc-muted: 156 163 175; /* #9ca3af (also the "grey" alias) */
3
+ --myghf-background: 248 249 250; /* #f8f9fa (deviation: brand says white; kept for surface separation) */
4
+ --myghf-foreground: 0 0 0; /* #000000 MYGHF Black */
5
+ --myghf-surface: 255 255 255; /* #ffffff MYGHF White */
6
+ --myghf-surface-muted: 243 244 246; /* #f3f4f6 */
7
+ --myghf-border: 230 230 230; /* #e6e6e6 brand light gray */
8
+ --myghf-muted: 128 128 128; /* #808080 brand secondary text */
9
9
 
10
- /* brand: primary (blue) */
11
- --ahc-primary-50: 240 249 253;
12
- --ahc-primary-100: 217 241 250;
13
- --ahc-primary-200: 173 225 244;
14
- --ahc-primary-300: 115 204 236;
15
- --ahc-primary-400: 56 182 228;
16
- --ahc-primary-500: 0 162 221;
17
- --ahc-primary-600: 0 130 177;
18
- --ahc-primary-700: 0 100 137;
19
- --ahc-primary-800: 0 73 99;
20
- --ahc-primary-900: 0 49 66;
10
+ /* brand: primary (blue) — MYGHF Blue #00A2DD */
11
+ --myghf-primary-50: 240 249 253;
12
+ --myghf-primary-100: 217 241 250;
13
+ --myghf-primary-200: 173 225 244;
14
+ --myghf-primary-300: 115 204 236;
15
+ --myghf-primary-400: 56 182 228;
16
+ --myghf-primary-500: 0 162 221;
17
+ --myghf-primary-600: 0 130 177;
18
+ --myghf-primary-700: 0 100 137;
19
+ --myghf-primary-800: 0 73 99;
20
+ --myghf-primary-900: 0 49 66;
21
21
 
22
- /* brand: secondary (plum) */
23
- --ahc-secondary-50: 249 244 247;
24
- --ahc-secondary-100: 240 228 235;
25
- --ahc-secondary-200: 222 198 213;
26
- --ahc-secondary-300: 198 157 183;
27
- --ahc-secondary-400: 175 115 153;
28
- --ahc-secondary-500: 152 76 124;
29
- --ahc-secondary-600: 122 61 99;
30
- --ahc-secondary-700: 94 47 77;
31
- --ahc-secondary-800: 68 34 56;
32
- --ahc-secondary-900: 46 23 37;
22
+ /* brand: secondary (plum) — MYGHF Plum #984C7C */
23
+ --myghf-secondary-50: 249 244 247;
24
+ --myghf-secondary-100: 240 228 235;
25
+ --myghf-secondary-200: 222 198 213;
26
+ --myghf-secondary-300: 198 157 183;
27
+ --myghf-secondary-400: 175 115 153;
28
+ --myghf-secondary-500: 152 76 124;
29
+ --myghf-secondary-600: 122 61 99;
30
+ --myghf-secondary-700: 94 47 77;
31
+ --myghf-secondary-800: 68 34 56;
32
+ --myghf-secondary-900: 46 23 37;
33
33
 
34
- /* feedback: success (teal) */
35
- --ahc-success-50: 240 250 249;
36
- --ahc-success-100: 219 242 240;
37
- --ahc-success-200: 178 227 224;
38
- --ahc-success-300: 122 207 201;
39
- --ahc-success-400: 66 186 179;
40
- --ahc-success-500: 13 167 157;
41
- --ahc-success-600: 10 134 126;
42
- --ahc-success-700: 8 104 97;
43
- --ahc-success-800: 6 75 71;
44
- --ahc-success-900: 4 50 47;
34
+ /* feedback: success (teal) — MYGHF Teal #0DA79E */
35
+ --myghf-success-50: 243 251 250;
36
+ --myghf-success-100: 231 246 245;
37
+ --myghf-success-200: 202 236 234;
38
+ --myghf-success-300: 158 220 216;
39
+ --myghf-success-400: 90 195 189;
40
+ --myghf-success-500: 13 167 158;
41
+ --myghf-success-600: 11 147 139;
42
+ --myghf-success-700: 9 120 114;
43
+ --myghf-success-800: 7 94 88;
44
+ --myghf-success-900: 5 70 66;
45
45
 
46
- /* feedback: warning (amber) */
47
- --ahc-warning-50: 254 250 242;
48
- --ahc-warning-100: 252 242 223;
49
- --ahc-warning-200: 249 227 186;
50
- --ahc-warning-300: 245 207 136;
51
- --ahc-warning-400: 241 187 87;
52
- --ahc-warning-500: 237 168 39;
53
- --ahc-warning-600: 190 134 31;
54
- --ahc-warning-700: 147 104 24;
55
- --ahc-warning-800: 107 76 18;
56
- --ahc-warning-900: 71 50 12;
46
+ /* feedback: warning (amber) — MYGHF Gold #EDA827 */
47
+ --myghf-warning-50: 254 250 242;
48
+ --myghf-warning-100: 252 242 223;
49
+ --myghf-warning-200: 249 227 186;
50
+ --myghf-warning-300: 245 207 136;
51
+ --myghf-warning-400: 241 187 87;
52
+ --myghf-warning-500: 237 168 39;
53
+ --myghf-warning-600: 190 134 31;
54
+ --myghf-warning-700: 147 104 24;
55
+ --myghf-warning-800: 107 76 18;
56
+ --myghf-warning-900: 71 50 12;
57
57
 
58
- /* feedback: error (pink; maps to PrimeVue "danger") */
59
- --ahc-error-50: 254 240 245;
60
- --ahc-error-100: 254 217 230;
61
- --ahc-error-200: 252 173 201;
62
- --ahc-error-300: 250 115 163;
63
- --ahc-error-400: 247 56 124;
64
- --ahc-error-500: 245 0 87;
65
- --ahc-error-600: 196 0 70;
66
- --ahc-error-700: 152 0 54;
67
- --ahc-error-800: 110 0 39;
68
- --ahc-error-900: 74 0 26;
58
+ /* feedback: error (red) — MYGHF Red #E9322B */
59
+ --myghf-error-50: 254 245 244;
60
+ --myghf-error-100: 253 235 234;
61
+ --myghf-error-200: 250 210 208;
62
+ --myghf-error-300: 246 173 170;
63
+ --myghf-error-400: 240 116 111;
64
+ --myghf-error-500: 233 50 43;
65
+ --myghf-error-600: 205 44 38;
66
+ --myghf-error-700: 168 36 31;
67
+ --myghf-error-800: 130 28 24;
68
+ --myghf-error-900: 98 21 18;
69
69
 
70
70
  /* feedback: info (same range as primary, kept separate for semantics) */
71
- --ahc-info-50: 240 249 253;
72
- --ahc-info-100: 217 241 250;
73
- --ahc-info-200: 173 225 244;
74
- --ahc-info-300: 115 204 236;
75
- --ahc-info-400: 56 182 228;
76
- --ahc-info-500: 0 162 221;
77
- --ahc-info-600: 0 130 177;
78
- --ahc-info-700: 0 100 137;
79
- --ahc-info-800: 0 73 99;
80
- --ahc-info-900: 0 49 66;
81
- }
71
+ --myghf-info-50: 240 249 253;
72
+ --myghf-info-100: 217 241 250;
73
+ --myghf-info-200: 173 225 244;
74
+ --myghf-info-300: 115 204 236;
75
+ --myghf-info-400: 56 182 228;
76
+ --myghf-info-500: 0 162 221;
77
+ --myghf-info-600: 0 130 177;
78
+ --myghf-info-700: 0 100 137;
79
+ --myghf-info-800: 0 73 99;
80
+ --myghf-info-900: 0 49 66;
81
+ }
82
+
83
+ [data-theme='dark'],
84
+ .dark {
85
+ color-scheme: dark;
86
+
87
+ /* surfaces */
88
+ --myghf-background: 15 18 23;
89
+ --myghf-foreground: 243 244 246;
90
+ --myghf-surface: 26 30 37;
91
+ --myghf-surface-muted: 39 44 53;
92
+ --myghf-border: 55 61 71;
93
+ --myghf-muted: 156 163 175;
94
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@myghf/ui",
3
- "version": "0.1.0",
3
+ "version": "0.3.0",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -35,6 +35,10 @@
35
35
  "build": "vite build && cp src/tokens.css src/tailwindPreset.js dist/",
36
36
  "typecheck": "vue-tsc --noEmit",
37
37
  "test": "vitest run",
38
+ "changeset": "changeset",
39
+ "docs:dev": "vitepress dev docs",
40
+ "docs:build": "vitepress build docs",
41
+ "docs:preview": "vitepress preview docs",
38
42
  "prepublishOnly": "npm run build"
39
43
  },
40
44
  "dependencies": {
@@ -51,17 +55,21 @@
51
55
  "vue": "^3.5.0"
52
56
  },
53
57
  "devDependencies": {
58
+ "@changesets/cli": "^3.0.3",
54
59
  "@types/node": "^24.0.0",
55
60
  "@vitejs/plugin-vue": "^6.0.7",
56
61
  "@vue/test-utils": "^2.5.1",
57
62
  "@vue/tsconfig": "^0.9.1",
63
+ "autoprefixer": "^10.6.1",
58
64
  "jsdom": "^30.1.1",
65
+ "postcss": "^8.5.28",
59
66
  "tailwindcss": "^3.4.19",
60
67
  "typescript": "~6.0.2",
61
68
  "vite": "^8.3.1",
62
69
  "vite-plugin-dts": "^4.5.4",
70
+ "vitepress": "^1.6.4",
63
71
  "vitest": "^4.1.10",
64
72
  "vue": "^3.5.39",
65
73
  "vue-tsc": "^3.3.5"
66
74
  }
67
- }
75
+ }