feat(tray): add configurable start page with last session memory#35
Merged
flexiondotorg merged 5 commits intomainfrom Mar 24, 2026
Merged
feat(tray): add configurable start page with last session memory#35flexiondotorg merged 5 commits intomainfrom
flexiondotorg merged 5 commits intomainfrom
Conversation
…abels Add on/off/style state labels to tray menu and reorganise notifications, Discord, and appearance toggles as radio button submenus. Add i18n strings for "On", "Off", "Style", and "Apple Music". Signed-off-by: Martin Wimpress <code@wimpress.io>
- Move navBarScript variable declaration outside event handlers to make it available for reinjection on in-page navigation - Reinject navigation bar when `did-navigate-in-page` event fires to ensure it's present after client-side routing Signed-off-by: Martin Wimpress <code@wimpress.io>
Signed-off-by: Martin Wimpress <code@wimpress.io>
- Add 'last' to startPage enum and lastPageUrl storage field - Track last visited URL when navigating within Apple Music - Display "Last session" option in tray menu with radio button - Provide localised "Last session" text for 25 languages - Fall through to 'new' if no previous session URL is stored Signed-off-by: Martin Wimpress <code@wimpress.io>
Contributor
There was a problem hiding this comment.
1 issue found across 4 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="src/main.ts">
<violation number="1" location="src/main.ts:405">
P2: The regex-based last-page extraction can save invalid paths (e.g. `us`), causing malformed restore URLs like `/us/us` on next launch.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
- Replace regex-based URL matching with URL constructor for robustness - Extract page path segments handling optional locale prefix - Add error handling for invalid URLs with warning log Signed-off-by: Martin Wimpress <code@wimpress.io>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a configurable start page feature allowing users to select their preferred landing page (Home, New, Radio, or All Playlists) plus a "Last session" option that remembers the previously visited page. Converts existing tray toggles to radio button submenus for cleaner UI. Fixes a race condition in navigationBar injection that prevented browser controls from appearing on non-
/newstart pages. Includes full localisation across 25+ languages.Changes
/newpagesTesting