@blofin/blofin-ui 0.6.87
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/LICENSE +21 -0
- package/README.md +97 -0
- package/dist/Badge.d.ts +1 -0
- package/dist/Badge.es.js +56 -0
- package/dist/Button.d.ts +1 -0
- package/dist/Button.es.js +377 -0
- package/dist/Dialog.d.ts +1 -0
- package/dist/Dialog.es.js +159 -0
- package/dist/Divider.d.ts +1 -0
- package/dist/Divider.es.js +25 -0
- package/dist/Drawer.d.ts +1 -0
- package/dist/Drawer.es.js +90 -0
- package/dist/Form.d.ts +1 -0
- package/dist/Form.es.js +752 -0
- package/dist/Slider.d.ts +1 -0
- package/dist/Slider.es.js +242 -0
- package/dist/blofin.css +1 -0
- package/dist/close-c67ec245.js +5 -0
- package/dist/components/Alert/Alert.d.ts +12 -0
- package/dist/components/Alert/index.d.ts +2 -0
- package/dist/components/Alert/styles.d.ts +7 -0
- package/dist/components/Badge/Badge.d.ts +21 -0
- package/dist/components/Badge/index.d.ts +2 -0
- package/dist/components/Badge/styles.d.ts +7 -0
- package/dist/components/Button/Button.d.ts +35 -0
- package/dist/components/Button/Loading/index.d.ts +8 -0
- package/dist/components/Button/index.d.ts +2 -0
- package/dist/components/Button/styles.d.ts +13 -0
- package/dist/components/Button/types.d.ts +5 -0
- package/dist/components/Calendar/Calendar.d.ts +12 -0
- package/dist/components/Calendar/index.d.ts +2 -0
- package/dist/components/Calendar/styles.d.ts +39 -0
- package/dist/components/Checkbox/Checkbox.d.ts +8 -0
- package/dist/components/Checkbox/index.d.ts +2 -0
- package/dist/components/Checkbox/styles.d.ts +22 -0
- package/dist/components/CssDropdown/CssDropdown.d.ts +18 -0
- package/dist/components/CssDropdown/styles.d.ts +7 -0
- package/dist/components/DatePickerRange/DatePickerRange.d.ts +32 -0
- package/dist/components/DatePickerRange/styles.d.ts +6 -0
- package/dist/components/DateTimePicker/Calendar.d.ts +10 -0
- package/dist/components/DateTimePicker/DateTimePicker.d.ts +18 -0
- package/dist/components/DateTimePicker/ScrollableList.d.ts +12 -0
- package/dist/components/DateTimePicker/hooks/useDateTimePicker.d.ts +35 -0
- package/dist/components/DateTimePicker/styles.d.ts +48 -0
- package/dist/components/Dialog/Dialog.d.ts +30 -0
- package/dist/components/Dialog/index.d.ts +2 -0
- package/dist/components/Dialog/styles.d.ts +13 -0
- package/dist/components/Divider/Divider.d.ts +8 -0
- package/dist/components/Divider/index.d.ts +2 -0
- package/dist/components/Divider/styles.d.ts +7 -0
- package/dist/components/Drawer/Drawer.d.ts +13 -0
- package/dist/components/Drawer/index.d.ts +2 -0
- package/dist/components/Drawer/styles.d.ts +6 -0
- package/dist/components/Dropdown/Dropdown.d.ts +14 -0
- package/dist/components/Dropdown/style.d.ts +9 -0
- package/dist/components/Empty/index.d.ts +5 -0
- package/dist/components/Form/Control.d.ts +13 -0
- package/dist/components/Form/Form.d.ts +3 -0
- package/dist/components/Form/FormItem.d.ts +4 -0
- package/dist/components/Form/FormLabel.d.ts +4 -0
- package/dist/components/Form/context.d.ts +5 -0
- package/dist/components/Form/index.d.ts +8 -0
- package/dist/components/Form/interface.d.ts +48 -0
- package/dist/components/Form/store.d.ts +16 -0
- package/dist/components/Form/styles/item.d.ts +5 -0
- package/dist/components/Form/useForm.d.ts +3 -0
- package/dist/components/LabelTextField/LabelTextField.d.ts +17 -0
- package/dist/components/LabelTextField/index.d.ts +2 -0
- package/dist/components/LabelTextField/styles.d.ts +34 -0
- package/dist/components/MonthPicker/index.d.ts +17 -0
- package/dist/components/Notification/Notification.d.ts +2 -0
- package/dist/components/Notification/style.d.ts +15 -0
- package/dist/components/Pagination/PageOptions.d.ts +12 -0
- package/dist/components/Pagination/Pagination.d.ts +34 -0
- package/dist/components/Pagination/styles.d.ts +6 -0
- package/dist/components/Picker/hooks/usePickerMethod.d.ts +9 -0
- package/dist/components/Picker/index.d.ts +10 -0
- package/dist/components/Picker/styles.d.ts +4 -0
- package/dist/components/Popover/Popover.d.ts +17 -0
- package/dist/components/Popup/index.d.ts +15 -0
- package/dist/components/Popup/styles.d.ts +3 -0
- package/dist/components/RadioButton/RadioButton.d.ts +10 -0
- package/dist/components/RadioButton/index.d.ts +2 -0
- package/dist/components/RadioButton/styles.d.ts +12 -0
- package/dist/components/Select/Select.d.ts +38 -0
- package/dist/components/Select/index.d.ts +2 -0
- package/dist/components/Select/styles.d.ts +24 -0
- package/dist/components/Slider/Slider.d.ts +20 -0
- package/dist/components/Slider/index.d.ts +2 -0
- package/dist/components/Slider/styles.d.ts +31 -0
- package/dist/components/Sort/SortButton.d.ts +14 -0
- package/dist/components/Sort/SortGroup.d.ts +8 -0
- package/dist/components/Sort/reducer.d.ts +36 -0
- package/dist/components/Sortable/SortItem.d.ts +6 -0
- package/dist/components/Sortable/index.d.ts +10 -0
- package/dist/components/Switch/Switch.d.ts +9 -0
- package/dist/components/Switch/styles.d.ts +12 -0
- package/dist/components/Tab/Tab.d.ts +21 -0
- package/dist/components/Tab/styles.d.ts +20 -0
- package/dist/components/Table/Pagination/index.d.ts +8 -0
- package/dist/components/Table/Table.d.ts +5 -0
- package/dist/components/Table/Tbody/index.d.ts +14 -0
- package/dist/components/Table/Thead/index.d.ts +17 -0
- package/dist/components/Table/context.d.ts +17 -0
- package/dist/components/Table/css.d.ts +12 -0
- package/dist/components/Table/hooks/useStickyClassName.d.ts +3 -0
- package/dist/components/Table/hooks/useStickyOffset.d.ts +15 -0
- package/dist/components/Table/index.d.ts +3 -0
- package/dist/components/Table/interface.d.ts +48 -0
- package/dist/components/TextField/TextField.d.ts +15 -0
- package/dist/components/TextField/index.d.ts +2 -0
- package/dist/components/TextSelect/TextSelect.d.ts +50 -0
- package/dist/components/TextSelect/styles.d.ts +27 -0
- package/dist/components/Textarea/index.d.ts +15 -0
- package/dist/components/Textarea/style.d.ts +13 -0
- package/dist/components/Toast/Toast.d.ts +2 -0
- package/dist/components/Toast/styles.d.ts +13 -0
- package/dist/components/Tooltip/Tooltip.d.ts +22 -0
- package/dist/components/Tooltip/enum.d.ts +21 -0
- package/dist/components/Tooltip/styles.d.ts +10 -0
- package/dist/components/Tooltip/type.d.ts +1 -0
- package/dist/components/Typography/Typography.d.ts +35 -0
- package/dist/components/Typography/styles.d.ts +10 -0
- package/dist/config/tailwind.js +9 -0
- package/dist/config/theme.js +318 -0
- package/dist/hooks/useAlign.d.ts +20 -0
- package/dist/hooks/useClient.d.ts +4 -0
- package/dist/hooks/useDelayEvent.d.ts +2 -0
- package/dist/hooks/useLatest.d.ts +1 -0
- package/dist/hooks/useNotification.d.ts +10 -0
- package/dist/hooks/useOutsideClick.d.ts +2 -0
- package/dist/hooks/useToast.d.ts +9 -0
- package/dist/index-0055aace.js +338 -0
- package/dist/index-0171eaca.js +436 -0
- package/dist/index-03ecf4ec.js +400 -0
- package/dist/index-04d10294.js +298 -0
- package/dist/index-0a1520d4.js +287 -0
- package/dist/index-0f855a91.js +14 -0
- package/dist/index-114820db.js +354 -0
- package/dist/index-1388dfff.js +336 -0
- package/dist/index-15b50a21.js +298 -0
- package/dist/index-17308ac1.js +298 -0
- package/dist/index-17afe366.js +298 -0
- package/dist/index-1d78221c.js +339 -0
- package/dist/index-1dc85776.js +437 -0
- package/dist/index-20e881af.js +354 -0
- package/dist/index-20f2adc4.js +398 -0
- package/dist/index-21539629.js +478 -0
- package/dist/index-21f85e78.js +377 -0
- package/dist/index-236e0579.js +71 -0
- package/dist/index-250f50e2.js +502 -0
- package/dist/index-356291b2.js +450 -0
- package/dist/index-38216e9e.js +340 -0
- package/dist/index-3c058c26.js +606 -0
- package/dist/index-3c3ba437.js +341 -0
- package/dist/index-3cd72a27.js +61 -0
- package/dist/index-3dcefa10.js +328 -0
- package/dist/index-3f70b1d4.js +331 -0
- package/dist/index-40ad0dd1.js +287 -0
- package/dist/index-42fb4fd5.js +334 -0
- package/dist/index-45696efa.js +438 -0
- package/dist/index-4b6824f2.js +61 -0
- package/dist/index-4b7924c1.js +354 -0
- package/dist/index-4c8ef561.js +337 -0
- package/dist/index-4ced47cd.js +359 -0
- package/dist/index-4eb29fd9.js +313 -0
- package/dist/index-4f2d4e0d.js +342 -0
- package/dist/index-51847d07.js +363 -0
- package/dist/index-51c1e00d.js +9 -0
- package/dist/index-51cf15b2.js +11054 -0
- package/dist/index-5357c173.js +336 -0
- package/dist/index-572ed179.js +353 -0
- package/dist/index-580c6bf2.js +362 -0
- package/dist/index-6817d9c1.js +363 -0
- package/dist/index-682656f7.js +62 -0
- package/dist/index-6834d6cf.js +330 -0
- package/dist/index-6a5829bd.js +387 -0
- package/dist/index-739cb389.js +332 -0
- package/dist/index-7601ed24.js +332 -0
- package/dist/index-76c2d21a.js +362 -0
- package/dist/index-7871c2fa.js +397 -0
- package/dist/index-7a871a23.js +362 -0
- package/dist/index-7aae1d07.js +298 -0
- package/dist/index-80121226.js +443 -0
- package/dist/index-872a50e8.js +353 -0
- package/dist/index-88fdaa89.js +437 -0
- package/dist/index-8a4c6daa.js +302 -0
- package/dist/index-8fb7d88b.js +360 -0
- package/dist/index-9412ffa1.js +346 -0
- package/dist/index-95d62350.js +427 -0
- package/dist/index-96a8d125.js +65 -0
- package/dist/index-9d0a665d.js +298 -0
- package/dist/index-a8c0dd3b.js +500 -0
- package/dist/index-aa90be0a.js +146 -0
- package/dist/index-aac5376e.js +331 -0
- package/dist/index-ac48594f.js +364 -0
- package/dist/index-acc7a626.js +146 -0
- package/dist/index-af6965cc.js +332 -0
- package/dist/index-b523f554.js +61 -0
- package/dist/index-b5aa671f.js +463 -0
- package/dist/index-b7612310.js +333 -0
- package/dist/index-babf632c.js +332 -0
- package/dist/index-baf0849c.js +346 -0
- package/dist/index-bb65c72e.js +514 -0
- package/dist/index-bb84ad8c.js +514 -0
- package/dist/index-c1e6e7ba.js +340 -0
- package/dist/index-cb4b8e2c.js +341 -0
- package/dist/index-d9848a76.js +545 -0
- package/dist/index-dc4bbb59.js +332 -0
- package/dist/index-dfc0fb0e.js +364 -0
- package/dist/index-e27e30cc.js +345 -0
- package/dist/index-e8380fcb.js +335 -0
- package/dist/index-ea4a8872.js +311 -0
- package/dist/index-eb696d64.js +436 -0
- package/dist/index-ebd469fd.js +297 -0
- package/dist/index-ed48cf75.js +383 -0
- package/dist/index-f3092738.js +308 -0
- package/dist/index-f41bdf2a.js +238 -0
- package/dist/index-f5c25d06.js +458 -0
- package/dist/index-f7e0a67b.js +511 -0
- package/dist/index-fafae16f.js +337 -0
- package/dist/index-ffe656da.js +332 -0
- package/dist/index.d.ts +43 -0
- package/dist/index.es.js +51 -0
- package/dist/isObjectLike-1b8bbac2.js +44 -0
- package/dist/jsx-runtime-944c88e2.js +631 -0
- package/dist/provider/NoticeProvider.d.ts +41 -0
- package/dist/provider/ThemeProvider.d.ts +7 -0
- package/dist/provider/useTheme.d.ts +4 -0
- package/dist/types/component.d.ts +16 -0
- package/dist/types/svg.d.ts +4 -0
- package/dist/utils/format.d.ts +7 -0
- package/dist/utils/helper.d.ts +7 -0
- package/dist/utils/locales.d.ts +1 -0
- package/dist/utils/utils.d.ts +2 -0
- package/dist/utils-7e50508b.js +2304 -0
- package/dist/vite.svg +1 -0
- package/package.json +117 -0
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { BUITheme } from "../..";
|
|
2
|
+
import { BUIComponentType } from "../../types/component";
|
|
3
|
+
declare const toastVariants: (props?: ({
|
|
4
|
+
theme?: "light" | "dark" | null | undefined;
|
|
5
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
6
|
+
declare const bgStyles: (props?: ({
|
|
7
|
+
theme?: "light" | "dark" | null | undefined;
|
|
8
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
9
|
+
declare const textStyles: (props?: ({
|
|
10
|
+
theme?: "light" | "dark" | null | undefined;
|
|
11
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
12
|
+
declare const iconstyles: (type: BUIComponentType, theme: BUITheme) => string;
|
|
13
|
+
export { toastVariants, bgStyles, textStyles, iconstyles };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { FC, ReactNode } from "react";
|
|
2
|
+
import { BUITheme } from "../..";
|
|
3
|
+
import { TooltipPlacement } from "./type";
|
|
4
|
+
interface TooltipProps {
|
|
5
|
+
placement: TooltipPlacement;
|
|
6
|
+
flipPlacement?: TooltipPlacement[];
|
|
7
|
+
title?: string;
|
|
8
|
+
content?: ReactNode;
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
isShow?: boolean;
|
|
11
|
+
className?: string;
|
|
12
|
+
hideArrow?: boolean;
|
|
13
|
+
scrollContainer?: HTMLDivElement | null;
|
|
14
|
+
theme?: BUITheme;
|
|
15
|
+
/**
|
|
16
|
+
* @property {number} [y] 控制tooltip到元素的距离
|
|
17
|
+
* */
|
|
18
|
+
y?: number;
|
|
19
|
+
x?: number;
|
|
20
|
+
}
|
|
21
|
+
declare const Tooltip: FC<TooltipProps>;
|
|
22
|
+
export { Tooltip };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export declare enum PLACEMENT {
|
|
2
|
+
top = "top",
|
|
3
|
+
bottom = "bottom",
|
|
4
|
+
topLeft = "top-start",
|
|
5
|
+
topRight = "top-end",
|
|
6
|
+
bottomLeft = "bottom-start",
|
|
7
|
+
bottomRight = "bottom-end",
|
|
8
|
+
left = "left",
|
|
9
|
+
right = "right"
|
|
10
|
+
}
|
|
11
|
+
export declare enum OFFSET {
|
|
12
|
+
top = 0,
|
|
13
|
+
bottom = 0,
|
|
14
|
+
topLeft = -5,
|
|
15
|
+
topRight = 5,
|
|
16
|
+
bottomLeft = -5,
|
|
17
|
+
bottomRight = 5,
|
|
18
|
+
left = 0,
|
|
19
|
+
right = 0
|
|
20
|
+
}
|
|
21
|
+
export declare const PLACEMENT_REVERSE: Record<string, string>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
declare const bgStyles: (props?: ({
|
|
2
|
+
theme?: "light" | "dark" | null | undefined;
|
|
3
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
4
|
+
declare const arrowPositionStyles: (props?: ({
|
|
5
|
+
placement?: "left" | "top" | "right" | "bottom" | "topLeft" | "topRight" | "bottomLeft" | "bottomRight" | null | undefined;
|
|
6
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
7
|
+
declare const popperStyles: (props?: ({
|
|
8
|
+
show?: boolean | null | undefined;
|
|
9
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
10
|
+
export { bgStyles, arrowPositionStyles, popperStyles };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type TooltipPlacement = "top" | "bottom" | "topLeft" | "topRight" | "bottomLeft" | "bottomRight" | "left" | "right";
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { BUITheme } from "../..";
|
|
3
|
+
declare const TYPEOGRAPHY_TAGS: {
|
|
4
|
+
h1: string;
|
|
5
|
+
h2: string;
|
|
6
|
+
h3: string;
|
|
7
|
+
h4: string;
|
|
8
|
+
h5: string;
|
|
9
|
+
h6: string;
|
|
10
|
+
subtitle1: string;
|
|
11
|
+
subtitle2: string;
|
|
12
|
+
subtitle3: string;
|
|
13
|
+
body1: string;
|
|
14
|
+
body2: string;
|
|
15
|
+
body3: string;
|
|
16
|
+
body4: string;
|
|
17
|
+
};
|
|
18
|
+
export type TypographyTag = keyof typeof TYPEOGRAPHY_TAGS;
|
|
19
|
+
export type TypographyWeight = "regular" | "medium" | "bold";
|
|
20
|
+
export interface TypographyProps {
|
|
21
|
+
/**
|
|
22
|
+
* Typography type
|
|
23
|
+
*/
|
|
24
|
+
variant: TypographyTag;
|
|
25
|
+
weight?: TypographyWeight;
|
|
26
|
+
className?: string;
|
|
27
|
+
children?: React.ReactNode;
|
|
28
|
+
theme?: BUITheme;
|
|
29
|
+
component?: React.ElementType;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Primary UI component for user interaction
|
|
33
|
+
*/
|
|
34
|
+
export declare const Typography: ({ variant, weight, className, children, theme: mode, component, ...props }: TypographyProps) => import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { BUITheme } from "../..";
|
|
2
|
+
export type TypographyTagType = "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "p";
|
|
3
|
+
export type TypographyWeight = "regular" | "medium" | "bold";
|
|
4
|
+
export type TypographyVariantsType = "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "subtitle1" | "subtitle2" | "subtitle3" | "body1" | "body2" | "body3" | "body4";
|
|
5
|
+
declare const TypographyVariants: (props: {
|
|
6
|
+
variant: TypographyVariantsType;
|
|
7
|
+
weight: TypographyWeight;
|
|
8
|
+
theme: BUITheme;
|
|
9
|
+
}) => string;
|
|
10
|
+
export default TypographyVariants;
|
|
@@ -0,0 +1,318 @@
|
|
|
1
|
+
module.exports = {
|
|
2
|
+
fontSize: {
|
|
3
|
+
"9xl": "72px",
|
|
4
|
+
"8xl": "64px",
|
|
5
|
+
"7xl": "48px",
|
|
6
|
+
"6xl": "36px",
|
|
7
|
+
"5xl": "32px",
|
|
8
|
+
"4xl": "28px",
|
|
9
|
+
"3xl": "24px",
|
|
10
|
+
"2xl": "22px",
|
|
11
|
+
xl: "20px",
|
|
12
|
+
lg: "18px",
|
|
13
|
+
md: "16px",
|
|
14
|
+
base: "14px",
|
|
15
|
+
sm: "12px",
|
|
16
|
+
xs: "10px"
|
|
17
|
+
},
|
|
18
|
+
extend: {
|
|
19
|
+
display: ["group-hover"],
|
|
20
|
+
boxShadow: {
|
|
21
|
+
card: "0px 0px 24px rgba(240, 242, 250, 0.6)",
|
|
22
|
+
table: "inset 6px 0 8px -3px rgb(0 0 0 / 5%)",
|
|
23
|
+
toast: "0px 2px 16px rgba(0, 0, 0, 0.06)"
|
|
24
|
+
},
|
|
25
|
+
colors: {
|
|
26
|
+
light: {
|
|
27
|
+
primary: {
|
|
28
|
+
DEFAULT: "var(--light-primary-default)",
|
|
29
|
+
60: "var(--light-primary-60)",
|
|
30
|
+
40: "var(--light-primary-40)",
|
|
31
|
+
14: "var(--light-primary-14)",
|
|
32
|
+
10: "var(--light-primary-10)"
|
|
33
|
+
},
|
|
34
|
+
secondary: {
|
|
35
|
+
DEFAULT: "var(--light-secondary-default)",
|
|
36
|
+
14: "var(--light-secondary-14)"
|
|
37
|
+
},
|
|
38
|
+
tertiary: {
|
|
39
|
+
DEFAULT: "var(--light-tertiary-default)",
|
|
40
|
+
14: "var(--light-tertiary-14)"
|
|
41
|
+
},
|
|
42
|
+
success: {
|
|
43
|
+
DEFAULT: "var(--light-success-default)",
|
|
44
|
+
14: "var(--light-success-14)"
|
|
45
|
+
},
|
|
46
|
+
warning: {
|
|
47
|
+
DEFAULT: "var(--light-warning-default)",
|
|
48
|
+
14: "var(--light-warning-14)"
|
|
49
|
+
},
|
|
50
|
+
danger: {
|
|
51
|
+
DEFAULT: "var(--light-danger-default)",
|
|
52
|
+
14: "var(--light-danger-14)"
|
|
53
|
+
},
|
|
54
|
+
green: {
|
|
55
|
+
DEFAULT: "var(--light-green-default)",
|
|
56
|
+
alpha: "var(--light-green-alpha)"
|
|
57
|
+
},
|
|
58
|
+
red: {
|
|
59
|
+
DEFAULT: "var(--light-red-default)",
|
|
60
|
+
alpha: "var(--light-red-alpha)"
|
|
61
|
+
},
|
|
62
|
+
background: "var(--light-background)",
|
|
63
|
+
second: "var(--light-second)",
|
|
64
|
+
label: {
|
|
65
|
+
DEFAULT: "var(--light-label-default)",
|
|
66
|
+
60: "var(--light-label-60)",
|
|
67
|
+
40: "var(--light-label-40)",
|
|
68
|
+
20: "var(--light-label-20)"
|
|
69
|
+
},
|
|
70
|
+
fill: {
|
|
71
|
+
primary: "var(--light-fill-primary)",
|
|
72
|
+
secondary: "var(--light-fill-secondary)",
|
|
73
|
+
tertiary: "var(--light-fill-tertiary)",
|
|
74
|
+
quaternary: "var(--light-fill-quaternary)"
|
|
75
|
+
},
|
|
76
|
+
line: {
|
|
77
|
+
primary: "var(--light-line-primary)",
|
|
78
|
+
secondary: "var(--light-line-secondary)",
|
|
79
|
+
tertiary: "var(--light-line-tertiary)"
|
|
80
|
+
},
|
|
81
|
+
hover: {
|
|
82
|
+
primary: "var(--light-hover-primary)",
|
|
83
|
+
secondary: "var(--light-hover-secondary)",
|
|
84
|
+
tertiary: "var(--light-hover-tertiary)",
|
|
85
|
+
success: "var(--light-hover-success)",
|
|
86
|
+
warning: "var(--light-hover-warning)",
|
|
87
|
+
danger: "var(--light-hover-danger)",
|
|
88
|
+
green: "var(--light-hover-green)",
|
|
89
|
+
red: "var(--light-hover-red)",
|
|
90
|
+
fill: {
|
|
91
|
+
primary: "var(--light-hover-fill-primary)",
|
|
92
|
+
secondary: "var(--light-hover-fill-secondary)",
|
|
93
|
+
tertiary: "var(--light-hover-fill-tertiary)",
|
|
94
|
+
quaternary: "var(--light-hover-fill-quaternary)"
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
disabled: {
|
|
98
|
+
blue: "var(--light-disabled-blue)"
|
|
99
|
+
},
|
|
100
|
+
badge: {
|
|
101
|
+
"primary-bg": "var(--light-badge-primary-bg)",
|
|
102
|
+
"secondary-bg": "var(--light-badge-secondary-bg)",
|
|
103
|
+
"success-bg": "var(--light-badge-success-bg)",
|
|
104
|
+
"warning-bg": "var(--light-badge-warning-bg)",
|
|
105
|
+
"danger-bg": "var(--light-badge-danger-bg)",
|
|
106
|
+
"info-bg": "var(--light-badge-info-bg)"
|
|
107
|
+
},
|
|
108
|
+
pagination: {
|
|
109
|
+
primary: "var(--light-pagination-primary)",
|
|
110
|
+
"primary-hover": "var(--light-pagination-primary-hover)"
|
|
111
|
+
},
|
|
112
|
+
input: {
|
|
113
|
+
primary: "var(--light-input-primary)",
|
|
114
|
+
gray: "var(--light-input-gray)",
|
|
115
|
+
error: "var(--light-input-error)"
|
|
116
|
+
},
|
|
117
|
+
header: {
|
|
118
|
+
bgColor: "var(--light-header-bgColor)"
|
|
119
|
+
},
|
|
120
|
+
text: "var(--light-text)"
|
|
121
|
+
},
|
|
122
|
+
dark: {
|
|
123
|
+
primary: {
|
|
124
|
+
DEFAULT: "var(--dark-primary-default)",
|
|
125
|
+
60: "var(--dark-primary-60)",
|
|
126
|
+
40: "var(--dark-primary-40)",
|
|
127
|
+
14: "var(--dark-primary-14)",
|
|
128
|
+
10: "var(--dark-primary-10)",
|
|
129
|
+
4: "var(--dark-primary-10)"
|
|
130
|
+
},
|
|
131
|
+
secondary: {
|
|
132
|
+
DEFAULT: "var(--dark-secondary-default)",
|
|
133
|
+
14: "var(--dark-secondary-14)"
|
|
134
|
+
},
|
|
135
|
+
tertiary: {
|
|
136
|
+
DEFAULT: "var(--dark-tertiary-default)",
|
|
137
|
+
14: "var(--dark-tertiary-14)"
|
|
138
|
+
},
|
|
139
|
+
success: {
|
|
140
|
+
DEFAULT: "var(--dark-success-default)",
|
|
141
|
+
14: "var(--dark-success-14)"
|
|
142
|
+
},
|
|
143
|
+
warning: {
|
|
144
|
+
DEFAULT: "var(--dark-warning-default)",
|
|
145
|
+
14: "var(--dark-warning-14)"
|
|
146
|
+
},
|
|
147
|
+
danger: {
|
|
148
|
+
DEFAULT: "var(--dark-danger-default)",
|
|
149
|
+
14: "var(--dark-danger-14)"
|
|
150
|
+
},
|
|
151
|
+
green: {
|
|
152
|
+
DEFAULT: "var(--dark-green-default)",
|
|
153
|
+
alpha: "var(--dark-green-alpha)"
|
|
154
|
+
},
|
|
155
|
+
red: {
|
|
156
|
+
DEFAULT: "var(--dark-red-default)",
|
|
157
|
+
alpha: "var(--dark-red-alpha)"
|
|
158
|
+
},
|
|
159
|
+
background: "var(--dark-background)",
|
|
160
|
+
second: "var(--dark-second)",
|
|
161
|
+
label: {
|
|
162
|
+
DEFAULT: "var(--dark-label-default)",
|
|
163
|
+
60: "var(--dark-label-60)",
|
|
164
|
+
40: "var(--dark-label-40)",
|
|
165
|
+
20: "var(--dark-label-20)"
|
|
166
|
+
},
|
|
167
|
+
fill: {
|
|
168
|
+
primary: "var(--dark-fill-primary)",
|
|
169
|
+
secondary: "var(--dark-fill-secondary)",
|
|
170
|
+
tertiary: "var(--dark-fill-tertiary)",
|
|
171
|
+
quaternary: "var(--dark-fill-quaternary)"
|
|
172
|
+
},
|
|
173
|
+
line: {
|
|
174
|
+
primary: "var(--dark-line-primary)",
|
|
175
|
+
secondary: "var(--dark-line-secondary)",
|
|
176
|
+
tertiary: "var(--dark-line-tertiary)"
|
|
177
|
+
},
|
|
178
|
+
hover: {
|
|
179
|
+
primary: "var(--dark-hover-primary)",
|
|
180
|
+
secondary: "var(--dark-hover-secondary)",
|
|
181
|
+
tertiary: "var(--dark-hover-tertiary)",
|
|
182
|
+
success: "var(--dark-hover-success)",
|
|
183
|
+
warning: "var(--dark-hover-warning)",
|
|
184
|
+
danger: "var(--dark-hover-danger)",
|
|
185
|
+
green: "var(--dark-hover-green)",
|
|
186
|
+
red: "var(--dark-hover-red)",
|
|
187
|
+
fill: {
|
|
188
|
+
primary: "var(--dark-hover-fill-primary)",
|
|
189
|
+
secondary: "var(--dark-hover-fill-secondary)",
|
|
190
|
+
tertiary: "var(--dark-hover-fill-tertiary)",
|
|
191
|
+
quaternary: "var(--dark-hover-fill-quaternary)"
|
|
192
|
+
}
|
|
193
|
+
},
|
|
194
|
+
disabled: {
|
|
195
|
+
blue: "var(--dark-disabled-blue)"
|
|
196
|
+
},
|
|
197
|
+
badge: {
|
|
198
|
+
"primary-bg": "var(--dark-badge-primary-bg)",
|
|
199
|
+
"secondary-bg": "var(--dark-badge-secondary-bg)",
|
|
200
|
+
"success-bg": "var(--dark-badge-success-bg)",
|
|
201
|
+
"warning-bg": "var(--dark-badge-warning-bg)",
|
|
202
|
+
"danger-bg": "var(--dark-badge-danger-bg)",
|
|
203
|
+
"info-bg": "var(--dark-badge-info-bg)"
|
|
204
|
+
},
|
|
205
|
+
pagination: {
|
|
206
|
+
primary: "var(--dark-pagination-primary)",
|
|
207
|
+
"primary-hover": "var(--dark-pagination-primary-hover)"
|
|
208
|
+
},
|
|
209
|
+
input: {
|
|
210
|
+
primary: "var(--dark-input-primary)",
|
|
211
|
+
gray: "var(--dark-input-gray)",
|
|
212
|
+
error: "var(--dark-input-error)"
|
|
213
|
+
},
|
|
214
|
+
header: {
|
|
215
|
+
bgColor: "var(--dark-header-bgColor)"
|
|
216
|
+
},
|
|
217
|
+
text: "var(--dark-text)"
|
|
218
|
+
},
|
|
219
|
+
base: {
|
|
220
|
+
primary: {
|
|
221
|
+
DEFAULT: "var(--base-primary-default)",
|
|
222
|
+
60: "var(--base-primary-60)",
|
|
223
|
+
40: "var(--base-primary-40)",
|
|
224
|
+
14: "var(--base-primary-14)",
|
|
225
|
+
10: "var(--base-primary-10)",
|
|
226
|
+
4: "var(--base-primary-10)"
|
|
227
|
+
},
|
|
228
|
+
secondary: {
|
|
229
|
+
DEFAULT: "var(--base-secondary-default)",
|
|
230
|
+
14: "var(--base-secondary-14)"
|
|
231
|
+
},
|
|
232
|
+
tertiary: {
|
|
233
|
+
DEFAULT: "var(--base-tertiary-default)",
|
|
234
|
+
14: "var(--base-tertiary-14)"
|
|
235
|
+
},
|
|
236
|
+
success: {
|
|
237
|
+
DEFAULT: "var(--base-success-default)",
|
|
238
|
+
14: "var(--base-success-14)"
|
|
239
|
+
},
|
|
240
|
+
warning: {
|
|
241
|
+
DEFAULT: "var(--base-warning-default)",
|
|
242
|
+
14: "var(--base-warning-14)"
|
|
243
|
+
},
|
|
244
|
+
danger: {
|
|
245
|
+
DEFAULT: "var(--base-danger-default)",
|
|
246
|
+
14: "var(--base-danger-14)"
|
|
247
|
+
},
|
|
248
|
+
green: {
|
|
249
|
+
DEFAULT: "var(--base-green-default)",
|
|
250
|
+
alpha: "var(--base-green-alpha)"
|
|
251
|
+
},
|
|
252
|
+
red: {
|
|
253
|
+
DEFAULT: "var(--base-red-default)",
|
|
254
|
+
alpha: "var(--base-red-alpha)"
|
|
255
|
+
},
|
|
256
|
+
background: "var(--base-background)",
|
|
257
|
+
second: "var(--base-second)",
|
|
258
|
+
label: {
|
|
259
|
+
DEFAULT: "var(--base-label-default)",
|
|
260
|
+
60: "var(--base-label-60)",
|
|
261
|
+
40: "var(--base-label-40)",
|
|
262
|
+
20: "var(--base-label-20)"
|
|
263
|
+
},
|
|
264
|
+
fill: {
|
|
265
|
+
primary: "var(--base-fill-primary)",
|
|
266
|
+
secondary: "var(--base-fill-secondary)",
|
|
267
|
+
tertiary: "var(--base-fill-tertiary)",
|
|
268
|
+
quaternary: "var(--base-fill-quaternary)"
|
|
269
|
+
},
|
|
270
|
+
line: {
|
|
271
|
+
primary: "var(--base-line-primary)",
|
|
272
|
+
secondary: "var(--base-line-secondary)",
|
|
273
|
+
tertiary: "var(--base-line-tertiary)"
|
|
274
|
+
},
|
|
275
|
+
hover: {
|
|
276
|
+
primary: "var(--base-hover-primary)",
|
|
277
|
+
secondary: "var(--base-hover-secondary)",
|
|
278
|
+
tertiary: "var(--base-hover-tertiary)",
|
|
279
|
+
success: "var(--base-hover-success)",
|
|
280
|
+
warning: "var(--base-hover-warning)",
|
|
281
|
+
danger: "var(--base-hover-danger)",
|
|
282
|
+
green: "var(--base-hover-green)",
|
|
283
|
+
red: "var(--base-hover-red)",
|
|
284
|
+
fill: {
|
|
285
|
+
primary: "var(--base-hover-fill-primary)",
|
|
286
|
+
secondary: "var(--base-hover-fill-secondary)",
|
|
287
|
+
tertiary: "var(--base-hover-fill-tertiary)",
|
|
288
|
+
quaternary: "var(--base-hover-fill-quaternary)"
|
|
289
|
+
}
|
|
290
|
+
},
|
|
291
|
+
disabled: {
|
|
292
|
+
blue: "var(--base-disabled-blue)"
|
|
293
|
+
},
|
|
294
|
+
badge: {
|
|
295
|
+
"primary-bg": "var(--base-badge-primary-bg)",
|
|
296
|
+
"secondary-bg": "var(--base-badge-secondary-bg)",
|
|
297
|
+
"success-bg": "var(--base-badge-success-bg)",
|
|
298
|
+
"warning-bg": "var(--base-badge-warning-bg)",
|
|
299
|
+
"danger-bg": "var(--base-badge-danger-bg)",
|
|
300
|
+
"info-bg": "var(--base-badge-info-bg)"
|
|
301
|
+
},
|
|
302
|
+
pagination: {
|
|
303
|
+
primary: "var(--base-pagination-primary)",
|
|
304
|
+
"primary-hover": "var(--base-pagination-primary-hover)"
|
|
305
|
+
},
|
|
306
|
+
input: {
|
|
307
|
+
primary: "var(--base-input-primary)",
|
|
308
|
+
gray: "var(--base-input-gray)",
|
|
309
|
+
error: "var(--base-input-error)"
|
|
310
|
+
},
|
|
311
|
+
header: {
|
|
312
|
+
bgColor: "var(--base-header-bgColor)"
|
|
313
|
+
},
|
|
314
|
+
text: "var(--base-text)"
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
}
|
|
318
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
declare const useAlign: (target: HTMLDivElement | null) => {
|
|
2
|
+
offset: {
|
|
3
|
+
offsetX: number;
|
|
4
|
+
offsetY: number;
|
|
5
|
+
clientWidth: number;
|
|
6
|
+
clientHeight: number;
|
|
7
|
+
offsetLeft: number;
|
|
8
|
+
offsetRight: number;
|
|
9
|
+
};
|
|
10
|
+
getOffset: (wrapper: HTMLDivElement) => {
|
|
11
|
+
offsetX: number;
|
|
12
|
+
offsetY: number;
|
|
13
|
+
clientWidth: number;
|
|
14
|
+
clientHeight: number;
|
|
15
|
+
offsetLeft: number;
|
|
16
|
+
offsetRight: number;
|
|
17
|
+
};
|
|
18
|
+
resize: () => void;
|
|
19
|
+
};
|
|
20
|
+
export default useAlign;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function useLatest<T>(value: T): import("react").MutableRefObject<T>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { configType } from "../provider/NoticeProvider";
|
|
2
|
+
declare const useNotification: () => {
|
|
3
|
+
methods: {
|
|
4
|
+
info: (config: configType) => void;
|
|
5
|
+
success: (config: configType) => void;
|
|
6
|
+
warning: (config: configType) => void;
|
|
7
|
+
danger: (config: configType) => void;
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
export default useNotification;
|