@agrotools1/at-components 0.6.26 → 0.6.29

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 (239) hide show
  1. package/README.md +7 -7
  2. package/dist/Accordion/Accordion.d.ts +4 -4
  3. package/dist/Accordion/Accordion.vue.js +4 -4
  4. package/dist/Accordion/Accordion.vue3.js +2 -2
  5. package/dist/Accordion/index.d.ts +1 -1
  6. package/dist/Avatar/Avatar.d.ts +4 -4
  7. package/dist/Avatar/Avatar.vue.js +1 -1
  8. package/dist/Avatar/Avatar.vue3.js +2 -2
  9. package/dist/Avatar/index.d.ts +1 -1
  10. package/dist/Button/Button.d.ts +4 -4
  11. package/dist/Button/Button.vue.js +1 -1
  12. package/dist/Button/Button.vue3.js +2 -2
  13. package/dist/Button/index.d.ts +1 -1
  14. package/dist/CardWithInsights/CardWithInsights.vue.js +6 -6
  15. package/dist/CardWithInsights/CardWithInsights.vue4.js +2 -2
  16. package/dist/CardWithInsights/index.d.ts +1 -1
  17. package/dist/Checkbox/Checkbox.d.ts +9 -8
  18. package/dist/Checkbox/Checkbox.vue.js +1 -1
  19. package/dist/Checkbox/img/checkmarck.svg.js +1 -1
  20. package/dist/Checkbox/index.d.ts +1 -1
  21. package/dist/Chips/index.d.ts +1 -1
  22. package/dist/ColorPicker/ColorPicker.Saturation.d.ts +8 -8
  23. package/dist/ColorPicker/ColorPicker.Saturation.vue.js +10 -10
  24. package/dist/ColorPicker/ColorPicker.Saturation.vue3.js +2 -2
  25. package/dist/ColorPicker/ColorPicker.vue.js +4 -4
  26. package/dist/ColorPicker/index.d.ts +1 -1
  27. package/dist/DataTable/Column/Column.d.ts +4 -3
  28. package/dist/DataTable/Column/Column.vue.js +6 -6
  29. package/dist/DataTable/Column/Column.vue3.js +2 -2
  30. package/dist/DataTable/Column/imgs/filter.svg.js +1 -1
  31. package/dist/DataTable/Counters/Counters.d.ts +6 -6
  32. package/dist/DataTable/Counters/Counters.vue.js +1 -1
  33. package/dist/DataTable/Counters/imgs/close.svg.js +1 -1
  34. package/dist/DataTable/DataTable.d.ts +9 -8
  35. package/dist/DataTable/DataTable.vue.js +5 -5
  36. package/dist/DataTable/index.d.ts +37 -37
  37. package/dist/DatePicker/DatePicker.d.ts +22 -21
  38. package/dist/DatePicker/DatePicker.scss.js +2 -2
  39. package/dist/DatePicker/DatePicker.vue.js +5 -5
  40. package/dist/DatePicker/DatePicker.vue2.js +89 -85
  41. package/dist/DatePicker/DatePickerCalendar/DatePickerCalendar.d.ts +6 -6
  42. package/dist/DatePicker/DatePickerCalendar/DatePickerCalendar.helper.d.ts +2 -1
  43. package/dist/DatePicker/DatePickerCalendar/DatePickerCalendar.vue.js +3 -3
  44. package/dist/DatePicker/DatePickerHeader/DatePickerHeader.d.ts +2 -2
  45. package/dist/DatePicker/DatePickerHeader/DatePickerHeader.scss.js +2 -2
  46. package/dist/DatePicker/DatePickerHeader/DatePickerHeader.vue.js +4 -4
  47. package/dist/DatePicker/DatePickerListSelector/DatePickerListSelector.d.ts +5 -5
  48. package/dist/DatePicker/DatePickerListSelector/DatePickerListSelector.vue.js +5 -5
  49. package/dist/DatePicker/DatePickerTime/DatePickerTime.d.ts +7 -6
  50. package/dist/DatePicker/DatePickerTime/DatePickerTime.scss.js +2 -2
  51. package/dist/DatePicker/DatePickerTime/DatePickerTime.vue.js +8 -8
  52. package/dist/DatePicker/index.d.ts +2 -2
  53. package/dist/Dropdown/Checklist/Dropdown.Checklist.d.ts +13 -12
  54. package/dist/Dropdown/Checklist/Dropdown.Checklist.vue.js +20 -20
  55. package/dist/Dropdown/Checklist/draggable.d.ts +2 -1
  56. package/dist/Dropdown/Dropdown.core.d.ts +9 -8
  57. package/dist/Dropdown/Dropdown.core.vue.js +2 -2
  58. package/dist/Dropdown/Dropdown.types.d.ts +1 -1
  59. package/dist/Dropdown/DropdownContent/DropdownContent.d.ts +1 -1
  60. package/dist/Faq/Faq.vue.js +5 -5
  61. package/dist/Faq/FaqItem/FaqItem.d.ts +5 -4
  62. package/dist/Faq/FaqItem/FaqItem.vue.js +1 -1
  63. package/dist/Faq/FaqItem/index.d.ts +1 -1
  64. package/dist/Faq/index.d.ts +1 -1
  65. package/dist/Filter/components/Filter.types.d.ts +2 -1
  66. package/dist/Filter/components/Filter.vue.js +19 -19
  67. package/dist/Filter/index.d.ts +4 -3
  68. package/dist/Filter/tests/mocks.d.ts +3 -2
  69. package/dist/Icons/icons.d.ts +1860 -1860
  70. package/dist/Illustration/Illustration.vue.js +5 -5
  71. package/dist/Illustration/images/renovabio-illustrations/biomass.svg.js +1 -1
  72. package/dist/Illustration/images/renovabio-illustrations/volume.svg.js +1 -1
  73. package/dist/Illustration/images/system-images/add-file.svg.js +1 -1
  74. package/dist/Illustration/images/system-images/cloud-connection.svg.js +1 -1
  75. package/dist/Illustration/images/system-images/cloud-download.svg.js +1 -1
  76. package/dist/Illustration/images/system-images/cloud-upload.svg.js +1 -1
  77. package/dist/Illustration/images/system-images/corrupted-file.svg.js +1 -1
  78. package/dist/Illustration/images/system-images/empty-box.svg.js +1 -1
  79. package/dist/Illustration/images/system-images/empty-folder-2.svg.js +1 -1
  80. package/dist/Illustration/images/system-images/empty-folder.svg.js +1 -1
  81. package/dist/Illustration/images/system-images/empty.svg.js +1 -1
  82. package/dist/Illustration/images/system-images/error-illustration.svg.js +1 -1
  83. package/dist/Illustration/images/system-images/file-backup-2.svg.js +1 -1
  84. package/dist/Illustration/images/system-images/file-backup.svg.js +1 -1
  85. package/dist/Illustration/images/system-images/filtering-upload.svg.js +1 -1
  86. package/dist/Illustration/images/system-images/flight.svg.js +1 -1
  87. package/dist/Illustration/images/system-images/fly.svg.js +1 -1
  88. package/dist/Illustration/images/system-images/movies.svg.js +1 -1
  89. package/dist/Illustration/images/system-images/multimedia.svg.js +1 -1
  90. package/dist/Illustration/images/system-images/notification-bell.svg.js +1 -1
  91. package/dist/Illustration/images/system-images/page-2.svg.js +1 -1
  92. package/dist/Illustration/images/system-images/page.svg.js +1 -1
  93. package/dist/Illustration/images/system-images/photos.svg.js +1 -1
  94. package/dist/Illustration/images/system-images/recycle-bin.svg.js +1 -1
  95. package/dist/Illustration/images/system-images/rocket-launch.svg.js +1 -1
  96. package/dist/Illustration/images/system-images/signal.svg.js +1 -1
  97. package/dist/Illustration/images/system-images/wrong.svg.js +1 -1
  98. package/dist/Illustration/images/tools-images/advanced-analysis.svg.js +1 -1
  99. package/dist/Illustration/images/tools-images/agriculture.svg.js +1 -1
  100. package/dist/Illustration/images/tools-images/alert-center.svg.js +1 -1
  101. package/dist/Illustration/images/tools-images/area.svg.js +1 -1
  102. package/dist/Illustration/images/tools-images/at-insights.svg.js +1 -1
  103. package/dist/Illustration/images/tools-images/conservation-unit.svg.js +1 -1
  104. package/dist/Illustration/images/tools-images/credit.svg.js +2 -2
  105. package/dist/Illustration/images/tools-images/deforestation.svg.js +1 -1
  106. package/dist/Illustration/images/tools-images/distance-proximity-rivers.svg.js +1 -1
  107. package/dist/Illustration/images/tools-images/estimated-productivity-penalty.svg.js +1 -1
  108. package/dist/Illustration/images/tools-images/extract.svg.js +1 -1
  109. package/dist/Illustration/images/tools-images/farm.svg.js +1 -1
  110. package/dist/Illustration/images/tools-images/geographical-consultation-municipalities.svg.js +1 -1
  111. package/dist/Illustration/images/tools-images/gix.svg.js +1 -1
  112. package/dist/Illustration/images/tools-images/insurance.svg.js +1 -1
  113. package/dist/Illustration/images/tools-images/land-appreciation.svg.js +1 -1
  114. package/dist/Illustration/images/tools-images/lockdown.svg.js +1 -1
  115. package/dist/Illustration/images/tools-images/map.svg.js +1 -1
  116. package/dist/Illustration/images/tools-images/pasture.svg.js +1 -1
  117. package/dist/Illustration/images/tools-images/rating-2.svg.js +1 -1
  118. package/dist/Illustration/images/tools-images/rating.svg.js +1 -1
  119. package/dist/Illustration/images/tools-images/recurrence.svg.js +1 -1
  120. package/dist/Illustration/images/tools-images/refrigerators.svg.js +1 -1
  121. package/dist/Illustration/images/tools-images/settings.svg.js +1 -1
  122. package/dist/Illustration/images/tools-images/socio-environmental-analysis.svg.js +1 -1
  123. package/dist/Illustration/images/tools-images/soil-use.svg.js +1 -1
  124. package/dist/Illustration/images/tools-images/storm.svg.js +1 -1
  125. package/dist/Illustration/images/tools-images/territory-details.svg.js +1 -1
  126. package/dist/Illustration/images/tools-images/timeline.svg.js +1 -1
  127. package/dist/Illustration/index.d.ts +1 -1
  128. package/dist/Input/Input.core.d.ts +356 -355
  129. package/dist/Input/Input.core.vue.js +6 -6
  130. package/dist/Input/Input.core.vue3.js +2 -2
  131. package/dist/Input/imgs/error.svg.js +2 -2
  132. package/dist/Input/index.d.ts +1695 -1694
  133. package/dist/Legend/Legend.d.ts +3 -3
  134. package/dist/Legend/Legend.vue.js +1 -1
  135. package/dist/Legend/index.d.ts +1 -1
  136. package/dist/List/components/List.d.ts +9 -9
  137. package/dist/List/components/List.types.d.ts +2 -1
  138. package/dist/List/components/List.vue.js +2 -2
  139. package/dist/List/index.d.ts +4 -3
  140. package/dist/List/tests/mocks.d.ts +2 -1
  141. package/dist/Loading/Loading.d.ts +2 -2
  142. package/dist/Loading/index.d.ts +1 -1
  143. package/dist/Menu/Menu.d.ts +4 -3
  144. package/dist/Menu/Menu.vue.js +2 -2
  145. package/dist/Menu/assets/agrotools.svg.js +1 -1
  146. package/dist/Menu/assets/at.svg.js +1 -1
  147. package/dist/Menu/index.d.ts +1 -1
  148. package/dist/Modal/Modal.d.ts +9 -8
  149. package/dist/Modal/Modal.vue.js +16 -16
  150. package/dist/Modal/Modal.vue2.js +4 -2
  151. package/dist/Modal/Modal.vue3.js +2 -2
  152. package/dist/Modal/images/cross.svg.js +1 -1
  153. package/dist/Modal/index.d.ts +1 -1
  154. package/dist/Notifications/Notification/Notification.d.ts +50 -50
  155. package/dist/Notifications/Notification/Notification.vue.js +4 -4
  156. package/dist/Notifications/Notifications.d.ts +9 -9
  157. package/dist/Notifications/Notifications.vue.js +6 -6
  158. package/dist/Notifications/Notifications.vue3.js +2 -2
  159. package/dist/Notifications/index.d.ts +1 -1
  160. package/dist/Paginator/Paginator.d.ts +7 -7
  161. package/dist/Paginator/Paginator.vue.js +2 -2
  162. package/dist/Paginator/imgs/double-left-arrow.svg.js +1 -1
  163. package/dist/Paginator/imgs/double-right-arrow.svg.js +1 -1
  164. package/dist/Paginator/imgs/left-arrow.svg.js +1 -1
  165. package/dist/Paginator/imgs/right-arrow.svg.js +1 -1
  166. package/dist/Paginator/index.d.ts +1 -1
  167. package/dist/ProgressBar/ProgressBar.d.ts +4 -3
  168. package/dist/ProgressBar/ProgressBar.vue.js +2 -2
  169. package/dist/ProgressBar/index.d.ts +1 -1
  170. package/dist/RadioButton/RadioButton.d.ts +3 -3
  171. package/dist/RadioButton/RadioButton.vue.js +1 -1
  172. package/dist/RadioButton/RadioButton.vue3.js +2 -2
  173. package/dist/RadioButton/index.d.ts +1 -1
  174. package/dist/Search/Search.d.ts +7 -6
  175. package/dist/Search/Search.vue.js +4 -4
  176. package/dist/Search/index.d.ts +1 -1
  177. package/dist/Search/test.mocks.d.ts +2 -1
  178. package/dist/Search/utils.d.ts +2 -1
  179. package/dist/Select/Item/Item.d.ts +3 -3
  180. package/dist/Select/Item/Item.vue.js +16 -16
  181. package/dist/Select/Multiple/Select.multiple.d.ts +14 -13
  182. package/dist/Select/Multiple/Select.multiple.vue.js +10 -10
  183. package/dist/Select/Select.core.d.ts +8 -7
  184. package/dist/Select/Single/Select.single.d.ts +12 -11
  185. package/dist/Select/Single/Select.single.vue.js +6 -6
  186. package/dist/Select/imgs/indicator.svg.js +1 -1
  187. package/dist/Select/index.d.ts +25 -24
  188. package/dist/Skeleton/Skeleton.d.ts +2 -2
  189. package/dist/Skeleton/index.d.ts +1 -1
  190. package/dist/Stepper/Stepper.vue.js +37 -37
  191. package/dist/Stepper/Stepper.vue2.js +53 -48
  192. package/dist/Stepper/index.d.ts +1 -1
  193. package/dist/TableConfig/TableConfig.d.ts +11 -10
  194. package/dist/TableConfig/TableConfig.vue.js +2 -2
  195. package/dist/TableConfig/index.d.ts +1 -1
  196. package/dist/TableConfig/test/mocks.d.ts +2 -1
  197. package/dist/Tabs/Tab/Tab.d.ts +4 -4
  198. package/dist/Tabs/Tab/Tab.vue.js +1 -1
  199. package/dist/Tabs/Tab/Tab.vue3.js +2 -2
  200. package/dist/Tabs/Tabs.d.ts +9 -8
  201. package/dist/Tabs/Tabs.vue.js +7 -7
  202. package/dist/Tabs/Tabs.vue3.js +2 -2
  203. package/dist/Tabs/index.d.ts +1 -1
  204. package/dist/Tag/Tag.d.ts +7 -6
  205. package/dist/Tag/Tag.vue.js +1 -1
  206. package/dist/Tag/index.d.ts +1 -1
  207. package/dist/Tipograph/Paragraph/Paragraph.d.ts +2 -2
  208. package/dist/Tipograph/Paragraph/Paragraph.vue.js +2 -2
  209. package/dist/Tipograph/Paragraph/Paragraph.vue3.js +2 -2
  210. package/dist/Tipograph/Title/Title.d.ts +2 -2
  211. package/dist/Tipograph/Title/Title.vue.js +2 -2
  212. package/dist/Tipograph/index.d.ts +4 -4
  213. package/dist/Toggle/Toggle.d.ts +5 -5
  214. package/dist/Toggle/Toggle.vue.js +2 -2
  215. package/dist/Toggle/index.d.ts +1 -1
  216. package/dist/Tooltip/Tooltip.d.ts +12 -11
  217. package/dist/Tooltip/Tooltip.vue.js +4 -4
  218. package/dist/Tooltip/Tooltip.vue2.js +48 -50
  219. package/dist/Tooltip/Tooltip.vue3.js +2 -2
  220. package/dist/Tooltip/index.d.ts +1 -1
  221. package/dist/Upload/MultipleUpload/MultipleUpload.d.ts +8 -7
  222. package/dist/Upload/MultipleUpload/MultipleUpload.vue.js +5 -5
  223. package/dist/Upload/MultipleUpload/MultipleUpload.vue2.js +55 -44
  224. package/dist/Upload/SingleUpload/SingleUpload.d.ts +6 -5
  225. package/dist/Upload/SingleUpload/SingleUpload.vue.js +4 -4
  226. package/dist/Upload/SingleUpload/SingleUpload.vue2.js +45 -34
  227. package/dist/Upload/Upload.d.ts +4 -3
  228. package/dist/Upload/Upload.vue.js +1 -1
  229. package/dist/Upload/UploaderHeader/UploaderHeader.d.ts +2 -2
  230. package/dist/Upload/UploaderHeader/UploaderHeader.vue.js +1 -1
  231. package/dist/Upload/UploaderInfoProgress/UploaderInfoProgress.d.ts +2 -2
  232. package/dist/Upload/UploaderInfoProgress/UploaderInfoProgress.vue.js +1 -1
  233. package/dist/Upload/UploaderInput/UploaderInput.d.ts +6 -5
  234. package/dist/Upload/UploaderInput/UploaderInput.vue.js +1 -1
  235. package/dist/Upload/index.d.ts +1 -1
  236. package/dist/index.d.ts +33 -32
  237. package/dist/index.js +36 -34
  238. package/dist/style.css +1 -1
  239. package/package.json +1 -1
@@ -1,13 +1,13 @@
1
- import { defineComponent as x, ref as g, computed as y } from "vue";
1
+ import { defineComponent as x, ref as y, computed as g } from "vue";
2
2
  import h from "../../ProgressBar/ProgressBar.vue.js";
3
- import q from "../UploaderHeader/UploaderHeader.vue.js";
4
- import T from "../UploaderInput/UploaderInput.vue.js";
5
- const I = x({
3
+ import T from "../UploaderHeader/UploaderHeader.vue.js";
4
+ import q from "../UploaderInput/UploaderInput.vue.js";
5
+ const P = x({
6
6
  name: "MultipleUpload",
7
7
  components: {
8
8
  AtProgressBar: h,
9
- UploaderHeader: q,
10
- UploaderInput: T
9
+ UploaderHeader: T,
10
+ UploaderInput: q
11
11
  },
12
12
  props: {
13
13
  warningTextUpload: {
@@ -111,52 +111,63 @@ const I = x({
111
111
  }
112
112
  },
113
113
  emits: ["updateFile", "updateProgress", "uploadError"],
114
- setup(e, { emit: l }) {
115
- const r = g([]), d = g(e.uploadProgress), v = (t) => {
114
+ setup(e, { emit: n }) {
115
+ const o = y([]), d = y(e.uploadProgress), v = (t) => {
116
116
  if (t.preventDefault(), t.dataTransfer) {
117
- const a = Array.from(t.dataTransfer.files), o = u(a);
118
- o.length && (r.value.push(...o), l("updateFile", r.value));
117
+ const a = Array.from(t.dataTransfer.files), i = u(a);
118
+ i.length && (o.value.push(...i), n("updateFile", o.value));
119
119
  }
120
120
  }, u = (t) => {
121
121
  const a = [];
122
- if (!c(t) || !m(t))
122
+ if (!f(t) || !m(t))
123
123
  return [];
124
- const o = t.filter((i) => {
125
- const n = f(i), s = p(i);
126
- return n || a.push({
127
- file: i,
124
+ const i = t.filter((r) => {
125
+ const l = c(r), s = p(r);
126
+ return l || a.push({
127
+ file: r,
128
128
  type: "unsupported_type",
129
- message: `O tipo (${i.type}) do arquivo ${i.name} não é suportado. `
129
+ message: `O tipo (${r.type}) do arquivo ${r.name} não é suportado. `
130
130
  }), s || a.push({
131
- file: i,
131
+ file: r,
132
132
  type: "exceeded_file_size",
133
- message: `O tamanho do arquivo ${i.name} excedeu o limite permitido. `
134
- }), n && s;
133
+ message: `O tamanho do arquivo ${r.name} excedeu o limite permitido. `
134
+ }), l && s;
135
135
  });
136
- return a.length && (console.warn(a.map((i) => i.message).join(`
137
- `)), l("uploadError", a)), o;
138
- }, p = (t) => e.maxFileSize ? t.size < e.maxFileSize : !0, f = (t) => e.acceptTypes.length ? e.acceptTypes.map((o) => o.toLowerCase()).includes(t.type.toLowerCase()) : !0, c = (t) => {
139
- const a = [], o = t.length + r.value.length;
140
- return e.maxFiles && o > e.maxFiles ? (a.push({
136
+ return a.length && (console.warn(a.map((r) => r.message).join(`
137
+ `)), n("uploadError", a)), i;
138
+ }, p = (t) => e.maxFileSize ? t.size < e.maxFileSize : !0, c = (t) => {
139
+ if (!e.acceptTypes.length && (!e.acceptTypesInput || e.acceptTypesInput === "*"))
140
+ return !0;
141
+ if (e.acceptTypes.length)
142
+ return e.acceptTypes.map(
143
+ (l) => l.toLowerCase()
144
+ ).includes(t.type.toLowerCase());
145
+ const a = t.name.split(".").pop();
146
+ return e.acceptTypesInput.split(",").some(
147
+ (r) => r.includes(a || "")
148
+ );
149
+ }, f = (t) => {
150
+ const a = [], i = t.length + o.value.length;
151
+ return e.maxFiles && i > e.maxFiles ? (a.push({
141
152
  file: t[0],
142
153
  type: "exceeded_file_length",
143
154
  message: `O tamanho limite de arquivos foi excedido (${e.maxFiles})`
144
- }), console.warn(a.map((i) => i.message).join(`
145
- `)), l("uploadError", a), !1) : !0;
155
+ }), console.warn(a.map((r) => r.message).join(`
156
+ `)), n("uploadError", a), !1) : !0;
146
157
  }, m = (t) => {
147
- const a = [], o = r.value.reduce(
148
- (n, s) => n + s.size,
158
+ const a = [], i = o.value.reduce(
159
+ (l, s) => l + s.size,
149
160
  0
150
- ), i = t.reduce(
151
- (n, s) => n + s.size,
161
+ ), r = t.reduce(
162
+ (l, s) => l + s.size,
152
163
  0
153
164
  );
154
- return e.maxTotalSize && i + o > e.maxTotalSize ? (a.push({
165
+ return e.maxTotalSize && r + i > e.maxTotalSize ? (a.push({
155
166
  file: t[0],
156
167
  type: "exceeded_total_size",
157
168
  message: `A soma de tamanho dos arquivos foi excedida, máximo permitido: ${e.maxTotalSize} B `
158
- }), console.warn(a.map((n) => n.message).join(`
159
- `)), l("uploadError", a), !1) : !0;
169
+ }), console.warn(a.map((l) => l.message).join(`
170
+ `)), n("uploadError", a), !1) : !0;
160
171
  };
161
172
  return {
162
173
  handleDrop: v,
@@ -164,28 +175,28 @@ const I = x({
164
175
  const a = t.target.files;
165
176
  if (!a)
166
177
  return;
167
- const o = u(Array.from(a));
168
- o.length && (r.value.push(...o), l("updateFile", r.value));
178
+ const i = u(Array.from(a));
179
+ i.length && (o.value.push(...i), n("updateFile", o.value));
169
180
  },
170
181
  handleRemove: (t) => {
171
- const a = r.value.indexOf(t);
172
- a !== -1 && (r.value.splice(a, 1), r.value.length === 0 && (d.value = 0, l("updateProgress", 0)), l("updateFile", r.value));
182
+ const a = o.value.indexOf(t);
183
+ a !== -1 && (o.value.splice(a, 1), o.value.length === 0 && (d.value = 0, n("updateProgress", 0)), n("updateFile", o.value));
173
184
  },
174
185
  handleUpdateProgressOnParent: (t) => {
175
- d.value = t, l("updateProgress", d.value);
186
+ d.value = t, n("updateProgress", d.value);
176
187
  },
177
188
  getAcceptedFiles: u,
178
189
  isMaxTotalFilesSizeInRange: m,
179
- isMaxFilesInRange: c,
180
- isTypeAccepted: f,
190
+ isMaxFilesInRange: f,
191
+ isTypeAccepted: c,
181
192
  isSizeAccepted: p,
182
- files: r,
193
+ files: o,
183
194
  progress: d,
184
- inputStyle: y(() => r.value.length > 0 ? { height: "256px", width: "256px" } : { width: "100%" }),
185
- uploaderContainerStyle: y(() => r.value.length <= 0 ? { width: "100%", padding: "0px" } : {})
195
+ inputStyle: g(() => o.value.length > 0 ? { height: "256px", width: "256px" } : { width: "100%" }),
196
+ uploaderContainerStyle: g(() => o.value.length <= 0 ? { width: "100%", padding: "0px" } : {})
186
197
  };
187
198
  }
188
199
  });
189
200
  export {
190
- I as default
201
+ P as default
191
202
  };
@@ -1,5 +1,6 @@
1
- import { type PropType } from "vue";
2
- declare const _default: import("vue").DefineComponent<{
1
+ import { PropType } from 'vue';
2
+
3
+ declare const _default: import('vue').DefineComponent<{
3
4
  warningTextUpload: {
4
5
  type: StringConstructor;
5
6
  required: false;
@@ -92,7 +93,7 @@ declare const _default: import("vue").DefineComponent<{
92
93
  handleUpdateProgressOnParent: (newValue: number) => void;
93
94
  getAcceptedFiles: (files: File[]) => File[];
94
95
  isSizeAccepted: (file: File) => boolean;
95
- file: import("vue").Ref<{
96
+ file: import('vue').Ref<{
96
97
  readonly lastModified: number;
97
98
  readonly name: string;
98
99
  readonly webkitRelativePath: string;
@@ -103,8 +104,8 @@ declare const _default: import("vue").DefineComponent<{
103
104
  stream: () => ReadableStream<Uint8Array>;
104
105
  text: () => Promise<string>;
105
106
  } | null>;
106
- progress: import("vue").Ref<number>;
107
- }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("updateProgress" | "updateFile" | "uploadError")[], "updateProgress" | "updateFile" | "uploadError", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
107
+ progress: import('vue').Ref<number>;
108
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, ("updateProgress" | "updateFile" | "uploadError")[], "updateProgress" | "updateFile" | "uploadError", import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, Readonly<import('vue').ExtractPropTypes<{
108
109
  warningTextUpload: {
109
110
  type: StringConstructor;
110
111
  required: false;
@@ -7,9 +7,9 @@ const m = { class: "at-uploader-single" }, f = {
7
7
  class: "at-uploader-status-container at-uploader-loading-input-container"
8
8
  };
9
9
  function g(e, v, h, $, U, w) {
10
- const p = t("UploaderHeader"), a = t("UploaderInput"), l = t("UploaderInfoProgress"), s = t("AtProgressBar");
10
+ const a = t("UploaderHeader"), p = t("UploaderInput"), l = t("UploaderInfoProgress"), s = t("AtProgressBar");
11
11
  return o(), r("div", null, [
12
- n(p, {
12
+ n(a, {
13
13
  "warning-text-upload": e.$props.warningTextUpload,
14
14
  "interactive-text-button": e.$props.interactiveTextButton,
15
15
  "interactive-texthref": e.$props.interactiveTexthref,
@@ -17,7 +17,7 @@ function g(e, v, h, $, U, w) {
17
17
  "warning-function": e.$props.warningFunction
18
18
  }, null, 8, ["warning-text-upload", "interactive-text-button", "interactive-texthref", "interactive-text-download-name", "warning-function"]),
19
19
  d("div", m, [
20
- e.file === null ? (o(), c(a, {
20
+ e.file === null ? (o(), c(p, {
21
21
  key: 0,
22
22
  style: { width: "100%" },
23
23
  "handle-drop": e.handleDrop,
@@ -44,7 +44,7 @@ function g(e, v, h, $, U, w) {
44
44
  ])
45
45
  ]);
46
46
  }
47
- const x = /* @__PURE__ */ u(i, [["render", g], ["__scopeId", "data-v-6037f873"]]);
47
+ const x = /* @__PURE__ */ u(i, [["render", g], ["__scopeId", "data-v-aba1d251"]]);
48
48
  export {
49
49
  x as default
50
50
  };
@@ -1,15 +1,15 @@
1
- import { defineComponent as g, ref as f } from "vue";
1
+ import { defineComponent as g, ref as c } from "vue";
2
2
  import m from "../../ProgressBar/ProgressBar.vue.js";
3
3
  import v from "../UploaderHeader/UploaderHeader.vue.js";
4
- import q from "../UploaderInfoProgress/UploaderInfoProgress.vue.js";
5
- import T from "../UploaderInput/UploaderInput.vue.js";
6
- const w = g({
4
+ import T from "../UploaderInfoProgress/UploaderInfoProgress.vue.js";
5
+ import q from "../UploaderInput/UploaderInput.vue.js";
6
+ const I = g({
7
7
  name: "SingleUpload",
8
8
  components: {
9
- UploaderInfoProgress: q,
9
+ UploaderInfoProgress: T,
10
10
  AtProgressBar: m,
11
11
  UploaderHeader: v,
12
- UploaderInput: T
12
+ UploaderInput: q
13
13
  },
14
14
  props: {
15
15
  warningTextUpload: {
@@ -102,49 +102,60 @@ const w = g({
102
102
  },
103
103
  emits: ["updateFile", "updateProgress", "uploadError"],
104
104
  setup(e, { emit: l }) {
105
- const s = f(null), i = f(e.uploadProgress), c = (t) => {
105
+ const n = c(null), s = c(e.uploadProgress), f = (t) => {
106
106
  if (t.preventDefault(), t.dataTransfer) {
107
- const r = t.dataTransfer.files, a = n(Array.from(r));
108
- a.length && (s.value = a[0], l("updateFile", s.value));
107
+ const a = t.dataTransfer.files, o = d(Array.from(a));
108
+ o.length && (n.value = o[0], l("updateFile", n.value));
109
109
  }
110
- }, n = (t) => {
111
- const r = [], a = t.filter((o) => {
112
- const p = y(o), u = d(o);
113
- return p || r.push({
114
- file: o,
110
+ }, d = (t) => {
111
+ const a = [], o = t.filter((r) => {
112
+ const i = y(r), u = p(r);
113
+ return i || a.push({
114
+ file: r,
115
115
  type: "unsupported_type",
116
- message: `O tipo (${o.type}) do arquivo ${o.name} não é suportado. `
117
- }), u || r.push({
118
- file: o,
116
+ message: `O tipo (${r.type}) do arquivo ${r.name} não é suportado. `
117
+ }), u || a.push({
118
+ file: r,
119
119
  type: "exceeded_file_size",
120
- message: `O tamanho do arquivo ${o.name} excedeu o limite permitido. `
121
- }), p && u;
120
+ message: `O tamanho do arquivo ${r.name} excedeu o limite permitido. `
121
+ }), i && u;
122
122
  });
123
- return r.length && (console.warn(r.map((o) => o.message).join(`
124
- `)), l("uploadError", r)), a;
125
- }, d = (t) => e.maxFileSize ? t.size < e.maxFileSize : !0, y = (t) => e.acceptTypes.length ? e.acceptTypes.map((a) => a.toLowerCase()).includes(t.type.toLowerCase()) : !0;
123
+ return a.length && (console.warn(a.map((r) => r.message).join(`
124
+ `)), l("uploadError", a)), o;
125
+ }, p = (t) => e.maxFileSize ? t.size < e.maxFileSize : !0, y = (t) => {
126
+ if (!e.acceptTypes.length && (!e.acceptTypesInput || e.acceptTypesInput === "*"))
127
+ return !0;
128
+ if (e.acceptTypes.length)
129
+ return e.acceptTypes.map(
130
+ (i) => i.toLowerCase()
131
+ ).includes(t.type.toLowerCase());
132
+ const a = t.name.split(".").pop();
133
+ return e.acceptTypesInput.split(",").some(
134
+ (r) => r.includes(a || "")
135
+ );
136
+ };
126
137
  return {
127
- handleDrop: c,
138
+ handleDrop: f,
128
139
  handleFileUpload: async (t) => {
129
- const r = t.target.files;
130
- if (!r)
140
+ const a = t.target.files;
141
+ if (!a)
131
142
  return;
132
- const a = n(Array.from(r));
133
- a.length && (s.value = a[0], l("updateFile", s.value));
143
+ const o = d(Array.from(a));
144
+ o.length && (n.value = o[0], l("updateFile", n.value));
134
145
  },
135
146
  handleRemove: () => {
136
- s.value = null, i.value = 0, l("updateFile", null), l("updateProgress", 0);
147
+ n.value = null, s.value = 0, l("updateFile", null), l("updateProgress", 0);
137
148
  },
138
149
  handleUpdateProgressOnParent: (t) => {
139
- i.value = t, l("updateProgress", i.value);
150
+ s.value = t, l("updateProgress", s.value);
140
151
  },
141
- getAcceptedFiles: n,
142
- isSizeAccepted: d,
143
- file: s,
144
- progress: i
152
+ getAcceptedFiles: d,
153
+ isSizeAccepted: p,
154
+ file: n,
155
+ progress: s
145
156
  };
146
157
  }
147
158
  });
148
159
  export {
149
- w as default
160
+ I as default
150
161
  };
@@ -1,5 +1,6 @@
1
- import { type PropType } from "vue";
2
- declare const _default: import("vue").DefineComponent<{
1
+ import { PropType } from 'vue';
2
+
3
+ declare const _default: import('vue').DefineComponent<{
3
4
  warningTextUpload: {
4
5
  type: StringConstructor;
5
6
  required: false;
@@ -97,7 +98,7 @@ declare const _default: import("vue").DefineComponent<{
97
98
  default: undefined;
98
99
  validator: (value: number) => boolean;
99
100
  };
100
- }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("updateProgress" | "updateFile" | "uploadError")[], "updateProgress" | "updateFile" | "uploadError", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
101
+ }, {}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, ("updateProgress" | "updateFile" | "uploadError")[], "updateProgress" | "updateFile" | "uploadError", import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, Readonly<import('vue').ExtractPropTypes<{
101
102
  warningTextUpload: {
102
103
  type: StringConstructor;
103
104
  required: false;
@@ -51,7 +51,7 @@ function m(e, t, $, g, v, c) {
51
51
  }, null, 8, ["complete-text", "loading-text", "progress-interval", "warning-text-upload", "multiple-select", "accept-types", "accept-types-input", "max-file-size", "interactive-text-button", "interactive-text-download-name", "interactive-texthref", "upload-progress", "warning-function", "upload-interaction-text", "upload-text"]))
52
52
  ]);
53
53
  }
54
- const y = /* @__PURE__ */ d(l, [["render", m], ["__scopeId", "data-v-fa633b73"]]);
54
+ const y = /* @__PURE__ */ d(l, [["render", m], ["__scopeId", "data-v-9a80204d"]]);
55
55
  export {
56
56
  y as default
57
57
  };
@@ -1,4 +1,4 @@
1
- declare const _default: import("vue").DefineComponent<{
1
+ declare const _default: import('vue').DefineComponent<{
2
2
  warningTextUpload: {
3
3
  type: StringConstructor;
4
4
  required: true;
@@ -28,7 +28,7 @@ declare const _default: import("vue").DefineComponent<{
28
28
  required: false;
29
29
  default: () => void;
30
30
  };
31
- }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
31
+ }, {}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, Readonly<import('vue').ExtractPropTypes<{
32
32
  warningTextUpload: {
33
33
  type: StringConstructor;
34
34
  required: true;
@@ -24,7 +24,7 @@ function g(e, t, h, w, x, _) {
24
24
  ])
25
25
  ]);
26
26
  }
27
- const y = /* @__PURE__ */ u(i, [["render", g], ["__scopeId", "data-v-342d92f9"]]);
27
+ const y = /* @__PURE__ */ u(i, [["render", g], ["__scopeId", "data-v-b8922f99"]]);
28
28
  export {
29
29
  y as default
30
30
  };
@@ -1,4 +1,4 @@
1
- declare const _default: import("vue").DefineComponent<{
1
+ declare const _default: import('vue').DefineComponent<{
2
2
  loadingText: {
3
3
  type: StringConstructor;
4
4
  required: false;
@@ -16,7 +16,7 @@ declare const _default: import("vue").DefineComponent<{
16
16
  required: true;
17
17
  validator: (value: number) => boolean;
18
18
  };
19
- }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("handleRemove" | "handleUpdateProgressOnParent")[], "handleRemove" | "handleUpdateProgressOnParent", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
19
+ }, {}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, ("handleRemove" | "handleUpdateProgressOnParent")[], "handleRemove" | "handleUpdateProgressOnParent", import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, Readonly<import('vue').ExtractPropTypes<{
20
20
  loadingText: {
21
21
  type: StringConstructor;
22
22
  required: false;
@@ -38,7 +38,7 @@ function f(o, g, u, h, x, $) {
38
38
  })
39
39
  ]));
40
40
  }
41
- const A = /* @__PURE__ */ d(c, [["render", f], ["__scopeId", "data-v-12db28eb"]]);
41
+ const A = /* @__PURE__ */ d(c, [["render", f], ["__scopeId", "data-v-4b6210a4"]]);
42
42
  export {
43
43
  A as default
44
44
  };
@@ -1,5 +1,6 @@
1
- import type { PropType } from "vue";
2
- declare const _default: import("vue").DefineComponent<{
1
+ import { PropType } from 'vue';
2
+
3
+ declare const _default: import('vue').DefineComponent<{
3
4
  uploadText: {
4
5
  type: StringConstructor;
5
6
  required: false;
@@ -35,9 +36,9 @@ declare const _default: import("vue").DefineComponent<{
35
36
  default: string;
36
37
  };
37
38
  }, {
38
- dropAreaElem: import("vue").Ref<HTMLDivElement | null | undefined>;
39
- dropAreaClasses: import("vue").Ref<string[]>;
40
- }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
39
+ dropAreaElem: import('vue').Ref<HTMLDivElement | null | undefined>;
40
+ dropAreaClasses: import('vue').Ref<string[]>;
41
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, Readonly<import('vue').ExtractPropTypes<{
41
42
  uploadText: {
42
43
  type: StringConstructor;
43
44
  required: false;
@@ -50,7 +50,7 @@ function I(t, e, b, C, D, _) {
50
50
  ])
51
51
  ], 34);
52
52
  }
53
- const z = /* @__PURE__ */ g(m, [["render", I], ["__scopeId", "data-v-040328b9"]]);
53
+ const z = /* @__PURE__ */ g(m, [["render", I], ["__scopeId", "data-v-746db2c1"]]);
54
54
  export {
55
55
  z as default
56
56
  };
@@ -1,4 +1,4 @@
1
- export { default as Upload } from "./Upload";
1
+ export { default as Upload } from './Upload';
2
2
  export interface IUploadError {
3
3
  file: File;
4
4
  type: TUploadErrorType;
package/dist/index.d.ts CHANGED
@@ -1,32 +1,33 @@
1
- export * from "./Accordion";
2
- export * from "./Avatar";
3
- export * from "./Button";
4
- export * from "./CardWithInsights";
5
- export * from "./Checkbox";
6
- export * from "./ColorPicker";
7
- export * from "./DataTable";
8
- export * from "./DatePicker";
9
- export * from "./Faq";
10
- export * from "./Faq/FaqItem";
11
- export * from "./Filter";
12
- export * from "./Illustration";
13
- export * from "./Input";
14
- export * from "./Legend";
15
- export * from "./List";
16
- export * from "./Loading";
17
- export * from "./Menu";
18
- export * from "./Modal";
19
- export * from "./Notifications";
20
- export * from "./ProgressBar";
21
- export * from "./RadioButton";
22
- export * from "./Search";
23
- export * from "./Select";
24
- export * from "./Skeleton";
25
- export * from "./Stepper";
26
- export * from "./TableConfig";
27
- export * from "./Tabs";
28
- export * from "./Tag";
29
- export * from "./Tipograph";
30
- export * from "./Toggle";
31
- export * from "./Tooltip";
32
- export * from "./Upload";
1
+ export * from './Accordion';
2
+ export * from './Avatar';
3
+ export * from './Button';
4
+ export * from './CardWithInsights';
5
+ export * from './Checkbox';
6
+ export * from './ColorPicker';
7
+ export * from './DataTable';
8
+ export * from './DatePicker';
9
+ export * from './Faq';
10
+ export * from './Faq/FaqItem';
11
+ export * from './Filter';
12
+ export * from './Illustration';
13
+ export * from './Input';
14
+ export * from './Legend';
15
+ export * from './List';
16
+ export * from './Loading';
17
+ export * from './Menu';
18
+ export * from './Modal';
19
+ export * from './Notifications';
20
+ export * from './Paginator';
21
+ export * from './ProgressBar';
22
+ export * from './RadioButton';
23
+ export * from './Search';
24
+ export * from './Select';
25
+ export * from './Skeleton';
26
+ export * from './Stepper';
27
+ export * from './TableConfig';
28
+ export * from './Tabs';
29
+ export * from './Tag';
30
+ export * from './Tipograph';
31
+ export * from './Toggle';
32
+ export * from './Tooltip';
33
+ export * from './Upload';
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { default as e } from "./Accordion/Accordion.vue.js";
2
- import { default as a } from "./Avatar/Avatar.vue.js";
2
+ import { default as r } from "./Avatar/Avatar.vue.js";
3
3
  import { default as l } from "./Button/Button.vue.js";
4
4
  import { default as s } from "./CardWithInsights/CardWithInsights.vue.js";
5
5
  import { default as m } from "./Checkbox/Checkbox.vue.js";
@@ -9,30 +9,31 @@ import { default as g } from "./DatePicker/DatePicker.vue.js";
9
9
  import { default as T } from "./Faq/Faq.vue.js";
10
10
  import { default as b } from "./Faq/FaqItem/FaqItem.vue.js";
11
11
  import { default as C } from "./Filter/components/Filter.vue.js";
12
- import { default as S } from "./Illustration/Illustration.vue.js";
13
- import { AtInput as F } from "./Input/index.js";
14
- import { default as P } from "./Legend/Legend.vue.js";
12
+ import { default as P } from "./Illustration/Illustration.vue.js";
13
+ import { AtInput as B } from "./Input/index.js";
14
+ import { default as L } from "./Legend/Legend.vue.js";
15
15
  import { default as D } from "./List/components/List.vue.js";
16
16
  import { default as v } from "./Loading/Loading.vue.js";
17
17
  import { default as R } from "./Menu/Menu.vue.js";
18
18
  import { default as W } from "./Modal/Modal.vue.js";
19
19
  import { default as w } from "./Notifications/Notifications.vue.js";
20
- import { default as z } from "./ProgressBar/ProgressBar.vue.js";
21
- import { default as G } from "./RadioButton/RadioButton.vue.js";
22
- import { default as J } from "./Search/Search.vue.js";
23
- import { AtSelect as O } from "./Select/index.js";
24
- import { default as V } from "./Skeleton/Skeleton.vue.js";
25
- import { default as Y } from "./Stepper/Stepper.vue.js";
26
- import { default as _ } from "./TableConfig/TableConfig.vue.js";
27
- import { default as tt } from "./Tabs/Tabs.vue.js";
28
- import { default as et } from "./Tag/Tag.vue.js";
29
- import { AtTipograph as at } from "./Tipograph/index.js";
30
- import { default as lt } from "./Toggle/Toggle.vue.js";
31
- import { default as st } from "./Tooltip/Tooltip.vue.js";
32
- import { default as mt } from "./Upload/Upload.vue.js";
20
+ import { default as z } from "./Paginator/Paginator.vue.js";
21
+ import { default as G } from "./ProgressBar/ProgressBar.vue.js";
22
+ import { default as J } from "./RadioButton/RadioButton.vue.js";
23
+ import { default as O } from "./Search/Search.vue.js";
24
+ import { AtSelect as V } from "./Select/index.js";
25
+ import { default as Y } from "./Skeleton/Skeleton.vue.js";
26
+ import { default as _ } from "./Stepper/Stepper.vue.js";
27
+ import { default as tt } from "./TableConfig/TableConfig.vue.js";
28
+ import { default as et } from "./Tabs/Tabs.vue.js";
29
+ import { default as rt } from "./Tag/Tag.vue.js";
30
+ import { AtTipograph as lt } from "./Tipograph/index.js";
31
+ import { default as st } from "./Toggle/Toggle.vue.js";
32
+ import { default as mt } from "./Tooltip/Tooltip.vue.js";
33
+ import { default as xt } from "./Upload/Upload.vue.js";
33
34
  export {
34
35
  e as AtAccordion,
35
- a as AtAvatar,
36
+ r as AtAvatar,
36
37
  l as AtButton,
37
38
  s as AtCardWithInsights,
38
39
  m as AtCheckbox,
@@ -40,27 +41,28 @@ export {
40
41
  g as AtDatePicker,
41
42
  b as AtFaqItem,
42
43
  C as AtFilter,
43
- S as AtIllustration,
44
- F as AtInput,
45
- P as AtLegend,
44
+ P as AtIllustration,
45
+ B as AtInput,
46
+ L as AtLegend,
46
47
  D as AtList,
47
48
  v as AtLoading,
48
49
  R as AtMenu,
49
50
  W as AtModal,
50
51
  w as AtNotifications,
51
- z as AtProgressBar,
52
- G as AtRadioButton,
53
- J as AtSearch,
54
- O as AtSelect,
55
- V as AtSkeleton,
56
- _ as AtTableConfig,
57
- tt as AtTabs,
58
- et as AtTag,
59
- at as AtTipograph,
60
- lt as AtToggle,
61
- st as AtTooltip,
52
+ z as AtPaginator,
53
+ G as AtProgressBar,
54
+ J as AtRadioButton,
55
+ O as AtSearch,
56
+ V as AtSelect,
57
+ Y as AtSkeleton,
58
+ tt as AtTableConfig,
59
+ et as AtTabs,
60
+ rt as AtTag,
61
+ lt as AtTipograph,
62
+ st as AtToggle,
63
+ mt as AtTooltip,
62
64
  x as ColorPicker,
63
65
  T as Faq,
64
- Y as Stepper,
65
- mt as Upload
66
+ _ as Stepper,
67
+ xt as Upload
66
68
  };