@kne-components/components-core 0.4.45 → 0.4.46

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 (173) hide show
  1. package/build/asset-manifest.json +111 -111
  2. package/build/index.html +1 -1
  3. package/build/remoteEntry.js +1 -1
  4. package/build/remoteEntry.js.map +1 -1
  5. package/build/static/css/1381.97c23e40.chunk.css +2 -0
  6. package/build/static/css/1381.97c23e40.chunk.css.map +1 -0
  7. package/build/static/css/1742.72826de6.chunk.css +2 -0
  8. package/build/static/css/{1742.12f27291.chunk.css.map → 1742.72826de6.chunk.css.map} +1 -1
  9. package/build/static/css/{1996.e97d56df.chunk.css → 1996.052f96b0.chunk.css} +2 -2
  10. package/build/static/css/{1996.e97d56df.chunk.css.map → 1996.052f96b0.chunk.css.map} +1 -1
  11. package/build/static/css/2004.59eeddc7.chunk.css +2 -0
  12. package/build/static/css/{2004.33c1e186.chunk.css.map → 2004.59eeddc7.chunk.css.map} +1 -1
  13. package/build/static/css/2307.4b3df026.chunk.css +2 -0
  14. package/build/static/css/2307.4b3df026.chunk.css.map +1 -0
  15. package/build/static/css/254.ee7957b1.chunk.css +2 -0
  16. package/build/static/css/254.ee7957b1.chunk.css.map +1 -0
  17. package/build/static/css/3404.f9aed7da.chunk.css +2 -0
  18. package/build/static/css/{3404.6f0b882e.chunk.css.map → 3404.f9aed7da.chunk.css.map} +1 -1
  19. package/build/static/css/3625.de3c6911.chunk.css +2 -0
  20. package/build/static/css/3625.de3c6911.chunk.css.map +1 -0
  21. package/build/static/css/{3771.accb9a83.chunk.css → 3771.0b0ceea9.chunk.css} +2 -2
  22. package/build/static/css/{3771.accb9a83.chunk.css.map → 3771.0b0ceea9.chunk.css.map} +1 -1
  23. package/build/static/css/{3790.8118caa7.chunk.css → 3790.0a878038.chunk.css} +2 -2
  24. package/build/static/css/{3790.8118caa7.chunk.css.map → 3790.0a878038.chunk.css.map} +1 -1
  25. package/build/static/css/5195.841f8004.chunk.css +2 -0
  26. package/build/static/css/5195.841f8004.chunk.css.map +1 -0
  27. package/build/static/css/{5582.877dc4db.chunk.css → 5582.1990debe.chunk.css} +2 -2
  28. package/build/static/css/5582.1990debe.chunk.css.map +1 -0
  29. package/build/static/css/5633.97c23e40.chunk.css +2 -0
  30. package/build/static/css/5633.97c23e40.chunk.css.map +1 -0
  31. package/build/static/css/5674.c88fd2db.chunk.css +2 -0
  32. package/build/static/css/5674.c88fd2db.chunk.css.map +1 -0
  33. package/build/static/css/653.f1a8c344.chunk.css +2 -0
  34. package/build/static/css/653.f1a8c344.chunk.css.map +1 -0
  35. package/build/static/css/{6763.5cb27d52.chunk.css → 6763.0df869ff.chunk.css} +2 -2
  36. package/build/static/css/{6763.5cb27d52.chunk.css.map → 6763.0df869ff.chunk.css.map} +1 -1
  37. package/build/static/css/7227.d9d1299c.chunk.css +2 -0
  38. package/build/static/css/{7227.65ee4c4e.chunk.css.map → 7227.d9d1299c.chunk.css.map} +1 -1
  39. package/build/static/css/7589.f3c8f89b.chunk.css +2 -0
  40. package/build/static/css/7589.f3c8f89b.chunk.css.map +1 -0
  41. package/build/static/css/{760.9d94b7ab.chunk.css → 760.f8be7f84.chunk.css} +2 -2
  42. package/build/static/css/{760.9d94b7ab.chunk.css.map → 760.f8be7f84.chunk.css.map} +1 -1
  43. package/build/static/css/7857.484072c1.chunk.css +2 -0
  44. package/build/static/css/{7857.ec76e428.chunk.css.map → 7857.484072c1.chunk.css.map} +1 -1
  45. package/build/static/css/7987.97c23e40.chunk.css +2 -0
  46. package/build/static/css/7987.97c23e40.chunk.css.map +1 -0
  47. package/build/static/css/833.e28708c8.chunk.css +2 -0
  48. package/build/static/css/{833.deb93503.chunk.css.map → 833.e28708c8.chunk.css.map} +1 -1
  49. package/build/static/css/{8593.4a9031dc.chunk.css → 8593.7ef21cba.chunk.css} +2 -2
  50. package/build/static/css/{8593.4a9031dc.chunk.css.map → 8593.7ef21cba.chunk.css.map} +1 -1
  51. package/build/static/css/8689.906ec3c8.chunk.css +12 -0
  52. package/build/static/css/8689.906ec3c8.chunk.css.map +1 -0
  53. package/build/static/css/9556.3c875a41.chunk.css +2 -0
  54. package/build/static/css/{9556.78fa406b.chunk.css.map → 9556.3c875a41.chunk.css.map} +1 -1
  55. package/build/static/js/{1381.3a1fb929.chunk.js → 1381.37b05f38.chunk.js} +1 -1
  56. package/build/static/js/1742.59b24864.chunk.js +2 -0
  57. package/build/static/js/1742.59b24864.chunk.js.map +1 -0
  58. package/build/static/js/{1996.758be72d.chunk.js → 1996.14344c2d.chunk.js} +2 -2
  59. package/build/static/js/{1996.758be72d.chunk.js.map → 1996.14344c2d.chunk.js.map} +1 -1
  60. package/build/static/js/{2004.74384107.chunk.js → 2004.d8122da2.chunk.js} +3 -3
  61. package/build/static/js/{2004.74384107.chunk.js.map → 2004.d8122da2.chunk.js.map} +1 -1
  62. package/build/static/js/2086.c3a0124d.chunk.js +3 -0
  63. package/build/static/js/2086.c3a0124d.chunk.js.map +1 -0
  64. package/build/static/js/{2242.a0059cca.chunk.js → 2242.a55a6844.chunk.js} +2 -2
  65. package/build/static/js/2242.a55a6844.chunk.js.map +1 -0
  66. package/build/static/js/254.e7805354.chunk.js +2 -0
  67. package/build/static/js/254.e7805354.chunk.js.map +1 -0
  68. package/build/static/js/{2723.a5f0a1fa.chunk.js → 2723.38314d6e.chunk.js} +1 -1
  69. package/build/static/js/{3404.b93a548c.chunk.js → 3404.1557958c.chunk.js} +3 -3
  70. package/build/static/js/{3404.b93a548c.chunk.js.map → 3404.1557958c.chunk.js.map} +1 -1
  71. package/build/static/js/{3625.db151aab.chunk.js → 3625.23761746.chunk.js} +2 -2
  72. package/build/static/js/{3625.db151aab.chunk.js.map → 3625.23761746.chunk.js.map} +1 -1
  73. package/build/static/js/{3771.d4bd749c.chunk.js → 3771.997ccc57.chunk.js} +2 -2
  74. package/build/static/js/{3771.d4bd749c.chunk.js.map → 3771.997ccc57.chunk.js.map} +1 -1
  75. package/build/static/js/{3790.6af26115.chunk.js → 3790.805593bc.chunk.js} +2 -2
  76. package/build/static/js/{3790.6af26115.chunk.js.map → 3790.805593bc.chunk.js.map} +1 -1
  77. package/build/static/js/{3856.23c16ed0.chunk.js → 3856.bfc95e79.chunk.js} +2 -2
  78. package/build/static/js/{3856.23c16ed0.chunk.js.map → 3856.bfc95e79.chunk.js.map} +1 -1
  79. package/build/static/js/{4189.473f9ca6.chunk.js → 4189.4161d40a.chunk.js} +3 -3
  80. package/build/static/js/4189.4161d40a.chunk.js.map +1 -0
  81. package/build/static/js/4297.71ba78e9.chunk.js +2 -0
  82. package/build/static/js/4297.71ba78e9.chunk.js.map +1 -0
  83. package/build/static/js/4474.bf030f69.chunk.js +2 -0
  84. package/build/static/js/4474.bf030f69.chunk.js.map +1 -0
  85. package/build/static/js/5195.605db17c.chunk.js +2 -0
  86. package/build/static/js/5195.605db17c.chunk.js.map +1 -0
  87. package/build/static/js/{5633.d81b4db2.chunk.js → 5633.10b44bd7.chunk.js} +1 -1
  88. package/build/static/js/{5674.8d9c60e9.chunk.js → 5674.86bb2ec6.chunk.js} +2 -2
  89. package/build/static/js/{5674.8d9c60e9.chunk.js.map → 5674.86bb2ec6.chunk.js.map} +1 -1
  90. package/build/static/js/5958.89468fa5.chunk.js +2 -0
  91. package/build/static/js/5958.89468fa5.chunk.js.map +1 -0
  92. package/build/static/js/{6763.77f6d956.chunk.js → 6763.f0ced4ef.chunk.js} +2 -2
  93. package/build/static/js/{6763.77f6d956.chunk.js.map → 6763.f0ced4ef.chunk.js.map} +1 -1
  94. package/build/static/js/{7040.fb2de04f.chunk.js → 7040.85ca80c3.chunk.js} +2 -2
  95. package/build/static/js/{7040.fb2de04f.chunk.js.map → 7040.85ca80c3.chunk.js.map} +1 -1
  96. package/build/static/js/{7227.3a5d8032.chunk.js → 7227.7bdd14a5.chunk.js} +3 -3
  97. package/build/static/js/{7227.3a5d8032.chunk.js.map → 7227.7bdd14a5.chunk.js.map} +1 -1
  98. package/build/static/js/{7589.03d16dce.chunk.js → 7589.19464c85.chunk.js} +2 -2
  99. package/build/static/js/{7589.03d16dce.chunk.js.map → 7589.19464c85.chunk.js.map} +1 -1
  100. package/build/static/js/{760.7adc7293.chunk.js → 760.93414278.chunk.js} +2 -2
  101. package/build/static/js/{760.7adc7293.chunk.js.map → 760.93414278.chunk.js.map} +1 -1
  102. package/build/static/js/7857.b3aee7e8.chunk.js +2 -0
  103. package/build/static/js/7857.b3aee7e8.chunk.js.map +1 -0
  104. package/build/static/js/7899.92317382.chunk.js +2 -0
  105. package/build/static/js/7899.92317382.chunk.js.map +1 -0
  106. package/build/static/js/833.61f11966.chunk.js +2 -0
  107. package/build/static/js/833.61f11966.chunk.js.map +1 -0
  108. package/build/static/js/{8593.92a539df.chunk.js → 8593.d3cad462.chunk.js} +2 -2
  109. package/build/static/js/{8593.92a539df.chunk.js.map → 8593.d3cad462.chunk.js.map} +1 -1
  110. package/build/static/js/{9556.46180fc4.chunk.js → 9556.1ce5861f.chunk.js} +3 -3
  111. package/build/static/js/{9556.46180fc4.chunk.js.map → 9556.1ce5861f.chunk.js.map} +1 -1
  112. package/build/static/js/main.26785b52.js +2 -0
  113. package/build/static/js/{main.3f3ac682.js.map → main.26785b52.js.map} +1 -1
  114. package/package.json +3 -3
  115. package/build/static/css/1381.ae89d4cb.chunk.css +0 -2
  116. package/build/static/css/1381.ae89d4cb.chunk.css.map +0 -1
  117. package/build/static/css/1742.12f27291.chunk.css +0 -2
  118. package/build/static/css/2004.33c1e186.chunk.css +0 -2
  119. package/build/static/css/2307.0ec76807.chunk.css +0 -2
  120. package/build/static/css/2307.0ec76807.chunk.css.map +0 -1
  121. package/build/static/css/254.b513f3ff.chunk.css +0 -2
  122. package/build/static/css/254.b513f3ff.chunk.css.map +0 -1
  123. package/build/static/css/3404.6f0b882e.chunk.css +0 -2
  124. package/build/static/css/3625.d84a60b5.chunk.css +0 -2
  125. package/build/static/css/3625.d84a60b5.chunk.css.map +0 -1
  126. package/build/static/css/5195.b239bddb.chunk.css +0 -2
  127. package/build/static/css/5195.b239bddb.chunk.css.map +0 -1
  128. package/build/static/css/5582.877dc4db.chunk.css.map +0 -1
  129. package/build/static/css/5633.ae89d4cb.chunk.css +0 -2
  130. package/build/static/css/5633.ae89d4cb.chunk.css.map +0 -1
  131. package/build/static/css/5674.49c3a29d.chunk.css +0 -2
  132. package/build/static/css/5674.49c3a29d.chunk.css.map +0 -1
  133. package/build/static/css/653.e0c03500.chunk.css +0 -2
  134. package/build/static/css/653.e0c03500.chunk.css.map +0 -1
  135. package/build/static/css/7227.65ee4c4e.chunk.css +0 -2
  136. package/build/static/css/7589.e72d7a14.chunk.css +0 -2
  137. package/build/static/css/7589.e72d7a14.chunk.css.map +0 -1
  138. package/build/static/css/7857.ec76e428.chunk.css +0 -2
  139. package/build/static/css/7987.ae89d4cb.chunk.css +0 -2
  140. package/build/static/css/7987.ae89d4cb.chunk.css.map +0 -1
  141. package/build/static/css/833.deb93503.chunk.css +0 -2
  142. package/build/static/css/8689.67d74ad5.chunk.css +0 -12
  143. package/build/static/css/8689.67d74ad5.chunk.css.map +0 -1
  144. package/build/static/css/9556.78fa406b.chunk.css +0 -2
  145. package/build/static/js/1742.190ff95f.chunk.js +0 -2
  146. package/build/static/js/1742.190ff95f.chunk.js.map +0 -1
  147. package/build/static/js/2086.04de3393.chunk.js +0 -3
  148. package/build/static/js/2086.04de3393.chunk.js.map +0 -1
  149. package/build/static/js/2242.a0059cca.chunk.js.map +0 -1
  150. package/build/static/js/254.54f5f58b.chunk.js +0 -2
  151. package/build/static/js/254.54f5f58b.chunk.js.map +0 -1
  152. package/build/static/js/4189.473f9ca6.chunk.js.map +0 -1
  153. package/build/static/js/4297.cb02aafc.chunk.js +0 -2
  154. package/build/static/js/4297.cb02aafc.chunk.js.map +0 -1
  155. package/build/static/js/4474.1059ef67.chunk.js +0 -2
  156. package/build/static/js/4474.1059ef67.chunk.js.map +0 -1
  157. package/build/static/js/5195.d3ea6ecc.chunk.js +0 -2
  158. package/build/static/js/5195.d3ea6ecc.chunk.js.map +0 -1
  159. package/build/static/js/5958.25a2c01c.chunk.js +0 -2
  160. package/build/static/js/5958.25a2c01c.chunk.js.map +0 -1
  161. package/build/static/js/7857.3ddc9e5b.chunk.js +0 -2
  162. package/build/static/js/7857.3ddc9e5b.chunk.js.map +0 -1
  163. package/build/static/js/7899.633b8c99.chunk.js +0 -2
  164. package/build/static/js/7899.633b8c99.chunk.js.map +0 -1
  165. package/build/static/js/833.816bfa8f.chunk.js +0 -2
  166. package/build/static/js/833.816bfa8f.chunk.js.map +0 -1
  167. package/build/static/js/main.3f3ac682.js +0 -2
  168. /package/build/static/js/{2004.74384107.chunk.js.LICENSE.txt → 2004.d8122da2.chunk.js.LICENSE.txt} +0 -0
  169. /package/build/static/js/{2086.04de3393.chunk.js.LICENSE.txt → 2086.c3a0124d.chunk.js.LICENSE.txt} +0 -0
  170. /package/build/static/js/{3404.b93a548c.chunk.js.LICENSE.txt → 3404.1557958c.chunk.js.LICENSE.txt} +0 -0
  171. /package/build/static/js/{4189.473f9ca6.chunk.js.LICENSE.txt → 4189.4161d40a.chunk.js.LICENSE.txt} +0 -0
  172. /package/build/static/js/{7227.3a5d8032.chunk.js.LICENSE.txt → 7227.7bdd14a5.chunk.js.LICENSE.txt} +0 -0
  173. /package/build/static/js/{9556.46180fc4.chunk.js.LICENSE.txt → 9556.1ce5861f.chunk.js.LICENSE.txt} +0 -0
@@ -1,2 +1,2 @@
1
- "use strict";(self.webpackChunk_kne_components_components_core=self.webpackChunk_kne_components_components_core||[]).push([[2908,3771],{3382(e,o,t){t.r(o),t.d(o,{ModalButton:()=>H,TabsModal:()=>O,TabsModalButton:()=>K,default:()=>P,useConfirmModal:()=>S,useModal:()=>T,useTabsModal:()=>D});var n=t(89379),l=t(53986),s=t(73884),i=t(55199),r=t(83136),a=t.n(r);const c={modal:"style_modal__Pm3cF__-0IeQ",large:"style_large__iaqVE__-0IeQ","modal-body-inner":"style_modal-body-inner__4PhpA__-0IeQ","modal-title":"style_modal-title__dswaw__-0IeQ","modal-outer":"style_modal-outer__r3SkX__-0IeQ","modal-body":"style_modal-body__jQJSI__-0IeQ","right-options-modal":"style_right-options-modal__FajDP__-0IeQ","right-options-row":"style_right-options-row__-mPb9__-0IeQ","right-options-col":"style_right-options-col__3ilee__-0IeQ","is-disabled-scroller":"style_is-disabled-scroller__PmHyk__-0IeQ",content:"style_content__k6MIF__-0IeQ","modal-footer":"style_modal-footer__-prbN__-0IeQ","modal-close":"style_modal-close__Oa5Kl__-0IeQ","confirm-modal-wrap":"style_confirm-modal-wrap__YFImr__-0IeQ","is-danger":"style_is-danger__H5110__-0IeQ",title:"style_title__orTym__-0IeQ","has-title":"style_has-title__qy0Wp__-0IeQ"},d=e=>({"en-US":()=>t.e(4628).then(t.bind(t,74628)),"zh-CN":()=>t.e(7478).then(t.bind(t,87478))}[e]());var m=t(47458),h=t(64671);const p=(e,o)=>"function"===typeof e?e(o):e;var f=t(81014),u=t(17342),_=t(70579);const g=["ButtonComponent","onClick","autoClose","display"],y=["children","rightOptions","rightSpan","footer","footerButtons","className","size","title","onClose","onConfirm","confirmText","onCancel","cancelText","closable","disabledScroller","withDecorator","childrenRef"],C=["size"],x=["children"],A=["type","icon","title","danger","wrapClassName","message","iconSetting","confirmType"],b="Modal",j=e=>{let{options:o,rightSpan:t=6,children:n}=e;return o?(0,_.jsxs)(i.Row,{wrap:!1,className:c["right-options-row"],children:[(0,_.jsx)(i.Col,{span:24-t,className:c["right-options-col"],children:n}),(0,_.jsx)(i.Col,{span:t,className:c["right-options-col"],children:o})]}):n},w=(e,o)=>"".concat(e-48-(o?58:0),"px"),N=e=>{let{footer:o,footerButtons:t,onConfirm:r,onCancel:a,cancelText:c,onClose:h,targetProps:p}=e;return(0,_.jsxs)(i.Row,{gutter:10,wrap:!1,children:[(0,_.jsx)(i.Col,{flex:1,children:o}),Array.isArray(t)&&0===t.length?null:(0,_.jsx)(i.Col,{children:(0,_.jsx)(i.Space,{children:(t||[{children:c||(0,_.jsx)(m.IntlProvider,{importMessages:d,moduleName:b,children:(0,_.jsx)(m.FormattedMessage,{id:"Cancel",moduleName:b})}),onClick:a},{type:"primary",children:(0,_.jsx)(m.IntlProvider,{importMessages:d,moduleName:b,children:(0,_.jsx)(m.FormattedMessage,{id:"Confirm",moduleName:b})}),onClick:r}]).filter(e=>"function"===typeof(null===e||void 0===e?void 0:e.display)?null===e||void 0===e?void 0:e.display():!1!==(null===e||void 0===e?void 0:e.display)).map((e,o)=>{let{ButtonComponent:t,onClick:i,autoClose:r=!0,display:a}=e,c=(0,l.A)(e,g);const d=t||f.default;return(0,s.createElement)(d,(0,n.A)((0,n.A)({},c),{},{key:o,onClick:async function(){for(var e=arguments.length,o=new Array(e),t=0;t<e;t++)o[t]=arguments[t];const n=await Promise.resolve(i&&i(...o,p));return r&&!1!==n&&h&&h(),n}}))})})})]})},v=e=>{let{title:o,footer:t,disabledScroller:n,footerButtons:l,onClose:r,closable:d,onConfirm:m,onCancel:p,children:f,targetProps:g,cancelText:y,confirmText:C}=e;const x=(0,s.useRef)(null);return(0,_.jsxs)("div",{className:a()(c["modal-outer"],"modal-container"),"data-testid":"components-core-modal",children:[!1===d?null:(0,_.jsx)(i.Button,{"data-testid":"components-core-modal-close-btn",className:a()(c["modal-close"],"modal-close"),type:"text",icon:(0,_.jsx)(h.default,{type:"icon-close-thin"}),onClick:e=>{e.stopPropagation(),r&&r()}}),o&&(0,_.jsx)("div",{className:c["modal-title"],children:o}),(0,_.jsx)(u.A,{className:a()(c["modal-body"],{[c["is-disabled-scroller"]]:n},"modal-body"),ref:x,children:(0,_.jsx)("div",{className:a()(c["modal-body-inner"],"modal-body-inner"),children:f})}),null!==t||l?(0,_.jsx)("div",{className:a()(c["modal-footer"],"modal-footer"),children:(0,_.jsx)(N,{footer:t,footerButtons:l,onConfirm:m,confirmText:C,onCancel:p,cancelText:y,onClose:r,targetProps:g})}):null]})},I=e=>{let{withDecorator:o,footerButtons:t,title:l,closable:s,onClose:i,onConfirm:r,confirmText:a,onCancel:c,cancelText:d,footer:m,rightOptions:h,rightSpan:f,disabledScroller:u,childrenRef:g,children:y}=e;const C=e=>(e=Object.assign({},{title:l},e),(0,_.jsx)(v,{title:p(e.title,(0,n.A)((0,n.A)({},e),{},{childrenRef:g,close:i})),closable:s,onClose:i,onConfirm:r,confirmText:a,onCancel:c,cancelText:d,footerButtons:p(t,(0,n.A)((0,n.A)({},e),{},{close:i})),disabledScroller:u,footer:p(m,(0,n.A)((0,n.A)({},e),{},{childrenRef:g,close:i})),targetProps:Object.assign({},e,{childrenRef:g,close:i}),children:(0,_.jsx)(j,{rightSpan:f,options:p(h,(0,n.A)((0,n.A)({},e),{},{childrenRef:g,close:i})),children:p(y,(0,n.A)((0,n.A)({},e),{},{childrenRef:g,close:i}))})}));return"function"===typeof o?o(C,{childrenRef:g,close:i}):C({})},k=e=>{let{children:o,rightOptions:t,rightSpan:s,footer:i,footerButtons:r,className:h,size:p,title:f,onClose:u,onConfirm:g,confirmText:C,onCancel:x,cancelText:A,closable:b,disabledScroller:j,withDecorator:N,childrenRef:v}=e,k=(0,l.A)(e,y);return(0,n.A)((0,n.A)((0,n.A)({},k),{},{icon:null,centered:!0,title:null,maskClosable:!!k.hasOwnProperty("maskClosable")&&k.maskClosable,destroyOnHidden:!0,footer:null,closable:!1,onCancel:u,className:a()(h,c.modal,c[p],{[c["right-options-modal"]]:t})},((e,o)=>"large"===e?{width:"".concat(Math.min(window.innerWidth-64,1500),"px"),style:{"--min-modal-height":w(500,o)}}:"small"===e?{width:"600px",style:{"--min-modal-height":w(300,o)}}:{width:"1000px",style:{"--min-modal-height":w(500,o)}})(p,!(null===i&&!r))),{},{children:(0,_.jsx)(m.IntlProvider,{importMessages:d,moduleName:"Modal",children:I({withDecorator:N,title:f,closable:b,onClose:u,onConfirm:g,confirmText:C,onCancel:x,cancelText:A,footer:i,footerButtons:r,rightOptions:t,rightSpan:s,disabledScroller:j,children:o,childrenRef:v})})})},T=()=>{const{modal:e}=i.App.useApp(),o=(0,s.useRef)(null);return t=>{const s={},i=k((0,n.A)({onClose:()=>s.close(),childrenRef:o},t)),{children:r}=i,a=(0,l.A)(i,x),{destroy:c}=e.info((0,n.A)((0,n.A)({},a),{},{content:r}));return s.close=c,s}},S=()=>{const{modal:e}=i.App.useApp();return o=>{const t={},s=(0,n.A)({onClose:()=>t.close(),maskClosable:!1},o),{type:r,icon:d,title:m,danger:p,wrapClassName:f,message:u,iconSetting:g={},confirmType:y="info"}=s,C=(0,l.A)(s,A),x=Object.assign({},{info:"icon-xinxi-tianchong",confirm:"icon-tishi-tianchong",warning:"icon-tishi-tianchong",error:"icon-shibai",success:"icon-chenggong"},g);if(e[r]){const{destroy:o}=e[r]((0,n.A)((0,n.A)({},C),{},{icon:null,wrapClassName:a()(c["confirm-modal-wrap"],f,{[c["is-danger"]]:p}),title:(0,_.jsx)(i.Space,{orientation:"vertical",onClick:e=>{e.stopPropagation()},children:m&&(0,_.jsxs)(i.Space,{size:0,align:"start",className:c.title,children:[p?(0,_.jsx)(h.default,{className:a()("title-icon","title-icon-".concat("confirm"===r?y:r)),type:d||x["confirm"===r?y:r]}):null,m]})}),content:(0,_.jsxs)(i.Space,{size:0,align:"start",className:a()(c.content,{[c["has-title"]]:m}),children:[!m&&p?(0,_.jsx)(h.default,{className:a()("title-icon","title-icon-".concat("confirm"===r?y:r)),type:d||x["confirm"===r?y:r]}):null,u]})}));t.close=o}return t}},P=e=>{let{size:o="default"}=e,t=(0,l.A)(e,C);const r=(0,s.useRef)(null);return(0,_.jsx)(i.Modal,(0,n.A)({},k(Object.assign({},t,{size:o,childrenRef:r}))))},Q=["items","className","activeKey","withDecorator","defaultActiveKey","onChange"],R=["withDecorator"],M=["children"],B=e=>{let{items:o,className:t,activeKey:s,withDecorator:r,defaultActiveKey:c,onChange:d}=e,m=(0,l.A)(e,Q);return(0,n.A)((0,n.A)({},m),{},{className:a()(t,"tabs-modal"),withDecorator:e=>{const t=t=>(0,_.jsx)(i.Tabs,{items:o.map(o=>{let{withDecorator:n}=o,s=(0,l.A)(o,R);return Object.assign({},s,{children:"function"===typeof n?n(o=>e(Object.assign({},t,o,{children:s.children}))):e(Object.assign({},t,{children:s.children}))})}),destroyInactiveTabPane:!0,activeKey:s,defaultActiveKey:c,onChange:d});return"function"===typeof r?r(t):t()},children:e=>{let{children:o}=e,t=(0,l.A)(e,M);return"function"===typeof o?o(t):o}})},O=e=>(0,_.jsx)(P,(0,n.A)({},B(e))),D=()=>{const e=T();return o=>e(B(o))};var z=t(73025);const F=["modalProps"],K=e=>{const o=D();return e.api?(0,_.jsx)(z.A,(0,n.A)((0,n.A)({},e),{},{modalFunc:o})):(0,_.jsx)(i.Button,(0,n.A)((0,n.A)({},e),{},{onClick:()=>{o(e.modalProps)}}))},H=e=>{const o=T();if(!e.api){const{modalProps:t}=e,s=(0,l.A)(e,F);return(0,_.jsx)(i.Button,(0,n.A)((0,n.A)({},s),{},{onClick:()=>{o(t)}}))}return(0,_.jsx)(z.A,(0,n.A)((0,n.A)({},e),{},{modalFunc:o}))}},17342(e,o,t){t.d(o,{A:()=>s});var n=t(34581),l=t.n(n);t(46733);const s=l()},46733(){}}]);
2
- //# sourceMappingURL=3771.d4bd749c.chunk.js.map
1
+ "use strict";(self.webpackChunk_kne_components_components_core=self.webpackChunk_kne_components_components_core||[]).push([[2908,3771],{3382(e,o,t){t.r(o),t.d(o,{ModalButton:()=>F,TabsModal:()=>M,TabsModalButton:()=>z,default:()=>P,useConfirmModal:()=>H,useModal:()=>S,useTabsModal:()=>B});var n=t(89379),l=t(53986),s=t(73884),i=t(55199),r=t(83136),a=t.n(r);const c={modal:"style_modal__Pm3cF__HJ3UV",large:"style_large__iaqVE__HJ3UV","modal-body-inner":"style_modal-body-inner__4PhpA__HJ3UV","modal-title":"style_modal-title__dswaw__HJ3UV","modal-outer":"style_modal-outer__r3SkX__HJ3UV","modal-body":"style_modal-body__jQJSI__HJ3UV","right-options-modal":"style_right-options-modal__FajDP__HJ3UV","right-options-row":"style_right-options-row__-mPb9__HJ3UV","right-options-col":"style_right-options-col__3ilee__HJ3UV","is-disabled-scroller":"style_is-disabled-scroller__PmHyk__HJ3UV",content:"style_content__k6MIF__HJ3UV","modal-footer":"style_modal-footer__-prbN__HJ3UV","modal-close":"style_modal-close__Oa5Kl__HJ3UV","confirm-modal-wrap":"style_confirm-modal-wrap__YFImr__HJ3UV","is-danger":"style_is-danger__H5110__HJ3UV",title:"style_title__orTym__HJ3UV","has-title":"style_has-title__qy0Wp__HJ3UV"},d=e=>({"en-US":()=>t.e(4628).then(t.bind(t,74628)),"zh-CN":()=>t.e(7478).then(t.bind(t,87478))}[e]());var m=t(47458),h=t(64671);const p=(e,o)=>"function"===typeof e?e(o):e;var f=t(81014),u=t(17342),_=t(70579);const g=["ButtonComponent","onClick","autoClose","display"],y=["children","rightOptions","rightSpan","footer","footerButtons","className","size","title","onClose","onConfirm","confirmText","onCancel","cancelText","closable","disabledScroller","withDecorator","childrenRef"],C=["size"],x=["children"],A=["type","icon","title","danger","wrapClassName","message","iconSetting","confirmType"],b="Modal",j=e=>{let{options:o,rightSpan:t=6,children:n}=e;return o?(0,_.jsxs)(i.Row,{wrap:!1,className:c["right-options-row"],children:[(0,_.jsx)(i.Col,{span:24-t,className:c["right-options-col"],children:n}),(0,_.jsx)(i.Col,{span:t,className:c["right-options-col"],children:o})]}):n},w=(e,o)=>"".concat(e-48-(o?58:0),"px"),N=e=>{let{footer:o,footerButtons:t,onConfirm:r,onCancel:a,cancelText:c,onClose:h,targetProps:p}=e;return(0,_.jsxs)(i.Row,{gutter:10,wrap:!1,children:[(0,_.jsx)(i.Col,{flex:1,children:o}),Array.isArray(t)&&0===t.length?null:(0,_.jsx)(i.Col,{children:(0,_.jsx)(i.Space,{children:(t||[{children:c||(0,_.jsx)(m.IntlProvider,{importMessages:d,moduleName:b,children:(0,_.jsx)(m.FormattedMessage,{id:"Cancel",moduleName:b})}),onClick:a},{type:"primary",children:(0,_.jsx)(m.IntlProvider,{importMessages:d,moduleName:b,children:(0,_.jsx)(m.FormattedMessage,{id:"Confirm",moduleName:b})}),onClick:r}]).filter(e=>"function"===typeof(null===e||void 0===e?void 0:e.display)?null===e||void 0===e?void 0:e.display():!1!==(null===e||void 0===e?void 0:e.display)).map((e,o)=>{let{ButtonComponent:t,onClick:i,autoClose:r=!0,display:a}=e,c=(0,l.A)(e,g);const d=t||f.default;return(0,s.createElement)(d,(0,n.A)((0,n.A)({},c),{},{key:o,onClick:async function(){for(var e=arguments.length,o=new Array(e),t=0;t<e;t++)o[t]=arguments[t];const n=await Promise.resolve(i&&i(...o,p));return r&&!1!==n&&h&&h(),n}}))})})})]})},v=e=>{let{title:o,footer:t,disabledScroller:n,footerButtons:l,onClose:r,closable:d,onConfirm:m,onCancel:p,children:f,targetProps:g,cancelText:y,confirmText:C}=e;const x=(0,s.useRef)(null);return(0,_.jsxs)("div",{className:a()(c["modal-outer"],"modal-container"),"data-testid":"components-core-modal",children:[!1===d?null:(0,_.jsx)(i.Button,{"data-testid":"components-core-modal-close-btn",className:a()(c["modal-close"],"modal-close"),type:"text",icon:(0,_.jsx)(h.default,{type:"icon-close-thin"}),onClick:e=>{e.stopPropagation(),r&&r()}}),o&&(0,_.jsx)("div",{className:c["modal-title"],children:o}),(0,_.jsx)(u.A,{className:a()(c["modal-body"],{[c["is-disabled-scroller"]]:n},"modal-body"),ref:x,children:(0,_.jsx)("div",{className:a()(c["modal-body-inner"],"modal-body-inner"),children:f})}),null!==t||l?(0,_.jsx)("div",{className:a()(c["modal-footer"],"modal-footer"),children:(0,_.jsx)(N,{footer:t,footerButtons:l,onConfirm:m,confirmText:C,onCancel:p,cancelText:y,onClose:r,targetProps:g})}):null]})},k=e=>{let{withDecorator:o,footerButtons:t,title:l,closable:s,onClose:i,onConfirm:r,confirmText:a,onCancel:c,cancelText:d,footer:m,rightOptions:h,rightSpan:f,disabledScroller:u,childrenRef:g,children:y}=e;const C=e=>(e=Object.assign({},{title:l},e),(0,_.jsx)(v,{title:p(e.title,(0,n.A)((0,n.A)({},e),{},{childrenRef:g,close:i})),closable:s,onClose:i,onConfirm:r,confirmText:a,onCancel:c,cancelText:d,footerButtons:p(t,(0,n.A)((0,n.A)({},e),{},{close:i})),disabledScroller:u,footer:p(m,(0,n.A)((0,n.A)({},e),{},{childrenRef:g,close:i})),targetProps:Object.assign({},e,{childrenRef:g,close:i}),children:(0,_.jsx)(j,{rightSpan:f,options:p(h,(0,n.A)((0,n.A)({},e),{},{childrenRef:g,close:i})),children:p(y,(0,n.A)((0,n.A)({},e),{},{childrenRef:g,close:i}))})}));return"function"===typeof o?o(C,{childrenRef:g,close:i}):C({})},T=e=>{let{children:o,rightOptions:t,rightSpan:s,footer:i,footerButtons:r,className:h,size:p,title:f,onClose:u,onConfirm:g,confirmText:C,onCancel:x,cancelText:A,closable:b,disabledScroller:j,withDecorator:N,childrenRef:v}=e,T=(0,l.A)(e,y);return(0,n.A)((0,n.A)((0,n.A)({},T),{},{icon:null,centered:!0,title:null,maskClosable:!!T.hasOwnProperty("maskClosable")&&T.maskClosable,destroyOnHidden:!0,footer:null,closable:!1,onCancel:u,className:a()(h,c.modal,c[p],{[c["right-options-modal"]]:t})},((e,o)=>"large"===e?{width:"".concat(Math.min(window.innerWidth-64,1500),"px"),style:{"--min-modal-height":w(500,o)}}:"small"===e?{width:"600px",style:{"--min-modal-height":w(300,o)}}:{width:"1000px",style:{"--min-modal-height":w(500,o)}})(p,!(null===i&&!r))),{},{children:(0,_.jsx)(m.IntlProvider,{importMessages:d,moduleName:"Modal",children:k({withDecorator:N,title:f,closable:b,onClose:u,onConfirm:g,confirmText:C,onCancel:x,cancelText:A,footer:i,footerButtons:r,rightOptions:t,rightSpan:s,disabledScroller:j,children:o,childrenRef:v})})})},S=()=>{const{modal:e}=i.App.useApp(),o=(0,s.useRef)(null);return t=>{const s={},i=T((0,n.A)({onClose:()=>s.close(),childrenRef:o},t)),{children:r}=i,a=(0,l.A)(i,x),{destroy:c}=e.info((0,n.A)((0,n.A)({},a),{},{content:r}));return s.close=c,s}},H=()=>{const{modal:e}=i.App.useApp();return o=>{const t={},s=(0,n.A)({onClose:()=>t.close(),maskClosable:!1},o),{type:r,icon:d,title:m,danger:p,wrapClassName:f,message:u,iconSetting:g={},confirmType:y="info"}=s,C=(0,l.A)(s,A),x=Object.assign({},{info:"icon-xinxi-tianchong",confirm:"icon-tishi-tianchong",warning:"icon-tishi-tianchong",error:"icon-shibai",success:"icon-chenggong"},g);if(e[r]){const{destroy:o}=e[r]((0,n.A)((0,n.A)({},C),{},{icon:null,wrapClassName:a()(c["confirm-modal-wrap"],f,{[c["is-danger"]]:p}),title:(0,_.jsx)(i.Space,{orientation:"vertical",onClick:e=>{e.stopPropagation()},children:m&&(0,_.jsxs)(i.Space,{size:0,align:"start",className:c.title,children:[p?(0,_.jsx)(h.default,{className:a()("title-icon","title-icon-".concat("confirm"===r?y:r)),type:d||x["confirm"===r?y:r]}):null,m]})}),content:(0,_.jsxs)(i.Space,{size:0,align:"start",className:a()(c.content,{[c["has-title"]]:m}),children:[!m&&p?(0,_.jsx)(h.default,{className:a()("title-icon","title-icon-".concat("confirm"===r?y:r)),type:d||x["confirm"===r?y:r]}):null,u]})}));t.close=o}return t}},P=e=>{let{size:o="default"}=e,t=(0,l.A)(e,C);const r=(0,s.useRef)(null);return(0,_.jsx)(i.Modal,(0,n.A)({},T(Object.assign({},t,{size:o,childrenRef:r}))))},J=["items","className","activeKey","withDecorator","defaultActiveKey","onChange"],U=["withDecorator"],V=["children"],R=e=>{let{items:o,className:t,activeKey:s,withDecorator:r,defaultActiveKey:c,onChange:d}=e,m=(0,l.A)(e,J);return(0,n.A)((0,n.A)({},m),{},{className:a()(t,"tabs-modal"),withDecorator:e=>{const t=t=>(0,_.jsx)(i.Tabs,{items:o.map(o=>{let{withDecorator:n}=o,s=(0,l.A)(o,U);return Object.assign({},s,{children:"function"===typeof n?n(o=>e(Object.assign({},t,o,{children:s.children}))):e(Object.assign({},t,{children:s.children}))})}),destroyInactiveTabPane:!0,activeKey:s,defaultActiveKey:c,onChange:d});return"function"===typeof r?r(t):t()},children:e=>{let{children:o}=e,t=(0,l.A)(e,V);return"function"===typeof o?o(t):o}})},M=e=>(0,_.jsx)(P,(0,n.A)({},R(e))),B=()=>{const e=S();return o=>e(R(o))};var O=t(73025);const D=["modalProps"],z=e=>{const o=B();return e.api?(0,_.jsx)(O.A,(0,n.A)((0,n.A)({},e),{},{modalFunc:o})):(0,_.jsx)(i.Button,(0,n.A)((0,n.A)({},e),{},{onClick:()=>{o(e.modalProps)}}))},F=e=>{const o=S();if(!e.api){const{modalProps:t}=e,s=(0,l.A)(e,D);return(0,_.jsx)(i.Button,(0,n.A)((0,n.A)({},s),{},{onClick:()=>{o(t)}}))}return(0,_.jsx)(O.A,(0,n.A)((0,n.A)({},e),{},{modalFunc:o}))}},17342(e,o,t){t.d(o,{A:()=>s});var n=t(34581),l=t.n(n);t(46733);const s=l()},46733(){}}]);
2
+ //# sourceMappingURL=3771.997ccc57.chunk.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"static/js/3771.d4bd749c.chunk.js","mappings":"sWACA,SAAgB,MAAQ,4BAA4B,MAAQ,4BAA4B,mBAAmB,uCAAuC,cAAc,kCAAkC,cAAc,kCAAkC,aAAa,iCAAiC,sBAAsB,0CAA0C,oBAAoB,wCAAwC,oBAAoB,wCAAwC,uBAAuB,2CAA2C,QAAU,8BAA8B,eAAe,mCAAmC,cAAc,kCAAkC,qBAAqB,yCAAyC,YAAY,gCAAgC,MAAQ,4BAA4B,YAAY,iCCK9zB,EANwBA,IACZ,CACJ,QAASC,IAAM,gCAAmB,QAASC,IAAM,iCAClDF,M,0BCHP,MAOA,EAP0BG,CAACC,EAAQC,IACX,oBAAXD,EACFA,EAAOC,GAETD,E,0aCOHE,EAAmB,QAEZC,EAAeC,IAAyC,IAAxC,QAACH,EAAO,UAAEI,EAAY,EAAC,SAAEC,GAASF,EAC3D,OAAKH,GAGGM,EAAAA,EAAAA,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E,EAJmByC,IACVnC,EAAAA,EAAAA,KAACiI,GAAKxF,EAAAA,EAAAA,GAAA,GAAKmC,EAAoBzC,KAK3B+F,EAAeA,KAC1B,MAAMvC,EAAQD,IACd,OAAQvD,GAAUwD,EAAMf,EAAoBzC,K,sCCtCjCgG,EAAmBhG,IAC9B,MAAMiG,EAAYF,IAClB,OAAK/F,EAAM2D,KAUJ9F,EAAAA,EAAAA,KAACqI,EAAAA,GAAW5F,EAAAA,EAAAA,IAAAA,EAAAA,EAAAA,GAAA,GAAKN,GAAK,IAAEmG,UAAWF,MARtCpI,EAAAA,EAAAA,KAAC4D,EAAAA,QAAMnB,EAAAA,EAAAA,IAAAA,EAAAA,EAAAA,GAAA,GACDN,GAAK,IACTV,QAASA,KACP2G,EAAUjG,EAAMoG,iBAO1B,EA9BqBpG,IACnB,MAAMwD,EAAQD,IACd,IAAKvD,EAAM2D,IAAK,CACd,MAAM,WAAEyC,GAA0BpG,EAAXqG,GAAMpG,EAAAA,EAAAA,GAAKD,EAAKE,GACvC,OACErC,EAAAA,EAAAA,KAAC4D,EAAAA,QAAMnB,EAAAA,EAAAA,IAAAA,EAAAA,EAAAA,GAAA,GACD+F,GAAM,IACV/G,QAASA,KACPkE,EAAM4C,MAId,CACA,OAAOvI,EAAAA,EAAAA,KAACqI,EAAAA,GAAW5F,EAAAA,EAAAA,IAAAA,EAAAA,EAAAA,GAAA,GAAKN,GAAK,IAAEmG,UAAW3C,K,iECf5C,QAAe1B,G","sources":["webpack://@kne-components/components-core/./src/components/Modal/style.module.scss?4fe4","components/Modal/locale/index.js","components/Modal/renderWithOptions.js","components/Modal/Modal.js","components/Modal/TabsModal.js","components/Modal/ModalButton.js","common/components/SimpleBar.js"],"sourcesContent":["// extracted by mini-css-extract-plugin\nexport default {\"modal\":\"style_modal__Pm3cF__-0IeQ\",\"large\":\"style_large__iaqVE__-0IeQ\",\"modal-body-inner\":\"style_modal-body-inner__4PhpA__-0IeQ\",\"modal-title\":\"style_modal-title__dswaw__-0IeQ\",\"modal-outer\":\"style_modal-outer__r3SkX__-0IeQ\",\"modal-body\":\"style_modal-body__jQJSI__-0IeQ\",\"right-options-modal\":\"style_right-options-modal__FajDP__-0IeQ\",\"right-options-row\":\"style_right-options-row__-mPb9__-0IeQ\",\"right-options-col\":\"style_right-options-col__3ilee__-0IeQ\",\"is-disabled-scroller\":\"style_is-disabled-scroller__PmHyk__-0IeQ\",\"content\":\"style_content__k6MIF__-0IeQ\",\"modal-footer\":\"style_modal-footer__-prbN__-0IeQ\",\"modal-close\":\"style_modal-close__Oa5Kl__-0IeQ\",\"confirm-modal-wrap\":\"style_confirm-modal-wrap__YFImr__-0IeQ\",\"is-danger\":\"style_is-danger__H5110__-0IeQ\",\"title\":\"style_title__orTym__-0IeQ\",\"has-title\":\"style_has-title__qy0Wp__-0IeQ\"};","const importMessages = (locale) => {\n return ({\n 'en-US': () => import('./en-US'), 'zh-CN': () => import('./zh-CN')\n })[locale]();\n};\n\nexport default importMessages;","const renderWithOptions = (footer, options) => {\n if (typeof footer === \"function\") {\n return footer(options);\n }\n return footer;\n};\n\nexport default renderWithOptions;\n","import React, {useRef} from \"react\";\nimport {App, Button, Col, Modal as AntdModal, Row, Space} from \"antd\";\nimport classnames from \"classnames\";\nimport style from \"./style.module.scss\";\nimport importMessages from \"./locale\";\nimport {FormattedMessage, IntlProvider} from \"@components/Intl\";\nimport Icon from \"@components/Icon\";\nimport renderWithOptions from \"./renderWithOptions\";\nimport LoadingButton from \"@components/LoadingButton\";\nimport SimpleBar from \"@common/components/SimpleBar\";\n\nconst localeModuleName = \"Modal\";\n\nexport const RightOptions = ({options, rightSpan = 6, children}) => {\n if (!options) {\n return children;\n }\n return (<Row wrap={false} className={style[\"right-options-row\"]}>\n <Col span={24 - rightSpan} className={style[\"right-options-col\"]}>\n {children}\n </Col>\n <Col span={rightSpan} className={style[\"right-options-col\"]}>\n {options}\n </Col>\n </Row>);\n};\n\nconst calcHeight = (height, footer) => {\n return `${height - 48 - (footer ? 58 : 0)}px`;\n};\n\nconst sizeMap = (type, footer) => {\n if (type === \"large\") {\n return {\n width: `${Math.min(window.innerWidth - 64, 1500)}px`,\n style: {\"--min-modal-height\": calcHeight(500, footer)},\n };\n }\n if (type === \"small\") {\n return {\n width: \"600px\", style: {\"--min-modal-height\": calcHeight(300, footer)},\n };\n }\n return {\n width: \"1000px\", style: {\"--min-modal-height\": calcHeight(500, footer)},\n };\n};\n\nconst Footer = ({\n footer, footerButtons, onConfirm, onCancel, cancelText, onClose, targetProps,\n }) => {\n return (<Row gutter={10} wrap={false}>\n <Col flex={1}>{footer}</Col>\n {Array.isArray(footerButtons) && footerButtons.length === 0 ? null : (<Col>\n <Space>\n {(footerButtons || [{\n children: cancelText || (<IntlProvider\n importMessages={importMessages}\n moduleName={localeModuleName}\n >\n <FormattedMessage\n id={\"Cancel\"}\n moduleName={localeModuleName}\n />\n </IntlProvider>), onClick: onCancel,\n }, {\n type: \"primary\", children: (<IntlProvider\n importMessages={importMessages}\n moduleName={localeModuleName}\n >\n <FormattedMessage\n id={\"Confirm\"}\n moduleName={localeModuleName}\n />\n </IntlProvider>), onClick: onConfirm,\n },])\n .filter((item) => {\n if (typeof item?.display === \"function\") {\n return item?.display();\n }\n return item?.display !== false;\n })\n .map(({\n ButtonComponent, onClick, autoClose = true, display, ...props\n }, index) => {\n const CurrentButton = ButtonComponent || LoadingButton;\n return (<CurrentButton\n {...props}\n key={index}\n onClick={async (...args) => {\n const res = await Promise.resolve(onClick && onClick(...args, targetProps));\n autoClose && res !== false && onClose && onClose();\n return res;\n }}\n />);\n })}\n </Space>\n </Col>)}\n </Row>);\n};\n\nconst ModalOuter = ({\n title,\n footer,\n disabledScroller,\n footerButtons,\n onClose,\n closable,\n onConfirm,\n onCancel,\n children,\n targetProps,\n cancelText,\n confirmText,\n }) => {\n const modalBodyRef = useRef(null);\n return (<div className={classnames(style[\"modal-outer\"], 'modal-container')} data-testid=\"components-core-modal\">\n {closable === false ? null : (<Button\n data-testid=\"components-core-modal-close-btn\"\n className={classnames(style[\"modal-close\"], \"modal-close\")}\n type=\"text\"\n icon={<Icon type=\"icon-close-thin\"/>}\n onClick={(e) => {\n e.stopPropagation();\n onClose && onClose();\n }}\n />)}\n {title && <div className={style[\"modal-title\"]}>{title}</div>}\n <SimpleBar\n className={classnames(style[\"modal-body\"], {\n [style[\"is-disabled-scroller\"]]: disabledScroller,\n }, \"modal-body\")}\n ref={modalBodyRef}\n >\n <div\n className={classnames(style[\"modal-body-inner\"], \"modal-body-inner\")}\n >\n {children}\n </div>\n </SimpleBar>\n {footer === null && !footerButtons ? null : (<div className={classnames(style[\"modal-footer\"], \"modal-footer\")}>\n <Footer\n footer={footer}\n footerButtons={footerButtons}\n onConfirm={onConfirm}\n confirmText={confirmText}\n onCancel={onCancel}\n cancelText={cancelText}\n onClose={onClose}\n targetProps={targetProps}\n />\n </div>)}\n </div>);\n};\n\nconst runWithDecorator = ({\n withDecorator,\n footerButtons,\n title,\n closable,\n onClose,\n onConfirm,\n confirmText,\n onCancel,\n cancelText,\n footer,\n rightOptions,\n rightSpan,\n disabledScroller,\n childrenRef,\n children,\n }) => {\n const getInner = (props) => {\n props = Object.assign({}, {title}, props);\n return (<ModalOuter\n title={renderWithOptions(props.title, {\n ...props, childrenRef, close: onClose,\n })}\n closable={closable}\n onClose={onClose}\n onConfirm={onConfirm}\n confirmText={confirmText}\n onCancel={onCancel}\n cancelText={cancelText}\n footerButtons={renderWithOptions(footerButtons, {\n ...props, close: onClose,\n })}\n disabledScroller={disabledScroller}\n footer={renderWithOptions(footer, {\n ...props, childrenRef, close: onClose,\n })}\n targetProps={Object.assign({}, props, {childrenRef, close: onClose})}\n >\n <RightOptions\n rightSpan={rightSpan}\n options={renderWithOptions(rightOptions, {\n ...props, childrenRef, close: onClose,\n })}\n >\n {renderWithOptions(children, {\n ...props, childrenRef, close: onClose,\n })}\n </RightOptions>\n </ModalOuter>);\n };\n return typeof withDecorator === \"function\" ? withDecorator(getInner, {\n childrenRef, close: onClose,\n }) : getInner({});\n};\n\nconst computedCommonProps = ({\n children,\n rightOptions,\n rightSpan,\n footer,\n footerButtons,\n className,\n size,\n title,\n onClose,\n onConfirm,\n confirmText,\n onCancel,\n cancelText,\n closable,\n disabledScroller,\n withDecorator,\n childrenRef,\n ...props\n }) => {\n return {\n ...props,\n icon: null,\n centered: true,\n title: null,\n maskClosable: props.hasOwnProperty(\"maskClosable\") ? props.maskClosable : false,\n destroyOnHidden: true,\n footer: null,\n closable: false,\n onCancel: onClose,\n className: classnames(className, style[\"modal\"], style[size], {\n [style[\"right-options-modal\"]]: rightOptions,\n }), ...sizeMap(size, !(footer === null && !footerButtons)),\n children: (<IntlProvider importMessages={importMessages} moduleName=\"Modal\">\n {runWithDecorator({\n withDecorator,\n title,\n closable,\n onClose,\n onConfirm,\n confirmText,\n onCancel,\n cancelText,\n footer,\n footerButtons,\n rightOptions,\n rightSpan,\n disabledScroller,\n children,\n childrenRef,\n })}\n </IntlProvider>),\n };\n};\n\nconst Modal = ({size = 'default', ...props}) => {\n const childrenRef = useRef(null);\n return (<AntdModal\n {...computedCommonProps(Object.assign({}, props, {size, childrenRef}))}\n />);\n};\n\nexport const useModal = () => {\n const {modal} = App.useApp();\n const childrenRef = useRef(null);\n return (props) => {\n const api = {};\n const {children, ...otherProps} = computedCommonProps({\n onClose: () => api.close(), childrenRef, ...props,\n });\n const {destroy} = modal.info({\n ...otherProps, content: children,\n });\n api.close = destroy;\n\n return api;\n };\n};\n\nexport const useConfirmModal = () => {\n const {modal} = App.useApp();\n return (props) => {\n const api = {};\n const {\n type, icon, title, danger, wrapClassName, message, iconSetting = {}, confirmType = \"info\", ...otherProps\n } = {\n onClose: () => api.close(), maskClosable: false, ...props,\n };\n const typeEnum = Object.assign({}, {\n info: \"icon-xinxi-tianchong\",\n confirm: \"icon-tishi-tianchong\",\n warning: \"icon-tishi-tianchong\",\n error: \"icon-shibai\",\n success: \"icon-chenggong\",\n }, iconSetting);\n if (modal[type]) {\n const {destroy} = modal[type]({\n ...otherProps, icon: null, wrapClassName: classnames(style[\"confirm-modal-wrap\"], wrapClassName, {\n [style[\"is-danger\"]]: danger,\n }), title: (<Space\n orientation=\"vertical\"\n onClick={(e) => {\n e.stopPropagation();\n }}\n >\n {title && (<Space size={0} align=\"start\" className={style[\"title\"]}>\n {danger ? (<Icon\n className={classnames(\"title-icon\", `title-icon-${type === \"confirm\" ? confirmType : type}`)}\n type={icon || typeEnum[type === \"confirm\" ? confirmType : type]}\n />) : null}\n {title}\n </Space>)}\n </Space>), content: (<Space\n size={0}\n align=\"start\"\n className={classnames(style[\"content\"], {\n [style[\"has-title\"]]: title,\n })}\n >\n {!title && danger ? (<Icon\n className={classnames(\"title-icon\", `title-icon-${type === \"confirm\" ? confirmType : type}`)}\n type={icon || typeEnum[type === \"confirm\" ? confirmType : type]}\n />) : null}\n {message}\n </Space>),\n });\n api.close = destroy;\n }\n return api;\n };\n};\n\nexport default Modal;\n","import Modal, { useModal } from \"./Modal\";\nimport { Tabs } from \"antd\";\nimport classnames from \"classnames\";\n\nconst computedCommonProps = ({\n items,\n className,\n activeKey,\n withDecorator,\n defaultActiveKey,\n onChange,\n ...props\n}) => {\n return {\n ...props,\n className: classnames(className, \"tabs-modal\"),\n withDecorator: (render) => {\n const innerRender = (props) => (\n <Tabs\n items={items.map(({ withDecorator: itemWithDecorator, ...item }) => {\n return Object.assign({}, item, {\n children:\n typeof itemWithDecorator === \"function\"\n ? itemWithDecorator((innerProps) =>\n render(\n Object.assign({}, props, innerProps, {\n children: item.children,\n })\n )\n )\n : render(\n Object.assign({}, props, { children: item.children })\n ),\n });\n })}\n destroyInactiveTabPane\n activeKey={activeKey}\n defaultActiveKey={defaultActiveKey}\n onChange={onChange}\n />\n );\n return typeof withDecorator === \"function\"\n ? withDecorator(innerRender)\n : innerRender();\n },\n children: ({ children, ...props }) => {\n return typeof children === \"function\" ? children(props) : children;\n },\n };\n};\n\nconst TabsModal = (props) => {\n return <Modal {...computedCommonProps(props)} />;\n};\n\nexport default TabsModal;\n\nexport const useTabsModal = () => {\n const modal = useModal();\n return (props) => modal(computedCommonProps(props));\n};\n","import { useModal } from \"./Modal\";\nimport { useTabsModal } from \"./TabsModal\";\nimport FetchButton from \"@common/components/FetchButton\";\nimport { Button } from \"antd\";\n\nconst ModalButton = (props) => {\n const modal = useModal();\n if (!props.api) {\n const { modalProps, ...others } = props;\n return (\n <Button\n {...others}\n onClick={() => {\n modal(modalProps);\n }}\n />\n );\n }\n return <FetchButton {...props} modalFunc={modal} />;\n};\n\nexport const TabsModalButton = (props) => {\n const tabsModal = useTabsModal();\n if (!props.api) {\n return (\n <Button\n {...props}\n onClick={() => {\n tabsModal(props.modalProps);\n }}\n />\n );\n }\n return <FetchButton {...props} modalFunc={tabsModal} />;\n};\nexport default ModalButton;\n","import SimpleBar from \"simplebar-react\";\nimport \"simplebar-react/dist/simplebar.min.css\";\n\nexport default SimpleBar;\n"],"names":["locale","en-US","zh-CN","renderWithOptions","footer","options","localeModuleName","RightOptions","_ref","rightSpan","children","_jsxs","Row","wrap","className","style","_jsx","Col","span","calcHeight","height","concat","Footer","_ref2","footerButtons","onConfirm","onCancel","cancelText","onClose","targetProps","gutter","flex","Array","isArray","length","Space","IntlProvider","importMessages","moduleName","FormattedMessage","id","onClick","type","filter","item","display","map","_ref3","index","ButtonComponent","autoClose","props","_objectWithoutProperties","_excluded","CurrentButton","LoadingButton","_createElement","_objectSpread","key","async","_len","arguments","args","_key","res","Promise","resolve","ModalOuter","_ref4","title","disabledScroller","closable","confirmText","modalBodyRef","useRef","classnames","Button","icon","Icon","e","stopPropagation","SimpleBar","ref","runWithDecorator","_ref5","withDecorator","rightOptions","childrenRef","getInner","Object","assign","close","computedCommonProps","_ref6","size","_excluded2","centered","maskClosable","hasOwnProperty","destroyOnHidden","sizeMap","width","Math","min","window","innerWidth","useModal","modal","App","useApp","api","_computedCommonProps","otherProps","_excluded4","destroy","info","content","useConfirmModal","_onClose$maskClosable","danger","wrapClassName","message","iconSetting","confirmType","_excluded5","typeEnum","confirm","warning","error","success","orientation","align","_ref7","_excluded3","AntdModal","items","activeKey","defaultActiveKey","onChange","render","innerRender","Tabs","itemWithDecorator","innerProps","destroyInactiveTabPane","Modal","useTabsModal","TabsModalButton","tabsModal","FetchButton","modalFunc","modalProps","others"],"ignoreList":[],"sourceRoot":""}
1
+ {"version":3,"file":"static/js/3771.997ccc57.chunk.js","mappings":"sWACA,SAAgB,MAAQ,4BAA4B,MAAQ,4BAA4B,mBAAmB,uCAAuC,cAAc,kCAAkC,cAAc,kCAAkC,aAAa,iCAAiC,sBAAsB,0CAA0C,oBAAoB,wCAAwC,oBAAoB,wCAAwC,uBAAuB,2CAA2C,QAAU,8BAA8B,eAAe,mCAAmC,cAAc,kCAAkC,qBAAqB,yCAAyC,YAAY,gCAAgC,MAAQ,4BAA4B,YAAY,iCCK9zB,EANwBA,IACZ,CACJ,QAASC,IAAM,gCAAmB,QAASC,IAAM,iCAClDF,M,0BCHP,MAOA,EAP0BG,CAACC,EAAQC,IACX,oBAAXD,EACFA,EAAOC,GAETD,E,0aCOHE,EAAmB,QAEZC,EAAeC,IAAyC,IAAxC,QAACH,EAAO,UAAEI,EAAY,EAAC,SAAEC,GAASF,EAC3D,OAAKH,GAGGM,EAAAA,EAAAA,MAACC,EAAAA,IAAG,CAACC,MAAM,EAAOC,UAAWC,EAAM,qBAAqBL,SAAA,EAC5DM,EAAAA,EAAAA,KAACC,EAAAA,IAAG,CAACC,KAAM,GAAKT,EAAWK,UAAWC,EAAM,qBAAqBL,SAC5DA,KAELM,EAAAA,EAAAA,KAACC,EAAAA,IAAG,CAACC,KAAMT,EAAWK,UAAWC,EAAM,qBAAqBL,SACvDL,OAPEK,GAYTS,EAAaA,CAACC,EAAQhB,IAClB,GAANiB,OAAUD,EAAS,IAAMhB,EAAS,GAAK,GAAE,MAoBvCkB,EAASC,IAEQ,IAFP,OACInB,EAAM,cAAEoB,EAAa,UAAEC,EAAS,SAAEC,EAAQ,WAAEC,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AA,GACDN,GAAK,IACTV,QAASA,KACP2G,EAAUjG,EAAMoG,iBAO1B,EA9BqBpG,IACnB,MAAMwD,EAAQD,IACd,IAAKvD,EAAM2D,IAAK,CACd,MAAM,WAAEyC,GAA0BpG,EAAXqG,GAAMpG,EAAAA,EAAAA,GAAKD,EAAKE,GACvC,OACErC,EAAAA,EAAAA,KAAC4D,EAAAA,QAAMnB,EAAAA,EAAAA,IAAAA,EAAAA,EAAAA,GAAA,GACD+F,GAAM,IACV/G,QAASA,KACPkE,EAAM4C,MAId,CACA,OAAOvI,EAAAA,EAAAA,KAACqI,EAAAA,GAAW5F,EAAAA,EAAAA,IAAAA,EAAAA,EAAAA,GAAA,GAAKN,GAAK,IAAEmG,UAAW3C,K,iECf5C,QAAe1B,G","sources":["webpack://@kne-components/components-core/./src/components/Modal/style.module.scss?4fe4","components/Modal/locale/index.js","components/Modal/renderWithOptions.js","components/Modal/Modal.js","components/Modal/TabsModal.js","components/Modal/ModalButton.js","common/components/SimpleBar.js"],"sourcesContent":["// extracted by mini-css-extract-plugin\nexport default {\"modal\":\"style_modal__Pm3cF__HJ3UV\",\"large\":\"style_large__iaqVE__HJ3UV\",\"modal-body-inner\":\"style_modal-body-inner__4PhpA__HJ3UV\",\"modal-title\":\"style_modal-title__dswaw__HJ3UV\",\"modal-outer\":\"style_modal-outer__r3SkX__HJ3UV\",\"modal-body\":\"style_modal-body__jQJSI__HJ3UV\",\"right-options-modal\":\"style_right-options-modal__FajDP__HJ3UV\",\"right-options-row\":\"style_right-options-row__-mPb9__HJ3UV\",\"right-options-col\":\"style_right-options-col__3ilee__HJ3UV\",\"is-disabled-scroller\":\"style_is-disabled-scroller__PmHyk__HJ3UV\",\"content\":\"style_content__k6MIF__HJ3UV\",\"modal-footer\":\"style_modal-footer__-prbN__HJ3UV\",\"modal-close\":\"style_modal-close__Oa5Kl__HJ3UV\",\"confirm-modal-wrap\":\"style_confirm-modal-wrap__YFImr__HJ3UV\",\"is-danger\":\"style_is-danger__H5110__HJ3UV\",\"title\":\"style_title__orTym__HJ3UV\",\"has-title\":\"style_has-title__qy0Wp__HJ3UV\"};","const importMessages = (locale) => {\n return ({\n 'en-US': () => import('./en-US'), 'zh-CN': () => import('./zh-CN')\n })[locale]();\n};\n\nexport default importMessages;","const renderWithOptions = (footer, options) => {\n if (typeof footer === \"function\") {\n return footer(options);\n }\n return footer;\n};\n\nexport default renderWithOptions;\n","import React, {useRef} from \"react\";\nimport {App, Button, Col, Modal as AntdModal, Row, Space} from \"antd\";\nimport classnames from \"classnames\";\nimport style from \"./style.module.scss\";\nimport importMessages from \"./locale\";\nimport {FormattedMessage, IntlProvider} from \"@components/Intl\";\nimport Icon from \"@components/Icon\";\nimport renderWithOptions from \"./renderWithOptions\";\nimport LoadingButton from \"@components/LoadingButton\";\nimport SimpleBar from \"@common/components/SimpleBar\";\n\nconst localeModuleName = \"Modal\";\n\nexport const RightOptions = ({options, rightSpan = 6, children}) => {\n if (!options) {\n return children;\n }\n return (<Row wrap={false} className={style[\"right-options-row\"]}>\n <Col span={24 - rightSpan} className={style[\"right-options-col\"]}>\n {children}\n </Col>\n <Col span={rightSpan} className={style[\"right-options-col\"]}>\n {options}\n </Col>\n </Row>);\n};\n\nconst calcHeight = (height, footer) => {\n return `${height - 48 - (footer ? 58 : 0)}px`;\n};\n\nconst sizeMap = (type, footer) => {\n if (type === \"large\") {\n return {\n width: `${Math.min(window.innerWidth - 64, 1500)}px`,\n style: {\"--min-modal-height\": calcHeight(500, footer)},\n };\n }\n if (type === \"small\") {\n return {\n width: \"600px\", style: {\"--min-modal-height\": calcHeight(300, footer)},\n };\n }\n return {\n width: \"1000px\", style: {\"--min-modal-height\": calcHeight(500, footer)},\n };\n};\n\nconst Footer = ({\n footer, footerButtons, onConfirm, onCancel, cancelText, onClose, targetProps,\n }) => {\n return (<Row gutter={10} wrap={false}>\n <Col flex={1}>{footer}</Col>\n {Array.isArray(footerButtons) && footerButtons.length === 0 ? null : (<Col>\n <Space>\n {(footerButtons || [{\n children: cancelText || (<IntlProvider\n importMessages={importMessages}\n moduleName={localeModuleName}\n >\n <FormattedMessage\n id={\"Cancel\"}\n moduleName={localeModuleName}\n />\n </IntlProvider>), onClick: onCancel,\n }, {\n type: \"primary\", children: (<IntlProvider\n importMessages={importMessages}\n moduleName={localeModuleName}\n >\n <FormattedMessage\n id={\"Confirm\"}\n moduleName={localeModuleName}\n />\n </IntlProvider>), onClick: onConfirm,\n },])\n .filter((item) => {\n if (typeof item?.display === \"function\") {\n return item?.display();\n }\n return item?.display !== false;\n })\n .map(({\n ButtonComponent, onClick, autoClose = true, display, ...props\n }, index) => {\n const CurrentButton = ButtonComponent || LoadingButton;\n return (<CurrentButton\n {...props}\n key={index}\n onClick={async (...args) => {\n const res = await Promise.resolve(onClick && onClick(...args, targetProps));\n autoClose && res !== false && onClose && onClose();\n return res;\n }}\n />);\n })}\n </Space>\n </Col>)}\n </Row>);\n};\n\nconst ModalOuter = ({\n title,\n footer,\n disabledScroller,\n footerButtons,\n onClose,\n closable,\n onConfirm,\n onCancel,\n children,\n targetProps,\n cancelText,\n confirmText,\n }) => {\n const modalBodyRef = useRef(null);\n return (<div className={classnames(style[\"modal-outer\"], 'modal-container')} data-testid=\"components-core-modal\">\n {closable === false ? null : (<Button\n data-testid=\"components-core-modal-close-btn\"\n className={classnames(style[\"modal-close\"], \"modal-close\")}\n type=\"text\"\n icon={<Icon type=\"icon-close-thin\"/>}\n onClick={(e) => {\n e.stopPropagation();\n onClose && onClose();\n }}\n />)}\n {title && <div className={style[\"modal-title\"]}>{title}</div>}\n <SimpleBar\n className={classnames(style[\"modal-body\"], {\n [style[\"is-disabled-scroller\"]]: disabledScroller,\n }, \"modal-body\")}\n ref={modalBodyRef}\n >\n <div\n className={classnames(style[\"modal-body-inner\"], \"modal-body-inner\")}\n >\n {children}\n </div>\n </SimpleBar>\n {footer === null && !footerButtons ? null : (<div className={classnames(style[\"modal-footer\"], \"modal-footer\")}>\n <Footer\n footer={footer}\n footerButtons={footerButtons}\n onConfirm={onConfirm}\n confirmText={confirmText}\n onCancel={onCancel}\n cancelText={cancelText}\n onClose={onClose}\n targetProps={targetProps}\n />\n </div>)}\n </div>);\n};\n\nconst runWithDecorator = ({\n withDecorator,\n footerButtons,\n title,\n closable,\n onClose,\n onConfirm,\n confirmText,\n onCancel,\n cancelText,\n footer,\n rightOptions,\n rightSpan,\n disabledScroller,\n childrenRef,\n children,\n }) => {\n const getInner = (props) => {\n props = Object.assign({}, {title}, props);\n return (<ModalOuter\n title={renderWithOptions(props.title, {\n ...props, childrenRef, close: onClose,\n })}\n closable={closable}\n onClose={onClose}\n onConfirm={onConfirm}\n confirmText={confirmText}\n onCancel={onCancel}\n cancelText={cancelText}\n footerButtons={renderWithOptions(footerButtons, {\n ...props, close: onClose,\n })}\n disabledScroller={disabledScroller}\n footer={renderWithOptions(footer, {\n ...props, childrenRef, close: onClose,\n })}\n targetProps={Object.assign({}, props, {childrenRef, close: onClose})}\n >\n <RightOptions\n rightSpan={rightSpan}\n options={renderWithOptions(rightOptions, {\n ...props, childrenRef, close: onClose,\n })}\n >\n {renderWithOptions(children, {\n ...props, childrenRef, close: onClose,\n })}\n </RightOptions>\n </ModalOuter>);\n };\n return typeof withDecorator === \"function\" ? withDecorator(getInner, {\n childrenRef, close: onClose,\n }) : getInner({});\n};\n\nconst computedCommonProps = ({\n children,\n rightOptions,\n rightSpan,\n footer,\n footerButtons,\n className,\n size,\n title,\n onClose,\n onConfirm,\n confirmText,\n onCancel,\n cancelText,\n closable,\n disabledScroller,\n withDecorator,\n childrenRef,\n ...props\n }) => {\n return {\n ...props,\n icon: null,\n centered: true,\n title: null,\n maskClosable: props.hasOwnProperty(\"maskClosable\") ? props.maskClosable : false,\n destroyOnHidden: true,\n footer: null,\n closable: false,\n onCancel: onClose,\n className: classnames(className, style[\"modal\"], style[size], {\n [style[\"right-options-modal\"]]: rightOptions,\n }), ...sizeMap(size, !(footer === null && !footerButtons)),\n children: (<IntlProvider importMessages={importMessages} moduleName=\"Modal\">\n {runWithDecorator({\n withDecorator,\n title,\n closable,\n onClose,\n onConfirm,\n confirmText,\n onCancel,\n cancelText,\n footer,\n footerButtons,\n rightOptions,\n rightSpan,\n disabledScroller,\n children,\n childrenRef,\n })}\n </IntlProvider>),\n };\n};\n\nconst Modal = ({size = 'default', ...props}) => {\n const childrenRef = useRef(null);\n return (<AntdModal\n {...computedCommonProps(Object.assign({}, props, {size, childrenRef}))}\n />);\n};\n\nexport const useModal = () => {\n const {modal} = App.useApp();\n const childrenRef = useRef(null);\n return (props) => {\n const api = {};\n const {children, ...otherProps} = computedCommonProps({\n onClose: () => api.close(), childrenRef, ...props,\n });\n const {destroy} = modal.info({\n ...otherProps, content: children,\n });\n api.close = destroy;\n\n return api;\n };\n};\n\nexport const useConfirmModal = () => {\n const {modal} = App.useApp();\n return (props) => {\n const api = {};\n const {\n type, icon, title, danger, wrapClassName, message, iconSetting = {}, confirmType = \"info\", ...otherProps\n } = {\n onClose: () => api.close(), maskClosable: false, ...props,\n };\n const typeEnum = Object.assign({}, {\n info: \"icon-xinxi-tianchong\",\n confirm: \"icon-tishi-tianchong\",\n warning: \"icon-tishi-tianchong\",\n error: \"icon-shibai\",\n success: \"icon-chenggong\",\n }, iconSetting);\n if (modal[type]) {\n const {destroy} = modal[type]({\n ...otherProps, icon: null, wrapClassName: classnames(style[\"confirm-modal-wrap\"], wrapClassName, {\n [style[\"is-danger\"]]: danger,\n }), title: (<Space\n orientation=\"vertical\"\n onClick={(e) => {\n e.stopPropagation();\n }}\n >\n {title && (<Space size={0} align=\"start\" className={style[\"title\"]}>\n {danger ? (<Icon\n className={classnames(\"title-icon\", `title-icon-${type === \"confirm\" ? confirmType : type}`)}\n type={icon || typeEnum[type === \"confirm\" ? confirmType : type]}\n />) : null}\n {title}\n </Space>)}\n </Space>), content: (<Space\n size={0}\n align=\"start\"\n className={classnames(style[\"content\"], {\n [style[\"has-title\"]]: title,\n })}\n >\n {!title && danger ? (<Icon\n className={classnames(\"title-icon\", `title-icon-${type === \"confirm\" ? confirmType : type}`)}\n type={icon || typeEnum[type === \"confirm\" ? confirmType : type]}\n />) : null}\n {message}\n </Space>),\n });\n api.close = destroy;\n }\n return api;\n };\n};\n\nexport default Modal;\n","import Modal, { useModal } from \"./Modal\";\nimport { Tabs } from \"antd\";\nimport classnames from \"classnames\";\n\nconst computedCommonProps = ({\n items,\n className,\n activeKey,\n withDecorator,\n defaultActiveKey,\n onChange,\n ...props\n}) => {\n return {\n ...props,\n className: classnames(className, \"tabs-modal\"),\n withDecorator: (render) => {\n const innerRender = (props) => (\n <Tabs\n items={items.map(({ withDecorator: itemWithDecorator, ...item }) => {\n return Object.assign({}, item, {\n children:\n typeof itemWithDecorator === \"function\"\n ? itemWithDecorator((innerProps) =>\n render(\n Object.assign({}, props, innerProps, {\n children: item.children,\n })\n )\n )\n : render(\n Object.assign({}, props, { children: item.children })\n ),\n });\n })}\n destroyInactiveTabPane\n activeKey={activeKey}\n defaultActiveKey={defaultActiveKey}\n onChange={onChange}\n />\n );\n return typeof withDecorator === \"function\"\n ? withDecorator(innerRender)\n : innerRender();\n },\n children: ({ children, ...props }) => {\n return typeof children === \"function\" ? children(props) : children;\n },\n };\n};\n\nconst TabsModal = (props) => {\n return <Modal {...computedCommonProps(props)} />;\n};\n\nexport default TabsModal;\n\nexport const useTabsModal = () => {\n const modal = useModal();\n return (props) => modal(computedCommonProps(props));\n};\n","import { useModal } from \"./Modal\";\nimport { useTabsModal } from \"./TabsModal\";\nimport FetchButton from \"@common/components/FetchButton\";\nimport { Button } from \"antd\";\n\nconst ModalButton = (props) => {\n const modal = useModal();\n if (!props.api) {\n const { modalProps, ...others } = props;\n return (\n <Button\n {...others}\n onClick={() => {\n modal(modalProps);\n }}\n />\n );\n }\n return <FetchButton {...props} modalFunc={modal} />;\n};\n\nexport const TabsModalButton = (props) => {\n const tabsModal = useTabsModal();\n if (!props.api) {\n return (\n <Button\n {...props}\n onClick={() => {\n tabsModal(props.modalProps);\n }}\n />\n );\n }\n return <FetchButton {...props} modalFunc={tabsModal} />;\n};\nexport default ModalButton;\n","import SimpleBar from \"simplebar-react\";\nimport \"simplebar-react/dist/simplebar.min.css\";\n\nexport default SimpleBar;\n"],"names":["locale","en-US","zh-CN","renderWithOptions","footer","options","localeModuleName","RightOptions","_ref","rightSpan","children","_jsxs","Row","wrap","className","style","_jsx","Col","span","calcHeight","height","concat","Footer","_ref2","footerButtons","onConfirm","onCancel","cancelText","onClose","targetProps","gutter","flex","Array","isArray","length","Space","IntlProvider","importMessages","moduleName","FormattedMessage","id","onClick","type","filter","item","display","map","_ref3","index","ButtonComponent","autoClose","props","_objectWithoutProperties","_excluded","CurrentButton","LoadingButton","_createElement","_objectSpread","key","async","_len","arguments","args","_key","res","Promise","resolve","ModalOuter","_ref4","title","disabledScroller","closable","confirmText","modalBodyRef","useRef","classnames","Button","icon","Icon","e","stopPropagation","SimpleBar","ref","runWithDecorator","_ref5","withDecorator","rightOptions","childrenRef","getInner","Object","assign","close","computedCommonProps","_ref6","size","_excluded2","centered","maskClosable","hasOwnProperty","destroyOnHidden","sizeMap","width","Math","min","window","innerWidth","useModal","modal","App","useApp","api","_computedCommonProps","otherProps","_excluded4","destroy","info","content","useConfirmModal","_onClose$maskClosable","danger","wrapClassName","message","iconSetting","confirmType","_excluded5","typeEnum","confirm","warning","error","success","orientation","align","_ref7","_excluded3","AntdModal","items","activeKey","defaultActiveKey","onChange","render","innerRender","Tabs","itemWithDecorator","innerProps","destroyInactiveTabPane","Modal","useTabsModal","TabsModalButton","tabsModal","FetchButton","modalFunc","modalProps","others"],"ignoreList":[],"sourceRoot":""}
@@ -1,2 +1,2 @@
1
- "use strict";(self.webpackChunk_kne_components_components_core=self.webpackChunk_kne_components_components_core||[]).push([[2908,3790],{48731(e,n,i){i.r(n),i.d(n,{default:()=>a.a});var s=i(98919),a=i.n(s),l=i(22717),t=i.n(l);(0,s.preset)({base:t()([["gender",()=>[{value:"M",description:"\u7537"},{value:"F",description:"\u5973"}]],["marital",()=>[{description:"\u5df2\u5a5a",value:"Y"},{description:"\u672a\u5a5a",value:"N"}]],["confirm",()=>[{description:"\u662f",value:"Y"},{description:"\u5426",value:"N"}]],["political",()=>[{description:"\u4e2d\u5171\u515a\u5458",value:"\u4e2d\u5171\u515a\u5458"},{description:"\u5171\u9752\u56e2\u5458",value:"\u5171\u9752\u56e2\u5458"},{description:"\u7fa4\u4f17",value:"\u7fa4\u4f17"},{description:"\u5176\u4ed6\u515a\u6d3e",value:"\u5176\u4ed6\u515a\u6d3e"}]],["phoneStateEnum",()=>[{value:0,description:"\u7a7a\u53f7"},{value:1,description:"\u5b9e\u53f7"},{value:2,description:"\u505c\u673a"},{value:3,description:"\u5e93\u65e0"},{value:4,description:"\u6c89\u9ed8\u53f7"},{value:5,description:"\u98ce\u9669\u53f7"}]],["degreeEnum",()=>[{description:"\u521d\u4e2d",value:10},{description:"\u4e2d\u4e13",value:20},{description:"\u9ad8\u4e2d",value:30},{description:"\u5927\u4e13",value:40},{description:"\u672c\u79d1",value:50},{description:"\u7855\u58eb\u7814\u7a76\u751f",value:60},{description:"\u535a\u58eb\u7814\u7a76\u751f",value:70},{description:"\u535a\u58eb\u540e",value:75},{description:"\u5b66\u5386\u4e0d\u9650",value:999}]]],(e,n)=>{e[n[0]]=n[1]},{})})},75363(e,n,i){i.r(n),i.d(n,{default:()=>h});const s=e=>({"en-US":()=>i.e(9431).then(i.bind(i,9431)),"zh-CN":()=>i.e(1065).then(i.bind(i,81065))}[e]());var a=i(47458),l=i(64671),t=i(55199),r=i(83136),c=i.n(r);const o="style_helper-guide__K5xFw__-0IeQ",d="style_inner__bMKeU__-0IeQ",u="style_content__xTfWZ__-0IeQ",p="style_link__93j7O__-0IeQ";var v=i(48731),_=i(70579);const h=e=>{let{name:n,className:i}=e;return(0,_.jsx)(a.IntlProvider,{importMessages:s,moduleName:"HelperGuide",children:(0,_.jsx)(v.default,{moduleName:"helperGuide",name:n,children:e=>e&&e.value&&(0,_.jsx)("div",{className:c()(o,i),children:(0,_.jsxs)(t.Space,{className:d,children:[(0,_.jsx)(l.default,{colorful:!0,type:"icon-color-bangzhuyindao"}),(0,_.jsx)("span",{className:u,children:e.content}),e.url&&(0,_.jsxs)(t.Typography.Link,{className:p,href:e.url,target:"_blank",children:["\u67e5\u770b\u5e2e\u52a9",(0,_.jsx)(l.default,{type:"icon-shuangjiantou-right"})]})]})})})})}}}]);
2
- //# sourceMappingURL=3790.6af26115.chunk.js.map
1
+ "use strict";(self.webpackChunk_kne_components_components_core=self.webpackChunk_kne_components_components_core||[]).push([[2908,3790],{48731(e,n,i){i.r(n),i.d(n,{default:()=>a.a});var s=i(98919),a=i.n(s),l=i(22717),t=i.n(l);(0,s.preset)({base:t()([["gender",()=>[{value:"M",description:"\u7537"},{value:"F",description:"\u5973"}]],["marital",()=>[{description:"\u5df2\u5a5a",value:"Y"},{description:"\u672a\u5a5a",value:"N"}]],["confirm",()=>[{description:"\u662f",value:"Y"},{description:"\u5426",value:"N"}]],["political",()=>[{description:"\u4e2d\u5171\u515a\u5458",value:"\u4e2d\u5171\u515a\u5458"},{description:"\u5171\u9752\u56e2\u5458",value:"\u5171\u9752\u56e2\u5458"},{description:"\u7fa4\u4f17",value:"\u7fa4\u4f17"},{description:"\u5176\u4ed6\u515a\u6d3e",value:"\u5176\u4ed6\u515a\u6d3e"}]],["phoneStateEnum",()=>[{value:0,description:"\u7a7a\u53f7"},{value:1,description:"\u5b9e\u53f7"},{value:2,description:"\u505c\u673a"},{value:3,description:"\u5e93\u65e0"},{value:4,description:"\u6c89\u9ed8\u53f7"},{value:5,description:"\u98ce\u9669\u53f7"}]],["degreeEnum",()=>[{description:"\u521d\u4e2d",value:10},{description:"\u4e2d\u4e13",value:20},{description:"\u9ad8\u4e2d",value:30},{description:"\u5927\u4e13",value:40},{description:"\u672c\u79d1",value:50},{description:"\u7855\u58eb\u7814\u7a76\u751f",value:60},{description:"\u535a\u58eb\u7814\u7a76\u751f",value:70},{description:"\u535a\u58eb\u540e",value:75},{description:"\u5b66\u5386\u4e0d\u9650",value:999}]]],(e,n)=>{e[n[0]]=n[1]},{})})},75363(e,n,i){i.r(n),i.d(n,{default:()=>h});const s=e=>({"en-US":()=>i.e(9431).then(i.bind(i,9431)),"zh-CN":()=>i.e(1065).then(i.bind(i,81065))}[e]());var a=i(47458),l=i(64671),t=i(55199),r=i(83136),c=i.n(r);const o="style_helper-guide__K5xFw__HJ3UV",d="style_inner__bMKeU__HJ3UV",u="style_content__xTfWZ__HJ3UV",p="style_link__93j7O__HJ3UV";var v=i(48731),_=i(70579);const h=e=>{let{name:n,className:i}=e;return(0,_.jsx)(a.IntlProvider,{importMessages:s,moduleName:"HelperGuide",children:(0,_.jsx)(v.default,{moduleName:"helperGuide",name:n,children:e=>e&&e.value&&(0,_.jsx)("div",{className:c()(o,i),children:(0,_.jsxs)(t.Space,{className:d,children:[(0,_.jsx)(l.default,{colorful:!0,type:"icon-color-bangzhuyindao"}),(0,_.jsx)("span",{className:u,children:e.content}),e.url&&(0,_.jsxs)(t.Typography.Link,{className:p,href:e.url,target:"_blank",children:["\u67e5\u770b\u5e2e\u52a9",(0,_.jsx)(l.default,{type:"icon-shuangjiantou-right"})]})]})})})})}}}]);
2
+ //# sourceMappingURL=3790.805593bc.chunk.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"static/js/3790.6af26115.chunk.js","mappings":"kOAyHAA,EAAAA,EAAAA,QAAO,CACLC,KAAMC,IAvHY,CAClB,CACE,SACA,IAAM,CACJ,CAAEC,MAAO,IAAKC,YAAa,UAC3B,CACED,MAAO,IACPC,YAAa,YAInB,CACE,UACA,IAAM,CACJ,CAAEA,YAAa,eAAMD,MAAO,KAC5B,CACEC,YAAa,eACbD,MAAO,OAIb,CACE,UACA,IAAM,CACJ,CAAEC,YAAa,SAAKD,MAAO,KAC3B,CACEC,YAAa,SACbD,MAAO,OAIb,CACE,YACA,IAAM,CACJ,CAAEC,YAAa,2BAAQD,MAAO,4BAC9B,CACEC,YAA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KAAK,8BACpBb,EAAAA,EAAAA,KAAA,QAAMD,UAAWS,EAAiBJ,SAAEE,EAAKQ,UACxCR,EAAKS,MACJN,EAAAA,EAAAA,MAACO,EAAAA,WAAWC,KAAI,CACdlB,UAAWS,EACXU,KAAMZ,EAAKS,IACXI,OAAO,SAAQf,SAAA,CAChB,4BAECJ,EAAAA,EAAAA,KAACW,EAAAA,QAAI,CAACE,KAAK,yC","sources":["components/Enum/index.js","components/HelperGuide/locale/index.js","webpack://@kne-components/components-core/./src/components/HelperGuide/style.module.scss?bc31","components/HelperGuide/index.js"],"sourcesContent":["import { preset } from \"@kne/react-enum\";\nimport transform from \"lodash/transform\";\n\nconst baseLoaders = [\n [\n \"gender\",\n () => [\n { value: \"M\", description: \"男\" },\n {\n value: \"F\",\n description: \"女\",\n },\n ],\n ],\n [\n \"marital\",\n () => [\n { description: \"已婚\", value: \"Y\" },\n {\n description: \"未婚\",\n value: \"N\",\n },\n ],\n ],\n [\n \"confirm\",\n () => [\n { description: \"是\", value: \"Y\" },\n {\n description: \"否\",\n value: \"N\",\n },\n ],\n ],\n [\n \"political\",\n () => [\n { description: \"中共党员\", value: \"中共党员\" },\n {\n description: \"共青团员\",\n value: \"共青团员\",\n },\n { description: \"群众\", value: \"群众\" },\n {\n description: \"其他党派\",\n value: \"其他党派\",\n },\n ],\n ],\n [\n \"phoneStateEnum\",\n () => [\n {\n value: 0,\n description: \"空号\",\n },\n {\n value: 1,\n description: \"实号\",\n },\n {\n value: 2,\n description: \"停机\",\n },\n {\n value: 3,\n description: \"库无\",\n },\n {\n value: 4,\n description: \"沉默号\",\n },\n {\n value: 5,\n description: \"风险号\",\n },\n ],\n ],\n [\n \"degreeEnum\",\n () => [\n {\n description: \"初中\",\n value: 10,\n },\n {\n description: \"中专\",\n value: 20,\n },\n {\n description: \"高中\",\n value: 30,\n },\n {\n description: \"大专\",\n value: 40,\n },\n {\n description: \"本科\",\n value: 50,\n },\n {\n description: \"硕士研究生\",\n value: 60,\n },\n {\n description: \"博士研究生\",\n value: 70,\n },\n {\n description: \"博士后\",\n value: 75,\n },\n {\n description: \"学历不限\",\n value: 999,\n },\n ],\n ],\n];\n\npreset({\n base: transform(\n baseLoaders,\n (result, value) => {\n result[value[0]] = value[1];\n },\n {}\n ),\n});\n\nexport { default } from \"@kne/react-enum\";\n","const importMessages = (locale) => {\n return {\n \"en-US\": () => import(\"./en-US\"),\n \"zh-CN\": () => import(\"./zh-CN\"),\n }[locale]();\n};\n\nexport default importMessages;\n","// extracted by mini-css-extract-plugin\nexport default {\"helper-guide\":\"style_helper-guide__K5xFw__-0IeQ\",\"inner\":\"style_inner__bMKeU__-0IeQ\",\"content\":\"style_content__xTfWZ__-0IeQ\",\"link\":\"style_link__93j7O__-0IeQ\"};","import importMessages from \"./locale\";\nimport { IntlProvider } from \"@components/Intl\";\nimport Icon from \"@components/Icon\";\nimport { Space, Typography } from \"antd\";\nimport classnames from \"classnames\";\nimport style from \"./style.module.scss\";\nimport Enum from \"@components/Enum\";\n\nconst HelperGuide = ({ name, className }) => {\n return (\n <IntlProvider importMessages={importMessages} moduleName=\"HelperGuide\">\n <Enum moduleName=\"helperGuide\" name={name}>\n {(data) => {\n return (\n data &&\n data.value && (\n <div className={classnames(style[\"helper-guide\"], className)}>\n <Space className={style[\"inner\"]}>\n <Icon colorful type=\"icon-color-bangzhuyindao\" />\n <span className={style[\"content\"]}>{data.content}</span>\n {data.url && (\n <Typography.Link\n className={style[\"link\"]}\n href={data.url}\n target=\"_blank\"\n >\n 查看帮助\n <Icon type=\"icon-shuangjiantou-right\" />\n </Typography.Link>\n )}\n </Space>\n </div>\n )\n );\n }}\n </Enum>\n </IntlProvider>\n );\n};\n\nexport default HelperGuide;\n"],"names":["preset","base","transform","value","description","result","locale","en-US","zh-CN","_ref","name","className","_jsx","IntlProvider","importMessages","moduleName","children","Enum","data","classnames","style","_jsxs","Space","Icon","colorful","type","content","url","Typography","Link","href","target"],"ignoreList":[],"sourceRoot":""}
1
+ {"version":3,"file":"static/js/3790.805593bc.chunk.js","mappings":"kOAyHAA,EAAAA,EAAAA,QAAO,CACLC,KAAMC,IAvHY,CAClB,CACE,SACA,IAAM,CACJ,CAAEC,MAAO,IAAKC,YAAa,UAC3B,CACED,MAAO,IACPC,YAAa,YAInB,CACE,UACA,IAAM,CACJ,CAAEA,YAAa,eAAMD,MAAO,KAC5B,CACEC,YAAa,eACbD,MAAO,OAIb,CACE,UACA,IAAM,CACJ,CAAEC,YAAa,SAAKD,MAAO,KAC3B,CACEC,YAAa,SACbD,MAAO,OAIb,CACE,YACA,IAAM,CACJ,CAAEC,YAAa,2BAAQD,MAAO,4BAC9B,CACEC,YAAa,2BACbD,MAAO,4BAET,CAAEC,YAAa,eAAMD,MAAO,gBAC5B,CACEC,YAAa,2BACbD,MAAO,8BAIb,CACE,iBACA,IAAM,CACJ,CACEA,MAAO,EACPC,YAAa,gBAEf,CACED,MAAO,EACPC,YAAa,gBAEf,CACED,MAAO,EACPC,YAAa,gBAEf,CACED,MAAO,EACPC,YAAa,gBAEf,CACED,MAAO,EACPC,YAAa,sBAEf,CACED,MAAO,EACPC,YAAa,wBAInB,CACE,aACA,IAAM,CACJ,CACEA,YAAa,eACbD,MAAO,IAET,CACEC,YAAa,eACbD,MAAO,IAET,CACEC,YAAa,eACbD,MAAO,IAET,CACEC,YAAa,eACbD,MAAO,IAET,CACEC,YAAa,eACbD,MAAO,IAET,CACEC,YAAa,iCACbD,MAAO,IAET,CACEC,YAAa,iCACbD,MAAO,IAET,CACEC,YAAa,qBACbD,MAAO,IAET,CACEC,YAAa,2BACbD,MAAO,QASX,CAACE,EAAQF,KACPE,EAAOF,EAAM,IAAMA,EAAM,IAE3B,CAAC,I,6CC/HL,MAOA,EAPwBG,IACf,CACL,QAASC,IAAM,+BACf,QAASC,IAAM,iCACfF,M,yDCHJ,QAA+B,mCAA/B,EAA0E,4BAA1E,EAAgH,8BAAhH,EAAqJ,2B,0BCOrJ,MAgCA,EAhCoBG,IAA0B,IAAzB,KAAEC,EAAI,UAAEC,GAAWF,EACtC,OACEG,EAAAA,EAAAA,KAACC,EAAAA,aAAY,CAACC,eAAgBA,EAAgBC,WAAW,cAAaC,UACpEJ,EAAAA,EAAAA,KAACK,EAAAA,QAAI,CAACF,WAAW,cAAcL,KAAMA,EAAKM,SACtCE,GAEEA,GACAA,EAAKf,QACHS,EAAAA,EAAAA,KAAA,OAAKD,UAAWQ,IAAWC,EAAuBT,GAAWK,UAC3DK,EAAAA,EAAAA,MAACC,EAAAA,MAAK,CAACX,UAAWS,EAAeJ,SAAA,EAC/BJ,EAAAA,EAAAA,KAACW,EAAAA,QAAI,CAACC,UAAQ,EAACC,KAAK,8BACpBb,EAAAA,EAAAA,KAAA,QAAMD,UAAWS,EAAiBJ,SAAEE,EAAKQ,UACxCR,EAAKS,MACJN,EAAAA,EAAAA,MAACO,EAAAA,WAAWC,KAAI,CACdlB,UAAWS,EACXU,KAAMZ,EAAKS,IACXI,OAAO,SAAQf,SAAA,CAChB,4BAECJ,EAAAA,EAAAA,KAACW,EAAAA,QAAI,CAACE,KAAK,yC","sources":["components/Enum/index.js","components/HelperGuide/locale/index.js","webpack://@kne-components/components-core/./src/components/HelperGuide/style.module.scss?bc31","components/HelperGuide/index.js"],"sourcesContent":["import { preset } from \"@kne/react-enum\";\nimport transform from \"lodash/transform\";\n\nconst baseLoaders = [\n [\n \"gender\",\n () => [\n { value: \"M\", description: \"男\" },\n {\n value: \"F\",\n description: \"女\",\n },\n ],\n ],\n [\n \"marital\",\n () => [\n { description: \"已婚\", value: \"Y\" },\n {\n description: \"未婚\",\n value: \"N\",\n },\n ],\n ],\n [\n \"confirm\",\n () => [\n { description: \"是\", value: \"Y\" },\n {\n description: \"否\",\n value: \"N\",\n },\n ],\n ],\n [\n \"political\",\n () => [\n { description: \"中共党员\", value: \"中共党员\" },\n {\n description: \"共青团员\",\n value: \"共青团员\",\n },\n { description: \"群众\", value: \"群众\" },\n {\n description: \"其他党派\",\n value: \"其他党派\",\n },\n ],\n ],\n [\n \"phoneStateEnum\",\n () => [\n {\n value: 0,\n description: \"空号\",\n },\n {\n value: 1,\n description: \"实号\",\n },\n {\n value: 2,\n description: \"停机\",\n },\n {\n value: 3,\n description: \"库无\",\n },\n {\n value: 4,\n description: \"沉默号\",\n },\n {\n value: 5,\n description: \"风险号\",\n },\n ],\n ],\n [\n \"degreeEnum\",\n () => [\n {\n description: \"初中\",\n value: 10,\n },\n {\n description: \"中专\",\n value: 20,\n },\n {\n description: \"高中\",\n value: 30,\n },\n {\n description: \"大专\",\n value: 40,\n },\n {\n description: \"本科\",\n value: 50,\n },\n {\n description: \"硕士研究生\",\n value: 60,\n },\n {\n description: \"博士研究生\",\n value: 70,\n },\n {\n description: \"博士后\",\n value: 75,\n },\n {\n description: \"学历不限\",\n value: 999,\n },\n ],\n ],\n];\n\npreset({\n base: transform(\n baseLoaders,\n (result, value) => {\n result[value[0]] = value[1];\n },\n {}\n ),\n});\n\nexport { default } from \"@kne/react-enum\";\n","const importMessages = (locale) => {\n return {\n \"en-US\": () => import(\"./en-US\"),\n \"zh-CN\": () => import(\"./zh-CN\"),\n }[locale]();\n};\n\nexport default importMessages;\n","// extracted by mini-css-extract-plugin\nexport default {\"helper-guide\":\"style_helper-guide__K5xFw__HJ3UV\",\"inner\":\"style_inner__bMKeU__HJ3UV\",\"content\":\"style_content__xTfWZ__HJ3UV\",\"link\":\"style_link__93j7O__HJ3UV\"};","import importMessages from \"./locale\";\nimport { IntlProvider } from \"@components/Intl\";\nimport Icon from \"@components/Icon\";\nimport { Space, Typography } from \"antd\";\nimport classnames from \"classnames\";\nimport style from \"./style.module.scss\";\nimport Enum from \"@components/Enum\";\n\nconst HelperGuide = ({ name, className }) => {\n return (\n <IntlProvider importMessages={importMessages} moduleName=\"HelperGuide\">\n <Enum moduleName=\"helperGuide\" name={name}>\n {(data) => {\n return (\n data &&\n data.value && (\n <div className={classnames(style[\"helper-guide\"], className)}>\n <Space className={style[\"inner\"]}>\n <Icon colorful type=\"icon-color-bangzhuyindao\" />\n <span className={style[\"content\"]}>{data.content}</span>\n {data.url && (\n <Typography.Link\n className={style[\"link\"]}\n href={data.url}\n target=\"_blank\"\n >\n 查看帮助\n <Icon type=\"icon-shuangjiantou-right\" />\n </Typography.Link>\n )}\n </Space>\n </div>\n )\n );\n }}\n </Enum>\n </IntlProvider>\n );\n};\n\nexport default HelperGuide;\n"],"names":["preset","base","transform","value","description","result","locale","en-US","zh-CN","_ref","name","className","_jsx","IntlProvider","importMessages","moduleName","children","Enum","data","classnames","style","_jsxs","Space","Icon","colorful","type","content","url","Typography","Link","href","target"],"ignoreList":[],"sourceRoot":""}
@@ -1,2 +1,2 @@
1
- "use strict";(self.webpackChunk_kne_components_components_core=self.webpackChunk_kne_components_components_core||[]).push([[3856],{3382(e,t,n){n.r(t),n.d(t,{ModalButton:()=>V,TabsModal:()=>M,TabsModalButton:()=>z,default:()=>L,useConfirmModal:()=>Q,useModal:()=>O,useTabsModal:()=>R});var a=n(89379),l=n(53986),s=n(73884),r=n(55199),o=n(83136),i=n.n(o);const c={modal:"style_modal__Pm3cF__-0IeQ",large:"style_large__iaqVE__-0IeQ","modal-body-inner":"style_modal-body-inner__4PhpA__-0IeQ","modal-title":"style_modal-title__dswaw__-0IeQ","modal-outer":"style_modal-outer__r3SkX__-0IeQ","modal-body":"style_modal-body__jQJSI__-0IeQ","right-options-modal":"style_right-options-modal__FajDP__-0IeQ","right-options-row":"style_right-options-row__-mPb9__-0IeQ","right-options-col":"style_right-options-col__3ilee__-0IeQ","is-disabled-scroller":"style_is-disabled-scroller__PmHyk__-0IeQ",content:"style_content__k6MIF__-0IeQ","modal-footer":"style_modal-footer__-prbN__-0IeQ","modal-close":"style_modal-close__Oa5Kl__-0IeQ","confirm-modal-wrap":"style_confirm-modal-wrap__YFImr__-0IeQ","is-danger":"style_is-danger__H5110__-0IeQ",title:"style_title__orTym__-0IeQ","has-title":"style_has-title__qy0Wp__-0IeQ"},d=e=>({"en-US":()=>n.e(4628).then(n.bind(n,74628)),"zh-CN":()=>n.e(7478).then(n.bind(n,87478))}[e]());var u=n(47458),p=n(64671);const m=(e,t)=>"function"===typeof e?e(t):e;var h=n(81014),_=n(17342),g=n(70579);const f=["ButtonComponent","onClick","autoClose","display"],x=["children","rightOptions","rightSpan","footer","footerButtons","className","size","title","onClose","onConfirm","confirmText","onCancel","cancelText","closable","disabledScroller","withDecorator","childrenRef"],A=["size"],y=["children"],v=["type","icon","title","danger","wrapClassName","message","iconSetting","confirmType"],C="Modal",j=e=>{let{options:t,rightSpan:n=6,children:a}=e;return t?(0,g.jsxs)(r.Row,{wrap:!1,className:c["right-options-row"],children:[(0,g.jsx)(r.Col,{span:24-n,className:c["right-options-col"],children:a}),(0,g.jsx)(r.Col,{span:n,className:c["right-options-col"],children:t})]}):a},b=(e,t)=>"".concat(e-48-(t?58:0),"px"),N=e=>{let{footer:t,footerButtons:n,onConfirm:o,onCancel:i,cancelText:c,onClose:p,targetProps:m}=e;return(0,g.jsxs)(r.Row,{gutter:10,wrap:!1,children:[(0,g.jsx)(r.Col,{flex:1,children:t}),Array.isArray(n)&&0===n.length?null:(0,g.jsx)(r.Col,{children:(0,g.jsx)(r.Space,{children:(n||[{children:c||(0,g.jsx)(u.IntlProvider,{importMessages:d,moduleName:C,children:(0,g.jsx)(u.FormattedMessage,{id:"Cancel",moduleName:C})}),onClick:i},{type:"primary",children:(0,g.jsx)(u.IntlProvider,{importMessages:d,moduleName:C,children:(0,g.jsx)(u.FormattedMessage,{id:"Confirm",moduleName:C})}),onClick:o}]).filter(e=>"function"===typeof(null===e||void 0===e?void 0:e.display)?null===e||void 0===e?void 0:e.display():!1!==(null===e||void 0===e?void 0:e.display)).map((e,t)=>{let{ButtonComponent:n,onClick:r,autoClose:o=!0,display:i}=e,c=(0,l.A)(e,f);const d=n||h.default;return(0,s.createElement)(d,(0,a.A)((0,a.A)({},c),{},{key:t,onClick:async function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];const a=await Promise.resolve(r&&r(...t,m));return o&&!1!==a&&p&&p(),a}}))})})})]})},I=e=>{let{title:t,footer:n,disabledScroller:a,footerButtons:l,onClose:o,closable:d,onConfirm:u,onCancel:m,children:h,targetProps:f,cancelText:x,confirmText:A}=e;const y=(0,s.useRef)(null);return(0,g.jsxs)("div",{className:i()(c["modal-outer"],"modal-container"),"data-testid":"components-core-modal",children:[!1===d?null:(0,g.jsx)(r.Button,{"data-testid":"components-core-modal-close-btn",className:i()(c["modal-close"],"modal-close"),type:"text",icon:(0,g.jsx)(p.default,{type:"icon-close-thin"}),onClick:e=>{e.stopPropagation(),o&&o()}}),t&&(0,g.jsx)("div",{className:c["modal-title"],children:t}),(0,g.jsx)(_.A,{className:i()(c["modal-body"],{[c["is-disabled-scroller"]]:a},"modal-body"),ref:y,children:(0,g.jsx)("div",{className:i()(c["modal-body-inner"],"modal-body-inner"),children:h})}),null!==n||l?(0,g.jsx)("div",{className:i()(c["modal-footer"],"modal-footer"),children:(0,g.jsx)(N,{footer:n,footerButtons:l,onConfirm:u,confirmText:A,onCancel:m,cancelText:x,onClose:o,targetProps:f})}):null]})},S=e=>{let{withDecorator:t,footerButtons:n,title:l,closable:s,onClose:r,onConfirm:o,confirmText:i,onCancel:c,cancelText:d,footer:u,rightOptions:p,rightSpan:h,disabledScroller:_,childrenRef:f,children:x}=e;const A=e=>(e=Object.assign({},{title:l},e),(0,g.jsx)(I,{title:m(e.title,(0,a.A)((0,a.A)({},e),{},{childrenRef:f,close:r})),closable:s,onClose:r,onConfirm:o,confirmText:i,onCancel:c,cancelText:d,footerButtons:m(n,(0,a.A)((0,a.A)({},e),{},{close:r})),disabledScroller:_,footer:m(u,(0,a.A)((0,a.A)({},e),{},{childrenRef:f,close:r})),targetProps:Object.assign({},e,{childrenRef:f,close:r}),children:(0,g.jsx)(j,{rightSpan:h,options:m(p,(0,a.A)((0,a.A)({},e),{},{childrenRef:f,close:r})),children:m(x,(0,a.A)((0,a.A)({},e),{},{childrenRef:f,close:r}))})}));return"function"===typeof t?t(A,{childrenRef:f,close:r}):A({})},w=e=>{let{children:t,rightOptions:n,rightSpan:s,footer:r,footerButtons:o,className:p,size:m,title:h,onClose:_,onConfirm:f,confirmText:A,onCancel:y,cancelText:v,closable:C,disabledScroller:j,withDecorator:N,childrenRef:I}=e,w=(0,l.A)(e,x);return(0,a.A)((0,a.A)((0,a.A)({},w),{},{icon:null,centered:!0,title:null,maskClosable:!!w.hasOwnProperty("maskClosable")&&w.maskClosable,destroyOnHidden:!0,footer:null,closable:!1,onCancel:_,className:i()(p,c.modal,c[m],{[c["right-options-modal"]]:n})},((e,t)=>"large"===e?{width:"".concat(Math.min(window.innerWidth-64,1500),"px"),style:{"--min-modal-height":b(500,t)}}:"small"===e?{width:"600px",style:{"--min-modal-height":b(300,t)}}:{width:"1000px",style:{"--min-modal-height":b(500,t)}})(m,!(null===r&&!o))),{},{children:(0,g.jsx)(u.IntlProvider,{importMessages:d,moduleName:"Modal",children:S({withDecorator:N,title:h,closable:C,onClose:_,onConfirm:f,confirmText:A,onCancel:y,cancelText:v,footer:r,footerButtons:o,rightOptions:n,rightSpan:s,disabledScroller:j,children:t,childrenRef:I})})})},O=()=>{const{modal:e}=r.App.useApp(),t=(0,s.useRef)(null);return n=>{const s={},r=w((0,a.A)({onClose:()=>s.close(),childrenRef:t},n)),{children:o}=r,i=(0,l.A)(r,y),{destroy:c}=e.info((0,a.A)((0,a.A)({},i),{},{content:o}));return s.close=c,s}},Q=()=>{const{modal:e}=r.App.useApp();return t=>{const n={},s=(0,a.A)({onClose:()=>n.close(),maskClosable:!1},t),{type:o,icon:d,title:u,danger:m,wrapClassName:h,message:_,iconSetting:f={},confirmType:x="info"}=s,A=(0,l.A)(s,v),y=Object.assign({},{info:"icon-xinxi-tianchong",confirm:"icon-tishi-tianchong",warning:"icon-tishi-tianchong",error:"icon-shibai",success:"icon-chenggong"},f);if(e[o]){const{destroy:t}=e[o]((0,a.A)((0,a.A)({},A),{},{icon:null,wrapClassName:i()(c["confirm-modal-wrap"],h,{[c["is-danger"]]:m}),title:(0,g.jsx)(r.Space,{orientation:"vertical",onClick:e=>{e.stopPropagation()},children:u&&(0,g.jsxs)(r.Space,{size:0,align:"start",className:c.title,children:[m?(0,g.jsx)(p.default,{className:i()("title-icon","title-icon-".concat("confirm"===o?x:o)),type:d||y["confirm"===o?x:o]}):null,u]})}),content:(0,g.jsxs)(r.Space,{size:0,align:"start",className:i()(c.content,{[c["has-title"]]:u}),children:[!u&&m?(0,g.jsx)(p.default,{className:i()("title-icon","title-icon-".concat("confirm"===o?x:o)),type:d||y["confirm"===o?x:o]}):null,_]})}));n.close=t}return n}},L=e=>{let{size:t="default"}=e,n=(0,l.A)(e,A);const o=(0,s.useRef)(null);return(0,g.jsx)(r.Modal,(0,a.A)({},w(Object.assign({},n,{size:t,childrenRef:o}))))},P=["items","className","activeKey","withDecorator","defaultActiveKey","onChange"],k=["withDecorator"],F=["children"],T=e=>{let{items:t,className:n,activeKey:s,withDecorator:o,defaultActiveKey:c,onChange:d}=e,u=(0,l.A)(e,P);return(0,a.A)((0,a.A)({},u),{},{className:i()(n,"tabs-modal"),withDecorator:e=>{const n=n=>(0,g.jsx)(r.Tabs,{items:t.map(t=>{let{withDecorator:a}=t,s=(0,l.A)(t,k);return Object.assign({},s,{children:"function"===typeof a?a(t=>e(Object.assign({},n,t,{children:s.children}))):e(Object.assign({},n,{children:s.children}))})}),destroyInactiveTabPane:!0,activeKey:s,defaultActiveKey:c,onChange:d});return"function"===typeof o?o(n):n()},children:e=>{let{children:t}=e,n=(0,l.A)(e,F);return"function"===typeof t?t(n):t}})},M=e=>(0,g.jsx)(L,(0,a.A)({},T(e))),R=()=>{const e=O();return t=>e(T(t))};var D=n(73025);const E=["modalProps"],z=e=>{const t=R();return e.api?(0,g.jsx)(D.A,(0,a.A)((0,a.A)({},e),{},{modalFunc:t})):(0,g.jsx)(r.Button,(0,a.A)((0,a.A)({},e),{},{onClick:()=>{t(e.modalProps)}}))},V=e=>{const t=O();if(!e.api){const{modalProps:n}=e,s=(0,l.A)(e,E);return(0,g.jsx)(r.Button,(0,a.A)((0,a.A)({},s),{},{onClick:()=>{t(n)}}))}return(0,g.jsx)(D.A,(0,a.A)((0,a.A)({},e),{},{modalFunc:t}))}},12392(e,t,n){n.d(t,{Bm:()=>B,Eo:()=>W,NR:()=>S,Ay:()=>U});var a=n(55199),l=n(83136),s=n.n(l),r=n(89379),o=n(53986),i=n(30509),c=n(25438),d=n(78784),u=n(33097),p=n.n(u),m=n(34677),h=n.n(m);const _="create-list_scroll-loader__zoaS7__-0IeQ",g="create-list_is-popup__t3d-G__-0IeQ",f="create-list_is-not-full__FXtX1__-0IeQ",x="create-list_search-input__tV3vf__-0IeQ",A="create-list_left__EXr3i__-0IeQ",y="create-list_list-header__3xeJa__-0IeQ",v="create-list_is-modal__BMfya__-0IeQ";var C=n(73161),j=n(47458),b=n(70579);const N=["extra"],I=i.A.useContext,S=e=>{let{renderList:t,defaultProps:n}=e;const l=e=>{let{value:n,setValue:l}=e;const{fetchApi:r,searchText:o,setSearchText:i,props:u,mapping:m}=I(),N=Object.assign({},{paramsType:"data",current:"currentPage",pageSizeName:"perPage",pageSize:20},u.pagination),S=p()(r.requestParams,[N.paramsType,N.current],1),w=p()(r.requestParams,[N.paramsType,N.pageSizeName])||N.pageSize,{formatMessage:O}=(0,j.useIntl)({moduleName:"Common"}),Q=u.dataFormat(r.data),{right:L,leftBottom:P,leftSpan:k=24}=u,F=1===n.length&&"all"===n[0];return(0,b.jsxs)(a.Row,{wrap:!1,className:L?s()("is-not-full",f):"",children:[(0,b.jsxs)(a.Col,{span:k,className:s()(A,"advance-select-left"),children:[u.getSearchProps?(0,b.jsx)(C.A,{isPopup:u.isPopup,className:s()(x,c.A["search-input"],{[c.A["is-popup"]]:u.isPopup}),placeholder:u.searchPlaceholder||O({id:"search"}),value:o,onSearch:e=>{r.reload(u.getSearchProps(e)),i(e)}}):null,u.single||!u.showSelectedCount&&!u.allowSelectAll?null:(0,b.jsxs)(a.Flex,{className:s()(y,{[v]:!u.isPopup}),justify:"space-between",children:[u.showSelectedCount?(0,b.jsxs)(a.Space,{children:[(0,b.jsx)(a.Typography,{children:"\u5df2\u9009:"}),(0,b.jsx)(a.Typography.Link,{children:F?u.allLabel||(0,b.jsx)(j.FormattedMessage,{id:"all",moduleName:"Common"}):"".concat(n.length).concat(u.countUnit||O({id:"items"}))})]}):(0,b.jsx)("div",{}),u.allowSelectAll?(0,b.jsx)("div",{children:(0,b.jsx)(a.Checkbox,{checked:F,onChange:e=>{l(e.target.checked?[u.allValue||"all"]:[])},children:(0,b.jsx)(j.FormattedMessage,{id:"selectAll",moduleName:"Common",values:{label:u.allLabel||(0,b.jsx)(j.FormattedMessage,{id:"all",moduleName:"Common"})}})})}):(0,b.jsx)("div",{})]}),(0,b.jsx)(d.default,{completeTips:"",isLoading:!r.isComplete,className:s()(_,{[g]:u.isPopup}),noMore:!Q.total||S*w>=Q.total,onLoader:async()=>{console.log("on loader"),await r.loadMore(h()({[N.paramsType]:{[N.pageSizeName]:w,[N.current]:S+1}},u.getSearchProps&&u.getSearchProps(o)),u.mergeList)},children:(()=>{const e={props:u,value:n,setValue:l,list:Q.list,data:r.data,fetchApi:r,itemIsSelected:e=>n.indexOf(e.value)>-1,isSelectedAll:F,onSelect:e=>{if(u.single)return void l([e.value]);const t=n.slice(0),a=t.indexOf(e.value);a>-1?t.splice(a,1):t.push(e.value),l(t)}},a=t(e);return"function"===typeof u.dropdownRender?u.dropdownRender(Object.assign({},e,{children:a})):a})()}),P&&P({fetchApi:r,value:n,mapping:m})]}),L&&L({value:n,mapping:m,fetchApi:r})]})};return e=>{const t=Object.assign({},{isPopup:!0,pagination:{},mergeList:(e,t)=>Object.assign({},t,{pageData:e.pageData.concat(t.pageData)}),dataFormat:e=>({list:e.pageData,total:e.totalCount})},n,e),{extra:a}=t,s=(0,o.A)(t,N);return(0,b.jsx)(i.A,(0,r.A)((0,r.A)({},s),{},{extra:a,children:e=>{let{value:t,setValue:n}=e;return(0,b.jsx)(l,{value:t,setValue:n})}}))}},w="list_list__TGynD__-0IeQ",O="list_list-item__WSswf__-0IeQ",Q="list_is-selected__6Wkgt__-0IeQ",L="list_item-label__bYzhe__-0IeQ",P="list_item-des__2nsEn__-0IeQ",k="list_is-disabled__qxCvO__-0IeQ",F="list_is-selected-all__Mp-hG__-0IeQ";var T=n(40438),M=n(64671);const R="user_list-inner__V508e__-0IeQ",D="user_list-info__y2nWo__-0IeQ",E="user_selected-icon__9OQJL__-0IeQ",z="user_item-des__o+7UR__-0IeQ",V="user_is-selected-all__2q0VZ__-0IeQ",W=S({renderList:e=>{let{list:t,onSelect:n,itemIsSelected:l,isSelectedAll:o}=e;return(0,b.jsx)(a.List,{size:"small",className:s()(w,{[F]:o,[V]:o}),dataSource:t,renderItem:e=>{const t=l(e);return(0,b.jsx)(a.List.Item,{className:s()(O,{[Q]:t}),onClick:()=>n(e),children:(0,b.jsxs)(a.Row,{wrap:!1,align:"middle",className:R,children:[(0,b.jsx)(a.Col,{children:(0,b.jsx)(T.default.Avatar,(0,r.A)((0,r.A)({},Object.assign({},e.avatar)),{},{size:40,gender:"M"}))}),(0,b.jsx)(a.Col,{className:D,flex:1,children:(0,b.jsxs)(a.Space,{direction:"vertical",children:[(0,b.jsx)("span",{className:L,children:e.label}),e.description&&(0,b.jsx)("span",{className:z,children:e.description})]})}),(0,b.jsx)(a.Col,{children:o||t?(0,b.jsx)(M.default,{className:E,type:"icon-gouxuan"}):null})]})})}})}}),K={"is-selected-all":"table_is-selected-all__IwXUY__-0IeQ"},B=S({defaultProps:{overlayWidth:"450px"},renderList:e=>{let{props:t,list:n,onSelect:l,value:r,setValue:o,itemIsSelected:i,isSelectedAll:c}=e;return(0,b.jsx)(a.Table,{className:s()(K.list,w,{[F]:c,[K["is-selected-all"]]:c}),size:"small",dataSource:n,columns:t.columns,rowClassName:e=>s()({"ant-table-row-selected":i(e)}),rowKey:t.rowKey||"value",pagination:!1,rowSelection:t.single?null:c?{selectedRowKeys:n.map(e=>{let{value:t}=e;return t}),getCheckboxProps:()=>({disabled:!0})}:{selectedRowKeys:r,onChange:e=>{o(e)}},sticky:!0,onRow:e=>({onClick:()=>l(e)})})}}),U=S({renderList:e=>{let{props:t,list:n,itemIsSelected:l,isSelectedAll:r,onSelect:o}=e;const{listClassName:i="",selectIcon:c=null}=t||{};return(0,b.jsx)(a.List,{className:s()(w,i,{[F]:r}),size:"small",dataSource:n,renderItem:e=>{var n;const i=l(e);return(0,b.jsxs)(a.List.Item,{className:s()(O,{[Q]:t.single&&i,[k]:r||e.disabled}),onClick:()=>{e.disabled||o(e)},children:[(0,b.jsxs)(a.Row,{wrap:!1,children:[t.single?null:(0,b.jsx)(a.Col,{children:(0,b.jsx)(a.Checkbox,{checked:r||i,disabled:r||e.disabled})}),(0,b.jsx)(a.Col,{children:(0,b.jsxs)(a.Space,{className:null!==(n=null===e||void 0===e?void 0:e.className)&&void 0!==n?n:"",children:[(0,b.jsx)("span",{className:L,children:e.label}),e.description&&(0,b.jsx)("span",{className:P,children:e.description})]})})]}),i&&c]})}})}})},17342(e,t,n){n.d(t,{A:()=>s});var a=n(34581),l=n.n(a);n(46733);const s=l()},17508(e,t,n){n.d(t,{AG:()=>y,Ay:()=>f,FI:()=>A,Zi:()=>x,lN:()=>s.useFileUpload});var a=n(89379),l=n(53986),s=n(61323),r=n(55199),o=n(83136),i=n.n(o),c=n(70579);const d=["className","multiple","accept","onChange","children"],u=["children"],p=["children"],m=["className","multiple","accept","onChange","children"],h=["children"],_=["className","multiple","accept","onChange","children"],g=["children"],f=e=>t=>{let{className:n,multiple:r,accept:o,onChange:i,children:p}=t,m=(0,l.A)(t,d);return(0,c.jsx)(s.FileInput,{className:n,multiple:r,accept:o,onChange:i,children:t=>{let{children:n}=t,s=(0,l.A)(t,u);return(0,c.jsxs)(e,(0,a.A)((0,a.A)({},Object.assign({},m,s)),{},{children:[p,n]}))}})},x=e=>{let{children:t}=e,n=(0,l.A)(e,p);return(0,c.jsx)(s.FileInput,(0,a.A)((0,a.A)({},n),{},{buttonText:t}))},A=e=>{let{className:t,multiple:n,accept:o,onChange:i,children:d}=e,u=(0,l.A)(e,m);return(0,c.jsx)(s.FileInput,{className:t,multiple:n,accept:o,onChange:i,children:e=>{let{children:t}=e,n=(0,l.A)(e,h);return(0,c.jsxs)(r.Typography.Link,(0,a.A)((0,a.A)({},Object.assign({},u,n)),{},{children:[d,t]}))}})},y=e=>{let{className:t,multiple:n,accept:o,onChange:d,children:u}=e,p=(0,l.A)(e,_);return(0,c.jsx)(s.FileInput,{className:i()(t,"ant-btn"),multiple:n,accept:o,onChange:d,children:e=>{let{children:t}=e,n=(0,l.A)(e,g);return(0,c.jsxs)(r.Typography.Text,(0,a.A)((0,a.A)({},Object.assign({},p,n)),{},{children:[u,t]}))}})}},18411(e,t,n){n.d(t,{A:()=>a});n(73884);const a=n.p+"static/media/defaultAvatar.b1f2a8046cc7bee36d9a404ce6a0a1d7.svg"},20492(e,t,n){n.d(t,{A:()=>a});const a=e=>({"en-US":()=>n.e(3086).then(n.bind(n,13086)),"zh-CN":()=>n.e(4308).then(n.bind(n,84308))}[e]())},21485(e,t,n){n.d(t,{A:()=>p});var a=n(89379),l=n(53986),s=n(73884),r=n(71298),o=n.n(r),i=n(96418),c=n.n(i),d=n(70579);const u=["children","onScroll","options","onReady"],p=(0,s.forwardRef)((e,t)=>{let{children:n,onScroll:r,options:i,onReady:p}=e,m=(0,l.A)(e,u);const h=(0,s.useRef)(null),_=(0,s.useRef)(null),g=(0,s.useRef)(i),f=c()(p),x=c()(r);return(0,s.useImperativeHandle)(t,()=>_.current),(0,s.useEffect)(()=>{const e=new(o())(h.current,g.current);return _.current=e.getScrollElement(),_.current.addEventListener("scroll",x),f(_.current),()=>{_.current.removeEventListener("scroll",x)}},[x,f,n]),(0,d.jsx)("div",(0,a.A)((0,a.A)({},m),{},{ref:h,children:n}))})},25438(e,t,n){n.d(t,{A:()=>a});const a={"search-input":"common_search-input__P6qLg__-0IeQ","is-popup":"common_is-popup__fJq+g__-0IeQ",list:"common_list__TKFzS__-0IeQ","list-item":"common_list-item__ASse7__-0IeQ","is-selected":"common_is-selected__-PU4Y__-0IeQ","item-label":"common_item-label__u+qz1__-0IeQ","item-des":"common_item-des__no2z0__-0IeQ"}},27047(e,t,n){n.d(t,{A:()=>r});var a=n(83694),l=n(33097),s=n.n(l);const r=()=>{const e=(0,a.useGlobalContext)();return s()(e,"preset",{apis:{}})}},30509(e,t,n){n.d(t,{A:()=>H});var a=n(89379),l=n(53986);const s={"ant-tag":"style_ant-tag__nNp8-__-0IeQ",overlay:"style_overlay__La5mO__-0IeQ",input:"style_input__SpJTE__-0IeQ","is-disabled":"style_is-disabled__joxdl__-0IeQ","input-icon":"style_input-icon__vVd8R__-0IeQ",large:"style_large__En6mL__-0IeQ",small:"style_small__DY0AQ__-0IeQ","input-inner":"style_input-inner__PWy27__-0IeQ","input-custom":"style_input-custom__ktsWD__-0IeQ","display-content":"style_display-content__hIKo+__-0IeQ","overlay-footer-extra":"style_overlay-footer-extra__Q+BiR__-0IeQ","selected-tag":"style_selected-tag__zXZZO__-0IeQ","selected-tag-list":"style_selected-tag-list__xUIms__-0IeQ","selected-tag-inner":"style_selected-tag-inner__Z5gPL__-0IeQ","text-inner":"style_text-inner__H24hY__-0IeQ",placeholder:"style_placeholder__x0ccE__-0IeQ","is-modal":"style_is-modal__JU+uq__-0IeQ","overlay-content":"style_overlay-content__WKqp+__-0IeQ"};var r=n(74981);const{context:o,useContext:i,Provider:c,Consumer:d}=(0,r.A)();var u=n(73884),p=n(10986),m=n.n(p),h=n(87558),_=n(33097),g=n.n(_),f=n(55199),x=n(83136),A=n.n(x),y=n(3382),v=n(64671),C=n(79686),j=n.n(C),b=n(41740),N=n.n(b),I=n(74065),S=n.n(I),w=n(21485),O=n(96418),Q=n.n(O),L=n(77964),P=n(91176),k=n(47458),F=n(20492),T=n(27047),M=n(70579);const R=["value","onChange","extra","showSelectedTag","renderSelectedContent","children"],D=["value","setValue","children","renderSelectedContent","showSelectedTag","placement","inputContent","single","extra","overlayWidth","wrapClassName","overlayClassName","disabled"],E=["setFetchApi","wrapClassName","getContentRef"],z=["api","className","displayItems","wrapClassName"],V=e=>{let{maxLength:t,single:n,setValue:a,value:l,message:s}=e;return e=>a(!n&&Number.isInteger(t)&&t>0&&e.length>t?(s(),l):e)},W=e=>{let{single:t,value:n,mapping:a,allValue:l,allLabel:r,onClose:o}=e;return n&&Array.isArray(n)&&0!==n.length?t?(0,M.jsx)("span",{className:s["text-inner"],children:g()(a.get(n[0]),"label")||n[0]}):1===n.length&&n[0]===(l||"all")?(0,M.jsx)("span",{className:s["text-inner"],children:r||(0,M.jsx)(k.FormattedMessage,{id:"all",moduleName:"Common"})}):n.map(e=>{const t=a.get(e);return(0,M.jsx)(f.Tag,{className:s["display-tag"],closable:!0,onClose:n=>{n.preventDefault(),o(e,t)},children:(0,M.jsx)("span",{className:s["tag-inner"],children:g()(t,"label")||e})},e)}):null},K=(0,u.forwardRef)((e,t)=>{let{value:n,onChange:r,extra:o,showSelectedTag:i,renderSelectedContent:c,children:d}=e,p=(0,l.A)(e,R);const[m,h]=(0,u.useState)(n),_=(0,u.useRef)(n),{formatMessage:g}=(0,k.useIntl)({moduleName:"Common"});_.current=n;const[x,A]=(0,u.useState)(!1),v=e=>{var t;A(e),null===(t=p.onOpenChange)||void 0===t||t.call(p,e)},{message:C}=f.App.useApp(),j=V({maxLength:p.maxLength,single:p.single,setValue:h,value:m,message:()=>C.error(g({id:"maxSelectedCount"},{count:p.maxLength}))});return(0,u.useEffect)(()=>{x&&h(_.current)},[x]),(0,u.useImperativeHandle)(t,()=>({modalOpen:()=>{v(!0)},close:()=>{v(!1)}})),(0,M.jsx)(y.default,(0,a.A)((0,a.A)({},p),{},{open:x,onConfirm:()=>{r(m)},onClose:()=>{v(!1)},footer:(0,M.jsxs)(f.Space,{direction:"vertical",className:s["overlay-footer"],children:[o&&(0,M.jsx)("div",{className:s["overlay-footer-extra"],children:o}),i&&c({value:m,setValue:j})]}),children:"function"===typeof d?d({value:m,setValue:j}):d}))}),B=(0,u.forwardRef)((e,t)=>{let{value:n,setValue:r,children:o,renderSelectedContent:i,showSelectedTag:c,placement:d,inputContent:p,single:m,extra:h,overlayWidth:_,wrapClassName:g,overlayClassName:x,disabled:y}=e,v=(0,l.A)(e,D);const[C,j]=(0,u.useState)(!1),b=Q()(e=>{var t;j(e),null===(t=v.onOpenChange)||void 0===t||t.call(v,e)});return(0,u.useImperativeHandle)(t,()=>({close:()=>{b(!1)}}),[b]),y?(0,M.jsx)("div",{className:s["input-inner"],children:p}):(0,M.jsx)(f.Popover,(0,a.A)((0,a.A)({},v),{},{open:C,onOpenChange:b,transitionName:"ant-slide-up",overlayClassName:A()(s.overlay,x),arrow:!1,content:(0,M.jsxs)("div",{style:_?{"--overlay-width":_}:{},className:A()(s["overlay-content"],"over-content"),onClick:e=>{e.stopPropagation()},children:[(0,M.jsx)("div",{className:s["overlay-inner"],children:"function"===typeof o?o({value:n,setValue:e=>{(!m||n[0]!==e[0])&&r(e),m&&b(!1)}}):o}),(c||h)&&(0,M.jsxs)("div",{className:s["overlay-footer"],children:[h&&(0,M.jsx)("div",{className:s["overlay-footer-extra"],children:h}),c&&i({value:n,setValue:r})]})]}),trigger:"click",placement:d,children:(0,M.jsx)("div",{className:s["input-inner"],children:p})}))}),U=(0,h.withFetch)(e=>{let{setFetchApi:t,wrapClassName:n,getContentRef:a}=e,r=(0,l.A)(e,E);const[o,c]=(0,u.useState)(!1),d=(0,u.useRef)(null),p=(0,u.useRef)(null),m=i(),{valueState:h,mapping:_,props:g,inputWidth:x}=m,[y,C]=h,{formatMessage:j}=(0,k.useIntl)({moduleName:"Common"}),{single:b,placement:N,getPopupContainer:I,placeholder:S,isPopup:O,disabled:L,showSelectedTag:F,extra:T,inputContent:R,allowClear:D,overlayClassName:z}=g,V=(0,u.useRef)(r);V.current=r;const U=Q()(a);(0,u.useEffect)(()=>{U(O?p:d)},[O,U]),(0,u.useEffect)(()=>{t(Object.assign({},V.current,{data:r.data,isComplete:r.isComplete}))},[r.data,t,r.isComplete]);const q=W({single:b,value:y,mapping:_,allValue:g.allValue,allLabel:g.allLabel,onClose:e=>{C(t=>{const n=t.slice(0),a=t.indexOf(e);return a>-1&&n.splice(a,1),n})}}),H=e=>{let{value:t,setValue:n}=e;return(0,M.jsxs)(f.Space,{className:s["selected-tag"],align:"center",wrap:!1,children:[(0,M.jsxs)("div",{children:[(0,M.jsx)(k.FormattedMessage,{id:"selectedTextAdvanced",moduleName:"Common",defaultMessage:"\u5df2\u9009"}),!g.single&&Number.isInteger(g.maxLength)&&g.maxLength>0?"(".concat(t.length,"/").concat(g.maxLength,")"):"",":"]}),(0,M.jsx)(w.A,{className:s["selected-tag-list"],children:(0,M.jsx)("div",{className:s["selected-tag-inner"],children:W({value:t,mapping:_,allValue:g.allValue,allLabel:g.allLabel,onClose:e=>{n(t=>{const n=t.slice(0),a=t.indexOf(e);return a>-1&&n.splice(a,1),n})}})})})]})},X=R?R(m):(0,M.jsxs)(f.Space,{className:s["display-content"],onMouseOver:()=>{c(!0)},onMouseOut:()=>{c(!1)},children:[(0,M.jsx)("div",{children:q||(0,M.jsx)("span",{className:s.placeholder,children:S||j({id:"pleaseSelect"})})}),o&&y&&y.length>0&&!L&&D?(0,M.jsx)(v.default,{className:A()(s.close,s["input-icon"],"close","input-icon"),type:"icon-shibai",onClick:e=>{e.stopPropagation(),C([])}}):(0,M.jsx)(v.default,{className:A()(s["input-icon"],"input-icon-arrow","input-icon"),type:"icon-arrow-thin-down"})]});return O?(0,M.jsx)(B,{ref:p,overlayWidth:(0,P.v)(Math.max(x,(0,P.j)(g.overlayWidth))),value:y,setValue:C,single:b,disabled:L,inputContent:X,onOpenChange:g.onOpenChange,overlayClassName:z,extra:"function"===typeof T?T({close:()=>p.current.close(),context:m}):T,renderSelectedContent:H,showSelectedTag:F,trigger:"click",placement:N,getPopupContainer:I,children:g.children}):(0,M.jsxs)("div",{className:s["input-inner"],onClick:()=>{L||d.current.modalOpen()},children:[(0,M.jsx)(K,{size:g.modalSize,ref:d,single:g.single,maxLength:g.maxLength,onOpenChange:g.onOpenChange,disabledScroller:!0,wrapClassName:A()(s.overlay,s["is-modal"],n),title:g.placeholder||j({id:"pleaseSelect"}),value:y,onChange:C,extra:"function"===typeof T?T({close:()=>d.current.close(),context:m}):T,showSelectedTag:F,renderSelectedContent:H,children:g.children}),X]})}),q=(0,k.createWithIntl)({importMessages:F.A,moduleName:"Common"})(e=>{const t=Object.assign({},{displayItems:[],extra:null,api:{loader:()=>[]},dataFormat:e=>({list:e}),placement:"bottomLeft",showSelectedTag:!0,allowClear:!0},e),{api:n,className:r,displayItems:o,wrapClassName:i}=t,d=(0,l.A)(t,z),{locale:p}=(0,T.A)(),[h,_]=(0,u.useState)(""),[x,y]=(0,u.useState)(new Map(o.map(e=>[e.value,e]))),{formatMessage:v}=(0,k.useIntl)({moduleName:"Common"}),[C,b]=(0,u.useState)(0),I=(0,L.A)(e=>{b(e.clientWidth)}),[w,O]=(0,u.useState)({}),{message:Q}=f.App.useApp(),P=e=>{const t=e.filter(e=>x.get(e.value)!==e);0!==t.length&&y(e=>{const n=N()(e);return t.forEach(e=>{n.set(e.value,e)}),n})},F=e=>((e,t)=>Array.isArray(e)&&e.every(e=>e&&e.hasOwnProperty("value")&&e.hasOwnProperty("label"))?(t(e),e.map(e=>e.value)):e)(d.single?j()(e)?[]:[e]:e||[],P,d.valueType),[R,D]=m()(Object.assign({},d,{onChange:e=>{const t=((e,t,n)=>"all"!==n?e:e.map(e=>t.get(e)).filter(e=>!!e))(e,x,d.valueType);d.onChange&&d.onChange(d.single?S()(t):t)}},"value"in d?{value:F(d.value)}:{defaultValue:F(d.defaultValue)})),E=V({maxLength:d.maxLength,single:d.single,setValue:D,value:R,message:()=>Q.error(v({id:"maxSelectedCount"},{count:d.maxLength}))}),W=(0,u.useRef)(null);return(0,M.jsx)(c,{value:{inputWidth:C,mapping:x,searchText:h,setSearchText:_,appendMapping:P,setItems:e=>{w.setData(e),P(g()(d.dataFormat(e,{locale:p}),"list",[]))},getContentApi:()=>W.current,fetchApi:w,valueState:[R,E],props:d},children:(0,M.jsx)("div",{ref:I,className:A()(s["input".concat(d.inputContent&&"function"===typeof d.inputContent?"-custom":"")],{"select-input-disabled":!!d.disabled},r),children:(0,M.jsx)(U,(0,a.A)((0,a.A)({},n),{},{wrapClassName:i,loading:null,setFetchApi:O,getContentRef:e=>{e.current&&(W.current=e.current)},onRequestSuccess:e=>{P(g()(d.dataFormat(e,{locale:p}),"list",[])),n.onRequestSuccess&&n.onRequestSuccess(e)}}))})})});q.useContext=i;const H=q},40438(e,t,n){n.r(t),n.d(t,{default:()=>S});var a=n(89379),l=n(53986),s=n(87558),r=n.n(s),o=n(97211),i=n(64671),c=n(83136),d=n.n(c),u=n(55199),p=n(73884);const m=e=>{let{params:t}=e;const{data:n}=t;return new Promise((e,t)=>{const a=new window.Image;a.src=n,a.addEventListener("load",()=>{e(n)}),a.addEventListener("error",e=>{t(e)})})},h="style_img-outer__4QLY5__-0IeQ",_="style_img__PSExq__-0IeQ",g="style_loading__WCOwA__-0IeQ",f="style_error__+ECgZ__-0IeQ";var x=n(18411),A=n(72752),y=n(70579);const v=["id","src","alt","onClick","loading","error","className","apis"],C=["id","src","alt","gender","loading","error","className","gap","icon","children","shape","size","width","height","defaultAvatar","apis"],j=e=>{let{data:t,className:n,alt:a,innerLoading:l,loading:s=(0,y.jsx)(u.Skeleton.Avatar,{shape:"square",active:!0}),error:o=(0,y.jsx)(i.default,{role:"error-icon",colorful:!0,type:"icon-color-touxiang-nan"}),innerError:c,children:p,onClick:h,staticUrl:g}=e;const{staticUrl:f}=(0,A.usePreset)(),x=g||f||"";return(0,y.jsx)(r(),{loader:m,params:{data:/^https?:\/\//.test(t)?t:x+t},error:c||o,loading:l||s,render:e=>{let{data:t}=e;return"function"===typeof p?p({alt:a,className:d()(n,_),src:t}):(0,y.jsx)("img",{alt:a,className:d()(n,_),src:t,onClick:h})}})},b=(0,o.A)(j),N=e=>{let{loading:t,error:n,src:a,id:l,alt:s,className:r,children:o,apis:i,onClick:c}=e;const d=t&&(0,p.cloneElement)(t,{className:g}),u=n&&(0,p.cloneElement)(n,{className:f});return a?(0,y.jsx)(j,{alt:s,className:r,data:a,loading:d,error:u,onClick:c,children:o}):l?(0,y.jsx)(b,{alt:s,className:r,id:l,loading:d,innerLoading:d,error:u,innerError:u,apis:i,onClick:c,children:o}):u},I=e=>{let{id:t,src:n,alt:s,onClick:r,loading:o=(0,y.jsx)(u.Skeleton.Avatar,{shape:"square",active:!0}),error:c=(0,y.jsx)(i.default,{role:"error-icon",colorful:!0,type:"icon-color-touxiang-nan"}),className:p,apis:m}=e,_=(0,l.A)(e,v);return(0,y.jsx)("div",(0,a.A)((0,a.A)({},_),{},{"data-testid":"components-core-image",className:d()(p,h),children:N({loading:o,error:c,src:n,id:t,alt:s,className:p,apis:m,onClick:r})}))};I.Avatar=e=>{let{id:t,src:n,alt:s,gender:r,loading:o=(0,y.jsx)(u.Skeleton.Avatar,{shape:"square",active:!0}),error:c=(0,y.jsx)(i.default,{role:"error-icon",colorful:!0,type:"icon-color-touxiang-nan"}),className:p,gap:m,icon:_,children:g,shape:f,size:A=100,width:v,height:j,defaultAvatar:b=x.A,apis:I}=e,S=(0,l.A)(e,C);const w=(()=>{const e=v&&j?{style:{width:v,height:j}}:{size:A};if(v&&v!==j&&(f="square"),t||n)return N({loading:o,error:c,src:n,defaultAvatar:b,id:t,alt:s,className:p,apis:I,children:t=>(0,y.jsx)(u.Avatar,(0,a.A)((0,a.A)({},t),{},{gap:m,shape:f},e))});if(r){const t=r&&["F","female","f"].indexOf(r)>-1?"icon-color-touxiang-nv":"icon-color-touxiang-nan";return(0,y.jsx)(u.Avatar,(0,a.A)((0,a.A)({},S),{},{src:(0,y.jsx)(i.default,{role:"touxiang",colorful:!0,type:t}),gap:m,shape:f},e))}return(0,y.jsx)(u.Avatar,(0,a.A)((0,a.A)((0,a.A)({},S),{},{gap:m,icon:_,shape:f,size:A,src:b},e),{},{children:g}))})();return(0,y.jsx)("div",(0,a.A)((0,a.A)({},S),{},{"data-testid":"components-core-image-avatar",className:d()(p,h),style:{width:v&&j?v:A,height:v&&j?j:A},children:w}))};const S=I},41654(e,t,n){n.d(t,{A:()=>f,K:()=>g});var a=n(89379),l=n(53986),s=n(45776),r=n(27047),o=n(33097),i=n.n(o),c=n(70579);const d=["apis"],u=["apis"],p=(e,t)=>"en-US"===t?i()(e,"enName"):i()(e,"chName"),m=()=>n.e(719).then(n.t.bind(n,10719,19)).then(e=>e.__esModule?e.default:e),h={cache:"FUNCTION_DATA",isLocal:!0,ttl:864e5,loader:m},_=e=>{const t=Object.assign({},{overlayWidth:"640px",getSearchProps:e=>({data:{searchText:e}})},e),{apis:n}=t,o=(0,l.A)(t,d),{apis:i,locale:u}=(0,r.A)(),m=Object.assign({},{functionData:h},null===i||void 0===i?void 0:i.staticData,n);return(0,c.jsx)(s.Ay,(0,a.A)((0,a.A)({},o),{},{api:Object.assign({},{transformData:e=>{let{data:t}=e;const{treeData:n}=(0,s.ON)(new Map(t.map(e=>[e.code,(0,a.A)((0,a.A)({},e),{},{id:e.code,label:p(e,u),parentId:e.parentCode||null})])));return n}},m.functionData)}))};_.defaultData=m;const g=e=>{let{apis:t}=e,n=(0,l.A)(e,u);const{apis:o,locale:i}=(0,r.A)(),d=Object.assign({},{functionData:h},null===o||void 0===o?void 0:o.staticData,t);return(0,c.jsx)(s.yK,(0,a.A)((0,a.A)((0,a.A)({},n),d.functionData),{},{type:"function",getLabel:e=>p(e,i),transformData:e=>{let{data:t}=e;return t}}))};_.FunctionEnum=_.Enum=g;const f=_},43856(e,t,n){n.r(t),n.d(t,{AddressEnum:()=>m.qn,AddressInputField:()=>m.TM,AddressSelectField:()=>m.Ay,AdvancedSelectField:()=>h.Ay,CascaderField:()=>g.Ay,FetchButton:()=>i.A,FetchScrollLoader:()=>o.FetchScrollLoader,FunctionEnum:()=>f.K,FunctionSelectField:()=>f.A,IndustryEnum:()=>x.W,IndustrySelectField:()=>x.A,InputFileButton:()=>p.Zi,InputFileLink:()=>p.FI,InputFileText:()=>p.AG,ScrollLoader:()=>o.default,SearchInput:()=>d.A,SelectInnerInput:()=>u.A,SimpleBar:()=>c.A,SuperSelectField:()=>_.Ay,SuperSelectTableListField:()=>_.e0,SuperSelectTreeField:()=>_.ec,SuperSelectUserField:()=>_.$9,TableField:()=>h.Bm,TypeDateRangePickerField:()=>A.A,UserField:()=>h.Eo,accept:()=>v.A,changeMoneyToChinese:()=>a.A,createAddressApi:()=>m.LH,createDeferred:()=>j(),createListField:()=>h.NR,createTreeUtils:()=>g.ON,getContainerBody:()=>l.c,getPopupContainer:()=>s,getScrollEl:()=>l.h,isNotEmpty:()=>b.A,numberToPx:()=>N.v,pxToNumber:()=>N.j,useFileUpload:()=>p.lN,useResize:()=>y.A,withAddressApi:()=>m.DF,withInputFile:()=>p.Ay,withOSSFile:()=>r.A});var a=n(69484),l=n(76801);const s=e=>{const t=e=>{const n=(0,l.h)();if(!e||e===n||!e.parentElement)return n;return[].slice.call(e.classList,0).find(e=>["ant-modal-body","ant-modal-content","ant-popover-content"].indexOf(e)>-1)?e:t(e.parentElement)};return t(e)};var r=n(97211),o=n(78784),i=n(73025),c=n(17342),d=n(73161),u=n(30509),p=n(17508),m=n(93761),h=n(12392),_=n(60586),g=n(45776),f=n(41654),x=n(53392),A=n(89319),y=n(77964),v=n(81348),C=n(1582),j=n.n(C),b=n(55490),N=n(91176)},45776(e,t,n){n.d(t,{yK:()=>F,ON:()=>g,Ay:()=>z});var a=n(53986),l=n(89379),s=n(30509),r=n(73884),o=n(96418),i=n.n(o),c=n(55199),d=n(64671),u=n(73161),p=n(33097),m=n.n(p),h=n(79686),_=n.n(h);const g=e=>{const t=Array.from(e.values()),n=t.filter(e=>null===e.parentId),a=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},l=t=>{const n=[],a=t=>{const l=e.get(t);l&&Array.isArray(l.children)&&l.children.length>0&&(n.push(...l.children),l.children.forEach(e=>{a(e.id)}))};return a(t),n},s=(t,n)=>{const a=t=>{const l=e.get(t);return l?n(l)?l:_()(l.parentId)?null:a(l.parentId):null};return a(t)},r=t=>{const a=e.get(t);if(!a)return[];const l=a.parentId;if(_()(l))return n;return e.get(l).children},o=(()=>{const e=n=>Array.isArray(n)&&n.length>0?n.map(n=>{const a=t.filter(e=>e.parentId===n.id);return Object.assign({},n,{children:e(a)})}):null;return e(n)})();return{mapping:e,getSelectedQueue:t=>{const n=e.get(t);if(!n)return[];const a=e=>{if(e.children&&e.children.length>0)return a(e.children.find(t=>t.children&&e.children.length>0)||m()(e.children,"0"));const t=l(e.parentId).find(e=>e.children&&e.children.length>0);return t?a(t):e},s=function(t){const n=[t,...arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]],a=e.get(t);return!a||_()(a.parentId)?n:s(a.parentId,n)},r=a(n);return s(m()(r,"id"))},getAllChildren:l,computedCheckboxStatus:function(t){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];if(s(t,e=>n.indexOf(e.id)>-1))return{checked:!0,indeterminate:!1};const a=(t=>{const a=t=>{const l=e.get(t);return l?(s=l,n.indexOf(s.id)>-1?l:Array.isArray(l.children)&&l.children.length>0?l.children.find(e=>!!a(e.id)):void 0):null;var s};return!!a(t)})(t);return a?{checked:!1,indeterminate:!0}:{checked:!1,indeterminate:!1}},getSiblingNode:r,findInParents:s,setNodeChecked:function(t){const n=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]).slice(0),s=t=>{const o=e.get(t);if(!o)return;n.push(t),l(t).forEach(e=>{a(n,e.id)});const i=r(t),c=i.every(e=>n.indexOf(e.id)>-1);o.parentId&&c&&(i.forEach(e=>{a(n,e.id)}),s(o.parentId))};return s(t),n},setNodeUnchecked:function(t){const n=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]).slice(0),l=t=>{const s=e.get(t);if(!s)return;if(n.indexOf(s.id)>-1)return void a(n,s.id);const o=r(t);s.parentId&&(o.forEach(e=>{t!==e.id&&n.push(e.id)}),l(s.parentId))};return l(t),n},treeData:o,treeMapping:new Map(o.map(e=>[e.id,e]))}};var f=n(74065),x=n.n(f),A=n(19853),y=n.n(A),v=n(17342),C=n(83136),j=n.n(C);const b={content:"style_content__Hxlt9__-0IeQ",columns:"style_columns__FmtPF__-0IeQ","content-item":"style_content-item__i6HCO__-0IeQ","last-level-area":"style_last-level-area__2y7jQ__-0IeQ","is-popup":"style_is-popup__+r3Mn__-0IeQ",menu:"style_menu__WZUVE__-0IeQ","scroll-plus-box":"style_scroll-plus-box__QcTst__-0IeQ","menu-label":"style_menu-label__iGt0Z__-0IeQ","menu-item":"style_menu-item__hXHfm__-0IeQ","checkbox-hidden":"style_checkbox-hidden__Xpx7J__-0IeQ",loading:"style_loading__ZwrVe__-0IeQ"};var N=n(87558),I=n(47458),S=n(25438),w=n(70579),O=n(27047);const Q=["data","name","type","cache","children","getLabel"],L=new Map,P=(0,N.withFetch)(e=>{let{data:t,name:n,type:s,cache:o,children:i,getLabel:c}=e,d=(0,a.A)(e,Q);const u=(0,r.useMemo)(()=>new Map(t.map(e=>[e.code,(0,l.A)((0,l.A)({},e),{},{id:e.code,label:c?c(e):e.chName,parentId:e.parentCode||null})])),[t,c]).get(n);return L.set("".concat(n,"_").concat(s),u),i(u,d)}),k=e=>{const{locale:t}=(0,O.A)(),n="".concat(t,"_").concat(e.name,"_").concat(e.type),a=L.get(n);return a&&!e.force?e.children(a):(0,w.jsx)(P,(0,l.A)({},e))};k.defaultProps={children:e=>m()(e,"label","")};const F=k,T=["maxLength","nodeFormat","dataFormat"],M=s.A.useContext,R=(0,N.withFetch)(e=>{let{data:t,computedIsChecked:n,onSelect:a}=e;return(0,w.jsx)(v.A,{className:b["scroll-plus-box"],children:(0,w.jsx)(c.List,{className:S.A.list,size:"small",dataSource:t,rowKey:"value",renderItem:e=>{const t=n(e);return(0,w.jsx)(c.List.Item,{className:j()(S.A["list-item"],{[S.A["is-selected"]]:t}),onClick:()=>a(e,t),children:(0,w.jsx)("span",{className:S.A["item-label"],children:e.label})})}})})}),D=e=>{let{value:t,setValue:n,size:a,selectLevel:s}=e;const{fetchApi:o,props:p}=M(),[h,_]=(0,r.useState)(""),f=i()(p.dataFormat),{formatMessage:A}=(0,I.useIntl)({moduleName:"Common"}),C=o.data,N=(0,r.useMemo)(()=>new Map(f(C).list.map(e=>[e.value,e])),[C,f]),O=(0,r.useMemo)(()=>g(N),[N]),Q=(0,r.useRef)({});Q.current={createMergeTree:p.createMergeTree,loadMore:o.loadMore,openLoadData:p.openLoadData,parentIdKey:p.parentIdKey,treeUtils:O};const[L,P]=(0,r.useState)(()=>{const e=t.find(e=>!!N.get(e));return O.getSelectedQueue(e||m()(o.data.find(e=>e.children&&e.children.length>0),"id")||m()(o.data,"[0].id"),N)});(0,r.useEffect)(()=>{const{openLoadData:e,loadMore:t,parentIdKey:n,createMergeTree:a,treeUtils:l}=Q.current;if(!e)return;const s=N.get(x()(L));if(!s)return;const r=l.getSelectedQueue(s.id);y()(L,r)?s.hasOwnProperty("children")||t({data:{[n]:s.id}},a(s.id)):P(r)},[L,N]);const k=(e,l)=>{const s=(()=>{if(p.onlyAllowLastLevel&&e){const e=t.slice(0);return e.push(l),e}if(p.onlyAllowLastLevel){const e=t.slice(0);return e.splice(t.indexOf(l),1),e}return e?O.setNodeChecked(l,t):O.setNodeUnchecked(l,t)})();s.length>a?c.message.error(A({id:"maxSelectedCount"},{count:a})):n(p.single&&s.length>0?[x()(s)]:s)},F=e=>{const t=N.get(e);return!(!p.openLoadData||t.hasOwnProperty("children"))||t.children&&t.children.length>0},T=!p.openLoadData&&"function"===typeof p.onSearch,D=T&&h&&(0,w.jsx)(R,{data:{searchText:h},loader:e=>{let{data:t}=e;return p.onSearch(t.searchText,{mapping:N})},computedIsChecked:e=>t.indexOf(e.id)>-1,onSelect:(e,t)=>{k(!t,e.id),!t&&P(O.getSelectedQueue(e.id,N)),_("")}});return(0,w.jsxs)("div",{className:j()(b.content,{[b["is-popup"]]:p.isPopup,[b["has-search"]]:T}),style:{"--menu-item-width":p.menuItemWidth},children:[T&&(0,w.jsx)(u.A,{isPopup:p.isPopup,className:j()(S.A["search-input"],{[S.A["is-popup"]]:p.isPopup}),placeholder:p.searchPlaceholder||A({id:"search"}),value:h,onSearch:e=>{_(e)}}),D||(0,w.jsx)("div",{children:(0,w.jsx)(v.A,{className:b.scroller,options:{autoHide:!1},children:(0,w.jsxs)("div",{className:b.columns,children:[L.map((e,n)=>{const a=N.get(e),o=O.getSiblingNode(e),i=!F(null===a||void 0===a?void 0:a.id)&&n>0;return(0,w.jsx)(v.A,{className:j()(b["content-item"],{[b["last-level-area"]]:i}),children:i?(0,w.jsx)(c.Space,{wrap:!0,children:o.map(e=>(0,r.createElement)(c.Checkbox,(0,l.A)((0,l.A)({},O.computedCheckboxStatus(e.id,t)),{},{disabled:s>1&&(t.indexOf(e.parentCode)>-1||t.indexOf(e.code.slice(0,3))>-1),key:e.id,onChange:t=>k(t.target.checked,e.id)}),e.label))}):(0,w.jsx)(c.Menu,{className:j()(b.menu),onSelect:e=>{const n=N.get(e.key);if(n)if(F(n.id))P(O.getSelectedQueue(n.id,N));else{const{checked:e}=O.computedCheckboxStatus(n.id,t);k(!e,n.id)}},selectedKeys:n===L.length-1?[]:L,items:o.map(e=>({key:e.id,label:(0,w.jsxs)(c.Space,{className:j()(b["menu-item"],{[b["checkbox-hidden"]]:p.onlyAllowLastLevel&&F(e.id)}),children:[!p.onlyAllowLastLevel&&(0,w.jsx)(c.Checkbox,(0,l.A)((0,l.A)({},O.computedCheckboxStatus(e.id,t)),{},{disabled:s>1&&t.indexOf(e.parentCode)>-1,onChange:t=>k(t.target.checked,e.id)})),(0,w.jsx)("div",{className:b["menu-label"],children:e.label}),F(e.id)&&(0,w.jsx)(d.default,{className:b["menu-item-icon"],type:"icon-arrow-thin-right",size:12})]})}))})},m()(o,"[0].id",n))}),o.isComplete?null:(0,w.jsx)("div",{className:b.loading,children:(0,w.jsx)(c.Spin,{size:"small"})})]})})})]})},E=e=>{let{maxLength:t,nodeFormat:n,dataFormat:r}=e,o=(0,a.A)(e,T);return(0,w.jsx)(s.A,(0,l.A)((0,l.A)({},o),{},{dataFormat:e=>r(e,n),children:e=>{let{value:n,setValue:a}=e;return(0,w.jsx)(D,(0,l.A)((0,l.A)({},o),{},{size:t,value:n,setValue:a}))}}))};E.defaultProps={maxLength:Number.MAX_VALUE,size:"middle",isPopup:!0,overlayWidth:"460px",menuItemWidth:"180px",openLoadData:!1,onlyAllowLastLevel:!1,parentIdKey:"id",onSearch:(e,t)=>{let{mapping:n}=t;return Array.from(n.values()).filter(t=>t.label.indexOf(e)>-1)},dataFormat:(e,t)=>{const n=(e,a)=>{const l=[];return l.push(...(e||[]).map(e=>("function"===typeof t&&Object.assign(e,t(e)),e.children&&e.children.length>0&&l.push(...n(e.children,e.id)),Object.assign({},e,{value:e.id,parentId:a})))),l};return{list:n(e,null)}},createMergeTree:e=>(t,n)=>{const a=t=>t.map(t=>t.id===e?Object.assign({},t,{children:n&&n.map(t=>Object.assign({},t,{parentId:e}))}):Array.isArray(t.children)&&t.children.length>0?Object.assign({},t,{children:a(t.children)}):t);return a(t)}};const z=E},53392(e,t,n){n.d(t,{A:()=>g,W:()=>_});var a=n(89379),l=n(53986),s=n(45776),r=n(27047),o=n(33097),i=n.n(o),c=n(70579);const d=["apis"],u=["apis"],p=(e,t)=>"en-US"===t?i()(e,"enName"):i()(e,"chName"),m={cache:"INDUSTRY_DATA",isLocal:!0,ttl:864e5,loader:()=>n.e(7183).then(n.t.bind(n,57183,19)).then(e=>e.__esModule?e.default:e)},h=e=>{let{apis:t}=e,n=(0,l.A)(e,d);const{apis:o,locale:i}=(0,r.A)(),u=Object.assign({},{industryData:m},null===o||void 0===o?void 0:o.staticData,t);return(0,c.jsx)(s.Ay,(0,a.A)((0,a.A)({},n),{},{api:Object.assign({},{transformData:e=>{let{data:t}=e;const{treeData:n}=(0,s.ON)(new Map(t.filter(e=>"000"!==e.code).map(e=>[e.code,(0,a.A)((0,a.A)({},e),{},{id:e.code,label:p(e,i),parentId:e.parentCode||null})])));return n}},u.industryData)}))};h.defaultProps={overlayWidth:"635px"};const _=e=>{let{apis:t}=e,n=(0,l.A)(e,u);const{apis:o,locale:i}=(0,r.A)(),d=Object.assign({},{industryData:m},null===o||void 0===o?void 0:o.staticData,t);return(0,c.jsx)(s.yK,(0,a.A)((0,a.A)((0,a.A)({},n),d.industryData),{},{type:"function",getLabel:e=>p(e,i),transformData:e=>{let{data:t}=e;return t}}))};h.IndustryEnum=h.Enum=_;const g=h},55490(e,t,n){n.d(t,{A:()=>a.isNotEmpty});var a=n(39129)},60586(e,t,n){n.d(t,{e0:()=>A,ec:()=>y,$9:()=>v,Ay:()=>x});var a=n(89379),l=n(73884),s=n(98949),r=n.n(s),o=n(3382),i=n(40438),c=n(55199);const d="style_select-list-item-description__ndJSX__-0IeQ",u="style_select-list-item-label__gyGnt__-0IeQ",p="style_select-list-item-content__2VJnt__-0IeQ";var m=n(83136),h=n.n(m),_=(n(96316),n(70579));const g=e=>{const{props:t,open:n,onOpenChange:a,value:l,onComplete:r}=e,{placeholder:i,children:c,showSelectedTag:d,onConfirm:u}=t;return(0,_.jsx)(o.default,{title:i,open:n,onClose:()=>{a(!1)},footer:d&&(0,_.jsx)(s.SelectedTagList,{}),onConfirm:()=>{if(r(),"function"===typeof u)return u(l)},children:c(e)})},f=(0,l.forwardRef)((e,t)=>{const n=Object.assign({},{children:e=>{let{components:t}=e;return(0,_.jsxs)(c.Flex,{vertical:!0,children:[t.search,t.selectedAll,t.fetchList,t.footer,!1!==n.isPopup&&t.selectedTag]})},renderModal:g},e);return(0,_.jsx)(r(),(0,a.A)((0,a.A)({},n),{},{ref:t}))}),x=f,A=(0,l.forwardRef)((e,t)=>{const n=Object.assign({},{renderModal:g},e);return(0,_.jsx)(s.SelectTableList,(0,a.A)((0,a.A)({},n),{},{ref:t}))}),y=(0,l.forwardRef)((e,t)=>{const n=Object.assign({},{renderModal:g},e);return(0,_.jsx)(s.SelectTree,(0,a.A)((0,a.A)({},n),{},{ref:t}))}),v=(0,l.forwardRef)((e,t)=>(0,_.jsx)(f,(0,a.A)((0,a.A)({},e),{},{ref:t,renderItemContent:e=>{let{item:t,props:n}=e;const{labelKey:l,avatarKey:s,descriptionKey:r}=n,o=t[s||"avatar"];return(0,_.jsxs)(c.Flex,{gap:8,children:[(0,_.jsx)(i.default.Avatar,(0,a.A)((0,a.A)({},Object.assign({},"string"===typeof o?{id:o}:o)),{},{size:32,gender:"M"})),(0,_.jsxs)(c.Flex,{vertical:!0,gap:8,className:p,align:"flex-start",children:[(0,_.jsx)("div",{className:h()(u,"select-list-item-label"),children:t[l]}),t[r||"description"]&&(0,_.jsx)("div",{className:h()(d,"select-list-item-description"),title:t[r||"description"],children:t[r||"description"]})]})]})}})))},69484(e,t,n){n.d(t,{A:()=>l,e:()=>a});const a=1e15,l=e=>{let t,n,l,s=["\u96f6","\u58f9","\u8d30","\u53c1","\u8086","\u4f0d","\u9646","\u67d2","\u634c","\u7396"],r=["","\u62fe","\u4f70","\u4edf"],o=["","\u4e07","\u4ebf","\u5146"],i=["\u89d2","\u5206","\u6beb","\u5398"],c="",d="";if(""===e)return"";if((e=parseFloat(e))>=a)return c="\u8d85\u51fa\u6700\u5927\u5904\u7406\u6570\u5b57",console.error("\u8d85\u51fa\u6700\u5927\u5904\u7406\u6570\u5b57"),c;if(0===e)return c=s[0]+"\u5143\u6574",c;if(e<0&&(e=-e,d="\u8d1f "),-1===(e=e.toString()).indexOf(".")?(t=e,n=""):(l=e.split("."),t=l[0],n=l[1].substr(0,4)),parseInt(t,10)>0){let e=0,n=t.length;for(let a=0;a<n;a++){let l=t.substr(a,1),i=n-a-1,d=i/4,u=i%4;"0"===l?e++:(e>0&&(c+=s[0]),e=0,c+=s[parseInt(l)]+r[u]),0===u&&e<4&&(c+=o[d])}c+="\u5143"}if(""!==n){let e=n.length;for(let t=0;t<e;t++){let e=n.substr(t,1);"0"!==e&&(c+=s[Number(e)]+i[t])}}return""===c?c+=s[0]+"\u5143\u6574":""===n&&(c+="\u6574"),c=d+c,c}},73161(e,t,n){n.d(t,{A:()=>_});var a=n(89379),l=n(53986),s=n(55199),r=n(83136),o=n.n(r);const i="style_search-input__8aH1G__-0IeQ",c="style_is-popup__L0973__-0IeQ";var d=n(64671),u=n(73884),p=n(51941),m=n(70579);const h=["value","debounce","onSearch","isPopup","placeholder","className"],_=e=>{let{value:t,debounce:n=500,onSearch:r,isPopup:_,placeholder:g,className:f}=e,x=(0,l.A)(e,h);const[A,y]=(0,u.useState)(t),v=(0,u.useRef)(t),C=(0,p.useDebouncedCallback)(r,n);return(0,u.useEffect)(()=>{t!==v.current&&(y(t),v.current=t)},[t]),(0,m.jsx)(s.Input.Search,(0,a.A)((0,a.A)({},x),{},{allowClear:!0,className:o()(f,i,{[c]:_}),value:A,placeholder:g,prefix:(0,m.jsx)(d.default,{type:"icon-sousuo"}),enterButton:(0,m.jsx)(d.default,{type:"icon-sousuo"}),onChange:e=>{const t=e.target.value;v.current=t,y(t),C(t.trim())},onSearch:e=>{C(e.trim())}}))}},74981(e,t,n){n.d(t,{A:()=>l});var a=n(73884);const l=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=(0,a.createContext)(e),{Provider:n,Consumer:l}=t;return{context:t,Provider:n,Consumer:l,useContext:()=>(0,a.useContext)(t)}}},77964(e,t,n){n.d(t,{A:()=>d});var a=n(73884),l=n(79889),s=n.n(l),r=n(93950),o=n.n(r),i=n(96418),c=n.n(i);const d=(e,t)=>{const n=(0,a.useRef)(null);n.current=Object.assign({},{time:500,isDebounce:!1},t);const l=(0,a.useRef)(null),r=c()(e);return(0,a.useLayoutEffect)(()=>{const e=l.current,t=()=>window.requestAnimationFrame(()=>{e&&r(e)});t();const a=new ResizeObserver((n.current.isDebounce?o():s())(t,n.current.time));return e&&a.observe(e),()=>{a.disconnect()}},[r]),l}},78784(e,t,n){n.d(t,{default:()=>l.a});n(21219);var a=n(14311),l=n.n(a);n.o(a,"FetchScrollLoader")&&n.d(t,{FetchScrollLoader:function(){return a.FetchScrollLoader}})},81348(e,t,n){n.d(t,{A:()=>a.computedAccept});var a=n(61323)},89319(e,t,n){n.d(t,{A:()=>m});var a=n(89379),l=n(20454),s=n(55199),r=n(10986),o=n.n(r),i=n(57469),c=n.n(i),d=n(20492),u=n(47458),p=n(70579);const m=(0,u.createWithIntl)({importMessages:d.A,moduleName:"Common"})(e=>{let t=Object.assign({},((0,l.A)(e),e));const{formatMessage:n}=(0,u.useIntl)({moduleName:"Common"}),r=new Map([["date",n({id:"customTime"})],["month",n({id:"monthly"})],["week",n({id:"weekly"})]]),[i,d]=o()(t);return(0,p.jsxs)(s.Space.Compact,{children:[(0,p.jsx)(s.Select,{style:{width:"120px"},value:(null===i||void 0===i?void 0:i.type)||"date",onChange:e=>{d(t=>{var n;return{value:null!==t&&void 0!==t&&null!==(n=t.value)&&void 0!==n&&n.length?[c()(t.value[0]).startOf(e||"date"),c()(t.value[1]).endOf(e||"date")]:null,type:e||"date"}})},options:Array.from(r).map(e=>{let[t,n]=e;return{label:n,value:t}})}),(0,p.jsx)(s.DatePicker.RangePicker,(0,a.A)((0,a.A)({},t),{},{picker:(null===i||void 0===i?void 0:i.type)||"date",value:Array.isArray(null===i||void 0===i?void 0:i.value)&&2===i.value.length&&i.value.map(e=>e&&c()(e)),onChange:e=>{d(t=>(console.log(Object.assign({type:"date"},t,{value:e&&[e[0]&&new Date(e[0].startOf((null===t||void 0===t?void 0:t.type)||"date").valueOf()),e[1]&&new Date(e[1].endOf((null===t||void 0===t?void 0:t.type)||"date").valueOf())]})),Object.assign({type:"date"},t,{value:e&&[e[0]&&new Date(e[0].startOf((null===t||void 0===t?void 0:t.type)||"date").valueOf()),e[1]&&new Date(e[1].endOf((null===t||void 0===t?void 0:t.type)||"date").valueOf())]})))}}))]})})},91176(e,t,n){n.d(t,{j:()=>l,v:()=>a});const a=e=>"number"===typeof e?"".concat(e,"px"):e,l=e=>{if(!e)return 0;const t=e.match(/^\d*(\.\d*)?/);return t?Number(t[0]):0}},93761(e,t,n){n.d(t,{qn:()=>V,TM:()=>ee,LH:()=>M,Ay:()=>K,NY:()=>R,DF:()=>W});var a=n(53986),l=n(89379),s=n(30509),r=n(25438),o=n(55199),i=n(27047),c=n(83136),d=n.n(c),u=n(64671),p=n(73884),m=n(21485),h=n(56434),_=n.n(h),g=n(15797),f=n.n(g),x=n(33097),A=n.n(x);const y="style_address__DIuRX__-0IeQ",v="style_is-popup__tqVvp__-0IeQ",C="style_title__FAe12__-0IeQ",j="style_scroll-box__JWiDl__-0IeQ",b="style_scroll-plus-box__lidEW__-0IeQ",N="style_content__lAARZ__-0IeQ",I="style_col-left__WPfeS__-0IeQ",S="style_col-right__z0e9-__-0IeQ";var w=n(87558),O=n.n(w);const Q=e=>({"en-US":()=>n.e(3691).then(n.bind(n,83691)),"zh-CN":()=>n.e(2253).then(n.bind(n,32253))}[e]());var L=n(47458),P=n(70579);const k=["name","data","getAddressApi","children"],F=["data"],T=s.A.useContext,M=e=>{let{city:t,province:n,country:a}=e;const l=f()(()=>{const e=[];return["gangaotai","municipality"].forEach(n=>{e.push(...t.relations[n])}),["provinces","continents"].forEach(n=>{t.relations[n].forEach(n=>{e.push(n),e.push(...t.relations[n])})}),e.map(e=>t.list[e])});return{getCity:f()(e=>{const n=t.list[e];return n?{city:n,parent:n.parentCode?t.list[n.parentCode]:null}:{city:null,parent:null}}),getChinaHotCities:f()(()=>t.relations[2].map(e=>t.list[e])),getChinaCities:f()(()=>["2",...n.relations.municipality,...n.relations.provinces,"gangaotai"].map(e=>Object.assign({id:e},t.list[e]))),getCountries:f()(()=>["1",...a.relations.continents].map(e=>Object.assign({id:e},a.list[e]))),getList:f()((e,l)=>{const{showChinaQuan:s,showForeignQuan:r}=Object.assign({},l);if("gangaotai"===e)return n.relations.gangaotai.map(e=>t.list[e]);const o=Object.assign({},t.list[e]);if(n.relations.municipality.indexOf(e)>-1)return o.name="".concat(s?"\u5168":"")+o.name,[o];const i=t.relations[e].map(e=>t.list[e]);return n.relations.provinces.indexOf(e)>-1&&s&&(o.name="\u5168"+o.name,i.splice(0,0,o)),a.relations.continents.indexOf(e)>-1&&r&&(o.name="\u5168"+o.name,i.splice(0,0,o)),i}),getNationalityList:f()(e=>{let n=_()(t);return"1"===e&&n.relations[1].unshift("410"),"350"===e&&n.relations[350].unshift("410"),n.relations[e].filter(e=>n.list[e]).map(e=>n.list[e])}),getCityByName:f()(e=>{const t=l();let n;return[t=>t.name===e,t=>t.name===e.replace(/(\u7701|\u5e02)$/,""),t=>0===e.indexOf(t.name)].find(e=>(n=t.find(e),n)),n}),combineCities:f()((e,n)=>[...n.filter(n=>t.list[n].parentCode!==e&&t.list[e].parentCode!==n&&e!==n),e]),searchCities:f()(e=>{if(!e)return[];return l().filter(t=>["pinyin","name","enName","spelling"].some(n=>t[n].toUpperCase().indexOf(e.toUpperCase())>-1)).map(e=>{const n=e.parentCode?t.list[e.parentCode]:null;return{label:n?"".concat(n.name,"\xb7").concat(e.name):e.name,value:e.code}})})}},R=(e,t)=>"en-US"===t?A()(e,"enName"):A()(e,"name"),D={cache:"CITY_DATA",isLocal:!0,ttl:864e5,loader:()=>n.e(7820).then(n.t.bind(n,37820,19)).then(e=>e.__esModule?e.default:e)},E=e=>{let{value:t,setValue:n}=e;const{fetchApi:a,props:l}=T(),[s,c]=(0,p.useState)(""),[h,_]=(0,p.useState)("2"),{formatMessage:g}=(0,L.useIntl)({moduleName:"AddressSelect"}),{locale:f}=(0,i.A)(),{getCity:x,getChinaCities:A,getCountries:w,getList:O,searchCities:Q}=(0,p.useMemo)(()=>M(a.data),[a.data]),k=e=>{if(l.single)return void n([e]);const a=t.slice(0),s=a.indexOf(e);s>-1?a.splice(s,1):a.push(e),n(a)},F=s&&(0,P.jsx)(m.A,{className:b,children:(0,P.jsx)(o.List,{className:r.A.list,size:"small",dataSource:Q(s),rowKey:"value",renderItem:e=>(0,P.jsx)(o.List.Item,{className:r.A["list-item"],onClick:()=>{k(e.value),c("")},children:(0,P.jsx)("span",{className:r.A["item-label"],children:e.label})})})});return(0,P.jsxs)("div",{className:d()(y,{[v]:l.isPopup}),children:[(0,P.jsx)(o.Input.Search,{className:d()(r.A["search-input"],{[r.A["is-popup"]]:l.isPopup}),placeholder:l.searchPlaceholder||g({id:"searchCity"}),prefix:(0,P.jsx)(u.default,{type:"icon-sousuo"}),enterButton:(0,P.jsx)(u.default,{type:"icon-sousuo"}),value:s,allowClear:!0,onChange:e=>{const t=e.target.value;c(t)},onSearch:e=>{c(e)}}),(0,P.jsx)("div",{className:N,children:F||(0,P.jsxs)(o.Row,{wrap:!1,children:[(0,P.jsx)(o.Col,{className:I,children:(0,P.jsx)(o.Tabs,{centered:!0,onChange:e=>{_(e)},items:[{key:"2",label:(0,P.jsx)(L.FormattedMessage,{id:"domestic",moduleName:"AddressSelect",defaultMessage:"\u56fd\u5185"}),children:(0,P.jsx)(m.A,{className:j,children:(0,P.jsx)(o.Menu,{selectedKeys:[h],onSelect:e=>{_(e.key)},items:A().map(e=>({label:R(e,f),key:e.id}))})})},{key:"1",label:(0,P.jsx)(L.FormattedMessage,{id:"abroad",moduleName:"AddressSelect",defaultMessage:"\u56fd\u5916"}),children:(0,P.jsx)(m.A,{className:j,children:(0,P.jsx)(o.Menu,{selectedKeys:[h],onSelect:e=>{_(e.key)},items:w().map(e=>({label:R(e,f),key:e.id}))})})}]})}),(0,P.jsxs)(o.Col,{flex:1,className:S,children:[(0,P.jsx)(o.Divider,{className:C,orientation:"left",children:R(x(h).city,f)}),(0,P.jsx)(m.A,{className:j,children:(0,P.jsx)(o.Space,{wrap:!0,children:O(h,{showChinaQuan:l.showChinaQuan,showForeignQuan:l.showForeignQuan}).map(e=>(0,P.jsx)(o.Tag.CheckableTag,{checked:t.indexOf(e.code)>-1,onChange:()=>{k(e.code)},children:R(e,f)},e.code))})})]})]})})]})},z=e=>(0,P.jsx)(s.A,(0,l.A)((0,l.A)({},e),{},{children:e=>{let{value:t,setValue:n}=e;return(0,P.jsx)(L.IntlProvider,{moduleName:"AddressSelect",importMessages:Q,children:(0,P.jsx)(E,{value:t,setValue:n})})}}));z.defaultProps={overlayWidth:"500px",isPopup:!0,api:D,dataFormat:(e,t)=>{let{city:n}=e;const{locale:a}=Object.assign({},t);return{list:Object.values(n.list).map(e=>Object.assign({},e,{value:e.code,label:R(e,a)}))}}};const V=(0,w.withFetch)(e=>{let{name:t,data:n,getAddressApi:l,children:s}=e,r=(0,a.A)(e,k);const{locale:o}=(0,i.A)(),c=(0,p.useMemo)(()=>M(n),[n]);return l?s(c):(0,P.jsx)(O(),{cache:"city-enum",params:{name:t},loader:e=>{let{params:t}=e;const{name:n}=t;return new Promise(e=>{setTimeout(()=>{e(c.getCity(n))},0)})},render:e=>{let{data:t}=e;return s(t,Object.assign({},r,{locale:o}))}})});V.defaultProps=(0,l.A)((0,l.A)({},D),{},{displayParent:!1,children:(e,t)=>{let{city:n,parent:a}=e,{displayParent:l,locale:s}=t;return l&&a?"".concat(R(a,s),"\xb7").concat(R(n,s)):R(n,s)}});const W=e=>{const t=(0,w.withFetch)(t=>{let{data:n}=t,s=(0,a.A)(t,F);const r=(0,p.useMemo)(()=>M(n),[n]);return(0,P.jsx)(e,(0,l.A)((0,l.A)({},s),{},{addressApi:r}))});return t.defaultProps=(0,l.A)({},D),t};z.AddressEnum=z.Enum=V,z.createAddressApi=M,z.withAddressApi=W,z.getLabelForLocal=R;const K=z;var B=n(10986),U=n.n(B),q=n(78491),H=n.n(q),X=n(20492),Z=n(22616),J=n.n(Z),Y=n(1488),G=n.n(Y);const $=["isPopup","size","disabled","inputPlaceholder","onBlur","className"],ee=(0,L.createWithIntl)({importMessages:X.A,moduleName:"Common"})(e=>{const{isPopup:t,size:n,disabled:s,inputPlaceholder:r,onBlur:i,className:c}=e,d=(0,a.A)(e,$),[u,p]=U()(e),m=["isPopup","searchPlaceholder","placeholder","overlayWidth","api","dataFormat"],{formatMessage:h}=(0,L.useIntl)({moduleName:"Common"}),_=H()(e=>{i&&i(e)});return(0,P.jsx)("div",{ref:_,children:(0,P.jsxs)(o.Row,{gutter:10,children:[(0,P.jsx)(o.Col,{span:12,children:(0,P.jsx)(K,(0,l.A)((0,l.A)({},J()(d,m)),{},{className:c,disabled:s,single:!0,size:n,value:A()(u,"city"),onChange:e=>{p({city:e,detail:A()(u,"detail")})}}))}),(0,P.jsx)(o.Col,{span:12,children:(0,P.jsx)(o.Input,(0,l.A)((0,l.A)({},G()(d,m)),{},{className:c,placeholder:r||h({id:"pleaseInput"}),disabled:s,size:n,value:A()(u,"detail"),onChange:e=>{p({city:A()(u,"city"),detail:e.target.value})}}))})]})})})},97211(e,t,n){n.d(t,{A:()=>a.withOSSFile});var a=n(61323)}}]);
2
- //# sourceMappingURL=3856.23c16ed0.chunk.js.map
1
+ "use strict";(self.webpackChunk_kne_components_components_core=self.webpackChunk_kne_components_components_core||[]).push([[3856],{3382(e,t,n){n.r(t),n.d(t,{ModalButton:()=>D,TabsModal:()=>k,TabsModalButton:()=>R,default:()=>H,useConfirmModal:()=>U,useModal:()=>O,useTabsModal:()=>F});var a=n(89379),l=n(53986),s=n(73884),r=n(55199),o=n(83136),i=n.n(o);const c={modal:"style_modal__Pm3cF__HJ3UV",large:"style_large__iaqVE__HJ3UV","modal-body-inner":"style_modal-body-inner__4PhpA__HJ3UV","modal-title":"style_modal-title__dswaw__HJ3UV","modal-outer":"style_modal-outer__r3SkX__HJ3UV","modal-body":"style_modal-body__jQJSI__HJ3UV","right-options-modal":"style_right-options-modal__FajDP__HJ3UV","right-options-row":"style_right-options-row__-mPb9__HJ3UV","right-options-col":"style_right-options-col__3ilee__HJ3UV","is-disabled-scroller":"style_is-disabled-scroller__PmHyk__HJ3UV",content:"style_content__k6MIF__HJ3UV","modal-footer":"style_modal-footer__-prbN__HJ3UV","modal-close":"style_modal-close__Oa5Kl__HJ3UV","confirm-modal-wrap":"style_confirm-modal-wrap__YFImr__HJ3UV","is-danger":"style_is-danger__H5110__HJ3UV",title:"style_title__orTym__HJ3UV","has-title":"style_has-title__qy0Wp__HJ3UV"},d=e=>({"en-US":()=>n.e(4628).then(n.bind(n,74628)),"zh-CN":()=>n.e(7478).then(n.bind(n,87478))}[e]());var u=n(47458),p=n(64671);const m=(e,t)=>"function"===typeof e?e(t):e;var h=n(81014),_=n(17342),g=n(70579);const f=["ButtonComponent","onClick","autoClose","display"],x=["children","rightOptions","rightSpan","footer","footerButtons","className","size","title","onClose","onConfirm","confirmText","onCancel","cancelText","closable","disabledScroller","withDecorator","childrenRef"],A=["size"],y=["children"],v=["type","icon","title","danger","wrapClassName","message","iconSetting","confirmType"],C="Modal",j=e=>{let{options:t,rightSpan:n=6,children:a}=e;return t?(0,g.jsxs)(r.Row,{wrap:!1,className:c["right-options-row"],children:[(0,g.jsx)(r.Col,{span:24-n,className:c["right-options-col"],children:a}),(0,g.jsx)(r.Col,{span:n,className:c["right-options-col"],children:t})]}):a},b=(e,t)=>"".concat(e-48-(t?58:0),"px"),N=e=>{let{footer:t,footerButtons:n,onConfirm:o,onCancel:i,cancelText:c,onClose:p,targetProps:m}=e;return(0,g.jsxs)(r.Row,{gutter:10,wrap:!1,children:[(0,g.jsx)(r.Col,{flex:1,children:t}),Array.isArray(n)&&0===n.length?null:(0,g.jsx)(r.Col,{children:(0,g.jsx)(r.Space,{children:(n||[{children:c||(0,g.jsx)(u.IntlProvider,{importMessages:d,moduleName:C,children:(0,g.jsx)(u.FormattedMessage,{id:"Cancel",moduleName:C})}),onClick:i},{type:"primary",children:(0,g.jsx)(u.IntlProvider,{importMessages:d,moduleName:C,children:(0,g.jsx)(u.FormattedMessage,{id:"Confirm",moduleName:C})}),onClick:o}]).filter(e=>"function"===typeof(null===e||void 0===e?void 0:e.display)?null===e||void 0===e?void 0:e.display():!1!==(null===e||void 0===e?void 0:e.display)).map((e,t)=>{let{ButtonComponent:n,onClick:r,autoClose:o=!0,display:i}=e,c=(0,l.A)(e,f);const d=n||h.default;return(0,s.createElement)(d,(0,a.A)((0,a.A)({},c),{},{key:t,onClick:async function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];const a=await Promise.resolve(r&&r(...t,m));return o&&!1!==a&&p&&p(),a}}))})})})]})},S=e=>{let{title:t,footer:n,disabledScroller:a,footerButtons:l,onClose:o,closable:d,onConfirm:u,onCancel:m,children:h,targetProps:f,cancelText:x,confirmText:A}=e;const y=(0,s.useRef)(null);return(0,g.jsxs)("div",{className:i()(c["modal-outer"],"modal-container"),"data-testid":"components-core-modal",children:[!1===d?null:(0,g.jsx)(r.Button,{"data-testid":"components-core-modal-close-btn",className:i()(c["modal-close"],"modal-close"),type:"text",icon:(0,g.jsx)(p.default,{type:"icon-close-thin"}),onClick:e=>{e.stopPropagation(),o&&o()}}),t&&(0,g.jsx)("div",{className:c["modal-title"],children:t}),(0,g.jsx)(_.A,{className:i()(c["modal-body"],{[c["is-disabled-scroller"]]:a},"modal-body"),ref:y,children:(0,g.jsx)("div",{className:i()(c["modal-body-inner"],"modal-body-inner"),children:h})}),null!==n||l?(0,g.jsx)("div",{className:i()(c["modal-footer"],"modal-footer"),children:(0,g.jsx)(N,{footer:n,footerButtons:l,onConfirm:u,confirmText:A,onCancel:m,cancelText:x,onClose:o,targetProps:f})}):null]})},w=e=>{let{withDecorator:t,footerButtons:n,title:l,closable:s,onClose:r,onConfirm:o,confirmText:i,onCancel:c,cancelText:d,footer:u,rightOptions:p,rightSpan:h,disabledScroller:_,childrenRef:f,children:x}=e;const A=e=>(e=Object.assign({},{title:l},e),(0,g.jsx)(S,{title:m(e.title,(0,a.A)((0,a.A)({},e),{},{childrenRef:f,close:r})),closable:s,onClose:r,onConfirm:o,confirmText:i,onCancel:c,cancelText:d,footerButtons:m(n,(0,a.A)((0,a.A)({},e),{},{close:r})),disabledScroller:_,footer:m(u,(0,a.A)((0,a.A)({},e),{},{childrenRef:f,close:r})),targetProps:Object.assign({},e,{childrenRef:f,close:r}),children:(0,g.jsx)(j,{rightSpan:h,options:m(p,(0,a.A)((0,a.A)({},e),{},{childrenRef:f,close:r})),children:m(x,(0,a.A)((0,a.A)({},e),{},{childrenRef:f,close:r}))})}));return"function"===typeof t?t(A,{childrenRef:f,close:r}):A({})},V=e=>{let{children:t,rightOptions:n,rightSpan:s,footer:r,footerButtons:o,className:p,size:m,title:h,onClose:_,onConfirm:f,confirmText:A,onCancel:y,cancelText:v,closable:C,disabledScroller:j,withDecorator:N,childrenRef:S}=e,V=(0,l.A)(e,x);return(0,a.A)((0,a.A)((0,a.A)({},V),{},{icon:null,centered:!0,title:null,maskClosable:!!V.hasOwnProperty("maskClosable")&&V.maskClosable,destroyOnHidden:!0,footer:null,closable:!1,onCancel:_,className:i()(p,c.modal,c[m],{[c["right-options-modal"]]:n})},((e,t)=>"large"===e?{width:"".concat(Math.min(window.innerWidth-64,1500),"px"),style:{"--min-modal-height":b(500,t)}}:"small"===e?{width:"600px",style:{"--min-modal-height":b(300,t)}}:{width:"1000px",style:{"--min-modal-height":b(500,t)}})(m,!(null===r&&!o))),{},{children:(0,g.jsx)(u.IntlProvider,{importMessages:d,moduleName:"Modal",children:w({withDecorator:N,title:h,closable:C,onClose:_,onConfirm:f,confirmText:A,onCancel:y,cancelText:v,footer:r,footerButtons:o,rightOptions:n,rightSpan:s,disabledScroller:j,children:t,childrenRef:S})})})},O=()=>{const{modal:e}=r.App.useApp(),t=(0,s.useRef)(null);return n=>{const s={},r=V((0,a.A)({onClose:()=>s.close(),childrenRef:t},n)),{children:o}=r,i=(0,l.A)(r,y),{destroy:c}=e.info((0,a.A)((0,a.A)({},i),{},{content:o}));return s.close=c,s}},U=()=>{const{modal:e}=r.App.useApp();return t=>{const n={},s=(0,a.A)({onClose:()=>n.close(),maskClosable:!1},t),{type:o,icon:d,title:u,danger:m,wrapClassName:h,message:_,iconSetting:f={},confirmType:x="info"}=s,A=(0,l.A)(s,v),y=Object.assign({},{info:"icon-xinxi-tianchong",confirm:"icon-tishi-tianchong",warning:"icon-tishi-tianchong",error:"icon-shibai",success:"icon-chenggong"},f);if(e[o]){const{destroy:t}=e[o]((0,a.A)((0,a.A)({},A),{},{icon:null,wrapClassName:i()(c["confirm-modal-wrap"],h,{[c["is-danger"]]:m}),title:(0,g.jsx)(r.Space,{orientation:"vertical",onClick:e=>{e.stopPropagation()},children:u&&(0,g.jsxs)(r.Space,{size:0,align:"start",className:c.title,children:[m?(0,g.jsx)(p.default,{className:i()("title-icon","title-icon-".concat("confirm"===o?x:o)),type:d||y["confirm"===o?x:o]}):null,u]})}),content:(0,g.jsxs)(r.Space,{size:0,align:"start",className:i()(c.content,{[c["has-title"]]:u}),children:[!u&&m?(0,g.jsx)(p.default,{className:i()("title-icon","title-icon-".concat("confirm"===o?x:o)),type:d||y["confirm"===o?x:o]}):null,_]})}));n.close=t}return n}},H=e=>{let{size:t="default"}=e,n=(0,l.A)(e,A);const o=(0,s.useRef)(null);return(0,g.jsx)(r.Modal,(0,a.A)({},V(Object.assign({},n,{size:t,childrenRef:o}))))},J=["items","className","activeKey","withDecorator","defaultActiveKey","onChange"],L=["withDecorator"],I=["children"],P=e=>{let{items:t,className:n,activeKey:s,withDecorator:o,defaultActiveKey:c,onChange:d}=e,u=(0,l.A)(e,J);return(0,a.A)((0,a.A)({},u),{},{className:i()(n,"tabs-modal"),withDecorator:e=>{const n=n=>(0,g.jsx)(r.Tabs,{items:t.map(t=>{let{withDecorator:a}=t,s=(0,l.A)(t,L);return Object.assign({},s,{children:"function"===typeof a?a(t=>e(Object.assign({},n,t,{children:s.children}))):e(Object.assign({},n,{children:s.children}))})}),destroyInactiveTabPane:!0,activeKey:s,defaultActiveKey:c,onChange:d});return"function"===typeof o?o(n):n()},children:e=>{let{children:t}=e,n=(0,l.A)(e,I);return"function"===typeof t?t(n):t}})},k=e=>(0,g.jsx)(H,(0,a.A)({},P(e))),F=()=>{const e=O();return t=>e(P(t))};var T=n(73025);const M=["modalProps"],R=e=>{const t=F();return e.api?(0,g.jsx)(T.A,(0,a.A)((0,a.A)({},e),{},{modalFunc:t})):(0,g.jsx)(r.Button,(0,a.A)((0,a.A)({},e),{},{onClick:()=>{t(e.modalProps)}}))},D=e=>{const t=O();if(!e.api){const{modalProps:n}=e,s=(0,l.A)(e,M);return(0,g.jsx)(r.Button,(0,a.A)((0,a.A)({},s),{},{onClick:()=>{t(n)}}))}return(0,g.jsx)(T.A,(0,a.A)((0,a.A)({},e),{},{modalFunc:t}))}},12392(e,t,n){n.d(t,{Bm:()=>W,Eo:()=>E,NR:()=>w,Ay:()=>K});var a=n(55199),l=n(83136),s=n.n(l),r=n(89379),o=n(53986),i=n(30509),c=n(25438),d=n(78784),u=n(33097),p=n.n(u),m=n(34677),h=n.n(m);const _="create-list_scroll-loader__zoaS7__HJ3UV",g="create-list_is-popup__t3d-G__HJ3UV",f="create-list_is-not-full__FXtX1__HJ3UV",x="create-list_search-input__tV3vf__HJ3UV",A="create-list_left__EXr3i__HJ3UV",y="create-list_list-header__3xeJa__HJ3UV",v="create-list_is-modal__BMfya__HJ3UV";var C=n(73161),j=n(47458),b=n(70579);const N=["extra"],S=i.A.useContext,w=e=>{let{renderList:t,defaultProps:n}=e;const l=e=>{let{value:n,setValue:l}=e;const{fetchApi:r,searchText:o,setSearchText:i,props:u,mapping:m}=S(),N=Object.assign({},{paramsType:"data",current:"currentPage",pageSizeName:"perPage",pageSize:20},u.pagination),w=p()(r.requestParams,[N.paramsType,N.current],1),V=p()(r.requestParams,[N.paramsType,N.pageSizeName])||N.pageSize,{formatMessage:O}=(0,j.useIntl)({moduleName:"Common"}),U=u.dataFormat(r.data),{right:H,leftBottom:J,leftSpan:L=24}=u,I=1===n.length&&"all"===n[0];return(0,b.jsxs)(a.Row,{wrap:!1,className:H?s()("is-not-full",f):"",children:[(0,b.jsxs)(a.Col,{span:L,className:s()(A,"advance-select-left"),children:[u.getSearchProps?(0,b.jsx)(C.A,{isPopup:u.isPopup,className:s()(x,c.A["search-input"],{[c.A["is-popup"]]:u.isPopup}),placeholder:u.searchPlaceholder||O({id:"search"}),value:o,onSearch:e=>{r.reload(u.getSearchProps(e)),i(e)}}):null,u.single||!u.showSelectedCount&&!u.allowSelectAll?null:(0,b.jsxs)(a.Flex,{className:s()(y,{[v]:!u.isPopup}),justify:"space-between",children:[u.showSelectedCount?(0,b.jsxs)(a.Space,{children:[(0,b.jsx)(a.Typography,{children:"\u5df2\u9009:"}),(0,b.jsx)(a.Typography.Link,{children:I?u.allLabel||(0,b.jsx)(j.FormattedMessage,{id:"all",moduleName:"Common"}):"".concat(n.length).concat(u.countUnit||O({id:"items"}))})]}):(0,b.jsx)("div",{}),u.allowSelectAll?(0,b.jsx)("div",{children:(0,b.jsx)(a.Checkbox,{checked:I,onChange:e=>{l(e.target.checked?[u.allValue||"all"]:[])},children:(0,b.jsx)(j.FormattedMessage,{id:"selectAll",moduleName:"Common",values:{label:u.allLabel||(0,b.jsx)(j.FormattedMessage,{id:"all",moduleName:"Common"})}})})}):(0,b.jsx)("div",{})]}),(0,b.jsx)(d.default,{completeTips:"",isLoading:!r.isComplete,className:s()(_,{[g]:u.isPopup}),noMore:!U.total||w*V>=U.total,onLoader:async()=>{console.log("on loader"),await r.loadMore(h()({[N.paramsType]:{[N.pageSizeName]:V,[N.current]:w+1}},u.getSearchProps&&u.getSearchProps(o)),u.mergeList)},children:(()=>{const e={props:u,value:n,setValue:l,list:U.list,data:r.data,fetchApi:r,itemIsSelected:e=>n.indexOf(e.value)>-1,isSelectedAll:I,onSelect:e=>{if(u.single)return void l([e.value]);const t=n.slice(0),a=t.indexOf(e.value);a>-1?t.splice(a,1):t.push(e.value),l(t)}},a=t(e);return"function"===typeof u.dropdownRender?u.dropdownRender(Object.assign({},e,{children:a})):a})()}),J&&J({fetchApi:r,value:n,mapping:m})]}),H&&H({value:n,mapping:m,fetchApi:r})]})};return e=>{const t=Object.assign({},{isPopup:!0,pagination:{},mergeList:(e,t)=>Object.assign({},t,{pageData:e.pageData.concat(t.pageData)}),dataFormat:e=>({list:e.pageData,total:e.totalCount})},n,e),{extra:a}=t,s=(0,o.A)(t,N);return(0,b.jsx)(i.A,(0,r.A)((0,r.A)({},s),{},{extra:a,children:e=>{let{value:t,setValue:n}=e;return(0,b.jsx)(l,{value:t,setValue:n})}}))}},V="list_list__TGynD__HJ3UV",O="list_list-item__WSswf__HJ3UV",U="list_is-selected__6Wkgt__HJ3UV",H="list_item-label__bYzhe__HJ3UV",J="list_item-des__2nsEn__HJ3UV",L="list_is-disabled__qxCvO__HJ3UV",I="list_is-selected-all__Mp-hG__HJ3UV";var P=n(40438),k=n(64671);const F="user_list-inner__V508e__HJ3UV",T="user_list-info__y2nWo__HJ3UV",M="user_selected-icon__9OQJL__HJ3UV",R="user_item-des__o+7UR__HJ3UV",D="user_is-selected-all__2q0VZ__HJ3UV",E=w({renderList:e=>{let{list:t,onSelect:n,itemIsSelected:l,isSelectedAll:o}=e;return(0,b.jsx)(a.List,{size:"small",className:s()(V,{[I]:o,[D]:o}),dataSource:t,renderItem:e=>{const t=l(e);return(0,b.jsx)(a.List.Item,{className:s()(O,{[U]:t}),onClick:()=>n(e),children:(0,b.jsxs)(a.Row,{wrap:!1,align:"middle",className:F,children:[(0,b.jsx)(a.Col,{children:(0,b.jsx)(P.default.Avatar,(0,r.A)((0,r.A)({},Object.assign({},e.avatar)),{},{size:40,gender:"M"}))}),(0,b.jsx)(a.Col,{className:T,flex:1,children:(0,b.jsxs)(a.Space,{direction:"vertical",children:[(0,b.jsx)("span",{className:H,children:e.label}),e.description&&(0,b.jsx)("span",{className:R,children:e.description})]})}),(0,b.jsx)(a.Col,{children:o||t?(0,b.jsx)(k.default,{className:M,type:"icon-gouxuan"}):null})]})})}})}}),z={"is-selected-all":"table_is-selected-all__IwXUY__HJ3UV"},W=w({defaultProps:{overlayWidth:"450px"},renderList:e=>{let{props:t,list:n,onSelect:l,value:r,setValue:o,itemIsSelected:i,isSelectedAll:c}=e;return(0,b.jsx)(a.Table,{className:s()(z.list,V,{[I]:c,[z["is-selected-all"]]:c}),size:"small",dataSource:n,columns:t.columns,rowClassName:e=>s()({"ant-table-row-selected":i(e)}),rowKey:t.rowKey||"value",pagination:!1,rowSelection:t.single?null:c?{selectedRowKeys:n.map(e=>{let{value:t}=e;return t}),getCheckboxProps:()=>({disabled:!0})}:{selectedRowKeys:r,onChange:e=>{o(e)}},sticky:!0,onRow:e=>({onClick:()=>l(e)})})}}),K=w({renderList:e=>{let{props:t,list:n,itemIsSelected:l,isSelectedAll:r,onSelect:o}=e;const{listClassName:i="",selectIcon:c=null}=t||{};return(0,b.jsx)(a.List,{className:s()(V,i,{[I]:r}),size:"small",dataSource:n,renderItem:e=>{var n;const i=l(e);return(0,b.jsxs)(a.List.Item,{className:s()(O,{[U]:t.single&&i,[L]:r||e.disabled}),onClick:()=>{e.disabled||o(e)},children:[(0,b.jsxs)(a.Row,{wrap:!1,children:[t.single?null:(0,b.jsx)(a.Col,{children:(0,b.jsx)(a.Checkbox,{checked:r||i,disabled:r||e.disabled})}),(0,b.jsx)(a.Col,{children:(0,b.jsxs)(a.Space,{className:null!==(n=null===e||void 0===e?void 0:e.className)&&void 0!==n?n:"",children:[(0,b.jsx)("span",{className:H,children:e.label}),e.description&&(0,b.jsx)("span",{className:J,children:e.description})]})})]}),i&&c]})}})}})},17342(e,t,n){n.d(t,{A:()=>s});var a=n(34581),l=n.n(a);n(46733);const s=l()},17508(e,t,n){n.d(t,{AG:()=>y,Ay:()=>f,FI:()=>A,Zi:()=>x,lN:()=>s.useFileUpload});var a=n(89379),l=n(53986),s=n(61323),r=n(55199),o=n(83136),i=n.n(o),c=n(70579);const d=["className","multiple","accept","onChange","children"],u=["children"],p=["children"],m=["className","multiple","accept","onChange","children"],h=["children"],_=["className","multiple","accept","onChange","children"],g=["children"],f=e=>t=>{let{className:n,multiple:r,accept:o,onChange:i,children:p}=t,m=(0,l.A)(t,d);return(0,c.jsx)(s.FileInput,{className:n,multiple:r,accept:o,onChange:i,children:t=>{let{children:n}=t,s=(0,l.A)(t,u);return(0,c.jsxs)(e,(0,a.A)((0,a.A)({},Object.assign({},m,s)),{},{children:[p,n]}))}})},x=e=>{let{children:t}=e,n=(0,l.A)(e,p);return(0,c.jsx)(s.FileInput,(0,a.A)((0,a.A)({},n),{},{buttonText:t}))},A=e=>{let{className:t,multiple:n,accept:o,onChange:i,children:d}=e,u=(0,l.A)(e,m);return(0,c.jsx)(s.FileInput,{className:t,multiple:n,accept:o,onChange:i,children:e=>{let{children:t}=e,n=(0,l.A)(e,h);return(0,c.jsxs)(r.Typography.Link,(0,a.A)((0,a.A)({},Object.assign({},u,n)),{},{children:[d,t]}))}})},y=e=>{let{className:t,multiple:n,accept:o,onChange:d,children:u}=e,p=(0,l.A)(e,_);return(0,c.jsx)(s.FileInput,{className:i()(t,"ant-btn"),multiple:n,accept:o,onChange:d,children:e=>{let{children:t}=e,n=(0,l.A)(e,g);return(0,c.jsxs)(r.Typography.Text,(0,a.A)((0,a.A)({},Object.assign({},p,n)),{},{children:[u,t]}))}})}},18411(e,t,n){n.d(t,{A:()=>a});n(73884);const a=n.p+"static/media/defaultAvatar.b1f2a8046cc7bee36d9a404ce6a0a1d7.svg"},20492(e,t,n){n.d(t,{A:()=>a});const a=e=>({"en-US":()=>n.e(3086).then(n.bind(n,13086)),"zh-CN":()=>n.e(4308).then(n.bind(n,84308))}[e]())},21485(e,t,n){n.d(t,{A:()=>p});var a=n(89379),l=n(53986),s=n(73884),r=n(71298),o=n.n(r),i=n(96418),c=n.n(i),d=n(70579);const u=["children","onScroll","options","onReady"],p=(0,s.forwardRef)((e,t)=>{let{children:n,onScroll:r,options:i,onReady:p}=e,m=(0,l.A)(e,u);const h=(0,s.useRef)(null),_=(0,s.useRef)(null),g=(0,s.useRef)(i),f=c()(p),x=c()(r);return(0,s.useImperativeHandle)(t,()=>_.current),(0,s.useEffect)(()=>{const e=new(o())(h.current,g.current);return _.current=e.getScrollElement(),_.current.addEventListener("scroll",x),f(_.current),()=>{_.current.removeEventListener("scroll",x)}},[x,f,n]),(0,d.jsx)("div",(0,a.A)((0,a.A)({},m),{},{ref:h,children:n}))})},25438(e,t,n){n.d(t,{A:()=>a});const a={"search-input":"common_search-input__P6qLg__HJ3UV","is-popup":"common_is-popup__fJq+g__HJ3UV",list:"common_list__TKFzS__HJ3UV","list-item":"common_list-item__ASse7__HJ3UV","is-selected":"common_is-selected__-PU4Y__HJ3UV","item-label":"common_item-label__u+qz1__HJ3UV","item-des":"common_item-des__no2z0__HJ3UV"}},27047(e,t,n){n.d(t,{A:()=>r});var a=n(83694),l=n(33097),s=n.n(l);const r=()=>{const e=(0,a.useGlobalContext)();return s()(e,"preset",{apis:{}})}},30509(e,t,n){n.d(t,{A:()=>q});var a=n(89379),l=n(53986);const s={"ant-tag":"style_ant-tag__nNp8-__HJ3UV",overlay:"style_overlay__La5mO__HJ3UV",input:"style_input__SpJTE__HJ3UV","is-disabled":"style_is-disabled__joxdl__HJ3UV","input-icon":"style_input-icon__vVd8R__HJ3UV",large:"style_large__En6mL__HJ3UV",small:"style_small__DY0AQ__HJ3UV","input-inner":"style_input-inner__PWy27__HJ3UV","input-custom":"style_input-custom__ktsWD__HJ3UV","display-content":"style_display-content__hIKo+__HJ3UV","overlay-footer-extra":"style_overlay-footer-extra__Q+BiR__HJ3UV","selected-tag":"style_selected-tag__zXZZO__HJ3UV","selected-tag-list":"style_selected-tag-list__xUIms__HJ3UV","selected-tag-inner":"style_selected-tag-inner__Z5gPL__HJ3UV","text-inner":"style_text-inner__H24hY__HJ3UV",placeholder:"style_placeholder__x0ccE__HJ3UV","is-modal":"style_is-modal__JU+uq__HJ3UV","overlay-content":"style_overlay-content__WKqp+__HJ3UV"};var r=n(74981);const{context:o,useContext:i,Provider:c,Consumer:d}=(0,r.A)();var u=n(73884),p=n(10986),m=n.n(p),h=n(87558),_=n(33097),g=n.n(_),f=n(55199),x=n(83136),A=n.n(x),y=n(3382),v=n(64671),C=n(79686),j=n.n(C),b=n(41740),N=n.n(b),S=n(74065),w=n.n(S),V=n(21485),O=n(96418),U=n.n(O),H=n(77964),J=n(91176),L=n(47458),I=n(20492),P=n(27047),k=n(70579);const F=["value","onChange","extra","showSelectedTag","renderSelectedContent","children"],T=["value","setValue","children","renderSelectedContent","showSelectedTag","placement","inputContent","single","extra","overlayWidth","wrapClassName","overlayClassName","disabled"],M=["setFetchApi","wrapClassName","getContentRef"],R=["api","className","displayItems","wrapClassName"],D=e=>{let{maxLength:t,single:n,setValue:a,value:l,message:s}=e;return e=>a(!n&&Number.isInteger(t)&&t>0&&e.length>t?(s(),l):e)},E=e=>{let{single:t,value:n,mapping:a,allValue:l,allLabel:r,onClose:o}=e;return n&&Array.isArray(n)&&0!==n.length?t?(0,k.jsx)("span",{className:s["text-inner"],children:g()(a.get(n[0]),"label")||n[0]}):1===n.length&&n[0]===(l||"all")?(0,k.jsx)("span",{className:s["text-inner"],children:r||(0,k.jsx)(L.FormattedMessage,{id:"all",moduleName:"Common"})}):n.map(e=>{const t=a.get(e);return(0,k.jsx)(f.Tag,{className:s["display-tag"],closable:!0,onClose:n=>{n.preventDefault(),o(e,t)},children:(0,k.jsx)("span",{className:s["tag-inner"],children:g()(t,"label")||e})},e)}):null},z=(0,u.forwardRef)((e,t)=>{let{value:n,onChange:r,extra:o,showSelectedTag:i,renderSelectedContent:c,children:d}=e,p=(0,l.A)(e,F);const[m,h]=(0,u.useState)(n),_=(0,u.useRef)(n),{formatMessage:g}=(0,L.useIntl)({moduleName:"Common"});_.current=n;const[x,A]=(0,u.useState)(!1),v=e=>{var t;A(e),null===(t=p.onOpenChange)||void 0===t||t.call(p,e)},{message:C}=f.App.useApp(),j=D({maxLength:p.maxLength,single:p.single,setValue:h,value:m,message:()=>C.error(g({id:"maxSelectedCount"},{count:p.maxLength}))});return(0,u.useEffect)(()=>{x&&h(_.current)},[x]),(0,u.useImperativeHandle)(t,()=>({modalOpen:()=>{v(!0)},close:()=>{v(!1)}})),(0,k.jsx)(y.default,(0,a.A)((0,a.A)({},p),{},{open:x,onConfirm:()=>{r(m)},onClose:()=>{v(!1)},footer:(0,k.jsxs)(f.Space,{direction:"vertical",className:s["overlay-footer"],children:[o&&(0,k.jsx)("div",{className:s["overlay-footer-extra"],children:o}),i&&c({value:m,setValue:j})]}),children:"function"===typeof d?d({value:m,setValue:j}):d}))}),W=(0,u.forwardRef)((e,t)=>{let{value:n,setValue:r,children:o,renderSelectedContent:i,showSelectedTag:c,placement:d,inputContent:p,single:m,extra:h,overlayWidth:_,wrapClassName:g,overlayClassName:x,disabled:y}=e,v=(0,l.A)(e,T);const[C,j]=(0,u.useState)(!1),b=U()(e=>{var t;j(e),null===(t=v.onOpenChange)||void 0===t||t.call(v,e)});return(0,u.useImperativeHandle)(t,()=>({close:()=>{b(!1)}}),[b]),y?(0,k.jsx)("div",{className:s["input-inner"],children:p}):(0,k.jsx)(f.Popover,(0,a.A)((0,a.A)({},v),{},{open:C,onOpenChange:b,transitionName:"ant-slide-up",overlayClassName:A()(s.overlay,x),arrow:!1,content:(0,k.jsxs)("div",{style:_?{"--overlay-width":_}:{},className:A()(s["overlay-content"],"over-content"),onClick:e=>{e.stopPropagation()},children:[(0,k.jsx)("div",{className:s["overlay-inner"],children:"function"===typeof o?o({value:n,setValue:e=>{(!m||n[0]!==e[0])&&r(e),m&&b(!1)}}):o}),(c||h)&&(0,k.jsxs)("div",{className:s["overlay-footer"],children:[h&&(0,k.jsx)("div",{className:s["overlay-footer-extra"],children:h}),c&&i({value:n,setValue:r})]})]}),trigger:"click",placement:d,children:(0,k.jsx)("div",{className:s["input-inner"],children:p})}))}),K=(0,h.withFetch)(e=>{let{setFetchApi:t,wrapClassName:n,getContentRef:a}=e,r=(0,l.A)(e,M);const[o,c]=(0,u.useState)(!1),d=(0,u.useRef)(null),p=(0,u.useRef)(null),m=i(),{valueState:h,mapping:_,props:g,inputWidth:x}=m,[y,C]=h,{formatMessage:j}=(0,L.useIntl)({moduleName:"Common"}),{single:b,placement:N,getPopupContainer:S,placeholder:w,isPopup:O,disabled:H,showSelectedTag:I,extra:P,inputContent:F,allowClear:T,overlayClassName:R}=g,D=(0,u.useRef)(r);D.current=r;const K=U()(a);(0,u.useEffect)(()=>{K(O?p:d)},[O,K]),(0,u.useEffect)(()=>{t(Object.assign({},D.current,{data:r.data,isComplete:r.isComplete}))},[r.data,t,r.isComplete]);const B=E({single:b,value:y,mapping:_,allValue:g.allValue,allLabel:g.allLabel,onClose:e=>{C(t=>{const n=t.slice(0),a=t.indexOf(e);return a>-1&&n.splice(a,1),n})}}),q=e=>{let{value:t,setValue:n}=e;return(0,k.jsxs)(f.Space,{className:s["selected-tag"],align:"center",wrap:!1,children:[(0,k.jsxs)("div",{children:[(0,k.jsx)(L.FormattedMessage,{id:"selectedTextAdvanced",moduleName:"Common",defaultMessage:"\u5df2\u9009"}),!g.single&&Number.isInteger(g.maxLength)&&g.maxLength>0?"(".concat(t.length,"/").concat(g.maxLength,")"):"",":"]}),(0,k.jsx)(V.A,{className:s["selected-tag-list"],children:(0,k.jsx)("div",{className:s["selected-tag-inner"],children:E({value:t,mapping:_,allValue:g.allValue,allLabel:g.allLabel,onClose:e=>{n(t=>{const n=t.slice(0),a=t.indexOf(e);return a>-1&&n.splice(a,1),n})}})})})]})},Q=F?F(m):(0,k.jsxs)(f.Space,{className:s["display-content"],onMouseOver:()=>{c(!0)},onMouseOut:()=>{c(!1)},children:[(0,k.jsx)("div",{children:B||(0,k.jsx)("span",{className:s.placeholder,children:w||j({id:"pleaseSelect"})})}),o&&y&&y.length>0&&!H&&T?(0,k.jsx)(v.default,{className:A()(s.close,s["input-icon"],"close","input-icon"),type:"icon-shibai",onClick:e=>{e.stopPropagation(),C([])}}):(0,k.jsx)(v.default,{className:A()(s["input-icon"],"input-icon-arrow","input-icon"),type:"icon-arrow-thin-down"})]});return O?(0,k.jsx)(W,{ref:p,overlayWidth:(0,J.v)(Math.max(x,(0,J.j)(g.overlayWidth))),value:y,setValue:C,single:b,disabled:H,inputContent:Q,onOpenChange:g.onOpenChange,overlayClassName:R,extra:"function"===typeof P?P({close:()=>p.current.close(),context:m}):P,renderSelectedContent:q,showSelectedTag:I,trigger:"click",placement:N,getPopupContainer:S,children:g.children}):(0,k.jsxs)("div",{className:s["input-inner"],onClick:()=>{H||d.current.modalOpen()},children:[(0,k.jsx)(z,{size:g.modalSize,ref:d,single:g.single,maxLength:g.maxLength,onOpenChange:g.onOpenChange,disabledScroller:!0,wrapClassName:A()(s.overlay,s["is-modal"],n),title:g.placeholder||j({id:"pleaseSelect"}),value:y,onChange:C,extra:"function"===typeof P?P({close:()=>d.current.close(),context:m}):P,showSelectedTag:I,renderSelectedContent:q,children:g.children}),Q]})}),B=(0,L.createWithIntl)({importMessages:I.A,moduleName:"Common"})(e=>{const t=Object.assign({},{displayItems:[],extra:null,api:{loader:()=>[]},dataFormat:e=>({list:e}),placement:"bottomLeft",showSelectedTag:!0,allowClear:!0},e),{api:n,className:r,displayItems:o,wrapClassName:i}=t,d=(0,l.A)(t,R),{locale:p}=(0,P.A)(),[h,_]=(0,u.useState)(""),[x,y]=(0,u.useState)(new Map(o.map(e=>[e.value,e]))),{formatMessage:v}=(0,L.useIntl)({moduleName:"Common"}),[C,b]=(0,u.useState)(0),S=(0,H.A)(e=>{b(e.clientWidth)}),[V,O]=(0,u.useState)({}),{message:U}=f.App.useApp(),J=e=>{const t=e.filter(e=>x.get(e.value)!==e);0!==t.length&&y(e=>{const n=N()(e);return t.forEach(e=>{n.set(e.value,e)}),n})},I=e=>((e,t)=>Array.isArray(e)&&e.every(e=>e&&e.hasOwnProperty("value")&&e.hasOwnProperty("label"))?(t(e),e.map(e=>e.value)):e)(d.single?j()(e)?[]:[e]:e||[],J,d.valueType),[F,T]=m()(Object.assign({},d,{onChange:e=>{const t=((e,t,n)=>"all"!==n?e:e.map(e=>t.get(e)).filter(e=>!!e))(e,x,d.valueType);d.onChange&&d.onChange(d.single?w()(t):t)}},"value"in d?{value:I(d.value)}:{defaultValue:I(d.defaultValue)})),M=D({maxLength:d.maxLength,single:d.single,setValue:T,value:F,message:()=>U.error(v({id:"maxSelectedCount"},{count:d.maxLength}))}),E=(0,u.useRef)(null);return(0,k.jsx)(c,{value:{inputWidth:C,mapping:x,searchText:h,setSearchText:_,appendMapping:J,setItems:e=>{V.setData(e),J(g()(d.dataFormat(e,{locale:p}),"list",[]))},getContentApi:()=>E.current,fetchApi:V,valueState:[F,M],props:d},children:(0,k.jsx)("div",{ref:S,className:A()(s["input".concat(d.inputContent&&"function"===typeof d.inputContent?"-custom":"")],{"select-input-disabled":!!d.disabled},r),children:(0,k.jsx)(K,(0,a.A)((0,a.A)({},n),{},{wrapClassName:i,loading:null,setFetchApi:O,getContentRef:e=>{e.current&&(E.current=e.current)},onRequestSuccess:e=>{J(g()(d.dataFormat(e,{locale:p}),"list",[])),n.onRequestSuccess&&n.onRequestSuccess(e)}}))})})});B.useContext=i;const q=B},40438(e,t,n){n.r(t),n.d(t,{default:()=>w});var a=n(89379),l=n(53986),s=n(87558),r=n.n(s),o=n(97211),i=n(64671),c=n(83136),d=n.n(c),u=n(55199),p=n(73884);const m=e=>{let{params:t}=e;const{data:n}=t;return new Promise((e,t)=>{const a=new window.Image;a.src=n,a.addEventListener("load",()=>{e(n)}),a.addEventListener("error",e=>{t(e)})})},h="style_img-outer__4QLY5__HJ3UV",_="style_img__PSExq__HJ3UV",g="style_loading__WCOwA__HJ3UV",f="style_error__+ECgZ__HJ3UV";var x=n(18411),A=n(72752),y=n(70579);const v=["id","src","alt","onClick","loading","error","className","apis"],C=["id","src","alt","gender","loading","error","className","gap","icon","children","shape","size","width","height","defaultAvatar","apis"],j=e=>{let{data:t,className:n,alt:a,innerLoading:l,loading:s=(0,y.jsx)(u.Skeleton.Avatar,{shape:"square",active:!0}),error:o=(0,y.jsx)(i.default,{role:"error-icon",colorful:!0,type:"icon-color-touxiang-nan"}),innerError:c,children:p,onClick:h,staticUrl:g}=e;const{staticUrl:f}=(0,A.usePreset)(),x=g||f||"";return(0,y.jsx)(r(),{loader:m,params:{data:/^https?:\/\//.test(t)?t:x+t},error:c||o,loading:l||s,render:e=>{let{data:t}=e;return"function"===typeof p?p({alt:a,className:d()(n,_),src:t}):(0,y.jsx)("img",{alt:a,className:d()(n,_),src:t,onClick:h})}})},b=(0,o.A)(j),N=e=>{let{loading:t,error:n,src:a,id:l,alt:s,className:r,children:o,apis:i,onClick:c}=e;const d=t&&(0,p.cloneElement)(t,{className:g}),u=n&&(0,p.cloneElement)(n,{className:f});return a?(0,y.jsx)(j,{alt:s,className:r,data:a,loading:d,error:u,onClick:c,children:o}):l?(0,y.jsx)(b,{alt:s,className:r,id:l,loading:d,innerLoading:d,error:u,innerError:u,apis:i,onClick:c,children:o}):u},S=e=>{let{id:t,src:n,alt:s,onClick:r,loading:o=(0,y.jsx)(u.Skeleton.Avatar,{shape:"square",active:!0}),error:c=(0,y.jsx)(i.default,{role:"error-icon",colorful:!0,type:"icon-color-touxiang-nan"}),className:p,apis:m}=e,_=(0,l.A)(e,v);return(0,y.jsx)("div",(0,a.A)((0,a.A)({},_),{},{"data-testid":"components-core-image",className:d()(p,h),children:N({loading:o,error:c,src:n,id:t,alt:s,className:p,apis:m,onClick:r})}))};S.Avatar=e=>{let{id:t,src:n,alt:s,gender:r,loading:o=(0,y.jsx)(u.Skeleton.Avatar,{shape:"square",active:!0}),error:c=(0,y.jsx)(i.default,{role:"error-icon",colorful:!0,type:"icon-color-touxiang-nan"}),className:p,gap:m,icon:_,children:g,shape:f,size:A=100,width:v,height:j,defaultAvatar:b=x.A,apis:S}=e,w=(0,l.A)(e,C);const V=(()=>{const e=v&&j?{style:{width:v,height:j}}:{size:A};if(v&&v!==j&&(f="square"),t||n)return N({loading:o,error:c,src:n,defaultAvatar:b,id:t,alt:s,className:p,apis:S,children:t=>(0,y.jsx)(u.Avatar,(0,a.A)((0,a.A)({},t),{},{gap:m,shape:f},e))});if(r){const t=r&&["F","female","f"].indexOf(r)>-1?"icon-color-touxiang-nv":"icon-color-touxiang-nan";return(0,y.jsx)(u.Avatar,(0,a.A)((0,a.A)({},w),{},{src:(0,y.jsx)(i.default,{role:"touxiang",colorful:!0,type:t}),gap:m,shape:f},e))}return(0,y.jsx)(u.Avatar,(0,a.A)((0,a.A)((0,a.A)({},w),{},{gap:m,icon:_,shape:f,size:A,src:b},e),{},{children:g}))})();return(0,y.jsx)("div",(0,a.A)((0,a.A)({},w),{},{"data-testid":"components-core-image-avatar",className:d()(p,h),style:{width:v&&j?v:A,height:v&&j?j:A},children:V}))};const w=S},41654(e,t,n){n.d(t,{A:()=>f,K:()=>g});var a=n(89379),l=n(53986),s=n(45776),r=n(27047),o=n(33097),i=n.n(o),c=n(70579);const d=["apis"],u=["apis"],p=(e,t)=>"en-US"===t?i()(e,"enName"):i()(e,"chName"),m=()=>n.e(719).then(n.t.bind(n,10719,19)).then(e=>e.__esModule?e.default:e),h={cache:"FUNCTION_DATA",isLocal:!0,ttl:864e5,loader:m},_=e=>{const t=Object.assign({},{overlayWidth:"640px",getSearchProps:e=>({data:{searchText:e}})},e),{apis:n}=t,o=(0,l.A)(t,d),{apis:i,locale:u}=(0,r.A)(),m=Object.assign({},{functionData:h},null===i||void 0===i?void 0:i.staticData,n);return(0,c.jsx)(s.Ay,(0,a.A)((0,a.A)({},o),{},{api:Object.assign({},{transformData:e=>{let{data:t}=e;const{treeData:n}=(0,s.ON)(new Map(t.map(e=>[e.code,(0,a.A)((0,a.A)({},e),{},{id:e.code,label:p(e,u),parentId:e.parentCode||null})])));return n}},m.functionData)}))};_.defaultData=m;const g=e=>{let{apis:t}=e,n=(0,l.A)(e,u);const{apis:o,locale:i}=(0,r.A)(),d=Object.assign({},{functionData:h},null===o||void 0===o?void 0:o.staticData,t);return(0,c.jsx)(s.yK,(0,a.A)((0,a.A)((0,a.A)({},n),d.functionData),{},{type:"function",getLabel:e=>p(e,i),transformData:e=>{let{data:t}=e;return t}}))};_.FunctionEnum=_.Enum=g;const f=_},43856(e,t,n){n.r(t),n.d(t,{AddressEnum:()=>m.qn,AddressInputField:()=>m.TM,AddressSelectField:()=>m.Ay,AdvancedSelectField:()=>h.Ay,CascaderField:()=>g.Ay,FetchButton:()=>i.A,FetchScrollLoader:()=>o.FetchScrollLoader,FunctionEnum:()=>f.K,FunctionSelectField:()=>f.A,IndustryEnum:()=>x.W,IndustrySelectField:()=>x.A,InputFileButton:()=>p.Zi,InputFileLink:()=>p.FI,InputFileText:()=>p.AG,ScrollLoader:()=>o.default,SearchInput:()=>d.A,SelectInnerInput:()=>u.A,SimpleBar:()=>c.A,SuperSelectField:()=>_.Ay,SuperSelectTableListField:()=>_.e0,SuperSelectTreeField:()=>_.ec,SuperSelectUserField:()=>_.$9,TableField:()=>h.Bm,TypeDateRangePickerField:()=>A.A,UserField:()=>h.Eo,accept:()=>v.A,changeMoneyToChinese:()=>a.A,createAddressApi:()=>m.LH,createDeferred:()=>j(),createListField:()=>h.NR,createTreeUtils:()=>g.ON,getContainerBody:()=>l.c,getPopupContainer:()=>s,getScrollEl:()=>l.h,isNotEmpty:()=>b.A,numberToPx:()=>N.v,pxToNumber:()=>N.j,useFileUpload:()=>p.lN,useResize:()=>y.A,withAddressApi:()=>m.DF,withInputFile:()=>p.Ay,withOSSFile:()=>r.A});var a=n(69484),l=n(76801);const s=e=>{const t=e=>{const n=(0,l.h)();if(!e||e===n||!e.parentElement)return n;return[].slice.call(e.classList,0).find(e=>["ant-modal-body","ant-modal-content","ant-popover-content"].indexOf(e)>-1)?e:t(e.parentElement)};return t(e)};var r=n(97211),o=n(78784),i=n(73025),c=n(17342),d=n(73161),u=n(30509),p=n(17508),m=n(93761),h=n(12392),_=n(60586),g=n(45776),f=n(41654),x=n(53392),A=n(89319),y=n(77964),v=n(81348),C=n(1582),j=n.n(C),b=n(55490),N=n(91176)},45776(e,t,n){n.d(t,{yK:()=>I,ON:()=>g,Ay:()=>R});var a=n(53986),l=n(89379),s=n(30509),r=n(73884),o=n(96418),i=n.n(o),c=n(55199),d=n(64671),u=n(73161),p=n(33097),m=n.n(p),h=n(79686),_=n.n(h);const g=e=>{const t=Array.from(e.values()),n=t.filter(e=>null===e.parentId),a=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},l=t=>{const n=[],a=t=>{const l=e.get(t);l&&Array.isArray(l.children)&&l.children.length>0&&(n.push(...l.children),l.children.forEach(e=>{a(e.id)}))};return a(t),n},s=(t,n)=>{const a=t=>{const l=e.get(t);return l?n(l)?l:_()(l.parentId)?null:a(l.parentId):null};return a(t)},r=t=>{const a=e.get(t);if(!a)return[];const l=a.parentId;if(_()(l))return n;return e.get(l).children},o=(()=>{const e=n=>Array.isArray(n)&&n.length>0?n.map(n=>{const a=t.filter(e=>e.parentId===n.id);return Object.assign({},n,{children:e(a)})}):null;return e(n)})();return{mapping:e,getSelectedQueue:t=>{const n=e.get(t);if(!n)return[];const a=e=>{if(e.children&&e.children.length>0)return a(e.children.find(t=>t.children&&e.children.length>0)||m()(e.children,"0"));const t=l(e.parentId).find(e=>e.children&&e.children.length>0);return t?a(t):e},s=function(t){const n=[t,...arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]],a=e.get(t);return!a||_()(a.parentId)?n:s(a.parentId,n)},r=a(n);return s(m()(r,"id"))},getAllChildren:l,computedCheckboxStatus:function(t){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];if(s(t,e=>n.indexOf(e.id)>-1))return{checked:!0,indeterminate:!1};const a=(t=>{const a=t=>{const l=e.get(t);return l?(s=l,n.indexOf(s.id)>-1?l:Array.isArray(l.children)&&l.children.length>0?l.children.find(e=>!!a(e.id)):void 0):null;var s};return!!a(t)})(t);return a?{checked:!1,indeterminate:!0}:{checked:!1,indeterminate:!1}},getSiblingNode:r,findInParents:s,setNodeChecked:function(t){const n=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]).slice(0),s=t=>{const o=e.get(t);if(!o)return;n.push(t),l(t).forEach(e=>{a(n,e.id)});const i=r(t),c=i.every(e=>n.indexOf(e.id)>-1);o.parentId&&c&&(i.forEach(e=>{a(n,e.id)}),s(o.parentId))};return s(t),n},setNodeUnchecked:function(t){const n=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:[]).slice(0),l=t=>{const s=e.get(t);if(!s)return;if(n.indexOf(s.id)>-1)return void a(n,s.id);const o=r(t);s.parentId&&(o.forEach(e=>{t!==e.id&&n.push(e.id)}),l(s.parentId))};return l(t),n},treeData:o,treeMapping:new Map(o.map(e=>[e.id,e]))}};var f=n(74065),x=n.n(f),A=n(19853),y=n.n(A),v=n(17342),C=n(83136),j=n.n(C);const b={content:"style_content__Hxlt9__HJ3UV",columns:"style_columns__FmtPF__HJ3UV","content-item":"style_content-item__i6HCO__HJ3UV","last-level-area":"style_last-level-area__2y7jQ__HJ3UV","is-popup":"style_is-popup__+r3Mn__HJ3UV",menu:"style_menu__WZUVE__HJ3UV","scroll-plus-box":"style_scroll-plus-box__QcTst__HJ3UV","menu-label":"style_menu-label__iGt0Z__HJ3UV","menu-item":"style_menu-item__hXHfm__HJ3UV","checkbox-hidden":"style_checkbox-hidden__Xpx7J__HJ3UV",loading:"style_loading__ZwrVe__HJ3UV"};var N=n(87558),S=n(47458),w=n(25438),V=n(70579),O=n(27047);const U=["data","name","type","cache","children","getLabel"],H=new Map,J=(0,N.withFetch)(e=>{let{data:t,name:n,type:s,cache:o,children:i,getLabel:c}=e,d=(0,a.A)(e,U);const u=(0,r.useMemo)(()=>new Map(t.map(e=>[e.code,(0,l.A)((0,l.A)({},e),{},{id:e.code,label:c?c(e):e.chName,parentId:e.parentCode||null})])),[t,c]).get(n);return H.set("".concat(n,"_").concat(s),u),i(u,d)}),L=e=>{const{locale:t}=(0,O.A)(),n="".concat(t,"_").concat(e.name,"_").concat(e.type),a=H.get(n);return a&&!e.force?e.children(a):(0,V.jsx)(J,(0,l.A)({},e))};L.defaultProps={children:e=>m()(e,"label","")};const I=L,P=["maxLength","nodeFormat","dataFormat"],k=s.A.useContext,F=(0,N.withFetch)(e=>{let{data:t,computedIsChecked:n,onSelect:a}=e;return(0,V.jsx)(v.A,{className:b["scroll-plus-box"],children:(0,V.jsx)(c.List,{className:w.A.list,size:"small",dataSource:t,rowKey:"value",renderItem:e=>{const t=n(e);return(0,V.jsx)(c.List.Item,{className:j()(w.A["list-item"],{[w.A["is-selected"]]:t}),onClick:()=>a(e,t),children:(0,V.jsx)("span",{className:w.A["item-label"],children:e.label})})}})})}),T=e=>{let{value:t,setValue:n,size:a,selectLevel:s}=e;const{fetchApi:o,props:p}=k(),[h,_]=(0,r.useState)(""),f=i()(p.dataFormat),{formatMessage:A}=(0,S.useIntl)({moduleName:"Common"}),C=o.data,N=(0,r.useMemo)(()=>new Map(f(C).list.map(e=>[e.value,e])),[C,f]),O=(0,r.useMemo)(()=>g(N),[N]),U=(0,r.useRef)({});U.current={createMergeTree:p.createMergeTree,loadMore:o.loadMore,openLoadData:p.openLoadData,parentIdKey:p.parentIdKey,treeUtils:O};const[H,J]=(0,r.useState)(()=>{const e=t.find(e=>!!N.get(e));return O.getSelectedQueue(e||m()(o.data.find(e=>e.children&&e.children.length>0),"id")||m()(o.data,"[0].id"),N)});(0,r.useEffect)(()=>{const{openLoadData:e,loadMore:t,parentIdKey:n,createMergeTree:a,treeUtils:l}=U.current;if(!e)return;const s=N.get(x()(H));if(!s)return;const r=l.getSelectedQueue(s.id);y()(H,r)?s.hasOwnProperty("children")||t({data:{[n]:s.id}},a(s.id)):J(r)},[H,N]);const L=(e,l)=>{const s=(()=>{if(p.onlyAllowLastLevel&&e){const e=t.slice(0);return e.push(l),e}if(p.onlyAllowLastLevel){const e=t.slice(0);return e.splice(t.indexOf(l),1),e}return e?O.setNodeChecked(l,t):O.setNodeUnchecked(l,t)})();s.length>a?c.message.error(A({id:"maxSelectedCount"},{count:a})):n(p.single&&s.length>0?[x()(s)]:s)},I=e=>{const t=N.get(e);return!(!p.openLoadData||t.hasOwnProperty("children"))||t.children&&t.children.length>0},P=!p.openLoadData&&"function"===typeof p.onSearch,T=P&&h&&(0,V.jsx)(F,{data:{searchText:h},loader:e=>{let{data:t}=e;return p.onSearch(t.searchText,{mapping:N})},computedIsChecked:e=>t.indexOf(e.id)>-1,onSelect:(e,t)=>{L(!t,e.id),!t&&J(O.getSelectedQueue(e.id,N)),_("")}});return(0,V.jsxs)("div",{className:j()(b.content,{[b["is-popup"]]:p.isPopup,[b["has-search"]]:P}),style:{"--menu-item-width":p.menuItemWidth},children:[P&&(0,V.jsx)(u.A,{isPopup:p.isPopup,className:j()(w.A["search-input"],{[w.A["is-popup"]]:p.isPopup}),placeholder:p.searchPlaceholder||A({id:"search"}),value:h,onSearch:e=>{_(e)}}),T||(0,V.jsx)("div",{children:(0,V.jsx)(v.A,{className:b.scroller,options:{autoHide:!1},children:(0,V.jsxs)("div",{className:b.columns,children:[H.map((e,n)=>{const a=N.get(e),o=O.getSiblingNode(e),i=!I(null===a||void 0===a?void 0:a.id)&&n>0;return(0,V.jsx)(v.A,{className:j()(b["content-item"],{[b["last-level-area"]]:i}),children:i?(0,V.jsx)(c.Space,{wrap:!0,children:o.map(e=>(0,r.createElement)(c.Checkbox,(0,l.A)((0,l.A)({},O.computedCheckboxStatus(e.id,t)),{},{disabled:s>1&&(t.indexOf(e.parentCode)>-1||t.indexOf(e.code.slice(0,3))>-1),key:e.id,onChange:t=>L(t.target.checked,e.id)}),e.label))}):(0,V.jsx)(c.Menu,{className:j()(b.menu),onSelect:e=>{const n=N.get(e.key);if(n)if(I(n.id))J(O.getSelectedQueue(n.id,N));else{const{checked:e}=O.computedCheckboxStatus(n.id,t);L(!e,n.id)}},selectedKeys:n===H.length-1?[]:H,items:o.map(e=>({key:e.id,label:(0,V.jsxs)(c.Space,{className:j()(b["menu-item"],{[b["checkbox-hidden"]]:p.onlyAllowLastLevel&&I(e.id)}),children:[!p.onlyAllowLastLevel&&(0,V.jsx)(c.Checkbox,(0,l.A)((0,l.A)({},O.computedCheckboxStatus(e.id,t)),{},{disabled:s>1&&t.indexOf(e.parentCode)>-1,onChange:t=>L(t.target.checked,e.id)})),(0,V.jsx)("div",{className:b["menu-label"],children:e.label}),I(e.id)&&(0,V.jsx)(d.default,{className:b["menu-item-icon"],type:"icon-arrow-thin-right",size:12})]})}))})},m()(o,"[0].id",n))}),o.isComplete?null:(0,V.jsx)("div",{className:b.loading,children:(0,V.jsx)(c.Spin,{size:"small"})})]})})})]})},M=e=>{let{maxLength:t,nodeFormat:n,dataFormat:r}=e,o=(0,a.A)(e,P);return(0,V.jsx)(s.A,(0,l.A)((0,l.A)({},o),{},{dataFormat:e=>r(e,n),children:e=>{let{value:n,setValue:a}=e;return(0,V.jsx)(T,(0,l.A)((0,l.A)({},o),{},{size:t,value:n,setValue:a}))}}))};M.defaultProps={maxLength:Number.MAX_VALUE,size:"middle",isPopup:!0,overlayWidth:"460px",menuItemWidth:"180px",openLoadData:!1,onlyAllowLastLevel:!1,parentIdKey:"id",onSearch:(e,t)=>{let{mapping:n}=t;return Array.from(n.values()).filter(t=>t.label.indexOf(e)>-1)},dataFormat:(e,t)=>{const n=(e,a)=>{const l=[];return l.push(...(e||[]).map(e=>("function"===typeof t&&Object.assign(e,t(e)),e.children&&e.children.length>0&&l.push(...n(e.children,e.id)),Object.assign({},e,{value:e.id,parentId:a})))),l};return{list:n(e,null)}},createMergeTree:e=>(t,n)=>{const a=t=>t.map(t=>t.id===e?Object.assign({},t,{children:n&&n.map(t=>Object.assign({},t,{parentId:e}))}):Array.isArray(t.children)&&t.children.length>0?Object.assign({},t,{children:a(t.children)}):t);return a(t)}};const R=M},53392(e,t,n){n.d(t,{A:()=>g,W:()=>_});var a=n(89379),l=n(53986),s=n(45776),r=n(27047),o=n(33097),i=n.n(o),c=n(70579);const d=["apis"],u=["apis"],p=(e,t)=>"en-US"===t?i()(e,"enName"):i()(e,"chName"),m={cache:"INDUSTRY_DATA",isLocal:!0,ttl:864e5,loader:()=>n.e(7183).then(n.t.bind(n,57183,19)).then(e=>e.__esModule?e.default:e)},h=e=>{let{apis:t}=e,n=(0,l.A)(e,d);const{apis:o,locale:i}=(0,r.A)(),u=Object.assign({},{industryData:m},null===o||void 0===o?void 0:o.staticData,t);return(0,c.jsx)(s.Ay,(0,a.A)((0,a.A)({},n),{},{api:Object.assign({},{transformData:e=>{let{data:t}=e;const{treeData:n}=(0,s.ON)(new Map(t.filter(e=>"000"!==e.code).map(e=>[e.code,(0,a.A)((0,a.A)({},e),{},{id:e.code,label:p(e,i),parentId:e.parentCode||null})])));return n}},u.industryData)}))};h.defaultProps={overlayWidth:"635px"};const _=e=>{let{apis:t}=e,n=(0,l.A)(e,u);const{apis:o,locale:i}=(0,r.A)(),d=Object.assign({},{industryData:m},null===o||void 0===o?void 0:o.staticData,t);return(0,c.jsx)(s.yK,(0,a.A)((0,a.A)((0,a.A)({},n),d.industryData),{},{type:"function",getLabel:e=>p(e,i),transformData:e=>{let{data:t}=e;return t}}))};h.IndustryEnum=h.Enum=_;const g=h},55490(e,t,n){n.d(t,{A:()=>a.isNotEmpty});var a=n(39129)},60586(e,t,n){n.d(t,{e0:()=>A,ec:()=>y,$9:()=>v,Ay:()=>x});var a=n(89379),l=n(73884),s=n(98949),r=n.n(s),o=n(3382),i=n(40438),c=n(55199);const d="style_select-list-item-description__ndJSX__HJ3UV",u="style_select-list-item-label__gyGnt__HJ3UV",p="style_select-list-item-content__2VJnt__HJ3UV";var m=n(83136),h=n.n(m),_=(n(96316),n(70579));const g=e=>{const{props:t,open:n,onOpenChange:a,value:l,onComplete:r}=e,{placeholder:i,children:c,showSelectedTag:d,onConfirm:u}=t;return(0,_.jsx)(o.default,{title:i,open:n,onClose:()=>{a(!1)},footer:d&&(0,_.jsx)(s.SelectedTagList,{}),onConfirm:()=>{if(r(),"function"===typeof u)return u(l)},children:c(e)})},f=(0,l.forwardRef)((e,t)=>{const n=Object.assign({},{children:e=>{let{components:t}=e;return(0,_.jsxs)(c.Flex,{vertical:!0,children:[t.search,t.selectedAll,t.fetchList,t.footer,!1!==n.isPopup&&t.selectedTag]})},renderModal:g},e);return(0,_.jsx)(r(),(0,a.A)((0,a.A)({},n),{},{ref:t}))}),x=f,A=(0,l.forwardRef)((e,t)=>{const n=Object.assign({},{renderModal:g},e);return(0,_.jsx)(s.SelectTableList,(0,a.A)((0,a.A)({},n),{},{ref:t}))}),y=(0,l.forwardRef)((e,t)=>{const n=Object.assign({},{renderModal:g},e);return(0,_.jsx)(s.SelectTree,(0,a.A)((0,a.A)({},n),{},{ref:t}))}),v=(0,l.forwardRef)((e,t)=>(0,_.jsx)(f,(0,a.A)((0,a.A)({},e),{},{ref:t,renderItemContent:e=>{let{item:t,props:n}=e;const{labelKey:l,avatarKey:s,descriptionKey:r}=n,o=t[s||"avatar"];return(0,_.jsxs)(c.Flex,{gap:8,children:[(0,_.jsx)(i.default.Avatar,(0,a.A)((0,a.A)({},Object.assign({},"string"===typeof o?{id:o}:o)),{},{size:32,gender:"M"})),(0,_.jsxs)(c.Flex,{vertical:!0,gap:8,className:p,align:"flex-start",children:[(0,_.jsx)("div",{className:h()(u,"select-list-item-label"),children:t[l]}),t[r||"description"]&&(0,_.jsx)("div",{className:h()(d,"select-list-item-description"),title:t[r||"description"],children:t[r||"description"]})]})]})}})))},69484(e,t,n){n.d(t,{A:()=>l,e:()=>a});const a=1e15,l=e=>{let t,n,l,s=["\u96f6","\u58f9","\u8d30","\u53c1","\u8086","\u4f0d","\u9646","\u67d2","\u634c","\u7396"],r=["","\u62fe","\u4f70","\u4edf"],o=["","\u4e07","\u4ebf","\u5146"],i=["\u89d2","\u5206","\u6beb","\u5398"],c="",d="";if(""===e)return"";if((e=parseFloat(e))>=a)return c="\u8d85\u51fa\u6700\u5927\u5904\u7406\u6570\u5b57",console.error("\u8d85\u51fa\u6700\u5927\u5904\u7406\u6570\u5b57"),c;if(0===e)return c=s[0]+"\u5143\u6574",c;if(e<0&&(e=-e,d="\u8d1f "),-1===(e=e.toString()).indexOf(".")?(t=e,n=""):(l=e.split("."),t=l[0],n=l[1].substr(0,4)),parseInt(t,10)>0){let e=0,n=t.length;for(let a=0;a<n;a++){let l=t.substr(a,1),i=n-a-1,d=i/4,u=i%4;"0"===l?e++:(e>0&&(c+=s[0]),e=0,c+=s[parseInt(l)]+r[u]),0===u&&e<4&&(c+=o[d])}c+="\u5143"}if(""!==n){let e=n.length;for(let t=0;t<e;t++){let e=n.substr(t,1);"0"!==e&&(c+=s[Number(e)]+i[t])}}return""===c?c+=s[0]+"\u5143\u6574":""===n&&(c+="\u6574"),c=d+c,c}},73161(e,t,n){n.d(t,{A:()=>_});var a=n(89379),l=n(53986),s=n(55199),r=n(83136),o=n.n(r);const i="style_search-input__8aH1G__HJ3UV",c="style_is-popup__L0973__HJ3UV";var d=n(64671),u=n(73884),p=n(51941),m=n(70579);const h=["value","debounce","onSearch","isPopup","placeholder","className"],_=e=>{let{value:t,debounce:n=500,onSearch:r,isPopup:_,placeholder:g,className:f}=e,x=(0,l.A)(e,h);const[A,y]=(0,u.useState)(t),v=(0,u.useRef)(t),C=(0,p.useDebouncedCallback)(r,n);return(0,u.useEffect)(()=>{t!==v.current&&(y(t),v.current=t)},[t]),(0,m.jsx)(s.Input.Search,(0,a.A)((0,a.A)({},x),{},{allowClear:!0,className:o()(f,i,{[c]:_}),value:A,placeholder:g,prefix:(0,m.jsx)(d.default,{type:"icon-sousuo"}),enterButton:(0,m.jsx)(d.default,{type:"icon-sousuo"}),onChange:e=>{const t=e.target.value;v.current=t,y(t),C(t.trim())},onSearch:e=>{C(e.trim())}}))}},74981(e,t,n){n.d(t,{A:()=>l});var a=n(73884);const l=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=(0,a.createContext)(e),{Provider:n,Consumer:l}=t;return{context:t,Provider:n,Consumer:l,useContext:()=>(0,a.useContext)(t)}}},77964(e,t,n){n.d(t,{A:()=>d});var a=n(73884),l=n(79889),s=n.n(l),r=n(93950),o=n.n(r),i=n(96418),c=n.n(i);const d=(e,t)=>{const n=(0,a.useRef)(null);n.current=Object.assign({},{time:500,isDebounce:!1},t);const l=(0,a.useRef)(null),r=c()(e);return(0,a.useLayoutEffect)(()=>{const e=l.current,t=()=>window.requestAnimationFrame(()=>{e&&r(e)});t();const a=new ResizeObserver((n.current.isDebounce?o():s())(t,n.current.time));return e&&a.observe(e),()=>{a.disconnect()}},[r]),l}},78784(e,t,n){n.d(t,{default:()=>l.a});n(21219);var a=n(14311),l=n.n(a);n.o(a,"FetchScrollLoader")&&n.d(t,{FetchScrollLoader:function(){return a.FetchScrollLoader}})},81348(e,t,n){n.d(t,{A:()=>a.computedAccept});var a=n(61323)},89319(e,t,n){n.d(t,{A:()=>m});var a=n(89379),l=n(20454),s=n(55199),r=n(10986),o=n.n(r),i=n(57469),c=n.n(i),d=n(20492),u=n(47458),p=n(70579);const m=(0,u.createWithIntl)({importMessages:d.A,moduleName:"Common"})(e=>{let t=Object.assign({},((0,l.A)(e),e));const{formatMessage:n}=(0,u.useIntl)({moduleName:"Common"}),r=new Map([["date",n({id:"customTime"})],["month",n({id:"monthly"})],["week",n({id:"weekly"})]]),[i,d]=o()(t);return(0,p.jsxs)(s.Space.Compact,{children:[(0,p.jsx)(s.Select,{style:{width:"120px"},value:(null===i||void 0===i?void 0:i.type)||"date",onChange:e=>{d(t=>{var n;return{value:null!==t&&void 0!==t&&null!==(n=t.value)&&void 0!==n&&n.length?[c()(t.value[0]).startOf(e||"date"),c()(t.value[1]).endOf(e||"date")]:null,type:e||"date"}})},options:Array.from(r).map(e=>{let[t,n]=e;return{label:n,value:t}})}),(0,p.jsx)(s.DatePicker.RangePicker,(0,a.A)((0,a.A)({},t),{},{picker:(null===i||void 0===i?void 0:i.type)||"date",value:Array.isArray(null===i||void 0===i?void 0:i.value)&&2===i.value.length&&i.value.map(e=>e&&c()(e)),onChange:e=>{d(t=>(console.log(Object.assign({type:"date"},t,{value:e&&[e[0]&&new Date(e[0].startOf((null===t||void 0===t?void 0:t.type)||"date").valueOf()),e[1]&&new Date(e[1].endOf((null===t||void 0===t?void 0:t.type)||"date").valueOf())]})),Object.assign({type:"date"},t,{value:e&&[e[0]&&new Date(e[0].startOf((null===t||void 0===t?void 0:t.type)||"date").valueOf()),e[1]&&new Date(e[1].endOf((null===t||void 0===t?void 0:t.type)||"date").valueOf())]})))}}))]})})},91176(e,t,n){n.d(t,{j:()=>l,v:()=>a});const a=e=>"number"===typeof e?"".concat(e,"px"):e,l=e=>{if(!e)return 0;const t=e.match(/^\d*(\.\d*)?/);return t?Number(t[0]):0}},93761(e,t,n){n.d(t,{qn:()=>D,TM:()=>ee,LH:()=>k,Ay:()=>z,NY:()=>F,DF:()=>E});var a=n(53986),l=n(89379),s=n(30509),r=n(25438),o=n(55199),i=n(27047),c=n(83136),d=n.n(c),u=n(64671),p=n(73884),m=n(21485),h=n(56434),_=n.n(h),g=n(15797),f=n.n(g),x=n(33097),A=n.n(x);const y="style_address__DIuRX__HJ3UV",v="style_is-popup__tqVvp__HJ3UV",C="style_title__FAe12__HJ3UV",j="style_scroll-box__JWiDl__HJ3UV",b="style_scroll-plus-box__lidEW__HJ3UV",N="style_content__lAARZ__HJ3UV",S="style_col-left__WPfeS__HJ3UV",w="style_col-right__z0e9-__HJ3UV";var V=n(87558),O=n.n(V);const U=e=>({"en-US":()=>n.e(3691).then(n.bind(n,83691)),"zh-CN":()=>n.e(2253).then(n.bind(n,32253))}[e]());var H=n(47458),J=n(70579);const L=["name","data","getAddressApi","children"],I=["data"],P=s.A.useContext,k=e=>{let{city:t,province:n,country:a}=e;const l=f()(()=>{const e=[];return["gangaotai","municipality"].forEach(n=>{e.push(...t.relations[n])}),["provinces","continents"].forEach(n=>{t.relations[n].forEach(n=>{e.push(n),e.push(...t.relations[n])})}),e.map(e=>t.list[e])});return{getCity:f()(e=>{const n=t.list[e];return n?{city:n,parent:n.parentCode?t.list[n.parentCode]:null}:{city:null,parent:null}}),getChinaHotCities:f()(()=>t.relations[2].map(e=>t.list[e])),getChinaCities:f()(()=>["2",...n.relations.municipality,...n.relations.provinces,"gangaotai"].map(e=>Object.assign({id:e},t.list[e]))),getCountries:f()(()=>["1",...a.relations.continents].map(e=>Object.assign({id:e},a.list[e]))),getList:f()((e,l)=>{const{showChinaQuan:s,showForeignQuan:r}=Object.assign({},l);if("gangaotai"===e)return n.relations.gangaotai.map(e=>t.list[e]);const o=Object.assign({},t.list[e]);if(n.relations.municipality.indexOf(e)>-1)return o.name="".concat(s?"\u5168":"")+o.name,[o];const i=t.relations[e].map(e=>t.list[e]);return n.relations.provinces.indexOf(e)>-1&&s&&(o.name="\u5168"+o.name,i.splice(0,0,o)),a.relations.continents.indexOf(e)>-1&&r&&(o.name="\u5168"+o.name,i.splice(0,0,o)),i}),getNationalityList:f()(e=>{let n=_()(t);return"1"===e&&n.relations[1].unshift("410"),"350"===e&&n.relations[350].unshift("410"),n.relations[e].filter(e=>n.list[e]).map(e=>n.list[e])}),getCityByName:f()(e=>{const t=l();let n;return[t=>t.name===e,t=>t.name===e.replace(/(\u7701|\u5e02)$/,""),t=>0===e.indexOf(t.name)].find(e=>(n=t.find(e),n)),n}),combineCities:f()((e,n)=>[...n.filter(n=>t.list[n].parentCode!==e&&t.list[e].parentCode!==n&&e!==n),e]),searchCities:f()(e=>{if(!e)return[];return l().filter(t=>["pinyin","name","enName","spelling"].some(n=>t[n].toUpperCase().indexOf(e.toUpperCase())>-1)).map(e=>{const n=e.parentCode?t.list[e.parentCode]:null;return{label:n?"".concat(n.name,"\xb7").concat(e.name):e.name,value:e.code}})})}},F=(e,t)=>"en-US"===t?A()(e,"enName"):A()(e,"name"),T={cache:"CITY_DATA",isLocal:!0,ttl:864e5,loader:()=>n.e(7820).then(n.t.bind(n,37820,19)).then(e=>e.__esModule?e.default:e)},M=e=>{let{value:t,setValue:n}=e;const{fetchApi:a,props:l}=P(),[s,c]=(0,p.useState)(""),[h,_]=(0,p.useState)("2"),{formatMessage:g}=(0,H.useIntl)({moduleName:"AddressSelect"}),{locale:f}=(0,i.A)(),{getCity:x,getChinaCities:A,getCountries:V,getList:O,searchCities:U}=(0,p.useMemo)(()=>k(a.data),[a.data]),L=e=>{if(l.single)return void n([e]);const a=t.slice(0),s=a.indexOf(e);s>-1?a.splice(s,1):a.push(e),n(a)},I=s&&(0,J.jsx)(m.A,{className:b,children:(0,J.jsx)(o.List,{className:r.A.list,size:"small",dataSource:U(s),rowKey:"value",renderItem:e=>(0,J.jsx)(o.List.Item,{className:r.A["list-item"],onClick:()=>{L(e.value),c("")},children:(0,J.jsx)("span",{className:r.A["item-label"],children:e.label})})})});return(0,J.jsxs)("div",{className:d()(y,{[v]:l.isPopup}),children:[(0,J.jsx)(o.Input.Search,{className:d()(r.A["search-input"],{[r.A["is-popup"]]:l.isPopup}),placeholder:l.searchPlaceholder||g({id:"searchCity"}),prefix:(0,J.jsx)(u.default,{type:"icon-sousuo"}),enterButton:(0,J.jsx)(u.default,{type:"icon-sousuo"}),value:s,allowClear:!0,onChange:e=>{const t=e.target.value;c(t)},onSearch:e=>{c(e)}}),(0,J.jsx)("div",{className:N,children:I||(0,J.jsxs)(o.Row,{wrap:!1,children:[(0,J.jsx)(o.Col,{className:S,children:(0,J.jsx)(o.Tabs,{centered:!0,onChange:e=>{_(e)},items:[{key:"2",label:(0,J.jsx)(H.FormattedMessage,{id:"domestic",moduleName:"AddressSelect",defaultMessage:"\u56fd\u5185"}),children:(0,J.jsx)(m.A,{className:j,children:(0,J.jsx)(o.Menu,{selectedKeys:[h],onSelect:e=>{_(e.key)},items:A().map(e=>({label:F(e,f),key:e.id}))})})},{key:"1",label:(0,J.jsx)(H.FormattedMessage,{id:"abroad",moduleName:"AddressSelect",defaultMessage:"\u56fd\u5916"}),children:(0,J.jsx)(m.A,{className:j,children:(0,J.jsx)(o.Menu,{selectedKeys:[h],onSelect:e=>{_(e.key)},items:V().map(e=>({label:F(e,f),key:e.id}))})})}]})}),(0,J.jsxs)(o.Col,{flex:1,className:w,children:[(0,J.jsx)(o.Divider,{className:C,orientation:"left",children:F(x(h).city,f)}),(0,J.jsx)(m.A,{className:j,children:(0,J.jsx)(o.Space,{wrap:!0,children:O(h,{showChinaQuan:l.showChinaQuan,showForeignQuan:l.showForeignQuan}).map(e=>(0,J.jsx)(o.Tag.CheckableTag,{checked:t.indexOf(e.code)>-1,onChange:()=>{L(e.code)},children:F(e,f)},e.code))})})]})]})})]})},R=e=>(0,J.jsx)(s.A,(0,l.A)((0,l.A)({},e),{},{children:e=>{let{value:t,setValue:n}=e;return(0,J.jsx)(H.IntlProvider,{moduleName:"AddressSelect",importMessages:U,children:(0,J.jsx)(M,{value:t,setValue:n})})}}));R.defaultProps={overlayWidth:"500px",isPopup:!0,api:T,dataFormat:(e,t)=>{let{city:n}=e;const{locale:a}=Object.assign({},t);return{list:Object.values(n.list).map(e=>Object.assign({},e,{value:e.code,label:F(e,a)}))}}};const D=(0,V.withFetch)(e=>{let{name:t,data:n,getAddressApi:l,children:s}=e,r=(0,a.A)(e,L);const{locale:o}=(0,i.A)(),c=(0,p.useMemo)(()=>k(n),[n]);return l?s(c):(0,J.jsx)(O(),{cache:"city-enum",params:{name:t},loader:e=>{let{params:t}=e;const{name:n}=t;return new Promise(e=>{setTimeout(()=>{e(c.getCity(n))},0)})},render:e=>{let{data:t}=e;return s(t,Object.assign({},r,{locale:o}))}})});D.defaultProps=(0,l.A)((0,l.A)({},T),{},{displayParent:!1,children:(e,t)=>{let{city:n,parent:a}=e,{displayParent:l,locale:s}=t;return l&&a?"".concat(F(a,s),"\xb7").concat(F(n,s)):F(n,s)}});const E=e=>{const t=(0,V.withFetch)(t=>{let{data:n}=t,s=(0,a.A)(t,I);const r=(0,p.useMemo)(()=>k(n),[n]);return(0,J.jsx)(e,(0,l.A)((0,l.A)({},s),{},{addressApi:r}))});return t.defaultProps=(0,l.A)({},T),t};R.AddressEnum=R.Enum=D,R.createAddressApi=k,R.withAddressApi=E,R.getLabelForLocal=F;const z=R;var W=n(10986),K=n.n(W),B=n(78491),q=n.n(B),Q=n(20492),X=n(22616),Z=n.n(X),Y=n(1488),G=n.n(Y);const $=["isPopup","size","disabled","inputPlaceholder","onBlur","className"],ee=(0,H.createWithIntl)({importMessages:Q.A,moduleName:"Common"})(e=>{const{isPopup:t,size:n,disabled:s,inputPlaceholder:r,onBlur:i,className:c}=e,d=(0,a.A)(e,$),[u,p]=K()(e),m=["isPopup","searchPlaceholder","placeholder","overlayWidth","api","dataFormat"],{formatMessage:h}=(0,H.useIntl)({moduleName:"Common"}),_=q()(e=>{i&&i(e)});return(0,J.jsx)("div",{ref:_,children:(0,J.jsxs)(o.Row,{gutter:10,children:[(0,J.jsx)(o.Col,{span:12,children:(0,J.jsx)(z,(0,l.A)((0,l.A)({},Z()(d,m)),{},{className:c,disabled:s,single:!0,size:n,value:A()(u,"city"),onChange:e=>{p({city:e,detail:A()(u,"detail")})}}))}),(0,J.jsx)(o.Col,{span:12,children:(0,J.jsx)(o.Input,(0,l.A)((0,l.A)({},G()(d,m)),{},{className:c,placeholder:r||h({id:"pleaseInput"}),disabled:s,size:n,value:A()(u,"detail"),onChange:e=>{p({city:A()(u,"city"),detail:e.target.value})}}))})]})})})},97211(e,t,n){n.d(t,{A:()=>a.withOSSFile});var a=n(61323)}}]);
2
+ //# sourceMappingURL=3856.bfc95e79.chunk.js.map