@leaflink/stash 50.2.1 → 50.4.0
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.
- package/assets/icons/camera.svg +1 -0
- package/assets/icons/home.svg +1 -0
- package/assets/spritesheet.svg +1 -1
- package/dist/Accordion.vue.d.ts +2 -2
- package/dist/AppNavigationItem.vue.d.ts +1 -1
- package/dist/Icon.js +2 -0
- package/dist/Icon.js.map +1 -1
- package/dist/Icon.vue.d.ts +1 -1
- package/dist/IconLabel.vue.d.ts +1 -1
- package/dist/ListView.vue.d.ts +6 -6
- package/dist/QuickAction.vue.d.ts +1 -1
- package/dist/SelectStatus.vue.d.ts +1 -1
- package/dist/TextEditor.vue.d.ts +1 -1
- package/dist/Tooltip.js +36 -157
- package/dist/Tooltip.js.map +1 -1
- package/dist/index-Ck3Dl09q.js +128 -0
- package/dist/index-Ck3Dl09q.js.map +1 -0
- package/dist/useSortable.d.ts +94 -0
- package/dist/useSortable.js +116 -0
- package/dist/useSortable.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Move sortable elements in the list
|
|
5
|
+
* @param list List of sortable elements
|
|
6
|
+
* @param from Original element position
|
|
7
|
+
* @param to New element position
|
|
8
|
+
*/
|
|
9
|
+
export declare function moveSortableElements<ListItem>({ list, from, to }: MoveSortableElementsOptions<ListItem>): void;
|
|
10
|
+
|
|
11
|
+
export declare interface MoveSortableElementsOptions<T> {
|
|
12
|
+
list: RefOrGetter<T[]>;
|
|
13
|
+
from: number;
|
|
14
|
+
to: number;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* Like the MaybeRefOrGetter type from Vue, but without the Maybe. Can be used to ensure the most up-to-date value is available.
|
|
19
|
+
*/
|
|
20
|
+
declare type RefOrGetter<T> = Ref<T> | (() => T);
|
|
21
|
+
|
|
22
|
+
export declare interface SortableDragEvent extends DragEvent {
|
|
23
|
+
/**
|
|
24
|
+
* The old index of the dragged element
|
|
25
|
+
*/
|
|
26
|
+
oldIndex: number;
|
|
27
|
+
/**
|
|
28
|
+
* The new index of the dragged element
|
|
29
|
+
*/
|
|
30
|
+
newIndex: number;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export declare type SortableOnDragEndEvent = SortableDragEvent;
|
|
34
|
+
|
|
35
|
+
export declare type SortableOnDragStartEvent = Omit<SortableDragEvent, 'newIndex'>;
|
|
36
|
+
|
|
37
|
+
declare function useSortable<SortableItem>({ isEnabled, sortInPlace, ...options }: UseSortableOptions<SortableItem>): UseSortableReturn;
|
|
38
|
+
export default useSortable;
|
|
39
|
+
|
|
40
|
+
export declare interface UseSortableOptions<SortableItem> {
|
|
41
|
+
/**
|
|
42
|
+
* The parent element of the sortable elements
|
|
43
|
+
*/
|
|
44
|
+
ref: Ref<HTMLElement | null>;
|
|
45
|
+
/**
|
|
46
|
+
* The list of sortable elements to be sorted
|
|
47
|
+
*/
|
|
48
|
+
list: Ref<SortableItem[]>;
|
|
49
|
+
/**
|
|
50
|
+
* Enables/Disables drag and drop sorting
|
|
51
|
+
* @default true
|
|
52
|
+
*/
|
|
53
|
+
isEnabled?: boolean;
|
|
54
|
+
/**
|
|
55
|
+
* Class name for the ghost element
|
|
56
|
+
* @default ''
|
|
57
|
+
*/
|
|
58
|
+
ghostClass?: string;
|
|
59
|
+
/**
|
|
60
|
+
* Class name for the chosen element
|
|
61
|
+
* @default ''
|
|
62
|
+
*/
|
|
63
|
+
chosenClass?: string;
|
|
64
|
+
/**
|
|
65
|
+
* Sort the list in place
|
|
66
|
+
* @default true
|
|
67
|
+
*/
|
|
68
|
+
sortInPlace?: boolean;
|
|
69
|
+
/**
|
|
70
|
+
* Callback when the dragging starts
|
|
71
|
+
*/
|
|
72
|
+
onDragStart?: (e: SortableOnDragStartEvent) => void;
|
|
73
|
+
/**
|
|
74
|
+
* Callback when the dragging ends
|
|
75
|
+
*/
|
|
76
|
+
onDragEnd?: (e: SortableOnDragEndEvent) => void;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export declare interface UseSortableReturn {
|
|
80
|
+
/**
|
|
81
|
+
* Whether the element is currently being dragged
|
|
82
|
+
*/
|
|
83
|
+
isDragging: Ref<boolean>;
|
|
84
|
+
/**
|
|
85
|
+
* The new position of the dragged element
|
|
86
|
+
*/
|
|
87
|
+
newIndex: Ref<number>;
|
|
88
|
+
/**
|
|
89
|
+
* The original position of the dragged element
|
|
90
|
+
*/
|
|
91
|
+
oldIndex: Ref<number>;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export { }
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import v from "@leaflink/snitch";
|
|
2
|
+
import { a as I } from "./index-Ck3Dl09q.js";
|
|
3
|
+
import { isRef as w, toValue as D, nextTick as A, computed as i, ref as y, watch as S, onMounted as $, onBeforeUnmount as G } from "vue";
|
|
4
|
+
function O({ list: n, from: s, to: e }) {
|
|
5
|
+
if (s === e) return;
|
|
6
|
+
const r = w(n), a = r ? [...D(n)] : D(n);
|
|
7
|
+
if (e >= 0 && e < a.length) {
|
|
8
|
+
const u = a.splice(s, 1)[0];
|
|
9
|
+
A(() => {
|
|
10
|
+
a.splice(e, 0, u), r && (n.value = a);
|
|
11
|
+
});
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
function B(n, s) {
|
|
15
|
+
var a;
|
|
16
|
+
const e = c(n.target).cloneNode(!0);
|
|
17
|
+
e.classList.add(...s), e.style.position = "absolute", e.style.top = "-9999px", e.style.listStyle = "none", e.setAttribute("data-test", `${e.dataset.test}|ghost`), e.removeAttribute("draggable"), document.body.appendChild(e), (a = n.dataTransfer) == null || a.setDragImage(e, e.offsetWidth / 2, e.offsetHeight / 2);
|
|
18
|
+
function r() {
|
|
19
|
+
requestAnimationFrame(() => {
|
|
20
|
+
document.body.removeChild(e);
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
return {
|
|
24
|
+
ghost: e,
|
|
25
|
+
cleanupGhostElement: r
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
function c(n) {
|
|
29
|
+
const s = n == null ? void 0 : n.closest("[draggable=true]");
|
|
30
|
+
if (!s) throw new Error("Draggable element not found");
|
|
31
|
+
return s;
|
|
32
|
+
}
|
|
33
|
+
function q({
|
|
34
|
+
isEnabled: n = !0,
|
|
35
|
+
sortInPlace: s = !0,
|
|
36
|
+
...e
|
|
37
|
+
}) {
|
|
38
|
+
const r = i(() => I(e.ref)), a = y(-1), u = y(-1), b = i(() => a.value !== -1), T = i(() => {
|
|
39
|
+
var t;
|
|
40
|
+
return ((t = e.ghostClass) == null ? void 0 : t.split(" ")) || [];
|
|
41
|
+
}), f = i(() => {
|
|
42
|
+
var t;
|
|
43
|
+
return ((t = e.chosenClass) == null ? void 0 : t.split(" ")) || [];
|
|
44
|
+
}), g = (t) => {
|
|
45
|
+
var l;
|
|
46
|
+
if (!(!t.dataTransfer || !r.value)) {
|
|
47
|
+
t.dataTransfer.setData("text/plain", ""), t.dataTransfer.effectAllowed = "move";
|
|
48
|
+
try {
|
|
49
|
+
const o = c(t.target), d = Array.from(r.value.children).indexOf(o);
|
|
50
|
+
if (d === -1) return;
|
|
51
|
+
const { cleanupGhostElement: C } = B(t, T.value);
|
|
52
|
+
u.value = a.value = d, o.classList.add(...f.value), C(), (l = e.onDragStart) == null || l.call(e, { ...t, oldIndex: d });
|
|
53
|
+
} catch (o) {
|
|
54
|
+
v.error(`Error in drag start: ${o}`);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}, m = (t) => {
|
|
58
|
+
if (!(!t.dataTransfer || !r.value)) {
|
|
59
|
+
t.dataTransfer.dropEffect = "move";
|
|
60
|
+
try {
|
|
61
|
+
const l = c(t.target), o = Array.from(r.value.children).indexOf(l);
|
|
62
|
+
if (o === -1 || o === a.value) return;
|
|
63
|
+
const d = r.value.children[a.value];
|
|
64
|
+
r.value.insertBefore(d, o < a.value ? l : l.nextSibling), a.value = o;
|
|
65
|
+
} catch (l) {
|
|
66
|
+
v.error(`Error in drag enter: ${l}`);
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
function h(t) {
|
|
71
|
+
t.preventDefault();
|
|
72
|
+
}
|
|
73
|
+
function E(t) {
|
|
74
|
+
if (t.preventDefault(), !!r.value)
|
|
75
|
+
try {
|
|
76
|
+
if (u.value === a.value || !s) return;
|
|
77
|
+
O({ list: e.list, from: u.value, to: a.value });
|
|
78
|
+
} catch (l) {
|
|
79
|
+
v.error(`Error in drag drop: ${l}`);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
function L(t) {
|
|
83
|
+
var l;
|
|
84
|
+
try {
|
|
85
|
+
c(t.target).classList.remove(...f.value), (l = e.onDragEnd) == null || l.call(e, {
|
|
86
|
+
...t,
|
|
87
|
+
oldIndex: u.value,
|
|
88
|
+
newIndex: a.value
|
|
89
|
+
}), u.value = a.value = -1;
|
|
90
|
+
} catch (o) {
|
|
91
|
+
v.error(`Error in drag end: ${o}`);
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
S(
|
|
95
|
+
() => n,
|
|
96
|
+
() => n ? p() : x()
|
|
97
|
+
);
|
|
98
|
+
function p() {
|
|
99
|
+
r.value && (r.value.addEventListener("dragstart", g), r.value.addEventListener("dragend", L), r.value.addEventListener("dragenter", m), r.value.addEventListener("dragover", h), r.value.addEventListener("drop", E));
|
|
100
|
+
}
|
|
101
|
+
function x() {
|
|
102
|
+
r.value && (r.value.removeEventListener("dragstart", g), r.value.removeEventListener("dragend", L), r.value.removeEventListener("dragenter", m), r.value.removeEventListener("dragover", h), r.value.removeEventListener("drop", E));
|
|
103
|
+
}
|
|
104
|
+
return $(() => {
|
|
105
|
+
n && p();
|
|
106
|
+
}), G(x), {
|
|
107
|
+
isDragging: b,
|
|
108
|
+
oldIndex: u,
|
|
109
|
+
newIndex: a
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
export {
|
|
113
|
+
q as default,
|
|
114
|
+
O as moveSortableElements
|
|
115
|
+
};
|
|
116
|
+
//# sourceMappingURL=useSortable.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useSortable.js","sources":["../src/composables/useSortable/useSortable.utils.ts","../src/composables/useSortable/useSortable.ts"],"sourcesContent":["import { isRef, nextTick, Ref, toValue } from 'vue';\n\nimport { MoveSortableElementsOptions } from './useSortable.types';\n\n/**\n * Move sortable elements in the list\n * @param list List of sortable elements\n * @param from Original element position\n * @param to New element position\n */\nexport function moveSortableElements<ListItem>({ list, from, to }: MoveSortableElementsOptions<ListItem>): void {\n if (from === to) return;\n\n const _listIsRef = isRef(list);\n // When the list is a ref, make a shallow copy of it to avoid repeatedly triggering side effects when moving elements\n const listCopy = _listIsRef ? [...toValue(list)] : toValue(list);\n\n if (to >= 0 && to < listCopy.length) {\n const element = listCopy.splice(from, 1)[0];\n nextTick(() => {\n listCopy.splice(to, 0, element);\n // When list is ref, assign listCopy to list.value\n if (_listIsRef) (list as Ref).value = listCopy;\n });\n }\n}\n\n/**\n * Create a ghost element for dragging, which is the element that follows the cursor while dragging\n * @param e Drag event\n * @param ghostClass Custom classes to be added to the ghost element\n * @returns Ghost element and cleanup function\n */\nexport function createGhostElement(e: DragEvent, ghostClass: string[]) {\n const ghost = getValidDragTarget(e.target as HTMLElement).cloneNode(true) as HTMLElement;\n\n ghost.classList.add(...ghostClass);\n\n ghost.style.position = 'absolute';\n ghost.style.top = '-9999px';\n ghost.style.listStyle = 'none';\n ghost.setAttribute('data-test', `${ghost.dataset.test}|ghost`);\n ghost.removeAttribute('draggable');\n\n document.body.appendChild(ghost);\n\n e.dataTransfer?.setDragImage(ghost, ghost.offsetWidth / 2, ghost.offsetHeight / 2);\n\n function cleanupGhostElement() {\n requestAnimationFrame(() => {\n document.body.removeChild(ghost);\n });\n }\n\n return {\n ghost,\n cleanupGhostElement,\n };\n}\n\n/**\n * Get the valid draggable target element\n * @param element\n * @returns Draggable element\n */\nexport function getValidDragTarget(element: HTMLElement | null) {\n const dragElement = element?.closest<HTMLElement>('[draggable=true]');\n if (!dragElement) throw new Error('Draggable element not found');\n return dragElement;\n}\n","import logger from '@leaflink/snitch';\nimport { unrefElement } from '@vueuse/core';\nimport { computed, onBeforeUnmount, onMounted, ref, watch } from 'vue';\n\nimport type { UseSortableOptions, UseSortableReturn } from './useSortable.types';\nimport { createGhostElement, getValidDragTarget, moveSortableElements } from './useSortable.utils';\n\nexport * from './useSortable.types';\nexport { moveSortableElements } from './useSortable.utils';\n\nexport default function useSortable<SortableItem>({\n isEnabled = true,\n sortInPlace = true,\n ...options\n}: UseSortableOptions<SortableItem>): UseSortableReturn {\n const parentEl = computed(() => unrefElement(options.ref));\n\n const newIndex = ref(-1);\n const oldIndex = ref(-1);\n\n const isDragging = computed(() => newIndex.value !== -1);\n\n const ghostClasses = computed(() => options.ghostClass?.split(' ') || []);\n const chosenClasses = computed(() => options.chosenClass?.split(' ') || []);\n\n const handleDragStart = (e: DragEvent) => {\n if (!e.dataTransfer || !parentEl.value) return;\n e.dataTransfer.setData('text/plain', ''); // Required for Firefox\n e.dataTransfer.effectAllowed = 'move';\n\n try {\n const target = getValidDragTarget(e.target as HTMLElement);\n\n const index = Array.from(parentEl.value.children).indexOf(target);\n if (index === -1) return;\n\n const { cleanupGhostElement } = createGhostElement(e, ghostClasses.value);\n\n oldIndex.value = newIndex.value = index;\n\n target.classList.add(...chosenClasses.value);\n\n cleanupGhostElement();\n\n options.onDragStart?.({ ...e, oldIndex: index });\n } catch (error) {\n logger.error(`Error in drag start: ${error}`);\n }\n };\n\n const handleDragEnter = (e: DragEvent) => {\n if (!e.dataTransfer || !parentEl.value) return;\n e.dataTransfer.dropEffect = 'move';\n\n try {\n const target = getValidDragTarget(e.target as HTMLElement);\n\n const index = Array.from(parentEl.value.children).indexOf(target);\n if (index === -1 || index === newIndex.value) return;\n\n const draggedEl = parentEl.value.children[newIndex.value];\n parentEl.value.insertBefore(draggedEl, index < newIndex.value ? target : target.nextSibling);\n\n newIndex.value = index;\n } catch (error) {\n logger.error(`Error in drag enter: ${error}`);\n }\n };\n\n function handleDragOver(e: DragEvent) {\n e.preventDefault(); // Required to allow dropping\n }\n\n function handleDrop(e: DragEvent) {\n e.preventDefault();\n\n if (!parentEl.value) return;\n\n try {\n if (oldIndex.value === newIndex.value || !sortInPlace) return;\n moveSortableElements({ list: options.list, from: oldIndex.value, to: newIndex.value });\n } catch (error) {\n logger.error(`Error in drag drop: ${error}`);\n }\n }\n\n function handleDragEnd(e: DragEvent) {\n try {\n const target = getValidDragTarget(e.target as HTMLElement);\n\n target.classList.remove(...chosenClasses.value);\n\n options.onDragEnd?.({\n ...e,\n oldIndex: oldIndex.value,\n newIndex: newIndex.value,\n });\n\n oldIndex.value = newIndex.value = -1;\n } catch (error) {\n logger.error(`Error in drag end: ${error}`);\n }\n }\n\n watch(\n () => isEnabled,\n () => (isEnabled ? setupListeners() : removeListeners()),\n );\n\n function setupListeners() {\n if (!parentEl.value) return;\n\n parentEl.value.addEventListener('dragstart', handleDragStart);\n parentEl.value.addEventListener('dragend', handleDragEnd);\n parentEl.value.addEventListener('dragenter', handleDragEnter);\n parentEl.value.addEventListener('dragover', handleDragOver);\n parentEl.value.addEventListener('drop', handleDrop);\n }\n\n function removeListeners() {\n if (!parentEl.value) return;\n\n parentEl.value.removeEventListener('dragstart', handleDragStart);\n parentEl.value.removeEventListener('dragend', handleDragEnd);\n parentEl.value.removeEventListener('dragenter', handleDragEnter);\n parentEl.value.removeEventListener('dragover', handleDragOver);\n parentEl.value.removeEventListener('drop', handleDrop);\n }\n\n onMounted(() => {\n if (!isEnabled) return;\n setupListeners();\n });\n\n onBeforeUnmount(removeListeners);\n\n return {\n isDragging,\n oldIndex,\n newIndex,\n };\n}\n"],"names":["moveSortableElements","list","from","to","_listIsRef","isRef","listCopy","toValue","element","nextTick","createGhostElement","e","ghostClass","ghost","getValidDragTarget","_a","cleanupGhostElement","dragElement","useSortable","isEnabled","sortInPlace","options","parentEl","computed","unrefElement","newIndex","ref","oldIndex","isDragging","ghostClasses","chosenClasses","handleDragStart","target","index","error","logger","handleDragEnter","draggedEl","handleDragOver","handleDrop","handleDragEnd","watch","setupListeners","removeListeners","onMounted","onBeforeUnmount"],"mappings":";;;AAUO,SAASA,EAA+B,EAAE,MAAAC,GAAM,MAAAC,GAAM,IAAAC,KAAmD;AAC9G,MAAID,MAASC,EAAI;AAEX,QAAAC,IAAaC,EAAMJ,CAAI,GAEvBK,IAAWF,IAAa,CAAC,GAAGG,EAAQN,CAAI,CAAC,IAAIM,EAAQN,CAAI;AAE/D,MAAIE,KAAM,KAAKA,IAAKG,EAAS,QAAQ;AACnC,UAAME,IAAUF,EAAS,OAAOJ,GAAM,CAAC,EAAE,CAAC;AAC1C,IAAAO,EAAS,MAAM;AACJ,MAAAH,EAAA,OAAOH,GAAI,GAAGK,CAAO,GAE1BJ,MAAaH,EAAa,QAAQK;AAAA,IAAA,CACvC;AAAA,EACH;AACF;AAQgB,SAAAI,EAAmBC,GAAcC,GAAsB;;AACrE,QAAMC,IAAQC,EAAmBH,EAAE,MAAqB,EAAE,UAAU,EAAI;AAElE,EAAAE,EAAA,UAAU,IAAI,GAAGD,CAAU,GAEjCC,EAAM,MAAM,WAAW,YACvBA,EAAM,MAAM,MAAM,WAClBA,EAAM,MAAM,YAAY,QACxBA,EAAM,aAAa,aAAa,GAAGA,EAAM,QAAQ,IAAI,QAAQ,GAC7DA,EAAM,gBAAgB,WAAW,GAExB,SAAA,KAAK,YAAYA,CAAK,IAE7BE,IAAAJ,EAAA,iBAAA,QAAAI,EAAc,aAAaF,GAAOA,EAAM,cAAc,GAAGA,EAAM,eAAe;AAEhF,WAASG,IAAsB;AAC7B,0BAAsB,MAAM;AACjB,eAAA,KAAK,YAAYH,CAAK;AAAA,IAAA,CAChC;AAAA,EACH;AAEO,SAAA;AAAA,IAC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