Skip to content

Commit 687a512

Browse files
authored
Merge pull request #254 from javascript-tutorial/sync-9e3fa135
Sync with upstream @ 9e3fa13
2 parents be57662 + 5cb0414 commit 687a512

4 files changed

Lines changed: 8 additions & 8 deletions

File tree

1-js/02-first-steps/18-javascript-specials/article.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -103,13 +103,13 @@ typeof function(){} == "function" // تابع‌ها در اصل زیرمجمو
103103

104104
ما از مرورگر به عنوان محیط کار خود استفاده می‌کنیم، در این محیط چند تابع برای ارتباط با کاربر وجود دارد:
105105

106-
[`prompt(question, [default])`](mdn:api/Window/prompt)
107-
: `question` را به کاربر نمایش می‌دهد که از او می‌خواهد متنی را تایپ کند. بعد متن تایپ شده را بر می‌گرداند. در صورتی که کاربر روی "cancel" کلیک کند یا کلید Esc را فشار دهد مقدار `null` را بر می‌گرداند.
106+
[`prompt(question, [default])`](https://developer.mozilla.org/en-US/docs/Web/API/Window/prompt)
107+
: `question` را به کاربر نمایش می‌دهد که از او می‌خواهد متنی را تایپ کند. بعد متن تایپ شده را بر می‌گرداند. در صورتی که کاربر روی "cancel" کلیک کند مقدار `null` را بر می‌گرداند.
108108

109-
[`confirm(question)`](mdn:api/Window/confirm)
109+
[`confirm(question)`](https://developer.mozilla.org/en-US/docs/Web/API/Window/confirm)
110110
: `question` را نشان می‌دهد و منتظر می‌ماند تا کاربر روی دکمه‌ی cancel یا ok کلیک کند. در صورت کلیک روی ok مقدار true و در صورت کلیک روی cancel یا زدن Esc مقدار false را برمی‌گرداند.
111111

112-
[`alert(message)`](mdn:api/Window/alert)
112+
[`alert(message)`](https://developer.mozilla.org/en-US/docs/Web/API/Window/alert)
113113
: `message` را به کاربر نمایش می‌دهد
114114

115115
تمام این توابع *modal* هستند، آنها اجرای کد را متوقف می‌کنند و از تعامل کاربر با صفحه تا زمانی که جواب بدهد جلوگیری می‌کنند.
@@ -144,7 +144,7 @@ alert( "Tea wanted: " + isTeaWanted ); // true
144144
: دو نوع مقداردهی داریم: مقداردهی معمولی مثل `a = b` و مقداردهی ترکیبی مثل `a *= 2`.
145145

146146
بیتی (Bitwise)
147-
: عملگرهای بیتی با اعداد 32 بیتی در پایین‌ترین سطح یعنی بیت کار می‌کنند: زمانی که به آنها نیاز داشتید به [مستندات](mdn:/JavaScript/Guide/Expressions_and_Operators#Bitwise) مراجعه کنید.
147+
: عملگرهای بیتی با اعداد 32 بیتی در پایین‌ترین سطح یعنی بیت کار می‌کنند: زمانی که به آنها نیاز داشتید به [مستندات](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Expressions_and_Operators#bitwise_operators) مراجعه کنید.
148148

149149
شرطی (Conditional)
150150
: تنها اپراتور 3 پارامتری: `cond ? resultA : resultB`. اگر `cond` truthy باشد، `resultA` را برمی‌گرداند، در غیر این صورت `resultB`.

2-ui/1-document/11-coordinates/article.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ Additionally, there are derived properties:
3636
```online
3737
For instance click this button to see its window coordinates:
3838
39-
<p><input id="brTest" type="button" value="Get coordinates using button.getBoundingClientRect() for this button" onclick='showRect(this)'/></p>
39+
<p><input id="brTest" type="button" style="max-width: 90vw;" value="Get coordinates using button.getBoundingClientRect() for this button" onclick='showRect(this)'/></p>
4040
4141
<script>
4242
function showRect(elem) {

2-ui/3-event-details/6-pointer-events/article.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ Some pointer devices measure contact area and pressure, e.g. for a finger on the
6969
- `height` - the height of the area where the pointer touches the device. Where unsupported, it's always `1`.
7070
- `pressure` - the pressure of the pointer tip, in range from 0 to 1. For devices that don't support pressure must be either `0.5` (pressed) or `0`.
7171
- `tangentialPressure` - the normalized tangential pressure.
72-
- `tiltX`, `tiltY`, `twist` - pen-specific properties that describe how the pen is positioned relative the surface.
72+
- `tiltX`, `tiltY`, `twist` - pen-specific properties that describe how the pen is positioned relative to the surface.
7373
7474
These properties aren't supported by most devices, so they are rarely used. You can find the details about them in the [specification](https://w3c.github.io/pointerevents/#pointerevent-interface) if needed.
7575

5-network/10-long-polling/article.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ The flow:
2929
3. When a message appears - the server responds to the request with it.
3030
4. The browser makes a new request immediately.
3131

32-
The situation when the browser sent a request and has a pending connection with the server, is standard for this method. Only when a message is delivered, the connection is reestablished.
32+
This situation, where the browser has sent a request and keeps a pending connection with the server, is standard for this method. Only when a message is delivered, the connection is closed and reestablished.
3333

3434
![](long-polling.svg)
3535

0 commit comments

Comments
 (0)