diff --git a/src/App.svelte b/src/App.svelte index 66700b5..42759de 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -62,6 +62,7 @@ let perpendicular = dir === 'bottom' || dir === 'top' ? 'left' : 'top' obj[perpendicular] = `calc(${pos * 100}% - 100px)` + // Disable transition for the initial position divEl.style.transition = `none` divEl.style.cssText = Object.keys(obj).map(key => `${key}: ${obj[key]}`).join('; ') await sleep(0.1) @@ -88,9 +89,8 @@ imgEl.style.cssText = Object.keys(obj).map(key => `${key}: ${obj[key]}`).join('; ') } - onMount(() => { - setTimeout(() => divStyles(), 100) - }) + onMount(() => setTimeout(divStyles, 100) +)
diff --git a/src/app.sass b/src/app.sass index 87e18be..b9ec6bb 100644 --- a/src/app.sass +++ b/src/app.sass @@ -16,3 +16,6 @@ body margin: 0 width: 100% height: 100% + +* + cursor: url("./matcha_cursor.png") 16 16, auto diff --git a/src/matcha_cursor.png b/src/matcha_cursor.png new file mode 100644 index 0000000..d55e4d3 Binary files /dev/null and b/src/matcha_cursor.png differ