@bergetai/ui 0.16.2 → 0.18.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.
- package/dist/components/alert/Alert.d.cts +1 -1
- package/dist/components/alert/Alert.d.mts +1 -1
- package/dist/components/badge/Badge.d.cts +1 -1
- package/dist/components/badge/Badge.d.mts +1 -1
- package/dist/components/box/Box.d.cts +2 -2
- package/dist/components/box/Box.d.mts +2 -2
- package/dist/components/button/Button.cjs +21 -4
- package/dist/components/button/Button.cjs.map +1 -1
- package/dist/components/button/Button.d.cts +2 -1
- package/dist/components/button/Button.d.cts.map +1 -1
- package/dist/components/button/Button.d.mts +2 -1
- package/dist/components/button/Button.d.mts.map +1 -1
- package/dist/components/button/Button.mjs +19 -5
- package/dist/components/button/Button.mjs.map +1 -1
- package/dist/components/button/anchorVariants.cjs +56 -0
- package/dist/components/button/anchorVariants.cjs.map +1 -0
- package/dist/components/button/anchorVariants.d.cts +45 -0
- package/dist/components/button/anchorVariants.d.cts.map +1 -0
- package/dist/components/button/anchorVariants.d.mts +45 -0
- package/dist/components/button/anchorVariants.d.mts.map +1 -0
- package/dist/components/button/anchorVariants.mjs +55 -0
- package/dist/components/button/anchorVariants.mjs.map +1 -0
- package/dist/components/button/index.d.cts +2 -1
- package/dist/components/button/index.d.mts +2 -1
- package/dist/components/code-block/CodeBlock.cjs +50 -48
- package/dist/components/code-block/CodeBlock.cjs.map +1 -1
- package/dist/components/code-block/CodeBlock.d.cts +27 -7
- package/dist/components/code-block/CodeBlock.d.cts.map +1 -1
- package/dist/components/code-block/CodeBlock.d.mts +27 -7
- package/dist/components/code-block/CodeBlock.d.mts.map +1 -1
- package/dist/components/code-block/CodeBlock.mjs +45 -50
- package/dist/components/code-block/CodeBlock.mjs.map +1 -1
- package/dist/components/code-block/index.d.cts +3 -0
- package/dist/components/code-block/index.d.mts +3 -0
- package/dist/components/combobox/index.d.cts +2 -0
- package/dist/components/combobox/index.d.mts +2 -0
- package/dist/components/country-select/CountrySelect.cjs +1 -1
- package/dist/components/country-select/CountrySelect.mjs +1 -1
- package/dist/components/grid/Grid.d.cts +2 -2
- package/dist/components/grid/Grid.d.mts +2 -2
- package/dist/components/popover/index.d.cts +2 -0
- package/dist/components/popover/index.d.mts +2 -0
- package/dist/components/radio-group/index.d.cts +2 -0
- package/dist/components/radio-group/index.d.mts +2 -0
- package/dist/components/tabs/Tabs.cjs +109 -0
- package/dist/components/tabs/Tabs.cjs.map +1 -0
- package/dist/components/tabs/Tabs.d.cts +29 -0
- package/dist/components/tabs/Tabs.d.cts.map +1 -0
- package/dist/components/tabs/Tabs.d.mts +29 -0
- package/dist/components/tabs/Tabs.d.mts.map +1 -0
- package/dist/components/tabs/Tabs.mjs +103 -0
- package/dist/components/tabs/Tabs.mjs.map +1 -0
- package/dist/components/tabs/index.d.cts +2 -0
- package/dist/components/tabs/index.d.mts +2 -0
- package/dist/hooks/use-highlighted-code.cjs +58 -0
- package/dist/hooks/use-highlighted-code.cjs.map +1 -0
- package/dist/hooks/use-highlighted-code.d.cts +5 -0
- package/dist/hooks/use-highlighted-code.d.cts.map +1 -0
- package/dist/hooks/use-highlighted-code.d.mts +5 -0
- package/dist/hooks/use-highlighted-code.d.mts.map +1 -0
- package/dist/hooks/use-highlighted-code.mjs +56 -0
- package/dist/hooks/use-highlighted-code.mjs.map +1 -0
- package/dist/index.cjs +44 -0
- package/dist/index.d.cts +14 -2
- package/dist/index.d.mts +14 -2
- package/dist/index.mjs +9 -2
- package/dist/lib/highlighter.cjs +81 -0
- package/dist/lib/highlighter.cjs.map +1 -0
- package/dist/lib/highlighter.mjs +79 -0
- package/dist/lib/highlighter.mjs.map +1 -0
- package/dist/primitives/button.d.cts +1 -1
- package/dist/primitives/button.d.mts +1 -1
- package/dist/primitives/code-block.cjs +133 -0
- package/dist/primitives/code-block.cjs.map +1 -0
- package/dist/primitives/code-block.d.cts +29 -0
- package/dist/primitives/code-block.d.cts.map +1 -0
- package/dist/primitives/code-block.d.mts +29 -0
- package/dist/primitives/code-block.d.mts.map +1 -0
- package/dist/primitives/code-block.mjs +124 -0
- package/dist/primitives/code-block.mjs.map +1 -0
- package/dist/primitives/combobox.cjs +123 -0
- package/dist/primitives/combobox.cjs.map +1 -0
- package/dist/primitives/combobox.d.cts +25 -0
- package/dist/primitives/combobox.d.cts.map +1 -0
- package/dist/primitives/combobox.d.mts +25 -0
- package/dist/primitives/combobox.d.mts.map +1 -0
- package/dist/primitives/combobox.mjs +111 -0
- package/dist/primitives/combobox.mjs.map +1 -0
- package/dist/primitives/message-scroller.cjs +1 -1
- package/dist/primitives/message-scroller.mjs +1 -1
- package/dist/primitives/popover.cjs +24 -0
- package/dist/primitives/popover.cjs.map +1 -1
- package/dist/primitives/popover.d.cts +12 -0
- package/dist/primitives/popover.d.cts.map +1 -0
- package/dist/primitives/popover.d.mts +12 -0
- package/dist/primitives/popover.d.mts.map +1 -0
- package/dist/primitives/popover.mjs +22 -1
- package/dist/primitives/popover.mjs.map +1 -1
- package/dist/primitives/radio-group.cjs +23 -0
- package/dist/primitives/radio-group.cjs.map +1 -0
- package/dist/primitives/radio-group.d.cts +8 -0
- package/dist/primitives/radio-group.d.cts.map +1 -0
- package/dist/primitives/radio-group.d.mts +8 -0
- package/dist/primitives/radio-group.d.mts.map +1 -0
- package/dist/primitives/radio-group.mjs +22 -0
- package/dist/primitives/radio-group.mjs.map +1 -0
- package/dist/primitives/sidebar.cjs +1 -1
- package/dist/primitives/sidebar.mjs +1 -1
- package/dist/primitives/tabs.cjs +51 -0
- package/dist/primitives/tabs.cjs.map +1 -0
- package/dist/primitives/tabs.d.cts +11 -0
- package/dist/primitives/tabs.d.cts.map +1 -0
- package/dist/primitives/tabs.d.mts +11 -0
- package/dist/primitives/tabs.d.mts.map +1 -0
- package/dist/primitives/tabs.mjs +47 -0
- package/dist/primitives/tabs.mjs.map +1 -0
- package/dist/styles/index.css +61 -0
- package/package.json +2 -1
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { TabsList as TabsList$1, TabsTrigger as TabsTrigger$1 } from "../../primitives/tabs.cjs";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
import { VariantProps } from "class-variance-authority";
|
|
4
|
+
//#region src/components/tabs/Tabs.d.ts
|
|
5
|
+
type TabsListPrimitiveProps = React.ComponentProps<typeof TabsList$1>;
|
|
6
|
+
type TabsTabProps = React.ComponentProps<typeof TabsTrigger$1>;
|
|
7
|
+
declare const Tabs: React.ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").TabsRootProps, "className"> & {
|
|
8
|
+
className?: string;
|
|
9
|
+
}, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
10
|
+
declare const tabsListVariants: (props?: ({
|
|
11
|
+
variant?: "line" | "default" | null | undefined;
|
|
12
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
13
|
+
type TabsListProps = Omit<TabsListPrimitiveProps, 'className'> & VariantProps<typeof tabsListVariants> & {
|
|
14
|
+
className?: string;
|
|
15
|
+
};
|
|
16
|
+
declare const TabsList: React.ForwardRefExoticComponent<Omit<TabsListProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
17
|
+
declare const tabsTriggerVariants: (props?: ({
|
|
18
|
+
variant?: "line" | "default" | null | undefined;
|
|
19
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
20
|
+
type TabsTriggerProps = Omit<TabsTabProps, 'className'> & VariantProps<typeof tabsTriggerVariants> & {
|
|
21
|
+
className?: string;
|
|
22
|
+
};
|
|
23
|
+
declare const TabsTrigger: React.ForwardRefExoticComponent<Omit<TabsTriggerProps, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
24
|
+
declare const TabsContent: React.ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").TabsPanelProps, "className"> & {
|
|
25
|
+
className?: string;
|
|
26
|
+
}, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
27
|
+
//#endregion
|
|
28
|
+
export { Tabs, TabsContent, TabsList, TabsTrigger, tabsListVariants, tabsTriggerVariants };
|
|
29
|
+
//# sourceMappingURL=Tabs.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Tabs.d.cts","names":["TabsListPrimitive","TabsTriggerPrimitive"],"sources":["../../../src/components/tabs/Tabs.tsx"],"mappings":";;;;KAiBK,yBAAyB,MAAM,sBAAsBA;KACrD,eAAe,MAAM,sBAAsBC;cAO1C,MAAI,MAAA,0BAAA,KAAA,8BAAA;EAGM;YAEiF,MAAA,cAAA;cAO3F,mBAAgB;;6CAyBrB;KAEI,gBAAgB,KAAK,uCACxB,oBAAoB;EAClB;;cAGE,UAAQ,MAAA,0BAAA,KAAA,wBAAA,MAAA,cAAA;cA0CR,sBAAmB;;6CA6DxB;KAEI,mBAAmB,KAAK,6BAC3B,oBAAoB;EAClB;;cAGE,aAAW,MAAA,0BAAA,KAAA,2BAAA,MAAA,cAAA;cAeX,aAAW,MAAA,0BAAA,KAAA,8BAAA;EAEmC;YAOlD,MAAA,cAAA"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { TabsList as TabsList$1, TabsTrigger as TabsTrigger$1 } from "../../primitives/tabs.mjs";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
import { VariantProps } from "class-variance-authority";
|
|
4
|
+
//#region src/components/tabs/Tabs.d.ts
|
|
5
|
+
type TabsListPrimitiveProps = React.ComponentProps<typeof TabsList$1>;
|
|
6
|
+
type TabsTabProps = React.ComponentProps<typeof TabsTrigger$1>;
|
|
7
|
+
declare const Tabs: React.ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").TabsRootProps, "className"> & {
|
|
8
|
+
className?: string;
|
|
9
|
+
}, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
10
|
+
declare const tabsListVariants: (props?: ({
|
|
11
|
+
variant?: "line" | "default" | null | undefined;
|
|
12
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
13
|
+
type TabsListProps = Omit<TabsListPrimitiveProps, 'className'> & VariantProps<typeof tabsListVariants> & {
|
|
14
|
+
className?: string;
|
|
15
|
+
};
|
|
16
|
+
declare const TabsList: React.ForwardRefExoticComponent<Omit<TabsListProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
17
|
+
declare const tabsTriggerVariants: (props?: ({
|
|
18
|
+
variant?: "line" | "default" | null | undefined;
|
|
19
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
20
|
+
type TabsTriggerProps = Omit<TabsTabProps, 'className'> & VariantProps<typeof tabsTriggerVariants> & {
|
|
21
|
+
className?: string;
|
|
22
|
+
};
|
|
23
|
+
declare const TabsTrigger: React.ForwardRefExoticComponent<Omit<TabsTriggerProps, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
24
|
+
declare const TabsContent: React.ForwardRefExoticComponent<Omit<Omit<import("@base-ui/react").TabsPanelProps, "className"> & {
|
|
25
|
+
className?: string;
|
|
26
|
+
}, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
27
|
+
//#endregion
|
|
28
|
+
export { Tabs, TabsContent, TabsList, TabsTrigger, tabsListVariants, tabsTriggerVariants };
|
|
29
|
+
//# sourceMappingURL=Tabs.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Tabs.d.mts","names":["TabsListPrimitive","TabsTriggerPrimitive"],"sources":["../../../src/components/tabs/Tabs.tsx"],"mappings":";;;;KAiBK,yBAAyB,MAAM,sBAAsBA;KACrD,eAAe,MAAM,sBAAsBC;cAO1C,MAAI,MAAA,0BAAA,KAAA,8BAAA;EAGM;YAEiF,MAAA,cAAA;cAO3F,mBAAgB;;6CAyBrB;KAEI,gBAAgB,KAAK,uCACxB,oBAAoB;EAClB;;cAGE,UAAQ,MAAA,0BAAA,KAAA,wBAAA,MAAA,cAAA;cA0CR,sBAAmB;;6CA6DxB;KAEI,mBAAmB,KAAK,6BAC3B,oBAAoB;EAClB;;cAGE,aAAW,MAAA,0BAAA,KAAA,2BAAA,MAAA,cAAA;cAeX,aAAW,MAAA,0BAAA,KAAA,8BAAA;EAEmC;YAOlD,MAAA,cAAA"}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { cn } from "../../lib/utils.mjs";
|
|
3
|
+
import { Tabs as Tabs$2, TabsContent as TabsContent$1, TabsList as TabsList$1, TabsTrigger as TabsTrigger$1 } from "../../primitives/tabs.mjs";
|
|
4
|
+
import * as React from "react";
|
|
5
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
+
import { cva } from "class-variance-authority";
|
|
7
|
+
import { Tabs } from "@base-ui/react/tabs";
|
|
8
|
+
//#region src/components/tabs/Tabs.tsx
|
|
9
|
+
const TabsIndicatorPrimitive = Tabs.Indicator;
|
|
10
|
+
const Tabs$1 = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(Tabs$2, {
|
|
11
|
+
ref,
|
|
12
|
+
className,
|
|
13
|
+
...props
|
|
14
|
+
}));
|
|
15
|
+
Tabs$1.displayName = "Tabs";
|
|
16
|
+
const tabsListVariants = cva(cn(`
|
|
17
|
+
group/tabs-list inline-flex w-fit items-center justify-center
|
|
18
|
+
rounded-berget-xs p-[3px] text-berget-muted-foreground
|
|
19
|
+
`, `
|
|
20
|
+
group-data-[orientation=horizontal]/tabs:h-9
|
|
21
|
+
group-data-[orientation=vertical]/tabs:h-fit
|
|
22
|
+
group-data-[orientation=vertical]/tabs:flex-col
|
|
23
|
+
`), {
|
|
24
|
+
variants: { variant: {
|
|
25
|
+
default: "bg-berget-tabs-list-bg",
|
|
26
|
+
line: "relative gap-2 rounded-berget-none bg-transparent"
|
|
27
|
+
} },
|
|
28
|
+
defaultVariants: { variant: "default" }
|
|
29
|
+
});
|
|
30
|
+
const TabsList = React.forwardRef(({ className, variant = "default", children, ...props }, ref) => /* @__PURE__ */ jsxs(TabsList$1, {
|
|
31
|
+
ref,
|
|
32
|
+
"data-variant": variant,
|
|
33
|
+
className: cn(tabsListVariants({ variant }), className),
|
|
34
|
+
...props,
|
|
35
|
+
children: [children, variant === "line" && /* @__PURE__ */ jsx(TabsIndicatorPrimitive, { className: cn(`
|
|
36
|
+
pointer-events-none absolute z-10 block rounded-berget-full
|
|
37
|
+
bg-berget-tabs-line-indicator transition-[left,top,width,height]
|
|
38
|
+
duration-200 ease-out
|
|
39
|
+
`, `
|
|
40
|
+
group-data-[orientation=horizontal]/tabs:bottom-0
|
|
41
|
+
group-data-[orientation=horizontal]/tabs:left-(--active-tab-left)
|
|
42
|
+
group-data-[orientation=horizontal]/tabs:h-0.5
|
|
43
|
+
group-data-[orientation=horizontal]/tabs:w-(--active-tab-width)
|
|
44
|
+
`, `
|
|
45
|
+
group-data-[orientation=vertical]/tabs:top-(--active-tab-top)
|
|
46
|
+
group-data-[orientation=vertical]/tabs:left-0
|
|
47
|
+
group-data-[orientation=vertical]/tabs:h-(--active-tab-height)
|
|
48
|
+
group-data-[orientation=vertical]/tabs:w-0.5
|
|
49
|
+
`) })]
|
|
50
|
+
}));
|
|
51
|
+
TabsList.displayName = "TabsList";
|
|
52
|
+
const tabsTriggerVariants = cva(cn(`
|
|
53
|
+
relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center
|
|
54
|
+
gap-1.5 rounded-berget-xs border border-transparent px-3 py-1.5 text-sm
|
|
55
|
+
font-medium whitespace-nowrap transition-all
|
|
56
|
+
`, `
|
|
57
|
+
group-data-[orientation=vertical]/tabs:w-full
|
|
58
|
+
group-data-[orientation=vertical]/tabs:justify-start
|
|
59
|
+
`, `
|
|
60
|
+
text-berget-foreground-alt
|
|
61
|
+
hover:text-berget-foreground
|
|
62
|
+
`, `
|
|
63
|
+
focus-visible:ring-berget-focus-ring focus-visible:ring-2
|
|
64
|
+
focus-visible:ring-offset-2 focus-visible:ring-offset-berget-tabs-list-bg
|
|
65
|
+
focus-visible:outline-none
|
|
66
|
+
`, `
|
|
67
|
+
disabled:pointer-events-none disabled:opacity-50
|
|
68
|
+
aria-disabled:pointer-events-none aria-disabled:opacity-50
|
|
69
|
+
`, `
|
|
70
|
+
[&_svg]:pointer-events-none [&_svg]:shrink-0
|
|
71
|
+
[&_svg:not([class*=size-])]:size-4
|
|
72
|
+
`, "after:hidden"), {
|
|
73
|
+
variants: { variant: {
|
|
74
|
+
default: cn(`
|
|
75
|
+
group-data-[variant=default]/tabs-list:data-active:bg-berget-tabs-trigger-active-bg
|
|
76
|
+
group-data-[variant=default]/tabs-list:data-active:text-berget-tabs-trigger-active-fg
|
|
77
|
+
group-data-[variant=default]/tabs-list:data-active:shadow-berget-sm
|
|
78
|
+
`),
|
|
79
|
+
line: cn(`
|
|
80
|
+
group-data-[variant=line]/tabs-list:bg-transparent
|
|
81
|
+
group-data-[variant=line]/tabs-list:hover:bg-berget-surface-hover
|
|
82
|
+
group-data-[variant=line]/tabs-list:data-active:bg-transparent
|
|
83
|
+
group-data-[variant=line]/tabs-list:data-active:text-berget-foreground
|
|
84
|
+
`)
|
|
85
|
+
} },
|
|
86
|
+
defaultVariants: { variant: "default" }
|
|
87
|
+
});
|
|
88
|
+
const TabsTrigger = React.forwardRef(({ className, variant, ...props }, ref) => /* @__PURE__ */ jsx(TabsTrigger$1, {
|
|
89
|
+
ref,
|
|
90
|
+
className: cn(tabsTriggerVariants({ variant }), className),
|
|
91
|
+
...props
|
|
92
|
+
}));
|
|
93
|
+
TabsTrigger.displayName = "TabsTrigger";
|
|
94
|
+
const TabsContent = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(TabsContent$1, {
|
|
95
|
+
ref,
|
|
96
|
+
className: cn("flex-1 text-sm text-berget-foreground outline-none", className),
|
|
97
|
+
...props
|
|
98
|
+
}));
|
|
99
|
+
TabsContent.displayName = "TabsContent";
|
|
100
|
+
//#endregion
|
|
101
|
+
export { Tabs$1 as Tabs, TabsContent, TabsList, TabsTrigger, tabsListVariants, tabsTriggerVariants };
|
|
102
|
+
|
|
103
|
+
//# sourceMappingURL=Tabs.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Tabs.mjs","names":["TabsBaseUI","Tabs","TabsPrimitive","TabsListPrimitive","TabsTriggerPrimitive","TabsContentPrimitive"],"sources":["../../../src/components/tabs/Tabs.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\n\nimport { Tabs as TabsBaseUI } from '@base-ui/react/tabs';\n\nimport { cn } from '../../lib/utils';\nimport {\n Tabs as TabsPrimitive,\n TabsList as TabsListPrimitive,\n TabsTrigger as TabsTriggerPrimitive,\n TabsContent as TabsContentPrimitive,\n} from '../../primitives/tabs';\n\nconst TabsIndicatorPrimitive = TabsBaseUI.Indicator;\ntype TabsRootProps = React.ComponentProps<typeof TabsPrimitive>;\ntype TabsListPrimitiveProps = React.ComponentProps<typeof TabsListPrimitive>;\ntype TabsTabProps = React.ComponentProps<typeof TabsTriggerPrimitive>;\ntype TabsPanelProps = React.ComponentProps<typeof TabsContentPrimitive>;\n\n/* ------------------------------------------------------------------ */\n/* Root — thin pass-through, Berget gap only */\n/* ------------------------------------------------------------------ */\n\nconst Tabs = React.forwardRef<\n HTMLDivElement,\n Omit<TabsRootProps, 'className'> & {\n className?: string;\n }\n>(({ className, ...props }, ref) => <TabsPrimitive ref={ref} className={className} {...props} />);\nTabs.displayName = 'Tabs';\n\n/* ------------------------------------------------------------------ */\n/* List — Berget tokens + the sliding Indicator for the line variant */\n/* ------------------------------------------------------------------ */\n\nconst tabsListVariants = cva(\n cn(\n `\n group/tabs-list inline-flex w-fit items-center justify-center\n rounded-berget-xs p-[3px] text-berget-muted-foreground\n `,\n `\n group-data-[orientation=horizontal]/tabs:h-9\n group-data-[orientation=vertical]/tabs:h-fit\n group-data-[orientation=vertical]/tabs:flex-col\n `,\n ),\n {\n variants: {\n variant: {\n // Pill / segmented control: recessed track.\n default: 'bg-berget-tabs-list-bg',\n // Underline: transparent track; the Indicator is the underline.\n line: 'relative gap-2 rounded-berget-none bg-transparent',\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\ntype TabsListProps = Omit<TabsListPrimitiveProps, 'className'> &\n VariantProps<typeof tabsListVariants> & {\n className?: string;\n };\n\nconst TabsList = React.forwardRef<HTMLDivElement, TabsListProps>(\n ({ className, variant = 'default', children, ...props }, ref) => (\n <TabsListPrimitive\n ref={ref}\n data-variant={variant}\n className={cn(tabsListVariants({ variant }), className)}\n {...props}\n >\n {children}\n {/* Animated sliding underline — rendered only for the line variant. */}\n {variant === 'line' && (\n <TabsIndicatorPrimitive\n className={cn(\n `\n pointer-events-none absolute z-10 block rounded-berget-full\n bg-berget-tabs-line-indicator transition-[left,top,width,height]\n duration-200 ease-out\n `,\n `\n group-data-[orientation=horizontal]/tabs:bottom-0\n group-data-[orientation=horizontal]/tabs:left-(--active-tab-left)\n group-data-[orientation=horizontal]/tabs:h-0.5\n group-data-[orientation=horizontal]/tabs:w-(--active-tab-width)\n `,\n `\n group-data-[orientation=vertical]/tabs:top-(--active-tab-top)\n group-data-[orientation=vertical]/tabs:left-0\n group-data-[orientation=vertical]/tabs:h-(--active-tab-height)\n group-data-[orientation=vertical]/tabs:w-0.5\n `,\n )}\n />\n )}\n </TabsListPrimitive>\n ),\n);\nTabsList.displayName = 'TabsList';\n\n/* ------------------------------------------------------------------ */\n/* Trigger — Berget-brand active/hover states */\n/* ------------------------------------------------------------------ */\n\nconst tabsTriggerVariants = cva(\n cn(\n `\n relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center\n gap-1.5 rounded-berget-xs border border-transparent px-3 py-1.5 text-sm\n font-medium whitespace-nowrap transition-all\n `,\n `\n group-data-[orientation=vertical]/tabs:w-full\n group-data-[orientation=vertical]/tabs:justify-start\n `,\n // Inactive: dimmed foreground.\n `\n text-berget-foreground-alt\n hover:text-berget-foreground\n `,\n // Focus.\n `\n focus-visible:ring-berget-focus-ring focus-visible:ring-2\n focus-visible:ring-offset-2 focus-visible:ring-offset-berget-tabs-list-bg\n focus-visible:outline-none\n `,\n // Disabled.\n `\n disabled:pointer-events-none disabled:opacity-50\n aria-disabled:pointer-events-none aria-disabled:opacity-50\n `,\n // Icons sized by the component, no manual sizing classes.\n `\n [&_svg]:pointer-events-none [&_svg]:shrink-0\n [&_svg:not([class*=size-])]:size-4\n `,\n // Hide the primitive's line-variant underline — Berget uses the sliding Indicator.\n 'after:hidden',\n ),\n {\n variants: {\n variant: {\n // Pill: active trigger lifts to the background surface.\n default: cn(\n `\n group-data-[variant=default]/tabs-list:data-active:bg-berget-tabs-trigger-active-bg\n group-data-[variant=default]/tabs-list:data-active:text-berget-tabs-trigger-active-fg\n group-data-[variant=default]/tabs-list:data-active:shadow-berget-sm\n `,\n ),\n // Underline: transparent trigger; the list's Indicator is the cue.\n line: cn(\n `\n group-data-[variant=line]/tabs-list:bg-transparent\n group-data-[variant=line]/tabs-list:hover:bg-berget-surface-hover\n group-data-[variant=line]/tabs-list:data-active:bg-transparent\n group-data-[variant=line]/tabs-list:data-active:text-berget-foreground\n `,\n ),\n },\n },\n defaultVariants: {\n variant: 'default',\n },\n },\n);\n\ntype TabsTriggerProps = Omit<TabsTabProps, 'className'> &\n VariantProps<typeof tabsTriggerVariants> & {\n className?: string;\n };\n\nconst TabsTrigger = React.forwardRef<HTMLButtonElement, TabsTriggerProps>(\n ({ className, variant, ...props }, ref) => (\n <TabsTriggerPrimitive\n ref={ref}\n className={cn(tabsTriggerVariants({ variant }), className)}\n {...props}\n />\n ),\n);\nTabsTrigger.displayName = 'TabsTrigger';\n\n/* ------------------------------------------------------------------ */\n/* Content */\n/* ------------------------------------------------------------------ */\n\nconst TabsContent = React.forwardRef<\n HTMLDivElement,\n Omit<TabsPanelProps, 'className'> & { className?: string }\n>(({ className, ...props }, ref) => (\n <TabsContentPrimitive\n ref={ref}\n className={cn('flex-1 text-sm text-berget-foreground outline-none', className)}\n {...props}\n />\n));\nTabsContent.displayName = 'TabsContent';\n\n/* ------------------------------------------------------------------ */\n/* Exports */\n/* ------------------------------------------------------------------ */\n\nexport { Tabs, TabsList, TabsTrigger, TabsContent, tabsListVariants, tabsTriggerVariants };\n"],"mappings":";;;;;;;;AAeA,MAAM,yBAAyBA,KAAW;AAU1C,MAAMC,SAAO,MAAM,YAKhB,EAAE,WAAW,GAAG,SAAS,QAAQ,oBAACC,QAAD;CAAoB;CAAgB;CAAW,GAAI;AAAQ,CAAA,CAAC;AAChG,OAAK,cAAc;AAMnB,MAAM,mBAAmB,IACvB,GACE;;;OAIA;;;;KAKF,GACA;CACE,UAAU,EACR,SAAS;EAEP,SAAS;EAET,MAAM;CACR,EACF;CACA,iBAAiB,EACf,SAAS,UACX;AACF,CACF;AAOA,MAAM,WAAW,MAAM,YACpB,EAAE,WAAW,UAAU,WAAW,UAAU,GAAG,SAAS,QACvD,qBAACC,YAAD;CACO;CACL,gBAAc;CACd,WAAW,GAAG,iBAAiB,EAAE,QAAQ,CAAC,GAAG,SAAS;CACtD,GAAI;CAJN,UAAA,CAMG,UAEA,YAAY,UACX,oBAAC,wBAAD,EACE,WAAW,GACT;;;;eAKA;;;;;eAMA;;;;;aAMF,EACD,CAAA,CAEc;AAEvB,CAAA,CAAA;AACA,SAAS,cAAc;AAMvB,MAAM,sBAAsB,IAC1B,GACE;;;;OAKA;;;OAKA;;;OAKA;;;;OAMA;;;OAKA;;;OAKA,cACF,GACA;CACE,UAAU,EACR,SAAS;EAEP,SAAS,GACP;;;;WAKF;EAEA,MAAM,GACJ;;;;;WAMF;CACF,EACF;CACA,iBAAiB,EACf,SAAS,UACX;AACF,CACF;AAOA,MAAM,cAAc,MAAM,YACvB,EAAE,WAAW,SAAS,GAAG,SAAS,QACjC,oBAACC,eAAD;CACO;CACL,WAAW,GAAG,oBAAoB,EAAE,QAAQ,CAAC,GAAG,SAAS;CACzD,GAAI;AACL,CAAA,CAEL;AACA,YAAY,cAAc;AAM1B,MAAM,cAAc,MAAM,YAGvB,EAAE,WAAW,GAAG,SAAS,QAC1B,oBAACC,eAAD;CACO;CACL,WAAW,GAAG,sDAAsD,SAAS;CAC7E,GAAI;AACL,CAAA,CACF;AACD,YAAY,cAAc"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
const require_runtime = require("../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_highlighter = require("../lib/highlighter.cjs");
|
|
3
|
+
let react = require("react");
|
|
4
|
+
react = require_runtime.__toESM(react, 1);
|
|
5
|
+
//#region src/hooks/use-highlighted-code.ts
|
|
6
|
+
function useHighlightedCode(value, language) {
|
|
7
|
+
const code = value.endsWith("\n") ? value.slice(0, -1) : value;
|
|
8
|
+
const [loaded, setLoaded] = react.useState(null);
|
|
9
|
+
const highlighter = loaded?.language === language ? loaded.highlighter : null;
|
|
10
|
+
react.useEffect(() => {
|
|
11
|
+
let cancelled = false;
|
|
12
|
+
require_highlighter.loadHighlighter(language).then((next) => {
|
|
13
|
+
if (!cancelled) setLoaded({
|
|
14
|
+
language,
|
|
15
|
+
highlighter: next
|
|
16
|
+
});
|
|
17
|
+
}).catch(() => {});
|
|
18
|
+
return () => {
|
|
19
|
+
cancelled = true;
|
|
20
|
+
};
|
|
21
|
+
}, [language]);
|
|
22
|
+
const [done, setDone] = react.useState({
|
|
23
|
+
highlighter: null,
|
|
24
|
+
text: "",
|
|
25
|
+
lines: []
|
|
26
|
+
});
|
|
27
|
+
let next = done;
|
|
28
|
+
if (next.highlighter !== highlighter || !code.startsWith(next.text)) next = {
|
|
29
|
+
highlighter,
|
|
30
|
+
text: "",
|
|
31
|
+
lines: []
|
|
32
|
+
};
|
|
33
|
+
const end = code.lastIndexOf("\n") + 1;
|
|
34
|
+
if (highlighter && end > next.text.length) {
|
|
35
|
+
const result = highlighter.highlight(code.slice(next.text.length, end - 1), next.state);
|
|
36
|
+
next = {
|
|
37
|
+
highlighter,
|
|
38
|
+
text: code.slice(0, end),
|
|
39
|
+
lines: [...next.lines, ...result.lines],
|
|
40
|
+
state: result.state
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
if (next !== done) setDone(next);
|
|
44
|
+
const tail = code.slice(end);
|
|
45
|
+
return react.useMemo(() => {
|
|
46
|
+
if (!highlighter) return code.split("\n");
|
|
47
|
+
return [...next.lines, highlighter.highlight(tail, next.state).lines[0]];
|
|
48
|
+
}, [
|
|
49
|
+
code,
|
|
50
|
+
highlighter,
|
|
51
|
+
next,
|
|
52
|
+
tail
|
|
53
|
+
]);
|
|
54
|
+
}
|
|
55
|
+
//#endregion
|
|
56
|
+
exports.useHighlightedCode = useHighlightedCode;
|
|
57
|
+
|
|
58
|
+
//# sourceMappingURL=use-highlighted-code.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-highlighted-code.cjs","names":["React"],"sources":["../../src/hooks/use-highlighted-code.ts"],"sourcesContent":["// BERGET: upstream uses an intentional mutate-during-render streaming pattern\n// (see the init/render loop below); the React Compiler skips this file, which\n// is safe and expected. Keep this minimal when replaying upstream updates.\n/* eslint-disable react-hooks/preserve-manual-memoization */\nimport * as React from 'react';\n\nimport { loadHighlighter } from '@/lib/highlighter';\n\nexport function useHighlightedCode(value: string, language: string) {\n // A trailing newline would render as an extra empty line.\n const code = value.endsWith('\\n') ? value.slice(0, -1) : value;\n const [loaded, setLoaded] = React.useState<{\n language: string;\n highlighter: Awaited<ReturnType<typeof loadHighlighter>>;\n } | null>(null);\n const highlighter = loaded?.language === language ? loaded.highlighter : null;\n\n React.useEffect(() => {\n let cancelled = false;\n\n loadHighlighter(language)\n .then((next) => {\n if (!cancelled) {\n setLoaded({ language, highlighter: next });\n }\n })\n .catch(() => {});\n\n return () => {\n cancelled = true;\n };\n }, [language]);\n\n // The complete lines, highlighted. While the code streams, only the new\n // lines are tokenized, starting from the grammar state of the last one.\n const [done, setDone] = React.useState<{\n highlighter: typeof highlighter;\n text: string;\n lines: React.ReactNode[];\n state?: Parameters<NonNullable<typeof highlighter>['highlight']>[1];\n }>({ highlighter: null, text: '', lines: [] });\n\n let next = done;\n\n if (next.highlighter !== highlighter || !code.startsWith(next.text)) {\n next = { highlighter, text: '', lines: [] };\n }\n\n const end = code.lastIndexOf('\\n') + 1;\n\n if (highlighter && end > next.text.length) {\n const result = highlighter.highlight(code.slice(next.text.length, end - 1), next.state);\n\n next = {\n highlighter,\n text: code.slice(0, end),\n lines: [...next.lines, ...result.lines],\n state: result.state,\n };\n }\n\n if (next !== done) {\n setDone(next);\n }\n\n // The last line is still being written, so it is tokenized on every render.\n const tail = code.slice(end);\n\n return React.useMemo(() => {\n if (!highlighter) {\n return code.split('\\n');\n }\n\n return [...next.lines, highlighter.highlight(tail, next.state).lines[0]];\n }, [code, highlighter, next, tail]);\n}\n"],"mappings":";;;;;AAQA,SAAgB,mBAAmB,OAAe,UAAkB;CAElE,MAAM,OAAO,MAAM,SAAS,IAAI,IAAI,MAAM,MAAM,GAAG,EAAE,IAAI;CACzD,MAAM,CAAC,QAAQ,aAAaA,MAAM,SAGxB,IAAI;CACd,MAAM,cAAc,QAAQ,aAAa,WAAW,OAAO,cAAc;CAEzE,MAAM,gBAAgB;EACpB,IAAI,YAAY;EAEhB,oBAAA,gBAAgB,QAAQ,CAAC,CACtB,MAAM,SAAS;GACd,IAAI,CAAC,WACH,UAAU;IAAE;IAAU,aAAa;GAAK,CAAC;EAE7C,CAAC,CAAC,CACD,YAAY,CAAC,CAAC;EAEjB,aAAa;GACX,YAAY;EACd;CACF,GAAG,CAAC,QAAQ,CAAC;CAIb,MAAM,CAAC,MAAM,WAAWA,MAAM,SAK3B;EAAE,aAAa;EAAM,MAAM;EAAI,OAAO,CAAC;CAAE,CAAC;CAE7C,IAAI,OAAO;CAEX,IAAI,KAAK,gBAAgB,eAAe,CAAC,KAAK,WAAW,KAAK,IAAI,GAChE,OAAO;EAAE;EAAa,MAAM;EAAI,OAAO,CAAC;CAAE;CAG5C,MAAM,MAAM,KAAK,YAAY,IAAI,IAAI;CAErC,IAAI,eAAe,MAAM,KAAK,KAAK,QAAQ;EACzC,MAAM,SAAS,YAAY,UAAU,KAAK,MAAM,KAAK,KAAK,QAAQ,MAAM,CAAC,GAAG,KAAK,KAAK;EAEtF,OAAO;GACL;GACA,MAAM,KAAK,MAAM,GAAG,GAAG;GACvB,OAAO,CAAC,GAAG,KAAK,OAAO,GAAG,OAAO,KAAK;GACtC,OAAO,OAAO;EAChB;CACF;CAEA,IAAI,SAAS,MACX,QAAQ,IAAI;CAId,MAAM,OAAO,KAAK,MAAM,GAAG;CAE3B,OAAOA,MAAM,cAAc;EACzB,IAAI,CAAC,aACH,OAAO,KAAK,MAAM,IAAI;EAGxB,OAAO,CAAC,GAAG,KAAK,OAAO,YAAY,UAAU,MAAM,KAAK,KAAK,CAAC,CAAC,MAAM,EAAE;CACzE,GAAG;EAAC;EAAM;EAAa;EAAM;CAAI,CAAC;AACpC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
//#region src/hooks/use-highlighted-code.d.ts
|
|
3
|
+
export declare function useHighlightedCode(value: string, language: string): (string | number | bigint | boolean | import("react/jsx-runtime").JSX.Element[] | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | null | undefined)[];
|
|
4
|
+
//#endregion
|
|
5
|
+
//# sourceMappingURL=use-highlighted-code.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-highlighted-code.d.cts","names":[],"sources":["../../src/hooks/use-highlighted-code.ts"],"mappings":";;wBAQgB,mBAAmB,eAAe,qFAAgB,IAAA,YAAA,MAAA,+BAAA,MAAA,8BAAA,SAAA,MAAA,aAAA,6CAAA,MAAA,cAAA,MAAA,+BAAA,MAAA,8BAAA,SAAA,MAAA"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
//#region src/hooks/use-highlighted-code.d.ts
|
|
3
|
+
export declare function useHighlightedCode(value: string, language: string): (string | number | bigint | boolean | import("react/jsx-runtime").JSX.Element[] | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | null | undefined)[];
|
|
4
|
+
//#endregion
|
|
5
|
+
//# sourceMappingURL=use-highlighted-code.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-highlighted-code.d.mts","names":[],"sources":["../../src/hooks/use-highlighted-code.ts"],"mappings":";;wBAQgB,mBAAmB,eAAe,qFAAgB,IAAA,YAAA,MAAA,+BAAA,MAAA,8BAAA,SAAA,MAAA,aAAA,6CAAA,MAAA,cAAA,MAAA,+BAAA,MAAA,8BAAA,SAAA,MAAA"}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { loadHighlighter } from "../lib/highlighter.mjs";
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
//#region src/hooks/use-highlighted-code.ts
|
|
4
|
+
function useHighlightedCode(value, language) {
|
|
5
|
+
const code = value.endsWith("\n") ? value.slice(0, -1) : value;
|
|
6
|
+
const [loaded, setLoaded] = React.useState(null);
|
|
7
|
+
const highlighter = loaded?.language === language ? loaded.highlighter : null;
|
|
8
|
+
React.useEffect(() => {
|
|
9
|
+
let cancelled = false;
|
|
10
|
+
loadHighlighter(language).then((next) => {
|
|
11
|
+
if (!cancelled) setLoaded({
|
|
12
|
+
language,
|
|
13
|
+
highlighter: next
|
|
14
|
+
});
|
|
15
|
+
}).catch(() => {});
|
|
16
|
+
return () => {
|
|
17
|
+
cancelled = true;
|
|
18
|
+
};
|
|
19
|
+
}, [language]);
|
|
20
|
+
const [done, setDone] = React.useState({
|
|
21
|
+
highlighter: null,
|
|
22
|
+
text: "",
|
|
23
|
+
lines: []
|
|
24
|
+
});
|
|
25
|
+
let next = done;
|
|
26
|
+
if (next.highlighter !== highlighter || !code.startsWith(next.text)) next = {
|
|
27
|
+
highlighter,
|
|
28
|
+
text: "",
|
|
29
|
+
lines: []
|
|
30
|
+
};
|
|
31
|
+
const end = code.lastIndexOf("\n") + 1;
|
|
32
|
+
if (highlighter && end > next.text.length) {
|
|
33
|
+
const result = highlighter.highlight(code.slice(next.text.length, end - 1), next.state);
|
|
34
|
+
next = {
|
|
35
|
+
highlighter,
|
|
36
|
+
text: code.slice(0, end),
|
|
37
|
+
lines: [...next.lines, ...result.lines],
|
|
38
|
+
state: result.state
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
if (next !== done) setDone(next);
|
|
42
|
+
const tail = code.slice(end);
|
|
43
|
+
return React.useMemo(() => {
|
|
44
|
+
if (!highlighter) return code.split("\n");
|
|
45
|
+
return [...next.lines, highlighter.highlight(tail, next.state).lines[0]];
|
|
46
|
+
}, [
|
|
47
|
+
code,
|
|
48
|
+
highlighter,
|
|
49
|
+
next,
|
|
50
|
+
tail
|
|
51
|
+
]);
|
|
52
|
+
}
|
|
53
|
+
//#endregion
|
|
54
|
+
export { useHighlightedCode };
|
|
55
|
+
|
|
56
|
+
//# sourceMappingURL=use-highlighted-code.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-highlighted-code.mjs","names":[],"sources":["../../src/hooks/use-highlighted-code.ts"],"sourcesContent":["// BERGET: upstream uses an intentional mutate-during-render streaming pattern\n// (see the init/render loop below); the React Compiler skips this file, which\n// is safe and expected. Keep this minimal when replaying upstream updates.\n/* eslint-disable react-hooks/preserve-manual-memoization */\nimport * as React from 'react';\n\nimport { loadHighlighter } from '@/lib/highlighter';\n\nexport function useHighlightedCode(value: string, language: string) {\n // A trailing newline would render as an extra empty line.\n const code = value.endsWith('\\n') ? value.slice(0, -1) : value;\n const [loaded, setLoaded] = React.useState<{\n language: string;\n highlighter: Awaited<ReturnType<typeof loadHighlighter>>;\n } | null>(null);\n const highlighter = loaded?.language === language ? loaded.highlighter : null;\n\n React.useEffect(() => {\n let cancelled = false;\n\n loadHighlighter(language)\n .then((next) => {\n if (!cancelled) {\n setLoaded({ language, highlighter: next });\n }\n })\n .catch(() => {});\n\n return () => {\n cancelled = true;\n };\n }, [language]);\n\n // The complete lines, highlighted. While the code streams, only the new\n // lines are tokenized, starting from the grammar state of the last one.\n const [done, setDone] = React.useState<{\n highlighter: typeof highlighter;\n text: string;\n lines: React.ReactNode[];\n state?: Parameters<NonNullable<typeof highlighter>['highlight']>[1];\n }>({ highlighter: null, text: '', lines: [] });\n\n let next = done;\n\n if (next.highlighter !== highlighter || !code.startsWith(next.text)) {\n next = { highlighter, text: '', lines: [] };\n }\n\n const end = code.lastIndexOf('\\n') + 1;\n\n if (highlighter && end > next.text.length) {\n const result = highlighter.highlight(code.slice(next.text.length, end - 1), next.state);\n\n next = {\n highlighter,\n text: code.slice(0, end),\n lines: [...next.lines, ...result.lines],\n state: result.state,\n };\n }\n\n if (next !== done) {\n setDone(next);\n }\n\n // The last line is still being written, so it is tokenized on every render.\n const tail = code.slice(end);\n\n return React.useMemo(() => {\n if (!highlighter) {\n return code.split('\\n');\n }\n\n return [...next.lines, highlighter.highlight(tail, next.state).lines[0]];\n }, [code, highlighter, next, tail]);\n}\n"],"mappings":";;;AAQA,SAAgB,mBAAmB,OAAe,UAAkB;CAElE,MAAM,OAAO,MAAM,SAAS,IAAI,IAAI,MAAM,MAAM,GAAG,EAAE,IAAI;CACzD,MAAM,CAAC,QAAQ,aAAa,MAAM,SAGxB,IAAI;CACd,MAAM,cAAc,QAAQ,aAAa,WAAW,OAAO,cAAc;CAEzE,MAAM,gBAAgB;EACpB,IAAI,YAAY;EAEhB,gBAAgB,QAAQ,CAAC,CACtB,MAAM,SAAS;GACd,IAAI,CAAC,WACH,UAAU;IAAE;IAAU,aAAa;GAAK,CAAC;EAE7C,CAAC,CAAC,CACD,YAAY,CAAC,CAAC;EAEjB,aAAa;GACX,YAAY;EACd;CACF,GAAG,CAAC,QAAQ,CAAC;CAIb,MAAM,CAAC,MAAM,WAAW,MAAM,SAK3B;EAAE,aAAa;EAAM,MAAM;EAAI,OAAO,CAAC;CAAE,CAAC;CAE7C,IAAI,OAAO;CAEX,IAAI,KAAK,gBAAgB,eAAe,CAAC,KAAK,WAAW,KAAK,IAAI,GAChE,OAAO;EAAE;EAAa,MAAM;EAAI,OAAO,CAAC;CAAE;CAG5C,MAAM,MAAM,KAAK,YAAY,IAAI,IAAI;CAErC,IAAI,eAAe,MAAM,KAAK,KAAK,QAAQ;EACzC,MAAM,SAAS,YAAY,UAAU,KAAK,MAAM,KAAK,KAAK,QAAQ,MAAM,CAAC,GAAG,KAAK,KAAK;EAEtF,OAAO;GACL;GACA,MAAM,KAAK,MAAM,GAAG,GAAG;GACvB,OAAO,CAAC,GAAG,KAAK,OAAO,GAAG,OAAO,KAAK;GACtC,OAAO,OAAO;EAChB;CACF;CAEA,IAAI,SAAS,MACX,QAAQ,IAAI;CAId,MAAM,OAAO,KAAK,MAAM,GAAG;CAE3B,OAAO,MAAM,cAAc;EACzB,IAAI,CAAC,aACH,OAAO,KAAK,MAAM,IAAI;EAGxB,OAAO,CAAC,GAAG,KAAK,OAAO,YAAY,UAAU,MAAM,KAAK,KAAK,CAAC,CAAC,MAAM,EAAE;CACzE,GAAG;EAAC;EAAM;EAAa;EAAM;CAAI,CAAC;AACpC"}
|
package/dist/index.cjs
CHANGED
|
@@ -3,6 +3,11 @@ const require_ThemeProvider = require("./components/theme-provider/ThemeProvider
|
|
|
3
3
|
const require_ThemeToggle = require("./components/theme-provider/ThemeToggle.cjs");
|
|
4
4
|
const require_button = require("./primitives/button.cjs");
|
|
5
5
|
const require_Button = require("./components/button/Button.cjs");
|
|
6
|
+
const require_anchorVariants = require("./components/button/anchorVariants.cjs");
|
|
7
|
+
const require_popover = require("./primitives/popover.cjs");
|
|
8
|
+
const require_combobox = require("./primitives/combobox.cjs");
|
|
9
|
+
const require_radio_group = require("./primitives/radio-group.cjs");
|
|
10
|
+
const require_Tabs = require("./components/tabs/Tabs.cjs");
|
|
6
11
|
const require_bubble = require("./primitives/bubble.cjs");
|
|
7
12
|
const require_message = require("./primitives/message.cjs");
|
|
8
13
|
const require_message_scroller = require("./primitives/message-scroller.cjs");
|
|
@@ -53,7 +58,9 @@ const require_Grid = require("./components/grid/Grid.cjs");
|
|
|
53
58
|
const require_Box = require("./components/box/Box.cjs");
|
|
54
59
|
const require_LanguageSelect = require("./components/language-select/LanguageSelect.cjs");
|
|
55
60
|
const require_List = require("./components/list/List.cjs");
|
|
61
|
+
const require_code_block = require("./primitives/code-block.cjs");
|
|
56
62
|
const require_CodeBlock = require("./components/code-block/CodeBlock.cjs");
|
|
63
|
+
const require_use_highlighted_code = require("./hooks/use-highlighted-code.cjs");
|
|
57
64
|
const require_WindowFrame = require("./components/window-frame/WindowFrame.cjs");
|
|
58
65
|
const require_FogIllustration = require("./components/fog-illustration/FogIllustration.cjs");
|
|
59
66
|
let _shadcn_react_message_scroller = require("@shadcn/react/message-scroller");
|
|
@@ -71,6 +78,7 @@ exports.AlertDialogPortal = require_AlertDialog.AlertDialogPortal;
|
|
|
71
78
|
exports.AlertDialogTitle = require_AlertDialog.AlertDialogTitle;
|
|
72
79
|
exports.AlertDialogTrigger = require_AlertDialog.AlertDialogTrigger;
|
|
73
80
|
exports.AlertTitle = require_alert.AlertTitle;
|
|
81
|
+
exports.Anchor = require_anchorVariants.Anchor;
|
|
74
82
|
exports.Badge = require_Badge.Badge;
|
|
75
83
|
exports.BergetLogo = require_BergetLogo.BergetLogo;
|
|
76
84
|
exports.Box = require_Box.Box;
|
|
@@ -89,6 +97,26 @@ exports.CardHeader = require_card.CardHeader;
|
|
|
89
97
|
exports.CardTitle = require_card.CardTitle;
|
|
90
98
|
exports.Checkbox = require_Checkbox.Checkbox;
|
|
91
99
|
exports.CodeBlock = require_CodeBlock.CodeBlock;
|
|
100
|
+
exports.CodeBlockActions = require_code_block.CodeBlockActions;
|
|
101
|
+
exports.CodeBlockContent = require_code_block.CodeBlockContent;
|
|
102
|
+
exports.CodeBlockCopyButton = require_code_block.CodeBlockCopyButton;
|
|
103
|
+
exports.CodeBlockFooter = require_code_block.CodeBlockFooter;
|
|
104
|
+
exports.CodeBlockHeader = require_CodeBlock.CodeBlockHeader;
|
|
105
|
+
exports.CodeBlockLine = require_code_block.CodeBlockLine;
|
|
106
|
+
exports.CodeBlockTitle = require_CodeBlock.CodeBlockTitle;
|
|
107
|
+
exports.Combobox = require_combobox.Combobox;
|
|
108
|
+
exports.ComboboxClear = require_combobox.ComboboxClear;
|
|
109
|
+
exports.ComboboxContent = require_combobox.ComboboxContent;
|
|
110
|
+
exports.ComboboxEmpty = require_combobox.ComboboxEmpty;
|
|
111
|
+
exports.ComboboxGroup = require_combobox.ComboboxGroup;
|
|
112
|
+
exports.ComboboxGroupLabel = require_combobox.ComboboxGroupLabel;
|
|
113
|
+
exports.ComboboxInput = require_combobox.ComboboxInput;
|
|
114
|
+
exports.ComboboxItem = require_combobox.ComboboxItem;
|
|
115
|
+
exports.ComboboxList = require_combobox.ComboboxList;
|
|
116
|
+
exports.ComboboxSeparator = require_combobox.ComboboxSeparator;
|
|
117
|
+
exports.ComboboxStatus = require_combobox.ComboboxStatus;
|
|
118
|
+
exports.ComboboxTrigger = require_combobox.ComboboxTrigger;
|
|
119
|
+
exports.ComboboxValue = require_combobox.ComboboxValue;
|
|
92
120
|
exports.Container = require_Container.Container;
|
|
93
121
|
exports.CountrySelect = require_CountrySelect.CountrySelect;
|
|
94
122
|
exports.Dialog = require_Dialog.Dialog;
|
|
@@ -183,11 +211,19 @@ exports.NavigationMenuLink = require_NavigationMenu.NavigationMenuLink;
|
|
|
183
211
|
exports.NavigationMenuList = require_navigation_menu.NavigationMenuList;
|
|
184
212
|
exports.NavigationMenuPositioner = require_NavigationMenu.NavigationMenuPositioner;
|
|
185
213
|
exports.NavigationMenuTrigger = require_NavigationMenu.NavigationMenuTrigger;
|
|
214
|
+
exports.Popover = require_popover.Popover;
|
|
215
|
+
exports.PopoverContent = require_popover.PopoverContent;
|
|
216
|
+
exports.PopoverDescription = require_popover.PopoverDescription;
|
|
217
|
+
exports.PopoverHeader = require_popover.PopoverHeader;
|
|
218
|
+
exports.PopoverTitle = require_popover.PopoverTitle;
|
|
219
|
+
exports.PopoverTrigger = require_popover.PopoverTrigger;
|
|
186
220
|
exports.Progress = require_Progress.Progress;
|
|
187
221
|
exports.ProgressIndicator = require_progress.ProgressIndicator;
|
|
188
222
|
exports.ProgressLabel = require_progress.ProgressLabel;
|
|
189
223
|
exports.ProgressTrack = require_progress.ProgressTrack;
|
|
190
224
|
exports.ProgressValue = require_progress.ProgressValue;
|
|
225
|
+
exports.RadioGroup = require_radio_group.RadioGroup;
|
|
226
|
+
exports.RadioGroupItem = require_radio_group.RadioGroupItem;
|
|
191
227
|
exports.SearchInput = require_SearchInput.SearchInput;
|
|
192
228
|
exports.Select = require_select.Select;
|
|
193
229
|
exports.SelectContent = require_select.SelectContent;
|
|
@@ -235,6 +271,10 @@ exports.TableFooter = require_Table.TableFooter;
|
|
|
235
271
|
exports.TableHead = require_Table.TableHead;
|
|
236
272
|
exports.TableHeader = require_Table.TableHeader;
|
|
237
273
|
exports.TableRow = require_Table.TableRow;
|
|
274
|
+
exports.Tabs = require_Tabs.Tabs;
|
|
275
|
+
exports.TabsContent = require_Tabs.TabsContent;
|
|
276
|
+
exports.TabsList = require_Tabs.TabsList;
|
|
277
|
+
exports.TabsTrigger = require_Tabs.TabsTrigger;
|
|
238
278
|
exports.Textarea = require_textarea.Textarea;
|
|
239
279
|
exports.ThemeProvider = require_ThemeProvider.ThemeProvider;
|
|
240
280
|
exports.ThemeToggle = require_ThemeToggle.ThemeToggle;
|
|
@@ -245,6 +285,7 @@ exports.TooltipTrigger = require_Tooltip.TooltipTrigger;
|
|
|
245
285
|
exports.Typography = require_Typography.Typography;
|
|
246
286
|
exports.WindowFrame = require_WindowFrame.WindowFrame;
|
|
247
287
|
exports.alertVariants = require_Alert.alertVariants;
|
|
288
|
+
exports.anchorVariants = require_anchorVariants.anchorVariants;
|
|
248
289
|
exports.badgeVariants = require_Badge.badgeVariants;
|
|
249
290
|
exports.boxVariants = require_Box.boxVariants;
|
|
250
291
|
exports.buttonVariants = require_button.buttonVariants;
|
|
@@ -260,7 +301,10 @@ exports.linkVariants = require_Link.linkVariants;
|
|
|
260
301
|
exports.navigationMenuTriggerStyle = require_NavigationMenu.navigationMenuTriggerStyle;
|
|
261
302
|
exports.switchRootVariants = require_Switch.switchRootVariants;
|
|
262
303
|
exports.switchThumbVariants = require_Switch.switchThumbVariants;
|
|
304
|
+
exports.tabsListVariants = require_Tabs.tabsListVariants;
|
|
305
|
+
exports.tabsTriggerVariants = require_Tabs.tabsTriggerVariants;
|
|
263
306
|
exports.typographyVariants = require_Typography.typographyVariants;
|
|
307
|
+
exports.useHighlightedCode = require_use_highlighted_code.useHighlightedCode;
|
|
264
308
|
Object.defineProperty(exports, "useMessageScroller", {
|
|
265
309
|
enumerable: true,
|
|
266
310
|
get: function() {
|
package/dist/index.d.cts
CHANGED
|
@@ -3,7 +3,16 @@ import { ThemeToggle, ThemeToggleProps } from "./components/theme-provider/Theme
|
|
|
3
3
|
import "./components/theme-provider/index.cjs";
|
|
4
4
|
import { buttonVariants } from "./primitives/button.cjs";
|
|
5
5
|
import { Button, ButtonProps } from "./components/button/Button.cjs";
|
|
6
|
+
import { Anchor, AnchorProps, AnchorVariantsProps, anchorVariants } from "./components/button/anchorVariants.cjs";
|
|
6
7
|
import "./components/button/index.cjs";
|
|
8
|
+
import { Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger } from "./primitives/popover.cjs";
|
|
9
|
+
import "./components/popover/index.cjs";
|
|
10
|
+
import { Combobox, ComboboxClear, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxGroupLabel, ComboboxInput, ComboboxItem, ComboboxList, ComboboxSeparator, ComboboxStatus, ComboboxTrigger, ComboboxValue } from "./primitives/combobox.cjs";
|
|
11
|
+
import "./components/combobox/index.cjs";
|
|
12
|
+
import { RadioGroup, RadioGroupItem } from "./primitives/radio-group.cjs";
|
|
13
|
+
import "./components/radio-group/index.cjs";
|
|
14
|
+
import { Tabs, TabsContent, TabsList, TabsTrigger, tabsListVariants, tabsTriggerVariants } from "./components/tabs/Tabs.cjs";
|
|
15
|
+
import "./components/tabs/index.cjs";
|
|
7
16
|
import { Bubble, BubbleContent, BubbleGroup, BubbleReactions } from "./primitives/bubble.cjs";
|
|
8
17
|
import "./components/bubble/index.cjs";
|
|
9
18
|
import { Message, MessageAvatar, MessageContent, MessageFooter, MessageGroup, MessageHeader } from "./primitives/message.cjs";
|
|
@@ -93,9 +102,12 @@ import { LanguageSelect, LanguageSelectOption, LanguageSelectProps } from "./com
|
|
|
93
102
|
import "./components/language-select/index.cjs";
|
|
94
103
|
import { FeatureList, FeatureListProps, List, ListHeader, ListHeaderProps, ListItem, ListItemProps, ListProps } from "./components/list/List.cjs";
|
|
95
104
|
import "./components/list/index.cjs";
|
|
96
|
-
import {
|
|
105
|
+
import { CodeBlockActions, CodeBlockContent, CodeBlockCopyButton, CodeBlockFooter, CodeBlockLine } from "./primitives/code-block.cjs";
|
|
106
|
+
import { CodeBlock, CodeBlockHeader, CodeBlockTitle } from "./components/code-block/CodeBlock.cjs";
|
|
107
|
+
import "./components/code-block/index.cjs";
|
|
108
|
+
import { useHighlightedCode } from "./hooks/use-highlighted-code.cjs";
|
|
97
109
|
import { TerminalExample } from "./lib/terminal.cjs";
|
|
98
110
|
import { WindowFrame, WindowFrameProps, WindowTab } from "./components/window-frame/WindowFrame.cjs";
|
|
99
111
|
import "./components/window-frame/index.cjs";
|
|
100
112
|
import { FOG_BRAND_PALETTE, FogIllustration, FogIllustrationProps, FogPalette } from "./components/fog-illustration/FogIllustration.cjs";
|
|
101
|
-
export { Alert, AlertDescription, type AlertDescriptionProps, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, type AlertProps, AlertTitle, type AlertTitleProps, Badge, type BadgeProps, BergetLogo, type BergetLogoProps, Box, type BoxProps, type SpacingScale as BoxSpacingScale, Bubble, BubbleContent, BubbleGroup, BubbleReactions, Button, type ButtonProps, COUNTRIES, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, type CardProps, CardTitle, Checkbox, type CheckboxProps, CodeBlock,
|
|
113
|
+
export { Alert, AlertDescription, type AlertDescriptionProps, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, type AlertProps, AlertTitle, type AlertTitleProps, Anchor, type AnchorProps, type AnchorVariantsProps, Badge, type BadgeProps, BergetLogo, type BergetLogoProps, Box, type BoxProps, type SpacingScale as BoxSpacingScale, Bubble, BubbleContent, BubbleGroup, BubbleReactions, Button, type ButtonProps, COUNTRIES, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, type CardProps, CardTitle, Checkbox, type CheckboxProps, CodeBlock, CodeBlockActions, CodeBlockContent, CodeBlockCopyButton, CodeBlockFooter, CodeBlockHeader, CodeBlockLine, CodeBlockTitle, Combobox, ComboboxClear, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxGroupLabel, ComboboxInput, ComboboxItem, ComboboxList, ComboboxSeparator, ComboboxStatus, ComboboxTrigger, ComboboxValue, Container, type ContainerProps, type Country, CountrySelect, type CountrySelectProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EU_COUNTRY_CODES, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, type EmptyProps, EmptyTitle, FOG_BRAND_PALETTE, FeatureList, type FeatureListProps, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, FogIllustration, type FogIllustrationProps, type FogPalette, Grid, type GridColsScale, type GridProps, type GridRowsScale, type SpacingScale$1 as GridSpacingScale, Icon, type IconProps, Input, InputGroup, InputGroupAddon, type InputGroupAddonProps, InputGroupButton, InputGroupInput, type InputGroupProps, InputGroupText, InputGroupTextarea, Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, type ItemProps, ItemSeparator, ItemTitle, Label, LanguageSelect, type LanguageSelectOption, type LanguageSelectProps, Link, type LinkProps, List, ListHeader, type ListHeaderProps, ListItem, type ListItemProps, type ListProps, Message, MessageAvatar, MessageContent, MessageFooter, MessageGroup, MessageHeader, MessageScroller, MessageScrollerButton, MessageScrollerContent, MessageScrollerItem, MessageScrollerProvider, MessageScrollerViewport, ModelCard, type ModelCardProps, type ModelCategory, type ModelLifecycle, ModelLogo, type ModelLogoProps, type ModelLogoProvider, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuPositioner, NavigationMenuTrigger, Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, Progress, ProgressIndicator, ProgressLabel, type ProgressProps, ProgressTrack, ProgressValue, RadioGroup, RadioGroupItem, SearchInput, type SearchInputProps, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarLogo, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarPageHeader, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, type SkeletonProps, Slider, type SliderProps, Switch, type SwitchProps, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, type TerminalExample, Textarea, type Theme, ThemeProvider, type ThemeProviderProps, ThemeToggle, type ThemeToggleProps, Tooltip, TooltipContent, type TooltipContentProps, TooltipProvider, TooltipTrigger, type TooltipTriggerProps, Typography, type TypographyProps, WindowFrame, type WindowFrameProps, type WindowTab, alertVariants, anchorVariants, badgeVariants, boxVariants, buttonVariants, cardVariants, categoryLabels, checkboxVariants, containerVariants, getCountryByCode, getCountryByName, gridVariants, isEUCountry, linkVariants, navigationMenuTriggerStyle, switchRootVariants, switchThumbVariants, tabsListVariants, tabsTriggerVariants, typographyVariants, useHighlightedCode, useMessageScroller, useMessageScrollerScrollable, useMessageScrollerVisibility, useSidebar, useTheme };
|
package/dist/index.d.mts
CHANGED
|
@@ -3,7 +3,16 @@ import { ThemeToggle, ThemeToggleProps } from "./components/theme-provider/Theme
|
|
|
3
3
|
import "./components/theme-provider/index.mjs";
|
|
4
4
|
import { buttonVariants } from "./primitives/button.mjs";
|
|
5
5
|
import { Button, ButtonProps } from "./components/button/Button.mjs";
|
|
6
|
+
import { Anchor, AnchorProps, AnchorVariantsProps, anchorVariants } from "./components/button/anchorVariants.mjs";
|
|
6
7
|
import "./components/button/index.mjs";
|
|
8
|
+
import { Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger } from "./primitives/popover.mjs";
|
|
9
|
+
import "./components/popover/index.mjs";
|
|
10
|
+
import { Combobox, ComboboxClear, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxGroupLabel, ComboboxInput, ComboboxItem, ComboboxList, ComboboxSeparator, ComboboxStatus, ComboboxTrigger, ComboboxValue } from "./primitives/combobox.mjs";
|
|
11
|
+
import "./components/combobox/index.mjs";
|
|
12
|
+
import { RadioGroup, RadioGroupItem } from "./primitives/radio-group.mjs";
|
|
13
|
+
import "./components/radio-group/index.mjs";
|
|
14
|
+
import { Tabs, TabsContent, TabsList, TabsTrigger, tabsListVariants, tabsTriggerVariants } from "./components/tabs/Tabs.mjs";
|
|
15
|
+
import "./components/tabs/index.mjs";
|
|
7
16
|
import { Bubble, BubbleContent, BubbleGroup, BubbleReactions } from "./primitives/bubble.mjs";
|
|
8
17
|
import "./components/bubble/index.mjs";
|
|
9
18
|
import { Message, MessageAvatar, MessageContent, MessageFooter, MessageGroup, MessageHeader } from "./primitives/message.mjs";
|
|
@@ -93,9 +102,12 @@ import { LanguageSelect, LanguageSelectOption, LanguageSelectProps } from "./com
|
|
|
93
102
|
import "./components/language-select/index.mjs";
|
|
94
103
|
import { FeatureList, FeatureListProps, List, ListHeader, ListHeaderProps, ListItem, ListItemProps, ListProps } from "./components/list/List.mjs";
|
|
95
104
|
import "./components/list/index.mjs";
|
|
96
|
-
import {
|
|
105
|
+
import { CodeBlockActions, CodeBlockContent, CodeBlockCopyButton, CodeBlockFooter, CodeBlockLine } from "./primitives/code-block.mjs";
|
|
106
|
+
import { CodeBlock, CodeBlockHeader, CodeBlockTitle } from "./components/code-block/CodeBlock.mjs";
|
|
107
|
+
import "./components/code-block/index.mjs";
|
|
108
|
+
import { useHighlightedCode } from "./hooks/use-highlighted-code.mjs";
|
|
97
109
|
import { TerminalExample } from "./lib/terminal.mjs";
|
|
98
110
|
import { WindowFrame, WindowFrameProps, WindowTab } from "./components/window-frame/WindowFrame.mjs";
|
|
99
111
|
import "./components/window-frame/index.mjs";
|
|
100
112
|
import { FOG_BRAND_PALETTE, FogIllustration, FogIllustrationProps, FogPalette } from "./components/fog-illustration/FogIllustration.mjs";
|
|
101
|
-
export { Alert, AlertDescription, type AlertDescriptionProps, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, type AlertProps, AlertTitle, type AlertTitleProps, Badge, type BadgeProps, BergetLogo, type BergetLogoProps, Box, type BoxProps, type SpacingScale as BoxSpacingScale, Bubble, BubbleContent, BubbleGroup, BubbleReactions, Button, type ButtonProps, COUNTRIES, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, type CardProps, CardTitle, Checkbox, type CheckboxProps, CodeBlock,
|
|
113
|
+
export { Alert, AlertDescription, type AlertDescriptionProps, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, type AlertProps, AlertTitle, type AlertTitleProps, Anchor, type AnchorProps, type AnchorVariantsProps, Badge, type BadgeProps, BergetLogo, type BergetLogoProps, Box, type BoxProps, type SpacingScale as BoxSpacingScale, Bubble, BubbleContent, BubbleGroup, BubbleReactions, Button, type ButtonProps, COUNTRIES, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, type CardProps, CardTitle, Checkbox, type CheckboxProps, CodeBlock, CodeBlockActions, CodeBlockContent, CodeBlockCopyButton, CodeBlockFooter, CodeBlockHeader, CodeBlockLine, CodeBlockTitle, Combobox, ComboboxClear, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxGroupLabel, ComboboxInput, ComboboxItem, ComboboxList, ComboboxSeparator, ComboboxStatus, ComboboxTrigger, ComboboxValue, Container, type ContainerProps, type Country, CountrySelect, type CountrySelectProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EU_COUNTRY_CODES, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, type EmptyProps, EmptyTitle, FOG_BRAND_PALETTE, FeatureList, type FeatureListProps, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, FogIllustration, type FogIllustrationProps, type FogPalette, Grid, type GridColsScale, type GridProps, type GridRowsScale, type SpacingScale$1 as GridSpacingScale, Icon, type IconProps, Input, InputGroup, InputGroupAddon, type InputGroupAddonProps, InputGroupButton, InputGroupInput, type InputGroupProps, InputGroupText, InputGroupTextarea, Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, type ItemProps, ItemSeparator, ItemTitle, Label, LanguageSelect, type LanguageSelectOption, type LanguageSelectProps, Link, type LinkProps, List, ListHeader, type ListHeaderProps, ListItem, type ListItemProps, type ListProps, Message, MessageAvatar, MessageContent, MessageFooter, MessageGroup, MessageHeader, MessageScroller, MessageScrollerButton, MessageScrollerContent, MessageScrollerItem, MessageScrollerProvider, MessageScrollerViewport, ModelCard, type ModelCardProps, type ModelCategory, type ModelLifecycle, ModelLogo, type ModelLogoProps, type ModelLogoProvider, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuPositioner, NavigationMenuTrigger, Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, Progress, ProgressIndicator, ProgressLabel, type ProgressProps, ProgressTrack, ProgressValue, RadioGroup, RadioGroupItem, SearchInput, type SearchInputProps, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarLogo, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarPageHeader, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, type SkeletonProps, Slider, type SliderProps, Switch, type SwitchProps, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, type TerminalExample, Textarea, type Theme, ThemeProvider, type ThemeProviderProps, ThemeToggle, type ThemeToggleProps, Tooltip, TooltipContent, type TooltipContentProps, TooltipProvider, TooltipTrigger, type TooltipTriggerProps, Typography, type TypographyProps, WindowFrame, type WindowFrameProps, type WindowTab, alertVariants, anchorVariants, badgeVariants, boxVariants, buttonVariants, cardVariants, categoryLabels, checkboxVariants, containerVariants, getCountryByCode, getCountryByName, gridVariants, isEUCountry, linkVariants, navigationMenuTriggerStyle, switchRootVariants, switchThumbVariants, tabsListVariants, tabsTriggerVariants, typographyVariants, useHighlightedCode, useMessageScroller, useMessageScrollerScrollable, useMessageScrollerVisibility, useSidebar, useTheme };
|
package/dist/index.mjs
CHANGED
|
@@ -2,6 +2,11 @@ import { ThemeProvider, useTheme } from "./components/theme-provider/ThemeProvid
|
|
|
2
2
|
import { ThemeToggle } from "./components/theme-provider/ThemeToggle.mjs";
|
|
3
3
|
import { buttonVariants } from "./primitives/button.mjs";
|
|
4
4
|
import { Button } from "./components/button/Button.mjs";
|
|
5
|
+
import { Anchor, anchorVariants } from "./components/button/anchorVariants.mjs";
|
|
6
|
+
import { Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger } from "./primitives/popover.mjs";
|
|
7
|
+
import { Combobox, ComboboxClear, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxGroupLabel, ComboboxInput, ComboboxItem, ComboboxList, ComboboxSeparator, ComboboxStatus, ComboboxTrigger, ComboboxValue } from "./primitives/combobox.mjs";
|
|
8
|
+
import { RadioGroup, RadioGroupItem } from "./primitives/radio-group.mjs";
|
|
9
|
+
import { Tabs, TabsContent, TabsList, TabsTrigger, tabsListVariants, tabsTriggerVariants } from "./components/tabs/Tabs.mjs";
|
|
5
10
|
import { Bubble, BubbleContent, BubbleGroup, BubbleReactions } from "./primitives/bubble.mjs";
|
|
6
11
|
import { Message, MessageAvatar, MessageContent, MessageFooter, MessageGroup, MessageHeader } from "./primitives/message.mjs";
|
|
7
12
|
import { MessageScroller, MessageScrollerButton, MessageScrollerContent, MessageScrollerItem, MessageScrollerProvider, MessageScrollerViewport, useMessageScroller, useMessageScrollerScrollable, useMessageScrollerVisibility } from "./primitives/message-scroller.mjs";
|
|
@@ -52,7 +57,9 @@ import { Grid, gridVariants } from "./components/grid/Grid.mjs";
|
|
|
52
57
|
import { Box, boxVariants } from "./components/box/Box.mjs";
|
|
53
58
|
import { LanguageSelect } from "./components/language-select/LanguageSelect.mjs";
|
|
54
59
|
import { FeatureList, List, ListHeader, ListItem } from "./components/list/List.mjs";
|
|
55
|
-
import {
|
|
60
|
+
import { CodeBlockActions, CodeBlockContent, CodeBlockCopyButton, CodeBlockFooter, CodeBlockLine } from "./primitives/code-block.mjs";
|
|
61
|
+
import { CodeBlock, CodeBlockHeader, CodeBlockTitle } from "./components/code-block/CodeBlock.mjs";
|
|
62
|
+
import { useHighlightedCode } from "./hooks/use-highlighted-code.mjs";
|
|
56
63
|
import { WindowFrame } from "./components/window-frame/WindowFrame.mjs";
|
|
57
64
|
import { FOG_BRAND_PALETTE, FogIllustration } from "./components/fog-illustration/FogIllustration.mjs";
|
|
58
|
-
export { Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, Badge, BergetLogo, Box, Bubble, BubbleContent, BubbleGroup, BubbleReactions, Button, COUNTRIES, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Checkbox, CodeBlock, Container, CountrySelect, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EU_COUNTRY_CODES, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle, FOG_BRAND_PALETTE, FeatureList, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, FogIllustration, Grid, Icon, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle, Label, LanguageSelect, Link, List, ListHeader, ListItem, Message, MessageAvatar, MessageContent, MessageFooter, MessageGroup, MessageHeader, MessageScroller, MessageScrollerButton, MessageScrollerContent, MessageScrollerItem, MessageScrollerProvider, MessageScrollerViewport, ModelCard, ModelLogo, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuPositioner, NavigationMenuTrigger, Progress, ProgressIndicator, ProgressLabel, ProgressTrack, ProgressValue, SearchInput, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarLogo, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarPageHeader, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, Slider, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Textarea, ThemeProvider, ThemeToggle, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, Typography, WindowFrame, alertVariants, badgeVariants, boxVariants, buttonVariants, cardVariants, categoryLabels, checkboxVariants, containerVariants, getCountryByCode, getCountryByName, gridVariants, isEUCountry, linkVariants, navigationMenuTriggerStyle, switchRootVariants, switchThumbVariants, typographyVariants, useMessageScroller, useMessageScrollerScrollable, useMessageScrollerVisibility, useSidebar, useTheme };
|
|
65
|
+
export { Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, Anchor, Badge, BergetLogo, Box, Bubble, BubbleContent, BubbleGroup, BubbleReactions, Button, COUNTRIES, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Checkbox, CodeBlock, CodeBlockActions, CodeBlockContent, CodeBlockCopyButton, CodeBlockFooter, CodeBlockHeader, CodeBlockLine, CodeBlockTitle, Combobox, ComboboxClear, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxGroupLabel, ComboboxInput, ComboboxItem, ComboboxList, ComboboxSeparator, ComboboxStatus, ComboboxTrigger, ComboboxValue, Container, CountrySelect, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, EU_COUNTRY_CODES, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle, FOG_BRAND_PALETTE, FeatureList, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, FogIllustration, Grid, Icon, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle, Label, LanguageSelect, Link, List, ListHeader, ListItem, Message, MessageAvatar, MessageContent, MessageFooter, MessageGroup, MessageHeader, MessageScroller, MessageScrollerButton, MessageScrollerContent, MessageScrollerItem, MessageScrollerProvider, MessageScrollerViewport, ModelCard, ModelLogo, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuPositioner, NavigationMenuTrigger, Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, Progress, ProgressIndicator, ProgressLabel, ProgressTrack, ProgressValue, RadioGroup, RadioGroupItem, SearchInput, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarLogo, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarPageHeader, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, Slider, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, ThemeProvider, ThemeToggle, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, Typography, WindowFrame, alertVariants, anchorVariants, badgeVariants, boxVariants, buttonVariants, cardVariants, categoryLabels, checkboxVariants, containerVariants, getCountryByCode, getCountryByName, gridVariants, isEUCountry, linkVariants, navigationMenuTriggerStyle, switchRootVariants, switchThumbVariants, tabsListVariants, tabsTriggerVariants, typographyVariants, useHighlightedCode, useMessageScroller, useMessageScrollerScrollable, useMessageScrollerVisibility, useSidebar, useTheme };
|