From 4114ff8b735094a77fe1fbf037cf0de36b18c18b Mon Sep 17 00:00:00 2001 From: WardPearce Date: Wed, 15 Oct 2025 02:13:16 +1300 Subject: [PATCH] Improvements --- .../src/lib/components/ItemsList.svelte | 8 +- .../lib/components/Settings/Settings.svelte | 2 +- materialious/src/routes/(app)/+layout.svelte | 74 +++++++----------- materialious/src/routes/(app)/+page.svelte | 2 - .../routes/(no-layout)/tv/[slug]/+page.svelte | 5 +- materialious/src/routes/+layout.svelte | 18 +++++ previews/android-tv-home.png | Bin 5040025 -> 5976593 bytes previews/android-tv-player.png | Bin 2979799 -> 2400632 bytes 8 files changed, 55 insertions(+), 54 deletions(-) create mode 100644 materialious/src/routes/+layout.svelte diff --git a/materialious/src/lib/components/ItemsList.svelte b/materialious/src/lib/components/ItemsList.svelte index afce526e..15fb6f89 100644 --- a/materialious/src/lib/components/ItemsList.svelte +++ b/materialious/src/lib/components/ItemsList.svelte @@ -71,7 +71,6 @@ } function setupAndroidTVNavigation() { - console.log('gridElement', gridElement); if (!$isAndroidTvStore || !gridElement) return; focusableItems = Array.from( @@ -117,6 +116,11 @@ switch (direction) { case 'left': + if (currentFocusIndex % columns === 0) { + lastFocusIndex = currentFocusIndex; + updateTabIndex(currentFocusIndex); + return true; + } newIndex = Math.max(0, currentFocusIndex - 1); break; case 'right': @@ -128,7 +132,6 @@ // Store current position before leaving and ensure it stays focusable lastFocusIndex = currentFocusIndex; updateTabIndex(currentFocusIndex); - // Allow the event to bubble up to parent navigation return true; } newIndex = Math.max(0, currentFocusIndex - columns); @@ -218,7 +221,6 @@
-
{#each items as item, index} diff --git a/materialious/src/lib/components/Settings/Settings.svelte b/materialious/src/lib/components/Settings/Settings.svelte index 0a087b6c..2c4192ed 100644 --- a/materialious/src/lib/components/Settings/Settings.svelte +++ b/materialious/src/lib/components/Settings/Settings.svelte @@ -84,7 +84,7 @@ -