sprintify-ui 0.0.15 → 0.0.17

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 (34) hide show
  1. package/dist/sprintify-ui.es.js +88 -66
  2. package/dist/style.css +1 -1
  3. package/dist/types/src/components/BaseAppDialogs.vue.d.ts +2 -68
  4. package/dist/types/src/components/BaseAppNotifications.vue.d.ts +1 -43
  5. package/dist/types/src/components/BaseAvatar.vue.d.ts +20 -104
  6. package/dist/types/src/components/BaseBoolean.vue.d.ts +7 -59
  7. package/dist/types/src/components/BaseBreadcrumbs.vue.d.ts +7 -59
  8. package/dist/types/src/components/BaseCharacterCounter.vue.d.ts +24 -118
  9. package/dist/types/src/components/BaseCounter.vue.d.ts +20 -104
  10. package/dist/types/src/components/BaseDataTableToggleColumns.vue.d.ts +236 -898
  11. package/dist/types/src/components/BaseDatePicker.vue.d.ts +32 -154
  12. package/dist/types/src/components/BaseDateSelect.vue.d.ts +28 -138
  13. package/dist/types/src/components/BaseInput.vue.d.ts +43 -191
  14. package/dist/types/src/components/BaseLoadingCover.vue.d.ts +46 -188
  15. package/dist/types/src/components/BaseMediaItem.vue.d.ts +13 -83
  16. package/dist/types/src/components/BaseMediaPreview.vue.d.ts +12 -82
  17. package/dist/types/src/components/BaseMenuItem.vue.d.ts +24 -120
  18. package/dist/types/src/components/BaseNavbarItemContent.vue.d.ts +20 -106
  19. package/dist/types/src/components/BasePagination.vue.d.ts +17 -99
  20. package/dist/types/src/components/BaseTextarea.vue.d.ts +40 -182
  21. package/dist/types/src/components/BaseTextareaAutoresize.vue.d.ts +32 -159
  22. package/dist/types/src/svg/BaseSpinnerSmall.vue.d.ts +1 -43
  23. package/package.json +4 -3
  24. package/src/components/BaseAppDialogs.vue +2 -4
  25. package/src/components/BaseBelongsTo.vue +8 -0
  26. package/src/components/BaseDataIterator.vue +4 -4
  27. package/src/components/BaseDataTable.vue +20 -11
  28. package/src/components/BaseHasMany.vue +8 -0
  29. package/src/components/BaseMediaItem.vue +2 -2
  30. package/src/components/BaseMediaLibrary.vue +12 -6
  31. package/src/components/BaseSideNavigationItem.vue +2 -2
  32. package/src/components/BaseTabItem.vue +2 -2
  33. package/src/components/BaseTable.vue +1 -1
  34. package/src/lang/fr.json +1 -1
@@ -1,160 +1,33 @@
1
- declare const _default: {
2
- new (...args: any[]): {
3
- $: import("vue").ComponentInternalInstance;
4
- $data: {};
5
- $props: Partial<{
6
- modelValue: string;
7
- placeholder: string;
8
- disabled: boolean;
9
- maxHeight: number;
10
- submitOnEnter: boolean;
11
- }> & Omit<Readonly<import("vue").ExtractPropTypes<{
12
- modelValue: {
13
- default: string;
14
- type: StringConstructor;
15
- };
16
- placeholder: {
17
- default: string;
18
- type: StringConstructor;
19
- };
20
- name: {
21
- required: true;
22
- type: StringConstructor;
23
- };
24
- maxHeight: {
25
- default: number;
26
- type: NumberConstructor;
27
- };
28
- /**
29
- * Setting this to true will trigger the 'submit' event while pressing Enter.
30
- * Users will be able to add a line break while pressing Shift + Enter.
31
- */
32
- submitOnEnter: {
33
- default: boolean;
34
- type: BooleanConstructor;
35
- };
36
- disabled: {
37
- default: boolean;
38
- type: BooleanConstructor;
39
- };
40
- }>> & {
41
- onFocus?: ((...args: any[]) => any) | undefined;
42
- onInput?: ((...args: any[]) => any) | undefined;
43
- onSubmit?: ((...args: any[]) => any) | undefined;
44
- "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
45
- } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, "modelValue" | "placeholder" | "disabled" | "maxHeight" | "submitOnEnter">;
46
- $attrs: {
47
- [x: string]: unknown;
48
- };
49
- $refs: {
50
- [x: string]: unknown;
51
- };
52
- $slots: Readonly<{
53
- [name: string]: import("vue").Slot | undefined;
54
- }>;
55
- $root: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null;
56
- $parent: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null;
57
- $emit: (event: "input" | "submit" | "update:modelValue" | "focus", ...args: any[]) => void;
58
- $el: any;
59
- $options: import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
60
- modelValue: {
61
- default: string;
62
- type: StringConstructor;
63
- };
64
- placeholder: {
65
- default: string;
66
- type: StringConstructor;
67
- };
68
- name: {
69
- required: true;
70
- type: StringConstructor;
71
- };
72
- maxHeight: {
73
- default: number;
74
- type: NumberConstructor;
75
- };
76
- /**
77
- * Setting this to true will trigger the 'submit' event while pressing Enter.
78
- * Users will be able to add a line break while pressing Shift + Enter.
79
- */
80
- submitOnEnter: {
81
- default: boolean;
82
- type: BooleanConstructor;
83
- };
84
- disabled: {
85
- default: boolean;
86
- type: BooleanConstructor;
87
- };
88
- }>> & {
89
- onFocus?: ((...args: any[]) => any) | undefined;
90
- onInput?: ((...args: any[]) => any) | undefined;
91
- onSubmit?: ((...args: any[]) => any) | undefined;
92
- "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
93
- }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input" | "submit" | "update:modelValue" | "focus")[], string, {
94
- modelValue: string;
95
- placeholder: string;
96
- disabled: boolean;
97
- maxHeight: number;
98
- submitOnEnter: boolean;
99
- }, {}, string> & {
100
- beforeCreate?: ((() => void) | (() => void)[]) | undefined;
101
- created?: ((() => void) | (() => void)[]) | undefined;
102
- beforeMount?: ((() => void) | (() => void)[]) | undefined;
103
- mounted?: ((() => void) | (() => void)[]) | undefined;
104
- beforeUpdate?: ((() => void) | (() => void)[]) | undefined;
105
- updated?: ((() => void) | (() => void)[]) | undefined;
106
- activated?: ((() => void) | (() => void)[]) | undefined;
107
- deactivated?: ((() => void) | (() => void)[]) | undefined;
108
- beforeDestroy?: ((() => void) | (() => void)[]) | undefined;
109
- beforeUnmount?: ((() => void) | (() => void)[]) | undefined;
110
- destroyed?: ((() => void) | (() => void)[]) | undefined;
111
- unmounted?: ((() => void) | (() => void)[]) | undefined;
112
- renderTracked?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
113
- renderTriggered?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
114
- errorCaptured?: (((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null, info: string) => boolean | void)[]) | undefined;
115
- };
116
- $forceUpdate: () => void;
117
- $nextTick: typeof import("vue").nextTick;
118
- $watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (args_0: R, args_1: R) => any : (...args: any) => any, options?: import("vue").WatchOptions<boolean> | undefined): import("vue").WatchStopHandle;
119
- } & Readonly<import("vue").ExtractPropTypes<{
120
- modelValue: {
121
- default: string;
122
- type: StringConstructor;
123
- };
124
- placeholder: {
125
- default: string;
126
- type: StringConstructor;
127
- };
128
- name: {
129
- required: true;
130
- type: StringConstructor;
131
- };
132
- maxHeight: {
133
- default: number;
134
- type: NumberConstructor;
135
- };
136
- /**
137
- * Setting this to true will trigger the 'submit' event while pressing Enter.
138
- * Users will be able to add a line break while pressing Shift + Enter.
139
- */
140
- submitOnEnter: {
141
- default: boolean;
142
- type: BooleanConstructor;
143
- };
144
- disabled: {
145
- default: boolean;
146
- type: BooleanConstructor;
147
- };
148
- }>> & {
149
- onFocus?: ((...args: any[]) => any) | undefined;
150
- onInput?: ((...args: any[]) => any) | undefined;
151
- onSubmit?: ((...args: any[]) => any) | undefined;
152
- "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
153
- } & import("vue").ShallowUnwrapRef<{}> & {} & import("vue").ComponentCustomProperties & {};
154
- __isFragment?: undefined;
155
- __isTeleport?: undefined;
156
- __isSuspense?: undefined;
157
- } & import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
1
+ declare const _default: import("vue").DefineComponent<{
2
+ modelValue: {
3
+ default: string;
4
+ type: StringConstructor;
5
+ };
6
+ placeholder: {
7
+ default: string;
8
+ type: StringConstructor;
9
+ };
10
+ name: {
11
+ required: true;
12
+ type: StringConstructor;
13
+ };
14
+ maxHeight: {
15
+ default: number;
16
+ type: NumberConstructor;
17
+ };
18
+ /**
19
+ * Setting this to true will trigger the 'submit' event while pressing Enter.
20
+ * Users will be able to add a line break while pressing Shift + Enter.
21
+ */
22
+ submitOnEnter: {
23
+ default: boolean;
24
+ type: BooleanConstructor;
25
+ };
26
+ disabled: {
27
+ default: boolean;
28
+ type: BooleanConstructor;
29
+ };
30
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input" | "submit" | "update:modelValue" | "focus")[], "input" | "submit" | "update:modelValue" | "focus", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
158
31
  modelValue: {
159
32
  default: string;
160
33
  type: StringConstructor;
@@ -188,11 +61,11 @@ declare const _default: {
188
61
  onInput?: ((...args: any[]) => any) | undefined;
189
62
  onSubmit?: ((...args: any[]) => any) | undefined;
190
63
  "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
191
- }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input" | "submit" | "update:modelValue" | "focus")[], "input" | "submit" | "update:modelValue" | "focus", {
64
+ }, {
192
65
  modelValue: string;
193
66
  placeholder: string;
194
67
  disabled: boolean;
195
68
  maxHeight: number;
196
69
  submitOnEnter: boolean;
197
- }, {}, string> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
70
+ }>;
198
71
  export default _default;
@@ -1,44 +1,2 @@
1
- declare const _default: {
2
- new (...args: any[]): {
3
- $: import("vue").ComponentInternalInstance;
4
- $data: {};
5
- $props: Partial<{}> & Omit<Readonly<import("vue").ExtractPropTypes<{}>> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, never>;
6
- $attrs: {
7
- [x: string]: unknown;
8
- };
9
- $refs: {
10
- [x: string]: unknown;
11
- };
12
- $slots: Readonly<{
13
- [name: string]: import("vue").Slot | undefined;
14
- }>;
15
- $root: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null;
16
- $parent: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null;
17
- $emit: (event: string, ...args: any[]) => void;
18
- $el: any;
19
- $options: import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string> & {
20
- beforeCreate?: ((() => void) | (() => void)[]) | undefined;
21
- created?: ((() => void) | (() => void)[]) | undefined;
22
- beforeMount?: ((() => void) | (() => void)[]) | undefined;
23
- mounted?: ((() => void) | (() => void)[]) | undefined;
24
- beforeUpdate?: ((() => void) | (() => void)[]) | undefined;
25
- updated?: ((() => void) | (() => void)[]) | undefined;
26
- activated?: ((() => void) | (() => void)[]) | undefined;
27
- deactivated?: ((() => void) | (() => void)[]) | undefined;
28
- beforeDestroy?: ((() => void) | (() => void)[]) | undefined;
29
- beforeUnmount?: ((() => void) | (() => void)[]) | undefined;
30
- destroyed?: ((() => void) | (() => void)[]) | undefined;
31
- unmounted?: ((() => void) | (() => void)[]) | undefined;
32
- renderTracked?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
33
- renderTriggered?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
34
- errorCaptured?: (((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string>, {}> | null, info: string) => boolean | void)[]) | undefined;
35
- };
36
- $forceUpdate: () => void;
37
- $nextTick: typeof import("vue").nextTick;
38
- $watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (args_0: R, args_1: R) => any : (...args: any) => any, options?: import("vue").WatchOptions<boolean> | undefined): import("vue").WatchStopHandle;
39
- } & Readonly<import("vue").ExtractPropTypes<{}>> & import("vue").ShallowUnwrapRef<{}> & {} & import("vue").ComponentCustomProperties & {};
40
- __isFragment?: undefined;
41
- __isTeleport?: undefined;
42
- __isSuspense?: undefined;
43
- } & import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
44
2
  export default _default;
package/package.json CHANGED
@@ -1,8 +1,9 @@
1
1
  {
2
2
  "name": "sprintify-ui",
3
- "version": "0.0.15",
3
+ "version": "0.0.17",
4
4
  "scripts": {
5
5
  "build": "rimraf dist && vue-tsc && vite build",
6
+ "build-fast": "rimraf dist && vite build",
6
7
  "docs:dev": "vitepress dev docs",
7
8
  "docs:build": "vitepress build docs",
8
9
  "docs:serve": "vitepress serve docs",
@@ -15,7 +16,7 @@
15
16
  "@tailwindcss/line-clamp": "^0.4.2",
16
17
  "@tailwindcss/typography": "^0.5.8",
17
18
  "@vueuse/core": "^9.0.0",
18
- "axios": "^1.0.0",
19
+ "axios": "^0.26.1",
19
20
  "lodash": "^4.17.21",
20
21
  "luxon": "^3.0.0",
21
22
  "pinia": "^2.0.0",
@@ -54,7 +55,7 @@
54
55
  "@vue/eslint-config-typescript": "^11.0.2",
55
56
  "@vueuse/core": "^9.5.0",
56
57
  "autoprefixer": "^10.4.13",
57
- "axios": "^1.1.3",
58
+ "axios": "^0.26.1",
58
59
  "babel-loader": "^8.3.0",
59
60
  "eslint": "^8.27.0",
60
61
  "eslint-config-prettier": "^8.5.0",
@@ -11,7 +11,7 @@
11
11
  >
12
12
  <div
13
13
  v-if="dialogs.length"
14
- class="z-dialogs fixed inset-0 h-full w-full bg-black bg-opacity-60"
14
+ class="fixed inset-0 z-dialogs h-full w-full bg-black bg-opacity-60"
15
15
  />
16
16
  </Transition>
17
17
 
@@ -29,7 +29,7 @@
29
29
  v-for="dialog in dialogs"
30
30
  :key="dialog.id"
31
31
  scroll-lock-target
32
- class="z-dialogs fixed inset-0 transform overflow-y-auto"
32
+ class="fixed inset-0 z-dialogs transform overflow-y-auto"
33
33
  >
34
34
  <div
35
35
  class="flex min-h-full items-end justify-center p-4 text-center sm:items-center sm:p-0"
@@ -68,8 +68,6 @@ import { disableScroll, enableScroll } from '@/utils/scrollPreventer';
68
68
  const dialogStore = useDialogsStore();
69
69
 
70
70
  const dialogs = computed(() => {
71
- console.log(dialogStore.dialogs);
72
-
73
71
  return dialogStore.dialogs;
74
72
  });
75
73
 
@@ -86,6 +86,14 @@ const emit = defineEmits(['update:modelValue']);
86
86
 
87
87
  const model = ref(props.currentModel);
88
88
 
89
+ watch(
90
+ () => props.currentModel,
91
+ (newValue, oldValue) => {
92
+ model.value = newValue;
93
+ },
94
+ { deep: true }
95
+ );
96
+
89
97
  watch(
90
98
  () => props.modelValue,
91
99
  (newValue, oldValue) => {
@@ -11,12 +11,12 @@
11
11
  :class="{ 'col-span-1': !mobileLayout, 'col-span-2': mobileLayout }"
12
12
  >
13
13
  <!-- Header -->
14
- <div class="flex mb-4 space-x-2 empty:mb-0">
14
+ <div class="mb-4 flex space-x-2 empty:mb-0">
15
15
  <!-- Search bar -->
16
16
  <div v-if="searchable" class="grow">
17
17
  <div class="relative h-11">
18
18
  <div
19
- class="flex pointer-events-none absolute top-0 left-0 h-full items-center justify-center pl-2.5"
19
+ class="pointer-events-none absolute top-0 left-0 flex h-full items-center justify-center pl-2.5"
20
20
  >
21
21
  <BaseIcon
22
22
  class="h-6 w-6 text-slate-400"
@@ -33,7 +33,7 @@
33
33
  />
34
34
  <div
35
35
  v-if="searchQuery"
36
- class="flex absolute top-0 right-0 h-full items-center justify-center p-1"
36
+ class="absolute top-0 right-0 flex h-full items-center justify-center p-1"
37
37
  >
38
38
  <button
39
39
  type="button"
@@ -55,7 +55,7 @@
55
55
  <!-- Filters (mobile) -->
56
56
  <button
57
57
  v-if="mobileLayout && hasFilters"
58
- class="flex btn h-11 items-center justify-center py-1 text-base shadow-sm"
58
+ class="btn flex h-11 items-center justify-center py-1 text-base shadow-sm"
59
59
  type="button"
60
60
  @click="showFilters = true"
61
61
  >
@@ -405,19 +405,28 @@ const onDelete = (row: CollectionItem) => {
405
405
  return;
406
406
  }
407
407
 
408
- http.delete(props.deleteUrl(row)).then((response) => {
409
- if (response.data && response.data.message) {
408
+ http
409
+ .delete(props.deleteUrl(row))
410
+ .then((response) => {
411
+ if (response.data && response.data.message) {
412
+ notifications.push({
413
+ title: i18n.t('sui.success'),
414
+ text: response.data.message,
415
+ color: 'success',
416
+ });
417
+ }
418
+ emit('delete', row);
419
+
420
+ // Refetch even if URL is the same
421
+ fetch();
422
+ })
423
+ .catch((error) => {
410
424
  notifications.push({
411
- title: i18n.t('sui.success'),
412
- text: response.data.message,
413
- color: 'success',
425
+ title: i18n.t('sui.error'),
426
+ text: error.response.data?.message ?? 'Unknown error',
427
+ color: 'danger',
414
428
  });
415
- }
416
- emit('delete', row);
417
-
418
- // Refetch even if URL is the same
419
- fetch();
420
- });
429
+ });
421
430
  };
422
431
 
423
432
  /*
@@ -82,6 +82,14 @@ const emit = defineEmits(['update:modelValue']);
82
82
 
83
83
  const models = ref(props.currentModels);
84
84
 
85
+ watch(
86
+ () => props.currentModels,
87
+ (newValue, oldValue) => {
88
+ models.value = newValue;
89
+ },
90
+ { deep: true }
91
+ );
92
+
85
93
  function onUpdate(newModels: Option[]) {
86
94
  models.value = newModels;
87
95
  emit(
@@ -23,7 +23,7 @@
23
23
  <button
24
24
  type="button"
25
25
  class="rounded-full bg-slate-400 p-1 text-white hover:bg-slate-500"
26
- @click="$emit('delete')"
26
+ @click="$emit('remove')"
27
27
  >
28
28
  <BaseIcon icon="heroicons:x-mark-20-solid" class="h-4 w-4"></BaseIcon>
29
29
  </button>
@@ -40,7 +40,7 @@ import { fileSizeFormat } from '@/utils';
40
40
  import BaseMediaPreview from './BaseMediaPreview.vue';
41
41
  import { BaseIcon } from '.';
42
42
 
43
- defineEmits(['delete']);
43
+ defineEmits(['remove']);
44
44
 
45
45
  const props = defineProps({
46
46
  media: {
@@ -25,13 +25,13 @@
25
25
  baseFileUploaderProps.dragging ? 'bg-blue-100' : 'bg-slate-100',
26
26
  baseFileUploaderProps.disabled
27
27
  ? 'cursor-not-allowed border-slate-300'
28
- : 'border-slate-400 hover:bg-slate-50',
28
+ : 'border-slate-300 hover:bg-slate-50',
29
29
  ]"
30
30
  >
31
31
  <div :class="[baseFileUploaderProps.disabled ? 'opacity-30' : '']">
32
32
  <BaseIcon
33
33
  icon="heroicons:arrow-up-on-square"
34
- class="mx-auto mb-3 h-6 w-6 text-slate-500"
34
+ class="mx-auto mb-3 h-6 w-6 text-primary-500"
35
35
  />
36
36
  <div class="text-center">
37
37
  <p class="mb-0 text-sm font-medium leading-tight">
@@ -57,24 +57,30 @@
57
57
  v-if="currentMediaInternal.length + normalizedModelValue.to_add.length"
58
58
  class="mt-5"
59
59
  >
60
- <div class="grid gap-2 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4">
61
- <div v-for="(media, index) in currentMediaInternal" :key="media.id">
60
+ <div class="-m-1 flex flex-wrap">
61
+ <div
62
+ v-for="(media, index) in currentMediaInternal"
63
+ :key="media.id"
64
+ class="min-w-[220px] flex-1 p-1"
65
+ >
62
66
  <BaseMediaItem
63
67
  :media="media"
64
68
  :show-remove="!disabled"
65
- @delete="promptRemoveMedia(index)"
69
+ @remove="promptRemoveMedia(index)"
66
70
  >
67
71
  {{ media.file_name }}
68
72
  </BaseMediaItem>
69
73
  </div>
74
+
70
75
  <div
71
76
  v-for="(file, index) in normalizedModelValue.to_add"
72
77
  :key="file.id"
78
+ class="min-w-[220px] flex-1 p-1"
73
79
  >
74
80
  <BaseMediaItem
75
81
  :media="file"
76
82
  :show-remove="!disabled"
77
- @delete="promptRemoveUploadedFile(index)"
83
+ @remove="promptRemoveUploadedFile(index)"
78
84
  >
79
85
  {{ file.file_name }}
80
86
  </BaseMediaItem>
@@ -10,7 +10,7 @@
10
10
  class="group relative flex items-center px-3 py-1"
11
11
  :class="[
12
12
  (activeStrategy == 'default' ? isActive : isExactActive)
13
- ? 'font-semibold text-blue-600'
13
+ ? 'font-semibold text-primary-600'
14
14
  : 'text-slate-600 hover:text-slate-900',
15
15
  disabled ? 'cursor-not-allowed opacity-60' : '',
16
16
  ]"
@@ -20,7 +20,7 @@
20
20
  class="absolute left-0 top-0 h-full"
21
21
  :class="[
22
22
  (activeStrategy == 'default' ? isActive : isExactActive)
23
- ? 'w-[2px] bg-blue-600'
23
+ ? 'w-[2px] bg-primary-600'
24
24
  : 'group-hover:w-px group-hover:bg-slate-700',
25
25
  ]"
26
26
  ></div>
@@ -10,7 +10,7 @@
10
10
  class="group relative inline-block rounded-t-lg px-2 py-3 font-medium"
11
11
  :class="[
12
12
  (activeStrategy == 'default' ? isActive : isExactActive)
13
- ? 'text-blue-600'
13
+ ? 'text-primary-600'
14
14
  : 'text-slate-600 hover:text-slate-900',
15
15
  disabled ? 'cursor-not-allowed opacity-60' : '',
16
16
  ]"
@@ -20,7 +20,7 @@
20
20
  class="absolute left-0 bottom-0 w-full"
21
21
  :class="[
22
22
  (activeStrategy == 'default' ? isActive : isExactActive)
23
- ? 'h-[2px] bg-blue-600'
23
+ ? 'h-[2px] bg-primary-600'
24
24
  : 'group-hover:h-px group-hover:bg-slate-700',
25
25
  ]"
26
26
  ></div>
@@ -10,7 +10,7 @@
10
10
  :style="{ maxHeight: maxHeight ? maxHeight + 'px' : undefined }"
11
11
  >
12
12
  <div class="inline-block min-w-full align-middle">
13
- <div class="relative">
13
+ <div class="relative min-h-[300px]">
14
14
  <table class="min-w-full border-separate border-spacing-0">
15
15
  <thead v-if="newColumns.length" ref="thead">
16
16
  <tr>
package/src/lang/fr.json CHANGED
@@ -50,7 +50,7 @@
50
50
  "upload_failed": "Le téléchargement a échoué",
51
51
  "whoops": "Oups",
52
52
  "x_rows_selected": "1 item sélectionné | \n{count} items sélectionnés",
53
- "year": "An",
53
+ "year": "Année",
54
54
  "yes_delete": "Oui, supprimer",
55
55
  "you_can_upload_up_to_n_files": "Vous pouvez télécharger un fichier au maximum|Vous pouvez télécharger jusqu'à {count} fichiers",
56
56
  "you_cannot_select_more_than_x_items": "Vous ne pouvez pas sélectionner plus de un élément|Vous ne pouvez pas sélectionner plus de {count} éléments"