Describe the bug
Every Microsoft Learn "Learn more" link rendered by the manifest editor webview hardcodes the /en-us/ locale segment in its URL. This pins the docs to English for all users regardless of their language, instead of letting learn.microsoft.com serve the reader's preferred language.
Microsoft Learn already handles locale negotiation server-side. A locale-less URL 302-redirects to the reader's preferred locale based on Accept-Language, while an en-us URL stays pinned to English:
# no locale segment -> redirected to the reader's language
$ curl -I -H "Accept-Language: fr-FR,fr;q=0.9" \
https://learn.microsoft.com/uwp/schemas/appxpackage/uapmanifestschema/element-identity
302 -> https://learn.microsoft.com/fr-fr/uwp/schemas/appxpackage/uapmanifestschema/element-identity
# hardcoded en-us -> stays English
$ curl -I -H "Accept-Language: fr-FR,fr;q=0.9" \
https://learn.microsoft.com/en-us/uwp/schemas/appxpackage/uapmanifestschema/element-identity
301 -> https://learn.microsoft.com/en-us/uwp/schemas/appxpackage/uapmanifestschema/element-f-identity
Omitting the locale is also the documented guidance for Microsoft Learn links, and it makes the URLs shorter.
Affected locations
All 17 doc links live in two files, covering 15 unique URLs — every one of them hardcodes /en-us/. There are no locale-less Learn links anywhere in the repo, so this is consistent across the board:
src/manifest-editor/webview-content.ts (14 links) — lines 99, 165, 203, 350, 360, 365, 370, 375, 380, 385, 393, 401, 409, 426
src/manifest-editor/webview-script-applications.ts (3 links) — lines 131, 220, 225
Unique URLs (all under https://learn.microsoft.com/en-us/uwp/schemas/appxpackage/uapmanifestschema/):
element-1-extension
element-application
element-capabilities
element-dependencies
element-identity
element-packagedependency
element-properties
element-resources
element-uap-visualelements
element-uap10-hostruntimedependency
element-uap3-mainpackagedependency2
element-uap4-customcapability
element-uap5-driverdependency
element-uap7-ospackagedependency
element-win32dependencies-externaldependency
Out of scope
Other en-us matches in the repo are legitimate BCP-47 language tags in appxmanifest <Resource Language="en-us" /> content (test fixtures, manifest-validator.ts error text, webview-script-resources.ts placeholder, README.md line 178). These are unrelated to URL localization and must not be changed.
To Reproduce
- Set your browser / OS display language to something other than English (e.g. French or Japanese).
- Open an
AppxManifest.xml / Package.appxmanifest file in the WinApp manifest editor.
- On any tab (Identity, Properties, Dependencies, Resources, Applications, Capabilities), click a Learn more link.
- The Microsoft Learn page opens in English rather than the reader's language, because the URL is pinned to
/en-us/.
Expected behavior
The /en-us/ segment should be dropped from all Microsoft Learn URLs, e.g.:
- https://learn.microsoft.com/en-us/uwp/schemas/appxpackage/uapmanifestschema/element-identity
+ https://learn.microsoft.com/uwp/schemas/appxpackage/uapmanifestschema/element-identity
Microsoft Learn then redirects each reader to the appropriate localized page automatically, and English readers see no change in behavior.
It would also be worth considering a lightweight guard so the pattern doesn't creep back in — for example a lint rule or a unit test asserting that no source file contains learn.microsoft.com/en-us/.
Screenshots
N/A
OS Version and details
Windows 11 (not OS-specific — affects all platforms and any non-English reader).
Describe the bug
Every Microsoft Learn "Learn more" link rendered by the manifest editor webview hardcodes the
/en-us/locale segment in its URL. This pins the docs to English for all users regardless of their language, instead of letting learn.microsoft.com serve the reader's preferred language.Microsoft Learn already handles locale negotiation server-side. A locale-less URL 302-redirects to the reader's preferred locale based on
Accept-Language, while anen-usURL stays pinned to English:Omitting the locale is also the documented guidance for Microsoft Learn links, and it makes the URLs shorter.
Affected locations
All 17 doc links live in two files, covering 15 unique URLs — every one of them hardcodes
/en-us/. There are no locale-less Learn links anywhere in the repo, so this is consistent across the board:src/manifest-editor/webview-content.ts(14 links) — lines 99, 165, 203, 350, 360, 365, 370, 375, 380, 385, 393, 401, 409, 426src/manifest-editor/webview-script-applications.ts(3 links) — lines 131, 220, 225Unique URLs (all under
https://learn.microsoft.com/en-us/uwp/schemas/appxpackage/uapmanifestschema/):Out of scope
Other
en-usmatches in the repo are legitimate BCP-47 language tags in appxmanifest<Resource Language="en-us" />content (test fixtures,manifest-validator.tserror text,webview-script-resources.tsplaceholder,README.mdline 178). These are unrelated to URL localization and must not be changed.To Reproduce
AppxManifest.xml/Package.appxmanifestfile in the WinApp manifest editor./en-us/.Expected behavior
The
/en-us/segment should be dropped from all Microsoft Learn URLs, e.g.:Microsoft Learn then redirects each reader to the appropriate localized page automatically, and English readers see no change in behavior.
It would also be worth considering a lightweight guard so the pattern doesn't creep back in — for example a lint rule or a unit test asserting that no source file contains
learn.microsoft.com/en-us/.Screenshots
N/A
OS Version and details
Windows 11 (not OS-specific — affects all platforms and any non-English reader).