@stll/ui 0.34.4 → 0.34.5
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.
|
@@ -13,7 +13,7 @@ import { VariantProps } from "class-variance-authority";
|
|
|
13
13
|
*/
|
|
14
14
|
declare const buttonAccessibleDisabledClass = "cursor-not-allowed opacity-64";
|
|
15
15
|
declare const buttonVariants: (props?: ({
|
|
16
|
-
size?: "default" | "row" | "chip" | "icon" | "icon-lg" | "icon-sm" | "icon-xl" | "icon-xs" | "
|
|
16
|
+
size?: "default" | "sm" | "lg" | "row" | "chip" | "icon" | "icon-lg" | "icon-sm" | "icon-xl" | "icon-xs" | "xl" | "xs" | null | undefined;
|
|
17
17
|
variant?: "link" | "default" | "destructive" | "destructive-outline" | "destructive-ghost" | "ghost" | "muted" | "outline" | "secondary" | null | undefined;
|
|
18
18
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
19
19
|
type ButtonProps = {
|
|
@@ -5,7 +5,7 @@ import { VariantProps } from "class-variance-authority";
|
|
|
5
5
|
//#region src/components/input-group.d.ts
|
|
6
6
|
declare const InputGroup: ({ className, ...props }: React$1.ComponentProps<"div">) => React$1.JSX.Element;
|
|
7
7
|
declare const inputGroupAddonVariants: (props?: ({
|
|
8
|
-
align?: "inline-
|
|
8
|
+
align?: "inline-start" | "block-end" | "block-start" | "inline-end" | null | undefined;
|
|
9
9
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
10
10
|
declare const InputGroupAddon: ({ className, align, ...props }: React$1.ComponentProps<"div"> & VariantProps<typeof inputGroupAddonVariants>) => React$1.JSX.Element;
|
|
11
11
|
declare const InputGroupText: ({ className, ...props }: React$1.ComponentProps<"span">) => React$1.JSX.Element;
|
|
@@ -83,7 +83,7 @@ declare const SidebarMenu: ({ className, ...props }: React.ComponentProps<"ul">)
|
|
|
83
83
|
declare const SidebarMenuItem: ({ className, ...props }: React.ComponentProps<"li">) => import("react").JSX.Element;
|
|
84
84
|
declare const sidebarMenuButtonVariants: (props?: ({
|
|
85
85
|
variant?: "default" | "outline" | null | undefined;
|
|
86
|
-
size?: "default" | "
|
|
86
|
+
size?: "default" | "sm" | "lg" | "rail" | null | undefined;
|
|
87
87
|
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
88
88
|
declare const SidebarMenuButton: ({ asChild, isActive, variant, size, tooltip, className, ...props }: React.ComponentProps<"button"> & {
|
|
89
89
|
asChild?: boolean;
|
|
@@ -5,6 +5,6 @@ declare const CONTROL_SIZE: Readonly<{
|
|
|
5
5
|
readonly lg: "lg";
|
|
6
6
|
}>;
|
|
7
7
|
type ControlSize = (typeof CONTROL_SIZE)[keyof typeof CONTROL_SIZE];
|
|
8
|
-
declare const CONTROL_SIZES: readonly ("default" | "
|
|
8
|
+
declare const CONTROL_SIZES: readonly ("default" | "sm" | "lg")[];
|
|
9
9
|
//#endregion
|
|
10
10
|
export { CONTROL_SIZE, CONTROL_SIZES, type ControlSize };
|
package/dist/lib/week.js
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Locale week data (first weekday, weekend) derived from CLDR via Intl.
|
|
4
4
|
* Shared so the app shell and the date picker resolve week starts identically.
|
|
5
5
|
*/
|
|
6
|
+
const isWeekInfo = (value) => typeof value === "object" && value !== null && "firstDay" in value && typeof value.firstDay === "number" && "weekend" in value && Array.isArray(value.weekend);
|
|
6
7
|
/**
|
|
7
8
|
* Read CLDR week info for a locale, tolerating the legacy `weekInfo` accessor
|
|
8
9
|
* on engines that predate `getWeekInfo()`. Returns undefined when unavailable
|
|
@@ -11,8 +12,9 @@
|
|
|
11
12
|
const getLocaleWeekInfo = (locale) => {
|
|
12
13
|
try {
|
|
13
14
|
const loc = new Intl.Locale(locale);
|
|
14
|
-
|
|
15
|
-
|
|
15
|
+
if (typeof loc.getWeekInfo === "function") return loc.getWeekInfo();
|
|
16
|
+
const legacy = "weekInfo" in loc ? loc.weekInfo : void 0;
|
|
17
|
+
return isWeekInfo(legacy) ? legacy : void 0;
|
|
16
18
|
} catch {
|
|
17
19
|
return;
|
|
18
20
|
}
|
package/package.json
CHANGED