p5.js-website
p5.js-website copied to clipboard
The "attribution" section is not falling back to English on translated pages
Most appropriate sections of the p5.js website?
Examples
What is your operating system?
None
Web browser and version
No response
Actual Behavior
The example pages are missing the "Attribution" section because they are not specified in the translation files.
Expected Behavior
The "Attribution" section should fallback to English when it is not included in the translated files.
Steps to reproduce
No response
Would you like to work on the issue?
It should be assigned to someone else.
Currently, the additional logic of attribution history is not included in the fallback english text. The "remix" metadata information structure is described here.
The fix for this bug would be:
- No localized .mdx files (those in /ko/ etc) should be updated - they should not need the remix block from the english version. This fix can be in either layoutsExample.astro or possibly in (...slug.astro). The solution should be as compact and with as few side effects as possible.
- The copyright section ("Sketch name: Revised by .... . Licensed under....") should be in English, except for sketch name. The additional info section ("You can find the code history") is already localizable (because it uses
t(...)in the ExampleLayout.astro) - Ideally the PR would include a test (eg in
test/pages/_utils.test.ts) that fails on the current codebase but passes with the proposed fix - (Updates to the contributor docs (in
docs/) to clarify the 'remix' behavior is also very welcome as part of this PR)
For now this issue is reserved for CodeDay microinternship; otherwise I will work on it when I next am able to
I'm working on this.