diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-datepicker.md b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-datepicker.md index c6405174c194a2e4f0fd89b68ce5a75d6b8b5cae..332676543c8b0a85d795a6ecee41230e44bfa9f3 100644 --- a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-datepicker.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-datepicker.md @@ -30,12 +30,12 @@ DatePicker(options?: {start?: Date, end?: Date, selected?: Date}) 除支持[通用属性](ts-universal-attributes-size.md)外,还支持以下属性: -| 名称 | 参数类型 | 描述 | -| -------------------------------- | ---------------------------------------- | ---------------------------------------- | -| lunar | boolean | 日期是否显示农历。
- true:展示农历。
- false:不展示农历。
默认值:false | -| disappearTextStyle10+ | [PickerTextStyle](#pickertextstyle10类型说明) | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。 | -| textStyle10+ | [PickerTextStyle](#pickertextstyle10类型说明) | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。 | -| selectedTextStyle10+ | [PickerTextStyle](#pickertextstyle10类型说明) | 设置选中项的文本颜色、字号、字体粗细。 | +| 名称 | 参数类型 | 描述 | +| -------------------------------- | --------------------------------------------- | ------------------------------------------------------------ | +| lunar | boolean | 日期是否显示农历。
- true:展示农历。
- false:不展示农历。
默认值:false | +| disappearTextStyle10+ | [PickerTextStyle](#pickertextstyle10类型说明) | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '14fp',
weight: FontWeight.Regular
}
} | +| textStyle10+ | [PickerTextStyle](#pickertextstyle10类型说明) | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '16fp',
weight: FontWeight.Regular
}
} | +| selectedTextStyle10+ | [PickerTextStyle](#pickertextstyle10类型说明) | 设置选中项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff007dff',
font: {
size: '20vp',
weight: FontWeight.Medium
}
} | ## PickerTextStyle10+类型说明 diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-rating.md b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-rating.md index 089c0d5798917c17966d61da4487da1cd2bb6a7d..b13dc7ce3ed655f800f5a2443ddca15a1a19b1f4 100644 --- a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-rating.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-rating.md @@ -28,10 +28,10 @@ Rating(options?: { rating: number, indicator?: boolean }) ## 属性 -| 名称 | 参数类型 | 描述 | -| --------- | ---------------------------------------- | ---------------------------------------- | -| stars | number | 设置评分总数。
默认值:5
从API version 9开始,该接口支持在ArkTS卡片中使用。
**说明:**
设置为小于0的值时,按默认值显示。 | -| stepSize | number | 操作评级的步长。
默认值:0.5
从API version 9开始,该接口支持在ArkTS卡片中使用。
**说明:**
设置为小于0的值时,按默认值显示。
取值范围为[0.1, stars]。 | +| 名称 | 参数类型 | 描述 | +| --------- | ------------------------------------------------------------ | ------------------------------------------------------------ | +| stars | number | 设置评分总数。
默认值:5
从API version 9开始,该接口支持在ArkTS卡片中使用。
**说明:**
设置为小于等于0的值时,按默认值显示。 | +| stepSize | number | 操作评级的步长。
默认值:0.5
从API version 9开始,该接口支持在ArkTS卡片中使用。
**说明:**
设置为小于0的值时,按默认值显示。
取值范围为[0.1, stars]。 | | starStyle | {
backgroundUri: string,
foregroundUri: string,
secondaryUri?: string
} | backgroundUri:未选中的星级的图片链接,可由用户自定义或使用系统默认图片。
foregroundUri:选中的星级的图片路径,可由用户自定义或使用系统默认图片。
secondaryUir:部分选中的星级的图片路径,可由用户自定义或使用系统默认图片。
从API version 9开始,该接口支持在ArkTS卡片中使用。
**说明:**
startStyle属性所支持的图片类型能力参考[Image](ts-basic-components-image.md)组件。
支持加载本地图片和网络图片,暂不支持PixelMap类型和Resource资源。
默认图片加载方式为异步,暂不支持同步加载。
设置值为undefined或者空字符串时,rating会选择加载系统默认星型图源。 | > **说明:** diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textpicker.md b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textpicker.md index 2bbed5719a9e4c7cd2a1793bbd0614270bf16c67..831a2a19a89c65ba815b591d9fb541079fbaf2ff 100755 --- a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textpicker.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-textpicker.md @@ -47,9 +47,9 @@ TextPicker(options?: {range: string[] | string[][] | Resource | TextPickerRangeC | 名称 | 参数类型 | 描述 | | -------- | -------- | -------- | | defaultPickerItemHeight | number \| string | 设置Picker各选择项的高度。 | -| disappearTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。 | -| textStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。 | -| selectedTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置选中项的文本颜色、字号、字体粗细。 | +| disappearTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '14fp',
weight: FontWeight.Regular
}
} | +| textStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '16fp',
weight: FontWeight.Regular
}
} | +| selectedTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置选中项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff007dff',
font: {
size: '20vp',
weight: FontWeight.Medium
}
} | | selectedIndex10+ | number \| number[] | 设置默认选中项在数组中的索引值,优先级高于options中的选中值。
**说明**:单列数据选择器使用number类型。多列、多列联动数据选择器使用number[]类型。 | ## 事件 diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-timepicker.md b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-timepicker.md index d472725ac4eaedb592d8fa813d5715b884b1b87a..654535bb907e002000994e20f40550abca2593ba 100644 --- a/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-timepicker.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-timepicker.md @@ -28,12 +28,12 @@ TimePicker(options?: {selected?: Date}) 除支持[通用属性](ts-universal-attributes-size.md)外,还支持以下属性: -| 名称 | 参数类型 | 描述 | -| -------------------------------- | ---------------------------------------- | ----------------------------------- | -| useMilitaryTime | boolean | 展示时间是否为24小时制,不支持动态修改。
默认值:false | -| disappearTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。 | -| textStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。 | -| selectedTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置选中项的文本颜色、字号、字体粗细。 | +| 名称 | 参数类型 | 描述 | +| -------------------------------- | ------------------------------------------------------------ | ------------------------------------------------------------ | +| useMilitaryTime | boolean | 展示时间是否为24小时制。
默认值:false | +| disappearTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '14fp',
weight: FontWeight.Regular
}
} | +| textStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '16fp',
weight: FontWeight.Regular
}
} | +| selectedTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 设置选中项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff007dff',
font: {
size: '20vp',
weight: FontWeight.Medium
}
} | ## 事件 diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-methods-datepicker-dialog.md b/zh-cn/application-dev/reference/arkui-ts/ts-methods-datepicker-dialog.md index cd6d19aa11e21603766b323f7a661b8d73fb186a..21cbf418422030c35d7b82534a9f9ad3f14a07e9 100644 --- a/zh-cn/application-dev/reference/arkui-ts/ts-methods-datepicker-dialog.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-methods-datepicker-dialog.md @@ -15,20 +15,20 @@ show(options?: DatePickerDialogOptions) **DatePickerDialogOptions参数:** -| 参数名 | 参数类型 | 必填 | 默认值 | 参数描述 | -| -------- | -------- | -------- | -------- | -------- | -| start | Date | 否 | Date('1970-1-1') | 设置选择器的起始日期。 | -| end | Date | 否 | Date('2100-12-31') | 设置选择器的结束日期。 | -| selected | Date | 否 | 当前系统日期 | 设置当前选中的日期。 | -| lunar | boolean | 否 | false | 日期是否显示为农历。 | -| showTime10+ | boolean | 否 | false | 是否展示时间项。 | -| useMilitaryTime10+ | boolean | 否 | false | 展示时间是否为24小时制。 | -| disappearTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | - | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。 | -| textStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | - | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。 | -| selectedTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | - | 设置选中项的文本颜色、字号、字体粗细。 | -| onAccept | (value: [DatePickerResult](ts-basic-components-datepicker.md#DatePickerResult对象说明)) => void | 否 | - | 点击弹窗中的“确定”按钮时触发该回调。 | -| onCancel | () => void | 否 | - | 点击弹窗中的“取消”按钮时触发该回调。 | -| onChange | (value: [DatePickerResult](ts-basic-components-datepicker.md#DatePickerResult对象说明)) => void | 否 | - | 滑动弹窗中的滑动选择器使当前选中项改变时触发该回调。 | +| 参数名 | 参数类型 | 必填 | 参数描述 | +| -------- | -------- | -------- | -------- | +| start | Date | 否 | 设置选择器的起始日期。
默认值:Date('1970-1-1') | +| end | Date | 否 | 设置选择器的结束日期。
默认值:Date('2100-12-31') | +| selected | Date | 否 | 设置当前选中的日期。
默认值:当前系统日期 | +| lunar | boolean | 否 | 日期是否显示为农历。
默认值:false | +| showTime10+ | boolean | 否 | 是否展示时间项。
默认值:false | +| useMilitaryTime10+ | boolean | 否 | 展示时间是否为24小时制。
默认值:false | +| disappearTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '14fp',
weight: FontWeight.Regular
}
} | +| textStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '16fp',
weight: FontWeight.Regular
}
} | +| selectedTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置选中项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff007dff',
font: {
size: '20vp',
weight: FontWeight.Medium
}
} | +| onAccept | (value: [DatePickerResult](ts-basic-components-datepicker.md#DatePickerResult对象说明)) => void | 否 | 点击弹窗中的“确定”按钮时触发该回调。 | +| onCancel | () => void | 否 | 点击弹窗中的“取消”按钮时触发该回调。 | +| onChange | (value: [DatePickerResult](ts-basic-components-datepicker.md#DatePickerResult对象说明)) => void | 否 | 滑动弹窗中的滑动选择器使当前选中项改变时触发该回调。 | ## 示例 @@ -87,4 +87,4 @@ struct DatePickerDialogExample { } ``` -![DataPickerDialog](figures\DataPickerDialog.gif) \ No newline at end of file +![DataPickerDialog](figures/DataPickerDialog.gif) diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-methods-textpicker-dialog.md b/zh-cn/application-dev/reference/arkui-ts/ts-methods-textpicker-dialog.md index a59a0462484d35b153ded64d791da79b4dbbf2c0..28785bc3be8c81a23cefca62cd409bae6cf39fc8 100755 --- a/zh-cn/application-dev/reference/arkui-ts/ts-methods-textpicker-dialog.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-methods-textpicker-dialog.md @@ -21,9 +21,9 @@ show(options?: TextPickerDialogOptions) | selected | number | 否 | 设置选中项的索引值。
默认值:0 | | value | string | 否 | 设置选中项的文本内容。当设置了selected参数时,该参数不生效。如果设置的value值不在range范围内,则默认取range第一个元素。| | defaultPickerItemHeight | number \| string | 否 | 设置选择器中选项的高度。 | -| disappearTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。 | -| textStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。 | -| selectedTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置选中项的文本颜色、字号、字体粗细。 | +| disappearTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '14fp',
weight: FontWeight.Regular
}
} | +| textStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '16fp',
weight: FontWeight.Regular
}
} | +| selectedTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置选中项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff007dff',
font: {
size: '20vp',
weight: FontWeight.Medium
}
} | | onAccept | (value: [TextPickerResult](#textpickerresult对象说明)) => void | 否 | 点击弹窗中的“确定”按钮时触发该回调。 | | onCancel | () => void | 否 | 点击弹窗中的“取消”按钮时触发该回调。 | | onChange | (value: [TextPickerResult](#textpickerresult对象说明)) => void | 否 | 滑动弹窗中的选择器使当前选中项改变时触发该回调。 | @@ -73,4 +73,4 @@ struct TextPickerDialogExample { } ``` -![TextPickerDialog](figures\TextPickerDialog.gif) \ No newline at end of file +![TextPickerDialog](figures/TextPickerDialog.gif) diff --git a/zh-cn/application-dev/reference/arkui-ts/ts-methods-timepicker-dialog.md b/zh-cn/application-dev/reference/arkui-ts/ts-methods-timepicker-dialog.md index 436e19230a34f32c9da3978891fea1c57d664ef6..5c4fede524c07beaa9ca3d558ad1f58398a1a25e 100644 --- a/zh-cn/application-dev/reference/arkui-ts/ts-methods-timepicker-dialog.md +++ b/zh-cn/application-dev/reference/arkui-ts/ts-methods-timepicker-dialog.md @@ -19,9 +19,9 @@ show(options?: TimePickerDialogOptions) | -------- | -------- | -------- | -------- | | selected | Date | 否 | 设置当前选中的时间。
默认值:当前系统时间 | | useMilitaryTime | boolean | 否 | 展示时间是否为24小时制,默认为12小时制。
默认值:false | -| disappearTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。 | -| textStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。 | -| selectedTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置选中项的文本颜色、字号、字体粗细。 | +| disappearTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置所有选项中最上和最下两个选项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '14fp',
weight: FontWeight.Regular
}
} | +| textStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置所有选项中除了最上、最下及选中项以外的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff182431',
font: {
size: '16fp',
weight: FontWeight.Regular
}
} | +| selectedTextStyle10+ | [PickerTextStyle](ts-basic-components-datepicker.md#pickertextstyle10类型说明) | 否 | 设置选中项的文本颜色、字号、字体粗细。
默认值:
{
corlor: '#ff007dff',
font: {
size: '20vp',
weight: FontWeight.Medium
}
} | | onAccept | (value: [TimePickerResult](ts-basic-components-timepicker.md#TimePickerResult对象说明)) => void | 否 | 点击弹窗中的“确定”按钮时触发该回调。 | | onCancel | () => void | 否 | 点击弹窗中的“取消”按钮时触发该回调。 | | onChange | (value: [TimePickerResult](ts-basic-components-timepicker.md#TimePickerResult对象说明)) => void | 否 | 滑动弹窗中的选择器使当前选中时间改变时触发该回调。 | @@ -78,4 +78,4 @@ struct TimePickerDialogExample { } ``` -![TimetPickerDialog](figures\TimePickerDialog.gif) \ No newline at end of file +![TimetPickerDialog](figures/TimePickerDialog.gif)