aboutsummaryrefslogtreecommitdiff
path: root/src/stores
diff options
context:
space:
mode:
authorFuwn <[email protected]>2024-04-16 15:36:42 -0700
committerFuwn <[email protected]>2024-04-16 15:36:42 -0700
commitd01162d603cd8ff52e0419f50cdb13b789702645 (patch)
tree215744928997d7d9de9f6aec5bfb3ee1feb8a276 /src/stores
parentfix(tooltip): fix despawn on quick hover (diff)
downloaddue.moe-d01162d603cd8ff52e0419f50cdb13b789702645.tar.xz
due.moe-d01162d603cd8ff52e0419f50cdb13b789702645.zip
feat(tooltip): sliding tooltip
Diffstat (limited to 'src/stores')
-rw-r--r--src/stores/tooltipPosition.ts12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/stores/tooltipPosition.ts b/src/stores/tooltipPosition.ts
new file mode 100644
index 00000000..06b38fe1
--- /dev/null
+++ b/src/stores/tooltipPosition.ts
@@ -0,0 +1,12 @@
+import { cubicOut } from 'svelte/easing';
+import { tweened } from 'svelte/motion';
+
+const tooltipPosition = tweened(
+ { x: 0, y: 0 },
+ {
+ duration: 200 * 1.75,
+ easing: cubicOut
+ }
+);
+
+export default tooltipPosition;