diff --git a/src/app.css b/src/app.css index ec1a811..308f044 100644 --- a/src/app.css +++ b/src/app.css @@ -19,11 +19,11 @@ html .dark { } .popin { - animation: popin 0.4s cubic-bezier(0.65, 0, 0.35, 1); + animation: popin 0.4s cubic-bezier(0.68, -0.6, 0.32, 1.6); } .fadein { - animation: fadein 0.4s cubic-bezier(0.65, 0, 0.35, 1); + animation: fadein 0.4s cubic-bezier(0.68, -0.6, 0.32, 1.6); } @keyframes fadein { @@ -46,14 +46,10 @@ html .dark { } ::-webkit-scrollbar { - width: 7px; + width: 0px; } -::-webkit-scrollbar-track { - background: #b8b8b8; -} - -::-webkit-scrollbar-thumb { - background: #888; - border-radius: 20px; -} +::selection { + background-color: #05d616; + color: #fff; +} \ No newline at end of file diff --git a/src/lib/components/KeymapButton.svelte b/src/lib/components/KeymapButton.svelte index 312dfd1..6c2e356 100644 --- a/src/lib/components/KeymapButton.svelte +++ b/src/lib/components/KeymapButton.svelte @@ -1,22 +1,22 @@ @@ -42,8 +42,8 @@ } .key-glow { - box-shadow: 0 0 10px #fff, 0 0 20px #fff, 0 0 30px #6100b6, 0 0 40px #760094, 0 0 50px #a500e6, - 0 0 60px #a500e6, 0 0 70px #a500e6; + box-shadow: 0 0 5px #fff, 0 0 10px #fff, 0 0 15px #6100b6, 0 0 20px #760094, 0 0 25px #a500e6, + 0 0 30px #a500e6, 0 0 35px #a500e6; } .key-shift { diff --git a/src/lib/components/LessonModal.svelte b/src/lib/components/LessonModal.svelte index 5459e1e..15f3c68 100644 --- a/src/lib/components/LessonModal.svelte +++ b/src/lib/components/LessonModal.svelte @@ -32,16 +32,16 @@ Lessons

closeModal()} > x

-
+
{#each lessons as lesson, idx}

{ $currentLessonName = lesson.name closeModal() diff --git a/src/lib/components/Modal.svelte b/src/lib/components/Modal.svelte index 34efbb0..11962b3 100644 --- a/src/lib/components/Modal.svelte +++ b/src/lib/components/Modal.svelte @@ -2,6 +2,7 @@ export let closeModal: () => void export let showKeymap: boolean export let showPrevOrNextWord: boolean + export let showLogo: boolean export let TabToRestart: boolean export let DarkMode: boolean export let GlowKey: boolean @@ -36,7 +37,7 @@ class="text-lg leading-6 font-medium text-gray-900 dark:text-gray-100" id="modal-title" > - Settings + ⚙Settings

@@ -56,6 +57,14 @@ />
+ Show Manoonchai Logo + +
+
Press Esc to show setting
- Glowing keys + Glowing keys (Better with dark mode) (storage.EscToSetting ?? DEFAULT['E export const TabToRestart = writable(storage.TabToRestart ?? DEFAULT['TabToRestart']) export const DarkMode = writable(storage.DarkMode ?? DEFAULT['DarkMode']) export const GlowKey = writable(storage.GlowKey ?? DEFAULT['GlowKey']) +export const ShowLogo = writable(storage.ShowLogo ?? DEFAULT['ShowLogo']) export const currentLessonName = writable(storage.currentLessonName ?? DEFAULT['currentLessonName']) showKeymap.subscribe((value) => { @@ -71,6 +74,11 @@ GlowKey.subscribe((value) => { storeSettings() }) +ShowLogo.subscribe((value) => { + storage.ShowLogo = value + storeSettings() +}) + currentLessonName.subscribe((value) => { storage.currentLessonName = value storeSettings() diff --git a/src/routes/index.svelte b/src/routes/index.svelte index 4bb9f9d..04eafd6 100644 --- a/src/routes/index.svelte +++ b/src/routes/index.svelte @@ -14,6 +14,7 @@ import { showKeymap, showPrevOrNextWord, + ShowLogo, currentLessonName, TabToRestart, DarkMode, @@ -84,9 +85,7 @@ e.preventDefault() } - if (ended) { - return - } + if (ended) return; const manoonchaiKey = Manoonchai[e.code]?.[e.shiftKey ? 1 : 0] || '' @@ -194,6 +193,7 @@
+ {#if $ShowLogo}

Learn {name}

+ {/if}

{wpm} wpm

@@ -261,7 +262,7 @@ {/if}