@pisell/materials 1.0.363 → 1.0.365

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 (294) hide show
  1. package/build/lowcode/assets/7b1c7af5ce9e37e4b40ea53fea6ccfd9.jpeg +0 -0
  2. package/build/lowcode/assets-daily.json +13 -13
  3. package/build/lowcode/assets-dev.json +4 -4
  4. package/build/lowcode/assets-prod.json +13 -13
  5. package/build/lowcode/index.js +1 -1
  6. package/build/lowcode/meta.js +2 -2
  7. package/build/lowcode/preview.js +142 -142
  8. package/build/lowcode/render/default/assets/7b1c7af5ce9e37e4b40ea53fea6ccfd9.jpeg +0 -0
  9. package/build/lowcode/render/default/view.css +1 -1
  10. package/build/lowcode/render/default/view.js +29 -27
  11. package/build/lowcode/view.css +1 -1
  12. package/build/lowcode/view.js +23 -21
  13. package/dist/umd/materials.min.css +1 -0
  14. package/dist/umd/materials.min.js +1 -0
  15. package/dist/umd/static/DotsSix.57d66266.svg +1 -0
  16. package/dist/umd/static/arrow-left.e542294f.svg +1 -0
  17. package/dist/umd/static/arrow-right.763f03e0.svg +1 -0
  18. package/dist/umd/static/filter-lines.04a54ae9.svg +1 -0
  19. package/dist/umd/static/help-circle.31c9be40.svg +1 -0
  20. package/dist/umd/static/switch-vertical-01.7ebe3ba8.svg +1 -0
  21. package/es/components/button/index.d.ts +4 -3
  22. package/es/components/button/index.js +14 -3
  23. package/es/components/iconfont/index.d.ts +2 -1
  24. package/es/components/iconfont/index.js +1 -1
  25. package/es/components/page/index.css +0 -0
  26. package/es/components/page/index.d.ts +2 -2
  27. package/es/components/page/index.js +208 -185
  28. package/es/components/pisell-config-provider/context.d.ts +16 -0
  29. package/es/components/pisell-config-provider/context.js +32 -0
  30. package/es/components/pisell-config-provider/hooks/usePisellConfig.d.ts +2 -0
  31. package/es/components/pisell-config-provider/hooks/usePisellConfig.js +7 -0
  32. package/es/components/pisell-config-provider/index.d.ts +9 -0
  33. package/es/components/pisell-config-provider/index.js +32 -0
  34. package/es/components/pisellCard/bg.jpeg +0 -0
  35. package/es/components/pisellCard/index.d.ts +47 -0
  36. package/es/components/pisellCard/index.js +84 -0
  37. package/es/components/pisellCard/index.less +89 -0
  38. package/es/components/pisellCardList/index.d.ts +23 -0
  39. package/es/components/pisellCardList/index.js +104 -0
  40. package/es/components/pisellCardList/index.less +75 -0
  41. package/es/components/pisellCheckboxGroup/index.d.ts +26 -0
  42. package/es/components/pisellCheckboxGroup/index.js +144 -0
  43. package/es/components/pisellCheckboxGroup/index.less +36 -0
  44. package/es/components/pisellCheckboxGroup/mock.d.ts +4 -0
  45. package/es/components/pisellCheckboxGroup/mock.js +16 -0
  46. package/es/components/pisellContainer/components/Portal/index.d.ts +10 -0
  47. package/es/components/pisellContainer/components/Portal/index.js +7 -0
  48. package/es/components/pisellContainer/containers.d.ts +1 -0
  49. package/es/components/pisellContainer/containers.js +8 -0
  50. package/es/components/pisellContainer/index.d.ts +22 -0
  51. package/es/components/pisellContainer/index.js +17 -0
  52. package/es/components/pisellCountdown/index.d.ts +24 -0
  53. package/es/components/pisellCountdown/index.js +44 -0
  54. package/es/components/pisellCountdown/utils.d.ts +1 -0
  55. package/es/components/pisellCountdown/utils.js +35 -0
  56. package/es/components/pisellDatePicker/datePickerCpt.d.ts +12 -0
  57. package/es/components/pisellDatePicker/datePickerCpt.js +131 -0
  58. package/es/components/pisellDatePicker/detePickerCpt.less +3 -0
  59. package/es/components/pisellDatePicker/index.d.ts +3 -0
  60. package/es/components/pisellDatePicker/index.js +17 -0
  61. package/es/components/pisellEmpty/index.d.ts +16 -0
  62. package/es/components/pisellEmpty/index.js +38 -0
  63. package/es/components/pisellEmpty/index.less +34 -0
  64. package/es/components/pisellInput/components/BankCard/cardPng/AMEX.png +0 -0
  65. package/es/components/pisellInput/components/BankCard/cardPng/Discover.png +0 -0
  66. package/es/components/pisellInput/components/BankCard/cardPng/JCB.png +0 -0
  67. package/es/components/pisellInput/components/BankCard/cardPng/MasterCard.png +0 -0
  68. package/es/components/pisellInput/components/BankCard/cardPng/UnionPay.png +0 -0
  69. package/es/components/pisellInput/components/BankCard/cardPng/VISA.png +0 -0
  70. package/es/components/pisellInput/components/BankCard/index.d.ts +11 -0
  71. package/es/components/pisellInput/components/BankCard/index.js +82 -0
  72. package/es/components/pisellInput/components/BankCard/index.less +4 -0
  73. package/es/components/pisellInput/components/BankCard/utils.d.ts +11 -0
  74. package/es/components/pisellInput/components/BankCard/utils.js +65 -0
  75. package/es/components/pisellInput/components/Copy/index.d.ts +11 -0
  76. package/es/components/pisellInput/components/Copy/index.js +53 -0
  77. package/es/components/pisellInput/components/SecurityCode/card.png +0 -0
  78. package/es/components/pisellInput/components/SecurityCode/index.d.ts +12 -0
  79. package/es/components/pisellInput/components/SecurityCode/index.js +46 -0
  80. package/es/components/pisellInput/components/SecurityCode/index.less +4 -0
  81. package/es/components/pisellInput/index.d.ts +13 -0
  82. package/es/components/pisellInput/index.js +15 -0
  83. package/es/components/pisellLoading/index.d.ts +15 -0
  84. package/es/components/pisellLoading/index.js +48 -0
  85. package/es/components/pisellLoading/index.less +35 -0
  86. package/es/components/pisellMessage/index.d.ts +4 -0
  87. package/es/components/pisellMessage/index.js +5 -0
  88. package/es/components/pisellModal/components/Information/index.d.ts +21 -0
  89. package/es/components/pisellModal/components/Information/index.js +23 -0
  90. package/es/components/pisellModal/components/Information/index.less +15 -0
  91. package/es/components/pisellModal/components/IpadModal/index.d.ts +6 -0
  92. package/es/components/pisellModal/components/IpadModal/index.js +6 -0
  93. package/es/components/pisellModal/components/MobileModal/index.d.ts +9 -0
  94. package/es/components/pisellModal/components/MobileModal/index.js +26 -0
  95. package/es/components/pisellModal/components/MobileModal/index.less +59 -0
  96. package/es/components/pisellModal/components/PcModal/index.d.ts +30 -0
  97. package/es/components/pisellModal/components/PcModal/index.js +129 -0
  98. package/es/components/pisellModal/components/PcModal/index.less +38 -0
  99. package/es/components/pisellModal/components/functions/index.d.ts +12 -0
  100. package/es/components/pisellModal/components/functions/index.js +44 -0
  101. package/es/components/pisellModal/components/functions/index.less +25 -0
  102. package/es/components/pisellModal/components/index.d.ts +10 -0
  103. package/es/components/pisellModal/components/index.js +9 -0
  104. package/es/components/pisellModal/constants.d.ts +6 -0
  105. package/es/components/pisellModal/constants.js +6 -0
  106. package/es/components/pisellModal/index.d.ts +43 -0
  107. package/es/components/pisellModal/index.js +30 -0
  108. package/es/components/pisellRow/index.d.ts +14 -0
  109. package/es/components/pisellRow/index.js +54 -0
  110. package/es/components/pisellRow/index.less +13 -0
  111. package/es/components/pisellText/components/Amount/index.d.ts +18 -0
  112. package/es/components/pisellText/components/Amount/index.js +25 -0
  113. package/es/components/pisellText/index.d.ts +8 -0
  114. package/es/components/pisellText/index.js +7 -0
  115. package/es/components/pisellToast/index.d.ts +16 -0
  116. package/es/components/pisellToast/index.js +32 -0
  117. package/es/components/pisellToast/index.less +26 -0
  118. package/es/components/pisellTooltip/index.d.ts +10 -0
  119. package/es/components/pisellTooltip/index.js +18 -0
  120. package/es/components/pisellTooltip/index.less +5 -0
  121. package/es/hooks/useCssVariables.d.ts +8 -0
  122. package/es/hooks/useCssVariables.js +21 -0
  123. package/es/index.d.ts +18 -0
  124. package/es/index.js +19 -1
  125. package/es/locales/en-US.d.ts +3 -0
  126. package/es/locales/en-US.js +5 -1
  127. package/es/locales/zh-CN.d.ts +3 -0
  128. package/es/locales/zh-CN.js +5 -1
  129. package/es/locales/zh-TW.d.ts +3 -0
  130. package/es/locales/zh-TW.js +5 -1
  131. package/es/utils/index.d.ts +1 -0
  132. package/es/utils/index.js +15 -1
  133. package/lib/components/button/index.d.ts +4 -3
  134. package/lib/components/button/index.js +13 -9
  135. package/lib/components/iconfont/index.d.ts +2 -1
  136. package/lib/components/iconfont/index.js +1 -1
  137. package/lib/components/page/index.css +0 -0
  138. package/lib/components/page/index.d.ts +2 -2
  139. package/lib/components/page/index.js +172 -159
  140. package/lib/components/pisell-config-provider/context.d.ts +16 -0
  141. package/lib/components/pisell-config-provider/context.js +49 -0
  142. package/lib/components/pisell-config-provider/hooks/usePisellConfig.d.ts +2 -0
  143. package/lib/components/pisell-config-provider/hooks/usePisellConfig.js +31 -0
  144. package/lib/components/pisell-config-provider/index.d.ts +9 -0
  145. package/lib/components/pisell-config-provider/index.js +61 -0
  146. package/lib/components/pisellCard/bg.jpeg +0 -0
  147. package/lib/components/pisellCard/index.d.ts +47 -0
  148. package/lib/components/pisellCard/index.js +97 -0
  149. package/lib/components/pisellCard/index.less +89 -0
  150. package/lib/components/pisellCardList/index.d.ts +23 -0
  151. package/lib/components/pisellCardList/index.js +146 -0
  152. package/lib/components/pisellCardList/index.less +75 -0
  153. package/lib/components/pisellCheckboxGroup/index.d.ts +26 -0
  154. package/lib/components/pisellCheckboxGroup/index.js +151 -0
  155. package/lib/components/pisellCheckboxGroup/index.less +36 -0
  156. package/lib/components/pisellCheckboxGroup/mock.d.ts +4 -0
  157. package/lib/components/pisellCheckboxGroup/mock.js +35 -0
  158. package/lib/components/pisellContainer/components/Portal/index.d.ts +10 -0
  159. package/lib/components/pisellContainer/components/Portal/index.js +40 -0
  160. package/lib/components/pisellContainer/containers.d.ts +1 -0
  161. package/lib/components/pisellContainer/containers.js +46 -0
  162. package/lib/components/pisellContainer/index.d.ts +22 -0
  163. package/lib/components/pisellContainer/index.js +49 -0
  164. package/lib/components/pisellCountdown/index.d.ts +24 -0
  165. package/lib/components/pisellCountdown/index.js +63 -0
  166. package/lib/components/pisellCountdown/utils.d.ts +1 -0
  167. package/lib/components/pisellCountdown/utils.js +60 -0
  168. package/lib/components/pisellDatePicker/datePickerCpt.d.ts +12 -0
  169. package/lib/components/pisellDatePicker/datePickerCpt.js +157 -0
  170. package/lib/components/pisellDatePicker/detePickerCpt.less +3 -0
  171. package/lib/components/pisellDatePicker/index.d.ts +3 -0
  172. package/lib/components/pisellDatePicker/index.js +48 -0
  173. package/lib/components/pisellEmpty/index.d.ts +16 -0
  174. package/lib/components/pisellEmpty/index.js +61 -0
  175. package/lib/components/pisellEmpty/index.less +34 -0
  176. package/lib/components/pisellInput/components/BankCard/cardPng/AMEX.png +0 -0
  177. package/lib/components/pisellInput/components/BankCard/cardPng/Discover.png +0 -0
  178. package/lib/components/pisellInput/components/BankCard/cardPng/JCB.png +0 -0
  179. package/lib/components/pisellInput/components/BankCard/cardPng/MasterCard.png +0 -0
  180. package/lib/components/pisellInput/components/BankCard/cardPng/UnionPay.png +0 -0
  181. package/lib/components/pisellInput/components/BankCard/cardPng/VISA.png +0 -0
  182. package/lib/components/pisellInput/components/BankCard/index.d.ts +11 -0
  183. package/lib/components/pisellInput/components/BankCard/index.js +98 -0
  184. package/lib/components/pisellInput/components/BankCard/index.less +4 -0
  185. package/lib/components/pisellInput/components/BankCard/utils.d.ts +11 -0
  186. package/lib/components/pisellInput/components/BankCard/utils.js +103 -0
  187. package/lib/components/pisellInput/components/Copy/index.d.ts +11 -0
  188. package/lib/components/pisellInput/components/Copy/index.js +61 -0
  189. package/lib/components/pisellInput/components/SecurityCode/card.png +0 -0
  190. package/lib/components/pisellInput/components/SecurityCode/index.d.ts +12 -0
  191. package/lib/components/pisellInput/components/SecurityCode/index.js +74 -0
  192. package/lib/components/pisellInput/components/SecurityCode/index.less +4 -0
  193. package/lib/components/pisellInput/index.d.ts +13 -0
  194. package/lib/components/pisellInput/index.js +46 -0
  195. package/lib/components/pisellLoading/index.d.ts +15 -0
  196. package/lib/components/pisellLoading/index.js +72 -0
  197. package/lib/components/pisellLoading/index.less +35 -0
  198. package/lib/components/pisellMessage/index.d.ts +4 -0
  199. package/lib/components/pisellMessage/index.js +34 -0
  200. package/lib/components/pisellModal/components/Information/index.d.ts +21 -0
  201. package/lib/components/pisellModal/components/Information/index.js +53 -0
  202. package/lib/components/pisellModal/components/Information/index.less +15 -0
  203. package/lib/components/pisellModal/components/IpadModal/index.d.ts +6 -0
  204. package/lib/components/pisellModal/components/IpadModal/index.js +40 -0
  205. package/lib/components/pisellModal/components/MobileModal/index.d.ts +9 -0
  206. package/lib/components/pisellModal/components/MobileModal/index.js +66 -0
  207. package/lib/components/pisellModal/components/MobileModal/index.less +59 -0
  208. package/lib/components/pisellModal/components/PcModal/index.d.ts +30 -0
  209. package/lib/components/pisellModal/components/PcModal/index.js +143 -0
  210. package/lib/components/pisellModal/components/PcModal/index.less +38 -0
  211. package/lib/components/pisellModal/components/functions/index.d.ts +12 -0
  212. package/lib/components/pisellModal/components/functions/index.js +90 -0
  213. package/lib/components/pisellModal/components/functions/index.less +25 -0
  214. package/lib/components/pisellModal/components/index.d.ts +10 -0
  215. package/lib/components/pisellModal/components/index.js +52 -0
  216. package/lib/components/pisellModal/constants.d.ts +6 -0
  217. package/lib/components/pisellModal/constants.js +33 -0
  218. package/lib/components/pisellModal/index.d.ts +43 -0
  219. package/lib/components/pisellModal/index.js +63 -0
  220. package/lib/components/pisellRow/index.d.ts +14 -0
  221. package/lib/components/pisellRow/index.js +85 -0
  222. package/lib/components/pisellRow/index.less +13 -0
  223. package/lib/components/pisellText/components/Amount/index.d.ts +18 -0
  224. package/lib/components/pisellText/components/Amount/index.js +64 -0
  225. package/lib/components/pisellText/index.d.ts +8 -0
  226. package/lib/components/pisellText/index.js +41 -0
  227. package/lib/components/pisellToast/index.d.ts +16 -0
  228. package/lib/components/pisellToast/index.js +59 -0
  229. package/lib/components/pisellToast/index.less +26 -0
  230. package/lib/components/pisellTooltip/index.d.ts +10 -0
  231. package/lib/components/pisellTooltip/index.js +56 -0
  232. package/lib/components/pisellTooltip/index.less +5 -0
  233. package/lib/hooks/useCssVariables.d.ts +8 -0
  234. package/lib/hooks/useCssVariables.js +36 -0
  235. package/lib/index.d.ts +18 -0
  236. package/lib/index.js +54 -0
  237. package/lib/locales/en-US.d.ts +3 -0
  238. package/lib/locales/en-US.js +5 -1
  239. package/lib/locales/zh-CN.d.ts +3 -0
  240. package/lib/locales/zh-CN.js +5 -1
  241. package/lib/locales/zh-TW.d.ts +3 -0
  242. package/lib/locales/zh-TW.js +5 -1
  243. package/lib/utils/index.d.ts +1 -0
  244. package/lib/utils/index.js +16 -0
  245. package/lowcode/_utils/transform-meta.ts +31 -10
  246. package/lowcode/button/__screenshots__/pisell-modal-information.png +0 -0
  247. package/lowcode/button/meta.ts +30 -0
  248. package/lowcode/button/snippets.ts +28 -0
  249. package/lowcode/information-modal/meta.ts +44 -1
  250. package/lowcode/modal/meta.ts +1 -1
  251. package/lowcode/pisell-card/meta.ts +189 -0
  252. package/lowcode/pisell-card/snippets.ts +20 -0
  253. package/lowcode/pisell-card-list/meta.ts +145 -0
  254. package/lowcode/pisell-card-list/snippets.ts +9 -0
  255. package/lowcode/pisell-checkbox-group/meta.ts +112 -0
  256. package/lowcode/pisell-checkbox-group/snippets.ts +13 -0
  257. package/lowcode/pisell-container/meta.ts +71 -0
  258. package/lowcode/pisell-container/snippets.ts +14 -0
  259. package/lowcode/pisell-countdown/meta.ts +71 -0
  260. package/lowcode/pisell-countdown/snippets.ts +12 -0
  261. package/lowcode/pisell-date-picker/meta.ts +76 -0
  262. package/lowcode/pisell-date-picker/snippets.ts +9 -0
  263. package/lowcode/pisell-empty/__screenshots__/empty-1.png +0 -0
  264. package/lowcode/pisell-empty/meta.ts +85 -0
  265. package/lowcode/pisell-empty/snippets.ts +10 -0
  266. package/lowcode/pisell-input/__screenshots__/input-1.png +0 -0
  267. package/lowcode/pisell-input/meta.ts +193 -0
  268. package/lowcode/pisell-input/snippets.ts +11 -0
  269. package/lowcode/pisell-input.bank-card-input/__screenshots__/pisell-input.bank-card-input.png +0 -0
  270. package/lowcode/pisell-input.bank-card-input/meta.ts +62 -0
  271. package/lowcode/pisell-input.bank-card-input/snippets.ts +11 -0
  272. package/lowcode/pisell-input.copy/meta.ts +73 -0
  273. package/lowcode/pisell-input.copy/snippets.ts +10 -0
  274. package/lowcode/pisell-input.security-code/__screenshots__/pisell-input.security-code.png +0 -0
  275. package/lowcode/pisell-input.security-code/meta.ts +92 -0
  276. package/lowcode/pisell-input.security-code/snippets.ts +11 -0
  277. package/lowcode/pisell-loading/meta.ts +98 -0
  278. package/lowcode/pisell-loading/snippets.ts +11 -0
  279. package/lowcode/pisell-modal/__screenshots__/modal-1.png +0 -0
  280. package/lowcode/pisell-modal/__screenshots__/modal-2.png +0 -0
  281. package/lowcode/pisell-modal/meta.ts +200 -0
  282. package/lowcode/pisell-modal/snippets.ts +38 -0
  283. package/lowcode/pisell-modal.information/__screenshots__/pisell-modal.information.png +0 -0
  284. package/lowcode/pisell-modal.information/meta.ts +109 -0
  285. package/lowcode/pisell-modal.information/snippets.ts +17 -0
  286. package/lowcode/pisell-row/meta.ts +127 -0
  287. package/lowcode/pisell-row/snippets.ts +24 -0
  288. package/lowcode/pisell-text/meta.ts +8117 -0
  289. package/lowcode/pisell-text.amount/meta.ts +61 -0
  290. package/lowcode/pisell-text.amount/snippets.ts +15 -0
  291. package/lowcode/pisell-tooltip/__screenshots__/tooltip-1.jpg +0 -0
  292. package/lowcode/pisell-tooltip/meta.ts +306 -0
  293. package/lowcode/pisell-tooltip/snippets.ts +12 -0
  294. package/package.json +3 -3
@@ -0,0 +1,61 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/components/pisellEmpty/index.tsx
30
+ var pisellEmpty_exports = {};
31
+ __export(pisellEmpty_exports, {
32
+ default: () => pisellEmpty_default
33
+ });
34
+ module.exports = __toCommonJS(pisellEmpty_exports);
35
+ var import_react = __toESM(require("react"));
36
+ var import_antd = require("antd");
37
+ var import_classnames = __toESM(require("classnames"));
38
+ var import_Inbox01 = __toESM(require("@pisell/icon/es/Inbox01"));
39
+ var import_locales = require("../../locales");
40
+ var import_index = require("./index.less");
41
+ var PisellEmpty = (props) => {
42
+ const {
43
+ description = (0, import_locales.getText)("pisell-empty-description-no-data"),
44
+ extraDescription,
45
+ icon,
46
+ footer,
47
+ className,
48
+ ...others
49
+ } = props;
50
+ return /* @__PURE__ */ import_react.default.createElement(
51
+ import_antd.Empty,
52
+ {
53
+ ...others,
54
+ className: (0, import_classnames.default)("pisell-empty-wrap", className),
55
+ image: /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-empty-icon-wrap" }, icon || /* @__PURE__ */ import_react.default.createElement(import_Inbox01.default, { style: { color: "#667085" } })),
56
+ description: /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-empty-wrap-description-wrap" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-empty-wrap-description" }, description), /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-empty-wrap-extra-description" }, extraDescription))
57
+ },
58
+ footer
59
+ );
60
+ };
61
+ var pisellEmpty_default = PisellEmpty;
@@ -0,0 +1,34 @@
1
+ .pisell-empty-wrap {
2
+ margin: 50px auto;
3
+ display: flex;
4
+ flex-direction: column;
5
+ align-items: center;
6
+ .pisell-lowcode-empty-image {
7
+ height: auto;
8
+ margin-bottom: 0;
9
+ }
10
+ .pisell-empty-icon-wrap {
11
+ .anticon {
12
+ font-size: 44px !important;
13
+ }
14
+ }
15
+ .pisell-empty-wrap-description-wrap {
16
+ max-width: 300px;
17
+ .pisell-empty-wrap-description {
18
+ color: var(--Gray-500, #667085);
19
+ font-size: 14px;
20
+ font-style: normal;
21
+ font-weight: 600;
22
+ line-height: 20px; /* 142.857% */
23
+ margin: 12px 0;
24
+ }
25
+ .pisell-empty-wrap-extra-description {
26
+ color: var(--Gray-500, #667085);
27
+ text-align: center;
28
+ font-size: 14px;
29
+ font-style: normal;
30
+ font-weight: 400;
31
+ line-height: 20px; /* 142.857% */
32
+ }
33
+ }
34
+ }
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import { InputProps } from 'antd';
3
+ import { PisellContextType } from "../../../pisell-config-provider/context";
4
+ import './index.less';
5
+ export declare type BankCardProps = InputProps & {
6
+ /** 平台 */
7
+ platform?: PisellContextType['platform'];
8
+ onChange?: (val: string) => void;
9
+ };
10
+ declare const BankCard: (props: BankCardProps) => React.JSX.Element;
11
+ export default BankCard;
@@ -0,0 +1,98 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/components/pisellInput/components/BankCard/index.tsx
30
+ var BankCard_exports = {};
31
+ __export(BankCard_exports, {
32
+ default: () => BankCard_default
33
+ });
34
+ module.exports = __toCommonJS(BankCard_exports);
35
+ var import_react = __toESM(require("react"));
36
+ var import_input = __toESM(require("../../../input"));
37
+ var import_utils = require("./utils");
38
+ var import_index = require("./index.less");
39
+ var bankCardMaxLength = (str) => {
40
+ return str.slice(0, 19);
41
+ };
42
+ var BankCard = (props) => {
43
+ const { onChange, value: propsValue, ...others } = props;
44
+ const inputRef = (0, import_react.useRef)(null);
45
+ const [_value, setValue] = (0, import_react.useState)(propsValue || "");
46
+ const [currentBankType, setCurrentBankType] = (0, import_react.useState)();
47
+ (0, import_react.useEffect)(() => {
48
+ document.body.id = "body";
49
+ }, []);
50
+ (0, import_react.useEffect)(() => {
51
+ setValue(bankCardMaxLength(formatBankCardNumber(`${propsValue || ""}`)));
52
+ }, [propsValue]);
53
+ const formatBankCardNumber = (value) => {
54
+ const cleanValue = value.replace(/\D/g, "");
55
+ const formattedValue = cleanValue.replace(/(.{4})/g, "$1 ").trim();
56
+ return formattedValue;
57
+ };
58
+ const handleChange = (e) => {
59
+ var _a, _b;
60
+ const { value } = e.target;
61
+ setCurrentBankType((0, import_utils.getCardType)(value));
62
+ const formattedValue = formatBankCardNumber(value);
63
+ let start = ((_b = (_a = inputRef.current) == null ? void 0 : _a.input) == null ? void 0 : _b.selectionStart) || 0;
64
+ const val = bankCardMaxLength(formattedValue);
65
+ setValue(val);
66
+ onChange == null ? void 0 : onChange(val.replace(/\s/g, ""));
67
+ if (formattedValue.length > 19 || formattedValue.length < _value.length) {
68
+ if ([4, 9, 14, 19].includes(start)) {
69
+ start = start + 1;
70
+ }
71
+ setTimeout(() => {
72
+ var _a2;
73
+ (_a2 = inputRef.current) == null ? void 0 : _a2.setSelectionRange(start, start);
74
+ });
75
+ }
76
+ };
77
+ return /* @__PURE__ */ import_react.default.createElement(
78
+ import_input.default,
79
+ {
80
+ ...others,
81
+ suffix: currentBankType ? /* @__PURE__ */ import_react.default.createElement(
82
+ "img",
83
+ {
84
+ className: "pisell-input-bank-card-suffix",
85
+ src: import_utils.bankTypeMap[currentBankType],
86
+ alt: currentBankType
87
+ }
88
+ ) : /* @__PURE__ */ import_react.default.createElement("span", null),
89
+ type: "tel",
90
+ placeholder: "XXXX XXXX XXXX XXXX",
91
+ size: "large",
92
+ ref: inputRef,
93
+ value: _value,
94
+ onChange: handleChange
95
+ }
96
+ );
97
+ };
98
+ var BankCard_default = BankCard;
@@ -0,0 +1,4 @@
1
+ .pisell-input-bank-card-suffix {
2
+ width: 34px;
3
+ height: 24px;
4
+ }
@@ -0,0 +1,11 @@
1
+ export declare const getCardType: (str: string) => "jcb" | "amex" | "visa" | "masterCard" | "unionPay" | "discover" | undefined;
2
+ export declare const bankTypeMap: {
3
+ jcb: any;
4
+ amex: any;
5
+ masterCard: any;
6
+ visa: any;
7
+ unionPay: any;
8
+ discover: any;
9
+ };
10
+ export declare const getCardImgByType: (type: keyof typeof bankTypeMap) => any;
11
+ export declare const getBankCardTypeImg: (val: number | string) => any;
@@ -0,0 +1,103 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/components/pisellInput/components/BankCard/utils.ts
30
+ var utils_exports = {};
31
+ __export(utils_exports, {
32
+ bankTypeMap: () => bankTypeMap,
33
+ getBankCardTypeImg: () => getBankCardTypeImg,
34
+ getCardImgByType: () => getCardImgByType,
35
+ getCardType: () => getCardType
36
+ });
37
+ module.exports = __toCommonJS(utils_exports);
38
+ var import_JCB = __toESM(require("./cardPng/JCB.png"));
39
+ var import_AMEX = __toESM(require("./cardPng/AMEX.png"));
40
+ var import_MasterCard = __toESM(require("./cardPng/MasterCard.png"));
41
+ var import_VISA = __toESM(require("./cardPng/VISA.png"));
42
+ var import_UnionPay = __toESM(require("./cardPng/UnionPay.png"));
43
+ var import_Discover = __toESM(require("./cardPng/Discover.png"));
44
+ var isJcb = (str) => {
45
+ return str.startsWith("35");
46
+ };
47
+ var isAmex = (str) => {
48
+ return str.startsWith("34") || str.startsWith("37");
49
+ };
50
+ var isMasterCard = (str) => {
51
+ return str.startsWith("51") || str.startsWith("52") || str.startsWith("53") || str.startsWith("54") || str.startsWith("55") || str.startsWith("22") || str.startsWith("23") || str.startsWith("24") || str.startsWith("25") || str.startsWith("26") || str.startsWith("27");
52
+ };
53
+ var isVisa = (str) => {
54
+ return str.startsWith("4");
55
+ };
56
+ var isUnionPay = (str) => {
57
+ return str.startsWith("62") || str.startsWith("81");
58
+ };
59
+ var isDiscover = (str) => {
60
+ return str.startsWith("60") || str.startsWith("64") || str.startsWith("65");
61
+ };
62
+ var getCardType = (str) => {
63
+ if (isJcb(str)) {
64
+ return "jcb";
65
+ }
66
+ if (isAmex(str)) {
67
+ return "amex";
68
+ }
69
+ if (isVisa(str)) {
70
+ return "visa";
71
+ }
72
+ if (isMasterCard(str)) {
73
+ return "masterCard";
74
+ }
75
+ if (isUnionPay(str)) {
76
+ return "unionPay";
77
+ }
78
+ if (isDiscover(str)) {
79
+ return "discover";
80
+ }
81
+ };
82
+ var bankTypeMap = {
83
+ jcb: import_JCB.default,
84
+ amex: import_AMEX.default,
85
+ masterCard: import_MasterCard.default,
86
+ visa: import_VISA.default,
87
+ unionPay: import_UnionPay.default,
88
+ discover: import_Discover.default
89
+ };
90
+ var getCardImgByType = (type) => {
91
+ return bankTypeMap[type] || "";
92
+ };
93
+ var getBankCardTypeImg = (val) => {
94
+ const type = getCardType(`${val || ""}`);
95
+ return type ? bankTypeMap[type] : null;
96
+ };
97
+ // Annotate the CommonJS export names for ESM import in node:
98
+ 0 && (module.exports = {
99
+ bankTypeMap,
100
+ getBankCardTypeImg,
101
+ getCardImgByType,
102
+ getCardType
103
+ });
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import { InputProps, ButtonProps } from 'antd';
3
+ import { PisellContextType } from "../../../pisell-config-provider/context";
4
+ export interface CopyProps extends InputProps {
5
+ /** 平台 */
6
+ platform?: PisellContextType['platform'];
7
+ /** 后缀button的透传配置 */
8
+ buttonProps?: ButtonProps;
9
+ }
10
+ declare const Copy: (props: CopyProps) => React.JSX.Element;
11
+ export default Copy;
@@ -0,0 +1,61 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/components/pisellInput/components/Copy/index.tsx
30
+ var Copy_exports = {};
31
+ __export(Copy_exports, {
32
+ default: () => Copy_default
33
+ });
34
+ module.exports = __toCommonJS(Copy_exports);
35
+ var import_react = __toESM(require("react"));
36
+ var import_antd = require("antd");
37
+ var import_utils = require("@pisell/utils");
38
+ var import_input = __toESM(require("../../../input"));
39
+ var import_icon = __toESM(require("../../../icon"));
40
+ var import_locales = require("../../../../locales");
41
+ var Copy = (props) => {
42
+ const { buttonProps } = props;
43
+ const inputRef = (0, import_react.useRef)(null);
44
+ const handleCopyClick = async (e) => {
45
+ var _a, _b, _c;
46
+ (_a = buttonProps == null ? void 0 : buttonProps.onClick) == null ? void 0 : _a.call(buttonProps, e);
47
+ await (0, import_utils.copyToClipboard)(((_c = (_b = inputRef.current) == null ? void 0 : _b.input) == null ? void 0 : _c.value) || "");
48
+ import_antd.message.success((0, import_locales.getText)("pisell-input-copy-success"));
49
+ };
50
+ return /* @__PURE__ */ import_react.default.createElement(import_antd.Space.Compact, { block: true }, /* @__PURE__ */ import_react.default.createElement(import_input.default, { ...props, ref: inputRef, disabled: props.disabled ?? true, size: "large" }), /* @__PURE__ */ import_react.default.createElement(
51
+ import_antd.Button,
52
+ {
53
+ size: "large",
54
+ icon: /* @__PURE__ */ import_react.default.createElement(import_icon.default, { type: "pisell2-copy-03" }),
55
+ ...buttonProps,
56
+ onClick: handleCopyClick,
57
+ children: (buttonProps == null ? void 0 : buttonProps.children) || (0, import_locales.getText)("pisell-input-copy")
58
+ }
59
+ ));
60
+ };
61
+ var Copy_default = Copy;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { InputProps } from 'antd';
3
+ import './index.less';
4
+ import { PisellContextType } from "../../../pisell-config-provider/context";
5
+ export interface SecurityCodeProps extends Omit<InputProps, 'onChange'> {
6
+ /** 平台 */
7
+ platform?: PisellContextType['platform'];
8
+ onChange?: (val: string) => void;
9
+ showCVCIcon?: boolean;
10
+ }
11
+ declare const SecurityCode: (props: SecurityCodeProps) => React.JSX.Element;
12
+ export default SecurityCode;
@@ -0,0 +1,74 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/components/pisellInput/components/SecurityCode/index.tsx
30
+ var SecurityCode_exports = {};
31
+ __export(SecurityCode_exports, {
32
+ default: () => SecurityCode_default
33
+ });
34
+ module.exports = __toCommonJS(SecurityCode_exports);
35
+ var import_react = __toESM(require("react"));
36
+ var import_ahooks = require("ahooks");
37
+ var import_input = __toESM(require("../../../input"));
38
+ var import_card = __toESM(require("./card.png"));
39
+ var import_index = require("./index.less");
40
+ var SecurityCode = (props) => {
41
+ const { maxLength, showCVCIcon = true } = props;
42
+ const [state, setState] = (0, import_ahooks.useControllableValue)(props, {
43
+ defaultValue: ""
44
+ });
45
+ const handleChange = (e) => {
46
+ const { value } = e.target;
47
+ let numberValue = value.replace(/\D/g, "");
48
+ if (maxLength) {
49
+ numberValue = numberValue.slice(0, maxLength);
50
+ }
51
+ setState == null ? void 0 : setState(numberValue);
52
+ };
53
+ return /* @__PURE__ */ import_react.default.createElement(
54
+ import_input.default,
55
+ {
56
+ ...props,
57
+ value: state,
58
+ onChange: handleChange,
59
+ maxLength,
60
+ size: "large",
61
+ placeholder: "CVC",
62
+ type: "number",
63
+ suffix: showCVCIcon && /* @__PURE__ */ import_react.default.createElement(
64
+ "img",
65
+ {
66
+ className: "pisell-security-code-suffix",
67
+ src: import_card.default,
68
+ alt: "security code img"
69
+ }
70
+ )
71
+ }
72
+ );
73
+ };
74
+ var SecurityCode_default = SecurityCode;
@@ -0,0 +1,4 @@
1
+ .pisell-security-code-suffix {
2
+ width: 34px;
3
+ height: 24px;
4
+ }
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ import { InputProps } from 'antd';
3
+ import { PisellContextType } from '../pisell-config-provider/context';
4
+ declare const PisellInput: {
5
+ (props: InputProps & {
6
+ /** 平台 */
7
+ platform?: PisellContextType['platform'];
8
+ }): React.JSX.Element;
9
+ BankCard: (props: import("./components/BankCard").BankCardProps) => React.JSX.Element;
10
+ SecurityCode: (props: import("./components/SecurityCode").SecurityCodeProps) => React.JSX.Element;
11
+ Copy: (props: import("./components/Copy").CopyProps) => React.JSX.Element;
12
+ };
13
+ export default PisellInput;
@@ -0,0 +1,46 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/components/pisellInput/index.tsx
30
+ var pisellInput_exports = {};
31
+ __export(pisellInput_exports, {
32
+ default: () => pisellInput_default
33
+ });
34
+ module.exports = __toCommonJS(pisellInput_exports);
35
+ var import_react = __toESM(require("react"));
36
+ var import_input = __toESM(require("../input"));
37
+ var import_BankCard = __toESM(require("./components/BankCard"));
38
+ var import_SecurityCode = __toESM(require("./components/SecurityCode"));
39
+ var import_Copy = __toESM(require("./components/Copy"));
40
+ var PisellInput = (props) => {
41
+ return /* @__PURE__ */ import_react.default.createElement(import_input.default, { ...props, size: props.size || "large" });
42
+ };
43
+ PisellInput.BankCard = import_BankCard.default;
44
+ PisellInput.SecurityCode = import_SecurityCode.default;
45
+ PisellInput.Copy = import_Copy.default;
46
+ var pisellInput_default = PisellInput;
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ import { SpinProps } from 'antd';
3
+ import './index.less';
4
+ declare type MaskType = {
5
+ width: number | string;
6
+ height: number | string;
7
+ backgroundColor: string;
8
+ };
9
+ export interface PisellLoadingProps extends SpinProps {
10
+ loading: boolean;
11
+ mask?: boolean | MaskType;
12
+ fullscreen?: boolean;
13
+ }
14
+ declare const PisellLoading: (props: PisellLoadingProps) => React.JSX.Element;
15
+ export default PisellLoading;
@@ -0,0 +1,72 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/components/pisellLoading/index.tsx
30
+ var pisellLoading_exports = {};
31
+ __export(pisellLoading_exports, {
32
+ default: () => pisellLoading_default
33
+ });
34
+ module.exports = __toCommonJS(pisellLoading_exports);
35
+ var import_react = __toESM(require("react"));
36
+ var import_antd = require("antd");
37
+ var import_iconfont = __toESM(require("../iconfont"));
38
+ var import_useCssVariables = __toESM(require("../../hooks/useCssVariables"));
39
+ var import_utils = require("../../utils");
40
+ var import_index = require("./index.less");
41
+ var PisellLoading = (props) => {
42
+ const { children, fullscreen, mask, loading } = props;
43
+ const ref = (0, import_react.useRef)(null);
44
+ const {
45
+ backgroundColor = "#fff",
46
+ width = "100%",
47
+ height = "100%"
48
+ } = mask || {};
49
+ (0, import_useCssVariables.default)({
50
+ variables: {
51
+ "--pisell-loading-mask-opacity": mask ? "1" : "0",
52
+ "--pisell-loading-bg-color": fullscreen && !mask ? "transparent" : backgroundColor,
53
+ "--pisell-loading-bg-width": (0, import_utils.getCssNumber)(width) || "100%",
54
+ "--pisell-loading-bg-height": (0, import_utils.getCssNumber)(height) || "100%",
55
+ "--pisell-loading-bg-border-radius": width !== "100%" || height !== "100%" ? "12px" : "0px"
56
+ },
57
+ ref
58
+ });
59
+ (0, import_react.useEffect)(() => {
60
+ document.body.id = "body";
61
+ }, []);
62
+ return /* @__PURE__ */ import_react.default.createElement("div", { ref, className: "pisell-loading-wrapper" }, /* @__PURE__ */ import_react.default.createElement(
63
+ import_antd.Spin,
64
+ {
65
+ fullscreen,
66
+ spinning: loading,
67
+ indicator: /* @__PURE__ */ import_react.default.createElement(import_iconfont.default, { type: "pisell2-loader2", style: { fontSize: 40 }, spin: true })
68
+ },
69
+ children
70
+ ));
71
+ };
72
+ var pisellLoading_default = PisellLoading;