quasar-ui-danx 0.0.11 → 0.0.13

Sign up to get free protection for your applications and to get access to all the features.
Files changed (84) hide show
  1. package/dist/index.css +5 -0
  2. package/dist/index.min.css +5 -0
  3. package/dist/index.rtl.css +5 -0
  4. package/dist/index.rtl.min.css +5 -0
  5. package/package.json +6 -1
  6. package/src/components/ActionTable/ActionTable.vue +49 -41
  7. package/src/components/ActionTable/BatchActionMenu.vue +20 -20
  8. package/src/components/ActionTable/EmptyTableState.vue +5 -5
  9. package/src/components/ActionTable/Filters/CollapsableFiltersSidebar.vue +11 -11
  10. package/src/components/ActionTable/Filters/FilterGroupItem.vue +7 -7
  11. package/src/components/ActionTable/Filters/FilterGroupList.vue +29 -29
  12. package/src/components/ActionTable/Filters/FilterListToggle.vue +15 -15
  13. package/src/components/ActionTable/Filters/FilterableField.vue +82 -80
  14. package/src/components/ActionTable/Filters/index.ts +5 -0
  15. package/src/components/ActionTable/Form/Fields/BooleanField.vue +13 -13
  16. package/src/components/ActionTable/Form/Fields/ConfirmPasswordField.vue +11 -11
  17. package/src/components/ActionTable/Form/Fields/DateField.vue +13 -13
  18. package/src/components/ActionTable/Form/Fields/DateRangeField.vue +25 -25
  19. package/src/components/ActionTable/Form/Fields/DateTimeField.vue +21 -21
  20. package/src/components/ActionTable/Form/Fields/DateTimePicker.vue +23 -23
  21. package/src/components/ActionTable/Form/Fields/FileUploadButton.vue +31 -31
  22. package/src/components/ActionTable/Form/Fields/InlineDateTimeField.vue +19 -19
  23. package/src/components/ActionTable/Form/Fields/IntegerField.vue +7 -7
  24. package/src/components/ActionTable/Form/Fields/LabelValueBlock.vue +22 -0
  25. package/src/components/ActionTable/Form/Fields/LabeledInput.vue +19 -19
  26. package/src/components/ActionTable/Form/Fields/MultiFileField.vue +40 -40
  27. package/src/components/ActionTable/Form/Fields/MultiKeywordField.vue +23 -23
  28. package/src/components/ActionTable/Form/Fields/NewPasswordField.vue +10 -10
  29. package/src/components/ActionTable/Form/Fields/NumberField.vue +29 -29
  30. package/src/components/ActionTable/Form/Fields/NumberRangeField.vue +33 -33
  31. package/src/components/ActionTable/Form/Fields/SelectDrawer.vue +36 -36
  32. package/src/components/ActionTable/Form/Fields/SelectField.vue +66 -66
  33. package/src/components/ActionTable/Form/Fields/SelectWithChildrenField.vue +23 -23
  34. package/src/components/ActionTable/Form/Fields/SingleFileField.vue +32 -32
  35. package/src/components/ActionTable/Form/Fields/TextField.vue +36 -36
  36. package/src/components/ActionTable/Form/Fields/WysiwygField.vue +16 -16
  37. package/src/components/ActionTable/Form/Fields/index.ts +23 -23
  38. package/src/components/ActionTable/Form/RenderedForm.vue +27 -25
  39. package/src/components/ActionTable/Form/index.ts +2 -0
  40. package/src/components/ActionTable/TableSummaryRow.vue +33 -33
  41. package/src/components/ActionTable/index.ts +8 -13
  42. package/src/components/ActionTable/listActions.ts +340 -339
  43. package/src/components/ActionTable/listHelpers.ts +74 -0
  44. package/src/components/ActionTable/tableColumns.ts +56 -56
  45. package/src/components/DragAndDrop/HandleDraggable.vue +29 -29
  46. package/src/components/DragAndDrop/ListItemDraggable.vue +10 -10
  47. package/src/components/DragAndDrop/index.ts +0 -1
  48. package/src/components/DragAndDrop/listDragAndDrop.ts +1 -1
  49. package/src/components/Utility/CollapsableSidebar.vue +35 -35
  50. package/src/components/Utility/ContentDrawer.vue +20 -20
  51. package/src/components/Utility/Dialogs/ConfirmDialog.vue +55 -55
  52. package/src/components/Utility/Dialogs/FullScreenDialog.vue +18 -18
  53. package/src/components/Utility/Dialogs/FullscreenCarouselDialog.vue +105 -0
  54. package/src/components/Utility/Dialogs/InfoDialog.vue +10 -10
  55. package/src/components/Utility/Dialogs/InputDialog.vue +13 -13
  56. package/src/components/Utility/ImagePreview.vue +192 -0
  57. package/src/components/Utility/Popover/PopoverMenu.vue +64 -0
  58. package/src/components/Utility/Transitions/StaggeredListTransition.vue +15 -15
  59. package/src/components/Utility/index.ts +11 -9
  60. package/src/components/index.ts +1 -1
  61. package/src/helpers/FileUpload.ts +274 -273
  62. package/src/helpers/compatibility.ts +45 -45
  63. package/src/helpers/date.ts +2 -2
  64. package/src/helpers/download.ts +166 -158
  65. package/src/helpers/downloadPdf.ts +48 -48
  66. package/src/helpers/files.ts +42 -42
  67. package/src/helpers/index.ts +2 -0
  68. package/src/helpers/multiFileUpload.ts +56 -56
  69. package/src/helpers/singleFileUpload.ts +49 -49
  70. package/src/index.esm.js +3 -4
  71. package/src/svg/FilterIcon.svg +7 -0
  72. package/src/svg/ImageIcon.svg +30 -0
  73. package/src/svg/PdfIcon.svg +21 -0
  74. package/src/svg/PercentIcon.svg +13 -0
  75. package/src/svg/TrashIcon.svg +15 -0
  76. package/src/svg/XIcon.svg +18 -0
  77. package/src/svg/index.ts +8 -0
  78. package/src/vendor/tinymce-config.ts +1 -0
  79. package/src/vue-plugin.js +7 -4
  80. package/tsconfig.json +18 -14
  81. package/src/components/ActionTable/tableHelpers.ts +0 -83
  82. package/src/components/DragAndDrop/Icons/index.ts +0 -2
  83. /package/src/{components/DragAndDrop/Icons → svg}/DragHandleDotsIcon.svg +0 -0
  84. /package/src/{components/DragAndDrop/Icons → svg}/DragHandleIcon.svg +0 -0
@@ -1,68 +1,68 @@
1
- import { FileUpload, FileUploadOptions } from "danx/src/helpers/FileUpload";
1
+ import { FileUpload, FileUploadOptions } from "@ui/helpers/FileUpload";
2
2
  import { ref } from "vue";
3
3
 
4
4
  export function useMultiFileUpload(options: FileUploadOptions) {
5
- const uploadedFiles = ref([]);
6
- const onCompleteCb = ref(null);
7
- const onFilesChangeCb = ref(null);
8
- const onFilesSelected = (e) => {
9
- uploadedFiles.value = [...uploadedFiles.value, ...e.target.files];
10
- new FileUpload(e.target.files, options)
11
- .onProgress(({ file }) => {
12
- updateFileInList(file);
13
- })
14
- .onComplete(({ file, uploadedFile }) => {
15
- updateFileInList(file, uploadedFile);
16
- })
17
- .onAllComplete(() => {
18
- onCompleteCb.value && onCompleteCb.value();
19
- onFilesChangeCb.value && onFilesChangeCb.value(uploadedFiles.value);
20
- })
21
- .upload();
22
- };
5
+ const uploadedFiles = ref([]);
6
+ const onCompleteCb = ref(null);
7
+ const onFilesChangeCb = ref(null);
8
+ const onFilesSelected = (e) => {
9
+ uploadedFiles.value = [...uploadedFiles.value, ...e.target.files];
10
+ new FileUpload(e.target.files, options)
11
+ .onProgress(({ file }) => {
12
+ updateFileInList(file);
13
+ })
14
+ .onComplete(({ file, uploadedFile }) => {
15
+ updateFileInList(file, uploadedFile);
16
+ })
17
+ .onAllComplete(() => {
18
+ onCompleteCb.value && onCompleteCb.value();
19
+ onFilesChangeCb.value && onFilesChangeCb.value(uploadedFiles.value);
20
+ })
21
+ .upload();
22
+ };
23
23
 
24
- function updateFileInList(file, replace = null) {
25
- const index = uploadedFiles.value.findIndex(f => f.id === file.id);
26
- if (index !== -1) {
27
- uploadedFiles.value.splice(index, 1, replace || file);
24
+ function updateFileInList(file, replace = null) {
25
+ const index = uploadedFiles.value.findIndex(f => f.id === file.id);
26
+ if (index !== -1) {
27
+ uploadedFiles.value.splice(index, 1, replace || file);
28
+ }
29
+ onFilesChangeCb.value && onFilesChangeCb.value(uploadedFiles.value);
28
30
  }
29
- onFilesChangeCb.value && onFilesChangeCb.value(uploadedFiles.value);
30
- }
31
31
 
32
- const onDrop = (e) => {
33
- onFilesSelected({ target: { files: e.dataTransfer.files } });
34
- };
32
+ const onDrop = (e) => {
33
+ onFilesSelected({ target: { files: e.dataTransfer.files } });
34
+ };
35
35
 
36
- const onFilesChange = (cb) => {
37
- onFilesChangeCb.value = cb;
38
- };
36
+ const onFilesChange = (cb) => {
37
+ onFilesChangeCb.value = cb;
38
+ };
39
39
 
40
- const onComplete = (cb) => {
41
- onCompleteCb.value = cb;
42
- };
40
+ const onComplete = (cb) => {
41
+ onCompleteCb.value = cb;
42
+ };
43
43
 
44
- const onClear = () => {
45
- uploadedFiles.value = [];
46
- onFilesChangeCb.value && onFilesChangeCb.value(uploadedFiles.value);
47
- onCompleteCb.value && onCompleteCb.value();
48
- };
44
+ const onClear = () => {
45
+ uploadedFiles.value = [];
46
+ onFilesChangeCb.value && onFilesChangeCb.value(uploadedFiles.value);
47
+ onCompleteCb.value && onCompleteCb.value();
48
+ };
49
49
 
50
- const onRemove = (file) => {
51
- const index = uploadedFiles.value.findIndex(f => f.id === file.id);
52
- if (index !== -1) {
53
- uploadedFiles.value.splice(index, 1);
54
- }
55
- onFilesChangeCb.value && onFilesChangeCb.value(uploadedFiles.value);
56
- onCompleteCb.value && onCompleteCb.value();
57
- };
50
+ const onRemove = (file) => {
51
+ const index = uploadedFiles.value.findIndex(f => f.id === file.id);
52
+ if (index !== -1) {
53
+ uploadedFiles.value.splice(index, 1);
54
+ }
55
+ onFilesChangeCb.value && onFilesChangeCb.value(uploadedFiles.value);
56
+ onCompleteCb.value && onCompleteCb.value();
57
+ };
58
58
 
59
- return {
60
- onClear,
61
- onRemove,
62
- onComplete,
63
- onFilesChange,
64
- onDrop,
65
- onFilesSelected,
66
- uploadedFiles
67
- };
59
+ return {
60
+ onClear,
61
+ onRemove,
62
+ onComplete,
63
+ onFilesChange,
64
+ onDrop,
65
+ onFilesSelected,
66
+ uploadedFiles
67
+ };
68
68
  }
@@ -1,54 +1,54 @@
1
- import { FileUpload, FileUploadOptions } from "danx/src/helpers";
1
+ import { FileUpload, FileUploadOptions } from "@ui/helpers";
2
2
  import { computed, ref } from "vue";
3
3
 
4
4
  export function useSingleFileUpload(options: FileUploadOptions) {
5
- const uploadedFile = ref(null);
6
- const onCompleteCb = ref(null);
7
- const onFileChangeCb = ref(null);
8
-
9
- const onFileSelected = (e) => {
10
- uploadedFile.value = null;
11
- new FileUpload(e.target.files[0], options)
12
- .onProgress(({ file }) => {
13
- uploadedFile.value = file;
5
+ const uploadedFile = ref(null);
6
+ const onCompleteCb = ref(null);
7
+ const onFileChangeCb = ref(null);
8
+
9
+ const onFileSelected = (e) => {
10
+ uploadedFile.value = null;
11
+ new FileUpload(e.target.files[0], options)
12
+ .onProgress(({ file }) => {
13
+ uploadedFile.value = file;
14
+ onFileChangeCb.value && onFileChangeCb.value(uploadedFile.value);
15
+ })
16
+ .onComplete(({ uploadedFile: completedFile }) => {
17
+ uploadedFile.value = completedFile;
18
+ onCompleteCb.value && onCompleteCb.value(uploadedFile.value);
19
+ onFileChangeCb.value && onFileChangeCb.value(uploadedFile.value);
20
+ })
21
+ .upload();
22
+ };
23
+
24
+ const onDrop = (e) => {
25
+ onFileSelected({ target: { files: e.dataTransfer.files } });
26
+ };
27
+
28
+ const isFileUploaded = computed(() => {
29
+ return uploadedFile.value && uploadedFile.value.url;
30
+ });
31
+
32
+ const onFileChange = (cb) => {
33
+ onFileChangeCb.value = cb;
34
+ };
35
+
36
+ const onComplete = (cb) => {
37
+ onCompleteCb.value = cb;
38
+ };
39
+
40
+ const onClear = () => {
41
+ uploadedFile.value = null;
14
42
  onFileChangeCb.value && onFileChangeCb.value(uploadedFile.value);
15
- })
16
- .onComplete(({ uploadedFile: completedFile }) => {
17
- uploadedFile.value = completedFile;
18
- onCompleteCb.value && onCompleteCb.value(uploadedFile.value);
19
- onFileChangeCb.value && onFileChangeCb.value(uploadedFile.value);
20
- })
21
- .upload();
22
- };
23
-
24
- const onDrop = (e) => {
25
- onFileSelected({ target: { files: e.dataTransfer.files } });
26
- };
27
-
28
- const isFileUploaded = computed(() => {
29
- return uploadedFile.value && uploadedFile.value.url;
30
- });
31
-
32
- const onFileChange = (cb) => {
33
- onFileChangeCb.value = cb;
34
- };
35
-
36
- const onComplete = (cb) => {
37
- onCompleteCb.value = cb;
38
- };
39
-
40
- const onClear = () => {
41
- uploadedFile.value = null;
42
- onFileChangeCb.value && onFileChangeCb.value(uploadedFile.value);
43
- };
44
-
45
- return {
46
- isFileUploaded,
47
- onClear,
48
- onComplete,
49
- onFileChange,
50
- onDrop,
51
- onFileSelected,
52
- uploadedFile
53
- };
43
+ };
44
+
45
+ return {
46
+ isFileUploaded,
47
+ onClear,
48
+ onComplete,
49
+ onFileChange,
50
+ onDrop,
51
+ onFileSelected,
52
+ uploadedFile
53
+ };
54
54
  }
package/src/index.esm.js CHANGED
@@ -1,5 +1,4 @@
1
+ import * as VuePlugin from './vue-plugin';
1
2
 
2
- import * as VuePlugin from './vue-plugin'
3
-
4
- export * from './vue-plugin'
5
- export default VuePlugin
3
+ export * from './vue-plugin';
4
+ export default VuePlugin;
@@ -0,0 +1,7 @@
1
+ <svg viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <g>
3
+ <path
4
+ d="M9.16667 17.5V12.5H10.8333V14.1667H17.5V15.8333H10.8333V17.5H9.16667ZM2.5 15.8333V14.1667H7.5V15.8333H2.5ZM5.83333 12.5V10.8333H2.5V9.16667H5.83333V7.5H7.5V12.5H5.83333ZM9.16667 10.8333V9.16667H17.5V10.8333H9.16667ZM12.5 7.5V2.5H14.1667V4.16667H17.5V5.83333H14.1667V7.5H12.5ZM2.5 5.83333V4.16667H10.8333V5.83333H2.5Z"
5
+ fill="currentColor"/>
6
+ </g>
7
+ </svg>
@@ -0,0 +1,30 @@
1
+ <svg
2
+ viewBox="0 0 20 20"
3
+ fill="none"
4
+ xmlns="http://www.w3.org/2000/svg"
5
+ >
6
+ <path
7
+ fill-rule="evenodd"
8
+ clip-rule="evenodd"
9
+ d="M17.8587 18.5578C18.2529 18.5578 18.5725 18.2383 18.5725 17.8441L18.5725 2.1414C18.5725 1.7472 18.2529 1.42764 17.8587 1.42764L2.15604 1.42764C1.76184 1.42764 1.44228 1.7472 1.44228 2.1414L1.44228 17.8441C1.44228 18.2383 1.76184 18.5578 2.15604 18.5578L17.8587 18.5578ZM20 17.8441C20 19.0267 19.0413 19.9854 17.8587 19.9854L2.15604 19.9854C0.97345 19.9854 0.014769 19.0267 0.014769 17.8441L0.014769 2.1414C0.014769 0.958801 0.97345 0.00012055 2.15604 0.00012055L17.8587 0.00012055C19.0413 0.00012055 20 0.958801 20 2.1414L20 17.8441Z"
10
+ fill="currentColor"
11
+ />
12
+ <path
13
+ fill-rule="evenodd"
14
+ clip-rule="evenodd"
15
+ d="M13.2048 4.99588C12.2193 4.99588 11.4204 5.79478 11.4204 6.78027C11.4204 7.76577 12.2193 8.56467 13.2048 8.56467C14.1903 8.56467 14.9892 7.76577 14.9892 6.78027C14.9892 5.79478 14.1903 4.99588 13.2048 4.99588ZM9.99292 6.78027C9.99292 5.00638 11.4309 3.56836 13.2048 3.56836C14.9787 3.56836 16.4167 5.00638 16.4167 6.78027C16.4167 8.55416 14.9787 9.99218 13.2048 9.99218C11.4309 9.99218 9.99292 8.55416 9.99292 6.78027Z"
16
+ fill="currentColor"
17
+ />
18
+ <path
19
+ fill-rule="evenodd"
20
+ clip-rule="evenodd"
21
+ d="M2.84806 9.9929C5.50442 9.93497 8.09526 10.8216 10.1592 12.4951C12.2256 14.1705 13.6294 16.5256 14.1203 19.1401C14.193 19.5275 13.9379 19.9005 13.5505 19.9733C13.1631 20.046 12.79 19.7909 12.7173 19.4035C12.2889 17.1216 11.0636 15.0662 9.26019 13.6039C7.45676 12.1417 5.19246 11.3678 2.8713 11.4203C2.86529 11.4204 2.85927 11.4205 2.85326 11.4204C2.18034 11.4186 1.50881 11.4813 0.847849 11.6076C0.460656 11.6816 0.0867981 11.4277 0.0128145 11.0405C-0.0611691 10.6533 0.192737 10.2794 0.57993 10.2055C1.3275 10.0626 2.08698 9.99144 2.84806 9.9929Z"
22
+ fill="currentColor"
23
+ />
24
+ <path
25
+ fill-rule="evenodd"
26
+ clip-rule="evenodd"
27
+ d="M10.9536 13.8192C12.4542 13.1749 14.0708 12.8443 15.7039 12.8477C16.9949 12.8471 18.2773 13.0574 19.5005 13.4705C19.8739 13.5966 20.0745 14.0016 19.9483 14.3751C19.8222 14.7486 19.4172 14.9491 19.0437 14.823C17.9677 14.4596 16.8395 14.2746 15.7037 14.2752L15.7018 14.2752C14.263 14.2721 12.8388 14.5633 11.5168 15.1309C11.1546 15.2864 10.7348 15.1189 10.5793 14.7567C10.4238 14.3944 10.5914 13.9747 10.9536 13.8192Z"
28
+ fill="currentColor"
29
+ />
30
+ </svg>
@@ -0,0 +1,21 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 550.801 550.801">
2
+ <g>
3
+ <path d="M160.381,282.225c0-14.832-10.299-23.684-28.474-23.684c-7.414,0-12.437,0.715-15.071,1.432V307.6
4
+ c3.114,0.707,6.942,0.949,12.192,0.949C148.419,308.549,160.381,298.74,160.381,282.225z"/>
5
+ <path d="M272.875,259.019c-8.145,0-13.397,0.717-16.519,1.435v105.523c3.116,0.729,8.142,0.729,12.69,0.729
6
+ c33.017,0.231,54.554-17.946,54.554-56.474C323.842,276.719,304.215,259.019,272.875,259.019z"/>
7
+ <path d="M488.426,197.019H475.2v-63.816c0-0.398-0.063-0.799-0.116-1.202c-0.021-2.534-0.827-5.023-2.562-6.995L366.325,3.694
8
+ c-0.032-0.031-0.063-0.042-0.085-0.076c-0.633-0.707-1.371-1.295-2.151-1.804c-0.231-0.155-0.464-0.285-0.706-0.419
9
+ c-0.676-0.369-1.393-0.675-2.131-0.896c-0.2-0.056-0.38-0.138-0.58-0.19C359.87,0.119,359.037,0,358.193,0H97.2
10
+ c-11.918,0-21.6,9.693-21.6,21.601v175.413H62.377c-17.049,0-30.873,13.818-30.873,30.873v160.545
11
+ c0,17.043,13.824,30.87,30.873,30.87h13.224V529.2c0,11.907,9.682,21.601,21.6,21.601h356.4c11.907,0,21.6-9.693,21.6-21.601
12
+ V419.302h13.226c17.044,0,30.871-13.827,30.871-30.87v-160.54C519.297,210.838,505.47,197.019,488.426,197.019z M97.2,21.605
13
+ h250.193v110.513c0,5.967,4.841,10.8,10.8,10.8h95.407v54.108H97.2V21.605z M362.359,309.023c0,30.876-11.243,52.165-26.82,65.333
14
+ c-16.971,14.117-42.82,20.814-74.396,20.814c-18.9,0-32.297-1.197-41.401-2.389V234.365c13.399-2.149,30.878-3.346,49.304-3.346
15
+ c30.612,0,50.478,5.508,66.039,17.226C351.828,260.69,362.359,280.547,362.359,309.023z M80.7,393.499V234.365
16
+ c11.241-1.904,27.042-3.346,49.296-3.346c22.491,0,38.527,4.308,49.291,12.928c10.292,8.131,17.215,21.534,17.215,37.328
17
+ c0,15.799-5.25,29.198-14.829,38.285c-12.442,11.728-30.865,16.996-52.407,16.996c-4.778,0-9.1-0.243-12.435-0.723v57.67H80.7
18
+ V393.499z M453.601,523.353H97.2V419.302h356.4V523.353z M484.898,262.127h-61.989v36.851h57.913v29.674h-57.913v64.848h-36.593
19
+ V232.216h98.582V262.127z"/>
20
+ </g>
21
+ </svg>
@@ -0,0 +1,13 @@
1
+ <svg fill="currentColor" xmlns="http://www.w3.org/2000/svg"
2
+ viewBox="0 0 394.4 394.4" xml:space="preserve"
3
+ >
4
+ <g>
5
+ <path d="M37.4,377.4c-5.223,0-10.438-1.992-14.423-5.977c-7.97-7.963-7.97-20.883,0-28.846l319.6-319.601
6
+ c7.97-7.97,20.876-7.97,28.846,0c7.97,7.962,7.97,20.882,0,28.845l-319.6,319.601C47.838,375.408,42.623,377.4,37.4,377.4z
7
+ M394.4,299.199c0-52.496-42.704-95.199-95.2-95.199S204,246.703,204,299.199s42.704,95.201,95.2,95.201
8
+ S394.4,351.695,394.4,299.199z M353.601,299.199c0,29.996-24.405,54.4-54.4,54.4s-54.4-24.404-54.4-54.4
9
+ c0-29.994,24.405-54.398,54.4-54.398S353.601,269.205,353.601,299.199z M190.4,95.2C190.4,42.704,147.696,0,95.2,0S0,42.704,0,95.2
10
+ s42.704,95.2,95.2,95.2S190.4,147.696,190.4,95.2z M149.6,95.2c0,29.995-24.405,54.4-54.4,54.4s-54.4-24.405-54.4-54.4
11
+ s24.405-54.4,54.4-54.4S149.6,65.206,149.6,95.2z"/>
12
+ </g>
13
+ </svg>
@@ -0,0 +1,15 @@
1
+ <svg
2
+ width="18"
3
+ height="20"
4
+ viewBox="0 0 16 18"
5
+ fill="none"
6
+ xmlns="http://www.w3.org/2000/svg"
7
+ >
8
+ <path
9
+ d="M13.8333 4.83333L13.1108 14.9517C13.0808 15.3722 12.8927 15.7657 12.5842 16.053C12.2757 16.3403 11.8698 16.5 11.4483 16.5H4.55159C4.13004 16.5 3.72414 16.3403 3.41566 16.053C3.10717 15.7657 2.91902 15.3722 2.88909 14.9517L2.16659 4.83333M6.33325 8.16667V13.1667M9.66659 8.16667V13.1667M10.4999 4.83333V2.33333C10.4999 2.11232 10.4121 1.90036 10.2558 1.74408C10.0996 1.5878 9.8876 1.5 9.66659 1.5H6.33325C6.11224 1.5 5.90028 1.5878 5.744 1.74408C5.58772 1.90036 5.49992 2.11232 5.49992 2.33333V4.83333M1.33325 4.83333H14.6666"
10
+ stroke="currentColor"
11
+ stroke-width="2"
12
+ stroke-linecap="round"
13
+ stroke-linejoin="round"
14
+ />
15
+ </svg>
@@ -0,0 +1,18 @@
1
+ <svg
2
+ viewBox="0 0 17 17"
3
+ fill="none"
4
+ xmlns="http://www.w3.org/2000/svg"
5
+ >
6
+ <path
7
+ fill-rule="evenodd"
8
+ clip-rule="evenodd"
9
+ d="M16.8222 0.177828C17.0593 0.414932 17.0593 0.799354 16.8222 1.03646L1.03646 16.8222C0.799354 17.0593 0.414932 17.0593 0.177828 16.8222C-0.059276 16.5851 -0.059276 16.2006 0.177828 15.9635L15.9635 0.177828C16.2006 -0.059276 16.5851 -0.059276 16.8222 0.177828Z"
10
+ fill="currentColor"
11
+ />
12
+ <path
13
+ fill-rule="evenodd"
14
+ clip-rule="evenodd"
15
+ d="M0.177828 0.177828C0.414932 -0.059276 0.799354 -0.059276 1.03646 0.177828L16.8222 15.9635C17.0593 16.2006 17.0593 16.5851 16.8222 16.8222C16.5851 17.0593 16.2006 17.0593 15.9635 16.8222L0.177828 1.03646C-0.059276 0.799354 -0.059276 0.414932 0.177828 0.177828Z"
16
+ fill="currentColor"
17
+ />
18
+ </svg>
@@ -0,0 +1,8 @@
1
+ export { default as DragHandleDotsIcon } from "./DragHandleDotsIcon.svg";
2
+ export { default as DragHandleIcon } from "./DragHandleIcon.svg";
3
+ export { default as FilterIcon } from "./FilterIcon.svg";
4
+ export { default as ImageIcon } from "./ImageIcon.svg";
5
+ export { default as PdfIcon } from "./PdfIcon.svg";
6
+ export { default as PercentIcon } from "./PercentIcon.svg";
7
+ export { default as TrashIcon } from "./TrashIcon.svg";
8
+ export { default as XIcon } from "./XIcon.svg";
@@ -0,0 +1 @@
1
+ export const apiKey = "YOUR_API_KEY";
package/src/vue-plugin.js CHANGED
@@ -1,7 +1,10 @@
1
- export * from "./helpers";
2
- export * from "./components/DragAndDrop";
1
+ export * from './helpers';
2
+ export * from './components/DragAndDrop';
3
+ export * from './components/ActionTable';
4
+ export * from './components/Utility';
5
+ // export * from './components';
3
6
 
4
- import packageJson from "../package.json";
7
+ import packageJson from '../package.json';
5
8
 
6
9
  const { version } = packageJson;
7
10
 
@@ -11,5 +14,5 @@ function install(app) {
11
14
 
12
15
  export {
13
16
  version,
14
- install,
17
+ install
15
18
  };
package/tsconfig.json CHANGED
@@ -1,30 +1,34 @@
1
1
  {
2
2
  "compilerOptions": {
3
- "target": "es5",
3
+ "outDir": "./dist",
4
+ "declaration": true,
4
5
  // Specify ECMAScript target version
5
- "module": "esnext",
6
+ "target": "esnext",
6
7
  // Specify module code generation
7
- "strict": false,
8
+ "module": "esnext",
8
9
  // Enable all strict type-checking options
9
- "esModuleInterop": true,
10
+ "strict": false,
10
11
  // Enables compatibility with Babel-imported CommonJS modules
11
- "moduleResolution": "node",
12
+ "esModuleInterop": true,
12
13
  // Resolve modules using Node.js style
13
- "allowSyntheticDefaultImports": true,
14
+ "moduleResolution": "node",
14
15
  // Allow default imports from modules with no default export
15
- "experimentalDecorators": true,
16
+ "allowSyntheticDefaultImports": true,
16
17
  // Enables experimental support for decorators
17
- "skipLibCheck": true,
18
+ "experimentalDecorators": true,
18
19
  // Skip type checking of all declaration files (*.d.ts)
19
- "forceConsistentCasingInFileNames": true,
20
+ "skipLibCheck": true,
20
21
  // Disallow inconsistently-cased references to the same file.
22
+ "forceConsistentCasingInFileNames": true,
23
+ // Base directory to resolve non-relative module names,
21
24
  "baseUrl": "./",
22
- // Base directory to resolve non-relative module names
23
25
  "paths": {
24
26
  "@/*": [
25
- "src/*"
27
+ "./dev/src/*"
28
+ ],
29
+ "@ui/*": [
30
+ "./src/*"
26
31
  ]
27
- // Path alias to resolve imports (adjust as needed)
28
32
  }
29
33
  },
30
34
  "include": [
@@ -34,7 +38,7 @@
34
38
  "types/**/*.d.ts"
35
39
  ],
36
40
  "exclude": [
37
- "node_modules"
38
- // Exclude the node_modules directory
41
+ "node_modules",
42
+ "dist"
39
43
  ]
40
44
  }
@@ -1,83 +0,0 @@
1
- import { onMounted, watch } from "vue";
2
-
3
- export function registerStickyScrolling(tableRef) {
4
- onMounted(() => {
5
- const scrollEl = tableRef.value.$el.getElementsByClassName("q-table__middle")[0];
6
- scrollEl.addEventListener("scroll", onScroll);
7
-
8
- function onScroll({ target }) {
9
- // Add / remove scroll y class based on whether we're scrolling vertically
10
- if (target.scrollTop > 0) {
11
- scrollEl.classList.add("is-scrolling-y");
12
- } else {
13
- scrollEl.classList.remove("is-scrolling-y");
14
- }
15
-
16
- // Add / remove scroll x class based on whether we're scrolling horizontally
17
- if (target.scrollLeft > 0) {
18
- scrollEl.classList.add("is-scrolling-x");
19
- } else {
20
- scrollEl.classList.remove("is-scrolling-x");
21
- }
22
- }
23
- });
24
- }
25
-
26
- export function mapSortBy(pagination, columns) {
27
- if (!pagination.sortBy) return null;
28
-
29
- const column = columns.find(c => c.name === pagination.sortBy);
30
- return [
31
- {
32
- column: column.sortBy || column.name,
33
- expression: column.sortByExpression || undefined,
34
- order: pagination.descending ? "desc" : "asc"
35
- }
36
- ];
37
- }
38
-
39
- /**
40
- * Wait for a ref to have a value and then resolve the promise
41
- *
42
- * @param ref
43
- * @param value
44
- * @returns {Promise<unknown>}
45
- */
46
- export function waitForRef(ref, value) {
47
- return new Promise((resolve) => {
48
- watch(ref, (newValue) => {
49
- if (newValue === value) {
50
- resolve();
51
- }
52
- });
53
- });
54
- }
55
-
56
- /**
57
- * Returns the value of the URL parameter (if it is set)
58
- * @param key
59
- * @param url
60
- */
61
- export function getUrlParam(key, url = undefined) {
62
- const params = new URLSearchParams(url?.replace(/.*\?/, "") || window.location.search);
63
- return params.get(key);
64
- }
65
-
66
- /**
67
- * Returns the filter from the URL if it is set
68
- * @param url
69
- * @param allowedKeys
70
- */
71
- export function getFilterFromUrl(url, allowedKeys = null) {
72
- const filter = {};
73
- const urlFilter = getUrlParam("filter", url);
74
- if (urlFilter) {
75
- const fields = JSON.parse(urlFilter);
76
- Object.keys(fields).forEach((key) => {
77
- if (!allowedKeys || allowedKeys.includes(key)) {
78
- filter[key] = fields[key];
79
- }
80
- });
81
- }
82
- return filter;
83
- }
@@ -1,2 +0,0 @@
1
- export * as HandleDraggableIcon from "./DragHandleIcon.svg";
2
- export * as HandleDraggableDotsIcon from "./DragHandleDotsIcon.svg";