@rimelight/ui 0.0.28 → 0.0.29

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/package.json +14 -13
  2. package/src/components/astro/RLAAccordion.astro +2 -6
  3. package/src/components/astro/RLAButton.astro +2 -22
  4. package/src/components/astro/RLAEmbedYoutube.astro +4 -26
  5. package/src/components/astro/RLAFooter.astro +2 -10
  6. package/src/components/astro/RLAHeader.astro +2 -14
  7. package/src/components/astro/RLAIcon.astro +2 -11
  8. package/src/components/astro/RLALogo.astro +2 -12
  9. package/src/components/astro/RLAPlaceholder.astro +2 -8
  10. package/src/components/astro/RLAScrollToTop.astro +2 -14
  11. package/src/components/astro/RLASection.astro +24 -72
  12. package/src/components/vue/RLVButton.vue +2 -64
  13. package/src/components/vue/RLVFooter.vue +2 -9
  14. package/src/components/vue/RLVHeader.vue +2 -13
  15. package/src/components/vue/RLVIcon.vue +2 -10
  16. package/src/components/vue/RLVLogo.vue +13 -21
  17. package/src/components/vue/RLVPlaceholder.vue +2 -8
  18. package/src/components/vue/RLVScrollToTop.vue +2 -13
  19. package/src/components/vue/RLVSection.vue +2 -19
  20. package/src/integrations/ui.ts +11 -1
  21. package/src/presets/index.ts +16 -6
  22. package/src/themes/button.theme.ts +176 -167
  23. package/src/themes/embedYoutube.theme.ts +14 -19
  24. package/src/types/components/accordion.ts +15 -0
  25. package/src/types/components/button.ts +71 -0
  26. package/src/types/components/embed-youtube.ts +27 -0
  27. package/src/types/components/footer.ts +15 -0
  28. package/src/types/components/header.ts +31 -0
  29. package/src/types/components/icon.ts +19 -0
  30. package/src/types/components/index.ts +12 -0
  31. package/src/types/components/link.ts +23 -0
  32. package/src/types/components/logo.ts +27 -0
  33. package/src/types/components/navigation.ts +34 -0
  34. package/src/types/components/placeholder.ts +11 -0
  35. package/src/types/components/scroll-to-top.ts +31 -0
  36. package/src/types/components/section.ts +63 -0
  37. package/src/types/index.ts +1 -0
  38. package/src/nuxt-types.ts +0 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rimelight/ui",
3
- "version": "0.0.28",
3
+ "version": "0.0.29",
4
4
  "private": false,
5
5
  "description": "Rimelight Entertainment UI Library.",
6
6
  "keywords": [
@@ -48,7 +48,8 @@
48
48
  "./middleware": "./src/middleware/index.ts",
49
49
  "./middleware/*": "./src/middleware/*",
50
50
  "./nuxt": "./src/nuxt.ts",
51
- "./nuxt/types": "./src/nuxt-types.ts",
51
+ "./types": "./src/types/index.ts",
52
+ "./types/*": "./src/types/*",
52
53
  "./presets": "./src/presets/index.ts",
53
54
  "./presets/*": "./src/presets/*",
54
55
  "./*": "./src/*"
@@ -63,14 +64,14 @@
63
64
  "docs:meta": "tsx scripts/extract-meta.ts"
64
65
  },
65
66
  "dependencies": {
66
- "@astrojs/prism": "^4.0.1",
67
+ "@astrojs/prism": "^4.0.2",
67
68
  "@astrojs/vue": "6.0.1",
68
- "@iconify-json/lucide": "^1.2.102",
69
- "@nuxt/ui": "4.6.1",
70
- "@tailwindcss/vite": "^4.2.3",
69
+ "@iconify-json/lucide": "^1.2.108",
70
+ "@nuxt/ui": "4.7.1",
71
+ "@tailwindcss/vite": "^4.3.0",
71
72
  "@unocss/astro": "^66.6.8",
72
73
  "css-variants": "2.3.5",
73
- "defu": "6.1.6",
74
+ "defu": "6.1.7",
74
75
  "embla-carousel": "8.6.0",
75
76
  "picomatch": "^4.0.4",
76
77
  "tailwindcss": "^4.2.3",
@@ -80,18 +81,18 @@
80
81
  },
81
82
  "devDependencies": {
82
83
  "@astrojs/check": "0.9.8",
83
- "@astrojs/ts-plugin": "1.10.7",
84
+ "@astrojs/ts-plugin": "1.10.8",
84
85
  "@e18e/eslint-plugin": "0.3.0",
85
- "@types/node": "25.5.2",
86
+ "@types/node": "25.8.0",
86
87
  "@types/picomatch": "^4.0.3",
87
88
  "@unocss/eslint-plugin": "66.6.8",
88
- "astro": "6.1.8",
89
+ "astro": "6.3.6",
89
90
  "eslint-plugin-regexp": "3.1.0",
90
- "knip": "6.12.2",
91
- "tsx": "4.21.0",
91
+ "knip": "6.14.1",
92
+ "tsx": "4.22.1",
92
93
  "typescript": "6.0.3",
93
94
  "unocss": "66.6.8",
94
- "vite-plus": "0.1.19"
95
+ "vite-plus": "0.1.21"
95
96
  },
96
97
  "peerDependencies": {
97
98
  "@astrojs/starlight": ">=0.5.0",
@@ -1,11 +1,7 @@
1
1
  ---
2
- import type { HTMLAttributes } from 'astro/types';
2
+ import type { AccordionProps } from "../../types";
3
3
 
4
- export type Props = HTMLAttributes<'details'> & {
5
- summary: string;
6
- };
7
-
8
- const { summary, class: className, ...attrs } = Astro.props;
4
+ const { summary, class: className, ...attrs } = Astro.props as AccordionProps;
9
5
  ---
10
6
 
11
7
  <details class:list={['group', className]} {...attrs}>
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  import { scv, cx } from "css-variants"
3
3
  import { useUi, resolveClasses } from "../../utils"
4
- import type { ComponentVariants, ComponentSlots } from "../../types"
4
+ import type { ButtonProps } from "../../types"
5
5
  import buttonThemeDefault, { createButtonTheme } from "../../themes/button.theme"
6
6
  import { getUIConfig } from "virtual:rimelight-ui"
7
7
 
@@ -9,26 +9,6 @@ const uiConfig = getUIConfig()
9
9
  const buttonTheme = uiConfig.colors ? createButtonTheme(uiConfig.colors) : buttonThemeDefault
10
10
 
11
11
  const button = scv(buttonTheme)
12
- type ButtonVariants = ComponentVariants<typeof buttonThemeDefault>
13
-
14
- export interface RLAButtonProps {
15
- variant?: ButtonVariants['variant'];
16
- color?: ButtonVariants['color'];
17
- size?: ButtonVariants['size'];
18
- href?: string;
19
- label?: string;
20
- leadingIcon?: string;
21
- trailingIcon?: string;
22
- loading?: boolean;
23
- square?: boolean;
24
- block?: boolean;
25
- active?: boolean;
26
- activeColor?: ButtonVariants['color'];
27
- activeVariant?: ButtonVariants['variant'];
28
- ui?: ComponentSlots<typeof buttonTheme>;
29
- class?: any;
30
- [key: string]: unknown;
31
- }
32
12
 
33
13
  const {
34
14
  variant = "solid",
@@ -47,7 +27,7 @@ const {
47
27
  ui: uiProp,
48
28
  class: className,
49
29
  ...rest
50
- } = Astro.props as RLAButtonProps
30
+ } = Astro.props as ButtonProps
51
31
 
52
32
  const isLeading = !!(leadingIcon || Astro.slots.has("leading")) || loading
53
33
  const isTrailing = !!(trailingIcon || Astro.slots.has("trailing")) || (loading && !isLeading)
@@ -1,9 +1,8 @@
1
1
  ---
2
2
  import { scv } from "css-variants"
3
3
  import { useUi, resolveClasses } from "../../utils"
4
- import type { ComponentVariants, ComponentSlots } from "../../types"
4
+ import type { EmbedYoutubeProps } from "../../types"
5
5
  import embedYoutubeTheme from "../../themes/embedYoutube.theme"
6
- import type { RLAIconProps } from "./RLAIcon.astro"
7
6
  import { Image } from "astro:assets"
8
7
 
9
8
  const PLACEHOLDER_THUMBNAIL = "/assets/placeholder.webp";
@@ -111,27 +110,6 @@ function getYoutubeEmbedUrl(rawUrl: string): string | null {
111
110
  }
112
111
 
113
112
  const embedYoutube = scv(embedYoutubeTheme)
114
- type EmbedYoutubeVariants = ComponentVariants<typeof embedYoutubeTheme>
115
-
116
- export interface RLAEmbedYoutubeProps {
117
- /**
118
- * The URL of the YouTube video to embed.
119
- */
120
- src: string;
121
- /**
122
- * The title of the video to display.
123
- * @default "YouTube Video Player"
124
- */
125
- title?: string;
126
- /**
127
- * The name of the icon to display in the play trigger overlay.
128
- * @default "i-lucide-play"
129
- */
130
- icon?: RLAIconProps["name"];
131
- ui?: ComponentSlots<typeof embedYoutubeTheme>;
132
- class?: any;
133
- [key: string]: unknown;
134
- }
135
113
 
136
114
  const {
137
115
  src,
@@ -140,11 +118,11 @@ const {
140
118
  ui: uiProp,
141
119
  class: className,
142
120
  ...rest
143
- } = Astro.props as RLAEmbedYoutubeProps;
121
+ } = Astro.props as EmbedYoutubeProps
144
122
 
145
123
  const classes = resolveClasses(embedYoutube, {
146
- title: !!(Astro.slots.has("title") || Astro.props.title),
147
- icon: !!(Astro.slots.has("icon") || Astro.props.icon),
124
+ title: !!(Astro.slots.has("title") || title),
125
+ icon: !!(Astro.slots.has("icon") || icon),
148
126
  }, useUi("embedYoutube", uiProp), className);
149
127
 
150
128
  const embedUrl = getYoutubeEmbedUrl(src);
@@ -1,25 +1,17 @@
1
1
  ---
2
2
  import { scv } from "css-variants"
3
3
  import { useUi, resolveClasses } from "../../utils"
4
- import type { ComponentVariants, ComponentSlots } from "../../types"
4
+ import type { FooterProps } from "../../types"
5
5
  import footerTheme from "../../themes/footer.theme"
6
6
 
7
7
  const footer = scv(footerTheme)
8
- type FooterVariants = ComponentVariants<typeof footerTheme>
9
-
10
- export interface RLAFooterProps {
11
- contain?: FooterVariants['contain'];
12
- ui?: ComponentSlots<typeof footerTheme>;
13
- class?: any;
14
- [key: string]: unknown;
15
- }
16
8
 
17
9
  const {
18
10
  contain = false,
19
11
  ui: uiProp,
20
12
  class: className,
21
13
  ...rest
22
- } = Astro.props as RLAFooterProps
14
+ } = Astro.props as FooterProps
23
15
 
24
16
  const classes = resolveClasses(footer, { contain }, useUi("footer", uiProp), className)
25
17
  ---
@@ -1,22 +1,10 @@
1
1
  ---
2
2
  import { scv } from "css-variants"
3
3
  import { useUi, resolveClasses } from "../../utils"
4
- import type { ComponentVariants, ComponentSlots } from "../../types"
4
+ import type { HeaderProps } from "../../types"
5
5
  import headerTheme from "../../themes/header.theme"
6
6
 
7
7
  const header = scv(headerTheme)
8
- type HeaderVariants = ComponentVariants<typeof headerTheme>
9
-
10
- export interface RLAHeaderProps {
11
- contain?: HeaderVariants['contain'];
12
- sticky?: HeaderVariants['sticky'];
13
- fixed?: HeaderVariants['fixed'];
14
- stackIndex?: number;
15
- hideOnScroll?: boolean;
16
- ui?: ComponentSlots<typeof headerTheme>;
17
- class?: any;
18
- [key: string]: unknown;
19
- }
20
8
 
21
9
  const {
22
10
  contain = true,
@@ -27,7 +15,7 @@ const {
27
15
  ui: uiProp,
28
16
  class: className,
29
17
  ...rest
30
- } = Astro.props as RLAHeaderProps;
18
+ } = Astro.props as HeaderProps;
31
19
 
32
20
  const classes = resolveClasses(header, {
33
21
  contain,
@@ -1,19 +1,10 @@
1
1
  ---
2
2
  import { scv } from "css-variants"
3
3
  import { useUi, resolveClasses } from "../../utils"
4
- import type { ComponentVariants, ComponentSlots } from "../../types"
4
+ import type { IconProps } from "../../types"
5
5
  import iconTheme from "../../themes/icon.theme"
6
6
 
7
7
  const icon = scv(iconTheme)
8
- type IconVariants = ComponentVariants<typeof iconTheme>
9
-
10
- export interface RLAIconProps {
11
- name: string
12
- size?: IconVariants['size']
13
- ui?: ComponentSlots<typeof iconTheme>
14
- class?: any
15
- [key: string]: unknown
16
- }
17
8
 
18
9
  const {
19
10
  name,
@@ -21,7 +12,7 @@ const {
21
12
  ui: uiProp,
22
13
  class: className,
23
14
  ...rest
24
- } = Astro.props as RLAIconProps
15
+ } = Astro.props as IconProps
25
16
 
26
17
  const classes = resolveClasses(icon, { size }, useUi("icon", uiProp), className)
27
18
  ---
@@ -1,22 +1,12 @@
1
1
  ---
2
2
  import { scv } from "css-variants"
3
3
  import { useUi, resolveClasses } from "../../utils"
4
- import type { ComponentSlots } from "../../types"
4
+ import type { LogoProps } from "../../types"
5
5
  import logoTheme from "../../themes/logo.theme"
6
6
  import { getUIConfig } from "virtual:rimelight-ui"
7
7
 
8
8
  const logo = scv(logoTheme)
9
9
 
10
- export interface RLALogoProps {
11
- variant?: string;
12
- mode?: "color" | "white" | "black";
13
- href?: string;
14
- alt?: string;
15
- ui?: ComponentSlots<typeof logoTheme>;
16
- class?: any;
17
- [key: string]: unknown;
18
- }
19
-
20
10
  const {
21
11
  variant = "logomark",
22
12
  mode,
@@ -25,7 +15,7 @@ const {
25
15
  ui: uiProp,
26
16
  class: className,
27
17
  ...rest
28
- } = Astro.props as RLALogoProps;
18
+ } = Astro.props as LogoProps;
29
19
 
30
20
  const classes = resolveClasses(logo, {}, useUi("logo", uiProp), className);
31
21
 
@@ -1,22 +1,16 @@
1
1
  ---
2
2
  import { scv } from "css-variants"
3
3
  import { useUi, resolveClasses } from "../../utils"
4
- import type { ComponentSlots } from "../../types"
4
+ import type { PlaceholderProps } from "../../types"
5
5
  import placeholderTheme from "../../themes/placeholder.theme"
6
6
 
7
7
  const placeholder = scv(placeholderTheme)
8
8
 
9
- export interface RLAPlaceholderProps {
10
- ui?: ComponentSlots<typeof placeholderTheme>
11
- class?: any
12
- [key: string]: unknown
13
- }
14
-
15
9
  const {
16
10
  ui: uiProp,
17
11
  class: className,
18
12
  ...rest
19
- } = Astro.props as RLAPlaceholderProps
13
+ } = Astro.props as PlaceholderProps
20
14
 
21
15
  const classes = resolveClasses(placeholder, {}, useUi("placeholder", uiProp), className)
22
16
  ---
@@ -1,22 +1,10 @@
1
1
  ---
2
2
  import { scv } from "css-variants"
3
3
  import { useUi, resolveClasses } from "../../utils"
4
- import type { ComponentVariants, ComponentSlots } from "../../types"
4
+ import type { ScrollToTopProps } from "../../types"
5
5
  import scrollToTopTheme from "../../themes/scroll-to-top.theme"
6
6
 
7
7
  const scrollToTop = scv(scrollToTopTheme)
8
- type ScrollToTopVariants = ComponentVariants<typeof scrollToTopTheme>
9
-
10
- export interface RLAScrollToTopProps {
11
- color?: ScrollToTopVariants['color'];
12
- progressWidth?: number;
13
- duration?: number;
14
- threshold?: number;
15
- showProgress?: boolean;
16
- ui?: ComponentSlots<typeof scrollToTopTheme>;
17
- class?: any;
18
- [key: string]: unknown;
19
- }
20
8
 
21
9
  const {
22
10
  color = "primary",
@@ -27,7 +15,7 @@ const {
27
15
  ui: uiProp,
28
16
  class: className,
29
17
  ...rest
30
- } = Astro.props as RLAScrollToTopProps
18
+ } = Astro.props as ScrollToTopProps
31
19
 
32
20
  const classes = resolveClasses(scrollToTop, { color }, useUi("scrollToTop", uiProp), className)
33
21
 
@@ -1,65 +1,12 @@
1
1
  ---
2
2
  import { scv } from "css-variants"
3
3
  import { useUi, resolveClasses } from "../../utils"
4
- import type { ComponentVariants, ComponentSlots } from "../../types"
4
+ import type { SectionProps } from "../../types"
5
5
  import sectionTheme from "../../themes/section.theme"
6
- import type { RLAIconProps } from "./RLAIcon.astro"
7
- import type { RLAButtonProps } from "./RLAButton.astro"
8
6
  import RLAIcon from "./RLAIcon.astro"
9
7
  import RLAButton from "./RLAButton.astro"
10
8
 
11
9
  const section = scv(sectionTheme)
12
- type SectionVariants = ComponentVariants<typeof sectionTheme>
13
-
14
- export interface RLASectionProps {
15
- /**
16
- * The element or component this component should render as.
17
- * @default 'section'
18
- */
19
- as?: any;
20
- /**
21
- * The variant of the section.
22
- * @default 'default'
23
- */
24
- variant?: SectionVariants['variant'];
25
- /** The variant of the section when it's a CTA.
26
- * @default 'solid'
27
- */
28
- ctaVariant?: SectionVariants['ctaVariant'];
29
- /**
30
- * The headline displayed above the title.
31
- */
32
- headline?: string;
33
- /**
34
- * The icon displayed above the title.
35
- */
36
- icon?: RLAIconProps["name"];
37
- /**
38
- * The section's title, displayed as a <h1> for the hero variant or <h2> otherwise.
39
- */
40
- title?: string;
41
- /**
42
- * The section's description, displayed under the title.
43
- */
44
- description?: string;
45
- /**
46
- * Display a list of buttons under the description.
47
- */
48
- links?: RLAButtonProps[]
49
- /**
50
- * The orientation of the section.
51
- * @default 'vertical'
52
- */
53
- orientation?: SectionVariants['orientation'];
54
- /**
55
- * Reverse the order of the default slot.
56
- * @default false
57
- */
58
- reverse?: boolean;
59
- ui?: ComponentSlots<typeof sectionTheme>;
60
- class?: any;
61
- [key: string]: unknown;
62
- }
63
10
 
64
11
  const {
65
12
  as = "section",
@@ -67,19 +14,24 @@ const {
67
14
  orientation = "vertical",
68
15
  reverse = false,
69
16
  ctaVariant = "solid",
17
+ headline,
18
+ title,
19
+ description,
20
+ icon,
21
+ links,
70
22
  ui: uiProp,
71
23
  class: className,
72
24
  ...rest
73
- } = Astro.props as RLASectionProps;
25
+ } = Astro.props as SectionProps;
74
26
 
75
27
  const classes = resolveClasses(section, {
76
28
  variant,
77
29
  orientation,
78
30
  reverse,
79
31
  ...(variant === "cta" && { ctaVariant }),
80
- headline: !!(Astro.slots.has("headline") || Astro.props.headline),
81
- title: !!(Astro.slots.has("title") || Astro.props.title),
82
- description: !!(Astro.slots.has("description") || Astro.props.description),
32
+ headline: !!(Astro.slots.has("headline") || headline),
33
+ title: !!(Astro.slots.has("title") || title),
34
+ description: !!(Astro.slots.has("description") || description),
83
35
  body: Astro.slots.has("body")
84
36
  }, useUi("section", uiProp), className);
85
37
 
@@ -106,53 +58,53 @@ const TitleTag = variant === "hero" ? "h1" : "h2";
106
58
  <div
107
59
  class:list={[classes.container]}
108
60
  >
109
- {(Astro.slots.has("header") || Astro.props.icon || Astro.props.headline || Astro.props.title || Astro.props.description || Astro.slots.has("body") || Astro.slots.has("footer") || Astro.slots.has("links") || Astro.props.links?.length) && (
61
+ {(Astro.slots.has("header") || icon || headline || title || description || Astro.slots.has("body") || Astro.slots.has("footer") || Astro.slots.has("links") || links?.length) && (
110
62
  <div
111
63
  class:list={[classes.wrapper]}
112
64
  >
113
- {(Astro.slots.has("header") || Astro.props.icon || Astro.props.headline || Astro.props.title || Astro.props.description) && (
65
+ {(Astro.slots.has("header") || icon || headline || title || description) && (
114
66
  <div
115
67
  class:list={[classes.header]}
116
68
  >
117
69
  <slot name="header">
118
- {(Astro.props.icon || Astro.slots.has("leading")) && (
70
+ {(icon || Astro.slots.has("leading")) && (
119
71
  <div
120
72
  class:list={[classes.leading]}
121
73
  >
122
74
  <slot name="leading" {...{ ui: classes }}>
123
- {Astro.props.icon && (
124
- <RLAIcon name={Astro.props.icon} size="md" ui={{ root: classes.leadingIcon }} />
75
+ {icon && (
76
+ <RLAIcon name={icon} size="md" ui={{ root: classes.leadingIcon }} />
125
77
  )}
126
78
  </slot>
127
79
  </div>
128
80
  )}
129
81
 
130
- {(Astro.props.headline || Astro.slots.has("headline")) && (
82
+ {(headline || Astro.slots.has("headline")) && (
131
83
  <div
132
84
  class:list={[classes.headline]}
133
85
  >
134
86
  <slot name="headline">
135
- {Astro.props.headline}
87
+ {headline}
136
88
  </slot>
137
89
  </div>
138
90
  )}
139
91
 
140
- {(Astro.props.title || Astro.slots.has("title")) && (
92
+ {(title || Astro.slots.has("title")) && (
141
93
  <TitleTag
142
94
  class:list={[classes.title]}
143
95
  >
144
96
  <slot name="title">
145
- {Astro.props.title}
97
+ {title}
146
98
  </slot>
147
99
  </TitleTag>
148
100
  )}
149
101
 
150
- {(Astro.props.description || Astro.slots.has("description")) && (
102
+ {(description || Astro.slots.has("description")) && (
151
103
  <div
152
104
  class:list={[classes.description]}
153
105
  >
154
106
  <slot name="description">
155
- {Astro.props.description}
107
+ {description}
156
108
  </slot>
157
109
  </div>
158
110
  )}
@@ -168,16 +120,16 @@ const TitleTag = variant === "hero" ? "h1" : "h2";
168
120
  </div>
169
121
  )}
170
122
 
171
- {(Astro.slots.has("footer") || Astro.slots.has("links") || Astro.props.links?.length) && (
123
+ {(Astro.slots.has("footer") || Astro.slots.has("links") || links?.length) && (
172
124
  <div
173
125
  class:list={[classes.footer]}
174
126
  >
175
127
  <slot name="footer">
176
- {(Astro.props.links?.length || Astro.slots.has("links")) && (
128
+ {(links?.length || Astro.slots.has("links")) && (
177
129
  <div
178
130
  class:list={[classes.links]}
179
131
  >
180
- {Astro.props.links?.map((link) => (
132
+ {links?.map((link) => (
181
133
  <RLAButton size="lg" {...link} />
182
134
  ))}
183
135
  <slot name="links" />
@@ -2,72 +2,10 @@
2
2
  import { computed, useSlots } from "vue"
3
3
  import { scv } from "css-variants"
4
4
  import { useUi, resolveClasses } from "../../utils"
5
- import type { ComponentVariants, ComponentSlots } from "../../types"
5
+ import type { ButtonProps } from "../../types/components/button"
6
6
  import buttonTheme from "../../themes/button.theme"
7
7
 
8
8
  const button = scv(buttonTheme)
9
- type ButtonVariants = ComponentVariants<typeof buttonTheme>
10
-
11
- export interface RLVButtonProps {
12
- /**
13
- * The visual style variant of the button
14
- */
15
- variant?: ButtonVariants["variant"]
16
- /**
17
- * The color scheme applied to the button
18
- */
19
- color?: ButtonVariants["color"]
20
- /**
21
- * The size scale of the button
22
- */
23
- size?: ButtonVariants["size"]
24
- /**
25
- * When provided, renders the button as an anchor link
26
- */
27
- href?: string
28
- /**
29
- * The text label displayed inside the button
30
- */
31
- label?: string
32
- /**
33
- * Icon name displayed before the label
34
- */
35
- leadingIcon?: string
36
- /**
37
- * Icon name displayed after the label
38
- */
39
- trailingIcon?: string
40
- /**
41
- * Shows a loading spinner animation
42
- */
43
- loading?: boolean
44
- /**
45
- * Renders a square button with equal padding
46
- */
47
- square?: boolean
48
- /**
49
- * Makes the button stretch to full width
50
- */
51
- block?: boolean
52
- /**
53
- * Applies active state styling
54
- */
55
- active?: boolean
56
- /**
57
- * Color used when button is in active state
58
- */
59
- activeColor?: ButtonVariants["color"]
60
- /**
61
- * Variant used when button is in active state
62
- */
63
- activeVariant?: ButtonVariants["variant"]
64
- /**
65
- * Component-specific CSS class overrides
66
- */
67
- ui?: ComponentSlots<typeof buttonTheme>
68
- class?: any
69
- [key: string]: unknown
70
- }
71
9
 
72
10
  const {
73
11
  variant = "solid",
@@ -85,7 +23,7 @@ const {
85
23
  activeVariant,
86
24
  ui: uiProp,
87
25
  class: className
88
- } = defineProps<RLVButtonProps>()
26
+ } = defineProps<ButtonProps>()
89
27
 
90
28
  const slots = useSlots()
91
29
 
@@ -2,19 +2,12 @@
2
2
  import { computed } from "vue"
3
3
  import { scv } from "css-variants"
4
4
  import { useUi, resolveClasses } from "../../utils"
5
- import type { ComponentVariants, ComponentSlots } from "../../types"
5
+ import type { FooterProps } from "../../types/components/footer"
6
6
  import footerTheme from "../../themes/footer.theme"
7
7
 
8
8
  const footer = scv(footerTheme)
9
- type FooterVariants = ComponentVariants<typeof footerTheme>
10
9
 
11
- export interface RLVFooterProps {
12
- contain?: FooterVariants["contain"]
13
- ui?: ComponentSlots<typeof footerTheme>
14
- class?: any
15
- }
16
-
17
- const { contain = false, ui: uiProp, class: className } = defineProps<RLVFooterProps>()
10
+ const { contain = false, ui: uiProp, class: className } = defineProps<FooterProps>()
18
11
 
19
12
  defineSlots<{
20
13
  left(props: {}): any
@@ -2,22 +2,11 @@
2
2
  import { computed, onMounted, onUnmounted, ref } from "vue"
3
3
  import { scv } from "css-variants"
4
4
  import { useUi, resolveClasses } from "../../utils"
5
- import type { ComponentVariants, ComponentSlots } from "../../types"
5
+ import type { HeaderProps } from "../../types/components/header"
6
6
  import headerTheme from "../../themes/header.theme"
7
7
  import { getHeaderStack } from "../../utils/headerStack"
8
8
 
9
9
  const header = scv(headerTheme)
10
- type HeaderVariants = ComponentVariants<typeof headerTheme>
11
-
12
- export interface RLVHeaderProps {
13
- contain?: HeaderVariants["contain"]
14
- sticky?: HeaderVariants["sticky"]
15
- fixed?: HeaderVariants["fixed"]
16
- stackIndex?: number
17
- hideOnScroll?: boolean
18
- ui?: ComponentSlots<typeof headerTheme>
19
- class?: any
20
- }
21
10
 
22
11
  const {
23
12
  contain = true,
@@ -27,7 +16,7 @@ const {
27
16
  hideOnScroll = false,
28
17
  ui: uiProp,
29
18
  class: className
30
- } = defineProps<RLVHeaderProps>()
19
+ } = defineProps<HeaderProps>()
31
20
 
32
21
  defineSlots<{
33
22
  left(props: {}): any