@douyinfe/semi-ui 2.1.0-beta.2 → 2.1.0-beta.3
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/css/semi.css +13 -1
- package/dist/css/semi.min.css +1 -1
- package/dist/umd/semi-ui.js +259 -134
- package/dist/umd/semi-ui.js.map +1 -1
- package/dist/umd/semi-ui.min.js +1 -1
- package/dist/umd/semi-ui.min.js.map +1 -1
- package/lib/es/autoComplete/index.d.ts +36 -11
- package/lib/es/button/index.d.ts +0 -1
- package/lib/es/button/index.js +1 -2
- package/lib/es/calendar/dayCalendar.js +1 -1
- package/lib/es/calendar/monthCalendar.js +1 -1
- package/lib/es/calendar/rangeCalendar.js +1 -1
- package/lib/es/calendar/weekCalendar.js +1 -1
- package/lib/es/cascader/index.d.ts +1 -0
- package/lib/es/cascader/index.js +15 -3
- package/lib/es/collapse/index.js +1 -5
- package/lib/es/datePicker/yearAndMonth.d.ts +2 -2
- package/lib/es/datePicker/yearAndMonth.js +1 -1
- package/lib/es/form/baseForm.d.ts +4 -10
- package/lib/es/form/baseForm.js +1 -2
- package/lib/es/form/field.d.ts +4 -22
- package/lib/es/form/field.js +2 -18
- package/lib/es/form/hoc/withField.d.ts +1 -1
- package/lib/es/form/hoc/withField.js +0 -3
- package/lib/es/iconButton/index.d.ts +0 -1
- package/lib/es/iconButton/index.js +0 -1
- package/lib/es/locale/localeConsumer.d.ts +5 -5
- package/lib/es/modal/useModal/HookModal.d.ts +3 -2
- package/lib/es/modal/useModal/index.js +1 -1
- package/lib/es/notification/index.d.ts +1 -1
- package/lib/es/notification/index.js +1 -1
- package/lib/es/popconfirm/index.d.ts +5 -1
- package/lib/es/popconfirm/index.js +10 -4
- package/lib/es/popover/index.d.ts +3 -1
- package/lib/es/popover/index.js +4 -8
- package/lib/es/radio/context.d.ts +1 -1
- package/lib/es/radio/radio.d.ts +2 -2
- package/lib/es/radio/radioGroup.d.ts +4 -4
- package/lib/es/rating/index.d.ts +1 -1
- package/lib/es/resizeObserver/index.js +1 -0
- package/lib/es/scrollList/scrollItem.d.ts +12 -11
- package/lib/es/scrollList/scrollItem.js +8 -8
- package/lib/es/select/index.js +18 -11
- package/lib/es/select/option.js +4 -4
- package/lib/es/select/utils.d.ts +1 -1
- package/lib/es/select/utils.js +12 -8
- package/lib/es/sideSheet/SideSheetContent.d.ts +1 -1
- package/lib/es/sideSheet/index.d.ts +3 -3
- package/lib/es/steps/basicSteps.js +2 -2
- package/lib/es/steps/fillSteps.js +3 -3
- package/lib/es/steps/navSteps.js +2 -2
- package/lib/es/tabs/TabBar.d.ts +5 -3
- package/lib/es/tabs/TabBar.js +12 -4
- package/lib/es/tabs/TabPane.d.ts +2 -1
- package/lib/es/tabs/TabPane.js +3 -2
- package/lib/es/tabs/index.d.ts +3 -1
- package/lib/es/tabs/index.js +85 -16
- package/lib/es/tabs/interface.d.ts +6 -1
- package/lib/es/tagInput/index.d.ts +3 -0
- package/lib/es/tagInput/index.js +6 -1
- package/lib/es/timePicker/Combobox.d.ts +10 -4
- package/lib/es/timePicker/Combobox.js +2 -1
- package/lib/es/timePicker/TimePicker.d.ts +1 -1
- package/lib/es/tooltip/index.d.ts +3 -0
- package/lib/es/tooltip/index.js +3 -0
- package/lib/es/tree/interface.d.ts +2 -2
- package/lib/es/treeSelect/index.d.ts +2 -11
- package/lib/es/treeSelect/index.js +2 -1
- package/lib/es/typography/base.d.ts +1 -1
- package/lib/es/typography/paragraph.d.ts +1 -1
- package/lib/es/typography/text.d.ts +1 -1
- package/lib/es/typography/title.d.ts +1 -1
- package/lib/es/upload/fileCard.d.ts +3 -18
- package/lib/es/upload/index.d.ts +4 -57
- package/lib/es/upload/interface.d.ts +56 -0
- package/lib/es/upload/interface.js +1 -0
- package/package.json +9 -8
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { ReactNode, CSSProperties, MouseEvent } from 'react';
|
|
2
|
+
import { BaseFileItem } from '@douyinfe/semi-foundation/lib/es/upload/foundation';
|
|
3
|
+
import { strings } from '@douyinfe/semi-foundation/lib/es/upload/constants';
|
|
4
|
+
import { ArrayElement } from '../_base/base';
|
|
5
|
+
export declare type PromptPositionType = ArrayElement<typeof strings.PROMPT_POSITION>;
|
|
6
|
+
export declare type UploadListType = ArrayElement<typeof strings.LIST_TYPE>;
|
|
7
|
+
export interface BeforeUploadProps {
|
|
8
|
+
file: FileItem;
|
|
9
|
+
fileList: Array<FileItem>;
|
|
10
|
+
}
|
|
11
|
+
export interface AfterUploadProps {
|
|
12
|
+
file: FileItem;
|
|
13
|
+
fileList: Array<FileItem>;
|
|
14
|
+
response: any;
|
|
15
|
+
}
|
|
16
|
+
export interface OnChangeProps {
|
|
17
|
+
fileList: Array<FileItem>;
|
|
18
|
+
currentFile: FileItem;
|
|
19
|
+
}
|
|
20
|
+
export interface customRequestArgs {
|
|
21
|
+
fileName: string;
|
|
22
|
+
data: Record<string, any>;
|
|
23
|
+
file: FileItem;
|
|
24
|
+
fileInstance: File;
|
|
25
|
+
onProgress: (event: {
|
|
26
|
+
total: number;
|
|
27
|
+
loaded: number;
|
|
28
|
+
}) => any;
|
|
29
|
+
onError: (userXhr: {
|
|
30
|
+
status?: number;
|
|
31
|
+
}, e: Event) => any;
|
|
32
|
+
onSuccess: (response: any, e: Event) => any;
|
|
33
|
+
withCredentials: boolean;
|
|
34
|
+
action: string;
|
|
35
|
+
}
|
|
36
|
+
export interface CustomError extends Error {
|
|
37
|
+
status: number;
|
|
38
|
+
method: string;
|
|
39
|
+
url: string;
|
|
40
|
+
}
|
|
41
|
+
export interface FileItem extends BaseFileItem {
|
|
42
|
+
validateMessage?: ReactNode;
|
|
43
|
+
}
|
|
44
|
+
export interface RenderFileItemProps extends FileItem {
|
|
45
|
+
previewFile?: (fileItem: RenderFileItemProps) => ReactNode;
|
|
46
|
+
listType: UploadListType;
|
|
47
|
+
onRemove: (props: RenderFileItemProps, e: MouseEvent) => void;
|
|
48
|
+
onRetry: (props: RenderFileItemProps, e: MouseEvent) => void;
|
|
49
|
+
onReplace: (props: RenderFileItemProps, e: MouseEvent) => void;
|
|
50
|
+
key: string;
|
|
51
|
+
showRetry: boolean;
|
|
52
|
+
showReplace: boolean;
|
|
53
|
+
style?: CSSProperties;
|
|
54
|
+
disabled: boolean;
|
|
55
|
+
onPreviewClick: () => void;
|
|
56
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@douyinfe/semi-ui",
|
|
3
|
-
"version": "2.1.0-beta.
|
|
3
|
+
"version": "2.1.0-beta.3",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "lib/es/index.js",
|
|
6
6
|
"module": "lib/es/index.js",
|
|
@@ -19,11 +19,12 @@
|
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@babel/runtime-corejs3": "^7.15.4",
|
|
22
|
-
"@douyinfe/semi-animation-react": "2.1.0-beta.
|
|
23
|
-
"@douyinfe/semi-foundation": "2.1.0-beta.
|
|
24
|
-
"@douyinfe/semi-icons": "2.1.0-beta.
|
|
25
|
-
"@douyinfe/semi-illustrations": "2.1.0-beta.
|
|
26
|
-
"@douyinfe/semi-theme-default": "2.1.0-beta.
|
|
22
|
+
"@douyinfe/semi-animation-react": "2.1.0-beta.3",
|
|
23
|
+
"@douyinfe/semi-foundation": "2.1.0-beta.3",
|
|
24
|
+
"@douyinfe/semi-icons": "2.1.0-beta.3",
|
|
25
|
+
"@douyinfe/semi-illustrations": "2.1.0-beta.3",
|
|
26
|
+
"@douyinfe/semi-theme-default": "2.1.0-beta.3",
|
|
27
|
+
"@types/react-window": "^1.8.2",
|
|
27
28
|
"async-validator": "^3.5.0",
|
|
28
29
|
"classnames": "^2.2.6",
|
|
29
30
|
"copy-text-to-clipboard": "^2.1.1",
|
|
@@ -64,13 +65,13 @@
|
|
|
64
65
|
],
|
|
65
66
|
"author": "",
|
|
66
67
|
"license": "MIT",
|
|
67
|
-
"gitHead": "
|
|
68
|
+
"gitHead": "e0c6552e86f1f87724110cfcf2e70609eb407a3e",
|
|
68
69
|
"devDependencies": {
|
|
69
70
|
"@babel/plugin-proposal-decorators": "^7.15.8",
|
|
70
71
|
"@babel/plugin-transform-runtime": "^7.15.8",
|
|
71
72
|
"@babel/preset-env": "^7.15.8",
|
|
72
73
|
"@babel/preset-react": "^7.14.5",
|
|
73
|
-
"@douyinfe/semi-scss-compile": "2.1.0-beta.
|
|
74
|
+
"@douyinfe/semi-scss-compile": "2.1.0-beta.3",
|
|
74
75
|
"@storybook/addon-knobs": "^6.3.1",
|
|
75
76
|
"babel-loader": "^8.2.2",
|
|
76
77
|
"case-sensitive-paths-webpack-plugin": "^2.4.0",
|