@qsxy/element-plus-react 1.0.2 → 1.0.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 (216) hide show
  1. package/dist/Alert/Alert.d.ts +7 -0
  2. package/dist/Alert/Alert.js +98 -0
  3. package/dist/Alert/index.d.ts +2 -0
  4. package/dist/Alert/index.js +1 -0
  5. package/dist/Alert/typings.d.ts +45 -0
  6. package/dist/Alert/typings.js +1 -0
  7. package/dist/Card/Card.js +5 -3
  8. package/dist/Cascader/useCascader.d.ts +0 -14
  9. package/dist/Cascader/useCascader.js +33 -32
  10. package/dist/Checkbox/Checkbox.js +3 -2
  11. package/dist/ConfigProvider/ConfigProvider.js +2 -24
  12. package/dist/ConfigProvider/ConfigProviderContext.js +1 -1
  13. package/dist/ConfigProvider/typings.d.ts +1 -1
  14. package/dist/Container/Main.d.ts +1 -1
  15. package/dist/Container/typings.d.ts +1 -1
  16. package/dist/Dialog/Dialog.js +5 -12
  17. package/dist/Input/Input.js +68 -43
  18. package/dist/Input/TextArea.js +1 -1
  19. package/dist/Input/typings.d.ts +42 -1
  20. package/dist/Input/utils.d.ts +1 -0
  21. package/dist/Input/utils.js +5 -1
  22. package/dist/InputNumber/InputNumber.js +351 -141
  23. package/dist/InputNumber/typings.d.ts +15 -1
  24. package/dist/Loading/Loading.js +5 -2
  25. package/dist/Menu/Menu.js +25 -1
  26. package/dist/Menu/MenuItem.js +4 -2
  27. package/dist/Menu/SubMenu.js +2 -2
  28. package/dist/Menu/SubMenuCollapseTransition.js +14 -9
  29. package/dist/Menu/typings.d.ts +2 -1
  30. package/dist/Message/Message.js +51 -23
  31. package/dist/Message/index.js +8 -10
  32. package/dist/Message/typings.d.ts +8 -5
  33. package/dist/MessageBox/MessageBox.js +52 -30
  34. package/dist/MessageBox/index.d.ts +2 -1
  35. package/dist/MessageBox/index.js +4 -2
  36. package/dist/MessageBox/typings.d.ts +3 -0
  37. package/dist/Notification/Notification.js +26 -19
  38. package/dist/Select/SelectContext.d.ts +2 -1
  39. package/dist/Select/SelectContext.js +2 -1
  40. package/dist/Select/SelectCore.js +13 -7
  41. package/dist/Select/SelectDropdown.js +23 -15
  42. package/dist/Select/index.d.ts +1 -1
  43. package/dist/Select/typings.d.ts +13 -9
  44. package/dist/Select/useSelect.d.ts +13 -10
  45. package/dist/Select/useSelect.js +34 -26
  46. package/dist/Space/Space.d.ts +4 -0
  47. package/dist/Space/Space.js +128 -0
  48. package/dist/Space/SpaceItem.d.ts +7 -0
  49. package/dist/Space/SpaceItem.js +14 -0
  50. package/dist/Space/index.d.ts +3 -0
  51. package/dist/Space/index.js +2 -0
  52. package/dist/Space/typings.d.ts +26 -0
  53. package/dist/Space/typings.js +1 -0
  54. package/dist/Space/useSpace.d.ts +7 -0
  55. package/dist/Space/useSpace.js +104 -0
  56. package/dist/Statistic/Statistic.d.ts +4 -0
  57. package/dist/Statistic/Statistic.js +92 -0
  58. package/dist/Statistic/index.d.ts +2 -0
  59. package/dist/Statistic/index.js +1 -0
  60. package/dist/Statistic/typings.d.ts +28 -0
  61. package/dist/Statistic/typings.js +1 -0
  62. package/dist/Switch/Switch.js +2 -2
  63. package/dist/Table/Table.js +3 -0
  64. package/dist/Table/typings.d.ts +2 -0
  65. package/dist/Tag/typings.d.ts +1 -1
  66. package/dist/Text/Text.d.ts +4 -0
  67. package/dist/Text/Text.js +84 -0
  68. package/dist/Text/index.d.ts +2 -0
  69. package/dist/Text/index.js +1 -0
  70. package/dist/Text/typings.d.ts +15 -0
  71. package/dist/Text/typings.js +1 -0
  72. package/dist/Tree/CollapseTransition.d.ts +7 -0
  73. package/dist/Tree/CollapseTransition.js +60 -0
  74. package/dist/Tree/Tree.d.ts +3 -140
  75. package/dist/Tree/Tree.js +350 -77
  76. package/dist/Tree/TreeContext.d.ts +9 -0
  77. package/dist/Tree/TreeContext.js +14 -0
  78. package/dist/Tree/TreeNode.d.ts +5 -3
  79. package/dist/Tree/TreeNode.js +321 -331
  80. package/dist/Tree/TreeNodeContent.d.ts +9 -0
  81. package/dist/Tree/TreeNodeContent.js +22 -0
  82. package/dist/Tree/index.d.ts +3 -8
  83. package/dist/Tree/index.js +1 -4
  84. package/dist/Tree/model/node.d.ts +62 -0
  85. package/dist/Tree/model/node.js +601 -0
  86. package/dist/Tree/model/tree-store.d.ts +52 -0
  87. package/dist/Tree/model/tree-store.js +510 -0
  88. package/dist/Tree/model/useDragNode.d.ts +30 -0
  89. package/dist/Tree/model/useDragNode.js +293 -0
  90. package/dist/Tree/model/useKeydown.d.ts +0 -0
  91. package/dist/Tree/model/useKeydown.js +104 -0
  92. package/dist/Tree/model/useNodeExpandEventBroadcast.d.ts +15 -0
  93. package/dist/Tree/model/useNodeExpandEventBroadcast.js +54 -0
  94. package/dist/Tree/model/util.d.ts +7 -0
  95. package/dist/Tree/model/util.js +24 -0
  96. package/dist/Tree/typings.d.ts +225 -114
  97. package/dist/TreeSelect/TreeSelect.d.ts +2 -10
  98. package/dist/TreeSelect/TreeSelect.js +90 -566
  99. package/dist/TreeSelect/TreeSelectOption.d.ts +6 -0
  100. package/dist/TreeSelect/TreeSelectOption.js +62 -0
  101. package/dist/TreeSelect/cacheOptions.d.ts +9 -0
  102. package/dist/TreeSelect/cacheOptions.js +22 -0
  103. package/dist/TreeSelect/index.d.ts +0 -1
  104. package/dist/TreeSelect/typings.d.ts +11 -63
  105. package/dist/TreeSelect/useSelect.d.ts +125 -0
  106. package/dist/TreeSelect/useSelect.js +104 -0
  107. package/dist/TreeSelect/useTree.d.ts +130 -0
  108. package/dist/TreeSelect/useTree.js +285 -0
  109. package/dist/TreeSelect/utils.d.ts +10 -0
  110. package/dist/TreeSelect/utils.js +38 -0
  111. package/dist/Upload/UploadContent.js +2 -0
  112. package/dist/Upload/ajax.js +3 -0
  113. package/dist/Upload/typings.d.ts +4 -0
  114. package/dist/Util/aria.js +12 -12
  115. package/dist/Util/base.d.ts +5 -0
  116. package/dist/Util/base.js +140 -1
  117. package/dist/config/Constants.d.ts +3 -0
  118. package/dist/config/Constants.js +8 -0
  119. package/dist/hooks/index.d.ts +1 -0
  120. package/dist/hooks/index.js +1 -0
  121. package/dist/hooks/popperPropsUtils.js +1 -1
  122. package/dist/hooks/treePropsUtils.d.ts +3 -3
  123. package/dist/hooks/treePropsUtils.js +2 -2
  124. package/dist/hooks/useConfigProvider.d.ts +27 -0
  125. package/dist/hooks/useConfigProvider.js +78 -0
  126. package/dist/hooks/useResizeObserver.js +6 -6
  127. package/dist/index.css +1 -1
  128. package/dist/index.d.ts +18 -11
  129. package/dist/index.js +11 -5
  130. package/package.json +1 -1
  131. package/theme-chalk/alert.scss +115 -0
  132. package/theme-chalk/aside.scss +8 -8
  133. package/theme-chalk/button-group.scss +80 -80
  134. package/theme-chalk/button.scss +304 -304
  135. package/theme-chalk/calendar/date-table.scss +164 -164
  136. package/theme-chalk/checkbox.scss +34 -0
  137. package/theme-chalk/color/index.scss +20 -20
  138. package/theme-chalk/common/transition.scss +142 -142
  139. package/theme-chalk/container.scss +14 -14
  140. package/theme-chalk/dark/css-vars.scss +39 -39
  141. package/theme-chalk/dark/var.scss +225 -225
  142. package/theme-chalk/date-picker.scss +12 -12
  143. package/theme-chalk/drawer.scss +1 -0
  144. package/theme-chalk/footer.scss +12 -12
  145. package/theme-chalk/header.scss +12 -12
  146. package/theme-chalk/index.scss +4 -0
  147. package/theme-chalk/input/input-range.scss +2 -1
  148. package/theme-chalk/input/input.scss +439 -424
  149. package/theme-chalk/input-number.bak +172 -0
  150. package/theme-chalk/input-number.scss +192 -172
  151. package/theme-chalk/link.scss +87 -87
  152. package/theme-chalk/main.scss +14 -14
  153. package/theme-chalk/menu.scss +353 -353
  154. package/theme-chalk/message.scss +104 -178
  155. package/theme-chalk/mixins/_button.scss +224 -224
  156. package/theme-chalk/mixins/_col.scss +33 -33
  157. package/theme-chalk/mixins/_var.scss +67 -67
  158. package/theme-chalk/mixins/config.scss +5 -5
  159. package/theme-chalk/mixins/function.scss +99 -99
  160. package/theme-chalk/mixins/mixins.scss +240 -240
  161. package/theme-chalk/mixins/utils.scss +39 -39
  162. package/theme-chalk/notification.bak +156 -0
  163. package/theme-chalk/notification.scss +109 -156
  164. package/theme-chalk/popper.scss +104 -104
  165. package/theme-chalk/radio-button.scss +169 -169
  166. package/theme-chalk/select/index.scss +278 -272
  167. package/theme-chalk/space.scss +20 -0
  168. package/theme-chalk/statistic.scss +35 -0
  169. package/theme-chalk/switch.scss +300 -300
  170. package/theme-chalk/tag.scss +181 -181
  171. package/theme-chalk/text.scss +48 -0
  172. package/theme-chalk/transition.scss +34 -4
  173. package/theme-chalk/tree-select.scss +41 -25
  174. package/theme-chalk/tree.scss +136 -0
  175. package/theme-chalk/var.scss +83 -83
  176. package/dist/Input/Input.1.d.ts +0 -16
  177. package/dist/Input/Input.1.js +0 -376
  178. package/dist/Tree/DirectoryTree.d.ts +0 -15
  179. package/dist/Tree/DirectoryTree.js +0 -183
  180. package/dist/Tree/DropIndicator.d.ts +0 -8
  181. package/dist/Tree/DropIndicator.js +0 -34
  182. package/dist/Tree/Indent.d.ts +0 -9
  183. package/dist/Tree/Indent.js +0 -25
  184. package/dist/Tree/MotionTreeNode.d.ts +0 -14
  185. package/dist/Tree/MotionTreeNode.js +0 -125
  186. package/dist/Tree/NodeList.d.ts +0 -50
  187. package/dist/Tree/NodeList.js +0 -301
  188. package/dist/Tree/RCTree.d.ts +0 -248
  189. package/dist/Tree/RCTree.js +0 -1216
  190. package/dist/Tree/contextTypes.d.ts +0 -69
  191. package/dist/Tree/contextTypes.js +0 -9
  192. package/dist/Tree/typings.tsx--bak +0 -245
  193. package/dist/Tree/useUnmount.d.ts +0 -5
  194. package/dist/Tree/useUnmount.js +0 -34
  195. package/dist/Tree/util.d.ts +0 -51
  196. package/dist/Tree/util.js +0 -303
  197. package/dist/Tree/utils/conductUtil.d.ts +0 -17
  198. package/dist/Tree/utils/conductUtil.js +0 -209
  199. package/dist/Tree/utils/dictUtil.d.ts +0 -13
  200. package/dist/Tree/utils/dictUtil.js +0 -75
  201. package/dist/Tree/utils/diffUtil.d.ts +0 -7
  202. package/dist/Tree/utils/diffUtil.js +0 -48
  203. package/dist/Tree/utils/dropIndicator.d.ts +0 -11
  204. package/dist/Tree/utils/dropIndicator.js +0 -36
  205. package/dist/Tree/utils/iconUtil.d.ts +0 -5
  206. package/dist/Tree/utils/iconUtil.js +0 -62
  207. package/dist/Tree/utils/keyUtil.d.ts +0 -2
  208. package/dist/Tree/utils/keyUtil.js +0 -3
  209. package/dist/Tree/utils/motion.d.ts +0 -10
  210. package/dist/Tree/utils/motion.js +0 -54
  211. package/dist/Tree/utils/pickAttrs.d.ts +0 -11
  212. package/dist/Tree/utils/pickAttrs.js +0 -51
  213. package/dist/Tree/utils/treeUtil.d.ts +0 -86
  214. package/dist/Tree/utils/treeUtil.js +0 -364
  215. package/dist/TreeSelect/Utils.d.ts +0 -3
  216. package/dist/TreeSelect/Utils.js +0 -20
package/dist/index.d.ts CHANGED
@@ -1,17 +1,23 @@
1
1
  import './locale/i18n';
2
- export { Link as ElLink } from './Link';
3
- export type { LinkProps } from './Link';
4
2
  export { Button as ElButton } from './Button';
5
3
  export type { ButtonGroupProps, ButtonProps } from './Button';
4
+ export { Aside as ElAside, Container as ElContainer, Footer as ElFooter, Header as ElHeader, Main as ElMain } from './Container';
5
+ export type { AsideProps, ContainerProps, FooterProps, HeaderProps, MainProps } from './Container';
6
6
  export { Col as ElCol } from './Col';
7
7
  export type { ColProps } from './Col';
8
+ export { Row as ElRow, RowContext } from './Row';
9
+ export type { RowProps } from './Row';
8
10
  export { Icon as ElIcon } from './Icon';
9
11
  export type { IconName, IconPrefix, IconProps } from './Icon';
10
12
  export * from './Icon/IconList';
11
- export { Row as ElRow, RowContext } from './Row';
12
- export type { RowProps } from './Row';
13
+ export { Link as ElLink } from './Link';
14
+ export type { LinkProps } from './Link';
15
+ export { Text as ElText } from './Text';
16
+ export type { TextProps } from './Text';
13
17
  export { Scrollbar as ElScrollbar } from './Scrollbar';
14
18
  export type { BarProps, ScrollbarProps, ScrollbarRef } from './Scrollbar';
19
+ export { Space as ElSpace } from './Space';
20
+ export type { SpaceProps } from './Space';
15
21
  export { Popper as ElPopper } from './Popper';
16
22
  export type { PopperOptionRef, PopperOptions, PopperProps } from './Popper';
17
23
  export { Transition as ElTransition } from './Transition';
@@ -33,7 +39,7 @@ export type { InputProps, InputRangeProps, InputRef, TextareaProps, TextareaRef
33
39
  export { InputNumber as ElInputNumber } from './InputNumber';
34
40
  export type { InputNumberProps, InputNumberRef } from './InputNumber';
35
41
  export { Option as ElOption, OptionGroup as ElOptionGroup, Select as ElSelect } from './Select';
36
- export type { SelectOptionGroupProps, SelectOptionProps, SelectProps, SelectRef } from './Select';
42
+ export type { OptionData, SelectOptionGroupProps, SelectOptionProps, SelectProps, SelectRef } from './Select';
37
43
  export { Calendar, CalendarContext } from './Calendar';
38
44
  export type { DateRangeType, DateType } from './Calendar';
39
45
  export { DatePicker as ElDatePicker } from './DatePicker';
@@ -54,8 +60,6 @@ export { Badge as ElBadge } from './Badge';
54
60
  export type { BadgeProps } from './Badge';
55
61
  export { Card as ElCard } from './Card';
56
62
  export type { CardProps } from './Card';
57
- export { Aside as ElAside, Container as ElContainer, Footer as ElFooter, Header as ElHeader, Main as ElMain } from './Container';
58
- export type { AsideProps, ContainerProps, FooterProps, HeaderProps, MainProps } from './Container';
59
63
  export { Carousel as ElCarousel, CarouselItem as ElCarouselItem } from './Carousel';
60
64
  export type { CarouselItemProps, CarouselProps, CarouselRef } from './Carousel';
61
65
  export { Collapse as ElCollapse, CollapseItem as ElCollapseItem } from './Collapse';
@@ -66,16 +70,17 @@ export { Pagination as ElPagination } from './Pagination';
66
70
  export type { PageType, PaginationProps, PaginationRef } from './Pagination';
67
71
  export { Progress as ElProgress } from './Progress';
68
72
  export type { PropgressProps } from './Progress';
73
+ export { Statistic as ElStatistic } from './Statistic';
74
+ export type { StatisticProps, StatisticRef } from './Statistic';
69
75
  export { Table as ElTable, TableColumn as ElTableColumn } from './Table';
70
76
  export type { RenderCell, TableColumnCtx, TableColumnProps, TableProps, TableRef, TableSort } from './Table';
71
77
  export { Tag as ElTag } from './Tag';
72
78
  export type { TagProps } from './Tag';
73
79
  export { TimeLine as ElTimeLine, TimeLineItem as ElTimeLineItem } from './TimeLine';
74
80
  export type { TimeLineItemProps, TimeLineProps } from './TimeLine';
75
- export { DirectoryTree as ElDirectoryTree, Tree as ElTree } from './Tree';
76
- export type { BasicDataNode, DataNode, DirectoryTreeExpandAction, DirectoryTreeProps, EventDataNode, Key, TreeProps, } from './Tree';
81
+ export { Tree as ElTree } from './Tree';
82
+ export type { AllowDragFunction, AllowDropFunction, AllowDropType, FilterNodeMethodFunction, LoadFunction, NodeDropType, TreeNode, TreeNodeData, TreeNodeProps, TreeOptionProps, TreeProps, TreeRef, TreeStore, } from './Tree';
77
83
  export { TreeSelect as ElTreeSelect } from './TreeSelect';
78
- export type { SelectInfo, TreeSelectProps, TreeSelectRef } from './TreeSelect';
79
84
  export { Breadcrumb as ElBreadcrumb, BreadcrumbItem as ElBreadcrumbItem } from './Breadcrumb';
80
85
  export type { BreadcrumbItemProps, BreadcrumbProps } from './Breadcrumb';
81
86
  export { Dropdown as ElDropdown, DropdownItem as ElDropdownItem, DropdownMenu as ElDropdownMenu } from './Dropdown';
@@ -88,6 +93,8 @@ export { Empty as ElEmpty } from './Empty';
88
93
  export type { IEmptyProps } from './Empty';
89
94
  export { Skeleton as ElSkeleton, SkeletonItem as ElSkeletonItem } from './Skeleton';
90
95
  export type { SkeletonItemProps, SkeletonProps } from './Skeleton';
96
+ export { Alert as ElAlert } from './Alert';
97
+ export type { AlertProps } from './Alert';
91
98
  export { Dialog as ElDialog } from './Dialog';
92
99
  export type { DialogBeforeCloseFn, DialogProps } from './Dialog';
93
100
  export { Drawer as ElDrawer } from './Drawer';
@@ -109,7 +116,7 @@ export type { PopoverProps } from './Popover';
109
116
  export { Divider as ElDivider } from './Divider';
110
117
  export type { DividerProps } from './Divider';
111
118
  export { PopupManager, download, genFileId, generateTree, getScrollWidth, isEmpty, isNotEmpty, randomCode } from './Util';
112
- export { htmlInputAttrs, htmlInputEvents, htmlInputProps, partitionAnimationProps, partitionHTMLProps, partitionPopperPropsUtils, partitionTreePropsUtils, prefix, useChildrenInstance, useClassNames, useClickOutside, useComponentWillMount, useControlled, useDisabled, useForceUpdate, useSize, } from './hooks';
119
+ export { htmlInputAttrs, htmlInputEvents, htmlInputProps, partitionAnimationProps, partitionHTMLProps, partitionPopperPropsUtils, partitionTreePropsUtils, prefix, useChildrenInstance, useClassNames, useClickOutside, useComponentWillMount, useConfigProvider, useControlled, useDisabled, useForceUpdate, useSize, } from './hooks';
113
120
  export type { AnimationEventProps, BaseProps, FormControlBaseProps, NativeProps, StandardProps, TooltipBaseProps, TypeAttributes } from './types/common';
114
121
  /** 全局配置 */
115
122
  export { ConfigProvider as ElConfigProvider } from './ConfigProvider';
package/dist/index.js CHANGED
@@ -1,13 +1,16 @@
1
1
  import "./locale/i18n";
2
2
 
3
3
  /* Basic 基础组件 */
4
- export { Link as ElLink } from "./Link";
5
4
  export { Button as ElButton } from "./Button";
5
+ export { Aside as ElAside, Container as ElContainer, Footer as ElFooter, Header as ElHeader, Main as ElMain } from "./Container";
6
6
  export { Col as ElCol } from "./Col";
7
+ export { Row as ElRow, RowContext } from "./Row";
7
8
  export { Icon as ElIcon } from "./Icon";
8
9
  export * from "./Icon/IconList";
9
- export { Row as ElRow, RowContext } from "./Row";
10
+ export { Link as ElLink } from "./Link";
11
+ export { Text as ElText } from "./Text";
10
12
  export { Scrollbar as ElScrollbar } from "./Scrollbar";
13
+ export { Space as ElSpace } from "./Space";
11
14
  export { Popper as ElPopper } from "./Popper";
12
15
  export { Transition as ElTransition } from "./Transition";
13
16
  /* Form 表单组件 */
@@ -31,17 +34,19 @@ export { Upload as ElUpload } from "./Upload";
31
34
  export { Avatar as ElAvatar } from "./Avatar";
32
35
  export { Badge as ElBadge } from "./Badge";
33
36
  export { Card as ElCard } from "./Card";
34
- export { Aside as ElAside, Container as ElContainer, Footer as ElFooter, Header as ElHeader, Main as ElMain } from "./Container";
35
37
  export { Carousel as ElCarousel, CarouselItem as ElCarouselItem } from "./Carousel";
36
38
  export { Collapse as ElCollapse, CollapseItem as ElCollapseItem } from "./Collapse";
37
39
  export { Descriptions as ElDescriptions, DescriptionsItem as ElDescriptionsItem } from "./Descriptions";
38
40
  export { Pagination as ElPagination } from "./Pagination";
39
41
  export { Progress as ElProgress } from "./Progress";
42
+ export { Statistic as ElStatistic } from "./Statistic";
40
43
  export { Table as ElTable, TableColumn as ElTableColumn } from "./Table";
41
44
  export { Tag as ElTag } from "./Tag";
42
45
  export { TimeLine as ElTimeLine, TimeLineItem as ElTimeLineItem } from "./TimeLine";
43
- export { DirectoryTree as ElDirectoryTree, Tree as ElTree /* , TreeNode */ } from "./Tree";
46
+ export { Tree as ElTree } from "./Tree";
44
47
  export { TreeSelect as ElTreeSelect } from "./TreeSelect";
48
+ // export type { SelectInfo, TreeSelectProps, TreeSelectRef } from './TreeSelect';
49
+
45
50
  // export { VirtualList } from './VirtualList';
46
51
  // export type { ListProps, ListRef, ScrollTo } from './VirtualList';
47
52
 
@@ -53,6 +58,7 @@ export { TabPane as ElTabPane, Tabs as ElTabs } from "./Tabs";
53
58
  export { Empty as ElEmpty } from "./Empty";
54
59
  export { Skeleton as ElSkeleton, SkeletonItem as ElSkeletonItem } from "./Skeleton";
55
60
  /* Feedback 反馈组件 */
61
+ export { Alert as ElAlert } from "./Alert";
56
62
  export { Dialog as ElDialog } from "./Dialog";
57
63
  export { Drawer as ElDrawer } from "./Drawer";
58
64
  export { Loading as ElLoading } from "./Loading";
@@ -66,7 +72,7 @@ export { Popover as ElPopover } from "./Popover";
66
72
  export { Divider as ElDivider } from "./Divider";
67
73
  /* 工具库与hooks */
68
74
  export { PopupManager, download, genFileId, generateTree, getScrollWidth, isEmpty, isNotEmpty, randomCode } from "./Util";
69
- export { htmlInputAttrs, htmlInputEvents, htmlInputProps, partitionAnimationProps, partitionHTMLProps, partitionPopperPropsUtils, partitionTreePropsUtils, prefix, useChildrenInstance, useClassNames, useClickOutside, useComponentWillMount, useControlled, useDisabled, useForceUpdate, useSize } from "./hooks";
75
+ export { htmlInputAttrs, htmlInputEvents, htmlInputProps, partitionAnimationProps, partitionHTMLProps, partitionPopperPropsUtils, partitionTreePropsUtils, prefix, useChildrenInstance, useClassNames, useClickOutside, useComponentWillMount, useConfigProvider, useControlled, useDisabled, useForceUpdate, useSize } from "./hooks";
70
76
 
71
77
  /* 通用types */
72
78
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qsxy/element-plus-react",
3
- "version": "1.0.2",
3
+ "version": "1.0.3",
4
4
  "description": "element-plus-react",
5
5
  "module": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -0,0 +1,115 @@
1
+ @use 'mixins/mixins' as *;
2
+ @use 'mixins/var' as *;
3
+ @use 'common/var' as *;
4
+
5
+ @include b(alert) {
6
+ @include set-component-css-var('alert', $alert);
7
+
8
+ width: 100%;
9
+ padding: getCssVar('alert', 'padding');
10
+ margin: 0;
11
+ box-sizing: border-box;
12
+ border-radius: getCssVar('alert', 'border-radius-base');
13
+ position: relative;
14
+ background-color: getCssVar('color', 'white');
15
+ overflow: hidden;
16
+ opacity: 1;
17
+ display: flex;
18
+ align-items: center;
19
+ transition: opacity getCssVar('transition-duration', 'fast');
20
+
21
+ @include when(light) {
22
+ .#{$namespace}-alert__close-btn {
23
+ color: getCssVar('text-color', 'placeholder');
24
+ }
25
+ }
26
+
27
+ @include when(dark) {
28
+ .#{$namespace}-alert__close-btn {
29
+ color: getCssVar('color', 'white');
30
+ }
31
+ .#{$namespace}-alert__description {
32
+ color: getCssVar('color', 'white');
33
+ }
34
+ }
35
+
36
+ @include when(center) {
37
+ justify-content: center;
38
+ }
39
+
40
+ @each $type in (primary, success, info, warning, error) {
41
+ @include m($type) {
42
+ @include css-var-from-global(
43
+ ('alert', 'bg-color'),
44
+ ('color', $type, 'light-9')
45
+ );
46
+
47
+ &.is-light {
48
+ background-color: getCssVar('alert', 'bg-color');
49
+ color: getCssVar('color', $type);
50
+
51
+ .#{$namespace}-alert__description {
52
+ color: getCssVar('color', $type);
53
+ }
54
+ }
55
+
56
+ &.is-dark {
57
+ background-color: getCssVar('color', $type);
58
+ color: getCssVar('color', 'white');
59
+ }
60
+ }
61
+ }
62
+
63
+ @include e(content) {
64
+ display: flex;
65
+ flex-direction: column;
66
+ gap: 4px;
67
+ }
68
+
69
+ & .#{$namespace}-alert__icon {
70
+ font-size: getCssVar('alert', 'icon-size');
71
+ width: getCssVar('alert', 'icon-size');
72
+ margin-right: 8px;
73
+
74
+ @include when(big) {
75
+ font-size: getCssVar('alert', 'icon-large-size');
76
+ width: getCssVar('alert', 'icon-large-size');
77
+ margin-right: 12px;
78
+ }
79
+ }
80
+
81
+ @include e(title) {
82
+ font-size: getCssVar('alert', 'title-font-size');
83
+ line-height: 24px;
84
+
85
+ &.with-description {
86
+ font-size: getCssVar('alert', 'title-with-description-font-size');
87
+ }
88
+ }
89
+
90
+ & .#{$namespace}-alert__description {
91
+ font-size: getCssVar('alert', 'description-font-size');
92
+ margin: 0;
93
+ }
94
+
95
+ & .#{$namespace}-alert__close-btn {
96
+ font-size: getCssVar('alert', 'close-font-size');
97
+ opacity: 1;
98
+ position: absolute;
99
+ top: 12px;
100
+ right: 16px;
101
+ cursor: pointer;
102
+
103
+ @include when(customed) {
104
+ font-style: normal;
105
+ font-size: getCssVar('alert', 'close-customed-font-size');
106
+ line-height: 24px;
107
+ top: 8px;
108
+ }
109
+ }
110
+ }
111
+
112
+ .#{$namespace}-alert-fade-enter-from,
113
+ .#{$namespace}-alert-fade-leave-active {
114
+ opacity: 0;
115
+ }
@@ -1,8 +1,8 @@
1
- @use 'mixins/mixins' as *;
2
-
3
- @include b(aside) {
4
- overflow: auto;
5
- box-sizing: border-box;
6
- flex-shrink: 0;
7
- width: var(#{getCssVarName('aside', 'width')}, 300px);
8
- }
1
+ @use 'mixins/mixins' as *;
2
+
3
+ @include b(aside) {
4
+ overflow: auto;
5
+ box-sizing: border-box;
6
+ flex-shrink: 0;
7
+ width: var(#{getCssVarName('aside', 'width')}, 300px);
8
+ }
@@ -1,80 +1,80 @@
1
- @use 'sass:map';
2
-
3
- @use 'common/var' as *;
4
- @use 'mixins/mixins' as *;
5
- @use 'mixins/utils' as *;
6
-
7
- @include b(button-group) {
8
- display: inline-block;
9
- vertical-align: middle;
10
- @include utils-clearfix;
11
-
12
- & > .#{$namespace}-button {
13
- float: left;
14
- position: relative;
15
- & + .#{$namespace}-button {
16
- margin-left: 0;
17
- }
18
- &:first-child {
19
- border-top-right-radius: 0;
20
- border-bottom-right-radius: 0;
21
- }
22
- &:last-child {
23
- border-top-left-radius: 0;
24
- border-bottom-left-radius: 0;
25
- }
26
- &:first-child:last-child {
27
- border-top-right-radius: map.get($button-border-radius, 'default');
28
- border-bottom-right-radius: map.get($button-border-radius, 'default');
29
- border-top-left-radius: map.get($button-border-radius, 'default');
30
- border-bottom-left-radius: map.get($button-border-radius, 'default');
31
-
32
- &.is-round {
33
- border-radius: getCssVar('border-radius', 'round');
34
- }
35
-
36
- &.is-circle {
37
- border-radius: 50%;
38
- }
39
- }
40
- &:not(:first-child):not(:last-child) {
41
- border-radius: 0;
42
- }
43
- &:not(:last-child) {
44
- margin-right: -1px;
45
- }
46
-
47
- &:hover,
48
- &:focus,
49
- &:active {
50
- z-index: 1;
51
- }
52
-
53
- @include when(active) {
54
- z-index: 1;
55
- }
56
- }
57
-
58
- & > .#{$namespace}-dropdown {
59
- & > .#{$namespace}-button {
60
- border-top-left-radius: 0;
61
- border-bottom-left-radius: 0;
62
- border-left-color: getCssVar('button', 'divide-border-color');
63
- }
64
- }
65
-
66
- @each $type in (primary, success, warning, danger, info) {
67
- .#{$namespace}-button--#{$type} {
68
- &:first-child {
69
- border-right-color: getCssVar('button', 'divide-border-color');
70
- }
71
- &:last-child {
72
- border-left-color: getCssVar('button', 'divide-border-color');
73
- }
74
- &:not(:first-child):not(:last-child) {
75
- border-left-color: getCssVar('button', 'divide-border-color');
76
- border-right-color: getCssVar('button', 'divide-border-color');
77
- }
78
- }
79
- }
80
- }
1
+ @use 'sass:map';
2
+
3
+ @use 'common/var' as *;
4
+ @use 'mixins/mixins' as *;
5
+ @use 'mixins/utils' as *;
6
+
7
+ @include b(button-group) {
8
+ display: inline-block;
9
+ vertical-align: middle;
10
+ @include utils-clearfix;
11
+
12
+ & > .#{$namespace}-button {
13
+ float: left;
14
+ position: relative;
15
+ & + .#{$namespace}-button {
16
+ margin-left: 0;
17
+ }
18
+ &:first-child {
19
+ border-top-right-radius: 0;
20
+ border-bottom-right-radius: 0;
21
+ }
22
+ &:last-child {
23
+ border-top-left-radius: 0;
24
+ border-bottom-left-radius: 0;
25
+ }
26
+ &:first-child:last-child {
27
+ border-top-right-radius: map.get($button-border-radius, 'default');
28
+ border-bottom-right-radius: map.get($button-border-radius, 'default');
29
+ border-top-left-radius: map.get($button-border-radius, 'default');
30
+ border-bottom-left-radius: map.get($button-border-radius, 'default');
31
+
32
+ &.is-round {
33
+ border-radius: getCssVar('border-radius', 'round');
34
+ }
35
+
36
+ &.is-circle {
37
+ border-radius: 50%;
38
+ }
39
+ }
40
+ &:not(:first-child):not(:last-child) {
41
+ border-radius: 0;
42
+ }
43
+ &:not(:last-child) {
44
+ margin-right: -1px;
45
+ }
46
+
47
+ &:hover,
48
+ &:focus,
49
+ &:active {
50
+ z-index: 1;
51
+ }
52
+
53
+ @include when(active) {
54
+ z-index: 1;
55
+ }
56
+ }
57
+
58
+ & > .#{$namespace}-dropdown {
59
+ & > .#{$namespace}-button {
60
+ border-top-left-radius: 0;
61
+ border-bottom-left-radius: 0;
62
+ border-left-color: getCssVar('button', 'divide-border-color');
63
+ }
64
+ }
65
+
66
+ @each $type in (primary, success, warning, danger, info) {
67
+ .#{$namespace}-button--#{$type} {
68
+ &:first-child {
69
+ border-right-color: getCssVar('button', 'divide-border-color');
70
+ }
71
+ &:last-child {
72
+ border-left-color: getCssVar('button', 'divide-border-color');
73
+ }
74
+ &:not(:first-child):not(:last-child) {
75
+ border-left-color: getCssVar('button', 'divide-border-color');
76
+ border-right-color: getCssVar('button', 'divide-border-color');
77
+ }
78
+ }
79
+ }
80
+ }