You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: 2-ui/4-forms-controls/2-focus-blur/article.md
+7-8Lines changed: 7 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -110,8 +110,7 @@
110
110
111
111
به صورت پیشفرض، بیشتر عناصر از focus پشتیبانی نمیکنند.
112
112
113
-
The list varies a bit between browsers, but one thing is always correct: `focus/blur` support is guaranteed for elements that a visitor can interact with: `<button>`, `<input>`, `<select>`, `<a>` and so on.
114
-
این لیست کمی میان مرورگرها تفاوت میکند اما یک چیز همیشه درست است: `focus/blur`
113
+
این لیست کمی میان مرورگرها تفاوت میکند اما یک چیز همیشه درست است: پشتیبانی از `focus/blur` برای elementهایی که یک کاربر میتواند با آنها تعامل داشته باشد: `<button>`, `<input>`, `<select>`, `<a>` و ... تضمین شده است.
115
114
116
115
از طرفی دیگر، عناصری که برای format کردن چیزی وجود دارند، مثل `<div>`، `<span>`، `<table>` -- به طور پیشفرض غیر قابل focus هستند. متد `elem.focus()` روی آنها کار نمیکند و eventهای `focus/blur` هیچ وقت trigger نمیشوند.
117
116
@@ -137,12 +136,12 @@ The list varies a bit between browsers, but one thing is always correct: `focus/
137
136
برای مثال، اینجا یک لیست داریم. روی اولین item کلیک کنید و `key:Tab` را فشار دهید.
138
137
139
138
```html autorun no-beautify
140
-
Click the first item and press Tab. Keep track of the order. Please note that many subsequent Tabs can move the focus out of the iframe in the example.
139
+
روی اولین item کلیک کنید و Tab را فشار دهید. order را پیگری کنید. لطفا توجه داشته باشد که تعداد زیادی Tab بعدی میتواند focus را از iframe داخل مثال خارج کند.
141
140
<ul>
142
-
<litabindex="1">One</li>
143
-
<litabindex="0">Zero</li>
144
-
<litabindex="2">Two</li>
145
-
<litabindex="-1">Minus one</li>
141
+
<litabindex="1">یک</li>
142
+
<litabindex="0">صفر</li>
143
+
<litabindex="2">دو</li>
144
+
<litabindex="-1">منهای یک</li>
146
145
</ul>
147
146
148
147
<style>
@@ -151,7 +150,7 @@ Click the first item and press Tab. Keep track of the order. Please note that ma
151
150
</style>
152
151
```
153
152
154
-
The order is like this: `1 - 2 - 0`. Normally, `<li>`does not support focusing, but`tabindex`full enables it, along with events and styling with`:focus`.
153
+
ترتیب به این صورت است: `1 - 2 - 0`. به طور نرمال، `<li>`از focus پشتیبانی نمیکند اما`tabindex`آن را به همراه eventها و style دادن با`:focus` مهیا میکند.
155
154
156
155
```smart header="The property `elem.tabIndex` works too"
157
156
We can add `tabindex` from JavaScript by using the `elem.tabIndex` property. That has the same effect.
0 commit comments