yari
yari copied to clipboard
helpful links on 404 page
Fixes #3931
What it looks like:
And if it's a non-en-US that can find the en-US equivalent:
To test this locally, with Yari, you do yarn dev
and can go to HTTP://localhost:3000/en-US/_404 or start Yari and use http://localhost:5000/en-US/docs/WHATEVER
Actually, mentioning German is funny because I realize a "bug" in this. The de pages are not maintained. You can't file an issue, because there is no team of reviewers for de. So it would be weird to combine that message with the hopelessness of "invalid locales" (for some reason, that's what we call locales that exist but not open for PRs).
Ha :-). I'm sure you get my point. To avoid ambiguity - very happy with the text and "approach" so would be pleased if it is merged. But as a post-process there needs to be some thinking about making this work for non-English locales!
Are there redirects in place for any of our 'deprecated locales' (see what I did there) @peterbe ?
Are there redirects in place for any of our 'deprecated locales' (see what I did there) @peterbe ?
Yeah, that's already in place. E.g. https://developer.mozilla.org/sv-SE/docs/Web/CSS
But let's not spend too much time on this here PR.
First, we make the second to last sentence switch from mdn/content
to mdn/translated-content
depending on the active locale
.
For the last sentence, we can perhaps just link to https://github.com/mdn/translated-content#readme
instead.
@Rumyra @hamishwillee If you still deem this useful, I can finish it up, but the text might need to be rewritten.
(Linking to mdn/content or mdn/translated-content depending on the locale should be fairly easy.)
![image](https://user-images.githubusercontent.com/495429/167675238-7729cd82-5355-4202-ba12-a091c7778726.png)
@caugner I'm still keen on this. What changes were you thinking about for the text?
What changes were you thinking about for the text?
Something along these lines:
Sorry, the page
...
could not be found.[this is where the green fallback box comes]
If you followed a link to this page:
- Maybe this page has not yet been written.
- Maybe this content has been archived, deleted or retired [add links to archived-content / GitHub search / retired-content respectively].
- Maybe the link was just incorrect.
If you followed a link on MDN, please go back to the page and let us know using the "Report issue" link at the bottom. If you followed a link on another site, don't hesitate to contact whoever can update the content on that site.
We also want to avoid getting issue reports for frozen locales, and the screenshots above invite e.g. German users to report issues for broken links to German MDN pages (probably not a good idea).
With respect to translated content, I have no real comment. I'd be happy in the first instance if this was applied only to English content.
With respect to the text, the original text is more succinct and took some time to agree among the team. If you need to change it (perhaps due to the green fallback box?) then we should do another round of review. But you've certainly go the main points. A possible option that is slightly more to my taste:
Sorry, we could not find the page: Xxxx
[this is where the green fallback box comes]
The page may be missing because it has not been written, or because it has been [archived], [deleted] or [retired]. It is also possible that the link URL was wrong (try searching for the page name).
If you followed a link on MDN, please go back to the page and let us know using the "Report issue" link at the bottom. If you followed a link on another site, please contact the administrator of that site.
@hamishwillee See also: https://github.com/mdn/yari/pull/7070