@clickhouse/click-ui 0.0.41 → 0.0.42
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/click-ui.es.js +4075 -4025
- package/dist/click-ui.umd.js +94 -95
- package/dist/components/ButtonGroup/ButtonGroup.d.ts +1 -0
- package/dist/components/CodeBlock/CodeBlock.d.ts +4 -2
- package/dist/components/EllipsisContent/EllipsisContent.d.ts +5 -2
- package/dist/components/Flyout/Flyout.d.ts +19 -8
- package/dist/components/Link/Link.d.ts +1 -1
- package/dist/components/Select/common/InternalSelect.d.ts +1 -1
- package/dist/components/Select/common/types.d.ts +1 -0
- package/dist/components/Typography/Text/Text.d.ts +2 -0
- package/dist/components/Typography/Title/Title.d.ts +1 -1
- package/dist/styles/types.d.ts +4 -0
- package/dist/styles/variables.classic.json.d.ts +6 -2
- package/dist/styles/variables.dark.json.d.ts +7 -3
- package/dist/styles/variables.json.d.ts +6 -2
- package/dist/styles/variables.light.json.d.ts +6 -2
- package/package.json +1 -1
|
@@ -2,6 +2,7 @@ import { HTMLAttributes, ReactNode } from "react";
|
|
|
2
2
|
export interface ButtonGroupElementProps extends Omit<HTMLAttributes<HTMLButtonElement>, "children"> {
|
|
3
3
|
value: string;
|
|
4
4
|
label?: ReactNode;
|
|
5
|
+
fillWidth?: boolean;
|
|
5
6
|
}
|
|
6
7
|
export interface ButtonGroupProps extends Omit<HTMLAttributes<HTMLDivElement>, "onClick"> {
|
|
7
8
|
options: Array<ButtonGroupElementProps>;
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import { HTMLAttributes } from "react";
|
|
2
2
|
export type CodeThemeType = "light" | "dark";
|
|
3
|
-
interface Props extends Omit<HTMLAttributes<HTMLDivElement>, "children"> {
|
|
3
|
+
interface Props extends Omit<HTMLAttributes<HTMLDivElement>, "children" | "onCopy"> {
|
|
4
4
|
language?: string;
|
|
5
5
|
children: string;
|
|
6
6
|
theme?: CodeThemeType;
|
|
7
7
|
showLineNumbers?: boolean;
|
|
8
8
|
showWrapButton?: boolean;
|
|
9
9
|
wrapLines?: boolean;
|
|
10
|
+
onCopy?: (value: string) => void | Promise<void>;
|
|
11
|
+
onCopyError?: (error: string) => void | Promise<void>;
|
|
10
12
|
}
|
|
11
|
-
export declare const CodeBlock: ({ children, language, theme, showLineNumbers, showWrapButton, wrapLines, ...props }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export declare const CodeBlock: ({ children, language, theme, showLineNumbers, showWrapButton, wrapLines, onCopy, onCopyError, ...props }: Props) => import("react/jsx-runtime").JSX.Element;
|
|
12
14
|
export {};
|
|
@@ -1,2 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export
|
|
1
|
+
import { ElementType } from "react";
|
|
2
|
+
export interface EllipsisContentProps<T extends ElementType> {
|
|
3
|
+
component?: T;
|
|
4
|
+
}
|
|
5
|
+
export declare const EllipsisContent: import("react").ForwardRefExoticComponent<Omit<EllipsisContentProps<ElementType> & Omit<any, "ref">, "ref"> & import("react").RefAttributes<unknown>>;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { HTMLAttributes } from "react";
|
|
1
|
+
import { HTMLAttributes, ReactNode } from "react";
|
|
2
2
|
import { DialogProps, DialogTriggerProps, DialogContentProps as RadixDialogContentProps } from "@radix-ui/react-dialog";
|
|
3
|
+
import { ButtonProps } from "..";
|
|
3
4
|
export type FlyoutProps = DialogProps;
|
|
4
5
|
export declare const Flyout: {
|
|
5
|
-
(props: FlyoutProps): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
({ modal, ...props }: FlyoutProps): import("react/jsx-runtime").JSX.Element;
|
|
6
7
|
Trigger: {
|
|
7
8
|
({ children, ...props }: DialogTriggerProps): import("react/jsx-runtime").JSX.Element;
|
|
8
9
|
displayName: string;
|
|
@@ -20,15 +21,21 @@ export declare const Flyout: {
|
|
|
20
21
|
displayName: string;
|
|
21
22
|
};
|
|
22
23
|
Body: {
|
|
23
|
-
(props:
|
|
24
|
+
({ align, ...props }: BodyProps): import("react/jsx-runtime").JSX.Element;
|
|
25
|
+
displayName: string;
|
|
26
|
+
};
|
|
27
|
+
Close: {
|
|
28
|
+
({ children, ...props }: FlyoutButtonProps | {
|
|
29
|
+
children?: ReactNode;
|
|
30
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
24
31
|
displayName: string;
|
|
25
32
|
};
|
|
26
33
|
Footer: {
|
|
27
|
-
(
|
|
34
|
+
(props: FlyoutFooterProps): import("react/jsx-runtime").JSX.Element;
|
|
28
35
|
displayName: string;
|
|
29
36
|
};
|
|
30
37
|
};
|
|
31
|
-
type FlyoutSizeType = "narrow" | "wide";
|
|
38
|
+
type FlyoutSizeType = "default" | "narrow" | "wide";
|
|
32
39
|
type Strategy = "relative" | "absolute" | "fixed";
|
|
33
40
|
export interface DialogContentProps extends RadixDialogContentProps {
|
|
34
41
|
container?: HTMLElement | null;
|
|
@@ -48,8 +55,12 @@ interface ChildrenHeaderProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
48
55
|
description?: never;
|
|
49
56
|
}
|
|
50
57
|
export type FlyoutHeaderProps = TitleHeaderProps | ChildrenHeaderProps;
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
58
|
+
type FlyoutAlign = "default" | "top";
|
|
59
|
+
interface BodyProps extends HTMLAttributes<HTMLDivElement> {
|
|
60
|
+
align?: FlyoutAlign;
|
|
61
|
+
}
|
|
62
|
+
export type FlyoutFooterProps = HTMLAttributes<HTMLDivElement>;
|
|
63
|
+
interface FlyoutButtonProps extends Omit<ButtonProps, "children"> {
|
|
64
|
+
children?: never;
|
|
54
65
|
}
|
|
55
66
|
export {};
|
|
@@ -14,5 +14,5 @@ export interface LinkProps<T extends ElementType> {
|
|
|
14
14
|
component?: T;
|
|
15
15
|
}
|
|
16
16
|
/** Component for linking to other pages or sections from with body text */
|
|
17
|
-
export declare const Link: <T extends ElementType
|
|
17
|
+
export declare const Link: <T extends ElementType = "a">({ size, weight, className, href, onClick, target, rel, hasIcon, children, component, ...props }: LinkProps<T> & ComponentPropsWithoutRef<T>) => import("react/jsx-runtime").JSX.Element;
|
|
18
18
|
export {};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { SelectContainerProps, SelectGroupProps, SelectItemProps } from "./types";
|
|
3
|
-
export declare const InternalSelect: ({ label, children, orientation, dir, disabled, id, error, value: selectedValues, onChange, onSelect, open, onOpenChange, name, form, onCreateOption: onCreateOptionProp, customText, options, showCheck, sortable, placeholder, multiple, showSearch, ...props }: SelectContainerProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
export declare const InternalSelect: ({ label, children, orientation, dir, disabled, id, error, value: selectedValues, onChange, onSelect, open, onOpenChange, name, form, onCreateOption: onCreateOptionProp, customText, options, showCheck, sortable, placeholder, multiple, showSearch, container, ...props }: SelectContainerProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
4
|
export declare const SelectGroup: import("react").ForwardRefExoticComponent<SelectGroupProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
5
5
|
export declare const SelectItem: import("react").ForwardRefExoticComponent<SelectItemProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -62,6 +62,7 @@ interface InternalSelectProps extends PopoverProps, Omit<HTMLAttributes<HTMLDivE
|
|
|
62
62
|
multiple?: boolean;
|
|
63
63
|
showSearch?: boolean;
|
|
64
64
|
customText?: string;
|
|
65
|
+
container?: HTMLElement;
|
|
65
66
|
}
|
|
66
67
|
export type SelectOptionProp = SelectOptionType | SelectChildrenType;
|
|
67
68
|
export type SelectContainerProps = SelectOptionProp & InternalSelectProps;
|
|
@@ -279,5 +279,7 @@ declare const Text: import("styled-components").IStyledComponent<"web", {
|
|
|
279
279
|
onAnimationIterationCapture?: import("react").AnimationEventHandler<HTMLParagraphElement> | undefined;
|
|
280
280
|
onTransitionEnd?: import("react").TransitionEventHandler<HTMLParagraphElement> | undefined;
|
|
281
281
|
onTransitionEndCapture?: import("react").TransitionEventHandler<HTMLParagraphElement> | undefined;
|
|
282
|
+
ref?: import("react").Ref<HTMLParagraphElement> | undefined;
|
|
283
|
+
key?: import("react").Key | null | undefined;
|
|
282
284
|
}>;
|
|
283
285
|
export { Text };
|
|
@@ -10,4 +10,4 @@ export interface TitleProps extends HTMLAttributes<HTMLHeadingElement> {
|
|
|
10
10
|
type: TitleType;
|
|
11
11
|
}
|
|
12
12
|
/** The `title` component allows you to easily add headings to your pages. They do not include built in margins. */
|
|
13
|
-
export declare const Title: (
|
|
13
|
+
export declare const Title: import("react").ForwardRefExoticComponent<TitleProps & import("react").RefAttributes<HTMLHeadingElement>>;
|
package/dist/styles/types.d.ts
CHANGED
|
@@ -604,11 +604,15 @@ export interface Theme {
|
|
|
604
604
|
"hover": string;
|
|
605
605
|
"active": string;
|
|
606
606
|
"panel": string;
|
|
607
|
+
"disabled": string;
|
|
608
|
+
"disabled-active": string;
|
|
607
609
|
};
|
|
608
610
|
"text": {
|
|
609
611
|
"default": string;
|
|
610
612
|
"hover": string;
|
|
611
613
|
"active": string;
|
|
614
|
+
"disabled": string;
|
|
615
|
+
"disabled-active": string;
|
|
612
616
|
};
|
|
613
617
|
"stroke": {
|
|
614
618
|
"panel": string;
|
|
@@ -222,12 +222,16 @@ declare const _default: {
|
|
|
222
222
|
"default": "lch(100 0 0)",
|
|
223
223
|
"hover": "lch(97.4 1.44 272)",
|
|
224
224
|
"active": "lch(95.3 1.54 272)",
|
|
225
|
-
"panel": "lch(100 0 0)"
|
|
225
|
+
"panel": "lch(100 0 0)",
|
|
226
|
+
"disabled": "#dfdfdf",
|
|
227
|
+
"disabled-active": "lch(97.9 0 0)"
|
|
226
228
|
},
|
|
227
229
|
"text": {
|
|
228
230
|
"default": "#161517",
|
|
229
231
|
"hover": "#161517",
|
|
230
|
-
"active": "#151515"
|
|
232
|
+
"active": "#151515",
|
|
233
|
+
"disabled": "#a0a0a0",
|
|
234
|
+
"disabled-active": "#808080"
|
|
231
235
|
},
|
|
232
236
|
"stroke": {
|
|
233
237
|
"panel": "lch(91.6 1.1 266)"
|
|
@@ -324,13 +324,17 @@ declare const _default: {
|
|
|
324
324
|
"background": {
|
|
325
325
|
"default": "lch(18.2 0 0)",
|
|
326
326
|
"hover": "lch(22.8 0 0)",
|
|
327
|
-
"active": "#
|
|
328
|
-
"panel": "lch(18.2 0 0)"
|
|
327
|
+
"active": "#1F1F1C",
|
|
328
|
+
"panel": "lch(18.2 0 0)",
|
|
329
|
+
"disabled": "#414141",
|
|
330
|
+
"disabled-active": "lch(22 0 0)"
|
|
329
331
|
},
|
|
330
332
|
"text": {
|
|
331
333
|
"default": "#ffffff",
|
|
332
334
|
"hover": "#ffffff",
|
|
333
|
-
"active": "#ffffff"
|
|
335
|
+
"active": "#ffffff",
|
|
336
|
+
"disabled": "#808080",
|
|
337
|
+
"disabled-active": "#808080"
|
|
334
338
|
},
|
|
335
339
|
"stroke": {
|
|
336
340
|
"panel": "lch(27.5 0 0 / 0.3)"
|
|
@@ -603,12 +603,16 @@ declare const _default: {
|
|
|
603
603
|
"default": "lch(94.5 0.72 266)",
|
|
604
604
|
"hover": "lch(97.4 1.44 272)",
|
|
605
605
|
"active": "#ffffff",
|
|
606
|
-
"panel": "lch(94.5 0.72 266)"
|
|
606
|
+
"panel": "lch(94.5 0.72 266)",
|
|
607
|
+
"disabled": "#dfdfdf",
|
|
608
|
+
"disabled-active": "lch(88.9 0 0)"
|
|
607
609
|
},
|
|
608
610
|
"text": {
|
|
609
611
|
"default": "#161517",
|
|
610
612
|
"hover": "#161517",
|
|
611
|
-
"active": "#151515"
|
|
613
|
+
"active": "#151515",
|
|
614
|
+
"disabled": "#a0a0a0",
|
|
615
|
+
"disabled-active": "#808080"
|
|
612
616
|
},
|
|
613
617
|
"stroke": {
|
|
614
618
|
"panel": "lch(91.6 1.1 266)"
|
|
@@ -325,12 +325,16 @@ declare const _default: {
|
|
|
325
325
|
"default": "lch(94.5 0.72 266)",
|
|
326
326
|
"hover": "lch(97.4 1.44 272)",
|
|
327
327
|
"active": "#ffffff",
|
|
328
|
-
"panel": "lch(94.5 0.72 266)"
|
|
328
|
+
"panel": "lch(94.5 0.72 266)",
|
|
329
|
+
"disabled": "#dfdfdf",
|
|
330
|
+
"disabled-active": "lch(88.9 0 0)"
|
|
329
331
|
},
|
|
330
332
|
"text": {
|
|
331
333
|
"default": "#161517",
|
|
332
334
|
"hover": "#161517",
|
|
333
|
-
"active": "#151515"
|
|
335
|
+
"active": "#151515",
|
|
336
|
+
"disabled": "#a0a0a0",
|
|
337
|
+
"disabled-active": "#808080"
|
|
334
338
|
},
|
|
335
339
|
"stroke": {
|
|
336
340
|
"panel": "lch(91.6 1.1 266)"
|