修订语法

This commit is contained in:
Eve 2018-08-05 12:03:58 +08:00 committed by 雪狼
parent e5b37584be
commit 937641f462
4 changed files with 8 additions and 8 deletions

View File

@ -10,7 +10,7 @@ This page shows how to validate user input in the UI and display useful validati
using both reactive and template-driven forms. It assumes some basic knowledge of the two using both reactive and template-driven forms. It assumes some basic knowledge of the two
forms modules. forms modules.
本文展示了如何在界面中如何验证用户输入,并显示有用的验证信息,先使用模板驱动表单方式,再使用响应式表单方式。 本文展示了在界面中如何验证用户输入,并显示有用的验证信息,先使用模板驱动表单方式,再使用响应式表单方式。
<div class="alert is-helpful"> <div class="alert is-helpful">

View File

@ -76,7 +76,7 @@ You can lay out the controls creatively, bind them to data, specify validation r
conditionally enable or disable specific controls, trigger built-in visual feedback, and much more. conditionally enable or disable specific controls, trigger built-in visual feedback, and much more.
利用 Angular 模板,可以构建几乎所有表单 &mdash; 登录表单、联系人表单…… 以及任何的商务表单。 利用 Angular 模板,可以构建几乎所有表单 &mdash; 登录表单、联系人表单…… 以及任何的商务表单。
可以创造性摆放各种控件、把它们绑定到数据、指定校验规则、显示校验错误、有条件的禁用或 可以创造性摆放各种控件、把它们绑定到数据、指定校验规则、显示校验错误、有条件的禁用或
启用特定的控件、触发内置的视觉反馈等等,不胜枚举。 启用特定的控件、触发内置的视觉反馈等等,不胜枚举。
Angular makes the process easy by handling many of the repetitive, boilerplate tasks you'd Angular makes the process easy by handling many of the repetitive, boilerplate tasks you'd

View File

@ -175,7 +175,7 @@ The `OnKey` method more clearly expresses what it expects from the template and
`$event` 的类型现在是 `KeyboardEvent` `$event` 的类型现在是 `KeyboardEvent`
不是所有的元素都有 `value` 属性,所以它将 `target` 转换为输入元素。 不是所有的元素都有 `value` 属性,所以它将 `target` 转换为输入元素。
`OnKey` 方法更加清晰表达了它期望从模板得到什么,以及它是如何解析事件的。 `OnKey` 方法更加清晰表达了它期望从模板得到什么,以及它是如何解析事件的。
### Passing _$event_ is a dubious practice ### Passing _$event_ is a dubious practice

View File

@ -12080,7 +12080,7 @@
{ {
"key": "THISPAGESHOWSHOWTOVALIDATEUSERINPUTINTHEUIANDDISPLAYUSEFULVALIDATIONMESSAGESUSINGBOTHREACTIVEANDTEMPLATEDRIVENFORMSITASSUMESSOMEBASICKNOWLEDGEOFTHETWOFORMSMODULES", "key": "THISPAGESHOWSHOWTOVALIDATEUSERINPUTINTHEUIANDDISPLAYUSEFULVALIDATIONMESSAGESUSINGBOTHREACTIVEANDTEMPLATEDRIVENFORMSITASSUMESSOMEBASICKNOWLEDGEOFTHETWOFORMSMODULES",
"original": "This page shows how to validate user input in the UI and display useful validation messages\nusing both reactive and template-driven forms. It assumes some basic knowledge of the two \nforms modules.", "original": "This page shows how to validate user input in the UI and display useful validation messages\nusing both reactive and template-driven forms. It assumes some basic knowledge of the two \nforms modules.",
"translation": "本文展示了如何在界面中如何验证用户输入,并显示有用的验证信息,先使用模板驱动表单方式,再使用响应式表单方式。", "translation": "本文展示了在界面中如何验证用户输入,并显示有用的验证信息,先使用模板驱动表单方式,再使用响应式表单方式。",
"sourceFile": "/Users/twer/private/GDE/angular-cn/aio/content/guide/form-validation.md" "sourceFile": "/Users/twer/private/GDE/angular-cn/aio/content/guide/form-validation.md"
}, },
{ {
@ -12488,7 +12488,7 @@
{ {
"key": "YOUCANBUILDALMOSTANYFORMWITHANANGULARTEMPLATEMDASHLOGINFORMSCONTACTFORMSANDPRETTYMUCHANYBUSINESSFORMYOUCANLAYOUTTHECONTROLSCREATIVELYBINDTHEMTODATASPECIFYVALIDATIONRULESANDDISPLAYVALIDATIONERRORSCONDITIONALLYENABLEORDISABLESPECIFICCONTROLSTRIGGERBUILTINVISUALFEEDBACKANDMUCHMORE", "key": "YOUCANBUILDALMOSTANYFORMWITHANANGULARTEMPLATEMDASHLOGINFORMSCONTACTFORMSANDPRETTYMUCHANYBUSINESSFORMYOUCANLAYOUTTHECONTROLSCREATIVELYBINDTHEMTODATASPECIFYVALIDATIONRULESANDDISPLAYVALIDATIONERRORSCONDITIONALLYENABLEORDISABLESPECIFICCONTROLSTRIGGERBUILTINVISUALFEEDBACKANDMUCHMORE",
"original": "You can build almost any form with an Angular template&mdash;login forms, contact forms, and pretty much any business form.\nYou can lay out the controls creatively, bind them to data, specify validation rules and display validation errors,\nconditionally enable or disable specific controls, trigger built-in visual feedback, and much more.", "original": "You can build almost any form with an Angular template&mdash;login forms, contact forms, and pretty much any business form.\nYou can lay out the controls creatively, bind them to data, specify validation rules and display validation errors,\nconditionally enable or disable specific controls, trigger built-in visual feedback, and much more.",
"translation": "利用 Angular 模板,可以构建几乎所有表单 &mdash; 登录表单、联系人表单…… 以及任何的商务表单。\n 可以创造性摆放各种控件、把它们绑定到数据、指定校验规则、显示校验错误、有条件的禁用或\n 启用特定的控件、触发内置的视觉反馈等等,不胜枚举。", "translation": "利用 Angular 模板,可以构建几乎所有表单 &mdash; 登录表单、联系人表单…… 以及任何的商务表单。\n 可以创造性摆放各种控件、把它们绑定到数据、指定校验规则、显示校验错误、有条件的禁用或\n 启用特定的控件、触发内置的视觉反馈等等,不胜枚举。",
"sourceFile": "/Users/twer/private/GDE/angular-cn/aio/content/guide/forms.md" "sourceFile": "/Users/twer/private/GDE/angular-cn/aio/content/guide/forms.md"
}, },
{ {
@ -43910,7 +43910,7 @@
{ {
"key": "YOUSEEATAGLANCEIFAPARTOFYOURAPPLICATIONLACKSTESTS", "key": "YOUSEEATAGLANCEIFAPARTOFYOURAPPLICATIONLACKSTESTS",
"original": "* You see at a glance if a part of your application lacks tests.", "original": "* You see at a glance if a part of your application lacks tests.",
"translation": "你可以一眼看出应用程序的那些部分缺乏测试程序。", "translation": "你可以一眼看出应用程序的哪些部分缺乏测试程序",
"sourceFile": "/Users/twer/private/GDE/angular-cn/aio/content/guide/testing.md" "sourceFile": "/Users/twer/private/GDE/angular-cn/aio/content/guide/testing.md"
}, },
{ {
@ -43928,7 +43928,7 @@
{ {
"key": "WHENYOURENAMETHESOURCEFILEINEVITABLEYOUREMEMBERTORENAMETHETESTFILE", "key": "WHENYOURENAMETHESOURCEFILEINEVITABLEYOUREMEMBERTORENAMETHETESTFILE",
"original": "* When you rename the source file (inevitable), you remember to rename the test file.", "original": "* When you rename the source file (inevitable), you remember to rename the test file.",
"translation": "当你重命名源代码文件(无可避免),你记得重命名测试程序文件", "translation": "当你重命名源代码文件(无可避免),你记得重命名测试程序文件",
"sourceFile": "/Users/twer/private/GDE/angular-cn/aio/content/guide/testing.md" "sourceFile": "/Users/twer/private/GDE/angular-cn/aio/content/guide/testing.md"
}, },
{ {
@ -47612,7 +47612,7 @@
{ {
"key": "THEEVENTISNOWASPECIFICKEYBOARDEVENTNOTALLELEMENTSHAVEAVALUEPROPERTYSOITCASTSTARGETTOANINPUTELEMENTTHEONKEYMETHODMORECLEARLYEXPRESSESWHATITEXPECTSFROMTHETEMPLATEANDHOWITINTERPRETSTHEEVENT", "key": "THEEVENTISNOWASPECIFICKEYBOARDEVENTNOTALLELEMENTSHAVEAVALUEPROPERTYSOITCASTSTARGETTOANINPUTELEMENTTHEONKEYMETHODMORECLEARLYEXPRESSESWHATITEXPECTSFROMTHETEMPLATEANDHOWITINTERPRETSTHEEVENT",
"original": "The `$event` is now a specific `KeyboardEvent`.\nNot all elements have a `value` property so it casts `target` to an input element.\nThe `OnKey` method more clearly expresses what it expects from the template and how it interprets the event.", "original": "The `$event` is now a specific `KeyboardEvent`.\nNot all elements have a `value` property so it casts `target` to an input element.\nThe `OnKey` method more clearly expresses what it expects from the template and how it interprets the event.",
"translation": "`$event` 的类型现在是 `KeyboardEvent`。\n不是所有的元素都有 `value` 属性,所以它将 `target` 转换为输入元素。\n`OnKey` 方法更加清晰表达了它期望从模板得到什么,以及它是如何解析事件的。", "translation": "`$event` 的类型现在是 `KeyboardEvent`。\n不是所有的元素都有 `value` 属性,所以它将 `target` 转换为输入元素。\n`OnKey` 方法更加清晰表达了它期望从模板得到什么,以及它是如何解析事件的。",
"sourceFile": "/Users/twer/private/GDE/angular-cn/aio/content/guide/user-input.md" "sourceFile": "/Users/twer/private/GDE/angular-cn/aio/content/guide/user-input.md"
}, },
{ {