@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.
Files changed (77) hide show
  1. package/dist/css/semi.css +13 -1
  2. package/dist/css/semi.min.css +1 -1
  3. package/dist/umd/semi-ui.js +259 -134
  4. package/dist/umd/semi-ui.js.map +1 -1
  5. package/dist/umd/semi-ui.min.js +1 -1
  6. package/dist/umd/semi-ui.min.js.map +1 -1
  7. package/lib/es/autoComplete/index.d.ts +36 -11
  8. package/lib/es/button/index.d.ts +0 -1
  9. package/lib/es/button/index.js +1 -2
  10. package/lib/es/calendar/dayCalendar.js +1 -1
  11. package/lib/es/calendar/monthCalendar.js +1 -1
  12. package/lib/es/calendar/rangeCalendar.js +1 -1
  13. package/lib/es/calendar/weekCalendar.js +1 -1
  14. package/lib/es/cascader/index.d.ts +1 -0
  15. package/lib/es/cascader/index.js +15 -3
  16. package/lib/es/collapse/index.js +1 -5
  17. package/lib/es/datePicker/yearAndMonth.d.ts +2 -2
  18. package/lib/es/datePicker/yearAndMonth.js +1 -1
  19. package/lib/es/form/baseForm.d.ts +4 -10
  20. package/lib/es/form/baseForm.js +1 -2
  21. package/lib/es/form/field.d.ts +4 -22
  22. package/lib/es/form/field.js +2 -18
  23. package/lib/es/form/hoc/withField.d.ts +1 -1
  24. package/lib/es/form/hoc/withField.js +0 -3
  25. package/lib/es/iconButton/index.d.ts +0 -1
  26. package/lib/es/iconButton/index.js +0 -1
  27. package/lib/es/locale/localeConsumer.d.ts +5 -5
  28. package/lib/es/modal/useModal/HookModal.d.ts +3 -2
  29. package/lib/es/modal/useModal/index.js +1 -1
  30. package/lib/es/notification/index.d.ts +1 -1
  31. package/lib/es/notification/index.js +1 -1
  32. package/lib/es/popconfirm/index.d.ts +5 -1
  33. package/lib/es/popconfirm/index.js +10 -4
  34. package/lib/es/popover/index.d.ts +3 -1
  35. package/lib/es/popover/index.js +4 -8
  36. package/lib/es/radio/context.d.ts +1 -1
  37. package/lib/es/radio/radio.d.ts +2 -2
  38. package/lib/es/radio/radioGroup.d.ts +4 -4
  39. package/lib/es/rating/index.d.ts +1 -1
  40. package/lib/es/resizeObserver/index.js +1 -0
  41. package/lib/es/scrollList/scrollItem.d.ts +12 -11
  42. package/lib/es/scrollList/scrollItem.js +8 -8
  43. package/lib/es/select/index.js +18 -11
  44. package/lib/es/select/option.js +4 -4
  45. package/lib/es/select/utils.d.ts +1 -1
  46. package/lib/es/select/utils.js +12 -8
  47. package/lib/es/sideSheet/SideSheetContent.d.ts +1 -1
  48. package/lib/es/sideSheet/index.d.ts +3 -3
  49. package/lib/es/steps/basicSteps.js +2 -2
  50. package/lib/es/steps/fillSteps.js +3 -3
  51. package/lib/es/steps/navSteps.js +2 -2
  52. package/lib/es/tabs/TabBar.d.ts +5 -3
  53. package/lib/es/tabs/TabBar.js +12 -4
  54. package/lib/es/tabs/TabPane.d.ts +2 -1
  55. package/lib/es/tabs/TabPane.js +3 -2
  56. package/lib/es/tabs/index.d.ts +3 -1
  57. package/lib/es/tabs/index.js +85 -16
  58. package/lib/es/tabs/interface.d.ts +6 -1
  59. package/lib/es/tagInput/index.d.ts +3 -0
  60. package/lib/es/tagInput/index.js +6 -1
  61. package/lib/es/timePicker/Combobox.d.ts +10 -4
  62. package/lib/es/timePicker/Combobox.js +2 -1
  63. package/lib/es/timePicker/TimePicker.d.ts +1 -1
  64. package/lib/es/tooltip/index.d.ts +3 -0
  65. package/lib/es/tooltip/index.js +3 -0
  66. package/lib/es/tree/interface.d.ts +2 -2
  67. package/lib/es/treeSelect/index.d.ts +2 -11
  68. package/lib/es/treeSelect/index.js +2 -1
  69. package/lib/es/typography/base.d.ts +1 -1
  70. package/lib/es/typography/paragraph.d.ts +1 -1
  71. package/lib/es/typography/text.d.ts +1 -1
  72. package/lib/es/typography/title.d.ts +1 -1
  73. package/lib/es/upload/fileCard.d.ts +3 -18
  74. package/lib/es/upload/index.d.ts +4 -57
  75. package/lib/es/upload/interface.d.ts +56 -0
  76. package/lib/es/upload/interface.js +1 -0
  77. 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.2",
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.2",
23
- "@douyinfe/semi-foundation": "2.1.0-beta.2",
24
- "@douyinfe/semi-icons": "2.1.0-beta.2",
25
- "@douyinfe/semi-illustrations": "2.1.0-beta.2",
26
- "@douyinfe/semi-theme-default": "2.1.0-beta.2",
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": "513b92cb3746033d0b7326485e85c73d80340a0d",
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.2",
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",