@clickhouse/click-ui 0.0.113 → 0.0.115
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 +6683 -6666
- package/dist/click-ui.umd.js +165 -167
- package/dist/components/Flyout/Flyout.d.ts +8 -2
- package/dist/components/Grid/Grid.d.ts +1 -2
- package/dist/components/Grid/Header.d.ts +3 -3
- package/dist/components/Grid/RowNumberColumn.d.ts +2 -3
- package/dist/components/Grid/StyledCell.d.ts +1 -2
- package/dist/components/Grid/types.d.ts +5 -3
- package/dist/styles/variables.classic.json.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ReactNode } from "react";
|
|
2
2
|
import { DialogProps, DialogTriggerProps, DialogContentProps as RadixDialogContentProps } from "@radix-ui/react-dialog";
|
|
3
|
-
import { ButtonProps, ContainerProps } from
|
|
3
|
+
import { ButtonProps, ContainerProps } from '../../components';
|
|
4
4
|
export type FlyoutProps = DialogProps;
|
|
5
5
|
export declare const Flyout: {
|
|
6
6
|
({ modal, ...props }: FlyoutProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -9,7 +9,7 @@ export declare const Flyout: {
|
|
|
9
9
|
displayName: string;
|
|
10
10
|
};
|
|
11
11
|
Content: {
|
|
12
|
-
({ showOverlay, children, container, strategy, size, type, closeOnInteractOutside, onInteractOutside, ...props }: DialogContentProps): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
({ showOverlay, children, container, strategy, size, type, closeOnInteractOutside, width, align, onInteractOutside, ...props }: DialogContentProps): import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
displayName: string;
|
|
14
14
|
};
|
|
15
15
|
Element: {
|
|
@@ -34,10 +34,14 @@ export declare const Flyout: {
|
|
|
34
34
|
(props: FlyoutFooterProps): import("react/jsx-runtime").JSX.Element;
|
|
35
35
|
displayName: string;
|
|
36
36
|
};
|
|
37
|
+
CodeBlock: ({ statement, ...props }: {
|
|
38
|
+
statement: string;
|
|
39
|
+
} & ElementProps) => import("react/jsx-runtime").JSX.Element;
|
|
37
40
|
};
|
|
38
41
|
type FlyoutSizeType = "default" | "narrow" | "wide";
|
|
39
42
|
type Strategy = "relative" | "absolute" | "fixed";
|
|
40
43
|
type FlyoutType = "default" | "inline";
|
|
44
|
+
type DialogContentAlignmentType = "start" | "end";
|
|
41
45
|
export interface DialogContentProps extends RadixDialogContentProps {
|
|
42
46
|
container?: HTMLElement | null;
|
|
43
47
|
showOverlay?: boolean;
|
|
@@ -46,6 +50,8 @@ export interface DialogContentProps extends RadixDialogContentProps {
|
|
|
46
50
|
type?: FlyoutType;
|
|
47
51
|
strategy?: Strategy;
|
|
48
52
|
closeOnInteractOutside?: boolean;
|
|
53
|
+
width?: string;
|
|
54
|
+
align?: DialogContentAlignmentType;
|
|
49
55
|
}
|
|
50
56
|
interface ElementProps extends Omit<ContainerProps<"div">, "component" | "padding" | "gap" | "orientation"> {
|
|
51
57
|
type?: FlyoutType;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { VariableSizeGrid } from "react-window";
|
|
3
2
|
import { GridProps } from "./types";
|
|
4
|
-
export declare const Grid: import("react").ForwardRefExoticComponent<GridProps & import("react").RefAttributes<
|
|
3
|
+
export declare const Grid: import("react").ForwardRefExoticComponent<GridProps & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CellProps, ColumnResizeFn,
|
|
1
|
+
import { CellProps, ColumnResizeFn, SelectionTypeFn, SetResizeCursorPositionFn } from "./types";
|
|
2
2
|
interface HeaderProps {
|
|
3
3
|
showRowNumber: boolean;
|
|
4
4
|
rowNumberWidth: number;
|
|
@@ -8,13 +8,13 @@ interface HeaderProps {
|
|
|
8
8
|
columnWidth: (index: number) => number;
|
|
9
9
|
cell: CellProps;
|
|
10
10
|
getSelectionType: SelectionTypeFn;
|
|
11
|
-
rounded: RoundedType;
|
|
12
11
|
columnCount: number;
|
|
13
12
|
onColumnResize: ColumnResizeFn;
|
|
14
13
|
getColumnHorizontalPosition: (columnIndex: number) => number;
|
|
15
14
|
scrolledVertical: boolean;
|
|
16
15
|
setResizeCursorPosition: SetResizeCursorPositionFn;
|
|
17
16
|
showBorder: boolean;
|
|
17
|
+
scrolledHorizontal: boolean;
|
|
18
18
|
}
|
|
19
|
-
declare const Header: ({ scrolledVertical, showRowNumber, rowNumberWidth, minColumn, maxColumn, height, columnWidth, cell,
|
|
19
|
+
declare const Header: ({ scrolledVertical, scrolledHorizontal, showRowNumber, rowNumberWidth, minColumn, maxColumn, height, columnWidth, cell, columnCount, getSelectionType, onColumnResize, getColumnHorizontalPosition, setResizeCursorPosition, showBorder, }: HeaderProps) => import("react/jsx-runtime").JSX.Element;
|
|
20
20
|
export default Header;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { SelectionTypeFn } from "./types";
|
|
2
2
|
interface RowNumberColumnProps {
|
|
3
3
|
minRow: number;
|
|
4
4
|
maxRow: number;
|
|
@@ -7,11 +7,10 @@ interface RowNumberColumnProps {
|
|
|
7
7
|
rowWidth: number;
|
|
8
8
|
getSelectionType: SelectionTypeFn;
|
|
9
9
|
rowCount: number;
|
|
10
|
-
rounded: RoundedType;
|
|
11
10
|
showHeader: boolean;
|
|
12
11
|
scrolledHorizontal: boolean;
|
|
13
12
|
rowStart: number;
|
|
14
13
|
showBorder: boolean;
|
|
15
14
|
}
|
|
16
|
-
declare const RowNumberColumn: ({ minRow, maxRow, rowHeight, headerHeight, rowWidth, getSelectionType, rowCount,
|
|
15
|
+
declare const RowNumberColumn: ({ minRow, maxRow, rowHeight, headerHeight, rowWidth, getSelectionType, rowCount, showHeader, scrolledHorizontal, rowStart, showBorder, }: RowNumberColumnProps) => import("react/jsx-runtime").JSX.Element;
|
|
17
16
|
export default RowNumberColumn;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { SelectionType } from "./types";
|
|
2
2
|
export declare const StyledCell: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
3
3
|
$isFocused: boolean;
|
|
4
4
|
$selectionType: SelectionType;
|
|
@@ -8,7 +8,6 @@ export declare const StyledCell: import("styled-components").StyledComponent<"di
|
|
|
8
8
|
$isLastColumn: boolean;
|
|
9
9
|
$isFirstRow: boolean;
|
|
10
10
|
$isFirstColumn: boolean;
|
|
11
|
-
$rounded: RoundedType;
|
|
12
11
|
$height: number;
|
|
13
12
|
$type?: "body" | "header" | undefined;
|
|
14
13
|
$showBorder: boolean;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ComponentType, HTMLAttributes, KeyboardEventHandler, MouseEventHandler, ReactNode } from "react";
|
|
2
|
-
import { VariableSizeGridProps } from "react-window";
|
|
1
|
+
import { ComponentType, HTMLAttributes, KeyboardEventHandler, MouseEventHandler, MutableRefObject, ReactNode } from "react";
|
|
2
|
+
import { VariableSizeGrid, VariableSizeGridProps } from "react-window";
|
|
3
3
|
import { ContextMenuItemProps } from '../../components';
|
|
4
4
|
interface CellCommonProps extends HTMLAttributes<HTMLElement> {
|
|
5
5
|
columnIndex: number;
|
|
@@ -100,7 +100,6 @@ export interface ItemDataType {
|
|
|
100
100
|
columnCount: number;
|
|
101
101
|
cell: CellProps;
|
|
102
102
|
focus: SelectionFocus;
|
|
103
|
-
rounded: RoundedType;
|
|
104
103
|
rowHeight: number;
|
|
105
104
|
headerHeight: number;
|
|
106
105
|
rowNumberWidth: number;
|
|
@@ -110,6 +109,8 @@ export interface GridContextMenuItemProps extends Omit<ContextMenuItemProps, "ch
|
|
|
110
109
|
label: ReactNode;
|
|
111
110
|
}
|
|
112
111
|
export interface GridProps extends Omit<VariableSizeGridProps, "height" | "width" | "rowHeight" | "children" | "innerElementType" | "innerRef" | "outerElementType" | "outerRef" | "columnWidth"> {
|
|
112
|
+
autoFocus?: boolean;
|
|
113
|
+
autoHeight?: boolean;
|
|
113
114
|
rowStart?: number;
|
|
114
115
|
rounded?: RoundedType;
|
|
115
116
|
focus?: SelectionFocus;
|
|
@@ -131,6 +132,7 @@ export interface GridProps extends Omit<VariableSizeGridProps, "height" | "width
|
|
|
131
132
|
showBorder?: boolean;
|
|
132
133
|
onCopy?: (isCopied: boolean) => void | Promise<void>;
|
|
133
134
|
onContextMenu?: MouseEventHandler<HTMLDivElement>;
|
|
135
|
+
forwardedGridRef?: MutableRefObject<VariableSizeGrid>;
|
|
134
136
|
}
|
|
135
137
|
export type SetResizeCursorPositionFn = (element: HTMLSpanElement, clientX: number, width: number, columnIndex: number) => void;
|
|
136
138
|
export {};
|