Feature/add-dropdown : Version Routing implementation#2355
Merged
sydseter merged 2 commits intoOWASP:masterfrom Feb 23, 2026
Merged
Feature/add-dropdown : Version Routing implementation#2355sydseter merged 2 commits intoOWASP:masterfrom
sydseter merged 2 commits intoOWASP:masterfrom
Conversation
840e374 to
899cb76
Compare
899cb76 to
febf306
Compare
Contributor
Author
|
Sorry for the delay, Thank, |
sydseter
approved these changes
Feb 23, 2026
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.
Issue Fixed : #2233
📌 Overview
This PR improves version and language handling for card routes and resolves multiple issues related to routing, SSR failures, and edge cases.
It ensures consistent navigation behavior across editions, versions, and languages while improving overall UX stability.
✅ What This PR Fixes
1️⃣ SSR Build Failure
Fixed
ReferenceError: versions is not definedProperly passed and destructured
versionsusing Svelte 5 runes mode ($props())Ensured no undefined variables during prerender
2️⃣ Incorrect Route Generation
Replaced outdated
/card/...paths with correct/edition/...routesPrevented 404 errors caused by invalid URL generation
Restored navigation for:
/cards/edition/webapp/edition/mobileapp3️⃣ Duplicate Languages in Dropdown
Removed repeated language entries using
SetEnsured language list renders uniquely
4️⃣ Version 3.0 Language Restriction
Version
3.0now correctly displays only English (en)Dropdown dynamically adapts based on selected version
5️⃣ Edge Case Handling (UX Improvement)
When switching versions:
If user is on:
/edition/.../2.2/frAnd switches to
3.0They are now automatically redirected to:
/edition/.../3.0/enInstead of encountering a 404.
This prevents invalid version-language combinations and improves user experience.
🧪 Testing
Verified successful
pnpm build(SSR + prerender)Confirmed no 404s during version/language switching
Tested edge cases:
Switching versions across languages
Switching languages across versions
Version 3.0 language enforcement
Screen.Recording.2026-02-24.at.01.32.56.mov
🎯 Result
No SSR crashes
No broken routes
No duplicate languages
Clean navigation behavior
Improved UX for edge cases