From 472c594c5e19203d9003a67a41a73075dc0034c5 Mon Sep 17 00:00:00 2001 From: Nwakaego Glory Nwaekpe <81041326+Nwakaego-Ego@users.noreply.github.com> Date: Sun, 10 May 2026 21:56:13 -0700 Subject: [PATCH 1/2] add docs/translation folder with language specific documentation --- docs/translation/README.md | 17 +++++++++++++++++ docs/translation/hi.md | 25 +++++++++++++++++++++++++ docs/translation/ko.md | 27 +++++++++++++++++++++++++++ docs/translation/zh.md | 19 +++++++++++++++++++ 4 files changed, 88 insertions(+) create mode 100644 docs/translation/README.md create mode 100644 docs/translation/hi.md create mode 100644 docs/translation/ko.md create mode 100644 docs/translation/zh.md diff --git a/docs/translation/README.md b/docs/translation/README.md new file mode 100644 index 0000000000..5518095fa9 --- /dev/null +++ b/docs/translation/README.md @@ -0,0 +1,17 @@ +# Translation Documentation + +This folder contains language-specific documentation for translation contributors working on the p5.js website. + +Each language has its own file in this folder. Each file contains: + +- **Glossary** - agreed translations for technical and p5.js-specific terms +- **Style points** - writing and formatting conventions specific to that language +- **Technical exceptions** - code level changes required to support that language correctly + +## Languages + +- [Hindi](./hi.md) +- [Korean](./ko.md) +- [Chinese](./zh.md) + +For general localization architecture, see [localization.md](../localization.md). \ No newline at end of file diff --git a/docs/translation/hi.md b/docs/translation/hi.md new file mode 100644 index 0000000000..54a7fa4271 --- /dev/null +++ b/docs/translation/hi.md @@ -0,0 +1,25 @@ +# Hindi (हिन्दी) Translation Guide + +This document contains translation guidelines for Hindi contributors working on the p5.js website. + +For general localization architecture, see [localization.md](../localization.md). + +## Glossary + +For the Hindi glossary of standardized technical and p5.js-specific terms, see [localization_hi.md](../localization_hi.md). + +## Technical Exceptions + +### Punctuation Handling + +Hindi uses `।` (danda) and `॥` (double danda) as sentence ending punctuation instead of the Latin full stop `.` + +The regex in `src/components/GridItem/Reference.astro` was updated in PR #1156 to include these characters. Without them the regex only recognised `.` and `。` as sentence endings, causing Hindi reference pages to display the entire description instead of just the first line. + +See [PR #1156](https://github.com/processing/p5.js-website/pull/1156) +and [issue #1154](https://github.com/processing/p5.js-website/issues/1154) +for full details. + +## Additional Resources + +The p5.js repository contains the Hindi FES error message translations which may be useful for terminology consistency: [Hindi FES Translations](https://github.com/processing/p5.js/tree/main/translations/hi) \ No newline at end of file diff --git a/docs/translation/ko.md b/docs/translation/ko.md new file mode 100644 index 0000000000..cbc097e71d --- /dev/null +++ b/docs/translation/ko.md @@ -0,0 +1,27 @@ +# Korean (한국어) Translation Guide + +This document contains translation guidelines for Korean contributors working on the p5.js website. + +For general localization architecture, see [localization.md](../localization.md). + +## Glossary + +A Korean terminology table is being developed in [issue #1323](https://github.com/processing/p5.js-website/issues/1323). + +## Style Points + +### Line Spacing + +Korean characters do not have descenders like Latin letters do, which causes fonts to allocate less vertical space by default. This makes Korean text appear more compressed than intended. A CSS rule was added in [PR #1392](https://github.com/processing/p5.js-website/pull/1392) to increase line spacing for Korean content: + +```css +html[lang="ko"] .rendered-markdown { + line-height: 1.7; + word-break: keep-all; +} +``` +`word-break: keep-all` prevents Korean words from breaking mid-word at line endings which can look awkward in Korean text. + +## Additional Resources + +The p5.js repository contains a Korean translation guide with tips, resources and terminology decisions from the FES Korean translation project: [Korean Translation Resources](https://github.com/processing/p5.js/tree/main/translations/ko) \ No newline at end of file diff --git a/docs/translation/zh.md b/docs/translation/zh.md new file mode 100644 index 0000000000..af03e7c869 --- /dev/null +++ b/docs/translation/zh.md @@ -0,0 +1,19 @@ +# Chinese (简体中文) Translation Guide + +This document contains translation guidelines for Chinese contributors working on the p5.js website. + +For general localization architecture, see [localization.md](../localization.md). + +## Glossary + +A Chinese terminology table has not been created yet. If you would like to contribute one, please open an issue. + +## Style Points + +### Line Spacing + +Based on input from Chinese translation contributor @lirenjie95 in [issue #1376](https://github.com/processing/p5.js-website/issues/1376), adjusting line spacing does not appear to make a noticeable visual difference for Chinese text. Chinese uses an ideographic writing system where each character carries its own independent meaning, which behaves differently from Korean text. No additional CSS rule has been added for Chinese at this time. + +## Additional Resources + +The p5.js repository contains the Chinese FES error message translations which may be useful for terminology consistency: [Chinese FES Translations](https://github.com/processing/p5.js/tree/main/translations/zh) \ No newline at end of file From 33132d081ea2cab0ba516b3af380b7137ec79d6a Mon Sep 17 00:00:00 2001 From: Nwakaego Glory Nwaekpe <81041326+Nwakaego-Ego@users.noreply.github.com> Date: Mon, 1 Jun 2026 16:04:49 -0700 Subject: [PATCH 2/2] consolidate localization_hi.md into docs/translation/hi.md --- docs/localization_hi.md | 123 ----------------------------------- docs/translation/hi.md | 138 ++++++++++++++++++++++++++++++++++++++-- 2 files changed, 132 insertions(+), 129 deletions(-) delete mode 100644 docs/localization_hi.md diff --git a/docs/localization_hi.md b/docs/localization_hi.md deleted file mode 100644 index f097d458a8..0000000000 --- a/docs/localization_hi.md +++ /dev/null @@ -1,123 +0,0 @@ -# Hindi (हिन्दी) Localization Guide - -This document contains the standardized Hindi translations for technical and p5.js-specific terms used across the p5.js website. Translators should refer to this glossary to maintain consistency. - -For the general localization architecture, see [localization.md](./localization.md). - -## Programming-Specific Terms - -| English | Hindi (हिन्दी) | -| --- | --- | -| array | सरणी | -| asynchronous | अतुल्यकालिक | -| attribute | गुण | -| blob tracking | बूँद ट्रैकिंग | -| boolean | बूलियन | -| byte | बाइट | -| callback | कॉलबैक | -| camera frustrum | कैमरा दृष्टिकोण | -| changelog | परिवर्तन लॉग | -| class | क्लास | -| code editor | कोड संपादक | -| color space | रंग स्थान | -| command line | कमांड लाइन | -| comment | टिप्पणी | -| compile | संकलन | -| component | अवयव | -| conditionals | शर्तें | -| console | कंसोल | -| constant | स्थिरांक | -| constructor function | कंस्ट्रक्टर फ़ंक्शन | -| control statement | नियंत्रण कथन | -| coordinate | निर्देशांक | -| curly brace | घुंघराले कोष्ठक | -| debug | डीबग | -| default value | डिफ़ॉल्ट मान | -| deprecated | पदावनत | -| depth | गहराई | -| error | गलती | -| event | आयोजन | -| fields | फील्ड | -| file | दस्तावेज़ | -| floating-point number | चल बिन्दु संख्या | -| framework | रूपरेखा | -| function | कार्य | -| functional programming | कार्यात्मक कार्यरचना | -| HTML | एचटीएमएल | -| HTML tag | एचटीएमएल टैग | -| indent | मांगपत्र | -| index | अनुक्रमणिका | -| iteration | पुनरावर्तन | -| matrix | आव्यूह | -| minify | छोटा करना | -| modelview | मॉडलव्यू | -| motion detection | गति का पता लगाना | -| noise | शोर | -| object | ऑब्जेक्ट | -| object oriented programming | ऑब्जेक्ट ओरिएंटेड प्रोग्रामिंग | -| operator | ऑपरेटर | -| optimize | अनुकूलन | -| optional argument | वैकल्पिक तर्क | -| parameter/argument | पैरामीटर/तर्क | -| parentheses | कोष्टक | -| pixel | पिक्सेल | -| programming library | प्रोग्रामिंग (कंप्यूटिंग) लाइब्रेरी | -| radian | कांति | -| raster | रेखापुंज | -| recursion | प्रत्यावर्तन | -| reference/documentation | संदर्भ/दस्तावेज़ीकरण | -| render/rendering | प्रस्तुत करना/प्रतिपादन करना | -| repository | कोष | -| return | वापसी विवरण | -| scope | दायरा | -| screen | पर्दा | -| server | सर्वर | -| source code | स्रोत कोड | -| square bracket | वर्गाकार ब्रैकेट | -| string | स्ट्रिंग | -| stylesheet | शैली पत्रक | -| subclass | सब-क्लास | -| superclass | सुपर-क्लास | -| syntax | वाक्य - विन्यास | -| test driven development | परीक्षण संचालित विकास | -| transform | परिवर्तन | -| unit testing | इकाई का परीक्षण | -| variable | चर | -| vector | वेक्टर | -| vertex | शिखर | -| video | वीडियो | - -## p5.js-Specific Terms - -| English | Hindi (हिन्दी) | -| --- | --- | -| access | पहुँच | -| accessibility | उपलब्धता | -| addon library | ऐडऑन लाइब्रेरी | -| audio | आवाज़ | -| bezier | बेइजेर | -| brightness | चमक | -| button | बटन | -| canvas | कैनवास | -| coding | कोडिंग (संकेतीकरण) | -| community | समुदाय | -| creative coding | रचनात्मक कोडिंग | -| emulation | अनुकरण | -| frame | फ्रेम | -| gradient (color) | ग्रेडियेंट | -| gradient (math) | क्रमिक | -| graphics buffer | ग्राफ़िक्स बफ़र | -| hue | रंग | -| image | छवि | -| input | इनपुट | -| instance mode | उदाहरण मोड | -| linear interpolation | रेखिक आंतरिक | -| port | पोर्ट | -| project | प्रोजैक्ट | -| saturation | संतृप्ति | -| sketch | स्केच | -| sketchbook | स्केचबुक | -| sound | आवाज़ | -| stroke (outline) | रूपरेखा | -| video | वीडियो | -| webcam | वेबकैम | diff --git a/docs/translation/hi.md b/docs/translation/hi.md index 54a7fa4271..51943e5e06 100644 --- a/docs/translation/hi.md +++ b/docs/translation/hi.md @@ -1,20 +1,144 @@ # Hindi (हिन्दी) Translation Guide -This document contains translation guidelines for Hindi contributors working on the p5.js website. +This document contains translation guidelines and standardized +term translations for Hindi contributors working on the p5.js +website. -For general localization architecture, see [localization.md](../localization.md). +For general localization architecture, see +[localization.md](../localization.md). ## Glossary -For the Hindi glossary of standardized technical and p5.js-specific terms, see [localization_hi.md](../localization_hi.md). +### Programming-Specific Terms + +| English | Hindi (हिन्दी) | +| --- | --- | +| array | सरणी | +| asynchronous | अतुल्यकालिक | +| attribute | गुण | +| blob tracking | बूँद ट्रैकिंग | +| boolean | बूलियन | +| byte | बाइट | +| callback | कॉलबैक | +| camera frustrum | कैमरा दृष्टिकोण | +| changelog | परिवर्तन लॉग | +| class | क्लास | +| code editor | कोड संपादक | +| color space | रंग स्थान | +| command line | कमांड लाइन | +| comment | टिप्पणी | +| compile | संकलन | +| component | अवयव | +| conditionals | शर्तें | +| console | कंसोल | +| constant | स्थिरांक | +| constructor function | कंस्ट्रक्टर फ़ंक्शन | +| control statement | नियंत्रण कथन | +| coordinate | निर्देशांक | +| curly brace | घुंघराले कोष्ठक | +| debug | डीबग | +| default value | डिफ़ॉल्ट मान | +| deprecated | पदावनत | +| depth | गहराई | +| error | गलती | +| event | आयोजन | +| fields | फील्ड | +| file | दस्तावेज़ | +| floating-point number | चल बिन्दु संख्या | +| framework | रूपरेखा | +| function | कार्य | +| functional programming | कार्यात्मक कार्यरचना | +| HTML | एचटीएमएल | +| HTML tag | एचटीएमएल टैग | +| indent | मांगपत्र | +| index | अनुक्रमणिका | +| iteration | पुनरावर्तन | +| matrix | आव्यूह | +| minify | छोटा करना | +| modelview | मॉडलव्यू | +| motion detection | गति का पता लगाना | +| noise | शोर | +| object | ऑब्जेक्ट | +| object oriented programming | ऑब्जेक्ट ओरिएंटेड प्रोग्रामिंग | +| operator | ऑपरेटर | +| optimize | अनुकूलन | +| optional argument | वैकल्पिक तर्क | +| parameter/argument | पैरामीटर/तर्क | +| parentheses | कोष्टक | +| pixel | पिक्सेल | +| programming library | प्रोग्रामिंग (कंप्यूटिंग) लाइब्रेरी | +| radian | कांति | +| raster | रेखापुंज | +| recursion | प्रत्यावर्तन | +| reference/documentation | संदर्भ/दस्तावेज़ीकरण | +| render/rendering | प्रस्तुत करना/प्रतिपादन करना | +| repository | कोष | +| return | वापसी विवरण | +| scope | दायरा | +| screen | पर्दा | +| server | सर्वर | +| source code | स्रोत कोड | +| square bracket | वर्गाकार ब्रैकेट | +| string | स्ट्रिंग | +| stylesheet | शैली पत्रक | +| subclass | सब-क्लास | +| superclass | सुपर-क्लास | +| syntax | वाक्य - विन्यास | +| test driven development | परीक्षण संचालित विकास | +| transform | परिवर्तन | +| unit testing | इकाई का परीक्षण | +| variable | चर | +| vector | वेक्टर | +| vertex | शिखर | +| video | वीडियो | + +### p5.js-Specific Terms + +| English | Hindi (हिन्दी) | +| --- | --- | +| access | पहुँच | +| accessibility | उपलब्धता | +| addon library | ऐडऑन लाइब्रेरी | +| audio | आवाज़ | +| bezier | बेइजेर | +| brightness | चमक | +| button | बटन | +| canvas | कैनवास | +| coding | कोडिंग (संकेतीकरण) | +| community | समुदाय | +| creative coding | रचनात्मक कोडिंग | +| emulation | अनुकरण | +| frame | फ्रेम | +| gradient (color) | ग्रेडियेंट | +| gradient (math) | क्रमिक | +| graphics buffer | ग्राफ़िक्स बफ़र | +| hue | रंग | +| image | छवि | +| input | इनपुट | +| instance mode | उदाहरण मोड | +| linear interpolation | रेखिक आंतरिक | +| port | पोर्ट | +| project | प्रोजैक्ट | +| saturation | संतृप्ति | +| sketch | स्केच | +| sketchbook | स्केचबुक | +| sound | आवाज़ | +| stroke (outline) | रूपरेखा | +| video | वीडियो | +| webcam | वेबकैम | ## Technical Exceptions ### Punctuation Handling -Hindi uses `।` (danda) and `॥` (double danda) as sentence ending punctuation instead of the Latin full stop `.` +Hindi uses `।` (danda) and `॥` (double danda) as sentence +ending punctuation instead of the Latin full stop `.` -The regex in `src/components/GridItem/Reference.astro` was updated in PR #1156 to include these characters. Without them the regex only recognised `.` and `。` as sentence endings, causing Hindi reference pages to display the entire description instead of just the first line. +The regex in `src/components/GridItem/Reference.astro` was +updated in PR #1156 to include these characters. Without them +the regex only recognised `.` and `。` as sentence endings, +causing Hindi reference pages to display the entire description +instead of just the first line. See [PR #1156](https://github.com/processing/p5.js-website/pull/1156) and [issue #1154](https://github.com/processing/p5.js-website/issues/1154) @@ -22,4 +146,6 @@ for full details. ## Additional Resources -The p5.js repository contains the Hindi FES error message translations which may be useful for terminology consistency: [Hindi FES Translations](https://github.com/processing/p5.js/tree/main/translations/hi) \ No newline at end of file +The p5.js repository contains the Hindi FES error message +translations which may be useful for terminology consistency: +[Hindi FES Translations](https://github.com/processing/p5.js/tree/main/translations/hi) \ No newline at end of file