@volverjs/ui-vue 0.0.10-beta.21 → 0.0.10-beta.23

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 (67) hide show
  1. package/dist/components/VvAccordion/VvAccordion.es.js +1 -3
  2. package/dist/components/VvAccordion/VvAccordion.umd.js +1 -1
  3. package/dist/components/VvAccordionGroup/VvAccordionGroup.es.js +1 -6
  4. package/dist/components/VvAccordionGroup/VvAccordionGroup.umd.js +1 -1
  5. package/dist/components/VvAction/VvAction.es.js +1 -2
  6. package/dist/components/VvAction/VvAction.umd.js +1 -1
  7. package/dist/components/VvAlert/VvAlert.es.js +0 -7
  8. package/dist/components/VvAlert/VvAlert.umd.js +1 -1
  9. package/dist/components/VvAlertGroup/VvAlertGroup.es.js +0 -10
  10. package/dist/components/VvAlertGroup/VvAlertGroup.umd.js +1 -1
  11. package/dist/components/VvBadge/VvBadge.es.js +1 -2
  12. package/dist/components/VvBadge/VvBadge.umd.js +1 -1
  13. package/dist/components/VvBreadcrumb/VvBreadcrumb.es.js +1 -3
  14. package/dist/components/VvBreadcrumb/VvBreadcrumb.umd.js +1 -1
  15. package/dist/components/VvButton/VvButton.es.js +15 -33
  16. package/dist/components/VvButton/VvButton.umd.js +1 -1
  17. package/dist/components/VvButtonGroup/VvButtonGroup.es.js +1 -2
  18. package/dist/components/VvButtonGroup/VvButtonGroup.umd.js +1 -1
  19. package/dist/components/VvCard/VvCard.es.js +1 -5
  20. package/dist/components/VvCard/VvCard.umd.js +1 -1
  21. package/dist/components/VvCheckbox/VvCheckbox.es.js +1 -2
  22. package/dist/components/VvCheckbox/VvCheckbox.umd.js +1 -1
  23. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.es.js +2 -13
  24. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.umd.js +1 -1
  25. package/dist/components/VvCombobox/VvCombobox.es.js +15 -48
  26. package/dist/components/VvCombobox/VvCombobox.umd.js +1 -1
  27. package/dist/components/VvCombobox/VvCombobox.vue.d.ts +26 -26
  28. package/dist/components/VvCombobox/index.d.ts +8 -8
  29. package/dist/components/VvDialog/VvDialog.es.js +0 -3
  30. package/dist/components/VvDialog/VvDialog.umd.js +1 -1
  31. package/dist/components/VvDropdown/VvDropdown.vue.d.ts +29 -29
  32. package/dist/components/VvDropdown/index.d.ts +8 -8
  33. package/dist/components/VvDropdownAction/VvDropdownAction.es.js +1 -2
  34. package/dist/components/VvDropdownAction/VvDropdownAction.umd.js +1 -1
  35. package/dist/components/VvInputFile/VvInputFile.es.js +37 -34
  36. package/dist/components/VvInputFile/VvInputFile.umd.js +1 -1
  37. package/dist/components/VvInputFile/VvInputFile.vue.d.ts +43 -4
  38. package/dist/components/VvInputFile/index.d.ts +14 -2
  39. package/dist/components/VvInputText/VvInputText.es.js +0 -6
  40. package/dist/components/VvInputText/VvInputText.umd.js +1 -1
  41. package/dist/components/VvNav/VvNav.es.js +1 -2
  42. package/dist/components/VvNav/VvNav.umd.js +1 -1
  43. package/dist/components/VvNavItem/VvNavItem.es.js +1 -2
  44. package/dist/components/VvNavItem/VvNavItem.umd.js +1 -1
  45. package/dist/components/VvRadioGroup/VvRadioGroup.es.js +1 -13
  46. package/dist/components/VvRadioGroup/VvRadioGroup.umd.js +1 -1
  47. package/dist/components/VvSelect/VvSelect.es.js +0 -4
  48. package/dist/components/VvSelect/VvSelect.umd.js +1 -1
  49. package/dist/components/VvTab/VvTab.es.js +2 -7
  50. package/dist/components/VvTab/VvTab.umd.js +1 -1
  51. package/dist/components/VvTextarea/VvTextarea.es.js +0 -4
  52. package/dist/components/VvTextarea/VvTextarea.umd.js +1 -1
  53. package/dist/components/index.es.js +41 -114
  54. package/dist/components/index.umd.js +1 -1
  55. package/dist/icons.es.js +3 -3
  56. package/dist/icons.umd.js +1 -1
  57. package/dist/index.es.js +20 -12
  58. package/dist/index.umd.js +1 -1
  59. package/dist/props/index.d.ts +8 -14
  60. package/dist/resolvers/unplugin.es.js +20 -12
  61. package/dist/resolvers/unplugin.umd.js +1 -1
  62. package/package.json +31 -31
  63. package/src/assets/icons/detailed.json +1 -1
  64. package/src/assets/icons/normal.json +1 -1
  65. package/src/assets/icons/simple.json +1 -1
  66. package/src/components/VvInputFile/VvInputFile.vue +7 -1
  67. package/src/components/VvInputFile/index.ts +20 -2
@@ -166,6 +166,9 @@
166
166
  localModelValue.value = undefined
167
167
  return
168
168
  }
169
+ if (selectedFileIndex.value === index) {
170
+ selectedFileIndex.value = 0
171
+ }
169
172
  const toReturn = [...localModelValue.value]
170
173
  toReturn.splice(index, 1)
171
174
  localModelValue.value = toReturn
@@ -177,7 +180,9 @@
177
180
  if (files.value.length === 0) {
178
181
  return
179
182
  }
180
-
183
+ if (!files.value[selectedFileIndex.value]) {
184
+ return undefined
185
+ }
181
186
  if (files.value[selectedFileIndex.value] instanceof File) {
182
187
  const currentFile = files.value[selectedFileIndex.value] as File
183
188
  if (!PREVIEW_MIME_TYPES.includes(currentFile.type)) {
@@ -297,6 +302,7 @@
297
302
  "
298
303
  :multiple="isMultiple"
299
304
  :accept="accept"
305
+ :capture="capture"
300
306
  :name="name"
301
307
  @change="onChange"
302
308
  />
@@ -13,7 +13,9 @@ import {
13
13
  import { type VvIconProps, ACTION_ICONS } from '../VvIcon'
14
14
 
15
15
  export type VvInputFileEvents = {
16
- 'update:modelValue': [File | undefined]
16
+ 'update:modelValue': [
17
+ File | UploadedFile | (File | UploadedFile)[] | undefined,
18
+ ]
17
19
  }
18
20
 
19
21
  export const VvInputFileProps = {
@@ -30,7 +32,9 @@ export const VvInputFileProps = {
30
32
  * Input value
31
33
  */
32
34
  modelValue: {
33
- type: Object as PropType<File | (File | UploadedFile)[] | UploadedFile>,
35
+ type: Object as PropType<
36
+ File | UploadedFile | (File | UploadedFile)[] | undefined
37
+ >,
34
38
  required: true,
35
39
  },
36
40
  /**
@@ -53,6 +57,20 @@ export const VvInputFileProps = {
53
57
  * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#multiple
54
58
  */
55
59
  multiple: { type: Boolean, default: false },
60
+ /**
61
+ * Front or rear camera
62
+ * @see https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/capture
63
+ */
64
+ capture: {
65
+ type: String as PropType<'user' | 'environment'>,
66
+ default: undefined,
67
+ validation: (value?: string) => {
68
+ if (value === undefined) {
69
+ return true
70
+ }
71
+ return ['user', 'environment'].includes(value)
72
+ },
73
+ },
56
74
  /**
57
75
  * Max number of files
58
76
  */