Updated Chinese translation (#19391)
This commit is contained in:
parent
6a9a3d2769
commit
133abcbcce
@ -7,17 +7,17 @@ localeTitle: 使用HTML5需要字段
|
||||
---
|
||||
|
||||
## Description
|
||||
<section id="description">您可以要求特定的表单字段,以便您的用户在填写表单之前无法提交表单。例如,如果要创建所需的文本输入字段,只需在<code>input</code>元素中添加<code>required</code>的属性,如下所示: <code><input type="text" required></code> </section>
|
||||
<section id="description">您可以订定必填项,限制您的用户在完成必填项之前无法提交表单。如果您要订定必填项段,只需在<code>input</code>元素中添加<code>required</code>的属性,如下所示: <code><input type="text" required></code> </section>
|
||||
|
||||
## Instructions
|
||||
<section id="instructions">使您的文本<code>input</code> <code>required</code>字段,以便您的用户无法在不填写此字段的情况下提交表单。然后尝试提交表单而不输入任何文本。了解您的HTML5表单如何通知您该字段是必需的? </section>
|
||||
<section id="instructions">利用<code>required</code> 使您的<code>input</code>成为必填项 ,限制您的用户在沒填写必填项的情况下无法提交表单。请尝试在沒有在完成必填项前提交表单,看看HTML5如何通知您少填了必填项。 </section>
|
||||
|
||||
## Tests
|
||||
<section id='tests'>
|
||||
|
||||
```yml
|
||||
tests:
|
||||
- text: 您的文本<code>input</code>元素应具有<code>required</code>属性。
|
||||
- text: 您的<code>input</code>元素应具有<code>required</code>属性。
|
||||
testString: 'assert($("input").prop("required"), "Your text <code>input</code> element should have the <code>required</code> attribute.");'
|
||||
|
||||
```
|
||||
|
Loading…
x
Reference in New Issue
Block a user