@agentscope-ai/design 1.0.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.
Files changed (398) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +85 -0
  3. package/dist/antd/styles/button.style.d.ts +47 -0
  4. package/dist/antd/styles/button.style.js +32 -0
  5. package/dist/antd/styles/dropdown.style.d.ts +15 -0
  6. package/dist/antd/styles/dropdown.style.js +16 -0
  7. package/dist/antd/styles/index.style.d.ts +19 -0
  8. package/dist/antd/styles/index.style.js +50 -0
  9. package/dist/antd/styles/message.style.d.ts +5 -0
  10. package/dist/antd/styles/message.style.js +10 -0
  11. package/dist/antd/styles/notification.style.d.ts +46 -0
  12. package/dist/antd/styles/notification.style.js +29 -0
  13. package/dist/antd/styles/popover.style.d.ts +13 -0
  14. package/dist/antd/styles/popover.style.js +14 -0
  15. package/dist/antd/styles/radio.style.d.ts +7 -0
  16. package/dist/antd/styles/radio.style.js +10 -0
  17. package/dist/antd/styles/segment.style.d.ts +7 -0
  18. package/dist/antd/styles/segment.style.js +12 -0
  19. package/dist/antd/styles/select.style.d.ts +6 -0
  20. package/dist/antd/styles/select.style.js +11 -0
  21. package/dist/antd/styles/slider.style.d.ts +22 -0
  22. package/dist/antd/styles/slider.style.js +21 -0
  23. package/dist/antd/styles/table.style.d.ts +5 -0
  24. package/dist/antd/styles/table.style.js +10 -0
  25. package/dist/antd/styles/tooltip.style.d.ts +8 -0
  26. package/dist/antd/styles/tooltip.style.js +11 -0
  27. package/dist/antd/themes/bailianDarkTheme.json +173 -0
  28. package/dist/antd/themes/bailianTheme.json +170 -0
  29. package/dist/antd/themes/blackTheme.json +12 -0
  30. package/dist/antd/themes/carbonDarkTheme.json +172 -0
  31. package/dist/antd/themes/carbonTheme.json +170 -0
  32. package/dist/antd/themes/xConsoleTheme.json +26 -0
  33. package/dist/components/CComponents/Alert/demo/index.d.ts +2 -0
  34. package/dist/components/CComponents/Alert/demo/index.js +99 -0
  35. package/dist/components/commonComponents/Alert/demo/index.d.ts +2 -0
  36. package/dist/components/commonComponents/Alert/demo/index.js +87 -0
  37. package/dist/components/commonComponents/AlertDialog/demo/demo1.d.ts +3 -0
  38. package/dist/components/commonComponents/AlertDialog/demo/demo1.js +86 -0
  39. package/dist/components/commonComponents/AlertDialog/demo/demo2.d.ts +3 -0
  40. package/dist/components/commonComponents/AlertDialog/demo/demo2.js +70 -0
  41. package/dist/components/commonComponents/AlertDialog/index.d.ts +25 -0
  42. package/dist/components/commonComponents/AlertDialog/index.js +143 -0
  43. package/dist/components/commonComponents/Avatar/demo/index.d.ts +3 -0
  44. package/dist/components/commonComponents/Avatar/demo/index.js +25 -0
  45. package/dist/components/commonComponents/Avatar/index.d.ts +4 -0
  46. package/dist/components/commonComponents/Avatar/index.js +39 -0
  47. package/dist/components/commonComponents/Badge/demo/index.d.ts +3 -0
  48. package/dist/components/commonComponents/Badge/demo/index.js +24 -0
  49. package/dist/components/commonComponents/Button/demo/demo1.d.ts +2 -0
  50. package/dist/components/commonComponents/Button/demo/demo1.js +103 -0
  51. package/dist/components/commonComponents/Button/demo/demo2.d.ts +2 -0
  52. package/dist/components/commonComponents/Button/demo/demo2.js +17 -0
  53. package/dist/components/commonComponents/Button/index.d.ts +18 -0
  54. package/dist/components/commonComponents/Button/index.js +78 -0
  55. package/dist/components/commonComponents/Card/demo/demo1.d.ts +3 -0
  56. package/dist/components/commonComponents/Card/demo/demo1.js +31 -0
  57. package/dist/components/commonComponents/Card/demo/demo2.d.ts +3 -0
  58. package/dist/components/commonComponents/Card/demo/demo2.js +46 -0
  59. package/dist/components/commonComponents/Card/index.d.ts +11 -0
  60. package/dist/components/commonComponents/Card/index.js +40 -0
  61. package/dist/components/commonComponents/Card/index.style.d.ts +58 -0
  62. package/dist/components/commonComponents/Card/index.style.js +44 -0
  63. package/dist/components/commonComponents/Checkbox/demo/demo1.d.ts +3 -0
  64. package/dist/components/commonComponents/Checkbox/demo/demo1.js +21 -0
  65. package/dist/components/commonComponents/Checkbox/demo/demo2.d.ts +3 -0
  66. package/dist/components/commonComponents/Checkbox/demo/demo2.js +25 -0
  67. package/dist/components/commonComponents/CodeBlock/demo/demo1.d.ts +3 -0
  68. package/dist/components/commonComponents/CodeBlock/demo/demo1.js +34 -0
  69. package/dist/components/commonComponents/CodeBlock/demo/demo2.d.ts +3 -0
  70. package/dist/components/commonComponents/CodeBlock/demo/demo2.js +14 -0
  71. package/dist/components/commonComponents/CodeBlock/index.d.ts +11 -0
  72. package/dist/components/commonComponents/CodeBlock/index.js +88 -0
  73. package/dist/components/commonComponents/CodeBlock/index.style.d.ts +46 -0
  74. package/dist/components/commonComponents/CodeBlock/index.style.js +59 -0
  75. package/dist/components/commonComponents/CollapsePanel/demo/demo1.d.ts +3 -0
  76. package/dist/components/commonComponents/CollapsePanel/demo/demo1.js +27 -0
  77. package/dist/components/commonComponents/CollapsePanel/index.d.ts +38 -0
  78. package/dist/components/commonComponents/CollapsePanel/index.js +116 -0
  79. package/dist/components/commonComponents/CollapsePanel/index.style.d.ts +329 -0
  80. package/dist/components/commonComponents/CollapsePanel/index.style.js +96 -0
  81. package/dist/components/commonComponents/ConfigProvider/index.d.ts +25 -0
  82. package/dist/components/commonComponents/ConfigProvider/index.js +152 -0
  83. package/dist/components/commonComponents/Drawer/demo/demo1.d.ts +2 -0
  84. package/dist/components/commonComponents/Drawer/demo/demo1.js +106 -0
  85. package/dist/components/commonComponents/Drawer/demo/demo2.d.ts +2 -0
  86. package/dist/components/commonComponents/Drawer/demo/demo2.js +66 -0
  87. package/dist/components/commonComponents/Drawer/index.d.ts +3 -0
  88. package/dist/components/commonComponents/Drawer/index.js +30 -0
  89. package/dist/components/commonComponents/Drawer/index.style.d.ts +38 -0
  90. package/dist/components/commonComponents/Drawer/index.style.js +40 -0
  91. package/dist/components/commonComponents/Dropdown/demo/demo1.d.ts +3 -0
  92. package/dist/components/commonComponents/Dropdown/demo/demo1.js +33 -0
  93. package/dist/components/commonComponents/Dropdown/demo/demo2.d.ts +3 -0
  94. package/dist/components/commonComponents/Dropdown/demo/demo2.js +38 -0
  95. package/dist/components/commonComponents/Dropdown/index.d.ts +5 -0
  96. package/dist/components/commonComponents/Dropdown/index.js +20 -0
  97. package/dist/components/commonComponents/Dropdown/index.style.d.ts +7 -0
  98. package/dist/components/commonComponents/Dropdown/index.style.js +21 -0
  99. package/dist/components/commonComponents/Ellipsis/demo/index.d.ts +2 -0
  100. package/dist/components/commonComponents/Ellipsis/demo/index.js +11 -0
  101. package/dist/components/commonComponents/EllipsisTip/demo/demo1.d.ts +3 -0
  102. package/dist/components/commonComponents/EllipsisTip/demo/demo1.js +25 -0
  103. package/dist/components/commonComponents/EllipsisTip/demo/demo2.d.ts +3 -0
  104. package/dist/components/commonComponents/EllipsisTip/demo/demo2.js +35 -0
  105. package/dist/components/commonComponents/EllipsisTip/index.d.ts +13 -0
  106. package/dist/components/commonComponents/EllipsisTip/index.js +30 -0
  107. package/dist/components/commonComponents/EllipsisTip/index.style.d.ts +10 -0
  108. package/dist/components/commonComponents/EllipsisTip/index.style.js +24 -0
  109. package/dist/components/commonComponents/Empty/demo/index.css +11 -0
  110. package/dist/components/commonComponents/Empty/demo/index.d.ts +3 -0
  111. package/dist/components/commonComponents/Empty/demo/index.js +186 -0
  112. package/dist/components/commonComponents/Empty/index.d.ts +57 -0
  113. package/dist/components/commonComponents/Empty/index.js +112 -0
  114. package/dist/components/commonComponents/Empty/index.style.d.ts +80 -0
  115. package/dist/components/commonComponents/Empty/index.style.js +43 -0
  116. package/dist/components/commonComponents/FileIcon/demo/index.d.ts +1 -0
  117. package/dist/components/commonComponents/FileIcon/demo/index.js +42 -0
  118. package/dist/components/commonComponents/FileIcon/icons/common.svg +1 -0
  119. package/dist/components/commonComponents/FileIcon/icons/epub.svg +1 -0
  120. package/dist/components/commonComponents/FileIcon/icons/excel.svg +1 -0
  121. package/dist/components/commonComponents/FileIcon/icons/html.svg +1 -0
  122. package/dist/components/commonComponents/FileIcon/icons/image.svg +1 -0
  123. package/dist/components/commonComponents/FileIcon/icons/md.svg +1 -0
  124. package/dist/components/commonComponents/FileIcon/icons/mobi.svg +1 -0
  125. package/dist/components/commonComponents/FileIcon/icons/pdf.svg +1 -0
  126. package/dist/components/commonComponents/FileIcon/icons/ppt.svg +1 -0
  127. package/dist/components/commonComponents/FileIcon/icons/txt.svg +1 -0
  128. package/dist/components/commonComponents/FileIcon/icons/web.svg +1 -0
  129. package/dist/components/commonComponents/FileIcon/icons/word.svg +1 -0
  130. package/dist/components/commonComponents/FileIcon/index.d.ts +19 -0
  131. package/dist/components/commonComponents/FileIcon/index.js +89 -0
  132. package/dist/components/commonComponents/FileIcon/index.style.d.ts +61 -0
  133. package/dist/components/commonComponents/FileIcon/index.style.js +42 -0
  134. package/dist/components/commonComponents/Form/demo/api.d.ts +2 -0
  135. package/dist/components/commonComponents/Form/demo/api.js +22 -0
  136. package/dist/components/commonComponents/Form/demo/demo1.d.ts +2 -0
  137. package/dist/components/commonComponents/Form/demo/demo1.js +107 -0
  138. package/dist/components/commonComponents/Form/demo/demo2.d.ts +2 -0
  139. package/dist/components/commonComponents/Form/demo/demo2.js +52 -0
  140. package/dist/components/commonComponents/Form/demo/demo3.d.ts +2 -0
  141. package/dist/components/commonComponents/Form/demo/demo3.js +28 -0
  142. package/dist/components/commonComponents/Form/demo/demo4.d.ts +2 -0
  143. package/dist/components/commonComponents/Form/demo/demo4.js +29 -0
  144. package/dist/components/commonComponents/Form/demo/index.module.less +0 -0
  145. package/dist/components/commonComponents/Form/index.d.ts +27 -0
  146. package/dist/components/commonComponents/Form/index.js +84 -0
  147. package/dist/components/commonComponents/Form/index.style.d.ts +49 -0
  148. package/dist/components/commonComponents/Form/index.style.js +37 -0
  149. package/dist/components/commonComponents/HelpIcon/demo/index.d.ts +2 -0
  150. package/dist/components/commonComponents/HelpIcon/demo/index.js +17 -0
  151. package/dist/components/commonComponents/HelpIcon/index.d.ts +9 -0
  152. package/dist/components/commonComponents/HelpIcon/index.js +35 -0
  153. package/dist/components/commonComponents/HelpIcon/index.style.d.ts +12 -0
  154. package/dist/components/commonComponents/HelpIcon/index.style.js +26 -0
  155. package/dist/components/commonComponents/IconButton/demo/demo1.d.ts +3 -0
  156. package/dist/components/commonComponents/IconButton/demo/demo1.js +66 -0
  157. package/dist/components/commonComponents/IconButton/demo/demo2.d.ts +3 -0
  158. package/dist/components/commonComponents/IconButton/demo/demo2.js +61 -0
  159. package/dist/components/commonComponents/IconButton/demo/demo3.d.ts +3 -0
  160. package/dist/components/commonComponents/IconButton/demo/demo3.js +53 -0
  161. package/dist/components/commonComponents/IconButton/demo/demo4.d.ts +3 -0
  162. package/dist/components/commonComponents/IconButton/demo/demo4.js +55 -0
  163. package/dist/components/commonComponents/IconButton/index.d.ts +22 -0
  164. package/dist/components/commonComponents/IconButton/index.js +43 -0
  165. package/dist/components/commonComponents/IconFont/demo/demo1.d.ts +2 -0
  166. package/dist/components/commonComponents/IconFont/demo/demo1.js +49 -0
  167. package/dist/components/commonComponents/IconFont/demo/demo2.d.ts +2 -0
  168. package/dist/components/commonComponents/IconFont/demo/demo2.js +17 -0
  169. package/dist/components/commonComponents/IconFont/demo/demo3.d.ts +2 -0
  170. package/dist/components/commonComponents/IconFont/demo/demo3.js +17 -0
  171. package/dist/components/commonComponents/IconFont/demo/demo4.d.ts +2 -0
  172. package/dist/components/commonComponents/IconFont/demo/demo4.js +23 -0
  173. package/dist/components/commonComponents/IconFont/index.d.ts +29 -0
  174. package/dist/components/commonComponents/IconFont/index.js +57 -0
  175. package/dist/components/commonComponents/IconFont/index.style.d.ts +67 -0
  176. package/dist/components/commonComponents/IconFont/index.style.js +44 -0
  177. package/dist/components/commonComponents/Image/demo/demo1.d.ts +1 -0
  178. package/dist/components/commonComponents/Image/demo/demo1.js +8 -0
  179. package/dist/components/commonComponents/Image/index.d.ts +8 -0
  180. package/dist/components/commonComponents/Image/index.js +37 -0
  181. package/dist/components/commonComponents/Input/demo/index.d.ts +2 -0
  182. package/dist/components/commonComponents/Input/demo/index.js +117 -0
  183. package/dist/components/commonComponents/Input/index.d.ts +13 -0
  184. package/dist/components/commonComponents/Input/index.js +34 -0
  185. package/dist/components/commonComponents/Input/index.style.d.ts +36 -0
  186. package/dist/components/commonComponents/Input/index.style.js +32 -0
  187. package/dist/components/commonComponents/InputNumber/demo/index.d.ts +3 -0
  188. package/dist/components/commonComponents/InputNumber/demo/index.js +38 -0
  189. package/dist/components/commonComponents/InputSearch/demo/index.d.ts +2 -0
  190. package/dist/components/commonComponents/InputSearch/demo/index.js +43 -0
  191. package/dist/components/commonComponents/Message/demo.d.ts +2 -0
  192. package/dist/components/commonComponents/Message/demo.js +53 -0
  193. package/dist/components/commonComponents/Message/index.d.ts +20 -0
  194. package/dist/components/commonComponents/Message/index.js +66 -0
  195. package/dist/components/commonComponents/Modal/demo/demo1.d.ts +2 -0
  196. package/dist/components/commonComponents/Modal/demo/demo1.js +137 -0
  197. package/dist/components/commonComponents/Modal/demo/demo2.d.ts +3 -0
  198. package/dist/components/commonComponents/Modal/demo/demo2.js +77 -0
  199. package/dist/components/commonComponents/Modal/demo/demo3.d.ts +2 -0
  200. package/dist/components/commonComponents/Modal/demo/demo3.js +57 -0
  201. package/dist/components/commonComponents/Modal/demo/demo4.d.ts +3 -0
  202. package/dist/components/commonComponents/Modal/demo/demo4.js +65 -0
  203. package/dist/components/commonComponents/Modal/index.css +1 -0
  204. package/dist/components/commonComponents/Modal/index.d.ts +15 -0
  205. package/dist/components/commonComponents/Modal/index.js +46 -0
  206. package/dist/components/commonComponents/Modal/index.style.d.ts +80 -0
  207. package/dist/components/commonComponents/Modal/index.style.js +58 -0
  208. package/dist/components/commonComponents/Notification/demo/demo1.d.ts +3 -0
  209. package/dist/components/commonComponents/Notification/demo/demo1.js +76 -0
  210. package/dist/components/commonComponents/Notification/demo/demo2.d.ts +3 -0
  211. package/dist/components/commonComponents/Notification/demo/demo2.js +50 -0
  212. package/dist/components/commonComponents/Notification/demo/demo3.d.ts +3 -0
  213. package/dist/components/commonComponents/Notification/demo/demo3.js +46 -0
  214. package/dist/components/commonComponents/Notification/index.d.ts +20 -0
  215. package/dist/components/commonComponents/Notification/index.js +106 -0
  216. package/dist/components/commonComponents/Pagination/demo/demo1.d.ts +3 -0
  217. package/dist/components/commonComponents/Pagination/demo/demo1.js +14 -0
  218. package/dist/components/commonComponents/Pagination/demo/demo2.d.ts +3 -0
  219. package/dist/components/commonComponents/Pagination/demo/demo2.js +16 -0
  220. package/dist/components/commonComponents/Pagination/index.d.ts +12 -0
  221. package/dist/components/commonComponents/Pagination/index.js +59 -0
  222. package/dist/components/commonComponents/Pagination/index.style.d.ts +12 -0
  223. package/dist/components/commonComponents/Pagination/index.style.js +24 -0
  224. package/dist/components/commonComponents/Popconfirm/demo/index.d.ts +3 -0
  225. package/dist/components/commonComponents/Popconfirm/demo/index.js +155 -0
  226. package/dist/components/commonComponents/Popconfirm/index.d.ts +5 -0
  227. package/dist/components/commonComponents/Popconfirm/index.js +29 -0
  228. package/dist/components/commonComponents/Popover/demo/demo1.d.ts +3 -0
  229. package/dist/components/commonComponents/Popover/demo/demo1.js +34 -0
  230. package/dist/components/commonComponents/Popover/demo/demo2.d.ts +3 -0
  231. package/dist/components/commonComponents/Popover/demo/demo2.js +183 -0
  232. package/dist/components/commonComponents/Popover/index.d.ts +4 -0
  233. package/dist/components/commonComponents/Popover/index.js +27 -0
  234. package/dist/components/commonComponents/Progress/demo/demo1.d.ts +3 -0
  235. package/dist/components/commonComponents/Progress/demo/demo1.js +15 -0
  236. package/dist/components/commonComponents/Radio/demo.d.ts +3 -0
  237. package/dist/components/commonComponents/Radio/demo.js +20 -0
  238. package/dist/components/commonComponents/Radio/demo2.d.ts +3 -0
  239. package/dist/components/commonComponents/Radio/demo2.js +115 -0
  240. package/dist/components/commonComponents/RadioButton/demo/demo.d.ts +3 -0
  241. package/dist/components/commonComponents/RadioButton/demo/demo.js +166 -0
  242. package/dist/components/commonComponents/RadioButton/index.d.ts +21 -0
  243. package/dist/components/commonComponents/RadioButton/index.js +32 -0
  244. package/dist/components/commonComponents/RadioButton/index.style.d.ts +62 -0
  245. package/dist/components/commonComponents/RadioButton/index.style.js +49 -0
  246. package/dist/components/commonComponents/Select/demo/demo.d.ts +3 -0
  247. package/dist/components/commonComponents/Select/demo/demo.js +29 -0
  248. package/dist/components/commonComponents/Select/demo/demo2.d.ts +3 -0
  249. package/dist/components/commonComponents/Select/demo/demo2.js +30 -0
  250. package/dist/components/commonComponents/Skeleton/demo/demo1.d.ts +3 -0
  251. package/dist/components/commonComponents/Skeleton/demo/demo1.js +9 -0
  252. package/dist/components/commonComponents/SlateEditor/demo/index.d.ts +2 -0
  253. package/dist/components/commonComponents/SlateEditor/demo/index.js +21 -0
  254. package/dist/components/commonComponents/SlateEditor/elements/S.d.ts +2 -0
  255. package/dist/components/commonComponents/SlateEditor/elements/S.js +18 -0
  256. package/dist/components/commonComponents/SlateEditor/elements/Var.d.ts +3 -0
  257. package/dist/components/commonComponents/SlateEditor/elements/Var.js +20 -0
  258. package/dist/components/commonComponents/SlateEditor/elements/index.d.ts +2 -0
  259. package/dist/components/commonComponents/SlateEditor/elements/index.js +2 -0
  260. package/dist/components/commonComponents/SlateEditor/elements/index.less +10 -0
  261. package/dist/components/commonComponents/SlateEditor/index.d.ts +39 -0
  262. package/dist/components/commonComponents/SlateEditor/index.js +272 -0
  263. package/dist/components/commonComponents/SlateEditor/index.style.d.ts +28 -0
  264. package/dist/components/commonComponents/SlateEditor/index.style.js +36 -0
  265. package/dist/components/commonComponents/SlateEditor/types.d.ts +56 -0
  266. package/dist/components/commonComponents/SlateEditor/types.js +1 -0
  267. package/dist/components/commonComponents/SlateEditor/utils/constant.d.ts +7 -0
  268. package/dist/components/commonComponents/SlateEditor/utils/constant.js +36 -0
  269. package/dist/components/commonComponents/SlateEditor/utils/editor.d.ts +68 -0
  270. package/dist/components/commonComponents/SlateEditor/utils/editor.js +558 -0
  271. package/dist/components/commonComponents/SlateEditor/utils/functions.d.ts +41 -0
  272. package/dist/components/commonComponents/SlateEditor/utils/functions.js +179 -0
  273. package/dist/components/commonComponents/SlateEditor/utils/index.d.ts +4 -0
  274. package/dist/components/commonComponents/SlateEditor/utils/index.js +4 -0
  275. package/dist/components/commonComponents/SlateEditor/utils/withEditor.d.ts +2 -0
  276. package/dist/components/commonComponents/SlateEditor/utils/withEditor.js +109 -0
  277. package/dist/components/commonComponents/Slider/demo/demo1.d.ts +3 -0
  278. package/dist/components/commonComponents/Slider/demo/demo1.js +35 -0
  279. package/dist/components/commonComponents/Slider/demo/demo2.d.ts +3 -0
  280. package/dist/components/commonComponents/Slider/demo/demo2.js +48 -0
  281. package/dist/components/commonComponents/SliderSelector/demo/index.d.ts +2 -0
  282. package/dist/components/commonComponents/SliderSelector/demo/index.js +41 -0
  283. package/dist/components/commonComponents/SliderSelector/index.d.ts +16 -0
  284. package/dist/components/commonComponents/SliderSelector/index.js +67 -0
  285. package/dist/components/commonComponents/SliderSelector/index.style.d.ts +38 -0
  286. package/dist/components/commonComponents/SliderSelector/index.style.js +37 -0
  287. package/dist/components/commonComponents/Spin/demo1.d.ts +3 -0
  288. package/dist/components/commonComponents/Spin/demo1.js +30 -0
  289. package/dist/components/commonComponents/Spinner/demo/demo1.d.ts +3 -0
  290. package/dist/components/commonComponents/Spinner/demo/demo1.js +46 -0
  291. package/dist/components/commonComponents/Spinner/demo/demo2.d.ts +3 -0
  292. package/dist/components/commonComponents/Spinner/demo/demo2.js +69 -0
  293. package/dist/components/commonComponents/Spinner/demo/demo3.d.ts +3 -0
  294. package/dist/components/commonComponents/Spinner/demo/demo3.js +59 -0
  295. package/dist/components/commonComponents/Spinner/index.d.ts +16 -0
  296. package/dist/components/commonComponents/Spinner/index.js +77 -0
  297. package/dist/components/commonComponents/Spinner/index.style.d.ts +82 -0
  298. package/dist/components/commonComponents/Spinner/index.style.js +60 -0
  299. package/dist/components/commonComponents/Switch/demo/demo1.d.ts +3 -0
  300. package/dist/components/commonComponents/Switch/demo/demo1.js +26 -0
  301. package/dist/components/commonComponents/Switch/demo/demo2.d.ts +3 -0
  302. package/dist/components/commonComponents/Switch/demo/demo2.js +27 -0
  303. package/dist/components/commonComponents/Switch/index.d.ts +11 -0
  304. package/dist/components/commonComponents/Switch/index.js +29 -0
  305. package/dist/components/commonComponents/Switch/index.style.d.ts +8 -0
  306. package/dist/components/commonComponents/Switch/index.style.js +23 -0
  307. package/dist/components/commonComponents/Table/demo/demo1.d.ts +3 -0
  308. package/dist/components/commonComponents/Table/demo/demo1.js +87 -0
  309. package/dist/components/commonComponents/Table/demo/demo2.d.ts +3 -0
  310. package/dist/components/commonComponents/Table/demo/demo2.js +98 -0
  311. package/dist/components/commonComponents/Table/demo/demo3.d.ts +3 -0
  312. package/dist/components/commonComponents/Table/demo/demo3.js +378 -0
  313. package/dist/components/commonComponents/Tabs/demo/demo1.d.ts +3 -0
  314. package/dist/components/commonComponents/Tabs/demo/demo1.js +45 -0
  315. package/dist/components/commonComponents/Tabs/demo/demo2.d.ts +3 -0
  316. package/dist/components/commonComponents/Tabs/demo/demo2.js +43 -0
  317. package/dist/components/commonComponents/Tabs/demo/demo3.d.ts +3 -0
  318. package/dist/components/commonComponents/Tabs/demo/demo3.js +32 -0
  319. package/dist/components/commonComponents/Tabs/index.d.ts +14 -0
  320. package/dist/components/commonComponents/Tabs/index.js +67 -0
  321. package/dist/components/commonComponents/Tabs/index.style.d.ts +23 -0
  322. package/dist/components/commonComponents/Tabs/index.style.js +30 -0
  323. package/dist/components/commonComponents/Tag/demo.d.ts +2 -0
  324. package/dist/components/commonComponents/Tag/demo.js +30 -0
  325. package/dist/components/commonComponents/Tag/index.d.ts +7 -0
  326. package/dist/components/commonComponents/Tag/index.js +36 -0
  327. package/dist/components/commonComponents/Tag/index.style.d.ts +26 -0
  328. package/dist/components/commonComponents/Tag/index.style.js +48 -0
  329. package/dist/components/commonComponents/Textarea/demo/demo1.d.ts +3 -0
  330. package/dist/components/commonComponents/Textarea/demo/demo1.js +36 -0
  331. package/dist/components/commonComponents/Tooltip/demo/index.d.ts +3 -0
  332. package/dist/components/commonComponents/Tooltip/demo/index.js +254 -0
  333. package/dist/components/commonComponents/Tooltip/index.d.ts +11 -0
  334. package/dist/components/commonComponents/Tooltip/index.js +35 -0
  335. package/dist/components/commonComponents/Tooltip/index.style.d.ts +24 -0
  336. package/dist/components/commonComponents/Tooltip/index.style.js +32 -0
  337. package/dist/components/commonComponents/Upload/demo/demo1.d.ts +3 -0
  338. package/dist/components/commonComponents/Upload/demo/demo1.js +43 -0
  339. package/dist/components/commonComponents/Upload/demo/demo2.d.ts +2 -0
  340. package/dist/components/commonComponents/Upload/demo/demo2.js +15 -0
  341. package/dist/components/commonComponents/Upload/demo/demo3.d.ts +3 -0
  342. package/dist/components/commonComponents/Upload/demo/demo3.js +145 -0
  343. package/dist/components/commonComponents/spark.style.d.ts +45 -0
  344. package/dist/components/commonComponents/spark.style.js +62 -0
  345. package/dist/config.d.ts +27 -0
  346. package/dist/config.js +56 -0
  347. package/dist/hooks/useGlobalStyle/demo/demo.d.ts +2 -0
  348. package/dist/hooks/useGlobalStyle/demo/demo.js +47 -0
  349. package/dist/hooks/useGlobalStyle/index.d.ts +8 -0
  350. package/dist/hooks/useGlobalStyle/index.js +51 -0
  351. package/dist/i18n/index.d.ts +33 -0
  352. package/dist/i18n/index.js +62 -0
  353. package/dist/i18n/strings/en-US.json +13 -0
  354. package/dist/i18n/strings/index.js +12 -0
  355. package/dist/i18n/strings/zh-CN.json +13 -0
  356. package/dist/index.d.ts +67 -0
  357. package/dist/index.js +70 -0
  358. package/dist/libs/cookie.d.ts +9 -0
  359. package/dist/libs/cookie.js +19 -0
  360. package/dist/libs/createStyle/index.d.ts +1 -0
  361. package/dist/libs/createStyle/index.js +76 -0
  362. package/dist/libs/data/index.d.ts +15 -0
  363. package/dist/libs/data/index.js +76 -0
  364. package/dist/libs/delay/index.d.ts +6 -0
  365. package/dist/libs/delay/index.js +31 -0
  366. package/dist/libs/dom.d.ts +8 -0
  367. package/dist/libs/dom.js +37 -0
  368. package/dist/libs/env/index.d.ts +10 -0
  369. package/dist/libs/env/index.js +16 -0
  370. package/dist/libs/generateCssVars/index.d.ts +19 -0
  371. package/dist/libs/generateCssVars/index.js +39 -0
  372. package/dist/libs/loadStyle.d.ts +7 -0
  373. package/dist/libs/loadStyle.js +41 -0
  374. package/dist/libs/region/constant.d.ts +6 -0
  375. package/dist/libs/region/constant.js +154 -0
  376. package/dist/libs/region/index.d.ts +2 -0
  377. package/dist/libs/region/index.js +18 -0
  378. package/dist/libs/requestPop/index.d.ts +52 -0
  379. package/dist/libs/requestPop/index.js +89 -0
  380. package/dist/libs/requestPopSse/index.d.ts +35 -0
  381. package/dist/libs/requestPopSse/index.js +159 -0
  382. package/dist/libs/requestSse/index.d.ts +47 -0
  383. package/dist/libs/requestSse/index.js +196 -0
  384. package/dist/libs/requestSse/parse.d.ts +36 -0
  385. package/dist/libs/requestSse/parse.js +190 -0
  386. package/dist/libs/staticRenderer/index.d.ts +8 -0
  387. package/dist/libs/staticRenderer/index.js +58 -0
  388. package/dist/libs/string/index.d.ts +19 -0
  389. package/dist/libs/string/index.js +63 -0
  390. package/dist/libs/tokens.json +3 -0
  391. package/dist/libs/utils/index.d.ts +7 -0
  392. package/dist/libs/utils/index.js +69 -0
  393. package/dist/libs/waitFor/index.d.ts +25 -0
  394. package/dist/libs/waitFor/index.js +39 -0
  395. package/dist/typings.d.ts +14 -0
  396. package/package.json +173 -0
  397. package/scripts/init-migrate-config.js +68 -0
  398. package/scripts/migrate-from-bl.js +78 -0
@@ -0,0 +1,46 @@
1
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
3
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
4
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
5
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
6
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
7
+ import { Spinner } from "../../../..";
8
+ import { Flex } from 'antd';
9
+ import React, { useEffect, useRef, useState } from 'react';
10
+ import { jsx as _jsx } from "react/jsx-runtime";
11
+ import { jsxs as _jsxs } from "react/jsx-runtime";
12
+ var App = function App() {
13
+ var _useState = useState(0),
14
+ _useState2 = _slicedToArray(_useState, 2),
15
+ percent = _useState2[0],
16
+ setPercent = _useState2[1];
17
+ var timerRef = useRef(null);
18
+ useEffect(function () {
19
+ timerRef.current = setInterval(function () {
20
+ setPercent(function (prevPercent) {
21
+ return prevPercent >= 100 ? 0 : prevPercent + 1;
22
+ });
23
+ }, 100);
24
+ return function () {
25
+ clearInterval(timerRef.current);
26
+ timerRef.current = null;
27
+ };
28
+ }, []);
29
+ return /*#__PURE__*/_jsxs(Flex, {
30
+ align: "center",
31
+ gap: "middle",
32
+ children: [/*#__PURE__*/_jsx(Spinner, {
33
+ tip: /*#__PURE__*/_jsx("span", {
34
+ children: "No progress"
35
+ }),
36
+ percent: percent
37
+ }), /*#__PURE__*/_jsx(Spinner, {
38
+ percent: percent,
39
+ showProgress: true,
40
+ defaultTip: {
41
+ text: 'user define texts'
42
+ }
43
+ })]
44
+ });
45
+ };
46
+ export default App;
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const App: React.FC;
3
+ export default App;
@@ -0,0 +1,69 @@
1
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
3
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
4
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
5
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
6
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
7
+ import { Button, Progress, Spinner } from "../../../..";
8
+ import { Flex } from 'antd';
9
+ import React, { useEffect, useRef, useState } from 'react';
10
+ import { jsx as _jsx } from "react/jsx-runtime";
11
+ import { jsxs as _jsxs } from "react/jsx-runtime";
12
+ var App = function App() {
13
+ var _useState = useState(0),
14
+ _useState2 = _slicedToArray(_useState, 2),
15
+ percent = _useState2[0],
16
+ setPercent = _useState2[1];
17
+ var _useState3 = useState(true),
18
+ _useState4 = _slicedToArray(_useState3, 2),
19
+ spinning = _useState4[0],
20
+ setSpinning = _useState4[1];
21
+ var timerRef = useRef(null);
22
+ useEffect(function () {
23
+ return function () {
24
+ clearInterval(timerRef.current);
25
+ timerRef.current = null;
26
+ };
27
+ }, []);
28
+ useEffect(function () {
29
+ if (spinning) {
30
+ timerRef.current = setInterval(function () {
31
+ setPercent(function (prevPercent) {
32
+ return prevPercent >= 100 ? 0 : prevPercent + 1;
33
+ });
34
+ }, 100);
35
+ } else {
36
+ clearInterval(timerRef.current);
37
+ timerRef.current = null;
38
+ }
39
+ }, [spinning]);
40
+ return /*#__PURE__*/_jsx(Flex, {
41
+ align: "center",
42
+ gap: "middle",
43
+ children: /*#__PURE__*/_jsx(Spinner, {
44
+ spinning: spinning,
45
+ tip: spinning ? /*#__PURE__*/_jsxs("div", {
46
+ children: [/*#__PURE__*/_jsxs("span", {
47
+ children: ["File uploading", /*#__PURE__*/_jsx("span", {
48
+ style: {
49
+ display: 'inline-block',
50
+ width: '24px',
51
+ textAlign: 'center'
52
+ },
53
+ children: percent
54
+ }), "% ..."]
55
+ }), /*#__PURE__*/_jsx(Button, {
56
+ type: "link",
57
+ onClick: function onClick() {
58
+ return setSpinning(false);
59
+ },
60
+ children: "cancel"
61
+ }), /*#__PURE__*/_jsx(Progress, {
62
+ percent: percent,
63
+ showInfo: false
64
+ })]
65
+ }) : undefined
66
+ })
67
+ });
68
+ };
69
+ export default App;
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const App: React.FC;
3
+ export default App;
@@ -0,0 +1,59 @@
1
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
3
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
4
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
5
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
6
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
7
+ import { Alert, Button, Progress, Spinner } from "../../../..";
8
+ import { Flex } from 'antd';
9
+ import React, { useEffect, useState } from 'react';
10
+ import { jsx as _jsx } from "react/jsx-runtime";
11
+ import { jsxs as _jsxs } from "react/jsx-runtime";
12
+ var App = function App() {
13
+ var _useState = useState(0),
14
+ _useState2 = _slicedToArray(_useState, 2),
15
+ percent = _useState2[0],
16
+ setPercent = _useState2[1];
17
+ useEffect(function () {
18
+ var timer = setInterval(function () {
19
+ setPercent(function (prevPercent) {
20
+ return prevPercent >= 100 ? 0 : prevPercent + 1;
21
+ });
22
+ }, 100);
23
+ return function () {
24
+ return clearInterval(timer);
25
+ };
26
+ }, []);
27
+ return /*#__PURE__*/_jsx(Flex, {
28
+ align: "center",
29
+ gap: "middle",
30
+ children: /*#__PURE__*/_jsx(Spinner, {
31
+ tip: /*#__PURE__*/_jsxs("div", {
32
+ children: [/*#__PURE__*/_jsxs("span", {
33
+ children: ["File uploading", ' ', /*#__PURE__*/_jsx("span", {
34
+ style: {
35
+ display: 'inline-block',
36
+ width: '24px'
37
+ },
38
+ children: percent
39
+ }), "% ..."]
40
+ }), /*#__PURE__*/_jsx(Button, {
41
+ type: "link",
42
+ children: "cancel"
43
+ }), /*#__PURE__*/_jsx(Progress, {
44
+ percent: percent,
45
+ showInfo: false
46
+ })]
47
+ }),
48
+ children: /*#__PURE__*/_jsx(Alert, {
49
+ message: "Alert message title",
50
+ description: "Further details about the context of this alert.",
51
+ type: "info",
52
+ style: {
53
+ height: 150
54
+ }
55
+ })
56
+ })
57
+ });
58
+ };
59
+ export default App;
@@ -0,0 +1,16 @@
1
+ /// <reference types="react" />
2
+ interface SparkSpin {
3
+ tip?: React.ReactNode;
4
+ defaultTip?: {
5
+ text?: string;
6
+ };
7
+ indicator?: React.ReactNode;
8
+ children?: React.ReactNode;
9
+ style?: React.CSSProperties;
10
+ className?: string;
11
+ percent?: number;
12
+ spinning?: boolean;
13
+ showProgress?: boolean;
14
+ }
15
+ declare const _default: (props: SparkSpin) => import("react/jsx-runtime").JSX.Element;
16
+ export default _default;
@@ -0,0 +1,77 @@
1
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
2
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
3
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
4
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
5
+ import { getCommonConfig } from "../../../config";
6
+ import { Progress } from 'antd';
7
+ import classNames from 'classnames';
8
+ import useIndexStyle from "./index.style";
9
+ import { jsx as _jsx } from "react/jsx-runtime";
10
+ import { Fragment as _Fragment } from "react/jsx-runtime";
11
+ import { jsxs as _jsxs } from "react/jsx-runtime";
12
+ export default (function (props) {
13
+ var _props$defaultTip;
14
+ var indicator = props.indicator,
15
+ _props$spinning = props.spinning,
16
+ spinning = _props$spinning === void 0 ? true : _props$spinning,
17
+ children = props.children,
18
+ style = props.style,
19
+ className = props.className;
20
+ var commonConfig = getCommonConfig();
21
+ var sparkPrefix = commonConfig.sparkPrefix;
22
+ useIndexStyle();
23
+ var defaultIndicator = /*#__PURE__*/_jsx("img", {
24
+ className: "".concat(sparkPrefix, "-default-indicator"),
25
+ src: "https://img.alicdn.com/imgextra/i3/O1CN01IvkNEh1WMXj68RCln_!!6000000002774-55-tps-40-40.svg",
26
+ alt: ""
27
+ });
28
+ var tip = props.tip || props.showProgress && /*#__PURE__*/_jsxs("div", {
29
+ children: [/*#__PURE__*/_jsxs("span", {
30
+ children: [((_props$defaultTip = props.defaultTip) === null || _props$defaultTip === void 0 ? void 0 : _props$defaultTip.text) || 'loading', props.percent !== undefined && props.percent !== null && /*#__PURE__*/_jsxs(_Fragment, {
31
+ children: [/*#__PURE__*/_jsx("span", {
32
+ style: {
33
+ display: 'inline-block',
34
+ width: '24px',
35
+ textAlign: 'center'
36
+ },
37
+ children: props.percent
38
+ }), "%"]
39
+ })]
40
+ }), /*#__PURE__*/_jsx(Progress, {
41
+ percent: props.percent,
42
+ showInfo: false
43
+ })]
44
+ }) || null;
45
+ if (children) {
46
+ return /*#__PURE__*/_jsxs("div", {
47
+ className: classNames("".concat(sparkPrefix, "-spinner-overlay"), className),
48
+ style: style,
49
+ children: [/*#__PURE__*/_jsx("div", {
50
+ className: classNames("".concat(sparkPrefix, "-spinner-content"), _defineProperty({}, "".concat(sparkPrefix, "-spinning"), spinning)),
51
+ children: children
52
+ }), spinning && /*#__PURE__*/_jsxs("div", {
53
+ className: "".concat(sparkPrefix, "-spinner"),
54
+ children: [/*#__PURE__*/_jsx("div", {
55
+ className: "".concat(sparkPrefix, "-indicator"),
56
+ children: indicator || defaultIndicator
57
+ }), /*#__PURE__*/_jsx("div", {
58
+ className: "".concat(sparkPrefix, "-title"),
59
+ children: tip
60
+ })]
61
+ })]
62
+ });
63
+ }
64
+ return /*#__PURE__*/_jsx("div", {
65
+ className: classNames("".concat(sparkPrefix, "-spinner"), className),
66
+ style: style,
67
+ children: spinning && /*#__PURE__*/_jsxs(_Fragment, {
68
+ children: [/*#__PURE__*/_jsx("div", {
69
+ className: "".concat(sparkPrefix, "-indicator"),
70
+ children: indicator || defaultIndicator
71
+ }), /*#__PURE__*/_jsx("div", {
72
+ className: "".concat(sparkPrefix, "-title"),
73
+ children: tip
74
+ })]
75
+ })
76
+ });
77
+ });
@@ -0,0 +1,82 @@
1
+ export declare function getIndexStyleData(params: any): {
2
+ [x: string]: {
3
+ '0%': {
4
+ transform: string;
5
+ };
6
+ '100%': {
7
+ transform: string;
8
+ };
9
+ position?: undefined;
10
+ width?: undefined;
11
+ height?: undefined;
12
+ } | {
13
+ [x: string]: {
14
+ [x: string]: string | {
15
+ width: string;
16
+ height: string;
17
+ animation: string;
18
+ };
19
+ display: string;
20
+ justifyContent: string;
21
+ alignItems: string;
22
+ marginTop?: undefined;
23
+ fontWeight?: undefined;
24
+ fontSize?: undefined;
25
+ color?: undefined;
26
+ } | {
27
+ marginTop: string;
28
+ fontWeight: number;
29
+ fontSize: string;
30
+ color: string;
31
+ display?: undefined;
32
+ justifyContent?: undefined;
33
+ alignItems?: undefined;
34
+ };
35
+ '0%'?: undefined;
36
+ '100%'?: undefined;
37
+ position?: undefined;
38
+ width?: undefined;
39
+ height?: undefined;
40
+ } | {
41
+ [x: string]: string | {
42
+ position: string;
43
+ opacity: number;
44
+ top?: undefined;
45
+ left?: undefined;
46
+ width?: undefined;
47
+ height?: undefined;
48
+ display?: undefined;
49
+ justifyContent?: undefined;
50
+ alignItems?: undefined;
51
+ flexDirection?: undefined;
52
+ zIndex?: undefined;
53
+ } | {
54
+ position: string;
55
+ top: number;
56
+ left: number;
57
+ width: string;
58
+ height: string;
59
+ display: string;
60
+ justifyContent: string;
61
+ alignItems: string;
62
+ flexDirection: string;
63
+ zIndex: number;
64
+ opacity?: undefined;
65
+ };
66
+ position: string;
67
+ width: string;
68
+ height: string;
69
+ '0%'?: undefined;
70
+ '100%'?: undefined;
71
+ };
72
+ '@keyframes loading': {
73
+ '0%': {
74
+ transform: string;
75
+ };
76
+ '100%': {
77
+ transform: string;
78
+ };
79
+ };
80
+ };
81
+ declare const useIndexStyle: (props?: {}) => import("../../../config").CommonConfig;
82
+ export default useIndexStyle;
@@ -0,0 +1,60 @@
1
+ var _excluded = ["css"];
2
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
3
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
4
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
7
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
8
+ import createStyle from "../../../libs/createStyle";
9
+ export function getIndexStyleData(params) {
10
+ var sparkPrefix = params.sparkPrefix,
11
+ antPrefix = params.antPrefix;
12
+ return _defineProperty(_defineProperty({
13
+ '@keyframes loading': {
14
+ '0%': {
15
+ transform: 'rotate(0deg)'
16
+ },
17
+ '100%': {
18
+ transform: 'rotate(360deg)'
19
+ }
20
+ }
21
+ }, ".".concat(sparkPrefix, "-spinner"), _defineProperty(_defineProperty({}, ".".concat(sparkPrefix, "-indicator"), _defineProperty({
22
+ display: 'flex',
23
+ justifyContent: 'center',
24
+ alignItems: 'center'
25
+ }, ".".concat(sparkPrefix, "-default-indicator"), {
26
+ width: '40px',
27
+ height: '40px',
28
+ animation: 'loading 1s linear infinite'
29
+ })), ".".concat(sparkPrefix, "-title"), {
30
+ marginTop: '12px',
31
+ fontWeight: 400,
32
+ fontSize: '14px',
33
+ color: "var(--".concat(antPrefix, "-color-text)")
34
+ })), ".".concat(sparkPrefix, "-spinner-overlay"), _defineProperty(_defineProperty({
35
+ position: 'relative',
36
+ width: '100%',
37
+ height: '100%'
38
+ }, ".".concat(sparkPrefix, "-spinner-content.").concat(sparkPrefix, "-spinning"), {
39
+ position: 'relative',
40
+ opacity: 0.3
41
+ }), ".".concat(sparkPrefix, "-spinner"), {
42
+ position: 'absolute',
43
+ top: 0,
44
+ left: 0,
45
+ width: '100%',
46
+ height: '100%',
47
+ display: 'flex',
48
+ justifyContent: 'center',
49
+ alignItems: 'center',
50
+ flexDirection: 'column',
51
+ zIndex: 4
52
+ }));
53
+ }
54
+ var useIndexStyle = createStyle(function (_ref2) {
55
+ var css = _ref2.css,
56
+ params = _objectWithoutProperties(_ref2, _excluded);
57
+ var result = css(getIndexStyleData(params));
58
+ return result;
59
+ });
60
+ export default useIndexStyle;
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const App: React.FC;
3
+ export default App;
@@ -0,0 +1,26 @@
1
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
3
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
4
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
5
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
6
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
7
+ import { Switch } from "../../../..";
8
+ import React, { useState } from 'react';
9
+ import { jsx as _jsx } from "react/jsx-runtime";
10
+ import { Fragment as _Fragment } from "react/jsx-runtime";
11
+ var App = function App() {
12
+ var _useState = useState(false),
13
+ _useState2 = _slicedToArray(_useState, 2),
14
+ checked = _useState2[0],
15
+ setChecked = _useState2[1];
16
+ return /*#__PURE__*/_jsx(_Fragment, {
17
+ children: /*#__PURE__*/_jsx(Switch, {
18
+ checked: checked,
19
+ onChange: function onChange(checked) {
20
+ return setChecked(checked);
21
+ },
22
+ label: checked ? 'Opening' : 'Closed'
23
+ })
24
+ });
25
+ };
26
+ export default App;
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const App: React.FC;
3
+ export default App;
@@ -0,0 +1,27 @@
1
+ import { Switch } from "../../../..";
2
+ import { CheckOutlined, CloseOutlined } from "@agentscope-ai/icons-override-antd";
3
+ import { Space } from 'antd';
4
+ import React from 'react';
5
+ import { jsx as _jsx } from "react/jsx-runtime";
6
+ import { jsxs as _jsxs } from "react/jsx-runtime";
7
+ import { Fragment as _Fragment } from "react/jsx-runtime";
8
+ var App = function App() {
9
+ return /*#__PURE__*/_jsx(_Fragment, {
10
+ children: /*#__PURE__*/_jsxs(Space, {
11
+ direction: "vertical",
12
+ children: [/*#__PURE__*/_jsx(Switch, {
13
+ checkedChildren: "\u5F00\u542F",
14
+ unCheckedChildren: "\u5173\u95ED",
15
+ defaultChecked: true
16
+ }), /*#__PURE__*/_jsx(Switch, {
17
+ checkedChildren: "1",
18
+ unCheckedChildren: "0"
19
+ }), /*#__PURE__*/_jsx(Switch, {
20
+ checkedChildren: /*#__PURE__*/_jsx(CheckOutlined, {}),
21
+ unCheckedChildren: /*#__PURE__*/_jsx(CloseOutlined, {}),
22
+ defaultChecked: true
23
+ })]
24
+ })
25
+ });
26
+ };
27
+ export default App;
@@ -0,0 +1,11 @@
1
+ import { SwitchProps } from 'antd/lib';
2
+ import { ReactNode } from 'react';
3
+ export interface SparkSwitchProps extends SwitchProps {
4
+ /**
5
+ * @description Switch后的内容
6
+ * @default info
7
+ */
8
+ label?: ReactNode;
9
+ }
10
+ declare const _default: (props: SparkSwitchProps) => import("react/jsx-runtime").JSX.Element;
11
+ export default _default;
@@ -0,0 +1,29 @@
1
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
2
+ var _excluded = ["label"];
3
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
4
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
7
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
8
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
9
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
10
+ import { Flex, Switch } from 'antd';
11
+ import { getCommonConfig } from "../../../config";
12
+ import useIndexStyle from "./index.style";
13
+ import { jsx as _jsx } from "react/jsx-runtime";
14
+ import { jsxs as _jsxs } from "react/jsx-runtime";
15
+ export default (function (props) {
16
+ useIndexStyle();
17
+ var label = props.label,
18
+ restProps = _objectWithoutProperties(props, _excluded);
19
+ var _getCommonConfig = getCommonConfig(),
20
+ sparkPrefix = _getCommonConfig.sparkPrefix;
21
+ return /*#__PURE__*/_jsxs(Flex, {
22
+ align: "center",
23
+ gap: 8,
24
+ children: [/*#__PURE__*/_jsx(Switch, _objectSpread({}, restProps)), /*#__PURE__*/_jsx("span", {
25
+ className: "".concat(sparkPrefix, "-switch-label"),
26
+ children: label
27
+ })]
28
+ });
29
+ });
@@ -0,0 +1,8 @@
1
+ export declare function getIndexStyleData(params: any): {
2
+ [x: string]: {
3
+ fontSize: string;
4
+ fontWeight: number;
5
+ };
6
+ };
7
+ declare const useIndexStyle: (props?: {}) => import("../../../config").CommonConfig;
8
+ export default useIndexStyle;
@@ -0,0 +1,23 @@
1
+ var _excluded = ["css"];
2
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
3
+ function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
4
+ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
7
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
8
+ import createStyle from "../../../libs/createStyle";
9
+ export function getIndexStyleData(params) {
10
+ var sparkPrefix = params.sparkPrefix,
11
+ antPrefix = params.antPrefix;
12
+ return _defineProperty({}, ".".concat(sparkPrefix, "-switch-label"), {
13
+ fontSize: '14px',
14
+ fontWeight: 500
15
+ });
16
+ }
17
+ var useIndexStyle = createStyle(function (_ref2) {
18
+ var css = _ref2.css,
19
+ params = _objectWithoutProperties(_ref2, _excluded);
20
+ var result = css(getIndexStyleData(params));
21
+ return result;
22
+ });
23
+ export default useIndexStyle;
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ declare const App: React.FC;
3
+ export default App;