@touchtech/baselayer-ui 2.22.3 → 2.22.4
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/Button/Button.d.ts +24 -0
- package/dist/components/Button/__tests__/Button.test.d.ts +1 -0
- package/dist/components/Button/index.d.ts +1 -0
- package/dist/components/ButtonBadge/ButtonBadge.d.ts +7 -0
- package/dist/components/ButtonBadge/__tests__/ButtonBadge.test.d.ts +1 -0
- package/dist/components/ButtonBadge/index.d.ts +1 -0
- package/dist/components/ButtonLink/ButtonLink.d.ts +22 -0
- package/dist/components/ButtonLink/__tests__/ButtonLink.test.d.ts +1 -0
- package/dist/components/ButtonLink/index.d.ts +1 -0
- package/dist/components/Checkbox/Checkbox.d.ts +15 -0
- package/dist/components/Checkbox/__tests__/Checkbox.test.d.ts +1 -0
- package/dist/components/Checkbox/index.d.ts +1 -0
- package/dist/components/ColorPicker/ColorPicker.d.ts +11 -0
- package/dist/components/ColorPicker/__tests__/ColorPicker.test.d.ts +1 -0
- package/dist/components/ColorPicker/index.d.ts +1 -0
- package/dist/components/ColorSwatch/ColorSwatch.d.ts +10 -0
- package/dist/components/ColorSwatch/__tests__/ColorSwatch.test.d.ts +1 -0
- package/dist/components/ColorSwatch/index.d.ts +1 -0
- package/dist/components/ConfirmationModal/ConfirmationModal.d.ts +19 -0
- package/dist/components/ConfirmationModal/__tests__/ConfirmationModal.test.d.ts +1 -0
- package/dist/components/ConfirmationModal/index.d.ts +1 -0
- package/dist/components/FileInput/FileInput.d.ts +22 -0
- package/dist/components/FileInput/__tests__/FileInput.test.d.ts +1 -0
- package/dist/components/FileInput/index.d.ts +2 -0
- package/dist/components/FloatingPanel/FloatingPanel.d.ts +14 -0
- package/dist/components/FloatingPanel/__tests__/FloatingPanel.test.d.ts +1 -0
- package/dist/components/FloatingPanel/index.d.ts +1 -0
- package/dist/components/Icon/Icon.d.ts +10 -0
- package/dist/components/Icon/__tests__/Icon.test.d.ts +1 -0
- package/dist/components/Icon/index.d.ts +1 -0
- package/dist/components/IconButton/IconButton.d.ts +21 -0
- package/dist/components/IconButton/__tests__/IconButton.test.d.ts +1 -0
- package/dist/components/IconButton/index.d.ts +1 -0
- package/dist/components/IconButtonLink/IconButtonLink.d.ts +20 -0
- package/dist/components/IconButtonLink/__tests__/IconButtonLink.test.d.ts +1 -0
- package/dist/components/IconButtonLink/index.d.ts +1 -0
- package/dist/components/Image/Image.d.ts +14 -0
- package/dist/components/Image/__tests__/Image.test.d.ts +1 -0
- package/dist/components/Image/index.d.ts +1 -0
- package/dist/components/Label/Label.d.ts +9 -0
- package/dist/components/Label/__tests/Label.test.d.ts +1 -0
- package/dist/components/Label/index.d.ts +1 -0
- package/dist/components/ListView/ListView.d.ts +10 -0
- package/dist/components/ListView/ListViewItem.d.ts +14 -0
- package/dist/components/ListView/ListViewLinkItem.d.ts +13 -0
- package/dist/components/ListView/__tests__/ListView.test.d.ts +1 -0
- package/dist/components/ListView/index.d.ts +3 -0
- package/dist/components/Menu/Menu.d.ts +11 -0
- package/dist/components/Menu/MenuContainer.d.ts +13 -0
- package/dist/components/Menu/MenuItem.d.ts +10 -0
- package/dist/components/Menu/MenuLinkItem.d.ts +9 -0
- package/dist/components/Menu/__tests__/Menu.test.d.ts +1 -0
- package/dist/components/Menu/__tests__/MenuLinkItem.test.d.ts +1 -0
- package/dist/components/Menu/index.d.ts +4 -0
- package/dist/components/Modal/Modal.d.ts +14 -0
- package/dist/components/Modal/__tests__/Modal.test.d.ts +1 -0
- package/dist/components/Modal/index.d.ts +1 -0
- package/dist/components/Overlay/Overlay.d.ts +10 -0
- package/dist/components/Overlay/__tests__/Overlay.test.d.ts +1 -0
- package/dist/components/Overlay/index.d.ts +1 -0
- package/dist/components/TextInput/TextInput.d.ts +18 -0
- package/dist/components/TextInput/__tests__/TextInput.test.d.ts +1 -0
- package/dist/components/TextInput/index.d.ts +1 -0
- package/dist/components/Toast/Toast.d.ts +8 -0
- package/dist/components/Toast/ToastContainer.d.ts +7 -0
- package/dist/components/Toast/__tests__/Toast.test.d.ts +1 -0
- package/dist/components/Toast/__tests__/ToastContainer.test.d.ts +1 -0
- package/dist/components/Toast/index.d.ts +2 -0
- package/dist/components/Video/Video.d.ts +23 -0
- package/dist/components/Video/__tests__/Video.test.d.ts +1 -0
- package/dist/components/Video/index.d.ts +1 -0
- package/dist/hooks/__tests__/useToggle.test.d.ts +1 -0
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/useOutsideClick.d.ts +4 -0
- package/dist/hooks/useToggle.d.ts +1 -0
- package/dist/index.d.ts +22 -0
- package/dist/index.js +12 -0
- package/dist/styles.css +1333 -0
- package/dist/types/index.d.ts +7 -0
- package/package.json +1 -1
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { ReactNode, RefObject, SyntheticEvent } from "react";
|
|
2
|
+
import { Size } from "../../types";
|
|
3
|
+
declare type ButtonProps = {
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
className?: string;
|
|
6
|
+
containerRef?: RefObject<HTMLButtonElement>;
|
|
7
|
+
disabled?: boolean;
|
|
8
|
+
inverted?: boolean;
|
|
9
|
+
rounded?: boolean;
|
|
10
|
+
noShadow?: boolean;
|
|
11
|
+
noPadding?: boolean;
|
|
12
|
+
noBorder?: boolean;
|
|
13
|
+
transparent?: boolean;
|
|
14
|
+
stretchHorizontally?: boolean;
|
|
15
|
+
stretchVertically?: boolean;
|
|
16
|
+
autoFocus?: boolean;
|
|
17
|
+
onClick?: (event?: SyntheticEvent<HTMLButtonElement>) => void;
|
|
18
|
+
size?: Size;
|
|
19
|
+
type?: "submit" | "reset" | "button";
|
|
20
|
+
align?: "left" | "center";
|
|
21
|
+
offsetSides?: Array<"left" | "right">;
|
|
22
|
+
};
|
|
23
|
+
declare function Button({ children, className, onClick, containerRef, disabled, inverted, rounded, noShadow, noPadding, noBorder, transparent, stretchHorizontally, stretchVertically, autoFocus, offsetSides, align, size, type, }: ButtonProps): JSX.Element;
|
|
24
|
+
export default Button;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Button } from "./Button";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ButtonBadge } from "./ButtonBadge";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ReactNode, ElementType, RefObject } from "react";
|
|
2
|
+
import { Size } from "../../types";
|
|
3
|
+
declare type OffsetSide = "left" | "right";
|
|
4
|
+
declare type ButtonLinkProps = {
|
|
5
|
+
as?: ElementType;
|
|
6
|
+
children: ReactNode;
|
|
7
|
+
className?: string;
|
|
8
|
+
containerRef?: RefObject<HTMLElement>;
|
|
9
|
+
inverted?: boolean;
|
|
10
|
+
rounded?: boolean;
|
|
11
|
+
transparent?: boolean;
|
|
12
|
+
noShadow?: boolean;
|
|
13
|
+
noPadding?: boolean;
|
|
14
|
+
noBorder?: boolean;
|
|
15
|
+
stretchHorizontally?: boolean;
|
|
16
|
+
stretchVertically?: boolean;
|
|
17
|
+
size?: Size;
|
|
18
|
+
offsetSides?: Array<OffsetSide>;
|
|
19
|
+
align?: "left" | "center";
|
|
20
|
+
} | any;
|
|
21
|
+
declare function ButtonLink({ as: Component, children, className, size, containerRef, inverted, rounded, transparent, noShadow, noPadding, noBorder, stretchHorizontally, stretchVertically, offsetSides, align, ...props }: ButtonLinkProps): JSX.Element;
|
|
22
|
+
export default ButtonLink;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ButtonLink } from "./ButtonLink";
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Size } from "../../types";
|
|
3
|
+
declare type CheckboxProps = {
|
|
4
|
+
label?: string;
|
|
5
|
+
onChange: (value: boolean) => void;
|
|
6
|
+
placeholder?: string;
|
|
7
|
+
checked?: boolean;
|
|
8
|
+
disabled?: boolean;
|
|
9
|
+
name?: string;
|
|
10
|
+
size?: Size;
|
|
11
|
+
autoFocus?: boolean;
|
|
12
|
+
indeterminate?: boolean;
|
|
13
|
+
};
|
|
14
|
+
declare function Checkbox({ label, onChange, placeholder, checked, disabled, name, indeterminate, size, autoFocus, }: CheckboxProps): JSX.Element;
|
|
15
|
+
export default Checkbox;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Checkbox } from "./Checkbox";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { RefObject } from "react";
|
|
2
|
+
import { Color } from "../../types";
|
|
3
|
+
declare type ColorPickerProps = {
|
|
4
|
+
colors: Color[];
|
|
5
|
+
containerRef?: RefObject<HTMLDivElement>;
|
|
6
|
+
direction?: "horizontal" | "vertical";
|
|
7
|
+
onSelect: (color: Color) => void;
|
|
8
|
+
selectedColor?: Color;
|
|
9
|
+
};
|
|
10
|
+
declare function ColorPicker({ colors, containerRef, onSelect, selectedColor, direction, }: ColorPickerProps): JSX.Element;
|
|
11
|
+
export default ColorPicker;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ColorPicker } from "./ColorPicker";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { RefObject } from "react";
|
|
2
|
+
import { Color } from "../../types";
|
|
3
|
+
declare type ColorSwatchProps = {
|
|
4
|
+
color: Color;
|
|
5
|
+
containerRef?: RefObject<HTMLButtonElement>;
|
|
6
|
+
isSelected?: boolean;
|
|
7
|
+
onClick?: () => void;
|
|
8
|
+
};
|
|
9
|
+
declare function ColorSwatch({ color, containerRef, onClick, isSelected, }: ColorSwatchProps): JSX.Element;
|
|
10
|
+
export default ColorSwatch;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ColorSwatch } from "./ColorSwatch";
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ReactElement, ReactNode, RefObject } from "react";
|
|
2
|
+
declare type ConfirmationModalProps = {
|
|
3
|
+
buttonsLeft?: ReactElement[];
|
|
4
|
+
buttonsRight?: ReactElement[];
|
|
5
|
+
children?: ReactNode;
|
|
6
|
+
containerRef?: RefObject<HTMLDivElement>;
|
|
7
|
+
header: string;
|
|
8
|
+
isOpen: boolean;
|
|
9
|
+
noPadding?: boolean;
|
|
10
|
+
noOverlay?: boolean;
|
|
11
|
+
noShadow?: boolean;
|
|
12
|
+
onClose?: () => void;
|
|
13
|
+
baseZIndex?: number;
|
|
14
|
+
};
|
|
15
|
+
declare function ConfirmationModal({ children, containerRef, header, isOpen, buttonsLeft, buttonsRight, onClose, noPadding, noOverlay, noShadow, baseZIndex, }: ConfirmationModalProps): JSX.Element;
|
|
16
|
+
declare namespace ConfirmationModal {
|
|
17
|
+
var displayName: string;
|
|
18
|
+
}
|
|
19
|
+
export default ConfirmationModal;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ConfirmationModal } from "./ConfirmationModal";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import React, { ChangeEvent } from "react";
|
|
2
|
+
import { Size } from "../../types";
|
|
3
|
+
export declare type FileInputSize = Size;
|
|
4
|
+
declare type Props = {
|
|
5
|
+
onChange: (e: ChangeEvent<HTMLInputElement>) => void;
|
|
6
|
+
children: React.ReactNode;
|
|
7
|
+
accept?: string;
|
|
8
|
+
multiple?: boolean;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
inputRef?: React.RefObject<HTMLInputElement>;
|
|
11
|
+
inverted?: boolean;
|
|
12
|
+
noShadow?: boolean;
|
|
13
|
+
noBorder?: boolean;
|
|
14
|
+
noPadding?: boolean;
|
|
15
|
+
transparent?: boolean;
|
|
16
|
+
stretchHorizontally?: boolean;
|
|
17
|
+
stretchVertically?: boolean;
|
|
18
|
+
rounded?: boolean;
|
|
19
|
+
size?: FileInputSize;
|
|
20
|
+
};
|
|
21
|
+
declare function FileInput({ children, accept, onChange, inputRef, multiple, disabled, inverted, noShadow, noBorder, noPadding, transparent, stretchHorizontally, stretchVertically, rounded, size, }: Props): JSX.Element;
|
|
22
|
+
export default FileInput;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ReactNode, RefObject } from "react";
|
|
2
|
+
declare type Placement = {
|
|
3
|
+
horizontal: "right" | "rightEdge" | "rightOnEdge" | "left" | "leftEdge" | "leftOnEdge" | "leftOnEdge" | "center";
|
|
4
|
+
vertical: "top" | "topEdge" | "topOnEdge" | "bottom" | "bottomEdge" | "bottomOnEdge" | "center";
|
|
5
|
+
parent: "viewport" | "container";
|
|
6
|
+
};
|
|
7
|
+
declare type FloatingPanelProps = {
|
|
8
|
+
children: ReactNode;
|
|
9
|
+
containerRef?: RefObject<HTMLDivElement>;
|
|
10
|
+
layout?: "column" | "row";
|
|
11
|
+
placement?: Placement;
|
|
12
|
+
};
|
|
13
|
+
declare function FloatingPanel({ children, containerRef, layout, placement, }: FloatingPanelProps): JSX.Element;
|
|
14
|
+
export default FloatingPanel;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as FloatingPanel } from "./FloatingPanel";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { RefObject } from "react";
|
|
2
|
+
declare type IconProps = {
|
|
3
|
+
alt?: string;
|
|
4
|
+
containerRef?: RefObject<HTMLImageElement>;
|
|
5
|
+
inverted?: boolean;
|
|
6
|
+
src: string;
|
|
7
|
+
size?: "small" | "medium" | "large" | "xlarge";
|
|
8
|
+
};
|
|
9
|
+
declare function Icon({ src, alt, containerRef, size, inverted, }: IconProps): JSX.Element;
|
|
10
|
+
export default Icon;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Icon } from "./Icon";
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { ReactNode, RefObject, SyntheticEvent } from "react";
|
|
2
|
+
import { Size } from "../../types";
|
|
3
|
+
declare type IconButtonProps = {
|
|
4
|
+
className?: string;
|
|
5
|
+
containerRef?: RefObject<HTMLButtonElement>;
|
|
6
|
+
src: string;
|
|
7
|
+
alt: string;
|
|
8
|
+
badgeContent?: ReactNode;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
inverted?: boolean;
|
|
11
|
+
noShadow?: boolean;
|
|
12
|
+
noBorder?: boolean;
|
|
13
|
+
transparent?: boolean;
|
|
14
|
+
rounded?: boolean;
|
|
15
|
+
onClick?: (event?: SyntheticEvent<HTMLButtonElement>) => void;
|
|
16
|
+
size?: Size;
|
|
17
|
+
type?: "submit" | "reset" | "button";
|
|
18
|
+
offsetSides?: Array<"top" | "right" | "bottom" | "left">;
|
|
19
|
+
};
|
|
20
|
+
declare function IconButton({ className, containerRef, src, alt, badgeContent, offsetSides, onClick, disabled, inverted, noShadow, noBorder, transparent, rounded, size, type, }: IconButtonProps): JSX.Element;
|
|
21
|
+
export default IconButton;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as IconButton } from "./IconButton";
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ElementType, ReactNode, RefObject } from "react";
|
|
2
|
+
import { Size } from "../../types";
|
|
3
|
+
declare type OffsetSide = "top" | "right" | "bottom" | "left";
|
|
4
|
+
declare type IconButtonLinkProps = {
|
|
5
|
+
as?: ElementType;
|
|
6
|
+
containerRef?: RefObject<HTMLElement>;
|
|
7
|
+
src: string;
|
|
8
|
+
alt: string;
|
|
9
|
+
badgeContent?: ReactNode;
|
|
10
|
+
className?: string;
|
|
11
|
+
inverted?: boolean;
|
|
12
|
+
rounded?: boolean;
|
|
13
|
+
transparent?: boolean;
|
|
14
|
+
noShadow?: boolean;
|
|
15
|
+
noBorder?: boolean;
|
|
16
|
+
size?: Size;
|
|
17
|
+
offsetSides?: Array<OffsetSide>;
|
|
18
|
+
} | any;
|
|
19
|
+
declare function IconButtonLink({ as: Component, containerRef, className, src, alt, badgeContent, inverted, noShadow, noBorder, transparent, rounded, offsetSides, size, ...props }: IconButtonLinkProps): JSX.Element;
|
|
20
|
+
export default IconButtonLink;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as IconButtonLink } from "./IconButtonLink";
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import React, { RefObject } from "react";
|
|
2
|
+
export declare type ImageProps = {
|
|
3
|
+
alt?: string;
|
|
4
|
+
children?: React.ReactNode;
|
|
5
|
+
containerRef?: RefObject<HTMLDivElement>;
|
|
6
|
+
layout?: "cover" | "contain" | "stretchHorizontally" | "stretchVertically";
|
|
7
|
+
src: string;
|
|
8
|
+
srcWidth?: number;
|
|
9
|
+
srcHeight?: number;
|
|
10
|
+
decoding?: "async" | "sync" | "auto";
|
|
11
|
+
loading?: "eager" | "lazy";
|
|
12
|
+
};
|
|
13
|
+
declare function ImageComponent({ src, alt, srcWidth, srcHeight, children, containerRef, layout, decoding, loading }: ImageProps): JSX.Element;
|
|
14
|
+
export default ImageComponent;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Image, ImageProps } from "./Image";
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { RefObject, ReactNode } from "react";
|
|
2
|
+
declare type LabelInputProps = {
|
|
3
|
+
className?: string;
|
|
4
|
+
children?: ReactNode;
|
|
5
|
+
containerRef?: RefObject<HTMLLabelElement>;
|
|
6
|
+
value: ReactNode;
|
|
7
|
+
};
|
|
8
|
+
declare function Label({ className, children, value, containerRef }: LabelInputProps): JSX.Element;
|
|
9
|
+
export default Label;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Label } from "./Label";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ReactNode, RefObject } from "react";
|
|
2
|
+
declare type ListViewProps = {
|
|
3
|
+
children: ReactNode;
|
|
4
|
+
className?: string;
|
|
5
|
+
containerRef?: RefObject<HTMLDivElement>;
|
|
6
|
+
header?: string;
|
|
7
|
+
headerActions?: ReactNode;
|
|
8
|
+
};
|
|
9
|
+
declare function ListView({ children, className, containerRef, header, headerActions, }: ListViewProps): JSX.Element;
|
|
10
|
+
export default ListView;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
|
+
import { Size } from "../../types";
|
|
3
|
+
declare type ListViewItemProps = {
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
active?: boolean;
|
|
6
|
+
disabled?: boolean;
|
|
7
|
+
transparent?: boolean;
|
|
8
|
+
noPadding?: boolean;
|
|
9
|
+
size?: Size;
|
|
10
|
+
align?: "left" | "center";
|
|
11
|
+
onClick?: () => void;
|
|
12
|
+
};
|
|
13
|
+
declare function ListViewItem({ children, active, disabled, transparent, noPadding, size, align, onClick, }: ListViewItemProps): JSX.Element;
|
|
14
|
+
export default ListViewItem;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ElementType, ReactNode } from "react";
|
|
2
|
+
import { Size } from "../../types";
|
|
3
|
+
declare type ListViewLinkItemProps = {
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
as?: ElementType;
|
|
6
|
+
active: boolean;
|
|
7
|
+
transparent: boolean;
|
|
8
|
+
noPadding: boolean;
|
|
9
|
+
align: "left" | "center";
|
|
10
|
+
size: Size;
|
|
11
|
+
} | any;
|
|
12
|
+
declare function ListViewLinkItem({ children, as: Component, active, transparent, noPadding, align, size, ...props }: ListViewLinkItemProps): JSX.Element;
|
|
13
|
+
export default ListViewLinkItem;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ReactNode, RefObject } from "react";
|
|
2
|
+
declare type MenuProps = {
|
|
3
|
+
children: ReactNode;
|
|
4
|
+
containerRef?: RefObject<HTMLDivElement>;
|
|
5
|
+
className?: string;
|
|
6
|
+
isOpen?: boolean;
|
|
7
|
+
header?: string;
|
|
8
|
+
footer?: ReactNode;
|
|
9
|
+
};
|
|
10
|
+
declare function Menu({ children, containerRef, className, isOpen, header, footer, }: MenuProps): JSX.Element;
|
|
11
|
+
export default Menu;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React, { ReactNode, ReactElement } from "react";
|
|
2
|
+
export declare type MenuPlacement = {
|
|
3
|
+
horizontal: "right" | "left";
|
|
4
|
+
vertical: "top" | "bottom";
|
|
5
|
+
};
|
|
6
|
+
declare type MenuContainerProps = {
|
|
7
|
+
children: ReactNode;
|
|
8
|
+
button?: ReactElement;
|
|
9
|
+
className?: string;
|
|
10
|
+
placement?: MenuPlacement;
|
|
11
|
+
};
|
|
12
|
+
declare const _default: React.ForwardRefExoticComponent<MenuContainerProps & React.RefAttributes<HTMLDivElement>>;
|
|
13
|
+
export default _default;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ReactNode, SyntheticEvent } from "react";
|
|
2
|
+
declare type MenuItemProps = {
|
|
3
|
+
children: ReactNode;
|
|
4
|
+
className?: string;
|
|
5
|
+
isActive?: boolean;
|
|
6
|
+
noPadding?: boolean;
|
|
7
|
+
onClick?: (event?: SyntheticEvent<HTMLLIElement>) => void;
|
|
8
|
+
};
|
|
9
|
+
declare function MenuItem({ children, className, onClick, noPadding, isActive, }: MenuItemProps): JSX.Element;
|
|
10
|
+
export default MenuItem;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ReactNode, ElementType } from "react";
|
|
2
|
+
declare type MenuLinkItemProps = {
|
|
3
|
+
as: ElementType;
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
className: string;
|
|
6
|
+
noPadding?: boolean;
|
|
7
|
+
} | any;
|
|
8
|
+
declare function MenuLinkItem({ as: Component, children, className, noPadding, ...props }: MenuLinkItemProps): JSX.Element;
|
|
9
|
+
export default MenuLinkItem;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ReactNode, RefObject } from "react";
|
|
2
|
+
declare type ModalProps = {
|
|
3
|
+
children: ReactNode;
|
|
4
|
+
containerRef?: RefObject<HTMLDivElement>;
|
|
5
|
+
isOpen: boolean;
|
|
6
|
+
onClose?: () => void;
|
|
7
|
+
button?: ReactNode;
|
|
8
|
+
transparent?: boolean;
|
|
9
|
+
noShadow?: boolean;
|
|
10
|
+
noOverlay?: boolean;
|
|
11
|
+
baseZIndex?: number;
|
|
12
|
+
};
|
|
13
|
+
declare function Modal({ children, containerRef, isOpen, button, transparent, noShadow, noOverlay, onClose, baseZIndex, }: ModalProps): JSX.Element;
|
|
14
|
+
export default Modal;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Modal } from "./Modal";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ReactNode, RefObject } from "react";
|
|
2
|
+
declare type OverlayProps = {
|
|
3
|
+
children: ReactNode;
|
|
4
|
+
containerRef?: RefObject<HTMLDivElement>;
|
|
5
|
+
transparent?: boolean;
|
|
6
|
+
isFixed?: boolean;
|
|
7
|
+
onClick?: () => void;
|
|
8
|
+
};
|
|
9
|
+
declare function Overlay({ children, containerRef, transparent, isFixed, onClick, }: OverlayProps): JSX.Element;
|
|
10
|
+
export default Overlay;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Overlay } from "./Overlay";
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { Size, TextInputType } from "../../types";
|
|
3
|
+
declare type TextInputProps = {
|
|
4
|
+
label?: string;
|
|
5
|
+
onChange?: (value: string) => void;
|
|
6
|
+
onBlur?: () => void;
|
|
7
|
+
onKeyDown?: (event: React.KeyboardEvent<HTMLInputElement>) => void;
|
|
8
|
+
placeholder?: string;
|
|
9
|
+
value?: string;
|
|
10
|
+
name?: string;
|
|
11
|
+
type?: TextInputType;
|
|
12
|
+
size?: Size;
|
|
13
|
+
noBorder?: boolean;
|
|
14
|
+
autoFocus?: boolean;
|
|
15
|
+
inputRef?: React.RefObject<HTMLInputElement>;
|
|
16
|
+
};
|
|
17
|
+
declare function TextInput({ label, onChange, onBlur, onKeyDown, placeholder, value, name, inputRef, size, type, autoFocus, noBorder, }: TextInputProps): JSX.Element;
|
|
18
|
+
export default TextInput;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as TextInput } from "./TextInput";
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ReactNode, RefObject } from "react";
|
|
2
|
+
declare type ToastProps = {
|
|
3
|
+
children: ReactNode;
|
|
4
|
+
containerRef?: RefObject<HTMLDivElement>;
|
|
5
|
+
onClick?: () => void;
|
|
6
|
+
};
|
|
7
|
+
declare function Toast({ children, containerRef, onClick }: ToastProps): JSX.Element;
|
|
8
|
+
export default Toast;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { ReactNode, RefObject } from "react";
|
|
2
|
+
/**
|
|
3
|
+
* There is a known issue in React in regards to the 'muted' property which causes the warning:
|
|
4
|
+
* "Warning: unstable_flushDiscreteUpdates: Cannot flush updates when React is already rendering."
|
|
5
|
+
*
|
|
6
|
+
* https://github.com/facebook/react/issues/10389
|
|
7
|
+
* https://github.com/facebook/react/issues/6544
|
|
8
|
+
* https://github.com/testing-library/react-testing-library/issues/470
|
|
9
|
+
*/
|
|
10
|
+
declare type Layout = "cover" | "contain" | "stretchHorizontally" | "stretchVertically";
|
|
11
|
+
export declare type VideoProps = {
|
|
12
|
+
src: string;
|
|
13
|
+
type: string;
|
|
14
|
+
layout?: Layout;
|
|
15
|
+
autoPlay?: boolean;
|
|
16
|
+
loop?: boolean;
|
|
17
|
+
muted?: boolean;
|
|
18
|
+
children?: ReactNode;
|
|
19
|
+
containerRef?: RefObject<HTMLDivElement>;
|
|
20
|
+
poster?: string;
|
|
21
|
+
};
|
|
22
|
+
declare function Video({ src, type, children, containerRef, poster, muted, loop, autoPlay, layout, }: VideoProps): JSX.Element;
|
|
23
|
+
export default Video;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Video, VideoProps } from "./Video";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function useToggle(initialValue?: boolean): [boolean, (newValue?: boolean) => void];
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export * from "./components/ButtonBadge";
|
|
2
|
+
export * from "./components/Button";
|
|
3
|
+
export * from "./components/ButtonLink";
|
|
4
|
+
export * from "./components/Checkbox";
|
|
5
|
+
export * from "./components/ColorPicker";
|
|
6
|
+
export * from "./components/ColorSwatch";
|
|
7
|
+
export * from "./components/ConfirmationModal";
|
|
8
|
+
export * from "./components/FileInput";
|
|
9
|
+
export * from "./components/FloatingPanel";
|
|
10
|
+
export * from "./components/Icon";
|
|
11
|
+
export * from "./components/IconButton";
|
|
12
|
+
export * from "./components/IconButtonLink";
|
|
13
|
+
export * from "./components/Image";
|
|
14
|
+
export * from "./components/ListView";
|
|
15
|
+
export * from "./components/Menu";
|
|
16
|
+
export * from "./components/Modal";
|
|
17
|
+
export * from "./components/Overlay";
|
|
18
|
+
export * from "./components/Label";
|
|
19
|
+
export * from "./components/TextInput";
|
|
20
|
+
export * from "./components/Toast";
|
|
21
|
+
export * from "./components/Video";
|
|
22
|
+
export * from "./hooks";
|