fix(web-ui): add documentation link and version-aware URLs#5176
Conversation
Add a Documentation button to ResourceCard and make docs links version-aware based on installed vs GitHub release. ResourceCard: register BookOpen icon, new installedVersionNotStable prop and documentationUrl computed property. App shell (apps.html/index.html): import SunshineVersion, fetch local version from ./api/config and latest GitHub release, compare versions to determine documentationBaseUrl and pass installedVersionNotStable into Resource-Card. Add "documentation" localization string to en.json. Docs: replace ~ with $(HOME) in app examples for clarity. AGENTS.md: add note to only update the `en` localization (no locale variants).
Bundle ReportChanges will increase total bundle size by 1.41kB (0.09%) ⬆️. This is within the configured threshold ✅ Detailed changes
Affected Assets, Files, and Routes:view changes for bundle: sunshine-esmAssets Changed:
Files in
Files in
Files in
Files in
|
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #5176 +/- ##
==========================================
+ Coverage 15.61% 16.14% +0.52%
==========================================
Files 110 111 +1
Lines 23648 23305 -343
Branches 10393 10410 +17
==========================================
+ Hits 3693 3762 +69
+ Misses 17690 15359 -2331
- Partials 2265 4184 +1919
Flags with carried forward coverage won't be shown. Click here to find out more. Continue to review full report in Codecov by Sentry.
|



Description
Add a Documentation button to ResourceCard and make docs links version-aware based on installed vs GitHub release. ResourceCard: register BookOpen icon, new installedVersionNotStable prop and documentationUrl computed property. App shell (apps.html/index.html): import SunshineVersion, fetch local version from ./api/config and latest GitHub release, compare versions to determine documentationBaseUrl and pass installedVersionNotStable into Resource-Card. Add "documentation" localization string to en.json. Docs: replace ~ with $(HOME) in app examples for clarity. AGENTS.md: add note to only update the
enlocalization (no locale variants).Screenshot
Issues Fixed or Closed
Roadmap Issues
Type of Change
Checklist
AI Usage