@txgw/payout-components 1.0.3 → 1.1.0

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 (226) hide show
  1. package/dist/{AMIS-BpATHKnv.js → AMIS-CM68rg5R.js} +1 -1
  2. package/dist/Action-D420OYTJ.js +1 -0
  3. package/dist/{Alert-DwWdKr12.js → Alert-OX9rdmI_.js} +1 -1
  4. package/dist/{AnchorNav-DRGjEF5J.js → AnchorNav-Bb6l3CBp.js} +1 -1
  5. package/dist/{App-DxKgyXV1.js → App-yGweuu7Q.js} +1 -1
  6. package/dist/{Audio-BoaWMJHA.js → Audio-D2LrX_57.js} +1 -1
  7. package/dist/{Avatar-B2lZKPPh.js → Avatar-B5tWHN23.js} +1 -1
  8. package/dist/{BarCode-dEGhm4u6.js → BarCode-B-Ddq7Ng.js} +1 -1
  9. package/dist/BarCode-CMMFyYuP.js +1 -0
  10. package/dist/{Breadcrumb-BHzIF2Vg.js → Breadcrumb-BCsI9Wi1.js} +1 -1
  11. package/dist/ButtonGroup-D_O7bRiN.js +1 -0
  12. package/dist/ButtonGroupSelect-DjOQ2Tuh.js +1 -0
  13. package/dist/{ButtonToolbar-CYZ0LWsz.js → ButtonToolbar-DnLpgwNx.js} +1 -1
  14. package/dist/{CRUD-BDeg8xZI.js → CRUD-CS67DNfG.js} +1 -1
  15. package/dist/{CRUD2-DrE-2JU3.js → CRUD2-D83jPL0v.js} +1 -1
  16. package/dist/{Calendar-DkEUJJQW.js → Calendar-BN1juoTQ.js} +1 -1
  17. package/dist/Card-D2R1STX8.js +1 -0
  18. package/dist/{Card2-Dyl0FIVL.js → Card2-By_1_3R5.js} +1 -1
  19. package/dist/{Cards-DlMpwNSr.js → Cards-BnJ0Dnmz.js} +1 -1
  20. package/dist/{Carousel-CXMYZL8H.js → Carousel-BP2Kp_P6.js} +1 -1
  21. package/dist/{ChainedSelect-BQK0j-pA.js → ChainedSelect-DW0A8lQ-.js} +1 -1
  22. package/dist/{Chart-uJ8v1OSG.js → Chart-c7rzExMK.js} +1 -1
  23. package/dist/{ChartRadios-C9Ov2SCd.js → ChartRadios-DpfBUZTk.js} +1 -1
  24. package/dist/Checkbox-D4QjyHE8.js +1 -0
  25. package/dist/{Checkboxes-wud_gmq3.js → Checkboxes-kyTqIZyc.js} +1 -1
  26. package/dist/{Code-VjDT2QOS.js → Code-DEZUwJqZ.js} +1 -1
  27. package/dist/Collapse-BIGybKyX.js +1 -0
  28. package/dist/{CollapseGroup-DkMS5MXZ.js → CollapseGroup-NqmQsF_6.js} +1 -1
  29. package/dist/{Color-CZV84qNC.js → Color-BzAgZwFR.js} +1 -1
  30. package/dist/{ColorPicker-R5D1ZNwb.js → ColorPicker-gyFFvfwL.js} +1 -1
  31. package/dist/{ColumnToggler-BxHry8EL.js → ColumnToggler-CBSdO39q.js} +1 -1
  32. package/dist/{ColumnToggler-D98cb4XS.js → ColumnToggler-D1bLNGs8.js} +1 -1
  33. package/dist/Combo-DmvnORaR.js +1 -0
  34. package/dist/{ConditionBuilder-DFF8QBcW.js → ConditionBuilder-C5JUufeO.js} +1 -1
  35. package/dist/{Container-f-JHe2WE.js → Container-DCAE5tQq.js} +1 -1
  36. package/dist/{Control-dOQnC26j.js → Control-GsHoIplL.js} +1 -1
  37. package/dist/{Custom-CqKL8xv_.js → Custom-Bx2nVsmn.js} +1 -1
  38. package/dist/{Date-BcRD4sv_.js → Date-Rnv2HuTu.js} +1 -1
  39. package/dist/{DateRange-BkGu5vJl.js → DateRange-CHTOLq35.js} +1 -1
  40. package/dist/{Dialog-CQSNeqgY.js → Dialog-HcAYAj35.js} +1 -1
  41. package/dist/{DiffEditor-DU9deT5c.js → DiffEditor-rf9IWV-b.js} +1 -1
  42. package/dist/{Divider-CYwXWwc5.js → Divider-DABewo1V.js} +1 -1
  43. package/dist/{Drawer-DmUqxMKd.js → Drawer-CuWqeLlJ.js} +1 -1
  44. package/dist/{DropDownButton-C0e2mksC.js → DropDownButton-DP0ONooh.js} +1 -1
  45. package/dist/{Each-Bnhdfx44.js → Each-ZriHtex3.js} +1 -1
  46. package/dist/FieldSet-CcrjH3er.js +1 -0
  47. package/dist/{Flex-C0c49ZMP.js → Flex-BK1nhXmI.js} +1 -1
  48. package/dist/{Formula-C82aVdAD.js → Formula-NTqpJbjF.js} +1 -1
  49. package/dist/{Grid2D-BJPrAz8w.js → Grid2D-CBGidn3i.js} +1 -1
  50. package/dist/{GridNav-DCCBgvz1.js → GridNav-BAL35ab_.js} +1 -1
  51. package/dist/{Group-D_2Fn4zB.js → Group-CjeKLlwD.js} +1 -1
  52. package/dist/HBox-BxQ8irHy.js +1 -0
  53. package/dist/{Hidden-SaNCTMlZ.js → Hidden-DaGW1F82.js} +1 -1
  54. package/dist/{IFrame-2LIicqpq.js → IFrame-DcNMOS2r.js} +1 -1
  55. package/dist/{Icon-3_vNko-P.js → Icon-Cl_2Jpom.js} +1 -1
  56. package/dist/{IconPicker-DAMClR_z.js → IconPicker-DjGeRhvh.js} +1 -1
  57. package/dist/{IconSelect-CHM0oHqd.js → IconSelect-FEBbRN6a.js} +1 -1
  58. package/dist/{IconSelectStore-MNwivoh-.js → IconSelectStore-BcDfZ6q0.js} +1 -1
  59. package/dist/Image-CqTh1gC1.js +1 -0
  60. package/dist/{Images-ZGJfaN-q.js → Images-BevE2x4f.js} +1 -1
  61. package/dist/{InputArray-D3y772RO.js → InputArray-DEANCSjZ.js} +1 -1
  62. package/dist/InputCity-Fa-Ocgca.js +1 -0
  63. package/dist/{InputColor-CYmzXu5I.js → InputColor-M_d8ADse.js} +1 -1
  64. package/dist/{InputDate-BldJd84x.js → InputDate-D-Y8KxsV.js} +1 -1
  65. package/dist/{InputDateRange-KzSlI2fv.js → InputDateRange-BvwhghV-.js} +1 -1
  66. package/dist/{InputExcel-CJZWvZFT.js → InputExcel-CnM4OLSW.js} +1 -1
  67. package/dist/InputFile-S9mBNnml.js +1 -0
  68. package/dist/{InputFormula-BKxq41uR.js → InputFormula-DSMFA8FM.js} +1 -1
  69. package/dist/{InputGroup-wvaymJ-V.js → InputGroup-C8LN-ThT.js} +1 -1
  70. package/dist/InputImage-CPX7pklM.js +1 -0
  71. package/dist/InputMonthRange-BJIplqND.js +1 -0
  72. package/dist/{InputNumber-BjzsM73z.js → InputNumber-C19HwmK3.js} +1 -1
  73. package/dist/{InputQuarterRange-DQuiFCOb.js → InputQuarterRange-CyUq5A6U.js} +1 -1
  74. package/dist/{InputRange-C97bKrW6.js → InputRange-B3_VlftI.js} +1 -1
  75. package/dist/{InputRating-CpFNTZKA.js → InputRating-CCO76jk6.js} +1 -1
  76. package/dist/{InputRepeat-CN2KxX7g.js → InputRepeat-ffy-FV9Q.js} +1 -1
  77. package/dist/InputRichText-D5aBhuXB.js +1 -0
  78. package/dist/{InputSignature-CsxuK757.js → InputSignature-C8dhqBsE.js} +1 -1
  79. package/dist/InputSubForm-pTFZ6o8m.js +1 -0
  80. package/dist/{InputTable-Bt8U_tyA.js → InputTable-BseTVkuI.js} +1 -1
  81. package/dist/{InputTag-kg2v747D.js → InputTag-lyFWGEvM.js} +1 -1
  82. package/dist/{InputText-bKR0VgA6.js → InputText-BgdghvXe.js} +1 -1
  83. package/dist/{InputTree-DbdS4b2m.js → InputTree--GJZZX0g.js} +1 -1
  84. package/dist/{InputVerificationCode-DcFJRWeR.js → InputVerificationCode-DuPItq2e.js} +1 -1
  85. package/dist/{InputYearRange-ChXlMgCi.js → InputYearRange-CZdX11Ga.js} +1 -1
  86. package/dist/{JSONSchema-C_VjFVVN.js → JSONSchema-BvOFcRIn.js} +1 -1
  87. package/dist/{JSONSchemaEditor-CEgywCvJ.js → JSONSchemaEditor-DhJ88P-t.js} +1 -1
  88. package/dist/{Json-DqjhkjHF.js → Json-BsgN5qcJ.js} +1 -1
  89. package/dist/{Link-9hUnE5FW.js → Link-DFR8SHgX.js} +1 -1
  90. package/dist/List-ByWIoyuh.js +1 -0
  91. package/dist/{ListSelect-lX84FGAP.js → ListSelect-3eDDrMA_.js} +1 -1
  92. package/dist/{LocationPicker-DnA8QpYh.js → LocationPicker-ybjVDQ2V.js} +1 -1
  93. package/dist/Log-CREZ5njl.js +1 -0
  94. package/dist/{Mapping-X2IRbppi.js → Mapping-B8ItEgTe.js} +1 -1
  95. package/dist/{Markdown-ByuMaB2P.js → Markdown-Bcl72sEX.js} +1 -1
  96. package/dist/{Markdown-BlxcmdTl.js → Markdown-D0bdiDuL.js} +1 -1
  97. package/dist/{MatrixCheckboxes-BvBU1E-4.js → MatrixCheckboxes-DdU_nnr0.js} +1 -1
  98. package/dist/{MultilineText-BmbIytvk.js → MultilineText-C3pkd141.js} +1 -1
  99. package/dist/{Nav-BxS7kBh9.js → Nav-Dte1RgqQ.js} +1 -1
  100. package/dist/{NestedSelect-CbWnin5b.js → NestedSelect-DC6jwkrQ.js} +1 -1
  101. package/dist/{Number-CGYpvopX.js → Number--P4xC2M_.js} +1 -1
  102. package/dist/{OfficeViewer-DBFFaH5P.js → OfficeViewer-C_cwhHYT.js} +1 -1
  103. package/dist/{Operation-j5yIUDkZ.js → Operation-cXbTSVW3.js} +1 -1
  104. package/dist/{Page-CJ2gK3vA.js → Page-D-XPAVqf.js} +1 -1
  105. package/dist/{Pagination-BDEmomCQ.js → Pagination-Didl7WSS.js} +1 -1
  106. package/dist/{PaginationWrapper-Bnsk8oIg.js → PaginationWrapper-XCkiXk5h.js} +1 -1
  107. package/dist/{Panel-DKpM1Qfc.js → Panel-CYHksr4M.js} +1 -1
  108. package/dist/{Password-CzHAzi8M.js → Password-CvWqk6ob.js} +1 -1
  109. package/dist/{Picker-D5WVPGTg.js → Picker-CiJw41qb.js} +1 -1
  110. package/dist/{Plain-oyGNzh1N.js → Plain-Climm5xS.js} +1 -1
  111. package/dist/{PopUp-DaheG-Vv.js → PopUp-COxX3IAH.js} +104 -104
  112. package/dist/{Portlet-dA2P7U6i.js → Portlet-BCW-gUdF.js} +1 -1
  113. package/dist/{Progress-D2LXKzUA.js → Progress-DBNPysOG.js} +1 -1
  114. package/dist/{Property-CekATdUy.js → Property-DdZPiZjm.js} +1 -1
  115. package/dist/{QRCode-DPoyEXK3.js → QRCode-PscItVbg.js} +1 -1
  116. package/dist/{Radio-HhPQKIKk.js → Radio-BMTh4Vc-.js} +1 -1
  117. package/dist/{Radios-DVzovX2u.js → Radios-BJQzOFWs.js} +1 -1
  118. package/dist/Remark-B9lXsYnM.js +1 -0
  119. package/dist/{RichText-wfPXQmb8.js → RichText-YBmfqP7K.js} +1 -1
  120. package/dist/{SearchBox-Jlwq8w3o.js → SearchBox-8TTon1Qg.js} +1 -1
  121. package/dist/{Select-DCB0i1Ga.js → Select-B-Diud2_.js} +1 -1
  122. package/dist/{Service-Bmfl8VSD.js → Service-BzPMjZsC.js} +1 -1
  123. package/dist/{Shape-5ZBBe1x0.js → Shape-H3GlFCsv.js} +1 -1
  124. package/dist/{Slider-pb5I0Xb2.js → Slider-CegLiXRn.js} +1 -1
  125. package/dist/{SparkLine-C4x34-6K.js → SparkLine-HFdKefmW.js} +1 -1
  126. package/dist/{Spinner-SR1wYU_1.js → Spinner-BfkWdJxA.js} +1 -1
  127. package/dist/{StaticHoc-DVc-5HZA.js → StaticHoc-BFjSxS01.js} +1 -1
  128. package/dist/{Status-7D4DBjk6.js → Status-CVsR4hla.js} +1 -1
  129. package/dist/{Steps-Dd_3MM0y.js → Steps-CUGsvohB.js} +1 -1
  130. package/dist/{Switch-CZqzJH45.js → Switch-CgTLMMxn.js} +1 -1
  131. package/dist/{SwitchContainer-L7IwrheV.js → SwitchContainer-Cq5nGkUH.js} +1 -1
  132. package/dist/Table-CtPiFO5y.js +1 -0
  133. package/dist/{Table2-CIZ93hrj.js → Table2-BTfFLrJy.js} +1 -1
  134. package/dist/{TableView-CigjcDJc.js → TableView-C7wVLaMb.js} +1 -1
  135. package/dist/{Tabs-Cljj-nTv.js → Tabs-DYbrDcE6.js} +1 -1
  136. package/dist/{TabsTransfer-BXwrW4NX.js → TabsTransfer-DPypfisf.js} +1 -1
  137. package/dist/{TabsTransferPicker-DB005nER.js → TabsTransferPicker-Dw1dbvwK.js} +1 -1
  138. package/dist/{Tag-CcfwT8FM.js → Tag-CMOiFppm.js} +1 -1
  139. package/dist/{Tasks-DeVW2Tdg.js → Tasks-D9XgeIzx.js} +1 -1
  140. package/dist/{Textarea-zsHcK0rZ.js → Textarea-C67KJSMF.js} +1 -1
  141. package/dist/{Timeline-D_3FRzUa.js → Timeline-DMKF0PW_.js} +1 -1
  142. package/dist/{TooltipWrapper-BElQhX67.js → TooltipWrapper-DFoUn1-Z.js} +1 -1
  143. package/dist/{Tpl-OPfW08Kh.js → Tpl-C6lLFZE7.js} +1 -1
  144. package/dist/Transfer-BgbxVlVM.js +1 -0
  145. package/dist/{TransferPicker-xlJfwHxP.js → TransferPicker-Di2yWAKS.js} +1 -1
  146. package/dist/{TreeSelect-BTKg9Ldf.js → TreeSelect-u76hHz7x.js} +1 -1
  147. package/dist/{UUID-BkwpeiT9.js → UUID-BQrPfyRW.js} +1 -1
  148. package/dist/{UserSelect-CsY5PQp9.js → UserSelect-CqpYW4gK.js} +1 -1
  149. package/dist/{VBox-Ca4DBR6-.js → VBox-Bg3hZgQ2.js} +1 -1
  150. package/dist/{Video-CXzxq3vU.js → Video-CtAf8rPO.js} +1 -1
  151. package/dist/{WebComponent-DYxJeu6a.js → WebComponent-YyQh4fcQ.js} +1 -1
  152. package/dist/{Wizard-fqzq2OCn.js → Wizard-C8hBTALf.js} +1 -1
  153. package/dist/{Words-V70QrARW.js → Words-BpUg7mc1.js} +1 -1
  154. package/dist/{Wrapper-BtFbBBXy.js → Wrapper-AnBzbtM_.js} +1 -1
  155. package/dist/_getTag-CNNwuCU_.js +1 -0
  156. package/dist/beneficiary-form-CXVut-7L.js +10 -0
  157. package/dist/{client-BoE-UyzU.js → client-o7kL9c9O.js} +1 -1
  158. package/dist/{crypto-js-Cv2Y8hvs.js → crypto-js-Q_GdNXmw.js} +1 -1
  159. package/dist/{doc-CmSOujco.js → doc-BH70Fa8Z.js} +1 -1
  160. package/dist/{es-DY5--nMG.js → es-BHW_hpQy.js} +1 -1
  161. package/dist/{esm-DyRrwLZv.js → esm-BcyTHOtS.js} +1 -1
  162. package/dist/esm-BmJ_y26h.js +28 -0
  163. package/dist/esm-HJl7vXYN.js +4 -0
  164. package/dist/{function-C8ta9DKb.js → function-Bv9HjNfK.js} +2 -2
  165. package/dist/index.css +1 -1
  166. package/dist/index.d.ts +4 -1
  167. package/dist/index.js +1 -1
  168. package/dist/isEqual-DVixCO8o.js +1 -0
  169. package/dist/{main-CLaM-mkN.js → main-C3dLbvVt.js} +1 -1
  170. package/dist/mi18n-react.esm-AFBvyBKc.js +1 -0
  171. package/dist/{objectSpread2-BCtAXXta.js → objectSpread2-BVLMCUKL.js} +1 -1
  172. package/dist/{omitBy-NMzUUhXs.js → omitBy-2E6rLjxO.js} +1 -1
  173. package/dist/{papaparse.min-CU0u_rom.js → papaparse.min-DNwbRM7w.js} +1 -1
  174. package/dist/{react-BW4ssgUo.js → react-1dn4ot9O.js} +1 -1
  175. package/dist/{react-cropper.es-zEJdZmmN.js → react-cropper.es-CJ1ZxeY0.js} +1 -1
  176. package/dist/react-dom-sh4H0cZ5.js +1 -0
  177. package/dist/rolldown-runtime-Ch1CtRr1.js +1 -0
  178. package/dist/xor-yKpUzT1Q.js +1 -0
  179. package/package.json +7 -6
  180. package/dist/Action-B0KUcn27.js +0 -1
  181. package/dist/Action-CzJ_r33l.js +0 -1
  182. package/dist/BarCode-BnchzdIg.js +0 -1
  183. package/dist/ButtonGroup-BMvNPoKc.js +0 -1
  184. package/dist/ButtonGroupSelect-BmQIuhWU.js +0 -1
  185. package/dist/ButtonGroupSelect-CfNu0OBj.js +0 -1
  186. package/dist/Card-BVUWwkgm.js +0 -1
  187. package/dist/Card-IZbcizfw.js +0 -1
  188. package/dist/Checkbox-DAq7LXTe.js +0 -1
  189. package/dist/Checkbox-DbHhD7iK.js +0 -1
  190. package/dist/Collapse-CRIu-D5O.js +0 -1
  191. package/dist/Collapse-CknZKNKz.js +0 -1
  192. package/dist/Combo-BUD7tb8b.js +0 -1
  193. package/dist/FieldSet-BRfWbiPG.js +0 -1
  194. package/dist/FieldSet-f-m_bp4h.js +0 -1
  195. package/dist/HBox-CG3Ad5us.js +0 -1
  196. package/dist/HBox-CRrACS8I.js +0 -1
  197. package/dist/Image-Br7JbiAF.js +0 -1
  198. package/dist/Image-hHgZkb5C.js +0 -1
  199. package/dist/InputCity-CF6mEwuH.js +0 -1
  200. package/dist/InputFile-C0FUNeFM.js +0 -1
  201. package/dist/InputFile-DFjvYmV3.js +0 -1
  202. package/dist/InputImage-CLuXGhoy.js +0 -1
  203. package/dist/InputImage-DasZBpb-.js +0 -1
  204. package/dist/InputMonthRange-DVRnBZ4I.js +0 -1
  205. package/dist/InputRichText-BXjRSQFh.js +0 -1
  206. package/dist/InputRichText-DdyJFH82.js +0 -1
  207. package/dist/InputSubForm-Ddweo6dR.js +0 -1
  208. package/dist/List-BBntusL0.js +0 -1
  209. package/dist/List-C8nPjG1-.js +0 -1
  210. package/dist/Log-CRxPlj86.js +0 -1
  211. package/dist/Remark-CHTOdmdn.js +0 -1
  212. package/dist/Remark-bXVj7ffU.js +0 -1
  213. package/dist/Table-CYUuVDxA.js +0 -1
  214. package/dist/Table-D-9NfAqg.js +0 -1
  215. package/dist/Transfer-Cx1Ijzfh.js +0 -1
  216. package/dist/Transfer-DboPBh8V.js +0 -1
  217. package/dist/_getTag-x788Ng9o.js +0 -1
  218. package/dist/beneficiary-form-BmmdIRc0.js +0 -10
  219. package/dist/esm-BMvKJM5q.js +0 -4
  220. package/dist/esm-BbZME5Ac.js +0 -28
  221. package/dist/isEqual-BxlJ5vH7.js +0 -1
  222. package/dist/mi18n-react.esm-BFa-Q7wX.js +0 -1
  223. package/dist/react-dom-DmgFzc6z.js +0 -1
  224. package/dist/rolldown-runtime-DcYi-9oA.js +0 -1
  225. package/dist/xor-CSkTraTY.js +0 -1
  226. /package/dist/{IconPickerIcons-DN0pqJHt.js → IconPickerIcons-Baf748sI.js} +0 -0
@@ -1 +1 @@
1
- import{o as r}from"./rolldown-runtime-DcYi-9oA.js";import{t as s}from"./react-BW4ssgUo.js";import{i as t,r as o}from"./tslib.es6-C2q27PUR.js";import{$n as n,it as e}from"./esm-BMvKJM5q.js";var i=function(r){function s(){return null!==r&&r.apply(this,arguments)||this}return t(s,r),s.prototype.render=function(){var r=this.props,s=r.render,t=r.props,o=r.schema,e=n(this.props)||o;if("string"==typeof e)try{e=JSON.parse(e)}catch(i){console.warn("amis value must be json string",i),e=null}return s("amis",e,t)},o([e({type:"amis"})],s)}(/* @__PURE__ */r(s()).Component);export{i as AMISRenderer};
1
+ import{o as r}from"./rolldown-runtime-Ch1CtRr1.js";import{t as s}from"./react-1dn4ot9O.js";import{i as t,r as o}from"./tslib.es6-C2q27PUR.js";import{$n as n,it as e}from"./esm-HJl7vXYN.js";var i=function(r){function s(){return null!==r&&r.apply(this,arguments)||this}return t(s,r),s.prototype.render=function(){var r=this.props,s=r.render,t=r.props,o=r.schema,e=n(this.props)||o;if("string"==typeof e)try{e=JSON.parse(e)}catch(i){console.warn("amis value must be json string",i),e=null}return s("amis",e,t)},o([e({type:"amis"})],s)}(/* @__PURE__ */r(s()).Component);export{i as AMISRenderer};
@@ -0,0 +1 @@
1
+ import{o as e,r as t}from"./rolldown-runtime-Ch1CtRr1.js";import{t as n}from"./react-1dn4ot9O.js";import{a as o,c as i,i as s,n as r,o as a,r as l,t as c}from"./tslib.es6-C2q27PUR.js";import{J as p,Nn as d,Vr as u,Xr as f,Z as y,dn as m,dt as h,it as v,kt as g,ln as b,oi as w,tt as k,ui as C,yn as E}from"./esm-HJl7vXYN.js";import{R as O}from"./esm-BmJ_y26h.js";import{a as D,n as j,s as A}from"./PopUp-COxX3IAH.js";import{n as x}from"./Remark-B9lXsYnM.js";var L=/* @__PURE__ */e(n()),P="undefined"!=typeof navigator&&navigator.userAgent.toLowerCase().indexOf("firefox")>0;function S(e,t,n,o){e.addEventListener?e.addEventListener(t,n,o):e.attachEvent&&e.attachEvent("on".concat(t),n)}function T(e,t,n,o){e.removeEventListener?e.removeEventListener(t,n,o):e.detachEvent&&e.detachEvent("on".concat(t),n)}function K(e,t){const n=t.slice(0,t.length-1);for(let o=0;o<n.length;o++)n[o]=e[n[o].toLowerCase()];return n}function N(e){"string"!=typeof e&&(e="");const t=(e=e.replace(/\s/g,"")).split(",");let n=t.lastIndexOf("");for(;n>=0;)t[n-1]+=",",t.splice(n,1),n=t.lastIndexOf("");return t}var M={backspace:8,"⌫":8,tab:9,clear:12,enter:13,"↩":13,return:13,esc:27,escape:27,space:32,left:37,up:38,right:39,down:40,arrowup:38,arrowdown:40,arrowleft:37,arrowright:39,del:46,delete:46,ins:45,insert:45,home:36,end:35,pageup:33,pagedown:34,capslock:20,num_0:96,num_1:97,num_2:98,num_3:99,num_4:100,num_5:101,num_6:102,num_7:103,num_8:104,num_9:105,num_multiply:106,num_add:107,num_enter:108,num_subtract:109,num_decimal:110,num_divide:111,"⇪":20,",":188,".":190,"/":191,"`":192,"-":P?173:189,"=":P?61:187,";":P?59:186,"'":222,"{":219,"}":221,"[":219,"]":221,"\\":220},I={"⇧":16,shift:16,"⌥":18,alt:18,option:18,"⌃":17,ctrl:17,control:17,"⌘":91,cmd:91,meta:91,command:91},_={16:"shiftKey",18:"altKey",17:"ctrlKey",91:"metaKey",shiftKey:16,ctrlKey:17,altKey:18,metaKey:91},F={16:!1,18:!1,17:!1,91:!1},U={};for(let ce=1;ce<20;ce++)M["f".concat(ce)]=111+ce;var B=[],R=null,z="all",W=/* @__PURE__ */new Map,q=e=>M[e.toLowerCase()]||I[e.toLowerCase()]||e.toUpperCase().charCodeAt(0);function V(e){z=e||"all"}function X(){return z||"all"}function $(e){if(void 0===e)Object.keys(U).forEach(e=>{Array.isArray(U[e])&&U[e].forEach(e=>G(e)),delete U[e]}),Q(null);else if(Array.isArray(e))e.forEach(e=>{e.key&&G(e)});else if("object"==typeof e)e.key&&G(e);else if("string"==typeof e){for(var t=arguments.length,n=new Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];let[i,s]=n;"function"==typeof i&&(s=i,i=""),G({key:e,scope:i,method:s,splitKey:"+"})}}var G=e=>{let{key:t,scope:n,method:o,splitKey:i="+"}=e;N(t).forEach(e=>{const t=e.split(i),s=t.length,r=t[s-1],a="*"===r?"*":q(r);if(!U[a])return;n||(n=X());const l=s>1?K(I,t):[],c=[];U[a]=U[a].filter(e=>{const t=(!o||e.method===o)&&e.scope===n&&function(e,t){const n=e.length>=t.length?e:t,o=e.length>=t.length?t:e;let i=!0;for(let s=0;s<n.length;s++)-1===o.indexOf(n[s])&&(i=!1);return i}(e.mods,l);return t&&c.push(e.element),!t}),c.forEach(e=>Q(e))})};function J(e,t,n,o){if(t.element!==o)return;let i;if(t.scope===n||"all"===t.scope){i=t.mods.length>0;for(const e in F)Object.prototype.hasOwnProperty.call(F,e)&&(!F[e]&&t.mods.indexOf(+e)>-1||F[e]&&-1===t.mods.indexOf(+e))&&(i=!1);(0!==t.mods.length||F[16]||F[18]||F[17]||F[91])&&!i&&"*"!==t.shortcut||(t.keys=[],t.keys=t.keys.concat(B),!1===t.method(e,t)&&(e.preventDefault?e.preventDefault():e.returnValue=!1,e.stopPropagation&&e.stopPropagation(),e.cancelBubble&&(e.cancelBubble=!0)))}}function Z(e,t){const n=U["*"];let o=e.keyCode||e.which||e.charCode;if(e.key&&"capslock"===e.key.toLowerCase())return;if(!H.filter.call(this,e))return;if(93!==o&&224!==o||(o=91),-1===B.indexOf(o)&&229!==o&&B.push(o),["metaKey","ctrlKey","altKey","shiftKey"].forEach(t=>{const n=_[t];e[t]&&-1===B.indexOf(n)?B.push(n):!e[t]&&B.indexOf(n)>-1?B.splice(B.indexOf(n),1):"metaKey"===t&&e[t]&&(B=B.filter(e=>e in _||e===o))}),o in F){F[o]=!0;for(const t in I)Object.prototype.hasOwnProperty.call(I,t)&&(H[t]=e[_[I[t]]]);if(!n)return}for(const a in F)Object.prototype.hasOwnProperty.call(F,a)&&(F[a]=e[_[a]]);e.getModifierState&&(!e.altKey||e.ctrlKey)&&e.getModifierState("AltGraph")&&(-1===B.indexOf(17)&&B.push(17),-1===B.indexOf(18)&&B.push(18),F[17]=!0,F[18]=!0);const i=X();if(n)for(let a=0;a<n.length;a++)n[a].scope===i&&("keydown"===e.type&&n[a].keydown||"keyup"===e.type&&n[a].keyup)&&J(e,n[a],i,t);if(!(o in U))return;const s=U[o],r=s.length;for(let a=0;a<r;a++)if(("keydown"===e.type&&s[a].keydown||"keyup"===e.type&&s[a].keyup)&&s[a].key){const n=s[a],{splitKey:o}=n,r=n.key.split(o),l=[];for(let e=0;e<r.length;e++)l.push(q(r[e]));l.sort().join("")===B.sort().join("")&&J(e,n,i,t)}}function H(e,t,n){B=[];const o=N(e);let i=[],s="all",r=document,a=0,l=!1,c=!0,p="+",d=!1,u=!1;for(void 0===n&&"function"==typeof t&&(n=t),"[object Object]"===Object.prototype.toString.call(t)&&(t.scope&&(s=t.scope),t.element&&(r=t.element),t.keyup&&(l=t.keyup),void 0!==t.keydown&&(c=t.keydown),void 0!==t.capture&&(d=t.capture),"string"==typeof t.splitKey&&(p=t.splitKey),!0===t.single&&(u=!0)),"string"==typeof t&&(s=t),u&&$(e,s);a<o.length;a++)i=[],(e=o[a].split(p)).length>1&&(i=K(I,e)),(e="*"===(e=e[e.length-1])?"*":q(e))in U||(U[e]=[]),U[e].push({keyup:l,keydown:c,scope:s,mods:i,shortcut:o[a],method:n,key:o[a],splitKey:p,element:r});if(void 0!==r&&window){if(!W.has(r)){const e=function(){return Z(arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.event,r)},t=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.event;Z(e,r),function(e){let t=e.keyCode||e.which||e.charCode;e.key&&"capslock"===e.key.toLowerCase()&&(t=q(e.key));const n=B.indexOf(t);if(n>=0&&B.splice(n,1),e.key&&"meta"===e.key.toLowerCase()&&B.splice(0,B.length),93!==t&&224!==t||(t=91),t in F){F[t]=!1;for(const e in I)I[e]===t&&(H[e]=!1)}}(e)};W.set(r,{keydownListener:e,keyupListenr:t,capture:d}),S(r,"keydown",e,d),S(r,"keyup",t,d)}if(!R){const e=()=>{B=[]};R={listener:e,capture:d},S(window,"focus",e,d)}}}function Q(e){const t=Object.values(U).flat();if(t.findIndex(t=>{let{element:n}=t;return n===e})<0){const{keydownListener:t,keyupListenr:n,capture:o}=W.get(e)||{};t&&n&&(T(e,"keyup",n,o),T(e,"keydown",t,o),W.delete(e))}if((t.length<=0||W.size<=0)&&(Object.keys(W).forEach(e=>{const{keydownListener:t,keyupListenr:n,capture:o}=W.get(e)||{};t&&n&&(T(e,"keyup",n,o),T(e,"keydown",t,o),W.delete(e))}),W.clear(),Object.keys(U).forEach(e=>delete U[e]),R)){const{listener:e,capture:t}=R;T(window,"focus",e,t),R=null}}var Y={getPressedKeyString:function(){return B.map(e=>{return t=e,Object.keys(M).find(e=>M[e]===t)||(e=>Object.keys(I).find(t=>I[t]===e))(e)||String.fromCharCode(e);var t})},setScope:V,getScope:X,deleteScope:function(e,t){let n,o;e||(e=X());for(const i in U)if(Object.prototype.hasOwnProperty.call(U,i))for(n=U[i],o=0;o<n.length;)n[o].scope===e?n.splice(o,1).forEach(e=>{let{element:t}=e;return Q(t)}):o++;X()===e&&V(t||"all")},getPressedKeyCodes:function(){return B.slice(0)},getAllKeyCodes:function(){const e=[];return Object.keys(U).forEach(t=>{U[t].forEach(t=>{let{key:n,scope:o,mods:i,shortcut:s}=t;e.push({scope:o,shortcut:s,mods:i,keys:n.split("+").map(e=>q(e))})})}),e},isPressed:function(e){return"string"==typeof e&&(e=q(e)),-1!==B.indexOf(e)},filter:function(e){const t=e.target||e.srcElement,{tagName:n}=t;let o=!0;const i="INPUT"===n&&!["checkbox","radio","range","button","file","reset","submit","color"].includes(t.type);return(t.isContentEditable||(i||"TEXTAREA"===n||"SELECT"===n)&&!t.readOnly)&&(o=!1),o},trigger:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"all";Object.keys(U).forEach(n=>{U[n].filter(n=>n.scope===t&&n.shortcut===e).forEach(e=>{e&&e.method&&e.method()})})},unbind:$,keyMap:M,modifier:I,modifierMap:_};for(const ce in Y)Object.prototype.hasOwnProperty.call(Y,ce)&&(H[ce]=Y[ce]);if("undefined"!=typeof window){const e=window.hotkeys;H.noConflict=t=>(t&&window.hotkeys===H&&(window.hotkeys=e),H),window.hotkeys=H}var ee=/* @__PURE__ */t({Action:()=>re,ActionRenderer:()=>le,createSyntheticEvent:()=>ie,default:()=>ae}),te=/* @__PURE__ */e(g()),ne=/* @__PURE__ */e(E()),oe=["id","dialog","drawer","toast","url","link","confirmText","confirmTitle","tooltip","disabledTip","className","asyncApi","redirect","size","level","primary","feedback","api","blank","tooltipPlacement","to","cc","bcc","subject","body","content","required","type","actionType","label","icon","rightIcon","reload","target","close","messages","mergeData","index","copy","copyFormat","payload","requireSelected","countDown","fileName","isolateScope","downloadFileName"],ie=function(e){var t=!1,n=!1;return{nativeEvent:e,currentTarget:e.currentTarget,target:e.target,bubbles:e.bubbles,cancelable:e.cancelable,defaultPrevented:e.defaultPrevented,eventPhase:e.eventPhase,isTrusted:e.isTrusted,preventDefault:function(){t=!0,e.preventDefault()},isDefaultPrevented:function(){return t},stopPropagation:function(){n=!0,e.stopPropagation()},isPropagationStopped:function(){return n},persist:function(){},timeStamp:e.timeStamp,type:e.type}},se=["button","submit","reset"],re=function(e){function t(t){var n,o,i=this;(i=e.call(this,t)||this).state={inCountDown:!1,countDownEnd:0,timeLeft:0},i.localStorageKey="amis-countdownend-"+(i.props.name||"")+((null===(o=null===(n=i.props)||void 0===n?void 0:n.$schema)||void 0===o?void 0:o.id)||u());var s=parseInt(localStorage.getItem(i.localStorageKey)||"0");return s&&i.props.countDown&&Date.now()<s&&(i.state={inCountDown:!0,countDownEnd:s,timeLeft:Math.floor((s-Date.now())/1e3)},i.handleCountDown()),i}return s(t,e),t.prototype.handleAction=function(e){return r(this,void 0,void 0,function(){var t,n,i,s,r,a,l,c,p,d,u,f,y,h,v=this;return o(this,function(o){switch(o.label){case 0:return t=this.props,n=t.onAction,i=t.onActionSensor,s=t.disabled,r=t.countDown,a=t.env,e.persist(),"string"==typeof(l=this.props.onClick)&&(l=m(l,"event","props")),(p=l)?[4,l(e,this.props)]:[3,2];case 1:p=o.sent(),o.label=2;case 2:return c=p,s||e.isDefaultPrevented()||!1===c||!n||this.state.inCountDown?[2]:(e.preventDefault(),d=(0,te.default)(this.props,oe),"ajax"!==(u=d.actionType)&&"download"!==u&&"add"!==u&&(null==a||a.tracker({eventType:u||this.props.type||"click",eventData:(0,ne.default)(d,["type","actionType","tooltipPlacement"])},this.props)),"download"===u&&(d.actionType="ajax",(f=b(d.api)).responseType="blob",f.downloadFileName=d.downloadFileName,d.api=f),(null==(y=n(e,d))?void 0:y.then)?(null==i||i(y),[4,y]):[3,4]);case 3:o.sent(),o.label=4;case 4:return r&&(h=Date.now()+1e3*r,this.setState({countDownEnd:h,inCountDown:!0,timeLeft:r}),localStorage.setItem(this.localStorageKey,String(h)),setTimeout(function(){v.handleCountDown()},1e3)),[2]}})})},t.prototype.handleCountDown=function(){var e=this,t=Math.floor((this.state.countDownEnd-Date.now())/1e3);t<=0?this.setState({inCountDown:!1,timeLeft:t}):(this.setState({timeLeft:t}),setTimeout(function(){e.handleCountDown()},1e3))},t.prototype.componentDidMount=function(){var e=this,t=this.props.hotKey;t&&H(t,function(t){t.preventDefault();var n=new MouseEvent("click",{bubbles:!0,cancelable:!0});e.handleAction(ie(n))})},t.prototype.componentWillUnmount=function(){var e=this.props.hotKey;e&&H.unbind(e)},t.prototype.render=function(){var e,t=this.props,n=t.type,o=t.iconClassName,i=t.rightIconClassName,s=t.loadingClassName,r=t.primary,a=t.size,l=t.level,d=t.countDownTpl,u=t.block,m=t.className,h=t.style,v=t.componentClass,g=t.tooltip,b=t.disabledTip,w=t.tooltipPlacement,k=t.actionType,C=t.link,E=t.data,O=t.translate,P=t.activeClassName,S=t.isCurrentUrl,T=t.isMenuItem,K=t.active,N=t.activeLevel,M=t.tooltipTrigger,I=t.tooltipContainer,_=t.tooltipRootClose,F=t.loading,U=t.body,B=t.render,R=t.onMouseEnter,z=t.onMouseLeave,W=t.classnames,q=t.classPrefix,V=t.loadingConfig,X=t.themeCss,$=t.wrapperCustomStyle,G=t.css,J=t.id,Z=t.testIdBuilder,H=t.env,Q=t.tabIndex;if("email"!==k&&U)return L.createElement(D,{classPrefix:q,classnames:W,placement:w,tooltip:g,container:I,trigger:M,rootClose:_},L.createElement("div",{className:W("Action",m),style:h,onClick:this.handleAction,onMouseEnter:R,onMouseLeave:z},B("body",U)));var Y=this.props.label,ee=this.props.disabled,te=!!K;"link"===k&&!te&&C&&S&&(te=S(C)),this.state.inCountDown&&(Y=x(O(d),c(c({},E),{timeLeft:this.state.timeLeft})),ee=!0);var ne=this.props.icon,oe=this.props.rightIcon;"string"==typeof ne&&(ne=f(this.props.icon,E)),"string"==typeof oe&&(oe=f(this.props.rightIcon,E));var ie=L.createElement(A,{cx:W,icon:ne,className:"Button-icon",classNameProp:W(o,y(c(c({},this.props),{name:"iconClassName",id:J,themeCss:X||G})))}),re=L.createElement(A,{cx:W,icon:oe,className:"Button-icon",classNameProp:W(i,y(c(c({},this.props),{name:"iconClassName",id:J,themeCss:X||G})))});return L.createElement(L.Fragment,null,L.createElement(j,{loadingConfig:V,className:W(m,y(c(c({},this.props),{name:"wrapperCustomStyle",id:J,themeCss:$})),y(c(c({},this.props),{name:"className",id:J,themeCss:X||G})),(e={},e[P||"is-active"]=te,e)),testIdBuilder:Z,style:h,size:a,level:N&&te?N:f(l,E)||(r?"primary":void 0),loadingClassName:s,loading:F,onClick:this.handleAction,onMouseEnter:R,onMouseLeave:z,type:n&&~se.indexOf(n)?n:"button",disabled:ee,componentClass:T?"a":v,overrideClassName:T,tooltip:x(g,E),disabledTip:x(b,E),tooltipPlacement:w,tooltipContainer:I,tooltipTrigger:M,tooltipRootClose:_,block:u,iconOnly:!(!ne||Y||"link"===l),tabIndex:Q},F?"":ie,Y?L.createElement("span",null,f(String(Y),E)):null,re),L.createElement(p,c({},this.props,{config:{themeCss:X||G,classNames:[{key:"className",weights:{hover:{suf:":not(:disabled):not(.is-disabled)"},active:{suf:":not(:disabled):not(.is-disabled)"}}},{key:"iconClassName",weights:{default:{important:!0},hover:{important:!0,suf:":not(:disabled):not(.is-disabled)"},active:{important:!0,suf:":not(:disabled):not(.is-disabled)"}}}],wrapperCustomStyle:$,id:J},env:H})))},t.defaultProps={type:"button",componentClass:"button",tooltipPlacement:"bottom",activeClassName:"is-active",countDownTpl:"Action.countDown",countDown:0},l([d,a("design:type",Function),a("design:paramtypes",[Object]),a("design:returntype",Promise)],t.prototype,"handleAction",null),l([d,a("design:type",Function),a("design:paramtypes",[]),a("design:returntype",void 0)],t.prototype,"handleCountDown",null),l([d,a("design:type",Function),a("design:paramtypes",[]),a("design:returntype",void 0)],t.prototype,"componentDidMount",null),l([d,a("design:type",Function),a("design:paramtypes",[]),a("design:returntype",void 0)],t.prototype,"componentWillUnmount",null),t}(L.Component),ae=k(re),le=function(e){function t(t,n){var o=e.call(this,t)||this;return o.state={actionDisabled:!1},n.registerComponent(o),o}return s(t,e),t.prototype.componentWillUnmount=function(){this.context.unRegisterComponent(this)},t.prototype.doAction=function(e,t){var n=null==e?void 0:e.actionType;"click"===n&&this.handleAction(n,e)},t.prototype.handleAction=function(e,t){return r(this,void 0,void 0,function(){var n,i,s,r,a,l,p,d,u,y,m;return o(this,function(o){switch(o.label){case 0:return o.trys.push([0,,10,11]),n=this.props,i=n.env,s=n.onAction,r=n.data,a=n.ignoreConfirm,l=n.dispatchEvent,p=n.$schema,d=r,this.setState({actionDisabled:!0}),"click"===(null==t?void 0:t.actionType)&&C(null==t?void 0:t.args)&&(d=w(r,t.args)),u=p.onEvent&&Object.keys(p.onEvent).length,y="",!1!==this.props.showConfirmBox&&(!a||u)&&t.confirmText&&i.confirm&&(y=f(t.confirmText,d))?[4,i.confirm(y,f(t.confirmTitle,d)||void 0)]:[3,6];case 1:return o.sent()?[4,l(e,d,this)]:[3,4];case 2:return(null==(m=o.sent())?void 0:m.prevented)?[2]:[4,s(e,c(c({},t),{ignoreConfirm:!!u}),d,void 0,void 0,m)];case 3:return o.sent(),[3,5];case 4:if(t.countDown)throw new Error("cancel");o.label=5;case 5:return[3,9];case 6:return[4,l(e,d)];case 7:return(null==(m=o.sent())?void 0:m.prevented)?[2]:[4,s(e,t,d,void 0,void 0,m)];case 8:o.sent(),o.label=9;case 9:return[3,11];case 10:return this.setState({actionDisabled:!1}),[7];case 11:return[2]}})})},t.prototype.handleMouseEnter=function(e){var t=this.props,n=t.dispatchEvent,o=t.data;n(e,w(o,{nativeEvent:e}))},t.prototype.handleMouseLeave=function(e){var t=this.props,n=t.dispatchEvent,o=t.data;n(e,w(o,{nativeEvent:e}))},t.prototype.isCurrentAction=function(e){var t=this.props,n=t.env,o=t.data;return n.isCurrentUrl(f(e,o))},t.prototype.render=function(){var e=this.props,t=e.env,n=e.disabled,o=e.btnDisabled,s=e.disabledOnAction,r=e.loading,a=i(e,["env","disabled","btnDisabled","disabledOnAction","loading"]),l=this.state.actionDisabled;return L.createElement(re,c({},a,{env:t,disabled:n||o||!!s&&l,onAction:this.handleAction,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave,loading:r,isCurrentUrl:this.isCurrentAction,tooltipContainer:a.popOverContainer||t.getModalContainer}))},t.contextType=h,l([d,a("design:type",Function),a("design:paramtypes",[Object,Object]),a("design:returntype",Promise)],t.prototype,"handleAction",null),l([d,a("design:type",Function),a("design:paramtypes",[Object]),a("design:returntype",void 0)],t.prototype,"handleMouseEnter",null),l([d,a("design:type",Function),a("design:paramtypes",[Object]),a("design:returntype",void 0)],t.prototype,"handleMouseLeave",null),l([d,a("design:type",Function),a("design:paramtypes",[String]),a("design:returntype",void 0)],t.prototype,"isCurrentAction",null),l([v({type:"action",alias:["button","submit","reset"]}),O,a("design:paramtypes",[Object,Object])],t)}(L.Component);export{ee as n,re as t};
@@ -1 +1 @@
1
- import{o}from"./rolldown-runtime-DcYi-9oA.js";import{t}from"./react-BW4ssgUo.js";import{c as r,i as s,r as e,t as n}from"./tslib.es6-C2q27PUR.js";import{Ii as a,Zr as i,it as p}from"./esm-BMvKJM5q.js";import{nt as l}from"./esm-BbZME5Ac.js";var c=/* @__PURE__ */o(t()),m=function(o){function t(){return null!==o&&o.apply(this,arguments)||this}return s(t,o),t.prototype.render=function(){var o=this.props,t=o.render,s=o.body,e=o.level,p=o.icon,m=o.showIcon,d=o.actions,h=r(o,["render","body","level","icon","showIcon","actions"]);i(e)&&(e=a(e,this.props.data)),i(p)&&(p=a(p,this.props.data)),i(m)&&(m=a(m,this.props.data));var u=d?c.isValidElement(d)?d:t("alert-actions",d):null;return c.createElement(l,n({},h,{level:e,icon:p,showIcon:m,actions:u}),t("body",s))},e([p({type:"alert"})],t)}(c.Component);export{m as AlertRenderer};
1
+ import{o}from"./rolldown-runtime-Ch1CtRr1.js";import{t}from"./react-1dn4ot9O.js";import{c as r,i as s,r as e,t as n}from"./tslib.es6-C2q27PUR.js";import{Ii as a,Zr as i,it as p}from"./esm-HJl7vXYN.js";import{nt as l}from"./esm-BmJ_y26h.js";var c=/* @__PURE__ */o(t()),m=function(o){function t(){return null!==o&&o.apply(this,arguments)||this}return s(t,o),t.prototype.render=function(){var o=this.props,t=o.render,s=o.body,e=o.level,p=o.icon,m=o.showIcon,d=o.actions,h=r(o,["render","body","level","icon","showIcon","actions"]);i(e)&&(e=a(e,this.props.data)),i(p)&&(p=a(p,this.props.data)),i(m)&&(m=a(m,this.props.data));var u=d?c.isValidElement(d)?d:t("alert-actions",d):null;return c.createElement(l,n({},h,{level:e,icon:p,showIcon:m,actions:u}),t("body",s))},e([p({type:"alert"})],t)}(c.Component);export{m as AlertRenderer};
@@ -1 +1 @@
1
- import{o as e}from"./rolldown-runtime-DcYi-9oA.js";import{t}from"./react-BW4ssgUo.js";import{i as r,o as s,r as n,s as a,t as i,u as o}from"./tslib.es6-C2q27PUR.js";import{Nn as c,Xr as l,it as p,xr as u}from"./esm-BMvKJM5q.js";import{U as d,W as f}from"./esm-BbZME5Ac.js";var h=/* @__PURE__ */e(t()),m=function(e){function t(t){var r=e.call(this,t)||this,s=t.links,n=0;if(void 0!==t.active)n=t.active;else{var a=r.getActiveSection(s,t.active,null);n=a&&a.href?a.href:s[0]&&s[0].href||0}return r.state={active:n},r}return r(t,e),t.prototype.getActiveSection=function(e,t,r){var s=this;return r||(e.forEach(function(e){e.href===t?r=e:e.children&&s.getActiveSection(e.children,t,r)}),r)},t.prototype.handleSelect=function(e){this.setState({active:e})},t.prototype.locateTo=function(e){var t=this.props.links;Array.isArray(t)&&t[e]&&this.setState({active:t[e].href||e})},t.prototype.renderSections=function(e,t){var r=this,s=this.props;s.classnames,s.classPrefix;var n=s.sectionRender,c=s.render,p=s.data;e=Array.isArray(e)?e:[e];var f=[];return e.forEach(function(e,s){if(u(e,p)){var m=(t?t+"-":"")+s;f.push(h.createElement(d,i({},e,{title:l(e.title,p),key:m,name:e.href||m}),r.renderSection?r.renderSection(e,r.props,m):n?n(e,r.props,m):c("section/".concat(m),e.body||""))),e.children&&f.push.apply(f,o([],a(r.renderSections(e.children,m)),!1))}}),f.filter(function(e){return!!e})},t.prototype.render=function(){var e=this.props,t=e.classnames,r=e.classPrefix,s=e.className,n=e.style,a=e.linkClassName,i=e.sectionClassName,o=e.direction;e.sectionRender,e.render,e.data;var c=this.props.links;if(!c)return null;var l=this.renderSections(c);return h.createElement(f,{classPrefix:r,classnames:t,className:s,style:n,linkClassName:a,sectionClassName:i,onSelect:this.handleSelect,active:this.state.active,direction:o},l)},t.defaultProps={className:"",linkClassName:"",sectionClassName:""},n([c,s("design:type",Function),s("design:paramtypes",[Object]),s("design:returntype",void 0)],t.prototype,"handleSelect",null),n([c,s("design:type",Function),s("design:paramtypes",[Number]),s("design:returntype",void 0)],t.prototype,"locateTo",null),t}(h.Component),v=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r(t,e),n([p({type:"anchor-nav"})],t)}(m);export{v as AnchorNavRenderer,m as default};
1
+ import{o as e}from"./rolldown-runtime-Ch1CtRr1.js";import{t}from"./react-1dn4ot9O.js";import{i as r,o as s,r as n,s as a,t as i,u as o}from"./tslib.es6-C2q27PUR.js";import{Nn as c,Xr as l,it as p,xr as u}from"./esm-HJl7vXYN.js";import{U as d,W as f}from"./esm-BmJ_y26h.js";var h=/* @__PURE__ */e(t()),m=function(e){function t(t){var r=e.call(this,t)||this,s=t.links,n=0;if(void 0!==t.active)n=t.active;else{var a=r.getActiveSection(s,t.active,null);n=a&&a.href?a.href:s[0]&&s[0].href||0}return r.state={active:n},r}return r(t,e),t.prototype.getActiveSection=function(e,t,r){var s=this;return r||(e.forEach(function(e){e.href===t?r=e:e.children&&s.getActiveSection(e.children,t,r)}),r)},t.prototype.handleSelect=function(e){this.setState({active:e})},t.prototype.locateTo=function(e){var t=this.props.links;Array.isArray(t)&&t[e]&&this.setState({active:t[e].href||e})},t.prototype.renderSections=function(e,t){var r=this,s=this.props;s.classnames,s.classPrefix;var n=s.sectionRender,c=s.render,p=s.data;e=Array.isArray(e)?e:[e];var f=[];return e.forEach(function(e,s){if(u(e,p)){var m=(t?t+"-":"")+s;f.push(h.createElement(d,i({},e,{title:l(e.title,p),key:m,name:e.href||m}),r.renderSection?r.renderSection(e,r.props,m):n?n(e,r.props,m):c("section/".concat(m),e.body||""))),e.children&&f.push.apply(f,o([],a(r.renderSections(e.children,m)),!1))}}),f.filter(function(e){return!!e})},t.prototype.render=function(){var e=this.props,t=e.classnames,r=e.classPrefix,s=e.className,n=e.style,a=e.linkClassName,i=e.sectionClassName,o=e.direction;e.sectionRender,e.render,e.data;var c=this.props.links;if(!c)return null;var l=this.renderSections(c);return h.createElement(f,{classPrefix:r,classnames:t,className:s,style:n,linkClassName:a,sectionClassName:i,onSelect:this.handleSelect,active:this.state.active,direction:o},l)},t.defaultProps={className:"",linkClassName:"",sectionClassName:""},n([c,s("design:type",Function),s("design:paramtypes",[Object]),s("design:returntype",void 0)],t.prototype,"handleSelect",null),n([c,s("design:type",Function),s("design:paramtypes",[Number]),s("design:returntype",void 0)],t.prototype,"locateTo",null),t}(h.Component),v=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r(t,e),n([p({type:"anchor-nav"})],t)}(m);export{v as AnchorNavRenderer,m as default};
@@ -1 +1 @@
1
- import{o as e}from"./rolldown-runtime-DcYi-9oA.js";import{t}from"./react-BW4ssgUo.js";import{a,i as n,n as r,o,r as i}from"./tslib.es6-C2q27PUR.js";import{Ft as s,Nn as l,Pt as c,Xr as d,_t as u,an as p,dt as m,it as h,sn as v}from"./esm-BMvKJM5q.js";import{Ht as f,It as g,vt as b}from"./esm-BbZME5Ac.js";import{i as y,o as E,s as N}from"./PopUp-DaheG-Vv.js";var P=/* @__PURE__ */e(t()),B=function(e){function t(t){var a,n,r,o=this;o=e.call(this,t)||this;var i=t.store;return i.syncProps(t,void 0,["pages"]),i.updateActivePage(Object.assign({},null!==(a=t.env)&&void 0!==a?a:{},{showFullBreadcrumbPath:null!==(n=t.showFullBreadcrumbPath)&&void 0!==n&&n,showBreadcrumbHomePath:null===(r=t.showBreadcrumbHomePath)||void 0===r||r})),t.env.watchRouteChange&&(o.unWatchRouteChange=t.env.watchRouteChange(function(){var e,a,n;return i.updateActivePage(Object.assign({},null!==(e=t.env)&&void 0!==e?e:{},{showFullBreadcrumbPath:null!==(a=t.showFullBreadcrumbPath)&&void 0!==a&&a,showBreadcrumbHomePath:null===(n=t.showBreadcrumbHomePath)||void 0===n||n}))})),o}return n(t,e),t.prototype.componentDidMount=function(){return r(this,void 0,void 0,function(){var e,t,n;return a(this,function(a){switch(a.label){case 0:return e=this.props,t=e.data,[4,(0,e.dispatchEvent)("init",t,this)];case 1:return(null==(n=a.sent())?void 0:n.prevented)||this.reload(),[2]}})})},t.prototype.componentDidUpdate=function(e){var t,n,o;return r(this,void 0,void 0,function(){var r,i;return a(this,function(a){return r=this.props,(i=r.store).syncProps(r,e,["pages"]),p(e.api,r.api,e.data,r.data)?this.reload():r.location&&r.location!==e.location&&i.updateActivePage(Object.assign({},null!==(t=r.env)&&void 0!==t?t:{},{showFullBreadcrumbPath:null!==(n=r.showFullBreadcrumbPath)&&void 0!==n&&n,showBreadcrumbHomePath:null===(o=r.showBreadcrumbHomePath)||void 0===o||o})),[2]})})},t.prototype.componentWillUnmount=function(){var e;null===(e=this.unWatchRouteChange)||void 0===e||e.call(this)},t.prototype.reload=function(e,t,n,o,i){return r(this,void 0,void 0,function(){var e,n,r,o,l,d,u,p,m,h;return a(this,function(a){switch(a.label){case 0:return t?[2,this.receive(t,void 0,i)]:(e=this.props,n=e.api,r=e.store,o=e.env,l=e.showFullBreadcrumbPath,d=void 0!==l&&l,u=e.showBreadcrumbHomePath,p=void 0===u||u,m=e.locale,v(n,r.data)?[4,r.fetchInitData(n,r.data,{})]:[3,2]);case 1:h=a.sent(),o.replaceText&&(h.data=s(h.data,o.replaceText,o.replaceTextIgnoreKeys)),(null==h?void 0:h.data.pages)&&(h.data=c(h.data,m),r.setPages(h.data.pages),r.updateActivePage(Object.assign({},null!=o?o:{},{showFullBreadcrumbPath:d,showBreadcrumbHomePath:p}))),a.label=2;case 2:return[2,r.data]}})})},t.prototype.receive=function(e,t,n){return r(this,void 0,void 0,function(){return a(this,function(t){return this.props.store.updateData(e,void 0,n),[2,this.reload()]})})},t.prototype.resolveDefinitions=function(e){var t,a=this.props,n=a.resolveDefinitions,r=null===(t=a.store.schema)||void 0===t?void 0:t.definitions;return(null==r?void 0:r[e])||n(e)},t.prototype.handleNavClick=function(e){e.preventDefault();var t=this.props.store,a=this.props.env,n=e.currentTarget.getAttribute("href");t.updateOffScreen(!1),a.jumpTo(n,void 0,this.props.data)},t.prototype.renderHeader=function(){var e=this.props,t=e.classnames,a=e.brandName,n=e.header,r=e.render,o=e.store,i=e.logo,s=e.env;return n||i||a?P.createElement(P.Fragment,null,P.createElement("div",{className:t("Layout-brandBar")},P.createElement("div",{onClick:o.toggleOffScreen,className:t("Layout-offScreenBtn")},P.createElement("i",{className:"bui-icon iconfont icon-collapse"})),P.createElement("div",{className:t("Layout-brand")},i&&~i.indexOf("<svg")?P.createElement(E,{className:t("AppLogo-html"),html:i,filterHtml:s.filterHtml}):i?P.createElement("img",{className:t("AppLogo"),src:i}):P.createElement("span",{className:"visible-folded "},null==a?void 0:a.substring(0,1)),P.createElement("span",{className:"hidden-folded m-l-sm"},a))),P.createElement("div",{className:t("Layout-headerBar")},P.createElement("a",{onClick:o.toggleFolded,type:"button",className:t("AppFoldBtn")},P.createElement("i",{className:"fa fa-".concat(o.folded?"indent":"dedent"," fa-fw")})),n?r("header",n):null)):null},t.prototype.renderAside=function(){var e=this,t=this.props,a=t.store,n=t.env,r=t.asideBefore,o=t.asideAfter,i=t.render,s=t.data;return P.createElement(P.Fragment,null,r?i("aside-before",r):null,P.createElement(g,{navigations:a.navigations,renderLink:function(t,n){var r=t.link;t.active;var o=t.toggleExpand,i=t.classnames,l=t.depth,c=t.subHeader,u=[];if(!1===r.visible)return null;!c&&r.children&&r.children.some(function(e){return null==e?void 0:e.visible})&&u.push(P.createElement("span",{key:"expand-toggle",className:i("AsideNav-itemArrow"),onClick:function(e){return o(r,e)}}));var p="string"==typeof r.badge?d(r.badge,s):r.badge;return null!=p&&u.push(P.createElement("b",{key:"badge",className:i("AsideNav-itemBadge",r.badgeClassName||"bg-info")},p)),!c&&r.icon?u.push(P.createElement(N,{key:"icon",cx:i,icon:r.icon,className:"AsideNav-itemIcon"})):a.folded&&1===l&&!c&&u.push(P.createElement("i",{key:"icon",className:i("AsideNav-itemIcon",r.children?"fa fa-folder":"fa fa-info")})),u.push(P.createElement("span",{className:i("AsideNav-itemLabel"),key:"label"},"string"==typeof r.label?d(r.label,s):r.label)),r.path?/^https?\:/.test(r.path)?P.createElement("a",{target:"_blank",key:"link",href:r.path,rel:"noopener"},u):P.createElement("a",{key:"link",onClick:e.handleNavClick,href:r.path||r.children&&r.children[0].path},u):P.createElement("a",{key:"link",onClick:r.children?function(){return o(r)}:void 0},u)},isActive:function(e){return!!n.isCurrentUrl(null==e?void 0:e.path,e)}}),o?i("aside-before",o):null)},t.prototype.renderFooter=function(){var e=this.props,t=e.render,a=e.footer;return a?t("footer",a):null},t.prototype.render=function(){var e,t=this,a=this.props,n=a.classnames,r=a.store,o=a.render,i=a.showBreadcrumb,s=void 0===i||i,l=a.loadingConfig;return P.createElement(b,{header:this.renderHeader(),aside:this.renderAside(),footer:this.renderFooter(),folded:r.folded,offScreen:r.offScreen,contentClassName:n("AppContent")},r.activePage&&r.schema?P.createElement(P.Fragment,null,s&&r.bcn.length?P.createElement("ul",{className:n("AppBcn")},r.bcn.map(function(e,a){return P.createElement("li",{key:a,className:n("AppBcn-item")},e.path?P.createElement("a",{href:e.path,onClick:t.handleNavClick},e.label):a!==r.bcn.length-1?P.createElement("a",null,e.label):e.label)})):null,P.createElement("div",{className:n("AppBody")},o("page",r.schema,{key:"".concat(null===(e=r.activePage)||void 0===e?void 0:e.id,"-").concat(r.schemaKey),data:r.pageData,resolveDefinitions:this.resolveDefinitions}))):r.pages&&!r.activePage?P.createElement(f,null,P.createElement("div",{className:"text-center"},"页面不存在")):null,P.createElement(y,{loadingConfig:l,overlay:!0,show:r.loading||!r.pages,size:"lg"}))},t.propsList=["brandName","logo","header","asideBefore","asideAfter","pages","footer"],t.defaultProps={},i([l,o("design:type",Function),o("design:paramtypes",[String]),o("design:returntype",void 0)],t.prototype,"resolveDefinitions",null),i([l,o("design:type",Function),o("design:paramtypes",[Object]),o("design:returntype",void 0)],t.prototype,"handleNavClick",null),t}(P.Component),k=function(e){function t(t,a){var n=e.call(this,t)||this;return a.registerComponent(n),n}return n(t,e),t.prototype.componentWillUnmount=function(){this.context.unRegisterComponent(this),e.prototype.componentWillUnmount.call(this)},t.prototype.setData=function(e,t){return this.props.store.updateData(e,void 0,t)},t.prototype.getData=function(){return this.props.store.data},t.contextType=m,i([h({type:"app",storeType:u.name}),o("design:paramtypes",[Object,Object])],t)}(B);export{B as App,k as default};
1
+ import{o as e}from"./rolldown-runtime-Ch1CtRr1.js";import{t}from"./react-1dn4ot9O.js";import{a,i as n,n as r,o,r as i}from"./tslib.es6-C2q27PUR.js";import{Ft as s,Nn as l,Pt as c,Xr as d,_t as u,an as p,dt as m,it as h,sn as v}from"./esm-HJl7vXYN.js";import{Ht as f,It as g,vt as b}from"./esm-BmJ_y26h.js";import{i as y,o as E,s as N}from"./PopUp-COxX3IAH.js";var P=/* @__PURE__ */e(t()),B=function(e){function t(t){var a,n,r,o=this;o=e.call(this,t)||this;var i=t.store;return i.syncProps(t,void 0,["pages"]),i.updateActivePage(Object.assign({},null!==(a=t.env)&&void 0!==a?a:{},{showFullBreadcrumbPath:null!==(n=t.showFullBreadcrumbPath)&&void 0!==n&&n,showBreadcrumbHomePath:null===(r=t.showBreadcrumbHomePath)||void 0===r||r})),t.env.watchRouteChange&&(o.unWatchRouteChange=t.env.watchRouteChange(function(){var e,a,n;return i.updateActivePage(Object.assign({},null!==(e=t.env)&&void 0!==e?e:{},{showFullBreadcrumbPath:null!==(a=t.showFullBreadcrumbPath)&&void 0!==a&&a,showBreadcrumbHomePath:null===(n=t.showBreadcrumbHomePath)||void 0===n||n}))})),o}return n(t,e),t.prototype.componentDidMount=function(){return r(this,void 0,void 0,function(){var e,t,n;return a(this,function(a){switch(a.label){case 0:return e=this.props,t=e.data,[4,(0,e.dispatchEvent)("init",t,this)];case 1:return(null==(n=a.sent())?void 0:n.prevented)||this.reload(),[2]}})})},t.prototype.componentDidUpdate=function(e){var t,n,o;return r(this,void 0,void 0,function(){var r,i;return a(this,function(a){return r=this.props,(i=r.store).syncProps(r,e,["pages"]),p(e.api,r.api,e.data,r.data)?this.reload():r.location&&r.location!==e.location&&i.updateActivePage(Object.assign({},null!==(t=r.env)&&void 0!==t?t:{},{showFullBreadcrumbPath:null!==(n=r.showFullBreadcrumbPath)&&void 0!==n&&n,showBreadcrumbHomePath:null===(o=r.showBreadcrumbHomePath)||void 0===o||o})),[2]})})},t.prototype.componentWillUnmount=function(){var e;null===(e=this.unWatchRouteChange)||void 0===e||e.call(this)},t.prototype.reload=function(e,t,n,o,i){return r(this,void 0,void 0,function(){var e,n,r,o,l,d,u,p,m,h;return a(this,function(a){switch(a.label){case 0:return t?[2,this.receive(t,void 0,i)]:(e=this.props,n=e.api,r=e.store,o=e.env,l=e.showFullBreadcrumbPath,d=void 0!==l&&l,u=e.showBreadcrumbHomePath,p=void 0===u||u,m=e.locale,v(n,r.data)?[4,r.fetchInitData(n,r.data,{})]:[3,2]);case 1:h=a.sent(),o.replaceText&&(h.data=s(h.data,o.replaceText,o.replaceTextIgnoreKeys)),(null==h?void 0:h.data.pages)&&(h.data=c(h.data,m),r.setPages(h.data.pages),r.updateActivePage(Object.assign({},null!=o?o:{},{showFullBreadcrumbPath:d,showBreadcrumbHomePath:p}))),a.label=2;case 2:return[2,r.data]}})})},t.prototype.receive=function(e,t,n){return r(this,void 0,void 0,function(){return a(this,function(t){return this.props.store.updateData(e,void 0,n),[2,this.reload()]})})},t.prototype.resolveDefinitions=function(e){var t,a=this.props,n=a.resolveDefinitions,r=null===(t=a.store.schema)||void 0===t?void 0:t.definitions;return(null==r?void 0:r[e])||n(e)},t.prototype.handleNavClick=function(e){e.preventDefault();var t=this.props.store,a=this.props.env,n=e.currentTarget.getAttribute("href");t.updateOffScreen(!1),a.jumpTo(n,void 0,this.props.data)},t.prototype.renderHeader=function(){var e=this.props,t=e.classnames,a=e.brandName,n=e.header,r=e.render,o=e.store,i=e.logo,s=e.env;return n||i||a?P.createElement(P.Fragment,null,P.createElement("div",{className:t("Layout-brandBar")},P.createElement("div",{onClick:o.toggleOffScreen,className:t("Layout-offScreenBtn")},P.createElement("i",{className:"bui-icon iconfont icon-collapse"})),P.createElement("div",{className:t("Layout-brand")},i&&~i.indexOf("<svg")?P.createElement(E,{className:t("AppLogo-html"),html:i,filterHtml:s.filterHtml}):i?P.createElement("img",{className:t("AppLogo"),src:i}):P.createElement("span",{className:"visible-folded "},null==a?void 0:a.substring(0,1)),P.createElement("span",{className:"hidden-folded m-l-sm"},a))),P.createElement("div",{className:t("Layout-headerBar")},P.createElement("a",{onClick:o.toggleFolded,type:"button",className:t("AppFoldBtn")},P.createElement("i",{className:"fa fa-".concat(o.folded?"indent":"dedent"," fa-fw")})),n?r("header",n):null)):null},t.prototype.renderAside=function(){var e=this,t=this.props,a=t.store,n=t.env,r=t.asideBefore,o=t.asideAfter,i=t.render,s=t.data;return P.createElement(P.Fragment,null,r?i("aside-before",r):null,P.createElement(g,{navigations:a.navigations,renderLink:function(t,n){var r=t.link;t.active;var o=t.toggleExpand,i=t.classnames,l=t.depth,c=t.subHeader,u=[];if(!1===r.visible)return null;!c&&r.children&&r.children.some(function(e){return null==e?void 0:e.visible})&&u.push(P.createElement("span",{key:"expand-toggle",className:i("AsideNav-itemArrow"),onClick:function(e){return o(r,e)}}));var p="string"==typeof r.badge?d(r.badge,s):r.badge;return null!=p&&u.push(P.createElement("b",{key:"badge",className:i("AsideNav-itemBadge",r.badgeClassName||"bg-info")},p)),!c&&r.icon?u.push(P.createElement(N,{key:"icon",cx:i,icon:r.icon,className:"AsideNav-itemIcon"})):a.folded&&1===l&&!c&&u.push(P.createElement("i",{key:"icon",className:i("AsideNav-itemIcon",r.children?"fa fa-folder":"fa fa-info")})),u.push(P.createElement("span",{className:i("AsideNav-itemLabel"),key:"label"},"string"==typeof r.label?d(r.label,s):r.label)),r.path?/^https?\:/.test(r.path)?P.createElement("a",{target:"_blank",key:"link",href:r.path,rel:"noopener"},u):P.createElement("a",{key:"link",onClick:e.handleNavClick,href:r.path||r.children&&r.children[0].path},u):P.createElement("a",{key:"link",onClick:r.children?function(){return o(r)}:void 0},u)},isActive:function(e){return!!n.isCurrentUrl(null==e?void 0:e.path,e)}}),o?i("aside-before",o):null)},t.prototype.renderFooter=function(){var e=this.props,t=e.render,a=e.footer;return a?t("footer",a):null},t.prototype.render=function(){var e,t=this,a=this.props,n=a.classnames,r=a.store,o=a.render,i=a.showBreadcrumb,s=void 0===i||i,l=a.loadingConfig;return P.createElement(b,{header:this.renderHeader(),aside:this.renderAside(),footer:this.renderFooter(),folded:r.folded,offScreen:r.offScreen,contentClassName:n("AppContent")},r.activePage&&r.schema?P.createElement(P.Fragment,null,s&&r.bcn.length?P.createElement("ul",{className:n("AppBcn")},r.bcn.map(function(e,a){return P.createElement("li",{key:a,className:n("AppBcn-item")},e.path?P.createElement("a",{href:e.path,onClick:t.handleNavClick},e.label):a!==r.bcn.length-1?P.createElement("a",null,e.label):e.label)})):null,P.createElement("div",{className:n("AppBody")},o("page",r.schema,{key:"".concat(null===(e=r.activePage)||void 0===e?void 0:e.id,"-").concat(r.schemaKey),data:r.pageData,resolveDefinitions:this.resolveDefinitions}))):r.pages&&!r.activePage?P.createElement(f,null,P.createElement("div",{className:"text-center"},"页面不存在")):null,P.createElement(y,{loadingConfig:l,overlay:!0,show:r.loading||!r.pages,size:"lg"}))},t.propsList=["brandName","logo","header","asideBefore","asideAfter","pages","footer"],t.defaultProps={},i([l,o("design:type",Function),o("design:paramtypes",[String]),o("design:returntype",void 0)],t.prototype,"resolveDefinitions",null),i([l,o("design:type",Function),o("design:paramtypes",[Object]),o("design:returntype",void 0)],t.prototype,"handleNavClick",null),t}(P.Component),k=function(e){function t(t,a){var n=e.call(this,t)||this;return a.registerComponent(n),n}return n(t,e),t.prototype.componentWillUnmount=function(){this.context.unRegisterComponent(this),e.prototype.componentWillUnmount.call(this)},t.prototype.setData=function(e,t){return this.props.store.updateData(e,void 0,t)},t.prototype.getData=function(){return this.props.store.data},t.contextType=m,i([h({type:"app",storeType:u.name}),o("design:paramtypes",[Object,Object])],t)}(B);export{B as App,k as default};
@@ -1 +1 @@
1
- import{o as e}from"./rolldown-runtime-DcYi-9oA.js";import{t}from"./react-BW4ssgUo.js";import{i as n,o,r as a}from"./tslib.es6-C2q27PUR.js";import{j as s}from"./function-C8ta9DKb.js";import{$n as i,Nn as r,Xr as p,it as u,zn as l}from"./esm-BMvKJM5q.js";import"./esm-BbZME5Ac.js";import{s as d}from"./PopUp-DaheG-Vv.js";var c=/* @__PURE__ */e(t()),m=/* @__PURE__ */e(s()),y=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={src:i(t.props,function(e){return e.src?p(e.src,e.data,"| raw"):void 0})||"",isReady:!1,muted:!1,playing:!1,played:0,seeking:!1,volume:.8,prevVolume:.8,loaded:0,playbackRate:1,showHandlePlaybackRate:!1,showHandleVolume:!1},t}return n(t,e),t.prototype.componentWillUnmount=function(){clearTimeout(this.progressTimeout),clearTimeout(this.durationTimeout)},t.prototype.componentDidMount=function(){var e=!!this.props.autoPlay;this.setState({playing:e},this.progress)},t.prototype.componentDidUpdate=function(e){var t=this,n=this.props;l(n,e,function(e){return t.setState({src:e,playing:!1},function(){t.audio.load(),t.progress()})},function(e){return e.src?p(e.src,e.data,"| raw"):void 0})},t.prototype.progress=function(){if(clearTimeout(this.progressTimeout),this.state.src&&this.audio){var e=(this.audio.currentTime||0)/this.audio.duration,t=this.state.playing;t=!(1==e||!t),this.setState({played:e,playing:t}),this.progressTimeout=setTimeout(this.progress,this.props.progressInterval/this.state.playbackRate)}},t.prototype.audioRef=function(e){this.audio=e},t.prototype.load=function(){this.setState({isReady:!0})},t.prototype.handlePlaybackRate=function(e){this.audio.playbackRate=e,this.setState({playbackRate:e,showHandlePlaybackRate:!1})},t.prototype.handleMute=function(){if(this.state.src){var e=this.state,t=e.muted,n=e.prevVolume,o=t?n:0;this.audio.muted=!t,this.setState({muted:!t,volume:o})}},t.prototype.handlePlaying=function(){if(this.state.src){var e=this.state.playing;e?this.audio.pause():this.audio.play(),this.setState({playing:!e})}},t.prototype.getCurrentTime=function(){if(!this.audio||!this.state.src||!this.state.isReady)return"0:00";var e=this.audio.duration,t=this.state.played;return this.formatTime(e*(t||0))},t.prototype.getDuration=function(){if(!this.audio||!this.state.src)return"0:00";if(!this.state.isReady)return this.onDurationCheck(),"0:00";var e=this.audio,t=e.duration,n=e.seekable;return t===1/0&&n.length>0?n.end(n.length-1):this.formatTime(t)},t.prototype.onDurationCheck=function(){clearTimeout(this.durationTimeout),this.audio&&this.audio.duration||(this.durationTimeout=setTimeout(this.onDurationCheck,500))},t.prototype.onSeekChange=function(e){if(this.state.src){var t=e.target.value;this.setState({played:t})}},t.prototype.onSeekMouseDown=function(){this.setState({seeking:!0})},t.prototype.onSeekMouseUp=function(e){if(this.state.src&&this.state.seeking){var t=e.target.value,n=this.audio.duration;this.audio.currentTime=n*t;var o=this.props.loop,a=this.state.playing;a=!!(t<1||o)&&a,this.setState({playing:a,seeking:!1})}},t.prototype.setVolume=function(e){if(this.state.src){var t=e.target.value;this.audio.volume=t,this.setState({volume:t,prevVolume:t})}},t.prototype.formatTime=function(e){var t=/* @__PURE__ */new Date(1e3*e),n=t.getUTCHours(),o=isNaN(t.getUTCMinutes())?0:t.getUTCMinutes(),a=isNaN(t.getUTCSeconds())?"00":this.pad(t.getUTCSeconds());return n?"".concat(n,":").concat(this.pad(o),":").concat(a):"".concat(o,":").concat(a)},t.prototype.pad=function(e){return("0"+e).slice(-2)},t.prototype.toggleHandlePlaybackRate=function(){this.state.src&&this.setState({showHandlePlaybackRate:!this.state.showHandlePlaybackRate})},t.prototype.toggleHandleVolume=function(e){this.state.src&&this.setState({showHandleVolume:e})},t.prototype.renderRates=function(){var e=this,t=this.props,n=t.rates,o=t.classnames,a=this.state,s=a.showHandlePlaybackRate,i=a.playbackRate;return n&&n.length?s?c.createElement("div",{className:o("Audio-rateControl")},n.map(function(t,n){return c.createElement("div",{key:n,className:o("Audio-rateControlItem"),onClick:function(){return e.handlePlaybackRate(t)}},"x",t.toFixed(1))})):c.createElement("div",{className:o("Audio-rates"),onClick:this.toggleHandlePlaybackRate},"x",i.toFixed(1)):null},t.prototype.renderPlay=function(){var e=this.props.classnames,t=this.state.playing;return c.createElement("div",{className:e("Audio-play"),onClick:this.handlePlaying},t?c.createElement(d,{icon:"pause",className:"icon"}):c.createElement(d,{icon:"play",className:"icon"}))},t.prototype.renderTime=function(){var e=this.props.classnames;return c.createElement("div",{className:e("Audio-times")},this.getCurrentTime()," / ",this.getDuration())},t.prototype.renderProcess=function(){var e=this.props.classnames,t=this.state.played;return c.createElement("div",{className:e("Audio-process")},c.createElement("input",{type:"range",min:0,max:1,step:"any",value:t||0,onMouseDown:this.onSeekMouseDown,onChange:this.onSeekChange,onMouseUp:this.onSeekMouseUp}))},t.prototype.renderVolume=function(){var e=this,t=this.props.classnames,n=this.state,o=n.volume;return n.showHandleVolume?c.createElement("div",{className:t("Audio-volumeControl"),onMouseLeave:function(){return e.toggleHandleVolume(!1)}},c.createElement("div",{className:t("Audio-volumeControlIcon"),onClick:this.handleMute},o>0?c.createElement(d,{icon:"volume",className:"icon"}):c.createElement(d,{icon:"mute",className:"icon"})),c.createElement("input",{type:"range",min:0,max:1,step:"any",value:o,onChange:this.setVolume})):c.createElement("div",{className:t("Audio-volume"),onMouseEnter:function(){return e.toggleHandleVolume(!0)}},o>0?c.createElement(d,{icon:"volume",className:"icon"}):c.createElement(d,{icon:"mute",className:"icon"}))},t.prototype.render=function(){var e=this,t=this.props,n=t.className,o=t.style,a=t.inline,s=t.autoPlay,i=t.loop,r=t.controls,p=t.classnames,u=this.state,l=u.muted,d=u.src;return c.createElement("div",{className:p("Audio",n,a?"Audio--inline":""),style:o},c.createElement("audio",{className:p("Audio-original"),ref:this.audioRef,onCanPlay:this.load,autoPlay:s,controls:!0,muted:l,loop:i},c.createElement("source",{src:d})),c.createElement("div",{className:p("Audio-controls")},r&&r.map(function(t,n){var o=t="render"+(0,m.default)(t);return c.createElement(c.Fragment,{key:n},e[o]())})))},t.defaultProps={inline:!0,autoPlay:!1,playbackRate:1,loop:!1,rates:[],progressInterval:1e3,controls:["rates","play","time","process","volume"]},a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"progress",null),a([r,o("design:type",Function),o("design:paramtypes",[HTMLMediaElement]),o("design:returntype",void 0)],t.prototype,"audioRef",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"load",null),a([r,o("design:type",Function),o("design:paramtypes",[Number]),o("design:returntype",void 0)],t.prototype,"handlePlaybackRate",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"handleMute",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"handlePlaying",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"getCurrentTime",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"getDuration",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"onDurationCheck",null),a([r,o("design:type",Function),o("design:paramtypes",[Object]),o("design:returntype",void 0)],t.prototype,"onSeekChange",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"onSeekMouseDown",null),a([r,o("design:type",Function),o("design:paramtypes",[Object]),o("design:returntype",void 0)],t.prototype,"onSeekMouseUp",null),a([r,o("design:type",Function),o("design:paramtypes",[Object]),o("design:returntype",void 0)],t.prototype,"setVolume",null),a([r,o("design:type",Function),o("design:paramtypes",[Number]),o("design:returntype",void 0)],t.prototype,"formatTime",null),a([r,o("design:type",Function),o("design:paramtypes",[Number]),o("design:returntype",void 0)],t.prototype,"pad",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"toggleHandlePlaybackRate",null),a([r,o("design:type",Function),o("design:paramtypes",[Boolean]),o("design:returntype",void 0)],t.prototype,"toggleHandleVolume",null),t}(c.Component),h=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n(t,e),a([u({type:"audio"})],t)}(y);export{y as Audio,h as AudioRenderer};
1
+ import{o as e}from"./rolldown-runtime-Ch1CtRr1.js";import{t}from"./react-1dn4ot9O.js";import{i as n,o,r as a}from"./tslib.es6-C2q27PUR.js";import{j as s}from"./function-Bv9HjNfK.js";import{$n as i,Nn as r,Xr as p,it as u,zn as l}from"./esm-HJl7vXYN.js";import"./esm-BmJ_y26h.js";import{s as d}from"./PopUp-COxX3IAH.js";var c=/* @__PURE__ */e(t()),m=/* @__PURE__ */e(s()),y=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={src:i(t.props,function(e){return e.src?p(e.src,e.data,"| raw"):void 0})||"",isReady:!1,muted:!1,playing:!1,played:0,seeking:!1,volume:.8,prevVolume:.8,loaded:0,playbackRate:1,showHandlePlaybackRate:!1,showHandleVolume:!1},t}return n(t,e),t.prototype.componentWillUnmount=function(){clearTimeout(this.progressTimeout),clearTimeout(this.durationTimeout)},t.prototype.componentDidMount=function(){var e=!!this.props.autoPlay;this.setState({playing:e},this.progress)},t.prototype.componentDidUpdate=function(e){var t=this,n=this.props;l(n,e,function(e){return t.setState({src:e,playing:!1},function(){t.audio.load(),t.progress()})},function(e){return e.src?p(e.src,e.data,"| raw"):void 0})},t.prototype.progress=function(){if(clearTimeout(this.progressTimeout),this.state.src&&this.audio){var e=(this.audio.currentTime||0)/this.audio.duration,t=this.state.playing;t=!(1==e||!t),this.setState({played:e,playing:t}),this.progressTimeout=setTimeout(this.progress,this.props.progressInterval/this.state.playbackRate)}},t.prototype.audioRef=function(e){this.audio=e},t.prototype.load=function(){this.setState({isReady:!0})},t.prototype.handlePlaybackRate=function(e){this.audio.playbackRate=e,this.setState({playbackRate:e,showHandlePlaybackRate:!1})},t.prototype.handleMute=function(){if(this.state.src){var e=this.state,t=e.muted,n=e.prevVolume,o=t?n:0;this.audio.muted=!t,this.setState({muted:!t,volume:o})}},t.prototype.handlePlaying=function(){if(this.state.src){var e=this.state.playing;e?this.audio.pause():this.audio.play(),this.setState({playing:!e})}},t.prototype.getCurrentTime=function(){if(!this.audio||!this.state.src||!this.state.isReady)return"0:00";var e=this.audio.duration,t=this.state.played;return this.formatTime(e*(t||0))},t.prototype.getDuration=function(){if(!this.audio||!this.state.src)return"0:00";if(!this.state.isReady)return this.onDurationCheck(),"0:00";var e=this.audio,t=e.duration,n=e.seekable;return t===1/0&&n.length>0?n.end(n.length-1):this.formatTime(t)},t.prototype.onDurationCheck=function(){clearTimeout(this.durationTimeout),this.audio&&this.audio.duration||(this.durationTimeout=setTimeout(this.onDurationCheck,500))},t.prototype.onSeekChange=function(e){if(this.state.src){var t=e.target.value;this.setState({played:t})}},t.prototype.onSeekMouseDown=function(){this.setState({seeking:!0})},t.prototype.onSeekMouseUp=function(e){if(this.state.src&&this.state.seeking){var t=e.target.value,n=this.audio.duration;this.audio.currentTime=n*t;var o=this.props.loop,a=this.state.playing;a=!!(t<1||o)&&a,this.setState({playing:a,seeking:!1})}},t.prototype.setVolume=function(e){if(this.state.src){var t=e.target.value;this.audio.volume=t,this.setState({volume:t,prevVolume:t})}},t.prototype.formatTime=function(e){var t=/* @__PURE__ */new Date(1e3*e),n=t.getUTCHours(),o=isNaN(t.getUTCMinutes())?0:t.getUTCMinutes(),a=isNaN(t.getUTCSeconds())?"00":this.pad(t.getUTCSeconds());return n?"".concat(n,":").concat(this.pad(o),":").concat(a):"".concat(o,":").concat(a)},t.prototype.pad=function(e){return("0"+e).slice(-2)},t.prototype.toggleHandlePlaybackRate=function(){this.state.src&&this.setState({showHandlePlaybackRate:!this.state.showHandlePlaybackRate})},t.prototype.toggleHandleVolume=function(e){this.state.src&&this.setState({showHandleVolume:e})},t.prototype.renderRates=function(){var e=this,t=this.props,n=t.rates,o=t.classnames,a=this.state,s=a.showHandlePlaybackRate,i=a.playbackRate;return n&&n.length?s?c.createElement("div",{className:o("Audio-rateControl")},n.map(function(t,n){return c.createElement("div",{key:n,className:o("Audio-rateControlItem"),onClick:function(){return e.handlePlaybackRate(t)}},"x",t.toFixed(1))})):c.createElement("div",{className:o("Audio-rates"),onClick:this.toggleHandlePlaybackRate},"x",i.toFixed(1)):null},t.prototype.renderPlay=function(){var e=this.props.classnames,t=this.state.playing;return c.createElement("div",{className:e("Audio-play"),onClick:this.handlePlaying},t?c.createElement(d,{icon:"pause",className:"icon"}):c.createElement(d,{icon:"play",className:"icon"}))},t.prototype.renderTime=function(){var e=this.props.classnames;return c.createElement("div",{className:e("Audio-times")},this.getCurrentTime()," / ",this.getDuration())},t.prototype.renderProcess=function(){var e=this.props.classnames,t=this.state.played;return c.createElement("div",{className:e("Audio-process")},c.createElement("input",{type:"range",min:0,max:1,step:"any",value:t||0,onMouseDown:this.onSeekMouseDown,onChange:this.onSeekChange,onMouseUp:this.onSeekMouseUp}))},t.prototype.renderVolume=function(){var e=this,t=this.props.classnames,n=this.state,o=n.volume;return n.showHandleVolume?c.createElement("div",{className:t("Audio-volumeControl"),onMouseLeave:function(){return e.toggleHandleVolume(!1)}},c.createElement("div",{className:t("Audio-volumeControlIcon"),onClick:this.handleMute},o>0?c.createElement(d,{icon:"volume",className:"icon"}):c.createElement(d,{icon:"mute",className:"icon"})),c.createElement("input",{type:"range",min:0,max:1,step:"any",value:o,onChange:this.setVolume})):c.createElement("div",{className:t("Audio-volume"),onMouseEnter:function(){return e.toggleHandleVolume(!0)}},o>0?c.createElement(d,{icon:"volume",className:"icon"}):c.createElement(d,{icon:"mute",className:"icon"}))},t.prototype.render=function(){var e=this,t=this.props,n=t.className,o=t.style,a=t.inline,s=t.autoPlay,i=t.loop,r=t.controls,p=t.classnames,u=this.state,l=u.muted,d=u.src;return c.createElement("div",{className:p("Audio",n,a?"Audio--inline":""),style:o},c.createElement("audio",{className:p("Audio-original"),ref:this.audioRef,onCanPlay:this.load,autoPlay:s,controls:!0,muted:l,loop:i},c.createElement("source",{src:d})),c.createElement("div",{className:p("Audio-controls")},r&&r.map(function(t,n){var o=t="render"+(0,m.default)(t);return c.createElement(c.Fragment,{key:n},e[o]())})))},t.defaultProps={inline:!0,autoPlay:!1,playbackRate:1,loop:!1,rates:[],progressInterval:1e3,controls:["rates","play","time","process","volume"]},a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"progress",null),a([r,o("design:type",Function),o("design:paramtypes",[HTMLMediaElement]),o("design:returntype",void 0)],t.prototype,"audioRef",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"load",null),a([r,o("design:type",Function),o("design:paramtypes",[Number]),o("design:returntype",void 0)],t.prototype,"handlePlaybackRate",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"handleMute",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"handlePlaying",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"getCurrentTime",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"getDuration",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"onDurationCheck",null),a([r,o("design:type",Function),o("design:paramtypes",[Object]),o("design:returntype",void 0)],t.prototype,"onSeekChange",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"onSeekMouseDown",null),a([r,o("design:type",Function),o("design:paramtypes",[Object]),o("design:returntype",void 0)],t.prototype,"onSeekMouseUp",null),a([r,o("design:type",Function),o("design:paramtypes",[Object]),o("design:returntype",void 0)],t.prototype,"setVolume",null),a([r,o("design:type",Function),o("design:paramtypes",[Number]),o("design:returntype",void 0)],t.prototype,"formatTime",null),a([r,o("design:type",Function),o("design:paramtypes",[Number]),o("design:returntype",void 0)],t.prototype,"pad",null),a([r,o("design:type",Function),o("design:paramtypes",[]),o("design:returntype",void 0)],t.prototype,"toggleHandlePlaybackRate",null),a([r,o("design:type",Function),o("design:paramtypes",[Boolean]),o("design:returntype",void 0)],t.prototype,"toggleHandleVolume",null),t}(c.Component),h=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n(t,e),a([u({type:"audio"})],t)}(y);export{y as Audio,h as AudioRenderer};
@@ -1 +1 @@
1
- import{o as t}from"./rolldown-runtime-DcYi-9oA.js";import{t as e}from"./react-BW4ssgUo.js";import{i as n,o as s,r}from"./tslib.es6-C2q27PUR.js";import{Ii as a,Nn as o,Zr as i,it as p}from"./esm-BMvKJM5q.js";import{Ft as l,R as c}from"./esm-BbZME5Ac.js";var u=/* @__PURE__ */t(e()),d=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.handleClick=function(t){var e=this.props;(0,e.dispatchEvent)(t,e.data)},e.prototype.handleMouseEnter=function(t){var e=this.props;(0,e.dispatchEvent)(t,e.data)},e.prototype.handleMouseLeave=function(t){var e=this.props;(0,e.dispatchEvent)(t,e.data)},e.prototype.render=function(){var t=this.props,e=t.style,n=void 0===e?{}:e,s=t.className,r=t.classnames,o=t.src,p=t.defaultAvatar,c=t.icon,d=void 0===c?"fa fa-user":c,h=t.fit,y=t.shape,m=t.size,f=t.text,v=t.gap,g=t.alt,E=t.draggable,j=t.crossOrigin,M=t.onError,b=t.data,C=function(){return!1};if("string"==typeof M)try{C=new Function("event",M)}catch(F){console.warn(M,F)}return i(o)&&(o=a(o,b,"| raw")),i(f)&&(f=a(f,b)),i(d)&&(d=a(d,b)),u.createElement(l,{style:n,className:s,classnames:r,src:o||p,icon:d,fit:h,shape:y,size:m,text:f,gap:v,alt:g,draggable:E,crossOrigin:j,onError:C,onClick:this.handleClick,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave})},r([o,s("design:type",Function),s("design:paramtypes",[Object]),s("design:returntype",void 0)],e.prototype,"handleClick",null),r([o,s("design:type",Function),s("design:paramtypes",[Object]),s("design:returntype",void 0)],e.prototype,"handleMouseEnter",null),r([o,s("design:type",Function),s("design:paramtypes",[Object]),s("design:returntype",void 0)],e.prototype,"handleMouseLeave",null),e}(u.Component),h=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),r([p({type:"avatar"}),c],e)}(d);export{d as AvatarField,h as AvatarFieldRenderer};
1
+ import{o as t}from"./rolldown-runtime-Ch1CtRr1.js";import{t as e}from"./react-1dn4ot9O.js";import{i as n,o as s,r}from"./tslib.es6-C2q27PUR.js";import{Ii as a,Nn as o,Zr as i,it as p}from"./esm-HJl7vXYN.js";import{Ft as l,R as c}from"./esm-BmJ_y26h.js";var u=/* @__PURE__ */t(e()),d=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.handleClick=function(t){var e=this.props;(0,e.dispatchEvent)(t,e.data)},e.prototype.handleMouseEnter=function(t){var e=this.props;(0,e.dispatchEvent)(t,e.data)},e.prototype.handleMouseLeave=function(t){var e=this.props;(0,e.dispatchEvent)(t,e.data)},e.prototype.render=function(){var t=this.props,e=t.style,n=void 0===e?{}:e,s=t.className,r=t.classnames,o=t.src,p=t.defaultAvatar,c=t.icon,d=void 0===c?"fa fa-user":c,h=t.fit,y=t.shape,m=t.size,f=t.text,v=t.gap,g=t.alt,E=t.draggable,j=t.crossOrigin,M=t.onError,b=t.data,C=function(){return!1};if("string"==typeof M)try{C=new Function("event",M)}catch(F){console.warn(M,F)}return i(o)&&(o=a(o,b,"| raw")),i(f)&&(f=a(f,b)),i(d)&&(d=a(d,b)),u.createElement(l,{style:n,className:s,classnames:r,src:o||p,icon:d,fit:h,shape:y,size:m,text:f,gap:v,alt:g,draggable:E,crossOrigin:j,onError:C,onClick:this.handleClick,onMouseEnter:this.handleMouseEnter,onMouseLeave:this.handleMouseLeave})},r([o,s("design:type",Function),s("design:paramtypes",[Object]),s("design:returntype",void 0)],e.prototype,"handleClick",null),r([o,s("design:type",Function),s("design:paramtypes",[Object]),s("design:returntype",void 0)],e.prototype,"handleMouseEnter",null),r([o,s("design:type",Function),s("design:paramtypes",[Object]),s("design:returntype",void 0)],e.prototype,"handleMouseLeave",null),e}(u.Component),h=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),r([p({type:"avatar"}),c],e)}(d);export{d as AvatarField,h as AvatarFieldRenderer};
@@ -1 +1 @@
1
- import{o as t}from"./rolldown-runtime-DcYi-9oA.js";import{t as e}from"./react-BW4ssgUo.js";import{i as r,r as s}from"./tslib.es6-C2q27PUR.js";import{$n as n,it as a}from"./esm-BMvKJM5q.js";var o=/* @__PURE__ */t(e()),i=o.lazy(function(){return import("./BarCode-BnchzdIg.js")}),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.render=function(){var t=this.props,e=t.className,r=t.style;t.width,t.height;var s=t.classnames,a=t.options,l=n(this.props);return o.createElement(o.Suspense,{fallback:o.createElement("div",null,"...")},o.createElement("div",{"data-testid":"barcode",className:s("BarCode",e),style:r},o.createElement(i,{value:l,options:a})))},e}(o.Component),p=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),s([a({type:"barcode"})],e)}(l);export{l as BarCodeField,p as BarCodeFieldRenderer};
1
+ import{o as t}from"./rolldown-runtime-Ch1CtRr1.js";import{t as e}from"./react-1dn4ot9O.js";import{i as r,r as s}from"./tslib.es6-C2q27PUR.js";import{$n as n,it as a}from"./esm-HJl7vXYN.js";var o=/* @__PURE__ */t(e()),i=o.lazy(function(){return import("./BarCode-CMMFyYuP.js")}),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.render=function(){var t=this.props,e=t.className,r=t.style;t.width,t.height;var s=t.classnames,a=t.options,l=n(this.props);return o.createElement(o.Suspense,{fallback:o.createElement("div",null,"...")},o.createElement("div",{"data-testid":"barcode",className:s("BarCode",e),style:r},o.createElement(i,{value:l,options:a})))},e}(o.Component),p=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),s([a({type:"barcode"})],e)}(l);export{l as BarCodeField,p as BarCodeFieldRenderer};
@@ -0,0 +1 @@
1
+ import{o as t,t as e}from"./rolldown-runtime-Ch1CtRr1.js";import{t as n}from"./react-1dn4ot9O.js";import{i as r}from"./tslib.es6-C2q27PUR.js";import{tt as o}from"./esm-HJl7vXYN.js";var i=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function t(e,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.data=e,this.text=n.text||e,this.options=n}}),a=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CODE39=void 0;var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),t=t.toUpperCase(),n.mod43&&(t+=function(t){return o[t]}(function(t){for(var e=0,n=0;n<t.length;n++)e+=f(t[n]);return e%43}(t))),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"encode",value:function(){for(var t=u("*"),e=0;e<this.data.length;e++)t+=u(this.data[e])+"0";return{data:t+=u("*"),text:this.text}}},{key:"valid",value:function(){return-1!==this.data.search(/^[0-9A-Z\-\.\ \$\/\+\%]+$/)}}]),e}(((e=i())&&e.__esModule?e:{default:e}).default),o=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","-","."," ","$","/","+","%","*"],a=[20957,29783,23639,30485,20951,29813,23669,20855,29789,23645,29975,23831,30533,22295,30149,24005,21623,29981,23837,22301,30023,23879,30545,22343,30161,24017,21959,30065,23921,22385,29015,18263,29141,17879,29045,18293,17783,29021,18269,17477,17489,17681,20753,35770];function u(t){return function(t){return a[t].toString(2)}(f(t))}function f(t){return o.indexOf(t)}t.CODE39=r}),u=/* @__PURE__ */e(t=>{var e;function n(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}Object.defineProperty(t,"__esModule",{value:!0});var r=t.SET_A=0,o=t.SET_B=1,i=t.SET_C=2;t.SHIFT=98;var a=t.START_A=103,u=t.START_B=104,f=t.START_C=105;t.MODULO=103,t.STOP=106,t.FNC1=207,t.SET_BY_CODE=(n(e={},a,r),n(e,u,o),n(e,f,i),e),t.SWAP={101:r,100:o,99:i},t.A_START_CHAR=String.fromCharCode(208),t.B_START_CHAR=String.fromCharCode(209),t.C_START_CHAR=String.fromCharCode(210),t.A_CHARS="[\0-_È-Ï]",t.B_CHARS="[ -È-Ï]",t.C_CHARS="(Ï*[0-9]{2}Ï*)",t.BARS=[11011001100,11001101100,11001100110,10010011e3,10010001100,10001001100,10011001e3,10011000100,10001100100,11001001e3,11001000100,11000100100,10110011100,10011011100,10011001110,10111001100,10011101100,10011100110,11001110010,11001011100,11001001110,11011100100,11001110100,11101101110,11101001100,11100101100,11100100110,11101100100,11100110100,11100110010,11011011e3,11011000110,11000110110,10100011e3,10001011e3,10001000110,10110001e3,10001101e3,10001100010,11010001e3,11000101e3,11000100010,10110111e3,10110001110,10001101110,10111011e3,10111000110,10001110110,11101110110,11010001110,11000101110,11011101e3,11011100010,11011101110,11101011e3,11101000110,11100010110,11101101e3,11101100010,11100011010,11101111010,11001000010,11110001010,1010011e4,10100001100,1001011e4,10010000110,10000101100,10000100110,1011001e4,10110000100,1001101e4,10011000010,10000110100,10000110010,11000010010,1100101e4,11110111010,11000010100,10001111010,10100111100,10010111100,10010011110,10111100100,10011110100,10011110010,11110100100,11110010100,11110010010,11011011110,11011110110,11110110110,10101111e3,10100011110,10001011110,10111101e3,10111100010,11110101e3,11110100010,10111011110,10111101110,11101011110,11110101110,11010000100,1101001e4,11010011100,1100011101011]}),f=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=(e=i())&&e.__esModule?e:{default:e},o=u(),a=function(t){function e(t,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t.substring(1),n));return r.bytes=t.split("").map(function(t){return t.charCodeAt(0)}),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return/^[\x00-\x7F\xC8-\xD3]+$/.test(this.data)}},{key:"encode",value:function(){var t=this.bytes,n=t.shift()-105,r=o.SET_BY_CODE[n];if(void 0===r)throw new RangeError("The encoding does not start with a start character.");!0===this.shouldEncodeAsEan128()&&t.unshift(o.FNC1);var i=e.next(t,1,r);return{text:this.text===this.data?this.text.replace(/[^\x20-\x7E]/g,""):this.text,data:e.getBar(n)+i.result+e.getBar((i.checksum+n)%o.MODULO)+e.getBar(o.STOP)}}},{key:"shouldEncodeAsEan128",value:function(){var t=this.options.ean128||!1;return"string"==typeof t&&(t="true"===t.toLowerCase()),t}}],[{key:"getBar",value:function(t){return o.BARS[t]?o.BARS[t].toString():""}},{key:"correctIndex",value:function(t,e){if(e===o.SET_A){var n=t.shift();return n<32?n+64:n-32}return e===o.SET_B?t.shift()-32:10*(t.shift()-48)+t.shift()-48}},{key:"next",value:function(t,n,r){if(!t.length)return{result:"",checksum:0};var i=void 0,a=void 0;if(t[0]>=200){a=t.shift()-105;var u=o.SWAP[a];void 0!==u?i=e.next(t,n+1,u):(r!==o.SET_A&&r!==o.SET_B||a!==o.SHIFT||(t[0]=r===o.SET_A?t[0]>95?t[0]-96:t[0]:t[0]<32?t[0]+96:t[0]),i=e.next(t,n+1,r))}else a=e.correctIndex(t,r),i=e.next(t,n+1,r);var f=a*n;return{result:e.getBar(a)+i.result,checksum:f+i.checksum}}}]),e}(r.default);t.default=a}),c=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=u(),n=function(t){return t.match(new RegExp("^"+e.A_CHARS+"*"))[0].length},r=function(t){return t.match(new RegExp("^"+e.B_CHARS+"*"))[0].length},o=function(t){return t.match(new RegExp("^"+e.C_CHARS+"*"))[0]};function i(t,n){var r=n?e.A_CHARS:e.B_CHARS,o=t.match(new RegExp("^("+r+"+?)(([0-9]{2}){2,})([^0-9]|$)"));if(o)return o[1]+String.fromCharCode(204)+a(t.substring(o[1].length));var u=t.match(new RegExp("^"+r+"+"))[0];return u.length===t.length?t:u+String.fromCharCode(n?205:206)+i(t.substring(u.length),!n)}function a(t){var e=o(t),a=e.length;if(a===t.length)return t;t=t.substring(a);var u=n(t)>=r(t);return e+String.fromCharCode(u?206:205)+i(t,u)}t.default=function(t){var u=void 0;if(o(t).length>=2)u=e.C_START_CHAR+a(t);else{var f=n(t)>r(t);u=(f?e.A_START_CHAR:e.B_START_CHAR)+i(t,f)}return u.replace(/[\xCD\xCE]([^])[\xCD\xCE]/,function(t,e){return String.fromCharCode(203)+e})}}),l=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=r(f()),n=r(c());function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}var i=function(t){function e(t,r){if(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),/^[\x00-\x7F\xC8-\xD3]+$/.test(t))var i=o(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,(0,n.default)(t),r));else i=o(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,r));return o(i)}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e}(e.default);t.default=i}),s=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=(e=f())&&e.__esModule?e:{default:e},o=u(),i=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,o.A_START_CHAR+t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return new RegExp("^"+o.A_CHARS+"+$").test(this.data)}}]),e}(r.default);t.default=i}),p=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=(e=f())&&e.__esModule?e:{default:e},o=u(),i=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,o.B_START_CHAR+t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return new RegExp("^"+o.B_CHARS+"+$").test(this.data)}}]),e}(r.default);t.default=i}),d=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=(e=f())&&e.__esModule?e:{default:e},o=u(),i=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,o.C_START_CHAR+t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return new RegExp("^"+o.C_CHARS+"+$").test(this.data)}}]),e}(r.default);t.default=i}),h=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CODE128C=t.CODE128B=t.CODE128A=t.CODE128=void 0;var e=i(l()),n=i(s()),r=i(p()),o=i(d());function i(t){return t&&t.__esModule?t:{default:t}}t.CODE128=e.default,t.CODE128A=n.default,t.CODE128B=r.default,t.CODE128C=o.default}),y=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.SIDE_BIN="101",t.MIDDLE_BIN="01010",t.BINARIES={L:["0001101","0011001","0010011","0111101","0100011","0110001","0101111","0111011","0110111","0001011"],G:["0100111","0110011","0011011","0100001","0011101","0111001","0000101","0010001","0001001","0010111"],R:["1110010","1100110","1101100","1000010","1011100","1001110","1010000","1000100","1001000","1110100"],O:["0001101","0011001","0010011","0111101","0100011","0110001","0101111","0111011","0110111","0001011"],E:["0100111","0110011","0011011","0100001","0011101","0111001","0000101","0010001","0001001","0010111"]},t.EAN2_STRUCTURE=["LL","LG","GL","GG"],t.EAN5_STRUCTURE=["GGLLL","GLGLL","GLLGL","GLLLG","LGGLL","LLGGL","LLLGG","LGLGL","LGLLG","LLGLG"],t.EAN13_STRUCTURE=["LLLLLL","LLGLGG","LLGGLG","LLGGGL","LGLLGG","LGGLLG","LGGGLL","LGLGLG","LGLGGL","LGGLGL"]}),b=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=y();t.default=function(t,n,r){var o=t.split("").map(function(t,r){return e.BINARIES[n[r]]}).map(function(e,n){return e?e[t[n]]:""});if(r){var i=t.length-1;o=o.map(function(t,e){return e<i?t+r:t})}return o.join("")}}),v=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),n=y(),r=o(b());function o(t){return t&&t.__esModule?t:{default:t}}var a=function(t){function o(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,o);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,t,e));return n.fontSize=!e.flat&&e.fontSize>10*e.width?10*e.width:e.fontSize,n.guardHeight=e.height+n.fontSize/2+e.textMargin,n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(o,t),e(o,[{key:"encode",value:function(){return this.options.flat?this.encodeFlat():this.encodeGuarded()}},{key:"leftText",value:function(t,e){return this.text.substr(t,e)}},{key:"leftEncode",value:function(t,e){return(0,r.default)(t,e)}},{key:"rightText",value:function(t,e){return this.text.substr(t,e)}},{key:"rightEncode",value:function(t,e){return(0,r.default)(t,e)}},{key:"encodeGuarded",value:function(){var t={fontSize:this.fontSize},e={height:this.guardHeight};return[{data:n.SIDE_BIN,options:e},{data:this.leftEncode(),text:this.leftText(),options:t},{data:n.MIDDLE_BIN,options:e},{data:this.rightEncode(),text:this.rightText(),options:t},{data:n.SIDE_BIN,options:e}]}},{key:"encodeFlat",value:function(){return{data:[n.SIDE_BIN,this.leftEncode(),n.MIDDLE_BIN,this.rightEncode(),n.SIDE_BIN].join(""),text:this.text}}}]),o}(o(i()).default);t.default=a}),_=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var a=o.get;return void 0!==a?a.call(r):void 0},o=y(),i=(e=v())&&e.__esModule?e:{default:e},a=function(t){return(10-t.substr(0,12).split("").map(function(t){return+t}).reduce(function(t,e,n){return n%2?t+3*e:t+e},0)%10)%10},u=function(t){function e(t,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),-1!==t.search(/^[0-9]{12}$/)&&(t+=a(t));var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.lastChar=n.lastChar,r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return-1!==this.data.search(/^[0-9]{13}$/)&&+this.data[12]===a(this.data)}},{key:"leftText",value:function(){return r(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"leftText",this).call(this,1,6)}},{key:"leftEncode",value:function(){var t=this.data.substr(1,6),n=o.EAN13_STRUCTURE[this.data[0]];return r(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"leftEncode",this).call(this,t,n)}},{key:"rightText",value:function(){return r(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"rightText",this).call(this,7,6)}},{key:"rightEncode",value:function(){var t=this.data.substr(7,6);return r(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"rightEncode",this).call(this,t,"RRRRRR")}},{key:"encodeGuarded",value:function(){var t=r(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"encodeGuarded",this).call(this);return this.options.displayValue&&(t.unshift({data:"000000000000",text:this.text.substr(0,1),options:{textAlign:"left",fontSize:this.fontSize}}),this.options.lastChar&&(t.push({data:"00"}),t.push({data:"00000",text:this.options.lastChar,options:{fontSize:this.fontSize}}))),t}}]),e}(i.default);t.default=u}),g=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var a=o.get;return void 0!==a?a.call(r):void 0},o=(e=v())&&e.__esModule?e:{default:e},i=function(t){return(10-t.substr(0,7).split("").map(function(t){return+t}).reduce(function(t,e,n){return n%2?t+e:t+3*e},0)%10)%10},a=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),-1!==t.search(/^[0-9]{7}$/)&&(t+=i(t)),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return-1!==this.data.search(/^[0-9]{8}$/)&&+this.data[7]===i(this.data)}},{key:"leftText",value:function(){return r(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"leftText",this).call(this,0,4)}},{key:"leftEncode",value:function(){var t=this.data.substr(0,4);return r(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"leftEncode",this).call(this,t,"LLLL")}},{key:"rightText",value:function(){return r(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"rightText",this).call(this,4,4)}},{key:"rightEncode",value:function(){var t=this.data.substr(4,4);return r(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"rightEncode",this).call(this,t,"RRRR")}}]),e}(o.default);t.default=a}),O=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),n=y(),r=o(b());function o(t){return t&&t.__esModule?t:{default:t}}var a=function(t){function o(t,e){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,o),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,t,e))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(o,t),e(o,[{key:"valid",value:function(){return-1!==this.data.search(/^[0-9]{5}$/)}},{key:"encode",value:function(){var t,e=n.EAN5_STRUCTURE[t=this.data,t.split("").map(function(t){return+t}).reduce(function(t,e,n){return n%2?t+9*e:t+3*e},0)%10];return{data:"1011"+(0,r.default)(this.data,e,"01"),text:this.text}}}]),o}(o(i()).default);t.default=a}),E=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),n=y(),r=o(b());function o(t){return t&&t.__esModule?t:{default:t}}var a=function(t){function o(t,e){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,o),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,t,e))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(o,t),e(o,[{key:"valid",value:function(){return-1!==this.data.search(/^[0-9]{2}$/)}},{key:"encode",value:function(){var t=n.EAN2_STRUCTURE[parseInt(this.data)%4];return{data:"1011"+(0,r.default)(this.data,t,"01"),text:this.text}}}]),o}(o(i()).default);t.default=a}),w=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}();t.checksum=a;var n=r(b());function r(t){return t&&t.__esModule?t:{default:t}}var o=function(t){function r(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,r),-1!==t.search(/^[0-9]{11}$/)&&(t+=a(t));var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,t,e));return n.displayValue=e.displayValue,e.fontSize>10*e.width?n.fontSize=10*e.width:n.fontSize=e.fontSize,n.guardHeight=e.height+n.fontSize/2+e.textMargin,n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(r,t),e(r,[{key:"valid",value:function(){return-1!==this.data.search(/^[0-9]{12}$/)&&this.data[11]==a(this.data)}},{key:"encode",value:function(){return this.options.flat?this.flatEncoding():this.guardedEncoding()}},{key:"flatEncoding",value:function(){var t="";return t+="101",t+=(0,n.default)(this.data.substr(0,6),"LLLLLL"),t+="01010",t+=(0,n.default)(this.data.substr(6,6),"RRRRRR"),{data:t+="101",text:this.text}}},{key:"guardedEncoding",value:function(){var t=[];return this.displayValue&&t.push({data:"00000000",text:this.text.substr(0,1),options:{textAlign:"left",fontSize:this.fontSize}}),t.push({data:"101"+(0,n.default)(this.data[0],"L"),options:{height:this.guardHeight}}),t.push({data:(0,n.default)(this.data.substr(1,5),"LLLLL"),text:this.text.substr(1,5),options:{fontSize:this.fontSize}}),t.push({data:"01010",options:{height:this.guardHeight}}),t.push({data:(0,n.default)(this.data.substr(6,5),"RRRRR"),text:this.text.substr(6,5),options:{fontSize:this.fontSize}}),t.push({data:(0,n.default)(this.data[11],"R")+"101",options:{height:this.guardHeight}}),this.displayValue&&t.push({data:"00000000",text:this.text.substr(11,1),options:{textAlign:"right",fontSize:this.fontSize}}),t}}]),r}(r(i()).default);function a(t){var e,n=0;for(e=1;e<11;e+=2)n+=parseInt(t[e]);for(e=0;e<11;e+=2)n+=3*parseInt(t[e]);return(10-n%10)%10}t.default=o}),m=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),n=a(b()),r=a(i()),o=w();function a(t){return t&&t.__esModule?t:{default:t}}function u(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}var f=["XX00000XXX","XX10000XXX","XX20000XXX","XXX00000XX","XXXX00000X","XXXXX00005","XXXXX00006","XXXXX00007","XXXXX00008","XXXXX00009"],c=[["EEEOOO","OOOEEE"],["EEOEOO","OOEOEE"],["EEOOEO","OOEEOE"],["EEOOOE","OOEEEO"],["EOEEOO","OEOOEE"],["EOOEEO","OEEOOE"],["EOOOEE","OEEEOO"],["EOEOEO","OEOEOE"],["EOEOOE","OEOEEO"],["EOOEOE","OEEOEO"]],l=function(t){function r(t,e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,r);var n=u(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,t,e));if(n.isValid=!1,-1!==t.search(/^[0-9]{6}$/))n.middleDigits=t,n.upcA=s(t,"0"),n.text=e.text||""+n.upcA[0]+t+n.upcA[n.upcA.length-1],n.isValid=!0;else{if(-1===t.search(/^[01][0-9]{7}$/))return u(n);if(n.middleDigits=t.substring(1,t.length-1),n.upcA=s(n.middleDigits,t[0]),n.upcA[n.upcA.length-1]!==t[t.length-1])return u(n);n.isValid=!0}return n.displayValue=e.displayValue,e.fontSize>10*e.width?n.fontSize=10*e.width:n.fontSize=e.fontSize,n.guardHeight=e.height+n.fontSize/2+e.textMargin,n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(r,t),e(r,[{key:"valid",value:function(){return this.isValid}},{key:"encode",value:function(){return this.options.flat?this.flatEncoding():this.guardedEncoding()}},{key:"flatEncoding",value:function(){var t="";return t+="101",t+=this.encodeMiddleDigits(),{data:t+="010101",text:this.text}}},{key:"guardedEncoding",value:function(){var t=[];return this.displayValue&&t.push({data:"00000000",text:this.text[0],options:{textAlign:"left",fontSize:this.fontSize}}),t.push({data:"101",options:{height:this.guardHeight}}),t.push({data:this.encodeMiddleDigits(),text:this.text.substring(1,7),options:{fontSize:this.fontSize}}),t.push({data:"010101",options:{height:this.guardHeight}}),this.displayValue&&t.push({data:"00000000",text:this.text[7],options:{textAlign:"right",fontSize:this.fontSize}}),t}},{key:"encodeMiddleDigits",value:function(){var t=this.upcA[0],e=this.upcA[this.upcA.length-1],r=c[parseInt(e)][parseInt(t)];return(0,n.default)(this.middleDigits,r)}}]),r}(r.default);function s(t,e){for(var n=f[parseInt(t[t.length-1])],r="",i=0,a=0;a<n.length;a++){var u=n[a];r+="X"===u?t[i++]:u}return(r=""+e+r)+(0,o.checksum)(r)}t.default=l}),j=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.UPCE=t.UPC=t.EAN2=t.EAN5=t.EAN8=t.EAN13=void 0;var e=u(_()),n=u(g()),r=u(O()),o=u(E()),i=u(w()),a=u(m());function u(t){return t&&t.__esModule?t:{default:t}}t.EAN13=e.default,t.EAN8=n.default,t.EAN5=r.default,t.EAN2=o.default,t.UPC=i.default,t.UPCE=a.default}),x=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.START_BIN="1010",t.END_BIN="11101",t.BINARIES=["00110","10001","01001","11000","00101","10100","01100","00011","10010","01010"]}),P=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=x(),o=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return-1!==this.data.search(/^([0-9]{2})+$/)}},{key:"encode",value:function(){var t=this,e=this.data.match(/.{2}/g).map(function(e){return t.encodePair(e)}).join("");return{data:r.START_BIN+e+r.END_BIN,text:this.text}}},{key:"encodePair",value:function(t){var e=r.BINARIES[t[1]];return r.BINARIES[t[0]].split("").map(function(t,n){return("1"===t?"111":"1")+("1"===e[n]?"000":"0")}).join("")}}]),e}(((e=i())&&e.__esModule?e:{default:e}).default);t.default=o}),S=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=(e=P())&&e.__esModule?e:{default:e},o=function(t){var e=t.substr(0,13).split("").map(function(t){return parseInt(t,10)}).reduce(function(t,e,n){return t+e*(3-n%2*2)},0);return 10*Math.ceil(e/10)-e},i=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),-1!==t.search(/^[0-9]{13}$/)&&(t+=o(t)),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return-1!==this.data.search(/^[0-9]{14}$/)&&+this.data[13]===o(this.data)}}]),e}(r.default);t.default=i}),C=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.ITF14=t.ITF=void 0;var e=r(P()),n=r(S());function r(t){return t&&t.__esModule?t:{default:t}}t.ITF=e.default,t.ITF14=n.default}),A=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"encode",value:function(){for(var t="110",e=0;e<this.data.length;e++){var n=parseInt(this.data[e]).toString(2);n=o(n,4-n.length);for(var r=0;r<n.length;r++)t+="0"==n[r]?"100":"110"}return{data:t+="1001",text:this.text}}},{key:"valid",value:function(){return-1!==this.data.search(/^[0-9]+$/)}}]),e}(((e=i())&&e.__esModule?e:{default:e}).default);function o(t,e){for(var n=0;n<e;n++)t="0"+t;return t}t.default=r}),T=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.mod10=function(t){for(var e=0,n=0;n<t.length;n++){var r=parseInt(t[n]);(n+t.length)%2==0?e+=r:e+=2*r%10+Math.floor(2*r/10)}return(10-e%10)%10},t.mod11=function(t){for(var e=0,n=[2,3,4,5,6,7],r=0;r<t.length;r++){var o=parseInt(t[t.length-1-r]);e+=n[r%n.length]*o}return(11-e%11)%11}}),M=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=(e=A())&&e.__esModule?e:{default:e},r=T(),o=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t+(0,r.mod10)(t),n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e}(n.default);t.default=o}),R=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=(e=A())&&e.__esModule?e:{default:e},r=T(),o=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t+(0,r.mod11)(t),n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e}(n.default);t.default=o}),L=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=(e=A())&&e.__esModule?e:{default:e},r=T(),o=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),t+=(0,r.mod10)(t),t+=(0,r.mod10)(t),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e}(n.default);t.default=o}),k=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=(e=A())&&e.__esModule?e:{default:e},r=T(),o=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),t+=(0,r.mod11)(t),t+=(0,r.mod10)(t),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e}(n.default);t.default=o}),I=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.MSI1110=t.MSI1010=t.MSI11=t.MSI10=t.MSI=void 0;var e=a(A()),n=a(M()),r=a(R()),o=a(L()),i=a(k());function a(t){return t&&t.__esModule?t:{default:t}}t.MSI=e.default,t.MSI10=n.default,t.MSI11=r.default,t.MSI1010=o.default,t.MSI1110=i.default}),B=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.pharmacode=void 0;var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=function(t){function e(t,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.number=parseInt(t,10),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"encode",value:function(){for(var t=this.number,e="";!isNaN(t)&&0!=t;)t%2==0?(e="11100"+e,t=(t-2)/2):(e="100"+e,t=(t-1)/2);return{data:e=e.slice(0,-2),text:this.text}}},{key:"valid",value:function(){return this.number>=3&&this.number<=131070}}]),e}(((e=i())&&e.__esModule?e:{default:e}).default);t.pharmacode=r}),G=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.codabar=void 0;var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=function(t){function e(t,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),0===t.search(/^[0-9\-\$\:\.\+\/]+$/)&&(t="A"+t+"A");var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t.toUpperCase(),n));return r.text=r.options.text||r.text.replace(/[A-D]/g,""),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return-1!==this.data.search(/^[A-D][0-9\-\$\:\.\+\/]+[A-D]$/)}},{key:"encode",value:function(){for(var t=[],e=this.getEncodings(),n=0;n<this.data.length;n++)t.push(e[this.data.charAt(n)]),n!==this.data.length-1&&t.push("0");return{text:this.text,data:t.join("")}}},{key:"getEncodings",value:function(){return{0:"101010011",1:"101011001",2:"101001011",3:"110010101",4:"101101001",5:"110101001",6:"100101011",7:"100101101",8:"100110101",9:"110100101","-":"101001101",$:"101100101",":":"1101011011","/":"1101101011",".":"1101101101","+":"1011011011",A:"1011001001",B:"1001001011",C:"1010010011",D:"1010011001"}}}]),e}(((e=i())&&e.__esModule?e:{default:e}).default);t.codabar=r}),D=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.SYMBOLS=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","-","."," ","$","/","+","%","($)","(%)","(/)","(+)","ÿ"],t.BINARIES=["100010100","101001000","101000100","101000010","100101000","100100100","100100010","101010000","100010010","100001010","110101000","110100100","110100010","110010100","110010010","110001010","101101000","101100100","101100010","100110100","100011010","101011000","101001100","101000110","100101100","100010110","110110100","110110010","110101100","110100110","110010110","110011010","101101100","101100110","100110110","100111010","100101110","111010100","111010010","111001010","101101110","101110110","110101110","100100110","111011010","111010110","100110010","101011110"],t.MULTI_SYMBOLS={"\0":["(%)","U"],"":["($)","A"],"":["($)","B"],"":["($)","C"],"":["($)","D"],"":["($)","E"],"":["($)","F"],"":["($)","G"],"\b":["($)","H"],"\t":["($)","I"],"\n":["($)","J"],"\v":["($)","K"],"\f":["($)","L"],"\r":["($)","M"],"":["($)","N"],"":["($)","O"],"":["($)","P"],"":["($)","Q"],"":["($)","R"],"":["($)","S"],"":["($)","T"],"":["($)","U"],"":["($)","V"],"":["($)","W"],"":["($)","X"],"":["($)","Y"],"":["($)","Z"],"":["(%)","A"],"":["(%)","B"],"":["(%)","C"],"":["(%)","D"],"":["(%)","E"],"!":["(/)","A"],'"':["(/)","B"],"#":["(/)","C"],"&":["(/)","F"],"'":["(/)","G"],"(":["(/)","H"],")":["(/)","I"],"*":["(/)","J"],",":["(/)","L"],":":["(/)","Z"],";":["(%)","F"],"<":["(%)","G"],"=":["(%)","H"],">":["(%)","I"],"?":["(%)","J"],"@":["(%)","V"],"[":["(%)","K"],"\\":["(%)","L"],"]":["(%)","M"],"^":["(%)","N"],_:["(%)","O"],"`":["(%)","W"],a:["(+)","A"],b:["(+)","B"],c:["(+)","C"],d:["(+)","D"],e:["(+)","E"],f:["(+)","F"],g:["(+)","G"],h:["(+)","H"],i:["(+)","I"],j:["(+)","J"],k:["(+)","K"],l:["(+)","L"],m:["(+)","M"],n:["(+)","N"],o:["(+)","O"],p:["(+)","P"],q:["(+)","Q"],r:["(+)","R"],s:["(+)","S"],t:["(+)","T"],u:["(+)","U"],v:["(+)","V"],w:["(+)","W"],x:["(+)","X"],y:["(+)","Y"],z:["(+)","Z"],"{":["(%)","P"],"|":["(%)","Q"],"}":["(%)","R"],"~":["(%)","S"],"":["(%)","T"]}}),N=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=D(),o=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return/^[0-9A-Z\-. $/+%]+$/.test(this.data)}},{key:"encode",value:function(){var t=this.data.split("").flatMap(function(t){return r.MULTI_SYMBOLS[t]||t}),n=t.map(function(t){return e.getEncoding(t)}).join(""),o=e.checksum(t,20),i=e.checksum(t.concat(o),15);return{text:this.text,data:e.getEncoding("ÿ")+n+e.getEncoding(o)+e.getEncoding(i)+e.getEncoding("ÿ")+"1"}}}],[{key:"getEncoding",value:function(t){return r.BINARIES[e.symbolValue(t)]}},{key:"getSymbol",value:function(t){return r.SYMBOLS[t]}},{key:"symbolValue",value:function(t){return r.SYMBOLS.indexOf(t)}},{key:"checksum",value:function(t,n){var r=t.slice().reverse().reduce(function(t,r,o){var i=o%n+1;return t+e.symbolValue(r)*i},0);return e.getSymbol(r%47)}}]),e}(((e=i())&&e.__esModule?e:{default:e}).default);t.default=o}),$=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"valid",value:function(){return/^[\x00-\x7f]+$/.test(this.data)}}]),e}(((e=N())&&e.__esModule?e:{default:e}).default);t.default=r}),X=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.CODE93FullASCII=t.CODE93=void 0;var e=r(N()),n=r($());function r(t){return t&&t.__esModule?t:{default:t}}t.CODE93=e.default,t.CODE93FullASCII=n.default}),H=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.GenericBarcode=void 0;var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=function(t){function e(t,n){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),n(e,[{key:"encode",value:function(){return{data:"10101010101010101010101010101010101010101",text:this.text}}},{key:"valid",value:function(){return!0}}]),e}(((e=i())&&e.__esModule?e:{default:e}).default);t.GenericBarcode=r}),z=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=a(),n=h(),r=j(),o=C(),i=I(),u=B(),f=G(),c=X(),l=H();t.default={CODE39:e.CODE39,CODE128:n.CODE128,CODE128A:n.CODE128A,CODE128B:n.CODE128B,CODE128C:n.CODE128C,EAN13:r.EAN13,EAN8:r.EAN8,EAN5:r.EAN5,EAN2:r.EAN2,UPC:r.UPC,UPCE:r.UPCE,ITF14:o.ITF14,ITF:o.ITF,MSI:i.MSI,MSI10:i.MSI10,MSI11:i.MSI11,MSI1010:i.MSI1010,MSI1110:i.MSI1110,pharmacode:u.pharmacode,codabar:f.codabar,CODE93:c.CODE93,CODE93FullASCII:c.CODE93FullASCII,GenericBarcode:l.GenericBarcode}}),V=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};t.default=function(t,n){return e({},t,n)}}),U=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(t){var e=[];return function t(n){if(Array.isArray(n))for(var r=0;r<n.length;r++)t(n[r]);else n.text=n.text||"",n.data=n.data||"",e.push(n)}(t),e}}),F=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(t){return t.marginTop=t.marginTop||t.margin,t.marginBottom=t.marginBottom||t.margin,t.marginRight=t.marginRight||t.margin,t.marginLeft=t.marginLeft||t.margin,t}}),W=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(t){var e=["width","height","textMargin","fontSize","margin","marginTop","marginBottom","marginLeft","marginRight"];for(var n in e)e.hasOwnProperty(n)&&"string"==typeof t[n=e[n]]&&(t[n]=parseInt(t[n],10));return"string"==typeof t.displayValue&&(t.displayValue="false"!=t.displayValue),t}}),Y=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.default={width:2,height:100,format:"auto",displayValue:!0,fontOptions:"",font:"monospace",text:void 0,textAlign:"center",textPosition:"bottom",textMargin:2,fontSize:20,background:"#ffffff",lineColor:"#000000",margin:10,marginTop:void 0,marginBottom:void 0,marginLeft:void 0,marginRight:void 0,valid:function(){}}}),J=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=r(W()),n=r(Y());function r(t){return t&&t.__esModule?t:{default:t}}t.default=function(t){var r={};for(var o in n.default)n.default.hasOwnProperty(o)&&(t.hasAttribute("jsbarcode-"+o.toLowerCase())&&(r[o]=t.getAttribute("jsbarcode-"+o.toLowerCase())),t.hasAttribute("data-"+o.toLowerCase())&&(r[o]=t.getAttribute("data-"+o.toLowerCase())));return r.value=t.getAttribute("jsbarcode-value")||t.getAttribute("data-value"),(0,e.default)(r)}}),Q=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0}),t.getTotalWidthOfEncodings=t.calculateEncodingAttributes=t.getBarcodePadding=t.getEncodingHeight=t.getMaximumHeightOfEncodings=void 0;var e,n=(e=V())&&e.__esModule?e:{default:e};function r(t,e){return e.height+(e.displayValue&&t.text.length>0?e.fontSize+e.textMargin:0)+e.marginTop+e.marginBottom}function o(t,e,n){if(n.displayValue&&e<t){if("center"==n.textAlign)return Math.floor((t-e)/2);if("left"==n.textAlign)return 0;if("right"==n.textAlign)return Math.floor(t-e)}return 0}function i(t,e,n){var r;if(n)r=n;else{if("undefined"==typeof document)return 0;r=document.createElement("canvas").getContext("2d")}r.font=e.fontOptions+" "+e.fontSize+"px "+e.font;var o=r.measureText(t);return o?o.width:0}t.getMaximumHeightOfEncodings=function(t){for(var e=0,n=0;n<t.length;n++)t[n].height>e&&(e=t[n].height);return e},t.getEncodingHeight=r,t.getBarcodePadding=o,t.calculateEncodingAttributes=function(t,e,a){for(var u=0;u<t.length;u++){var f,c=t[u],l=(0,n.default)(e,c.options);f=l.displayValue?i(c.text,l,a):0;var s=c.data.length*l.width;c.width=Math.ceil(Math.max(f,s)),c.height=r(c,l),c.barcodePadding=o(f,s,l)}},t.getTotalWidthOfEncodings=function(t){for(var e=0,n=0;n<t.length;n++)e+=t[n].width;return e}}),Z=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=(e=V())&&e.__esModule?e:{default:e},o=Q(),i=function(){function t(e,n,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.canvas=e,this.encodings=n,this.options=r}return n(t,[{key:"render",value:function(){if(!this.canvas.getContext)throw new Error("The browser does not support canvas.");this.prepareCanvas();for(var t=0;t<this.encodings.length;t++){var e=(0,r.default)(this.options,this.encodings[t].options);this.drawCanvasBarcode(e,this.encodings[t]),this.drawCanvasText(e,this.encodings[t]),this.moveCanvasDrawing(this.encodings[t])}this.restoreCanvas()}},{key:"prepareCanvas",value:function(){var t=this.canvas.getContext("2d");t.save(),(0,o.calculateEncodingAttributes)(this.encodings,this.options,t);var e=(0,o.getTotalWidthOfEncodings)(this.encodings),n=(0,o.getMaximumHeightOfEncodings)(this.encodings);this.canvas.width=e+this.options.marginLeft+this.options.marginRight,this.canvas.height=n,t.clearRect(0,0,this.canvas.width,this.canvas.height),this.options.background&&(t.fillStyle=this.options.background,t.fillRect(0,0,this.canvas.width,this.canvas.height)),t.translate(this.options.marginLeft,0)}},{key:"drawCanvasBarcode",value:function(t,e){var n,r=this.canvas.getContext("2d"),o=e.data;n="top"==t.textPosition?t.marginTop+t.fontSize+t.textMargin:t.marginTop,r.fillStyle=t.lineColor;for(var i=0;i<o.length;i++){var a=i*t.width+e.barcodePadding;"1"===o[i]?r.fillRect(a,n,t.width,t.height):o[i]&&r.fillRect(a,n,t.width,t.height*o[i])}}},{key:"drawCanvasText",value:function(t,e){var n,r,o=this.canvas.getContext("2d"),i=t.fontOptions+" "+t.fontSize+"px "+t.font;t.displayValue&&(r="top"==t.textPosition?t.marginTop+t.fontSize-t.textMargin:t.height+t.textMargin+t.marginTop+t.fontSize,o.font=i,"left"==t.textAlign||e.barcodePadding>0?(n=0,o.textAlign="left"):"right"==t.textAlign?(n=e.width-1,o.textAlign="right"):(n=e.width/2,o.textAlign="center"),o.fillText(e.text,n,r))}},{key:"moveCanvasDrawing",value:function(t){this.canvas.getContext("2d").translate(t.width,0)}},{key:"restoreCanvas",value:function(){this.canvas.getContext("2d").restore()}}]),t}();t.default=i}),K=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e,n=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),r=(e=V())&&e.__esModule?e:{default:e},o=Q(),i="http://www.w3.org/2000/svg",a=function(){function t(e,n,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.svg=e,this.encodings=n,this.options=r,this.document=r.xmlDocument||document}return n(t,[{key:"render",value:function(){var t=this.options.marginLeft;this.prepareSVG();for(var e=0;e<this.encodings.length;e++){var n=this.encodings[e],o=(0,r.default)(this.options,n.options),i=this.createGroup(t,o.marginTop,this.svg);this.setGroupOptions(i,o),this.drawSvgBarcode(i,o,n),this.drawSVGText(i,o,n),t+=n.width}}},{key:"prepareSVG",value:function(){for(;this.svg.firstChild;)this.svg.removeChild(this.svg.firstChild);(0,o.calculateEncodingAttributes)(this.encodings,this.options);var t=(0,o.getTotalWidthOfEncodings)(this.encodings),e=(0,o.getMaximumHeightOfEncodings)(this.encodings),n=t+this.options.marginLeft+this.options.marginRight;this.setSvgAttributes(n,e),this.options.background&&this.drawRect(0,0,n,e,this.svg).setAttribute("fill",this.options.background)}},{key:"drawSvgBarcode",value:function(t,e,n){var r,o=n.data;r="top"==e.textPosition?e.fontSize+e.textMargin:0;for(var i=0,a=0,u=0;u<o.length;u++)a=u*e.width+n.barcodePadding,"1"===o[u]?i++:i>0&&(this.drawRect(a-e.width*i,r,e.width*i,e.height,t),i=0);i>0&&this.drawRect(a-e.width*(i-1),r,e.width*i,e.height,t)}},{key:"drawSVGText",value:function(t,e,n){var r,o,a=this.document.createElementNS(i,"text");e.displayValue&&(a.setAttribute("font-family",e.font),a.setAttribute("font-size",e.fontSize),e.fontOptions.includes("bold")&&a.setAttribute("font-weight","bold"),e.fontOptions.includes("italic")&&a.setAttribute("font-style","italic"),o="top"==e.textPosition?e.fontSize-e.textMargin:e.height+e.textMargin+e.fontSize,"left"==e.textAlign||n.barcodePadding>0?(r=0,a.setAttribute("text-anchor","start")):"right"==e.textAlign?(r=n.width-1,a.setAttribute("text-anchor","end")):(r=n.width/2,a.setAttribute("text-anchor","middle")),a.setAttribute("x",r),a.setAttribute("y",o),a.appendChild(this.document.createTextNode(n.text)),t.appendChild(a))}},{key:"setSvgAttributes",value:function(t,e){var n=this.svg;n.setAttribute("width",t+"px"),n.setAttribute("height",e+"px"),n.setAttribute("x","0px"),n.setAttribute("y","0px"),n.setAttribute("viewBox","0 0 "+t+" "+e),n.setAttribute("xmlns",i),n.setAttribute("version","1.1")}},{key:"createGroup",value:function(t,e,n){var r=this.document.createElementNS(i,"g");return r.setAttribute("transform","translate("+t+", "+e+")"),n.appendChild(r),r}},{key:"setGroupOptions",value:function(t,e){t.setAttribute("fill",e.lineColor)}},{key:"drawRect",value:function(t,e,n,r,o){var a=this.document.createElementNS(i,"rect");return a.setAttribute("x",t),a.setAttribute("y",e),a.setAttribute("width",n),a.setAttribute("height",r),o.appendChild(a),a}}]),t}();t.default=a}),q=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),n=function(){function t(e,n,r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.object=e,this.encodings=n,this.options=r}return e(t,[{key:"render",value:function(){this.object.encodings=this.encodings}}]),t}();t.default=n}),tt=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=o(Z()),n=o(K()),r=o(q());function o(t){return t&&t.__esModule?t:{default:t}}t.default={CanvasRenderer:e.default,SVGRenderer:n.default,ObjectRenderer:r.default}}),et=/* @__PURE__ */e(t=>{function e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function n(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function r(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(t,"__esModule",{value:!0});var o=function(){function t(r,o){e(this,t);var i=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return i.name="InvalidInputException",i.symbology=r,i.input=o,i.message='"'+i.input+'" is not a valid input for '+i.symbology,i}return r(t,Error),t}(),i=function(){function t(){e(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.name="InvalidElementException",r.message="Not supported type to render on",r}return r(t,Error),t}(),a=function(){function t(){e(this,t);var r=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.name="NoElementException",r.message="No element to render on.",r}return r(t,Error),t}();t.InvalidInputException=o,t.InvalidElementException=i,t.NoElementException=a}),nt=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n=i(J()),r=i(tt()),o=et();function i(t){return t&&t.__esModule?t:{default:t}}t.default=function t(i){if("string"==typeof i)return function(e){var n=document.querySelectorAll(e);if(0!==n.length){for(var r=[],o=0;o<n.length;o++)r.push(t(n[o]));return r}}(i);if(Array.isArray(i)){for(var a=[],u=0;u<i.length;u++)a.push(t(i[u]));return a}if("undefined"!=typeof HTMLCanvasElement&&i instanceof HTMLImageElement)return f=i,{element:c=document.createElement("canvas"),options:(0,n.default)(f),renderer:r.default.CanvasRenderer,afterRender:function(){f.setAttribute("src",c.toDataURL())}};if(i&&i.nodeName&&"svg"===i.nodeName.toLowerCase()||"undefined"!=typeof SVGElement&&i instanceof SVGElement)return{element:i,options:(0,n.default)(i),renderer:r.default.SVGRenderer};if("undefined"!=typeof HTMLCanvasElement&&i instanceof HTMLCanvasElement)return{element:i,options:(0,n.default)(i),renderer:r.default.CanvasRenderer};if(i&&i.getContext)return{element:i,renderer:r.default.CanvasRenderer};if(i&&"object"===(void 0===i?"undefined":e(i))&&!i.nodeName)return{element:i,renderer:r.default.ObjectRenderer};throw new o.InvalidElementException;var f,c}}),rt=/* @__PURE__ */e(t=>{Object.defineProperty(t,"__esModule",{value:!0});var e=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),n=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.api=e}return e(t,[{key:"handleCatch",value:function(t){if("InvalidInputException"!==t.name)throw t;if(this.api._options.valid===this.api._defaults.valid)throw t.message;this.api._options.valid(!1),this.api.render=function(){}}},{key:"wrapBarcodeCall",value:function(t){try{var e=t.apply(void 0,arguments);return this.api._options.valid(!0),e}catch(n){return this.handleCatch(n),this.api}}}]),t}();t.default=n}),ot=/* @__PURE__ */e((t,e)=>{var n=s(z()),r=s(V()),o=s(U()),i=s(F()),a=s(nt()),u=s(W()),f=s(rt()),c=et(),l=s(Y());function s(t){return t&&t.__esModule?t:{default:t}}var p=function(){},d=function(t,e,n){var r=new p;if(void 0===t)throw Error("No element to render on was provided.");return r._renderProperties=(0,a.default)(t),r._encodings=[],r._options=l.default,r._errorHandler=new f.default(r),void 0!==e&&((n=n||{}).format||(n.format=v()),r.options(n)[n.format](e,n).render()),r};for(var h in d.getModule=function(t){return n.default[t]},n.default)n.default.hasOwnProperty(h)&&y(n.default,h);function y(t,e){p.prototype[e]=p.prototype[e.toUpperCase()]=p.prototype[e.toLowerCase()]=function(n,o){var i=this;return i._errorHandler.wrapBarcodeCall(function(){o.text=void 0===o.text?void 0:""+o.text;var a=(0,r.default)(i._options,o);a=(0,u.default)(a);var f=t[e],c=b(n,f,a);return i._encodings.push(c),i})}}function b(t,e,n){var i=new e(t=""+t,n);if(!i.valid())throw new c.InvalidInputException(i.constructor.name,t);var a=i.encode();a=(0,o.default)(a);for(var u=0;u<a.length;u++)a[u].options=(0,r.default)(n,a[u].options);return a}function v(){return n.default.CODE128?"CODE128":Object.keys(n.default)[0]}function _(t,e,n){e=(0,o.default)(e);for(var a=0;a<e.length;a++)e[a].options=(0,r.default)(n,e[a].options),(0,i.default)(e[a].options);(0,i.default)(n),new(0,t.renderer)(t.element,e,n).render(),t.afterRender&&t.afterRender()}p.prototype.options=function(t){return this._options=(0,r.default)(this._options,t),this},p.prototype.blank=function(t){var e=new Array(t+1).join("0");return this._encodings.push({data:e}),this},p.prototype.init=function(){var t;if(this._renderProperties)for(var e in Array.isArray(this._renderProperties)||(this._renderProperties=[this._renderProperties]),this._renderProperties){t=this._renderProperties[e];var o=(0,r.default)(this._options,t.options);"auto"==o.format&&(o.format=v()),this._errorHandler.wrapBarcodeCall(function(){var e=b(o.value,n.default[o.format.toUpperCase()],o);_(t,e,o)})}},p.prototype.render=function(){if(!this._renderProperties)throw new c.NoElementException;if(Array.isArray(this._renderProperties))for(var t=0;t<this._renderProperties.length;t++)_(this._renderProperties[t],this._encodings,this._options);else _(this._renderProperties,this._encodings,this._options);return this},p.prototype._defaults=l.default,"undefined"!=typeof window&&(window.JsBarcode=d),"undefined"!=typeof jQuery&&(jQuery.fn.JsBarcode=function(t,e){var n=[];return jQuery(this).each(function(){n.push(this)}),d(n,t,e)}),e.exports=d}),it=/* @__PURE__ */t(n()),at=/* @__PURE__ */t(ot()),ut=function(t){function e(e){var n=t.call(this,e)||this;return n.dom=it.createRef(),n}return r(e,t),e.prototype.componentDidUpdate=function(t){this.props.value===t.value&&JSON.stringify(this.props.options)===JSON.stringify(t.options)||this.renderBarCode()},e.prototype.renderBarCode=function(){this.dom.current&&(0,at.default)(this.dom.current,this.props.value,this.props.options)},e.prototype.componentDidMount=function(){this.renderBarCode()},e.prototype.render=function(){return it.createElement("img",{ref:this.dom})},e}(it.Component),ft=o(ut);export{ut as BarCode,ft as default};
@@ -1 +1 @@
1
- import{o as r}from"./rolldown-runtime-DcYi-9oA.js";import{t}from"./react-BW4ssgUo.js";import{c as e,i as o,r as n,t as a}from"./tslib.es6-C2q27PUR.js";import{Ii as s,Xr as i,it as l}from"./esm-BMvKJM5q.js";import{Pt as p}from"./esm-BbZME5Ac.js";var m=/* @__PURE__ */r(t()),u=function(r){function t(){return null!==r&&r.apply(this,arguments)||this}return o(t,r),t.prototype.render=function(){var r=this.props,t=r.items,o=r.source,n=r.data,l=r.env,u=e(r,["items","source","data","env"]),f=t||s(o,n,"| raw");return f&&(f=f.map(function(r){return r.label&&(r.label=i(r.label,n)),r.href&&(r.href=s(r.href,n,"| raw")),r.dropdown&&(r.dropdown=r.dropdown.map(function(r){return r.label&&(r.label=i(r.label,n)),r.href&&(r.href=s(r.href,n,"| raw")),r})),r})),m.createElement(p,a({items:f,tooltipContainer:null==l?void 0:l.getModalContainer},u))},t}(m.Component),f=function(r){function t(){return null!==r&&r.apply(this,arguments)||this}return o(t,r),n([l({type:"breadcrumb"})],t)}(u);export{u as BreadcrumbField,f as BreadcrumbFieldRenderer};
1
+ import{o as r}from"./rolldown-runtime-Ch1CtRr1.js";import{t}from"./react-1dn4ot9O.js";import{c as e,i as o,r as n,t as a}from"./tslib.es6-C2q27PUR.js";import{Ii as s,Xr as i,it as l}from"./esm-HJl7vXYN.js";import{Pt as p}from"./esm-BmJ_y26h.js";var m=/* @__PURE__ */r(t()),u=function(r){function t(){return null!==r&&r.apply(this,arguments)||this}return o(t,r),t.prototype.render=function(){var r=this.props,t=r.items,o=r.source,n=r.data,l=r.env,u=e(r,["items","source","data","env"]),f=t||s(o,n,"| raw");return f&&(f=f.map(function(r){return r.label&&(r.label=i(r.label,n)),r.href&&(r.href=s(r.href,n,"| raw")),r.dropdown&&(r.dropdown=r.dropdown.map(function(r){return r.label&&(r.label=i(r.label,n)),r.href&&(r.href=s(r.href,n,"| raw")),r})),r})),m.createElement(p,a({items:f,tooltipContainer:null==l?void 0:l.getModalContainer},u))},t}(m.Component),f=function(r){function t(){return null!==r&&r.apply(this,arguments)||this}return o(t,r),n([l({type:"breadcrumb"})],t)}(u);export{u as BreadcrumbField,f as BreadcrumbFieldRenderer};
@@ -0,0 +1 @@
1
+ import{i as t,r}from"./tslib.es6-C2q27PUR.js";import{it as s}from"./esm-HJl7vXYN.js";import{t as o}from"./ButtonGroupSelect-DjOQ2Tuh.js";var i=function(o){function i(){return null!==o&&o.apply(this,arguments)||this}return t(i,o),r([s({type:"button-group"})],i)}(o);export{i as ButtonGroupRenderer,o as default};
@@ -0,0 +1 @@
1
+ import{o as e,r as t}from"./rolldown-runtime-Ch1CtRr1.js";import{t as n}from"./react-1dn4ot9O.js";import{i as o,o as a,r as l,t as r}from"./tslib.es6-C2q27PUR.js";import{Nn as i,P as s,Qn as u,ui as p,vi as d}from"./esm-HJl7vXYN.js";import{t as c}from"./StaticHoc-BFjSxS01.js";var v=/* @__PURE__ */t({ButtonGroupControlRenderer:()=>m,default:()=>b}),g=/* @__PURE__ */e(n()),b=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.doAction=function(e,t,n){var o,a,l=this.props,r=l.resetValue,i=l.onChange,s=l.formStore,u=l.store,p=l.name,c=null==e?void 0:e.actionType;if("clear"===c)i("");else if("reset"===c){var v=null!==(a=d(null!==(o=null==s?void 0:s.pristine)&&void 0!==o?o:null==u?void 0:u.pristine,p))&&void 0!==a?a:r;i(null!=v?v:"")}},t.prototype.handleToggle=function(e){var t=this.props,n=t.onToggle;t.multiple,t.autoFill,t.onBulkChange,n(e)},t.prototype.reload=function(e,t){var n=this.props.reloadOptions;n&&n(e,t)},t.prototype.getBadgeConfig=function(e,t){return e?!(null==t?void 0:t.badge)||"string"!=typeof t.badge&&"number"!=typeof t.badge?(null==t?void 0:t.badge)&&p(t.badge)?r(r({},e),t.badge):null:r(r({},e),{text:t.badge}):t.badge},t.prototype.render=function(e){var t,n=this;void 0===e&&(e=this.props);var o=e.render,a=e.classPrefix,l=e.classnames,i=e.className;e.style;var s=e.disabled,p=e.options;e.value;var d=e.labelField,c=e.placeholder,v=e.btnClassName,b=e.btnActiveClassName,m=e.selectedOptions,f=e.buttons,y=e.size,h=e.block,B=e.vertical,C=e.tiled,N=e.badge,k=e.testIdBuilder,G=e.translate,j=[],A=e.btnLevel,z=e.btnActiveLevel;return v&&(A=u(v)),b&&(z=u(b)),p&&p.length?j=p.map(function(e,t){var a=!!~m.indexOf(e),r=n.getBadgeConfig(N,e);return o("option/".concat(t),{label:e[d||"label"],icon:e.icon,size:e.size||y,badge:r,type:"button",block:h},{key:t,level:(a?z:"")||e.level||A,className:l(e.className,v,a&&"ButtonGroup-button--active"),disabled:e.disabled||s,testIdBuilder:null==k?void 0:k.getChild("item-".concat(e[d||"label"]||t)),onClick:function(t){s||(n.handleToggle(e),t.preventDefault())}})}):Array.isArray(f)&&(j=f.map(function(e,t){var a=n.getBadgeConfig(N,e);return o("button/".concat(t),r(r({size:y,block:h,activeLevel:z,level:A,disabled:s},e),{badge:a}),{key:t,className:l(e.className,v)})})),g.createElement("div",{className:l("ButtonGroup",(t={"ButtonGroup--block":h,"ButtonGroup--vertical":B,"ButtonGroup--tiled":C},t["ButtonGroup--".concat(y)]=y,t),i)},j.length?j:g.createElement("span",{className:"".concat(a,"ButtonGroup-placeholder")},G(c)))},t.defaultProps={btnLevel:"default",btnActiveLevel:"primary",clearable:!1,vertical:!1},l([i,a("design:type",Function),a("design:paramtypes",[Object]),a("design:returntype",void 0)],t.prototype,"handleToggle",null),l([c(),a("design:type",Function),a("design:paramtypes",[Object]),a("design:returntype",void 0)],t.prototype,"render",null),t}(g.Component),m=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),l([s({type:"button-group-select",sizeMutable:!1,strictMode:!1})],t)}(b);export{m as n,v as r,b as t};
@@ -1 +1 @@
1
- import{o as t}from"./rolldown-runtime-DcYi-9oA.js";import{t as r}from"./react-BW4ssgUo.js";import{i as n,r as s}from"./tslib.es6-C2q27PUR.js";import{F as o}from"./esm-BMvKJM5q.js";var e=/* @__PURE__ */t(r()),a=function(t){function r(){return null!==t&&t.apply(this,arguments)||this}return n(r,t),r.prototype.renderButtons=function(){var t=this.props,r=t.render;t.classPrefix;var n=t.buttons;return Array.isArray(n)?n.map(function(t,n){return r("button/".concat(n),t,{key:n})}):null},r.prototype.render=function(){var t=this.props;t.buttons;var r=t.className,n=t.classnames;return t.render,t.style,e.createElement("div",{className:n("ButtonToolbar",r)},this.renderButtons())},r.propsList=["buttons","className"],r}(e.Component),u=function(t){function r(){return null!==t&&t.apply(this,arguments)||this}return n(r,t),s([o({type:"button-toolbar",strictMode:!1})],r)}(a);export{u as ButtonToolbarRenderer,a as default};
1
+ import{o as t}from"./rolldown-runtime-Ch1CtRr1.js";import{t as r}from"./react-1dn4ot9O.js";import{i as n,r as s}from"./tslib.es6-C2q27PUR.js";import{F as o}from"./esm-HJl7vXYN.js";var e=/* @__PURE__ */t(r()),a=function(t){function r(){return null!==t&&t.apply(this,arguments)||this}return n(r,t),r.prototype.renderButtons=function(){var t=this.props,r=t.render;t.classPrefix;var n=t.buttons;return Array.isArray(n)?n.map(function(t,n){return r("button/".concat(n),t,{key:n})}):null},r.prototype.render=function(){var t=this.props;t.buttons;var r=t.className,n=t.classnames;return t.render,t.style,e.createElement("div",{className:n("ButtonToolbar",r)},this.renderButtons())},r.propsList=["buttons","className"],r}(e.Component),u=function(t){function r(){return null!==t&&t.apply(this,arguments)||this}return n(r,t),s([o({type:"button-toolbar",strictMode:!1})],r)}(a);export{u as ButtonToolbarRenderer,a as default};