Files
CT/src/View/utility.ts
T

19 lines
382 B
TypeScript
Raw Normal View History

2024-07-25 16:20:43 +02:00
export function allowDrop(event: DragEvent) {
2026-04-01 08:29:39 +00:00
event.preventDefault();
2024-07-25 16:20:43 +02:00
}
2024-07-25 18:16:29 +02:00
export function allowDrag(event: DragEvent) {
2026-04-01 08:29:39 +00:00
event.dataTransfer?.setData("text", "");
2024-07-28 03:46:08 +02:00
}
export function reload() {
2026-04-01 08:29:39 +00:00
window.location.reload();
}
2026-04-01 08:53:50 +00:00
export function setFocus() {
document.getElementById("focused")?.focus();
}
export function setFocusWithDelay() {
setTimeout(setFocus, 100);
}