Skip to content

Commit b7e2ff8

Browse files
authored
Merge pull request #695 from limzykenneth/link-fix
Bulk fix reference link
2 parents 4e95522 + 4b72466 commit b7e2ff8

File tree

235 files changed

+492
-492
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

235 files changed

+492
-492
lines changed

public/reference/data.json

+13-13
Large diffs are not rendered by default.

public/search-indices/zh-Hans.json

+1-1
Large diffs are not rendered by default.

src/content/contributor-docs/en/fes_contribution_guide.mdx

+6-6
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ arc(1, 1, 10.5, 10);
237237
FES will generate the following message in the console:
238238

239239
```
240-
🌸 p5.js says: [sketch.js, line 13] arc() was expecting at least 6 arguments, but received only 4. (http://p5js.org/reference/#/p5/arc)
240+
🌸 p5.js says: [sketch.js, line 13] arc() was expecting at least 6 arguments, but received only 4. (http://p5js.org/reference/p5/arc)
241241
```
242242

243243
Example of a type mismatch
@@ -249,7 +249,7 @@ arc(1, ',1', 10.5, 10, 0, Math.PI);
249249
FES will generate the following message in the console:
250250

251251
```
252-
🌸 p5.js says: [sketch.js, line 14] arc() was expecting Number for the first parameter, received string instead. (http://p5js.org/reference/#/p5/arc)
252+
🌸 p5.js says: [sketch.js, line 14] arc() was expecting Number for the first parameter, received string instead. (http://p5js.org/reference/p5/arc)
253253
```
254254

255255
#### Location
@@ -323,7 +323,7 @@ function preload() {
323323
FES will generate the following message in the console:
324324

325325
```
326-
🌸 p5.js says: [sketch.js, line 8] An error with message "Cannot read properties of undefined (reading 'background')" occurred inside the p5js library when "background" was called. If not stated otherwise, it might be due to "background" being called from preload. Nothing besides load calls (loadImage, loadJSON, loadFont, loadStrings, etc.) should be inside the preload function. (http://p5js.org/reference/#/p5/preload)
326+
🌸 p5.js says: [sketch.js, line 8] An error with message "Cannot read properties of undefined (reading 'background')" occurred inside the p5js library when "background" was called. If not stated otherwise, it might be due to "background" being called from preload. Nothing besides load calls (loadImage, loadJSON, loadFont, loadStrings, etc.) should be inside the preload function. (http://p5js.org/reference/p5/preload)
327327
```
328328

329329
Internal Error Example 2:
@@ -338,7 +338,7 @@ function setup() {
338338
FES will generate the following message in the console:
339339

340340
```js
341-
🌸 p5.js says: [sketch.js, line 12] An error with message "Cannot read properties of undefined (reading 'bind')" occurred inside the p5js library when mouseClicked was called. If not stated otherwise, it might be an issue with the arguments passed to mouseClicked. (http://p5js.org/reference/#/p5/mouseClicked)
341+
🌸 p5.js says: [sketch.js, line 12] An error with message "Cannot read properties of undefined (reading 'bind')" occurred inside the p5js library when mouseClicked was called. If not stated otherwise, it might be an issue with the arguments passed to mouseClicked. (http://p5js.org/reference/p5/mouseClicked)
342342
```
343343
344344
Example of an Error (Scope):
@@ -373,7 +373,7 @@ function setup() {
373373
FES will generate the following message in the console:
374374
375375
```
376-
🌸 p5.js says: [sketch.js, line 2] It seems that you may have accidentally written "xolor" instead of "color". Please correct it to color if you wish to use the function from p5.js. (http://p5js.org/reference/#/p5/color)
376+
🌸 p5.js says: [sketch.js, line 2] It seems that you may have accidentally written "xolor" instead of "color". Please correct it to color if you wish to use the function from p5.js. (http://p5js.org/reference/p5/color)
377377
```
378378
379379
#### Location
@@ -413,7 +413,7 @@ function preload() {
413413
FES will generate the following message in the console:
414414
415415
```
416-
🌸 p5.js says: It seems that you may have accidentally written preLoad instead of preload. Please correct it if it's not intentional. (http://p5js.org/reference/#/p5/preload)
416+
🌸 p5.js says: It seems that you may have accidentally written preLoad instead of preload. Please correct it if it's not intentional. (http://p5js.org/reference/p5/preload)
417417
```
418418
419419
#### Location

src/content/contributor-docs/en/how-to-add-friendly-error-messages.mdx

+6-6
Original file line numberDiff line numberDiff line change
@@ -123,9 +123,9 @@ circle(100, 100, 'hello');
123123
The code above should generate the following FE messages:
124124

125125
```
126-
🌸 p5.js says: [sketch.js, line 9] circle() was expecting at least 3 arguments, but received only 1. (http://p5js.org/reference/#/p5/circle)
127-
🌸 p5.js says: [sketch.js, line 14] circle() was expecting no more than 3 arguments, but received 4. (http://p5js.org/reference/#/p5/circle)
128-
🌸 p5.js says: [sketch.js, line 12] circle() was expecting Number for the third parameter, received string instead. (http://p5js.org/reference/#/p5/circle)
126+
🌸 p5.js says: [sketch.js, line 9] circle() was expecting at least 3 arguments, but received only 1. (http://p5js.org/reference/p5/circle)
127+
🌸 p5.js says: [sketch.js, line 14] circle() was expecting no more than 3 arguments, but received 4. (http://p5js.org/reference/p5/circle)
128+
🌸 p5.js says: [sketch.js, line 12] circle() was expecting Number for the third parameter, received string instead. (http://p5js.org/reference/p5/circle)
129129
```
130130

131131
Congratulations 🎈! You are now done adding parameter validation for your new method.
@@ -240,7 +240,7 @@ p5._friendlyError(
240240
This should generate the following FE messages:
241241

242242
```
243-
🌸 p5.js says: [sketch.js, line 19] An error with the message "vertex() must be used once before calling bezierVertex()" occurred inside the p5js library when bezierVertex was called. If not stated otherwise, it might be an issue with the arguments passed to bezierVertex. (http://p5js.org/reference/#/p5/bezierVertex) 
243+
🌸 p5.js says: [sketch.js, line 19] An error with the message "vertex() must be used once before calling bezierVertex()" occurred inside the p5js library when bezierVertex was called. If not stated otherwise, it might be an issue with the arguments passed to bezierVertex. (http://p5js.org/reference/p5/bezierVertex) 
244244
```
245245

246246
Congratulations 🎈! You are now done adding library error messages for your method.
@@ -250,13 +250,13 @@ Congratulations 🎈! You are now done adding library error messages for your me
250250
FES message writers should prioritize lowering the barrier of understanding error messages and increasing the accessibility of the debugging process. Here is one example:
251251

252252
```
253-
🌸 p5.js says: [sketch.js, line 7] circle() was expecting at least 3 arguments, but received only 1. (http://p5js.org/reference/#/p5/circle) 
253+
🌸 p5.js says: [sketch.js, line 7] circle() was expecting at least 3 arguments, but received only 1. (http://p5js.org/reference/p5/circle) 
254254
```
255255

256256
The above parameter validation message will be shown in Korean if the browser is set to `ko-KR` (Korean) locale:
257257

258258
```
259-
🌸 p5.js says: [sketch.js, 줄7] 최소 3개의 인수(argument)를 받는 함수 circle()에 인수가 1개만 입력되었습니다. (http://p5js.org/reference/#/p5/circle) 
259+
🌸 p5.js says: [sketch.js, 줄7] 최소 3개의 인수(argument)를 받는 함수 circle()에 인수가 1개만 입력되었습니다. (http://p5js.org/reference/p5/circle) 
260260
```
261261

262262
[Friendly Errors i18n Book](https://almchung.github.io/p5-fes-i18n-book/) discusses challenges and best practices for writing Friendly Error messages within the cross-cultural i18n context. Here are the main points from the book:

src/content/contributor-docs/en/release_process.mdx

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ CDNs will take a bit more time (a day or two) to update but they will automatica
5353

5454
## What's actually happening
5555

56-
The GitHub Action ["New p5.js release"](../.github/workflows/release.yml) is triggered on a tag that matches the pattern `v*.*.*` which is created by the `npm version ___` command.
56+
The GitHub Action ["New p5.js release"](../.github/workflows/release-workflow.yml) is triggered on a tag that matches the pattern `v*.*.*` which is created by the `npm version ___` command.
5757

5858
Once triggered, it will run the following steps:
5959

src/content/contributor-docs/es/contributing_to_the_p5js_reference.mdx

+2-2
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ Cualquier cosa en un bloque de estos se interpretará como documentación de ref
7777

7878
## Bloque de comentarios de referencia
7979

80-
Desglosemos el bloque de comentarios de referencia anterior para la función `sin()` y veamos qué hace cada sección. Puedes comparar lo que vez en estos comentarios con el contenido de la página de referencia para [`sin()`](https://p5js.org/reference/#/p5/sin/).
80+
Desglosemos el bloque de comentarios de referencia anterior para la función `sin()` y veamos qué hace cada sección. Puedes comparar lo que vez en estos comentarios con el contenido de la página de referencia para [`sin()`](https://p5js.org/reference/p5/sin/).
8181

8282
```
8383
/**
@@ -268,7 +268,7 @@ Si no quieres que el ejemplo se ejecute como parte de las pruebas automatizadas
268268
* </code></div>
269269
```
270270

271-
Si tu ejemplo utiliza archivos externos como recursos, colócalos en la carpeta [/docs/yuidoc-p5-theme/assets](https://github.com/processing/p5.js/tree/main/docs/yuidoc-p5-theme/assets/) (o reutiliza uno que ya esté allí) y luego enlázalos con "assets/nombrearchivo.ext" en el código. Consulta la referencia de [tint()](http://p5js.org/reference/#/p5/tint/) como ejemplo.
271+
Si tu ejemplo utiliza archivos externos como recursos, colócalos en la carpeta [/docs/yuidoc-p5-theme/assets](https://github.com/processing/p5.js/tree/main/docs/yuidoc-p5-theme/assets/) (o reutiliza uno que ya esté allí) y luego enlázalos con "assets/nombrearchivo.ext" en el código. Consulta la referencia de [tint()](http://p5js.org/reference/p5/tint/) como ejemplo.
272272

273273
### Agregar descripción a un lienzo usando `describe()`
274274

src/content/contributor-docs/hi/contributing_to_the_p5js_reference.mdx

+2-2
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ p5.js के स्रोत कोड को देखने पर, आपक
7777

7878
## संदर्भ टिप्पणी ब्लॉक
7979

80-
ऊपर दिए गए `sin()` फ़ंक्शन के लिए संदर्भ टिप्पणियों ब्लॉक को विश्लेषित करें और देखें कि प्रत्येक खंड का क्या काम है। आप यहाँ टिप्पणियों में दिखने वाली जानकारी और `sin()` के संदर्भ पृष्ठ पर जो दिखता है, उनकी तुलना कर सकते हैं। ([`sin()`](https://p5js.org/reference/#/p5/sin/))
80+
ऊपर दिए गए `sin()` फ़ंक्शन के लिए संदर्भ टिप्पणियों ब्लॉक को विश्लेषित करें और देखें कि प्रत्येक खंड का क्या काम है। आप यहाँ टिप्पणियों में दिखने वाली जानकारी और `sin()` के संदर्भ पृष्ठ पर जो दिखता है, उनकी तुलना कर सकते हैं। ([`sin()`](https://p5js.org/reference/p5/sin/))
8181

8282
```
8383
/**
@@ -268,7 +268,7 @@ p5.js के स्रोत कोड को देखने पर, आपक
268268
* </code></div>
269269
```
270270

271-
यदि आपका उदाहरण बाहरी संसाधन फ़ाइलों का उपयोग करता है, तो उन्हें [/docs/yuidoc-p5-theme/assets](https://github.com/processing/p5.js/tree/main/docs/yuidoc-p5-theme/assets/) फ़ोल्डर में रखें (या पहले से वहां मौजूद कोई उपयोग करें) फिर उन्हें कोड में "assets/filename.ext" के साथ लिंक करें। उदाहरण के लिए [tint()](http://p5js.org/reference/#/p5/tint/) संदर्भ देखें।
271+
यदि आपका उदाहरण बाहरी संसाधन फ़ाइलों का उपयोग करता है, तो उन्हें [/docs/yuidoc-p5-theme/assets](https://github.com/processing/p5.js/tree/main/docs/yuidoc-p5-theme/assets/) फ़ोल्डर में रखें (या पहले से वहां मौजूद कोई उपयोग करें) फिर उन्हें कोड में "assets/filename.ext" के साथ लिंक करें। उदाहरण के लिए [tint()](http://p5js.org/reference/p5/tint/) संदर्भ देखें।
272272

273273
### `describe()` का उपयोग करके कैनवास का विवरण जोड़ें
274274

src/content/contributor-docs/ko/contributing_to_the_p5js_reference.mdx

+2-2
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ p5.js 소스 코드를 보면 많은 라인이 레퍼런스 주석으로 작성
7777

7878
## 레퍼런스 주석 블록
7979

80-
앞서 보았던 `sin()` 함수의 레퍼런스 주석 블록을 조금 더 자세히 살펴보고, 각 섹션이 어떤 역할을 하는지 알아봅시다. 주석으로 작성한 내용이 실제 [`sin()`](https://p5js.org/reference/#/p5/sin/) 레퍼런스 페이지에서는 어떻게 보여지는지 비교해보세요.
80+
앞서 보았던 `sin()` 함수의 레퍼런스 주석 블록을 조금 더 자세히 살펴보고, 각 섹션이 어떤 역할을 하는지 알아봅시다. 주석으로 작성한 내용이 실제 [`sin()`](https://p5js.org/reference/p5/sin/) 레퍼런스 페이지에서는 어떻게 보여지는지 비교해보세요.
8181

8282
```
8383
/**
@@ -268,7 +268,7 @@ p5.js 소스 코드를 보면 많은 라인이 레퍼런스 주석으로 작성
268268
* </code></div>
269269
```
270270

271-
만약, 예제 코드가 외부 애셋 파일을 사용해야 한다면, 필요한 파일들을 [/docs/yuidoc-p5-theme/assets](https://github.com/processing/p5.js/tree/main/docs/yuidoc-p5-theme/assets/) 폴더에 넣어두세요(이미 해당 폴더에 존재하는 파일을 재사용해도 됩니다). 그리고 코드에서 "assets/filename.ext" 경로로 파일을 불러와 사용하면 됩니다. [tint()](http://p5js.org/reference/#/p5/tint/) 레퍼런스를 참고하세요.
271+
만약, 예제 코드가 외부 애셋 파일을 사용해야 한다면, 필요한 파일들을 [/docs/yuidoc-p5-theme/assets](https://github.com/processing/p5.js/tree/main/docs/yuidoc-p5-theme/assets/) 폴더에 넣어두세요(이미 해당 폴더에 존재하는 파일을 재사용해도 됩니다). 그리고 코드에서 "assets/filename.ext" 경로로 파일을 불러와 사용하면 됩니다. [tint()](http://p5js.org/reference/p5/tint/) 레퍼런스를 참고하세요.
272272

273273
### `describe()`로 캔버스 설명 추가하기
274274

src/content/contributor-docs/ko/creating_libraries.mdx

+1-1
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ p5.prototype.registerMethod('remove', p5.prototype.doRemoveStuff);
136136

137137
* **기여된 라이브러리는 제작자가 호스팅, 문서화 및 유지 관리합니다.** 라이브러리들은 GitHub, 별도의 웹 사이트 또는 어딘가에 있을 수 있습니다.
138138

139-
* **문서가 핵심입니다!** 라이브러리 문서는 사용자가 쉽게 찾아보고 다운로드 하여 사용할 수 있는 곳에 있어야 합니다. 기여된 라이브러리에 대한 문서는 기본 p5.js 레퍼런스에 포함되지 않지만 여러분이 유사한 형식을 따르고 싶을 수도 있습니다. [라이브러리 개요 페이지](http://p5js.org/reference/#/libraries/p5.sound), [클래스 개요 페이지](http://p5js.org/reference/#/p5.Vector)[메소드 페이지](http://p5js.org/reference/#/p5/arc/) 의 예제를 참조하세요.
139+
* **문서가 핵심입니다!** 라이브러리 문서는 사용자가 쉽게 찾아보고 다운로드 하여 사용할 수 있는 곳에 있어야 합니다. 기여된 라이브러리에 대한 문서는 기본 p5.js 레퍼런스에 포함되지 않지만 여러분이 유사한 형식을 따르고 싶을 수도 있습니다. [라이브러리 개요 페이지](http://p5js.org/reference/libraries/p5.sound), [클래스 개요 페이지](http://p5js.org/reference/p5.Vector)[메소드 페이지](http://p5js.org/reference/p5/arc/) 의 예제를 참조하세요.
140140

141141
* **예제가 좋습니다!** 사람들에게 라이브러리가 할 수 있는 일을 보여주세요. 모두 자바스크립트이므로 사람들은 라이브러리를 다운로드하기 전 온라인에서 실행 되는 것을 볼 수 있습니다. 예제들을 호스팅하기 쉬운
142142
[jsfiddle](http://jsfiddle.net/)[codepen](http://codepen.io)이라는 두가지 좋은 옵션이 있습니다.

src/content/contributor-docs/zh-Hans/contributing_to_the_p5js_reference.mdx

+2-2
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ description: |
7777

7878
## 参考注释块
7979

80-
让我们解析上面 `sin()` 函数的参考注释块,并查看每个部分的作用。你可以将此处的注释与参考页面上的[`sin()`](https://p5js.org/reference/#/p5/sin/)进行比较。
80+
让我们解析上面 `sin()` 函数的参考注释块,并查看每个部分的作用。你可以将此处的注释与参考页面上的[`sin()`](https://p5js.org/reference/p5/sin/)进行比较。
8181

8282
```
8383
/**
@@ -268,7 +268,7 @@ description: |
268268
* </code></div>
269269
```
270270

271-
如果你的示例使用外部素材文件,请将它们放入 [/docs/yuidoc-p5-theme/assets](https://github.com/processing/p5.js/tree/main/docs/yuidoc-p5-theme/assets/) 文件夹中(或者重用其中已有的文件),然后在代码中使用 "assets/filename.ext" 链接到它们。请参阅 [tint()](http://p5js.org/reference/#/p5/tint/) 参考示例。
271+
如果你的示例使用外部素材文件,请将它们放入 [/docs/yuidoc-p5-theme/assets](https://github.com/processing/p5.js/tree/main/docs/yuidoc-p5-theme/assets/) 文件夹中(或者重用其中已有的文件),然后在代码中使用 "assets/filename.ext" 链接到它们。请参阅 [tint()](http://p5js.org/reference/p5/tint/) 参考示例。
272272

273273
### 使用 `describe()` 添加画布描述
274274

src/content/contributor-docs/zh-Hans/creating_libraries.mdx

+1-1
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ p5.prototype.registerMethod('remove', p5.prototype.doRemoveStuff);
131131

132132
* **贡献的库由创建者托管、文档化和维护。** 这可以在GitHub、一个单独的网站或其他地方进行。
133133

134-
* **文档至关重要!** 您的库的文档应该放在某个易于找到的位置,供下载和使用您的库的用户使用。贡献的库的文档将不会包含在主要的p5.js参考文档中,但您可能希望遵循类似的格式。请参阅这些示例:[库概述页面](http://p5js.org/reference/#/libraries/p5.sound)[类概述页面](http://p5js.org/reference/#/p5.Vector)[方法页面](http://p5js.org/reference/#/p5/arc/)
134+
* **文档至关重要!** 您的库的文档应该放在某个易于找到的位置,供下载和使用您的库的用户使用。贡献的库的文档将不会包含在主要的p5.js参考文档中,但您可能希望遵循类似的格式。请参阅这些示例:[库概述页面](http://p5js.org/reference/libraries/p5.sound)[类概述页面](http://p5js.org/reference/p5.Vector)[方法页面](http://p5js.org/reference/p5/arc/)
135135

136136
* **示例也很棒!** 它们向人们展示了您的库能做什么。由于这全部是JavaScript,人们可以在下载之前在线运行它们。[jsfiddle](http://jsfiddle.net/)[codepen](http://codepen.io)是两个很好的简单选项,可以用来托管示例。
137137

0 commit comments

Comments
 (0)