siam-ui-utils 3.0.31 → 3.0.32

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 (170) hide show
  1. package/dist/CustomBootstrap.js +9 -0
  2. package/dist/CustomBootstrap.js.map +1 -0
  3. package/dist/_virtual/_commonjsHelpers.js +7 -0
  4. package/dist/_virtual/_commonjsHelpers.js.map +1 -0
  5. package/dist/_virtual/events.js +6 -0
  6. package/dist/_virtual/events.js.map +1 -0
  7. package/dist/_virtual/events2.js +5 -0
  8. package/dist/_virtual/events2.js.map +1 -0
  9. package/dist/_virtual/index.js +8 -0
  10. package/dist/_virtual/index.js.map +1 -0
  11. package/dist/_virtual/index2.js +5 -0
  12. package/dist/_virtual/index2.js.map +1 -0
  13. package/dist/_virtual/react-dropzone.js +8 -0
  14. package/dist/_virtual/react-dropzone.js.map +1 -0
  15. package/dist/_virtual/react-dropzone2.js +5 -0
  16. package/dist/_virtual/react-dropzone2.js.map +1 -0
  17. package/dist/assets/img/copiar.png.js +5 -0
  18. package/dist/assets/img/copiar.png.js.map +1 -0
  19. package/dist/assets/img/take-photo.jpg.js +5 -0
  20. package/dist/assets/img/take-photo.jpg.js.map +1 -0
  21. package/dist/constants.js +9 -0
  22. package/dist/constants.js.map +1 -0
  23. package/dist/copy-link/index.js +60 -0
  24. package/dist/copy-link/index.js.map +1 -0
  25. package/dist/copy-link/styles.css +38 -0
  26. package/dist/custom-input/CustomInputCheckbox.js +35 -0
  27. package/dist/custom-input/CustomInputCheckbox.js.map +1 -0
  28. package/dist/custom-input/CustomInputCurrency.js +84 -0
  29. package/dist/custom-input/CustomInputCurrency.js.map +1 -0
  30. package/dist/custom-input/CustomInputFile.js +45 -0
  31. package/dist/custom-input/CustomInputFile.js.map +1 -0
  32. package/dist/custom-input/CustomInputRadio.js +66 -0
  33. package/dist/custom-input/CustomInputRadio.js.map +1 -0
  34. package/dist/custom-input/constant.js +5 -0
  35. package/dist/custom-input/constant.js.map +1 -0
  36. package/dist/custom-input/index.css +167 -0
  37. package/dist/custom-input/index.js +12 -0
  38. package/dist/custom-input/index.js.map +1 -0
  39. package/dist/drag-and-dropzone/config.js +59 -0
  40. package/dist/drag-and-dropzone/config.js.map +1 -0
  41. package/dist/drag-and-dropzone/index.css +276 -0
  42. package/dist/drag-and-dropzone/index.js +39 -0
  43. package/dist/drag-and-dropzone/index.js.map +1 -0
  44. package/dist/dropzone/Input.js +77 -0
  45. package/dist/dropzone/Input.js.map +1 -0
  46. package/dist/dropzone/Layout.js +50 -0
  47. package/dist/dropzone/Layout.js.map +1 -0
  48. package/dist/dropzone/Preview.js +117 -0
  49. package/dist/dropzone/Preview.js.map +1 -0
  50. package/dist/dropzone/SubmitButton.js +34 -0
  51. package/dist/dropzone/SubmitButton.js.map +1 -0
  52. package/dist/dropzone/assets/cancel.svg.js +5 -0
  53. package/dist/dropzone/assets/cancel.svg.js.map +1 -0
  54. package/dist/dropzone/assets/remove.svg.js +5 -0
  55. package/dist/dropzone/assets/remove.svg.js.map +1 -0
  56. package/dist/dropzone/assets/restart.svg.js +5 -0
  57. package/dist/dropzone/assets/restart.svg.js.map +1 -0
  58. package/dist/dropzone/index.js +514 -0
  59. package/dist/dropzone/index.js.map +1 -0
  60. package/dist/dropzone/utils.js +93 -0
  61. package/dist/dropzone/utils.js.map +1 -0
  62. package/dist/dropzone-uploader/base/index.css +207 -0
  63. package/dist/dropzone-uploader/base/index.js +135 -0
  64. package/dist/dropzone-uploader/base/index.js.map +1 -0
  65. package/dist/dropzone-uploader/index.js +7 -0
  66. package/dist/dropzone-uploader/index.js.map +1 -0
  67. package/dist/dropzone-uploader/styled/index.css +348 -0
  68. package/dist/dropzone-uploader/styled/index.js +148 -0
  69. package/dist/dropzone-uploader/styled/index.js.map +1 -0
  70. package/dist/iconos/constants-svg.js +666 -0
  71. package/dist/iconos/constants-svg.js.map +1 -0
  72. package/dist/iconos/icon-button-svg.js +50 -0
  73. package/dist/iconos/icon-button-svg.js.map +1 -0
  74. package/dist/iconos/index.js +24 -0
  75. package/dist/iconos/index.js.map +1 -0
  76. package/dist/iconos/styled-icon.js +26 -0
  77. package/dist/iconos/styled-icon.js.map +1 -0
  78. package/dist/index.js +4 -0
  79. package/dist/index.js.map +1 -0
  80. package/dist/intl-messages/index.js +11 -0
  81. package/dist/intl-messages/index.js.map +1 -0
  82. package/dist/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js +8 -0
  83. package/dist/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js.map +1 -0
  84. package/dist/node_modules/@babel/runtime/helpers/esm/extends.js +13 -0
  85. package/dist/node_modules/@babel/runtime/helpers/esm/extends.js.map +1 -0
  86. package/dist/node_modules/@babel/runtime/helpers/esm/inheritsLoose.js +8 -0
  87. package/dist/node_modules/@babel/runtime/helpers/esm/inheritsLoose.js.map +1 -0
  88. package/dist/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js +13 -0
  89. package/dist/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js.map +1 -0
  90. package/dist/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js +9 -0
  91. package/dist/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js.map +1 -0
  92. package/dist/node_modules/classnames/index.js +62 -0
  93. package/dist/node_modules/classnames/index.js.map +1 -0
  94. package/dist/node_modules/dom-helpers/esm/addClass.js +10 -0
  95. package/dist/node_modules/dom-helpers/esm/addClass.js.map +1 -0
  96. package/dist/node_modules/dom-helpers/esm/hasClass.js +8 -0
  97. package/dist/node_modules/dom-helpers/esm/hasClass.js.map +1 -0
  98. package/dist/node_modules/dom-helpers/esm/removeClass.js +16 -0
  99. package/dist/node_modules/dom-helpers/esm/removeClass.js.map +1 -0
  100. package/dist/node_modules/events/events.js +372 -0
  101. package/dist/node_modules/events/events.js.map +1 -0
  102. package/dist/node_modules/react-dropzone-component/dist/react-dropzone.js +1023 -0
  103. package/dist/node_modules/react-dropzone-component/dist/react-dropzone.js.map +1 -0
  104. package/dist/node_modules/react-multi-select-component/dist/esm/index.js +178 -0
  105. package/dist/node_modules/react-multi-select-component/dist/esm/index.js.map +1 -0
  106. package/dist/node_modules/react-transition-group/esm/CSSTransition.js +275 -0
  107. package/dist/node_modules/react-transition-group/esm/CSSTransition.js.map +1 -0
  108. package/dist/node_modules/react-transition-group/esm/Transition.js +441 -0
  109. package/dist/node_modules/react-transition-group/esm/Transition.js.map +1 -0
  110. package/dist/node_modules/react-transition-group/esm/TransitionGroup.js +146 -0
  111. package/dist/node_modules/react-transition-group/esm/TransitionGroup.js.map +1 -0
  112. package/dist/node_modules/react-transition-group/esm/TransitionGroupContext.js +6 -0
  113. package/dist/node_modules/react-transition-group/esm/TransitionGroupContext.js.map +1 -0
  114. package/dist/node_modules/react-transition-group/esm/config.js +7 -0
  115. package/dist/node_modules/react-transition-group/esm/config.js.map +1 -0
  116. package/dist/node_modules/react-transition-group/esm/utils/ChildMapping.js +100 -0
  117. package/dist/node_modules/react-transition-group/esm/utils/ChildMapping.js.map +1 -0
  118. package/dist/node_modules/react-transition-group/esm/utils/PropTypes.js +24 -0
  119. package/dist/node_modules/react-transition-group/esm/utils/PropTypes.js.map +1 -0
  120. package/dist/node_modules/react-transition-group/esm/utils/reflow.js +7 -0
  121. package/dist/node_modules/react-transition-group/esm/utils/reflow.js.map +1 -0
  122. package/dist/react-notifications/Notification.js +73 -0
  123. package/dist/react-notifications/Notification.js.map +1 -0
  124. package/dist/react-notifications/NotificationContainer.js +59 -0
  125. package/dist/react-notifications/NotificationContainer.js.map +1 -0
  126. package/dist/react-notifications/NotificationManager.js +174 -0
  127. package/dist/react-notifications/NotificationManager.js.map +1 -0
  128. package/dist/react-notifications/Notifications.js +72 -0
  129. package/dist/react-notifications/Notifications.js.map +1 -0
  130. package/dist/react-notifications/constants.js +26 -0
  131. package/dist/react-notifications/constants.js.map +1 -0
  132. package/dist/react-notifications/index.js +11 -0
  133. package/dist/react-notifications/index.js.map +1 -0
  134. package/dist/react-notifications/notifications.css +213 -0
  135. package/dist/select/custom-select/constants.js +8 -0
  136. package/dist/select/custom-select/constants.js.map +1 -0
  137. package/dist/select/custom-select/index.js +90 -0
  138. package/dist/select/custom-select/index.js.map +1 -0
  139. package/dist/select/custom-select-input/index.js +12 -0
  140. package/dist/select/custom-select-input/index.js.map +1 -0
  141. package/dist/select/index.js +9 -0
  142. package/dist/select/index.js.map +1 -0
  143. package/dist/select/multi-select/badge-label-multi-select.js +29 -0
  144. package/dist/select/multi-select/badge-label-multi-select.js.map +1 -0
  145. package/dist/select/multi-select/index.css +24 -0
  146. package/dist/select/multi-select/index.js +62 -0
  147. package/dist/select/multi-select/index.js.map +1 -0
  148. package/dist/select/multi-select/styled-component.js +24 -0
  149. package/dist/select/multi-select/styled-component.js.map +1 -0
  150. package/dist/timer/index.js +60 -0
  151. package/dist/timer/index.js.map +1 -0
  152. package/dist/timer/styles.css +59 -0
  153. package/dist/tomar-foto/index.js +62 -0
  154. package/dist/tomar-foto/index.js.map +1 -0
  155. package/dist/view-layout/button-editor.js +14 -0
  156. package/dist/view-layout/button-editor.js.map +1 -0
  157. package/dist/view-layout/constants.js +11 -0
  158. package/dist/view-layout/constants.js.map +1 -0
  159. package/dist/view-layout/editor-layer.js +28 -0
  160. package/dist/view-layout/editor-layer.js.map +1 -0
  161. package/dist/view-layout/index.js +53 -0
  162. package/dist/view-layout/index.js.map +1 -0
  163. package/dist/view-layout/slot-wrapper.js +39 -0
  164. package/dist/view-layout/slot-wrapper.js.map +1 -0
  165. package/dist/view-layout/styles.css +127 -0
  166. package/dist/where-by-room/index.js +20 -0
  167. package/dist/where-by-room/index.js.map +1 -0
  168. package/dist/where-by-room/room.js +78 -0
  169. package/dist/where-by-room/room.js.map +1 -0
  170. package/package.json +1 -1
@@ -0,0 +1,77 @@
1
+ import { jsxs, jsx } from "react/jsx-runtime";
2
+ import PropTypes from "prop-types";
3
+ const Input = (props) => {
4
+ const {
5
+ className,
6
+ labelClassName,
7
+ labelWithFilesClassName,
8
+ style,
9
+ labelStyle,
10
+ labelWithFilesStyle,
11
+ getFilesFromEvent,
12
+ accept,
13
+ multiple,
14
+ disabled,
15
+ content,
16
+ withFilesContent,
17
+ onFiles,
18
+ files
19
+ } = props;
20
+ return /* @__PURE__ */ jsxs(
21
+ "label",
22
+ {
23
+ className: files.length > 0 ? labelWithFilesClassName : labelClassName,
24
+ style: files.length > 0 ? labelWithFilesStyle : labelStyle,
25
+ children: [
26
+ files.length > 0 ? withFilesContent : content,
27
+ /* @__PURE__ */ jsx(
28
+ "input",
29
+ {
30
+ className,
31
+ style,
32
+ type: "file",
33
+ accept,
34
+ multiple,
35
+ disabled,
36
+ onChange: async (e) => {
37
+ const target = e.target;
38
+ const chosenFiles = await getFilesFromEvent(e);
39
+ onFiles(chosenFiles);
40
+ target.value = null;
41
+ }
42
+ }
43
+ )
44
+ ]
45
+ }
46
+ );
47
+ };
48
+ Input.propTypes = {
49
+ className: PropTypes.string,
50
+ labelClassName: PropTypes.string,
51
+ labelWithFilesClassName: PropTypes.string,
52
+ style: PropTypes.object,
53
+ labelStyle: PropTypes.object,
54
+ labelWithFilesStyle: PropTypes.object,
55
+ getFilesFromEvent: PropTypes.func.isRequired,
56
+ accept: PropTypes.string.isRequired,
57
+ multiple: PropTypes.bool.isRequired,
58
+ disabled: PropTypes.bool.isRequired,
59
+ content: PropTypes.node,
60
+ withFilesContent: PropTypes.node,
61
+ onFiles: PropTypes.func.isRequired,
62
+ files: PropTypes.arrayOf(PropTypes.any).isRequired,
63
+ extra: PropTypes.shape({
64
+ active: PropTypes.bool.isRequired,
65
+ reject: PropTypes.bool.isRequired,
66
+ dragged: PropTypes.arrayOf(PropTypes.any).isRequired,
67
+ accept: PropTypes.string.isRequired,
68
+ multiple: PropTypes.bool.isRequired,
69
+ minSizeBytes: PropTypes.number.isRequired,
70
+ maxSizeBytes: PropTypes.number.isRequired,
71
+ maxFiles: PropTypes.number.isRequired
72
+ }).isRequired
73
+ };
74
+ export {
75
+ Input as default
76
+ };
77
+ //# sourceMappingURL=Input.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Input.js","sources":["../../src/dropzone/Input.tsx"],"sourcesContent":["import React from 'react'\r\nimport PropTypes from 'prop-types'\r\n\r\nimport { IInputProps } from '.'\r\n\r\nconst Input = (props: IInputProps) => {\r\n const {\r\n className,\r\n labelClassName,\r\n labelWithFilesClassName,\r\n style,\r\n labelStyle,\r\n labelWithFilesStyle,\r\n getFilesFromEvent,\r\n accept,\r\n multiple,\r\n disabled,\r\n content,\r\n withFilesContent,\r\n onFiles,\r\n files,\r\n } = props\r\n\r\n return (\r\n <label\r\n className={files.length > 0 ? labelWithFilesClassName : labelClassName}\r\n style={files.length > 0 ? labelWithFilesStyle : labelStyle}\r\n >\r\n {files.length > 0 ? withFilesContent : content}\r\n <input\r\n className={className}\r\n style={style}\r\n type=\"file\"\r\n accept={accept}\r\n multiple={multiple}\r\n disabled={disabled}\r\n onChange={async e => {\r\n const target = e.target\r\n const chosenFiles = await getFilesFromEvent(e)\r\n onFiles(chosenFiles)\r\n //@ts-ignore\r\n target.value = null\r\n }}\r\n />\r\n </label>\r\n )\r\n}\r\n\r\nInput.propTypes = {\r\n className: PropTypes.string,\r\n labelClassName: PropTypes.string,\r\n labelWithFilesClassName: PropTypes.string,\r\n style: PropTypes.object,\r\n labelStyle: PropTypes.object,\r\n labelWithFilesStyle: PropTypes.object,\r\n getFilesFromEvent: PropTypes.func.isRequired,\r\n accept: PropTypes.string.isRequired,\r\n multiple: PropTypes.bool.isRequired,\r\n disabled: PropTypes.bool.isRequired,\r\n content: PropTypes.node,\r\n withFilesContent: PropTypes.node,\r\n onFiles: PropTypes.func.isRequired,\r\n files: PropTypes.arrayOf(PropTypes.any).isRequired,\r\n extra: PropTypes.shape({\r\n active: PropTypes.bool.isRequired,\r\n reject: PropTypes.bool.isRequired,\r\n dragged: PropTypes.arrayOf(PropTypes.any).isRequired,\r\n accept: PropTypes.string.isRequired,\r\n multiple: PropTypes.bool.isRequired,\r\n minSizeBytes: PropTypes.number.isRequired,\r\n maxSizeBytes: PropTypes.number.isRequired,\r\n maxFiles: PropTypes.number.isRequired,\r\n }).isRequired,\r\n}\r\n\r\nexport default Input\r\n"],"names":[],"mappings":";;AAKA,MAAM,QAAQ,CAAC,UAAuB;AACpC,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EAAA,IACE;AAEJ,SACE;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAW,MAAM,SAAS,IAAI,0BAA0B;AAAA,MACxD,OAAO,MAAM,SAAS,IAAI,sBAAsB;AAAA,MAE/C,UAAA;AAAA,QAAA,MAAM,SAAS,IAAI,mBAAmB;AAAA,QACvC;AAAA,UAAC;AAAA,UAAA;AAAA,YACC;AAAA,YACA;AAAA,YACA,MAAK;AAAA,YACL;AAAA,YACA;AAAA,YACA;AAAA,YACA,UAAU,OAAM,MAAK;AACnB,oBAAM,SAAS,EAAE;AACjB,oBAAM,cAAc,MAAM,kBAAkB,CAAC;AAC7C,sBAAQ,WAAW;AAEnB,qBAAO,QAAQ;AAAA,YACjB;AAAA,UAAA;AAAA,QAAA;AAAA,MACF;AAAA,IAAA;AAAA,EAAA;AAGN;AAEA,MAAM,YAAY;AAAA,EAChB,WAAW,UAAU;AAAA,EACrB,gBAAgB,UAAU;AAAA,EAC1B,yBAAyB,UAAU;AAAA,EACnC,OAAO,UAAU;AAAA,EACjB,YAAY,UAAU;AAAA,EACtB,qBAAqB,UAAU;AAAA,EAC/B,mBAAmB,UAAU,KAAK;AAAA,EAClC,QAAQ,UAAU,OAAO;AAAA,EACzB,UAAU,UAAU,KAAK;AAAA,EACzB,UAAU,UAAU,KAAK;AAAA,EACzB,SAAS,UAAU;AAAA,EACnB,kBAAkB,UAAU;AAAA,EAC5B,SAAS,UAAU,KAAK;AAAA,EACxB,OAAO,UAAU,QAAQ,UAAU,GAAG,EAAE;AAAA,EACxC,OAAO,UAAU,MAAM;AAAA,IACrB,QAAQ,UAAU,KAAK;AAAA,IACvB,QAAQ,UAAU,KAAK;AAAA,IACvB,SAAS,UAAU,QAAQ,UAAU,GAAG,EAAE;AAAA,IAC1C,QAAQ,UAAU,OAAO;AAAA,IACzB,UAAU,UAAU,KAAK;AAAA,IACzB,cAAc,UAAU,OAAO;AAAA,IAC/B,cAAc,UAAU,OAAO;AAAA,IAC/B,UAAU,UAAU,OAAO;AAAA,EAAA,CAC5B,EAAE;AACL;"}
@@ -0,0 +1,50 @@
1
+ import { jsxs } from "react/jsx-runtime";
2
+ import PropTypes from "prop-types";
3
+ const Layout = (props) => {
4
+ const {
5
+ input,
6
+ previews,
7
+ submitButton,
8
+ dropzoneProps,
9
+ files,
10
+ extra: { maxFiles }
11
+ } = props;
12
+ return /* @__PURE__ */ jsxs("div", { ...dropzoneProps, children: [
13
+ previews,
14
+ files.length < maxFiles && input,
15
+ files.length > 0 && submitButton
16
+ ] });
17
+ };
18
+ Layout.propTypes = {
19
+ input: PropTypes.node,
20
+ previews: PropTypes.arrayOf(PropTypes.node),
21
+ submitButton: PropTypes.node,
22
+ dropzoneProps: PropTypes.shape({
23
+ ref: PropTypes.any.isRequired,
24
+ className: PropTypes.string.isRequired,
25
+ style: PropTypes.object,
26
+ onDragEnter: PropTypes.func.isRequired,
27
+ onDragOver: PropTypes.func.isRequired,
28
+ onDragLeave: PropTypes.func.isRequired,
29
+ onDrop: PropTypes.func.isRequired
30
+ }).isRequired,
31
+ files: PropTypes.arrayOf(PropTypes.any).isRequired,
32
+ extra: PropTypes.shape({
33
+ active: PropTypes.bool.isRequired,
34
+ reject: PropTypes.bool.isRequired,
35
+ dragged: PropTypes.arrayOf(PropTypes.any).isRequired,
36
+ accept: PropTypes.string.isRequired,
37
+ multiple: PropTypes.bool.isRequired,
38
+ minSizeBytes: PropTypes.number.isRequired,
39
+ maxSizeBytes: PropTypes.number.isRequired,
40
+ maxFiles: PropTypes.number.isRequired,
41
+ onFiles: PropTypes.func.isRequired,
42
+ onCancelFile: PropTypes.func.isRequired,
43
+ onRemoveFile: PropTypes.func.isRequired,
44
+ onRestartFile: PropTypes.func.isRequired
45
+ }).isRequired
46
+ };
47
+ export {
48
+ Layout as default
49
+ };
50
+ //# sourceMappingURL=Layout.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Layout.js","sources":["../../src/dropzone/Layout.tsx"],"sourcesContent":["import React from 'react'\r\nimport PropTypes from 'prop-types'\r\n\r\nimport { ILayoutProps } from '.'\r\n\r\nconst Layout = (props: ILayoutProps) => {\r\n const {\r\n input,\r\n previews,\r\n submitButton,\r\n dropzoneProps,\r\n files,\r\n extra: { maxFiles },\r\n } = props\r\n\r\n return (\r\n <div {...dropzoneProps}>\r\n {previews}\r\n\r\n {files.length < maxFiles && input}\r\n\r\n {files.length > 0 && submitButton}\r\n </div>\r\n )\r\n}\r\n\r\nLayout.propTypes = {\r\n input: PropTypes.node,\r\n previews: PropTypes.arrayOf(PropTypes.node),\r\n submitButton: PropTypes.node,\r\n dropzoneProps: PropTypes.shape({\r\n ref: PropTypes.any.isRequired,\r\n className: PropTypes.string.isRequired,\r\n style: PropTypes.object,\r\n onDragEnter: PropTypes.func.isRequired,\r\n onDragOver: PropTypes.func.isRequired,\r\n onDragLeave: PropTypes.func.isRequired,\r\n onDrop: PropTypes.func.isRequired,\r\n }).isRequired,\r\n files: PropTypes.arrayOf(PropTypes.any).isRequired,\r\n extra: PropTypes.shape({\r\n active: PropTypes.bool.isRequired,\r\n reject: PropTypes.bool.isRequired,\r\n dragged: PropTypes.arrayOf(PropTypes.any).isRequired,\r\n accept: PropTypes.string.isRequired,\r\n multiple: PropTypes.bool.isRequired,\r\n minSizeBytes: PropTypes.number.isRequired,\r\n maxSizeBytes: PropTypes.number.isRequired,\r\n maxFiles: PropTypes.number.isRequired,\r\n onFiles: PropTypes.func.isRequired,\r\n onCancelFile: PropTypes.func.isRequired,\r\n onRemoveFile: PropTypes.func.isRequired,\r\n onRestartFile: PropTypes.func.isRequired,\r\n }).isRequired,\r\n}\r\n\r\nexport default Layout\r\n"],"names":[],"mappings":";;AAKA,MAAM,SAAS,CAAC,UAAwB;AACtC,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA,OAAO,EAAE,SAAA;AAAA,EAAS,IAChB;AAEJ,SACE,qBAAC,OAAA,EAAK,GAAG,eACN,UAAA;AAAA,IAAA;AAAA,IAEA,MAAM,SAAS,YAAY;AAAA,IAE3B,MAAM,SAAS,KAAK;AAAA,EAAA,GACvB;AAEJ;AAEA,OAAO,YAAY;AAAA,EACjB,OAAO,UAAU;AAAA,EACjB,UAAU,UAAU,QAAQ,UAAU,IAAI;AAAA,EAC1C,cAAc,UAAU;AAAA,EACxB,eAAe,UAAU,MAAM;AAAA,IAC7B,KAAK,UAAU,IAAI;AAAA,IACnB,WAAW,UAAU,OAAO;AAAA,IAC5B,OAAO,UAAU;AAAA,IACjB,aAAa,UAAU,KAAK;AAAA,IAC5B,YAAY,UAAU,KAAK;AAAA,IAC3B,aAAa,UAAU,KAAK;AAAA,IAC5B,QAAQ,UAAU,KAAK;AAAA,EAAA,CACxB,EAAE;AAAA,EACH,OAAO,UAAU,QAAQ,UAAU,GAAG,EAAE;AAAA,EACxC,OAAO,UAAU,MAAM;AAAA,IACrB,QAAQ,UAAU,KAAK;AAAA,IACvB,QAAQ,UAAU,KAAK;AAAA,IACvB,SAAS,UAAU,QAAQ,UAAU,GAAG,EAAE;AAAA,IAC1C,QAAQ,UAAU,OAAO;AAAA,IACzB,UAAU,UAAU,KAAK;AAAA,IACzB,cAAc,UAAU,OAAO;AAAA,IAC/B,cAAc,UAAU,OAAO;AAAA,IAC/B,UAAU,UAAU,OAAO;AAAA,IAC3B,SAAS,UAAU,KAAK;AAAA,IACxB,cAAc,UAAU,KAAK;AAAA,IAC7B,cAAc,UAAU,KAAK;AAAA,IAC7B,eAAe,UAAU,KAAK;AAAA,EAAA,CAC/B,EAAE;AACL;"}
@@ -0,0 +1,117 @@
1
+ import { jsxs, jsx } from "react/jsx-runtime";
2
+ import React from "react";
3
+ import PropTypes from "prop-types";
4
+ import { formatBytes, formatDuration } from "./utils.js";
5
+ import cancelImg from "./assets/cancel.svg.js";
6
+ import removeImg from "./assets/remove.svg.js";
7
+ import restartImg from "./assets/restart.svg.js";
8
+ const iconByFn = {
9
+ cancel: { backgroundImage: `url(${cancelImg})` },
10
+ remove: { backgroundImage: `url(${removeImg})` },
11
+ restart: { backgroundImage: `url(${restartImg})` }
12
+ };
13
+ class Preview extends React.PureComponent {
14
+ render() {
15
+ const {
16
+ className,
17
+ imageClassName,
18
+ style,
19
+ imageStyle,
20
+ fileWithMeta: { cancel, remove, restart },
21
+ meta: { name = "", percent = 0, size = 0, previewUrl, status, duration, validationError },
22
+ isUpload,
23
+ canCancel,
24
+ canRemove,
25
+ canRestart,
26
+ extra: { minSizeBytes }
27
+ } = this.props;
28
+ let title = `${name || "?"}, ${formatBytes(size)}`;
29
+ if (duration) title = `${title}, ${formatDuration(duration)}`;
30
+ if (status === "error_file_size" || status === "error_validation") {
31
+ return /* @__PURE__ */ jsxs("div", { className, style, children: [
32
+ /* @__PURE__ */ jsx("span", { className: "dzu-previewFileNameError", children: title }),
33
+ status === "error_file_size" && /* @__PURE__ */ jsx("span", { children: size < minSizeBytes ? "File too small" : "File too big" }),
34
+ status === "error_validation" && /* @__PURE__ */ jsx("span", { children: String(validationError) }),
35
+ canRemove && /* @__PURE__ */ jsx("span", { className: "dzu-previewButton", style: iconByFn.remove, onClick: remove })
36
+ ] });
37
+ }
38
+ if (status === "error_upload_params" || status === "exception_upload" || status === "error_upload") {
39
+ title = `${title} (upload failed)`;
40
+ }
41
+ if (status === "aborted") title = `${title} (cancelled)`;
42
+ return /* @__PURE__ */ jsxs("div", { className, style, children: [
43
+ previewUrl && /* @__PURE__ */ jsx("img", { className: imageClassName, style: imageStyle, src: previewUrl, alt: title, title }),
44
+ !previewUrl && /* @__PURE__ */ jsx("span", { className: "dzu-previewFileName", children: title }),
45
+ /* @__PURE__ */ jsxs("div", { className: "dzu-previewStatusContainer", children: [
46
+ isUpload && /* @__PURE__ */ jsx("progress", { max: 100, value: status === "done" || status === "headers_received" ? 100 : percent }),
47
+ status === "uploading" && canCancel && /* @__PURE__ */ jsx("span", { className: "dzu-previewButton", style: iconByFn.cancel, onClick: cancel }),
48
+ status !== "preparing" && status !== "getting_upload_params" && status !== "uploading" && canRemove && /* @__PURE__ */ jsx("span", { className: "dzu-previewButton", style: iconByFn.remove, onClick: remove }),
49
+ ["error_upload_params", "exception_upload", "error_upload", "aborted", "ready"].includes(status) && canRestart && /* @__PURE__ */ jsx("span", { className: "dzu-previewButton", style: iconByFn.restart, onClick: restart })
50
+ ] })
51
+ ] });
52
+ }
53
+ }
54
+ Preview.propTypes = {
55
+ className: PropTypes.string,
56
+ imageClassName: PropTypes.string,
57
+ style: PropTypes.object,
58
+ imageStyle: PropTypes.object,
59
+ fileWithMeta: PropTypes.shape({
60
+ file: PropTypes.any.isRequired,
61
+ meta: PropTypes.object.isRequired,
62
+ cancel: PropTypes.func.isRequired,
63
+ restart: PropTypes.func.isRequired,
64
+ remove: PropTypes.func.isRequired,
65
+ xhr: PropTypes.any
66
+ }).isRequired,
67
+ // copy of fileWithMeta.meta, won't be mutated
68
+ meta: PropTypes.shape({
69
+ status: PropTypes.oneOf([
70
+ "preparing",
71
+ "error_file_size",
72
+ "error_validation",
73
+ "ready",
74
+ "getting_upload_params",
75
+ "error_upload_params",
76
+ "uploading",
77
+ "exception_upload",
78
+ "aborted",
79
+ "error_upload",
80
+ "headers_received",
81
+ "done"
82
+ ]).isRequired,
83
+ type: PropTypes.string.isRequired,
84
+ name: PropTypes.string,
85
+ uploadedDate: PropTypes.string.isRequired,
86
+ percent: PropTypes.number,
87
+ size: PropTypes.number,
88
+ lastModifiedDate: PropTypes.string,
89
+ previewUrl: PropTypes.string,
90
+ duration: PropTypes.number,
91
+ width: PropTypes.number,
92
+ height: PropTypes.number,
93
+ videoWidth: PropTypes.number,
94
+ videoHeight: PropTypes.number,
95
+ validationError: PropTypes.any
96
+ }).isRequired,
97
+ isUpload: PropTypes.bool.isRequired,
98
+ canCancel: PropTypes.bool.isRequired,
99
+ canRemove: PropTypes.bool.isRequired,
100
+ canRestart: PropTypes.bool.isRequired,
101
+ files: PropTypes.arrayOf(PropTypes.any).isRequired,
102
+ // eslint-disable-line react/no-unused-prop-types
103
+ extra: PropTypes.shape({
104
+ active: PropTypes.bool.isRequired,
105
+ reject: PropTypes.bool.isRequired,
106
+ dragged: PropTypes.arrayOf(PropTypes.any).isRequired,
107
+ accept: PropTypes.string.isRequired,
108
+ multiple: PropTypes.bool.isRequired,
109
+ minSizeBytes: PropTypes.number.isRequired,
110
+ maxSizeBytes: PropTypes.number.isRequired,
111
+ maxFiles: PropTypes.number.isRequired
112
+ }).isRequired
113
+ };
114
+ export {
115
+ Preview as default
116
+ };
117
+ //# sourceMappingURL=Preview.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Preview.js","sources":["../../src/dropzone/Preview.tsx"],"sourcesContent":["import React from 'react'\r\nimport PropTypes from 'prop-types'\r\n\r\nimport { formatBytes, formatDuration } from './utils'\r\nimport { IPreviewProps } from '.'\r\n//@ts-ignore\r\nimport cancelImg from './assets/cancel.svg'\r\n//@ts-ignore\r\nimport removeImg from './assets/remove.svg'\r\n//@ts-ignore\r\nimport restartImg from './assets/restart.svg'\r\n\r\nconst iconByFn = {\r\n cancel: { backgroundImage: `url(${cancelImg})` },\r\n remove: { backgroundImage: `url(${removeImg})` },\r\n restart: { backgroundImage: `url(${restartImg})` },\r\n}\r\n\r\nclass Preview extends React.PureComponent<IPreviewProps> {\r\n render() {\r\n const {\r\n className,\r\n imageClassName,\r\n style,\r\n imageStyle,\r\n fileWithMeta: { cancel, remove, restart },\r\n meta: { name = '', percent = 0, size = 0, previewUrl, status, duration, validationError },\r\n isUpload,\r\n canCancel,\r\n canRemove,\r\n canRestart,\r\n extra: { minSizeBytes },\r\n } = this.props\r\n\r\n let title = `${name || '?'}, ${formatBytes(size)}`\r\n if (duration) title = `${title}, ${formatDuration(duration)}`\r\n\r\n if (status === 'error_file_size' || status === 'error_validation') {\r\n return (\r\n <div className={className} style={style}>\r\n <span className=\"dzu-previewFileNameError\">{title}</span>\r\n {status === 'error_file_size' && <span>{size < minSizeBytes ? 'File too small' : 'File too big'}</span>}\r\n {status === 'error_validation' && <span>{String(validationError)}</span>}\r\n {canRemove && <span className=\"dzu-previewButton\" style={iconByFn.remove} onClick={remove} />}\r\n </div>\r\n )\r\n }\r\n\r\n if (status === 'error_upload_params' || status === 'exception_upload' || status === 'error_upload') {\r\n title = `${title} (upload failed)`\r\n }\r\n if (status === 'aborted') title = `${title} (cancelled)`\r\n\r\n return (\r\n <div className={className} style={style}>\r\n {previewUrl && <img className={imageClassName} style={imageStyle} src={previewUrl} alt={title} title={title} />}\r\n {!previewUrl && <span className=\"dzu-previewFileName\">{title}</span>}\r\n\r\n <div className=\"dzu-previewStatusContainer\">\r\n {isUpload && (\r\n <progress max={100} value={status === 'done' || status === 'headers_received' ? 100 : percent} />\r\n )}\r\n\r\n {status === 'uploading' && canCancel && (\r\n <span className=\"dzu-previewButton\" style={iconByFn.cancel} onClick={cancel} />\r\n )}\r\n {status !== 'preparing' && status !== 'getting_upload_params' && status !== 'uploading' && canRemove && (\r\n <span className=\"dzu-previewButton\" style={iconByFn.remove} onClick={remove} />\r\n )}\r\n {['error_upload_params', 'exception_upload', 'error_upload', 'aborted', 'ready'].includes(status) &&\r\n canRestart && <span className=\"dzu-previewButton\" style={iconByFn.restart} onClick={restart} />}\r\n </div>\r\n </div>\r\n )\r\n }\r\n}\r\n\r\n// @ts-ignore\r\nPreview.propTypes = {\r\n className: PropTypes.string,\r\n imageClassName: PropTypes.string,\r\n style: PropTypes.object,\r\n imageStyle: PropTypes.object,\r\n fileWithMeta: PropTypes.shape({\r\n file: PropTypes.any.isRequired,\r\n meta: PropTypes.object.isRequired,\r\n cancel: PropTypes.func.isRequired,\r\n restart: PropTypes.func.isRequired,\r\n remove: PropTypes.func.isRequired,\r\n xhr: PropTypes.any,\r\n }).isRequired,\r\n // copy of fileWithMeta.meta, won't be mutated\r\n meta: PropTypes.shape({\r\n status: PropTypes.oneOf([\r\n 'preparing',\r\n 'error_file_size',\r\n 'error_validation',\r\n 'ready',\r\n 'getting_upload_params',\r\n 'error_upload_params',\r\n 'uploading',\r\n 'exception_upload',\r\n 'aborted',\r\n 'error_upload',\r\n 'headers_received',\r\n 'done',\r\n ]).isRequired,\r\n type: PropTypes.string.isRequired,\r\n name: PropTypes.string,\r\n uploadedDate: PropTypes.string.isRequired,\r\n percent: PropTypes.number,\r\n size: PropTypes.number,\r\n lastModifiedDate: PropTypes.string,\r\n previewUrl: PropTypes.string,\r\n duration: PropTypes.number,\r\n width: PropTypes.number,\r\n height: PropTypes.number,\r\n videoWidth: PropTypes.number,\r\n videoHeight: PropTypes.number,\r\n validationError: PropTypes.any,\r\n }).isRequired,\r\n isUpload: PropTypes.bool.isRequired,\r\n canCancel: PropTypes.bool.isRequired,\r\n canRemove: PropTypes.bool.isRequired,\r\n canRestart: PropTypes.bool.isRequired,\r\n files: PropTypes.arrayOf(PropTypes.any).isRequired, // eslint-disable-line react/no-unused-prop-types\r\n extra: PropTypes.shape({\r\n active: PropTypes.bool.isRequired,\r\n reject: PropTypes.bool.isRequired,\r\n dragged: PropTypes.arrayOf(PropTypes.any).isRequired,\r\n accept: PropTypes.string.isRequired,\r\n multiple: PropTypes.bool.isRequired,\r\n minSizeBytes: PropTypes.number.isRequired,\r\n maxSizeBytes: PropTypes.number.isRequired,\r\n maxFiles: PropTypes.number.isRequired,\r\n }).isRequired,\r\n}\r\n\r\nexport default Preview\r\n"],"names":[],"mappings":"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"}
@@ -0,0 +1,34 @@
1
+ import { jsx } from "react/jsx-runtime";
2
+ import PropTypes from "prop-types";
3
+ const SubmitButton = (props) => {
4
+ const { className, buttonClassName, style, buttonStyle, disabled, content, onSubmit, files } = props;
5
+ const _disabled = files.some((f) => ["preparing", "getting_upload_params", "uploading"].includes(f.meta.status)) || !files.some((f) => ["headers_received", "done"].includes(f.meta.status));
6
+ const handleSubmit = () => {
7
+ onSubmit(files.filter((f) => ["headers_received", "done"].includes(f.meta.status)));
8
+ };
9
+ return /* @__PURE__ */ jsx("div", { className, style, children: /* @__PURE__ */ jsx("button", { className: buttonClassName, style: buttonStyle, onClick: handleSubmit, disabled: disabled || _disabled, children: content }) });
10
+ };
11
+ SubmitButton.propTypes = {
12
+ className: PropTypes.string,
13
+ buttonClassName: PropTypes.string,
14
+ style: PropTypes.object,
15
+ buttonStyle: PropTypes.object,
16
+ disabled: PropTypes.bool.isRequired,
17
+ content: PropTypes.node,
18
+ onSubmit: PropTypes.func.isRequired,
19
+ files: PropTypes.arrayOf(PropTypes.object).isRequired,
20
+ extra: PropTypes.shape({
21
+ active: PropTypes.bool.isRequired,
22
+ reject: PropTypes.bool.isRequired,
23
+ dragged: PropTypes.arrayOf(PropTypes.any).isRequired,
24
+ accept: PropTypes.string.isRequired,
25
+ multiple: PropTypes.bool.isRequired,
26
+ minSizeBytes: PropTypes.number.isRequired,
27
+ maxSizeBytes: PropTypes.number.isRequired,
28
+ maxFiles: PropTypes.number.isRequired
29
+ }).isRequired
30
+ };
31
+ export {
32
+ SubmitButton as default
33
+ };
34
+ //# sourceMappingURL=SubmitButton.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SubmitButton.js","sources":["../../src/dropzone/SubmitButton.tsx"],"sourcesContent":["import React from 'react'\r\nimport PropTypes from 'prop-types'\r\n\r\nimport { ISubmitButtonProps } from '.'\r\n\r\nconst SubmitButton = (props: ISubmitButtonProps) => {\r\n const { className, buttonClassName, style, buttonStyle, disabled, content, onSubmit, files } = props\r\n\r\n const _disabled =\r\n files.some(f => ['preparing', 'getting_upload_params', 'uploading'].includes(f.meta.status)) ||\r\n !files.some(f => ['headers_received', 'done'].includes(f.meta.status))\r\n\r\n const handleSubmit = () => {\r\n onSubmit(files.filter(f => ['headers_received', 'done'].includes(f.meta.status)))\r\n }\r\n\r\n return (\r\n <div className={className} style={style}>\r\n <button className={buttonClassName} style={buttonStyle} onClick={handleSubmit} disabled={disabled || _disabled}>\r\n {content}\r\n </button>\r\n </div>\r\n )\r\n}\r\n\r\nSubmitButton.propTypes = {\r\n className: PropTypes.string,\r\n buttonClassName: PropTypes.string,\r\n style: PropTypes.object,\r\n buttonStyle: PropTypes.object,\r\n disabled: PropTypes.bool.isRequired,\r\n content: PropTypes.node,\r\n onSubmit: PropTypes.func.isRequired,\r\n files: PropTypes.arrayOf(PropTypes.object).isRequired,\r\n extra: PropTypes.shape({\r\n active: PropTypes.bool.isRequired,\r\n reject: PropTypes.bool.isRequired,\r\n dragged: PropTypes.arrayOf(PropTypes.any).isRequired,\r\n accept: PropTypes.string.isRequired,\r\n multiple: PropTypes.bool.isRequired,\r\n minSizeBytes: PropTypes.number.isRequired,\r\n maxSizeBytes: PropTypes.number.isRequired,\r\n maxFiles: PropTypes.number.isRequired,\r\n }).isRequired,\r\n}\r\n\r\nexport default SubmitButton\r\n"],"names":[],"mappings":";;AAKA,MAAM,eAAe,CAAC,UAA8B;AAClD,QAAM,EAAE,WAAW,iBAAiB,OAAO,aAAa,UAAU,SAAS,UAAU,MAAA,IAAU;AAE/F,QAAM,YACJ,MAAM,KAAK,CAAA,MAAK,CAAC,aAAa,yBAAyB,WAAW,EAAE,SAAS,EAAE,KAAK,MAAM,CAAC,KAC3F,CAAC,MAAM,KAAK,CAAA,MAAK,CAAC,oBAAoB,MAAM,EAAE,SAAS,EAAE,KAAK,MAAM,CAAC;AAEvE,QAAM,eAAe,MAAM;AACzB,aAAS,MAAM,OAAO,CAAA,MAAK,CAAC,oBAAoB,MAAM,EAAE,SAAS,EAAE,KAAK,MAAM,CAAC,CAAC;AAAA,EAClF;AAEA,6BACG,OAAA,EAAI,WAAsB,OACzB,UAAA,oBAAC,YAAO,WAAW,iBAAiB,OAAO,aAAa,SAAS,cAAc,UAAU,YAAY,WAClG,mBACH,GACF;AAEJ;AAEA,aAAa,YAAY;AAAA,EACvB,WAAW,UAAU;AAAA,EACrB,iBAAiB,UAAU;AAAA,EAC3B,OAAO,UAAU;AAAA,EACjB,aAAa,UAAU;AAAA,EACvB,UAAU,UAAU,KAAK;AAAA,EACzB,SAAS,UAAU;AAAA,EACnB,UAAU,UAAU,KAAK;AAAA,EACzB,OAAO,UAAU,QAAQ,UAAU,MAAM,EAAE;AAAA,EAC3C,OAAO,UAAU,MAAM;AAAA,IACrB,QAAQ,UAAU,KAAK;AAAA,IACvB,QAAQ,UAAU,KAAK;AAAA,IACvB,SAAS,UAAU,QAAQ,UAAU,GAAG,EAAE;AAAA,IAC1C,QAAQ,UAAU,OAAO;AAAA,IACzB,UAAU,UAAU,KAAK;AAAA,IACzB,cAAc,UAAU,OAAO;AAAA,IAC/B,cAAc,UAAU,OAAO;AAAA,IAC/B,UAAU,UAAU,OAAO;AAAA,EAAA,CAC5B,EAAE;AACL;"}
@@ -0,0 +1,5 @@
1
+ const cancelImg = "data:image/svg+xml,%3csvg%20viewBox='0%200%208%2014'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20fill='%23333333'%3e%3cpath%20d='M1,14%20C0.4,14%200,13.6%200,13%20L0,1%20C0,0.4%200.4,0%201,0%20C1.6,0%202,0.4%202,1%20L2,13%20C2,13.6%201.6,14%201,14%20Z'%20id='Path'%3e%3c/path%3e%3cpath%20d='M7,14%20C6.4,14%206,13.6%206,13%20L6,1%20C6,0.4%206.4,0%207,0%20C7.6,0%208,0.4%208,1%20L8,13%20C8,13.6%207.6,14%207,14%20Z'%20id='Path'%3e%3c/path%3e%3c/g%3e%3c/svg%3e";
2
+ export {
3
+ cancelImg as default
4
+ };
5
+ //# sourceMappingURL=cancel.svg.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cancel.svg.js","sources":["../../../src/dropzone/assets/cancel.svg"],"sourcesContent":["export default \"data:image/svg+xml,%3csvg%20viewBox='0%200%208%2014'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20fill='%23333333'%3e%3cpath%20d='M1,14%20C0.4,14%200,13.6%200,13%20L0,1%20C0,0.4%200.4,0%201,0%20C1.6,0%202,0.4%202,1%20L2,13%20C2,13.6%201.6,14%201,14%20Z'%20id='Path'%3e%3c/path%3e%3cpath%20d='M7,14%20C6.4,14%206,13.6%206,13%20L6,1%20C6,0.4%206.4,0%207,0%20C7.6,0%208,0.4%208,1%20L8,13%20C8,13.6%207.6,14%207,14%20Z'%20id='Path'%3e%3c/path%3e%3c/g%3e%3c/svg%3e\""],"names":[],"mappings":"AAAA,MAAA,YAAe;"}
@@ -0,0 +1,5 @@
1
+ const removeImg = "data:image/svg+xml,%3csvg%20viewBox='0%200%2014%2014'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20transform='translate(-5.0,%200.0)'%20fill='%23333333'%3e%3cg%20transform='translate(4.0,%200.0)'%3e%3cpolygon%20points='7.719%204.964%2012.692%200.017%2014.389%201.715%209.412%206.666%2014.354%2011.634%2012.657%2013.331%206.017%206.657%207.715%204.960'%3e%3c/polygon%3e%3cpolygon%20points='7.612%204.964%207.616%204.960%209.313%206.657%202.674%2013.331%200.977%2011.634%205.919%206.666%200.942%201.715%202.639%200.017'%3e%3c/polygon%3e%3c/g%3e%3c/g%3e%3c/svg%3e";
2
+ export {
3
+ removeImg as default
4
+ };
5
+ //# sourceMappingURL=remove.svg.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"remove.svg.js","sources":["../../../src/dropzone/assets/remove.svg"],"sourcesContent":["export default \"data:image/svg+xml,%3csvg%20viewBox='0%200%2014%2014'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20transform='translate(-5.0,%200.0)'%20fill='%23333333'%3e%3cg%20transform='translate(4.0,%200.0)'%3e%3cpolygon%20points='7.719%204.964%2012.692%200.017%2014.389%201.715%209.412%206.666%2014.354%2011.634%2012.657%2013.331%206.017%206.657%207.715%204.960'%3e%3c/polygon%3e%3cpolygon%20points='7.612%204.964%207.616%204.960%209.313%206.657%202.674%2013.331%200.977%2011.634%205.919%206.666%200.942%201.715%202.639%200.017'%3e%3c/polygon%3e%3c/g%3e%3c/g%3e%3c/svg%3e\""],"names":[],"mappings":"AAAA,MAAA,YAAe;"}
@@ -0,0 +1,5 @@
1
+ const restartImg = "data:image/svg+xml,%3csvg%20viewBox='0%200%2011%2015'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%3e%3cpath%20d='M0.5,14.9%20C0.2,14.7%200,14.4%200,14%20L0,2%20C0,1.6%200.2,1.3%200.5,1.1%20C0.8,0.9%201.2,0.9%201.5,1.1%20L10.5,7.1%20C10.8,7.3%2010.9,7.6%2010.9,7.9%20C10.9,8.2%2010.7,8.5%2010.5,8.7%20L1.5,14.7%20C1.4,14.9%200.8,15.1%200.5,14.9%20Z%20M2,3.9%20L2,12.2%20L8.2,8.1%20L2,3.9%20Z'%3e%3c/path%3e%3c/g%3e%3c/svg%3e";
2
+ export {
3
+ restartImg as default
4
+ };
5
+ //# sourceMappingURL=restart.svg.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"restart.svg.js","sources":["../../../src/dropzone/assets/restart.svg"],"sourcesContent":["export default \"data:image/svg+xml,%3csvg%20viewBox='0%200%2011%2015'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%3e%3cpath%20d='M0.5,14.9%20C0.2,14.7%200,14.4%200,14%20L0,2%20C0,1.6%200.2,1.3%200.5,1.1%20C0.8,0.9%201.2,0.9%201.5,1.1%20L10.5,7.1%20C10.8,7.3%2010.9,7.6%2010.9,7.9%20C10.9,8.2%2010.7,8.5%2010.5,8.7%20L1.5,14.7%20C1.4,14.9%200.8,15.1%200.5,14.9%20Z%20M2,3.9%20L2,12.2%20L8.2,8.1%20L2,3.9%20Z'%3e%3c/path%3e%3c/g%3e%3c/svg%3e\""],"names":[],"mappings":"AAAA,MAAA,aAAe;"}