From e8773d159940b6d1de63fab45c13222a32901d30 Mon Sep 17 00:00:00 2001 From: tianyu Date: Tue, 28 Jun 2022 10:14:57 +0800 Subject: [PATCH] fixed 3fe4161 from https://gitee.com/yamila89/docs/pulls/6012 uodata process Signed-off-by: tianyu --- .../reference/arkui-js/js-components-media-video.md | 2 +- .../reference/arkui-ts/ts-basic-components-progress.md | 4 ++-- .../reference/arkui-ts/ts-basic-components-textarea.md | 6 ++++-- .../arkui-ts/ts-basic-components-textinput.md | 3 +-- .../reference/arkui-ts/ts-container-navigator.md | 10 ++++++---- 5 files changed, 14 insertions(+), 11 deletions(-) diff --git a/zh-cn/application-dev/reference/arkui-js/js-components-media-video.md b/zh-cn/application-dev/reference/arkui-js/js-components-media-video.md index b6543f2742..ed78e584cd 100644 --- a/zh-cn/application-dev/reference/arkui-js/js-components-media-video.md +++ b/zh-cn/application-dev/reference/arkui-js/js-components-media-video.md @@ -89,7 +89,7 @@ onpaues='pauesCallback' onfinish='finishCallback' onerror='errorCallback' onseeking='seekingCallback' onseeked='seekedCallback' ontimeupdate='timeupdateCallback' - style="object-fit:fit; width:80%; height:400px;" + style="object-fit:fill; width:80%; height:400px;" onclick="change_start_pause"> diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-progress.md b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-progress.md index 1acb2860c2..412a9e92d6 100644 --- a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-progress.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-progress.md @@ -86,8 +86,8 @@ struct ProgressExample { Text('Capsule Progress').fontSize(9).fontColor(0xCCCCCC).width('90%') Row({ space: 40 }) { - Progress({ value: 10, type: ProgressType.Capsule }).width(100) - Progress({ value: 20, total: 150, type: ProgressType.Capsule }).color(Color.Grey).value(50).width(100) + Progress({ value: 10, type: ProgressType.Capsule }).width(100).height(50) + Progress({ value: 20, total: 150, type: ProgressType.Capsule }).color(Color.Grey).value(50).width(100).height(50) } }.width('100%').margin({ top: 30 }) } diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textarea.md b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textarea.md index f513523443..4198db7e5b 100644 --- a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textarea.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textarea.md @@ -19,7 +19,7 @@ ## 接口 -TextArea(value?:{placeholder?: string controller?: TextAreaController}) +TextArea(value?:{placeholder?: string, controller?: TextAreaController}) - 参数 | 参数名 | 参数类型 | 必填 | 默认值 | 参数描述 | @@ -89,10 +89,11 @@ caretPosition(value: number): void @Entry @Component struct TextAreaExample1 { + controller: TextAreaController = new TextAreaController() @State text: string = '' build() { Column() { - TextArea({ placeholder: 'input your word'}) + TextArea({ placeholder: 'input your word', controller: this.controller}) .placeholderColor("rgb(0,0,225)") .placeholderFont({ size: 30, weight: 100, family: 'cursive', style: FontStyle.Italic }) .textAlign(TextAlign.Center) @@ -108,6 +109,7 @@ struct TextAreaExample1 { }) .onChange((value: string) => { this.text = value + this.controller.caretPosition(-1) }) Text(this.text).width('90%') } diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textinput.md b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textinput.md index 279471bbf8..fbcf06c145 100644 --- a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textinput.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textinput.md @@ -105,10 +105,9 @@ struct TextInputExample1 { build() { Column() { - TextArea({ placeholder: 'input your word' }) + TextInput({ placeholder: 'input your word' }) .placeholderColor("rgb(0,0,225)") .placeholderFont({ size: 30, weight: 100, family: 'cursive', style: FontStyle.Italic }) - .textAlign(TextAlign.Center) .caretColor(Color.Blue) .height(50) .fontSize(30) diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-container-navigator.md b/zh-cn/application-dev/reference/arkui-ts/ts-container-navigator.md index b8afaa69fd..cab72748f3 100644 --- a/zh-cn/application-dev/reference/arkui-ts/ts-container-navigator.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-container-navigator.md @@ -53,12 +53,13 @@ Navigator(value?: {target: string, type?: NavigationType}) @Component struct NavigatorExample { @State active: boolean = false - @State Text: string = 'news' + @State Text: object = {name: 'news'} build() { Flex({ direction: FlexDirection.Column, alignItems: ItemAlign.Start, justifyContent: FlexAlign.SpaceBetween }) { Navigator({ target: 'pages/container/navigator/Detail', type: NavigationType.Push }) { - Text('Go to ' + this.Text + ' page').width('100%').textAlign(TextAlign.Center) + Text('Go to ' + this.Text['name'] + ' page') + .width('100%').textAlign(TextAlign.Center) }.params({ text: this.Text }) Navigator() { @@ -79,7 +80,7 @@ import router from '@system.router' @Entry @Component struct DetailExample { - @State text: string = router.getParams().text + @State text: any = router.getParams().text build() { Flex({ direction: FlexDirection.Column, alignItems: ItemAlign.Start, justifyContent: FlexAlign.SpaceBetween }) { @@ -87,7 +88,8 @@ struct DetailExample { Text('Go to back page').width('100%').height(20) } - Text('This is ' + this.text + ' page').width('100%').textAlign(TextAlign.Center) + Text('This is ' + this.text['name'] + ' page') + .width('100%').textAlign(TextAlign.Center) } .width('100%').height(200).padding({ left: 35, right: 35, top: 35 }) } -- GitLab