@krak-stack/registry 0.10.2 → 0.10.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @krak-stack/registry
2
2
 
3
+ ## 0.10.3
4
+
5
+ ### Patch Changes
6
+
7
+ - 098424e: Expose optional ThemeSwitcher trigger and portalled menu class hooks. Preserve default appearance, localized choices, keyboard interactions and theme persistence; consumers own custom colors and selected-state styling.
8
+
3
9
  ## 0.10.2
4
10
 
5
11
  ### Patch Changes
@@ -18,7 +18,9 @@ type ThemeProviderProps = {
18
18
  initialTheme?: ThemePayload;
19
19
  scriptDisabled?: boolean;
20
20
  };
21
- type ThemeSwitcherProps = {
21
+ export type ThemeSwitcherProps = {
22
+ className?: string;
23
+ contentClassName?: string;
22
24
  locale?: string;
23
25
  messages?: ThemeSwitcherMessageTranslations;
24
26
  options?: ReadonlyArray<Theme>;
@@ -27,5 +29,5 @@ type ThemeSwitcherProps = {
27
29
  };
28
30
  export declare const ThemeProvider: ({ children, initialTheme, scriptDisabled, }: ThemeProviderProps) => import("react").JSX.Element;
29
31
  export declare const useTheme: () => ThemeProviderState;
30
- export declare const ThemeSwitcher: ({ locale: localeOverride, messages, options, value, onChange, }: ThemeSwitcherProps) => import("react").JSX.Element;
32
+ export declare const ThemeSwitcher: ({ className, contentClassName, locale: localeOverride, messages, options, value, onChange, }: ThemeSwitcherProps) => import("react").JSX.Element;
31
33
  export {};
@@ -264,6 +264,8 @@ var useTheme = () => {
264
264
  return context;
265
265
  };
266
266
  var ThemeSwitcher = ({
267
+ className,
268
+ contentClassName,
267
269
  locale: localeOverride,
268
270
  messages,
269
271
  options = themes,
@@ -279,6 +281,7 @@ var ThemeSwitcher = ({
279
281
  variant: "outline",
280
282
  size: "icon",
281
283
  "aria-label": labels.title,
284
+ className,
282
285
  children: [
283
286
  /* @__PURE__ */ jsx3(Sun, {
284
287
  "aria-hidden": "true",
@@ -300,7 +303,7 @@ var ThemeSwitcher = ({
300
303
  })
301
304
  }),
302
305
  /* @__PURE__ */ jsx3(DropdownMenuContent, {
303
- className: "w-32",
306
+ className: cn("w-32", contentClassName),
304
307
  children: /* @__PURE__ */ jsxs2(DropdownMenuGroup, {
305
308
  children: [
306
309
  /* @__PURE__ */ jsx3(DropdownMenuLabel, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@krak-stack/registry",
3
- "version": "0.10.2",
3
+ "version": "0.10.3",
4
4
  "description": "Tree-shakable KrakStack components and Effect services.",
5
5
  "license": "MIT",
6
6
  "repository": {