From d01162d603cd8ff52e0419f50cdb13b789702645 Mon Sep 17 00:00:00 2001 From: Fuwn Date: Tue, 16 Apr 2024 15:36:42 -0700 Subject: feat(tooltip): sliding tooltip --- src/stores/tooltipPosition.ts | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 src/stores/tooltipPosition.ts (limited to 'src/stores') 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; -- cgit v1.2.3